diff --git a/.gitignore b/.gitignore index dbef116..a35a5ec 100644 --- a/.gitignore +++ b/.gitignore @@ -1,21 +1,79 @@ -# See https://www.dartlang.org/guides/libraries/private-files +# Miscellaneous +*.class +*.lock +*.log +*.pyc +*.swp +.DS_Store +.atom/ +.buildlog/ +.history +.svn/ -# Files and directories created by pub +# IntelliJ related +*.iml +*.ipr +*.iws +.idea/ + +# The .vscode folder contains launch configuration and tasks you configure in +# VS Code which you may wish to be included in version control, so this line +# is commented out by default. +#.vscode/ + +# Flutter/Dart/Pub related +**/doc/api/ .dart_tool/ +.flutter-plugins +.flutter-plugins-dependencies .packages +.pub-cache/ +.pub/ build/ -# If you're building an application, you may want to check-in your pubspec.lock -pubspec.lock -# Directory created by dartdoc -# If you don't generate documentation locally you can remove this line. -doc/api/ +# Android related +**/android/**/gradle-wrapper.jar +**/android/.gradle +**/android/captures/ +**/android/gradlew +**/android/gradlew.bat +**/android/local.properties +**/android/**/GeneratedPluginRegistrant.java + +# iOS/XCode related +**/ios/**/*.mode1v3 +**/ios/**/*.mode2v3 +**/ios/**/*.moved-aside +**/ios/**/*.pbxuser +**/ios/**/*.perspectivev3 +**/ios/**/*sync/ +**/ios/**/.sconsign.dblite +**/ios/**/.tags* +**/ios/**/.vagrant/ +**/ios/**/DerivedData/ +**/ios/**/Icon? +**/ios/**/Pods/ +**/ios/**/.symlinks/ +**/ios/**/profile +**/ios/**/xcuserdata +**/ios/.generated/ +**/ios/Flutter/App.framework +**/ios/Flutter/Flutter.framework +**/ios/Flutter/Flutter.podspec +**/ios/Flutter/Generated.xcconfig +**/ios/Flutter/ephemeral +**/ios/Flutter/app.flx +**/ios/Flutter/app.zip +**/ios/Flutter/flutter_assets/ +**/ios/Flutter/flutter_export_environment.sh +**/ios/ServiceDefinitions.json +**/ios/Runner/GeneratedPluginRegistrant.* + +# Exceptions to above rules. +!**/ios/**/default.mode1v3 +!**/ios/**/default.mode2v3 +!**/ios/**/default.pbxuser +!**/ios/**/default.perspectivev3 -# Avoid committing generated Javascript files: -*.dart.js -*.info.json # Produced by the --dump-info flag. -*.js # When generated by dart2js. Don't specify *.js if your - # project includes source files written in JavaScript. -*.js_ -*.js.deps -*.js.map +# Tizen Rootstraps +rootstraps/ \ No newline at end of file diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..b8fc056 --- /dev/null +++ b/LICENSE @@ -0,0 +1,25 @@ +Copyright (c) 2021 Samsung Electronics Co., Ltd. All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, +are permitted provided that the following conditions are met: + + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above + copyright notice, this list of conditions and the following + disclaimer in the documentation and/or other materials provided + with the distribution. + * Neither the name of the copyright holder nor the names of the + contributors may be used to endorse or promote products derived + from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..c236cbc --- /dev/null +++ b/README.md @@ -0,0 +1,22 @@ +# tizen_interop + +This package provides Dart bindings and utility functions for using Tizen native APIs. + +## Example + +```dart +import 'dart:ffi'; +import 'package:ffi/ffi.dart'; +import 'package:tizen_interop/4.0/wearable/tizen.dart'; + +String? getApplicationName() { + String? appName; + using((Arena arena) { + Pointer> namePtr = arena.allocate(sizeOf()); + tizen.app_get_name(namePtr); + appName = namePtr.value.toDartString(); + malloc.free(namePtr.value); + }); + return appName; +} +``` diff --git a/build.sh b/build.sh new file mode 100755 index 0000000..26c4899 --- /dev/null +++ b/build.sh @@ -0,0 +1,27 @@ +#!/usr/bin/env bash +# Copyright 2021 Samsung Electronics Co., Ltd. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. + +set -e + +SCRIPT_DIR=$(dirname $(readlink -f $0)) + +if [[ -z $TIZEN_STUDIO ]]; then + if [[ -d $HOME/tizen-studio ]]; then + TIZEN_STUDIO=$HOME/tizen-studio + else + echo "Not found the Tizen Studio. Please set the TIZEN_STUDIO environment variable." + exit 1 + fi +fi + +# Copy rootstraps from Tizen Studio. +OUTDIR=$SCRIPT_DIR/rootstraps +mkdir -p $OUTDIR + +cp -fr $TIZEN_STUDIO/platforms/tizen-4.0/wearable/rootstraps/wearable-4.0-device.core $OUTDIR + +# Generate binding code. +dart run symgen --config configs/4.0/wearable/symgen.yaml +dart run ffigen --config configs/4.0/wearable/ffigen.yaml diff --git a/configs/4.0/wearable/allowlist.txt b/configs/4.0/wearable/allowlist.txt new file mode 100644 index 0000000..d06f1bd --- /dev/null +++ b/configs/4.0/wearable/allowlist.txt @@ -0,0 +1,12282 @@ +ecore_animator_add +ecore_animator_del +ecore_animator_frametime_set +ecore_animator_freeze +ecore_animator_pos_map +ecore_animator_pos_map_n +ecore_animator_thaw +ecore_animator_timeline_add +ecore_animator_custom_source_tick_begin_callback_set +ecore_animator_custom_source_tick_end_callback_set +ecore_animator_custom_tick +ecore_animator_frametime_get +ecore_animator_source_get +ecore_animator_source_set +ecore_buffer_consumer_buffer_dequeue +ecore_buffer_consumer_buffer_enqueued_cb_set +ecore_buffer_consumer_buffer_release +ecore_buffer_consumer_free +ecore_buffer_consumer_new +ecore_buffer_consumer_provider_add_cb_set +ecore_buffer_consumer_provider_del_cb_set +ecore_buffer_consumer_queue_is_empty +ecore_buffer_flags_get +ecore_buffer_format_get +ecore_buffer_free +ecore_buffer_free_callback_add +ecore_buffer_free_callback_remove +ecore_buffer_init +ecore_buffer_new +ecore_buffer_new_with_tbm_surface +ecore_buffer_provider_buffer_acquirable_check +ecore_buffer_provider_buffer_acquire +ecore_buffer_provider_buffer_enqueue +ecore_buffer_provider_buffer_released_cb_set +ecore_buffer_provider_consumer_add_cb_set +ecore_buffer_provider_consumer_del_cb_set +ecore_buffer_provider_free +ecore_buffer_provider_new +ecore_buffer_queue_init +ecore_buffer_queue_shutdown +ecore_buffer_register +ecore_buffer_shutdown +ecore_buffer_size_get +ecore_buffer_tbm_surface_get +ecore_buffer_unregister +ecore_compose_get +ecore_event_init +ecore_event_modifier_mask +ecore_event_shutdown +ecore_event_update_modifier +ecore_event_add +ecore_event_handler_add +ecore_event_handler_data_set +ecore_event_handler_del +ecore_event_handler_data_get +ecore_event_current_event_get +ecore_event_current_type_get +ecore_event_del +ecore_event_type_new +ecore_event_filter_add +ecore_event_filter_del +ecore_imf_context_add +ecore_imf_context_autocapital_type_get +ecore_imf_context_autocapital_type_set +ecore_imf_context_available_ids_by_canvas_type_get +ecore_imf_context_available_ids_get +ecore_imf_context_bidi_direction_get +ecore_imf_context_bidi_direction_set +ecore_imf_context_candidate_panel_geometry_get +ecore_imf_context_client_canvas_get +ecore_imf_context_client_canvas_set +ecore_imf_context_client_window_get +ecore_imf_context_client_window_set +ecore_imf_context_commit_event_add +ecore_imf_context_control_panel_hide +ecore_imf_context_control_panel_show +ecore_imf_context_cursor_location_set +ecore_imf_context_cursor_position_set +ecore_imf_context_data_get +ecore_imf_context_data_set +ecore_imf_context_default_id_by_canvas_type_get +ecore_imf_context_default_id_get +ecore_imf_context_del +ecore_imf_context_delete_surrounding_event_add +ecore_imf_context_event_callback_add +ecore_imf_context_event_callback_call +ecore_imf_context_event_callback_del +ecore_imf_context_filter_event +ecore_imf_context_focus_in +ecore_imf_context_focus_out +ecore_imf_context_hide +ecore_imf_context_info_by_id_get +ecore_imf_context_info_get +ecore_imf_context_input_hint_get +ecore_imf_context_input_hint_set +ecore_imf_context_input_mode_get +ecore_imf_context_input_mode_set +ecore_imf_context_input_panel_caps_lock_mode_get +ecore_imf_context_input_panel_caps_lock_mode_set +ecore_imf_context_input_panel_enabled_get +ecore_imf_context_input_panel_enabled_set +ecore_imf_context_input_panel_event_callback_add +ecore_imf_context_input_panel_event_callback_call +ecore_imf_context_input_panel_event_callback_clear +ecore_imf_context_input_panel_event_callback_del +ecore_imf_context_input_panel_geometry_get +ecore_imf_context_input_panel_hide +ecore_imf_context_input_panel_imdata_get +ecore_imf_context_input_panel_imdata_set +ecore_imf_context_input_panel_language_get +ecore_imf_context_input_panel_language_locale_get +ecore_imf_context_input_panel_language_set +ecore_imf_context_input_panel_layout_get +ecore_imf_context_input_panel_layout_set +ecore_imf_context_input_panel_layout_variation_get +ecore_imf_context_input_panel_layout_variation_set +ecore_imf_context_input_panel_return_key_disabled_get +ecore_imf_context_input_panel_return_key_disabled_set +ecore_imf_context_input_panel_return_key_type_get +ecore_imf_context_input_panel_return_key_type_set +ecore_imf_context_input_panel_show +ecore_imf_context_input_panel_show_on_demand_get +ecore_imf_context_input_panel_show_on_demand_set +ecore_imf_context_input_panel_state_get +ecore_imf_context_new +ecore_imf_context_prediction_allow_get +ecore_imf_context_prediction_allow_set +ecore_imf_context_preedit_changed_event_add +ecore_imf_context_preedit_end_event_add +ecore_imf_context_preedit_start_event_add +ecore_imf_context_preedit_string_get +ecore_imf_context_preedit_string_with_attributes_get +ecore_imf_context_reset +ecore_imf_context_retrieve_selection_callback_set +ecore_imf_context_retrieve_surrounding_callback_set +ecore_imf_context_selection_get +ecore_imf_context_show +ecore_imf_context_surrounding_get +ecore_imf_context_use_preedit_set +ecore_imf_evas_event_key_down_wrap +ecore_imf_evas_event_key_up_wrap +ecore_imf_evas_event_mouse_down_wrap +ecore_imf_evas_event_mouse_in_wrap +ecore_imf_evas_event_mouse_move_wrap +ecore_imf_evas_event_mouse_out_wrap +ecore_imf_evas_event_mouse_up_wrap +ecore_imf_evas_event_mouse_wheel_wrap +ecore_imf_init +ecore_imf_input_panel_hide +ecore_imf_module_register +ecore_imf_shutdown +ecore_input_joystick_init +ecore_input_joystick_shutdown +ecore_idle_enterer_add +ecore_idle_enterer_before_add +ecore_idle_enterer_del +ecore_idle_exiter_add +ecore_idle_exiter_del +ecore_idler_add +ecore_idler_del +ecore_job_add +ecore_job_del +ecore_main_fd_handler_active_get +ecore_main_fd_handler_active_set +ecore_main_fd_handler_add +ecore_main_fd_handler_del +ecore_main_fd_handler_fd_get +ecore_main_fd_handler_file_add +ecore_main_fd_handler_prepare_callback_set +ecore_main_loop_begin +ecore_main_loop_glib_always_integrate_disable +ecore_main_loop_glib_integrate +ecore_main_loop_iterate +ecore_main_loop_quit +ecore_main_loop_select_func_get +ecore_main_loop_select_func_set +ecore_main_loop_thread_safe_call_async +ecore_main_loop_thread_safe_call_sync +ecore_thread_main_loop_begin +ecore_thread_main_loop_end +ecore_fork_reset +ecore_fork_reset_callback_add +ecore_fork_reset_callback_del +ecore_pipe_add +ecore_pipe_del +ecore_pipe_freeze +ecore_pipe_read_close +ecore_pipe_wait +ecore_pipe_write +ecore_pipe_write_close +ecore_pipe_thaw +ecore_poller_add +ecore_poller_del +ecore_poller_poll_interval_get +ecore_poller_poll_interval_set +ecore_poller_poller_interval_get +ecore_poller_poller_interval_set +ecore_thread_active_get +ecore_thread_available_get +ecore_thread_reschedule +ecore_thread_cancel +ecore_thread_check +ecore_thread_run +ecore_thread_feedback +ecore_thread_feedback_run +ecore_thread_global_data_add +ecore_thread_global_data_del +ecore_thread_global_data_find +ecore_thread_global_data_set +ecore_thread_global_data_wait +ecore_thread_local_data_add +ecore_thread_local_data_del +ecore_thread_local_data_find +ecore_thread_local_data_set +ecore_thread_max_get +ecore_thread_max_set +ecore_thread_max_reset +ecore_thread_pending_feedback_get +ecore_thread_pending_get +ecore_thread_pending_total_get +ecore_time_get +ecore_time_unix_get +ecore_loop_time_get +ecore_timer_add +ecore_timer_loop_add +ecore_timer_del +ecore_timer_delay +ecore_timer_dump +ecore_timer_freeze +ecore_timer_interval_get +ecore_timer_interval_set +ecore_timer_pending_get +ecore_timer_precision_set +ecore_timer_reset +ecore_timer_precision_get +ecore_timer_thaw +edje_object_add +edje_object_preload +edje_color_class_del +edje_color_class_get +edje_color_class_list +edje_color_class_set +edje_object_color_class_del +edje_object_color_class_get +edje_object_color_class_set +edje_text_class_del +edje_text_class_get +edje_text_class_list +edje_text_class_set +edje_object_text_class_get +edje_object_text_class_set +edje_file_collection_list +edje_file_collection_list_free +edje_file_data_get +edje_file_group_exists +edje_object_file_get +edje_object_file_set +edje_object_data_get +edje_object_load_error_get +edje_load_error_str +edje_frametime_get +edje_frametime_set +edje_freeze +edje_thaw +edje_object_play_get +edje_object_play_set +edje_object_animation_get +edje_object_part_state_get +edje_object_animation_set +edje_object_base_scale_get +edje_object_thaw +edje_object_freeze +edje_object_size_min_calc +edje_object_size_max_get +edje_object_size_min_get +edje_object_update_hints_get +edje_object_update_hints_set +edje_object_calc_force +edje_object_size_min_restricted_calc +edje_object_parts_extends_calc +edje_object_perspective_get +edje_object_perspective_set +edje_evas_global_perspective_get +edje_perspective_free +edje_perspective_global_get +edje_perspective_global_set +edje_perspective_new +edje_perspective_set +edje_message_signal_process +edje_object_message_handler_set +edje_object_message_send +edje_object_message_signal_process +edje_object_part_box_append +edje_object_part_box_insert_at +edje_object_part_box_insert_before +edje_object_part_box_prepend +edje_object_part_box_remove +edje_object_part_box_remove_all +edje_object_part_box_remove_at +edje_box_layout_register +edje_object_part_drag_dir_get +edje_object_part_drag_page +edje_object_part_drag_page_get +edje_object_part_drag_page_set +edje_object_part_drag_size_get +edje_object_part_drag_size_set +edje_object_part_drag_step +edje_object_part_drag_step_get +edje_object_part_drag_step_set +edje_object_part_drag_value_get +edje_object_part_drag_value_set +edje_object_part_swallow +edje_object_part_swallow_get +edje_object_part_unswallow +edje_object_part_exists +edje_object_part_geometry_get +edje_object_part_object_get +edje_object_access_part_list_get +edje_object_part_text_set +edje_object_part_text_get +edje_object_part_text_style_user_peek +edje_object_part_text_style_user_pop +edje_object_part_text_style_user_push +edje_object_part_text_unescaped_get +edje_object_part_text_unescaped_set +edje_object_part_text_insert +edje_object_part_text_append +edje_object_text_change_cb_set +edje_object_part_text_anchor_list_get +edje_object_part_text_anchor_geometry_get +edje_object_part_text_item_list_get +edje_object_part_text_item_geometry_get +edje_object_part_text_user_insert +edje_object_part_table_child_get +edje_object_part_table_clear +edje_object_part_table_col_row_size_get +edje_object_part_table_pack +edje_object_part_table_unpack +edje_scale_get +edje_scale_set +edje_object_scale_get +edje_object_scale_set +edje_object_signal_callback_add +edje_object_signal_callback_del +edje_object_signal_callback_del_full +edje_object_signal_callback_extra_data_get +edje_object_signal_emit +edje_object_part_text_escaped_set +eina_accessor_container_get +eina_accessor_data_get +eina_accessor_free +eina_accessor_lock +eina_accessor_over +eina_accessor_unlock +eina_array_accessor_new +eina_array_flush +eina_array_free +eina_array_iterator_new +eina_array_new +eina_array_remove +eina_array_step_set +eina_array_clean +eina_array_push +eina_array_pop +eina_array_data_get +eina_array_data_set +eina_array_count +eina_array_foreach +eina_unicode_strcmp +eina_unicode_strcpy +eina_unicode_strdup +eina_unicode_strlen +eina_unicode_strncpy +eina_unicode_strndup +eina_unicode_strnlen +eina_unicode_strstr +eina_unicode_unicode_to_utf8 +eina_unicode_utf8_get_len +eina_unicode_utf8_get_prev +eina_unicode_utf8_to_unicode +eina_unicode_utf8_next_get +eina_unicode_escape +eina_ustrbuf_append +eina_ustrbuf_free +eina_ustrbuf_insert +eina_ustrbuf_insert_n +eina_ustrbuf_manage_new +eina_ustrbuf_new +eina_ustrbuf_remove +eina_ustrbuf_append_char +eina_ustrbuf_append_escaped +eina_ustrbuf_append_length +eina_ustrbuf_append_n +eina_ustrbuf_insert_char +eina_ustrbuf_insert_escaped +eina_ustrbuf_insert_length +eina_ustrbuf_manage_new_length +eina_ustrbuf_reset +eina_ustrbuf_length_get +eina_ustrbuf_string_free +eina_ustrbuf_string_get +eina_ustrbuf_string_steal +eina_ustrbuf_prepend +eina_ustrbuf_prepend_escaped +eina_ustrbuf_prepend_n +eina_ustrbuf_prepend_length +eina_ustrbuf_prepend_char +eina_ustringshare_add +eina_ustringshare_del +eina_ustringshare_ref +eina_ustringshare_strlen +eina_ustringshare_add_length +eina_ustringshare_dump +eina_ustringshare_replace +eina_ustringshare_replace_length +eina_strbuf_append_vprintf +eina_strbuf_insert_char +eina_strbuf_insert_length +eina_strbuf_insert_vprintf +eina_strbuf_ltrim +eina_strbuf_manage_new_length +eina_strbuf_rtrim +eina_strbuf_trim +eina_strbuf_append +eina_strbuf_append_char +eina_strbuf_append_escaped +eina_strbuf_append_length +eina_strbuf_append_n +eina_strbuf_append_printf +eina_strbuf_free +eina_strbuf_insert +eina_strbuf_insert_escaped +eina_strbuf_insert_n +eina_strbuf_insert_printf +eina_strbuf_length_get +eina_strbuf_manage_new +eina_strbuf_new +eina_strbuf_remove +eina_strbuf_replace +eina_strbuf_replace_all +eina_strbuf_replace_first +eina_strbuf_reset +eina_strbuf_string_free +eina_strbuf_string_get +eina_strbuf_string_steal +eina_strbuf_prepend +eina_strbuf_prepend_char +eina_strbuf_prepend_escaped +eina_strbuf_prepend_length +eina_strbuf_prepend_n +eina_strbuf_prepend_printf +eina_strbuf_prepend_vprintf +eina_tmpstr_add +eina_tmpstr_add_length +eina_tmpstr_del +eina_tmpstr_strlen +eina_binbuf_append_length +eina_binbuf_free +eina_binbuf_length_get +eina_binbuf_new +eina_binbuf_remove +eina_binbuf_reset +eina_binbuf_string_get +eina_binbuf_string_steal +eina_binbuf_append_char +eina_binbuf_insert_char +eina_binbuf_insert_length +eina_binbuf_manage_new_length +eina_binbuf_string_free +eina_binshare_add +eina_binshare_add_length +eina_binshare_del +eina_binshare_dump +eina_binshare_length +eina_binshare_ref +eina_convert_atod +eina_convert_atofp +eina_convert_dtoa +eina_convert_fptoa +eina_convert_itoa +eina_convert_xtoa +eina_counter_dump +eina_counter_free +eina_counter_new +eina_counter_start +eina_counter_stop +eina_hash_add +eina_hash_add_by_hash +eina_hash_del +eina_hash_del_by_data +eina_hash_del_by_hash +eina_hash_del_by_key +eina_hash_del_by_key_hash +eina_hash_direct_add +eina_hash_direct_add_by_hash +eina_hash_find +eina_hash_find_by_hash +eina_hash_foreach +eina_hash_free +eina_hash_free_buckets +eina_hash_free_cb_set +eina_hash_int32_new +eina_hash_int64_new +eina_hash_iterator_data_new +eina_hash_iterator_key_new +eina_hash_iterator_tuple_new +eina_hash_modify +eina_hash_modify_by_hash +eina_hash_move +eina_hash_new +eina_hash_pointer_new +eina_hash_population +eina_hash_set +eina_hash_string_djb2_new +eina_hash_string_small_new +eina_hash_string_superfast_new +eina_hash_stringshared_new +eina_hash_superfast +eina_hash_djb2 +eina_hash_djb2_len +eina_hash_int32 +eina_hash_int64 +eina_hash_murmur3 +eina_inarray_accessor_new +eina_inarray_alloc_at +eina_inarray_count +eina_inarray_flush +eina_inarray_foreach +eina_inarray_foreach_remove +eina_inarray_free +eina_inarray_grow +eina_inarray_insert +eina_inarray_insert_at +eina_inarray_insert_sorted +eina_inarray_iterator_new +eina_inarray_iterator_reversed_new +eina_inarray_new +eina_inarray_nth +eina_inarray_pop +eina_inarray_push +eina_inarray_remove +eina_inarray_remove_at +eina_inarray_replace_at +eina_inarray_reverse +eina_inarray_search +eina_inarray_search_sorted +eina_inarray_sort +eina_inarray_step_set +eina_inlist_accessor_new +eina_inlist_append +eina_inlist_append_relative +eina_inlist_count +eina_inlist_demote +eina_inlist_find +eina_inlist_iterator_new +eina_inlist_prepend +eina_inlist_prepend_relative +eina_inlist_promote +eina_inlist_remove +eina_inlist_sort +eina_inlist_sorted_insert +eina_inlist_sorted_state_free +eina_inlist_sorted_state_init +eina_inlist_sorted_state_insert +eina_inlist_sorted_state_new +eina_iterator_container_get +eina_iterator_foreach +eina_iterator_free +eina_iterator_lock +eina_iterator_next +eina_iterator_unlock +eina_lalloc_element_add +eina_lalloc_elements_add +eina_lalloc_free +eina_lalloc_new +eina_list_accessor_new +eina_list_append +eina_list_append_relative +eina_list_append_relative_list +eina_list_data_find +eina_list_data_find_list +eina_list_demote_list +eina_list_free +eina_list_iterator_new +eina_list_merge +eina_list_move +eina_list_nth +eina_list_nth_list +eina_list_prepend +eina_list_prepend_relative +eina_list_prepend_relative_list +eina_list_promote_list +eina_list_remove +eina_list_remove_list +eina_list_reverse +eina_list_reverse_clone +eina_list_search_sorted +eina_list_search_sorted_list +eina_list_search_sorted_near_list +eina_list_search_unsorted +eina_list_search_unsorted_list +eina_list_sort +eina_list_sorted_insert +eina_list_sorted_merge +eina_list_count +eina_list_last +eina_list_next +eina_list_prev +eina_list_data_get +eina_list_data_set +eina_list_clone +eina_list_iterator_reversed_new +eina_list_move_list +eina_list_split_list +EINA_LIST_FOREACH +EINA_LIST_REVERSE_FOREACH +EINA_LIST_FOREACH_SAFE +EINA_LIST_REVERSE_FOREACH_SAFE +EINA_LIST_FREE +eina_matrixsparse_cell_clear +eina_matrixsparse_cell_data_get +eina_matrixsparse_cell_data_replace +eina_matrixsparse_cell_data_set +eina_matrixsparse_cell_idx_clear +eina_matrixsparse_cell_idx_get +eina_matrixsparse_cell_position_get +eina_matrixsparse_column_idx_clear +eina_matrixsparse_data_idx_get +eina_matrixsparse_data_idx_replace +eina_matrixsparse_data_idx_set +eina_matrixsparse_free +eina_matrixsparse_iterator_complete_new +eina_matrixsparse_iterator_new +eina_matrixsparse_new +eina_matrixsparse_row_idx_clear +eina_matrixsparse_size_get +eina_matrixsparse_size_set +eina_module_arch_list_get +eina_module_environment_path_get +eina_module_file_get +eina_module_free +eina_module_list_free +eina_module_list_get +eina_module_list_load +eina_module_list_unload +eina_module_load +eina_module_new +eina_module_symbol_get +eina_module_symbol_path_get +eina_module_unload +eina_module_find +eina_rbtree_delete +eina_rbtree_inline_insert +eina_rbtree_inline_remove +eina_rbtree_iterator_infix +eina_rbtree_iterator_postfix +eina_rbtree_iterator_prefix +eina_rectangle_free +eina_rectangle_new +eina_rectangle_pool_count +eina_rectangle_pool_data_get +eina_rectangle_pool_data_set +eina_rectangle_pool_free +eina_rectangle_pool_geometry_get +eina_rectangle_pool_get +eina_rectangle_pool_new +eina_rectangle_pool_release +eina_rectangle_pool_request +eina_rectangle_pool_packing_set +eina_spans_intersect +eina_rectangle_is_empty +eina_rectangle_coords_from +eina_rectangles_intersect +eina_rectangle_xcoord_inside +eina_rectangle_ycoord_inside +eina_rectangle_coords_inside +eina_rectangle_union +eina_rectangle_intersection +eina_rectangle_rescale_in +eina_rectangle_rescale_out +eina_simple_xml_node_dump +eina_simple_xml_node_load +eina_simple_xml_node_root_free +eina_simple_xml_parse +eina_simple_xml_attribute_free +eina_simple_xml_attribute_new +eina_simple_xml_attributes_parse +eina_simple_xml_node_cdata_free +eina_simple_xml_node_cdata_new +eina_simple_xml_node_comment_free +eina_simple_xml_node_comment_new +eina_simple_xml_node_data_free +eina_simple_xml_node_data_new +eina_simple_xml_node_doctype_child_free +eina_simple_xml_node_doctype_child_new +eina_simple_xml_node_doctype_free +eina_simple_xml_node_doctype_new +eina_simple_xml_node_processing_free +eina_simple_xml_node_processing_new +eina_simple_xml_node_tag_free +eina_simple_xml_node_tag_new +eina_simple_xml_tag_attributes_find +eina_str_convert +eina_str_escape +eina_str_has_extension +eina_str_has_prefix +eina_str_has_suffix +eina_str_join_len +eina_str_split +eina_str_split_full +eina_str_tolower +eina_str_toupper +eina_str_join +eina_str_join_static +eina_strlen_bounded +eina_strlcat +eina_strlcpy +eina_stringshare_add +eina_stringshare_add_length +eina_stringshare_del +eina_stringshare_dump +eina_stringshare_nprintf +eina_stringshare_printf +eina_stringshare_ref +eina_stringshare_strlen +eina_stringshare_vprintf +eina_stringshare_refplace +eina_stringshare_replace +eina_stringshare_replace_length +eina_tile_grid_slicer_iterator_new +eina_tiler_clear +eina_tiler_free +eina_tiler_iterator_new +eina_tiler_new +eina_tiler_rect_add +eina_tiler_rect_del +eina_tiler_tile_size_set +eina_tile_grid_slicer_next +eina_tile_grid_slicer_setup +eina_trash_init +eina_trash_push +eina_trash_pop +EINA_TRASH_CLEAN +eina_xattr_double_get +eina_xattr_double_set +eina_xattr_fd_ls +eina_xattr_get +eina_xattr_int_get +eina_xattr_int_set +eina_xattr_ls +eina_xattr_set +eina_xattr_string_get +eina_xattr_string_set +eina_xattr_value_fd_ls +eina_xattr_value_ls +eina_clist_add_after +eina_clist_add_before +eina_clist_add_head +eina_clist_add_tail +eina_clist_count +eina_clist_element_init +eina_clist_element_is_linked +eina_clist_empty +eina_clist_head +eina_clist_init +eina_clist_move_head +eina_clist_move_tail +eina_clist_next +eina_clist_prev +eina_clist_remove +eina_clist_tail +elm_atspi_accessible_name_set +elm_atspi_accessible_name_get +elm_atspi_accessible_description_set +elm_atspi_accessible_description_get +elm_atspi_accessible_role_set +elm_atspi_accessible_role_get +elm_atspi_accessible_relationship_append +elm_atspi_accessible_relationship_remove +elm_atspi_accessible_translation_domain_set +elm_atspi_accessible_translation_domain_get +elm_calendar_first_day_of_week_set +elm_calendar_first_day_of_week_get +elm_calendar_selectable_set +elm_calendar_selectable_get +elm_calendar_interval_get +elm_calendar_interval_set +elm_calendar_weekdays_names_set +elm_calendar_weekdays_names_get +elm_calendar_select_mode_set +elm_calendar_select_mode_get +elm_calendar_min_max_year_set +elm_calendar_min_max_year_get +elm_calendar_marks_get +elm_calendar_format_function_set +elm_calendar_selected_time_set +elm_calendar_selected_time_get +elm_calendar_mark_add +elm_calendar_marks_clear +elm_calendar_marks_draw +elm_calendar_displayed_time_get +elm_calendar_mark_del +elm_calendar_add +elm_cnp_selection_set +elm_cnp_selection_get +elm_object_cnp_selection_clear +elm_cnp_selection_loss_callback_set +elm_drop_target_add +elm_drop_target_del +elm_drag_start +elm_drag_cancel +elm_drag_action_set +elm_drag_item_container_add +elm_drag_item_container_del +elm_drop_item_container_add +elm_drop_item_container_del +elm_bg_add +elm_bg_color_get +elm_bg_color_set +elm_bg_file_get +elm_bg_file_set +elm_bg_load_size_set +elm_bg_option_get +elm_bg_option_set +elm_box_add +elm_box_align_get +elm_box_align_set +elm_box_children_get +elm_box_clear +elm_box_homogeneous_get +elm_box_homogeneous_set +elm_box_horizontal_get +elm_box_horizontal_set +elm_box_layout_set +elm_box_layout_transition +elm_box_pack_after +elm_box_pack_before +elm_box_pack_end +elm_box_pack_start +elm_box_padding_get +elm_box_padding_set +elm_box_recalculate +elm_box_transition_free +elm_box_transition_new +elm_box_unpack +elm_box_unpack_all +elm_button_add +elm_button_autorepeat_gap_timeout_get +elm_button_autorepeat_gap_timeout_set +elm_button_autorepeat_get +elm_button_autorepeat_initial_timeout_get +elm_button_autorepeat_initial_timeout_set +elm_button_autorepeat_set +elm_check_add +elm_check_state_get +elm_check_state_pointer_set +elm_check_state_set +elm_colorselector_add +elm_colorselector_color_get +elm_colorselector_color_set +elm_colorselector_mode_get +elm_colorselector_mode_set +elm_colorselector_palette_clear +elm_colorselector_palette_color_add +elm_colorselector_palette_item_color_get +elm_colorselector_palette_item_color_set +elm_colorselector_palette_items_get +elm_colorselector_palette_name_get +elm_colorselector_palette_name_set +elm_config_accel_preference_get +elm_config_accel_preference_set +elm_config_accel_preference_override_get +elm_config_accel_preference_override_set +elm_config_all_flush +elm_config_cache_edje_collection_cache_size_get +elm_config_cache_edje_collection_cache_size_set +elm_config_cache_edje_file_cache_size_get +elm_config_cache_edje_file_cache_size_set +elm_config_cache_flush_enabled_get +elm_config_cache_flush_enabled_set +elm_config_cache_flush_interval_get +elm_config_cache_flush_interval_set +elm_config_cache_font_cache_size_get +elm_config_cache_font_cache_size_set +elm_config_cache_image_cache_size_get +elm_config_cache_image_cache_size_set +elm_config_color_classes_list_free +elm_config_color_classes_list_get +elm_config_color_overlay_apply +elm_config_color_overlay_list_get +elm_config_color_overlay_set +elm_config_color_overlay_unset +elm_config_cursor_engine_only_get +elm_config_cursor_engine_only_set +elm_config_finger_size_get +elm_config_finger_size_set +elm_config_focus_highlight_animate_get +elm_config_focus_highlight_animate_set +elm_config_focus_highlight_enabled_get +elm_config_focus_highlight_enabled_set +elm_config_font_overlay_apply +elm_config_font_overlay_list_get +elm_config_font_overlay_set +elm_config_font_overlay_unset +elm_config_glayer_double_tap_timeout_get +elm_config_glayer_double_tap_timeout_set +elm_config_glayer_long_tap_start_timeout_get +elm_config_glayer_long_tap_start_timeout_set +elm_config_indicator_service_get +elm_config_longpress_timeout_get +elm_config_longpress_timeout_set +elm_config_mirrored_get +elm_config_mirrored_set +elm_config_password_show_last_get +elm_config_password_show_last_set +elm_config_password_show_last_timeout_get +elm_config_password_show_last_timeout_set +elm_config_preferred_engine_get +elm_config_preferred_engine_set +elm_config_profile_dir_free +elm_config_profile_dir_get +elm_config_profile_get +elm_config_profile_list_free +elm_config_profile_list_get +elm_config_profile_set +elm_config_reload +elm_config_scale_get +elm_config_scale_set +elm_config_scroll_bounce_enabled_get +elm_config_scroll_bounce_enabled_set +elm_config_scroll_bounce_friction_get +elm_config_scroll_bounce_friction_set +elm_config_scroll_bring_in_scroll_friction_get +elm_config_scroll_bring_in_scroll_friction_set +elm_config_scroll_item_align_enabled_get +elm_config_scroll_item_align_enabled_set +elm_config_scroll_item_valign_get +elm_config_scroll_item_valign_set +elm_config_scroll_page_scroll_friction_get +elm_config_scroll_page_scroll_friction_set +elm_config_scroll_thumbscroll_acceleration_threshold_get +elm_config_scroll_thumbscroll_acceleration_threshold_set +elm_config_scroll_thumbscroll_acceleration_time_limit_get +elm_config_scroll_thumbscroll_acceleration_time_limit_set +elm_config_scroll_thumbscroll_acceleration_weight_get +elm_config_scroll_thumbscroll_acceleration_weight_set +elm_config_scroll_thumbscroll_border_friction_get +elm_config_scroll_thumbscroll_border_friction_set +elm_config_scroll_thumbscroll_enabled_get +elm_config_scroll_thumbscroll_enabled_set +elm_config_scroll_thumbscroll_flick_distance_tolerance_get +elm_config_scroll_thumbscroll_flick_distance_tolerance_set +elm_config_scroll_thumbscroll_friction_get +elm_config_scroll_thumbscroll_friction_set +elm_config_scroll_thumbscroll_friction_standard_get +elm_config_scroll_thumbscroll_friction_standard_set +elm_config_scroll_thumbscroll_hold_threshold_get +elm_config_scroll_thumbscroll_hold_threshold_set +elm_config_scroll_thumbscroll_min_friction_get +elm_config_scroll_thumbscroll_min_friction_set +elm_config_scroll_thumbscroll_momentum_threshold_get +elm_config_scroll_thumbscroll_momentum_threshold_set +elm_config_scroll_thumbscroll_sensitivity_friction_get +elm_config_scroll_thumbscroll_sensitivity_friction_set +elm_config_scroll_thumbscroll_threshold_get +elm_config_scroll_thumbscroll_threshold_set +elm_config_scroll_zoom_friction_get +elm_config_scroll_zoom_friction_set +elm_config_selection_unfocused_clear_get +elm_config_selection_unfocused_clear_set +elm_config_softcursor_mode_get +elm_config_softcursor_mode_set +elm_config_text_classes_list_free +elm_config_text_classes_list_get +elm_config_tooltip_delay_get +elm_config_tooltip_delay_set +elm_conformant_add +elm_ctxpopup_add +elm_ctxpopup_auto_hide_disabled_set +elm_ctxpopup_clear +elm_ctxpopup_direction_get +elm_ctxpopup_direction_priority_get +elm_ctxpopup_direction_priority_set +elm_ctxpopup_dismiss +elm_ctxpopup_horizontal_get +elm_ctxpopup_horizontal_set +elm_ctxpopup_hover_parent_get +elm_ctxpopup_hover_parent_set +elm_ctxpopup_item_append +elm_datetime_add +elm_datetime_field_limit_get +elm_datetime_field_limit_set +elm_datetime_field_visible_get +elm_datetime_field_visible_set +elm_datetime_format_get +elm_datetime_format_set +elm_datetime_value_get +elm_datetime_value_max_get +elm_datetime_value_max_set +elm_datetime_value_min_get +elm_datetime_value_min_set +elm_datetime_value_set +elm_app_name_set +elm_app_name_get +elm_app_base_scale_set +elm_app_base_scale_get +elm_app_bin_dir_get +elm_app_compile_bin_dir_set +elm_app_compile_data_dir_set +elm_app_compile_lib_dir_set +elm_app_compile_locale_set +elm_app_data_dir_get +elm_app_info_set +elm_app_lib_dir_get +elm_app_locale_dir_get +elm_app_prefix_dir_get +elm_cache_all_flush +elm_coords_finger_size_adjust +elm_entry_add +elm_entry_anchor_hover_end +elm_entry_anchor_hover_parent_get +elm_entry_anchor_hover_parent_set +elm_entry_anchor_hover_style_get +elm_entry_anchor_hover_style_set +elm_entry_autocapital_type_get +elm_entry_autocapital_type_set +elm_entry_autosave_get +elm_entry_autosave_set +elm_entry_calc_force +elm_entry_cnp_mode_get +elm_entry_cnp_mode_set +elm_entry_context_menu_clear +elm_entry_context_menu_disabled_get +elm_entry_context_menu_disabled_set +elm_entry_context_menu_item_add +elm_entry_cursor_begin_set +elm_entry_cursor_content_get +elm_entry_cursor_down +elm_entry_cursor_end_set +elm_entry_cursor_geometry_get +elm_entry_cursor_is_format_get +elm_entry_cursor_is_visible_format_get +elm_entry_cursor_line_begin_set +elm_entry_cursor_line_end_set +elm_entry_cursor_next +elm_entry_cursor_pos_get +elm_entry_cursor_pos_set +elm_entry_cursor_prev +elm_entry_cursor_selection_begin +elm_entry_cursor_selection_end +elm_entry_cursor_up +elm_entry_editable_get +elm_entry_editable_set +elm_entry_entry_append +elm_entry_entry_get +elm_entry_entry_insert +elm_entry_entry_set +elm_entry_file_get +elm_entry_file_save +elm_entry_file_set +elm_entry_filter_accept_set +elm_entry_filter_limit_size +elm_entry_icon_visible_set +elm_entry_imf_context_get +elm_entry_imf_context_reset +elm_entry_input_hint_get +elm_entry_input_hint_set +elm_entry_input_panel_enabled_get +elm_entry_input_panel_enabled_set +elm_entry_input_panel_hide +elm_entry_input_panel_imdata_get +elm_entry_input_panel_imdata_set +elm_entry_input_panel_language_get +elm_entry_input_panel_language_set +elm_entry_input_panel_layout_get +elm_entry_input_panel_layout_set +elm_entry_input_panel_layout_variation_get +elm_entry_input_panel_layout_variation_set +elm_entry_input_panel_return_key_autoenabled_set +elm_entry_input_panel_return_key_disabled_get +elm_entry_input_panel_return_key_disabled_set +elm_entry_input_panel_return_key_type_get +elm_entry_input_panel_return_key_type_set +elm_entry_input_panel_show +elm_entry_input_panel_show_on_demand_get +elm_entry_input_panel_show_on_demand_set +elm_entry_is_empty +elm_entry_item_provider_append +elm_entry_item_provider_prepend +elm_entry_item_provider_remove +elm_entry_line_wrap_get +elm_entry_line_wrap_set +elm_entry_markup_filter_append +elm_entry_markup_filter_prepend +elm_entry_markup_filter_remove +elm_entry_markup_to_utf8 +elm_entry_password_get +elm_entry_password_set +elm_entry_prediction_allow_get +elm_entry_prediction_allow_set +elm_entry_scrollable_get +elm_entry_scrollable_set +elm_entry_select_all +elm_entry_select_region_set +elm_entry_select_none +elm_entry_selection_copy +elm_entry_selection_cut +elm_entry_selection_get +elm_entry_selection_paste +elm_entry_single_line_get +elm_entry_single_line_set +elm_entry_text_style_user_peek +elm_entry_text_style_user_pop +elm_entry_text_style_user_push +elm_entry_textblock_get +elm_entry_utf8_to_markup +elm_flip_add +elm_flip_front_visible_get +elm_flip_go +elm_flip_go_to +elm_flip_interaction_direction_enabled_get +elm_flip_interaction_direction_enabled_set +elm_flip_interaction_direction_hitsize_get +elm_flip_interaction_direction_hitsize_set +elm_flip_interaction_get +elm_flip_interaction_set +elm_flip_perspective_set +elm_flipselector_first_interval_set +elm_flipselector_first_interval_get +elm_flipselector_items_get +elm_flipselector_first_item_get +elm_flipselector_last_item_get +elm_flipselector_selected_item_get +elm_flipselector_item_prepend +elm_flipselector_flip_next +elm_flipselector_item_append +elm_flipselector_flip_prev +elm_flipselector_add +elm_flipselector_item_selected_set +elm_flipselector_item_selected_get +elm_flipselector_item_prev_get +elm_flipselector_item_next_get +elm_font_available_hash_add +elm_font_available_hash_del +elm_font_fontconfig_name_free +elm_font_fontconfig_name_get +elm_font_properties_free +elm_font_properties_get +elm_gengrid_add +elm_gengrid_align_get +elm_gengrid_align_set +elm_gengrid_at_xy_item_get +elm_gengrid_clear +elm_gengrid_filled_get +elm_gengrid_filled_set +elm_gengrid_first_item_get +elm_gengrid_group_item_size_get +elm_gengrid_group_item_size_set +elm_gengrid_highlight_mode_get +elm_gengrid_highlight_mode_set +elm_gengrid_horizontal_get +elm_gengrid_horizontal_set +elm_gengrid_item_append +elm_gengrid_item_all_contents_unset +elm_gengrid_item_bring_in +elm_gengrid_item_class_free +elm_gengrid_item_class_new +elm_gengrid_item_class_ref +elm_gengrid_item_class_unref +elm_gengrid_item_cursor_engine_only_get +elm_gengrid_item_cursor_engine_only_set +elm_gengrid_item_cursor_get +elm_gengrid_item_cursor_set +elm_gengrid_item_cursor_style_get +elm_gengrid_item_cursor_style_set +elm_gengrid_item_cursor_unset +elm_gengrid_item_index_get +elm_gengrid_item_insert_after +elm_gengrid_item_insert_before +elm_gengrid_item_item_class_get +elm_gengrid_item_item_class_update +elm_gengrid_item_next_get +elm_gengrid_item_pos_get +elm_gengrid_item_prepend +elm_gengrid_item_prev_get +elm_gengrid_item_select_mode_get +elm_gengrid_item_select_mode_set +elm_gengrid_item_selected_get +elm_gengrid_item_selected_set +elm_gengrid_item_show +elm_gengrid_item_size_get +elm_gengrid_item_size_set +elm_gengrid_item_sorted_insert +elm_gengrid_item_tooltip_content_cb_set +elm_gengrid_item_tooltip_style_get +elm_gengrid_item_tooltip_style_set +elm_gengrid_item_tooltip_text_set +elm_gengrid_item_tooltip_unset +elm_gengrid_item_tooltip_window_mode_get +elm_gengrid_item_tooltip_window_mode_set +elm_gengrid_item_update +elm_gengrid_item_fields_update +elm_gengrid_items_count +elm_gengrid_last_item_get +elm_gengrid_multi_select_get +elm_gengrid_multi_select_set +elm_gengrid_page_show +elm_gengrid_realized_items_get +elm_gengrid_realized_items_update +elm_gengrid_reorder_mode_get +elm_gengrid_reorder_mode_set +elm_gengrid_select_mode_get +elm_gengrid_select_mode_set +elm_gengrid_selected_item_get +elm_gengrid_selected_items_get +elm_genlist_add +elm_genlist_at_xy_item_get +elm_genlist_block_count_get +elm_genlist_block_count_set +elm_genlist_clear +elm_genlist_first_item_get +elm_genlist_highlight_mode_get +elm_genlist_highlight_mode_set +elm_genlist_homogeneous_get +elm_genlist_homogeneous_set +elm_genlist_item_all_contents_unset +elm_genlist_item_append +elm_genlist_item_bring_in +elm_genlist_item_class_free +elm_genlist_item_class_new +elm_genlist_item_class_ref +elm_genlist_item_class_unref +elm_genlist_item_cursor_get +elm_genlist_item_cursor_set +elm_genlist_item_cursor_style_get +elm_genlist_item_cursor_style_set +elm_genlist_item_cursor_unset +elm_genlist_item_cursor_engine_only_set +elm_genlist_item_cursor_engine_only_get +elm_genlist_item_demote +elm_genlist_item_expanded_depth_get +elm_genlist_item_expanded_get +elm_genlist_item_expanded_set +elm_genlist_item_fields_update +elm_genlist_item_index_get +elm_genlist_item_insert_after +elm_genlist_item_insert_before +elm_genlist_item_item_class_get +elm_genlist_item_item_class_update +elm_genlist_item_next_get +elm_genlist_item_parent_get +elm_genlist_item_prepend +elm_genlist_item_prev_get +elm_genlist_item_promote +elm_genlist_item_select_mode_get +elm_genlist_item_select_mode_set +elm_genlist_item_selected_get +elm_genlist_item_selected_set +elm_genlist_item_show +elm_genlist_item_sorted_insert +elm_genlist_item_subitems_clear +elm_genlist_item_tooltip_content_cb_set +elm_genlist_item_tooltip_style_get +elm_genlist_item_tooltip_style_set +elm_genlist_item_tooltip_text_set +elm_genlist_item_tooltip_unset +elm_genlist_item_tooltip_window_mode_get +elm_genlist_item_tooltip_window_mode_set +elm_genlist_item_type_get +elm_genlist_item_update +elm_genlist_items_count +elm_genlist_last_item_get +elm_genlist_longpress_timeout_get +elm_genlist_longpress_timeout_set +elm_genlist_mode_get +elm_genlist_mode_set +elm_genlist_multi_select_get +elm_genlist_multi_select_set +elm_genlist_nth_item_get +elm_genlist_realized_items_get +elm_genlist_realized_items_update +elm_genlist_reorder_mode_get +elm_genlist_reorder_mode_set +elm_genlist_select_mode_get +elm_genlist_select_mode_set +elm_genlist_selected_item_get +elm_genlist_selected_items_get +elm_gesture_layer_add +elm_gesture_layer_attach +elm_gesture_layer_cb_set +elm_gesture_layer_continues_enable_get +elm_gesture_layer_continues_enable_set +elm_gesture_layer_double_tap_timeout_get +elm_gesture_layer_double_tap_timeout_set +elm_gesture_layer_flick_time_limit_ms_get +elm_gesture_layer_flick_time_limit_ms_set +elm_gesture_layer_hold_events_get +elm_gesture_layer_hold_events_set +elm_gesture_layer_line_angular_tolerance_get +elm_gesture_layer_line_angular_tolerance_set +elm_gesture_layer_line_distance_tolerance_get +elm_gesture_layer_line_distance_tolerance_set +elm_gesture_layer_line_min_length_get +elm_gesture_layer_line_min_length_set +elm_gesture_layer_long_tap_start_timeout_get +elm_gesture_layer_long_tap_start_timeout_set +elm_gesture_layer_rotate_angular_tolerance_get +elm_gesture_layer_rotate_angular_tolerance_set +elm_gesture_layer_rotate_step_get +elm_gesture_layer_rotate_step_set +elm_gesture_layer_tap_finger_size_get +elm_gesture_layer_tap_finger_size_set +elm_gesture_layer_zoom_distance_tolerance_get +elm_gesture_layer_zoom_distance_tolerance_set +elm_gesture_layer_zoom_finger_factor_get +elm_gesture_layer_zoom_finger_factor_set +elm_gesture_layer_zoom_step_get +elm_gesture_layer_zoom_step_set +elm_gesture_layer_zoom_wheel_factor_get +elm_gesture_layer_zoom_wheel_factor_set +elm_glview_add +elm_glview_changed_set +elm_glview_del_func_set +elm_glview_gl_api_get +elm_glview_init_func_set +elm_glview_mode_set +elm_glview_render_func_set +elm_glview_render_policy_set +elm_glview_resize_func_set +elm_glview_resize_policy_set +elm_glview_rotation_get +elm_glview_size_get +elm_glview_size_set +elm_glview_version_add +elm_glview_evas_gl_get +elm_grid_add +elm_grid_children_get +elm_grid_clear +elm_grid_pack +elm_grid_pack_get +elm_grid_pack_set +elm_grid_size_get +elm_grid_size_set +elm_grid_unpack +elm_hoversel_add +elm_hoversel_horizontal_set +elm_hoversel_horizontal_get +elm_hoversel_hover_parent_set +elm_hoversel_hover_parent_get +elm_hoversel_expanded_get +elm_hoversel_items_get +elm_hoversel_hover_begin +elm_hoversel_clear +elm_hoversel_hover_end +elm_hoversel_item_add +elm_hoversel_item_icon_set +elm_hoversel_item_icon_get +elm_icon_add +elm_icon_order_lookup_get +elm_icon_order_lookup_set +elm_icon_standard_get +elm_icon_standard_set +elm_icon_thumb_set +elm_image_add +elm_image_animated_available_get +elm_image_animated_get +elm_image_animated_play_get +elm_image_animated_play_set +elm_image_animated_set +elm_image_aspect_fixed_get +elm_image_aspect_fixed_set +elm_image_editable_get +elm_image_editable_set +elm_image_file_get +elm_image_file_set +elm_image_fill_outside_get +elm_image_fill_outside_set +elm_image_memfile_set +elm_image_no_scale_get +elm_image_no_scale_set +elm_image_object_get +elm_image_object_size_get +elm_image_orient_get +elm_image_orient_set +elm_image_preload_disabled_set +elm_image_prescale_get +elm_image_prescale_set +elm_image_resizable_get +elm_image_resizable_set +elm_image_smooth_get +elm_image_smooth_set +elm_index_add +elm_index_autohide_disabled_get +elm_index_autohide_disabled_set +elm_index_delay_change_time_get +elm_index_delay_change_time_set +elm_index_horizontal_get +elm_index_horizontal_set +elm_index_indicator_disabled_get +elm_index_indicator_disabled_set +elm_index_item_append +elm_index_item_clear +elm_index_item_find +elm_index_item_insert_after +elm_index_item_insert_before +elm_index_item_letter_get +elm_index_item_level_get +elm_index_item_level_set +elm_index_item_prepend +elm_index_item_selected_set +elm_index_item_sorted_insert +elm_index_level_go +elm_index_omit_enabled_get +elm_index_omit_enabled_set +elm_index_selected_item_get +elm_label_add +elm_label_ellipsis_get +elm_label_ellipsis_set +elm_label_line_wrap_get +elm_label_line_wrap_set +elm_label_slide_duration_get +elm_label_slide_duration_set +elm_label_slide_go +elm_label_slide_mode_get +elm_label_slide_mode_set +elm_label_wrap_width_get +elm_label_wrap_width_set +elm_layout_add +elm_layout_box_append +elm_layout_box_insert_at +elm_layout_box_insert_before +elm_layout_box_prepend +elm_layout_box_remove +elm_layout_box_remove_all +elm_layout_content_get +elm_layout_content_set +elm_layout_content_unset +elm_layout_data_get +elm_layout_edje_get +elm_layout_edje_object_can_access_get +elm_layout_edje_object_can_access_set +elm_layout_file_set +elm_layout_freeze +elm_layout_part_cursor_engine_only_get +elm_layout_part_cursor_engine_only_set +elm_layout_part_cursor_get +elm_layout_part_cursor_set +elm_layout_part_cursor_style_get +elm_layout_part_cursor_style_set +elm_layout_part_cursor_unset +elm_layout_signal_callback_add +elm_layout_signal_callback_del +elm_layout_signal_emit +elm_layout_sizing_eval +elm_layout_table_clear +elm_layout_table_pack +elm_layout_table_unpack +elm_layout_text_get +elm_layout_text_set +elm_layout_thaw +elm_layout_theme_set +elm_list_add +elm_list_at_xy_item_get +elm_list_clear +elm_list_first_item_get +elm_list_go +elm_list_horizontal_get +elm_list_horizontal_set +elm_list_item_append +elm_list_item_bring_in +elm_list_item_insert_after +elm_list_item_insert_before +elm_list_item_next +elm_list_item_object_get +elm_list_item_prepend +elm_list_item_prev +elm_list_item_selected_get +elm_list_item_selected_set +elm_list_item_separator_get +elm_list_item_separator_set +elm_list_item_show +elm_list_item_sorted_insert +elm_list_items_get +elm_list_last_item_get +elm_list_mode_get +elm_list_mode_set +elm_list_multi_select_get +elm_list_multi_select_set +elm_list_select_mode_get +elm_list_select_mode_set +elm_list_selected_item_get +elm_list_selected_items_get +elm_map_add +elm_map_canvas_to_region_convert +elm_map_name_add +elm_map_name_address_get +elm_map_name_del +elm_map_name_region_get +elm_map_name_search +elm_map_overlay_add +elm_map_overlay_bubble_add +elm_map_overlay_bubble_content_append +elm_map_overlay_bubble_content_clear +elm_map_overlay_bubble_follow +elm_map_overlay_circle_add +elm_map_overlay_class_add +elm_map_overlay_class_append +elm_map_overlay_class_remove +elm_map_overlay_class_zoom_max_get +elm_map_overlay_class_zoom_max_set +elm_map_overlay_color_get +elm_map_overlay_color_set +elm_map_overlay_content_get +elm_map_overlay_content_set +elm_map_overlay_data_get +elm_map_overlay_data_set +elm_map_overlay_del +elm_map_overlay_del_cb_set +elm_map_overlay_displayed_zoom_min_get +elm_map_overlay_displayed_zoom_min_set +elm_map_overlay_get_cb_set +elm_map_overlay_group_members_get +elm_map_overlay_hide_get +elm_map_overlay_hide_set +elm_map_overlay_icon_get +elm_map_overlay_icon_set +elm_map_overlay_line_add +elm_map_overlay_paused_get +elm_map_overlay_paused_set +elm_map_overlay_polygon_add +elm_map_overlay_polygon_region_add +elm_map_overlay_region_get +elm_map_overlay_region_set +elm_map_overlay_route_add +elm_map_overlay_scale_add +elm_map_overlay_show +elm_map_overlay_type_get +elm_map_overlay_visible_get +elm_map_overlays_get +elm_map_overlays_show +elm_map_paused_get +elm_map_paused_set +elm_map_region_bring_in +elm_map_region_get +elm_map_region_show +elm_map_region_to_canvas_convert +elm_map_rotate_get +elm_map_rotate_set +elm_map_route_add +elm_map_route_del +elm_map_route_distance_get +elm_map_route_node_get +elm_map_route_waypoint_get +elm_map_source_get +elm_map_source_set +elm_map_sources_get +elm_map_tile_load_status_get +elm_map_track_add +elm_map_track_remove +elm_map_user_agent_get +elm_map_user_agent_set +elm_map_wheel_disabled_get +elm_map_wheel_disabled_set +elm_map_zoom_get +elm_map_zoom_max_get +elm_map_zoom_max_set +elm_map_zoom_min_get +elm_map_zoom_min_set +elm_map_zoom_mode_get +elm_map_zoom_mode_set +elm_map_zoom_set +elm_mapbuf_add +elm_mapbuf_alpha_get +elm_mapbuf_alpha_set +elm_mapbuf_enabled_get +elm_mapbuf_enabled_set +elm_mapbuf_point_color_set +elm_mapbuf_point_color_get +elm_mapbuf_smooth_get +elm_mapbuf_smooth_set +elm_multibuttonentry_add +elm_multibuttonentry_clear +elm_multibuttonentry_editable_get +elm_multibuttonentry_editable_set +elm_multibuttonentry_entry_get +elm_multibuttonentry_expanded_get +elm_multibuttonentry_expanded_set +elm_multibuttonentry_first_item_get +elm_multibuttonentry_item_append +elm_multibuttonentry_item_filter_append +elm_multibuttonentry_item_filter_prepend +elm_multibuttonentry_item_filter_remove +elm_multibuttonentry_item_insert_after +elm_multibuttonentry_item_insert_before +elm_multibuttonentry_item_next_get +elm_multibuttonentry_item_prepend +elm_multibuttonentry_item_prev_get +elm_multibuttonentry_item_selected_get +elm_multibuttonentry_item_selected_set +elm_multibuttonentry_items_get +elm_multibuttonentry_last_item_get +elm_multibuttonentry_selected_item_get +elm_naviframe_add +elm_naviframe_bottom_item_get +elm_naviframe_content_preserve_on_pop_get +elm_naviframe_content_preserve_on_pop_set +elm_naviframe_event_enabled_get +elm_naviframe_event_enabled_set +elm_naviframe_item_insert_after +elm_naviframe_item_insert_before +elm_naviframe_item_pop +elm_naviframe_item_pop_cb_set +elm_naviframe_item_pop_to +elm_naviframe_item_promote +elm_naviframe_item_push +elm_naviframe_item_simple_push +elm_naviframe_item_simple_promote +elm_naviframe_item_style_get +elm_naviframe_item_style_set +elm_naviframe_item_title_enabled_get +elm_naviframe_item_title_enabled_set +elm_naviframe_items_get +elm_naviframe_prev_btn_auto_pushed_get +elm_naviframe_prev_btn_auto_pushed_set +elm_naviframe_top_item_get +elm_notify_add +elm_notify_align_get +elm_notify_align_set +elm_notify_allow_events_get +elm_notify_allow_events_set +elm_notify_dismiss +elm_notify_parent_get +elm_notify_parent_set +elm_notify_timeout_get +elm_notify_timeout_set +elm_object_access_info_set +elm_object_content_get +elm_object_content_set +elm_object_cursor_get +elm_object_cursor_set +elm_object_cursor_style_get +elm_object_cursor_style_set +elm_object_cursor_theme_search_enabled_get +elm_object_cursor_theme_search_enabled_set +elm_object_cursor_unset +elm_object_disabled_get +elm_object_disabled_set +elm_object_domain_part_text_translatable_set +elm_object_domain_translatable_part_text_set +elm_object_event_callback_add +elm_object_event_callback_del +elm_object_focus_allow_get +elm_object_focus_allow_set +elm_object_focus_custom_chain_append +elm_object_focus_custom_chain_get +elm_object_focus_custom_chain_prepend +elm_object_focus_custom_chain_set +elm_object_focus_custom_chain_unset +elm_object_focus_get +elm_object_focus_next +elm_object_focus_next_object_get +elm_object_focus_next_object_set +elm_object_focus_set +elm_object_focused_object_get +elm_object_mirrored_automatic_get +elm_object_mirrored_automatic_set +elm_object_mirrored_get +elm_object_mirrored_set +elm_object_name_find +elm_object_orientation_mode_disabled_get +elm_object_orientation_mode_disabled_set +elm_object_parent_widget_get +elm_object_part_content_get +elm_object_part_content_set +elm_object_part_content_unset +elm_object_part_text_get +elm_object_part_text_set +elm_object_scale_get +elm_object_scale_set +elm_object_scroll_freeze_get +elm_object_scroll_freeze_pop +elm_object_scroll_freeze_push +elm_object_scroll_hold_get +elm_object_scroll_hold_pop +elm_object_scroll_hold_push +elm_object_scroll_lock_x_get +elm_object_scroll_lock_x_set +elm_object_scroll_lock_y_get +elm_object_scroll_lock_y_set +elm_object_signal_callback_add +elm_object_signal_callback_del +elm_object_signal_emit +elm_object_style_get +elm_object_style_set +elm_object_text_get +elm_object_text_set +elm_object_theme_get +elm_object_theme_set +elm_object_tooltip_content_cb_set +elm_object_tooltip_hide +elm_object_tooltip_show +elm_object_tooltip_style_get +elm_object_tooltip_style_set +elm_object_tooltip_text_set +elm_object_tooltip_unset +elm_object_tooltip_window_mode_get +elm_object_tooltip_window_mode_set +elm_object_top_widget_get +elm_object_translatable_part_text_get +elm_object_tree_dot_dump +elm_object_tree_dump +elm_object_tree_focus_allow_get +elm_object_tree_focus_allow_set +elm_object_widget_check +elm_object_widget_type_get +elm_object_item_access_info_set +elm_object_item_access_object_get +elm_object_item_access_order_get +elm_object_item_access_order_set +elm_object_item_access_order_unset +elm_object_item_access_register +elm_object_item_access_unregister +elm_object_item_content_get +elm_object_item_content_set +elm_object_item_cursor_engine_only_get +elm_object_item_cursor_engine_only_set +elm_object_item_cursor_get +elm_object_item_cursor_set +elm_object_item_cursor_style_get +elm_object_item_cursor_style_set +elm_object_item_cursor_unset +elm_object_item_data_get +elm_object_item_data_set +elm_object_item_del +elm_object_item_del_cb_set +elm_object_item_disabled_get +elm_object_item_disabled_set +elm_object_item_domain_part_text_translatable_set +elm_object_item_domain_translatable_part_text_set +elm_object_item_part_content_get +elm_object_item_part_content_set +elm_object_item_part_content_unset +elm_object_item_part_text_get +elm_object_item_part_text_set +elm_object_item_signal_callback_add +elm_object_item_signal_callback_del +elm_object_item_signal_emit +elm_object_item_style_get +elm_object_item_style_set +elm_object_item_text_get +elm_object_item_text_set +elm_object_item_tooltip_content_cb_set +elm_object_item_tooltip_style_get +elm_object_item_tooltip_style_set +elm_object_item_tooltip_text_set +elm_object_item_tooltip_unset +elm_object_item_tooltip_window_mode_get +elm_object_item_tooltip_window_mode_set +elm_object_item_track +elm_object_item_track_get +elm_object_item_translatable_part_text_get +elm_object_item_untrack +elm_object_item_widget_get +elm_panel_add +elm_panel_hidden_get +elm_panel_hidden_set +elm_panel_orient_get +elm_panel_orient_set +elm_panel_scrollable_set +elm_panel_toggle +elm_panes_add +elm_panes_content_left_size_get +elm_panes_content_left_size_set +elm_panes_content_right_size_get +elm_panes_content_right_size_set +elm_panes_fixed_get +elm_panes_fixed_set +elm_panes_horizontal_get +elm_panes_horizontal_set +elm_photocam_add +elm_photocam_file_get +elm_photocam_file_set +elm_photocam_gesture_enabled_get +elm_photocam_gesture_enabled_set +elm_photocam_image_region_bring_in +elm_photocam_image_region_get +elm_photocam_image_region_show +elm_photocam_image_size_get +elm_photocam_internal_image_get +elm_photocam_paused_get +elm_photocam_paused_set +elm_photocam_zoom_get +elm_photocam_zoom_mode_get +elm_photocam_zoom_mode_set +elm_photocam_zoom_set +elm_plug_add +elm_plug_connect +elm_plug_image_object_get +elm_popup_add +elm_popup_align_get +elm_popup_align_set +elm_popup_allow_events_get +elm_popup_allow_events_set +elm_popup_content_text_wrap_type_get +elm_popup_content_text_wrap_type_set +elm_popup_dismiss +elm_popup_item_append +elm_popup_orient_get +elm_popup_orient_set +elm_popup_timeout_get +elm_popup_timeout_set +elm_progressbar_add +elm_progressbar_horizontal_get +elm_progressbar_horizontal_set +elm_progressbar_inverted_get +elm_progressbar_inverted_set +elm_progressbar_pulse +elm_progressbar_pulse_get +elm_progressbar_pulse_set +elm_progressbar_span_size_get +elm_progressbar_span_size_set +elm_progressbar_unit_format_function_set +elm_progressbar_unit_format_get +elm_progressbar_unit_format_set +elm_progressbar_value_get +elm_progressbar_value_set +elm_radio_add +elm_radio_group_add +elm_radio_selected_object_get +elm_radio_state_value_get +elm_radio_state_value_set +elm_radio_value_get +elm_radio_value_pointer_set +elm_radio_value_set +elm_scroller_add +elm_scroller_bounce_get +elm_scroller_bounce_set +elm_scroller_child_size_get +elm_scroller_content_min_limit +elm_scroller_current_page_get +elm_scroller_gravity_get +elm_scroller_gravity_set +elm_scroller_last_page_get +elm_scroller_loop_set +elm_scroller_movement_block_get +elm_scroller_movement_block_set +elm_scroller_page_bring_in +elm_scroller_page_relative_get +elm_scroller_page_relative_set +elm_scroller_page_scroll_limit_get +elm_scroller_page_scroll_limit_set +elm_scroller_page_show +elm_scroller_page_size_get +elm_scroller_page_size_set +elm_scroller_policy_get +elm_scroller_policy_set +elm_scroller_propagate_events_get +elm_scroller_propagate_events_set +elm_scroller_region_bring_in +elm_scroller_region_get +elm_scroller_region_show +elm_scroller_single_direction_get +elm_scroller_single_direction_set +elm_segment_control_add +elm_segment_control_item_add +elm_segment_control_item_count_get +elm_segment_control_item_del_at +elm_segment_control_item_get +elm_segment_control_item_icon_get +elm_segment_control_item_index_get +elm_segment_control_item_insert_at +elm_segment_control_item_label_get +elm_segment_control_item_object_get +elm_segment_control_item_selected_get +elm_segment_control_item_selected_set +elm_slider_add +elm_slider_horizontal_get +elm_slider_horizontal_set +elm_slider_indicator_format_function_set +elm_slider_indicator_format_get +elm_slider_indicator_format_set +elm_slider_indicator_show_get +elm_slider_indicator_show_set +elm_slider_inverted_get +elm_slider_inverted_set +elm_slider_min_max_get +elm_slider_min_max_set +elm_slider_span_size_get +elm_slider_span_size_set +elm_slider_step_get +elm_slider_step_set +elm_slider_unit_format_get +elm_slider_unit_format_set +elm_slider_units_format_function_set +elm_slider_value_get +elm_slider_value_set +elm_slider_indicator_visible_mode_set +elm_slider_indicator_visible_mode_get +elm_spinner_add +elm_spinner_base_get +elm_spinner_base_set +elm_spinner_editable_get +elm_spinner_editable_set +elm_spinner_interval_get +elm_spinner_interval_set +elm_spinner_label_format_get +elm_spinner_label_format_set +elm_spinner_min_max_get +elm_spinner_min_max_set +elm_spinner_round_get +elm_spinner_round_set +elm_spinner_special_value_add +elm_spinner_special_value_del +elm_spinner_special_value_get +elm_spinner_step_get +elm_spinner_step_set +elm_spinner_value_get +elm_spinner_value_set +elm_spinner_wrap_get +elm_spinner_wrap_set +elm_table_add +elm_table_clear +elm_table_homogeneous_get +elm_table_homogeneous_set +elm_table_pack +elm_table_pack_get +elm_table_pack_set +elm_table_padding_get +elm_table_padding_set +elm_table_unpack +elm_theme_copy +elm_theme_data_get +elm_theme_default_get +elm_theme_extension_add +elm_theme_extension_del +elm_theme_extension_list_get +elm_theme_flush +elm_theme_free +elm_theme_full_flush +elm_theme_get +elm_theme_list_get +elm_theme_list_item_path_get +elm_theme_name_available_list_free +elm_theme_name_available_list_new +elm_theme_new +elm_theme_overlay_add +elm_theme_overlay_del +elm_theme_overlay_list_get +elm_theme_ref_get +elm_theme_ref_set +elm_theme_set +elm_toolbar_add +elm_toolbar_align_get +elm_toolbar_align_set +elm_toolbar_first_item_get +elm_toolbar_homogeneous_get +elm_toolbar_homogeneous_set +elm_toolbar_horizontal_get +elm_toolbar_horizontal_set +elm_toolbar_icon_order_lookup_get +elm_toolbar_icon_order_lookup_set +elm_toolbar_icon_size_get +elm_toolbar_icon_size_set +elm_toolbar_item_append +elm_toolbar_item_bring_in +elm_toolbar_item_find_by_label +elm_toolbar_item_icon_file_set +elm_toolbar_item_icon_get +elm_toolbar_item_icon_memfile_set +elm_toolbar_item_icon_object_get +elm_toolbar_item_icon_set +elm_toolbar_item_insert_after +elm_toolbar_item_insert_before +elm_toolbar_item_next_get +elm_toolbar_item_object_get +elm_toolbar_item_prepend +elm_toolbar_item_prev_get +elm_toolbar_item_priority_get +elm_toolbar_item_priority_set +elm_toolbar_item_selected_get +elm_toolbar_item_selected_set +elm_toolbar_item_separator_get +elm_toolbar_item_separator_set +elm_toolbar_item_show +elm_toolbar_item_state_add +elm_toolbar_item_state_del +elm_toolbar_item_state_get +elm_toolbar_item_state_next +elm_toolbar_item_state_prev +elm_toolbar_item_state_set +elm_toolbar_item_state_unset +elm_toolbar_items_count +elm_toolbar_last_item_get +elm_toolbar_menu_parent_get +elm_toolbar_menu_parent_set +elm_toolbar_more_item_get +elm_toolbar_reorder_mode_get +elm_toolbar_reorder_mode_set +elm_toolbar_select_mode_get +elm_toolbar_select_mode_set +elm_toolbar_selected_item_get +elm_toolbar_shrink_mode_get +elm_toolbar_shrink_mode_set +elm_toolbar_standard_priority_get +elm_toolbar_standard_priority_set +elm_toolbar_transverse_expanded_get +elm_toolbar_transverse_expanded_set +elm_transit_add +elm_transit_auto_reverse_get +elm_transit_auto_reverse_set +elm_transit_chain_transit_add +elm_transit_chain_transit_del +elm_transit_chain_transits_get +elm_transit_del +elm_transit_del_cb_set +elm_transit_duration_get +elm_transit_duration_set +elm_transit_effect_add +elm_transit_effect_blend_add +elm_transit_effect_color_add +elm_transit_effect_del +elm_transit_effect_fade_add +elm_transit_effect_flip_add +elm_transit_effect_image_animation_add +elm_transit_effect_resizable_flip_add +elm_transit_effect_resizing_add +elm_transit_effect_rotation_add +elm_transit_effect_translation_add +elm_transit_effect_wipe_add +elm_transit_effect_zoom_add +elm_transit_event_enabled_get +elm_transit_event_enabled_set +elm_transit_go +elm_transit_object_add +elm_transit_object_remove +elm_transit_objects_final_state_keep_get +elm_transit_objects_final_state_keep_set +elm_transit_objects_get +elm_transit_paused_get +elm_transit_paused_set +elm_transit_progress_value_get +elm_transit_repeat_times_get +elm_transit_repeat_times_set +elm_transit_smooth_get +elm_transit_smooth_set +elm_transit_tween_mode_factor_get +elm_transit_tween_mode_factor_n_set +elm_transit_tween_mode_factor_set +elm_transit_tween_mode_get +elm_transit_tween_mode_set +elm_win_activate +elm_win_add +elm_win_alpha_get +elm_win_alpha_set +elm_win_aspect_get +elm_win_aspect_set +elm_win_autodel_get +elm_win_autodel_set +elm_win_borderless_get +elm_win_borderless_set +elm_win_conformant_get +elm_win_conformant_set +elm_win_demand_attention_get +elm_win_demand_attention_set +elm_win_floating_mode_get +elm_win_floating_mode_set +elm_win_focus_get +elm_win_focus_highlight_enabled_get +elm_win_focus_highlight_enabled_set +elm_win_focus_highlight_style_get +elm_win_focus_highlight_style_set +elm_win_icon_name_get +elm_win_icon_name_set +elm_win_icon_object_get +elm_win_icon_object_set +elm_win_iconified_get +elm_win_iconified_set +elm_win_illume_command_send +elm_win_indicator_mode_get +elm_win_indicator_mode_set +elm_win_indicator_opacity_get +elm_win_indicator_opacity_set +elm_win_inlined_image_object_get +elm_win_inwin_activate +elm_win_inwin_add +elm_win_inwin_content_get +elm_win_inwin_content_set +elm_win_inwin_content_unset +elm_win_keyboard_mode_get +elm_win_keyboard_mode_set +elm_win_layer_get +elm_win_layer_set +elm_win_lower +elm_win_maximized_get +elm_win_maximized_set +elm_win_modal_get +elm_win_modal_set +elm_win_norender_get +elm_win_norender_pop +elm_win_norender_push +elm_win_profile_get +elm_win_profile_set +elm_win_prop_focus_skip_set +elm_win_raise +elm_win_render +elm_win_resize_object_add +elm_win_resize_object_del +elm_win_role_get +elm_win_role_set +elm_win_rotation_get +elm_win_rotation_set +elm_win_rotation_with_resize_set +elm_win_screen_constrain_get +elm_win_screen_constrain_set +elm_win_screen_dpi_get +elm_win_screen_position_get +elm_win_screen_size_get +elm_win_size_base_get +elm_win_size_base_set +elm_win_size_step_get +elm_win_size_step_set +elm_win_socket_listen +elm_win_title_get +elm_win_title_set +elm_win_trap_set +elm_win_type_get +elm_win_urgent_get +elm_win_urgent_set +elm_win_util_standard_add +elm_win_withdrawn_get +elm_win_withdrawn_set +elm_win_wm_rotation_available_rotations_get +elm_win_wm_rotation_available_rotations_set +elm_win_wm_rotation_manual_rotation_done +elm_win_wm_rotation_manual_rotation_done_get +elm_win_wm_rotation_manual_rotation_done_set +elm_win_wm_rotation_preferred_rotation_get +elm_win_wm_rotation_preferred_rotation_set +elm_win_wm_rotation_supported_get +elm_win_window_id_get +elm_exit +elm_init +elm_language_set +elm_policy_get +elm_policy_set +elm_run +elm_shutdown +evas_color_argb_premul +evas_color_argb_unpremul +evas_color_hsv_to_rgb +evas_color_rgb_to_hsv +evas_coord_screen_x_to_world +evas_coord_screen_y_to_world +evas_coord_world_x_to_screen +evas_coord_world_y_to_screen +evas_damage_rectangle_add +evas_data_argb_premul +evas_data_argb_unpremul +evas_data_attach_get +evas_data_attach_set +evas_engine_info_get +evas_engine_info_set +evas_event_callback_add +evas_event_callback_del +evas_event_callback_del_full +evas_event_callback_priority_add +evas_event_default_flags_get +evas_event_default_flags_set +evas_event_freeze +evas_event_freeze_get +evas_event_thaw +evas_event_thaw_eval +evas_focus_in +evas_focus_out +evas_focus_state_get +evas_free +evas_gl_api_get +evas_gl_config_free +evas_gl_config_new +evas_gl_context_api_get +evas_gl_context_create +evas_gl_context_destroy +evas_gl_context_version_create +evas_gl_current_context_get +evas_gl_current_surface_get +evas_gl_error_get +evas_gl_free +evas_gl_make_current +evas_gl_native_surface_get +evas_gl_new +evas_gl_pbuffer_surface_create +evas_gl_proc_address_get +evas_gl_rotation_get +evas_gl_string_query +evas_gl_surface_create +evas_gl_surface_destroy +evas_gl_surface_query +evas_key_lock_add +evas_key_lock_del +evas_key_lock_get +evas_key_lock_is_set +evas_key_lock_off +evas_key_lock_on +evas_key_modifier_add +evas_key_modifier_del +evas_key_modifier_get +evas_key_modifier_is_set +evas_key_modifier_mask_get +evas_key_modifier_off +evas_key_modifier_on +evas_load_error_str +evas_map_alpha_get +evas_map_alpha_set +evas_map_count_get +evas_map_dup +evas_map_free +evas_map_new +evas_map_point_color_get +evas_map_point_color_set +evas_map_point_coord_get +evas_map_point_coord_set +evas_map_point_image_uv_get +evas_map_point_image_uv_set +evas_map_smooth_get +evas_map_smooth_set +evas_map_util_3d_lighting +evas_map_util_3d_perspective +evas_map_util_3d_rotate +evas_map_util_clockwise_get +evas_map_util_points_color_set +evas_map_util_points_populate_from_geometry +evas_map_util_points_populate_from_object +evas_map_util_points_populate_from_object_full +evas_map_util_quat_rotate +evas_map_util_rotate +evas_map_util_zoom +evas_new +evas_nochange_pop +evas_nochange_push +evas_norender +evas_object_above_get +evas_object_anti_alias_get +evas_object_anti_alias_set +evas_object_below_get +evas_object_box_accessor_new +evas_object_box_add +evas_object_box_add_to +evas_object_box_align_get +evas_object_box_align_set +evas_object_box_append +evas_object_box_children_get +evas_object_box_insert_after +evas_object_box_insert_at +evas_object_box_insert_before +evas_object_box_iterator_new +evas_object_box_layout_flow_horizontal +evas_object_box_layout_flow_vertical +evas_object_box_layout_homogeneous_horizontal +evas_object_box_layout_homogeneous_max_size_horizontal +evas_object_box_layout_homogeneous_max_size_vertical +evas_object_box_layout_homogeneous_vertical +evas_object_box_layout_horizontal +evas_object_box_layout_set +evas_object_box_layout_stack +evas_object_box_layout_vertical +evas_object_box_option_property_get +evas_object_box_option_property_id_get +evas_object_box_option_property_name_get +evas_object_box_option_property_set +evas_object_box_option_property_vget +evas_object_box_option_property_vset +evas_object_box_padding_get +evas_object_box_padding_set +evas_object_box_prepend +evas_object_box_remove +evas_object_box_remove_all +evas_object_box_remove_at +evas_object_box_smart_class_get +evas_object_box_smart_set +evas_object_clip_get +evas_object_clip_set +evas_object_clip_unset +evas_object_clipees_get +evas_object_color_get +evas_object_color_set +evas_object_data_del +evas_object_data_get +evas_object_data_set +evas_object_del +evas_object_evas_get +evas_object_event_callback_add +evas_object_event_callback_del +evas_object_event_callback_del_full +evas_object_event_callback_priority_add +evas_object_focus_get +evas_object_focus_set +evas_object_freeze_events_get +evas_object_freeze_events_set +evas_object_geometry_get +evas_object_grid_accessor_new +evas_object_grid_add +evas_object_grid_add_to +evas_object_grid_children_get +evas_object_grid_clear +evas_object_grid_iterator_new +evas_object_grid_mirrored_get +evas_object_grid_mirrored_set +evas_object_grid_pack +evas_object_grid_pack_get +evas_object_grid_size_get +evas_object_grid_size_set +evas_object_grid_unpack +evas_object_hide +evas_object_image_add +evas_object_image_alpha_get +evas_object_image_alpha_mask_set +evas_object_image_alpha_set +evas_object_image_animated_frame_count_get +evas_object_image_animated_frame_duration_get +evas_object_image_animated_frame_set +evas_object_image_animated_get +evas_object_image_animated_loop_count_get +evas_object_image_animated_loop_type_get +evas_object_image_border_center_fill_get +evas_object_image_border_center_fill_set +evas_object_image_border_get +evas_object_image_border_scale_get +evas_object_image_border_scale_set +evas_object_image_border_set +evas_object_image_colorspace_get +evas_object_image_colorspace_set +evas_object_image_content_hint_get +evas_object_image_content_hint_set +evas_object_image_data_convert +evas_object_image_data_copy_set +evas_object_image_data_get +evas_object_image_data_set +evas_object_image_data_update_add +evas_object_image_extension_can_load_fast_get +evas_object_image_extension_can_load_get +evas_object_image_file_get +evas_object_image_file_set +evas_object_image_fill_get +evas_object_image_fill_set +evas_object_image_fill_spread_get +evas_object_image_fill_spread_set +evas_object_image_filled_add +evas_object_image_filled_get +evas_object_image_filled_set +evas_object_image_load_dpi_get +evas_object_image_load_dpi_set +evas_object_image_load_error_get +evas_object_image_load_orientation_get +evas_object_image_load_orientation_set +evas_object_image_load_region_get +evas_object_image_load_region_set +evas_object_image_load_scale_down_get +evas_object_image_load_scale_down_set +evas_object_image_load_size_get +evas_object_image_load_size_set +evas_object_image_memfile_set +evas_object_image_native_surface_get +evas_object_image_native_surface_set +evas_object_image_pixels_dirty_get +evas_object_image_pixels_dirty_set +evas_object_image_pixels_get_callback_set +evas_object_image_pixels_import +evas_object_image_preload +evas_object_image_region_support_get +evas_object_image_reload +evas_object_image_save +evas_object_image_scale_hint_get +evas_object_image_scale_hint_set +evas_object_image_size_get +evas_object_image_size_set +evas_object_image_smooth_scale_get +evas_object_image_smooth_scale_set +evas_object_image_source_clip_get +evas_object_image_source_clip_set +evas_object_image_source_get +evas_object_image_source_set +evas_object_image_source_unset +evas_object_image_source_visible_get +evas_object_image_source_visible_set +evas_object_image_stride_get +evas_object_image_video_surface_get +evas_object_image_video_surface_set +evas_object_key_grab +evas_object_key_ungrab +evas_object_layer_get +evas_object_layer_set +evas_object_line_add +evas_object_line_xy_get +evas_object_line_xy_set +evas_object_lower +evas_object_map_enable_get +evas_object_map_enable_set +evas_object_map_get +evas_object_map_set +evas_object_move +evas_object_name_get +evas_object_name_set +evas_object_pass_events_get +evas_object_pass_events_set +evas_object_pointer_mode_get +evas_object_pointer_mode_set +evas_object_polygon_add +evas_object_polygon_point_add +evas_object_polygon_points_clear +evas_object_precise_is_inside_get +evas_object_precise_is_inside_set +evas_object_propagate_events_get +evas_object_propagate_events_set +evas_object_raise +evas_object_rectangle_add +evas_object_ref +evas_object_ref_get +evas_object_render_op_get +evas_object_render_op_set +evas_object_repeat_events_get +evas_object_repeat_events_set +evas_object_resize +evas_object_scale_get +evas_object_scale_set +evas_object_show +evas_object_size_hint_expand_get +evas_object_size_hint_expand_set +evas_object_size_hint_align_get +evas_object_size_hint_align_set +evas_object_size_hint_aspect_get +evas_object_size_hint_aspect_set +evas_object_size_hint_display_mode_get +evas_object_size_hint_display_mode_set +evas_object_size_hint_fill_get +evas_object_size_hint_fill_set +evas_object_size_hint_max_get +evas_object_size_hint_max_set +evas_object_size_hint_min_get +evas_object_size_hint_min_set +evas_object_size_hint_padding_get +evas_object_size_hint_padding_set +evas_object_size_hint_weight_get +evas_object_size_hint_weight_set +evas_object_smart_add +evas_object_smart_callback_add +evas_object_smart_callback_call +evas_object_smart_callback_del +evas_object_smart_callback_del_full +evas_object_smart_callbacks_descriptions_get +evas_object_smart_callbacks_descriptions_set +evas_object_smart_changed +evas_object_smart_data_get +evas_object_smart_data_set +evas_object_smart_member_add +evas_object_smart_member_del +evas_object_smart_members_get +evas_object_smart_parent_get +evas_object_smart_type_check +evas_object_stack_above +evas_object_stack_below +evas_object_static_clip_get +evas_object_static_clip_set +evas_object_table_accessor_new +evas_object_table_add +evas_object_table_add_to +evas_object_table_align_get +evas_object_table_align_set +evas_object_table_child_get +evas_object_table_children_get +evas_object_table_clear +evas_object_table_col_row_size_get +evas_object_table_homogeneous_get +evas_object_table_homogeneous_set +evas_object_table_iterator_new +evas_object_table_mirrored_get +evas_object_table_mirrored_set +evas_object_table_pack +evas_object_table_pack_get +evas_object_table_padding_get +evas_object_table_padding_set +evas_object_table_unpack +evas_object_text_add +evas_object_text_bidi_delimiters_get +evas_object_text_bidi_delimiters_set +evas_object_text_char_pos_get +evas_object_text_direction_get +evas_object_text_ellipsis_get +evas_object_text_ellipsis_set +evas_object_text_font_get +evas_object_text_font_set +evas_object_text_font_source_get +evas_object_text_font_source_set +evas_object_text_glow_color_get +evas_object_text_glow_color_set +evas_object_text_glow2_color_get +evas_object_text_glow2_color_set +evas_object_text_last_up_to_pos +evas_object_text_outline_color_get +evas_object_text_outline_color_set +evas_object_text_shadow_color_get +evas_object_text_shadow_color_set +evas_object_text_style_get +evas_object_text_style_pad_get +evas_object_text_style_set +evas_object_text_text_get +evas_object_text_text_set +evas_object_textblock_add +evas_object_textblock_bidi_delimiters_get +evas_object_textblock_bidi_delimiters_set +evas_object_textblock_clear +evas_object_textblock_cursor_get +evas_object_textblock_cursor_new +evas_object_textblock_legacy_newline_get +evas_object_textblock_legacy_newline_set +evas_object_textblock_line_number_geometry_get +evas_object_textblock_replace_char_get +evas_object_textblock_replace_char_set +evas_object_textblock_size_formatted_get +evas_object_textblock_size_native_get +evas_object_textblock_style_get +evas_object_textblock_style_set +evas_object_textblock_style_user_peek +evas_object_textblock_style_user_pop +evas_object_textblock_style_user_push +evas_object_textblock_text_markup_get +evas_object_textblock_text_markup_prepend +evas_object_textblock_text_markup_set +evas_object_textblock_valign_get +evas_object_textblock_valign_set +evas_object_type_get +evas_object_unref +evas_object_visible_get +evas_obscured_clear +evas_obscured_rectangle_add +evas_output_framespace_get +evas_output_framespace_set +evas_output_method_get +evas_output_method_set +evas_output_size_get +evas_output_size_set +evas_output_viewport_get +evas_output_viewport_set +evas_pointer_button_down_mask_get +evas_pointer_canvas_xy_get +evas_pointer_inside_get +evas_pointer_output_xy_get +evas_post_event_callback_push +evas_post_event_callback_remove +evas_post_event_callback_remove_full +evas_render +evas_render_dump +evas_render_idle_flush +evas_render_method_list +evas_render_method_list_free +evas_render_method_lookup +evas_render_updates +evas_render_updates_free +evas_smart_objects_calculate +evas_smart_objects_calculate_count_get +evas_string_char_len_get +evas_string_char_next_get +evas_string_char_prev_get +evas_textblock_cursor_at_format_set +evas_textblock_cursor_char_coord_set +evas_textblock_cursor_char_delete +evas_textblock_cursor_char_geometry_get +evas_textblock_cursor_char_next +evas_textblock_cursor_char_prev +evas_textblock_cursor_compare +evas_textblock_cursor_content_get +evas_textblock_cursor_copy +evas_textblock_cursor_eol_get +evas_textblock_cursor_format_append +evas_textblock_cursor_format_get +evas_textblock_cursor_format_is_visible_get +evas_textblock_cursor_format_next +evas_textblock_cursor_format_prepend +evas_textblock_cursor_format_prev +evas_textblock_cursor_free +evas_textblock_cursor_geometry_bidi_get +evas_textblock_cursor_geometry_get +evas_textblock_cursor_is_format +evas_textblock_cursor_line_char_first +evas_textblock_cursor_line_char_last +evas_textblock_cursor_line_coord_set +evas_textblock_cursor_line_geometry_get +evas_textblock_cursor_line_set +evas_textblock_cursor_paragraph_char_first +evas_textblock_cursor_paragraph_char_last +evas_textblock_cursor_paragraph_first +evas_textblock_cursor_paragraph_last +evas_textblock_cursor_paragraph_next +evas_textblock_cursor_paragraph_prev +evas_textblock_cursor_paragraph_text_get +evas_textblock_cursor_paragraph_text_length_get +evas_textblock_cursor_pen_geometry_get +evas_textblock_cursor_pos_get +evas_textblock_cursor_pos_set +evas_textblock_cursor_range_delete +evas_textblock_cursor_range_formats_get +evas_textblock_cursor_range_geometry_get +evas_textblock_cursor_range_text_get +evas_textblock_cursor_text_append +evas_textblock_cursor_text_prepend +evas_textblock_cursor_visible_range_get +evas_textblock_cursor_word_end +evas_textblock_cursor_word_start +evas_textblock_escape_string_get +evas_textblock_escape_string_range_get +evas_textblock_node_format_first_get +evas_textblock_node_format_last_get +evas_textblock_node_format_list_get +evas_textblock_node_format_next_get +evas_textblock_node_format_prev_get +evas_textblock_node_format_remove_pair +evas_textblock_node_format_text_get +evas_textblock_string_escape_get +evas_textblock_style_free +evas_textblock_style_get +evas_textblock_style_new +evas_textblock_style_set +evas_textblock_text_markup_to_utf8 +evas_textblock_text_utf8_to_markup +audio_in_create +audio_in_destroy +audio_in_drop +audio_in_get_buffer_size +audio_in_get_channel +audio_in_get_sample_rate +audio_in_get_sample_type +audio_in_peek +audio_in_prepare +audio_in_read +audio_in_unprepare +audio_in_flush +audio_in_set_stream_cb +audio_in_unset_stream_cb +audio_in_set_sound_stream_info +audio_in_pause +audio_in_resume +audio_in_set_state_changed_cb +audio_in_unset_state_changed_cb +audio_out_create_new +audio_out_destroy +audio_out_get_buffer_size +audio_out_get_channel +audio_out_get_sample_rate +audio_out_get_sample_type +audio_out_get_sound_type +audio_out_prepare +audio_out_set_stream_cb +audio_out_unprepare +audio_out_unset_stream_cb +audio_out_write +audio_out_drain +audio_out_flush +audio_out_set_sound_stream_info +audio_out_pause +audio_out_resume +audio_out_set_state_changed_cb +audio_out_unset_state_changed_cb +ime_run +ime_event_set_focus_in_cb +ime_event_set_focus_out_cb +ime_event_set_surrounding_text_updated_cb +ime_event_set_input_context_reset_cb +ime_event_set_cursor_position_updated_cb +ime_event_set_language_requested_cb +ime_event_set_language_set_cb +ime_event_set_imdata_set_cb +ime_event_set_layout_set_cb +ime_event_set_return_key_type_set_cb +ime_event_set_return_key_state_set_cb +ime_event_set_geometry_requested_cb +ime_event_set_process_key_event_cb +ime_event_set_display_language_changed_cb +ime_event_set_rotation_degree_changed_cb +ime_event_set_accessibility_state_changed_cb +ime_event_set_option_window_created_cb +ime_event_set_option_window_destroyed_cb +ime_event_set_prediction_hint_set_cb +ime_event_set_mime_type_set_request_cb +ime_send_key_event +ime_send_private_command +ime_commit_content +ime_commit_string +ime_show_preedit_string +ime_hide_preedit_string +ime_update_preedit_string +ime_request_surrounding_text +ime_delete_surrounding_text +ime_get_main_window +ime_set_size +ime_create_option_window +ime_destroy_option_window +ime_context_get_layout +ime_context_get_layout_variation +ime_context_get_cursor_position +ime_context_get_autocapital_type +ime_context_get_return_key_type +ime_context_get_return_key_state +ime_context_get_prediction_mode +ime_context_get_password_mode +ime_context_get_input_hint +ime_context_get_bidi_direction +ime_context_get_language +ime_device_info_get_name +ime_device_info_get_class +ime_device_info_get_subclass +ime_event_set_imdata_requested_cb +ime_set_selection +ime_get_surrounding_text +ime_event_set_process_input_device_event_cb +ime_event_unset_process_input_device_event_cb +ime_input_device_rotary_get_direction +ime_set_floating_mode +ime_set_floating_drag_start +ime_set_floating_drag_end +ime_get_selected_text +ime_manager_show_ime_list +ime_manager_show_ime_selector +ime_manager_is_ime_enabled +ime_manager_get_active_ime +ime_manager_get_enabled_ime_count +i18n_ubrk_create +i18n_ubrk_create_rules +i18n_ubrk_safe_clone +i18n_ubrk_destroy +i18n_ubrk_set_text +i18n_ubrk_current +i18n_ubrk_next +i18n_ubrk_previous +i18n_ubrk_first +i18n_ubrk_last +i18n_ubrk_preceding +i18n_ubrk_following +i18n_ubrk_get_available +i18n_ubrk_count_available +i18n_ubrk_is_boundary +i18n_ubrk_get_rule_status +i18n_ubrk_get_rule_status_vec +i18n_ubrk_get_locale_by_type +i18n_ucalendar_add +i18n_ucalendar_create +i18n_ucalendar_destroy +i18n_ucalendar_get +i18n_ucalendar_get_milliseconds +i18n_ucalendar_get_now +i18n_ucalendar_get_timezone_displayname +i18n_ucalendar_is_equivalent_to +i18n_ucalendar_is_in_daylight_time +i18n_ucalendar_set_attribute +i18n_ucalendar_set_date_time +i18n_ucalendar_set_milliseconds +i18n_ucalendar_timezone_id_enumeration_create +i18n_ucalendar_timezones_create +i18n_ucalendar_country_timezones_create +i18n_ucalendar_get_default_timezone +i18n_ucalendar_set_timezone +i18n_ucalendar_get_timezone_id +i18n_ucalendar_set_gregorian_change +i18n_ucalendar_get_gregorian_change +i18n_ucalendar_get_available +i18n_ucalendar_count_available +i18n_ucalendar_set_date +i18n_ucalendar_roll +i18n_ucalendar_is_set +i18n_ucalendar_clear_field +i18n_ucalendar_clear +i18n_ucalendar_get_limit +i18n_ucalendar_get_locale_by_type +i18n_ucalendar_get_tz_data_version +i18n_ucalendar_get_canonical_timezone_id +i18n_ucalendar_get_type +i18n_ucalendar_get_keyword_values_for_locale +i18n_ucalendar_get_day_of_week_type +i18n_ucalendar_get_weekend_transition +i18n_ucalendar_is_weekend +i18n_ucalendar_get_field_difference +i18n_ucalendar_get_timezone_transition_date +i18n_uchar_get_int_property_value +i18n_uchar_get_ublock_code +i18n_uchar_iter_create +i18n_uchar_iter_destroy +i18n_uchar_iter_set_string +i18n_uchar_iter_set_utf16be +i18n_uchar_iter_set_utf8 +i18n_uchar_iter_get_index +i18n_uchar_iter_move +i18n_uchar_iter_has_next +i18n_uchar_iter_has_previous +i18n_uchar_iter_current +i18n_uchar_iter_next +i18n_uchar_iter_previous +i18n_uchar_iter_get_state +i18n_uchar_iter_set_state +i18n_uchar_has_binary_property +i18n_uchar_is_alphabetic +i18n_uchar_is_lowercase +i18n_uchar_is_uppercase +i18n_uchar_is_white_space +i18n_uchar_get_int_property_min_value +i18n_uchar_get_int_property_max_value +i18n_uchar_get_numeric_value +i18n_uchar_is_lower +i18n_uchar_is_upper +i18n_uchar_is_title +i18n_uchar_is_digit +i18n_uchar_is_alpha +i18n_uchar_is_alnum +i18n_uchar_is_xdigit +i18n_uchar_is_punct +i18n_uchar_is_graph +i18n_uchar_is_blank +i18n_uchar_is_defined +i18n_uchar_is_space +i18n_uchar_is_java_space_char +i18n_uchar_is_whitespace +i18n_uchar_is_control +i18n_uchar_is_iso_control +i18n_uchar_is_printable +i18n_uchar_is_base +i18n_uchar_char_direction +i18n_uchar_is_mirrored +i18n_uchar_char_mirror +i18n_uchar_get_bidi_paired_bracket +i18n_uchar_char_type +i18n_uchar_enum_char_types +i18n_uchar_get_combining_class +i18n_uchar_char_digit_value +i18n_uchar_char_name +i18n_uchar_char_from_name +i18n_uchar_enum_char_names +i18n_uchar_get_property_name +i18n_uchar_get_property_enum +i18n_uchar_get_property_value_name +i18n_uchar_get_property_value_enum +i18n_uchar_is_id_start +i18n_uchar_is_id_part +i18n_uchar_is_id_ignorable +i18n_uchar_is_java_id_start +i18n_uchar_is_java_id_part +i18n_uchar_to_lower +i18n_uchar_to_upper +i18n_uchar_to_title +i18n_uchar_fold_case +i18n_uchar_digit +i18n_uchar_for_digit +i18n_uchar_char_age +i18n_uchar_get_unicode_version +i18n_uchar_get_fc_nfkc_closure +i18n_ucollator_create +i18n_ucollator_destroy +i18n_ucollator_equal +i18n_ucollator_set_attribute +i18n_ucollator_set_strength +i18n_ucollator_str_collator +i18n_udate_create +i18n_udate_destroy +i18n_udate_format_date +i18n_udate_to_calendar_date_field +i18n_udate_clone +i18n_udate_parse +i18n_udate_parse_calendar +i18n_udate_is_lenient +i18n_udate_set_lenient +i18n_udate_get_calendar +i18n_udate_set_calendar +i18n_udate_get_number_format +i18n_udate_set_number_format +i18n_udate_get_available +i18n_udate_count_available +i18n_udate_get_2digit_year_start +i18n_udate_set_2digit_year_start +i18n_udate_to_pattern +i18n_udate_apply_pattern +i18n_udate_get_symbols +i18n_udate_count_symbols +i18n_udate_set_symbols +i18n_udate_get_locale_by_type +i18n_udate_set_context +i18n_udatepg_create +i18n_udatepg_destroy +i18n_udatepg_get_best_pattern +i18n_udatepg_set_decimal +i18n_udatepg_set_date_time_format +i18n_udatepg_set_append_item_name +i18n_udatepg_set_append_item_format +i18n_udatepg_replace_field_types_with_options +i18n_udatepg_replace_field_types +i18n_udatepg_get_skeleton +i18n_udatepg_get_best_pattern_with_options +i18n_udatepg_get_base_skeleton +i18n_udatepg_skeletons_create +i18n_udatepg_base_skeletons_create +i18n_udatepg_create_empty +i18n_udatepg_clone +i18n_udatepg_add_pattern +i18n_udatepg_get_pattern_for_skeleton +i18n_udatepg_get_decimal +i18n_udatepg_get_date_time_format +i18n_udatepg_get_append_item_name +i18n_udatepg_get_append_item_format +i18n_uenumeration_destroy +i18n_uenumeration_count +i18n_uenumeration_unext +i18n_uenumeration_next +i18n_uenumeration_reset +i18n_uenumeration_uchar_strings_enumeration_create +i18n_uenumeration_char_strings_enumeration_create +i18n_ulocale_get_default +i18n_ulocale_get_display_name +i18n_ulocale_get_language +i18n_ulocale_set_default +i18n_ulocale_get_available +i18n_ulocale_get_country +i18n_ulocale_count_available +i18n_ulocale_add_likely_subtags +i18n_ulocale_canonicalize +i18n_ulocale_for_language_tag +i18n_ulocale_get_base_name +i18n_ulocale_get_character_orientation +i18n_ulocale_get_display_country +i18n_ulocale_get_display_keyword +i18n_ulocale_get_display_keyword_value +i18n_ulocale_get_display_language +i18n_ulocale_get_display_script +i18n_ulocale_get_display_variant +i18n_ulocale_get_iso3_country +i18n_ulocale_get_iso3_language +i18n_ulocale_get_iso_countries +i18n_ulocale_get_iso_languages +i18n_ulocale_get_keyword_value +i18n_ulocale_get_lcid +i18n_ulocale_get_line_orientation +i18n_ulocale_get_locale_for_lcid +i18n_ulocale_get_name +i18n_ulocale_get_parent +i18n_ulocale_get_script +i18n_ulocale_get_variant +i18n_ulocale_keywords_create +i18n_ulocale_minimize_subtags +i18n_ulocale_set_keyword_value +i18n_ulocale_to_language_tag +i18n_ulocale_is_bogus +i18n_unormalization_get_instance +i18n_unormalization_normalize +i18n_unumber_create +i18n_unumber_destroy +i18n_unumber_get_symbol +i18n_unumber_apply_pattern +i18n_unumber_clone +i18n_unumber_count_available +i18n_unumber_format +i18n_unumber_format_decimal +i18n_unumber_format_double +i18n_unumber_format_double_currency +i18n_unumber_format_int64 +i18n_unumber_get_attribute +i18n_unumber_get_available +i18n_unumber_get_double_attribute +i18n_unumber_get_locale_by_type +i18n_unumber_get_text_attribute +i18n_unumber_parse +i18n_unumber_parse_decimal +i18n_unumber_parse_double +i18n_unumber_parse_double_currency +i18n_unumber_parse_int64 +i18n_unumber_set_attribute +i18n_unumber_set_double_attribute +i18n_unumber_set_symbol +i18n_unumber_set_text_attribute +i18n_unumber_to_pattern +i18n_usearch_destroy +i18n_usearch_first +i18n_usearch_get_collator +i18n_usearch_get_matched_text +i18n_usearch_create_new +i18n_uset_add +i18n_uset_add_all +i18n_uset_add_all_code_points +i18n_uset_add_range +i18n_uset_add_string +i18n_uset_apply_int_property_value +i18n_uset_apply_pattern +i18n_uset_apply_property_alias +i18n_uset_char_at +i18n_uset_clear +i18n_uset_clone +i18n_uset_clone_as_thawed +i18n_uset_destroy +i18n_uset_destroy_over +i18n_uset_compact +i18n_uset_complement +i18n_uset_complement_all +i18n_uset_contains +i18n_uset_contains_all +i18n_uset_contains_all_code_points +i18n_uset_contains_none +i18n_uset_contains_range +i18n_uset_contains_some +i18n_uset_contains_string +i18n_uset_equals +i18n_uset_freeze +i18n_uset_get_item +i18n_uset_get_item_count +i18n_uset_get_serialized_range +i18n_uset_get_serialized_range_count +i18n_uset_get_serialized_set +i18n_uset_index_of +i18n_uset_is_empty +i18n_uset_is_frozen +i18n_uset_create +i18n_uset_create_empty +i18n_uset_create_pattern +i18n_uset_create_pattern_options +i18n_uset_remove +i18n_uset_remove_all +i18n_uset_remove_all_strings +i18n_uset_remove_range +i18n_uset_remove_string +i18n_uset_resembles_pattern +i18n_uset_retain +i18n_uset_retain_all +i18n_uset_serialize +i18n_uset_serialized_contains +i18n_uset_set +i18n_uset_set_serialized_to_one +i18n_uset_size +i18n_uset_span +i18n_uset_span_back +i18n_uset_span_back_utf8 +i18n_uset_span_utf8 +i18n_uset_to_pattern +i18n_ustring_compare +i18n_ustring_copy +i18n_ustring_copy_au +i18n_ustring_copy_au_n +i18n_ustring_copy_n +i18n_ustring_copy_ua +i18n_ustring_copy_ua_n +i18n_ustring_from_UTF8 +i18n_ustring_get_length +i18n_ustring_to_title_new +i18n_ustring_to_UTF8 +i18n_ustring_to_upper +i18n_ucalendar_clone +i18n_ucalendar_set +i18n_ucalendar_set_default_timezone +i18n_ucalendar_get_attribute +i18n_timezone_create_unknown +i18n_timezone_create_gmt +i18n_timezone_create +i18n_timezone_destroy +i18n_timezone_foreach_timezone_id_by_region +i18n_timezone_foreach_timezone_id +i18n_timezone_foreach_timezone_id_with_offset +i18n_timezone_foreach_timezone_id_by_country +i18n_timezone_count_equivalent_ids +i18n_timezone_get_equivalent_id +i18n_timezone_create_default +i18n_timezone_set_default +i18n_timezone_get_tzdata_version +i18n_timezone_get_region +i18n_timezone_get_offset_with_date +i18n_timezone_set_raw_offset +i18n_timezone_get_raw_offset +i18n_timezone_get_id +i18n_timezone_set_id +i18n_timezone_get_display_name +i18n_timezone_get_display_name_with_locale +i18n_timezone_get_display_name_with_type +i18n_timezone_get_display_name_with_type_locale +i18n_timezone_use_daylight_time +i18n_timezone_has_same_rule +i18n_timezone_clone +i18n_timezone_get_dst_savings +i18n_timezone_detect_host_timezone +i18n_ustring_count_char32 +i18n_ustring_has_more_char32_than +i18n_ustring_cat +i18n_ustring_cat_n +i18n_ustring_string +i18n_ustring_find_first +i18n_ustring_char +i18n_ustring_char32 +i18n_ustring_r_string +i18n_ustring_find_last +i18n_ustring_r_char +i18n_ustring_r_char32 +i18n_ustring_pbrk +i18n_ustring_cspn +i18n_ustring_spn +i18n_ustring_tokenizer_r +i18n_ustring_compare_code_point_order +i18n_ustring_compare_binary_order +i18n_ustring_case_compare_with_length +i18n_ustring_compare_n +i18n_ustring_compare_n_code_point_order +i18n_ustring_case_compare +i18n_ustring_case_compare_n +i18n_ustring_mem_case_compare +i18n_ustring_mem_copy +i18n_ustring_mem_move +i18n_ustring_mem_set +i18n_ustring_mem_compare +i18n_ustring_mem_compare_code_point_order +i18n_ustring_mem_char +i18n_ustring_mem_char32 +i18n_ustring_mem_r_char +i18n_ustring_mem_r_char32 +i18n_ustring_unescape +i18n_ustring_unescape_at +i18n_ustring_to_lower +i18n_ustring_fold_case +i18n_ustring_to_WCS +i18n_ustring_from_WCS +i18n_ustring_to_UTF8_with_sub +i18n_ustring_from_UTF8_with_sub +i18n_ustring_from_UTF8_lenient +i18n_ustring_to_UTF32 +i18n_ustring_from_UTF32 +i18n_ustring_to_UTF32_with_sub +i18n_ustring_from_UTF32_with_sub +i18n_alpha_idx_create +i18n_alpha_idx_destroy +i18n_alpha_idx_add_labels +i18n_alpha_idx_add_record +i18n_alpha_idx_get_next_bucket +i18n_alpha_idx_get_next_record +i18n_alpha_idx_get_bucket_record_count +i18n_alpha_idx_get_bucket_label +i18n_alpha_idx_get_record_data +i18n_alpha_idx_get_inflow_label +i18n_alpha_idx_set_inflow_label +i18n_alpha_idx_get_overflow_label +i18n_alpha_idx_set_overflow_label +i18n_alpha_idx_get_underflow_label +i18n_alpha_idx_set_underflow_label +i18n_alpha_idx_get_max_label_count +i18n_alpha_idx_set_max_label_count +i18n_alpha_idx_clear_records +i18n_alpha_idx_get_bucket_count +i18n_alpha_idx_get_record_count +i18n_alpha_idx_get_bucket_index +i18n_alpha_idx_get_current_bucket_index +i18n_alpha_idx_get_bucket_label_type +i18n_alpha_idx_get_record_name +i18n_alpha_idx_reset_bucket_iter +i18n_alpha_idx_reset_record_iter +i18n_formattable_create_default +i18n_formattable_create_with_udate +i18n_formattable_create_with_double +i18n_formattable_create_with_long +i18n_formattable_create_with_int64 +i18n_formattable_create_with_char_string +i18n_formattable_create_with_formattable_array +i18n_formattable_destroy +i18n_formattable_clone +i18n_formattable_get_array +i18n_formattable_get_date +i18n_formattable_get_double +i18n_formattable_get_int64 +i18n_formattable_get_long +i18n_formattable_get_string +i18n_formattable_get_type +i18n_formattable_is_numeric +i18n_formattable_not_equal +i18n_formattable_equal +i18n_formattable_element_at +i18n_formattable_set_array +i18n_formattable_set_date +i18n_formattable_set_double +i18n_formattable_set_int64 +i18n_formattable_set_long +i18n_formattable_set_string +i18n_measure_unit_create +i18n_measure_unit_clone +i18n_measure_unit_destroy +i18n_measure_unit_array_destroy +i18n_measure_unit_get_type +i18n_measure_unit_get_subtype +i18n_measure_unit_get_available +i18n_measure_unit_get_available_with_type +i18n_measure_unit_foreach_available_type +i18n_measure_unit_create_g_force +i18n_measure_unit_create_meter_per_second_squared +i18n_measure_unit_create_arc_minute +i18n_measure_unit_create_arc_second +i18n_measure_unit_create_degree +i18n_measure_unit_create_radian +i18n_measure_unit_create_acre +i18n_measure_unit_create_hectare +i18n_measure_unit_create_square_centimeter +i18n_measure_unit_create_square_foot +i18n_measure_unit_create_square_inch +i18n_measure_unit_create_square_kilometer +i18n_measure_unit_create_square_meter +i18n_measure_unit_create_square_mile +i18n_measure_unit_create_square_yard +i18n_measure_unit_create_liter_per_kilometer +i18n_measure_unit_create_mile_per_gallon +i18n_measure_unit_create_bit +i18n_measure_unit_create_byte +i18n_measure_unit_create_gigabit +i18n_measure_unit_create_gigabyte +i18n_measure_unit_create_kilobit +i18n_measure_unit_create_kilobyte +i18n_measure_unit_create_megabit +i18n_measure_unit_create_megabyte +i18n_measure_unit_create_terabit +i18n_measure_unit_create_terabyte +i18n_measure_unit_create_day +i18n_measure_unit_create_hour +i18n_measure_unit_create_microsecond +i18n_measure_unit_create_millisecond +i18n_measure_unit_create_minute +i18n_measure_unit_create_month +i18n_measure_unit_create_nanosecond +i18n_measure_unit_create_second +i18n_measure_unit_create_week +i18n_measure_unit_create_year +i18n_measure_unit_create_ampere +i18n_measure_unit_create_milliampere +i18n_measure_unit_create_ohm +i18n_measure_unit_create_volt +i18n_measure_unit_create_calorie +i18n_measure_unit_create_foodcalorie +i18n_measure_unit_create_joule +i18n_measure_unit_create_kilocalorie +i18n_measure_unit_create_kilojoule +i18n_measure_unit_create_kilowatt_hour +i18n_measure_unit_create_gigahertz +i18n_measure_unit_create_hertz +i18n_measure_unit_create_kilohertz +i18n_measure_unit_create_megahertz +i18n_measure_unit_create_astronomical_unit +i18n_measure_unit_create_centimeter +i18n_measure_unit_create_decimeter +i18n_measure_unit_create_fathom +i18n_measure_unit_create_foot +i18n_measure_unit_create_furlong +i18n_measure_unit_create_inch +i18n_measure_unit_create_kilometer +i18n_measure_unit_create_light_year +i18n_measure_unit_create_meter +i18n_measure_unit_create_micrometer +i18n_measure_unit_create_mile +i18n_measure_unit_create_millimeter +i18n_measure_unit_create_nanometer +i18n_measure_unit_create_nautical_mile +i18n_measure_unit_create_parsec +i18n_measure_unit_create_picometer +i18n_measure_unit_create_yard +i18n_measure_unit_create_lux +i18n_measure_unit_create_carat +i18n_measure_unit_create_gram +i18n_measure_unit_create_kilogram +i18n_measure_unit_create_metric_ton +i18n_measure_unit_create_microgram +i18n_measure_unit_create_milligram +i18n_measure_unit_create_ounce +i18n_measure_unit_create_ounce_troy +i18n_measure_unit_create_pound +i18n_measure_unit_create_stone +i18n_measure_unit_create_ton +i18n_measure_unit_create_gigawatt +i18n_measure_unit_create_horsepower +i18n_measure_unit_create_kilowatt +i18n_measure_unit_create_megawatt +i18n_measure_unit_create_milliwatt +i18n_measure_unit_create_watt +i18n_measure_unit_create_hectopascal +i18n_measure_unit_create_inch_hg +i18n_measure_unit_create_millibar +i18n_measure_unit_create_millimeter_of_mercury +i18n_measure_unit_create_pound_per_square_inch +i18n_measure_unit_create_karat +i18n_measure_unit_create_kilometer_per_hour +i18n_measure_unit_create_meter_per_second +i18n_measure_unit_create_mile_per_hour +i18n_measure_unit_create_celsius +i18n_measure_unit_create_fahrenheit +i18n_measure_unit_create_kelvin +i18n_measure_unit_create_acre_foot +i18n_measure_unit_create_bushel +i18n_measure_unit_create_centiliter +i18n_measure_unit_create_cubic_centimeter +i18n_measure_unit_create_cubic_foot +i18n_measure_unit_create_cubic_inch +i18n_measure_unit_create_cubic_kilometer +i18n_measure_unit_create_cubic_meter +i18n_measure_unit_create_cubic_mile +i18n_measure_unit_create_cubic_yard +i18n_measure_unit_create_cup +i18n_measure_unit_create_deciliter +i18n_measure_unit_create_fluid_ounce +i18n_measure_unit_create_gallon +i18n_measure_unit_create_hectoliter +i18n_measure_unit_create_liter +i18n_measure_unit_create_megaliter +i18n_measure_unit_create_milliliter +i18n_measure_unit_create_pint +i18n_measure_unit_create_quart +i18n_measure_unit_create_tablespoon +i18n_measure_unit_create_teaspoon +i18n_measure_create +i18n_measure_clone +i18n_measure_destroy +i18n_measure_get_number +i18n_measure_get_unit +i18n_format_destroy +i18n_format_clone +i18n_format_format +i18n_format_format_with_field_position +i18n_format_parse_object +i18n_format_parse_object_with_parse_position +i18n_format_get_locale +i18n_measure_format_create +i18n_measure_format_destroy +i18n_measure_format_clone +i18n_measure_format_format +i18n_measure_format_parse_object +i18n_measure_format_create_currency_format_from_locale +i18n_measure_format_create_currency_format +i18n_measure_format_format_buff +i18n_measure_format_format_measures +i18n_measure_format_format_measure_per_unit +i18n_field_position_create +i18n_field_position_create_for_field +i18n_field_position_destroy +i18n_field_position_clone +i18n_field_position_get_field +i18n_field_position_get_begin_index +i18n_field_position_get_end_index +i18n_field_position_set_field +i18n_field_position_set_begin_index +i18n_field_position_set_end_index +i18n_parse_position_create +i18n_parse_position_create_with_index +i18n_parse_position_destroy +i18n_parse_position_clone +i18n_parse_position_get_index +i18n_parse_position_set_index +i18n_parse_position_set_error_index +i18n_parse_position_get_error_index +i18n_ushape_shape_arabic +i18n_utmscale_get_time_scale_value +i18n_utmscale_from_int64 +i18n_utmscale_to_int64 +i18n_ubidi_destroy +i18n_ubidi_count_paragraphs +i18n_ubidi_count_runs +i18n_ubidi_get_base_direction +i18n_ubidi_get_class_cb +i18n_ubidi_get_customized_class +i18n_ubidi_get_direction +i18n_ubidi_get_length +i18n_ubidi_get_level_at +i18n_ubidi_get_levels +i18n_ubidi_get_logical_index +i18n_ubidi_get_logical_map +i18n_ubidi_get_logical_run +i18n_ubidi_get_paragraph +i18n_ubidi_get_paragraph_by_index +i18n_ubidi_get_para_level +i18n_ubidi_get_processed_length +i18n_ubidi_get_reordering_mode +i18n_ubidi_get_reordering_options +i18n_ubidi_get_result_length +i18n_ubidi_get_text +i18n_ubidi_get_visual_index +i18n_ubidi_get_visual_map +i18n_ubidi_get_visual_run +i18n_ubidi_invert_map +i18n_ubidi_is_inverse +i18n_ubidi_is_order_paragraphs_ltr +i18n_ubidi_create +i18n_ubidi_create_sized +i18n_ubidi_order_paragraphs_ltr +i18n_ubidi_reorder_logical +i18n_ubidi_reorder_visual +i18n_ubidi_set_class_cb +i18n_ubidi_set_context +i18n_ubidi_set_inverse +i18n_ubidi_set_line +i18n_ubidi_set_para +i18n_ubidi_set_reordering_mode +i18n_ubidi_set_reordering_options +i18n_ubidi_write_reordered +i18n_ubidi_write_reverse +i18n_uversion_get_version +i18n_uversion_from_string +i18n_uversion_from_ustring +i18n_uversion_to_string +i18n_ucollator_create_rules +i18n_ucollator_get_contractions_and_expansions +i18n_ucollator_str_collator_utf8 +i18n_ucollator_greater +i18n_ucollator_greater_or_equal +i18n_ucollator_str_collator_iter +i18n_ucollator_get_strength +i18n_ucollator_get_reorder_codes +i18n_ucollator_set_reorder_codes +i18n_ucollator_get_equivalent_reorder_codes +i18n_ucollator_get_display_name +i18n_ucollator_get_available +i18n_ucollator_count_available +i18n_ucollator_create_available_locales +i18n_ucollator_get_keywords +i18n_ucollator_get_keyword_values +i18n_ucollator_get_keyword_values_for_locale +i18n_ucollator_get_functional_equivalent +i18n_ucollator_get_rules +i18n_ucollator_get_sort_key +i18n_ucollator_next_sort_key_part +i18n_ucollator_get_bound +i18n_ucollator_get_version +i18n_ucollator_get_uca_version +i18n_ucollator_merge_sort_keys +i18n_ucollator_get_attribute +i18n_ucollator_set_max_variable +i18n_ucollator_get_max_variable +i18n_ucollator_get_variable_top +i18n_ucollator_safe_clone +i18n_ucollator_get_rules_ex +i18n_ucollator_get_locale_by_type +i18n_ucollator_get_tailored_set +i18n_ucollator_clone_binary +i18n_ucollator_create_binary +i18n_plural_rules_create +i18n_plural_rules_destroy +i18n_plural_rules_clone +i18n_plural_rules_create_rules_from_descr +i18n_plural_rules_for_locale +i18n_plural_rules_select_int32 +i18n_plural_rules_select_double +i18n_plural_rules_get_keywords +i18n_plural_rules_get_samples +i18n_plural_rules_is_keyword +i18n_plural_rules_get_keyword_other +cairo_gl_surface_create_for_evas_gl +cairo_evas_gl_device_create +cairo_evas_gl_device_get_gl +cairo_evas_gl_device_get_context +cairo_gl_surface_create +cairo_gl_surface_create_for_texture +cairo_gl_surface_get_width +cairo_gl_surface_get_height +cairo_gl_device_set_thread_aware +camera_attr_clear_af_area +camera_attr_disable_shutter_sound +camera_attr_enable_anti_shake +camera_attr_enable_auto_contrast +camera_attr_enable_tag +camera_attr_enable_video_stabilization +camera_attr_foreach_supported_af_mode +camera_attr_foreach_supported_effect +camera_attr_foreach_supported_exposure_mode +camera_attr_foreach_supported_flash_mode +camera_attr_foreach_supported_fps +camera_attr_foreach_supported_fps_by_resolution +camera_attr_foreach_supported_iso +camera_attr_foreach_supported_scene_mode +camera_attr_foreach_supported_stream_flip +camera_attr_foreach_supported_stream_rotation +camera_attr_foreach_supported_theater_mode +camera_attr_foreach_supported_whitebalance +camera_attr_get_encoded_preview_bitrate +camera_attr_set_encoded_preview_bitrate +camera_attr_get_encoded_preview_gop_interval +camera_attr_set_encoded_preview_gop_interval +camera_attr_get_af_mode +camera_attr_get_brightness +camera_attr_get_brightness_range +camera_attr_get_contrast +camera_attr_get_contrast_range +camera_attr_get_effect +camera_attr_get_exposure +camera_attr_get_exposure_mode +camera_attr_get_exposure_range +camera_attr_get_flash_mode +camera_attr_get_geotag +camera_attr_get_hdr_mode +camera_attr_get_image_quality +camera_attr_get_iso +camera_attr_get_lens_orientation +camera_attr_get_preview_fps +camera_attr_get_scene_mode +camera_attr_get_stream_flip +camera_attr_get_stream_rotation +camera_attr_get_tag_image_description +camera_attr_get_tag_orientation +camera_attr_get_tag_software +camera_attr_get_theater_mode +camera_attr_get_whitebalance +camera_attr_get_zoom +camera_attr_get_zoom_range +camera_attr_is_enabled_anti_shake +camera_attr_is_enabled_auto_contrast +camera_attr_is_enabled_tag +camera_attr_is_enabled_video_stabilization +camera_attr_is_supported_anti_shake +camera_attr_is_supported_auto_contrast +camera_attr_is_supported_hdr_capture +camera_attr_is_supported_video_stabilization +camera_attr_remove_geotag +camera_attr_set_af_area +camera_attr_set_af_mode +camera_attr_set_brightness +camera_attr_set_contrast +camera_attr_set_effect +camera_attr_set_exposure +camera_attr_set_exposure_mode +camera_attr_set_flash_mode +camera_attr_set_geotag +camera_attr_set_hdr_capture_progress_cb +camera_attr_set_hdr_mode +camera_attr_set_image_quality +camera_attr_set_iso +camera_attr_set_preview_fps +camera_attr_set_scene_mode +camera_attr_set_stream_flip +camera_attr_set_stream_rotation +camera_attr_set_tag_image_description +camera_attr_set_tag_orientation +camera_attr_set_tag_software +camera_attr_set_theater_mode +camera_attr_set_whitebalance +camera_attr_set_zoom +camera_attr_unset_hdr_capture_progress_cb +camera_attr_set_pan +camera_attr_get_pan +camera_attr_get_pan_range +camera_attr_set_tilt +camera_attr_get_tilt +camera_attr_get_tilt_range +camera_attr_set_ptz_type +camera_attr_foreach_supported_ptz_type +camera_attr_set_display_roi_area +camera_attr_get_display_roi_area +camera_attr_set_hue +camera_attr_get_hue +camera_attr_get_hue_range +camera_cancel_focusing +camera_create +camera_destroy +camera_foreach_supported_capture_format +camera_foreach_supported_capture_resolution +camera_foreach_supported_preview_format +camera_foreach_supported_preview_resolution +camera_get_capture_format +camera_get_capture_resolution +camera_get_device_count +camera_get_display_flip +camera_get_display_mode +camera_get_display_rotation +camera_get_preview_format +camera_get_preview_resolution +camera_get_recommended_preview_resolution +camera_get_state +camera_get_flash_state +camera_get_facing_direction +camera_is_display_visible +camera_is_supported_continuous_capture +camera_is_supported_face_detection +camera_is_supported_media_packet_preview_cb +camera_is_supported_zero_shutter_lag +camera_set_capture_format +camera_set_capture_resolution +camera_set_display +camera_set_display_flip +camera_set_display_mode +camera_set_display_rotation +camera_set_display_visible +camera_set_error_cb +camera_set_focus_changed_cb +camera_set_interrupted_cb +camera_set_media_packet_preview_cb +camera_set_preview_cb +camera_set_preview_format +camera_set_preview_resolution +camera_set_state_changed_cb +camera_start_capture +camera_start_continuous_capture +camera_start_face_detection +camera_start_focusing +camera_start_preview +camera_stop_continuous_capture +camera_stop_face_detection +camera_stop_preview +camera_unset_error_cb +camera_unset_focus_changed_cb +camera_unset_interrupted_cb +camera_unset_media_packet_preview_cb +camera_unset_preview_cb +camera_unset_state_changed_cb +camera_change_device +camera_set_display_reuse_hint +camera_get_display_reuse_hint +camera_get_device_state +camera_add_device_state_changed_cb +camera_remove_device_state_changed_cb +camera_set_interrupt_started_cb +camera_unset_interrupt_started_cb +media_packet_alloc +media_packet_copy +media_packet_create +media_packet_create_alloc +media_packet_create_from_tbm_surface +media_packet_create_from_external_memory +media_packet_destroy +media_packet_get_codec_data +media_packet_get_buffer_data_ptr +media_packet_get_buffer_size +media_packet_get_dts +media_packet_get_duration +media_packet_get_extra +media_packet_get_format +media_packet_get_pts +media_packet_get_tbm_surface +media_packet_get_number_of_video_planes +media_packet_get_video_stride_width +media_packet_get_video_stride_height +media_packet_get_video_plane_data_ptr +media_packet_get_flags +media_packet_is_audio +media_packet_is_codec_config +media_packet_is_encoded +media_packet_is_end_of_stream +media_packet_is_raw +media_packet_is_sync_frame +media_packet_is_video +media_packet_is_text +media_packet_set_buffer_size +media_packet_set_dts +media_packet_set_duration +media_packet_set_extra +media_packet_set_flags +media_packet_set_format +media_packet_set_pts +media_packet_unset_flags +media_format_create +media_format_get_video_info +media_format_get_audio_info +media_format_get_type +media_format_get_container_mime +media_format_set_container_mime +media_format_set_video_frame_rate +media_format_get_video_frame_rate +media_format_get_text_info +media_format_get_audio_aac_header_type +media_format_set_audio_aac_header_type +media_format_set_text_mime +media_format_set_text_type +media_format_set_video_mime +media_format_set_video_width +media_format_set_video_height +media_format_set_video_avg_bps +media_format_set_video_max_bps +media_format_set_audio_aac_type +media_format_set_audio_mime +media_format_set_audio_channel +media_format_set_audio_samplerate +media_format_set_audio_bit +media_format_set_audio_avg_bps +media_format_get_audio_aac_type +media_format_set_extra +media_format_get_extra +media_format_ref +media_format_unref +media_format_is_writable +media_format_make_writable +media_packet_has_tbm_surface_buffer +media_packet_pool_create +media_packet_pool_set_media_format +media_packet_pool_set_size +media_packet_pool_get_size +media_packet_pool_allocate +media_packet_pool_acquire_packet +media_packet_pool_release_packet +media_packet_pool_deallocate +media_packet_pool_destroy +get_last_result +set_last_result +get_error_message +connection_add_profile +connection_add_route +connection_add_route_ipv6 +connection_remove_route_ipv6 +connection_add_route_entry +connection_remove_route_entry +connection_close_profile +connection_create +connection_destroy +connection_destroy_profile_iterator +connection_get_bt_state +connection_get_cellular_state +connection_get_current_profile +connection_get_default_cellular_service_profile +connection_get_ethernet_state +connection_get_ip_address +connection_get_profile_iterator +connection_get_proxy +connection_get_statistics +connection_get_type +connection_get_wifi_state +connection_get_mac_address +connection_set_ethernet_cable_state_changed_cb +connection_unset_ethernet_cable_state_changed_cb +connection_get_ethernet_cable_state +connection_open_profile +connection_profile_clone +connection_profile_create +connection_profile_destroy +connection_profile_get_cellular_apn +connection_profile_get_cellular_auth_info +connection_profile_get_cellular_home_url +connection_profile_get_cellular_service_type +connection_profile_get_dns_address +connection_profile_get_gateway_address +connection_profile_get_id +connection_profile_get_ip_address +connection_profile_get_ip_config_type +connection_profile_get_name +connection_profile_get_network_interface_name +connection_profile_get_proxy_address +connection_profile_get_proxy_type +connection_profile_get_state +connection_profile_get_subnet_mask +connection_profile_get_type +connection_profile_get_wifi_bssid +connection_profile_get_wifi_encryption_type +connection_profile_get_wifi_essid +connection_profile_get_wifi_frequency +connection_profile_get_wifi_max_speed +connection_profile_get_wifi_rssi +connection_profile_get_wifi_security_type +connection_profile_is_cellular_editable +connection_profile_is_cellular_default +connection_profile_is_cellular_hidden +connection_profile_is_cellular_roaming +connection_profile_is_wifi_passphrase_required +connection_profile_is_wifi_wps_supported +connection_profile_iterator_has_next +connection_profile_iterator_next +connection_profile_refresh +connection_profile_set_cellular_apn +connection_profile_set_cellular_auth_info +connection_profile_set_cellular_home_url +connection_profile_set_cellular_service_type +connection_profile_set_dns_address +connection_profile_set_gateway_address +connection_profile_set_ip_address +connection_profile_set_ip_config_type +connection_profile_set_proxy_address +connection_profile_set_proxy_type +connection_profile_set_state_changed_cb +connection_profile_set_subnet_mask +connection_profile_set_wifi_passphrase +connection_profile_unset_state_changed_cb +connection_remove_profile +connection_remove_route +connection_reset_profile +connection_reset_statistics +connection_set_default_cellular_service_profile +connection_set_default_cellular_service_profile_async +connection_set_ip_address_changed_cb +connection_set_proxy_address_changed_cb +connection_set_type_changed_cb +connection_unset_ip_address_changed_cb +connection_unset_proxy_address_changed_cb +connection_unset_type_changed_cb +connection_update_profile +connection_profile_get_cellular_pdn_type +connection_profile_get_cellular_roam_pdn_type +connection_profile_set_cellular_pdn_type +connection_profile_set_cellular_roam_pdn_type +connection_foreach_ipv6_address +connection_profile_get_ipv6_state +connection_profile_get_dns_config_type +connection_profile_set_dns_config_type +connection_profile_get_prefix_length +connection_profile_set_prefix_length +connection_profile_get_dhcp_server_address +connection_profile_get_dhcp_lease_duration +connection_is_metered_network +data_control_map_add +data_control_map_create +data_control_map_destroy +data_control_map_get +data_control_map_get_data_id +data_control_map_get_provider_id +data_control_map_get_with_page +data_control_map_register_response_cb +data_control_map_remove +data_control_map_set +data_control_map_set_data_id +data_control_map_set_provider_id +data_control_map_unregister_response_cb +data_control_provider_create_delete_statement +data_control_provider_create_insert_statement +data_control_provider_create_select_statement +data_control_provider_create_update_statement +data_control_provider_get_client_appid +data_control_provider_map_register_cb +data_control_provider_map_unregister_cb +data_control_provider_match_data_id +data_control_provider_match_provider_id +data_control_provider_send_delete_result +data_control_provider_send_error +data_control_provider_send_insert_result +data_control_provider_send_map_get_value_result +data_control_provider_send_map_result +data_control_provider_send_select_result +data_control_provider_send_update_result +data_control_provider_sql_register_cb +data_control_provider_sql_unregister_cb +data_control_sql_create +data_control_sql_delete +data_control_sql_destroy +data_control_sql_get_blob_data +data_control_sql_get_column_count +data_control_sql_get_column_item_size +data_control_sql_get_column_item_type +data_control_sql_get_column_name +data_control_sql_get_data_id +data_control_sql_get_double_data +data_control_sql_get_int_data +data_control_sql_get_int64_data +data_control_sql_get_provider_id +data_control_sql_get_text_data +data_control_sql_insert +data_control_sql_register_response_cb +data_control_sql_select +data_control_sql_select_with_page +data_control_sql_set_data_id +data_control_sql_set_provider_id +data_control_sql_step_first +data_control_sql_step_last +data_control_sql_step_next +data_control_sql_step_previous +data_control_sql_unregister_response_cb +data_control_sql_update +data_control_add_data_change_cb +data_control_remove_data_change_cb +data_control_provider_send_data_change_noti +data_control_provider_add_data_change_consumer_filter_cb +data_control_provider_remove_data_change_consumer_filter_cb +data_control_provider_foreach_data_change_consumer +data_control_bulk_data_get_data +data_control_bulk_data_get_count +data_control_bulk_data_add +data_control_bulk_data_create +data_control_bulk_data_destroy +data_control_bulk_result_data_get_result_data +data_control_bulk_result_data_get_count +data_control_bulk_result_data_add +data_control_bulk_result_data_create +data_control_bulk_result_data_destroy +data_control_provider_send_bulk_insert_result +data_control_provider_send_map_bulk_add_result +data_control_provider_sql_register_insert_bulk_data_request_cb +data_control_provider_sql_unregister_insert_bulk_data_request_cb +data_control_provider_map_register_add_bulk_data_request_cb +data_control_provider_map_unregister_add_bulk_data_request_cb +data_control_sql_insert_bulk_data +data_control_sql_register_insert_bulk_data_response_cb +data_control_sql_unregister_insert_bulk_data_response_cb +data_control_map_add_bulk_data +data_control_map_register_add_bulk_data_response_cb +data_control_map_unregister_add_bulk_data_response_cb +data_control_map_bind_response_cb +data_control_map_unbind_response_cb +data_control_map_bind_add_bulk_data_response_cb +data_control_map_unbind_add_bulk_data_response_cb +data_control_map_get_handle_id +data_control_sql_bind_response_cb +data_control_sql_unbind_response_cb +data_control_sql_bind_insert_bulk_data_response_cb +data_control_sql_unbind_insert_bulk_data_response_cb +data_control_sql_get_handle_id +device_add_callback +device_battery_get_level_status +device_battery_get_percent +device_battery_is_charging +device_battery_get_health +device_battery_get_power_source +device_battery_get_property +device_battery_get_status +device_display_change_state +device_display_get_brightness +device_display_get_max_brightness +device_display_get_numbers +device_display_get_state +device_display_set_brightness +device_flash_get_brightness +device_flash_get_max_brightness +device_flash_set_brightness +device_haptic_close +device_haptic_get_count +device_haptic_open +device_haptic_stop +device_haptic_vibrate +device_led_play_custom +device_led_stop_custom +device_power_release_lock +device_power_request_lock +device_remove_callback +device_power_reboot +device_ir_is_available +device_ir_transmit +efl_util_get_notification_window_level +efl_util_set_notification_window_level +efl_util_set_window_opaque_state +efl_util_set_window_screen_mode +efl_util_get_window_screen_mode +efl_util_set_window_screen_mode_error_cb +efl_util_unset_window_screen_mode_error_cb +efl_util_set_window_brightness +efl_util_get_window_brightness +efl_util_input_initialize_generator +efl_util_input_deinitialize_generator +efl_util_input_generate_key +efl_util_input_generate_touch +efl_util_input_generate_pointer +efl_util_input_initialize_generator_with_name +efl_util_screenshot_initialize +efl_util_screenshot_deinitialize +efl_util_screenshot_take_tbm_surface +efl_util_gesture_initialize +efl_util_gesture_deinitialize +efl_util_gesture_edge_swipe_new +efl_util_gesture_edge_swipe_free +efl_util_gesture_edge_swipe_size_set +efl_util_gesture_edge_drag_new +efl_util_gesture_edge_drag_free +efl_util_gesture_edge_drag_size_set +efl_util_gesture_tap_new +efl_util_gesture_tap_free +efl_util_gesture_palm_cover_new +efl_util_gesture_palm_cover_free +efl_util_gesture_grab +efl_util_gesture_ungrab +efl_util_gesture_select +efl_util_gesture_deselect +efl_util_gesture_activate_set +efl_util_gesture_activate_set_on_window +email_add_attach +email_add_recipient +email_create_message +email_destroy_message +email_remove_all_attachments +email_remove_all_recipients +email_save_message +email_send_message +email_set_body +email_set_message_sent_cb +email_set_subject +email_unset_message_sent_cb +image_util_calculate_buffer_size +image_util_decode_jpeg_with_downscale +image_util_decode_jpeg_from_memory_with_downscale +image_util_foreach_supported_colorspace +image_util_decode_create +image_util_decode_set_input_path +image_util_decode_set_input_buffer +image_util_decode_set_output_buffer +image_util_decode_set_colorspace +image_util_decode_set_jpeg_downscale +image_util_encode_set_gif_frame_delay_time +image_util_decode_run +image_util_decode_run_async +image_util_decode_destroy +image_util_encode_create +image_util_encode_set_resolution +image_util_encode_set_png_compression +image_util_encode_set_input_buffer +image_util_encode_set_output_path +image_util_encode_set_output_buffer +image_util_encode_set_colorspace +image_util_encode_set_quality +image_util_encode_run +image_util_encode_run_async +image_util_encode_destroy +image_util_extract_color_from_memory +image_util_transform_create +image_util_transform_set_hardware_acceleration +image_util_transform_set_colorspace +image_util_transform_set_resolution +image_util_transform_set_rotation +image_util_transform_set_crop_area +image_util_transform_get_colorspace +image_util_transform_get_resolution +image_util_transform_get_rotation +image_util_transform_get_crop_area +image_util_transform_run +image_util_transform_destroy +gps_status_foreach_last_satellites_in_view +gps_status_foreach_satellites_in_view +gps_status_get_last_satellite +gps_status_get_nmea +gps_status_get_satellite +gps_status_set_satellite_updated_cb +gps_status_unset_satellite_updated_cb +location_bounds_contains_coordinates +location_bounds_create_circle +location_bounds_create_polygon +location_bounds_create_rect +location_bounds_destroy +location_bounds_foreach_polygon_coords +location_bounds_get_circle_coords +location_bounds_get_rect_coords +location_bounds_get_type +location_bounds_set_state_changed_cb +location_bounds_unset_state_changed_cb +location_manager_add_boundary +location_manager_create +location_manager_destroy +location_manager_foreach_boundary +location_manager_get_accuracy +location_manager_get_distance +location_manager_get_last_accuracy +location_manager_get_last_location +location_manager_get_last_position +location_manager_get_last_velocity +location_manager_get_location +location_manager_get_method +location_manager_get_position +location_manager_get_velocity +location_manager_is_enabled_method +location_manager_is_supported_method +location_manager_remove_boundary +location_manager_request_single_location +location_manager_set_position_updated_cb +location_manager_set_service_state_changed_cb +location_manager_set_setting_changed_cb +location_manager_set_velocity_updated_cb +location_manager_set_zone_changed_cb +location_manager_set_distance_based_location_changed_cb +location_manager_set_location_changed_cb +location_manager_enable_method +location_manager_start +location_manager_stop +location_manager_unset_position_updated_cb +location_manager_unset_service_state_changed_cb +location_manager_unset_setting_changed_cb +location_manager_unset_velocity_updated_cb +location_manager_unset_zone_changed_cb +location_manager_unset_distance_based_location_changed_cb +location_manager_unset_location_changed_cb +location_manager_set_mock_location +location_manager_enable_mock_location +location_manager_clear_mock_location +location_manager_is_enabled_mock_location +location_manager_start_batch +location_manager_foreach_location_batch +location_manager_stop_batch +location_manager_set_location_batch_cb +location_manager_unset_location_batch_cb +location_manager_set_fused_mode +mediacodec_create +mediacodec_destroy +mediacodec_set_codec +mediacodec_set_vdec_info +mediacodec_set_venc_info +mediacodec_set_adec_info +mediacodec_set_aenc_info +mediacodec_prepare +mediacodec_unprepare +mediacodec_process_input +mediacodec_get_output +mediacodec_set_input_buffer_used_cb +mediacodec_unset_input_buffer_used_cb +mediacodec_set_output_buffer_available_cb +mediacodec_unset_output_buffer_available_cb +mediacodec_set_error_cb +mediacodec_unset_error_cb +mediacodec_set_eos_cb +mediacodec_unset_eos_cb +mediacodec_set_buffer_status_cb +mediacodec_unset_buffer_status_cb +mediacodec_flush_buffers +mediacodec_foreach_supported_codec +mediacodec_get_supported_type +mediacodec_get_packet_pool +mediacodec_configure_from_media_format +audio_meta_clone +audio_meta_destroy +audio_meta_get_album +audio_meta_get_album_artist +audio_meta_get_artist +audio_meta_get_bit_rate +audio_meta_get_bitpersample +audio_meta_get_channel +audio_meta_get_composer +audio_meta_get_copyright +audio_meta_get_duration +audio_meta_get_genre +audio_meta_get_media_id +audio_meta_get_recorded_date +audio_meta_get_sample_rate +audio_meta_get_track_num +audio_meta_get_year +image_meta_clone +image_meta_destroy +image_meta_get_date_taken +image_meta_get_height +image_meta_get_media_id +image_meta_get_orientation +image_meta_get_width +image_meta_get_exposure_time +image_meta_get_fnumber +image_meta_get_iso +image_meta_get_model +media_album_clone +media_album_destroy +media_album_foreach_album_from_db +media_album_foreach_media_from_db +media_album_get_album_art +media_album_get_album_count_from_db +media_album_get_album_from_db +media_album_get_album_id +media_album_get_artist +media_album_get_media_count_from_db +media_album_get_name +media_bookmark_clone +media_bookmark_delete_from_db +media_bookmark_destroy +media_bookmark_get_bookmark_count_from_db +media_bookmark_get_bookmark_id +media_bookmark_get_marked_time +media_bookmark_get_thumbnail_path +media_bookmark_insert_to_db +media_bookmark_get_name +media_bookmark_set_name +media_bookmark_update_to_db +media_bookmark_foreach_bookmark_from_db +media_content_connect +media_content_disconnect +media_content_scan_file +media_content_scan_folder +media_content_cancel_scan_folder +media_content_add_db_updated_cb +media_content_remove_db_updated_cb +media_face_create +media_face_clone +media_face_destroy +media_face_set_face_rect +media_face_set_orientation +media_face_set_tag +media_face_get_media_id +media_face_get_face_rect +media_face_get_face_id +media_face_get_orientation +media_face_get_tag +media_face_insert_to_db +media_face_update_to_db +media_face_delete_from_db +media_face_get_face_count_from_db +media_face_foreach_face_from_db +media_filter_create +media_filter_destroy +media_filter_get_condition +media_filter_get_offset +media_filter_get_order +media_filter_set_condition +media_filter_set_offset +media_filter_set_order +media_filter_set_storage +media_filter_get_storage +media_folder_clone +media_folder_destroy +media_folder_foreach_folder_from_db +media_folder_foreach_media_from_db +media_folder_get_folder_count_from_db +media_folder_get_folder_from_db +media_folder_get_folder_id +media_folder_get_media_count_from_db +media_folder_get_name +media_folder_get_path +media_folder_get_storage_type +media_folder_get_storage_id +media_group_foreach_group_from_db +media_group_foreach_media_from_db +media_group_get_group_count_from_db +media_group_get_media_count_from_db +media_info_cancel_thumbnail +media_info_clone +media_info_create_thumbnail +media_info_delete_from_db +media_info_destroy +media_info_foreach_bookmark_from_db +media_info_foreach_media_from_db +media_info_foreach_tag_from_db +media_info_foreach_face_from_db +media_info_get_face_count_from_db +media_info_get_added_time +media_info_get_altitude +media_info_get_audio +media_info_get_bookmark_count_from_db +media_info_get_description +media_info_get_display_name +media_info_get_favorite +media_info_get_file_path +media_info_get_image +media_info_get_latitude +media_info_get_longitude +media_info_get_media_count_from_db +media_info_get_media_from_db +media_info_get_media_id +media_info_get_media_type +media_info_get_mime_type +media_info_get_modified_time +media_info_get_rating +media_info_get_size +media_info_get_storage_id +media_info_get_storage_type +media_info_get_tag_count_from_db +media_info_get_thumbnail_path +media_info_get_timeline +media_info_get_title +media_info_get_video +media_info_insert_batch_to_db +media_info_insert_to_db +media_info_is_drm +media_info_is_360_content +media_info_move_to_db +media_info_set_favorite +media_info_update_to_db +media_info_start_face_detection +media_info_cancel_face_detection +media_playlist_add_media +media_playlist_clone +media_playlist_delete_from_db +media_playlist_destroy +media_playlist_foreach_media_from_db +media_playlist_foreach_playlist_from_db +media_playlist_get_media_count_from_db +media_playlist_get_name +media_playlist_get_play_order +media_playlist_get_playlist_count_from_db +media_playlist_get_playlist_from_db +media_playlist_get_playlist_id +media_playlist_get_thumbnail_path +media_playlist_insert_to_db +media_playlist_remove_media +media_playlist_set_name +media_playlist_set_play_order +media_playlist_set_thumbnail_path +media_playlist_update_to_db +media_playlist_import_from_file +media_playlist_export_to_file +media_storage_get_storage_info_from_db +media_storage_get_storage_count_from_db +media_storage_foreach_storage_from_db +media_storage_destroy +media_storage_clone +media_storage_get_id +media_storage_get_path +media_storage_get_type +media_storage_get_media_count_from_db +media_storage_foreach_media_from_db +media_tag_add_media +media_tag_clone +media_tag_delete_from_db +media_tag_destroy +media_tag_foreach_media_from_db +media_tag_foreach_tag_from_db +media_tag_get_media_count_from_db +media_tag_get_name +media_tag_get_tag_count_from_db +media_tag_get_tag_from_db +media_tag_get_tag_id +media_tag_insert_to_db +media_tag_remove_media +media_tag_set_name +media_tag_update_to_db +video_meta_clone +video_meta_destroy +video_meta_get_album +video_meta_get_album_artist +video_meta_get_artist +video_meta_get_bit_rate +video_meta_get_composer +video_meta_get_copyright +video_meta_get_duration +video_meta_get_genre +video_meta_get_height +video_meta_get_media_id +video_meta_get_recorded_date +video_meta_get_track_num +video_meta_get_width +video_meta_get_year +video_meta_get_rotation +media_key_release +media_key_reserve +message_port_check_remote_port +message_port_check_trusted_remote_port +message_port_register_local_port +message_port_register_trusted_local_port +message_port_send_message +message_port_send_message_with_local_port +message_port_send_trusted_message +message_port_send_trusted_message_with_local_port +message_port_unregister_local_port +message_port_unregister_trusted_local_port +message_port_add_registered_cb +message_port_add_unregistered_cb +message_port_remove_registration_event_cb +messages_add_address +messages_add_sms_listening_port +messages_close_service +messages_create_message +messages_destroy_message +messages_foreach_message +messages_free_message_array +messages_get_address +messages_get_address_count +messages_get_mbox_type +messages_get_message_count +messages_get_message_id +messages_get_message_port +messages_get_message_type +messages_get_sim_id +messages_get_text +messages_get_time +messages_mms_add_attachment +messages_mms_get_attachment +messages_mms_get_attachment_count +messages_mms_get_subject +messages_mms_remove_all_attachments +messages_mms_set_subject +messages_open_service +messages_push_add_incoming_cb +messages_push_deregister +messages_push_register +messages_push_remove_incoming_cb +messages_push_reregister +messages_remove_all_addresses +messages_search_message +messages_search_message_by_id +messages_send_message +messages_set_message_incoming_cb +messages_set_sim_id +messages_set_text +messages_unset_message_incoming_cb +messages_add_message +messages_set_mbox_type +messages_set_time +metadata_extractor_create +metadata_extractor_destroy +metadata_extractor_get_artwork +metadata_extractor_get_frame +metadata_extractor_get_frame_at_time +metadata_extractor_get_metadata +metadata_extractor_get_synclyrics +metadata_extractor_set_buffer +metadata_extractor_set_path +metadata_editor_create +metadata_editor_set_path +metadata_editor_get_metadata +metadata_editor_set_metadata +metadata_editor_update_metadata +metadata_editor_get_picture +metadata_editor_append_picture +metadata_editor_remove_picture +metadata_editor_destroy +mime_type_get_file_extension +mime_type_get_mime_type +mime_type_get_mime_type_for_data +mime_type_get_mime_type_for_file +package_info_clone +package_info_create +package_info_destroy +package_info_foreach_app_from_package +package_info_foreach_cert_info +package_info_get_icon +package_info_get_installed_storage +package_info_get_label +package_info_get_package +package_info_get_root_path +package_info_get_type +package_info_get_version +package_info_get_tep_name +package_info_get_installed_time +package_info_get_main_app_id +package_info_is_accessible +package_info_is_equal +package_info_is_preload_package +package_info_is_removable_package +package_info_is_system_package +package_info_updateinfo_create +package_info_updateinfo_get_pkgid +package_info_updateinfo_get_version +package_info_updateinfo_get_type +package_info_updateinfo_destroy +package_info_updateinfo_foreach_info +package_manager_drm_generate_license_request +package_manager_drm_register_license +package_manager_drm_decrypt_package +package_manager_clear_all_cache_dir +package_manager_clear_cache_dir +package_manager_clear_data_dir +package_manager_compare_app_cert_info +package_manager_compare_package_cert_info +package_manager_create +package_manager_destroy +package_manager_filter_add_bool +package_manager_filter_count +package_manager_filter_create +package_manager_filter_destroy +package_manager_filter_foreach_package_info +package_manager_foreach_package_info +package_manager_get_package_id_by_app_id +package_manager_get_package_info +package_manager_get_package_size_info +package_manager_get_permission_type +package_manager_get_total_package_size_info +package_manager_is_preload_package_by_app_id +package_manager_request_create +package_manager_request_destroy +package_manager_request_install +package_manager_request_install_with_cb +package_manager_request_move +package_manager_request_move_with_cb +package_manager_request_set_event_cb +package_manager_request_set_mode +package_manager_request_set_type +package_manager_request_set_tep +package_manager_request_uninstall +package_manager_request_uninstall_with_cb +package_manager_request_unset_event_cb +package_manager_set_event_cb +package_manager_set_event_status +package_manager_unset_event_cb +package_manager_updateinfo_request_create +package_manager_updateinfo_set_pkgid +package_manager_updateinfo_set_version +package_manager_updateinfo_set_type +package_manager_updateinfo_request_register +package_manager_updateinfo_request_destroy +package_manager_updateinfo_request_unregister +package_manager_updateinfo_request_unregister_all +package_info_foreach_privilege_info +package_size_info_get_data_size +package_size_info_get_cache_size +package_size_info_get_app_size +package_size_info_get_external_data_size +package_size_info_get_external_cache_size +package_size_info_get_external_app_size +package_archive_info_create +package_archive_info_destroy +package_archive_info_get_package +package_archive_info_get_type +package_archive_info_get_version +package_archive_info_get_api_version +package_archive_info_get_description +package_archive_info_get_label +package_archive_info_get_author +package_archive_info_get_icon +player_audio_effect_equalizer_clear +player_audio_effect_equalizer_is_available +player_audio_effect_get_equalizer_band_frequency +player_audio_effect_get_equalizer_band_frequency_range +player_audio_effect_get_equalizer_band_level +player_audio_effect_get_equalizer_bands_count +player_audio_effect_get_equalizer_level_range +player_audio_effect_set_equalizer_all_bands +player_audio_effect_set_equalizer_band_level +player_capture_video +player_create +player_destroy +player_get_album_art +player_get_audio_latency_mode +player_get_audio_stream_info +player_get_codec_info +player_get_content_info +player_get_current_track +player_get_display_mode +player_get_display_rotation +player_get_duration +player_get_play_position +player_get_state +player_get_streaming_download_progress +player_get_track_count +player_get_track_language_code +player_get_video_size +player_get_video_stream_info +player_get_volume +player_is_display_visible +player_is_looping +player_is_muted +player_pause +player_prepare +player_prepare_async +player_select_track +player_set_video_stream_changed_cb +player_unset_video_stream_changed_cb +player_set_sound_stream_info +player_set_audio_latency_mode +player_set_buffering_cb +player_set_completed_cb +player_set_display +player_set_display_mode +player_set_display_rotation +player_set_display_visible +player_set_display_roi_area +player_set_error_cb +player_set_interrupted_cb +player_set_looping +player_set_media_packet_video_frame_decoded_cb +player_set_memory_buffer +player_set_mute +player_set_play_position +player_set_playback_rate +player_set_streaming_cookie +player_set_streaming_user_agent +player_set_subtitle_path +player_set_subtitle_position_offset +player_set_subtitle_updated_cb +player_set_uri +player_set_volume +player_set_media_stream_info +player_set_media_stream_buffer_status_cb +player_unset_media_stream_buffer_status_cb +player_set_media_stream_seek_cb +player_unset_media_stream_seek_cb +player_set_media_stream_buffer_max_size +player_get_media_stream_buffer_max_size +player_set_media_stream_buffer_min_threshold +player_get_media_stream_buffer_min_threshold +player_push_media_stream +player_start +player_stop +player_unprepare +player_unset_buffering_cb +player_unset_completed_cb +player_unset_error_cb +player_unset_interrupted_cb +player_unset_media_packet_video_frame_decoded_cb +player_unset_subtitle_updated_cb +player_foreach_adaptive_variant +player_set_max_adaptive_variant_limit +player_get_max_adaptive_variant_limit +player_set_audio_only +player_is_audio_only +player_set_streaming_buffering_time +player_get_streaming_buffering_time +radio_create +radio_destroy +radio_get_frequency +radio_get_signal_strength +radio_get_state +radio_get_frequency_range +radio_get_channel_spacing +radio_is_muted +radio_scan_start +radio_scan_stop +radio_seek_down +radio_seek_up +radio_set_frequency +radio_set_interrupted_cb +radio_set_mute +radio_set_scan_completed_cb +radio_start +radio_stop +radio_unset_interrupted_cb +radio_unset_scan_completed_cb +radio_set_volume +radio_get_volume +recorder_attr_get_audio_channel +recorder_attr_get_audio_device +recorder_attr_get_audio_encoder_bitrate +recorder_attr_get_audio_samplerate +recorder_attr_get_orientation_tag +recorder_attr_get_recording_motion_rate +recorder_attr_get_size_limit +recorder_attr_get_time_limit +recorder_attr_get_video_encoder_bitrate +recorder_attr_is_muted +recorder_attr_set_audio_channel +recorder_attr_set_audio_device +recorder_attr_set_audio_encoder_bitrate +recorder_attr_set_audio_samplerate +recorder_attr_set_mute +recorder_attr_set_orientation_tag +recorder_attr_set_recording_motion_rate +recorder_attr_set_size_limit +recorder_attr_set_time_limit +recorder_attr_set_video_encoder_bitrate +recorder_cancel +recorder_commit +recorder_create_audiorecorder +recorder_create_videorecorder +recorder_destroy +recorder_foreach_supported_audio_encoder +recorder_foreach_supported_file_format +recorder_foreach_supported_video_encoder +recorder_foreach_supported_video_resolution +recorder_get_audio_encoder +recorder_get_audio_level +recorder_get_file_format +recorder_get_filename +recorder_get_state +recorder_get_video_encoder +recorder_get_video_resolution +recorder_pause +recorder_prepare +recorder_set_audio_encoder +recorder_set_audio_stream_cb +recorder_set_error_cb +recorder_set_file_format +recorder_set_filename +recorder_set_interrupted_cb +recorder_set_recording_limit_reached_cb +recorder_set_recording_status_cb +recorder_set_state_changed_cb +recorder_set_video_encoder +recorder_set_video_resolution +recorder_set_sound_stream_info +recorder_start +recorder_unprepare +recorder_unset_audio_stream_cb +recorder_unset_error_cb +recorder_unset_interrupted_cb +recorder_unset_recording_limit_reached_cb +recorder_unset_recording_status_cb +recorder_unset_state_changed_cb +recorder_get_device_state +recorder_add_device_state_changed_cb +recorder_remove_device_state_changed_cb +recorder_set_muxed_stream_cb +recorder_unset_muxed_stream_cb +recorder_set_interrupt_started_cb +recorder_unset_interrupt_started_cb +runtime_info_get_value_bool +runtime_info_get_value_double +runtime_info_get_value_int +runtime_info_get_value_string +runtime_info_set_changed_cb +runtime_info_unset_changed_cb +runtime_info_get_system_memory_info +runtime_info_get_process_memory_info +runtime_info_get_cpu_usage +runtime_info_get_process_cpu_usage +runtime_info_get_processor_count +runtime_info_get_processor_current_frequency +runtime_info_get_processor_max_frequency +runtime_info_get_physical_memory_size +runtime_info_app_usage_destroy +runtime_info_app_usage_get_count +runtime_info_app_usage_get_appid +runtime_info_app_usage_get_usage +runtime_info_get_all_apps_memory_usage +runtime_info_get_all_apps_cpu_rate +sensor_create_listener +sensor_destroy_listener +sensor_get_default_sensor +sensor_get_fifo_count +sensor_get_max_batch_count +sensor_get_max_range +sensor_get_min_interval +sensor_get_min_range +sensor_get_name +sensor_get_resolution +sensor_get_sensor_list +sensor_get_type +sensor_get_vendor +sensor_is_supported +sensor_is_wake_up +sensor_listener_read_data +sensor_listener_set_accuracy_cb +sensor_listener_set_event_cb +sensor_listener_set_interval +sensor_listener_set_max_batch_latency +sensor_listener_set_option +sensor_listener_set_attribute_int +sensor_listener_start +sensor_listener_stop +sensor_listener_unset_accuracy_cb +sensor_listener_unset_event_cb +sensor_util_get_angle_change +sensor_util_get_declination +sensor_util_get_inclination +sensor_util_get_orientation +sensor_util_get_rotation_matrix +sensor_util_get_rotation_matrix_from_vector +sensor_util_remap_coordinate_system +sensor_util_get_altitude +sensor_recorder_is_supported +sensor_recorder_start +sensor_recorder_stop +sensor_recorder_create_option +sensor_recorder_destroy_option +sensor_recorder_option_set_int +sensor_recorder_create_query +sensor_recorder_destroy_query +sensor_recorder_query_set_int +sensor_recorder_query_set_time +sensor_recorder_read +sensor_recorder_read_sync +sensor_recorder_data_get_time +sensor_recorder_data_get_int +sensor_recorder_data_get_double +sensor_is_supported_by_uri +sensor_get_default_sensor_by_uri +sensor_get_sensor_list_by_uri +sensor_get_uri +sensor_add_sensor_added_cb +sensor_remove_sensor_added_cb +sensor_add_sensor_removed_cb +sensor_remove_sensor_removed_cb +sensor_create_provider +sensor_add_provider +sensor_remove_provider +sensor_destroy_provider +sensor_provider_set_name +sensor_provider_set_vendor +sensor_provider_set_range +sensor_provider_set_resolution +sensor_provider_set_start_cb +sensor_provider_set_stop_cb +sensor_provider_set_interval_changed_cb +sensor_provider_publish +sound_manager_get_current_sound_type +sound_manager_get_max_volume +sound_manager_get_volume +sound_manager_set_volume +sound_manager_add_volume_changed_cb +sound_manager_remove_volume_changed_cb +sound_manager_get_device_list +sound_manager_get_next_device +sound_manager_get_prev_device +sound_manager_get_device_type +sound_manager_get_device_io_direction +sound_manager_get_device_id +sound_manager_get_device_name +sound_manager_add_device_connection_changed_cb +sound_manager_remove_device_connection_changed_cb +sound_manager_free_device_list +sound_manager_create_stream_information +sound_manager_destroy_stream_information +sound_manager_add_device_for_stream_routing +sound_manager_remove_device_for_stream_routing +sound_manager_remove_all_devices_for_stream_routing +sound_manager_apply_stream_routing +sound_manager_acquire_focus +sound_manager_release_focus +sound_manager_acquire_focus_all +sound_manager_release_focus_all +sound_manager_deliver_focus +sound_manager_set_focus_reacquisition +sound_manager_get_focus_reacquisition +sound_manager_get_focus_state +sound_manager_get_sound_type +sound_manager_add_focus_state_watch_cb +sound_manager_remove_focus_state_watch_cb +sound_manager_get_current_playback_focus +sound_manager_get_current_recording_focus +sound_manager_is_stream_on_device +sound_manager_get_current_media_playback_device_type +system_info_get_custom_bool +system_info_get_custom_double +system_info_get_custom_int +system_info_get_custom_string +system_info_get_platform_bool +system_info_get_platform_double +system_info_get_platform_int +system_info_get_platform_string +system_settings_get_value_bool +system_settings_get_value_int +system_settings_get_value_string +system_settings_set_changed_cb +system_settings_set_value_bool +system_settings_set_value_int +system_settings_set_value_string +system_settings_unset_changed_cb +system_settings_add_value_string +system_settings_delete_value_string +system_settings_foreach_value_string +system_settings_add_changed_cb +system_settings_remove_changed_cb +telephony_call_get_preferred_voice_subscription +telephony_call_get_call_list +telephony_call_release_call_list +telephony_call_get_handle_id +telephony_call_get_number +telephony_call_get_type +telephony_call_get_status +telephony_call_get_direction +telephony_call_get_conference_status +telephony_deinit +telephony_init +telephony_get_state +telephony_set_state_changed_cb +telephony_unset_state_changed_cb +telephony_modem_get_imei +telephony_modem_get_power_status +telephony_network_get_cell_id +telephony_network_get_lac +telephony_network_get_mcc +telephony_network_get_mnc +telephony_network_get_network_name +telephony_network_get_roaming_status +telephony_network_get_rssi +telephony_network_get_service_state +telephony_network_get_type +telephony_network_get_ps_type +telephony_network_get_network_name_option +telephony_network_get_default_data_subscription +telephony_network_get_default_subscription +telephony_network_get_signal_strength +telephony_set_noti_cb +telephony_sim_get_icc_id +telephony_sim_get_msin +telephony_sim_get_operator +telephony_sim_get_spn +telephony_sim_get_state +telephony_sim_get_subscriber_number +telephony_sim_is_changed +telephony_sim_get_subscriber_id +telephony_sim_get_application_list +telephony_unset_noti_cb +telephony_sim_get_lock_state +telephony_sim_get_group_id1 +telephony_sim_get_call_forwarding_indicator_state +telephony_network_get_selection_mode +telephony_network_get_tac +telephony_network_get_system_id +telephony_network_get_network_id +telephony_network_get_base_station_id +telephony_network_get_base_station_latitude +telephony_network_get_base_station_longitude +telephony_modem_get_meid +thumbnail_util_create +thumbnail_util_extract +thumbnail_util_set_path +thumbnail_util_set_size +thumbnail_util_cancel +thumbnail_util_destroy +tone_player_start_new +tone_player_stop +download_add_http_header_field +download_cancel +download_create +download_destroy +download_get_auto_download +download_get_content_name +download_get_content_size +download_get_destination +download_get_downloaded_file_path +download_get_error +download_get_etag +download_get_file_name +download_get_http_header_field +download_get_http_header_field_list +download_get_http_status +download_get_mime_type +download_get_network_type +download_get_notification_app_control +download_get_notification_description +download_get_notification_title +download_get_notification_type +download_get_state +download_get_temp_path +download_get_url +download_pause +download_remove_http_header_field +download_set_auto_download +download_set_destination +download_set_file_name +download_set_network_type +download_set_notification_app_control +download_set_notification_description +download_set_notification_title +download_set_notification_type +download_set_progress_cb +download_set_state_changed_cb +download_set_temp_file_path +download_set_url +download_start +download_unset_progress_cb +download_unset_state_changed_cb +wav_player_start_new +wav_player_stop +wifi_manager_initialize +wifi_manager_deinitialize +wifi_manager_activate +wifi_manager_activate_with_wifi_picker_tested +wifi_manager_deactivate +wifi_manager_is_activated +wifi_manager_get_mac_address +wifi_manager_get_network_interface_name +wifi_manager_scan +wifi_manager_scan_specific_ap +wifi_manager_get_connected_ap +wifi_manager_foreach_found_ap +wifi_manager_foreach_found_specific_ap +wifi_manager_foreach_found_bssid_ap +wifi_manager_bssid_scan +wifi_manager_ap_get_raw_ssid +wifi_manager_connect +wifi_manager_connect_hidden_ap +wifi_manager_disconnect +wifi_manager_connect_by_wps_pbc +wifi_manager_connect_by_wps_pbc_without_ssid +wifi_manager_connect_by_wps_pin +wifi_manager_connect_by_wps_pin_without_ssid +wifi_manager_cancel_wps +wifi_manager_forget_ap +wifi_manager_update_ap +wifi_manager_get_connection_state +wifi_manager_get_scan_state +wifi_manager_get_module_state +wifi_manager_set_device_state_changed_cb +wifi_manager_unset_device_state_changed_cb +wifi_manager_set_background_scan_cb +wifi_manager_unset_background_scan_cb +wifi_manager_set_connection_state_changed_cb +wifi_manager_unset_connection_state_changed_cb +wifi_manager_set_rssi_level_changed_cb +wifi_manager_unset_rssi_level_changed_cb +wifi_manager_set_scan_state_changed_cb +wifi_manager_unset_scan_state_changed_cb +wifi_manager_set_module_state_changed_cb +wifi_manager_unset_module_state_changed_cb +wifi_manager_ap_create +wifi_manager_ap_hidden_create +wifi_manager_ap_destroy +wifi_manager_ap_clone +wifi_manager_ap_refresh +wifi_manager_ap_get_essid +wifi_manager_ap_get_bssid +wifi_manager_ap_get_rssi +wifi_manager_ap_get_rssi_level +wifi_manager_ap_get_frequency +wifi_manager_ap_get_max_speed +wifi_manager_ap_is_favorite +wifi_manager_ap_is_passpoint +wifi_manager_ap_get_connection_state +wifi_manager_ap_get_ip_config_type +wifi_manager_ap_set_ip_config_type +wifi_manager_ap_get_ip_address +wifi_manager_ap_set_ip_address +wifi_manager_ap_get_subnet_mask +wifi_manager_ap_set_subnet_mask +wifi_manager_ap_get_gateway_address +wifi_manager_ap_set_gateway_address +wifi_manager_ap_get_proxy_address +wifi_manager_ap_set_proxy_address +wifi_manager_ap_get_proxy_type +wifi_manager_ap_set_proxy_type +wifi_manager_ap_get_dns_address +wifi_manager_ap_set_dns_address +wifi_manager_ap_get_security_type +wifi_manager_ap_set_security_type +wifi_manager_ap_get_encryption_type +wifi_manager_ap_set_encryption_type +wifi_manager_ap_is_passphrase_required +wifi_manager_ap_set_passphrase +wifi_manager_ap_is_wps_supported +wifi_manager_ap_set_eap_passphrase +wifi_manager_ap_get_eap_passphrase +wifi_manager_ap_get_eap_ca_cert_file +wifi_manager_ap_set_eap_ca_cert_file +wifi_manager_ap_get_eap_client_cert_file +wifi_manager_ap_set_eap_client_cert_file +wifi_manager_ap_get_eap_private_key_file +wifi_manager_ap_set_eap_private_key_info +wifi_manager_ap_get_eap_type +wifi_manager_ap_set_eap_type +wifi_manager_ap_get_eap_auth_type +wifi_manager_ap_set_eap_auth_type +wifi_manager_ap_get_disconnect_reason +wifi_manager_ap_foreach_ipv6_address +wifi_manager_ap_get_dns_config_type +wifi_manager_ap_set_dns_config_type +wifi_manager_ap_get_prefix_length +wifi_manager_ap_set_prefix_length +wifi_manager_ap_get_dhcp_server_address +wifi_manager_ap_get_dhcp_lease_duration +wifi_manager_ap_get_error_state +wifi_manager_config_create +wifi_manager_config_clone +wifi_manager_config_destroy +wifi_manager_config_save +wifi_manager_config_remove +wifi_manager_config_foreach_configuration +wifi_manager_config_get_name +wifi_manager_config_get_security_type +wifi_manager_config_set_proxy_address +wifi_manager_config_get_proxy_address +wifi_manager_config_set_hidden_ap_property +wifi_manager_config_get_hidden_ap_property +wifi_manager_config_get_eap_anonymous_identity +wifi_manager_config_set_eap_anonymous_identity +wifi_manager_config_get_eap_client_cert_file +wifi_manager_config_set_eap_client_cert_file +wifi_manager_config_get_eap_identity +wifi_manager_config_set_eap_identity +wifi_manager_config_get_eap_type +wifi_manager_config_set_eap_type +wifi_manager_config_get_eap_auth_type +wifi_manager_config_set_eap_auth_type +wifi_manager_config_get_eap_subject_match +wifi_manager_config_set_eap_subject_match +wifi_manager_config_get_eap_ca_cert_file +wifi_manager_config_set_eap_ca_cert_file +wifi_manager_tdls_disconnect +wifi_manager_tdls_get_connected_peer +wifi_manager_tdls_set_state_changed_cb +wifi_manager_tdls_unset_state_changed_cb +wifi_manager_tdls_set_discovered_cb +wifi_manager_tdls_unset_discovered_cb +wifi_manager_tdls_start_discovery +wifi_manager_tdls_connect +wifi_manager_tdls_enable_channel_switching +wifi_manager_tdls_disable_channel_switching +wifi_manager_specific_scan_create +wifi_manager_specific_scan_destroy +wifi_manager_specific_scan_set_ssid +wifi_manager_specific_scan_set_freq +wifi_manager_specific_ap_start_multi_scan +bundle_add_byte +bundle_add_str +bundle_add_str_array +bundle_create +bundle_decode +bundle_del +bundle_dup +bundle_encode +bundle_foreach +bundle_free +bundle_get_byte +bundle_get_count +bundle_get_str +bundle_get_str_array +bundle_get_type +bundle_keyval_get_array_val +bundle_keyval_get_basic_val +bundle_keyval_get_type +bundle_keyval_type_is_array +activity_create +activity_get_accuracy +activity_is_supported +activity_release +activity_start_recognition +activity_stop_recognition +gesture_create +gesture_get_event +gesture_get_tilt +gesture_is_supported +gesture_release +gesture_start_recognition +gesture_stop_recognition +contacts_activity_delete_by_account_id +contacts_activity_delete_by_contact_id +contacts_connect +contacts_connect_on_thread +contacts_connect_with_flags +contacts_db_add_changed_cb +contacts_db_add_status_changed_cb +contacts_db_delete_record +contacts_db_delete_records +contacts_db_get_all_records +contacts_db_get_changes_by_version +contacts_db_get_count +contacts_db_get_count_with_query +contacts_db_get_current_version +contacts_db_get_last_change_version +contacts_db_get_record +contacts_db_get_records_with_query +contacts_db_get_status +contacts_db_insert_record +contacts_db_insert_records +contacts_db_remove_changed_cb +contacts_db_remove_status_changed_cb +contacts_db_replace_record +contacts_db_replace_records +contacts_db_search_records +contacts_db_search_records_with_query +contacts_db_search_records_with_range +contacts_db_search_records_for_snippet +contacts_db_search_records_with_range_for_snippet +contacts_db_search_records_with_query_for_snippet +contacts_db_update_record +contacts_db_update_records +contacts_disconnect +contacts_disconnect_on_thread +contacts_filter_add_bool +contacts_filter_add_double +contacts_filter_add_filter +contacts_filter_add_int +contacts_filter_add_lli +contacts_filter_add_operator +contacts_filter_add_str +contacts_filter_create +contacts_filter_destroy +contacts_group_add_contact +contacts_group_remove_contact +contacts_group_set_group_order +contacts_list_add +contacts_list_create +contacts_list_destroy +contacts_list_first +contacts_list_get_count +contacts_list_get_current_record_p +contacts_list_last +contacts_list_next +contacts_list_prev +contacts_list_remove +contacts_person_get_default_property +contacts_person_get_aggregation_suggestions +contacts_person_link_person +contacts_person_reset_usage +contacts_person_set_default_property +contacts_person_set_favorite_order +contacts_person_unlink_contact +contacts_phone_log_reset_statistics +contacts_phone_log_reset_statistics_by_sim +contacts_query_create +contacts_query_destroy +contacts_query_set_distinct +contacts_query_set_filter +contacts_query_set_projection +contacts_query_set_sort +contacts_record_add_child_record +contacts_record_clone +contacts_record_clone_child_record_list +contacts_record_create +contacts_record_destroy +contacts_record_get_bool +contacts_record_get_child_record_at_p +contacts_record_get_child_record_count +contacts_record_get_double +contacts_record_get_int +contacts_record_get_lli +contacts_record_get_str +contacts_record_get_str_p +contacts_record_get_uri_p +contacts_record_remove_child_record +contacts_record_set_bool +contacts_record_set_double +contacts_record_set_int +contacts_record_set_lli +contacts_record_set_str +contacts_setting_add_name_display_order_changed_cb +contacts_setting_add_name_sorting_order_changed_cb +contacts_setting_get_name_display_order +contacts_setting_get_name_sorting_order +contacts_setting_remove_name_display_order_changed_cb +contacts_setting_remove_name_sorting_order_changed_cb +contacts_setting_set_name_display_order +contacts_setting_set_name_sorting_order +contacts_sim_get_initialization_status +contacts_sim_get_initialization_status_by_sim_slot_no +contacts_sim_import_all_contacts +contacts_sim_import_all_contacts_by_sim_slot_no +contacts_vcard_get_entity_count +contacts_vcard_make_from_contact +contacts_vcard_make_from_my_profile +contacts_vcard_make_from_person +contacts_vcard_parse_to_contact_foreach +contacts_vcard_parse_to_contacts +contacts_vcard_get_limit_size_of_photo +contacts_vcard_set_limit_size_of_photo +_contacts_activity +_contacts_activity_photo +_contacts_address +_contacts_address_book +_contacts_company +_contacts_contact +_contacts_contact_activity +_contacts_contact_email +_contacts_contact_email_phonetic_name +_contacts_contact_grouprel +_contacts_contact_number +_contacts_contact_updated_info +_contacts_email +_contacts_emergency +_contacts_event +_contacts_extension +_contacts_group +_contacts_group_member_updated_info +_contacts_group_relation +_contacts_group_updated_info +_contacts_grouprel_updated_info +_contacts_image +_contacts_messenger +_contacts_my_profile +_contacts_my_profile_updated_info +_contacts_name +_contacts_nickname +_contacts_note +_contacts_number +_contacts_person +_contacts_person_business_card +_contacts_person_contact +_contacts_person_email +_contacts_person_group_assigned +_contacts_person_group_not_assigned +_contacts_person_grouprel +_contacts_person_number +_contacts_person_number_fuzzy +_contacts_person_phone_log +_contacts_person_usage +_contacts_phone_log +_contacts_phone_log_duration +_contacts_phone_log_stat +_contacts_profile +_contacts_quick_connect_info +_contacts_relationship +_contacts_sdn +_contacts_simple_contact +_contacts_sip +_contacts_speeddial +_contacts_url +account_connect +account_connect_readonly +account_create +account_delete_from_db_by_id +account_delete_from_db_by_package_name +account_delete_from_db_by_user_name +account_destroy +account_disconnect +account_foreach_account_from_db +account_get_access_token +account_get_account_id +account_get_auth_type +account_get_capability +account_get_capability_all +account_get_custom +account_get_custom_all +account_get_display_name +account_get_domain_name +account_get_email_address +account_get_icon_path +account_get_package_name +account_get_secret +account_get_source +account_get_sync_support +account_get_total_count_from_db +account_get_user_int +account_get_user_name +account_get_user_text +account_insert_to_db +account_query_account_by_account_id +account_query_account_by_capability +account_query_account_by_capability_type +account_query_account_by_package_name +account_query_account_by_user_name +account_query_capability_by_account_id +account_set_access_token +account_set_auth_type +account_set_capability +account_set_custom +account_set_display_name +account_set_domain_name +account_set_email_address +account_set_icon_path +account_set_package_name +account_set_secret +account_set_source +account_set_sync_support +account_set_user_int +account_set_user_name +account_set_user_text +account_subscribe_create +account_subscribe_notification +account_type_create +account_type_destroy +account_type_foreach_account_type_from_db +account_type_get_app_id +account_type_get_icon_path +account_type_get_label +account_type_get_label_by_locale +account_type_get_multiple_account_support +account_type_get_provider_feature_all +account_type_get_service_provider_id +account_type_get_small_icon_path +account_type_query_app_id_exist +account_type_query_by_app_id +account_type_query_by_provider_feature +account_type_query_label_by_app_id +account_type_query_label_by_locale +account_type_query_provider_feature_by_app_id +account_type_query_supported_feature +account_unsubscribe_notification +account_update_sync_status_by_id +account_update_to_db_by_id +account_update_to_db_by_id_ex +account_update_to_db_by_user_name +ckmc_pkcs12_new +ckmc_alias_list_add +ckmc_alias_list_all_free +ckmc_alias_list_free +ckmc_alias_list_new +ckmc_alias_new +ckmc_buffer_free +ckmc_buffer_new +ckmc_cert_free +ckmc_cert_list_add +ckmc_cert_list_all_free +ckmc_cert_list_free +ckmc_cert_list_new +ckmc_cert_new +ckmc_create_key_aes +ckmc_create_key_pair_dsa +ckmc_create_key_pair_ecdsa +ckmc_create_key_pair_rsa +ckmc_create_signature +ckmc_encrypt_data +ckmc_decrypt_data +ckmc_param_list_new +ckmc_param_list_set_integer +ckmc_param_list_set_buffer +ckmc_param_list_get_integer +ckmc_param_list_get_buffer +ckmc_param_list_free +ckmc_generate_new_params +ckmc_get_cert +ckmc_get_cert_alias_list +ckmc_get_cert_chain +ckmc_get_cert_chain_with_trustedcert +ckmc_get_data +ckmc_get_data_alias_list +ckmc_get_key +ckmc_get_key_alias_list +ckmc_get_pkcs12 +ckmc_key_free +ckmc_key_new +ckmc_load_cert_from_file +ckmc_ocsp_check +ckmc_pkcs12_free +ckmc_pkcs12_load +ckmc_remove_alias +ckmc_save_cert +ckmc_save_data +ckmc_save_key +ckmc_save_pkcs12 +ckmc_set_permission +ckmc_verify_signature +ckmc_owner_id_separator +ckmc_owner_id_system +privilege_info_get_description +privilege_info_get_display_name +privilege_info_get_description_by_pkgtype +privilege_info_get_display_name_by_pkgtype +privilege_info_get_privacy_display_name +privilege_info_get_privacy_privilege_status +dlog_print +dlog_vprint +storage_foreach_device_supported +storage_get_available_space +storage_get_directory +storage_get_external_memory_size +storage_get_external_memory_size64 +storage_get_internal_memory_size +storage_get_internal_memory_size64 +storage_get_root_directory +storage_get_state +storage_get_total_space +storage_get_type +storage_set_state_changed_cb +storage_unset_state_changed_cb +storage_set_changed_cb +storage_unset_changed_cb +eext_object_event_callback_add +eext_object_event_callback_del +eext_circle_object_scroller_add +eext_circle_object_scroller_policy_set +eext_circle_object_scroller_policy_get +eext_rotary_object_event_callback_add +eext_rotary_object_event_callback_priority_add +eext_rotary_object_event_callback_del +eext_rotary_event_handler_add +eext_rotary_event_handler_del +eext_rotary_object_event_activated_set +eext_circle_object_item_line_width_set +eext_circle_object_item_line_width_get +eext_circle_object_item_angle_set +eext_circle_object_item_angle_get +eext_circle_object_item_angle_offset_set +eext_circle_object_item_angle_offset_get +eext_circle_object_item_angle_min_max_set +eext_circle_object_item_angle_min_max_get +eext_circle_object_item_value_min_max_set +eext_circle_object_item_value_min_max_get +eext_circle_object_item_value_set +eext_circle_object_item_value_get +eext_circle_object_item_color_set +eext_circle_object_item_color_get +eext_circle_object_item_radius_set +eext_circle_object_item_radius_get +eext_circle_object_line_width_set +eext_circle_object_line_width_get +eext_circle_object_angle_set +eext_circle_object_angle_get +eext_circle_object_angle_offset_set +eext_circle_object_angle_offset_get +eext_circle_object_angle_min_max_set +eext_circle_object_angle_min_max_get +eext_circle_object_value_min_max_set +eext_circle_object_value_min_max_get +eext_circle_object_value_set +eext_circle_object_value_get +eext_circle_object_color_set +eext_circle_object_color_get +eext_circle_object_radius_set +eext_circle_object_radius_get +eext_circle_object_disabled_set +eext_circle_object_disabled_get +eext_circle_object_add +eext_circle_object_genlist_add +eext_circle_object_genlist_scroller_policy_set +eext_circle_object_genlist_scroller_policy_get +eext_circle_object_slider_add +eext_circle_object_slider_step_set +eext_circle_object_slider_step_get +eext_circle_object_datetime_add +eext_circle_object_progressbar_add +eext_circle_surface_conformant_add +eext_circle_surface_layout_add +eext_circle_surface_naviframe_add +eext_circle_surface_del +eext_rotary_selector_add +eext_rotary_selector_item_append +eext_rotary_selector_item_prepend +eext_rotary_selector_item_insert_after +eext_rotary_selector_item_insert_before +eext_rotary_selector_item_del +eext_rotary_selector_items_clear +eext_rotary_selector_item_part_text_set +eext_rotary_selector_item_part_text_get +eext_rotary_selector_item_domain_translatable_part_text_set +eext_rotary_selector_item_part_content_set +eext_rotary_selector_item_part_content_get +eext_rotary_selector_part_content_set +eext_rotary_selector_part_content_get +eext_rotary_selector_item_part_color_set +eext_rotary_selector_item_part_color_get +eext_rotary_selector_part_color_set +eext_rotary_selector_part_color_get +eext_rotary_selector_selected_item_set +eext_rotary_selector_selected_item_get +eext_rotary_selector_items_get +eext_rotary_selector_editing_enabled_get +eext_rotary_selector_editing_enabled_set +eext_rotary_selector_add_item_enabled_get +eext_rotary_selector_add_item_enabled_set +eext_rotary_selector_item_delete_enabled_get +eext_rotary_selector_item_delete_enabled_set +eext_more_option_add +eext_more_option_direction_set +eext_more_option_direction_get +eext_more_option_item_append +eext_more_option_item_prepend +eext_more_option_item_insert_after +eext_more_option_item_insert_before +eext_more_option_item_del +eext_more_option_items_clear +eext_more_option_item_part_text_set +eext_more_option_item_part_text_get +eext_more_option_item_domain_translatable_part_text_set +eext_more_option_item_part_content_set +eext_more_option_item_part_content_get +eext_more_option_opened_set +eext_more_option_opened_get +eext_more_option_items_get +eext_more_option_editing_enabled_get +eext_more_option_editing_enabled_set +eext_more_option_add_item_enabled_get +eext_more_option_add_item_enabled_set +eext_more_option_item_delete_enabled_get +eext_more_option_item_delete_enabled_set +eext_circle_object_spinner_add +eext_circle_object_spinner_angle_set +eext_circle_object_mirrored_set +eext_circle_object_mirrored_get +eext_panel_add +eext_panel_part_content_set +eext_panel_part_content_get +eext_floatingbutton_pos_set +eext_floatingbutton_pos_get +eext_floatingbutton_movement_block_set +eext_floatingbutton_movement_block_get +eext_floatingbutton_add +eext_floatingbutton_mode_set +eext_floatingbutton_mode_get +eext_floatingbutton_pos_bring_in +eext_win_keygrab_set +eext_win_keygrab_unset +tbm_surface_create +tbm_surface_destroy +tbm_surface_get_format +tbm_surface_get_height +tbm_surface_get_info +tbm_surface_get_width +tbm_surface_map +tbm_surface_query_formats +tbm_surface_unmap +stt_create +stt_destroy +stt_foreach_supported_engines +stt_get_engine +stt_set_engine +stt_prepare +stt_unprepare +stt_foreach_supported_languages +stt_get_default_language +stt_get_state +stt_is_recognition_type_supported +stt_set_silence_detection +stt_set_start_sound +stt_unset_start_sound +stt_set_stop_sound +stt_unset_stop_sound +stt_start +stt_stop +stt_cancel +stt_get_recording_volume +stt_foreach_detailed_result +stt_set_recognition_result_cb +stt_unset_recognition_result_cb +stt_set_state_changed_cb +stt_unset_state_changed_cb +stt_set_error_cb +stt_unset_error_cb +stt_set_default_language_changed_cb +stt_unset_default_language_changed_cb +stt_set_credential +stt_get_error_message +stt_set_engine_changed_cb +stt_unset_engine_changed_cb +stt_set_private_data +stt_get_private_data +stte_main +stte_send_result +stte_send_error +stte_send_speech_status +stte_set_private_data_set_cb +stte_set_private_data_requested_cb +tts_create +tts_destroy +tts_set_mode +tts_get_mode +tts_prepare +tts_unprepare +tts_foreach_supported_voices +tts_get_default_voice +tts_get_max_text_size +tts_get_state +tts_get_speed_range +tts_add_text +tts_play +tts_stop +tts_pause +tts_set_state_changed_cb +tts_unset_state_changed_cb +tts_set_utterance_started_cb +tts_unset_utterance_started_cb +tts_set_utterance_completed_cb +tts_unset_utterance_completed_cb +tts_set_error_cb +tts_unset_error_cb +tts_set_default_voice_changed_cb +tts_unset_default_voice_changed_cb +tts_set_credential +tts_set_private_data +tts_get_private_data +tts_get_error_message +tts_set_engine_changed_cb +tts_unset_engine_changed_cb +ttse_main +ttse_get_speed_range +ttse_get_pitch_range +ttse_send_result +ttse_send_error +ttse_set_private_data_set_cb +ttse_set_private_data_requested_cb +csr_cs_context_create +csr_cs_context_destroy +csr_cs_set_ask_user +csr_cs_set_popup_message +csr_cs_set_core_usage +csr_cs_set_scan_on_cloud +csr_cs_scan_data +csr_cs_scan_file +csr_cs_set_file_scanned_cb +csr_cs_set_detected_cb +csr_cs_set_completed_cb +csr_cs_set_cancelled_cb +csr_cs_set_error_cb +csr_cs_scan_files_async +csr_cs_scan_dir_async +csr_cs_scan_dirs_async +csr_cs_cancel_scanning +csr_cs_malware_get_severity +csr_cs_malware_get_name +csr_cs_malware_get_detailed_url +csr_cs_malware_get_timestamp +csr_cs_malware_get_file_name +csr_cs_malware_get_user_response +csr_cs_malware_is_app +csr_cs_malware_get_pkg_id +csr_cs_judge_detected_malware +csr_cs_get_detected_malware +csr_cs_get_detected_malwares +csr_cs_get_ignored_malware +csr_cs_get_ignored_malwares +csr_cs_malware_list_get_malware +csr_wp_context_create +csr_wp_context_destroy +csr_wp_set_ask_user +csr_wp_set_popup_message +csr_wp_check_url +csr_wp_result_get_risk_level +csr_wp_result_get_detailed_url +csr_wp_result_get_user_response +csr_get_current_engine +csr_engine_get_vendor +csr_engine_get_name +csr_engine_get_version +csr_engine_get_data_version +csr_engine_get_latest_update_time +csr_engine_get_activated +csr_engine_set_state +csr_engine_get_state +csr_engine_destroy +nfc_manager_is_supported +nfc_manager_initialize +nfc_manager_deinitialize +nfc_manager_set_activation +nfc_manager_is_activated +nfc_manager_set_activation_changed_cb +nfc_manager_unset_activation_changed_cb +nfc_manager_set_tag_discovered_cb +nfc_manager_unset_tag_discovered_cb +nfc_manager_set_ndef_discovered_cb +nfc_manager_unset_ndef_discovered_cb +nfc_manager_set_p2p_target_discovered_cb +nfc_manager_unset_p2p_target_discovered_cb +nfc_manager_set_se_event_cb +nfc_manager_unset_se_event_cb +nfc_manager_set_se_transaction_event_cb +nfc_manager_unset_se_transaction_event_cb +nfc_manager_enable_transaction_fg_dispatch +nfc_manager_disable_transaction_fg_dispatch +nfc_manager_set_hce_event_cb +nfc_manager_unset_hce_event_cb +nfc_manager_set_se_type +nfc_manager_get_se_type +nfc_manager_set_tag_filter +nfc_manager_get_tag_filter +nfc_manager_get_connected_tag +nfc_manager_get_connected_target +nfc_manager_get_cached_message +nfc_manager_set_system_handler_enable +nfc_manager_is_system_handler_enabled +nfc_hce_send_apdu_response +nfc_ndef_record_create +nfc_ndef_record_create_text +nfc_ndef_record_create_uri +nfc_ndef_record_create_mime +nfc_ndef_record_destroy +nfc_ndef_record_set_id +nfc_ndef_record_get_id +nfc_ndef_record_get_payload +nfc_ndef_record_get_type +nfc_ndef_record_get_tnf +nfc_ndef_record_get_text +nfc_ndef_record_get_langcode +nfc_ndef_record_get_encode_type +nfc_ndef_record_get_uri +nfc_ndef_record_get_mime_type +nfc_ndef_message_create +nfc_ndef_message_create_from_rawdata +nfc_ndef_message_destroy +nfc_ndef_message_get_record_count +nfc_ndef_message_get_rawdata +nfc_ndef_message_append_record +nfc_ndef_message_insert_record +nfc_ndef_message_remove_record +nfc_ndef_message_get_record +nfc_tag_get_type +nfc_tag_is_support_ndef +nfc_tag_get_maximum_ndef_size +nfc_tag_get_ndef_size +nfc_tag_foreach_information +nfc_tag_transceive +nfc_tag_read_ndef +nfc_tag_write_ndef +nfc_tag_format_ndef +nfc_mifare_authenticate_with_keyA +nfc_mifare_authenticate_with_keyB +nfc_mifare_read_block +nfc_mifare_read_page +nfc_mifare_write_block +nfc_mifare_write_page +nfc_mifare_increment +nfc_mifare_decrement +nfc_mifare_transfer +nfc_mifare_restore +nfc_p2p_set_data_received_cb +nfc_p2p_unset_data_received_cb +nfc_p2p_send +nfc_snep_start_server +nfc_snep_start_client +nfc_snep_send_client_request +nfc_snep_stop_service +nfc_snep_register_server +nfc_snep_unregister_server +nfc_se_enable_card_emulation +nfc_se_disable_card_emulation +nfc_se_get_card_emulation_mode +nfc_se_set_default_route +nfc_se_is_activated_handler_for_aid +nfc_se_is_activated_handler_for_category +nfc_se_register_aid +nfc_se_unregister_aid +nfc_se_foreach_registered_aids +nfc_se_set_preferred_handler +nfc_se_unset_preferred_handler +NFC_RECORD_ALTERNATIVE_CARRIER_TYPE +NFC_RECORD_HANDOVER_CARRIER_TYPE +NFC_RECORD_HANDOVER_REQUEST_TYPE +NFC_RECORD_HANDOVER_SELECT_TYPE +NFC_RECORD_SMART_POSTER_TYPE +NFC_RECORD_TEXT_TYPE +NFC_RECORD_URI_TYPE +NFC_TAG_MIFARE_KEY_APPLICATION_DIRECTORY +NFC_TAG_MIFARE_KEY_DEFAULT +NFC_TAG_MIFARE_KEY_NFC_FORUM +notification_clone +notification_create +notification_delete +notification_delete_all +notification_free +notification_get_auto_remove +notification_get_display_applist +notification_get_image +notification_get_insert_time +notification_get_launch_option +notification_get_layout +notification_get_led +notification_get_led_time_period +notification_get_progress +notification_get_property +notification_get_size +notification_get_sound +notification_get_tag +notification_get_text +notification_get_time +notification_get_time_from_text +notification_get_type +notification_get_vibration +notification_load_by_tag +notification_post +notification_set_auto_remove +notification_set_display_applist +notification_set_image +notification_set_launch_option +notification_set_layout +notification_set_led +notification_set_led_time_period +notification_set_progress +notification_set_property +notification_set_size +notification_set_sound +notification_set_tag +notification_set_text +notification_set_text_input +notification_set_time +notification_set_time_to_text +notification_set_vibration +notification_set_event_handler +notification_get_event_handler +notification_get_pkgname +notification_add_button +notification_remove_button +notification_status_message_post +notification_update +notification_save_as_template +notification_create_from_template +notification_get_noti_block_state +notification_set_extension_image_size +notification_get_extension_image_size +alarm_cancel +alarm_cancel_all +alarm_foreach_registered_alarm +alarm_get_app_control +alarm_get_current_time +alarm_get_scheduled_date +alarm_get_scheduled_period +alarm_get_scheduled_recurrence_week_flag +alarm_schedule_after_delay +alarm_schedule_once_after_delay +alarm_schedule_once_at_date +alarm_schedule_with_recurrence_week_flag +alarm_schedule_noti_once_at_date +alarm_schedule_noti_after_delay +alarm_schedule_noti_once_after_delay +alarm_schedule_noti_with_recurrence_week_flag +alarm_get_notification +alarm_set_global +alarm_get_global +alarm_update_delay +alarm_update_date +alarm_update_period +alarm_update_week_flag +app_control_add_extra_data +app_control_add_extra_data_array +app_control_clone +app_control_create +app_control_destroy +app_control_foreach_app_matched +app_control_foreach_extra_data +app_control_get_app_id +app_control_get_caller +app_control_get_category +app_control_get_extra_data +app_control_get_extra_data_array +app_control_get_mime +app_control_get_operation +app_control_get_uri +app_control_get_launch_mode +app_control_is_extra_data_array +app_control_is_reply_requested +app_control_remove_extra_data +app_control_reply_to_launch_request +app_control_send_launch_request +app_control_send_terminate_request +app_control_set_app_id +app_control_set_category +app_control_set_mime +app_control_set_operation +app_control_set_uri +app_control_set_launch_mode +app_control_enable_app_started_result_event +app_get_cache_path +app_get_data_path +app_get_device_orientation +app_get_external_cache_path +app_get_external_data_path +app_get_id +app_get_name +app_get_resource_path +app_get_tep_resource_path +app_get_shared_data_path +app_get_shared_resource_path +app_get_shared_trusted_path +app_get_version +ui_app_main +ui_app_exit +ui_app_add_event_handler +ui_app_remove_event_handler +app_event_get_low_memory_status +app_event_get_low_battery_status +app_event_get_language +app_event_get_region_format +app_event_get_device_orientation +app_event_get_suspended_state +i18n_get_text +preference_foreach_item +preference_get_boolean +preference_get_double +preference_get_int +preference_get_string +preference_is_existing +preference_remove +preference_remove_all +preference_set_boolean +preference_set_changed_cb +preference_set_double +preference_set_int +preference_set_string +preference_unset_changed_cb +app_resource_manager_init +app_resource_manager_get +app_resource_manager_release +app_context_clone +app_context_destroy +app_context_get_app_id +app_context_get_package_id +app_context_get_pid +app_context_get_app_state +app_context_is_equal +app_context_is_terminated +app_context_is_sub_app +app_info_clone +app_info_create +app_info_destroy +app_info_filter_add_bool +app_info_filter_add_string +app_info_filter_count_appinfo +app_info_filter_create +app_info_filter_destroy +app_info_filter_foreach_appinfo +app_info_foreach_metadata +app_info_foreach_category +app_info_get_app_id +app_info_get_exec +app_info_get_icon +app_info_get_label +app_info_get_localed_label +app_info_get_package +app_info_get_type +app_info_get_app_component_type +app_info_is_enabled +app_info_is_equal +app_info_is_nodisplay +app_info_is_onboot +app_info_is_preload +app_info_metadata_filter_add +app_info_metadata_filter_create +app_info_metadata_filter_destroy +app_info_metadata_filter_foreach +app_manager_foreach_app_context +app_manager_foreach_running_app_context +app_manager_foreach_app_info +app_manager_get_app_context +app_manager_get_app_id +app_manager_get_app_info +app_manager_get_shared_data_path +app_manager_get_shared_resource_path +app_manager_get_shared_trusted_path +app_manager_is_running +app_manager_resume_app +app_manager_set_app_context_event_cb +app_manager_unset_app_context_event_cb +app_manager_request_terminate_bg_app +app_manager_event_create +app_manager_event_set_status +app_manager_set_event_cb +app_manager_unset_event_cb +app_manager_event_destroy +bt_adapter_foreach_bonded_device +bt_adapter_free_device_info +bt_adapter_get_address +bt_adapter_get_bonded_device_info +bt_adapter_get_local_oob_data +bt_adapter_get_local_oob_ext_data +bt_adapter_get_name +bt_adapter_get_state +bt_adapter_get_visibility +bt_adapter_is_discovering +bt_adapter_is_service_used +bt_adapter_le_add_advertising_data +bt_adapter_le_clear_advertising_data +bt_adapter_le_create_advertiser +bt_adapter_le_destroy_advertiser +bt_adapter_le_is_discovering +bt_adapter_le_remove_advertising_data +bt_adapter_le_set_device_discovery_state_changed_cb +bt_adapter_le_set_scan_mode +bt_adapter_le_start_advertising +bt_adapter_le_stop_advertising +bt_adapter_le_start_device_discovery +bt_adapter_le_stop_device_discovery +bt_adapter_le_unset_device_discovery_state_changed_cb +bt_adapter_remove_remote_oob_data +bt_adapter_set_remote_oob_ext_data +bt_adapter_set_device_discovery_state_changed_cb +bt_adapter_set_name +bt_adapter_set_name_changed_cb +bt_adapter_set_remote_oob_data +bt_adapter_set_state_changed_cb +bt_adapter_set_visibility_duration_changed_cb +bt_adapter_set_visibility_mode_changed_cb +bt_adapter_start_device_discovery +bt_adapter_stop_device_discovery +bt_adapter_unset_device_discovery_state_changed_cb +bt_adapter_unset_name_changed_cb +bt_adapter_unset_state_changed_cb +bt_adapter_unset_visibility_duration_changed_cb +bt_adapter_unset_visibility_mode_changed_cb +bt_adapter_le_start_scan +bt_adapter_le_stop_scan +bt_adapter_le_get_scan_result_service_uuids +bt_adapter_le_get_scan_result_device_name +bt_adapter_le_get_scan_result_tx_power_level +bt_adapter_le_get_scan_result_service_solicitation_uuids +bt_adapter_le_get_scan_result_service_data_list +bt_adapter_le_free_service_data_list +bt_adapter_le_get_scan_result_appearance +bt_adapter_le_get_scan_result_manufacturer_data +bt_adapter_le_add_advertising_service_uuid +bt_adapter_le_add_advertising_service_solicitation_uuid +bt_adapter_le_add_advertising_service_data +bt_adapter_le_set_advertising_appearance +bt_adapter_le_add_advertising_manufacturer_data +bt_adapter_le_set_advertising_device_name +bt_adapter_le_set_advertising_tx_power_level +bt_adapter_le_start_advertising_new +bt_adapter_le_set_advertising_mode +bt_adapter_le_set_advertising_connectable +bt_adapter_le_scan_filter_create +bt_adapter_le_scan_filter_destroy +bt_adapter_le_scan_filter_set_device_address +bt_adapter_le_scan_filter_set_device_name +bt_adapter_le_scan_filter_set_service_uuid +bt_adapter_le_scan_filter_set_service_uuid_with_mask +bt_adapter_le_scan_filter_set_service_solicitation_uuid +bt_adapter_le_scan_filter_set_service_solicitation_uuid_with_mask +bt_adapter_le_scan_filter_set_service_data +bt_adapter_le_scan_filter_set_service_data_with_mask +bt_adapter_le_scan_filter_set_manufacturer_data +bt_adapter_le_scan_filter_set_manufacturer_data_with_mask +bt_adapter_le_scan_filter_set_type +bt_adapter_le_scan_filter_register +bt_adapter_le_scan_filter_unregister +bt_adapter_le_scan_filter_unregister_all +bt_adapter_le_get_scan_result_ibeacon_report +bt_adapter_le_free_ibeacon_report +bt_audio_connect +bt_audio_deinitialize +bt_audio_disconnect +bt_audio_initialize +bt_audio_set_connection_state_changed_cb +bt_audio_unset_connection_state_changed_cb +bt_avrcp_set_equalizer_state_changed_cb +bt_avrcp_set_repeat_mode_changed_cb +bt_avrcp_set_scan_mode_changed_cb +bt_avrcp_set_shuffle_mode_changed_cb +bt_avrcp_target_deinitialize +bt_avrcp_target_initialize +bt_avrcp_target_notify_equalizer_state +bt_avrcp_target_notify_player_state +bt_avrcp_target_notify_position +bt_avrcp_target_notify_repeat_mode +bt_avrcp_target_notify_scan_mode +bt_avrcp_target_notify_shuffle_mode +bt_avrcp_target_notify_track +bt_avrcp_unset_equalizer_state_changed_cb +bt_avrcp_unset_repeat_mode_changed_cb +bt_avrcp_unset_scan_mode_changed_cb +bt_avrcp_unset_shuffle_mode_changed_cb +bt_avrcp_control_initialize +bt_avrcp_control_deinitialize +bt_avrcp_control_connect +bt_avrcp_control_disconnect +bt_avrcp_control_send_player_command +bt_avrcp_control_set_equalizer_state +bt_avrcp_control_set_repeat_mode +bt_avrcp_control_set_shuffle_mode +bt_avrcp_control_set_scan_mode +bt_avrcp_control_get_equalizer_state +bt_avrcp_control_get_repeat_mode +bt_avrcp_control_get_shuffle_mode +bt_avrcp_control_get_scan_mode +bt_avrcp_control_get_position +bt_avrcp_control_get_play_status +bt_avrcp_control_get_track_info +bt_avrcp_control_free_track_info +bt_avrcp_set_position_changed_cb +bt_avrcp_unset_position_changed_cb +bt_avrcp_set_play_status_changed_cb +bt_avrcp_unset_play_status_changed_cb +bt_avrcp_set_track_info_changed_cb +bt_avrcp_unset_track_info_changed_cb +bt_deinitialize +bt_device_cancel_bonding +bt_device_create_bond +bt_device_destroy_bond +bt_device_foreach_connected_profiles +bt_device_get_service_mask_from_uuid_list +bt_device_is_profile_connected +bt_device_set_alias +bt_device_set_authorization +bt_device_set_authorization_changed_cb +bt_device_set_bond_created_cb +bt_device_set_bond_destroyed_cb +bt_device_set_connection_state_changed_cb +bt_device_set_service_searched_cb +bt_device_start_service_search +bt_device_unset_authorization_changed_cb +bt_device_unset_bond_created_cb +bt_device_unset_bond_destroyed_cb +bt_device_unset_connection_state_changed_cb +bt_device_unset_service_searched_cb +bt_device_update_le_connection_mode +bt_gatt_clone_attribute_handle +bt_gatt_connect +bt_gatt_destroy_attribute_handle +bt_gatt_disconnect +bt_gatt_discover_characteristic_descriptor +bt_gatt_discover_characteristics +bt_gatt_foreach_included_services +bt_gatt_foreach_primary_services +bt_gatt_get_characteristic_declaration +bt_gatt_get_service_uuid +bt_gatt_read_characteristic_value +bt_gatt_set_characteristic_changed_cb +bt_gatt_set_characteristic_value +bt_gatt_set_characteristic_value_request +bt_gatt_set_connection_state_changed_cb +bt_gatt_unset_characteristic_changed_cb +bt_gatt_unset_connection_state_changed_cb +bt_gatt_unwatch_characteristic_changes +bt_gatt_watch_characteristic_changes +bt_gatt_get_value +bt_gatt_get_int_value +bt_gatt_get_float_value +bt_gatt_set_value +bt_gatt_set_int_value +bt_gatt_set_float_value +bt_gatt_get_uuid +bt_gatt_get_type +bt_gatt_service_get_client +bt_gatt_service_get_characteristic +bt_gatt_service_foreach_characteristics +bt_gatt_service_get_included_service +bt_gatt_service_foreach_included_services +bt_gatt_characteristic_get_service +bt_gatt_characteristic_get_properties +bt_gatt_characteristic_get_write_type +bt_gatt_characteristic_set_write_type +bt_gatt_characteristic_get_descriptor +bt_gatt_characteristic_foreach_descriptors +bt_gatt_descriptor_get_characteristic +bt_gatt_client_create +bt_gatt_client_destroy +bt_gatt_client_get_remote_address +bt_gatt_client_read_value +bt_gatt_client_write_value +bt_gatt_client_set_characteristic_value_changed_cb +bt_gatt_client_unset_characteristic_value_changed_cb +bt_gatt_client_get_service +bt_gatt_client_foreach_services +bt_gatt_client_set_service_changed_cb +bt_gatt_client_unset_service_changed_cb +bt_gatt_client_get_att_mtu +bt_gatt_client_set_att_mtu_changed_cb +bt_gatt_client_unset_att_mtu_changed_cb +bt_gatt_client_request_att_mtu_change +bt_gatt_service_destroy +bt_gatt_characteristic_destroy +bt_gatt_descriptor_destroy +bt_gatt_characteristic_get_permissions +bt_gatt_descriptor_get_permissions +bt_gatt_service_create +bt_gatt_service_add_characteristic +bt_gatt_service_add_included_service +bt_gatt_service_get_server +bt_gatt_characteristic_create +bt_gatt_characteristic_add_descriptor +bt_gatt_descriptor_create +bt_gatt_server_initialize +bt_gatt_server_deinitialize +bt_gatt_server_create +bt_gatt_server_destroy +bt_gatt_server_set_read_value_requested_cb +bt_gatt_server_set_characteristic_notification_state_change_cb +bt_gatt_server_set_write_value_requested_cb +bt_gatt_server_notify_characteristic_changed_value +bt_gatt_server_get_service +bt_gatt_server_foreach_services +bt_gatt_server_register_service +bt_gatt_server_unregister_service +bt_gatt_server_unregister_all_services +bt_gatt_server_start +bt_gatt_server_send_response +bt_hdp_connect_to_source +bt_hdp_disconnect +bt_hdp_register_sink_app +bt_hdp_send_data +bt_hdp_set_connection_state_changed_cb +bt_hdp_set_data_received_cb +bt_hdp_unregister_sink_app +bt_hdp_unset_connection_state_changed_cb +bt_hdp_unset_data_received_cb +bt_hid_host_connect +bt_hid_host_deinitialize +bt_hid_host_disconnect +bt_hid_host_initialize +bt_hid_device_activate +bt_hid_device_deactivate +bt_hid_device_connect +bt_hid_device_disconnect +bt_hid_device_send_mouse_event +bt_hid_device_send_key_event +bt_hid_device_set_data_received_cb +bt_hid_device_unset_data_received_cb +bt_hid_device_reply_to_report +bt_initialize +bt_opp_client_add_file +bt_opp_client_cancel_push +bt_opp_client_clear_files +bt_opp_client_deinitialize +bt_opp_client_initialize +bt_opp_client_push_files +bt_opp_server_accept +bt_opp_server_cancel_transfer +bt_opp_server_deinitialize +bt_opp_server_initialize_by_connection_request +bt_opp_server_reject +bt_opp_server_set_destination +bt_socket_connect_rfcomm +bt_socket_create_rfcomm +bt_socket_destroy_rfcomm +bt_socket_disconnect_rfcomm +bt_socket_listen_and_accept_rfcomm +bt_socket_send_data +bt_socket_set_connection_requested_cb +bt_socket_set_connection_state_changed_cb +bt_socket_set_data_received_cb +bt_socket_unset_connection_requested_cb +bt_socket_unset_connection_state_changed_cb +bt_socket_unset_data_received_cb +bt_pbap_client_initialize +bt_pbap_client_deinitialize +bt_pbap_client_set_connection_state_changed_cb +bt_pbap_client_unset_connection_state_changed_cb +bt_pbap_client_connect +bt_pbap_client_disconnect +bt_pbap_client_get_phone_book_size +bt_pbap_client_get_phone_book +bt_pbap_client_get_list +bt_pbap_client_pull_vcard +bt_pbap_client_search_phone_book +bt_get_uuid_name +bt_ipsp_initialize +bt_ipsp_deinitialize +bt_ipsp_set_connection_state_changed_cb +bt_ipsp_unset_connection_state_changed_cb +bt_ipsp_connect +bt_ipsp_disconnect +video_util_cancel_transcoding +video_util_create +video_util_destroy +video_util_foreach_supported_audio_codec +video_util_foreach_supported_file_format +video_util_foreach_supported_video_codec +video_util_get_progress_transcoding +video_util_set_accurate_mode +video_util_set_audio_codec +video_util_set_file_format +video_util_set_file_path +video_util_set_fps +video_util_set_resolution +video_util_set_video_codec +video_util_start_transcoding +service_app_exit +service_app_main +service_app_add_event_handler +service_app_remove_event_handler +badge_get_count +badge_get_display +badge_add +badge_register_changed_cb +badge_remove +badge_set_count +badge_set_display +badge_unregister_changed_cb +badge_foreach +shortcut_add_to_home +shortcut_add_to_home_widget +shortcut_set_request_cb +shortcut_get_list +shortcut_set_remove_cb +shortcut_unset_request_cb +shortcut_unset_remove_cb +shortcut_remove_from_home +push_service_app_control_to_noti_data +push_service_connect +push_service_deregister +push_service_disconnect +push_service_free_notification +push_service_get_notification_data +push_service_get_notification_message +push_service_get_notification_time +push_service_get_registration_id +push_service_get_unread_notification +push_service_register +push_service_request_unread_notification +push_service_app_control_to_notification +push_service_get_notification_sender +push_service_get_notification_session_info +push_service_get_notification_request_id +push_service_get_notification_type +calendar_connect +calendar_connect_on_thread +calendar_connect_with_flags +calendar_db_add_changed_cb +calendar_db_delete_record +calendar_db_delete_records +calendar_db_get_all_records +calendar_db_get_changes_by_version +calendar_db_get_changes_exception_by_version +calendar_db_get_count +calendar_db_get_count_with_query +calendar_db_get_current_version +calendar_db_get_last_change_version +calendar_db_get_record +calendar_db_get_records_with_query +calendar_db_insert_record +calendar_db_insert_records +calendar_db_insert_vcalendars +calendar_db_remove_changed_cb +calendar_db_replace_record +calendar_db_replace_records +calendar_db_replace_vcalendars +calendar_db_update_record +calendar_db_update_records +calendar_db_link_record +calendar_db_unlink_record +calendar_disconnect +calendar_disconnect_on_thread +calendar_filter_add_caltime +calendar_filter_add_double +calendar_filter_add_filter +calendar_filter_add_int +calendar_filter_add_lli +calendar_filter_add_operator +calendar_filter_add_str +calendar_filter_create +calendar_filter_destroy +calendar_list_add +calendar_list_create +calendar_list_destroy +calendar_list_first +calendar_list_get_count +calendar_list_get_current_record_p +calendar_list_last +calendar_list_next +calendar_list_prev +calendar_list_remove +calendar_query_create +calendar_query_destroy +calendar_query_set_distinct +calendar_query_set_filter +calendar_query_set_projection +calendar_query_set_sort +calendar_record_add_child_record +calendar_record_clone +calendar_record_clone_child_record_list +calendar_record_create +calendar_record_destroy +calendar_record_get_caltime +calendar_record_get_child_record_at_p +calendar_record_get_child_record_count +calendar_record_get_double +calendar_record_get_int +calendar_record_get_lli +calendar_record_get_str +calendar_record_get_str_p +calendar_record_get_uri_p +calendar_record_remove_child_record +calendar_record_set_caltime +calendar_record_set_double +calendar_record_set_int +calendar_record_set_lli +calendar_record_set_str +calendar_reminder_add_cb +calendar_reminder_remove_cb +calendar_vcalendar_make_from_records +calendar_vcalendar_parse_to_calendar +calendar_vcalendar_parse_to_calendar_foreach +calendar_db_clean_after_sync +_calendar_alarm +_calendar_attendee +_calendar_book +_calendar_event +_calendar_event_calendar_book +_calendar_event_calendar_book_attendee +_calendar_extended_property +_calendar_instance_localtime_calendar_book +_calendar_instance_localtime_calendar_book_extended +_calendar_instance_utime_calendar_book +_calendar_instance_utime_calendar_book_extended +_calendar_timezone +_calendar_todo +_calendar_todo_calendar_book +_calendar_updated_info +ewk_autofill_profile_data_get +ewk_autofill_profile_data_set +ewk_autofill_profile_delete +ewk_autofill_profile_id_get +ewk_autofill_profile_new +ewk_back_forward_list_count +ewk_back_forward_list_current_item_get +ewk_back_forward_list_item_at_index_get +ewk_back_forward_list_item_original_url_get +ewk_back_forward_list_item_ref +ewk_back_forward_list_item_title_get +ewk_back_forward_list_item_unref +ewk_back_forward_list_item_url_get +ewk_back_forward_list_n_back_items_copy +ewk_back_forward_list_n_forward_items_copy +ewk_back_forward_list_next_item_get +ewk_back_forward_list_previous_item_get +ewk_context_cache_model_get +ewk_context_cache_model_set +ewk_context_cookie_manager_get +ewk_context_menu_item_append +ewk_context_menu_item_append_as_action +ewk_context_menu_item_count +ewk_context_menu_item_image_url_get +ewk_context_menu_item_link_url_get +ewk_context_menu_item_remove +ewk_context_menu_item_tag_get +ewk_context_menu_nth_item_get +ewk_context_resource_cache_clear +ewk_context_application_cache_delete_all +ewk_context_form_autofill_profile_add +ewk_context_form_autofill_profile_get +ewk_context_form_autofill_profile_get_all +ewk_context_form_autofill_profile_remove +ewk_context_form_autofill_profile_set +ewk_context_form_candidate_data_delete_all +ewk_context_form_password_data_delete_all +ewk_context_icon_database_icon_object_add +ewk_context_web_indexed_database_delete_all +ewk_context_web_storage_delete_all +ewk_context_background_music_get +ewk_context_background_music_set +ewk_context_block_multimedia_on_call_get +ewk_context_block_multimedia_on_call_set +ewk_context_rotation_lock_get +ewk_context_rotation_lock_set +ewk_context_sound_overlap_get +ewk_context_sound_overlap_set +ewk_cookie_manager_accept_policy_async_get +ewk_cookie_manager_accept_policy_set +ewk_cookie_manager_cookies_clear +ewk_cookie_manager_file_scheme_cookies_allow_get +ewk_cookie_manager_file_scheme_cookies_allow_set +ewk_cookie_manager_persistent_storage_set +ewk_init +ewk_policy_decision_cookie_get +ewk_policy_decision_host_get +ewk_policy_decision_http_method_get +ewk_policy_decision_ignore +ewk_policy_decision_navigation_type_get +ewk_policy_decision_response_headers_get +ewk_policy_decision_response_mime_get +ewk_policy_decision_response_status_code_get +ewk_policy_decision_scheme_get +ewk_policy_decision_type_get +ewk_policy_decision_url_get +ewk_policy_decision_use +ewk_settings_auto_fitting_get +ewk_settings_auto_fitting_set +ewk_settings_default_font_size_get +ewk_settings_default_font_size_set +ewk_settings_default_text_encoding_name_get +ewk_settings_default_text_encoding_name_set +ewk_settings_javascript_enabled_get +ewk_settings_javascript_enabled_set +ewk_settings_loads_images_automatically_get +ewk_settings_loads_images_automatically_set +ewk_settings_scripts_can_open_windows_get +ewk_settings_scripts_can_open_windows_set +ewk_settings_form_candidate_data_enabled_set +ewk_settings_form_profile_data_enabled_set +ewk_settings_autofill_password_form_enabled_set +ewk_shutdown +ewk_view_add +ewk_view_add_in_incognito_mode +ewk_view_back +ewk_view_back_forward_list_clear +ewk_view_back_forward_list_get +ewk_view_back_possible +ewk_view_html_string_load +ewk_view_contents_set +ewk_view_contents_size_get +ewk_view_context_get +ewk_view_forward +ewk_view_forward_possible +ewk_view_fullscreen_exit +ewk_view_load_progress_get +ewk_view_reload +ewk_view_resume +ewk_view_scale_get +ewk_view_scale_set +ewk_view_script_execute +ewk_view_scroll_by +ewk_view_scroll_pos_get +ewk_view_scroll_set +ewk_view_settings_get +ewk_view_stop +ewk_view_suspend +ewk_view_text_find +ewk_view_title_get +ewk_view_url_get +ewk_view_url_request_set +ewk_view_url_set +ewk_view_user_agent_get +ewk_view_user_agent_set +ewk_view_orientation_send +ewk_view_text_selection_clear +ewk_view_text_selection_text_get +ewk_view_visibility_set +ewk_view_javascript_message_handler_add +ewk_view_evaluate_javascript +ewk_context_intercept_request_callback_set +ewk_view_focus_set +ewk_view_focus_get +ewk_view_original_url_get +ewk_intercept_request_url_get +ewk_intercept_request_http_method_get +ewk_intercept_request_headers_get +ewk_intercept_request_ignore +ewk_intercept_request_response_set +ewk_intercept_request_response_status_set +ewk_intercept_request_response_header_add +ewk_intercept_request_response_header_map_add +ewk_intercept_request_response_body_set +ewk_intercept_request_response_write_chunk +ewk_error_url_get +ewk_error_code_get +ewk_error_description_get +ewk_error_cancellation_get +ewk_geolocation_permission_request_origin_get +ewk_security_origin_host_get +ewk_security_origin_protocol_get +ewk_view_request_manifest +ewk_manifest_short_name_get +ewk_manifest_name_get +ewk_manifest_start_url_get +ewk_manifest_orientation_type_get +ewk_manifest_web_display_mode_get +ewk_manifest_theme_color_get +ewk_manifest_background_color_get +ewk_manifest_icons_count_get +ewk_manifest_icons_src_get +ewk_manifest_icons_type_get +ewk_manifest_icons_sizes_count_get +ewk_manifest_icons_width_get +ewk_manifest_icons_height_get +wifi_direct_unset_service_state_changed_cb +wifi_direct_unset_peer_found_cb +wifi_direct_unset_discovery_state_changed_cb +wifi_direct_unset_device_state_changed_cb +wifi_direct_unset_connection_state_changed_cb +wifi_direct_unset_client_ip_address_assigned_cb +wifi_direct_start_discovery_specific_channel +wifi_direct_start_discovery +wifi_direct_set_wps_pin +wifi_direct_set_service_state_changed_cb +wifi_direct_set_req_wps_type +wifi_direct_set_persistent_group_enabled +wifi_direct_set_peer_found_cb +wifi_direct_set_max_clients +wifi_direct_set_group_owner_intent +wifi_direct_set_discovery_state_changed_cb +wifi_direct_set_device_state_changed_cb +wifi_direct_set_device_name +wifi_direct_set_connection_state_changed_cb +wifi_direct_set_client_ip_address_assigned_cb +wifi_direct_set_autoconnection_mode +wifi_direct_remove_persistent_group +wifi_direct_is_persistent_group_enabled +wifi_direct_is_listening_only +wifi_direct_is_group_owner +wifi_direct_is_discoverable +wifi_direct_is_autonomous_group +wifi_direct_is_autoconnection_mode +wifi_direct_initialize +wifi_direct_init_miracast +wifi_direct_get_wps_pin +wifi_direct_get_supported_wps_mode +wifi_direct_get_subnet_mask +wifi_direct_get_state +wifi_direct_get_ssid +wifi_direct_get_secondary_device_type +wifi_direct_get_req_wps_type +wifi_direct_get_primary_device_type +wifi_direct_get_peer_info +wifi_direct_get_peer_rssi +wifi_direct_get_operating_channel +wifi_direct_get_network_interface_name +wifi_direct_get_max_clients +wifi_direct_get_mac_address +wifi_direct_get_local_wps_type +wifi_direct_get_ip_address +wifi_direct_get_group_owner_intent +wifi_direct_get_gateway_address +wifi_direct_get_device_name +wifi_direct_foreach_supported_wps_types +wifi_direct_foreach_persistent_groups +wifi_direct_foreach_discovered_peers +wifi_direct_foreach_connected_peers +wifi_direct_disconnect_all +wifi_direct_disconnect +wifi_direct_destroy_group +wifi_direct_register_service +wifi_direct_deregister_service +wifi_direct_deinitialize +wifi_direct_deactivate +wifi_direct_create_group +wifi_direct_connect +wifi_direct_cancel_service_discovery +wifi_direct_start_service_discovery +wifi_direct_cancel_discovery +wifi_direct_cancel_connection +wifi_direct_activate_pushbutton +wifi_direct_activate +wifi_direct_init_display +wifi_direct_deinit_display +wifi_direct_set_display +wifi_direct_set_display_availability +wifi_direct_get_peer_display_availability +wifi_direct_get_peer_display_type +wifi_direct_get_peer_display_hdcp +wifi_direct_get_peer_display_port +wifi_direct_get_peer_display_throughput +wifi_direct_set_autoconnection_peer +wifi_direct_set_passphrase +wifi_direct_get_passphrase +wifi_direct_set_auto_group_removal +wifi_direct_set_session_timer +wifi_direct_get_session_timer +wifi_direct_set_state_changed_cb +wifi_direct_unset_state_changed_cb +wifi_direct_start_discovery_specific_freq +wifi_direct_add_vsie +wifi_direct_get_vsie +wifi_direct_remove_vsie +wifi_direct_get_connecting_peer_info +smartcard_get_readers +smartcard_reader_get_name +smartcard_reader_is_secure_element_present +smartcard_session_get_reader +smartcard_session_is_closed +smartcard_channel_is_basic_channel +smartcard_channel_is_closed +smartcard_channel_get_select_response +smartcard_channel_get_session +smartcard_channel_transmit_retrieve_response +smartcard_initialize +smartcard_deinitialize +smartcard_reader_open_session +smartcard_reader_close_sessions +smartcard_session_get_atr +smartcard_session_close +smartcard_session_close_channels +smartcard_session_open_basic_channel +smartcard_session_open_logical_channel +smartcard_channel_close +smartcard_channel_transmit +smartcard_channel_select_next +smartcard_get_version +smartcard_reader_set_event_cb +smartcard_reader_unset_event_cb +oauth2_error_get_code +oauth2_error_get_description +oauth2_error_get_uri +oauth2_error_get_custom_data +oauth2_manager_create +oauth2_manager_destroy +oauth2_manager_request_token +oauth2_manager_request_authorization_grant +oauth2_manager_request_access_token +oauth2_manager_refresh_access_token +oauth2_manager_is_request_in_progress +oauth2_manager_clear_cookies +oauth2_manager_clear_cache +oauth2_request_create +oauth2_request_destroy +oauth2_request_set_auth_end_point_url +oauth2_request_set_token_end_point_url +oauth2_request_set_redirection_url +oauth2_request_set_refresh_token_url +oauth2_request_set_refresh_token +oauth2_request_set_response_type +oauth2_request_set_client_id +oauth2_request_set_client_secret +oauth2_request_set_client_authentication_type +oauth2_request_set_scope +oauth2_request_set_state +oauth2_request_set_grant_type +oauth2_request_set_authorization_code +oauth2_request_set_user_name +oauth2_request_set_password +oauth2_request_add_custom_data +oauth2_request_get_auth_end_point_url +oauth2_request_get_token_end_point_url +oauth2_request_get_redirection_url +oauth2_request_get_refresh_token_url +oauth2_request_get_refresh_token +oauth2_request_get_response_type +oauth2_request_get_client_id +oauth2_request_get_client_secret +oauth2_request_get_scope +oauth2_request_get_state +oauth2_request_get_grant_type +oauth2_request_get_authorization_code +oauth2_request_get_user_name +oauth2_request_get_password +oauth2_request_get_custom_data +oauth2_response_destroy +oauth2_response_get_authorization_code +oauth2_response_get_state +oauth2_response_get_access_token +oauth2_response_get_token_type +oauth2_response_get_expires_in +oauth2_response_get_refresh_token +oauth2_response_get_scope +oauth2_response_get_error +oauth2_response_get_custom_data +geofence_manager_is_supported +geofence_manager_create +geofence_manager_destroy +geofence_manager_start +geofence_manager_stop +geofence_manager_add_place +geofence_manager_update_place +geofence_manager_remove_place +geofence_manager_add_fence +geofence_manager_remove_fence +geofence_manager_set_geofence_state_changed_cb +geofence_manager_unset_geofence_state_changed_cb +geofence_manager_set_geofence_proximity_state_changed_cb +geofence_manager_unset_geofence_proximity_state_changed_cb +geofence_manager_foreach_geofence_list +geofence_manager_foreach_place_geofence_list +geofence_manager_foreach_place_list +geofence_manager_get_place_name +geofence_create_geopoint +geofence_create_bluetooth +geofence_create_wifi +geofence_destroy +geofence_get_type +geofence_get_place_id +geofence_get_latitude +geofence_get_longitude +geofence_get_radius +geofence_get_bssid +geofence_status_create +geofence_status_destroy +geofence_status_get_state +geofence_status_get_duration +geofence_manager_set_geofence_event_cb +geofence_manager_unset_geofence_event_cb +geofence_get_address +geofence_get_ssid +context_history_create +context_history_destroy +context_history_filter_create +context_history_filter_destroy +context_history_filter_set_int +context_history_filter_set_string +context_history_get_list +context_history_list_get_count +context_history_list_get_current +context_history_list_move_first +context_history_list_move_next +context_history_list_destroy +context_history_record_get_int +context_history_record_get_double +context_history_record_get_string +context_history_record_destroy +context_history_is_supported +context_trigger_add_rule +context_trigger_remove_rule +context_trigger_enable_rule +context_trigger_disable_rule +context_trigger_get_own_rule_ids +context_trigger_get_rule_by_id +context_trigger_rule_create +context_trigger_rule_destroy +context_trigger_rule_add_entry +context_trigger_rule_set_action_app_control +context_trigger_rule_set_action_notification +context_trigger_rule_set_description +context_trigger_rule_get_description +context_trigger_rule_event_create +context_trigger_rule_event_is_supported +context_trigger_rule_condition_create +context_trigger_rule_condition_is_supported +context_trigger_rule_entry_destroy +context_trigger_rule_entry_add_key +context_trigger_rule_entry_add_comparison_int +context_trigger_rule_entry_add_comparison_string +context_trigger_rule_entry_add_option_int +context_trigger_rule_entry_add_option_string +context_trigger_rule_entry_add_option +context_trigger_rule_entry_add_comparison +context_trigger_custom_register +context_trigger_custom_unregister +context_trigger_custom_publish +context_trigger_rule_custom_event_create +context_trigger_rule_custom_condition_create +phone_number_connect +phone_number_disconnect +phone_number_get_location_from_number +phone_number_get_formatted_number +phone_number_get_normalized_number +phone_number_add_blocking_rule +phone_number_remove_blocking_rule +phone_number_get_blocking_rules +phone_number_get_blocking_rules_related +phone_number_check_blocking +phone_number_blocking_rule_create +phone_number_blocking_rule_destroy +phone_number_blocking_rule_get_number +phone_number_blocking_rule_get_match_type +phone_number_blocking_rule_set_number +phone_number_blocking_rule_set_match_type +feedback_initialize +feedback_deinitialize +feedback_play +feedback_play_type +feedback_stop +feedback_is_supported_pattern +scmirroring_sink_create +scmirroring_sink_set_state_changed_cb +scmirroring_sink_prepare +scmirroring_sink_set_ip_and_port +scmirroring_sink_set_display +scmirroring_sink_set_resolution +scmirroring_sink_connect +scmirroring_sink_start +scmirroring_sink_pause +scmirroring_sink_resume +scmirroring_sink_disconnect +scmirroring_sink_unprepare +scmirroring_sink_unset_state_changed_cb +scmirroring_sink_destroy +scmirroring_sink_get_negotiated_video_codec +scmirroring_sink_get_negotiated_video_resolution +scmirroring_sink_get_negotiated_video_frame_rate +scmirroring_sink_get_negotiated_audio_codec +scmirroring_sink_get_negotiated_audio_channel +scmirroring_sink_get_negotiated_audio_sample_rate +scmirroring_sink_get_negotiated_audio_bitwidth +maps_address_clone +maps_address_create +maps_address_destroy +maps_address_get_building_number +maps_address_get_city +maps_address_get_country +maps_address_get_country_code +maps_address_get_county +maps_address_get_district +maps_address_get_freetext +maps_address_get_postal_code +maps_address_get_state +maps_address_get_street +maps_address_set_building_number +maps_address_set_city +maps_address_set_country +maps_address_set_country_code +maps_address_set_county +maps_address_set_district +maps_address_set_freetext +maps_address_set_postal_code +maps_address_set_state +maps_address_set_street +maps_address_list_create +maps_address_list_append +maps_address_list_remove +maps_address_list_get_length +maps_address_list_foreach +maps_address_list_destroy +maps_area_clone +maps_area_create_circle +maps_area_create_rectangle +maps_area_destroy +maps_coordinates_clone +maps_coordinates_create +maps_coordinates_destroy +maps_coordinates_get_latitude +maps_coordinates_get_longitude +maps_coordinates_set_latitude +maps_coordinates_set_longitude +maps_coordinates_set_latitude_longitude +maps_coordinates_get_latitude_longitude +maps_coordinates_list_create +maps_coordinates_list_append +maps_coordinates_list_remove +maps_coordinates_list_get_length +maps_coordinates_list_foreach +maps_coordinates_list_destroy +maps_place_list_foreach +maps_place_list_destroy +maps_place_filter_get_place_address +maps_place_filter_set_place_address +maps_place_attribute_clone +maps_place_attribute_destroy +maps_place_attribute_get_id +maps_place_attribute_get_label +maps_place_attribute_get_text +maps_place_category_clone +maps_place_category_destroy +maps_place_category_get_id +maps_place_category_get_name +maps_place_category_get_url +maps_place_clone +maps_place_contact_clone +maps_place_contact_destroy +maps_place_contact_get_label +maps_place_contact_get_type +maps_place_contact_get_value +maps_place_destroy +maps_place_editorial_clone +maps_place_editorial_destroy +maps_place_editorial_get_description +maps_place_editorial_get_language +maps_place_editorial_get_media +maps_place_filter_clone +maps_place_filter_create +maps_place_filter_destroy +maps_place_filter_foreach_property +maps_place_filter_get +maps_place_filter_get_category +maps_place_filter_get_keyword +maps_place_filter_get_place_name +maps_place_filter_set +maps_place_filter_set_category +maps_place_filter_set_keyword +maps_place_filter_set_place_name +maps_place_foreach_attribute +maps_place_foreach_category +maps_place_foreach_contact +maps_place_foreach_editorial +maps_place_foreach_image +maps_place_foreach_property +maps_place_foreach_review +maps_place_get_address +maps_place_get_distance +maps_place_get_id +maps_place_get_location +maps_place_get_name +maps_place_get_rating +maps_place_get_related_link +maps_place_get_supplier_link +maps_place_get_uri +maps_place_image_clone +maps_place_image_destroy +maps_place_image_get_height +maps_place_image_get_id +maps_place_image_get_media +maps_place_image_get_url +maps_place_image_get_user_link +maps_place_image_get_width +maps_place_link_object_clone +maps_place_link_object_destroy +maps_place_link_object_get_id +maps_place_link_object_get_name +maps_place_link_object_get_string +maps_place_link_object_get_type +maps_place_media_clone +maps_place_media_destroy +maps_place_media_get_attribution +maps_place_media_get_supplier +maps_place_media_get_via +maps_place_rating_clone +maps_place_rating_destroy +maps_place_rating_get_average +maps_place_rating_get_count +maps_place_review_clone +maps_place_review_destroy +maps_place_review_get_date +maps_place_review_get_description +maps_place_review_get_language +maps_place_review_get_media +maps_place_review_get_rating +maps_place_review_get_title +maps_place_review_get_user_link +maps_place_url_clone +maps_place_url_destroy +maps_place_url_get_description +maps_place_url_get_path +maps_preference_clone +maps_preference_create +maps_preference_destroy +maps_preference_foreach_property +maps_preference_get +maps_preference_get_country_code +maps_preference_get_distance_unit +maps_preference_get_language +maps_preference_get_max_results +maps_preference_get_route_alternatives_enabled +maps_preference_get_route_feature +maps_preference_get_route_feature_weight +maps_preference_get_route_optimization +maps_preference_get_route_transport_mode +maps_preference_set_country_code +maps_preference_set_distance_unit +maps_preference_set_language +maps_preference_set_max_results +maps_preference_set_property +maps_preference_set_route_alternatives_enabled +maps_preference_set_route_feature +maps_preference_set_route_feature_weight +maps_preference_set_route_optimization +maps_preference_set_route_transport_mode +maps_route_clone +maps_route_destroy +maps_route_foreach_path +maps_route_foreach_property +maps_route_foreach_segment +maps_route_get_bounding_box +maps_route_get_destination +maps_route_get_distance_unit +maps_route_get_origin +maps_route_get_route_id +maps_route_get_total_distance +maps_route_get_total_duration +maps_route_get_transport_mode +maps_route_maneuver_clone +maps_route_maneuver_destroy +maps_route_maneuver_get_direction_id +maps_route_maneuver_get_distance_to_next_instruction +maps_route_maneuver_get_instruction_text +maps_route_maneuver_get_locale +maps_route_maneuver_get_position +maps_route_maneuver_get_road_name +maps_route_maneuver_get_time_to_next_instruction +maps_route_maneuver_get_turn_type +maps_route_segment_clone +maps_route_segment_destroy +maps_route_segment_foreach_maneuver +maps_route_segment_foreach_path +maps_route_segment_get_bounding_box +maps_route_segment_get_destination +maps_route_segment_get_distance +maps_route_segment_get_duration +maps_route_segment_get_origin +maps_service_cancel_request +maps_service_create +maps_service_destroy +maps_service_foreach_provider +maps_service_geocode +maps_service_geocode_by_structured_address +maps_service_geocode_inside_area +maps_service_get_preference +maps_service_get_provider_key +maps_service_provider_is_data_supported +maps_service_provider_is_service_supported +maps_service_reverse_geocode +maps_service_multi_reverse_geocode +maps_service_search_place +maps_service_search_place_by_address +maps_service_search_place_by_area +maps_service_search_place_list +maps_service_get_place_details +maps_service_search_route +maps_service_search_route_waypoints +maps_service_set_preference +maps_service_set_provider_key +maps_service_request_user_consent +maps_view_create +maps_view_destroy +maps_view_set_center +maps_view_get_center +maps_view_set_zoom_level +maps_view_get_zoom_level +maps_view_set_min_zoom_level +maps_view_get_min_zoom_level +maps_view_set_max_zoom_level +maps_view_get_max_zoom_level +maps_view_set_orientation +maps_view_get_orientation +maps_view_screen_to_geolocation +maps_view_geolocation_to_screen +maps_view_set_type +maps_view_get_type +maps_view_set_buildings_enabled +maps_view_get_buildings_enabled +maps_view_set_traffic_enabled +maps_view_get_traffic_enabled +maps_view_set_language +maps_view_get_language +maps_view_set_scalebar_enabled +maps_view_get_scalebar_enabled +maps_view_get_viewport +maps_view_set_screen_location +maps_view_get_screen_location +maps_view_move +maps_view_resize +maps_view_set_visibility +maps_view_get_visibility +maps_view_set_event_cb +maps_view_unset_event_cb +maps_view_set_gesture_enabled +maps_view_get_gesture_enabled +maps_view_set_public_transit_enabled +maps_view_get_public_transit_enabled +maps_view_capture_snapshot +maps_view_add_object +maps_view_remove_object +maps_view_remove_all_objects +maps_view_foreach_object +maps_view_object_create_marker +maps_view_object_create_polyline +maps_view_object_create_polygon +maps_view_object_destroy +maps_view_object_get_type +maps_view_object_set_visible +maps_view_object_get_visible +maps_view_object_polyline_set_polyline +maps_view_object_polyline_foreach_point +maps_view_object_polyline_set_color +maps_view_object_polyline_get_color +maps_view_object_polyline_set_width +maps_view_object_polyline_get_width +maps_view_object_polygon_set_polygon +maps_view_object_polygon_foreach_point +maps_view_object_polygon_set_fill_color +maps_view_object_polygon_get_fill_color +maps_view_object_marker_set_coordinates +maps_view_object_marker_resize +maps_view_object_marker_set_image_file +maps_view_object_marker_get_image_file +maps_view_object_marker_get_coordinates +maps_view_object_marker_get_size +maps_view_object_marker_get_type +maps_view_object_marker_set_z_order +maps_view_object_marker_get_z_order +maps_view_object_create_overlay +maps_view_object_overlay_get_object +maps_view_object_overlay_set_coordinates +maps_view_object_overlay_get_coordinates +maps_view_object_overlay_set_min_zoom_level +maps_view_object_overlay_get_min_zoom_level +maps_view_object_overlay_set_max_zoom_level +maps_view_object_overlay_get_max_zoom_level +maps_view_event_data_destroy +maps_view_event_data_clone +maps_view_event_data_get_type +maps_view_event_data_get_gesture_type +maps_view_event_data_get_action_type +maps_view_event_data_get_center +maps_view_event_data_get_delta +maps_view_event_data_get_position +maps_view_event_data_get_fingers +maps_view_event_data_get_zoom_factor +maps_view_event_data_get_rotation_angle +maps_view_event_data_get_object +maps_view_event_data_get_coordinates +maps_place_category_create +maps_place_category_set_id +maps_place_category_set_name +maps_place_category_set_url +watch_app_add_event_handler +watch_app_remove_event_handler +watch_app_main +watch_app_exit +watch_app_get_elm_win +watch_app_set_ambient_tick_type +watch_app_get_ambient_tick_type +watch_app_set_time_tick_frequency +watch_app_get_time_tick_frequency +watch_time_get_current_time +watch_time_delete +watch_time_get_year +watch_time_get_month +watch_time_get_day +watch_time_get_day_of_week +watch_time_get_hour +watch_time_get_hour24 +watch_time_get_minute +watch_time_get_second +watch_time_get_millisecond +watch_time_get_utc_time +watch_time_get_utc_timestamp +watch_time_get_time_zone +watch_time_get_dst_status +event_add_event_handler +event_remove_event_handler +event_publish_app_event +event_publish_trusted_app_event +event_keep_last_event_data +sync_adapter_set_callbacks +sync_adapter_unset_callbacks +sync_manager_add_periodic_sync_job +sync_manager_remove_sync_job +sync_manager_on_demand_sync_job +sync_manager_add_data_change_sync_job +sync_manager_foreach_sync_job +service_adaptor_create +service_adaptor_destroy +service_adaptor_foreach_plugin +service_adaptor_create_plugin +service_adaptor_get_last_result +service_adaptor_get_last_error_message +service_plugin_destroy +service_plugin_add_property +service_plugin_remove_property +service_plugin_get_property +service_plugin_start +service_plugin_stop +service_storage_remove +service_storage_get_file_list +service_storage_create_upload_task +service_storage_create_download_task +service_storage_create_download_thumbnail_task +service_storage_destroy_task +service_storage_start_task +service_storage_cancel_task +service_storage_set_task_progress_cb +service_storage_unset_task_progress_cb +service_storage_set_task_state_changed_cb +service_storage_unset_task_state_changed_cb +service_storage_file_list_clone +service_storage_file_list_destroy +service_storage_file_list_get_length +service_storage_file_list_foreach_file +service_storage_file_destroy +service_storage_file_clone +service_storage_file_is_dir +service_storage_file_get_size +service_storage_file_get_logical_path +service_storage_file_get_physical_path +mc_client_create +mc_client_set_server_updated_cb +mc_client_unset_server_updated_cb +mc_client_set_playback_updated_cb +mc_client_unset_playback_updated_cb +mc_client_set_metadata_updated_cb +mc_client_unset_metadata_updated_cb +mc_client_set_shuffle_mode_updated_cb +mc_client_unset_shuffle_mode_updated_cb +mc_client_set_repeat_mode_updated_cb +mc_client_unset_repeat_mode_updated_cb +mc_client_set_playlist_updated_cb +mc_client_unset_playlist_updated_cb +mc_client_set_cmd_reply_received_cb +mc_client_unset_cmd_reply_received_cb +mc_client_set_custom_event_received_cb +mc_client_unset_custom_event_received_cb +mc_client_get_playback_state +mc_client_get_playback_position +mc_client_destroy_playback +mc_client_get_latest_server_info +mc_client_get_server_playback_info +mc_client_get_server_metadata +mc_client_get_server_shuffle_mode +mc_client_get_server_repeat_mode +mc_client_get_playlist_item_index +mc_client_foreach_server_playlist +mc_client_foreach_server +mc_client_send_playback_action_cmd +mc_client_send_playback_position_cmd +mc_client_send_shuffle_mode_cmd +mc_client_send_repeat_mode_cmd +mc_client_send_playlist_cmd +mc_client_send_custom_cmd +mc_client_send_event_reply +mc_client_destroy +mc_client_subscribe +mc_client_unsubscribe +mc_client_foreach_server_subscribed +mc_server_create +mc_server_set_playback_state +mc_server_set_playback_position +mc_server_update_playback_info +mc_server_set_metadata +mc_server_update_metadata +mc_server_update_shuffle_mode +mc_server_update_repeat_mode +mc_server_create_playlist +mc_server_add_item_to_playlist +mc_server_update_playlist_done +mc_server_delete_playlist +mc_server_foreach_playlist +mc_server_foreach_client +mc_server_set_playlist_item_index +mc_server_set_playback_action_cmd_received_cb +mc_server_unset_playback_action_cmd_received_cb +mc_server_set_playback_position_cmd_received_cb +mc_server_unset_playback_position_cmd_received_cb +mc_server_set_shuffle_mode_cmd_received_cb +mc_server_unset_shuffle_mode_cmd_received_cb +mc_server_set_repeat_mode_cmd_received_cb +mc_server_unset_repeat_mode_cmd_received_cb +mc_server_set_playlist_cmd_received_cb +mc_server_unset_playlist_cmd_received_cb +mc_server_set_custom_cmd_received_cb +mc_server_unset_custom_cmd_received_cb +mc_server_set_event_reply_received_cb +mc_server_unset_event_reply_received_cb +mc_server_send_custom_event +mc_server_send_cmd_reply +mc_server_destroy +mc_playlist_get_name +mc_playlist_foreach_item +mc_playlist_clone +mc_playlist_destroy +mc_metadata_clone +mc_metadata_destroy +mc_metadata_get +widget_app_main +widget_app_exit +widget_app_terminate_context +widget_app_foreach_context +widget_app_add_event_handler +widget_app_remove_event_handler +widget_app_get_id +widget_app_class_create +widget_app_class_add +widget_app_context_set_tag +widget_app_context_get_tag +widget_app_context_set_content_info +widget_app_context_set_title +widget_app_get_elm_win +eom_init +eom_deinit +eom_set_output_added_cb +eom_unset_output_added_cb +eom_set_output_removed_cb +eom_unset_output_removed_cb +eom_set_mode_changed_cb +eom_unset_mode_changed_cb +eom_set_attribute_changed_cb +eom_unset_attribute_changed_cb +eom_get_eom_output_ids +eom_get_output_type +eom_get_output_mode +eom_get_output_attribute +eom_get_output_attribute_state +eom_get_output_resolution +eom_get_output_physical_size +eom_set_output_attribute +eom_set_output_window +vc_elm_initialize +vc_elm_deinitialize +vc_elm_foreach_supported_languages +vc_elm_get_current_language +vc_elm_foreach_supported_widgets +vc_elm_foreach_supported_actions +vc_elm_get_action_command +vc_elm_create_object +vc_elm_create_item +vc_elm_destroy +vc_elm_set_command +vc_elm_unset_command +vc_elm_set_command_hint +vc_elm_unset_command_hint +vc_elm_set_command_hint_direction +vc_elm_get_command_hint_direction +vc_elm_set_command_hint_offset +vc_elm_get_command_hint_offset +vc_elm_set_current_language_changed_cb +vc_elm_unset_current_language_changed_cb +vc_initialize +vc_deinitialize +vc_prepare +vc_unprepare +vc_foreach_supported_languages +vc_get_current_language +vc_get_state +vc_get_service_state +vc_set_command_list +vc_unset_command_list +vc_set_result_cb +vc_unset_result_cb +vc_set_service_state_changed_cb +vc_unset_service_state_changed_cb +vc_set_state_changed_cb +vc_unset_state_changed_cb +vc_set_current_language_changed_cb +vc_unset_current_language_changed_cb +vc_set_error_cb +vc_unset_error_cb +vc_get_system_command_list +vc_set_invocation_name +vc_request_dialog +vc_get_result +vc_cmd_get_unfixed_command +vc_cmd_set_format +vc_cmd_get_format +vc_cmd_list_create +vc_cmd_list_destroy +vc_cmd_list_get_count +vc_cmd_list_add +vc_cmd_list_remove +vc_cmd_list_foreach_commands +vc_cmd_list_first +vc_cmd_list_last +vc_cmd_list_next +vc_cmd_list_prev +vc_cmd_list_get_current +vc_cmd_create +vc_cmd_destroy +vc_cmd_set_command +vc_cmd_get_command +vc_cmd_set_type +vc_cmd_get_type +vce_main +vce_send_result +vce_send_asr_result +vce_send_nlg_result +vce_send_error +vce_set_private_data_set_cb +vce_set_private_data_requested_cb +vce_set_nlu_base_info_requested_cb +vce_get_foreach_command +vce_get_command_count +vce_get_audio_type +vce_set_private_data +vce_get_private_data +vce_start_recording +vce_stop_recording +vce_send_specific_engine_result +vce_set_specific_engine_request_cb +vce_unset_specific_engine_request_cb +vce_send_feedback_audio_format +vce_send_feedback_streaming +widget_service_trigger_update +widget_service_change_period +widget_service_get_nodisplay +widget_service_get_size_type +widget_service_get_size +widget_service_get_widget_id +widget_service_get_icon +widget_service_get_main_app_id +widget_service_get_need_of_mouse_event +widget_service_get_need_of_frame +widget_service_get_app_id_of_setup_app +widget_service_get_need_of_touch_effect +widget_service_get_widget_list +widget_service_get_widget_list_by_pkgid +widget_service_get_package_id +widget_service_get_name +widget_service_get_preview_image_path +widget_service_get_supported_sizes +widget_service_get_supported_size_types +widget_service_get_widget_instance_list +widget_service_set_lifecycle_event_cb +widget_service_unset_lifecycle_event_cb +widget_service_get_content_of_widget_instance +widget_viewer_evas_init +widget_viewer_evas_fini +widget_viewer_evas_add_widget +widget_viewer_evas_notify_resumed_status_of_viewer +widget_viewer_evas_notify_paused_status_of_viewer +widget_viewer_evas_pause_widget +widget_viewer_evas_resume_widget +widget_viewer_evas_set_option +widget_viewer_evas_get_content_info +widget_viewer_evas_get_title_string +widget_viewer_evas_get_widget_id +widget_viewer_evas_get_widget_instance_id +widget_viewer_evas_get_period +widget_viewer_evas_cancel_click_event +widget_viewer_evas_disable_preview +widget_viewer_evas_disable_overlay_text +widget_viewer_evas_disable_loading +widget_viewer_evas_feed_mouse_up_event +widget_viewer_evas_activate_faulted_widget +widget_viewer_evas_is_faulted +widget_viewer_evas_freeze_visibility +widget_viewer_evas_thaw_visibility +widget_viewer_evas_is_visibility_frozen +widget_viewer_evas_is_widget +widget_viewer_evas_set_permanent_delete +widget_viewer_evas_notify_orientation_of_viewer +trace_begin +trace_end +trace_async_begin +trace_async_end +trace_update_counter +minicontrol_viewer_add +minicontrol_viewer_send_event +minicontrol_viewer_set_event_cb +minicontrol_viewer_unset_event_cb +minicontrol_create_window +minicontrol_send_event +mv_create_source +mv_destroy_source +mv_source_fill_by_media_packet +mv_source_fill_by_buffer +mv_source_clear +mv_source_get_buffer +mv_source_get_height +mv_source_get_width +mv_source_get_colorspace +mv_create_engine_config +mv_destroy_engine_config +mv_engine_config_set_double_attribute +mv_engine_config_set_int_attribute +mv_engine_config_set_bool_attribute +mv_engine_config_set_string_attribute +mv_engine_config_get_double_attribute +mv_engine_config_get_int_attribute +mv_engine_config_get_bool_attribute +mv_engine_config_get_string_attribute +mv_engine_config_foreach_supported_attribute +mv_barcode_detect +mv_barcode_generate_source +mv_barcode_generate_image +mv_face_detect +mv_face_recognize +mv_face_track +mv_face_eye_condition_recognize +mv_face_facial_expression_recognize +mv_face_recognition_model_create +mv_face_recognition_model_destroy +mv_face_recognition_model_clone +mv_face_recognition_model_save +mv_face_recognition_model_load +mv_face_recognition_model_add +mv_face_recognition_model_reset +mv_face_recognition_model_learn +mv_face_recognition_model_query_labels +mv_face_tracking_model_create +mv_face_tracking_model_destroy +mv_face_tracking_model_prepare +mv_face_tracking_model_clone +mv_face_tracking_model_save +mv_face_tracking_model_load +mv_image_recognize +mv_image_track +mv_image_object_create +mv_image_object_destroy +mv_image_object_fill +mv_image_object_get_recognition_rate +mv_image_object_set_label +mv_image_object_get_label +mv_image_object_clone +mv_image_object_save +mv_image_object_load +mv_image_tracking_model_create +mv_image_tracking_model_set_target +mv_image_tracking_model_destroy +mv_image_tracking_model_refresh +mv_image_tracking_model_clone +mv_image_tracking_model_save +mv_image_tracking_model_load +mv_surveillance_event_trigger_create +mv_surveillance_event_trigger_destroy +mv_surveillance_get_event_trigger_type +mv_surveillance_set_event_trigger_roi +mv_surveillance_get_event_trigger_roi +mv_surveillance_subscribe_event_trigger +mv_surveillance_unsubscribe_event_trigger +mv_surveillance_push_source +mv_surveillance_foreach_supported_event_type +mv_surveillance_foreach_event_result_name +mv_surveillance_get_result_value +media_streamer_set_error_cb +media_streamer_unset_error_cb +media_streamer_set_state_change_cb +media_streamer_unset_state_change_cb +media_streamer_src_set_buffer_status_cb +media_streamer_src_unset_buffer_status_cb +media_streamer_set_play_position +media_streamer_get_play_position +media_streamer_get_duration +media_streamer_sink_set_data_ready_cb +media_streamer_sink_unset_data_ready_cb +media_streamer_sink_set_eos_cb +media_streamer_sink_unset_eos_cb +media_streamer_create +media_streamer_prepare +media_streamer_unprepare +media_streamer_play +media_streamer_pause +media_streamer_stop +media_streamer_destroy +media_streamer_get_state +media_streamer_node_create_src +media_streamer_node_push_packet +media_streamer_node_create_sink +media_streamer_node_pull_packet +media_streamer_node_create +media_streamer_node_add +media_streamer_node_destroy +media_streamer_node_remove +media_streamer_node_set_pad_format +media_streamer_node_get_pad_format +media_streamer_node_link +media_streamer_node_get_pad_name +media_streamer_node_set_params +media_streamer_node_get_params +media_streamer_node_set_param +media_streamer_node_get_param +media_streamer_set_interrupted_cb +media_streamer_unset_interrupted_cb +mediamuxer_create +mediamuxer_set_data_sink +mediamuxer_add_track +mediamuxer_start +mediamuxer_write_sample +mediamuxer_close_track +mediamuxer_pause +mediamuxer_resume +mediamuxer_stop +mediamuxer_destroy +mediamuxer_get_state +mediamuxer_set_error_cb +mediamuxer_unset_error_cb +mediamuxer_prepare +mediamuxer_unprepare +mediamuxer_set_eos_cb +mediamuxer_unset_eos_cb +mediademuxer_create +mediademuxer_set_data_source +mediademuxer_prepare +mediademuxer_get_track_count +mediademuxer_select_track +mediademuxer_start +mediademuxer_get_track_info +mediademuxer_read_sample +mediademuxer_seek +mediademuxer_unselect_track +mediademuxer_stop +mediademuxer_unprepare +mediademuxer_destroy +mediademuxer_get_state +mediademuxer_set_error_cb +mediademuxer_unset_error_cb +mediademuxer_set_eos_cb +mediademuxer_unset_eos_cb +streamrecorder_create +streamrecorder_destroy +streamrecorder_prepare +streamrecorder_unprepare +streamrecorder_start +streamrecorder_pause +streamrecorder_commit +streamrecorder_cancel +streamrecorder_push_stream_buffer +streamrecorder_enable_source_buffer +streamrecorder_get_state +streamrecorder_set_filename +streamrecorder_get_filename +streamrecorder_set_file_format +streamrecorder_get_file_format +streamrecorder_set_audio_encoder +streamrecorder_get_audio_encoder +streamrecorder_set_video_resolution +streamrecorder_get_video_resolution +streamrecorder_set_video_encoder +streamrecorder_get_video_encoder +streamrecorder_set_video_source_format +streamrecorder_set_video_framerate +streamrecorder_get_video_framerate +streamrecorder_get_video_source_format +streamrecorder_set_recording_limit +streamrecorder_get_recording_limit +streamrecorder_set_audio_samplerate +streamrecorder_get_audio_samplerate +streamrecorder_set_audio_encoder_bitrate +streamrecorder_set_video_encoder_bitrate +streamrecorder_get_audio_encoder_bitrate +streamrecorder_get_video_encoder_bitrate +streamrecorder_set_audio_channel +streamrecorder_get_audio_channel +streamrecorder_foreach_supported_file_format +streamrecorder_foreach_supported_audio_encoder +streamrecorder_foreach_supported_video_encoder +streamrecorder_foreach_supported_video_resolution +streamrecorder_set_notify_cb +streamrecorder_unset_notify_cb +streamrecorder_set_recording_status_cb +streamrecorder_unset_recording_status_cb +streamrecorder_set_recording_limit_reached_cb +streamrecorder_unset_recording_limit_reached_cb +streamrecorder_set_error_cb +streamrecorder_unset_error_cb +streamrecorder_set_buffer_consume_completed_cb +streamrecorder_unset_buffer_consume_completed_cb +attach_panel_create +attach_panel_destroy +attach_panel_add_content_category +attach_panel_remove_content_category +attach_panel_set_extra_data +attach_panel_set_result_cb +attach_panel_unset_result_cb +attach_panel_set_event_cb +attach_panel_unset_event_cb +attach_panel_show +attach_panel_hide +attach_panel_get_visibility +attach_panel_get_state +attach_panel_show_without_animation +attach_panel_hide_without_animation +fido_foreach_authenticator +fido_authenticator_get_title +fido_authenticator_get_aaid +fido_authenticator_get_description +fido_authenticator_get_assertion_scheme +fido_authenticator_get_algorithm +fido_authenticator_foreach_attestation_type +fido_authenticator_get_verification_method +fido_authenticator_get_key_protection_method +fido_authenticator_get_matcher_protection_method +fido_authenticator_get_attachment_hint +fido_authenticator_get_is_second_factor_only +fido_authenticator_get_tc_discplay +fido_authenticator_get_tc_display_type +fido_authenticator_get_icon +fido_get_client_vendor +fido_get_client_version +fido_uaf_is_supported +fido_uaf_get_response_message +fido_uaf_set_server_result +iotcon_initialize +iotcon_deinitialize +iotcon_polling_get_interval +iotcon_polling_set_interval +iotcon_polling_invoke +iotcon_set_device_name +iotcon_get_timeout +iotcon_set_timeout +iotcon_add_presence_cb +iotcon_remove_presence_cb +iotcon_add_generated_pin_cb +iotcon_remove_generated_pin_cb +iotcon_presence_get_host_addres +iotcon_presence_get_connectivity_type +iotcon_presence_get_resource_type +iotcon_presence_response_get_result +iotcon_presence_response_get_trigger +iotcon_presence_response_get_host_address +iotcon_presence_response_get_connectivity_type +iotcon_presence_response_get_resource_type +iotcon_start_presence +iotcon_stop_presence +iotcon_find_resource +iotcon_find_device_info +iotcon_device_info_get_property +iotcon_find_platform_info +iotcon_platform_info_get_property +iotcon_remote_resource_create +iotcon_remote_resource_destroy +iotcon_remote_resource_clone +iotcon_remote_resource_observe_register +iotcon_remote_resource_observe_deregister +iotcon_remote_resource_get +iotcon_remote_resource_put +iotcon_remote_resource_post +iotcon_remote_resource_delete +iotcon_remote_resource_start_caching +iotcon_remote_resource_stop_caching +iotcon_remote_resource_start_monitoring +iotcon_remote_resource_stop_monitoring +iotcon_remote_resource_get_uri_path +iotcon_remote_resource_get_connectivity_type +iotcon_remote_resource_get_host_address +iotcon_remote_resource_get_device_id +iotcon_remote_resource_get_types +iotcon_remote_resource_get_interfaces +iotcon_remote_resource_get_policies +iotcon_remote_resource_get_options +iotcon_remote_resource_set_options +iotcon_remote_resource_get_cached_representation +iotcon_remote_resource_get_checking_interval +iotcon_remote_resource_set_checking_interval +iotcon_remote_resource_get_device_name +iotcon_options_create +iotcon_options_destroy +iotcon_options_add +iotcon_options_remove +iotcon_options_lookup +iotcon_options_foreach +iotcon_query_create +iotcon_query_destroy +iotcon_query_get_resource_type +iotcon_query_get_interface +iotcon_query_set_resource_type +iotcon_query_set_interface +iotcon_query_add +iotcon_query_remove +iotcon_query_lookup +iotcon_query_foreach +iotcon_representation_create +iotcon_representation_destroy +iotcon_representation_clone +iotcon_representation_set_uri_path +iotcon_representation_get_uri_path +iotcon_representation_set_resource_types +iotcon_representation_get_resource_types +iotcon_representation_set_resource_interfaces +iotcon_representation_get_resource_interfaces +iotcon_representation_set_attributes +iotcon_representation_get_attributes +iotcon_representation_add_child +iotcon_representation_remove_child +iotcon_representation_foreach_children +iotcon_representation_get_child_count +iotcon_representation_get_nth_child +iotcon_attributes_create +iotcon_attributes_destroy +iotcon_attributes_clone +iotcon_attributes_add_int +iotcon_attributes_add_bool +iotcon_attributes_add_double +iotcon_attributes_add_str +iotcon_attributes_add_byte_str +iotcon_attributes_add_list +iotcon_attributes_add_attributes +iotcon_attributes_add_null +iotcon_attributes_get_int +iotcon_attributes_get_bool +iotcon_attributes_get_double +iotcon_attributes_get_str +iotcon_attributes_get_byte_str +iotcon_attributes_get_list +iotcon_attributes_get_attributes +iotcon_attributes_is_null +iotcon_attributes_remove +iotcon_attributes_get_type +iotcon_attributes_foreach +iotcon_attributes_get_keys_count +iotcon_list_create +iotcon_list_destroy +iotcon_list_add_int +iotcon_list_add_bool +iotcon_list_add_double +iotcon_list_add_str +iotcon_list_add_byte_str +iotcon_list_add_list +iotcon_list_add_attributes +iotcon_list_get_nth_int +iotcon_list_get_nth_bool +iotcon_list_get_nth_double +iotcon_list_get_nth_str +iotcon_list_get_nth_byte_str +iotcon_list_get_nth_list +iotcon_list_get_nth_attributes +iotcon_list_remove_nth +iotcon_list_get_type +iotcon_list_get_length +iotcon_list_foreach_int +iotcon_list_foreach_bool +iotcon_list_foreach_double +iotcon_list_foreach_byte_str +iotcon_list_foreach_str +iotcon_list_foreach_list +iotcon_list_foreach_attributes +iotcon_resource_types_create +iotcon_resource_types_destroy +iotcon_resource_types_add +iotcon_resource_types_remove +iotcon_resource_types_foreach +iotcon_resource_types_clone +iotcon_response_create +iotcon_response_destroy +iotcon_response_get_options +iotcon_response_get_representation +iotcon_response_get_result +iotcon_response_set_result +iotcon_response_set_representation +iotcon_response_set_options +iotcon_response_send +iotcon_lite_resource_create +iotcon_lite_resource_destroy +iotcon_lite_resource_update_attributes +iotcon_lite_resource_get_attributes +iotcon_observers_create +iotcon_observers_destroy +iotcon_observers_add +iotcon_observers_remove +iotcon_request_get_host_address +iotcon_request_get_connectivity_type +iotcon_request_get_representation +iotcon_request_get_request_type +iotcon_request_get_options +iotcon_request_get_query +iotcon_request_get_observe_type +iotcon_request_get_observe_id +iotcon_resource_create +iotcon_resource_destroy +iotcon_resource_bind_interface +iotcon_resource_bind_type +iotcon_resource_set_request_handler +iotcon_resource_bind_child_resource +iotcon_resource_unbind_child_resource +iotcon_resource_notify +iotcon_resource_get_child_count +iotcon_resource_get_nth_child +iotcon_resource_get_uri_path +iotcon_resource_get_types +iotcon_resource_get_interfaces +iotcon_resource_get_policies +iotcon_resource_interfaces_create +iotcon_resource_interfaces_destroy +iotcon_resource_interfaces_add +iotcon_resource_interfaces_remove +iotcon_resource_interfaces_foreach +iotcon_resource_interfaces_clone +Dali::Actor::Actor(); +Dali::Actor::Actor(const Actor& copy); +Dali::Actor::Add(Actor child); +Dali::Actor::AddRenderer( struct Renderer& renderer ); +Dali::Actor::DownCast( BaseHandle handle ); +Dali::Actor::FindChildById(const unsigned int id); +Dali::Actor::FindChildByName(const std::string& actorName); +Dali::Actor::GetChildAt(unsigned int index) const; +Dali::Actor::GetChildCount() const; +Dali::Actor::GetColorMode() const; +Dali::Actor::GetCurrentAnchorPoint() const; +Dali::Actor::GetCurrentColor() const; +Dali::Actor::GetCurrentOpacity() const; +Dali::Actor::GetCurrentOrientation() const; +Dali::Actor::GetCurrentParentOrigin() const; +Dali::Actor::GetCurrentPosition() const; +Dali::Actor::GetCurrentScale() const; +Dali::Actor::GetCurrentSize() const; +Dali::Actor::GetCurrentWorldColor() const; +Dali::Actor::GetCurrentWorldMatrix() const; +Dali::Actor::GetCurrentWorldOrientation() const; +Dali::Actor::GetCurrentWorldPosition() const; +Dali::Actor::GetCurrentWorldScale() const; +Dali::Actor::GetDrawMode() const; +Dali::Actor::GetHeightForWidth( float width ); +Dali::Actor::GetHierarchyDepth(); +Dali::Actor::GetId() const; +Dali::Actor::GetLayer(); +Dali::Actor::GetLeaveRequired() const; +Dali::Actor::GetMaximumSize(); +Dali::Actor::GetMinimumSize(); +Dali::Actor::GetName() const; +Dali::Actor::GetNaturalSize() const; +Dali::Actor::GetPadding( Padding& paddingOut ) const; +Dali::Actor::GetParent() const; +Dali::Actor::GetRendererAt( unsigned int index ); +Dali::Actor::GetRendererCount() const; +Dali::Actor::GetRelayoutSize( Dimension::Type dimension ) const; +Dali::Actor::GetResizePolicy( Dimension::Type dimension ) const; +Dali::Actor::GetSizeModeFactor() const; +Dali::Actor::GetSizeScalePolicy() const; +Dali::Actor::GetTargetSize() const; +Dali::Actor::GetWidthForHeight( float height ); +Dali::Actor::HoveredSignal(); +Dali::Actor::IsKeyboardFocusable() const; +Dali::Actor::IsLayer() const; +Dali::Actor::IsOrientationInherited() const; +Dali::Actor::IsRoot() const; +Dali::Actor::IsScaleInherited() const; +Dali::Actor::IsSensitive() const; +Dali::Actor::IsVisible() const; +Dali::Actor::New(); +Dali::Actor::OffStageSignal(); +Dali::Actor::OnRelayoutSignal(); +Dali::Actor::OnStage() const; +Dali::Actor::OnStageSignal(); +Dali::Actor::Remove(Actor child); +Dali::Actor::RemoveRenderer( struct Renderer& renderer ); +Dali::Actor::RemoveRenderer( unsigned int index ); +Dali::Actor::RotateBy( const Degree& angle, const Vector3& axis ) +Dali::Actor::RotateBy(const Quaternion& relativeRotation); +Dali::Actor::RotateBy(const Radian& angle, const Vector3& axis); +Dali::Actor::ScaleBy(const Vector3& relativeScale); +Dali::Actor::ScreenToLocal(float& localX, float& localY, float screenX, float screenY) const; +Dali::Actor::SetAnchorPoint(const Vector3& anchorPoint); +Dali::Actor::SetColor(const Vector4& color); +Dali::Actor::SetColorMode( ColorMode colorMode ); +Dali::Actor::SetDrawMode( DrawMode::Type drawMode ); +Dali::Actor::SetInheritOrientation(bool inherit); +Dali::Actor::SetInheritScale( bool inherit ); +Dali::Actor::SetKeyboardFocusable( bool focusable ); +Dali::Actor::SetLeaveRequired(bool required); +Dali::Actor::SetMaximumSize( const Vector2& size ); +Dali::Actor::SetMinimumSize( const Vector2& size ); +Dali::Actor::SetName(const std::string& name); +Dali::Actor::SetOpacity(float opacity); +Dali::Actor::SetOrientation( const Degree& angle, const Vector3& axis ) +Dali::Actor::SetOrientation(const Quaternion& orientation); +Dali::Actor::SetOrientation(const Radian& angle, const Vector3& axis); +Dali::Actor::SetPadding( const Padding& padding ); +Dali::Actor::SetParentOrigin(const Vector3& origin); +Dali::Actor::SetPosition(const Vector3& position); +Dali::Actor::SetPosition(float x, float y); +Dali::Actor::SetPosition(float x, float y, float z); +Dali::Actor::SetInheritPosition( bool inherit ) +Dali::Actor:: IsPositionInherited() const +Dali::Actor::SetResizePolicy( ResizePolicy::Type policy, Dimension::Type dimension ); +Dali::Actor::SetScale(const Vector3& scale); +Dali::Actor::SetScale(float scale); +Dali::Actor::SetScale(float scaleX, float scaleY, float scaleZ); +Dali::Actor::SetSensitive(bool sensitive); +Dali::Actor::SetSize(const Vector2& size); +Dali::Actor::SetSize(const Vector3& size); +Dali::Actor::SetSize(float width, float height); +Dali::Actor::SetSize(float width, float height, float depth); +Dali::Actor::SetSizeModeFactor( const Vector3& factor ); +Dali::Actor::SetSizeScalePolicy( SizeScalePolicy::Type policy ); +Dali::Actor::SetVisible(bool visible); +Dali::Actor::SetX(float x); +Dali::Actor::SetY(float y); +Dali::Actor::SetZ(float z); +Dali::Actor::TouchSignal() +Dali::Actor::TranslateBy(const Vector3& distance); +Dali::Actor::Unparent(); +Dali::UnparentAndReset( Actor& actor ); +Dali::Actor::WheelEventSignal(); +Dali::Actor::operator=(const Actor& rhs); +Dali::Actor::~Actor(); +Dali::Actor::LayoutDirectionChangedSignal() +Dali::Actor::Lower() +Dali::Actor::LowerBelow(Dali::Actor) +Dali::Actor::LowerToBottom() +Dali::Actor::Raise() +Dali::Actor::RaiseAbove(Dali::Actor) +Dali::Actor::RaiseToTop() +Dali::CameraActor::CameraActor(); +Dali::CameraActor::CameraActor(const CameraActor& copy); +Dali::CameraActor::DownCast( BaseHandle handle ); +Dali::CameraActor::GetAspectRatio( ); +Dali::CameraActor::GetFarClippingPlane( ); +Dali::CameraActor::GetFieldOfView( ); +Dali::CameraActor::GetInvertYAxis(); +Dali::CameraActor::GetNearClippingPlane( ); +Dali::CameraActor::GetProjectionMode() const; +Dali::CameraActor::GetTargetPosition() const; +Dali::CameraActor::GetType() const; +Dali::CameraActor::New( const Size& size ); +Dali::CameraActor::New(); +Dali::CameraActor::SetAspectRatio( float aspectRatio ); +Dali::CameraActor::SetFarClippingPlane( float farClippingPlane ); +Dali::CameraActor::SetFieldOfView( float fieldOfView ); +Dali::CameraActor::SetInvertYAxis(bool invertYAxis); +Dali::CameraActor::SetNearClippingPlane( float nearClippingPlane ); +Dali::CameraActor::SetOrthographicProjection( const Size& size ); +Dali::CameraActor::SetOrthographicProjection( float left, float right, float top, float bottom, float near, float far ); +Dali::CameraActor::SetPerspectiveProjection( const Size& size ); +Dali::CameraActor::SetProjectionMode( Dali::Camera::ProjectionMode mode ); +Dali::CameraActor::SetTargetPosition( const Vector3& targetPosition ); +Dali::CameraActor::SetType( Dali::Camera::Type type ); +Dali::CameraActor::operator=(const CameraActor& rhs); +Dali::CameraActor::~CameraActor(); +Dali::CustomActorImpl::CalculateChildSizeBase( const Dali::Actor& child, Dimension::Type dimension ); +Dali::CustomActorImpl::CustomActorImpl( ActorFlags flags ); +Dali::CustomActorImpl::GetExtension() +Dali::CustomActorImpl::GetHeightForWidthBase( float width ); +Dali::CustomActorImpl::GetOwner() const; +Dali::CustomActorImpl::GetWidthForHeightBase( float height ); +Dali::CustomActorImpl::Initialize(Internal::CustomActor& owner); +Dali::CustomActorImpl::IsRelayoutEnabled() const; +Dali::CustomActorImpl::OnPropertySet( Property::Index index, Property::Value propertyValue ); +Dali::CustomActorImpl::RelayoutDependentOnChildrenBase( Dimension::Type dimension = Dimension::ALL_DIMENSIONS ); +Dali::CustomActorImpl::RelayoutRequest(); +Dali::CustomActorImpl::RequiresHoverEvents() const; +Dali::CustomActorImpl::RequiresTouchEvents() const; +Dali::CustomActorImpl::RequiresWheelEvents() const; +Dali::CustomActorImpl::Self() const; +Dali::CustomActorImpl::~CustomActorImpl(); +Dali::CustomActor::CustomActor(); +Dali::CustomActor::CustomActor(CustomActorImpl& implementation); +Dali::CustomActor::CustomActor(Internal::CustomActor* actor); +Dali::CustomActor::CustomActor(const CustomActor& copy); +Dali::CustomActor::DownCast( BaseHandle handle ); +Dali::CustomActor::GetImplementation(); +Dali::CustomActor::GetImplementation() const; +Dali::CustomActor::operator=(const CustomActor& rhs); +Dali::CustomActor::~CustomActor(); +Dali::Layer::DownCast( BaseHandle handle ); +Dali::Layer::GetBehavior( ) const; +Dali::Layer::GetClippingBox() const; +Dali::Layer::GetDepth() const; +Dali::Layer::IsClipping() const; +Dali::Layer::IsDepthTestDisabled() const; +Dali::Layer::IsHoverConsumed() const; +Dali::Layer::IsTouchConsumed() const; +Dali::Layer::Layer(); +Dali::Layer::Layer(const Layer& copy); +Dali::Layer::Lower(); +Dali::Layer::LowerBelow( Layer target ); +Dali::Layer::LowerToBottom(); +Dali::Layer::MoveAbove( Layer target ); +Dali::Layer::MoveBelow( Layer target ); +Dali::Layer::New(); +Dali::Layer::Raise(); +Dali::Layer::RaiseAbove( Layer target ); +Dali::Layer::RaiseToTop(); +Dali::Layer::SetBehavior( enum Layer::Behavior behavior ); +Dali::Layer::SetClipping(bool enabled); +Dali::Layer::SetClippingBox(ClippingBox box); +Dali::Layer::SetClippingBox(int x, int y, int width, int height); +Dali::Layer::SetDepthTestDisabled( bool disable ); +Dali::Layer::SetHoverConsumed( bool consume ); +Dali::Layer::SetSortFunction( SortFunctionType function ); +Dali::Layer::SetTouchConsumed( bool consume ); +Dali::Layer::operator=(const Layer& rhs); +Dali::Layer::~Layer(); +Dali::AlphaFunction::AlphaFunction( AlphaFunctionPrototype function); +Dali::AlphaFunction::AlphaFunction( BuiltinFunction function); +Dali::AlphaFunction::AlphaFunction( const Dali::Vector2& controlPoint0, const Dali::Vector2& controlPoint1 ); +Dali::AlphaFunction::AlphaFunction(); +Dali::AlphaFunction::GetBezierControlPoints() const; +Dali::AlphaFunction::GetBuiltinFunction() const; +Dali::AlphaFunction::GetCustomFunction() const; +Dali::AlphaFunction::GetMode() const; +Dali::Animation::Animate( Actor actor, Path path, const Vector3& forward ); +Dali::Animation::Animate( Actor actor, Path path, const Vector3& forward, AlphaFunction alpha ); +Dali::Animation::Animate( Actor actor, Path path, const Vector3& forward, AlphaFunction alpha, TimePeriod period); +Dali::Animation::Animate( Actor actor, Path path, const Vector3& forward, TimePeriod period ); +Dali::Animation::AnimateBetween(Property target, KeyFrames& keyFrames); +Dali::Animation::AnimateBetween(Property target, KeyFrames& keyFrames, AlphaFunction alpha); +Dali::Animation::AnimateBetween(Property target, KeyFrames& keyFrames, AlphaFunction alpha, Interpolation interpolation); +Dali::Animation::AnimateBetween(Property target, KeyFrames& keyFrames, AlphaFunction alpha, TimePeriod period); +Dali::Animation::AnimateBetween(Property target, KeyFrames& keyFrames, AlphaFunction alpha, TimePeriod period, Interpolation interpolation); +Dali::Animation::AnimateBetween(Property target, KeyFrames& keyFrames, Interpolation interpolation); +Dali::Animation::AnimateBetween(Property target, KeyFrames& keyFrames, TimePeriod period); +Dali::Animation::AnimateBetween(Property target, KeyFrames& keyFrames, TimePeriod period, Interpolation interpolation); +Dali::Animation::AnimateBy(Property target, Property::Value relativeValue); +Dali::Animation::AnimateBy(Property target, Property::Value relativeValue, AlphaFunction alpha); +Dali::Animation::AnimateBy(Property target, Property::Value relativeValue, AlphaFunction alpha, TimePeriod period); +Dali::Animation::AnimateBy(Property target, Property::Value relativeValue, TimePeriod period); +Dali::Animation::AnimateTo(Property target, Property::Value destinationValue); +Dali::Animation::AnimateTo(Property target, Property::Value destinationValue, AlphaFunction alpha); +Dali::Animation::AnimateTo(Property target, Property::Value destinationValue, AlphaFunction alpha, TimePeriod period); +Dali::Animation::AnimateTo(Property target, Property::Value destinationValue, TimePeriod period); +Dali::Animation::Animation(); +Dali::Animation::Animation(const Animation& handle); +Dali::Animation::Clear(); +Dali::Animation::DownCast( BaseHandle handle ); +Dali::Animation::FinishedSignal(); +Dali::Animation::GetCurrentProgress(); +Dali::Animation::GetDefaultAlphaFunction() const; +Dali::Animation::GetDisconnectAction() const; +Dali::Animation::GetDuration() const; +Dali::Animation::GetEndAction() const; +Dali::Animation::GetPlayRange() const; +Dali::Animation::GetSpeedFactor() const; +Dali::Animation::GetLoopingMode() const +Dali::Animation::Hide(Actor actor, float delaySeconds); +Dali::Animation::IsLooping() const; +Dali::Animation::New(float durationSeconds); +Dali::Animation::Pause(); +Dali::Animation::Play(); +Dali::Animation::PlayFrom( float progress ); +Dali::Animation::PlayAfter(float) +Dali::Animation::SetCurrentProgress( float progress ); +Dali::Animation::SetDefaultAlphaFunction(AlphaFunction alpha); +Dali::Animation::SetDisconnectAction( EndAction disconnectAction ); +Dali::Animation::SetDuration(float seconds); +Dali::Animation::SetEndAction(EndAction action); +Dali::Animation::SetLooping(bool looping); +Dali::Animation::SetLoopingMode(Dali::Animation::LoopingMode) +Dali::Animation::SetPlayRange( const Vector2& range ); +Dali::Animation::SetSpeedFactor( float factor ); +Dali::Animation::Show(Actor actor, float delaySeconds); +Dali::Animation::Stop(); +Dali::Animation::operator=(const Animation& rhs); +Dali::Animation::~Animation(); +Dali::Animation::SetLoopCount(int count); +Dali::Animation::GetLoopCount(); +Dali::Animation::GetCurrentLoop(); +Dali::Animation::GetState(); +Dali::ConstraintSource::ConstraintSource( LocalSource local ); +Dali::ConstraintSource::ConstraintSource( ParentSource parent ); +Dali::ConstraintSource::ConstraintSource( Source source ); +Dali::LocalSource::LocalSource( Property::Index index ); +Dali::ParentSource::ParentSource( Property::Index index ); +Dali::Source::Source( Handle& object, Property::Index index ); +Dali::Constraint::AddSource( ConstraintSource source ); +Dali::Constraint::Apply(); +Dali::Constraint::Function::Clone() +Dali::Constraint::Clone( Handle handle ); +Dali::Constraint::Constraint( const Constraint& constraint ); +Dali::Constraint::Constraint(); +Dali::Constraint::DownCast( BaseHandle baseHandle ); +Dali::Constraint::Function::Function( const T& object ) +Dali::Constraint::Function::Function( const T& object, void ( T::*memberFunction ) ( P&, const PropertyInputContainer& ) ) +Dali::Constraint::Function::Function( void( *function )( P&, const PropertyInputContainer& ) ) +Dali::Constraint::GetRemoveAction() const; +Dali::Constraint::GetTag() const; +Dali::Constraint::GetTargetObject(); +Dali::Constraint::GetTargetProperty(); +Dali::Constraint::New( Handle handle, Property::Index targetIndex, const T& object ) +Dali::Constraint::New( Handle handle, Property::Index targetIndex, const T& object, void ( T::*memberFunction ) ( P&, const PropertyInputContainer& ) ) +Dali::Constraint::New( Handle handle, Property::Index targetIndex, void( *function )( P&, const PropertyInputContainer& ) ) +Dali::Constraint::Remove(); +Dali::Constraint::SetRemoveAction( RemoveAction action ); +Dali::Constraint::SetTag( const unsigned int tag ); +Dali::Constraint::operator=( const Constraint& rhs ); +Dali::Constraint::~Constraint(); +Dali::EqualToConstraint::EqualToConstraint() +Dali::LookAt( Quaternion& current, const PropertyInputContainer& inputs ) +Dali::RelativeToConstraint::RelativeToConstraint( const Vector3& scale ) +Dali::RelativeToConstraint::RelativeToConstraint( float scale ) +Dali::RelativeToConstraintFloat::RelativeToConstraintFloat( float scale ) +Dali::EqualToConstraint::operator()( Matrix& current, const PropertyInputContainer& inputs ) +Dali::EqualToConstraint::operator()( Matrix3& current, const PropertyInputContainer& inputs ) +Dali::EqualToConstraint::operator()( Quaternion& current, const PropertyInputContainer& inputs ) +Dali::EqualToConstraint::operator()( Vector2& current, const PropertyInputContainer& inputs ) +Dali::RelativeToConstraint::operator()( Vector3& current, const PropertyInputContainer& inputs ) +Dali::EqualToConstraint::operator()( Vector3& current, const PropertyInputContainer& inputs ) +Dali::EqualToConstraint::operator()( Vector4& current, const PropertyInputContainer& inputs ) +Dali::RelativeToConstraintFloat::operator()( float& current, const PropertyInputContainer& inputs ) +Dali::EqualToConstraint::operator()( float& current, const PropertyInputContainer& inputs ) +Dali::KeyFrames::Add(float progress, Property::Value value); +Dali::KeyFrames::Add(float progress, Property::Value value, AlphaFunction alpha); +Dali::KeyFrames::DownCast( BaseHandle handle ); +Dali::KeyFrames::GetType() const; +Dali::KeyFrames::KeyFrames(); +Dali::KeyFrames::KeyFrames(const KeyFrames& handle); +Dali::KeyFrames::New(); +Dali::KeyFrames::operator=(const KeyFrames& rhs); +Dali::KeyFrames::~KeyFrames(); +Dali::LinearConstrainer::Apply( Dali::Property target, Dali::Property source, const Vector2& range, const Vector2& wrap = Vector2(-FLT_MAX, FLT_MAX) ); +Dali::LinearConstrainer::DownCast( BaseHandle handle ); +Dali::LinearConstrainer::LinearConstrainer(); +Dali::LinearConstrainer::LinearConstrainer(const LinearConstrainer& handle); +Dali::LinearConstrainer::New(); +Dali::LinearConstrainer::Remove( Dali::Handle& target ); +Dali::LinearConstrainer::operator=(const LinearConstrainer& rhs); +Dali::LinearConstrainer::~LinearConstrainer(); +Dali::Path::AddControlPoint(const Vector3& point ); +Dali::Path::AddPoint(const Vector3& point ); +Dali::Path::DownCast( BaseHandle handle ); +Dali::Path::GenerateControlPoints( float curvature ); +Dali::Path::GetControlPoint( size_t index ); +Dali::Path::GetPoint( size_t index ); +Dali::Path::GetPointCount() const; +Dali::Path::New(); +Dali::Path::Path(); +Dali::Path::Path(const Path& handle); +Dali::Path::Sample( float progress, Vector3& position, Vector3& tangent ) const; +Dali::Path::operator=(const Path& rhs); +Dali::Path::~Path(); +Dali::TimePeriod::TimePeriod(float delaySeconds, float durationSeconds); +Dali::TimePeriod::TimePeriod(float durationSeconds); +Dali::TimePeriod::~TimePeriod(); +Dali::DaliAssertMessage( const char* location, const char* condition ); +Dali::DaliException::DaliException( const char* location, const char* condition ); +Dali::Vector::Begin() const +Dali::VectorBase::Capacity() const; +Dali::VectorBase::Empty() const +Dali::VectorAlgorithms::Clear() +Dali::Vector::Clear() +Dali::VectorAlgorithms::Copy( const VectorBase& rhs, SizeType elementSize ) +Dali::VectorBase::Copy( const VectorBase& vector, SizeType elementSize ); +Dali::VectorBase::CopyMemory( char* destination, const char* source, size_t numberOfBytes ); +Dali::VectorBase::Count() const +Dali::Vector::End() const +Dali::Vector::Erase( Iterator first, Iterator last ) +Dali::Vector::Erase( Iterator iterator ) +Dali::VectorAlgorithms::Erase( char* first, char* last, SizeType elementSize ) +Dali::VectorBase::Erase( char* first, char* last, SizeType elementSize ); +Dali::VectorAlgorithms::Erase( char* address, SizeType elementSize ) +Dali::VectorBase::Erase( char* address, SizeType elementSize ); +Dali::Vector::Insert( Iterator at, Iterator from, Iterator to ) +Dali::Vector::Insert( Iterator at, const ItemType& element ) +Dali::VectorAlgorithms::Insert( char* at, char* from, char* to, SizeType elementSize ) +Dali::Vector::PushBack( const ItemType& element ) +Dali::VectorAlgorithms::Release() +Dali::Vector::Release() +Dali::VectorBase::Release(); +Dali::Vector::Remove( Iterator iterator ) +Dali::Vector::Reserve( SizeType count ) +Dali::VectorAlgorithms::Reserve( SizeType count, SizeType elementSize ) +Dali::VectorBase::Reserve( SizeType count, SizeType elementSize ); +Dali::Vector::Resize( SizeType count, ItemType item = ItemType() ) +Dali::Vector::Resize( SizeType count, const ItemType& item) +Dali::Vector::Resize( SizeType count ) +Dali::VectorAlgorithms::Resize( SizeType count, SizeType elementSize ) +Dali::VectorBase::SetCount( SizeType count ); +Dali::VectorBase::Size() const +Dali::Vector::Swap( Vector& vector ) +Dali::VectorBase::Swap( VectorBase& vector ); +Dali::Vector::Vector( const Vector& vector ) +Dali::Vector::Vector() +Dali::VectorAlgorithms::VectorAlgorithms() +Dali::VectorBase::VectorBase(); +Dali::Vector::operator=( const Vector& vector ) +Dali::Vector::operator[]( SizeType index ) +Dali::Vector::operator[]( SizeType index ) const +Dali::Vector::~Vector() +Dali::VectorAlgorithms::~VectorAlgorithms() +Dali::VectorBase::~VectorBase(); +Dali::Vector::begin() const +Dali::Vector::end() const +Dali::IntrusivePtr::Detach() +Dali::IntrusivePtr::Get() const +Dali::IntrusivePtr::IntrusivePtr( IntrusivePtr const& rhs ) : mPtr( rhs.mPtr ) +Dali::IntrusivePtr::IntrusivePtr( IntrusivePtr const& rhs ) : mPtr( rhs.Get() ) +Dali::IntrusivePtr::IntrusivePtr( T* p ) : mPtr( p ) +Dali::IntrusivePtr::IntrusivePtr() : mPtr( 0 ) {} +Dali::IntrusivePtr::Reset( T* rhs ) +Dali::IntrusivePtr::Reset() +Dali::IntrusivePtr::Swap( IntrusivePtr& rhs ) +Dali::IntrusivePtr::ThisIsSaferThanReturningVoidStar() const {} +Dali::operator!=( IntrusivePtrconst& lhs, IntrusivePtrconst &rhs) +Dali::operator!=( IntrusivePtrconst& lhs, U* rhs ) +Dali::operator!=( T* lhs, IntrusivePtrconst& rhs ) +Dali::IntrusivePtr::operator*() const +Dali::IntrusivePtr::operator->() const +Dali::IntrusivePtr::operator=( IntrusivePtr const& rhs ) +Dali::IntrusivePtr::operator=( T* rhs ) +Dali::operator==( IntrusivePtrconst& lhs, IntrusivePtrconst& rhs ) +Dali::operator==( IntrusivePtrconst& lhs, U* rhs ) +Dali::operator==( T* lhs, IntrusivePtrconst& rhs ) +Dali::IntrusivePtr::operator BooleanType() const +Dali::IntrusivePtr::~IntrusivePtr() +Dali::Stage::Add(Actor& actor); +Dali::Stage::ContextLostSignal(); +Dali::Stage::ContextRegainedSignal(); +Dali::Stage::EventProcessingFinishedSignal(); +Dali::Stage::GetBackgroundColor() const; +Dali::Stage::GetCurrent(); +Dali::Stage::GetDpi() const; +Dali::Stage::GetLayer(unsigned int depth) const; +Dali::Stage::GetLayerCount() const; +Dali::Stage::GetObjectRegistry() const; +Dali::Stage::GetRenderTaskList() const; +Dali::Stage::GetRootLayer() const; +Dali::Stage::GetSize() const; +Dali::Stage::IsInstalled(); +Dali::Stage::KeepRendering( float durationSeconds ); +Dali::Stage::KeyEventSignal(); +Dali::Stage::Remove(Actor& actor); +Dali::Stage::SceneCreatedSignal(); +Dali::Stage::SetBackgroundColor(Vector4 color); +Dali::Stage::Stage(); +Dali::Stage::Stage(const Stage& handle); +Dali::Stage::TouchSignal() +Dali::Stage::WheelEventSignal(); +Dali::Stage::operator=(const Stage& rhs); +Dali::Stage::~Stage(); +Dali::GestureDetector::Attach(Actor actor); +Dali::GestureDetector::Detach(Actor actor); +Dali::GestureDetector::DetachAll(); +Dali::GestureDetector::DownCast( BaseHandle handle ); +Dali::GestureDetector::GestureDetector(); +Dali::GestureDetector::GestureDetector(const GestureDetector& handle); +Dali::GestureDetector::GetAttachedActor(size_t index) const; +Dali::GestureDetector::GetAttachedActorCount() const; +Dali::GestureDetector::operator=(const GestureDetector& rhs); +Dali::GestureDetector::~GestureDetector(); +Dali::Gesture::Gesture( const Gesture& rhs ); +Dali::Gesture::Gesture(Type gestureType, State gestureState); +Dali::Gesture::operator=( const Gesture& rhs ); +Dali::Gesture::~Gesture(); +Dali::HoverEvent::GetPoint(unsigned int point) const; +Dali::HoverEvent::GetPointCount() const; +Dali::HoverEvent::HoverEvent(); +Dali::HoverEvent::HoverEvent(unsigned long time); +Dali::HoverEvent::~HoverEvent(); +Dali::KeyEvent::IsAltModifier() const; +Dali::KeyEvent::IsCtrlModifier() const; +Dali::KeyEvent::IsShiftModifier() const; +Dali::KeyEvent::KeyEvent(); +Dali::KeyEvent::KeyEvent(const std::string& keyName, const std::string& keyString, int keyCode, int keyModifier, unsigned long timeStamp, const State& keyState); +Dali::KeyEvent::~KeyEvent(); +Dali::KeyEvent::KeyEvent( const KeyEvent& rhs ); +Dali::KeyEvent::KeyEvent& operator=( const KeyEvent& rhs ); +Dali::KeyEvent::GetDeviceClass()const +Dali::KeyEvent::GetDeviceName()const +Dali::KeyEvent::GetDeviceSubclass()const +Dali::LongPressGestureDetector::DetectedSignal(); +Dali::LongPressGestureDetector::DownCast( BaseHandle handle ); +Dali::LongPressGestureDetector::GetMaximumTouchesRequired() const; +Dali::LongPressGestureDetector::GetMinimumTouchesRequired() const; +Dali::LongPressGestureDetector::LongPressGestureDetector(); +Dali::LongPressGestureDetector::LongPressGestureDetector(const LongPressGestureDetector& handle); +Dali::LongPressGestureDetector::New(); +Dali::LongPressGestureDetector::New(unsigned int minTouches, unsigned int maxTouches); +Dali::LongPressGestureDetector::New(unsigned int touchesRequired); +Dali::LongPressGestureDetector::SetTouchesRequired(unsigned int minTouches, unsigned int maxTouches); +Dali::LongPressGestureDetector::SetTouchesRequired(unsigned int touches); +Dali::LongPressGestureDetector::operator=(const LongPressGestureDetector& rhs); +Dali::LongPressGestureDetector::~LongPressGestureDetector(); +Dali::LongPressGesture::LongPressGesture( const LongPressGesture& rhs ); +Dali::LongPressGesture::LongPressGesture(Gesture::State state); +Dali::LongPressGesture::operator=( const LongPressGesture& rhs ); +Dali::LongPressGesture::~LongPressGesture(); +Dali::PanGestureDetector::AddAngle( Radian angle, Radian threshold = DEFAULT_THRESHOLD ); +Dali::PanGestureDetector::AddDirection( Radian direction, Radian threshold = DEFAULT_THRESHOLD ); +Dali::PanGestureDetector::ClearAngles(); +Dali::PanGestureDetector::DetectedSignal(); +Dali::PanGestureDetector::DownCast( BaseHandle handle ); +Dali::PanGestureDetector::GetAngle(size_t index) const; +Dali::PanGestureDetector::GetAngleCount() const; +Dali::PanGestureDetector::GetMaximumTouchesRequired() const; +Dali::PanGestureDetector::GetMinimumTouchesRequired() const; +Dali::PanGestureDetector::New(); +Dali::PanGestureDetector::PanGestureDetector(); +Dali::PanGestureDetector::PanGestureDetector(const PanGestureDetector& handle); +Dali::PanGestureDetector::RemoveAngle( Radian angle ); +Dali::PanGestureDetector::RemoveDirection( Radian direction ); +Dali::PanGestureDetector::SetMaximumTouchesRequired(unsigned int maximum); +Dali::PanGestureDetector::SetMinimumTouchesRequired(unsigned int minimum); +Dali::PanGestureDetector::SetPanGestureProperties( const PanGesture& pan ); +Dali::PanGestureDetector::operator=(const PanGestureDetector& rhs); +Dali::PanGestureDetector::~PanGestureDetector(); +Dali::PanGesture::GetDistance() const; +Dali::PanGesture::GetScreenDistance() const; +Dali::PanGesture::GetScreenSpeed() const; +Dali::PanGesture::GetSpeed() const; +Dali::PanGesture::PanGesture( const PanGesture& rhs ); +Dali::PanGesture::PanGesture(); +Dali::PanGesture::PanGesture(Gesture::State state); +Dali::PanGesture::operator=( const PanGesture& rhs ); +Dali::PanGesture::~PanGesture(); +Dali::PinchGestureDetector::DetectedSignal(); +Dali::PinchGestureDetector::DownCast( BaseHandle handle ); +Dali::PinchGestureDetector::New(); +Dali::PinchGestureDetector::PinchGestureDetector(); +Dali::PinchGestureDetector::PinchGestureDetector(const PinchGestureDetector& handle); +Dali::PinchGestureDetector::operator=(const PinchGestureDetector& rhs); +Dali::PinchGestureDetector::~PinchGestureDetector(); +Dali::PinchGesture::PinchGesture( const PinchGesture& rhs ); +Dali::PinchGesture::PinchGesture(Gesture::State state); +Dali::PinchGesture::operator=( const PinchGesture& rhs ); +Dali::PinchGesture::~PinchGesture(); +Dali::TapGestureDetector::DetectedSignal(); +Dali::TapGestureDetector::DownCast( BaseHandle handle ); +Dali::TapGestureDetector::GetMaximumTapsRequired() const; +Dali::TapGestureDetector::GetMinimumTapsRequired() const; +Dali::TapGestureDetector::New( unsigned int tapsRequired ); +Dali::TapGestureDetector::New(); +Dali::TapGestureDetector::SetMaximumTapsRequired( unsigned int maximumTaps ); +Dali::TapGestureDetector::SetMinimumTapsRequired( unsigned int minimumTaps ); +Dali::TapGestureDetector::TapGestureDetector(); +Dali::TapGestureDetector::TapGestureDetector(const TapGestureDetector& handle); +Dali::TapGestureDetector::operator=(const TapGestureDetector& rhs); +Dali::TapGestureDetector::~TapGestureDetector(); +Dali::TapGesture::TapGesture( const TapGesture& rhs ); +Dali::TapGesture::TapGesture(); +Dali::TapGesture::operator=( const TapGesture& rhs ); +Dali::TapGesture::~TapGesture(); +Dali::TouchData::TouchData() +Dali::TouchData::TouchData( const TouchData& other ) +Dali::TouchData::~TouchData() +Dali::TouchData::operator=( const TouchData& other ) +Dali::TouchData::GetTime() +Dali::TouchData::GetPointCount() +Dali::TouchData::GetDeviceId( size_t point ) +Dali::TouchData::GetState( size_t point ) +Dali::TouchData::GetHitActor( size_t point ) +Dali::TouchData::GetLocalPosition( size_t point ) +Dali::TouchData::GetScreenPosition( size_t point ) +Dali::TouchData::GetRadius( std::size_t point ) const +Dali::TouchData::GetEllipseRadius( std::size_t point ) const +Dali::TouchData::GetPressure( std::size_t point ) const +Dali::TouchData::GetAngle( std::size_t point ) const +Dali::TouchData::GetDeviceClass(unsignedlong) const +Dali::TouchData::GetDeviceSubclass(unsignedlong) const +Dali::TouchPoint::TouchPoint(int id, State state, float screenX, float screenY); +Dali::TouchPoint::TouchPoint(int id, State state, float screenX, float screenY, float localX, float localY); +Dali::TouchPoint::~TouchPoint(); +Dali::WheelEvent::IsAltModifier() const; +Dali::WheelEvent::IsCtrlModifier() const; +Dali::WheelEvent::IsShiftModifier() const; +Dali::WheelEvent::WheelEvent( Type type, int direction, unsigned int modifiers, Vector2 point, int z, unsigned int timeStamp ); +Dali::WheelEvent::WheelEvent(); +Dali::WheelEvent::~WheelEvent(); +Dali::NativeImageInterface::GetExtension() +Dali::NativeImageInterface::~NativeImageInterface() +Dali::Pixel::GetAlphaOffsetAndMask(Format pixelFormat, int& byteOffset, int& bitMask); +Dali::Pixel::GetBytesPerPixel(Format pixelFormat); +Dali::Pixel::HasAlpha(Format pixelformat); +Dali::AngleAxis::AngleAxis( Radian initialAngle, const Vector3& initialAxis ) +Dali::AngleAxis::AngleAxis() +Dali::operator==( const Dali::AngleAxis& lhs, const Dali::AngleAxis& rhs ) +Dali::operator<< (std::ostream& o, const Dali::AngleAxis& angleAxis) +Dali::Clamp( Degree angle, float min, float max ) +Dali::Degree::Degree( Radian value ); +Dali::Degree::Degree() +Dali::Degree::Degree( float value ) +Dali::operator!=( const Degree& lhs, const Degree& rhs ) +Dali::operator==( const Degree& lhs, const Degree& rhs ) +Dali::Clamp( const T& value, const T& min, const T& max ) +Dali::ClampInPlace( T& value, const T& min, const T& max ) +Dali::Equals( float a, float b ) +Dali::Equals( float a, float b, float epsilon ) +Dali::EqualsZero( float value ) +Dali::GetRangedEpsilon( float a, float b ) +Dali::IsPowerOfTwo( unsigned int i ) +Dali::Lerp( const float offset, const T& low, const T& high ) +Dali::NextPowerOfTwo( unsigned int i ) +Dali::Round(float value, int pos) +Dali::ShortestDistanceInDomain( float a, float b, float start, float end ) +Dali::WrapInDomain(float x, float start, float end) +Dali::Matrix::AsFloat() const {return mMatrix;} +Dali::Matrix::AsFloat() {return mMatrix;} +Dali::Matrix::GetTransformComponents(Vector3& position, +Dali::Matrix::GetTranslation() const { return reinterpret_cast(mMatrix[12]); } +Dali::Matrix::GetTranslation3() const { return reinterpret_cast(mMatrix[12]); } +Dali::Matrix::GetXAxis() const; +Dali::Matrix::GetYAxis() const; +Dali::Matrix::GetZAxis() const; +Dali::Matrix::Invert(); +Dali::Matrix::InvertTransform(Matrix& result) const; +Dali::Matrix::Matrix( const Matrix& matrix ); +Dali::Matrix::Matrix(); +Dali::Matrix::Matrix( bool initialize ); +Dali::Matrix::Matrix( const Quaternion& rotation ); +Dali::Matrix::Matrix(const float* array); +Dali::Matrix::Multiply( Matrix& result, const Matrix& lhs, const Matrix& rhs ); +Dali::Matrix::Multiply( Matrix& result, const Matrix& lhs, const Quaternion& rhs ); +Dali::Matrix::OrthoNormalize(); +Dali::Matrix::SetIdentity(); +Dali::Matrix::SetIdentityAndScale( const Vector3& scale ); +Dali::Matrix::SetInverseTransformComponents(const Vector3& scale, +Dali::Matrix::SetInverseTransformComponents(const Vector3& xAxis, +Dali::Matrix::SetTransformComponents(const Vector3& scale, +Dali::Matrix::SetTranslation(const Vector3& translation); +Dali::Matrix::SetTranslation(const Vector4& translation); +Dali::Matrix::SetXAxis(const Vector3& axis); +Dali::Matrix::SetYAxis(const Vector3& axis); +Dali::Matrix::SetZAxis(const Vector3& axis); +Dali::Matrix::Transpose(); +Dali::Matrix::operator!=(const Matrix & rhs) const; +Dali::Matrix::operator*(const Vector4& rhs) const; +Dali::Matrix::operator<< (std::ostream& o, const Matrix& matrix); +Dali::operator<< (std::ostream& o, const Matrix& matrix); +Dali::Matrix::operator=( const Matrix& matrix ); +Dali::Matrix::operator==(const Matrix & rhs) const; +Dali::Matrix3::AsFloat() const {return &mElements[0];} +Dali::Matrix3::AsFloat() {return &mElements[0];} +Dali::Matrix3::Invert(); +Dali::Matrix3::Magnitude() const; +Dali::Matrix3::Matrix3(); +Dali::Matrix3::Matrix3(const Matrix& m); +Dali::Matrix3::Matrix3(const Matrix3& m); +Dali::Matrix3::Matrix3(float s00, float s01, float s02, float s10, float s11, float s12, float s20, float s21, float s22); +Dali::Matrix3::Multiply( Matrix3& result, const Matrix3& lhs, const Matrix3& rhs ); +Dali::Matrix3::Scale(float scale); +Dali::Matrix3::ScaledInverseTranspose(); +Dali::Matrix3::SetIdentity(); +Dali::Matrix3::Transpose(); +Dali::Matrix3::operator!=(const Matrix3 & rhs) const; +Dali::Matrix3::operator<< (std::ostream& o, const Matrix3& matrix); +Dali::operator<< (std::ostream& o, const Matrix3& matrix); +Dali::Matrix3::operator=( const Matrix& matrix ); +Dali::Matrix3::operator=( const Matrix3& matrix ); +Dali::Matrix3::operator==(const Matrix3 & rhs) const; +Dali::Matrix3::~Matrix3() +Dali::Quaternion::AngleBetween( const Quaternion& q1, const Quaternion& q2 ); +Dali::Quaternion::AsVector() const; +Dali::Quaternion::Conjugate(); +Dali::Quaternion::Dot( const Quaternion &q1, const Quaternion &q2 ); +Dali::Quaternion::EulerAngles() const; +Dali::Quaternion::Exp() const; +Dali::Quaternion::Invert(); +Dali::Quaternion::IsIdentity() const; +Dali::Quaternion::Length() const; +Dali::Quaternion::LengthSquared() const; +Dali::Quaternion::Lerp( const Quaternion &q1, const Quaternion &q2, float t ); +Dali::Quaternion::Log() const; +Dali::Quaternion::Normalize(); +Dali::Quaternion::Normalized() const; +Dali::Quaternion::Quaternion( Radian angle, const Vector3& axis ); +Dali::Quaternion::Quaternion( Radian pitch, Radian yaw, Radian roll ); +Dali::Quaternion::Quaternion( float cosThetaBy2, float iBySineTheta, float jBySineTheta, float kBySineTheta ); +Dali::Quaternion::Quaternion(); +Dali::Quaternion::Quaternion( const Vector3& v0, const Vector3& v1 ); +Dali::Quaternion::Quaternion( const Vector3& xAxis, const Vector3& yAxis, const Vector3& zAxis ); +Dali::Quaternion::Quaternion( const Vector4& vector ); +Dali::Quaternion::Quaternion(const Matrix& matrix); +Dali::Quaternion::Rotate( const Vector3& vector ) const; +Dali::Quaternion::Rotate( const Vector4& vector ) const; +Dali::Quaternion::SetEuler( Radian pitch, Radian yaw, Radian roll ); +Dali::Quaternion::Slerp( const Quaternion &q1, const Quaternion &q2, float progress ); +Dali::Quaternion::SlerpNoInvert( const Quaternion &q1, const Quaternion &q2, float t ); +Dali::Quaternion::Squad( const Quaternion& start, const Quaternion& end, const Quaternion& ctrl1, const Quaternion& ctrl2, float t ); +Dali::Quaternion::ToAxisAngle( Vector3& axis, Radian& angle ) const; +Dali::Quaternion::operator!=( const Quaternion& rhs ) const; +Dali::Quaternion::operator*( const Vector3& other ) const; +Dali::Quaternion::operator*( const Quaternion& other ) const; +Dali::Quaternion::operator*( float scale ) const; +Dali::Quaternion::operator*=( const Quaternion& other ); +Dali::Quaternion::operator*=( float scale ); +Dali::Quaternion::operator+( const Quaternion& other ) const; +Dali::Quaternion::operator+=( const Quaternion& other ); +Dali::Quaternion::operator-() const; +Dali::Quaternion::operator-( const Quaternion& other ) const; +Dali::Quaternion::operator-=( const Quaternion& other ); +Dali::Quaternion::operator/( const Quaternion& other ) const; +Dali::Quaternion::operator/( float scale ) const; +Dali::Quaternion::operator/=( float scale ); +Dali::operator<< (std::ostream& o, const Quaternion& quaternion); +Dali::Quaternion::operator==( const Quaternion& rhs ) const; +Dali::Quaternion::~Quaternion(); +Dali::Clamp( Radian angle, float min, float max ) +Dali::Radian::Radian( Degree degree ) +Dali::Radian::Radian() +Dali::Radian::Radian( float value ) +Dali::operator!=( Degree lhs, Radian rhs ) +Dali::operator!=( Radian lhs, Degree rhs ) +Dali::operator!=( Radian lhs, Radian rhs ) +Dali::operator*( Radian lhs, float rhs ) +Dali::operator-( Radian in ) +Dali::operator<( Degree lhs, Radian rhs ) +Dali::operator<( Radian lhs, Degree rhs ) +Dali::operator<( Radian lhs, Radian rhs ) +Dali::Radian::operator=( Degree degree ) +Dali::Radian::operator=( float value ) +Dali::operator==( Degree lhs, Radian rhs ) +Dali::operator==( Radian lhs, Degree rhs ) +Dali::operator==( Radian lhs, Radian rhs ) +Dali::operator>( Degree lhs, Radian rhs ) +Dali::operator>( Radian lhs, Degree rhs ) +Dali::operator>( Radian lhs, Radian rhs ) +Dali::Radian::operator float() const +Dali::Random::Axis() +Dali::Random::Range(float f0, float f1) +Dali::Rect::Area() const +Dali::Rect::Bottom() const +Dali::Rect::Contains(const Rect& other) const +Dali::Rect::Intersects(const Rect& other) const +Dali::Rect::IsEmpty() const +Dali::Rect::IsEmpty() const +Dali::Rect::Left() const +Dali::Rect::Rect() +Dali::Rect::Rect(T x, T y, T width, T height) +Dali::Rect::Rect(const Rect& rhs) +Dali::Rect::Right() const +Dali::Rect::Set(T newX, T newY, T newWidth, T newHeight) +Dali::Rect::Top() const +Dali::operator!=( const Rect& lhs, const Rect& rhs ) +Dali::operator<< (std::ostream& stream, const Rect& rectangle) +Dali::Rect::operator= (const Rect& rhs) +Dali::operator==( const Rect& lhs, const Rect& rhs ) +Dali::operator==( const Rect& lhs, const Rect& rhs ) +Dali::Uint16Pair::FromFloatArray( const FLOAT_ARRAY& from ) +Dali::Uint16Pair::FromFloatVec2( const FLOAT_VECTOR_N_TYPE& from ) +Dali::Uint16Pair::GetHeight() const +Dali::Uint16Pair::GetWidth() const +Dali::Uint16Pair::GetX() const +Dali::Uint16Pair::GetY() const +Dali::Uint16Pair::Uint16Pair( const Uint16Pair& rhs ) +Dali::Uint16Pair::Uint16Pair( uint32_t width, uint32_t height ) +Dali::Uint16Pair::Uint16Pair() : mData(0) {} +Dali::Uint16Pair::operator!=( const Uint16Pair& rhs ) const +Dali::Uint16Pair::operator<( const Uint16Pair& rhs ) const +Dali::Uint16Pair::operator==( const Uint16Pair& rhs ) const +Dali::Uint16Pair::operator>( const Uint16Pair& rhs ) const +Dali::Uint16Pair::operator=( const Uint16Pair& rhs ) +Dali::Uint16Pair::SetWidth( uint16_t width ) +Dali::Uint16Pair::SetHeight( uint16_t height ) +Dali::Uint16Pair::SetX( uint16_t x ) +Dali::Uint16Pair::SetY( uint16_t y ) +Dali::Vector2::AsFloat() const {return &x;} +Dali::Vector2::AsFloat() {return &x;} +Dali::Vector2::Clamp( const Vector2& min, const Vector2& max ); +Dali::Clamp( const Vector2& v, const float& min, const float& max ); +Dali::Vector2::Length() const; +Dali::Vector2::LengthSquared() const; +Dali::Max( const Vector2& a, const Vector2& b ) +Dali::Min( const Vector2& a, const Vector2& b ) +Dali::Vector2::Normalize(); +Dali::Vector2::Vector2() +Dali::Vector2::Vector2(const Vector3& vec3); +Dali::Vector2::Vector2(const Vector4& vec4); +Dali::Vector2::Vector2(const float* array) +Dali::Vector2::Vector2(float x, float y) +Dali::Vector2::operator!=(const Vector2& rhs) const +Dali::Vector2::operator*(const Vector2& rhs) const +Dali::Vector2::operator*(float rhs) const +Dali::Vector2::operator*=(const Vector2& rhs) +Dali::Vector2::operator*=(float rhs) +Dali::Vector2::operator+(const Vector2& rhs) const +Dali::Vector2::operator+=(const Vector2& rhs) +Dali::Vector2::operator-() const +Dali::Vector2::operator-(const Vector2& rhs) const +Dali::Vector2::operator-=(const Vector2& rhs) +Dali::Vector2::operator/(const Vector2& rhs) const +Dali::Vector2::operator/(float rhs) const +Dali::Vector2::operator/=(const Vector2& rhs) +Dali::Vector2::operator/=(float rhs) +Dali::operator<< (std::ostream& o, const Vector2& vector); +Dali::Vector2::operator=(const Vector3& rhs); +Dali::Vector2::operator=(const Vector4& rhs); +Dali::Vector2::operator=(const float* array) +Dali::Vector2::operator==(const Vector2& rhs) const; +Dali::Vector2::operator[](const unsigned int index) const +Dali::Vector2::operator[](const unsigned int index) +Dali::Vector3::AsFloat() const {return &x;} +Dali::Vector3::AsFloat() {return &x;} +Dali::Vector3::Clamp( const Vector3& min, const Vector3& max ); +Dali::Clamp( const Vector3& v, const float& min, const float& max ); +Dali::Vector3::Cross(const Vector3& other) const; +Dali::Vector3::Dot(const Vector3& other) const; +Dali::Vector3::GetVectorXY() {return reinterpret_cast(x);} +Dali::Vector3::GetVectorXY() const {return reinterpret_cast(x);} +Dali::Vector3::GetVectorYZ() {return reinterpret_cast(y);} +Dali::Vector3::GetVectorYZ() const {return reinterpret_cast(y);} +Dali::Vector3::Length() const; +Dali::Vector3::LengthSquared() const; +Dali::Max( const Vector3& a, const Vector3& b ) +Dali::Min( const Vector3& a, const Vector3& b ) +Dali::Vector3::Normalize(); +Dali::Vector3::Vector3() +Dali::Vector3::Vector3( const Vector2& vec2 ); +Dali::Vector3::Vector3( const Vector4& vec4 ); +Dali::Vector3::Vector3(const float* array) +Dali::Vector3::Vector3(float x, float y, float z) +Dali::Vector3::operator!=(const Vector3& rhs) const +Dali::Vector3::operator*(const Vector3& rhs) const +Dali::Vector3::operator*(float rhs) const +Dali::Vector3::operator*=(const Quaternion& rhs); +Dali::Vector3::operator*=(const Vector3& rhs) +Dali::Vector3::operator*=(float rhs) +Dali::Vector3::operator+(const Vector3& rhs) const +Dali::Vector3::operator+=(const Vector3& rhs) +Dali::Vector3::operator-() const +Dali::Vector3::operator-(const Vector3& rhs) const +Dali::Vector3::operator-=(const Vector3& rhs) +Dali::Vector3::operator/(const Vector3& rhs) const +Dali::Vector3::operator/(float rhs) const +Dali::Vector3::operator/=(const Vector3& rhs) +Dali::Vector3::operator/=(float rhs) +Dali::operator<< (std::ostream& o, const Vector3& vector); +Dali::Vector3::operator=(const Vector2& rhs); +Dali::Vector3::operator=(const Vector4& rhs); +Dali::Vector3::operator=(const float* array) +Dali::Vector3::operator==(const Vector3& rhs) const; +Dali::Vector3::operator[](const unsigned int index) const +Dali::Vector3::operator[](const unsigned int index) +Dali::Vector4::AsFloat() const {return &x;} +Dali::Vector4::AsFloat() {return &x;} +Dali::Vector4::Clamp( const Vector4& min, const Vector4& max ); +Dali::Clamp( const Vector4& v, const float& min, const float& max ); +Dali::Vector4::Cross(const Vector4& other) const; +Dali::Vector4::Dot(const Vector3& other) const; +Dali::Vector4::Dot(const Vector4& other) const; +Dali::Vector4::Dot4(const Vector4& other) const; +Dali::Vector4::Length() const; +Dali::Vector4::LengthSquared() const; +Dali::Max( const Vector4& a, const Vector4& b ) +Dali::Min( const Vector4& a, const Vector4& b ) +Dali::Vector4::Normalize(); +Dali::Vector4::Vector4() +Dali::Vector4::Vector4( const Vector2& vec2 ); +Dali::Vector4::Vector4( const Vector3& vec3 ); +Dali::Vector4::Vector4(const float* array) +Dali::Vector4::Vector4(float x, float y, float z, float w) +Dali::Vector4::operator!=(const Vector4 &rhs) const +Dali::Vector4::operator*(const Vector4& rhs) const +Dali::Vector4::operator*(float rhs) const +Dali::Vector4::operator*=(const Vector4& rhs) +Dali::Vector4::operator*=(float rhs) +Dali::Vector4::operator+(const Vector4 & rhs) const +Dali::Vector4::operator+=(const Vector4& rhs) +Dali::Vector4::operator-() const +Dali::Vector4::operator-(const Vector4& rhs) const +Dali::Vector4::operator-=(const Vector4& rhs) +Dali::Vector4::operator/(const Vector4 & rhs) const +Dali::Vector4::operator/(float rhs) const +Dali::Vector4::operator/=(const Vector4& rhs) +Dali::Vector4::operator/=(float rhs) +Dali::operator<<(std::ostream& o, const Vector4& vector); +Dali::Vector4::operator=(const Vector2& vec2 ); +Dali::Vector4::operator=(const Vector3& vec3 ); +Dali::Vector4::operator=(const float* array) +Dali::Vector4::operator==(const Vector4 &rhs) const; +Dali::Vector4::operator[](const unsigned int index) const +Dali::Vector4::operator[](const unsigned int index) +Dali::Any::Any( const Any& any ) +Dali::Any::Any( const Type& value ) +Dali::Any::Any(); +Dali::AnyCast( Any& any ) +Dali::AnyCast( const Any& any ) +Dali::AnyCast( Any* any ) +Dali::AnyCast( const Any* any ) +Dali::AnyCastReference( Any& any ) +Dali::AnyCastReference( const Any& any ) +Dali::Any::AnyContainerBase::AnyContainerBase( const std::type_info& type, CloneFunc cloneFunc, DeleteFunc deleteFunc ) +Dali::Any::AnyContainerImpl::AnyContainerImpl( const AnyContainerBase& base ) +Dali::Any::AnyContainerImpl::AnyContainerImpl( const Type& value ) +Dali::Any::AssertAlways( const char* assertMessage ); +Dali::Any::AnyContainerImplCloner::Clone( const AnyContainerBase& base ) +Dali::Any::AnyContainerImplDelete::Delete( const AnyContainerBase* base ) +Dali::Any::Empty() const +Dali::Any::Get() const +Dali::Any::Get( Type& type ) const +Dali::Any::GetPointer() +Dali::Any::GetPointer() const +Dali::Any::AnyContainerImpl::GetPointerToValue() +Dali::Any::AnyContainerImpl::GetPointerToValue() const +Dali::Any::AnyContainerBase::GetType() const +Dali::Any::GetType() const; +Dali::Any::AnyContainerImpl::GetValue() const +Dali::Any::AnyContainerImpl::SetValue( const Type& value ) +Dali::Any::operator=( const Type& value ) +Dali::Any::operator=( const Any& any ); +Dali::Any::~Any(); +Dali::BaseHandle::BaseHandle(); +Dali::BaseHandle::BaseHandle(Dali::BaseObject* handle); +Dali::BaseHandle::BaseHandle(const BaseHandle& handle); +Dali::BaseHandle::ConnectSignal( ConnectionTrackerInterface* connectionTracker, const std::string& signalName, const T& functor ) +Dali::BaseHandle::DoAction(const std::string& actionName, const Property::Map& attributes); +Dali::DownCast( BaseHandle handle ) +Dali::BaseHandle::GetBaseObject(); +Dali::BaseHandle::GetBaseObject() const; +Dali::BaseHandle::GetObjectPtr() const; +Dali::BaseHandle::GetTypeInfo(Dali::TypeInfo& info) const; +Dali::BaseHandle::GetTypeName() const; +Dali::BaseHandle::Reset(); +Dali::BaseHandle::ThisIsSaferThanReturningVoidStar() const {} +Dali::BaseHandle::operator!=(const BaseHandle& rhs) const; +Dali::operator!=(const BaseHandle& lhs, const T& rhs) +Dali::operator<(const BaseHandle& lhs, const BaseHandle& rhs) +Dali::BaseHandle::operator=(const BaseHandle& rhs); +Dali::BaseHandle::operator==(const BaseHandle& rhs) const; +Dali::operator==(const BaseHandle& lhs, const T& rhs) +Dali::BaseHandle::operator BooleanType() const; +Dali::BaseHandle::~BaseHandle(); +Dali::BaseObject::BaseObject(); +Dali::BaseObject::ConnectSignal( ConnectionTrackerInterface* connectionTracker, const std::string& signalName, const T& functor ) +Dali::BaseObject::DoAction(const std::string& actionName, const Property::Map& attributes); +Dali::BaseObject::DoConnectSignal( ConnectionTrackerInterface* connectionTracker, const std::string& signalName, FunctorDelegate* functorDelegate ); +Dali::GetImplementation(Dali::BaseHandle& handle) +Dali::GetImplementation(const Dali::BaseHandle& handle) +Dali::BaseObject::GetTypeInfo(Dali::TypeInfo& info) const; +Dali::BaseObject::GetTypeName() const; +Dali::BaseObject::RegisterObject(); +Dali::BaseObject::UnregisterObject(); +Dali::BaseObject::~BaseObject(); +Dali::Handle::AddPropertyNotification( Property::Index index, +Dali::Handle::AddPropertyNotification( Property::Index index, +Dali::Handle::DownCast( BaseHandle handle ); +Dali::Handle::GetProperty( Property::Index index ) const; +Dali::Handle::GetProperty( Property::Index index ) const +Dali::Handle::GetPropertyCount() const; +Dali::Handle::GetPropertyIndex( const std::string& name ) const; +Dali::Handle::GetPropertyIndices( Property::IndexContainer& indices ) const; +Dali::Handle::GetPropertyName( Property::Index index ) const; +Dali::Handle::GetPropertyType( Property::Index index ) const; +Dali::Handle::GetCurrentProperty( Property::Index index ) const; +Dali::Handle::Handle( Dali::Internal::Object* handle ); +Dali::Handle::Handle( const Handle& handle ); +Dali::Handle::Handle(); +Dali::Handle::IsPropertyAConstraintInput( Property::Index index ) const; +Dali::Handle::IsPropertyAnimatable( Property::Index index ) const; +Dali::Handle::IsPropertyWritable( Property::Index index ) const; +Dali::Handle::New(); +Dali::WeightObject::New(); +Dali::Handle::RegisterProperty( const std::string& name, const Property::Value& propertyValue ); +Dali::Handle::RegisterProperty( const std::string& name, const Property::Value& propertyValue, Property::AccessMode accessMode ); +Dali::Handle::RemoveConstraints( unsigned int tag ); +Dali::Handle::RemoveConstraints(); +Dali::Handle::RemovePropertyNotification( Dali::PropertyNotification propertyNotification ); +Dali::Handle::RemovePropertyNotifications(); +Dali::Handle::SetProperty( Property::Index index, const Property::Value& propertyValue ); +Dali::Handle::Supports( Capability capability ) const; +Dali::Handle::operator=( const Handle& rhs ); +Dali::Handle::~Handle(); +Dali::ObjectRegistry::ObjectCreatedSignal(); +Dali::ObjectRegistry::ObjectDestroyedSignal(); +Dali::ObjectRegistry::ObjectRegistry(); +Dali::ObjectRegistry::ObjectRegistry(const ObjectRegistry& handle); +Dali::ObjectRegistry::operator=(const ObjectRegistry& rhs); +Dali::ObjectRegistry::~ObjectRegistry(); +Dali::Property::Array::Array( const Array& other ); +Dali::Property::Array::Array(); +Dali::Property::Array::Capacity(); +Dali::Property::Array::Clear(); +Dali::Property::Array::Count() const; +Dali::Property::Array::Empty() const +Dali::Property::Array::GetElementAt( SizeType index ) +Dali::Property::Array::GetElementAt( SizeType index ) const +Dali::Property::Array::PushBack( const Value& value ); +Dali::Property::Array::Reserve( SizeType size ); +Dali::Property::Array::Resize( SizeType size ); +Dali::Property::Array::Size() const +Dali::Property::Array::operator=( const Array& other ); +Dali::Property::Array::operator[]( SizeType index ); +Dali::Property::Array::operator[]( SizeType index ) const; +Dali::Property::Array::~Array(); +Dali::Property::Array::Add( const Value& value ); +Dali::PropertyCondition::GetArgument( std::size_t index ) const; +Dali::PropertyCondition::GetArgumentCount() const; +Dali::GreaterThanCondition( float arg ); +Dali::InsideCondition( float arg0, float arg1 ); +Dali::LessThanCondition( float arg ); +Dali::OutsideCondition( float arg0, float arg1 ); +Dali::PropertyCondition::PropertyCondition( const PropertyCondition& handle ); +Dali::PropertyCondition::PropertyCondition(); +Dali::StepCondition( float stepAmount, float initialValue = 0.0f ); +Dali::VariableStepCondition( const Dali::Vector& steps ); +Dali::PropertyCondition::operator=( const PropertyCondition& rhs ); +Dali::PropertyCondition::~PropertyCondition(); +Dali::PropertyInput::GetExtension() +Dali::Property::Map::Clear(); +Dali::Property::Map::Count() const; +Dali::Property::Map::Empty() const; +Dali::Property::Map::Find( const char* key ) const; +Dali::Property::Map::Find( const std::string& key ) const; +Dali::Property::Map::Find( const std::string& key, Property::Type type ) const; +Dali::Property::Map::Find(Property::Index) +Dali::Property::Map::Find(Property::Index, Property::Type) +Dali::Property::Map::Find(Property::Index, const std::string&) +Dali::Property::Map::Insert( const char* key, const Value& value ); +Dali::Property::Map::Insert( const std::string& key, const Value& value ); +Dali::Property::Map::Insert(Property::Index, const Value&) +Dali::Property::Map::Map( const Map& other ); +Dali::Property::Map::Map(); +Dali::Property::Map::Merge( const Map& from ); +Dali::Property::Map::operator=( const Map& other ); +Dali::Property::Map::operator[]( const std::string& key ); +Dali::Property::Map::operator[]( const std::string& key ) const; +Dali::Property::Map::operator[](Property::Index) +Dali::Property::Map::operator[]( Property::Index key ) const +Dali::Property::Map::~Map(); +Dali::Property::Map::GetKeyAt( SizeType position ) const; +Dali::Property::Map::GetKeyValue( SizeType position ) const; +Dali::Property::Map::Add( const char* key, const Value& value ); +Dali::Property::Map::Add( const std::string& key, const Value& value ); +Dali::Property::Map::Add( Property::Index key, const Value& value ); +Dali::PropertyNotification::DownCast( BaseHandle handle ); +Dali::PropertyNotification::GetCondition(); +Dali::PropertyNotification::GetCondition() const; +Dali::PropertyNotification::GetNotifyMode(); +Dali::PropertyNotification::GetNotifyResult() const; +Dali::PropertyNotification::GetTarget() const; +Dali::PropertyNotification::GetTargetProperty() const; +Dali::PropertyNotification::NotifySignal(); +Dali::PropertyNotification::PropertyNotification(); +Dali::PropertyNotification::PropertyNotification(const PropertyNotification& handle); +Dali::PropertyNotification::SetNotifyMode( NotifyMode mode ); +Dali::PropertyNotification::operator=(const PropertyNotification& rhs); +Dali::PropertyNotification::~PropertyNotification(); +Dali::PropertyTypes::Get() { return Property::NONE; } +Dali::PropertyTypes::Get() { return Property::ROTATION; } // Rotation has two representations +Dali::PropertyTypes::Get >() { return Property::RECTANGLE; } +Dali::PropertyTypes::Get() { return Property::MATRIX3; } +Dali::PropertyTypes::Get() { return Property::MATRIX; } +Dali::PropertyTypes::Get() { return Property::ARRAY; } +Dali::PropertyTypes::Get() { return Property::MAP; } +Dali::PropertyTypes::Get() { return Property::ROTATION; } // Rotation has two representations +Dali::PropertyTypes::Get() { return Property::VECTOR2; } +Dali::PropertyTypes::Get() { return Property::VECTOR3; } +Dali::PropertyTypes::Get() { return Property::VECTOR4; } +Dali::PropertyTypes::Get() { return Property::BOOLEAN; } +Dali::PropertyTypes::Get() { return Property::FLOAT; } +Dali::PropertyTypes::Get() { return Property::INTEGER; } +Dali::PropertyTypes::Get() { return Property::STRING; } +Dali::PropertyTypes::Get() { return Property::UNSIGNED_INTEGER; } +Dali::PropertyTypes::GetName(Property::Type type); +Dali::Property::Value::Get( AngleAxis& angleAxisValue ) const; +Dali::Property::Value::Get( Matrix& matrixValue ) const; +Dali::Property::Value::Get( Matrix3& matrixValue ) const; +Dali::Property::Value::Get( Property::Array& arrayValue ) const; +Dali::Property::Value::Get( Property::Map& mapValue ) const; +Dali::Property::Value::Get( Quaternion& quaternionValue ) const; +Dali::Property::Value::Get( Rect& rect ) const; +Dali::Property::Value::Get( Vector2& vectorValue ) const; +Dali::Property::Value::Get( Vector3& vectorValue ) const; +Dali::Property::Value::Get( Vector4& vectorValue ) const; +Dali::Property::Value::Get( bool& boolValue ) const; +Dali::Property::Value::Get( float& floatValue ) const; +Dali::Property::Value::Get( int& integerValue ) const; +Dali::Property::Value::Get( std::string& stringValue ) const; +Dali::Property::Value::GetArray() const; +Dali::Property::Value::GetMap() const; +Dali::Property::Value::GetType() const; +Dali::Property::Value::Value( Property::Array& arrayValue ); +Dali::Property::Value::Value( Property::Map& mapValue ); +Dali::Property::Value::Value( bool boolValue ); +Dali::Property::Value::Value( const AngleAxis& angleAxis ); +Dali::Property::Value::Value( const Matrix& matrixValue ); +Dali::Property::Value::Value( const Matrix3& matrixValue ); +Dali::Property::Value::Value( const Quaternion& quaternion ); +Dali::Property::Value::Value( const Rect& vectorValue ); +Dali::Property::Value::Value( const Value& value ); +Dali::Property::Value::Value( const Vector2& vectorValue ); +Dali::Property::Value::Value( const Vector3& vectorValue ); +Dali::Property::Value::Value( const Vector4& vectorValue ); +Dali::Property::Value::Value( const char* stringValue ); +Dali::Property::Value::Value( const std::string& stringValue ); +Dali::Property::Value::Value( float floatValue ); +Dali::Property::Value::Value( int integerValue ); +Dali::Property::Value::Value(); +Dali::Property::Value::Value( Type type ); +Dali::Property::Value::operator<<( std::ostream& ouputStream, const Property::Value& value ); +Dali::operator<<( std::ostream& ouputStream, const Property::Value& value ); +Dali::operator<<( std::ostream& stream, const Property::Array& array ); +Dali::operator<<( std::ostream& stream, const Property::Map& map ); +Dali::Property::Value::operator=( const Value& value ); +Dali::Property::Value::~Value(); +Dali::Property::Value::Value( const Extents& ) +Dali::Property::Value::Get( Extents& extentsValue ) const +Dali::Property::Property( Handle& object, Property::Index propertyIndex ); +Dali::Property::Property( Handle& object, Property::Index propertyIndex, int componentIndex ); +Dali::Property::Property( Handle& object, const std::string& propertyName ); +Dali::Property::Property( Handle& object, const std::string& propertyName, int componentIndex ); +Dali::Property::~Property(); +Dali::Property::Key::Key( const std::string& key ); +Dali::Property::Key::Key( Property::Index key ); +Dali::Property::Key::operator== (const std::string& rhs); +Dali::Property::Key::operator== (Property::Index rhs); +Dali::Property::Key::operator== (const Key& rhs); +Dali::Property::Key::operator!= (const std::string& rhs); +Dali::Property::Key::operator!= (Property::Index rhs); +Dali::Property::Key::operator!= (const Key& rhs); +Dali::Property::Key::operator<<( std::ostream& stream, const Property::Key& key ); +Dali::RefObject::RefObject(); +Dali::RefObject::RefObject(const RefObject& rhs); +Dali::RefObject::Reference(); +Dali::RefObject::ReferenceCount(); +Dali::RefObject::Unreference(); +Dali::RefObject::operator=(const RefObject& rhs); +Dali::RefObject::~RefObject(); +Dali::TypeInfo::CreateInstance() const; +Dali::TypeInfo::GetActionCount() const; +Dali::TypeInfo::GetActionName(size_t index); +Dali::TypeInfo::GetBaseName() const; +Dali::TypeInfo::GetCreator() const; +Dali::TypeInfo::GetName() const; +Dali::TypeInfo::GetPropertyCount() const; +Dali::TypeInfo::GetPropertyIndices( Property::IndexContainer& indices ) const; +Dali::TypeInfo::GetPropertyName( Property::Index index ) const; +Dali::TypeInfo::GetSignalCount() const; +Dali::TypeInfo::GetSignalName(size_t index); +Dali::TypeInfo::TypeInfo(); +Dali::TypeInfo::TypeInfo(const TypeInfo& handle); +Dali::TypeInfo::operator=(const TypeInfo& rhs); +Dali::TypeInfo::~TypeInfo(); +Dali::AnimatablePropertyComponentRegistration::AnimatablePropertyComponentRegistration( TypeRegistration& registered, const std::string& name, Property::Index index, Property::Index baseIndex, unsigned int componentIndex ); +Dali::AnimatablePropertyRegistration::AnimatablePropertyRegistration( TypeRegistration& registered, const std::string& name, Property::Index index, Property::Type type ); +Dali::AnimatablePropertyRegistration::AnimatablePropertyRegistration( TypeRegistration& registered, const std::string& name, Property::Index index, const Property::Value& value ); +Dali::TypeRegistry::Get(); +Dali::TypeRegistry::GetTypeInfo( const std::string &uniqueTypeName ); +Dali::TypeRegistry::GetTypeInfo( const std::type_info& registerType ); +Dali::TypeRegistry::GetTypeName(size_t index) const; +Dali::TypeRegistry::GetTypeNameCount() const; +Dali::PropertyRegistration::PropertyRegistration( TypeRegistration& registered, const std::string &name, Property::Index index, Property::Type type, TypeInfo::SetPropertyFunction setFunc, TypeInfo::GetPropertyFunction getFunc) +Dali::ChildPropertyRegistration::ChildPropertyRegistration( TypeRegistration& registered, const std::string& name, Property::Index index, Property::Type type ); +Dali::TypeRegistration::RegisteredName() const; +Dali::SignalConnectorType::SignalConnectorType( TypeRegistration& typeRegistration, const std::string& name, TypeInfo::SignalConnectorFunction func ); +Dali::TypeAction::TypeAction( TypeRegistration ®istered, const std::string &name, TypeInfo::ActionFunction f); +Dali::TypeRegistration::TypeRegistration( const std::string& name, const std::type_info& baseType, +Dali::TypeRegistration::TypeRegistration( const std::type_info& registerType, const std::type_info& baseType, +Dali::TypeRegistration::TypeRegistration( const std::type_info& registerType, const std::type_info& baseType, +Dali::TypeRegistry::TypeRegistry(); +Dali::TypeRegistry::TypeRegistry(const TypeRegistry& handle); +Dali::TypeRegistry::operator=(const TypeRegistry& rhs); +Dali::TypeRegistry::~TypeRegistry(); +Dali::RenderTaskList::CreateTask(); +Dali::RenderTaskList::DownCast( BaseHandle handle ); +Dali::RenderTaskList::GetTask( unsigned int index ) const; +Dali::RenderTaskList::GetTaskCount() const; +Dali::RenderTaskList::RemoveTask( RenderTask task ); +Dali::RenderTaskList::RenderTaskList(); +Dali::RenderTaskList::RenderTaskList(const RenderTaskList& handle); +Dali::RenderTaskList::operator=(const RenderTaskList& rhs); +Dali::RenderTaskList::~RenderTaskList(); +Dali::RenderTask::DownCast( BaseHandle handle ); +Dali::RenderTask::FinishedSignal(); +Dali::RenderTask::GetCameraActor() const; +Dali::RenderTask::GetClearColor() const; +Dali::RenderTask::GetClearEnabled() const; +Dali::RenderTask::GetCullMode() const; +Dali::RenderTask::GetCurrentViewportPosition() const; +Dali::RenderTask::GetCurrentViewportSize() const; +Dali::RenderTask::GetInputEnabled() const; +Dali::RenderTask::GetRefreshRate() const; +Dali::RenderTask::GetScreenToFrameBufferFunction() const; +Dali::RenderTask::GetScreenToFrameBufferMappingActor() const; +Dali::RenderTask::GetSourceActor() const; +Dali::RenderTask::GetTargetFrameBuffer() const; +Dali::RenderTask::GetViewport() const; +Dali::RenderTask::IsExclusive() const; +Dali::RenderTask::RenderTask(); +Dali::RenderTask::RenderTask(const RenderTask& handle); +Dali::RenderTask::SetCameraActor( CameraActor cameraActor ); +Dali::RenderTask::SetClearColor( const Vector4& color ); +Dali::RenderTask::SetClearEnabled( bool enabled ); +Dali::RenderTask::SetCullMode( bool cullMode ); +Dali::RenderTask::SetExclusive( bool exclusive ); +Dali::RenderTask::SetInputEnabled( bool enabled ); +Dali::RenderTask::SetRefreshRate( unsigned int refreshRate ); +Dali::RenderTask::SetScreenToFrameBufferFunction( ScreenToFrameBufferFunction conversionFunction ); +Dali::RenderTask::SetScreenToFrameBufferMappingActor( Actor mappingActor ); +Dali::RenderTask::SetSourceActor( Actor actor ); +Dali::RenderTask::SetTargetFrameBuffer( FrameBufferImage frameBuffer ); +Dali::RenderTask::SetViewport( Viewport viewport ); +Dali::RenderTask::SetViewportPosition( Vector2 position ); +Dali::RenderTask::SetViewportSize( Vector2 size ); +Dali::RenderTask::operator=(const RenderTask& rhs); +Dali::RenderTask::~RenderTask(); +Dali::RenderTask::WorldToViewport(const Vector3 &position, float& viewportX, float& viewportY) const; +Dali::RenderTask::ViewportToLocal(Actor actor, float viewportX, float viewportY, float &localX, float &localY) const; +Dali::RenderTask::SetFrameBuffer( FrameBuffer frameBuffer ) +Dali::RenderTask::GetFrameBuffer() const +Dali::BaseSignal::BaseSignal(); +Dali::BaseSignal::Emit( Arg0 arg0 ) +Dali::BaseSignal::Emit( Arg0 arg0, Arg1 arg1 ) +Dali::BaseSignal::Emit( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) +Dali::BaseSignal::Emit(); +Dali::BaseSignal::EmitGuard::EmitGuard( bool& flag ); +Dali::BaseSignal::EmitReturn( Arg0 arg0 ) +Dali::BaseSignal::EmitReturn( Arg0 arg0, Arg1 arg1 ) +Dali::BaseSignal::EmitReturn( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) +Dali::BaseSignal::EmitReturn() +Dali::BaseSignal::Empty() const; +Dali::BaseSignal::EmitGuard::ErrorOccurred(); +Dali::BaseSignal::GetConnectionCount() const; +Dali::BaseSignal::OnConnect( CallbackBase* callback ); +Dali::BaseSignal::OnConnect( ConnectionTrackerInterface* tracker, CallbackBase* callback ); +Dali::BaseSignal::OnDisconnect( CallbackBase* callback ); +Dali::BaseSignal::OnDisconnect( ConnectionTrackerInterface* tracker, CallbackBase* callback ); +Dali::BaseSignal::~BaseSignal(); +Dali::BaseSignal::EmitGuard::~EmitGuard(); +Dali::Callback::Callback( T* object, R(T::*memberFunction)(P1) ) +Dali::Callback::Callback( T* object, R(T::*memberFunction)(P1, P2) ) +Dali::Callback::Callback( T* object, R(T::*memberFunction)(P1, P2, P3) ) +Dali::Callback::Callback( T* object, R(T::*memberFunction)(void) ) +Dali::Callback::Callback( T* object, void(T::*memberFunction)(P1) ) +Dali::Callback::Callback( T* object, void(T::*memberFunction)(P1, P2) ) +Dali::Callback::Callback( T* object, void(T::*memberFunction)(P1, P2, P3) ) +Dali::Callback::Callback( T* object, void(T::*memberFunction)(void) ) +Dali::Callback::Callback() +Dali::CallbackBase::CallbackBase( Function function ); +Dali::CallbackBase::CallbackBase( const CallbackBase& rhs ); +Dali::CallbackBase::CallbackBase( void* object, MemberFunction function, Dispatcher dispatcher ); +Dali::CallbackBase::CallbackBase( void* object, MemberFunction function, Dispatcher dispatcher, Destructor destructor ); +Dali::CallbackBase::CallbackBase(); +Dali::CallbackFunction::CallbackFunction( R(*function)() ) +Dali::CallbackFunction::CallbackFunction( R(*function)(P1) ) +Dali::CallbackFunction::CallbackFunction( R(*function)(P1,P2) ) +Dali::CallbackFunction::CallbackFunction( R(*function)(P1,P2,P3) ) +Dali::CallbackFunction::CallbackFunction( void(*function)() ) +Dali::CallbackFunction::CallbackFunction( void(*function)(P1) ) +Dali::CallbackFunction::CallbackFunction( void(*function)(P1,P2) ) +Dali::CallbackFunction::CallbackFunction( void(*function)(P1,P2,P3) ) +Dali::CallbackFunction::CallbackFunction() +Dali::CallbackFunctor0::CallbackFunctor0( const T& object ) +Dali::CallbackFunctor1::CallbackFunctor1( const T& object ) +Dali::CallbackFunctor2::CallbackFunctor2( const T& object ) +Dali::CallbackFunctor3::CallbackFunctor3( const T& object ) +Dali::CallbackFunctorDelegate0::CallbackFunctorDelegate0( FunctorDelegate* object ) +Dali::CallbackFunctorDelegate1::CallbackFunctorDelegate1( FunctorDelegate* object ) +Dali::CallbackFunctorDelegate2::CallbackFunctorDelegate2( FunctorDelegate* object ) +Dali::CallbackFunctorDelegate3::CallbackFunctorDelegate3( FunctorDelegate* object ) +Dali::CallbackFunctorDelegateReturn0::CallbackFunctorDelegateReturn0( FunctorDelegate* object ) +Dali::CallbackFunctorDelegateReturn1::CallbackFunctorDelegateReturn1( FunctorDelegate* object ) +Dali::CallbackFunctorDelegateReturn2::CallbackFunctorDelegateReturn2( FunctorDelegate* object ) +Dali::CallbackFunctorDelegateReturn3::CallbackFunctorDelegateReturn3( FunctorDelegate* object ) +Dali::CallbackFunctorReturn0::CallbackFunctorReturn0( const T& object ) +Dali::CallbackFunctorReturn1::CallbackFunctorReturn1( const T& object ) +Dali::CallbackFunctorReturn2::CallbackFunctorReturn2( const T& object ) +Dali::CallbackFunctorReturn3::CallbackFunctorReturn3( const T& object ) +Dali::Destroyer::Delete( void* object ) +Dali::DispatcherReturn0::Dispatch( CallbackBase& callback ) +Dali::FunctorDispatcherReturn0::Dispatch( CallbackBase& callback ) +Dali::VoidFunctorDispatcherReturn0::Dispatch( CallbackBase& callback ) +Dali::DispatcherReturn1::Dispatch( CallbackBase& callback, P1 param1 ) +Dali::FunctorDispatcherReturn1::Dispatch( CallbackBase& callback, P1 param1 ) +Dali::VoidFunctorDispatcherReturn1::Dispatch( CallbackBase& callback, P1 param1 ) +Dali::DispatcherReturn2::Dispatch( CallbackBase& callback, P1 param1, P2 param2 ) +Dali::FunctorDispatcherReturn2::Dispatch( CallbackBase& callback, P1 param1, P2 param2 ) +Dali::VoidFunctorDispatcherReturn2::Dispatch( CallbackBase& callback, P1 param1, P2 param2 ) +Dali::DispatcherReturn3::Dispatch( CallbackBase& callback, P1 param1, P2 param2, P3 param3 ) +Dali::FunctorDispatcherReturn3::Dispatch( CallbackBase& callback, P1 param1, P2 param2, P3 param3 ) +Dali::VoidFunctorDispatcherReturn3::Dispatch( CallbackBase& callback, P1 param1, P2 param2, P3 param3 ) +Dali::Dispatcher0::Dispatch( CallbackBase& callback ) +Dali::FunctorDispatcher0::Dispatch( CallbackBase& callback ) +Dali::VoidFunctorDispatcher0::Dispatch( CallbackBase& callback ) +Dali::Dispatcher1::Dispatch( CallbackBase& callback, P1 param1 ) +Dali::FunctorDispatcher1::Dispatch( CallbackBase& callback, P1 param1 ) +Dali::VoidFunctorDispatcher1::Dispatch( CallbackBase& callback, P1 param1 ) +Dali::Dispatcher2::Dispatch( CallbackBase& callback, P1 param1, P2 param2 ) +Dali::FunctorDispatcher2::Dispatch( CallbackBase& callback, P1 param1, P2 param2 ) +Dali::VoidFunctorDispatcher2::Dispatch( CallbackBase& callback, P1 param1, P2 param2 ) +Dali::Dispatcher3::Dispatch( CallbackBase& callback, P1 param1, P2 param2, P3 param3 ) +Dali::FunctorDispatcher3::Dispatch( CallbackBase& callback, P1 param1, P2 param2, P3 param3 ) +Dali::VoidFunctorDispatcher3::Dispatch( CallbackBase& callback, P1 param1, P2 param2, P3 param3 ) +Dali::CallbackBase::Execute( CallbackBase& callback ) +Dali::CallbackBase::Execute( CallbackBase& callback, P1 param1 ) +Dali::CallbackBase::Execute( CallbackBase& callback, P1 param1, P2 param2 ) +Dali::CallbackBase::Execute( CallbackBase& callback, P1 param1, P2 param2, P3 param3 ) +Dali::CallbackBase::ExecuteReturn( CallbackBase& callback ) +Dali::CallbackBase::ExecuteReturn( CallbackBase& callback, P1 param1 ) +Dali::CallbackBase::ExecuteReturn( CallbackBase& callback, P1 param1, P2 param2 ) +Dali::CallbackBase::ExecuteReturn( CallbackBase& callback, P1 param1, P2 param2, P3 param3 ) +Dali::CallbackBase::Impl::Impl(); ///< Default constructor +Dali::MakeCallback( R(*function)(P1) ) +Dali::MakeCallback( R(*function)(P1,P2) ) +Dali::MakeCallback( R(*function)(P1,P2,P3) ) +Dali::MakeCallback( R(*function)(void) ) +Dali::MakeCallback( T& object, void(Base::*function)(void) ) +Dali::MakeCallback( T* object, R(T::*function)() ) +Dali::MakeCallback( T* object, R(T::*function)(P1) ) +Dali::MakeCallback( T* object, R(T::*function)(P1,P2) ) +Dali::MakeCallback( T* object, R(T::*function)(P1,P2,P3) ) +Dali::MakeCallback( T* object, void(Base::*function)(void) ) +Dali::MakeCallback( T* object, void(T::*function)(P1) ) +Dali::MakeCallback( T* object, void(T::*function)(P1,P2) ) +Dali::MakeCallback( T* object, void(T::*function)(P1,P2,P3) ) +Dali::MakeCallback( T* object, void(T::*function)(void) ) +Dali::MakeCallback( void(*function)(P1) ) +Dali::MakeCallback( void(*function)(P1,P2) ) +Dali::MakeCallback( void(*function)(P1,P2,P3) ) +Dali::MakeCallback( void(*function)(void) ) +Dali::CallbackBase::Reset(); +Dali::CallbackBase::operator=( const CallbackBase& rhs ); +Dali::CallbackBase::~CallbackBase(); +Dali::ConnectionTrackerInterface::ConnectionTrackerInterface(); +Dali::ConnectionTrackerInterface::~ConnectionTrackerInterface(); +Dali::ConnectionTracker::ConnectionTracker(); +Dali::ConnectionTracker::DisconnectAll(); +Dali::ConnectionTracker::GetConnectionCount() const; +Dali::ConnectionTracker::SignalConnected( SlotObserver* slotObserver, CallbackBase* callback ); +Dali::ConnectionTracker::SignalDisconnected( SlotObserver* slotObserver, CallbackBase* callback ); +Dali::ConnectionTracker::~ConnectionTracker(); +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, FunctorDelegate* delegate ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, FunctorDelegate* delegate ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, FunctorDelegate* delegate ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, FunctorDelegate* delegate ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, FunctorDelegate* delegate ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, FunctorDelegate* delegate ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, FunctorDelegate* delegate ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, FunctorDelegate* delegate ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, const X& func ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, const X& func ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, const X& func ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, const X& func ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, const X& func ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, const X& func ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, const X& func ) +Dali::Signal::Connect( ConnectionTrackerInterface* connectionTracker, const X& func ) +Dali::Signal::Connect( Ret (*func)( Arg0 arg0 ) ) +Dali::Signal::Connect( Ret (*func)( Arg0 arg0, Arg1 arg1 ) ) +Dali::Signal::Connect( Ret (*func)( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) ) +Dali::Signal::Connect( Ret (*func)() ) +Dali::Signal::Connect( SlotDelegate& delegate, Ret (X::*func)( Arg0 arg0 ) ) +Dali::Signal::Connect( SlotDelegate& delegate, Ret (X::*func)( Arg0 arg0, Arg1 arg1 ) ) +Dali::Signal::Connect( SlotDelegate& delegate, Ret (X::*func)( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) ) +Dali::Signal::Connect( SlotDelegate& delegate, Ret (X::*func)() ) +Dali::Signal::Connect( SlotDelegate& delegate, void (X::*func)( Arg0 arg0 ) ) +Dali::Signal::Connect( SlotDelegate& delegate, void (X::*func)( Arg0 arg0, Arg1 arg1 ) ) +Dali::Signal::Connect( SlotDelegate& delegate, void (X::*func)( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) ) +Dali::Signal::Connect( SlotDelegate& delegate, void (X::*func)() ) +Dali::Signal::Connect( X* obj, Ret (X::*func)( Arg0 arg0 ) ) +Dali::Signal::Connect( X* obj, Ret (X::*func)( Arg0 arg0, Arg1 arg1 ) ) +Dali::Signal::Connect( X* obj, Ret (X::*func)( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) ) +Dali::Signal::Connect( X* obj, Ret (X::*func)() ) +Dali::Signal::Connect( X* obj, void (X::*func)( Arg0 arg0 ) ) +Dali::Signal::Connect( X* obj, void (X::*func)( Arg0 arg0, Arg1 arg1 ) ) +Dali::Signal::Connect( X* obj, void (X::*func)( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) ) +Dali::Signal::Connect( X* obj, void (X::*func)() ) +Dali::Signal::Connect( void (*func)( Arg0 arg0 ) ) +Dali::Signal::Connect( void (*func)( Arg0 arg0, Arg1 arg1 ) ) +Dali::Signal::Connect( void (*func)( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) ) +Dali::Signal::Connect( void (*func)() ) +Dali::Signal::Disconnect( Ret (*func)( Arg0 arg0 ) ) +Dali::Signal::Disconnect( Ret (*func)( Arg0 arg0, Arg1 arg1 ) ) +Dali::Signal::Disconnect( Ret (*func)( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) ) +Dali::Signal::Disconnect( Ret (*func)() ) +Dali::Signal::Disconnect( SlotDelegate& delegate, Ret (X::*func)( Arg0 arg0 ) ) +Dali::Signal::Disconnect( SlotDelegate& delegate, Ret (X::*func)( Arg0 arg0, Arg1 arg1 ) ) +Dali::Signal::Disconnect( SlotDelegate& delegate, Ret (X::*func)( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) ) +Dali::Signal::Disconnect( SlotDelegate& delegate, Ret (X::*func)() ) +Dali::Signal::Disconnect( SlotDelegate& delegate, void (X::*func)( Arg0 arg0 ) ) +Dali::Signal::Disconnect( SlotDelegate& delegate, void (X::*func)( Arg0 arg0, Arg1 arg1 ) ) +Dali::Signal::Disconnect( SlotDelegate& delegate, void (X::*func)( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) ) +Dali::Signal::Disconnect( SlotDelegate& delegate, void (X::*func)() ) +Dali::Signal::Disconnect( X* obj, Ret (X::*func)( Arg0 arg0 ) ) +Dali::Signal::Disconnect( X* obj, Ret (X::*func)( Arg0 arg0, Arg1 arg1 ) ) +Dali::Signal::Disconnect( X* obj, Ret (X::*func)( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) ) +Dali::Signal::Disconnect( X* obj, Ret (X::*func)() ) +Dali::Signal::Disconnect( X* obj, void (X::*func)( Arg0 arg0 ) ) +Dali::Signal::Disconnect( X* obj, void (X::*func)( Arg0 arg0, Arg1 arg1 ) ) +Dali::Signal::Disconnect( X* obj, void (X::*func)( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) ) +Dali::Signal::Disconnect( X* obj, void (X::*func)() ) +Dali::Signal::Disconnect( void (*func)( Arg0 arg0 ) ) +Dali::Signal::Disconnect( void (*func)( Arg0 arg0, Arg1 arg1 ) ) +Dali::Signal::Disconnect( void (*func)( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) ) +Dali::Signal::Disconnect( void (*func)() ) +Dali::Signal::Emit( Arg0 arg0 ) +Dali::Signal::Emit( Arg0 arg0, Arg1 arg1 ) +Dali::Signal::Emit( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) +Dali::Signal::Emit() +Dali::Signal::Emit( Arg0 arg0 ) +Dali::Signal::Emit( Arg0 arg0, Arg1 arg1 ) +Dali::Signal::Emit( Arg0 arg0, Arg1 arg1, Arg2 arg2 ) +Dali::Signal::Emit() +Dali::Signal::Empty() const +Dali::Signal::Empty() const +Dali::Signal::Empty() const +Dali::Signal::Empty() const +Dali::Signal::Empty() const +Dali::Signal::Empty() const +Dali::Signal::Empty() const +Dali::Signal::Empty() const +Dali::Signal::GetConnectionCount() const +Dali::Signal::GetConnectionCount() const +Dali::Signal::GetConnectionCount() const +Dali::Signal::GetConnectionCount() const +Dali::Signal::GetConnectionCount() const +Dali::Signal::GetConnectionCount() const +Dali::Signal::GetConnectionCount() const +Dali::Signal::GetConnectionCount() const +Dali::Signal::Signal() +Dali::Signal::Signal() +Dali::Signal::Signal() +Dali::Signal::Signal() +Dali::Signal::Signal() +Dali::Signal::Signal() +Dali::Signal::Signal() +Dali::Signal::Signal() +Dali::Signal::~Signal() +Dali::Signal::~Signal() +Dali::Signal::~Signal() +Dali::Signal::~Signal() +Dali::Signal::~Signal() +Dali::Signal::~Signal() +Dali::Signal::~Signal() +Dali::Signal::~Signal() +Dali::FunctorDestroyer::Delete( void* functorPtr ) +Dali::FunctorDispatcher::Dispatch( void* functorPtr ) +Dali::FunctorDelegate::Execute(); +Dali::FunctorDelegate::New( const T& functor ) +Dali::FunctorDelegate::~FunctorDelegate(); +Dali::SignalConnection::Disconnect( SlotObserver* slotObserver ); +Dali::SignalConnection::GetCallback(); +Dali::SlotConnection::GetCallback(); +Dali::SlotConnection::GetSlotObserver(); +Dali::SignalConnection::SignalConnection( CallbackBase* callback ); +Dali::SignalConnection::SignalConnection( SignalObserver* signalObserver, CallbackBase* callback ); +Dali::SlotConnection::SlotConnection(SlotObserver* slotObserver, CallbackBase* callback); +Dali::SignalConnection::~SignalConnection(); +Dali::SlotConnection::~SlotConnection(); +Dali::SignalObserver::SignalObserver(); +Dali::SlotObserver::SlotObserver(); +Dali::SignalObserver::~SignalObserver(); +Dali::SlotObserver::~SlotObserver(); +Dali::SlotDelegate::DisconnectAll() +Dali::SlotDelegate::GetConnectionCount() const +Dali::SlotDelegate::GetConnectionTracker() +Dali::SlotDelegate::GetSlot() +Dali::SlotDelegate::SlotDelegate( Slot* slot ) +Dali::SlotDelegate::~SlotDelegate() +Dali::RelayoutContainer::RelayoutContainer() {} +Dali::RelayoutContainer::~RelayoutContainer() {} +Dali::Sign( T value ) +ANGLE_360 +ANGLE_315 +ANGLE_270 +ANGLE_225 +ANGLE_180 +ANGLE_135 +ANGLE_120 +ANGLE_90 +ANGLE_60 +ANGLE_45 +ANGLE_30 +ANGLE_0 +Dali::Renderer() +Dali::~Renderer() +Dali::Renderer::New( Geometry& geometry, Shader& shader ) +Dali::Renderer( const Renderer& handle ) +Dali::Renderer::DownCast( BaseHandle handle ) +Dali::Renderer::=( const Renderer& handle ) +Dali::Renderer::SetGeometry( Geometry& geometry ) +Dali::Renderer::GetGeometry() +Dali::Renderer::SetIndexRange( int firstElement, int elementsCount ) +Dali::Renderer::SetTextures( TextureSet& textureSet ) +Dali::Renderer::GetTextures() +Dali::Renderer::SetShader( Shader& shader ) +Dali::Renderer::GetShader() +Dali::FrameBuffer() +Dali::~FrameBuffer() +Dali::FrameBuffer( const FrameBuffer& handle ) +Dali::FrameBuffer::New( unsigned int width, unsigned int height, unsigned int attachments ) +Dali::FrameBuffer::DownCast( BaseHandle handle ) +Dali::FrameBuffer::=( const FrameBuffer& handle ) +Dali::FrameBuffer::AttachColorTexture( Texture& texture ) +Dali::FrameBuffer::AttachColorTexture( Texture& texture, unsigned int mipmapLevel, unsigned int layer ) +Dali::FrameBuffer::GetColorTexture() +Dali::Geometry() +Dali::~Geometry() +Dali::Geometry::New() +Dali::Geometry::DownCast( BaseHandle handle ) +Dali::Geometry::=( const Geometry& handle ) +Dali::Geometry::AddVertexBuffer( PropertyBuffer& vertexBuffer ) +Dali::Geometry::GetNumberOfVertexBuffers() +Dali::Geometry::RemoveVertexBuffer( std::size_t index ) +Dali::Geometry::SetIndexBuffer( const unsigned short* indices, size_t count ) +Dali::Geometry::SetType( Type geometryType ) +Dali::Geometry::GetType() +Dali::Sampler() +Dali::~Sampler() +Dali::Sampler( const Sampler& handle ) +Dali::Sampler::New() +Dali::Sampler::DownCast( BaseHandle handle ) +Dali::Sampler::=( const Sampler& handle ) +Dali::Sampler::SetFilterMode( FilterMode::Type minFilter, FilterMode::Type magFilter ) +Dali::Sampler::SetWrapMode( WrapMode::Type uWrap, WrapMode::Type vWrap ) +Dali::Sampler::SetWrapMode( WrapMode::Type rWrap, WrapMode::Type sWrap, WrapMode::Type tWrap ) +Dali::Shader() +Dali::~Shader() +Dali::Shader( const Shader& handle ) +Dali::Shader::New( const std::string& vertexShader, const std::string& fragmentShader, Hint::Value hints = Hint::NONE ) +Dali::Shader::DownCast( BaseHandle handle ) +Dali::Shader::=( const Shader& handle ) +Dali::Texture() +Dali::~Texture() +Dali::Texture( const Texture& handle ) +Dali::Texture::New( TextureType::Type type, Pixel::Format format, unsigned int width, unsigned int height ) +Dali::Texture::New( NativeImageInterface& nativeImageInterface ) +Dali::Texture::DownCast( BaseHandle handle ) +Dali::Texture::=( const Texture& handle ) +Dali::Texture::Upload ( PixelData pixelData ) +Dali::Texture::Upload( PixelData pixelData, unsigned int layer, unsigned int mipmap, unsigned int xOffset, unsigned int yOffset, unsigned int width, unsigned int height ) +Dali::Texture::GenerateMipmaps() +Dali::Texture::GetWidth() +Dali::Texture::GetHeight() +Dali::TextureSet() +Dali::~TextureSet() +Dali::TextureSet( const TextureSet& handle ) +Dali::TextureSet::New() +Dali::TextureSet::DownCast( BaseHandle handle ) +Dali::TextureSet::=( const TextureSet& handle ) +Dali::TextureSet::SetTexture( size_t index, Texture texture ) +Dali::TextureSet::GetTexture( size_t index ) +Dali::TextureSet::SetSampler( size_t index, Sampler sampler ) +Dali::TextureSet::GetSampler( size_t index ) +Dali::TextureSet::GetTextureCount() +Dali::PixelData() +Dali::~PixelData() +Dali::PixelData( const PixelData& handle ) +Dali::PixelData::New( unsigned char* buffer, unsigned int bufferSize, unsigned int width, unsigned int height, Pixel::Format pixelFormat, ReleaseFunction releaseFunction ) +Dali::PixelData::=( const PixelData& rhs ) +Dali::PixelData::GetWidth() +Dali::PixelData::GetHeight() +Dali::PixelData::GetPixelFormat() +Dali::PropertyBuffer() +Dali::~PropertyBuffer() +Dali::PropertyBuffer( const PropertyBuffer& handle ) +Dali::PropertyBuffer::New( Dali::Property::Map& bufferFormat ) +Dali::PropertyBuffer::DownCast( BaseHandle handle ) +Dali::PropertyBuffer::=( const PropertyBuffer& handle ) +Dali::PropertyBuffer::SetData( const void* data, std::size_t size ) +Dali::PropertyBuffer::GetSize() +Dali::WeakHandleBase::GetBaseHandle() const +Dali::WeakHandleBase::Reset() +Dali::WeakHandleBase::WeakHandleBase() +Dali::WeakHandleBase::WeakHandleBase(Dali::Handle&) +Dali::WeakHandleBase::WeakHandleBase(Dali::WeakHandleBase const&) +Dali::WeakHandleBase::operator!=(Dali::WeakHandleBase const&) const +Dali::WeakHandleBase::operator=(Dali::WeakHandleBase const&) +Dali::WeakHandleBase::operator==(Dali::WeakHandleBase const&) const +Dali::WeakHandleBase::~WeakHandleBase() +Dali::Extents::Extents() +Dali::Extents::Extents( const Extents& ) +Dali::Extents::Extents( uint16_t, uint16_t, uint16_t , uint16_t ) +Dali::Extents::operator=( const Extents& ) +Dali::Extents::operator=( const uint16_t* ) +Dali::Extents::operator==( const Extents & ) const +Dali::Extents::operator!=( const Extents & ) const +Dali::Extents::operator<< (std::ostream&, const Extents& ) +Dali::Application::AddIdle( CallbackBase* callback ); +Dali::Application::AppControlSignal(); +Dali::Application::Application( const Application& application ); +Dali::Application::Application(); +Dali::Application::LowBatterySignal(); +Dali::Application::GetResourcePath(); +Dali::Application::GetStereoBase() const; +Dali::Application::GetViewMode() const; +Dali::Application::GetWindow(); +Dali::Application::GetRegion() const; +Dali::Application::GetLanguage() const; +Dali::Application::InitSignal(); +Dali::Application::LanguageChangedSignal(); +Dali::Application::Lower(); +Dali::Application::MainLoop(); +Dali::Application::MainLoop(Configuration::ContextLoss configuration); +Dali::Application::LowMemorySignal(); +Dali::Application::New( int* argc, char **argv[] ); +Dali::Application::New( int* argc, char **argv[], const std::string& stylesheet ); +Dali::Application::New( int* argc, char **argv[], const std::string& stylesheet, WINDOW_MODE windowMode ); +Dali::Application::New(); +Dali::Application::New(int*, char***, std::string const&, Dali::Application::WINDOW_MODE, Dali::Rect) +Dali::Application::PauseSignal(); +Dali::Application::Quit(); +Dali::Application::RegionChangedSignal(); +Dali::Application::ReplaceWindow(PositionSize windowPosition, const std::string& name); +Dali::Application::ResetSignal(); +Dali::Application::ResumeSignal(); +Dali::Application::SetStereoBase( float stereoBase ); +Dali::Application::SetViewMode( ViewMode viewMode ); +Dali::Application::TerminateSignal(); +Dali::Application::operator=( const Application& applicaton ); +Dali::Application::~Application(); +DALI_IMPORT_API::IsKey( KeyEvent const& keyEvent, enum KEY daliKey ); +Dali::KeyGrab::GrabKeyTopmost( Window window, Dali::KEY daliKey ); +Dali::KeyGrab::UngrabKeyTopmost( Window window, Dali::KEY daliKey ); +Dali::KeyGrab::GrabKey( Window window, Dali::KEY daliKey, KeyGrabMode grabMode ); +Dali::KeyGrab::UngrabKey( Window window, Dali::KEY daliKey ); +Dali::KeyGrab::GrabKeyList( Window window, const Dali::Vector& daliKeyVector, const Dali::Vector& grabModeVector) +Dali::KeyGrab::UngrabKeyList( Window window, const Dali::Vector& daliKeyVector ) +Dali::NativeImageSource::EncodeToFile(const std::string& filename) const; +Dali::NativeImageSource::GetPixels( std::vector& pixbuf, unsigned int& width, unsigned int& height, Pixel::Format& pixelFormat ) const; +Dali::NativeImageSource::GetNativeImageSource(); +Dali::NativeImageSource::New( Any nativeImageSource ); +Dali::NativeImageSource::New( unsigned int width, unsigned int height, ColorDepth depth ); +Dali::NativeImageSource::IsColorDepthSupported( ColorDepth colorDepth ); +Dali::NativeImageSource::SetSource( Any source ) +Dali::Timer::DownCast( BaseHandle handle ); +Dali::Timer::GetInterval() const; +Dali::Timer::IsRunning() const; +Dali::Timer::New( unsigned int milliSec ); +Dali::Timer::SetInterval( unsigned int milliSec ); +Dali::Timer::Start(); +Dali::Timer::Stop(); +Dali::Timer::TickSignal(); +Dali::Timer::Timer( const Timer& timer ); +Dali::Timer::Timer(); +Dali::Timer::operator=( const Timer& timer ); +Dali::Timer::~Timer(); +Dali::TtsPlayer::Get(Dali::TtsPlayer::Mode mode = Dali::TtsPlayer::DEFAULT); +Dali::TtsPlayer::GetState(); +Dali::TtsPlayer::Pause(); +Dali::TtsPlayer::Play(const std::string& text); +Dali::TtsPlayer::Resume(); +Dali::TtsPlayer::StateChangedSignal( ); +Dali::TtsPlayer::Stop(); +Dali::TtsPlayer::TtsPlayer(); +Dali::TtsPlayer::TtsPlayer(const TtsPlayer& handle); +Dali::TtsPlayer::operator=(const TtsPlayer& rhs); +Dali::TtsPlayer::~TtsPlayer(); +Dali::Window::Activate(); +Dali::Window::AddAvailableOrientation( WindowOrientation orientation ); +Dali::Window::GetDragAndDropDetector() const; +Dali::Window::GetNativeHandle() const; +Dali::Window::GetPreferredOrientation(); +Dali::Window::IndicatorVisibilityChangedSignal(); +Dali::Window::Lower(); +Dali::Window::New(PositionSize windowPosition, std::string name, bool isTransparent = false); +Dali::Window::Raise(); +Dali::Window::RemoveAvailableOrientation( WindowOrientation orientation ); +Dali::Window::RotateIndicator(WindowOrientation orientation); +Dali::Window::SetClass(std::string name, std::string klass); +Dali::Window::SetIndicatorBgOpacity( IndicatorBgOpacity opacity ); +Dali::Window::SetPreferredOrientation( WindowOrientation orientation ); +Dali::Window::ShowIndicator( IndicatorVisibleMode visibleMode ); +Dali::Window::Window(); +Dali::Window::Window(const Window& handle); +Dali::Window::operator=(const Window& rhs); +Dali::Window::~Window(); +Dali::Window::AddAuxiliaryHint(std::string const&, std::string const&); +Dali::Window::FocusChangedSignal(); +Dali::Window::GetAuxiliaryHintId(std::string const&) const; +Dali::Window::GetAuxiliaryHintValue(unsigned int) const; +Dali::Window::GetBrightness() const; +Dali::Window::GetNotificationLevel() const; +Dali::Window::GetPosition() const; +Dali::Window::GetScreenOffMode() const; +Dali::Window::GetSize() const; +Dali::Window::GetSupportedAuxiliaryHintCount() const; +Dali::Window::GetSupportedAuxiliaryHint(unsigned int) const; +Dali::Window::GetType() coinst; +Dali::Window::Hide(); +Dali::Window::IsFocusAcceptable() const; +Dali::Window::IsOpaqueState() const; +Dali::Window::IsVisible() const; +Dali::Window::RemoveAuxiliaryHint(unsigned int); +Dali::Window::ResizedSignal(); +Dali::Window::SetAcceptFocus(bool); +Dali::Window::SetAuxiliaryHintValue(unsigned int, std::string const&); +Dali::Window::SetBrightness(int); +Dali::Window::SetInputRegion(Dali::Rect const&); +Dali::Window::SetNotificationLevel(Dali::Window::NotificationLevel::Type); +Dali::Window::SetOpaqueState(bool); +Dali::Window::SetPosition(Dali::Uint16Pair); +Dali::Window::SetScreenOffMode(Dali::Window::ScreenOffMode::Type); +Dali::Window::SetSize(Dali::Uint16Pair); +Dali::Window::SetTransparency(bool); +Dali::Window::SetType(Dali::Window::Type); +Dali::Window::Show(); +Dali::WidgetApplication::New(); +Dali::WidgetApplication::WidgetApplication(); +Dali::WidgetApplication::WidgetApplication( const WidgetApplication& widgetApplication ); +Dali::WidgetApplication::WidgetApplication& operator=( const WidgetApplication& widgetApplication ); +Dali::WidgetApplication::~WidgetApplication(); +Dali::WidgetApplication::RegisterWidgetCreatingFunction( const std::string& widgetName, CreateWidgetFunction createFunction ); +Dali::Widget::New(); +Dali::Widget::Widget(); +Dali::Widget::Widget( const Widget& widget ); +Dali::Widget::operator=( const Widget& widget ); +Dali::Widget::~Widget(); +Dali::WidgetImpl::New(); +Dali::WidgetImpl::OnCreate( const std::string& contentInfo, Dali::Window window ); +Dali::WidgetImpl::OnTerminate( const std::string& contentInfo, Dali::Widget::Termination type ); +Dali::WidgetImpl::OnPause(); +Dali::WidgetImpl::OnResume(); +Dali::WidgetImpl::OnResize( Dali::Window window ); +Dali::WidgetImpl::OnUpdate( const std::string& contentInfo, int force ); +Dali::WidgetImpl::SignalConnected( SlotObserver* slotObserver, CallbackBase* callback ); +Dali::WidgetImpl::SignalDisconnected( SlotObserver* slotObserver, CallbackBase* callback ); +Dali::WidgetImpl::SetContentInfo( const std::string& contentInfo ); +Dali::WatchApplication::New(); +Dali::WatchApplication::New( int* argc, char **argv[] ); +Dali::WatchApplication::New( int* argc, char **argv[], const std::string& stylesheet ); +Dali::WatchApplication::WatchApplication(); +Dali::WatchApplication::WatchApplication( const WatchApplication& implementation ); +Dali::WatchApplication::operator=( const WatchApplication& applicaton ); +Dali::WatchApplication::~WatchApplication(); +Dali::WatchApplication::TimeTickSignal(); +Dali::WatchApplication::AmbientTickSignal(); +Dali::WatchApplication::AmbientChangedSignal(); +Dali::WatchTime::WatchTime(); +Dali::WatchTime::~WatchTime(); +Dali::WatchTime::GetHour() const; +Dali::WatchTime::GetHour24() const; +Dali::WatchTime::GetMinute() const; +Dali::WatchTime::GetSecond() const; +Dali::WatchTime::GetMillisecond() const; +Dali::WatchTime::GetYear() const; +Dali::WatchTime::GetMonth() const; +Dali::WatchTime::GetDay() const; +Dali::WatchTime::GetDayOfWeek() const; +Dali::WatchTime::GetUtcTime() const; +Dali::WatchTime::GetUtcTimeStamp() const; +Dali::WatchTime::GetTimeZone() const; +Dali::WatchTime::GetDaylightSavingTimeStatus() const; +Dali::Capture::New() +Dali::Capture::New(Dali::CameraActor) +Dali::Capture::Capture() +Dali::Capture::~Capture() +Dali::Capture::Capture(Dali::Capture const&) +Dali::Capture::operator=(Dali::Capture const&) +Dali::Capture::Start(Dali::Actor, Dali::Vector2 const&, std::__cxx11::basic_string, std::allocator > const&) +Dali::Capture::Start(Dali::Actor, Dali::Vector2 const&, std::__cxx11::basic_string, std::allocator > const&, Dali::Vector4 const&) +Dali::Capture::DownCast(Dali::BaseHandle) +Dali::Capture::FinishedSignal() +Dali::Toolkit::AccessibilityManager::AccessibilityManager( ); +Dali::Toolkit::AccessibilityManager::AccessibilityManager( struct Internal::AccessibilityManager* impl ); +Dali::Toolkit::AccessibilityManager::ActionActivateSignal( ); +Dali::Toolkit::AccessibilityManager::ActionBackSignal( ); +Dali::Toolkit::AccessibilityManager::ActionClearFocusSignal( ); +Dali::Toolkit::AccessibilityManager::ActionDownSignal( ); +Dali::Toolkit::AccessibilityManager::ActionMoveToFirstSignal( ); +Dali::Toolkit::AccessibilityManager::ActionMoveToLastSignal( ); +Dali::Toolkit::AccessibilityManager::ActionNextSignal( ); +Dali::Toolkit::AccessibilityManager::ActionOverSignal( ); +Dali::Toolkit::AccessibilityManager::ActionPageDownSignal( ); +Dali::Toolkit::AccessibilityManager::ActionPageLeftSignal( ); +Dali::Toolkit::AccessibilityManager::ActionPageRightSignal( ); +Dali::Toolkit::AccessibilityManager::ActionPageUpSignal( ); +Dali::Toolkit::AccessibilityManager::ActionPreviousSignal( ); +Dali::Toolkit::AccessibilityManager::ActionReadFromNextSignal( ); +Dali::Toolkit::AccessibilityManager::ActionReadFromTopSignal( ); +Dali::Toolkit::AccessibilityManager::ActionReadIndicatorInformationSignal( ); +Dali::Toolkit::AccessibilityManager::ActionReadNextSignal( ); +Dali::Toolkit::AccessibilityManager::ActionReadPauseResumeSignal( ); +Dali::Toolkit::AccessibilityManager::ActionReadPreviousSignal( ); +Dali::Toolkit::AccessibilityManager::ActionReadSignal( ); +Dali::Toolkit::AccessibilityManager::ActionScrollDownSignal( ); +Dali::Toolkit::AccessibilityManager::ActionScrollSignal( ); +Dali::Toolkit::AccessibilityManager::ActionScrollUpSignal( ); +Dali::Toolkit::AccessibilityManager::ActionStartStopSignal( ); +Dali::Toolkit::AccessibilityManager::ActionUpSignal( ); +Dali::Toolkit::AccessibilityManager::ActionZoomSignal( ); +Dali::Toolkit::AccessibilityManager::ClearFocus( ); +Dali::Toolkit::AccessibilityManager::FocusChangedSignal( ); +Dali::Toolkit::AccessibilityManager::FocusedActorActivatedSignal( ); +Dali::Toolkit::AccessibilityManager::FocusOvershotSignal( ); +Dali::Toolkit::AccessibilityManager::GenerateNewFocusOrder( ) const; +Dali::Toolkit::AccessibilityManager::Get( ); +Dali::Toolkit::AccessibilityManager::GetAccessibilityAttribute( Dali::Actor actor, enum AccessibilityManager::AccessibilityAttribute type ) const; +Dali::Toolkit::AccessibilityManager::GetActorByFocusOrder( unsigned int const order ); +Dali::Toolkit::AccessibilityManager::GetCurrentFocusActor( ); +Dali::Toolkit::AccessibilityManager::GetCurrentFocusGroup( ); +Dali::Toolkit::AccessibilityManager::GetCurrentFocusOrder( ); +Dali::Toolkit::AccessibilityManager::GetFocusGroup( Dali::Actor actor ); +Dali::Toolkit::AccessibilityManager::GetFocusIndicatorActor( ); +Dali::Toolkit::AccessibilityManager::GetFocusOrder( Dali::Actor actor ) const; +Dali::Toolkit::AccessibilityManager::GetGroupMode( ) const; +Dali::Toolkit::AccessibilityManager::GetReadPosition( ) const; +Dali::Toolkit::AccessibilityManager::GetWrapMode( ) const; +Dali::Toolkit::AccessibilityManager::IsFocusGroup( Dali::Actor actor ) const; +Dali::Toolkit::AccessibilityManager::MoveFocusBackward( ); +Dali::Toolkit::AccessibilityManager::MoveFocusForward( ); +Dali::Toolkit::AccessibilityManager::Reset( ); +Dali::Toolkit::AccessibilityManager::SetAccessibilityAttribute( Dali::Actor actor, enum AccessibilityManager::AccessibilityAttribute type, std::string const& text ); +Dali::Toolkit::AccessibilityManager::SetCurrentFocusActor( Dali::Actor actor ); +Dali::Toolkit::AccessibilityManager::SetFocusGroup( Dali::Actor actor, bool isFocusGroup ); +Dali::Toolkit::AccessibilityManager::SetFocusIndicatorActor( Dali::Actor indicator ); +Dali::Toolkit::AccessibilityManager::SetFocusOrder( Dali::Actor actor, unsigned int const order ); +Dali::Toolkit::AccessibilityManager::SetGroupMode( bool enabled ); +Dali::Toolkit::AccessibilityManager::SetWrapMode( bool wrapped ); +Dali::Toolkit::AccessibilityManager::StatusChangedSignal( ); +Dali::Toolkit::AccessibilityManager::~AccessibilityManager( ); +Dali::Toolkit::Alignment::Alignment(); +Dali::Toolkit::Alignment::Alignment(const Alignment& alignment); +Dali::Toolkit::Alignment::DownCast( BaseHandle handle ); +Dali::Toolkit::Alignment::GetAlignmentType() const; +Dali::Toolkit::Alignment::GetPadding() const; +Dali::Toolkit::Alignment::GetScaling() const; +Dali::Toolkit::Alignment::New( Type horizontal = HorizontalCenter, Type vertical = VerticalCenter ); +Dali::Toolkit::Alignment::Padding::Padding( float l, float r, float t, float b ) +Dali::Toolkit::Alignment::Padding::Padding() +Dali::Toolkit::Alignment::SetAlignmentType( Type type ); +Dali::Toolkit::Alignment::SetPadding( const Padding& padding ); +Dali::Toolkit::Alignment::SetScaling( Scaling scaling ); +Dali::Toolkit::Alignment::operator=(const Alignment& alignment); +Dali::Toolkit::Alignment::~Alignment(); +Dali::Toolkit::Button::Button( const Button& button ); +Dali::Toolkit::Button::Button(); +Dali::Toolkit::Button::ClickedSignal(); +Dali::Toolkit::Button::DownCast( BaseHandle handle ); +Dali::Toolkit::Button::PressedSignal(); +Dali::Toolkit::Button::ReleasedSignal(); +Dali::Toolkit::Button::StateChangedSignal(); +Dali::Toolkit::Button::operator=( const Button& button ); +Dali::Toolkit::Button::~Button(); +Dali::Toolkit::CheckBoxButton::CheckBoxButton( const CheckBoxButton& checkBox ); +Dali::Toolkit::CheckBoxButton::CheckBoxButton(); +Dali::Toolkit::CheckBoxButton::DownCast( BaseHandle handle ); +Dali::Toolkit::CheckBoxButton::New(); +Dali::Toolkit::CheckBoxButton::operator=( const CheckBoxButton& checkBox ); +Dali::Toolkit::CheckBoxButton::~CheckBoxButton(); +Dali::Toolkit::PushButton::DownCast( BaseHandle handle ); +Dali::Toolkit::PushButton::New(); +Dali::Toolkit::PushButton::PushButton( const PushButton& pushButton ); +Dali::Toolkit::PushButton::PushButton(); +Dali::Toolkit::PushButton::operator=( const PushButton& pushButton ); +Dali::Toolkit::PushButton::~PushButton(); +Dali::Toolkit::RadioButton::DownCast( BaseHandle handle ); +Dali::Toolkit::RadioButton::New( const std::string& label ); +Dali::Toolkit::RadioButton::New(); +Dali::Toolkit::RadioButton::RadioButton( const RadioButton& radioButton ); +Dali::Toolkit::RadioButton::RadioButton(); +Dali::Toolkit::RadioButton::operator=( const RadioButton& radioButton ); +Dali::Toolkit::RadioButton::~RadioButton(); +Dali::Toolkit::Internal::Control::CalculateChildSize( const Dali::Actor& child, Dimension::Type dimension ); +Dali::Toolkit::Internal::Control::ClearBackground(); +Dali::Toolkit::Internal::Control::ClearKeyInputFocus(); +Dali::Toolkit::Internal::Control::Control( ControlBehaviour behaviourFlags ); +Dali::Toolkit::Internal::Control::DisableGestureDetection( Gesture::Type type ); +Dali::Toolkit::Internal::Control::EmitKeyInputFocusSignal( bool focusGained ); +Dali::Toolkit::Internal::Control::EnableGestureDetection( Gesture::Type type ); +Dali::Toolkit::Internal::Control::GetBackgroundColor() const; +Dali::Toolkit::Internal::Control::GetControlExtension() +Dali::Toolkit::Internal::Control::GetHeightForWidth( float width ); +Dali::Toolkit::Internal::GetImplementation( Dali::Toolkit::Control& handle ); +Dali::Toolkit::Internal::GetImplementation( const Dali::Toolkit::Control& handle ); +Dali::Toolkit::Internal::Control::GetLongPressGestureDetector() const; +Dali::Toolkit::Internal::Control::GetNaturalSize(); +Dali::Toolkit::Internal::Control::GetNextKeyboardFocusableActor( Actor currentFocusedActor, Toolkit::Control::KeyboardFocus::Direction direction, bool loopEnabled ); +Dali::Toolkit::Internal::Control::GetPanGestureDetector() const; +Dali::Toolkit::Internal::Control::GetPinchGestureDetector() const; +Dali::Toolkit::Internal::Control::GetStyleName() const; +Dali::Toolkit::Internal::Control::GetTapGestureDetector() const; +Dali::Toolkit::Internal::Control::GetWidthForHeight( float height ); +Dali::Toolkit::Internal::Control::HasKeyInputFocus(); +Dali::Toolkit::Internal::Control::Initialize(); +Dali::Toolkit::Internal::Control::IsKeyboardFocusGroup(); +Dali::Toolkit::Internal::Control::IsKeyboardNavigationSupported(); +Dali::Toolkit::Internal::Control::KeyboardEnter( ); +Dali::Toolkit::Internal::Control::KeyEventSignal(); +Dali::Toolkit::Internal::Control::KeyInputFocusGainedSignal(); +Dali::Toolkit::Internal::Control::KeyInputFocusLostSignal(); +Dali::Toolkit::Internal::Control::New(); +Dali::Toolkit::Internal::Control::OnAccessibilityActivated(); +Dali::Toolkit::Internal::Control::OnAccessibilityPan( PanGesture gesture ); +Dali::Toolkit::Internal::Control::OnAccessibilityTouch( const TouchEvent& touchEvent ); +Dali::Toolkit::Internal::Control::OnAccessibilityValueChange( bool isIncrease ); +Dali::Toolkit::Internal::Control::OnAccessibilityZoom( ); +Dali::Toolkit::Internal::Control::OnCalculateRelayoutSize( Dimension::Type dimension ); +Dali::Toolkit::Internal::Control::OnChildAdd( Actor& child ); +Dali::Toolkit::Internal::Control::OnChildRemove( Actor& child ); +Dali::Toolkit::Internal::Control::OnHoverEvent( const HoverEvent& event ); +Dali::Toolkit::Internal::Control::OnInitialize(); +Dali::Toolkit::Internal::Control::OnKeyboardEnter( ); +Dali::Toolkit::Internal::Control::OnKeyEvent( const KeyEvent& event ); +Dali::Toolkit::Internal::Control::OnKeyInputFocusGained(); +Dali::Toolkit::Internal::Control::OnKeyInputFocusLost(); +Dali::Toolkit::Internal::Control::OnKeyboardFocusChangeCommitted( Actor commitedFocusableActor ); +Dali::Toolkit::Internal::Control::OnLayoutNegotiated( float size, Dimension::Type dimension ); +Dali::Toolkit::Internal::Control::OnLongPress( const LongPressGesture& longPress ); +Dali::Toolkit::Internal::Control::OnPan( const PanGesture& pan ); +Dali::Toolkit::Internal::Control::OnPinch( const PinchGesture& pinch ); +Dali::Toolkit::Internal::Control::OnRelayout( const Vector2& size, RelayoutContainer& container ); +Dali::Toolkit::Internal::Control::OnSetResizePolicy( ResizePolicy::Type policy, Dimension::Type dimension ); +Dali::Toolkit::Internal::Control::OnSizeAnimation( Animation& animation, const Vector3& targetSize ); +Dali::Toolkit::Internal::Control::OnSizeSet( const Vector3& targetSize ); +Dali::Toolkit::Internal::Control::OnStageConnection( int depth ); +Dali::Toolkit::Internal::Control::OnStageDisconnection(); +Dali::Toolkit::Internal::Control::OnStyleChange( Toolkit::StyleManager styleManager, StyleChange::Type change ); +Dali::Toolkit::Internal::Control::OnTap( const TapGesture& tap ); +Dali::Toolkit::Internal::Control::OnTouchEvent( const TouchEvent& event ); +Dali::Toolkit::Internal::Control::OnWheelEvent( const WheelEvent& event ); +Dali::Toolkit::Internal::Control::RelayoutDependentOnChildren( Dimension::Type dimension = Dimension::ALL_DIMENSIONS ); +Dali::Toolkit::Internal::Control::SetAsKeyboardFocusGroup( bool isFocusGroup ); +Dali::Toolkit::Internal::Control::SetBackgroundColor( const Vector4& color ); +Dali::Toolkit::Internal::Control::SetBackgroundImage( Image image ); +Dali::Toolkit::Internal::Control::SetKeyInputFocus(); +Dali::Toolkit::Internal::Control::SetKeyboardNavigationSupport( bool isSupported ); +Dali::Toolkit::Internal::Control::SetStyleName( const std::string& styleName ); +Dali::Toolkit::Internal::Control::SignalConnected( SlotObserver* slotObserver, CallbackBase* callback ); +Dali::Toolkit::Internal::Control::SignalDisconnected( SlotObserver* slotObserver, CallbackBase* callback ); +Dali::Toolkit::Internal::Control::~Control(); +Dali::Toolkit::Internal::Control::SetBackground(const Property::Map& map); +Dali::Toolkit::Control::ClearBackground(); +Dali::Toolkit::Control::ClearKeyInputFocus(); +Dali::Toolkit::Control::Control(); +Dali::Toolkit::Control::Control(const Control& uiControl); +Dali::Toolkit::Control::Control(Dali::Internal::CustomActor* internal); +Dali::Toolkit::Control::Control(Internal::Control& implementation); +Dali::Toolkit::Control::DownCast( BaseHandle handle ); +Dali::Toolkit::Control::GetLongPressGestureDetector() const; +Dali::Toolkit::Control::GetPanGestureDetector() const; +Dali::Toolkit::Control::GetPinchGestureDetector() const; +Dali::Toolkit::Control::GetStyleName() const; +Dali::Toolkit::Control::GetTapGestureDetector() const; +Dali::Toolkit::Control::HasKeyInputFocus(); +Dali::Toolkit::Control::KeyEventSignal(); +Dali::Toolkit::Control::KeyInputFocusGainedSignal(); +Dali::Toolkit::Control::KeyInputFocusLostSignal(); +Dali::Toolkit::Control::New(); +Dali::Toolkit::Control::SetBackgroundColor( const Vector4& color ); +Dali::Toolkit::Control::SetKeyInputFocus(); +Dali::Toolkit::Control::SetStyleName( const std::string& styleName ); +Dali::Toolkit::Control::operator=( const Control& handle ); +Dali::Toolkit::Control::~Control(); +Dali::Toolkit::Control::IsResourceReady() const +Dali::Toolkit::Control::ResourceReadySignal() +Dali::Toolkit::Control::GetVisualResourceStatus ( const Dali::Property::Index index ) +Dali::Toolkit::ImageView::DownCast( Dali::BaseHandle handle ); +Dali::Toolkit::ImageView::GetImage( ) const; +Dali::Toolkit::ImageView::ImageView( ); +Dali::Toolkit::ImageView::ImageView( ImageView const& imageView ); +Dali::Toolkit::ImageView::ImageView( struct Dali::Internal::CustomActor* internal ); +Dali::Toolkit::ImageView::ImageView( struct Internal::ImageView& implementation ); +Dali::Toolkit::ImageView::New( ); +Dali::Toolkit::ImageView::New( std::string const& url ); +Dali::Toolkit::ImageView::New( const std::string& url, ImageDimensions size ) +Dali::Toolkit::ImageView::operator=( ImageView const& imageView ); +Dali::Toolkit::ImageView::SetImage( const std::string& url ); +Dali::Toolkit::ImageView::SetImage( const std::string& url, ImageDimensions size ) +Dali::Toolkit::ImageView::~ImageView( ) +Dali::Toolkit::ScrollBar::DownCast( BaseHandle handle ); +Dali::Toolkit::ScrollBar::GetIndicatorFixedHeight() const; +Dali::Toolkit::ScrollBar::GetIndicatorHeightPolicy() const; +Dali::Toolkit::ScrollBar::GetIndicatorHideDuration() const; +Dali::Toolkit::ScrollBar::GetIndicatorShowDuration() const; +Dali::Toolkit::ScrollBar::GetScrollDirection() const; +Dali::Toolkit::ScrollBar::GetScrollIndicator(); +Dali::Toolkit::ScrollBar::GetScrollPositionIntervals() const; +Dali::Toolkit::ScrollBar::HideIndicator(); +Dali::Toolkit::ScrollBar::New(Direction direction = Vertical); +Dali::Toolkit::ScrollBar::PanFinishedSignal(); +Dali::Toolkit::ScrollBar::ScrollBar( const ScrollBar& scrollBar ); +Dali::Toolkit::ScrollBar::ScrollBar(); +Dali::Toolkit::ScrollBar::ScrollPositionIntervalReachedSignal(); +Dali::Toolkit::ScrollBar::SetIndicatorFixedHeight( float height ); +Dali::Toolkit::ScrollBar::SetIndicatorHeightPolicy( IndicatorHeightPolicy policy ); +Dali::Toolkit::ScrollBar::SetIndicatorHideDuration( float durationSeconds ); +Dali::Toolkit::ScrollBar::SetIndicatorShowDuration( float durationSeconds ); +Dali::Toolkit::ScrollBar::SetScrollDirection( Direction direction ); +Dali::Toolkit::ScrollBar::SetScrollIndicator( Actor indicator ); +Dali::Toolkit::ScrollBar::SetScrollPositionIntervals( const Dali::Vector& positions ); +Dali::Toolkit::ScrollBar::SetScrollPropertySource( Handle handle, Dali::Property::Index propertyScrollPosition, Dali::Property::Index propertyMinScrollPosition, Dali::Property::Index propertyMaxScrollPosition, Dali::Property::Index propertyScrollContentSize ); +Dali::Toolkit::ScrollBar::ShowIndicator(); +Dali::Toolkit::ScrollBar::operator=( const ScrollBar& scrollBar ); +Dali::Toolkit::ScrollBar::~ScrollBar(); +Dali::Toolkit::DefaultItemLayout::New( Type type ); +Dali::Toolkit::ItemFactory::GetExtension() +Dali::Toolkit::ItemFactory::ItemReleased(unsigned int itemId, Actor actor) {}; +Dali::Toolkit::ItemFactory::~ItemFactory() {}; +Dali::Toolkit::ItemLayout::GetClosestOnScreenLayoutPosition(int itemID, float currentLayoutPosition, const Vector3& layoutSize); +Dali::Toolkit::ItemLayout::GetExtension() +Dali::Toolkit::ItemLayout::GetFlickSpeedFactor() const; +Dali::Toolkit::ItemLayout::GetItemSize( unsigned int itemId, const Vector3& layoutSize, Vector3& itemSize ) const; +Dali::Toolkit::ItemLayout::GetNextFocusItemID(int itemID, int maxItems, Dali::Toolkit::Control::KeyboardFocus::Direction direction, bool loopEnabled); +Dali::Toolkit::ItemLayout::GetOrientation() const; +Dali::Toolkit::ItemRange::Intersection(const ItemRange& second) +Dali::Toolkit::ItemLayout::ItemLayout(); +Dali::Toolkit::ItemRange::ItemRange(const ItemRange& copy) +Dali::Toolkit::ItemRange::ItemRange(unsigned int beginItem, unsigned int endItem) +Dali::Toolkit::ItemLayout::SetItemSize( const Vector3& itemSize ); +Dali::Toolkit::ItemLayout::SetOrientation(ControlOrientation::Type orientation); +Dali::Toolkit::ItemRange::Within(unsigned int itemId) +Dali::Toolkit::ItemRange::operator=(const ItemRange& range) +Dali::Toolkit::ItemLayout::~ItemLayout(); +Dali::Toolkit::ItemLayout::SetLayoutProperties(const Property::Map& properties); +Dali::Toolkit::ItemLayout::GetLayoutProperties(); +Dali::Toolkit::ItemView::ActivateLayout(unsigned int layoutIndex, Vector3 targetSize, float durationSeconds); +Dali::Toolkit::ItemView::AddLayout(ItemLayout& layout); +Dali::Toolkit::ItemView::DeactivateCurrentLayout(); +Dali::Toolkit::ItemView::DownCast( BaseHandle handle ); +Dali::Toolkit::ItemView::GetActiveLayout() const; +Dali::Toolkit::ItemView::GetAnchoring() const; +Dali::Toolkit::ItemView::GetAnchoringDuration() const; +Dali::Toolkit::ItemView::GetCurrentLayoutPosition(ItemId itemId) const; +Dali::Toolkit::ItemView::GetItem(ItemId itemId) const; +Dali::Toolkit::ItemView::GetItemId(Actor actor) const; +Dali::Toolkit::ItemView::GetItemsAnchorPoint() const; +Dali::Toolkit::ItemView::GetItemsParentOrigin() const; +Dali::Toolkit::ItemView::GetItemsRange(ItemRange& range); +Dali::Toolkit::ItemView::GetLayout(unsigned int layoutIndex) const; +Dali::Toolkit::ItemView::GetLayoutCount() const; +Dali::Toolkit::ItemView::GetMinimumSwipeDistance() const; +Dali::Toolkit::ItemView::GetMinimumSwipeSpeed() const; +Dali::Toolkit::ItemView::GetRefreshInterval() const; +Dali::Toolkit::ItemView::GetWheelScrollDistanceStep() const; +Dali::Toolkit::ItemView::InsertItem(Item newItem, float durationSeconds); +Dali::Toolkit::ItemView::InsertItems(const ItemContainer& newItems, float durationSeconds); +Dali::Toolkit::ItemView::ItemView( const ItemView& itemView ); +Dali::Toolkit::ItemView::ItemView(); +Dali::Toolkit::ItemView::LayoutActivatedSignal(); +Dali::Toolkit::ItemView::New(ItemFactory& factory); +Dali::Toolkit::ItemView::Refresh(); +Dali::Toolkit::ItemView::RemoveItem(ItemId itemId, float durationSeconds); +Dali::Toolkit::ItemView::RemoveItems(const ItemIdContainer& itemIds, float durationSeconds); +Dali::Toolkit::ItemView::RemoveLayout(unsigned int layoutIndex); +Dali::Toolkit::ItemView::ReplaceItem(Item replacementItem, float durationSeconds); +Dali::Toolkit::ItemView::ReplaceItems(const ItemContainer& replacementItems, float durationSeconds); +Dali::Toolkit::ItemView::ScrollToItem(ItemId itemId, float durationSeconds); +Dali::Toolkit::ItemView::SetAnchoring(bool enabled); +Dali::Toolkit::ItemView::SetAnchoringDuration(float durationSeconds); +Dali::Toolkit::ItemView::SetItemsAnchorPoint( const Vector3& anchorPoint ); +Dali::Toolkit::ItemView::SetItemsParentOrigin( const Vector3& parentOrigin ); +Dali::Toolkit::ItemView::SetMinimumSwipeDistance(float distance); +Dali::Toolkit::ItemView::SetMinimumSwipeSpeed(float speed); +Dali::Toolkit::ItemView::SetRefreshInterval(float intervalLayoutPositions); +Dali::Toolkit::ItemView::SetWheelScrollDistanceStep(float step); +Dali::Toolkit::ItemView::operator=( const ItemView& itemView ); +Dali::Toolkit::ItemView::~ItemView(); +Dali::Toolkit::MoveActorConstraint( Vector3& current, const PropertyInputContainer& inputs ); +Dali::Toolkit::WrapActorConstraint( Vector3& position, const PropertyInputContainer& inputs ); +Dali::Toolkit::ScrollViewEffect::ScrollViewEffect(); +Dali::Toolkit::ScrollViewPagePathEffect::ApplyToPage( Actor page, unsigned int pageOrder ); +Dali::Toolkit::ScrollViewPagePathEffect::DownCast( BaseHandle handle ); +Dali::Toolkit::ScrollViewPagePathEffect::New(Path path, const Vector3& forward, Dali::Property::Index inputPropertyIndex, const Vector3& pageSize, unsigned int pageCount); +Dali::Toolkit::ScrollViewPagePathEffect::ScrollViewPagePathEffect(); +Dali::Toolkit::ScrollView::ApplyConstraintToChildren(Constraint constraint); +Dali::Toolkit::ScrollView::ApplyEffect(ScrollViewEffect effect); +Dali::Toolkit::ScrollView::BindActor(Actor child); +Dali::Toolkit::RulerDomain::Clamp(float x, float length = 0.0f, float scale = 1.0f) const; +Dali::Toolkit::Ruler::Clamp(float x, float length = 0.0f, float scale = 1.0f) const; +Dali::Toolkit::RulerDomain::Clamp(float x, float length, float scale, ClampState &clamped) const; +Dali::Toolkit::Ruler::Clamp(float x, float length, float scale, ClampState &clamped) const; +Dali::Toolkit::DefaultRuler::DefaultRuler(); +Dali::Toolkit::Ruler::Disable(); +Dali::Toolkit::Ruler::DisableDomain(); +Dali::Toolkit::ScrollView::DownCast( BaseHandle handle ); +Dali::Toolkit::Ruler::Enable(); +Dali::Toolkit::FixedRuler::FixedRuler(float spacing = 1.0f); +Dali::Toolkit::ScrollView::GetAxisAutoLock() const; +Dali::Toolkit::ScrollView::GetAxisAutoLockGradient() const; +Dali::Toolkit::ScrollView::GetCurrentPage() const; +Dali::Toolkit::ScrollView::GetCurrentScrollPosition() const; +Dali::Toolkit::Ruler::GetDomain() const; +Dali::Toolkit::Ruler::GetExtension() { return NULL; } +Dali::Toolkit::ScrollView::GetFlickSpeedCoefficient() const; +Dali::Toolkit::ScrollView::GetFrictionCoefficient() const; +Dali::Toolkit::ScrollView::GetMaxFlickSpeed() const; +Dali::Toolkit::ScrollView::GetMinimumDistanceForFlick() const; +Dali::Toolkit::ScrollView::GetMinimumSpeedForFlick() const; +Dali::Toolkit::DefaultRuler::GetPageFromPosition(float position, bool wrap) const; +Dali::Toolkit::FixedRuler::GetPageFromPosition(float position, bool wrap) const; +Dali::Toolkit::DefaultRuler::GetPositionFromPage(unsigned int page, unsigned int &volume, bool wrap) const; +Dali::Toolkit::FixedRuler::GetPositionFromPage(unsigned int page, unsigned int &volume, bool wrap) const; +Dali::Toolkit::ScrollView::GetScrollFlickAlphaFunction() const; +Dali::Toolkit::ScrollView::GetScrollFlickDuration() const; +Dali::Toolkit::ScrollView::GetScrollSnapAlphaFunction() const; +Dali::Toolkit::ScrollView::GetScrollSnapDuration() const; +Dali::Toolkit::ScrollView::GetScrollUpdateDistance() const; +Dali::Toolkit::RulerDomain::GetSize() const; +Dali::Toolkit::DefaultRuler::GetTotalPages() const; +Dali::Toolkit::FixedRuler::GetTotalPages() const; +Dali::Toolkit::Ruler::GetType() const; +Dali::Toolkit::ScrollView::GetWheelScrollDistanceStep() const; +Dali::Toolkit::Ruler::IsEnabled() const; +Dali::Toolkit::ScrollView::New(); +Dali::Toolkit::ScrollView::RemoveAllEffects(); +Dali::Toolkit::ScrollView::RemoveConstraintsFromChildren(); +Dali::Toolkit::ScrollView::RemoveEffect(ScrollViewEffect effect); +Dali::Toolkit::ScrollView::RemoveScrollingDirection( Radian direction ); +Dali::Toolkit::Ruler::Ruler(); +Dali::Toolkit::RulerDomain::RulerDomain(float min, float max, bool enabled = true); +Dali::Toolkit::ScrollView::ScrollTo(Actor& actor); +Dali::Toolkit::ScrollView::ScrollTo(Actor& actor, float duration); +Dali::Toolkit::ScrollView::ScrollTo(const Vector2& position); +Dali::Toolkit::ScrollView::ScrollTo(const Vector2& position, float duration); +Dali::Toolkit::ScrollView::ScrollTo(const Vector2& position, float duration, AlphaFunction alpha); +Dali::Toolkit::ScrollView::ScrollTo(const Vector2& position, float duration, AlphaFunction alpha, +Dali::Toolkit::ScrollView::ScrollTo(const Vector2& position, float duration, +Dali::Toolkit::ScrollView::ScrollTo(unsigned int page); +Dali::Toolkit::ScrollView::ScrollTo(unsigned int page, float duration); +Dali::Toolkit::ScrollView::ScrollTo(unsigned int page, float duration, DirectionBias bias); +Dali::Toolkit::ScrollView::ScrollToSnapPoint(); +Dali::Toolkit::ScrollView::ScrollView( const ScrollView& handle ); +Dali::Toolkit::ScrollView::ScrollView(); +Dali::Toolkit::ScrollView::SetActorAutoSnap(bool enable); +Dali::Toolkit::ScrollView::SetAxisAutoLock(bool enable); +Dali::Toolkit::ScrollView::SetAxisAutoLockGradient(float gradient); +Dali::Toolkit::Ruler::SetDomain(RulerDomain domain); +Dali::Toolkit::ScrollView::SetFlickSpeedCoefficient(float speed); +Dali::Toolkit::ScrollView::SetFrictionCoefficient(float friction); +Dali::Toolkit::ScrollView::SetMaxFlickSpeed(float speed); +Dali::Toolkit::ScrollView::SetMaxOvershoot(float overshootX, float overshootY); +Dali::Toolkit::ScrollView::SetMinimumDistanceForFlick( const Vector2& distance ); +Dali::Toolkit::ScrollView::SetMinimumSpeedForFlick( float speed ); +Dali::Toolkit::ScrollView::SetRulerX(RulerPtr ruler); +Dali::Toolkit::ScrollView::SetRulerY(RulerPtr ruler); +Dali::Toolkit::ScrollView::SetScrollFlickAlphaFunction(AlphaFunction alpha); +Dali::Toolkit::ScrollView::SetScrollFlickDuration(float time); +Dali::Toolkit::ScrollView::SetScrollSensitive(bool sensitive); +Dali::Toolkit::ScrollView::SetScrollSnapAlphaFunction(AlphaFunction alpha); +Dali::Toolkit::ScrollView::SetScrollSnapDuration(float time); +Dali::Toolkit::ScrollView::SetScrollUpdateDistance(int distance); +Dali::Toolkit::ScrollView::SetScrollingDirection( Radian direction, Radian threshold = PanGestureDetector::DEFAULT_THRESHOLD ); +Dali::Toolkit::ScrollView::SetSnapOvershootAlphaFunction(AlphaFunction alpha); +Dali::Toolkit::ScrollView::SetSnapOvershootDuration(float duration); +Dali::Toolkit::ScrollView::SetWheelScrollDistanceStep(Vector2 step); +Dali::Toolkit::ScrollView::SetWrapMode(bool enable); +Dali::Toolkit::DefaultRuler::Snap(float x, float bias) const; +Dali::Toolkit::FixedRuler::Snap(float x, float bias) const; +Dali::Toolkit::Ruler::SnapAndClamp(float x, float bias = 0.5f, float length = 0.0f, float scale = 1.0f) const; +Dali::Toolkit::Ruler::SnapAndClamp(float x, float bias, float length, float scale, ClampState &clamped) const; +Dali::Toolkit::ScrollView::SnapStartedSignal(); +Dali::Toolkit::ScrollView::UnbindActor(Actor child); +Dali::Toolkit::ScrollView::operator=( const ScrollView& handle ); +Dali::Toolkit::Ruler::~Ruler(); +Dali::Toolkit::ScrollView::~ScrollView(); +Dali::Toolkit::Scrollable::DownCast( BaseHandle handle ); +Dali::Toolkit::Scrollable::GetOvershootAnimationSpeed() const; +Dali::Toolkit::Scrollable::GetOvershootEffectColor() const; +Dali::Toolkit::Scrollable::IsOvershootEnabled() const; +Dali::Toolkit::Scrollable::ScrollCompletedSignal(); +Dali::Toolkit::Scrollable::ScrollStartedSignal(); +Dali::Toolkit::Scrollable::ScrollUpdatedSignal(); +Dali::Toolkit::Scrollable::Scrollable( const Scrollable& handle ); +Dali::Toolkit::Scrollable::Scrollable(); +Dali::Toolkit::Scrollable::SetOvershootAnimationSpeed( float pixelsPerSecond ); +Dali::Toolkit::Scrollable::SetOvershootEffectColor( const Vector4& color ); +Dali::Toolkit::Scrollable::SetOvershootEnabled(bool enable); +Dali::Toolkit::Scrollable::operator=( const Scrollable& handle ); +Dali::Toolkit::Scrollable::~Scrollable(); +Dali::Toolkit::TableView::AddChild( Actor child, CellPosition position ); +Dali::Toolkit::TableView::CellPosition::CellPosition( unsigned int rowIndex = 0, unsigned int columnIndex = 0, +Dali::Toolkit::TableView::DeleteColumn( unsigned int columnIndex ); +Dali::Toolkit::TableView::DeleteColumn( unsigned int columnIndex, std::vector& removed ); +Dali::Toolkit::TableView::DeleteRow( unsigned int rowIndex ); +Dali::Toolkit::TableView::DeleteRow( unsigned int rowIndex, std::vector& removed ); +Dali::Toolkit::TableView::DownCast( BaseHandle handle ); +Dali::Toolkit::TableView::FindChildPosition( Actor child, CellPosition& position ); +Dali::Toolkit::TableView::GetCellPadding(); +Dali::Toolkit::TableView::GetChildAt( CellPosition position ); +Dali::Toolkit::TableView::GetColumns(); +Dali::Toolkit::TableView::GetFixedHeight( unsigned int rowIndex ) const; +Dali::Toolkit::TableView::GetFixedWidth( unsigned int columnIndex ) const; +Dali::Toolkit::TableView::GetRelativeHeight( unsigned int rowIndex ) const; +Dali::Toolkit::TableView::GetRelativeWidth( unsigned int columnIndex ) const; +Dali::Toolkit::TableView::GetRows(); +Dali::Toolkit::TableView::InsertColumn( unsigned int columnIndex ); +Dali::Toolkit::TableView::InsertRow( unsigned int rowIndex ); +Dali::Toolkit::TableView::IsFitHeight( unsigned int rowIndex ) const; +Dali::Toolkit::TableView::IsFitWidth( unsigned int columnIndex ) const; +Dali::Toolkit::TableView::New( unsigned int initialRows, unsigned int initialColumns ); +Dali::Toolkit::TableView::RemoveChildAt( CellPosition position ); +Dali::Toolkit::TableView::Resize( unsigned int rows, unsigned int columns ); +Dali::Toolkit::TableView::Resize( unsigned int rows, unsigned int columns, std::vector& removed ); +Dali::Toolkit::TableView::SetCellAlignment( CellPosition position, HorizontalAlignment::Type horizontal, VerticalAlignment::Type vertical ); +Dali::Toolkit::TableView::SetCellPadding( Size padding ); +Dali::Toolkit::TableView::SetFitHeight( unsigned int rowIndex ); +Dali::Toolkit::TableView::SetFitWidth( unsigned int columnIndex ); +Dali::Toolkit::TableView::SetFixedHeight( unsigned int rowIndex, float height ); +Dali::Toolkit::TableView::SetFixedWidth( unsigned int columnIndex, float width ); +Dali::Toolkit::TableView::SetRelativeHeight( unsigned int rowIndex, float heightPercentage ); +Dali::Toolkit::TableView::SetRelativeWidth( unsigned int columnIndex, float widthPercentage ); +Dali::Toolkit::TableView::TableView( const TableView& handle ); +Dali::Toolkit::TableView::TableView(); +Dali::Toolkit::TableView::operator=( const TableView& handle ); +Dali::Toolkit::TableView::~TableView(); +Dali::Toolkit::TextField::DownCast( BaseHandle handle ); +Dali::Toolkit::TextField::MaxLengthReachedSignal(); +Dali::Toolkit::TextField::New(); +Dali::Toolkit::TextField::TextChangedSignal(); +Dali::Toolkit::TextField::TextField( const TextField& handle ); +Dali::Toolkit::TextField::TextField(); +Dali::Toolkit::TextField::operator=( const TextField& handle ); +Dali::Toolkit::TextField::~TextField(); +Dali::Toolkit::TextField::InputStyleChangedSigna() +Dali::Toolkit::TextLabel::DownCast( BaseHandle handle ); +Dali::Toolkit::TextLabel::New( const std::string& text ); +Dali::Toolkit::TextLabel::New(); +Dali::Toolkit::TextLabel::TextLabel( const TextLabel& handle ); +Dali::Toolkit::TextLabel::TextLabel(); +Dali::Toolkit::TextLabel::operator=( const TextLabel& handle ); +Dali::Toolkit::TextLabel::~TextLabel(); +Dali::Toolkit::IsHorizontal(ControlOrientation::Type orientation); +Dali::Toolkit::KeyboardFocusManager::ClearFocus(); +Dali::Toolkit::KeyboardFocusManager::FocusChangedSignal(); +Dali::Toolkit::KeyboardFocusManager::FocusGroupChangedSignal(); +Dali::Toolkit::KeyboardFocusManager::FocusedActorEnterKeySignal(); +Dali::Toolkit::KeyboardFocusManager::Get(); +Dali::Toolkit::KeyboardFocusManager::GetCurrentFocusActor(); +Dali::Toolkit::KeyboardFocusManager::GetFocusGroup(Actor actor); +Dali::Toolkit::KeyboardFocusManager::GetFocusGroupLoop() const; +Dali::Toolkit::KeyboardFocusManager::GetFocusIndicatorActor(); +Dali::Toolkit::KeyboardFocusManager::IsFocusGroup(Actor actor) const; +Dali::Toolkit::KeyboardFocusManager::KeyboardFocusManager(); +Dali::Toolkit::KeyboardFocusManager::MoveFocus(Control::KeyboardFocus::Direction direction); +Dali::Toolkit::KeyboardFocusManager::MoveFocusBackward(); +Dali::Toolkit::KeyboardFocusManager::PreFocusChangeSignal(); +Dali::Toolkit::KeyboardFocusManager::SetAsFocusGroup(Actor actor, bool isFocusGroup); +Dali::Toolkit::KeyboardFocusManager::SetCurrentFocusActor(Actor actor); +Dali::Toolkit::KeyboardFocusManager::SetFocusGroupLoop(bool enabled); +Dali::Toolkit::KeyboardFocusManager::SetFocusIndicatorActor(Actor indicator); +Dali::Toolkit::KeyboardFocusManager::~KeyboardFocusManager(); +Dali::Toolkit::Model3dView::New(); +Dali::Toolkit::Model3dView::New( const std::string& objUrl, const std::string& mtlUrl, const std::string& imagesUrl ); +Dali::Toolkit::Model3dView::Model3dView(); +Dali::Toolkit::Model3dView::~Model3dView(); +Dali::Toolkit::Model3dView::Model3dView( const Model3dView& model3dView ); +Dali::Toolkit::Model3dView::operator=( const Model3dView& model3dView ) +Dali::Toolkit::Model3dView::DownCast( BaseHandle handle ); +Dali::Toolkit::StyleManager::StyleManager() +Dali::Toolkit::StyleManager::~StyleManager() +Dali::Toolkit::StyleManager::Get() +Dali::Toolkit::StyleManager::ApplyTheme( const std::string& themeFile ) +Dali::Toolkit::StyleManager::ApplyDefaultTheme() +Dali::Toolkit::StyleManager::SetStyleConstant( const std::string& key, const Property::Value& value ) +Dali::Toolkit::StyleManager::GetStyleConstant( const std::string& key, Property::Value& valueOut ) +Dali::Toolkit::StyleManager::ApplyStyle( Toolkit::Control control, const std::string& jsonFileName, const std::string& styleName ) +Dali::Toolkit::StyleManager::StyleChangedSignal() +Dali::Toolkit::StyleManager::StyleManager( Internal::StyleManager *impl ) +Dali::Toolkit::FlexContainer::FlexContainer(); +Dali::Toolkit::FlexContainer::FlexContainer( const FlexContainer& handle ); +Dali::Toolkit::FlexContainer::FlexContainer& operator=( const FlexContainer& handle ); +Dali::Toolkit::FlexContainer::~FlexContainer(); +Dali::Toolkit::FlexContainer::New(); +Dali::Toolkit::FlexContainer::DownCast(); +Dali::Toolkit::TextEditor::New(); +Dali::Toolkit::TextEditor::TextEditor(); +Dali::Toolkit::TextEditor::TextEditor( const TextEditor& handle ); +Dali::Toolkit::TextEditor::operator=( const TextEditor& handle ); +Dali::Toolkit::TextEditor::~TextEditor(); +Dali::Toolkit::TextEditor::DownCast( BaseHandle handle ); +Dali::Toolkit::TextEditor::TextChangedSignal(); +Dali::Toolkit::TextEditor::InputStyleChangedSignal() +Dali::Toolkit::TextEditor::ScrollStateChangedSignal(Dali::Toolkit::TextEditor) +Dali::Toolkit::Slider::Slider(); +Dali::Toolkit::Slider::Slider( const Slider& handle ); +Dali::Toolkit::Slider::Slider& operator=( const Slider& handle ); +Dali::Toolkit::Slider::~Slider(); +Dali::Toolkit::Slider::New(); +Dali::Toolkit::Slider::DownCast( BaseHandle handle ); +Dali::Toolkit::Slider::ValueChangedSignal() +Dali::Toolkit::Slider::SlidingFinishedSignal() +Dali::Toolkit::Slider::MarkReachedSignal() +Dali::Toolkit::VideoView::New() +Dali::Toolkit::VideoView::New(const std::string& url) +Dali::Toolkit::VideoView::New( bool swCodec ) +Dali::Toolkit::VideoView::New( const std::string& url, bool swCodec ) +Dali::Toolkit::VideoView::VideoView() +Dali::Toolkit::VideoView::~VideoView() +Dali::Toolkit::VideoView::VideoView(const VideoView& videoView) +Dali::Toolkit::VideoView::operator=(const VideoView& videoView) +Dali::Toolkit::VideoView::DownCast(BaseHandle handle) +Dali::Toolkit::VideoView::Play() +Dali::Toolkit::VideoView::Pause() +Dali::Toolkit::VideoView::Stop() +Dali::Toolkit::VideoView::Forward(int millisecond) +Dali::Toolkit::VideoView::Backward(int millisecond) +Dali::Toolkit::VideoView::FinishedSignal() +Dali::Toolkit::AsyncImageLoader() +Dali::Toolkit::~AsyncImageLoader() +Dali::Toolkit::AsyncImageLoader( const AsyncImageLoader& handle ) +Dali::Toolkit::AsyncImageLoader::operator=( const AsyncImageLoader& handle ) +Dali::Toolkit::AsyncImageLoader::New() +Dali::Toolkit::AsyncImageLoader::DownCast( BaseHandle handle ) +Dali::Toolkit::AsyncImageLoader::Load( const std::string& url ) +Dali::Toolkit::AsyncImageLoader::Load( const std::string& url, ImageDimensions dimensions ) +Dali::Toolkit::AsyncImageLoader::Load( const std::string& url, ImageDimensions dimensions, FittingMode::Type fittingMode, SamplingMode::Type samplingMode, bool orientationCorrection ) +Dali::Toolkit::AsyncImageLoader::Cancel( uint32_t loadingTaskId ) +Dali::Toolkit::AsyncImageLoader::CancelAll() +Dali::Toolkit::AsyncImageLoader::ImageLoadedSignal() +Dali::Toolkit::SyncImageLoader::Load( const std::string& url ) +Dali::Toolkit::SyncImageLoader::Load( const std::string& url, ImageDimensions dimensions ) +Dali::Toolkit::SyncImageLoader::Load( const std::string& url, ImageDimensions dimensions, FittingMode::Type fittingMode, SamplingMode::Type samplingMode, bool orientationCorrection ) +Dali::Toolkit::ProgressBar::DownCast(Dali::BaseHandle) +Dali::Toolkit::ProgressBar::New() +Dali::Toolkit::ProgressBar::ProgressBar() +Dali::Toolkit::ProgressBar::ProgressBar(Dali::Toolkit::ProgressBarconst&) +Dali::Toolkit::ProgressBar::ValueChangedSignal() +Dali::Toolkit::ProgressBar::operator=(Dali::Toolkit::ProgressBarconst&) +Dali::Toolkit::ProgressBar::~ProgressBar() +ecore_con_client_connected_get +ecore_con_client_data_get +ecore_con_client_data_set +ecore_con_client_del +ecore_con_client_fd_get +ecore_con_client_flush +ecore_con_client_ip_get +ecore_con_client_port_get +ecore_con_client_send +ecore_con_client_server_get +ecore_con_client_timeout_get +ecore_con_client_timeout_set +ecore_con_client_uptime_get +ecore_con_eet +ecore_con_eet_client_connect_callback_add +ecore_con_eet_client_connect_callback_del +ecore_con_eet_client_disconnect_callback_add +ecore_con_eet_client_disconnect_callback_del +ecore_con_eet_client_new +ecore_con_eet_data_callback_add +ecore_con_eet_data_callback_del +ecore_con_eet_data_get +ecore_con_eet_data_set +ecore_con_eet_raw_data_callback_add +ecore_con_eet_raw_data_callback_del +ecore_con_eet_raw_send +ecore_con_eet_register +ecore_con_eet_reply +ecore_con_eet_send +ecore_con_eet_server_connect_callback_add +ecore_con_eet_server_connect_callback_del +ecore_con_eet_server_disconnect_callback_add +ecore_con_eet_server_disconnect_callback_del +ecore_con_eet_server_free +ecore_con_eet_server_new +ECORE_CON_EVENT_CLIENT_ADD +ECORE_CON_EVENT_CLIENT_DATA +ECORE_CON_EVENT_CLIENT_DEL +ECORE_CON_EVENT_CLIENT_ERROR +ECORE_CON_EVENT_CLIENT_UPGRADE +ECORE_CON_EVENT_CLIENT_WRITE +ECORE_CON_EVENT_PROXY_BIND +ECORE_CON_EVENT_SERVER_ADD +ECORE_CON_EVENT_SERVER_DATA +ECORE_CON_EVENT_SERVER_DEL +ECORE_CON_EVENT_SERVER_ERROR +ECORE_CON_EVENT_SERVER_UPGRADE +ECORE_CON_EVENT_SERVER_WRITE +ECORE_CON_EVENT_URL_COMPLETE +ECORE_CON_EVENT_URL_DATA +ECORE_CON_EVENT_URL_PROGRESS +ecore_con_init +ecore_con_lookup +ecore_con_server_add +ecore_con_server_client_limit_set +ecore_con_server_clients_get +ecore_con_server_connect +ecore_con_server_connected_get +ecore_con_server_data_get +ecore_con_server_data_set +ecore_con_server_del +ecore_con_server_fd_get +ecore_con_server_flush +ecore_con_server_ip_get +ecore_con_server_name_get +ecore_con_server_port_get +ecore_con_server_send +ecore_con_server_timeout_get +ecore_con_server_timeout_set +ecore_con_server_uptime_get +ecore_con_shutdown +ecore_con_socks4_remote_add +ecore_con_socks4_remote_del +ecore_con_socks4_remote_exists +ecore_con_socks5_remote_add +ecore_con_socks5_remote_del +ecore_con_socks5_remote_exists +ecore_con_socks_apply_always +ecore_con_socks_apply_once +ecore_con_socks_bind_get +ecore_con_socks_bind_set +ecore_con_socks_lookup_get +ecore_con_socks_lookup_set +ecore_con_socks_remote_del +ecore_con_socks_version_get +ecore_con_ssl_available_get +ecore_con_ssl_client_upgrade +ecore_con_ssl_server_cafile_add +ecore_con_ssl_server_cert_add +ecore_con_ssl_server_crl_add +ecore_con_ssl_server_privkey_add +ecore_con_ssl_server_upgrade +ecore_con_ssl_server_verify +ecore_con_ssl_server_verify_basic +ecore_con_ssl_server_verify_name_get +ecore_con_ssl_server_verify_name_set +ecore_con_url_additional_header_add +ecore_con_url_additional_headers_clear +ecore_con_url_cookies_clear +ecore_con_url_cookies_file_add +ecore_con_url_cookies_ignore_old_session_set +ecore_con_url_cookies_init +ecore_con_url_cookies_jar_file_set +ecore_con_url_cookies_jar_write +ecore_con_url_cookies_session_clear +ecore_con_url_custom_new +ecore_con_url_data_get +ecore_con_url_data_set +ecore_con_url_fd_set +ecore_con_url_free +ecore_con_url_ftp_upload +ecore_con_url_ftp_use_epsv_set +ecore_con_url_get +ecore_con_url_head +ecore_con_url_httpauth_set +ecore_con_url_http_version_set +ecore_con_url_init +ecore_con_url_new +ecore_con_url_pipeline_get +ecore_con_url_pipeline_set +ecore_con_url_post +ecore_con_url_proxy_password_set +ecore_con_url_proxy_set +ecore_con_url_proxy_username_set +ecore_con_url_received_bytes_get +ecore_con_url_response_headers_get +ecore_con_url_shutdown +ecore_con_url_ssl_ca_set +ecore_con_url_ssl_verify_peer_set +ecore_con_url_status_code_get +ecore_con_url_time +ecore_con_url_timeout_set +ecore_con_url_url_get +ecore_con_url_url_set +ecore_con_url_verbose_set +ecore_evas_activate +ecore_evas_alpha_get +ecore_evas_alpha_set +ecore_evas_app_comp_sync_get +ecore_evas_app_comp_sync_set +ecore_evas_aspect_get +ecore_evas_aspect_set +ecore_evas_aux_hint_del +ecore_evas_aux_hint_id_get +ecore_evas_aux_hints_allowed_get +ecore_evas_aux_hints_supported_get +ecore_evas_aux_hint_val_get +ecore_evas_aux_hint_val_set +ecore_evas_borderless_get +ecore_evas_borderless_set +ecore_evas_buffer_allocfunc_new +ecore_evas_buffer_ecore_evas_parent_get +ecore_evas_buffer_new +ecore_evas_buffer_pixels_get +ecore_evas_callback_delete_request_set +ecore_evas_callback_destroy_set +ecore_evas_callback_focus_in_set +ecore_evas_callback_focus_out_set +ecore_evas_callback_hide_set +ecore_evas_callback_mouse_in_set +ecore_evas_callback_mouse_out_set +ecore_evas_callback_move_set +ecore_evas_callback_msg_handle_set +ecore_evas_callback_msg_parent_handle_set +ecore_evas_callback_post_render_set +ecore_evas_callback_pre_free_set +ecore_evas_callback_pre_render_set +ecore_evas_callback_resize_set +ecore_evas_callback_show_set +ecore_evas_callback_state_change_set +ecore_evas_callback_sticky_set +ecore_evas_callback_unsticky_set +ecore_evas_comp_sync_get +ecore_evas_comp_sync_set +ecore_evas_cursor_get +ecore_evas_cursor_set +ecore_evas_cursor_unset +ecore_evas_data_get +ecore_evas_data_set +ecore_evas_draw_frame_get +ecore_evas_draw_frame_set +ecore_evas_ecore_evas_get +ecore_evas_focus_get +ecore_evas_focus_set +ecore_evas_focus_skip_get +ecore_evas_focus_skip_set +ecore_evas_free +ecore_evas_fullscreen_get +ecore_evas_fullscreen_set +ecore_evas_geometry_get +ecore_evas_get +ecore_evas_hide +ecore_evas_iconified_get +ecore_evas_iconified_set +ecore_evas_ignore_events_get +ecore_evas_ignore_events_set +ecore_evas_init +ecore_evas_input_event_register +ecore_evas_input_event_unregister +ecore_evas_layer_get +ecore_evas_layer_set +ecore_evas_lower +ecore_evas_manual_render +ecore_evas_manual_render_get +ecore_evas_manual_render_set +ecore_evas_maximized_get +ecore_evas_maximized_set +ecore_evas_move +ecore_evas_move_resize +ecore_evas_msg_parent_send +ecore_evas_msg_send +ecore_evas_name_class_get +ecore_evas_name_class_set +ecore_evas_pointer_warp +ecore_evas_pointer_xy_get +ecore_evas_raise +ecore_evas_request_geometry_get +ecore_evas_resize +ecore_evas_rotation_get +ecore_evas_rotation_set +ecore_evas_rotation_with_resize_set +ecore_evas_screen_dpi_get +ecore_evas_screen_geometry_get +ecore_evas_show +ecore_evas_shutdown +ecore_evas_size_base_get +ecore_evas_size_base_set +ecore_evas_size_max_get +ecore_evas_size_max_set +ecore_evas_size_min_get +ecore_evas_size_min_set +ecore_evas_size_step_get +ecore_evas_size_step_set +ecore_evas_title_get +ecore_evas_title_set +ecore_evas_transparent_get +ecore_evas_transparent_set +ecore_evas_visibility_get +ecore_evas_window_get +ecore_evas_window_profile_supported_get +ecore_evas_withdrawn_get +ecore_evas_withdrawn_set +ecore_evas_wm_rotation_available_rotations_get +ecore_evas_wm_rotation_available_rotations_set +ecore_evas_wm_rotation_manual_rotation_done +ecore_evas_wm_rotation_manual_rotation_done_get +ecore_evas_wm_rotation_manual_rotation_done_set +ecore_evas_wm_rotation_preferred_rotation_get +ecore_evas_wm_rotation_preferred_rotation_set +ecore_evas_wm_rotation_supported_get +ecore_file_app_exe_get +ecore_file_app_installed +ecore_file_app_list +ecore_file_can_exec +ecore_file_can_read +ecore_file_can_write +ecore_file_cp +ecore_file_dir_get +ecore_file_dir_is_empty +ecore_file_download +ecore_file_download_abort +ecore_file_download_abort_all +ecore_file_download_full +ecore_file_download_protocol_available +ecore_file_escape_name +ecore_file_exists +ecore_file_file_get +ecore_file_init +ecore_file_is_dir +ecore_file_ls +ecore_file_mkdir +ecore_file_mkdirs +ecore_file_mkpath +ecore_file_mkpaths +ecore_file_mksubdirs +ecore_file_mod_time +ecore_file_monitor_add +ecore_file_monitor_del +ecore_file_monitor_path_get +ecore_file_mv +ecore_file_path_dir_exists +ecore_file_readlink +ecore_file_realpath +ecore_file_recursive_rm +ecore_file_remove +ecore_file_rmdir +ecore_file_shutdown +ecore_file_size +ecore_file_strip_ext +ecore_file_symlink +ecore_file_unlink +ecore_ipc_client_data_get +ecore_ipc_client_data_set +ecore_ipc_client_data_size_max_get +ecore_ipc_client_data_size_max_set +ecore_ipc_client_del +ecore_ipc_client_flush +ecore_ipc_client_ip_get +ecore_ipc_client_send +ecore_ipc_client_server_get +ecore_ipc_init +ecore_ipc_server_add +ecore_ipc_server_client_limit_set +ecore_ipc_server_clients_get +ecore_ipc_server_connect +ecore_ipc_server_connected_get +ecore_ipc_server_data_get +ecore_ipc_server_data_size_max_get +ecore_ipc_server_data_size_max_set +ecore_ipc_server_del +ecore_ipc_server_flush +ecore_ipc_server_ip_get +ecore_ipc_server_send +ecore_ipc_shutdown +ecore_ipc_ssl_available_get +ecore_app_args_get +ecore_app_args_set +ecore_app_no_system_modules +ecore_app_restart +ecore_exe_auto_limits_set +ecore_exe_callback_pre_free_set +ecore_exe_close_stdin +ecore_exe_cmd_get +ecore_exe_continue +ecore_exe_data_get +ecore_exe_data_set +ECORE_EXE_EVENT_ADD +ECORE_EXE_EVENT_DATA +ecore_exe_event_data_free +ecore_exe_event_data_get +ECORE_EXE_EVENT_DEL +ECORE_EXE_EVENT_ERROR +ecore_exe_flags_get +ecore_exe_free +ecore_exe_hup +ecore_exe_interrupt +ecore_exe_kill +ecore_exe_pause +ecore_exe_pid_get +ecore_exe_pipe_run +ecore_exe_quit +ecore_exe_run +ecore_exe_run_priority_get +ecore_exe_run_priority_set +ecore_exe_send +ecore_exe_signal +ecore_exe_tag_get +ecore_exe_tag_set +ecore_exe_terminate +ecore_getopt_callback_geometry_parse +ecore_getopt_callback_size_parse +ecore_getopt_help +ecore_getopt_help_category +ecore_getopt_list_free +ecore_getopt_parse +ecore_getopt_parse_positional +ecore_getopt_parser_has_duplicates +ecore_init +ecore_main_loop_animator_ticked_get +ecore_main_loop_iterate_may_block +ecore_main_loop_nested_get +ecore_main_loop_thread_safe_call_wait +ecore_memory_state_get +ecore_memory_state_set +ecore_pipe_full_add +ecore_pipe_read_fd +ecore_pipe_write_fd +ecore_power_state_get +ecore_power_state_set +ecore_shutdown +ecore_thread_wait +ecore_throttle_adjust +ecore_throttle_get +ecore_timer_freeze_get +edje_audio_channel_mute_get +edje_audio_channel_mute_set +edje_available_modules_get +edje_collection_cache_flush +edje_collection_cache_get +edje_collection_cache_set +edje_color_class_active_iterator_new +edje_external_iterator_get +edje_external_param_bool_get +edje_external_param_choice_get +edje_external_param_double_get +edje_external_param_find +edje_external_param_info_get +edje_external_param_int_get +edje_external_param_string_get +edje_external_param_type_str +edje_external_type_abi_version_get +edje_external_type_array_register +edje_external_type_array_unregister +edje_external_type_get +edje_external_type_register +edje_external_type_unregister +edje_file_cache_flush +edje_file_cache_get +edje_file_cache_set +edje_file_iterator_new +edje_fontset_append_get +edje_fontset_append_set +edje_init +edje_language_set +edje_mmap_collection_list +edje_mmap_collection_list_free +edje_mmap_color_class_iterator_new +edje_mmap_data_get +edje_mmap_group_exists +edje_module_load +edje_object_color_class_description_get +edje_object_item_provider_set +edje_object_language_get +edje_object_language_set +edje_object_mirrored_get +edje_object_mirrored_set +edje_object_mmap_set +edje_object_part_external_content_get +edje_object_part_external_object_get +edje_object_part_external_param_get +edje_object_part_external_param_set +edje_object_part_external_param_type_get +edje_object_part_object_name_get +edje_object_part_text_autocapital_type_get +edje_object_part_text_autocapital_type_set +edje_object_part_text_cursor_begin_set +edje_object_part_text_cursor_content_get +edje_object_part_text_cursor_coord_set +edje_object_part_text_cursor_copy +edje_object_part_text_cursor_down +edje_object_part_text_cursor_end_set +edje_object_part_text_cursor_geometry_get +edje_object_part_text_cursor_is_format_get +edje_object_part_text_cursor_is_visible_format_get +edje_object_part_text_cursor_line_begin_set +edje_object_part_text_cursor_line_end_set +edje_object_part_text_cursor_next +edje_object_part_text_cursor_pos_get +edje_object_part_text_cursor_pos_set +edje_object_part_text_cursor_prev +edje_object_part_text_cursor_up +edje_object_part_text_imf_context_get +edje_object_part_text_imf_context_reset +edje_object_part_text_input_hint_get +edje_object_part_text_input_hint_set +edje_object_part_text_input_panel_enabled_get +edje_object_part_text_input_panel_enabled_set +edje_object_part_text_input_panel_hide +edje_object_part_text_input_panel_imdata_get +edje_object_part_text_input_panel_imdata_set +edje_object_part_text_input_panel_language_get +edje_object_part_text_input_panel_language_set +edje_object_part_text_input_panel_layout_get +edje_object_part_text_input_panel_layout_set +edje_object_part_text_input_panel_layout_variation_get +edje_object_part_text_input_panel_layout_variation_set +edje_object_part_text_input_panel_return_key_disabled_get +edje_object_part_text_input_panel_return_key_disabled_set +edje_object_part_text_input_panel_return_key_type_get +edje_object_part_text_input_panel_return_key_type_set +edje_object_part_text_input_panel_show +edje_object_part_text_input_panel_show_on_demand_get +edje_object_part_text_input_panel_show_on_demand_set +edje_object_part_text_prediction_allow_get +edje_object_part_text_prediction_allow_set +edje_object_part_text_select_abort +edje_object_part_text_select_all +edje_object_part_text_select_allow_set +edje_object_part_text_select_begin +edje_object_part_text_select_extend +edje_object_part_text_selection_get +edje_object_part_text_select_none +edje_object_text_insert_filter_callback_add +edje_object_text_insert_filter_callback_del +edje_object_text_insert_filter_callback_del_full +edje_object_text_markup_filter_callback_add +edje_object_text_markup_filter_callback_del +edje_object_text_markup_filter_callback_del_full +edje_object_transition_duration_factor_get +edje_object_transition_duration_factor_set +edje_password_show_last_set +edje_password_show_last_timeout_set +edje_shutdown +edje_transition_duration_factor_get +edje_transition_duration_factor_set +eet_alias +eet_alias_get +eet_clearcache +eet_close +eet_connection_close +eet_connection_empty +eet_connection_new +eet_connection_node_send +eet_connection_received +eet_connection_send +eet_data_descriptor2_new +eet_data_descriptor3_new +eet_data_descriptor_decode +eet_data_descriptor_decode_cipher +eet_data_descriptor_element_add +eet_data_descriptor_encode +eet_data_descriptor_encode_cipher +eet_data_descriptor_file_new +eet_data_descriptor_free +eet_data_descriptor_name_get +eet_data_descriptor_stream_new +eet_data_dump +eet_data_dump_cipher +eet_data_image_colorspace_get +eet_data_image_decode +eet_data_image_decode_cipher +eet_data_image_decode_to_cspace_surface_cipher +eet_data_image_decode_to_surface +eet_data_image_decode_to_surface_cipher +eet_data_image_encode +eet_data_image_encode_cipher +eet_data_image_header_decode +eet_data_image_header_decode_cipher +eet_data_image_header_read +eet_data_image_header_read_cipher +eet_data_image_read +eet_data_image_read_cipher +eet_data_image_read_to_cspace_surface_cipher +eet_data_image_read_to_surface +eet_data_image_read_to_surface_cipher +eet_data_image_write +eet_data_image_write_cipher +eet_data_node_decode_cipher +eet_data_node_encode_cipher +eet_data_node_read_cipher +eet_data_node_write_cipher +eet_data_read +eet_data_read_cipher +eet_data_read_cipher_buffer +eet_data_text_dump +eet_data_text_dump_cipher +eet_data_text_undump +eet_data_text_undump_cipher +eet_data_undump +eet_data_undump_cipher +eet_data_write +eet_data_write_cipher +eet_data_xattr_cipher_get +eet_data_xattr_cipher_set +eet_delete +eet_dictionary_count +eet_dictionary_get +eet_dictionary_string_check +eet_eina_file_data_descriptor_class_set +eet_eina_stream_data_descriptor_class_set +eet_file_get +eet_identity_certificate_print +eet_identity_close +eet_identity_open +eet_identity_print +eet_identity_set +eet_identity_sha1 +eet_identity_signature +eet_identity_verify +eet_identity_x509 +eet_init +eet_list +eet_list_entries +eet_memopen_read +eet_mmap +eet_mode_get +eet_node_array_new +eet_node_char_new +eet_node_children_get +eet_node_del +eet_node_double_new +eet_node_dump +eet_node_float_new +eet_node_hash_add +eet_node_hash_new +eet_node_inlined_string_new +eet_node_int_new +eet_node_list_append +eet_node_list_new +eet_node_long_long_new +eet_node_next_get +eet_node_null_new +eet_node_parent_get +eet_node_short_new +eet_node_string_new +eet_node_struct_append +eet_node_struct_child_new +eet_node_struct_new +eet_node_type_get +eet_node_unsigned_char_new +eet_node_unsigned_int_new +eet_node_unsigned_long_long_new +eet_node_unsigned_short_new +eet_node_value_get +eet_node_var_array_new +eet_node_walk +eet_num_entries +eet_open +eet_read +eet_read_cipher +eet_read_direct +eet_shutdown +eet_sync +eet_write +eet_write_cipher +eet_version +eina_accessor_clone +eina_benchmark_free +eina_benchmark_new +eina_benchmark_register +eina_benchmark_run +eina_bezier_angle_at +eina_bezier_bounds_get +eina_bezier_length_get +eina_bezier_point_at +eina_bezier_split_at_length +eina_bezier_t_at +eina_bezier_values_get +eina_bezier_values_set +eina_binbuf_append_buffer +eina_binbuf_manage_new +eina_binshare_init +eina_binshare_shutdown +eina_cow_add +eina_cow_alloc +eina_cow_del +eina_cow_done +eina_cow_free +eina_cow_gc +eina_cow_memcpy +eina_cow_write +eina_cpu_count +eina_cpu_features_get +eina_cpu_page_size +_eina_crc +eina_environment_home_get +eina_environment_tmp_get +eina_error_find +eina_error_get +eina_error_msg_get +eina_error_msg_modify +eina_error_msg_register +eina_error_msg_static_register +eina_error_set +eina_f32p32_cos +eina_f32p32_sin +eina_file_close +eina_file_copy +eina_file_direct_ls +eina_file_dir_list +eina_file_dup +eina_file_filename_get +eina_file_ls +eina_file_map_all +eina_file_map_faulted +eina_file_map_free +eina_file_map_lines +eina_file_map_new +eina_file_map_populate +eina_file_mkdtemp +eina_file_mkstemp +eina_file_mtime_get +eina_file_open +eina_file_path_sanitize +eina_file_refresh +eina_file_size_get +eina_file_split +eina_file_statat +eina_file_stat_ls +eina_file_virtual +eina_file_virtualize +eina_file_xattr_get +eina_file_xattr_value_get +eina_hamster_count +eina_hash_list_append +eina_hash_list_prepend +eina_hash_list_remove +eina_inarray_resize +eina_init +eina_list_data_idx +eina_list_shuffle +eina_log_abort_on_critical_get +eina_log_abort_on_critical_level_get +eina_log_abort_on_critical_level_set +eina_log_abort_on_critical_set +eina_log_color_disable_set +eina_log_console_color_set +eina_log_domain_level_get +eina_log_domain_level_set +eina_log_domain_register +eina_log_domain_registered_level_set +eina_log_domain_unregister +eina_log_file_disable_get +eina_log_file_disable_set +eina_log_function_disable_get +eina_log_function_disable_set +eina_log_level_set +eina_log_main_thread_check +eina_log_print_cb_file +eina_log_print_cb_journald +eina_log_print_cb_set +eina_log_print_cb_stderr +eina_log_print_cb_stdout +_eina_log_state_init +_eina_log_state_shutdown +eina_log_threads_enable +eina_log_timing +eina_log_vprint +eina_magic_fail +eina_magic_string_get +eina_magic_string_set +eina_magic_string_static_set +eina_main_loop_define +eina_main_loop_is +eina_matrix2_array_set +eina_matrix2_copy +eina_matrix2_identity +eina_matrix2_inverse +eina_matrix2_multiply +eina_matrix2_multiply_copy +eina_matrix2_type_get +eina_matrix2_values_get +eina_matrix2_values_set +eina_matrix3_adjoint +eina_matrix3_array_set +eina_matrix3_cofactor +eina_matrix3_compose +eina_matrix3_copy +eina_matrix3_determinant +eina_matrix3_divide +eina_matrix3_equal +eina_matrix3_f16p16_compose +eina_matrix3_f16p16_identity +eina_matrix3_f16p16_type_get +eina_matrix3_fixed_values_get +eina_matrix3_identity +eina_matrix3_inverse +eina_matrix3_matrix3_f16p16_to +eina_matrix3_matrix4_to +eina_matrix3_multiply +eina_matrix3_multiply_copy +eina_matrix3_point_transform +eina_matrix3_position_transform_set +eina_matrix3_quad_quad_map +eina_matrix3_quad_square_map +eina_matrix3_quaternion_get +eina_matrix3_rectangle_transform +eina_matrix3_rotate +eina_matrix3_scale +eina_matrix3_scale_transform_set +eina_matrix3_square_quad_map +eina_matrix3_translate +eina_matrix3_transpose +eina_matrix3_type_get +eina_matrix3_values_get +eina_matrix3_values_set +eina_matrix4_array_set +eina_matrix4_copy +eina_matrix4_determinant +eina_matrix4_identity +eina_matrix4_inverse +eina_matrix4_matrix3_to +eina_matrix4_multiply +eina_matrix4_multiply_copy +eina_matrix4_normalized +eina_matrix4_ortho_set +eina_matrix4_quaternion_to +eina_matrix4_transpose +eina_matrix4_type_get +eina_matrix4_values_get +eina_matrix4_values_set +eina_memdup +eina_mempool_add +eina_mempool_alignof +eina_mempool_del +eina_mempool_gc +eina_mempool_register +eina_mempool_repack +eina_mempool_statistics +eina_mempool_unregister +eina_mmap_safety_enabled_get +eina_mmap_safety_enabled_set +eina_module_symbol_global_set +eina_normal3_matrix_get +eina_prefix_bin_get +eina_prefix_data_get +eina_prefix_free +eina_prefix_get +eina_prefix_lib_get +eina_prefix_locale_get +eina_prefix_new +eina_quad_coords_get +eina_quad_coords_set +eina_quad_rectangle_from +eina_quad_rectangle_to +eina_quadtree_add +eina_quadtree_change +eina_quadtree_collide +eina_quadtree_cycle +eina_quadtree_del +eina_quadtree_free +eina_quadtree_hide +eina_quadtree_increase +eina_quadtree_new +eina_quadtree_object +eina_quadtree_resize +eina_quadtree_show +eina_quaternion_add +eina_quaternion_conjugate +eina_quaternion_dot +eina_quaternion_f16p16_add +eina_quaternion_f16p16_conjugate +eina_quaternion_f16p16_dot +eina_quaternion_f16p16_lerp +eina_quaternion_f16p16_mul +eina_quaternion_f16p16_negative +eina_quaternion_f16p16_nlerp +eina_quaternion_f16p16_norm +eina_quaternion_f16p16_normalized +eina_quaternion_f16p16_rotate +eina_quaternion_f16p16_rotation_matrix3_get +eina_quaternion_f16p16_scale +eina_quaternion_f16p16_set +eina_quaternion_f16p16_slerp +eina_quaternion_lerp +eina_quaternion_matrix4_to +eina_quaternion_mul +eina_quaternion_negative +eina_quaternion_nlerp +eina_quaternion_norm +eina_quaternion_normalized +eina_quaternion_rotate +eina_quaternion_rotation_matrix3_get +eina_quaternion_scale +eina_quaternion_set +eina_quaternion_slerp +eina_sched_prio_drop +eina_shutdown +eina_simple_xml_attribute_w3c_parse +eina_strbuf_append_buffer +eina_strbuf_manage_read_only_new_length +eina_strbuf_tolower +eina_str_convert_len +eina_thread_create +eina_thread_equal +eina_thread_join +eina_thread_name_set +eina_thread_queue_fd_get +eina_thread_queue_fd_set +eina_thread_queue_free +eina_thread_queue_new +eina_thread_queue_parent_get +eina_thread_queue_parent_set +eina_thread_queue_pending_get +eina_thread_queue_poll +eina_thread_queue_send +eina_thread_queue_send_done +eina_thread_queue_wait +eina_thread_queue_wait_done +eina_thread_self +eina_threads_init +eina_threads_shutdown +eina_tiler_area_size_get +eina_tiler_area_size_set +eina_tiler_empty +eina_tiler_equal +eina_tiler_intersection +eina_tiler_strict_set +eina_tiler_subtract +eina_tiler_union +eina_tmpstr_len +eina_unicode_unicode_to_utf8_range +eina_ustrbuf_append_buffer +eina_ustrbuf_manage_read_only_new_length +eina_value_array_new +eina_value_convert +eina_value_copy +eina_value_free +eina_value_hash_new +eina_value_inner_alloc +eina_value_inner_free +eina_value_list_new +eina_value_new +eina_value_struct_new +eina_value_to_string +eina_value_type_check +eina_value_type_name_get +eina_value_util_struct_desc_new +eina_value_util_time_string_new +eina_xattr_copy +eina_xattr_del +eina_xattr_fd_copy +eina_xattr_fd_del +eina_xattr_fd_get +eina_xattr_fd_set +_eina_unicode_utf8_next_get +eio_dir_copy +eio_dir_direct_ls +eio_dir_move +eio_dir_stat_ls +eio_dir_unlink +eio_eet_close +eio_eet_data_image_write_cipher +eio_eet_data_read_cipher +eio_eet_data_write_cipher +eio_eet_open +eio_eet_read_cipher +eio_eet_read_direct +eio_eet_sync +eio_eet_write_cipher +eio_file_associate_add +eio_file_associate_direct_add +eio_file_associate_find +eio_file_cancel +eio_file_check +eio_file_chmod +eio_file_chown +eio_file_close +eio_file_container_get +eio_file_copy +eio_file_direct_ls +eio_file_direct_stat +eio_file_ls +eio_file_map_all +eio_file_map_new +eio_file_mkdir +eio_file_move +eio_file_open +eio_file_stat_ls +eio_file_unlink +eio_file_xattr +eio_file_xattr_double_get +eio_file_xattr_double_set +eio_file_xattr_get +eio_file_xattr_int_get +eio_file_xattr_int_set +eio_file_xattr_set +eio_file_xattr_string_get +eio_file_xattr_string_set +eio_init +eio_memory_burst_limit_get +eio_memory_burst_limit_set +eio_monitor_add +eio_monitor_del +EIO_MONITOR_DIRECTORY_CLOSED +EIO_MONITOR_DIRECTORY_CREATED +EIO_MONITOR_DIRECTORY_DELETED +EIO_MONITOR_DIRECTORY_MODIFIED +EIO_MONITOR_ERROR +EIO_MONITOR_FILE_CLOSED +EIO_MONITOR_FILE_CREATED +EIO_MONITOR_FILE_DELETED +EIO_MONITOR_FILE_MODIFIED +eio_monitor_path_get +EIO_MONITOR_SELF_DELETED +EIO_MONITOR_SELF_RENAME +eio_monitor_stringshared_add +eio_shutdown +eio_version +elm_atspi_attributes_list_free +elm_atspi_bridge_connected_get +elm_atspi_relation_clone +elm_atspi_relation_free +elm_atspi_relation_set_clone +elm_atspi_relation_set_free +elm_atspi_relation_set_relation_append +elm_atspi_relation_set_relation_remove +elm_atspi_relation_set_relation_type_remove +elm_atspi_text_text_attribute_free +elm_calendar_day_selection_disabled_get +elm_calendar_day_selection_disabled_set +elm_colorselector_palette_item_selected_get +elm_colorselector_palette_item_selected_set +elm_config_atspi_mode_get +elm_config_atspi_mode_set +elm_config_first_item_focus_on_first_focusin_get +elm_config_first_item_focus_on_first_focusin_set +elm_config_focus_autoscroll_mode_get +elm_config_focus_autoscroll_mode_set +elm_config_focus_highlight_clip_disabled_get +elm_config_focus_highlight_clip_disabled_set +elm_config_focus_move_policy_get +elm_config_focus_move_policy_set +elm_config_font_hint_type_set +elm_config_item_select_on_focus_disabled_get +elm_config_item_select_on_focus_disabled_set +elm_config_scroll_thumbscroll_smooth_amount_get +elm_config_scroll_thumbscroll_smooth_amount_set +elm_config_scroll_thumbscroll_smooth_start_get +elm_config_scroll_thumbscroll_smooth_start_set +elm_config_scroll_thumbscroll_smooth_time_window_get +elm_config_scroll_thumbscroll_smooth_time_window_set +elm_config_slider_indicator_visible_mode_get +elm_config_slider_indicator_visible_mode_set +elm_config_transition_duration_factor_get +elm_config_transition_duration_factor_set +elm_config_vsync_get +elm_config_vsync_set +elm_config_window_auto_focus_animate_get +elm_config_window_auto_focus_animate_set +elm_config_window_auto_focus_enable_get +elm_config_window_auto_focus_enable_set +elm_entry_cnp_textonly_get +elm_entry_cnp_textonly_set +elm_entry_context_menu_item_icon_get +elm_entry_context_menu_item_label_get +elm_entry_file_text_format_set +elm_entry_selection_handler_disabled_set +elm_frame_add +elm_frame_autocollapse_get +elm_frame_autocollapse_set +elm_frame_collapse_get +elm_frame_collapse_go +elm_frame_collapse_set +elm_gengrid_nth_item_get +elm_gesture_layer_cb_add +elm_gesture_layer_cb_del +elm_gesture_layer_tap_longpress_cb_add +elm_gesture_layer_tap_longpress_cb_del +elm_hoversel_auto_update_get +elm_hoversel_auto_update_set +elm_image_mmap_set +elm_index_item_priority_set +elm_index_standard_priority_get +elm_index_standard_priority_set +elm_label_slide_speed_get +elm_label_slide_speed_set +elm_layout_content_swallow_list_get +elm_layout_file_get +elm_layout_sizing_restricted_eval +elm_list_focus_on_selection_get +elm_list_focus_on_selection_set +elm_list_multi_select_mode_get +elm_list_multi_select_mode_set +elm_mapbuf_auto_get +elm_mapbuf_auto_set +elm_map_region_zoom_bring_in +elm_multibuttonentry_format_function_set +elm_multibuttonentry_item_data_get +elm_multibuttonentry_item_data_set +elm_object_access_info_get +elm_object_focused_item_get +elm_object_focus_highlight_style_get +elm_object_focus_highlight_style_set +elm_object_focus_move_policy_get +elm_object_focus_move_policy_set +elm_object_focus_next_item_get +elm_object_focus_next_item_set +elm_object_focus_region_show_mode_get +elm_object_focus_region_show_mode_set +elm_object_item_focus_get +elm_object_item_focus_next_item_get +elm_object_item_focus_next_item_set +elm_object_item_focus_next_object_get +elm_object_item_focus_next_object_set +elm_object_item_focus_set +elm_object_scroll_item_loop_enabled_get +elm_object_scroll_item_loop_enabled_set +elm_object_tooltip_domain_translatable_text_set +elm_object_tooltip_move_freeze_get +elm_object_tooltip_move_freeze_pop +elm_object_tooltip_move_freeze_push +elm_object_tooltip_orient_get +elm_object_tooltip_orient_set +elm_panel_scrollable_get +elm_panes_content_left_min_relative_size_get +elm_panes_content_left_min_relative_size_set +elm_panes_content_left_min_size_get +elm_panes_content_left_min_size_set +elm_panes_content_left_unset +elm_panes_content_right_min_relative_size_get +elm_panes_content_right_min_relative_size_set +elm_panes_content_right_min_size_get +elm_panes_content_right_min_size_set +elm_panes_content_right_unset +elm_photocam_image_orient_get +elm_photocam_image_orient_set +elm_progressbar_part_value_get +elm_progressbar_part_value_set +elm_scroller_loop_get +elm_scroller_page_snap_get +elm_scroller_page_snap_set +elm_scroller_step_size_get +elm_scroller_step_size_set +elm_scroller_wheel_disabled_get +elm_scroller_wheel_disabled_set +elm_slider_indicator_show_on_focus_get +elm_slider_indicator_show_on_focus_set +elm_table_align_get +elm_table_align_set +elm_table_child_get +elm_theme_extension_mmap_add +elm_theme_extension_mmap_del +elm_theme_group_base_list +elm_theme_group_path_find +elm_theme_overlay_mmap_add +elm_theme_overlay_mmap_del +elm_theme_system_dir_get +elm_theme_user_dir_get +elm_transit_go_in +elm_win_autohide_get +elm_win_autohide_set +elm_win_available_profiles_get +elm_win_available_profiles_set +elm_win_fake_add +elm_win_fake_canvas_set +elm_win_focus_highlight_animate_get +elm_win_focus_highlight_animate_set +elm_win_name_set +elm_win_noblank_get +elm_win_noblank_set +elm_win_trap_data_get +elm_win_type_set +elm_win_util_dialog_add +elm_object_part_access_register +elm_object_part_access_object_get +elm_access_object_register +elm_access_object_unregister +elm_access_object_get +elm_atspi_bridge_utils_say +elm_atspi_accessible_name_cb_set +elm_atspi_accessible_description_cb_set +elm_atspi_accessible_attribute_append +elm_atspi_accessible_reading_info_type_set +elm_atspi_accessible_reading_info_type_get +elm_atspi_accessible_gesture_cb_set +elm_atspi_accessible_can_highlight_set +elm_atspi_accessible_can_highlight_get +elm_atspi_component_highlight_grab +elm_atspi_component_highlight_clear +elm_atspi_accessible_relationships_clear +elm_config_language_auto_mirrored_set +elm_config_language_auto_mirrored_get +evas_alloc_error +evas_async_events_fd_get +evas_async_events_process +evas_async_events_put +evas_device_add +evas_device_class_get +evas_device_class_set +evas_device_del +evas_device_description_get +evas_device_description_set +evas_device_emulation_source_get +evas_device_emulation_source_set +evas_device_list +evas_device_name_get +evas_device_name_set +evas_device_parent_get +evas_device_parent_set +evas_device_pop +evas_device_push +evas_device_subclass_get +evas_device_subclass_set +evas_event_down_count_get +evas_event_feed_axis_update +evas_event_feed_hold +evas_event_feed_key_down +evas_event_feed_key_down_with_keycode +evas_event_feed_key_up +evas_event_feed_key_up_with_keycode +evas_event_feed_mouse_cancel +evas_event_feed_mouse_down +evas_event_feed_mouse_in +evas_event_feed_mouse_move +evas_event_feed_mouse_out +evas_event_feed_mouse_up +evas_event_feed_mouse_wheel +evas_event_feed_multi_down +evas_event_feed_multi_move +evas_event_feed_multi_up +evas_event_input_mouse_move +evas_event_input_multi_down +evas_event_input_multi_move +evas_event_input_multi_up +evas_event_refeed_event +evas_focus_get +evas_font_available_list +evas_font_available_list_free +evas_font_cache_flush +evas_font_cache_get +evas_font_cache_set +evas_font_hinting_can_hint +evas_font_hinting_get +evas_font_hinting_set +evas_font_path_append +evas_font_path_clear +evas_font_path_global_append +evas_font_path_global_clear +evas_font_path_global_list +evas_font_path_global_prepend +evas_font_path_list +evas_font_path_prepend +evas_font_reinit +evas_gl_current_evas_gl_get +evas_image_cache_flush +evas_image_cache_get +evas_image_cache_reload +evas_image_cache_set +evas_image_max_size_get +evas_init +evas_map_util_object_move_sync_get +evas_map_util_object_move_sync_set +evas_module_register +evas_module_unregister +evas_object_bottom_get +evas_object_clipees_has +evas_object_geometry_set +evas_object_image_mmap_get +evas_object_image_mmap_set +evas_object_image_orient_get +evas_object_image_orient_set +evas_object_image_snapshot_get +evas_object_image_snapshot_set +evas_object_image_source_events_get +evas_object_image_source_events_set +evas_object_image_video_surface_caps_get +evas_object_image_video_surface_caps_set +evas_object_intercept_clip_set_callback_add +evas_object_intercept_clip_set_callback_del +evas_object_intercept_clip_unset_callback_add +evas_object_intercept_clip_unset_callback_del +evas_object_intercept_color_set_callback_add +evas_object_intercept_color_set_callback_del +evas_object_intercept_focus_set_callback_add +evas_object_intercept_focus_set_callback_del +evas_object_intercept_hide_callback_add +evas_object_intercept_hide_callback_del +evas_object_intercept_layer_set_callback_add +evas_object_intercept_layer_set_callback_del +evas_object_intercept_lower_callback_add +evas_object_intercept_lower_callback_del +evas_object_intercept_move_callback_add +evas_object_intercept_move_callback_del +evas_object_intercept_raise_callback_add +evas_object_intercept_raise_callback_del +evas_object_intercept_resize_callback_add +evas_object_intercept_resize_callback_del +evas_object_intercept_show_callback_add +evas_object_intercept_show_callback_del +evas_object_intercept_stack_above_callback_add +evas_object_intercept_stack_above_callback_del +evas_object_intercept_stack_below_callback_add +evas_object_intercept_stack_below_callback_del +evas_object_is_frame_object_get +evas_object_is_frame_object_set +evas_object_name_child_find +evas_object_name_find +evas_object_paragraph_direction_get +evas_object_paragraph_direction_set +evas_objects_at_xy_get +evas_objects_in_rectangle_get +evas_object_size_hint_request_get +evas_object_size_hint_request_set +evas_object_smart_calculate +evas_object_smart_callback_description_find +evas_object_smart_callback_priority_add +evas_object_smart_clipped_class_get +evas_object_smart_clipped_clipper_get +evas_object_smart_clipped_smart_set +evas_object_smart_interface_data_get +evas_object_smart_interface_get +evas_object_smart_iterator_new +evas_object_smart_move_children_relative +evas_object_smart_need_recalculate_get +evas_object_smart_need_recalculate_set +evas_object_smart_smart_get +evas_object_smart_type_check_ptr +evas_object_text_ascent_get +evas_object_textblock_obstacle_add +evas_object_textblock_obstacle_del +evas_object_textblock_obstacles_update +evas_object_textblock_style_insets_get +evas_object_text_char_coords_get +evas_object_text_descent_get +evas_object_textgrid_add +evas_object_textgrid_cellrow_get +evas_object_textgrid_cellrow_set +evas_object_textgrid_cell_size_get +evas_object_textgrid_font_get +evas_object_textgrid_font_set +evas_object_textgrid_font_source_get +evas_object_textgrid_font_source_set +evas_object_textgrid_palette_get +evas_object_textgrid_palette_set +evas_object_textgrid_size_get +evas_object_textgrid_size_set +evas_object_textgrid_supported_font_styles_get +evas_object_textgrid_supported_font_styles_set +evas_object_textgrid_update_add +evas_object_text_horiz_advance_get +evas_object_text_inset_get +evas_object_text_max_ascent_get +evas_object_text_max_descent_get +evas_object_text_vert_advance_get +evas_object_top_at_pointer_get +evas_object_top_at_xy_get +evas_object_top_get +evas_object_top_in_rectangle_get +evas_object_vg_add +evas_object_vg_root_node_get +evas_out_add +evas_output_del +evas_output_view_get +evas_shutdown +evas_smart_callback_description_find +evas_smart_callbacks_descriptions_get +evas_smart_class_get +evas_smart_class_inherit_full +evas_smart_class_new +evas_smart_data_get +evas_smart_free +evas_smart_legacy_type_register +evas_smart_usage_get +evas_sync +evas_textblock_cursor_format_item_geometry_get +evas_textblock_cursor_range_simple_geometry_get +evas_touch_point_list_count +evas_touch_point_list_nth_id_get +evas_touch_point_list_nth_state_get +evas_touch_point_list_nth_xy_get +evas_tree_objects_at_xy_get +evas_vg_container_add +evas_vg_gradient_linear_end_get +evas_vg_gradient_linear_end_set +evas_vg_gradient_linear_start_get +evas_vg_gradient_linear_start_set +evas_vg_gradient_radial_center_get +evas_vg_gradient_radial_center_set +evas_vg_gradient_radial_focal_get +evas_vg_gradient_radial_focal_set +evas_vg_gradient_radial_radius_get +evas_vg_gradient_radial_radius_set +evas_vg_gradient_spread_get +evas_vg_gradient_spread_set +evas_vg_gradient_stop_get +evas_vg_gradient_stop_set +evas_vg_node_color_get +evas_vg_node_color_set +evas_vg_node_interpolate +evas_vg_node_origin_get +evas_vg_node_origin_set +evas_vg_node_transformation_get +evas_vg_node_transformation_set +evas_vg_node_visible_get +evas_vg_node_visible_set +evas_vg_shape_add +evas_vg_shape_fill_get +evas_vg_shape_fill_set +evas_vg_shape_stroke_cap_get +evas_vg_shape_stroke_cap_set +evas_vg_shape_stroke_color_get +evas_vg_shape_stroke_color_set +evas_vg_shape_stroke_fill_get +evas_vg_shape_stroke_fill_set +evas_vg_shape_stroke_join_get +evas_vg_shape_stroke_join_set +evas_vg_shape_stroke_width_get +evas_vg_shape_stroke_width_set +evas_version +evas_changed_get +ecore_buffer_pixmap_get +ECORE_EVENT_AXIS_UPDATE +ECORE_EVENT_KEY_DOWN +ECORE_EVENT_KEY_UP +ECORE_EVENT_MOUSE_BUTTON_CANCEL +ECORE_EVENT_MOUSE_BUTTON_DOWN +ECORE_EVENT_MOUSE_BUTTON_UP +ECORE_EVENT_MOUSE_IN +ECORE_EVENT_MOUSE_MOVE +ECORE_EVENT_MOUSE_OUT +ECORE_EVENT_MOUSE_WHEEL +ECORE_IMF_EVENT_COMMIT +ECORE_IMF_EVENT_DELETE_SURROUNDING +ECORE_IMF_EVENT_PREEDIT_CHANGED +ECORE_IMF_EVENT_PREEDIT_END +ECORE_IMF_EVENT_PREEDIT_START +ECORE_IPC_EVENT_CLIENT_ADD +ECORE_IPC_EVENT_CLIENT_DATA +ECORE_IPC_EVENT_CLIENT_DEL +ECORE_IPC_EVENT_SERVER_ADD +ECORE_IPC_EVENT_SERVER_DATA +ECORE_IPC_EVENT_SERVER_DEL +ecore_version +EDJE_EDIT_ERROR_GROUP_CURRENTLY_USED +EDJE_EDIT_ERROR_GROUP_DOES_NOT_EXIST +EDJE_EDIT_ERROR_GROUP_REFERENCED +edje_version +edje_object_color_class_clear +edje_size_class_set +edje_size_class_get +edje_size_class_del +edje_size_class_list +edje_size_class_active_iterator_new +edje_mmap_size_class_iterator_new +edje_object_size_class_set +edje_object_size_class_get +edje_object_size_class_del +eina_array_grow +eina_cpu_features +EINA_ERROR_CONVERT_0X_NOT_FOUND +EINA_ERROR_CONVERT_OUTRUN_STRING_LENGTH +EINA_ERROR_CONVERT_P_NOT_FOUND +EINA_ERROR_MAGIC_FAILED +EINA_ERROR_MODULE_INIT_FAILED +EINA_ERROR_NOT_MAIN_LOOP +EINA_ERROR_NOT_MEMPOOL_MODULE +EINA_ERROR_OUT_OF_MEMORY +EINA_ERROR_SAFETY_FAILED +EINA_ERROR_VALUE_FAILED +EINA_ERROR_WRONG_MODULE +eina_log_color_disable_get +EINA_LOG_DOMAIN_GLOBAL +eina_log_domain_registered_level_get +eina_log_level_get +eina_log_print +eina_prime_table +eina_seed +EINA_UNICODE_EMPTY_STRING +EINA_VALUE_BLOB_OPERATIONS_MALLOC +EINA_VALUE_STRUCT_OPERATIONS_BINSEARCH +EINA_VALUE_STRUCT_OPERATIONS_STRINGSHARE +EINA_VALUE_TYPE_ARRAY +EINA_VALUE_TYPE_BLOB +EINA_VALUE_TYPE_CHAR +EINA_VALUE_TYPE_DOUBLE +EINA_VALUE_TYPE_FLOAT +EINA_VALUE_TYPE_HASH +EINA_VALUE_TYPE_INT +EINA_VALUE_TYPE_INT64 +EINA_VALUE_TYPE_LIST +EINA_VALUE_TYPE_LONG +EINA_VALUE_TYPE_SHORT +EINA_VALUE_TYPE_STRING +EINA_VALUE_TYPE_STRINGSHARE +EINA_VALUE_TYPE_STRUCT +EINA_VALUE_TYPE_TIMESTAMP +EINA_VALUE_TYPE_TIMEVAL +EINA_VALUE_TYPE_UCHAR +EINA_VALUE_TYPE_UINT +EINA_VALUE_TYPE_UINT64 +EINA_VALUE_TYPE_ULONG +EINA_VALUE_TYPE_USHORT +eina_version +ELM_CTXPOPUP_SMART_NAME +ELM_ECORE_EVENT_ETHUMB_CONNECT +ELM_EVENT_CONFIG_ALL_CHANGED +ELM_EVENT_POLICY_CHANGED +ELM_EVENT_PROCESS_BACKGROUND +ELM_EVENT_PROCESS_FOREGROUND +ELM_EVENT_SYS_NOTIFY_ACTION_INVOKED +ELM_EVENT_SYS_NOTIFY_NOTIFICATION_CLOSED +ELM_EVENT_SYSTRAY_READY +ELM_FILESELECTOR_ENTRY_SMART_NAME +ELM_GENGRID_PAN_SMART_NAME +ELM_GENGRID_SMART_NAME +elm_panel_scrollable_content_size_set +elm_version +elm_color_class_color_set +elm_color_class_color_get +elm_color_class_color2_set +elm_color_class_color2_get +elm_color_class_color3_set +elm_color_class_color3_get +elm_object_color_class_color_set +elm_object_color_class_color_get +elm_object_color_class_color2_set +elm_object_color_class_color2_get +elm_object_color_class_color3_set +elm_object_color_class_color3_get +elm_object_item_color_class_color_set +elm_object_item_color_class_color_get +elm_object_item_color_class_color2_set +elm_object_item_color_class_color2_get +elm_object_item_color_class_color3_set +elm_object_item_color_class_color3_get +elm_color_class_del +elm_object_color_class_del +elm_object_item_color_class_del +elm_object_color_class_clear +elm_object_item_color_class_clear +dnssd_initialize +dnssd_deinitialize +dnssd_create_local_service +dnssd_destroy_local_service +dnssd_service_set_name +dnssd_service_set_port +dnssd_service_add_txt_record +dnssd_service_remove_txt_record +dnssd_service_set_record +dnssd_service_unset_record +dnssd_register_local_service +dnssd_deregister_local_service +dnssd_start_browsing_service +dnssd_stop_browsing_service +dnssd_service_get_type +dnssd_service_get_name +dnssd_service_get_ip +dnssd_service_get_port +dnssd_service_get_all_txt_record +ssdp_initialize +ssdp_deinitialize +ssdp_create_local_service +ssdp_destroy_local_service +ssdp_service_set_usn +ssdp_service_set_url +ssdp_service_get_target +ssdp_service_get_usn +ssdp_service_get_url +ssdp_register_local_service +ssdp_deregister_local_service +ssdp_start_browsing_service +ssdp_stop_browsing_service +mtp_initialize +mtp_get_devices +mtp_get_storages +mtp_get_object_handles +mtp_get_object +mtp_get_thumbnail +mtp_add_mtp_event_cb +mtp_remove_mtp_event_cb +mtp_deinitialize +mtp_deviceinfo_get_manufacturer_name +mtp_deviceinfo_get_model_name +mtp_deviceinfo_get_serial_number +mtp_deviceinfo_get_device_version +mtp_storageinfo_get_description +mtp_storageinfo_get_free_space +mtp_storageinfo_get_max_capacity +mtp_storageinfo_get_storage_type +mtp_storageinfo_get_volume_identifier +mtp_objectinfo_get_file_name +mtp_objectinfo_get_keywords +mtp_objectinfo_get_association_desc +mtp_objectinfo_get_association_type +mtp_objectinfo_get_size +mtp_objectinfo_get_parent_object_handle +mtp_objectinfo_get_storage +mtp_objectinfo_get_date_created +mtp_objectinfo_get_date_modified +mtp_objectinfo_get_file_type +mtp_objectinfo_get_image_bit_depth +mtp_objectinfo_get_image_pix_width +mtp_objectinfo_get_image_pix_height +mtp_objectinfo_get_thumbnail_size +mtp_objectinfo_get_thumbnail_file_type +mtp_objectinfo_get_thumbnail_pix_height +mtp_objectinfo_get_thumbnail_pix_width +vpnsvc_init +vpnsvc_deinit +vpnsvc_protect +vpnsvc_read +vpnsvc_write +vpnsvc_block_networks +vpnsvc_unblock_networks +vpnsvc_get_iface_fd +vpnsvc_get_iface_index +vpnsvc_get_iface_name +vpnsvc_set_mtu +vpnsvc_set_blocking +vpnsvc_set_session +vpnsvc_get_session +vpnsvc_set_local_ip_address +vpnsvc_set_remote_ip_address +vpnsvc_update_settings +vpnsvc_add_route +vpnsvc_remove_route +vpnsvc_add_dns_server +vpnsvc_remove_dns_server +http_init +http_deinit +http_session_create +http_session_destroy +http_session_set_auto_redirection +http_session_get_auto_redirection +http_session_get_active_transaction_count +http_session_get_max_transaction_count +http_session_open_transaction +http_session_destroy_all_transactions +http_transaction_submit +http_transaction_destroy +http_transaction_set_received_header_cb +http_transaction_set_received_body_cb +http_transaction_set_uploaded_cb +http_transaction_set_completed_cb +http_transaction_set_progress_cb +http_transaction_set_aborted_cb +http_transaction_set_timeout +http_transaction_get_timeout +http_transaction_resume +http_transaction_pause +http_transaction_cancel +http_transaction_set_ready_to_write +http_transaction_set_interface_name +http_transaction_get_interface_name +http_transaction_set_server_certificate_verification +http_transaction_get_server_certificate_verification +http_transaction_header_add_field +http_transaction_header_remove_field +http_transaction_header_get_field_value +http_transaction_request_set_method +http_transaction_request_get_method +http_transaction_request_set_version +http_transaction_request_get_version +http_transaction_request_set_uri +http_transaction_request_get_uri +http_transaction_request_set_accept_encoding +http_transaction_request_get_accept_encoding +http_transaction_request_set_cookie +http_transaction_request_get_cookie +http_transaction_request_write_body +http_transaction_request_set_upload_file +http_transaction_response_get_status_code +http_transaction_response_get_status_text +http_transaction_response_get_version +http_transaction_open_authentication +http_transaction_set_credentials +http_transaction_get_credentials +http_transaction_set_http_auth_scheme +http_transaction_get_http_auth_scheme +http_transaction_get_realm +dpm_manager_create +dpm_manager_destroy +dpm_add_policy_changed_cb +dpm_remove_policy_changed_cb +dpm_add_signal_cb +dpm_remove_signal_cb +dpm_password_set_quality +dpm_password_set_minimum_length +dpm_password_set_min_complex_chars +dpm_password_set_maximum_failed_attempts_for_wipe +dpm_password_set_expires +dpm_password_set_history +dpm_password_set_pattern +dpm_password_reset +dpm_password_enforce_change +dpm_password_set_max_inactivity_time_device_lock +dpm_password_set_status +dpm_password_delete_pattern +dpm_password_set_maximum_character_occurrences +dpm_password_set_maximum_numeric_sequence_length +dpm_password_create_iterator +dpm_password_destroy_iterator +dpm_password_set_forbidden_strings +dpm_password_get_quality +dpm_password_get_minimum_length +dpm_password_get_min_complex_chars +dpm_password_get_maximum_failed_attempts_for_wipe +dpm_password_get_expires +dpm_password_get_history +dpm_password_get_max_inactivity_time_device_lock +dpm_password_get_pattern +dpm_password_get_maximum_character_occurrences +dpm_password_get_maximum_numeric_sequence_length +dpm_password_get_status +dpm_password_iterator_next +dpm_restriction_set_camera_state +dpm_restriction_set_microphone_state +dpm_restriction_set_location_state +dpm_restriction_set_external_storage_state +dpm_restriction_set_clipboard_state +dpm_restriction_set_usb_debugging_state +dpm_restriction_set_wifi_state +dpm_restriction_set_wifi_hotspot_state +dpm_restriction_set_bluetooth_tethering_state +dpm_restriction_set_bluetooth_mode_change_state +dpm_restriction_set_bluetooth_desktop_connectivity_state +dpm_restriction_set_bluetooth_pairing_state +dpm_restriction_set_usb_tethering_state +dpm_restriction_set_messaging_state +dpm_restriction_set_popimap_email_state +dpm_restriction_set_browser_state +dpm_restriction_get_camera_state +dpm_restriction_get_microphone_state +dpm_restriction_get_location_state +dpm_restriction_get_external_storage_state +dpm_restriction_get_clipboard_state +dpm_restriction_get_usb_debugging_state +dpm_restriction_get_wifi_state +dpm_restriction_get_wifi_hotspot_state +dpm_restriction_get_bluetooth_tethering_state +dpm_restriction_get_usb_tethering_state +dpm_restriction_get_bluetooth_mode_change_state +dpm_restriction_get_bluetooth_desktop_connectivity_state +dpm_restriction_get_bluetooth_pairing_state +dpm_restriction_get_messaging_state +dpm_restriction_get_popimap_email_state +dpm_restriction_get_browser_state +dpm_security_lockout_screen +dpm_security_set_internal_storage_encryption +dpm_security_set_external_storage_encryption +dpm_security_wipe_data +dpm_security_is_internal_storage_encrypted +dpm_security_is_external_storage_encrypted +dpm_zone_create +dpm_zone_destroy +dpm_zone_get_state +dpm_zone_foreach_name +yaca_initialize +yaca_cleanup +yaca_malloc +yaca_zalloc +yaca_realloc +yaca_free +yaca_randomize_bytes +yaca_context_set_property +yaca_context_get_property +yaca_context_destroy +yaca_context_get_output_length +yaca_memcmp +yaca_encrypt_initialize +yaca_encrypt_update +yaca_encrypt_finalize +yaca_decrypt_initialize +yaca_decrypt_update +yaca_decrypt_finalize +yaca_encrypt_get_iv_bit_length +yaca_key_get_type +yaca_key_get_bit_length +yaca_key_import +yaca_key_export +yaca_key_generate +yaca_key_generate_from_parameters +yaca_key_extract_parameters +yaca_key_extract_public +yaca_key_destroy +yaca_key_derive_dh +yaca_key_derive_kdf +yaca_key_derive_pbkdf2 +yaca_sign_initialize +yaca_sign_initialize_hmac +yaca_sign_initialize_cmac +yaca_sign_update +yaca_sign_finalize +yaca_verify_initialize +yaca_verify_update +yaca_verify_finalize +yaca_digest_initialize +yaca_digest_update +yaca_digest_finalize +yaca_seal_initialize +yaca_seal_update +yaca_seal_finalize +yaca_open_initialize +yaca_open_update +yaca_open_finalize +yaca_rsa_public_encrypt +yaca_rsa_private_decrypt +yaca_rsa_private_encrypt +yaca_rsa_public_decrypt +yaca_simple_calculate_digest +yaca_simple_encrypt +yaca_simple_decrypt +yaca_simple_calculate_signature +yaca_simple_verify_signature +yaca_simple_calculate_hmac +yaca_simple_calculate_cmac +usb_host_create +usb_host_destroy +usb_host_get_device_list +usb_host_free_device_list +usb_host_ref_device +usb_host_unref_device +usb_host_device_open +usb_host_device_close +usb_host_device_open_with_vid_pid +usb_host_device_get_bus_number +usb_host_device_get_address +usb_host_device_get_port_numbers +usb_host_device_get_config +usb_host_get_active_config +usb_host_set_config +usb_host_device_get_bcd_usb +usb_host_device_get_class +usb_host_device_get_sub_class +usb_host_device_get_protocol +usb_host_device_get_max_packet_size_0 +usb_host_device_get_id_vendor +usb_host_device_get_id_product +usb_host_device_get_bcd_device +usb_host_device_get_num_configurations +usb_host_is_device_opened +usb_host_device_get_manufacturer_str +usb_host_device_get_product_str +usb_host_device_get_serial_number_str +usb_host_config_get_num_interfaces +usb_host_config_is_self_powered +usb_host_config_support_remote_wakeup +usb_host_config_get_max_power +usb_host_device_get_config_str +usb_host_config_get_interface +usb_host_config_destroy +usb_host_claim_interface +usb_host_release_interface +usb_host_interface_get_number +usb_host_interface_get_num_endpoints +usb_host_interface_get_endpoint +usb_host_interface_set_altsetting +usb_host_interface_get_str +usb_host_endpoint_get_number +usb_host_endpoint_get_direction +usb_host_endpoint_get_transfer_type +usb_host_endpoint_get_synch_type +usb_host_endpoint_get_usage_type +usb_host_endpoint_get_max_packet_size +usb_host_endpoint_get_interval +usb_host_control_transfer +usb_host_transfer +usb_host_set_hotplug_cb +usb_host_unset_hotplug_cb +usb_host_device_unconfigure +usb_host_interface_get_altsetting +tzsh_create +tzsh_destroy +tzsh_quickpanel_create +tzsh_quickpanel_destroy +tzsh_quickpanel_show +tzsh_quickpanel_hide +tzsh_quickpanel_visible_get +tzsh_quickpanel_scrollable_set +tzsh_quickpanel_scrollable_get +tzsh_quickpanel_orientation_get +tzsh_quickpanel_event_handler_add +tzsh_quickpanel_event_handler_del +tzsh_quickpanel_event_visible_get +tzsh_quickpanel_event_orientation_get +ui_application_init +ui_application_run +ui_application_term +ui_menu_set_content +ui_menu_get_content +ui_menu_unset_content +ui_menu_activate +ui_menu_deactivate +ui_menu_get_activated +ui_menu_get_base +ui_menu_get_degree +ui_menu_get_view +ui_popup_create +ui_popup_destroy +ui_popup_set_content +ui_popup_get_content +ui_popup_unset_content +ui_popup_activate +ui_popup_deactivate +ui_popup_get_activated +ui_popup_get_base +ui_popup_get_degree +ui_popup_get_view +ui_standard_view_create +ui_standard_view_set_title +ui_standard_view_set_sub_title +ui_standard_view_set_title_badge +ui_standard_view_set_title_right_btn +ui_standard_view_get_title_right_btn +ui_standard_view_unset_title_right_btn +ui_standard_view_set_title_left_btn +ui_standard_view_get_title_left_btn +ui_standard_view_unset_title_left_btn +ui_standard_view_set_toolbar +ui_standard_view_get_toolbar +ui_standard_view_unset_toolbar +ui_standard_view_set_title_visible +ui_view_create +ui_view_set_content +ui_view_get_content +ui_view_unset_content +ui_view_set_event_cb +ui_view_get_base +ui_view_set_indicator +ui_view_get_indicator +ui_view_set_available_rotations +ui_view_get_available_rotations +ui_view_set_removable_content +ui_view_get_removable_content +ui_view_get_degree +ui_view_get_orientation_mode +ui_view_set_transition_style +ui_view_get_transition_style +ui_view_get_menu +ui_view_get_name +ui_view_get_state +ui_view_destroy +ui_viewmgr_push_view +ui_viewmgr_insert_view_before +ui_viewmgr_insert_view_after +ui_viewmgr_pop_view +ui_viewmgr_activate +ui_viewmgr_deactivate +ui_viewmgr_get_window +ui_viewmgr_get_last_view +ui_viewmgr_get_view_by_idx +ui_viewmgr_get_view_by_name +ui_viewmgr_get_base +ui_viewmgr_get_view_index +ui_viewmgr_get_view_count +cbhm_open_service +cbhm_close_service +cbhm_show +cbhm_hide +cbhm_selection_type_set +cbhm_selection_type_get +cbhm_item_selected_callback_add +cbhm_selection_set +cbhm_selection_get +cbhm_item_count_get +cbhm_item_changed_callback_add +cbhm_item_changed_callback_remove +cbhm_latest_item_type_get +cbhm_item_selected_callback_remove +cbhm_monitor_callback_add +cbhm_monitor_callback_remove +SDL_Vulkan_GetInstanceExtensions +SDL_Vulkan_CreateSurface +SDL_tizen_app_init +Dali::WidgetView::WidgetViewManager::New(Dali::Application, std::basic_string, std::allocator > const&) +Dali::WidgetView::WidgetViewManager::DownCast(Dali::BaseHandle) +Dali::WidgetView::WidgetViewManager::AddWidget(std::basic_string, std::allocator > const&, std::basic_string, std::allocator > const&, int, int, float) +Dali::WidgetView::WidgetViewManager::operator=(Dali::WidgetView::WidgetViewManager const&) +Dali::WidgetView::WidgetViewManager::WidgetViewManager(Dali::WidgetView::WidgetViewManager const&) +Dali::WidgetView::WidgetViewManager::WidgetViewManager() +Dali::WidgetView::WidgetViewManager::~WidgetViewManager() +Dali::WidgetView::WidgetView::PauseWidget() +Dali::WidgetView::WidgetView::ResumeWidget() +Dali::WidgetView::WidgetView::CancelTouchEvent() +Dali::WidgetView::WidgetView::WidgetAddedSignal() +Dali::WidgetView::WidgetView::WidgetDeletedSignal() +Dali::WidgetView::WidgetView::WidgetFaultedSignal() +Dali::WidgetView::WidgetView::ActivateFaultedWidget() +Dali::WidgetView::WidgetView::WidgetContentUpdatedSignal() +Dali::WidgetView::WidgetView::WidgetCreationAbortedSignal() +Dali::WidgetView::WidgetView::WidgetUpdatePeriodChangedSignal() +Dali::WidgetView::WidgetView::New(std::basic_string, std::allocator > const&, std::basic_string, std::allocator > const&, int, int, float) +Dali::WidgetView::WidgetView::DownCast(Dali::BaseHandle) +Dali::WidgetView::WidgetView::operator=(Dali::WidgetView::WidgetView const&) +Dali::WidgetView::WidgetView::WidgetView(Dali::WidgetView::WidgetView const&) +Dali::WidgetView::WidgetView::WidgetView() +Dali::WidgetView::WidgetView::~WidgetView() +Dali::WidgetView::WidgetView::TerminateWidget() +alcOpenDeviceNew +asp_initialize +asp_deinitialize +asp_seek_set_search_result_cb +asp_seek_unset_search_result_cb +asp_advert_set_status_changed_cb +asp_advert_unset_status_changed_cb +asp_session_set_request_cb +asp_session_unset_request_cb +asp_session_set_config_request_cb +asp_session_unset_config_request_cb +asp_session_set_connect_status_cb +asp_session_unset_connect_status_cb +asp_session_set_status_cb +asp_session_unset_status_cb +asp_session_set_port_status_cb +asp_session_unset_port_status_cb +asp_advert_create +asp_advert_destroy +asp_advert_set_service_type +asp_advert_set_auto_accept +asp_advert_add_info +asp_advert_get_info +asp_advert_remove_info +asp_advert_set_status +asp_advert_set_discovery_tech +asp_advert_set_preferred_connection +asp_advert_set_p2p_role_scheme +asp_advert_get_p2p_role_scheme +asp_advert_set_p2p_config_method +asp_advert_get_p2p_config_method +asp_advert_set_p2p_response +asp_advert_start_advertising +asp_advert_stop_advertising +asp_advert_change_service_status +asp_seek_create +asp_seek_destroy +asp_seek_add_info +asp_seek_remove_info +asp_seek_set_discovery_tech +asp_seek_set_preferred_connection +asp_seek_start +asp_seek_stop +asp_session_create +asp_session_destroy +asp_session_get_mac +asp_session_get_id +asp_session_set_info +asp_session_get_info +asp_session_set_p2p_role_scheme +asp_session_get_p2p_role_scheme +asp_session_set_p2p_config_method +asp_session_get_p2p_config_method +asp_session_get_close_status +asp_session_connect +asp_session_confirm +asp_session_get_handle +asp_session_set_state_ready +asp_session_close +asp_session_bind_port +asp_session_release_port +stc_initialize +stc_deinitialize +stc_get_stats +stc_foreach_stats +stc_get_total_stats +stc_stats_rule_create +stc_stats_rule_destroy +stc_stats_rule_set_app_id +stc_stats_rule_set_time_interval +stc_stats_rule_set_iface_type +stc_stats_rule_set_time_period +stc_stats_rule_get_app_id +stc_stats_rule_get_time_interval +stc_stats_rule_get_iface_type +stc_stats_rule_get_time_period +stc_stats_info_get_app_id +stc_stats_info_get_iface_name +stc_stats_info_get_time_interval +stc_stats_info_get_iface_type +stc_stats_info_get_counter +stc_stats_info_get_roaming_type +stc_stats_info_get_protocol_type +stc_stats_info_get_process_state +ppm_check_permission +ppm_request_permission +sound_pool_create +sound_pool_destroy +sound_pool_load_source_from_file +sound_pool_unload_source +sound_pool_activate +sound_pool_deactivate +sound_pool_set_volume +sound_pool_get_volume +sound_pool_get_state +sound_pool_set_state_changed_cb +sound_pool_unset_state_changed_cb +sound_pool_stream_play +sound_pool_stream_pause +sound_pool_stream_resume +sound_pool_stream_stop +sound_pool_stream_set_volume +sound_pool_stream_get_volume +sound_pool_stream_set_priority +sound_pool_stream_get_priority +sound_pool_stream_get_state +job_info_create +job_info_destroy +job_info_set_periodic +job_info_set_persistent +job_info_set_once +job_info_set_requirement_timeout +job_info_set_requires_battery_not_low +job_info_set_requires_charging +job_info_set_requires_wifi_connection +job_info_add_trigger_event +job_info_remove_trigger_event +job_info_get_job_id +job_info_clone +job_scheduler_init +job_scheduler_finish +job_scheduler_schedule +job_scheduler_cancel +job_scheduler_cancel_all +job_scheduler_job_finished +job_scheduler_foreach_job +job_scheduler_service_add +job_scheduler_service_remove +rpc_port_read +rpc_port_write +rpc_port_proxy_create +rpc_port_proxy_destroy +rpc_port_proxy_connect +rpc_port_proxy_add_connected_event_cb +rpc_port_proxy_add_disconnected_event_cb +rpc_port_proxy_add_rejected_event_cb +rpc_port_proxy_add_received_event_cb +rpc_port_stub_create +rpc_port_stub_destroy +rpc_port_stub_listen +rpc_port_stub_add_privilege +rpc_port_stub_set_trusted +rpc_port_stub_add_connected_event_cb +rpc_port_stub_add_disconnected_event_cb +rpc_port_stub_add_received_event_cb +rpc_port_parcel_create +rpc_port_parcel_create_from_port +rpc_port_parcel_send +rpc_port_parcel_destroy +rpc_port_parcel_write_byte +rpc_port_parcel_write_int16 +rpc_port_parcel_write_int32 +rpc_port_parcel_write_int64 +rpc_port_parcel_write_float +rpc_port_parcel_write_double +rpc_port_parcel_write_string +rpc_port_parcel_write_bool +rpc_port_parcel_write_bundle +rpc_port_parcel_write_array_count +rpc_port_parcel_write +rpc_port_parcel_read_byte +rpc_port_parcel_read_int16 +rpc_port_parcel_read_int32 +rpc_port_parcel_read_int64 +rpc_port_parcel_read_float +rpc_port_parcel_read_double +rpc_port_parcel_read_string +rpc_port_parcel_read_bool +rpc_port_parcel_read_bundle +rpc_port_parcel_read_array_count +rpc_port_parcel_read +rpc_port_parcel_burst_read +rpc_port_parcel_burst_write +rpc_port_proxy_get_port +rpc_port_stub_get_port diff --git a/configs/4.0/wearable/entrypoints.h b/configs/4.0/wearable/entrypoints.h new file mode 100644 index 0000000..e55371f --- /dev/null +++ b/configs/4.0/wearable/entrypoints.h @@ -0,0 +1,157 @@ +#define __GLIBC_USE + +// Account +#include +#include +#include +#include +#include +#include +#include + +// Application Framework +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +// Content +#include +#include + +// Context +#include +#include +#include + +// Location +#include +#include + +// Messaging +#include +#include +#include + +// Multimedia +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +// Network +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +// Security +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +// Social +#include +#include +#include + +// System +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +// Telephony +#include + +// UIX +#include +#include +#include +#include +#include +#include +#include + + diff --git a/configs/4.0/wearable/ffigen.yaml b/configs/4.0/wearable/ffigen.yaml new file mode 100644 index 0000000..3e9744f --- /dev/null +++ b/configs/4.0/wearable/ffigen.yaml @@ -0,0 +1,110 @@ +name: 'Tizen40Wearable' +output: 'lib/src/bindings/4.0/wearable/generated_bindings.dart' +llvm-path: + - '/usr/lib/llvm-12' +headers: + entry-points: + - 'configs/4.0/wearable/entrypoints.h' + include-directives: + - '**/tizen*.h' + - '**/account*.h' + - '**/fido*.h' + - '**/oauth2*.h' + - '**/sync*.h' + - '**/appfw/*.h' + - '**/badge/*.h' + - '**/appcore-agent/*.h' + - '**/appcore-watch/*.h' + - '**/widget-service/*.h' + - '**/widget_viewer_evas/*.h' + - '**/content/*.h' + - '**/media-content/*.h' + - '**/context-service/*.h' + - '**/location/*.h' + - '**/maps/*.h' + - '**/messaging/*.h' + - '**/push-service.h' + - '**/media/*.h' + - '**/metadata-editor/*.h' + - '**/asp/*.h' + - '**/network/*.h' + - '**/nsd/*.h' + - '**/iotcon/*.h' + - '**/smartcard.h' + - '**/csr/*.h' + - '**/dpm/*.h' + - '**/ckmc/*.h' + - '**/privacy-privilege-manager/*.h' + - '**/privilege_information.h' + - '**/yaca/*.h' + - '**/calendar-service2/*.h' + - '**/contacts-svc/*.h' + - '**/phonenumber-utils/*.h' + - '**/device/*.h' + - '**/dlog/*.h' + - '**/feedback/*.h' + - '**/system/*.h' + - '**/sensor/*.h' + - '**/storage/*.h' + - '**/trace.h' + - '**/telephony/*.h' + - '**/inputmethod*.h' + - '**/stt*.h' + - '**/tts*.h' + - '**/voice_control*.h' + +compiler-opts: + - '-m32' + - '-Wno-incomplete-setjmp-declaration' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/appfw/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/notification/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/badge/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/appcore-agent/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/appcore-watch/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/widget_service/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/widget_viewer_evas/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/content/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/media-content/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/context-service/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/location/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/maps/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/messaging/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/media/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/metadata-editor/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/asp/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/network/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/nsd/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/iotcon/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/csr/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/ckm/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/privacy-privilege-manager/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/yaca/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/calendar-service2/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/contacts-svc/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/phonenumber-utils/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/dlog/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/feedback/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/system/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/sensor/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/storage/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/telephony/' + +# include efl directories + - '-I./rootstraps/wearable-4.0-device.core/usr/include/evas-1/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/efl-1/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/eo-1/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/eina-1/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/eina-1/eina/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/emile-1/' + - '-I./rootstraps/wearable-4.0-device.core/usr/include/ecore-imf-1/' + +dart-bool: true + +typedef-map: + 'size_t': 'Int32' + +preamble: | + // Copyright 2021 Samsung Electronics Co., Ltd. All rights reserved. + // Use of this source code is governed by a BSD-style license that can be + // found in the LICENSE file. diff --git a/configs/4.0/wearable/symgen.yaml b/configs/4.0/wearable/symgen.yaml new file mode 100644 index 0000000..7b0ce10 --- /dev/null +++ b/configs/4.0/wearable/symgen.yaml @@ -0,0 +1,104 @@ +# Tizen 4.0 Wearable Native Libraries + +preamble: | + // Copyright 2021 Samsung Electronics Co., Ltd. All rights reserved. + // Use of this source code is governed by a BSD-style license that can be + // found in the LICENSE file. + +name: tizen40Symbols +output: 'lib/src/bindings/4.0/wearable/generated_symbols.dart' +library-path: 'rootstraps/wearable-4.0-device.core/usr/lib' +allowlist: 'configs/4.0/wearable/allowlist.txt' +target-libraries: + - libaccounts-svc.so.0 # Account / Account Manager + - libfido-client.so.0 # Account / FIDO Client + - liboauth2.so.0 # Account / OAuth 2.0 + - libcore-sync-client.so.1.0 # Account / Sync Manager + - libcapi-appfw-application.so.0 # Applicatoin Framework / Application (include i18n) + - libcapi-appfw-alarm.so.0 # Application Framework / Application / Alarm + - libcapi-appfw-app-common.so.0 # Application Framework / Application / App Common, Resource Manager + - libcapi-appfw-app-control.so.0 # Application Framework / Application / App Control + - libcapi-appfw-event.so.0 # Application Framework / Application / Event + - libcapi-appfw-job-scheduler.so.0 # Application Framework / Application / Job scheduler + - libcapi-appfw-preference.so.0 # Application Framework / Application / Preference + - libcapi-appfw-app-manager.so.0 # Application Framework / Application Manager + - libbadge.so.0 # Application Framework / Badge + - libbundle.so.0 # Application Framework / Bundle + - libdata-control.so.0 # Application Framework / Data Control + - libmessage-port.so.1 # Application Framework / Message Port + - libnotification.so.0 # Application Framework / Notification + - libcapi-appfw-package-manager.so.0 # Application Framework / Package Manager + - libappcore-agent.so.1 # Application Framework / Service Application + - libappcore-watch.so.1 # Application Framework / Watch Application + - libcapi-appfw-widget-application.so.1 # Application Framework / Widget / Widget Application + - libwidget_service.so.1 # Application Framework / Widget / Widget Service + - libwidget_viewer_evas.so.1 # Application Framework / Widget / Widget Viewer + - libcapi-base-common.so.0 # Base / Common Error + - libcapi-content-mime-type.so.0 # Content / Mime Type + - libcapi-content-media-content.so.0 # Content / Media Content + - libcapi-context-motion.so.2 # Context / Activity Recognition, Gesture Recognition + - libcapi-context.so.1 # Context / Contextual History + - libcapi-location-manager.so.0 # Location / Location Manager + - libcapi-maps-service.so.0 # Location / Maps Service + - libcapi-messaging-email.so.0 # Messaging / Email + - libcapi-messaging-messages.so.0 # Messaging / Messages + - libpush.so.0 # Messaging / Push + - libcapi-media-audio-io.so.0 # Multimedia / Audio I/O + - libcapi-media-camera.so.0 # Multimedia / Camera + - libcapi-media-image-util.so.0 # Multimedia / Image Util + - libcapi-media-codec.so.0 # Multimedia / Media Codec + - libcapi-media-controller.so.0 # Multimedia / Media Controller + - libcapi-mediademuxer.so.0 # Multimedia / Media Demuxer + - libcapi-mediamuxer.so.0 # Multimedia / Media Muxer + - libcapi-media-streamer.so.0 # Multimedia / Media Streamer + - libcapi-media-tool.so.0 # Multimedia / Media Tool + - libcapi-media-vision.so.0 # Multimedia / Media Vision + - libcapi-media-metadata-editor.so # Multimedia / Metadata Editor + - libcapi-media-metadata-extractor.so # Multimedia / Metadata Extractor + - libcapi-media-player.so.0 # Multimedia / Player + - libcapi-media-radio.so.0 # Multimedia / Radio + - libcapi-media-recorder.so.0 # Multimedia / Recorder + - libcapi-media-sound-manager.so.0 # Multimedia / Sound Manager + - libcapi-media-sound-pool.so.0 # Multimedia / Sound Pool + - libcapi-media-streamrecorder.so.0 # Multimedia / StreamRecorder + - libcapi-media-thumbnail-util.so # Multimedia / Thumbnail Util + - libcapi-media-tone-player.so.0 # Multimedia / Tone Player + - libcapi-media-wav-player.so.0 # Multimedia / WAV Player + - libasp.so.0 # Network / Application Service Platform + - libcapi-network-bluetooth.so.0 # Network / Bluetooth + - libcapi-network-connection.so.1 # Network / Connection + - libnsd-dns-sd.so.0 # Network / DNSSD + - libcapi-network-http.so.0.1.0 # Network / HTTP + - libiotcon.so.0 # Network / IoTCon + - libcapi-network-nfc.so.0 # Network / NFC + - libnsd-ssdp.so.0 # Network / SSDP + - libcapi-network-stc.so.0 # Network / Smart Traffic Control + - libcapi-network-smartcard.so.0 # Network / Smartcard + - libcapi-network-wifi-manager.so.1 # Network / WI-Fi Manager + - libcsr-client.so.2 # Security / CSR + - libdpm.so.0 # Security / Device Policy Manager + - libkey-manager-client.so.1 # Security / Key Manager Client + - libcapi-privacy-privilege-manager.so.0 # Security / Privacy Privilege Manager + - libprivilege-info.so.1 # Security / Privilege Info + - libyaca.so.0 # Security / YACA + - libcalendar-service2.so.0 # Social / Calendar + - libcontacts-service2.so.0 # Social / Contacts + - libphonenumber-utils.so.0 # Social / Phonenumber utils + - libcapi-system-device.so.0 # System / Device + - libdlog.so.0 # System / Dlog + - libfeedback.so.0 # System / Feedback + - libcapi-system-media-key.so.0 # System / Media key + - libcapi-system-runtime-info.so.0 # System / Runtime information + - libcapi-system-sensor.so.0 # System / Sensor + - libstorage.so.0.1 # System / Storage + - libcapi-system-info.so.0 # System / System Information + - libcapi-system-system-settings.so.0 # System / System Settings + - libttrace.so.1 # System / T-trace + - libcapi-telephony.so.0 # Telephony / Telephony Information + - libcapi-ui-inputmethod.so.0 # UIX / Input Method + - libcapi-ui-inputmethod-manager.so.0 # UIX / Input Method Manager + - libstt.so # UIX / STT + - libstt_engine.so # UIX / STT Engine + - libtts.so # UIX / TTS + - libtts_engine.so # UIX / TTS Engine + - libvc.so # UIX / Voice control diff --git a/lib/4.0/wearable/tizen.dart b/lib/4.0/wearable/tizen.dart new file mode 100644 index 0000000..f2283ba --- /dev/null +++ b/lib/4.0/wearable/tizen.dart @@ -0,0 +1,39 @@ +library tizen_interop; + +import 'dart:ffi'; +import '../../src/bindings/4.0/wearable/generated_bindings.dart'; +import '../../src/bindings/4.0/wearable/generated_symbols.dart'; + +export '../../src/bindings/4.0/wearable/generated_bindings.dart'; +export '../../src/extensions.dart'; + +final _provider = _LookupProvider(); + +Tizen40Wearable? _tizen; +Tizen40Wearable get tizen => + _tizen ??= Tizen40Wearable.fromLookup(_provider.lookup); + +class _LookupProvider { + late Map _libraryIndex = _getSymbolToLibraryIndex(); + Map _libraryCache = Map(); + + Pointer lookup(String symbolName) { + var libraryName = _libraryIndex[symbolName]; + if (libraryName == null) { + throw ArgumentError( + 'Failed to lookup symbol (undefined symbol: $symbolName'); + } + _libraryCache[libraryName] ??= DynamicLibrary.open(libraryName); + return _libraryCache[libraryName]!.lookup(symbolName); + } + + Map _getSymbolToLibraryIndex() { + final ret = Map(); + for (final library in tizen40Symbols.keys) { + for (final symbol in tizen40Symbols[library]!) { + ret[symbol] = library; + } + } + return ret; + } +} diff --git a/lib/src/bindings/4.0/wearable/generated_bindings.dart b/lib/src/bindings/4.0/wearable/generated_bindings.dart new file mode 100644 index 0000000..3bdce33 --- /dev/null +++ b/lib/src/bindings/4.0/wearable/generated_bindings.dart @@ -0,0 +1,210286 @@ +// Copyright 2021 Samsung Electronics Co., Ltd. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// AUTO GENERATED FILE, DO NOT EDIT. +// +// Generated by `package:ffigen`. +import 'dart:ffi' as ffi; + +class Tizen40Wearable { + /// Holds the symbol lookup function. + final ffi.Pointer Function(String symbolName) + _lookup; + + /// The symbols are looked up in [dynamicLibrary]. + Tizen40Wearable(ffi.DynamicLibrary dynamicLibrary) + : _lookup = dynamicLibrary.lookup; + + /// The symbols are looked up with [lookup]. + Tizen40Wearable.fromLookup( + ffi.Pointer Function(String symbolName) + lookup) + : _lookup = lookup; + + /// @brief Gets the last error code in the thread. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @details This function retrieves the last error code which is set by set_last_result() + /// @return One of #tizen_error_e + /// @see #tizen_error_e + /// @see set_last_result() + int get_last_result() { + return _get_last_result(); + } + + late final _get_last_result_ptr = + _lookup>('get_last_result'); + late final _dart_get_last_result _get_last_result = + _get_last_result_ptr.asFunction<_dart_get_last_result>(); + + /// @brief Sets the last error code to be returned in the thread. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] err The error code to be returned + /// @see #tizen_error_e + /// @see get_last_result() + void set_last_result( + int err, + ) { + return _set_last_result( + err, + ); + } + + late final _set_last_result_ptr = + _lookup>('set_last_result'); + late final _dart_set_last_result _set_last_result = + _set_last_result_ptr.asFunction<_dart_set_last_result>(); + + /// @brief Gets the message for given the error code. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remark This function returns a static pointer; subsequent calls will overwrite it. + /// @param[in] err The error value to be returned + /// @return The error's message + /// @see #tizen_error_e + /// + /// @code + /// char* errMsg; + /// location_manager_h location_handle; + /// int result = location_manager_create(LOCATION_METHOD_GPS, &location_handle); + /// + /// if (LOCATIONS_ERROR_NONE != result) { + /// errMsg = get_error_message(result); + /// dlog_print(DLOG_INFO, "MyTag", "%s", errMsg); + /// } + /// @endcode + ffi.Pointer get_error_message( + int err, + ) { + return _get_error_message( + err, + ); + } + + late final _get_error_message_ptr = + _lookup>('get_error_message'); + late final _dart_get_error_message _get_error_message = + _get_error_message_ptr.asFunction<_dart_get_error_message>(); + + /// @deprecated Deprecated since Tizen 2.4.\n + /// This API is not necessary to use since Tizen 2.4. + /// @brief Connects to the account database by readwrite mode. + /// + /// @since_tizen @if MOBILE 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read \n + /// %http://tizen.org/privilege/account.wirte + /// @remarks This API need both privileges + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED DB is not connected + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + int account_connect() { + return _account_connect(); + } + + late final _account_connect_ptr = + _lookup>('account_connect'); + late final _dart_account_connect _account_connect = + _account_connect_ptr.asFunction<_dart_account_connect>(); + + /// @deprecated Deprecated since Tizen 2.4.\n + /// This API is not necessary to use since Tizen 2.4. + /// @brief Connects to the account database by readonly mode. + /// + /// @since_tizen @if MOBILE 2.3 @endif + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED DB is not connected + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + int account_connect_readonly() { + return _account_connect_readonly(); + } + + late final _account_connect_readonly_ptr = + _lookup>( + 'account_connect_readonly'); + late final _dart_account_connect_readonly _account_connect_readonly = + _account_connect_readonly_ptr + .asFunction<_dart_account_connect_readonly>(); + + /// @deprecated Deprecated since Tizen 2.4.\n + /// This API is not necessary to use since Tizen 2.4. + /// @brief Disconnects from the account database. + /// + /// @since_tizen @if MOBILE 2.3 @endif + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite busy handler exprired + int account_disconnect() { + return _account_disconnect(); + } + + late final _account_disconnect_ptr = + _lookup>('account_disconnect'); + late final _dart_account_disconnect _account_disconnect = + _account_disconnect_ptr.asFunction<_dart_account_disconnect>(); + + /// @brief Creates a handle to the account. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks Release @a account using account_destroy(). + /// @remarks The created handle is not added to the account database until account_insert_to_db() is called. + /// + /// @param[in] account The account handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_destroy() + int account_create( + ffi.Pointer> account, + ) { + return _account_create( + account, + ); + } + + late final _account_create_ptr = + _lookup>('account_create'); + late final _dart_account_create _account_create = + _account_create_ptr.asFunction<_dart_account_create>(); + + /// @brief Destroys the account handle and releases all its resources. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_create() + int account_destroy( + ffi.Pointer account, + ) { + return _account_destroy( + account, + ); + } + + late final _account_destroy_ptr = + _lookup>('account_destroy'); + late final _dart_account_destroy _account_destroy = + _account_destroy_ptr.asFunction<_dart_account_destroy>(); + + /// @brief Inserts the account details to the account database. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read \n + /// %http://tizen.org/privilege/account.write + /// @remarks This API need both privileges + /// @param[in] account The account handle + /// @param[out] account_db_id The account ID to be assigned to an account + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_DUPLICATED Same user name exists in your application + /// @retval #ACCOUNT_ERROR_NOT_ALLOW_MULTIPLE Tried to add an account in spite of multiple false accounts + /// @retval #ACCOUNT_ERROR_NOT_REGISTERED_PROVIDER Tried to add an account though you did not register the account type in manifest + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// + /// @see account_delete_from_db_by_id() + /// @see account_delete_from_db_by_user_name() + /// @see account_delete_from_db_by_package_name() + /// @see account_update_to_db_by_id() + /// @see account_update_to_db_by_user_name() + int account_insert_to_db( + ffi.Pointer account, + ffi.Pointer account_db_id, + ) { + return _account_insert_to_db( + account, + account_db_id, + ); + } + + late final _account_insert_to_db_ptr = + _lookup>( + 'account_insert_to_db'); + late final _dart_account_insert_to_db _account_insert_to_db = + _account_insert_to_db_ptr.asFunction<_dart_account_insert_to_db>(); + + /// @brief Deletes an account from the account database by account DB ID. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read \n + /// %http://tizen.org/privilege/account.write + /// @remarks This API need both privileges \n + /// Only can delete an account which was added by same package applications + /// @param[in] account_db_id The account ID to delete + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED The account owner is different from the caller or DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// + /// @see account_insert_to_db() + /// @see account_delete_from_db_by_user_name() + /// @see account_delete_from_db_by_package_name() + /// @see account_update_to_db_by_id() + /// @see account_update_to_db_by_user_name() + int account_delete_from_db_by_id( + int account_db_id, + ) { + return _account_delete_from_db_by_id( + account_db_id, + ); + } + + late final _account_delete_from_db_by_id_ptr = + _lookup>( + 'account_delete_from_db_by_id'); + late final _dart_account_delete_from_db_by_id _account_delete_from_db_by_id = + _account_delete_from_db_by_id_ptr + .asFunction<_dart_account_delete_from_db_by_id>(); + + /// @brief Deletes an account from the account database by user name. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read \n + /// %http://tizen.org/privilege/account.write + /// @remarks This API need both privileges \n + /// Only can delete accounts which were added by same package applications + /// @param[in] user_name The user name of the account to delete + /// @param[in] package_name The package name of the account to delete + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// + /// @see account_insert_to_db() + /// @see account_delete_from_db_by_id() + /// @see account_delete_from_db_by_package_name() + /// @see account_update_to_db_by_id() + /// @see account_update_to_db_by_user_name() + int account_delete_from_db_by_user_name( + ffi.Pointer user_name, + ffi.Pointer package_name, + ) { + return _account_delete_from_db_by_user_name( + user_name, + package_name, + ); + } + + late final _account_delete_from_db_by_user_name_ptr = + _lookup>( + 'account_delete_from_db_by_user_name'); + late final _dart_account_delete_from_db_by_user_name + _account_delete_from_db_by_user_name = + _account_delete_from_db_by_user_name_ptr + .asFunction<_dart_account_delete_from_db_by_user_name>(); + + /// @brief Deletes an account from the account database by package name. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read \n + /// %http://tizen.org/privilege/account.write + /// @remarks This API need both privileges \n + /// Only can delete accounts which was added by same package applications + /// @param[in] package_name The package name of account(s) to delete + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// + /// @see account_insert_to_db() + /// @see account_delete_from_db_by_id() + /// @see account_delete_from_db_by_user_name() + /// @see account_update_to_db_by_id() + /// @see account_update_to_db_by_user_name() + int account_delete_from_db_by_package_name( + ffi.Pointer package_name, + ) { + return _account_delete_from_db_by_package_name( + package_name, + ); + } + + late final _account_delete_from_db_by_package_name_ptr = + _lookup>( + 'account_delete_from_db_by_package_name'); + late final _dart_account_delete_from_db_by_package_name + _account_delete_from_db_by_package_name = + _account_delete_from_db_by_package_name_ptr + .asFunction<_dart_account_delete_from_db_by_package_name>(); + + /// @brief Updates the account details to the account database. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read \n + /// %http://tizen.org/privilege/account.write + /// @remarks This API need both privileges \n + /// Only can update an account which was added by same package applications + /// @param[in] account The account handle + /// @param[in] account_id The account ID to update + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_RECORD_NOT_FOUND The account to update does not exist + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// + /// @see account_insert_to_db() + /// @see account_delete_from_db_by_id() + /// @see account_delete_from_db_by_user_name() + /// @see account_delete_from_db_by_package_name() + /// @see account_update_to_db_by_user_name() + int account_update_to_db_by_id( + ffi.Pointer account, + int account_id, + ) { + return _account_update_to_db_by_id( + account, + account_id, + ); + } + + late final _account_update_to_db_by_id_ptr = + _lookup>( + 'account_update_to_db_by_id'); + late final _dart_account_update_to_db_by_id _account_update_to_db_by_id = + _account_update_to_db_by_id_ptr + .asFunction<_dart_account_update_to_db_by_id>(); + + /// @brief Updates the account details to the account database. + /// The provider permission check has been added since tizen 2.4. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read \n + /// %http://tizen.org/privilege/account.write + /// @remarks This API need both privileges \n + /// Only can update an account which was added by same package applications + /// @param[in] account The account handle + /// @param[in] account_id The account ID to update + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_RECORD_NOT_FOUND The account to update does not exist + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// + /// @see account_insert_to_db() + /// @see account_delete_from_db_by_id() + /// @see account_delete_from_db_by_user_name() + /// @see account_delete_from_db_by_package_name() + /// @see account_update_to_db_by_user_name() + int account_update_to_db_by_id_ex( + ffi.Pointer account, + int account_id, + ) { + return _account_update_to_db_by_id_ex( + account, + account_id, + ); + } + + late final _account_update_to_db_by_id_ex_ptr = + _lookup>( + 'account_update_to_db_by_id_ex'); + late final _dart_account_update_to_db_by_id_ex + _account_update_to_db_by_id_ex = _account_update_to_db_by_id_ex_ptr + .asFunction<_dart_account_update_to_db_by_id_ex>(); + + /// @brief Updates the account details to the account database. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read \n + /// %http://tizen.org/privilege/account.write + /// @remarks This API need both privileges \n + /// Only can update accounts which were added by same package applications + /// @param[in] account The account handle + /// @param[in] user_name The user name of the account to update + /// @param[in] package_name The package name for the user name + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_RECORD_NOT_FOUND The account to update does not exist + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// + /// @see account_insert_to_db() + /// @see account_delete_from_db_by_id() + /// @see account_delete_from_db_by_user_name() + /// @see account_delete_from_db_by_package_name() + /// @see account_update_to_db_by_id() + int account_update_to_db_by_user_name( + ffi.Pointer account, + ffi.Pointer user_name, + ffi.Pointer package_name, + ) { + return _account_update_to_db_by_user_name( + account, + user_name, + package_name, + ); + } + + late final _account_update_to_db_by_user_name_ptr = + _lookup>( + 'account_update_to_db_by_user_name'); + late final _dart_account_update_to_db_by_user_name + _account_update_to_db_by_user_name = + _account_update_to_db_by_user_name_ptr + .asFunction<_dart_account_update_to_db_by_user_name>(); + + /// @brief Gets the ID of an account. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[out] account_id The account ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + int account_get_account_id( + ffi.Pointer account, + ffi.Pointer account_id, + ) { + return _account_get_account_id( + account, + account_id, + ); + } + + late final _account_get_account_id_ptr = + _lookup>( + 'account_get_account_id'); + late final _dart_account_get_account_id _account_get_account_id = + _account_get_account_id_ptr.asFunction<_dart_account_get_account_id>(); + + /// @brief Gets the user name of an account. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a user_name using free(). + /// + /// @param[in] account The account handle + /// @param[out] user_name The user name of the account + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_user_name() + int account_get_user_name( + ffi.Pointer account, + ffi.Pointer> user_name, + ) { + return _account_get_user_name( + account, + user_name, + ); + } + + late final _account_get_user_name_ptr = + _lookup>( + 'account_get_user_name'); + late final _dart_account_get_user_name _account_get_user_name = + _account_get_user_name_ptr.asFunction<_dart_account_get_user_name>(); + + /// @brief Sets the user name of an account. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] user_name The string to set as user name + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_user_name() + int account_set_user_name( + ffi.Pointer account, + ffi.Pointer user_name, + ) { + return _account_set_user_name( + account, + user_name, + ); + } + + late final _account_set_user_name_ptr = + _lookup>( + 'account_set_user_name'); + late final _dart_account_set_user_name _account_set_user_name = + _account_set_user_name_ptr.asFunction<_dart_account_set_user_name>(); + + /// @brief Gets the display name of an account. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a display_name using free(). + /// + /// @param[in] account The account handle + /// @param[out] display_name The display name of the account + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_display_name() + int account_get_display_name( + ffi.Pointer account, + ffi.Pointer> display_name, + ) { + return _account_get_display_name( + account, + display_name, + ); + } + + late final _account_get_display_name_ptr = + _lookup>( + 'account_get_display_name'); + late final _dart_account_get_display_name _account_get_display_name = + _account_get_display_name_ptr + .asFunction<_dart_account_get_display_name>(); + + /// @brief Sets the display name of an account. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] display_name The text string to set as the display name + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_display_name() + int account_set_display_name( + ffi.Pointer account, + ffi.Pointer display_name, + ) { + return _account_set_display_name( + account, + display_name, + ); + } + + late final _account_set_display_name_ptr = + _lookup>( + 'account_set_display_name'); + late final _dart_account_set_display_name _account_set_display_name = + _account_set_display_name_ptr + .asFunction<_dart_account_set_display_name>(); + + /// @brief Gets the capability detail of an account. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] capability_type The capability type to get the capability value + /// @param[out] capability_value The capability value (on/off) of the specified capability_type + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_RECORD_NOT_FOUND There is no given capability_type in the account + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_capability() + int account_get_capability( + ffi.Pointer account, + ffi.Pointer capability_type, + ffi.Pointer capability_value, + ) { + return _account_get_capability( + account, + capability_type, + capability_value, + ); + } + + late final _account_get_capability_ptr = + _lookup>( + 'account_get_capability'); + late final _dart_account_get_capability _account_get_capability = + _account_get_capability_ptr.asFunction<_dart_account_get_capability>(); + + /// @brief Gets all the capabilities of an account. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] callback The callback function + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_capability() + int account_get_capability_all( + ffi.Pointer account, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _account_get_capability_all( + account, + callback, + user_data, + ); + } + + late final _account_get_capability_all_ptr = + _lookup>( + 'account_get_capability_all'); + late final _dart_account_get_capability_all _account_get_capability_all = + _account_get_capability_all_ptr + .asFunction<_dart_account_get_capability_all>(); + + /// @brief Sets the capability. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] capability_type The capability type + /// @param[in] capability_state The capability state + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_capability() + int account_set_capability( + ffi.Pointer account, + ffi.Pointer capability_type, + int capability_state, + ) { + return _account_set_capability( + account, + capability_type, + capability_state, + ); + } + + late final _account_set_capability_ptr = + _lookup>( + 'account_set_capability'); + late final _dart_account_set_capability _account_set_capability = + _account_set_capability_ptr.asFunction<_dart_account_set_capability>(); + + /// @brief Gets the icon path. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a icon_path using free(). + /// + /// @param[in] account The account handle + /// @param[out] icon_path The icon path + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_icon_path() + int account_get_icon_path( + ffi.Pointer account, + ffi.Pointer> icon_path, + ) { + return _account_get_icon_path( + account, + icon_path, + ); + } + + late final _account_get_icon_path_ptr = + _lookup>( + 'account_get_icon_path'); + late final _dart_account_get_icon_path _account_get_icon_path = + _account_get_icon_path_ptr.asFunction<_dart_account_get_icon_path>(); + + /// @brief Sets the icon path. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] icon_path The text string to set as the icon path + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_icon_path() + int account_set_icon_path( + ffi.Pointer account, + ffi.Pointer icon_path, + ) { + return _account_set_icon_path( + account, + icon_path, + ); + } + + late final _account_set_icon_path_ptr = + _lookup>( + 'account_set_icon_path'); + late final _dart_account_set_icon_path _account_set_icon_path = + _account_set_icon_path_ptr.asFunction<_dart_account_set_icon_path>(); + + /// @brief Gets the domain name. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a domain_name using free(). + /// + /// @param[in] account The account handle + /// @param[out] domain_name The domain name + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_domain_name() + int account_get_domain_name( + ffi.Pointer account, + ffi.Pointer> domain_name, + ) { + return _account_get_domain_name( + account, + domain_name, + ); + } + + late final _account_get_domain_name_ptr = + _lookup>( + 'account_get_domain_name'); + late final _dart_account_get_domain_name _account_get_domain_name = + _account_get_domain_name_ptr.asFunction<_dart_account_get_domain_name>(); + + /// @brief Sets the domain name. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] domain_name The text string to set as the domain name + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_domain_name() + int account_set_domain_name( + ffi.Pointer account, + ffi.Pointer domain_name, + ) { + return _account_set_domain_name( + account, + domain_name, + ); + } + + late final _account_set_domain_name_ptr = + _lookup>( + 'account_set_domain_name'); + late final _dart_account_set_domain_name _account_set_domain_name = + _account_set_domain_name_ptr.asFunction<_dart_account_set_domain_name>(); + + /// @brief Gets the email address. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a email_address using free(). + /// + /// @param[in] account The account handle + /// @param[out] email_address The email address + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_email_address() + int account_get_email_address( + ffi.Pointer account, + ffi.Pointer> email_address, + ) { + return _account_get_email_address( + account, + email_address, + ); + } + + late final _account_get_email_address_ptr = + _lookup>( + 'account_get_email_address'); + late final _dart_account_get_email_address _account_get_email_address = + _account_get_email_address_ptr + .asFunction<_dart_account_get_email_address>(); + + /// @brief Sets the email address. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] email_address The text string to set as the email address + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_email_address() + int account_set_email_address( + ffi.Pointer account, + ffi.Pointer email_address, + ) { + return _account_set_email_address( + account, + email_address, + ); + } + + late final _account_set_email_address_ptr = + _lookup>( + 'account_set_email_address'); + late final _dart_account_set_email_address _account_set_email_address = + _account_set_email_address_ptr + .asFunction<_dart_account_set_email_address>(); + + /// @brief Gets the package name. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a package_name using free(). + /// + /// @param[in] account The account handle + /// @param[out] package_name The package name + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_package_name() + int account_get_package_name( + ffi.Pointer account, + ffi.Pointer> package_name, + ) { + return _account_get_package_name( + account, + package_name, + ); + } + + late final _account_get_package_name_ptr = + _lookup>( + 'account_get_package_name'); + late final _dart_account_get_package_name _account_get_package_name = + _account_get_package_name_ptr + .asFunction<_dart_account_get_package_name>(); + + /// @brief Sets the package name. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] package_name The text string to set as the package name + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_email_address() + int account_set_package_name( + ffi.Pointer account, + ffi.Pointer package_name, + ) { + return _account_set_package_name( + account, + package_name, + ); + } + + late final _account_set_package_name_ptr = + _lookup>( + 'account_set_package_name'); + late final _dart_account_set_package_name _account_set_package_name = + _account_set_package_name_ptr + .asFunction<_dart_account_set_package_name>(); + + /// @brief Gets the access token. Access token field is used to store account secrets (such as password or master token). + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a access_token using free(). + /// @remarks Access token field is used for storing account secret (password / master token etc) + /// + /// @param[in] account The account handle + /// @param[out] access_token The access token + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// Only account owner application can retrieve account password / access_token. For others this field will be null. + /// @see account_set_access_token() + int account_get_access_token( + ffi.Pointer account, + ffi.Pointer> access_token, + ) { + return _account_get_access_token( + account, + access_token, + ); + } + + late final _account_get_access_token_ptr = + _lookup>( + 'account_get_access_token'); + late final _dart_account_get_access_token _account_get_access_token = + _account_get_access_token_ptr + .asFunction<_dart_account_get_access_token>(); + + /// @brief Sets the access token. Access token field is used to store account secrets (such as password or master token). + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks Only account owner application can retrieve account password / access_token. For others this field will be null. + /// + /// @param[in] account The account handle + /// @param[in] access_token The text string to set as the access token + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// @see account_get_access_token() + int account_set_access_token( + ffi.Pointer account, + ffi.Pointer access_token, + ) { + return _account_set_access_token( + account, + access_token, + ); + } + + late final _account_set_access_token_ptr = + _lookup>( + 'account_set_access_token'); + late final _dart_account_set_access_token _account_set_access_token = + _account_set_access_token_ptr + .asFunction<_dart_account_set_access_token>(); + + /// @brief Gets the user text. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a user_text using free(). + /// + /// @param[in] account The account handle + /// @param[in] user_text_index The index of the user text (range: 0 ~ 4) + /// @param[out] user_text The user text + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_user_text() + int account_get_user_text( + ffi.Pointer account, + int user_text_index, + ffi.Pointer> user_text, + ) { + return _account_get_user_text( + account, + user_text_index, + user_text, + ); + } + + late final _account_get_user_text_ptr = + _lookup>( + 'account_get_user_text'); + late final _dart_account_get_user_text _account_get_user_text = + _account_get_user_text_ptr.asFunction<_dart_account_get_user_text>(); + + /// @brief Sets the user text. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] user_text_index The index of the user text (must be in range from @c 0 to @c 4) + /// @param[in] user_text The text string to set as the user text + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_user_text() + int account_set_user_text( + ffi.Pointer account, + int user_text_index, + ffi.Pointer user_text, + ) { + return _account_set_user_text( + account, + user_text_index, + user_text, + ); + } + + late final _account_set_user_text_ptr = + _lookup>( + 'account_set_user_text'); + late final _dart_account_set_user_text _account_set_user_text = + _account_set_user_text_ptr.asFunction<_dart_account_set_user_text>(); + + /// @brief Gets the user integer. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] user_int_index The index of the user integer (must be in range from @c 0 to @c 4) + /// @param[out] user_integer The user integer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_user_int() + int account_get_user_int( + ffi.Pointer account, + int user_int_index, + ffi.Pointer user_integer, + ) { + return _account_get_user_int( + account, + user_int_index, + user_integer, + ); + } + + late final _account_get_user_int_ptr = + _lookup>( + 'account_get_user_int'); + late final _dart_account_get_user_int _account_get_user_int = + _account_get_user_int_ptr.asFunction<_dart_account_get_user_int>(); + + /// @brief Sets the user integer. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] user_int_index The index of the user integer (must be in range from @c 0 to @c 4) + /// @param[in] user_integer The integer to set as the user integer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_user_int() + int account_set_user_int( + ffi.Pointer account, + int user_int_index, + int user_integer, + ) { + return _account_set_user_int( + account, + user_int_index, + user_integer, + ); + } + + late final _account_set_user_int_ptr = + _lookup>( + 'account_set_user_int'); + late final _dart_account_set_user_int _account_set_user_int = + _account_set_user_int_ptr.asFunction<_dart_account_set_user_int>(); + + /// @brief Gets the authentiacation type. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[out] auth_type The authentiacation type + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_auth_type() + int account_get_auth_type( + ffi.Pointer account, + ffi.Pointer auth_type, + ) { + return _account_get_auth_type( + account, + auth_type, + ); + } + + late final _account_get_auth_type_ptr = + _lookup>( + 'account_get_auth_type'); + late final _dart_account_get_auth_type _account_get_auth_type = + _account_get_auth_type_ptr.asFunction<_dart_account_get_auth_type>(); + + /// @brief Sets the authentiacation type. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] auth_type The integer to be set as the authentiacation type + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_auth_type() + int account_set_auth_type( + ffi.Pointer account, + int auth_type, + ) { + return _account_set_auth_type( + account, + auth_type, + ); + } + + late final _account_set_auth_type_ptr = + _lookup>( + 'account_set_auth_type'); + late final _dart_account_set_auth_type _account_set_auth_type = + _account_set_auth_type_ptr.asFunction<_dart_account_set_auth_type>(); + + /// @brief Gets the secret. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[out] secret The secret + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_secret() + int account_get_secret( + ffi.Pointer account, + ffi.Pointer secret, + ) { + return _account_get_secret( + account, + secret, + ); + } + + late final _account_get_secret_ptr = + _lookup>('account_get_secret'); + late final _dart_account_get_secret _account_get_secret = + _account_get_secret_ptr.asFunction<_dart_account_get_secret>(); + + /// @brief Sets the secret. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] secret The secrecy to be set + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_secret() + int account_set_secret( + ffi.Pointer account, + int secret, + ) { + return _account_set_secret( + account, + secret, + ); + } + + late final _account_set_secret_ptr = + _lookup>('account_set_secret'); + late final _dart_account_set_secret _account_set_secret = + _account_set_secret_ptr.asFunction<_dart_account_set_secret>(); + + /// @brief Gets the sync support. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[out] sync_support The sync support + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_sync_support() + int account_get_sync_support( + ffi.Pointer account, + ffi.Pointer sync_support, + ) { + return _account_get_sync_support( + account, + sync_support, + ); + } + + late final _account_get_sync_support_ptr = + _lookup>( + 'account_get_sync_support'); + late final _dart_account_get_sync_support _account_get_sync_support = + _account_get_sync_support_ptr + .asFunction<_dart_account_get_sync_support>(); + + /// @brief Sets the sync support. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] sync_support The sync state to be set + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_sync_support() + int account_set_sync_support( + ffi.Pointer account, + int sync_support, + ) { + return _account_set_sync_support( + account, + sync_support, + ); + } + + late final _account_set_sync_support_ptr = + _lookup>( + 'account_set_sync_support'); + late final _dart_account_set_sync_support _account_set_sync_support = + _account_set_sync_support_ptr + .asFunction<_dart_account_set_sync_support>(); + + /// @brief Gets the source. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a source using free(). + /// + /// @param[in] account The account handle + /// @param[out] source The source + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_source() + int account_get_source( + ffi.Pointer account, + ffi.Pointer> source, + ) { + return _account_get_source( + account, + source, + ); + } + + late final _account_get_source_ptr = + _lookup>('account_get_source'); + late final _dart_account_get_source _account_get_source = + _account_get_source_ptr.asFunction<_dart_account_get_source>(); + + /// @brief Sets the source. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] source The text string to set as the source + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_source() + int account_set_source( + ffi.Pointer account, + ffi.Pointer source, + ) { + return _account_set_source( + account, + source, + ); + } + + late final _account_set_source_ptr = + _lookup>('account_set_source'); + late final _dart_account_set_source _account_set_source = + _account_set_source_ptr.asFunction<_dart_account_set_source>(); + + /// @brief Sets the custom. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] key The user custom key for the specific value + /// @param[in] value The user custom value about the given key + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_get_custom() + int account_set_custom( + ffi.Pointer account, + ffi.Pointer key, + ffi.Pointer value, + ) { + return _account_set_custom( + account, + key, + value, + ); + } + + late final _account_set_custom_ptr = + _lookup>('account_set_custom'); + late final _dart_account_set_custom _account_set_custom = + _account_set_custom_ptr.asFunction<_dart_account_set_custom>(); + + /// @brief Gets the user specific custom text of an account key. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a value using free(). + /// + /// @param[in] account The account handle + /// @param[in] key The key to retrieve custom text + /// @param[out] value The text of the given key + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_RECORD_NOT_FOUND There is no given capability type in the account + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_custom() + int account_get_custom( + ffi.Pointer account, + ffi.Pointer key, + ffi.Pointer> value, + ) { + return _account_get_custom( + account, + key, + value, + ); + } + + late final _account_get_custom_ptr = + _lookup>('account_get_custom'); + late final _dart_account_get_custom _account_get_custom = + _account_get_custom_ptr.asFunction<_dart_account_get_custom>(); + + /// @brief Gets all the user custom texts of an account. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account The account handle + /// @param[in] callback The callback function to retrieve all custom text \n + /// The callback function gives the key and value. + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_set_custom() + int account_get_custom_all( + ffi.Pointer account, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _account_get_custom_all( + account, + callback, + user_data, + ); + } + + late final _account_get_custom_all_ptr = + _lookup>( + 'account_get_custom_all'); + late final _dart_account_get_custom_all _account_get_custom_all = + _account_get_custom_all_ptr.asFunction<_dart_account_get_custom_all>(); + + /// @brief Retrieves all accounts details by invoking the given callback function iteratively. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_RECORD_NOT_FOUND Related record does not exist + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// @post This function invokes account_cb(). + /// + /// @see account_query_account_by_account_id() + /// @see account_query_account_by_user_name() + /// @see account_query_account_by_package_name() + /// @see account_query_account_by_capability() + int account_foreach_account_from_db( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _account_foreach_account_from_db( + callback, + user_data, + ); + } + + late final _account_foreach_account_from_db_ptr = + _lookup>( + 'account_foreach_account_from_db'); + late final _dart_account_foreach_account_from_db + _account_foreach_account_from_db = _account_foreach_account_from_db_ptr + .asFunction<_dart_account_foreach_account_from_db>(); + + /// @brief Retrieves an account with the account ID. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @remarks You must allocate @a account using account_create() and release using account_destroy(). + /// + /// @param[in] account_db_id The account database ID to search + /// @param[out] account The account handle \n + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// + /// @see account_query_account_by_user_name() + /// @see account_query_account_by_package_name() + /// @see account_query_account_by_capability() + int account_query_account_by_account_id( + int account_db_id, + ffi.Pointer> account, + ) { + return _account_query_account_by_account_id( + account_db_id, + account, + ); + } + + late final _account_query_account_by_account_id_ptr = + _lookup>( + 'account_query_account_by_account_id'); + late final _dart_account_query_account_by_account_id + _account_query_account_by_account_id = + _account_query_account_by_account_id_ptr + .asFunction<_dart_account_query_account_by_account_id>(); + + /// @brief Retrieves all accounts with the user name. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @param[in] callback The callback function to invoke + /// @param[in] user_name The user name to search + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// @post This function invokes account_cb(). + /// + /// @see account_foreach_account_from_db() + /// @see account_query_account_by_account_id() + /// @see account_query_account_by_package_name() + /// @see account_query_account_by_capability() + int account_query_account_by_user_name( + ffi.Pointer> callback, + ffi.Pointer user_name, + ffi.Pointer user_data, + ) { + return _account_query_account_by_user_name( + callback, + user_name, + user_data, + ); + } + + late final _account_query_account_by_user_name_ptr = + _lookup>( + 'account_query_account_by_user_name'); + late final _dart_account_query_account_by_user_name + _account_query_account_by_user_name = + _account_query_account_by_user_name_ptr + .asFunction<_dart_account_query_account_by_user_name>(); + + /// @brief Retrieves all accounts with the package name. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @param[in] callback The callback function to invoke + /// @param[in] package_name The package name to search + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// @post This function invokes account_cb(). + /// + /// @see account_foreach_account_from_db() + /// @see account_query_account_by_account_id() + /// @see account_query_account_by_user_name() + /// @see account_query_account_by_capability() + int account_query_account_by_package_name( + ffi.Pointer> callback, + ffi.Pointer package_name, + ffi.Pointer user_data, + ) { + return _account_query_account_by_package_name( + callback, + package_name, + user_data, + ); + } + + late final _account_query_account_by_package_name_ptr = + _lookup>( + 'account_query_account_by_package_name'); + late final _dart_account_query_account_by_package_name + _account_query_account_by_package_name = + _account_query_account_by_package_name_ptr + .asFunction<_dart_account_query_account_by_package_name>(); + + /// @brief Retrieves all accounts with the capability type and capability value. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @param[in] callback The callback function to invoke + /// @param[in] capability_type The capability type to search + /// @param[in] capability_value The capability value to search + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// @post This function invokes account_cb(). + /// + /// @see account_foreach_account_from_db() + /// @see account_query_account_by_account_id() + /// @see account_query_account_by_user_name() + /// @see account_query_account_by_package_name() + int account_query_account_by_capability( + ffi.Pointer> callback, + ffi.Pointer capability_type, + int capability_value, + ffi.Pointer user_data, + ) { + return _account_query_account_by_capability( + callback, + capability_type, + capability_value, + user_data, + ); + } + + late final _account_query_account_by_capability_ptr = + _lookup>( + 'account_query_account_by_capability'); + late final _dart_account_query_account_by_capability + _account_query_account_by_capability = + _account_query_account_by_capability_ptr + .asFunction<_dart_account_query_account_by_capability>(); + + /// @brief Retrieves all accounts with the capability type. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @param[in] callback The callback function to invoke + /// @param[in] capability_type The capability type to search + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// @post This function invokes account_cb(). + /// + /// @see account_foreach_account_from_db() + /// @see account_query_account_by_account_id() + /// @see account_query_account_by_user_name() + /// @see account_query_account_by_package_name() + int account_query_account_by_capability_type( + ffi.Pointer> callback, + ffi.Pointer capability_type, + ffi.Pointer user_data, + ) { + return _account_query_account_by_capability_type( + callback, + capability_type, + user_data, + ); + } + + late final _account_query_account_by_capability_type_ptr = + _lookup>( + 'account_query_account_by_capability_type'); + late final _dart_account_query_account_by_capability_type + _account_query_account_by_capability_type = + _account_query_account_by_capability_type_ptr + .asFunction<_dart_account_query_account_by_capability_type>(); + + /// @brief Retrieves all capabilities with the account database ID. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @param[in] callback The callback function to invoke + /// @param[in] account_db_id The account database ID to search + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// @post This function invokes capability_cb(). + /// + /// @see account_get_capability() + /// @see account_set_capability() + int account_query_capability_by_account_id( + ffi.Pointer> callback, + int account_db_id, + ffi.Pointer user_data, + ) { + return _account_query_capability_by_account_id( + callback, + account_db_id, + user_data, + ); + } + + late final _account_query_capability_by_account_id_ptr = + _lookup>( + 'account_query_capability_by_account_id'); + late final _dart_account_query_capability_by_account_id + _account_query_capability_by_account_id = + _account_query_capability_by_account_id_ptr + .asFunction<_dart_account_query_capability_by_account_id>(); + + /// @brief Gets the count of accounts in the account database. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @param[out] count The out parameter for count of all accounts + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + int account_get_total_count_from_db( + ffi.Pointer count, + ) { + return _account_get_total_count_from_db( + count, + ); + } + + late final _account_get_total_count_from_db_ptr = + _lookup>( + 'account_get_total_count_from_db'); + late final _dart_account_get_total_count_from_db + _account_get_total_count_from_db = _account_get_total_count_from_db_ptr + .asFunction<_dart_account_get_total_count_from_db>(); + + /// @brief Updates the sync status of an account with the given account ID. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read \n + /// %http://tizen.org/privilege/account.write + /// @remarks This API need both privileges \n + /// Only can update an account which was added by same package applications + /// @param[in] account_db_id The account ID for which sync status needs to be changed + /// @param[in] sync_status The new sync status + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + int account_update_sync_status_by_id( + int account_db_id, + int sync_status, + ) { + return _account_update_sync_status_by_id( + account_db_id, + sync_status, + ); + } + + late final _account_update_sync_status_by_id_ptr = + _lookup>( + 'account_update_sync_status_by_id'); + late final _dart_account_update_sync_status_by_id + _account_update_sync_status_by_id = _account_update_sync_status_by_id_ptr + .asFunction<_dart_account_update_sync_status_by_id>(); + + /// @brief Creates a handle to the account provider. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a account_type handle using account_type_destroy().\n + /// + /// @param[in] account_type The account provider handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_type_destroy() + int account_type_create( + ffi.Pointer> account_type, + ) { + return _account_type_create( + account_type, + ); + } + + late final _account_type_create_ptr = + _lookup>( + 'account_type_create'); + late final _dart_account_type_create _account_type_create = + _account_type_create_ptr.asFunction<_dart_account_type_create>(); + + /// @brief Destroys the account provider handle and releases all its resources. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// + /// @remarks When you get @a account_type_h using account_type_create(), you must release the handle using account_destroy() to avoid the memory leak. + /// + /// @param[in] account_type The account provider handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_type_create() + int account_type_destroy( + ffi.Pointer account_type, + ) { + return _account_type_destroy( + account_type, + ); + } + + late final _account_type_destroy_ptr = + _lookup>( + 'account_type_destroy'); + late final _dart_account_type_destroy _account_type_destroy = + _account_type_destroy_ptr.asFunction<_dart_account_type_destroy>(); + + /// @brief Retrieves capability information with your application ID. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @param[in] callback The callback function carries the capability name of an app ID + /// @param[in] app_id The application ID to search + /// @param[in] user_data The user data \n + /// If you have your private data to carry into callback function, then you can use it. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + int account_type_query_provider_feature_by_app_id( + ffi.Pointer> callback, + ffi.Pointer app_id, + ffi.Pointer user_data, + ) { + return _account_type_query_provider_feature_by_app_id( + callback, + app_id, + user_data, + ); + } + + late final _account_type_query_provider_feature_by_app_id_ptr = _lookup< + ffi.NativeFunction<_c_account_type_query_provider_feature_by_app_id>>( + 'account_type_query_provider_feature_by_app_id'); + late final _dart_account_type_query_provider_feature_by_app_id + _account_type_query_provider_feature_by_app_id = + _account_type_query_provider_feature_by_app_id_ptr + .asFunction<_dart_account_type_query_provider_feature_by_app_id>(); + + /// @brief Checks whether the given application ID supports the capability. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] app_id The application ID + /// @param[in] capability The capability \n + /// For example, ACCOUNT_SUPPORTS_CAPABILITY_CONTACT or "http://tizen.org/account/capability/contact" + /// + /// @return @c TRUE if the application supports the given capability, \n + /// otherwise @c FALSE if the application does not support the given capability + /// @retval @c TRUE means the application supports the given capability + /// @retval @c FALSE means the application does not support the given capability + /// @exception #ACCOUNT_ERROR_NONE Successful + /// @exception #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #ACCOUNT_ERROR_RECORD_NOT_FOUND Related record does not exist + /// @exception #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @exception #ACCOUNT_ERROR_PERMISSION_DENIED DB access fail by permission + /// @exception #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @exception #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @exception #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + bool account_type_query_supported_feature( + ffi.Pointer app_id, + ffi.Pointer capability, + ) { + return _account_type_query_supported_feature( + app_id, + capability, + ) != + 0; + } + + late final _account_type_query_supported_feature_ptr = + _lookup>( + 'account_type_query_supported_feature'); + late final _dart_account_type_query_supported_feature + _account_type_query_supported_feature = + _account_type_query_supported_feature_ptr + .asFunction<_dart_account_type_query_supported_feature>(); + + /// @brief Gets the application ID of an account provider. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a app_id using free(). + /// + /// @param[in] account_type The account provider handle \n + /// It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db(). + /// @param[out] app_id The application ID of an account provider item + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_type_foreach_account_type_from_db() + /// @see account_type_query_by_app_id() + int account_type_get_app_id( + ffi.Pointer account_type, + ffi.Pointer> app_id, + ) { + return _account_type_get_app_id( + account_type, + app_id, + ); + } + + late final _account_type_get_app_id_ptr = + _lookup>( + 'account_type_get_app_id'); + late final _dart_account_type_get_app_id _account_type_get_app_id = + _account_type_get_app_id_ptr.asFunction<_dart_account_type_get_app_id>(); + + /// @brief Gets the service provider ID of an account provider. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a service_provider_id using free(). + /// + /// @param[in] account_type The account provider handle \n + /// It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db(). + /// @param[out] service_provider_id The service provider text ID of an account provider item + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_type_foreach_account_type_from_db() + /// @see account_type_query_by_app_id() + int account_type_get_service_provider_id( + ffi.Pointer account_type, + ffi.Pointer> service_provider_id, + ) { + return _account_type_get_service_provider_id( + account_type, + service_provider_id, + ); + } + + late final _account_type_get_service_provider_id_ptr = + _lookup>( + 'account_type_get_service_provider_id'); + late final _dart_account_type_get_service_provider_id + _account_type_get_service_provider_id = + _account_type_get_service_provider_id_ptr + .asFunction<_dart_account_type_get_service_provider_id>(); + + /// @brief Gets the icon path of an account provider. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a icon_path using free(). + /// + /// @param[in] account_type The account provider handle \n + /// It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db(). + /// @param[out] icon_path The icon path of the account provider item + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_type_foreach_account_type_from_db() + /// @see account_type_query_by_app_id() + int account_type_get_icon_path( + ffi.Pointer account_type, + ffi.Pointer> icon_path, + ) { + return _account_type_get_icon_path( + account_type, + icon_path, + ); + } + + late final _account_type_get_icon_path_ptr = + _lookup>( + 'account_type_get_icon_path'); + late final _dart_account_type_get_icon_path _account_type_get_icon_path = + _account_type_get_icon_path_ptr + .asFunction<_dart_account_type_get_icon_path>(); + + /// @brief Gets the small icon path of an account provider. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a small_icon_path using free(). + /// + /// @param[in] account_type The account provider handle\n + /// It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db(). + /// @param[out] small_icon_path The small icon path of the account provider item + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_type_foreach_account_type_from_db() + /// @see account_type_query_by_app_id() + int account_type_get_small_icon_path( + ffi.Pointer account_type, + ffi.Pointer> small_icon_path, + ) { + return _account_type_get_small_icon_path( + account_type, + small_icon_path, + ); + } + + late final _account_type_get_small_icon_path_ptr = + _lookup>( + 'account_type_get_small_icon_path'); + late final _dart_account_type_get_small_icon_path + _account_type_get_small_icon_path = _account_type_get_small_icon_path_ptr + .asFunction<_dart_account_type_get_small_icon_path>(); + + /// @brief Checks whether the given account provider supports multiple accounts. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account_type The account provider handle \n + /// It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db. + /// @param[out] multiple_account_support The flag indicating support for multiple accounts accounts\n + /// TRUE or FALSE. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_type_foreach_account_type_from_db() + /// @see account_type_query_by_app_id() + int account_type_get_multiple_account_support( + ffi.Pointer account_type, + ffi.Pointer multiple_account_support, + ) { + return _account_type_get_multiple_account_support( + account_type, + multiple_account_support, + ); + } + + late final _account_type_get_multiple_account_support_ptr = + _lookup>( + 'account_type_get_multiple_account_support'); + late final _dart_account_type_get_multiple_account_support + _account_type_get_multiple_account_support = + _account_type_get_multiple_account_support_ptr + .asFunction<_dart_account_type_get_multiple_account_support>(); + + /// @brief Gets capability information with the given account provider handle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account_type The account provider handle\n + /// It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db(). + /// @param[in] callback The callback function that carries the capability name of the app ID + /// @param[in] user_data The user data \n + /// If you have your private data to carry into callback function, then you can use it. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + int account_type_get_provider_feature_all( + ffi.Pointer account_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _account_type_get_provider_feature_all( + account_type, + callback, + user_data, + ); + } + + late final _account_type_get_provider_feature_all_ptr = + _lookup>( + 'account_type_get_provider_feature_all'); + late final _dart_account_type_get_provider_feature_all + _account_type_get_provider_feature_all = + _account_type_get_provider_feature_all_ptr + .asFunction<_dart_account_type_get_provider_feature_all>(); + + /// @brief Gets the specific label information detail of an account provider. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a label using free(). + /// + /// @param[in] account_type The account provider handle\n + /// It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db(). + /// @param[in] locale The locale is specified as an ISO 3166 alpha-2 two letter country-code followed by ISO 639-1 for the two-letter language code.\n + /// For example, "ko_KR" or "ko-kr" for Korean, "en_US" or "en-us" for American English. + /// @param[out] label The label text given for the locale + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_RECORD_NOT_FOUND No label for the given locale + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_type_foreach_account_type_from_db() + /// @see account_type_query_by_app_id() + int account_type_get_label_by_locale( + ffi.Pointer account_type, + ffi.Pointer locale, + ffi.Pointer> label, + ) { + return _account_type_get_label_by_locale( + account_type, + locale, + label, + ); + } + + late final _account_type_get_label_by_locale_ptr = + _lookup>( + 'account_type_get_label_by_locale'); + late final _dart_account_type_get_label_by_locale + _account_type_get_label_by_locale = _account_type_get_label_by_locale_ptr + .asFunction<_dart_account_type_get_label_by_locale>(); + + /// @brief Gets the label information detail of an account provider. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] account_type The account provider handle\n + /// It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db(). + /// @param[in] callback The callback function carrying the label information + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_type_foreach_account_type_from_db() + /// @see account_type_query_by_app_id() + int account_type_get_label( + ffi.Pointer account_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _account_type_get_label( + account_type, + callback, + user_data, + ); + } + + late final _account_type_get_label_ptr = + _lookup>( + 'account_type_get_label'); + late final _dart_account_type_get_label _account_type_get_label = + _account_type_get_label_ptr.asFunction<_dart_account_type_get_label>(); + + /// @brief Retrieves the label information with your application ID. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @param[in] callback The callback function that carries label_h for label information \n + /// label_h contains label info as parameter. + /// @param[in] app_id The application ID to search + /// @param[in] user_data The user data \n + /// If you have your private data to carry into callback function, then you can use it. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// + /// @see account_type_query_by_app_id() + /// @see account_type_foreach_account_type_from_db() + int account_type_query_label_by_app_id( + ffi.Pointer> callback, + ffi.Pointer app_id, + ffi.Pointer user_data, + ) { + return _account_type_query_label_by_app_id( + callback, + app_id, + user_data, + ); + } + + late final _account_type_query_label_by_app_id_ptr = + _lookup>( + 'account_type_query_label_by_app_id'); + late final _dart_account_type_query_label_by_app_id + _account_type_query_label_by_app_id = + _account_type_query_label_by_app_id_ptr + .asFunction<_dart_account_type_query_label_by_app_id>(); + + /// @brief Retrieves the account provider information with your application ID. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @param[in] app_id The application ID to search + /// @param[in,out] account_type The account handle which has to be created by account_type_create() before calling this function and released by account_type_destroy() after calling this function. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_RECORD_NOT_FOUND Queried data does not exist + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// + /// @see account_type_create() + /// @see account_type_get_app_id() + /// @see account_type_get_service_provider_id() + /// @see account_type_get_icon_path() + /// @see account_type_get_small_icon_path() + /// @see account_type_get_multiple_account_support() + /// @see account_type_get_label() + /// @see account_type_destroy() + int account_type_query_by_app_id( + ffi.Pointer app_id, + ffi.Pointer> account_type, + ) { + return _account_type_query_by_app_id( + app_id, + account_type, + ); + } + + late final _account_type_query_by_app_id_ptr = + _lookup>( + 'account_type_query_by_app_id'); + late final _dart_account_type_query_by_app_id _account_type_query_by_app_id = + _account_type_query_by_app_id_ptr + .asFunction<_dart_account_type_query_by_app_id>(); + + /// @brief Retrieves all account priovider information. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @param[in] callback The account provider information \n + /// You can get the account information through account_type_get_* with the carried account_type_handle. + /// @param[in] user_data The user data \n + /// It will be carried through your callback function. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// + /// @see account_type_create() + /// @see account_type_get_app_id() + /// @see account_type_get_service_provider_id() + /// @see account_type_get_icon_path() + /// @see account_type_get_small_icon_path() + /// @see account_type_get_multiple_account_support() + /// @see account_type_get_label() + /// @see account_type_destroy() + int account_type_foreach_account_type_from_db( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _account_type_foreach_account_type_from_db( + callback, + user_data, + ); + } + + late final _account_type_foreach_account_type_from_db_ptr = + _lookup>( + 'account_type_foreach_account_type_from_db'); + late final _dart_account_type_foreach_account_type_from_db + _account_type_foreach_account_type_from_db = + _account_type_foreach_account_type_from_db_ptr + .asFunction<_dart_account_type_foreach_account_type_from_db>(); + + /// @brief Retrieves the label information with the given application ID and locale. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @param[in] app_id The application ID + /// @param[in] locale The locale is specified as an ISO 3166 alpha-2 two letter country-code followed by ISO 639-1 for the two-letter language code.\n + /// For example, "ko_KR" or "ko-kr" for Korean, "en_US" or "en-us" for American English. + /// @param[out] label The label text corresponding app_id and locale \n + /// It must be free text. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + int account_type_query_label_by_locale( + ffi.Pointer app_id, + ffi.Pointer locale, + ffi.Pointer> label, + ) { + return _account_type_query_label_by_locale( + app_id, + locale, + label, + ); + } + + late final _account_type_query_label_by_locale_ptr = + _lookup>( + 'account_type_query_label_by_locale'); + late final _dart_account_type_query_label_by_locale + _account_type_query_label_by_locale = + _account_type_query_label_by_locale_ptr + .asFunction<_dart_account_type_query_label_by_locale>(); + + /// @brief Retrieves account provider information with the capability name. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @param[in] callback The callback function to retrieve account provider information + /// @param[in] key The capability value to search account provider \n + /// For example, ACCOUNT_SUPPORTS_CAPABILITY_CONTACT or "http://tizen.org/account/capability/contact" + /// @param[in] user_data If you have your private data to carry into callback function, then you can use it + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_RECORD_NOT_FOUND Record not found + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + int account_type_query_by_provider_feature( + ffi.Pointer> callback, + ffi.Pointer key, + ffi.Pointer user_data, + ) { + return _account_type_query_by_provider_feature( + callback, + key, + user_data, + ); + } + + late final _account_type_query_by_provider_feature_ptr = + _lookup>( + 'account_type_query_by_provider_feature'); + late final _dart_account_type_query_by_provider_feature + _account_type_query_by_provider_feature = + _account_type_query_by_provider_feature_ptr + .asFunction<_dart_account_type_query_by_provider_feature>(); + + /// @brief Checks whether the given app_id exists in the account provider DB. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read + /// @param[in] app_id The application ID to check + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_RECORD_NOT_FOUND Record not found + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid app ID + /// @retval #ACCOUNT_ERROR_DB_FAILED Database operation failed + /// @retval #ACCOUNT_ERROR_PERMISSION_DENIED DB Access fail by permission + /// @retval #ACCOUNT_ERROR_DATABASE_BUSY SQLite handler is busy + /// @retval #ACCOUNT_ERROR_DB_NOT_OPENED Account database did not opened + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires an open connection to an account service by account_connect() on tizen 2.3 (MOBILE).\n + /// But the account_connect() is not required to use this function since tizen 2.4. + /// + /// @see account_type_query_by_app_id() + int account_type_query_app_id_exist( + ffi.Pointer app_id, + ) { + return _account_type_query_app_id_exist( + app_id, + ); + } + + late final _account_type_query_app_id_exist_ptr = + _lookup>( + 'account_type_query_app_id_exist'); + late final _dart_account_type_query_app_id_exist + _account_type_query_app_id_exist = _account_type_query_app_id_exist_ptr + .asFunction<_dart_account_type_query_app_id_exist>(); + + /// @brief Creates a handle for the account event subscription. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a account_subscribe handle using account_unsubscribe_notification(). + /// + /// @param[in] account_subscribe The account subscription handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_unsubscribe_notification() + /// @see account_subscribe_notification() + int account_subscribe_create( + ffi.Pointer> account_subscribe, + ) { + return _account_subscribe_create( + account_subscribe, + ); + } + + late final _account_subscribe_create_ptr = + _lookup>( + 'account_subscribe_create'); + late final _dart_account_subscribe_create _account_subscribe_create = + _account_subscribe_create_ptr + .asFunction<_dart_account_subscribe_create>(); + + /// @brief Starts to subscribe account event through the given callback function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read \n + /// @param[in] account_subscribe The account subscription handle + /// @param[in] callback The callback function that is called when an account is removed and a data of account is updated from the account database \n + /// It will be called with event message and account ID. + /// @param[in] user_data The user_data that is delivered to callback + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_EVENT_SUBSCRIPTION_FAIL Subscription fail + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre account_subscribe_create() + /// + /// @see account_unsubscribe_notification() + /// @see account_subscribe_notification() + int account_subscribe_notification( + ffi.Pointer account_subscribe, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _account_subscribe_notification( + account_subscribe, + callback, + user_data, + ); + } + + late final _account_subscribe_notification_ptr = + _lookup>( + 'account_subscribe_notification'); + late final _dart_account_subscribe_notification + _account_subscribe_notification = _account_subscribe_notification_ptr + .asFunction<_dart_account_subscribe_notification>(); + + /// @brief Destroys the account subscribe handle and releases all its resources. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/account.read \n + /// @remarks You must call @a account_unsubscribe_notification when you do not need to subscribe account event. + /// + /// @param[in] account_subscribe The account subscription handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ACCOUNT_ERROR_NONE Successful + /// @retval #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ACCOUNT_ERROR_EVENT_SUBSCRIPTION_FAIL Unsubscription failed + /// @retval #ACCOUNT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see account_create() + int account_unsubscribe_notification( + ffi.Pointer account_subscribe, + ) { + return _account_unsubscribe_notification( + account_subscribe, + ); + } + + late final _account_unsubscribe_notification_ptr = + _lookup>( + 'account_unsubscribe_notification'); + late final _dart_account_unsubscribe_notification + _account_unsubscribe_notification = _account_unsubscribe_notification_ptr + .asFunction<_dart_account_unsubscribe_notification>(); + + /// @brief Retrieves all the available FIDO authenticators supported by this Device. + /// @details fido_authenticator_cb() callback is called synchronously once for each authenticator. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/fido.client + /// + /// @param[in] cb The iteration callback handle + /// @param[in] user_data The user data handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #FIDO_ERROR_PERMISSION_DENIED The application does not have permission to call this function. + /// @retval #FIDO_ERROR_NOT_SUPPORTED FIDO is not supported on this device. + int fido_foreach_authenticator( + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _fido_foreach_authenticator( + cb, + user_data, + ); + } + + late final _fido_foreach_authenticator_ptr = + _lookup>( + 'fido_foreach_authenticator'); + late final _dart_fido_foreach_authenticator _fido_foreach_authenticator = + _fido_foreach_authenticator_ptr + .asFunction<_dart_fido_foreach_authenticator>(); + + /// @brief Gets the Authenticator title. + /// @since_tizen 3.0 + /// + /// @remarks The @a title should be released using free(). + /// @param[in] auth The Authenticator handle + /// @param[out] title The title + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_authenticator_get_title( + ffi.Pointer auth, + ffi.Pointer> title, + ) { + return _fido_authenticator_get_title( + auth, + title, + ); + } + + late final _fido_authenticator_get_title_ptr = + _lookup>( + 'fido_authenticator_get_title'); + late final _dart_fido_authenticator_get_title _fido_authenticator_get_title = + _fido_authenticator_get_title_ptr + .asFunction<_dart_fido_authenticator_get_title>(); + + /// @brief Retrieves the Authenticator AAID (Authenticator Attestation ID). + /// @since_tizen 3.0 + /// + /// @remarks The @a aaid should be released using free(). + /// @param[in] auth The Authenticator handle + /// @param[out] aaid The AAID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_authenticator_get_aaid( + ffi.Pointer auth, + ffi.Pointer> aaid, + ) { + return _fido_authenticator_get_aaid( + auth, + aaid, + ); + } + + late final _fido_authenticator_get_aaid_ptr = + _lookup>( + 'fido_authenticator_get_aaid'); + late final _dart_fido_authenticator_get_aaid _fido_authenticator_get_aaid = + _fido_authenticator_get_aaid_ptr + .asFunction<_dart_fido_authenticator_get_aaid>(); + + /// @brief Retrieves the Authenticator description + /// @since_tizen 3.0 + /// + /// @remarks The @a desc should be released using free(). + /// @param[in] auth The Authenticator handle + /// @param[out] desc The description + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_authenticator_get_description( + ffi.Pointer auth, + ffi.Pointer> desc, + ) { + return _fido_authenticator_get_description( + auth, + desc, + ); + } + + late final _fido_authenticator_get_description_ptr = + _lookup>( + 'fido_authenticator_get_description'); + late final _dart_fido_authenticator_get_description + _fido_authenticator_get_description = + _fido_authenticator_get_description_ptr + .asFunction<_dart_fido_authenticator_get_description>(); + + /// @brief Retrieves the Authenticator assertion scheme. + /// @since_tizen 3.0 + /// + /// @remarks The @a scheme should be released using free(). Refer to FIDO UAF Registry document for more details. + /// @param[in] auth The Authenticator handle + /// @param[out] scheme The assertion scheme. UAFV1TLV is the default assertion scheme + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_authenticator_get_assertion_scheme( + ffi.Pointer auth, + ffi.Pointer> scheme, + ) { + return _fido_authenticator_get_assertion_scheme( + auth, + scheme, + ); + } + + late final _fido_authenticator_get_assertion_scheme_ptr = + _lookup>( + 'fido_authenticator_get_assertion_scheme'); + late final _dart_fido_authenticator_get_assertion_scheme + _fido_authenticator_get_assertion_scheme = + _fido_authenticator_get_assertion_scheme_ptr + .asFunction<_dart_fido_authenticator_get_assertion_scheme>(); + + /// @brief Retrieves the Authenticator algorithm. + /// @since_tizen 3.0 + /// + /// @param[in] auth The Authenticator handle + /// @param[out] algo The authentication algorithm + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_authenticator_get_algorithm( + ffi.Pointer auth, + ffi.Pointer algo, + ) { + return _fido_authenticator_get_algorithm( + auth, + algo, + ); + } + + late final _fido_authenticator_get_algorithm_ptr = + _lookup>( + 'fido_authenticator_get_algorithm'); + late final _dart_fido_authenticator_get_algorithm + _fido_authenticator_get_algorithm = _fido_authenticator_get_algorithm_ptr + .asFunction<_dart_fido_authenticator_get_algorithm>(); + + /// @brief Retrieves all the available attestation types for this Authenticator. + /// @since_tizen 3.0 + /// + /// @param[in] auth The Authenticator handle + /// @param[in] cb The iteration callback + /// @param[in] user_data The user data + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_authenticator_foreach_attestation_type( + ffi.Pointer auth, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _fido_authenticator_foreach_attestation_type( + auth, + cb, + user_data, + ); + } + + late final _fido_authenticator_foreach_attestation_type_ptr = _lookup< + ffi.NativeFunction<_c_fido_authenticator_foreach_attestation_type>>( + 'fido_authenticator_foreach_attestation_type'); + late final _dart_fido_authenticator_foreach_attestation_type + _fido_authenticator_foreach_attestation_type = + _fido_authenticator_foreach_attestation_type_ptr + .asFunction<_dart_fido_authenticator_foreach_attestation_type>(); + + /// @brief Retrieves the user verification method of this Authenticator. + /// @since_tizen 3.0 + /// + /// @param[in] auth The Authenticator handle + /// @param[out] user_verification The user verification method + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_authenticator_get_verification_method( + ffi.Pointer auth, + ffi.Pointer user_verification, + ) { + return _fido_authenticator_get_verification_method( + auth, + user_verification, + ); + } + + late final _fido_authenticator_get_verification_method_ptr = _lookup< + ffi.NativeFunction<_c_fido_authenticator_get_verification_method>>( + 'fido_authenticator_get_verification_method'); + late final _dart_fido_authenticator_get_verification_method + _fido_authenticator_get_verification_method = + _fido_authenticator_get_verification_method_ptr + .asFunction<_dart_fido_authenticator_get_verification_method>(); + + /// @brief Retrieves the key protection method of this Authenticator. + /// @since_tizen 3.0 + /// + /// @param[in] auth The Authenticator handle + /// @param[out] key_protection The key protection method + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_authenticator_get_key_protection_method( + ffi.Pointer auth, + ffi.Pointer key_protection, + ) { + return _fido_authenticator_get_key_protection_method( + auth, + key_protection, + ); + } + + late final _fido_authenticator_get_key_protection_method_ptr = _lookup< + ffi.NativeFunction<_c_fido_authenticator_get_key_protection_method>>( + 'fido_authenticator_get_key_protection_method'); + late final _dart_fido_authenticator_get_key_protection_method + _fido_authenticator_get_key_protection_method = + _fido_authenticator_get_key_protection_method_ptr + .asFunction<_dart_fido_authenticator_get_key_protection_method>(); + + /// @brief Retrieves the matcher protection method of this Authenticator. + /// @since_tizen 3.0 + /// + /// @param[in] auth The Authenticator handle + /// @param[out] matcher_protection The matcher protection method + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_authenticator_get_matcher_protection_method( + ffi.Pointer auth, + ffi.Pointer matcher_protection, + ) { + return _fido_authenticator_get_matcher_protection_method( + auth, + matcher_protection, + ); + } + + late final _fido_authenticator_get_matcher_protection_method_ptr = _lookup< + ffi.NativeFunction< + _c_fido_authenticator_get_matcher_protection_method>>( + 'fido_authenticator_get_matcher_protection_method'); + late final _dart_fido_authenticator_get_matcher_protection_method + _fido_authenticator_get_matcher_protection_method = + _fido_authenticator_get_matcher_protection_method_ptr + .asFunction<_dart_fido_authenticator_get_matcher_protection_method>(); + + /// @brief Retrieves the attachment hint of this Authenticator. + /// @since_tizen 3.0 + /// + /// @param[in] auth The Authenticator handle + /// @param[out] attachment_hint The matcher protection method + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_authenticator_get_attachment_hint( + ffi.Pointer auth, + ffi.Pointer attachment_hint, + ) { + return _fido_authenticator_get_attachment_hint( + auth, + attachment_hint, + ); + } + + late final _fido_authenticator_get_attachment_hint_ptr = + _lookup>( + 'fido_authenticator_get_attachment_hint'); + late final _dart_fido_authenticator_get_attachment_hint + _fido_authenticator_get_attachment_hint = + _fido_authenticator_get_attachment_hint_ptr + .asFunction<_dart_fido_authenticator_get_attachment_hint>(); + + /// @brief Checks if the Authenticator is Second factor only which is supported by U2F standards. + /// @since_tizen 3.0 + /// + /// @param[in] auth The Authenticator handle + /// + /// @return @c true if its only second factor, + /// otherwise false. + bool fido_authenticator_get_is_second_factor_only( + ffi.Pointer auth, + ) { + return _fido_authenticator_get_is_second_factor_only( + auth, + ) != + 0; + } + + late final _fido_authenticator_get_is_second_factor_only_ptr = _lookup< + ffi.NativeFunction<_c_fido_authenticator_get_is_second_factor_only>>( + 'fido_authenticator_get_is_second_factor_only'); + late final _dart_fido_authenticator_get_is_second_factor_only + _fido_authenticator_get_is_second_factor_only = + _fido_authenticator_get_is_second_factor_only_ptr + .asFunction<_dart_fido_authenticator_get_is_second_factor_only>(); + + /// @brief Retrieves the Transaction Confirmation display type of this Authenticator. + /// @since_tizen 3.0 + /// + /// @param[in] auth The Authenticator handle + /// @param[out] tc_display The TC display type + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_authenticator_get_tc_discplay( + ffi.Pointer auth, + ffi.Pointer tc_display, + ) { + return _fido_authenticator_get_tc_discplay( + auth, + tc_display, + ); + } + + late final _fido_authenticator_get_tc_discplay_ptr = + _lookup>( + 'fido_authenticator_get_tc_discplay'); + late final _dart_fido_authenticator_get_tc_discplay + _fido_authenticator_get_tc_discplay = + _fido_authenticator_get_tc_discplay_ptr + .asFunction<_dart_fido_authenticator_get_tc_discplay>(); + + /// @brief Retrieves the Transaction Confirmation display content type of this Authenticator. + /// @since_tizen 3.0 + /// + /// @remarks The @a tc_display_content_type should be released using free(). + /// @param[in] auth The Authenticator handle + /// @param[out] tc_display_content_type The TC display content type which is supported MIME type [RFC2049] such as text/plain or image/png + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_authenticator_get_tc_display_type( + ffi.Pointer auth, + ffi.Pointer> tc_display_content_type, + ) { + return _fido_authenticator_get_tc_display_type( + auth, + tc_display_content_type, + ); + } + + late final _fido_authenticator_get_tc_display_type_ptr = + _lookup>( + 'fido_authenticator_get_tc_display_type'); + late final _dart_fido_authenticator_get_tc_display_type + _fido_authenticator_get_tc_display_type = + _fido_authenticator_get_tc_display_type_ptr + .asFunction<_dart_fido_authenticator_get_tc_display_type>(); + + /// @brief Retrieves the icon of this Authenticator. + /// @since_tizen 3.0 + /// + /// @remarks The @a icon should be released using free(). + /// @param[in] auth The Authenticator handle + /// @param[out] icon The icon. Portable Network Graphic (PNG) format image file representing the icon encoded as a data: url[RFC2397] + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_authenticator_get_icon( + ffi.Pointer auth, + ffi.Pointer> icon, + ) { + return _fido_authenticator_get_icon( + auth, + icon, + ); + } + + late final _fido_authenticator_get_icon_ptr = + _lookup>( + 'fido_authenticator_get_icon'); + late final _dart_fido_authenticator_get_icon _fido_authenticator_get_icon = + _fido_authenticator_get_icon_ptr + .asFunction<_dart_fido_authenticator_get_icon>(); + + /// @brief Gets the FIDO client vendor name. + /// @since_tizen 3.0 + /// + /// @remarks The @a vendor_name should be released using free(). + /// @param[out] vendor_name The vendor name + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_get_client_vendor( + ffi.Pointer> vendor_name, + ) { + return _fido_get_client_vendor( + vendor_name, + ); + } + + late final _fido_get_client_vendor_ptr = + _lookup>( + 'fido_get_client_vendor'); + late final _dart_fido_get_client_vendor _fido_get_client_vendor = + _fido_get_client_vendor_ptr.asFunction<_dart_fido_get_client_vendor>(); + + /// @brief Gets the FIDO client vendor version information. + /// @since_tizen 3.0 + /// + /// @param[out] client_major_version The FIDO client major version + /// @param[out] client_minor_version The FIDO client minor version + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + int fido_get_client_version( + ffi.Pointer client_major_version, + ffi.Pointer client_minor_version, + ) { + return _fido_get_client_version( + client_major_version, + client_minor_version, + ); + } + + late final _fido_get_client_version_ptr = + _lookup>( + 'fido_get_client_version'); + late final _dart_fido_get_client_version _fido_get_client_version = + _fido_get_client_version_ptr.asFunction<_dart_fido_get_client_version>(); + + /// @brief Checks whether the FIDO message can be processed. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/fido.client + /// + /// @param[in] uaf_message_json The FIDO message in JSON format which is received from the relying party server + /// @param[out] is_supported True if the message can be handled by the device, else false + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #FIDO_ERROR_NOT_SUPPORTED FIDO is not supported + /// @retval #FIDO_ERROR_PERMISSION_DENIED The application does not have permission to call this function. + /// @retval #FIDO_ERROR_UNSUPPORTED_VERSION The UAF Message does not specify a protocol version supported by this FIDO UAF Client. + /// @retval #FIDO_ERROR_NO_SUITABLE_AUTHENTICATOR No suitable authenticators found. + /// @retval #FIDO_ERROR_PROTOCOL_ERROR The interaction may have timed out, or the UAF message is malformed. + /// @retval #FIDO_ERROR_UNTRUSTED_FACET_ID The caller's id is not allowed to use this operation. + int fido_uaf_is_supported( + ffi.Pointer uaf_message_json, + ffi.Pointer is_supported, + ) { + return _fido_uaf_is_supported( + uaf_message_json, + is_supported, + ); + } + + late final _fido_uaf_is_supported_ptr = + _lookup>( + 'fido_uaf_is_supported'); + late final _dart_fido_uaf_is_supported _fido_uaf_is_supported = + _fido_uaf_is_supported_ptr.asFunction<_dart_fido_uaf_is_supported>(); + + /// @brief Processes the given FIDO UAF message. + /// @details This function is asynchronous. The response is delivered via fido_uaf_response_message_cb(). + /// Depending on the FIDO message type, this may involve user interactions. + /// + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/fido.client + /// + /// @param[in] uaf_request_json The FIDO UAF message in JSON format which is received from the relying party server + /// @param[in] channel_binding The channel binding data in JSON format which is received from the relying party server + /// @param[in] callback The callback to receive response + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #FIDO_ERROR_NOT_SUPPORTED FIDO is not supported + /// + /// @see fido_uaf_response_message_cb() + int fido_uaf_get_response_message( + ffi.Pointer uaf_request_json, + ffi.Pointer channel_binding, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _fido_uaf_get_response_message( + uaf_request_json, + channel_binding, + callback, + user_data, + ); + } + + late final _fido_uaf_get_response_message_ptr = + _lookup>( + 'fido_uaf_get_response_message'); + late final _dart_fido_uaf_get_response_message + _fido_uaf_get_response_message = _fido_uaf_get_response_message_ptr + .asFunction<_dart_fido_uaf_get_response_message>(); + + /// @brief Notifies the FIDO client about the server result. FIDO Server sends the result of processing a UAF message to FIDO client. + /// @remarks This is especially important for cases when a new registration may be considered by the client to be in a pending state + /// until it is communicated that the server accepted it. + /// + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/fido.client + /// + /// @param[in] response_code The status code received from Server, #FIDO_SERVER_STATUS_CODE_OK implies success + /// @param[in] uaf_response_json The FIDO response message sent to server in JSON format + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FIDO_ERROR_NONE Successful + /// @retval #FIDO_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #FIDO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #FIDO_ERROR_NOT_SUPPORTED FIDO is not supported + /// @retval #FIDO_ERROR_PERMISSION_DENIED The application does not have permission to call this function. + /// @retval #FIDO_ERROR_UNSUPPORTED_VERSION The UAF Message does not specify a protocol version supported by this FIDO UAF Client. + /// @retval #FIDO_ERROR_NO_SUITABLE_AUTHENTICATOR No suitable authenticators found. + /// @retval #FIDO_ERROR_PROTOCOL_ERROR The interaction may have timed out, or the UAF message is malformed. + /// @retval #FIDO_ERROR_UNTRUSTED_FACET_ID The caller's id is not allowed to use this operation. + /// + /// @see fido_uaf_response_message_cb() + int fido_uaf_set_server_result( + int response_code, + ffi.Pointer uaf_response_json, + ) { + return _fido_uaf_set_server_result( + response_code, + uaf_response_json, + ); + } + + late final _fido_uaf_set_server_result_ptr = + _lookup>( + 'fido_uaf_set_server_result'); + late final _dart_fido_uaf_set_server_result _fido_uaf_set_server_result = + _fido_uaf_set_server_result_ptr + .asFunction<_dart_fido_uaf_set_server_result>(); + + /// @brief Creates oauth2_request_h handle. + /// @details The handle must be freed via oauth2_request_destroy(). + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[out] handle The created oauth2_request handle, else NULL for error cases + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_create( + ffi.Pointer> handle, + ) { + return _oauth2_request_create( + handle, + ); + } + + late final _oauth2_request_create_ptr = + _lookup>( + 'oauth2_request_create'); + late final _dart_oauth2_request_create _oauth2_request_create = + _oauth2_request_create_ptr.asFunction<_dart_oauth2_request_create>(); + + /// @brief Destroys oauth2_request_h handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The oauth2_request handle to destory + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_destroy( + ffi.Pointer handle, + ) { + return _oauth2_request_destroy( + handle, + ); + } + + late final _oauth2_request_destroy_ptr = + _lookup>( + 'oauth2_request_destroy'); + late final _dart_oauth2_request_destroy _oauth2_request_destroy = + _oauth2_request_destroy_ptr.asFunction<_dart_oauth2_request_destroy>(); + + /// @brief Sets authorization end point URL. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] url The url + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_set_auth_end_point_url( + ffi.Pointer handle, + ffi.Pointer url, + ) { + return _oauth2_request_set_auth_end_point_url( + handle, + url, + ); + } + + late final _oauth2_request_set_auth_end_point_url_ptr = + _lookup>( + 'oauth2_request_set_auth_end_point_url'); + late final _dart_oauth2_request_set_auth_end_point_url + _oauth2_request_set_auth_end_point_url = + _oauth2_request_set_auth_end_point_url_ptr + .asFunction<_dart_oauth2_request_set_auth_end_point_url>(); + + /// @brief Sets access token end point URL. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] url The url + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_set_token_end_point_url( + ffi.Pointer handle, + ffi.Pointer url, + ) { + return _oauth2_request_set_token_end_point_url( + handle, + url, + ); + } + + late final _oauth2_request_set_token_end_point_url_ptr = + _lookup>( + 'oauth2_request_set_token_end_point_url'); + late final _dart_oauth2_request_set_token_end_point_url + _oauth2_request_set_token_end_point_url = + _oauth2_request_set_token_end_point_url_ptr + .asFunction<_dart_oauth2_request_set_token_end_point_url>(); + + /// @brief Sets redirection URL. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] url The url + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_set_redirection_url( + ffi.Pointer handle, + ffi.Pointer url, + ) { + return _oauth2_request_set_redirection_url( + handle, + url, + ); + } + + late final _oauth2_request_set_redirection_url_ptr = + _lookup>( + 'oauth2_request_set_redirection_url'); + late final _dart_oauth2_request_set_redirection_url + _oauth2_request_set_redirection_url = + _oauth2_request_set_redirection_url_ptr + .asFunction<_dart_oauth2_request_set_redirection_url>(); + + /// @brief Sets refresh token end point URL. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] url The url + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_set_refresh_token_url( + ffi.Pointer handle, + ffi.Pointer url, + ) { + return _oauth2_request_set_refresh_token_url( + handle, + url, + ); + } + + late final _oauth2_request_set_refresh_token_url_ptr = + _lookup>( + 'oauth2_request_set_refresh_token_url'); + late final _dart_oauth2_request_set_refresh_token_url + _oauth2_request_set_refresh_token_url = + _oauth2_request_set_refresh_token_url_ptr + .asFunction<_dart_oauth2_request_set_refresh_token_url>(); + + /// @brief Sets refresh token. Used mostly while using oauth2_manager_refresh_access_token(). + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] refresh_token The refresh token string + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_set_refresh_token( + ffi.Pointer handle, + ffi.Pointer refresh_token, + ) { + return _oauth2_request_set_refresh_token( + handle, + refresh_token, + ); + } + + late final _oauth2_request_set_refresh_token_ptr = + _lookup>( + 'oauth2_request_set_refresh_token'); + late final _dart_oauth2_request_set_refresh_token + _oauth2_request_set_refresh_token = _oauth2_request_set_refresh_token_ptr + .asFunction<_dart_oauth2_request_set_refresh_token>(); + + /// @brief Sets response type. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] response_type The response type + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_set_response_type( + ffi.Pointer handle, + int response_type, + ) { + return _oauth2_request_set_response_type( + handle, + response_type, + ); + } + + late final _oauth2_request_set_response_type_ptr = + _lookup>( + 'oauth2_request_set_response_type'); + late final _dart_oauth2_request_set_response_type + _oauth2_request_set_response_type = _oauth2_request_set_response_type_ptr + .asFunction<_dart_oauth2_request_set_response_type>(); + + /// @brief Sets client id. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] client_id The client id + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_set_client_id( + ffi.Pointer handle, + ffi.Pointer client_id, + ) { + return _oauth2_request_set_client_id( + handle, + client_id, + ); + } + + late final _oauth2_request_set_client_id_ptr = + _lookup>( + 'oauth2_request_set_client_id'); + late final _dart_oauth2_request_set_client_id _oauth2_request_set_client_id = + _oauth2_request_set_client_id_ptr + .asFunction<_dart_oauth2_request_set_client_id>(); + + /// @brief Sets client secret. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] client_secret The secret + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_set_client_secret( + ffi.Pointer handle, + ffi.Pointer client_secret, + ) { + return _oauth2_request_set_client_secret( + handle, + client_secret, + ); + } + + late final _oauth2_request_set_client_secret_ptr = + _lookup>( + 'oauth2_request_set_client_secret'); + late final _dart_oauth2_request_set_client_secret + _oauth2_request_set_client_secret = _oauth2_request_set_client_secret_ptr + .asFunction<_dart_oauth2_request_set_client_secret>(); + + /// @brief Sets client authentication type. Default is OAUTH2_CLIENT_AUTHENTICATION_TYPE_BASIC. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks Facebook and Google does not support HTTP Basic Authentication, instead they require client credentials to be sent via request body.\n + /// So application must set #OAUTH2_CLIENT_AUTHENTICATION_TYPE_REQUEST_BODY for them. + /// + /// @param[in] handle The request handle + /// @param[in] client_auth_type The client authentication type + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_set_client_authentication_type( + ffi.Pointer handle, + int client_auth_type, + ) { + return _oauth2_request_set_client_authentication_type( + handle, + client_auth_type, + ); + } + + late final _oauth2_request_set_client_authentication_type_ptr = _lookup< + ffi.NativeFunction<_c_oauth2_request_set_client_authentication_type>>( + 'oauth2_request_set_client_authentication_type'); + late final _dart_oauth2_request_set_client_authentication_type + _oauth2_request_set_client_authentication_type = + _oauth2_request_set_client_authentication_type_ptr + .asFunction<_dart_oauth2_request_set_client_authentication_type>(); + + /// @brief Sets scope. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] scope The scope + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_set_scope( + ffi.Pointer handle, + ffi.Pointer scope, + ) { + return _oauth2_request_set_scope( + handle, + scope, + ); + } + + late final _oauth2_request_set_scope_ptr = + _lookup>( + 'oauth2_request_set_scope'); + late final _dart_oauth2_request_set_scope _oauth2_request_set_scope = + _oauth2_request_set_scope_ptr + .asFunction<_dart_oauth2_request_set_scope>(); + + /// @brief Sets state. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] state The state + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_set_state( + ffi.Pointer handle, + ffi.Pointer state, + ) { + return _oauth2_request_set_state( + handle, + state, + ); + } + + late final _oauth2_request_set_state_ptr = + _lookup>( + 'oauth2_request_set_state'); + late final _dart_oauth2_request_set_state _oauth2_request_set_state = + _oauth2_request_set_state_ptr + .asFunction<_dart_oauth2_request_set_state>(); + + /// @brief Sets grant type. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] grant_type The grant type + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_set_grant_type( + ffi.Pointer handle, + int grant_type, + ) { + return _oauth2_request_set_grant_type( + handle, + grant_type, + ); + } + + late final _oauth2_request_set_grant_type_ptr = + _lookup>( + 'oauth2_request_set_grant_type'); + late final _dart_oauth2_request_set_grant_type + _oauth2_request_set_grant_type = _oauth2_request_set_grant_type_ptr + .asFunction<_dart_oauth2_request_set_grant_type>(); + + /// @brief Sets authorization code. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] code The authorization code + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + /// + /// @see oauth2_response_get_authorization_code() + int oauth2_request_set_authorization_code( + ffi.Pointer handle, + ffi.Pointer code, + ) { + return _oauth2_request_set_authorization_code( + handle, + code, + ); + } + + late final _oauth2_request_set_authorization_code_ptr = + _lookup>( + 'oauth2_request_set_authorization_code'); + late final _dart_oauth2_request_set_authorization_code + _oauth2_request_set_authorization_code = + _oauth2_request_set_authorization_code_ptr + .asFunction<_dart_oauth2_request_set_authorization_code>(); + + /// @brief Sets user name. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] user_name The user name + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_set_user_name( + ffi.Pointer handle, + ffi.Pointer user_name, + ) { + return _oauth2_request_set_user_name( + handle, + user_name, + ); + } + + late final _oauth2_request_set_user_name_ptr = + _lookup>( + 'oauth2_request_set_user_name'); + late final _dart_oauth2_request_set_user_name _oauth2_request_set_user_name = + _oauth2_request_set_user_name_ptr + .asFunction<_dart_oauth2_request_set_user_name>(); + + /// @brief Sets password. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] password The password + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_set_password( + ffi.Pointer handle, + ffi.Pointer password, + ) { + return _oauth2_request_set_password( + handle, + password, + ); + } + + late final _oauth2_request_set_password_ptr = + _lookup>( + 'oauth2_request_set_password'); + late final _dart_oauth2_request_set_password _oauth2_request_set_password = + _oauth2_request_set_password_ptr + .asFunction<_dart_oauth2_request_set_password>(); + + /// @brief Adds custom key-value pair to the request. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The request handle + /// @param[in] key The key + /// @param[in] value The value + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + /// + /// @see oauth2_request_get_custom_data() + int oauth2_request_add_custom_data( + ffi.Pointer handle, + ffi.Pointer key, + ffi.Pointer value, + ) { + return _oauth2_request_add_custom_data( + handle, + key, + value, + ); + } + + late final _oauth2_request_add_custom_data_ptr = + _lookup>( + 'oauth2_request_add_custom_data'); + late final _dart_oauth2_request_add_custom_data + _oauth2_request_add_custom_data = _oauth2_request_add_custom_data_ptr + .asFunction<_dart_oauth2_request_add_custom_data>(); + + /// @brief Gets authorization end point URL. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a url using free(). + /// @param[in] handle The request handle + /// @param[out] url The url + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_auth_end_point_url( + ffi.Pointer handle, + ffi.Pointer> url, + ) { + return _oauth2_request_get_auth_end_point_url( + handle, + url, + ); + } + + late final _oauth2_request_get_auth_end_point_url_ptr = + _lookup>( + 'oauth2_request_get_auth_end_point_url'); + late final _dart_oauth2_request_get_auth_end_point_url + _oauth2_request_get_auth_end_point_url = + _oauth2_request_get_auth_end_point_url_ptr + .asFunction<_dart_oauth2_request_get_auth_end_point_url>(); + + /// @brief Gets access token end point URL. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a url using free(). + /// @param[in] handle The request handle + /// @param[out] url The url + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_token_end_point_url( + ffi.Pointer handle, + ffi.Pointer> url, + ) { + return _oauth2_request_get_token_end_point_url( + handle, + url, + ); + } + + late final _oauth2_request_get_token_end_point_url_ptr = + _lookup>( + 'oauth2_request_get_token_end_point_url'); + late final _dart_oauth2_request_get_token_end_point_url + _oauth2_request_get_token_end_point_url = + _oauth2_request_get_token_end_point_url_ptr + .asFunction<_dart_oauth2_request_get_token_end_point_url>(); + + /// @brief Gets redirection URL. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a url using free(). + /// @param[in] handle The request handle + /// @param[out] url The url + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_redirection_url( + ffi.Pointer handle, + ffi.Pointer> url, + ) { + return _oauth2_request_get_redirection_url( + handle, + url, + ); + } + + late final _oauth2_request_get_redirection_url_ptr = + _lookup>( + 'oauth2_request_get_redirection_url'); + late final _dart_oauth2_request_get_redirection_url + _oauth2_request_get_redirection_url = + _oauth2_request_get_redirection_url_ptr + .asFunction<_dart_oauth2_request_get_redirection_url>(); + + /// @brief Gets refresh token end point URL. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// + /// @remarks You must not release @a url using free(). + /// @param[in] handle The request handle + /// @param[out] url The url + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_refresh_token_url( + ffi.Pointer handle, + ffi.Pointer> url, + ) { + return _oauth2_request_get_refresh_token_url( + handle, + url, + ); + } + + late final _oauth2_request_get_refresh_token_url_ptr = + _lookup>( + 'oauth2_request_get_refresh_token_url'); + late final _dart_oauth2_request_get_refresh_token_url + _oauth2_request_get_refresh_token_url = + _oauth2_request_get_refresh_token_url_ptr + .asFunction<_dart_oauth2_request_get_refresh_token_url>(); + + /// @brief Gets refresh token. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a refresh_token using free(). + /// @param[in] handle The request handle + /// @param[out] refresh_token The refresh token + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_refresh_token( + ffi.Pointer handle, + ffi.Pointer> refresh_token, + ) { + return _oauth2_request_get_refresh_token( + handle, + refresh_token, + ); + } + + late final _oauth2_request_get_refresh_token_ptr = + _lookup>( + 'oauth2_request_get_refresh_token'); + late final _dart_oauth2_request_get_refresh_token + _oauth2_request_get_refresh_token = _oauth2_request_get_refresh_token_ptr + .asFunction<_dart_oauth2_request_get_refresh_token>(); + + /// @brief Gets response type. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not free response_type + /// @param[in] handle The request handle + /// @param[out] response_type The respose type + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_response_type( + ffi.Pointer handle, + ffi.Pointer response_type, + ) { + return _oauth2_request_get_response_type( + handle, + response_type, + ); + } + + late final _oauth2_request_get_response_type_ptr = + _lookup>( + 'oauth2_request_get_response_type'); + late final _dart_oauth2_request_get_response_type + _oauth2_request_get_response_type = _oauth2_request_get_response_type_ptr + .asFunction<_dart_oauth2_request_get_response_type>(); + + /// @brief Gets client id. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a client_id using free(). + /// @param[in] handle The request handle + /// @param[out] client_id The client id + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_client_id( + ffi.Pointer handle, + ffi.Pointer> client_id, + ) { + return _oauth2_request_get_client_id( + handle, + client_id, + ); + } + + late final _oauth2_request_get_client_id_ptr = + _lookup>( + 'oauth2_request_get_client_id'); + late final _dart_oauth2_request_get_client_id _oauth2_request_get_client_id = + _oauth2_request_get_client_id_ptr + .asFunction<_dart_oauth2_request_get_client_id>(); + + /// @brief Gets client secret. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a client_secret using free(). + /// @param[in] handle The request handle + /// @param[out] client_secret The client_secret + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_client_secret( + ffi.Pointer handle, + ffi.Pointer> client_secret, + ) { + return _oauth2_request_get_client_secret( + handle, + client_secret, + ); + } + + late final _oauth2_request_get_client_secret_ptr = + _lookup>( + 'oauth2_request_get_client_secret'); + late final _dart_oauth2_request_get_client_secret + _oauth2_request_get_client_secret = _oauth2_request_get_client_secret_ptr + .asFunction<_dart_oauth2_request_get_client_secret>(); + + /// @brief Gets scope. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a scope using free(). + /// @param[in] handle The request handle + /// @param[out] scope The scope + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_scope( + ffi.Pointer handle, + ffi.Pointer> scope, + ) { + return _oauth2_request_get_scope( + handle, + scope, + ); + } + + late final _oauth2_request_get_scope_ptr = + _lookup>( + 'oauth2_request_get_scope'); + late final _dart_oauth2_request_get_scope _oauth2_request_get_scope = + _oauth2_request_get_scope_ptr + .asFunction<_dart_oauth2_request_get_scope>(); + + /// @brief Gets state. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a state using free(). + /// @param[in] handle The request handle + /// @param[out] state The state + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_state( + ffi.Pointer handle, + ffi.Pointer> state, + ) { + return _oauth2_request_get_state( + handle, + state, + ); + } + + late final _oauth2_request_get_state_ptr = + _lookup>( + 'oauth2_request_get_state'); + late final _dart_oauth2_request_get_state _oauth2_request_get_state = + _oauth2_request_get_state_ptr + .asFunction<_dart_oauth2_request_get_state>(); + + /// @brief Gets grant type. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a grant_type using free(). + /// @param[in] handle The request handle + /// @param[out] grant_type The grant type + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_grant_type( + ffi.Pointer handle, + ffi.Pointer grant_type, + ) { + return _oauth2_request_get_grant_type( + handle, + grant_type, + ); + } + + late final _oauth2_request_get_grant_type_ptr = + _lookup>( + 'oauth2_request_get_grant_type'); + late final _dart_oauth2_request_get_grant_type + _oauth2_request_get_grant_type = _oauth2_request_get_grant_type_ptr + .asFunction<_dart_oauth2_request_get_grant_type>(); + + /// @brief Gets authorization code. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a code using free(). + /// @param[in] handle The request handle. + /// @param[out] code The code. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_authorization_code( + ffi.Pointer handle, + ffi.Pointer> code, + ) { + return _oauth2_request_get_authorization_code( + handle, + code, + ); + } + + late final _oauth2_request_get_authorization_code_ptr = + _lookup>( + 'oauth2_request_get_authorization_code'); + late final _dart_oauth2_request_get_authorization_code + _oauth2_request_get_authorization_code = + _oauth2_request_get_authorization_code_ptr + .asFunction<_dart_oauth2_request_get_authorization_code>(); + + /// @brief Gets user name. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a user_name using free(). + /// @param[in] handle The request handle + /// @param[out] user_name The user name + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_user_name( + ffi.Pointer handle, + ffi.Pointer> user_name, + ) { + return _oauth2_request_get_user_name( + handle, + user_name, + ); + } + + late final _oauth2_request_get_user_name_ptr = + _lookup>( + 'oauth2_request_get_user_name'); + late final _dart_oauth2_request_get_user_name _oauth2_request_get_user_name = + _oauth2_request_get_user_name_ptr + .asFunction<_dart_oauth2_request_get_user_name>(); + + /// @brief Gets password. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a password using free(). + /// @param[in] handle The request handle + /// @param[out] password The password + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_password( + ffi.Pointer handle, + ffi.Pointer> password, + ) { + return _oauth2_request_get_password( + handle, + password, + ); + } + + late final _oauth2_request_get_password_ptr = + _lookup>( + 'oauth2_request_get_password'); + late final _dart_oauth2_request_get_password _oauth2_request_get_password = + _oauth2_request_get_password_ptr + .asFunction<_dart_oauth2_request_get_password>(); + + /// @brief Gets the custom value. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a custom_value using free(). + /// @param[in] handle The request handle + /// @param[in] custom_key The custom key + /// @param[out] custom_value The custom value + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_request_get_custom_data( + ffi.Pointer handle, + ffi.Pointer custom_key, + ffi.Pointer> custom_value, + ) { + return _oauth2_request_get_custom_data( + handle, + custom_key, + custom_value, + ); + } + + late final _oauth2_request_get_custom_data_ptr = + _lookup>( + 'oauth2_request_get_custom_data'); + late final _dart_oauth2_request_get_custom_data + _oauth2_request_get_custom_data = _oauth2_request_get_custom_data_ptr + .asFunction<_dart_oauth2_request_get_custom_data>(); + + /// @brief Gets error code. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a server_error_code and @a platform_error_code using free(). + /// @param[in] handle The error handle + /// @param[out] server_error_code Error code (if any) returned by the server + /// @param[out] platform_error_code Tizen platform related error code (if any), value is of type #oauth2_error_e + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_error_get_code( + ffi.Pointer handle, + ffi.Pointer server_error_code, + ffi.Pointer platform_error_code, + ) { + return _oauth2_error_get_code( + handle, + server_error_code, + platform_error_code, + ); + } + + late final _oauth2_error_get_code_ptr = + _lookup>( + 'oauth2_error_get_code'); + late final _dart_oauth2_error_get_code _oauth2_error_get_code = + _oauth2_error_get_code_ptr.asFunction<_dart_oauth2_error_get_code>(); + + /// @brief Gets error description. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a description using free(). + /// @param[in] handle The error handle + /// @param[out] description The Error description + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_error_get_description( + ffi.Pointer handle, + ffi.Pointer> description, + ) { + return _oauth2_error_get_description( + handle, + description, + ); + } + + late final _oauth2_error_get_description_ptr = + _lookup>( + 'oauth2_error_get_description'); + late final _dart_oauth2_error_get_description _oauth2_error_get_description = + _oauth2_error_get_description_ptr + .asFunction<_dart_oauth2_error_get_description>(); + + /// @brief Gets error uri. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a uri using free(). + /// @param[in] handle The error handle + /// @param[out] uri The Error URI + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_error_get_uri( + ffi.Pointer handle, + ffi.Pointer> uri, + ) { + return _oauth2_error_get_uri( + handle, + uri, + ); + } + + late final _oauth2_error_get_uri_ptr = + _lookup>( + 'oauth2_error_get_uri'); + late final _dart_oauth2_error_get_uri _oauth2_error_get_uri = + _oauth2_error_get_uri_ptr.asFunction<_dart_oauth2_error_get_uri>(); + + /// @brief Gets the custom data. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a custom_value using free(). + /// @param[in] handle The error handle + /// @param[in] custom_key The custom key + /// @param[out] custom_value The custom value + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_error_get_custom_data( + ffi.Pointer handle, + ffi.Pointer custom_key, + ffi.Pointer> custom_value, + ) { + return _oauth2_error_get_custom_data( + handle, + custom_key, + custom_value, + ); + } + + late final _oauth2_error_get_custom_data_ptr = + _lookup>( + 'oauth2_error_get_custom_data'); + late final _dart_oauth2_error_get_custom_data _oauth2_error_get_custom_data = + _oauth2_error_get_custom_data_ptr + .asFunction<_dart_oauth2_error_get_custom_data>(); + + /// @brief Destroys the received handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The response handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_response_destroy( + ffi.Pointer handle, + ) { + return _oauth2_response_destroy( + handle, + ); + } + + late final _oauth2_response_destroy_ptr = + _lookup>( + 'oauth2_response_destroy'); + late final _dart_oauth2_response_destroy _oauth2_response_destroy = + _oauth2_response_destroy_ptr.asFunction<_dart_oauth2_response_destroy>(); + + /// @brief Gets the authorization code. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a code using free(). + /// @param[in] handle The response handle + /// @param[out] code The code. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + /// + /// @see oauth2_request_set_authorization_code() + int oauth2_response_get_authorization_code( + ffi.Pointer handle, + ffi.Pointer> code, + ) { + return _oauth2_response_get_authorization_code( + handle, + code, + ); + } + + late final _oauth2_response_get_authorization_code_ptr = + _lookup>( + 'oauth2_response_get_authorization_code'); + late final _dart_oauth2_response_get_authorization_code + _oauth2_response_get_authorization_code = + _oauth2_response_get_authorization_code_ptr + .asFunction<_dart_oauth2_response_get_authorization_code>(); + + /// @brief Gets state. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a state using free(). + /// @param[in] handle The response handle + /// @param[out] state The state. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_response_get_state( + ffi.Pointer handle, + ffi.Pointer> state, + ) { + return _oauth2_response_get_state( + handle, + state, + ); + } + + late final _oauth2_response_get_state_ptr = + _lookup>( + 'oauth2_response_get_state'); + late final _dart_oauth2_response_get_state _oauth2_response_get_state = + _oauth2_response_get_state_ptr + .asFunction<_dart_oauth2_response_get_state>(); + + /// @brief Gets access token. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a access_token using free(). + /// @param[in] handle The response handle + /// @param[out] access_token The access token + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_response_get_access_token( + ffi.Pointer handle, + ffi.Pointer> access_token, + ) { + return _oauth2_response_get_access_token( + handle, + access_token, + ); + } + + late final _oauth2_response_get_access_token_ptr = + _lookup>( + 'oauth2_response_get_access_token'); + late final _dart_oauth2_response_get_access_token + _oauth2_response_get_access_token = _oauth2_response_get_access_token_ptr + .asFunction<_dart_oauth2_response_get_access_token>(); + + /// @brief Gets token type. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a token_type using free(). + /// @param[in] handle The response handle + /// @param[out] token_type The token type + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_response_get_token_type( + ffi.Pointer handle, + ffi.Pointer> token_type, + ) { + return _oauth2_response_get_token_type( + handle, + token_type, + ); + } + + late final _oauth2_response_get_token_type_ptr = + _lookup>( + 'oauth2_response_get_token_type'); + late final _dart_oauth2_response_get_token_type + _oauth2_response_get_token_type = _oauth2_response_get_token_type_ptr + .asFunction<_dart_oauth2_response_get_token_type>(); + + /// @brief Gets expiry time. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a expires_in using free(). + /// @param[in] handle The response handle + /// @param[out] expires_in Expiry value + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_response_get_expires_in( + ffi.Pointer handle, + ffi.Pointer expires_in, + ) { + return _oauth2_response_get_expires_in( + handle, + expires_in, + ); + } + + late final _oauth2_response_get_expires_in_ptr = + _lookup>( + 'oauth2_response_get_expires_in'); + late final _dart_oauth2_response_get_expires_in + _oauth2_response_get_expires_in = _oauth2_response_get_expires_in_ptr + .asFunction<_dart_oauth2_response_get_expires_in>(); + + /// @brief Gets refresh token. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a refresh_token using free(). + /// @param[in] handle The response handle + /// @param[out] refresh_token The refresh token + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_response_get_refresh_token( + ffi.Pointer handle, + ffi.Pointer> refresh_token, + ) { + return _oauth2_response_get_refresh_token( + handle, + refresh_token, + ); + } + + late final _oauth2_response_get_refresh_token_ptr = + _lookup>( + 'oauth2_response_get_refresh_token'); + late final _dart_oauth2_response_get_refresh_token + _oauth2_response_get_refresh_token = + _oauth2_response_get_refresh_token_ptr + .asFunction<_dart_oauth2_response_get_refresh_token>(); + + /// @brief Gets scope. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a scope using free(). + /// @param[in] handle The response handle + /// @param[out] scope The scope + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_response_get_scope( + ffi.Pointer handle, + ffi.Pointer> scope, + ) { + return _oauth2_response_get_scope( + handle, + scope, + ); + } + + late final _oauth2_response_get_scope_ptr = + _lookup>( + 'oauth2_response_get_scope'); + late final _dart_oauth2_response_get_scope _oauth2_response_get_scope = + _oauth2_response_get_scope_ptr + .asFunction<_dart_oauth2_response_get_scope>(); + + /// @brief Gets error. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a error using free(). + /// @param[in] handle The response handle + /// @param[out] error The error structure + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + /// + /// @see oauth2_error_h + int oauth2_response_get_error( + ffi.Pointer handle, + ffi.Pointer> error, + ) { + return _oauth2_response_get_error( + handle, + error, + ); + } + + late final _oauth2_response_get_error_ptr = + _lookup>( + 'oauth2_response_get_error'); + late final _dart_oauth2_response_get_error _oauth2_response_get_error = + _oauth2_response_get_error_ptr + .asFunction<_dart_oauth2_response_get_error>(); + + /// @brief Gets the custom data. + /// @details Some service providers send additional keys not specified in OAuth 2.0 RFC. To get those additional fields this API needs to be used. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must not release @a custom_value using free(). + /// @param[in] handle The response handle + /// @param[in] custom_key The custom key + /// @param[out] custom_value The custom value + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_VALUE_NOT_FOUND Value not found + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_response_get_custom_data( + ffi.Pointer handle, + ffi.Pointer custom_key, + ffi.Pointer> custom_value, + ) { + return _oauth2_response_get_custom_data( + handle, + custom_key, + custom_value, + ); + } + + late final _oauth2_response_get_custom_data_ptr = + _lookup>( + 'oauth2_response_get_custom_data'); + late final _dart_oauth2_response_get_custom_data + _oauth2_response_get_custom_data = _oauth2_response_get_custom_data_ptr + .asFunction<_dart_oauth2_response_get_custom_data>(); + + /// @brief Creates oauth2_manager_h handle. + /// @remarks The @a handle must be released using oauth2_manager_destroy(). + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[out] handle The created handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + /// + /// @see oauth2_manager_destroy() + int oauth2_manager_create( + ffi.Pointer> handle, + ) { + return _oauth2_manager_create( + handle, + ); + } + + late final _oauth2_manager_create_ptr = + _lookup>( + 'oauth2_manager_create'); + late final _dart_oauth2_manager_create _oauth2_manager_create = + _oauth2_manager_create_ptr.asFunction<_dart_oauth2_manager_create>(); + + /// @brief Destroys oauth2_manager_h handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The oauth2 manager handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + int oauth2_manager_destroy( + ffi.Pointer handle, + ) { + return _oauth2_manager_destroy( + handle, + ); + } + + late final _oauth2_manager_destroy_ptr = + _lookup>( + 'oauth2_manager_destroy'); + late final _dart_oauth2_manager_destroy _oauth2_manager_destroy = + _oauth2_manager_destroy_ptr.asFunction<_dart_oauth2_manager_destroy>(); + + /// @brief Request OAuth 2.0 access token. + /// @details The response is delivered via oauth2_token_cb(). + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks The "internet" privilege is required to call this API. Note, only one pending request is allowed. + /// + /// @param[in] handle The oauth2 manager handle. + /// @param[in] request The request handle. + /// @param[in] callback The callback to receive response. + /// @param[in] user_data The user data to be passed to the callback function. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of memory. + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid input parameter(s) passed. + /// @retval #OAUTH2_ERROR_ALREADY_IN_PROGRESS The previous request is already in progress. + /// @retval #OAUTH2_ERROR_PERMISSION_DENIED Permission denied. + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported. + /// @retval #OAUTH2_ERROR_PARSE_FAILED Parsing failed. + /// @retval #OAUTH2_ERROR_NETWORK_ERROR Network Error. + /// @retval #OAUTH2_ERROR_UNKNOWN Unknown system error. + /// + /// @see oauth2_token_cb() + /// @see oauth2_manager_create() + /// @see oauth2_request_create() + int oauth2_manager_request_token( + ffi.Pointer handle, + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _oauth2_manager_request_token( + handle, + request, + callback, + user_data, + ); + } + + late final _oauth2_manager_request_token_ptr = + _lookup>( + 'oauth2_manager_request_token'); + late final _dart_oauth2_manager_request_token _oauth2_manager_request_token = + _oauth2_manager_request_token_ptr + .asFunction<_dart_oauth2_manager_request_token>(); + + /// @brief Request authorization grant. + /// @details The response is delivered via oauth2_auth_grant_cb(). + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks The "internet" privilege is required to call this API. Note, only one pending request is allowed at a time. + /// + /// @param[in] handle The oauth2_manager handle. + /// @param[in] request The request handle. + /// @param[in] callback The application callback. + /// @param[in] user_data The user data to be passed to the callback function. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of memory. + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid input parameter(s) passed. + /// @retval #OAUTH2_ERROR_ALREADY_IN_PROGRESS The previous request is already in progress. + /// @retval #OAUTH2_ERROR_PERMISSION_DENIED Permission denied. + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported. + /// @retval #OAUTH2_ERROR_PARSE_FAILED Parsing failed. + /// @retval #OAUTH2_ERROR_NETWORK_ERROR Network Error. + /// @retval #OAUTH2_ERROR_UNKNOWN Unknown system error. + /// + /// @see oauth2_auth_grant_cb() + /// @see oauth2_manager_create() + /// @see oauth2_request_create() + int oauth2_manager_request_authorization_grant( + ffi.Pointer handle, + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _oauth2_manager_request_authorization_grant( + handle, + request, + callback, + user_data, + ); + } + + late final _oauth2_manager_request_authorization_grant_ptr = _lookup< + ffi.NativeFunction<_c_oauth2_manager_request_authorization_grant>>( + 'oauth2_manager_request_authorization_grant'); + late final _dart_oauth2_manager_request_authorization_grant + _oauth2_manager_request_authorization_grant = + _oauth2_manager_request_authorization_grant_ptr + .asFunction<_dart_oauth2_manager_request_authorization_grant>(); + + /// @brief Requests an access token. + /// @details The response is delivered via oauth2_access_token_cb() callback. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks The "internet" privilege is required to call this API. Note, only one pending request is allowed at a time. + /// + /// @param[in] handle The oauth2_manager handle. + /// @param[in] request The request handle. + /// @param[in] callback The application callback. + /// @param[in] user_data The user data to be passed to the callback function. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of memory. + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid input parameter(s) passed. + /// @retval #OAUTH2_ERROR_ALREADY_IN_PROGRESS The previous request is already in progress. + /// @retval #OAUTH2_ERROR_PERMISSION_DENIED Permission denied. + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported. + /// @retval #OAUTH2_ERROR_PARSE_FAILED Parsing failed. + /// @retval #OAUTH2_ERROR_NETWORK_ERROR Network Error. + /// @retval #OAUTH2_ERROR_UNKNOWN Unknown system error. + /// + /// @see oauth2_access_token_cb() + /// @see oauth2_manager_create() + /// @see oauth2_request_create() + int oauth2_manager_request_access_token( + ffi.Pointer handle, + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _oauth2_manager_request_access_token( + handle, + request, + callback, + user_data, + ); + } + + late final _oauth2_manager_request_access_token_ptr = + _lookup>( + 'oauth2_manager_request_access_token'); + late final _dart_oauth2_manager_request_access_token + _oauth2_manager_request_access_token = + _oauth2_manager_request_access_token_ptr + .asFunction<_dart_oauth2_manager_request_access_token>(); + + /// @brief Requests a refresh token. + /// @details The response is delivered via oauth2_refresh_token_cb() callback. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks The "internet" privilege is required to call this API. Note, only one pending request is allowed at a time. + /// + /// @param[in] handle The oauth2 manager handle. + /// @param[in] request The request handle. + /// @param[in] callback The application callback. + /// @param[in] user_data The user data to be passed to the callback function. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of memory. + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid input parameter(s) passed. + /// @retval #OAUTH2_ERROR_ALREADY_IN_PROGRESS The previous request is already in progress. + /// @retval #OAUTH2_ERROR_PERMISSION_DENIED Permission denied. + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported. + /// @retval #OAUTH2_ERROR_PARSE_FAILED Parsing failed. + /// @retval #OAUTH2_ERROR_NETWORK_ERROR Network Error. + /// @retval #OAUTH2_ERROR_UNKNOWN Unknown system error. + /// + /// @see oauth2_refresh_token_cb() + /// @see oauth2_manager_create() + /// @see oauth2_request_create() + int oauth2_manager_refresh_access_token( + ffi.Pointer handle, + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _oauth2_manager_refresh_access_token( + handle, + request, + callback, + user_data, + ); + } + + late final _oauth2_manager_refresh_access_token_ptr = + _lookup>( + 'oauth2_manager_refresh_access_token'); + late final _dart_oauth2_manager_refresh_access_token + _oauth2_manager_refresh_access_token = + _oauth2_manager_refresh_access_token_ptr + .asFunction<_dart_oauth2_manager_refresh_access_token>(); + + /// @brief Returns whether oauth2_manager related request is pending. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] handle The auth2 manager handle. + /// @retval false No pending request + /// @retval true There is pending request. + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported + bool oauth2_manager_is_request_in_progress( + ffi.Pointer handle, + ) { + return _oauth2_manager_is_request_in_progress( + handle, + ) != + 0; + } + + late final _oauth2_manager_is_request_in_progress_ptr = + _lookup>( + 'oauth2_manager_is_request_in_progress'); + late final _dart_oauth2_manager_is_request_in_progress + _oauth2_manager_is_request_in_progress = + _oauth2_manager_is_request_in_progress_ptr + .asFunction<_dart_oauth2_manager_is_request_in_progress>(); + + /// @brief Clears the cookies. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// + /// @param[in] handle The oauth2 manager handle. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_PERMISSION_DENIED Permission denied. + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported. + int oauth2_manager_clear_cookies( + ffi.Pointer handle, + ) { + return _oauth2_manager_clear_cookies( + handle, + ); + } + + late final _oauth2_manager_clear_cookies_ptr = + _lookup>( + 'oauth2_manager_clear_cookies'); + late final _dart_oauth2_manager_clear_cookies _oauth2_manager_clear_cookies = + _oauth2_manager_clear_cookies_ptr + .asFunction<_dart_oauth2_manager_clear_cookies>(); + + /// @brief Clears the cache. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// + /// @param[in] handle The oauth2 manager handle. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #OAUTH2_ERROR_NONE Successful + /// @retval #OAUTH2_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #OAUTH2_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #OAUTH2_ERROR_PERMISSION_DENIED Permission denied. + /// @retval #OAUTH2_ERROR_NOT_SUPPORTED Not supported. + int oauth2_manager_clear_cache( + ffi.Pointer handle, + ) { + return _oauth2_manager_clear_cache( + handle, + ); + } + + late final _oauth2_manager_clear_cache_ptr = + _lookup>( + 'oauth2_manager_clear_cache'); + late final _dart_oauth2_manager_clear_cache _oauth2_manager_clear_cache = + _oauth2_manager_clear_cache_ptr + .asFunction<_dart_oauth2_manager_clear_cache>(); + + /// @brief Requests Sync Manager to perform one time sync operation. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] account An account handle on which sync operation was requested or @c NULL in the case of accountless sync operation + /// @param[in] sync_job_name A string representing a sync job which will be operated just one time + /// @param[in] sync_option sync options determine an way to operate sync job and can be used as ORing. + /// @param[in] sync_job_user_data User data which contains additional information related registered sync job or it can be @c NULL in the case of requesting without sync_job_user_data + /// @param[out] sync_job_id A unique value which can manage sync jobs. The number of sync job id is limited as less than a hundred. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SYNC_ERROR_NONE Successful + /// @retval #SYNC_ERROR_NOT_SUPPORTED Not supported + /// @retval #SYNC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYNC_ERROR_QUOTA_EXCEEDED Quota exceeded + /// @retval #SYNC_ERROR_SYSTEM Internal system error + /// @retval #SYNC_ERROR_SYNC_ADAPTER_NOT_FOUND Sync adapter is not registered + /// + /// @pre This function requires calling below Sync Adapter's APIs by a service application before it is called. + /// @pre Call sync_adapter_set_callbacks() before calling this function. + /// + /// @see sync_manager_remove_sync_job() + /// @see sync_option_e + int sync_manager_on_demand_sync_job( + ffi.Pointer account, + ffi.Pointer sync_job_name, + int sync_option, + ffi.Pointer sync_job_user_data, + ffi.Pointer sync_job_id, + ) { + return _sync_manager_on_demand_sync_job( + account, + sync_job_name, + sync_option, + sync_job_user_data, + sync_job_id, + ); + } + + late final _sync_manager_on_demand_sync_job_ptr = + _lookup>( + 'sync_manager_on_demand_sync_job'); + late final _dart_sync_manager_on_demand_sync_job + _sync_manager_on_demand_sync_job = _sync_manager_on_demand_sync_job_ptr + .asFunction<_dart_sync_manager_on_demand_sync_job>(); + + /// @brief Requests Sync Manager to perform periodic sync operations. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// + /// @remarks Sync job can be added with its name. In the case of adding periodic sync job with same sync job, it will replace previous setting with new one. + /// + /// @param[in] account An account handle on which sync operation was requested or @c NULL in the case of accountless sync operation + /// @param[in] sync_job_name A string representing a sync job which will be operated with period interval + /// @param[in] sync_period Determines time interval of periodic sync. The periodic sync operation can be triggered in that interval, but it does not guarantee exact time. The minimum value is 30 minutes. + /// @param[in] sync_option sync options determine an way to operate sync job and can be used as ORing. + /// @param[in] sync_job_user_data User data which contains additional information related registered sync job or it can be @c NULL in the case of requesting without sync_job_user_data + /// @param[out] sync_job_id A unique value which can manage sync jobs. The number of sync job id is limited as less than a hundred. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SYNC_ERROR_NONE Successful + /// @retval #SYNC_ERROR_NOT_SUPPORTED Not supported + /// @retval #SYNC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYNC_ERROR_QUOTA_EXCEEDED Quota exceeded + /// @retval #SYNC_ERROR_SYSTEM Internal system error + /// @retval #SYNC_ERROR_SYNC_ADAPTER_NOT_FOUND Sync adapter is not registered + /// + /// @pre This function requires calling below Sync Adapter's APIs by a service application before it is called. + /// @pre Call sync_adapter_set_callbacks() before calling this function. + /// + /// @see sync_manager_remove_sync_job() + /// @see sync_option_e + /// @see sync_period_e + int sync_manager_add_periodic_sync_job( + ffi.Pointer account, + ffi.Pointer sync_job_name, + int sync_period, + int sync_option, + ffi.Pointer sync_job_user_data, + ffi.Pointer sync_job_id, + ) { + return _sync_manager_add_periodic_sync_job( + account, + sync_job_name, + sync_period, + sync_option, + sync_job_user_data, + sync_job_id, + ); + } + + late final _sync_manager_add_periodic_sync_job_ptr = + _lookup>( + 'sync_manager_add_periodic_sync_job'); + late final _dart_sync_manager_add_periodic_sync_job + _sync_manager_add_periodic_sync_job = + _sync_manager_add_periodic_sync_job_ptr + .asFunction<_dart_sync_manager_add_periodic_sync_job>(); + + /// @brief Requests Sync Manager to perform sync operations whenever corresponding DB changed. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.read since @if MOBILE 2.4 @endif + /// @privilege %http://tizen.org/privilege/contact.read + /// + /// @remarks Data change sync job can be added by using its capability. In the case of adding a sync job with same capability, it will replace previous setting with new one. \n\n + /// %http://tizen.org/privilege/calendar.read is needed to add data change sync job for receiving notification with @ref SYNC_SUPPORTS_CAPABILITY_CALENDAR. This capability is supported on Mobile profile only. \n\n since @if MOBILE 2.4 @endif + /// %http://tizen.org/privilege/contact.read is needed to add data change sync job for receiving notification with @ref SYNC_SUPPORTS_CAPABILITY_CONTACT. + /// + /// @param[in] account An account handle on which sync operation was requested or @c NULL in the case of accountless sync operation + /// @param[in] sync_capability A string representing a sync job which will be operated whenever data change of this capability + /// @param[in] sync_option sync options determine an way to operate sync job and can be used as ORing. + /// @param[in] sync_job_user_data User data which contains additional information related registered sync job or it can be @c NULL in the case of requesting without sync_job_user_data + /// @param[out] sync_job_id A unique value which can manage sync jobs. The number of sync job id is limited as less than a hundred. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SYNC_ERROR_NONE Successful + /// @retval #SYNC_ERROR_NOT_SUPPORTED Not supported + /// @retval #SYNC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYNC_ERROR_QUOTA_EXCEEDED Quota exceeded + /// @retval #SYNC_ERROR_SYSTEM Internal system error + /// @retval #SYNC_ERROR_SYNC_ADAPTER_NOT_FOUND Sync adapter is not registered + /// + /// @pre This function requires calling below Sync Adapter's APIs by a service application before it is called. + /// @pre Call sync_adapter_set_callbacks() before calling this function. + /// + /// @see sync_manager_remove_sync_job() + /// @see sync_option_e + int sync_manager_add_data_change_sync_job( + ffi.Pointer account, + ffi.Pointer sync_capability, + int sync_option, + ffi.Pointer sync_job_user_data, + ffi.Pointer sync_job_id, + ) { + return _sync_manager_add_data_change_sync_job( + account, + sync_capability, + sync_option, + sync_job_user_data, + sync_job_id, + ); + } + + late final _sync_manager_add_data_change_sync_job_ptr = + _lookup>( + 'sync_manager_add_data_change_sync_job'); + late final _dart_sync_manager_add_data_change_sync_job + _sync_manager_add_data_change_sync_job = + _sync_manager_add_data_change_sync_job_ptr + .asFunction<_dart_sync_manager_add_data_change_sync_job>(); + + /// @brief Requests Sync Manager to remove corresponding sync job id. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks sync_job_id can not be @c NULL. + /// + /// @param[in] sync_job_id A unique value of each sync job, it can be used to search specific sync job and remove it + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SYNC_ERROR_NONE Successful + /// @retval #SYNC_ERROR_NOT_SUPPORTED Not supported + /// @retval #SYNC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYNC_ERROR_SYSTEM Internal system error + /// + /// @pre This function requires calling at least one of the below Sync Manager's APIs before it is called. + /// @pre sync_manager_on_demand_sync_job() + /// @pre sync_manager_add_periodic_sync_job() + /// @pre sync_manager_add_data_change_sync_job() + /// + /// @see sync_manager_on_demand_sync_job() + /// @see sync_manager_add_periodic_sync_job() + /// @see sync_manager_add_data_change_sync_job() + int sync_manager_remove_sync_job( + int sync_job_id, + ) { + return _sync_manager_remove_sync_job( + sync_job_id, + ); + } + + late final _sync_manager_remove_sync_job_ptr = + _lookup>( + 'sync_manager_remove_sync_job'); + late final _dart_sync_manager_remove_sync_job _sync_manager_remove_sync_job = + _sync_manager_remove_sync_job_ptr + .asFunction<_dart_sync_manager_remove_sync_job>(); + + /// @brief Requests Sync Manager to query corresponding sync request. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] sync_job_cb A callback function for receiving the result of this API + /// @param[in] user_data User data which contains additional information related foreach job or @c NULL if do not want to transfer user data + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SYNC_ERROR_NONE Successful + /// @retval #SYNC_ERROR_NOT_SUPPORTED Not supported + /// @retval #SYNC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYNC_ERROR_SYSTEM Internal system error + /// + /// @pre This function requires calling at least one of the below Sync Manager's APIs before it is called. + /// @pre sync_manager_on_demand_sync_job() + /// @pre sync_manager_add_periodic_sync_job() + /// @pre sync_manager_add_data_change_sync_job() + /// + /// @see sync_manager_sync_job_cb() + /// @see sync_manager_on_demand_sync_job() + /// @see sync_manager_add_periodic_sync_job() + /// @see sync_manager_add_data_change_sync_job() + int sync_manager_foreach_sync_job( + ffi.Pointer> sync_job_cb, + ffi.Pointer user_data, + ) { + return _sync_manager_foreach_sync_job( + sync_job_cb, + user_data, + ); + } + + late final _sync_manager_foreach_sync_job_ptr = + _lookup>( + 'sync_manager_foreach_sync_job'); + late final _dart_sync_manager_foreach_sync_job + _sync_manager_foreach_sync_job = _sync_manager_foreach_sync_job_ptr + .asFunction<_dart_sync_manager_foreach_sync_job>(); + + /// @brief Sets client (Sync Adapter) callback functions + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks This API only can be called by a service application. And it can be set by only one service application per a package. + /// + /// @param[in] on_start_cb A callback function to be called by Sync Manager for performing sync operation + /// @param[in] on_cancel_cb A callback function to be called by Sync Manager for cancelling sync operation + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #SYNC_ERROR_NONE Successful + /// @retval #SYNC_ERROR_NOT_SUPPORTED Not supported + /// @retval #SYNC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #SYNC_ERROR_IO_ERROR I/O error + /// @retval #SYNC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYNC_ERROR_QUOTA_EXCEEDED Quota exceeded + /// @retval #SYNC_ERROR_SYSTEM System error + /// + /// @see sync_adapter_start_sync_cb() + /// @see sync_adapter_cancel_sync_cb() + /// @see sync_adapter_unset_callbacks() + int sync_adapter_set_callbacks( + ffi.Pointer> on_start_cb, + ffi.Pointer> on_cancel_cb, + ) { + return _sync_adapter_set_callbacks( + on_start_cb, + on_cancel_cb, + ); + } + + late final _sync_adapter_set_callbacks_ptr = + _lookup>( + 'sync_adapter_set_callbacks'); + late final _dart_sync_adapter_set_callbacks _sync_adapter_set_callbacks = + _sync_adapter_set_callbacks_ptr + .asFunction<_dart_sync_adapter_set_callbacks>(); + + /// @brief Unsets client (Sync Adapter) callback functions + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #SYNC_ERROR_NONE Successful + /// @retval #SYNC_ERROR_NOT_SUPPORTED Not supported + /// @retval #SYNC_ERROR_SYSTEM System error + /// + /// @pre Call sync_adapter_set_callbacks() before calling this function. + /// + /// @see sync_adapter_start_sync_cb() + /// @see sync_adapter_cancel_sync_cb() + /// @see sync_adapter_set_callbacks() + int sync_adapter_unset_callbacks() { + return _sync_adapter_unset_callbacks(); + } + + late final _sync_adapter_unset_callbacks_ptr = + _lookup>( + 'sync_adapter_unset_callbacks'); + late final _dart_sync_adapter_unset_callbacks _sync_adapter_unset_callbacks = + _sync_adapter_unset_callbacks_ptr + .asFunction<_dart_sync_adapter_unset_callbacks>(); + + /// @brief Creates an app_control handle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The @a app_control must be released using app_control_destroy(). + /// @param[out] app_control The app_control handle to be newly created on success + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see app_control_destroy() + int app_control_create( + ffi.Pointer> app_control, + ) { + return _app_control_create( + app_control, + ); + } + + late final _app_control_create_ptr = + _lookup>('app_control_create'); + late final _dart_app_control_create _app_control_create = + _app_control_create_ptr.asFunction<_dart_app_control_create>(); + + /// @brief Destroys the app_control handle and releases all its resources. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_control The app_control handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see app_control_create() + int app_control_destroy( + ffi.Pointer app_control, + ) { + return _app_control_destroy( + app_control, + ); + } + + late final _app_control_destroy_ptr = + _lookup>( + 'app_control_destroy'); + late final _dart_app_control_destroy _app_control_destroy = + _app_control_destroy_ptr.asFunction<_dart_app_control_destroy>(); + + /// @brief Sets the operation to be performed. + /// + /// @details The @a operation is the mandatory information for the launch request. + /// If the operation is not specified, #APP_CONTROL_OPERATION_DEFAULT is used for the launch request. + /// If the operation is #APP_CONTROL_OPERATION_DEFAULT, the package information is mandatory to explicitly launch the application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_control The app_control handle + /// @param[in] operation The operation to be performed (if the @a operation is @c NULL, it clears the previous value) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see app_control_get_operation() + /// @see APP_CONTROL_OPERATION_DEFAULT + /// @see APP_CONTROL_OPERATION_EDIT + /// @see APP_CONTROL_OPERATION_VIEW + /// @see APP_CONTROL_OPERATION_PICK + /// @see APP_CONTROL_OPERATION_CREATE_CONTENT + /// @see APP_CONTROL_OPERATION_CALL + /// @see APP_CONTROL_OPERATION_SEND + /// @see APP_CONTROL_OPERATION_SEND_TEXT + /// @see APP_CONTROL_OPERATION_DIAL + /// @see APP_CONTROL_OPERATION_SEARCH + int app_control_set_operation( + ffi.Pointer app_control, + ffi.Pointer operation, + ) { + return _app_control_set_operation( + app_control, + operation, + ); + } + + late final _app_control_set_operation_ptr = + _lookup>( + 'app_control_set_operation'); + late final _dart_app_control_set_operation _app_control_set_operation = + _app_control_set_operation_ptr + .asFunction<_dart_app_control_set_operation>(); + + /// @brief Gets the operation to be performed. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The @a operation must be released using free(). + /// @param[in] app_control The app_control handle + /// @param[out] operation The operation to be performed + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see app_control_set_operation() + int app_control_get_operation( + ffi.Pointer app_control, + ffi.Pointer> operation, + ) { + return _app_control_get_operation( + app_control, + operation, + ); + } + + late final _app_control_get_operation_ptr = + _lookup>( + 'app_control_get_operation'); + late final _dart_app_control_get_operation _app_control_get_operation = + _app_control_get_operation_ptr + .asFunction<_dart_app_control_get_operation>(); + + /// @brief Sets the URI of the data. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks Since Tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif, if the parameter @a uri is started with 'file://' and it is a regular file in this application's data path which can be obtained by calling the app_get_data_path() function, it will be shared to the callee application. Framework will grant a temporary permission to the callee application for this file and revoke it when the callee application is terminated. The callee application can just read it. + /// @param[in] app_control The app_control handle + /// @param[in] uri The URI of the data this app_control is operating on (if the @a uri is @c NULL, it clears the previous value) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see app_control_get_uri() + int app_control_set_uri( + ffi.Pointer app_control, + ffi.Pointer uri, + ) { + return _app_control_set_uri( + app_control, + uri, + ); + } + + late final _app_control_set_uri_ptr = + _lookup>( + 'app_control_set_uri'); + late final _dart_app_control_set_uri _app_control_set_uri = + _app_control_set_uri_ptr.asFunction<_dart_app_control_set_uri>(); + + /// @brief Gets the URI of the data. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The @a uri must be released using free(). + /// @param[in] app_control The app_control handle + /// @param[out] uri The URI of the data this app_control is operating on + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see app_control_set_uri() + int app_control_get_uri( + ffi.Pointer app_control, + ffi.Pointer> uri, + ) { + return _app_control_get_uri( + app_control, + uri, + ); + } + + late final _app_control_get_uri_ptr = + _lookup>( + 'app_control_get_uri'); + late final _dart_app_control_get_uri _app_control_get_uri = + _app_control_get_uri_ptr.asFunction<_dart_app_control_get_uri>(); + + /// @brief Sets the explicit MIME type of the data. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_control The app_control handle + /// @param[in] mime The explicit MIME type of the data this app_control is operating on (if the @a mime is @c NULL, it clears the previous value) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see app_control_get_mime() + int app_control_set_mime( + ffi.Pointer app_control, + ffi.Pointer mime, + ) { + return _app_control_set_mime( + app_control, + mime, + ); + } + + late final _app_control_set_mime_ptr = + _lookup>( + 'app_control_set_mime'); + late final _dart_app_control_set_mime _app_control_set_mime = + _app_control_set_mime_ptr.asFunction<_dart_app_control_set_mime>(); + + /// @brief Gets the explicit MIME type of the data. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The @a uri must be released using free(). + /// @param[in] app_control The app_control handle + /// @param[out] mime The explicit MIME type of the data this app_control is operating on + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see app_control_set_mime() + int app_control_get_mime( + ffi.Pointer app_control, + ffi.Pointer> mime, + ) { + return _app_control_get_mime( + app_control, + mime, + ); + } + + late final _app_control_get_mime_ptr = + _lookup>( + 'app_control_get_mime'); + late final _dart_app_control_get_mime _app_control_get_mime = + _app_control_get_mime_ptr.asFunction<_dart_app_control_get_mime>(); + + /// @brief Sets the explicit category. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_control The app_control handle + /// @param[in] category The explicit category (if the @a category is @c NULL, it clears the previous value) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see app_control_get_category() + int app_control_set_category( + ffi.Pointer app_control, + ffi.Pointer category, + ) { + return _app_control_set_category( + app_control, + category, + ); + } + + late final _app_control_set_category_ptr = + _lookup>( + 'app_control_set_category'); + late final _dart_app_control_set_category _app_control_set_category = + _app_control_set_category_ptr + .asFunction<_dart_app_control_set_category>(); + + /// @brief Gets the explicit category. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The @a category must be released using free(). + /// @param[in] app_control The app_control handle + /// @param[out] category The explicit category + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see app_control_set_category() + int app_control_get_category( + ffi.Pointer app_control, + ffi.Pointer> category, + ) { + return _app_control_get_category( + app_control, + category, + ); + } + + late final _app_control_get_category_ptr = + _lookup>( + 'app_control_get_category'); + late final _dart_app_control_get_category _app_control_get_category = + _app_control_get_category_ptr + .asFunction<_dart_app_control_get_category>(); + + /// @brief Sets the ID of the application to explicitly launch. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_control The app_control handle + /// @param[in] app_id The ID of the application to explicitly launch (if the @a app_id is @c NULL, it clears the previous value) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see app_control_get_app_id() + int app_control_set_app_id( + ffi.Pointer app_control, + ffi.Pointer app_id, + ) { + return _app_control_set_app_id( + app_control, + app_id, + ); + } + + late final _app_control_set_app_id_ptr = + _lookup>( + 'app_control_set_app_id'); + late final _dart_app_control_set_app_id _app_control_set_app_id = + _app_control_set_app_id_ptr.asFunction<_dart_app_control_set_app_id>(); + + /// @brief Gets the ID of the application to explicitly launch. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The @a app_id must be released with free(). + /// @param[in] app_control The app_control handle + /// @param[out] app_id The ID of the application to explicitly launch + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see app_control_set_app_id() + int app_control_get_app_id( + ffi.Pointer app_control, + ffi.Pointer> app_id, + ) { + return _app_control_get_app_id( + app_control, + app_id, + ); + } + + late final _app_control_get_app_id_ptr = + _lookup>( + 'app_control_get_app_id'); + late final _dart_app_control_get_app_id _app_control_get_app_id = + _app_control_get_app_id_ptr.asFunction<_dart_app_control_get_app_id>(); + + /// @brief Adds extra data to the app_control. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The function replaces any existing value for the given key. + /// @remarks The function returns #APP_CONTROL_ERROR_INVALID_PARAMETER if @a key or @a value is a zero-length string. + /// @remarks The function returns #APP_CONTROL_ERROR_KEY_REJECTED if the application tries to use the same key with the system-defined key. + /// @param[in] app_control The app_control handle + /// @param[in] key The name of the extra data + /// @param[in] value The value associated with the given key + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_KEY_REJECTED Key not available + /// @see app_control_add_extra_data_array() + /// @see app_control_remove_extra_data() + /// @see app_control_get_extra_data() + int app_control_add_extra_data( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer value, + ) { + return _app_control_add_extra_data( + app_control, + key, + value, + ); + } + + late final _app_control_add_extra_data_ptr = + _lookup>( + 'app_control_add_extra_data'); + late final _dart_app_control_add_extra_data _app_control_add_extra_data = + _app_control_add_extra_data_ptr + .asFunction<_dart_app_control_add_extra_data>(); + + /// @brief Adds the extra data array to the app_control. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The function replaces any existing value for the given key. + /// @remarks The function returns #APP_CONTROL_ERROR_INVALID_PARAMETER if @a key is a zero-length string. + /// @remarks The function returns #APP_CONTROL_ERROR_KEY_REJECTED if the application tries to use the same key with the system-defined key. + /// @param[in] app_control The app_control handle + /// @param[in] key The name of the extra data + /// @param[in] value The array value associated with the given key + /// @param[in] length The length of the array + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_KEY_REJECTED Key not available + /// @see app_control_add_extra_data() + /// @see app_control_remove_extra_data() + /// @see app_control_get_extra_data() + int app_control_add_extra_data_array( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer> value, + int length, + ) { + return _app_control_add_extra_data_array( + app_control, + key, + value, + length, + ); + } + + late final _app_control_add_extra_data_array_ptr = + _lookup>( + 'app_control_add_extra_data_array'); + late final _dart_app_control_add_extra_data_array + _app_control_add_extra_data_array = _app_control_add_extra_data_array_ptr + .asFunction<_dart_app_control_add_extra_data_array>(); + + /// @brief Removes the extra data from the app_control. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_control The app_control handle + /// @param[in] key The name of the extra data + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_KEY_NOT_FOUND Specified key not found + /// @retval #APP_CONTROL_ERROR_KEY_REJECTED Key not available + /// @see app_control_add_extra_data() + /// @see app_control_add_extra_data_array() + /// @see app_control_get_extra_data() + int app_control_remove_extra_data( + ffi.Pointer app_control, + ffi.Pointer key, + ) { + return _app_control_remove_extra_data( + app_control, + key, + ); + } + + late final _app_control_remove_extra_data_ptr = + _lookup>( + 'app_control_remove_extra_data'); + late final _dart_app_control_remove_extra_data + _app_control_remove_extra_data = _app_control_remove_extra_data_ptr + .asFunction<_dart_app_control_remove_extra_data>(); + + /// @brief Gets the extra data from the app_control. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The @a value must be released using free(). + /// @remarks The function returns #APP_CONTROL_ERROR_INVALID_DATA_TYPE if @a value is of array data type. + /// @param[in] app_control The app_control handle + /// @param[in] key The name of the extra data + /// @param[out] value The value associated with the given key + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_KEY_NOT_FOUND Specified key not found + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #APP_CONTROL_ERROR_INVALID_DATA_TYPE Invalid data type + /// @retval #APP_CONTROL_ERROR_KEY_REJECTED Key not available + /// @see app_control_add_extra_data() + /// @see app_control_add_extra_data_array() + /// @see app_control_get_extra_data() + /// @see app_control_remove_extra_data() + /// @see app_control_foreach_extra_data() + int app_control_get_extra_data( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer> value, + ) { + return _app_control_get_extra_data( + app_control, + key, + value, + ); + } + + late final _app_control_get_extra_data_ptr = + _lookup>( + 'app_control_get_extra_data'); + late final _dart_app_control_get_extra_data _app_control_get_extra_data = + _app_control_get_extra_data_ptr + .asFunction<_dart_app_control_get_extra_data>(); + + /// @brief Gets the extra data array from the app_control. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The @a value must be released using free(). + /// @remarks The function returns #APP_CONTROL_ERROR_INVALID_DATA_TYPE if @a value is not of array data type. + /// @param[in] app_control The app_control handle + /// @param[in] key The name of the extra data + /// @param[out] value The array value associated with the given key + /// @param[out] length The length of the array + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_KEY_NOT_FOUND Specified key not found + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #APP_CONTROL_ERROR_INVALID_DATA_TYPE Invalid data type + /// @retval #APP_CONTROL_ERROR_KEY_REJECTED Key not available + /// @see app_control_add_extra_data() + /// @see app_control_add_extra_data_array() + /// @see app_control_remove_extra_data() + /// @see app_control_foreach_extra_data() + int app_control_get_extra_data_array( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer>> value, + ffi.Pointer length, + ) { + return _app_control_get_extra_data_array( + app_control, + key, + value, + length, + ); + } + + late final _app_control_get_extra_data_array_ptr = + _lookup>( + 'app_control_get_extra_data_array'); + late final _dart_app_control_get_extra_data_array + _app_control_get_extra_data_array = _app_control_get_extra_data_array_ptr + .asFunction<_dart_app_control_get_extra_data_array>(); + + /// @brief Checks whether the extra data associated with the given @a key is of array data type. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_control The app_control handle + /// @param[in] key The name of the extra data + /// @param[out] array If @c true the extra data is of array data type, + /// otherwise @c false + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see app_control_add_extra_data() + /// @see app_control_add_extra_data_array() + /// @see app_control_remove_extra_data() + /// @see app_control_foreach_extra_data() + int app_control_is_extra_data_array( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer array, + ) { + return _app_control_is_extra_data_array( + app_control, + key, + array, + ); + } + + late final _app_control_is_extra_data_array_ptr = + _lookup>( + 'app_control_is_extra_data_array'); + late final _dart_app_control_is_extra_data_array + _app_control_is_extra_data_array = _app_control_is_extra_data_array_ptr + .asFunction<_dart_app_control_is_extra_data_array>(); + + /// @brief Retrieves all extra data contained in app_control. + /// @details This function calls app_control_extra_data_cb() once for each key-value pair for extra data contained in app_control. \n + /// If the app_control_extra_data_cb() callback function returns @c false, then iteration will be finished. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_control The app_control handle + /// @param[in] callback The iteration callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @post This function invokes app_control_extra_data_cb(). + /// @see app_control_extra_data_cb() + int app_control_foreach_extra_data( + ffi.Pointer app_control, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _app_control_foreach_extra_data( + app_control, + callback, + user_data, + ); + } + + late final _app_control_foreach_extra_data_ptr = + _lookup>( + 'app_control_foreach_extra_data'); + late final _dart_app_control_foreach_extra_data + _app_control_foreach_extra_data = _app_control_foreach_extra_data_ptr + .asFunction<_dart_app_control_foreach_extra_data>(); + + /// @brief Retrieves all applications that can be launched to handle the given app_control request. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_control The app_control handle + /// @param[in] callback The iteration callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Success + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @post This function invokes app_control_app_matched_cb(). + /// @see app_control_app_matched_cb() + int app_control_foreach_app_matched( + ffi.Pointer app_control, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _app_control_foreach_app_matched( + app_control, + callback, + user_data, + ); + } + + late final _app_control_foreach_app_matched_ptr = + _lookup>( + 'app_control_foreach_app_matched'); + late final _dart_app_control_foreach_app_matched + _app_control_foreach_app_matched = _app_control_foreach_app_matched_ptr + .asFunction<_dart_app_control_foreach_app_matched>(); + + /// @brief Sends the launch request. + /// + /// @details The operation is mandatory information for the launch request. \n + /// If the operation is not specified, #APP_CONTROL_OPERATION_DEFAULT is used by default. + /// If the operation is #APP_CONTROL_OPERATION_DEFAULT, the application ID is mandatory to explicitly launch the application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/appmanager.launch + /// @remarks The function returns #APP_CONTROL_ERROR_LAUNCH_REJECTED if the operation value is #APP_CONTROL_OPERATION_LAUNCH_ON_EVENT which is only for handling the event from the platform or other application, refer to the @a CAPI_EVENT_MODULE module. + /// @remarks Since Tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif, the launch request of the service application over out of packages is restricted by the platform. Also, implicit launch requests are NOT delivered to service applications since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. To launch a service application, an explicit launch request with application ID given by the app_control_set_app_id() must be sent. + /// @param[in] app_control The app_control handle + /// @param[in] callback The callback function to be called when the reply is delivered + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #APP_CONTROL_ERROR_APP_NOT_FOUND The application to run the given launch request is not found + /// @retval #APP_CONTROL_ERROR_LAUNCH_REJECTED The application cannot be launched in current context + /// @retval #APP_CONTROL_ERROR_LAUNCH_FAILED Failed to launch the application + /// @retval #APP_CONTROL_ERROR_TIMED_OUT Failed due to timeout. The application that handles @a app_control may be busy + /// @retval #APP_CONTROL_ERROR_PERMISSION_DENIED Permission denied + /// @post If the launch request is sent for the result, the result will come back through the app_control_reply_cb() from the callee application. Additional replies may be delivered on the app_control_enable_app_started_result_event() called. + /// @see app_control_reply_to_launch_request() + /// @see app_control_reply_cb() + /// @see app_control_enable_app_started_result_event() + int app_control_send_launch_request( + ffi.Pointer app_control, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _app_control_send_launch_request( + app_control, + callback, + user_data, + ); + } + + late final _app_control_send_launch_request_ptr = + _lookup>( + 'app_control_send_launch_request'); + late final _dart_app_control_send_launch_request + _app_control_send_launch_request = _app_control_send_launch_request_ptr + .asFunction<_dart_app_control_send_launch_request>(); + + /// @brief Sends the terminate request to the application that is launched by app_control. This API is only effective for some applications that are provided by default for handling platform default app_controls. You are not allowed to terminate other general applications using this API. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks Since Tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif, this API can be used to terminate sub-applications which were launched as group mode by the caller application. + /// Once callee application is being terminated by this API, other applications which were launched by the callee application as a group mode will be terminated as well. + /// @param[in] app_control The app_control handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_PERMISSION_DENIED Permission denied + /// @see app_control_send_launch_request() + /// @see app_control_set_launch_mode() + int app_control_send_terminate_request( + ffi.Pointer app_control, + ) { + return _app_control_send_terminate_request( + app_control, + ); + } + + late final _app_control_send_terminate_request_ptr = + _lookup>( + 'app_control_send_terminate_request'); + late final _dart_app_control_send_terminate_request + _app_control_send_terminate_request = + _app_control_send_terminate_request_ptr + .asFunction<_dart_app_control_send_terminate_request>(); + + /// @brief Replies to the launch request sent by the caller. + /// @details If the caller application sent the launch request to receive the result, the callee application can return the result back to the caller. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The function is not allowed to send reply #APP_CONTROL_RESULT_APP_STARTED as @a result which is reserved for platform developers. + /// @param[in] reply The app_control handle in which the results of the callee are contained + /// @param[in] request The app_control handle sent by the caller + /// @param[in] result The result code of the launch request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see app_control_send_launch_request() + int app_control_reply_to_launch_request( + ffi.Pointer reply, + ffi.Pointer request, + int result, + ) { + return _app_control_reply_to_launch_request( + reply, + request, + result, + ); + } + + late final _app_control_reply_to_launch_request_ptr = + _lookup>( + 'app_control_reply_to_launch_request'); + late final _dart_app_control_reply_to_launch_request + _app_control_reply_to_launch_request = + _app_control_reply_to_launch_request_ptr + .asFunction<_dart_app_control_reply_to_launch_request>(); + + /// @brief Creates and returns a copy of the given app_control handle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks A newly created app_control should be destroyed by calling the app_control_destroy() if it is no longer needed. + /// + /// @param[out] clone If successful, a newly created app_control handle will be returned + /// @param[in] app_control The app_control handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see app_control_destroy() + int app_control_clone( + ffi.Pointer> clone, + ffi.Pointer app_control, + ) { + return _app_control_clone( + clone, + app_control, + ); + } + + late final _app_control_clone_ptr = + _lookup>('app_control_clone'); + late final _dart_app_control_clone _app_control_clone = + _app_control_clone_ptr.asFunction<_dart_app_control_clone>(); + + /// @brief Gets the application ID of the caller from the launch request. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The @a app_control must be the launch request from app_control_cb(). + /// @remarks This function returns #APP_CONTROL_ERROR_INVALID_PARAMETER if the given app_control is not the launch request. + /// @remarks The @a id must be released using free(). + /// @param[in] app_control The app_control handle from app_control_cb() + /// @param[out] id The application ID of the caller + /// @return @a 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + int app_control_get_caller( + ffi.Pointer app_control, + ffi.Pointer> id, + ) { + return _app_control_get_caller( + app_control, + id, + ); + } + + late final _app_control_get_caller_ptr = + _lookup>( + 'app_control_get_caller'); + late final _dart_app_control_get_caller _app_control_get_caller = + _app_control_get_caller_ptr.asFunction<_dart_app_control_get_caller>(); + + /// @brief Checks whether the caller is requesting a reply from the launch request. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The @a app_control must be the launch request from app_control_cb(). + /// @remarks This function returns #APP_CONTROL_ERROR_INVALID_PARAMETER if the given app_control is not the launch request. + /// @param[in] app_control The app_control handle from app_control_cb() + /// @param[out] requested If @c true a reply is requested by the caller, + /// otherwise @c false + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + int app_control_is_reply_requested( + ffi.Pointer app_control, + ffi.Pointer requested, + ) { + return _app_control_is_reply_requested( + app_control, + requested, + ); + } + + late final _app_control_is_reply_requested_ptr = + _lookup>( + 'app_control_is_reply_requested'); + late final _dart_app_control_is_reply_requested + _app_control_is_reply_requested = _app_control_is_reply_requested_ptr + .asFunction<_dart_app_control_is_reply_requested>(); + + /// @brief Sets the launch mode of the application. + /// + /// @details This function allows the callee application to be launched as a group or as a single mode. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks Although launch_mode were set as #APP_CONTROL_LAUNCH_MODE_GROUP, the callee application would be launched as a single mode if the manifest file of callee application defined the launch mode as "single". + /// This function can just set the preference of the caller application to launch an application. + /// @remarks Sub-applications which were launched as a group mode always have own process. + /// + /// @param[in] app_control The app_control handle + /// @param[in] mode The launch mode of the application + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see app_control_set_launch_mode() + /// @see app_control_launch_mode_e + int app_control_set_launch_mode( + ffi.Pointer app_control, + int mode, + ) { + return _app_control_set_launch_mode( + app_control, + mode, + ); + } + + late final _app_control_set_launch_mode_ptr = + _lookup>( + 'app_control_set_launch_mode'); + late final _dart_app_control_set_launch_mode _app_control_set_launch_mode = + _app_control_set_launch_mode_ptr + .asFunction<_dart_app_control_set_launch_mode>(); + + /// @brief Gets the launch mode of the application. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks Since Tizen 3.0, if launch mode is not set in the caller application control, + /// the function returns the #APP_CONTROL_LAUNCH_MODE_SINGLE launch mode. + /// @param[in] app_control The app_control handle + /// @param[out] mode The launch mode of the application + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see app_control_get_launch_mode() + /// @see app_control_launch_mode_e + int app_control_get_launch_mode( + ffi.Pointer app_control, + ffi.Pointer mode, + ) { + return _app_control_get_launch_mode( + app_control, + mode, + ); + } + + late final _app_control_get_launch_mode_ptr = + _lookup>( + 'app_control_get_launch_mode'); + late final _dart_app_control_get_launch_mode _app_control_get_launch_mode = + _app_control_get_launch_mode_ptr + .asFunction<_dart_app_control_get_launch_mode>(); + + /// @brief Enables an additional launch result event on the launch request. + /// + /// @details The function allows to receive the #APP_CONTROL_RESULT_APP_STARTED event on\n + /// application get launched by the app_control. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks app_control_reply_cb() will be called on the APP_CONTROL_RESULT_APP_STARTED event received. + /// @param[in] app_control The app_control handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_CONTROL_ERROR_NONE Successful + /// @retval #APP_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see app_control_send_launch_request() + /// @see #APP_CONTROL_RESULT_APP_STARTED + int app_control_enable_app_started_result_event( + ffi.Pointer app_control, + ) { + return _app_control_enable_app_started_result_event( + app_control, + ); + } + + late final _app_control_enable_app_started_result_event_ptr = _lookup< + ffi.NativeFunction<_c_app_control_enable_app_started_result_event>>( + 'app_control_enable_app_started_result_event'); + late final _dart_app_control_enable_app_started_result_event + _app_control_enable_app_started_result_event = + _app_control_enable_app_started_result_event_ptr + .asFunction<_dart_app_control_enable_app_started_result_event>(); + + /// @brief Gets the low memory status from the given event info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] event_info The system event info + /// @param[out] status The low memory status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_INVALID_CONTEXT Invalid event context + /// @see app_event_info_h + /// @see app_event_low_memory_status_e + int app_event_get_low_memory_status( + ffi.Pointer event_info, + ffi.Pointer status, + ) { + return _app_event_get_low_memory_status( + event_info, + status, + ); + } + + late final _app_event_get_low_memory_status_ptr = + _lookup>( + 'app_event_get_low_memory_status'); + late final _dart_app_event_get_low_memory_status + _app_event_get_low_memory_status = _app_event_get_low_memory_status_ptr + .asFunction<_dart_app_event_get_low_memory_status>(); + + /// @brief Gets the low battery status from given event info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] event_info The system event info + /// @param[out] status The low battery status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_INVALID_CONTEXT Invalid event context + /// @see app_event_info_h + /// @see app_event_low_battery_status_e + int app_event_get_low_battery_status( + ffi.Pointer event_info, + ffi.Pointer status, + ) { + return _app_event_get_low_battery_status( + event_info, + status, + ); + } + + late final _app_event_get_low_battery_status_ptr = + _lookup>( + 'app_event_get_low_battery_status'); + late final _dart_app_event_get_low_battery_status + _app_event_get_low_battery_status = _app_event_get_low_battery_status_ptr + .asFunction<_dart_app_event_get_low_battery_status>(); + + /// @brief Gets the language from the given event info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks @a lang must be released using free(). + /// @param[in] event_info The system event info + /// @param[out] lang The language changed + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_INVALID_CONTEXT Invalid event context + /// @see app_event_info_h + int app_event_get_language( + ffi.Pointer event_info, + ffi.Pointer> lang, + ) { + return _app_event_get_language( + event_info, + lang, + ); + } + + late final _app_event_get_language_ptr = + _lookup>( + 'app_event_get_language'); + late final _dart_app_event_get_language _app_event_get_language = + _app_event_get_language_ptr.asFunction<_dart_app_event_get_language>(); + + /// @brief Gets the region format from the given event info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks @a region must be released using free(). + /// @param[in] event_info The system event info + /// @param[out] region The region format changed + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_INVALID_CONTEXT Invalid event context + /// @see app_event_info_h + int app_event_get_region_format( + ffi.Pointer event_info, + ffi.Pointer> region, + ) { + return _app_event_get_region_format( + event_info, + region, + ); + } + + late final _app_event_get_region_format_ptr = + _lookup>( + 'app_event_get_region_format'); + late final _dart_app_event_get_region_format _app_event_get_region_format = + _app_event_get_region_format_ptr + .asFunction<_dart_app_event_get_region_format>(); + + /// @brief Gets the device orientation from the given event info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] event_info The system event info + /// @param[out] orientation The device orientation changed + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_INVALID_CONTEXT Invalid event context + /// @see app_event_info_h + /// @see app_device_orientation_e + int app_event_get_device_orientation( + ffi.Pointer event_info, + ffi.Pointer orientation, + ) { + return _app_event_get_device_orientation( + event_info, + orientation, + ); + } + + late final _app_event_get_device_orientation_ptr = + _lookup>( + 'app_event_get_device_orientation'); + late final _dart_app_event_get_device_orientation + _app_event_get_device_orientation = _app_event_get_device_orientation_ptr + .asFunction<_dart_app_event_get_device_orientation>(); + + /// @brief Gets the suspended state of the application from the given event info. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks The application should not use any asynchronous operations in #APP_SUSPENDED_STATE_WILL_ENTER event. + /// Because applications will be changed to suspended state just after #APP_SUSPENDED_STATE_WILL_ENTER, asynchronous calls are not guaranteed to work properly. + /// @param[in] event_info The handle for getting the suspended state + /// @param[out] state The suspended state of the application + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_INVALID_CONTEXT Invalid event context + int app_event_get_suspended_state( + ffi.Pointer event_info, + ffi.Pointer state, + ) { + return _app_event_get_suspended_state( + event_info, + state, + ); + } + + late final _app_event_get_suspended_state_ptr = + _lookup>( + 'app_event_get_suspended_state'); + late final _dart_app_event_get_suspended_state + _app_event_get_suspended_state = _app_event_get_suspended_state_ptr + .asFunction<_dart_app_event_get_suspended_state>(); + + /// @brief Gets the ID of the application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks @a id must be released using free(). + /// @param[out] id The ID of the application + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_INVALID_CONTEXT The application is launched illegally, not launched by the launch system + /// @retval #APP_ERROR_OUT_OF_MEMORY Out of memory + int app_get_id( + ffi.Pointer> id, + ) { + return _app_get_id( + id, + ); + } + + late final _app_get_id_ptr = + _lookup>('app_get_id'); + late final _dart_app_get_id _app_get_id = + _app_get_id_ptr.asFunction<_dart_app_get_id>(); + + /// @brief Gets the localized name of the application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks @a name must be released using free(). + /// @param[out] name The name of the application + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_INVALID_CONTEXT The application is launched illegally, not launched by the launch system + /// @retval #APP_ERROR_OUT_OF_MEMORY Out of memory + int app_get_name( + ffi.Pointer> name, + ) { + return _app_get_name( + name, + ); + } + + late final _app_get_name_ptr = + _lookup>('app_get_name'); + late final _dart_app_get_name _app_get_name = + _app_get_name_ptr.asFunction<_dart_app_get_name>(); + + /// @brief Gets the version of the application package. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks @a version must be released using free(). + /// @param[out] version The version of the application + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_INVALID_CONTEXT The application is launched illegally, not launched by the launch system + /// @retval #APP_ERROR_OUT_OF_MEMORY Out of memory + int app_get_version( + ffi.Pointer> version, + ) { + return _app_get_version( + version, + ); + } + + late final _app_get_version_ptr = + _lookup>('app_get_version'); + late final _dart_app_get_version _app_get_version = + _app_get_version_ptr.asFunction<_dart_app_get_version>(); + + /// @brief Gets the absolute path to the application's data directory which is used to store private data of the application. + /// @details An application can read and write its own files in the application's data directory. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The returned path should be released. + /// @return The absolute path to the application's data directory, @n + /// otherwise a null pointer if the memory is insufficient + ffi.Pointer app_get_data_path() { + return _app_get_data_path(); + } + + late final _app_get_data_path_ptr = + _lookup>('app_get_data_path'); + late final _dart_app_get_data_path _app_get_data_path = + _app_get_data_path_ptr.asFunction<_dart_app_get_data_path>(); + + /// @brief Gets the absolute path to the application's cache directory which is used to store temporary data of the application. + /// @details An application can read and write its own files in the application's cache directory. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The returned path should be released. @n + /// The files stored in the application's cache directory can be removed by setting application or platform while the application is running. + /// @return The absolute path to the application's cache directory, @n + /// otherwise a null pointer if the memory is insufficient + ffi.Pointer app_get_cache_path() { + return _app_get_cache_path(); + } + + late final _app_get_cache_path_ptr = + _lookup>('app_get_cache_path'); + late final _dart_app_get_cache_path _app_get_cache_path = + _app_get_cache_path_ptr.asFunction<_dart_app_get_cache_path>(); + + /// @brief Gets the absolute path to the application resource directory. The resource files are delivered with the application package. + /// @details An application can only read its own files in the application's resource directory. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The returned path should be released. + /// @return The absolute path to the application's resource directory, @n + /// otherwise a null pointer if the memory is insufficient + ffi.Pointer app_get_resource_path() { + return _app_get_resource_path(); + } + + late final _app_get_resource_path_ptr = + _lookup>( + 'app_get_resource_path'); + late final _dart_app_get_resource_path _app_get_resource_path = + _app_get_resource_path_ptr.asFunction<_dart_app_get_resource_path>(); + + /// @brief Gets the absolute path to the application's shared data directory which is used to share data with other applications. + /// @details An application can read and write its own files in the application's shared data directory and others can only read the files. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/appdir.shareddata + /// @remarks The returned path should be released. @n + /// Since Tizen 3.0, an application that want to use shared/data directory must declare http://tizen.org/privilege/appdir.shareddata privilege. If the application doesn't declare the privilege, the framework will not create shared/data directory for the application. + /// Carefully consider the privacy implications when deciding whether to use the shared/data directory, since the application cannot control access to this directory by other applications. + /// If you want to share files with other applications, consider passing path via @ref CAPI_APP_CONTROL_MODULE API. + /// The @ref CAPI_APP_CONTROL_MODULE API supports giving permission to other applications by passing path via app_control. @n + /// The specific error code can be obtained using the get_last_result(). Error codes are described in Exception section. + /// + /// @return The absolute path to the application's shared data directory, @n + /// otherwise a null pointer if the memory is insufficient. It will return NULL for applications with api-version 3.0 or later, and set #APP_ERROR_PERMISSION_DENIED if the application does not declare the shareddata privilege. + /// @exception APP_ERROR_NONE Success + /// @exception APP_ERROR_OUT_OF_MEMORY Out of memory + /// @exception APP_ERROR_PERMISSION_DENIED Permission denied + ffi.Pointer app_get_shared_data_path() { + return _app_get_shared_data_path(); + } + + late final _app_get_shared_data_path_ptr = + _lookup>( + 'app_get_shared_data_path'); + late final _dart_app_get_shared_data_path _app_get_shared_data_path = + _app_get_shared_data_path_ptr + .asFunction<_dart_app_get_shared_data_path>(); + + /// @brief Gets the absolute path to the application's shared resource directory which is used to share resources with other applications. + /// @details An application can read its own files in the application's shared resource directory, and others can only read the files. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The returned path should be released. + /// @return The absolute path to the application's shared resource directory, @n + /// otherwise a null pointer if the memory is insufficient + ffi.Pointer app_get_shared_resource_path() { + return _app_get_shared_resource_path(); + } + + late final _app_get_shared_resource_path_ptr = + _lookup>( + 'app_get_shared_resource_path'); + late final _dart_app_get_shared_resource_path _app_get_shared_resource_path = + _app_get_shared_resource_path_ptr + .asFunction<_dart_app_get_shared_resource_path>(); + + /// @brief Gets the absolute path to the application's shared trusted directory which is used to share data with a family of trusted applications. + /// @details An application can read and write its own files in the application's shared trusted directory + /// and the family applications signed with the same certificate can read and write the files in the shared trusted directory. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The returned path should be released. + /// @return The absolute path to the application's shared trusted directory, @n + /// otherwise a null pointer if the memory is insufficient + ffi.Pointer app_get_shared_trusted_path() { + return _app_get_shared_trusted_path(); + } + + late final _app_get_shared_trusted_path_ptr = + _lookup>( + 'app_get_shared_trusted_path'); + late final _dart_app_get_shared_trusted_path _app_get_shared_trusted_path = + _app_get_shared_trusted_path_ptr + .asFunction<_dart_app_get_shared_trusted_path>(); + + /// @brief Gets the absolute path to the application's external data directory which is used to store data of the application. + /// @details An application can read and write its own files in the application's external data directory. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The returned path should be released. @n + /// The important files stored in the application's external data directory should be encrypted because they can be exported via the external sdcard. + /// To access the path returned by this function requires the privilege + /// that is "http://tizen.org/privilege/externalstorage.appdata". + /// @return The absolute path to the application's external data directory, @n + /// otherwise a null pointer if the memory is insufficient + ffi.Pointer app_get_external_data_path() { + return _app_get_external_data_path(); + } + + late final _app_get_external_data_path_ptr = + _lookup>( + 'app_get_external_data_path'); + late final _dart_app_get_external_data_path _app_get_external_data_path = + _app_get_external_data_path_ptr + .asFunction<_dart_app_get_external_data_path>(); + + /// @brief Gets the absolute path to the application's external cache directory which is used to store temporary data of the application. + /// @details An application can read and write its own files in the application's external cache directory. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The returned path should be released. @n + /// The files stored in the application's external cache directory can be removed by + /// setting application while the application is running. @n + /// The important files stored in the application's external cache directory should be + /// encrypted because they can be exported via the external sdcard. + /// To access the path returned by this function requires the privilege + /// that is "http://tizen.org/privilege/externalstorage.appdata". + /// @return The absolute path to the application's external cache directory, @n + /// otherwise a null pointer if the memory is insufficient + ffi.Pointer app_get_external_cache_path() { + return _app_get_external_cache_path(); + } + + late final _app_get_external_cache_path_ptr = + _lookup>( + 'app_get_external_cache_path'); + late final _dart_app_get_external_cache_path _app_get_external_cache_path = + _app_get_external_cache_path_ptr + .asFunction<_dart_app_get_external_cache_path>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. + /// @brief Gets the absolute path to the application's external shared data directory which is used to share data with other applications. + /// @details An application can read and write its own files in the application's external shared data directory, and others can only read the files. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specified @a path should be released. + /// To access the path returned by this function requires the privilege + /// that is "http://tizen.org/privilege/externalstorage.appdata". + /// The function may not work as intended in certain devices due to some implementation issues. + /// @return The absolute path to the application's external shared data directory, @n + /// otherwise a null pointer if the memory is insufficient + ffi.Pointer app_get_external_shared_data_path() { + return _app_get_external_shared_data_path(); + } + + late final _app_get_external_shared_data_path_ptr = + _lookup>( + 'app_get_external_shared_data_path'); + late final _dart_app_get_external_shared_data_path + _app_get_external_shared_data_path = + _app_get_external_shared_data_path_ptr + .asFunction<_dart_app_get_external_shared_data_path>(); + + /// @brief Gets the absolute path to the application's TEP(Tizen Expansion Package) directory. The resource files are delivered with the expansion package. + /// @details An application can only read its own files in the application's TEP(Tizen Expansion Package) directory. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks The returned path should be released. + /// @return The absolute path to the application's TEP(Tizen Expansion Package) directory, @n + /// otherwise a null pointer if the memory is insufficient + ffi.Pointer app_get_tep_resource_path() { + return _app_get_tep_resource_path(); + } + + late final _app_get_tep_resource_path_ptr = + _lookup>( + 'app_get_tep_resource_path'); + late final _dart_app_get_tep_resource_path _app_get_tep_resource_path = + _app_get_tep_resource_path_ptr + .asFunction<_dart_app_get_tep_resource_path>(); + + /// @brief Gets the localized translation for the specified string. + /// + /// @details If a translation is not found in the localization file(.po file), @a message is returned. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks Do not free the returned value. + /// + /// @param[in] message The string to be translated + /// @return The localized translation for the given @a message on success, + /// otherwise the given @a message + ffi.Pointer i18n_get_text( + ffi.Pointer message, + ) { + return _i18n_get_text( + message, + ); + } + + late final _i18n_get_text_ptr = + _lookup>('i18n_get_text'); + late final _dart_i18n_get_text _i18n_get_text = + _i18n_get_text_ptr.asFunction<_dart_i18n_get_text>(); + + /// @brief Gets the current device orientation. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @return The current device orientation + int app_get_device_orientation() { + return _app_get_device_orientation(); + } + + late final _app_get_device_orientation_ptr = + _lookup>( + 'app_get_device_orientation'); + late final _dart_app_get_device_orientation _app_get_device_orientation = + _app_get_device_orientation_ptr + .asFunction<_dart_app_get_device_orientation>(); + + /// @brief Runs the application's main loop until ui_app_exit() is called. + /// @details This function is the main entry point of the Tizen application. + /// The app_create_cb() callback function is called to initialize the application before the main loop of application starts up. + /// After the app_create_cb() callback function returns true, the main loop starts up and the app_control_cb() callback function is subsequently called. + /// If the app_create_cb() callback function returns false, the main loop doesn't start up and app_terminate_cb() callback function is called. + /// This main loop supports event handling for the Ecore Main Loop. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] argc The argument count + /// @param[in] argv The argument vector + /// @param[in] callback The set of callback functions to handle application lifecycle events + /// @param[in] user_data The user data to be passed to the callback functions + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_INVALID_CONTEXT The application is launched illegally, not launched by the launch system + /// @retval #APP_ERROR_ALREADY_RUNNING The main loop already started + /// @see app_create_cb() + /// @see app_terminate_cb() + /// @see app_pause_cb() + /// @see app_resume_cb() + /// @see app_control_cb() + /// @see ui_app_exit() + /// @see #ui_app_lifecycle_callback_s + int ui_app_main( + int argc, + ffi.Pointer> argv, + ffi.Pointer callback, + ffi.Pointer user_data, + ) { + return _ui_app_main( + argc, + argv, + callback, + user_data, + ); + } + + late final _ui_app_main_ptr = + _lookup>('ui_app_main'); + late final _dart_ui_app_main _ui_app_main = + _ui_app_main_ptr.asFunction<_dart_ui_app_main>(); + + /// @brief Exits the main loop of application. + /// @details The main loop of application stops and app_terminate_cb() is invoked. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @see ui_app_main() + /// @see app_terminate_cb() + void ui_app_exit() { + return _ui_app_exit(); + } + + late final _ui_app_exit_ptr = + _lookup>('ui_app_exit'); + late final _dart_ui_app_exit _ui_app_exit = + _ui_app_exit_ptr.asFunction<_dart_ui_app_exit>(); + + /// @brief Adds the system event handler. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] event_handler The event handler + /// @param[in] event_type The system event type + /// @param[in] callback The callback function + /// @param[in] user_data The user data to be passed to the callback functions + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_OUT_OF_MEMORY Out of memory + /// @see app_event_type_e + /// @see app_event_cb + /// @see ui_app_remove_event_handler + int ui_app_add_event_handler( + ffi.Pointer> event_handler, + int event_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _ui_app_add_event_handler( + event_handler, + event_type, + callback, + user_data, + ); + } + + late final _ui_app_add_event_handler_ptr = + _lookup>( + 'ui_app_add_event_handler'); + late final _dart_ui_app_add_event_handler _ui_app_add_event_handler = + _ui_app_add_event_handler_ptr + .asFunction<_dart_ui_app_add_event_handler>(); + + /// @brief Removes registered event handler. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] event_handler The event handler + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @see ui_app_add_event_handler + int ui_app_remove_event_handler( + ffi.Pointer event_handler, + ) { + return _ui_app_remove_event_handler( + event_handler, + ); + } + + late final _ui_app_remove_event_handler_ptr = + _lookup>( + 'ui_app_remove_event_handler'); + late final _dart_ui_app_remove_event_handler _ui_app_remove_event_handler = + _ui_app_remove_event_handler_ptr + .asFunction<_dart_ui_app_remove_event_handler>(); + + /// @brief Sets an alarm to be triggered after a specific time. + /// @details The alarm will first go off @a delay seconds later and then will go off every certain amount of time defined using @a period seconds. To cancel the alarm, call alarm_cancel() with @a alarm_id. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @privilege %http://tizen.org/privilege/appmanager.launch + /// @remarks If the application is uninstalled after setting an alarm, the alarm is cancelled automatically. + /// If the operation of @a app_control is not specified, #APP_CONTROL_OPERATION_DEFAULT is used for the launch request. + /// If the operation of @a app_control is #APP_CONTROL_OPERATION_DEFAULT, the package information is mandatory to explicitly launch the application. + /// Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif, this api does not support exact period and delay for minimizing the wakeups of the device. The system can adjust when the alarm expires. + /// If you want to trigger an alarm exactly, see @see alarm_schedule_once_after_delay() + /// Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif If @a app_control is specified with service-application, the application is only allowed to run on which has Background Category. + /// Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif If the appid of @a app_control is not specified, this api is not allowed. In other words, the explicit @a app_control is only allowed. + /// Since 4.0, %http://tizen.org/privilege/appmanager.launch privilege is additionally required. + /// + /// @param[in] app_control The destination app_control to perform a specific task when the alarm is triggered + /// @param[in] delay The amount of time before the first execution (in seconds). Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif, Although this is inexact, the alarm will not fire before this time + /// @param[in] period The amount of time between subsequent alarms (in seconds). Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif, This value does not guarantee the accuracy. The actual interval is calculated by the OS. The minimum value is 600sec + /// @param[out] alarm_id The alarm ID that uniquely identifies an alarm + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_INVALID_TIME Triggered time is invalid + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ALARM_ERROR_NOT_PERMITTED_APP @a app_control is not permitted + /// @see alarm_cancel() + /// @see alarm_cancel_all() + /// @see alarm_get_scheduled_date() + /// @see alarm_get_scheduled_period() + /// @see alarm_schedule_once_after_delay() + int alarm_schedule_after_delay( + ffi.Pointer app_control, + int delay, + int period, + ffi.Pointer alarm_id, + ) { + return _alarm_schedule_after_delay( + app_control, + delay, + period, + alarm_id, + ); + } + + late final _alarm_schedule_after_delay_ptr = + _lookup>( + 'alarm_schedule_after_delay'); + late final _dart_alarm_schedule_after_delay _alarm_schedule_after_delay = + _alarm_schedule_after_delay_ptr + .asFunction<_dart_alarm_schedule_after_delay>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. [Use alarm_schedule_once_at_date() instead] + /// @brief Sets an alarm to be triggered at a specific time. + /// @details The @a date describes the time of the first occurrence. + /// If @a period is bigger than @c 0, the alarm will be scheduled after the @a period time. + /// If @a period is set to @c 0, the alarm will go off just once without repetition. + /// To cancel the alarm, call alarm_cancel() with @a alarm_id. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @remarks If application is uninstalled after setting an alarm, the alarm is cancelled automatically. + /// If the operation of @a app_control is not specified, #APP_CONTROL_OPERATION_DEFAULT is used for the launch request. + /// If the operation of @a app_control is #APP_CONTROL_OPERATION_DEFAULT, the package information is mandatory to explicitly launch the application. + /// + /// @param[in] app_control The destination app_control to perform specific work when the alarm is triggered + /// @param[in] date The first active alarm time + /// @param[in] period The amount of time between subsequent alarms(in second) + /// @param[out] alarm_id The alarm ID that uniquely identifies an alarm + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_INVALID_DATE Triggered date is invalid + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @see alarm_cancel() + /// @see alarm_cancel_all() + /// @see alarm_get_scheduled_date() + /// @see alarm_get_scheduled_period() + int alarm_schedule_at_date( + ffi.Pointer app_control, + ffi.Pointer date, + int period, + ffi.Pointer alarm_id, + ) { + return _alarm_schedule_at_date( + app_control, + date, + period, + alarm_id, + ); + } + + late final _alarm_schedule_at_date_ptr = + _lookup>( + 'alarm_schedule_at_date'); + late final _dart_alarm_schedule_at_date _alarm_schedule_at_date = + _alarm_schedule_at_date_ptr.asFunction<_dart_alarm_schedule_at_date>(); + + /// @brief Sets an alarm to be triggered after a specific time. + /// @details The alarm will go off @a delay seconds later. To cancel the alarm, call alarm_cancel() with @a alarm_id. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @privilege %http://tizen.org/privilege/appmanager.launch + /// @remarks If the application is uninstalled after setting an alarm, the alarm is cancelled automatically. + /// If the operation of @a app_control is not specified, #APP_CONTROL_OPERATION_DEFAULT is used for the launch request. + /// If the operation of @a app_control is #APP_CONTROL_OPERATION_DEFAULT, the package information is mandatory to explicitly launch the application. + /// If the appid of @a app_control is not specified, this api is not allowed. In other words, the explicit @a app_control is only allowed. + /// The @a app_control only supports UI application with this api. If @a app_control is not UI application, #ALARM_ERROR_NOT_PERMITTED_APP returned. + /// When the alarm is expired, Alarm Manager will turn on LCD to prohibit background jobs. + /// Since 4.0, %http://tizen.org/privilege/appmanager.launch privilege is additionally required. + /// + /// @param[in] app_control The destination app_control to perform a specific task when the alarm is triggered + /// @param[in] delay The amount of time before the execution (in seconds) + /// @param[out] alarm_id The alarm ID that uniquely identifies an alarm + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_INVALID_TIME Triggered time is invalid + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ALARM_ERROR_NOT_PERMITTED_APP @a app_control is not permitted. @a app_control for UI application is only permitted. + /// @see alarm_cancel() + /// @see alarm_cancel_all() + /// @see alarm_get_scheduled_date() + int alarm_schedule_once_after_delay( + ffi.Pointer app_control, + int delay, + ffi.Pointer alarm_id, + ) { + return _alarm_schedule_once_after_delay( + app_control, + delay, + alarm_id, + ); + } + + late final _alarm_schedule_once_after_delay_ptr = + _lookup>( + 'alarm_schedule_once_after_delay'); + late final _dart_alarm_schedule_once_after_delay + _alarm_schedule_once_after_delay = _alarm_schedule_once_after_delay_ptr + .asFunction<_dart_alarm_schedule_once_after_delay>(); + + /// @brief Sets an alarm to be triggered at a specific time. + /// @details The @a date describes the time of the first occurrence. To cancel the alarm, call alarm_cancel() with @a alarm_id. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @privilege %http://tizen.org/privilege/appmanager.launch + /// @remarks If application is uninstalled after setting an alarm, the alarm is cancelled automatically. + /// If the operation of @a app_control is not specified, #APP_CONTROL_OPERATION_DEFAULT is used for the launch request. + /// If the operation of @a app_control is #APP_CONTROL_OPERATION_DEFAULT, the package information is mandatory to explicitly launch the application. + /// If the appid of @a app_control is not specified, this api is not allowed. In other words, the explicit @a app_control is only allowed. + /// The @a app_control only supports UI application with this api. If @a app_control is not UI application, #ALARM_ERROR_NOT_PERMITTED_APP returned. + /// When the alarm is expired, Alarm Manager will turn on LCD to prohibit background jobs. + /// Since 4.0, %http://tizen.org/privilege/appmanager.launch privilege is additionally required. + /// + /// @param[in] app_control The destination app_control to perform specific work when the alarm is triggered + /// @param[in] date The first active alarm time + /// @param[out] alarm_id The alarm ID that uniquely identifies an alarm + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_INVALID_DATE Triggered date is invalid + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ALARM_ERROR_NOT_PERMITTED_APP @a app_control is not permitted. @a app_control for UI application is only permitted. + /// @see alarm_cancel() + /// @see alarm_cancel_all() + /// @see alarm_get_scheduled_date() + int alarm_schedule_once_at_date( + ffi.Pointer app_control, + ffi.Pointer date, + ffi.Pointer alarm_id, + ) { + return _alarm_schedule_once_at_date( + app_control, + date, + alarm_id, + ); + } + + late final _alarm_schedule_once_at_date_ptr = + _lookup>( + 'alarm_schedule_once_at_date'); + late final _dart_alarm_schedule_once_at_date _alarm_schedule_once_at_date = + _alarm_schedule_once_at_date_ptr + .asFunction<_dart_alarm_schedule_once_at_date>(); + + /// @brief Sets an alarm to be triggered periodically, starting at a specific time. + /// @details The @a date describes the time of the first occurrence. + /// @a week_flag is the repeat value of the days of the week. + /// If @a week_flag is #ALARM_WEEK_FLAG_TUESDAY, the alarm will repeat every Tuesday at a specific time. + /// To cancel the alarm, call alarm_cancel() with @a alarm_id. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @privilege %http://tizen.org/privilege/appmanager.launch + /// @remarks If the application is uninstalled after setting an alarm, the alarm is cancelled automatically. + /// If the operation of @a app_control is not specified, #APP_CONTROL_OPERATION_DEFAULT is used for the launch request. + /// If the operation of @a app_control is #APP_CONTROL_OPERATION_DEFAULT, the package information is mandatory to explicitly launch the application. + /// Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif, The @a app_control only supports UI application with this api. If @a app_control is not UI application, #ALARM_ERROR_NOT_PERMITTED_APP returned. + /// When the alarm is expired, Alarm Manager will turn on LCD to prohibit background jobs. + /// Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif, If the appid of @a app_control is not specified, this api is not allowed. In other words, the explicit @a app_control is only allowed. + /// Since 4.0, %http://tizen.org/privilege/appmanager.launch privilege is additionally required. + /// + /// @param[in] app_control The destination app_control to perform specific work when the alarm is triggered + /// @param[in] date The first active alarm time + /// @param[in] week_flag The day of the week, @a week_flag may be a combination of days, like #ALARM_WEEK_FLAG_TUESDAY | #ALARM_WEEK_FLAG_FRIDAY + /// @param[out] alarm_id The alarm ID that uniquely identifies an alarm + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_INVALID_DATE Triggered date is invalid + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ALARM_ERROR_NOT_PERMITTED_APP @a app_control is not permitted. @a app_control for UI application is only permitted. + /// @see alarm_cancel() + /// @see alarm_cancel_all() + /// @see alarm_get_scheduled_recurrence_week_flag() + /// @see alarm_get_scheduled_date() + /// @see #alarm_week_flag_e + int alarm_schedule_with_recurrence_week_flag( + ffi.Pointer app_control, + ffi.Pointer date, + int week_flag, + ffi.Pointer alarm_id, + ) { + return _alarm_schedule_with_recurrence_week_flag( + app_control, + date, + week_flag, + alarm_id, + ); + } + + late final _alarm_schedule_with_recurrence_week_flag_ptr = + _lookup>( + 'alarm_schedule_with_recurrence_week_flag'); + late final _dart_alarm_schedule_with_recurrence_week_flag + _alarm_schedule_with_recurrence_week_flag = + _alarm_schedule_with_recurrence_week_flag_ptr + .asFunction<_dart_alarm_schedule_with_recurrence_week_flag>(); + + /// @brief Gets the recurrence days of the week. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.get + /// @remarks If the given @a alarm_id is not obtained by using the alarm_schedule_with_recurrence_week_flag() function, + /// an error (error code #ALARM_ERROR_INVALID_PARAMETER) will occur because this alarm is scheduled with no recurrence. + /// If the operation of @a app_control is not specified, #APP_CONTROL_OPERATION_DEFAULT is used for the launch request. + /// If the operation of @a app_control is #APP_CONTROL_OPERATION_DEFAULT, the package information is mandatory to explicitly launch the application. + /// @param[in] alarm_id The alarm ID returned when the alarm is scheduled + /// @param[out] week_flag The recurrence days of the week, @a week_flag may be a combination of days, like #ALARM_WEEK_FLAG_TUESDAY | #ALARM_WEEK_FLAG_FRIDAY + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @see alarm_schedule_with_recurrence_week_flag() + /// @see #alarm_week_flag_e + int alarm_get_scheduled_recurrence_week_flag( + int alarm_id, + ffi.Pointer week_flag, + ) { + return _alarm_get_scheduled_recurrence_week_flag( + alarm_id, + week_flag, + ); + } + + late final _alarm_get_scheduled_recurrence_week_flag_ptr = + _lookup>( + 'alarm_get_scheduled_recurrence_week_flag'); + late final _dart_alarm_get_scheduled_recurrence_week_flag + _alarm_get_scheduled_recurrence_week_flag = + _alarm_get_scheduled_recurrence_week_flag_ptr + .asFunction<_dart_alarm_get_scheduled_recurrence_week_flag>(); + + /// @brief Cancels the alarm with the specific alarm ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @param[in] alarm_id The alarm ID that is cancelled + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @see alarm_schedule_at_date() + /// @see alarm_schedule_after_delay() + /// @see alarm_schedule_with_recurrence_week_flag() + /// @see alarm_cancel_all() + int alarm_cancel( + int alarm_id, + ) { + return _alarm_cancel( + alarm_id, + ); + } + + late final _alarm_cancel_ptr = + _lookup>('alarm_cancel'); + late final _dart_alarm_cancel _alarm_cancel = + _alarm_cancel_ptr.asFunction<_dart_alarm_cancel>(); + + /// @brief Cancels all scheduled alarms that are registered by the application that calls this API. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @see alarm_schedule_at_date() + /// @see alarm_schedule_after_delay() + /// @see alarm_schedule_with_recurrence_week_flag() + /// @see alarm_cancel() + int alarm_cancel_all() { + return _alarm_cancel_all(); + } + + late final _alarm_cancel_all_ptr = + _lookup>('alarm_cancel_all'); + late final _dart_alarm_cancel_all _alarm_cancel_all = + _alarm_cancel_all_ptr.asFunction<_dart_alarm_cancel_all>(); + + /// @brief Retrieves the IDs of all registered alarms by invoking a callback once for each scheduled alarm. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.get + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @post This function invokes alarm_registered_alarm_cb() repeatedly for each registered alarm. + /// @see alarm_registered_alarm_cb() + int alarm_foreach_registered_alarm( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _alarm_foreach_registered_alarm( + callback, + user_data, + ); + } + + late final _alarm_foreach_registered_alarm_ptr = + _lookup>( + 'alarm_foreach_registered_alarm'); + late final _dart_alarm_foreach_registered_alarm + _alarm_foreach_registered_alarm = _alarm_foreach_registered_alarm_ptr + .asFunction<_dart_alarm_foreach_registered_alarm>(); + + /// @brief Gets the scheduled time from the given alarm ID in C standard time struct. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.get + /// @remarks @a date is not needed by the function after the call. + /// @param[in] alarm_id The alarm ID returned when the alarm is scheduled + /// @param[out] date The time value of the next alarm event + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @see alarm_schedule_at_date() + /// @see alarm_schedule_after_delay() + /// @see alarm_schedule_with_recurrence_week_flag() + int alarm_get_scheduled_date( + int alarm_id, + ffi.Pointer date, + ) { + return _alarm_get_scheduled_date( + alarm_id, + date, + ); + } + + late final _alarm_get_scheduled_date_ptr = + _lookup>( + 'alarm_get_scheduled_date'); + late final _dart_alarm_get_scheduled_date _alarm_get_scheduled_date = + _alarm_get_scheduled_date_ptr + .asFunction<_dart_alarm_get_scheduled_date>(); + + /// @brief Gets the period of time between the recurrent alarms. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.get + /// @remarks If the given @a alarm_id is not obtained by using the alarm_schedule_at_date() or alarm_schedule_after_delay() function, + /// an error (error code #ALARM_ERROR_INVALID_PARAMETER) will occur. + /// @param[in] alarm_id The alarm ID returned when the alarm is scheduled + /// @param[out] period The period of time between recurrent alarms in seconds + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @see alarm_schedule_at_date() + /// @see alarm_schedule_after_delay() + /// @see alarm_schedule_with_recurrence_week_flag() + int alarm_get_scheduled_period( + int alarm_id, + ffi.Pointer period, + ) { + return _alarm_get_scheduled_period( + alarm_id, + period, + ); + } + + late final _alarm_get_scheduled_period_ptr = + _lookup>( + 'alarm_get_scheduled_period'); + late final _dart_alarm_get_scheduled_period _alarm_get_scheduled_period = + _alarm_get_scheduled_period_ptr + .asFunction<_dart_alarm_get_scheduled_period>(); + + /// @brief Gets the current system time using C standard time struct. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] date The current system time + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + int alarm_get_current_time( + ffi.Pointer date, + ) { + return _alarm_get_current_time( + date, + ); + } + + late final _alarm_get_current_time_ptr = + _lookup>( + 'alarm_get_current_time'); + late final _dart_alarm_get_current_time _alarm_get_current_time = + _alarm_get_current_time_ptr.asFunction<_dart_alarm_get_current_time>(); + + /// @brief Gets the app_control to be invoked when the alarm is triggered. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.get + /// @remarks The @a app_control must be released using app_control_destroy(). + /// @param[in] alarm_id The alarm ID uniquely identifies an alarm + /// @param[out] app_control The app_control handle to launch when the alarm is triggered + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @see alarm_schedule_at_date() + /// @see alarm_schedule_after_delay() + /// @see alarm_schedule_with_recurrence_week_flag() + int alarm_get_app_control( + int alarm_id, + ffi.Pointer> app_control, + ) { + return _alarm_get_app_control( + alarm_id, + app_control, + ); + } + + late final _alarm_get_app_control_ptr = + _lookup>( + 'alarm_get_app_control'); + late final _dart_alarm_get_app_control _alarm_get_app_control = + _alarm_get_app_control_ptr.asFunction<_dart_alarm_get_app_control>(); + + /// @brief Sets global flag in the alarm. + /// @details Sets @a global flag to set/unset alarm globally. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @remarks The @a alarm_id must be id of alarm which will launch global application. + /// The function returns an error (error code #ALARM_ERROR_NOT_PERMITTED_APP) if it is not. + /// Note that the application which is launched by global alarm runs in the user session that is logged in currently. + /// It doesn't run in the session for the user who registers the global alarm. + /// So, if the application uses application's private data for each user to handling the app_control for the alarm, it might not show proper data to the user. + /// Therefore, We recommend to contain all the data for the alarm to the app_control handle for the global alarm. + /// Then, the launched application would be able to use the data to show proper alarm UX to the user. + /// @param[in] alarm_id The alarm ID uniquely identifies an alarm + /// @param[in] global The global flag to set/unset alarm globally + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_NOT_PERMITTED_APP @a alarm_id is not permitted + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @see alarm_schedule_at_date() + /// @see alarm_schedule_after_delay() + /// @see alarm_schedule_with_recurrence_week_flag() + int alarm_set_global( + int alarm_id, + bool global, + ) { + return _alarm_set_global( + alarm_id, + global ? 1 : 0, + ); + } + + late final _alarm_set_global_ptr = + _lookup>('alarm_set_global'); + late final _dart_alarm_set_global _alarm_set_global = + _alarm_set_global_ptr.asFunction<_dart_alarm_set_global>(); + + /// @brief Gets whether the alarm will launch global application or not. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.get + /// @param[in] alarm_id The alarm ID uniquely identifies an alarm + /// @param[out] global Whether the alarm will launch global application or not + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @see alarm_set_global() + int alarm_get_global( + int alarm_id, + ffi.Pointer global, + ) { + return _alarm_get_global( + alarm_id, + global, + ); + } + + late final _alarm_get_global_ptr = + _lookup>('alarm_get_global'); + late final _dart_alarm_get_global _alarm_get_global = + _alarm_get_global_ptr.asFunction<_dart_alarm_get_global>(); + + /// @brief Sets a notification alarm to be triggered at a specific time. + /// @details The @a date describes the time of the alarm occurrence. + /// To cancel the alarm, call alarm_cancel() with @a alarm_id. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @privilege %http://tizen.org/privilege/notification + /// @remarks If application is uninstalled after setting an alarm, the alarm is cancelled automatically. + /// When the alarm goes off, Alarm Manager will turn on LCD to prohibit background jobs. + /// + /// @param[in] noti The notification to be posted when the alarm is triggered + /// @param[in] date The active alarm time + /// @param[out] alarm_id The ID which uniquely identifies the scheduled alarm + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_INVALID_DATE Triggered date is invalid + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @see alarm_cancel() + /// @see alarm_cancel_all() + /// @see alarm_get_scheduled_date() + int alarm_schedule_noti_once_at_date( + ffi.Pointer noti, + ffi.Pointer date, + ffi.Pointer alarm_id, + ) { + return _alarm_schedule_noti_once_at_date( + noti, + date, + alarm_id, + ); + } + + late final _alarm_schedule_noti_once_at_date_ptr = + _lookup>( + 'alarm_schedule_noti_once_at_date'); + late final _dart_alarm_schedule_noti_once_at_date + _alarm_schedule_noti_once_at_date = _alarm_schedule_noti_once_at_date_ptr + .asFunction<_dart_alarm_schedule_noti_once_at_date>(); + + /// @brief Sets a notification alarm to be triggered after a specific delay. + /// @details The alarm will first go off after @a delay seconds. + /// The alarm will then go off every period seconds until canceled. + /// To cancel the alarm, call alarm_cancel() with @a alarm_id. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @privilege %http://tizen.org/privilege/notification + /// @remarks If the application is uninstalled after setting an alarm, the alarm is cancelled automatically. + /// This function is a minimally intrusive way to trigger alarms when precision is not important. + /// The system will adjust the @a delay and @a period requests to suit internal needs; the requests + /// will be treated as minimum values. Note that @a period cannot be less than 600 seconds, if + /// a smaller request is supplied it will be silently adjusted to a request of 600. + /// When the alarm goes off, Alarm Manager will turn on LCD to prohibit background jobs. + /// + /// @param[in] noti The notification to be posted when the alarm is triggered + /// @param[in] delay The amount of time before the first execution (in seconds). + /// @param[in] period The amount of time between subsequent alarms (in seconds). + /// @param[out] alarm_id The ID which uniquely identifies the scheduled alarm + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_INVALID_TIME Triggered time is invalid + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @see alarm_cancel() + /// @see alarm_cancel_all() + /// @see alarm_get_scheduled_date() + /// @see alarm_get_scheduled_period() + /// @see alarm_schedule_noti_once_after_delay() + int alarm_schedule_noti_after_delay( + ffi.Pointer noti, + int delay, + int period, + ffi.Pointer alarm_id, + ) { + return _alarm_schedule_noti_after_delay( + noti, + delay, + period, + alarm_id, + ); + } + + late final _alarm_schedule_noti_after_delay_ptr = + _lookup>( + 'alarm_schedule_noti_after_delay'); + late final _dart_alarm_schedule_noti_after_delay + _alarm_schedule_noti_after_delay = _alarm_schedule_noti_after_delay_ptr + .asFunction<_dart_alarm_schedule_noti_after_delay>(); + + /// @brief Sets a notification alarm to be triggered after a specific delay. + /// @details The alarm will go off @a delay seconds later. + /// To cancel the alarm, call alarm_cancel() with @a alarm_id. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @privilege %http://tizen.org/privilege/notification + /// @remarks If the application is uninstalled after setting an alarm, the alarm is cancelled automatically. + /// When the alarm goes off, Alarm Manager will turn on LCD to prohibit background jobs. + /// + /// @param[in] noti The notification to be posted when the alarm is triggered + /// @param[in] delay The amount of time before the execution (in seconds) + /// @param[out] alarm_id The ID which uniquely identifies the scheduled alarm + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_INVALID_TIME Triggered time is invalid + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @see alarm_cancel() + /// @see alarm_cancel_all() + /// @see alarm_get_scheduled_date() + int alarm_schedule_noti_once_after_delay( + ffi.Pointer noti, + int delay, + ffi.Pointer alarm_id, + ) { + return _alarm_schedule_noti_once_after_delay( + noti, + delay, + alarm_id, + ); + } + + late final _alarm_schedule_noti_once_after_delay_ptr = + _lookup>( + 'alarm_schedule_noti_once_after_delay'); + late final _dart_alarm_schedule_noti_once_after_delay + _alarm_schedule_noti_once_after_delay = + _alarm_schedule_noti_once_after_delay_ptr + .asFunction<_dart_alarm_schedule_noti_once_after_delay>(); + + /// @brief Sets a notification to be triggered periodically, starting at a specific time. + /// @details The @a date describes the time of the first occurrence. + /// @a week_flag describes the day(s) of the week when the notification recurs. + /// If @a week_flag is #ALARM_WEEK_FLAG_TUESDAY, the alarm will repeat every Tuesday at a specific time. + /// If @a week_flag is less than or equal to zero, the alarm is not repeated. + /// To cancel the alarm, call alarm_cancel() with @a alarm_id. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @privilege %http://tizen.org/privilege/notification + /// @remarks If the application is uninstalled after setting an alarm, the alarm is cancelled automatically. + /// + /// @param[in] noti The notification to be posted when the alarm is triggered + /// @param[in] date The first active alarm time + /// @param[in] week_flag The day of the week the notification recurs. @a week_flag may be a combination of days, like #ALARM_WEEK_FLAG_TUESDAY | #ALARM_WEEK_FLAG_FRIDAY + /// @param[out] alarm_id The ID which uniquely identifies the scheduled alarm + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_INVALID_DATE Triggered date is invalid + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @see alarm_cancel() + /// @see alarm_cancel_all() + /// @see alarm_get_scheduled_recurrence_week_flag() + /// @see alarm_get_scheduled_date() + /// @see #alarm_week_flag_e + int alarm_schedule_noti_with_recurrence_week_flag( + ffi.Pointer noti, + ffi.Pointer date, + int week_flag, + ffi.Pointer alarm_id, + ) { + return _alarm_schedule_noti_with_recurrence_week_flag( + noti, + date, + week_flag, + alarm_id, + ); + } + + late final _alarm_schedule_noti_with_recurrence_week_flag_ptr = _lookup< + ffi.NativeFunction<_c_alarm_schedule_noti_with_recurrence_week_flag>>( + 'alarm_schedule_noti_with_recurrence_week_flag'); + late final _dart_alarm_schedule_noti_with_recurrence_week_flag + _alarm_schedule_noti_with_recurrence_week_flag = + _alarm_schedule_noti_with_recurrence_week_flag_ptr + .asFunction<_dart_alarm_schedule_noti_with_recurrence_week_flag>(); + + /// @brief Gets the notification to be posted when an alarm is triggered. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.get + /// @remarks @a noti must be released using notification_free(). + /// + /// @param[in] alarm_id The ID which uniquely identifies a scheduled alarm + /// @param[out] noti The notification to be posted when the alarm is triggered + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @see alarm_schedule_noti_once_at_date() + /// @see alarm_schedule_noti_after_delay() + /// @see alarm_schedule_noti_once_after_delay() + /// @see alarm_schedule_noti_with_recurrence_week_flag() + int alarm_get_notification( + int alarm_id, + ffi.Pointer> noti, + ) { + return _alarm_get_notification( + alarm_id, + noti, + ); + } + + late final _alarm_get_notification_ptr = + _lookup>( + 'alarm_get_notification'); + late final _dart_alarm_get_notification _alarm_get_notification = + _alarm_get_notification_ptr.asFunction<_dart_alarm_get_notification>(); + + /// @brief Updates the delay of the registered alarm. + /// @details The @a delay is the time (in seconds) before the alarm's first setting off. + /// The delay is an exact value, see alarm_schedule_once_after_delay() for details. + /// This function can be called for any alarm. + /// If the delay was set before, it will be overwritten. If it was not, it will be set. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @remarks This function can be called only for alarms whose app control launches an UI application. + /// If this condition is not met, #ALARM_ERROR_NOT_PERMITTED_APP is returned. + /// @param[in] alarm_id The ID which uniquely identifies the scheduled alarm + /// @param[in] delay The amount of time before the first execution (in seconds). + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ALARM_ERROR_NOT_PERMITTED_APP App control does not launch an UI application + int alarm_update_delay( + int alarm_id, + int delay, + ) { + return _alarm_update_delay( + alarm_id, + delay, + ); + } + + late final _alarm_update_delay_ptr = + _lookup>('alarm_update_delay'); + late final _dart_alarm_update_delay _alarm_update_delay = + _alarm_update_delay_ptr.asFunction<_dart_alarm_update_delay>(); + + /// @brief Updates the date of the registered alarm. + /// @details The @a date describes the date on which the alarm is set off for the first time. + /// This function can be called for any alarm. + /// If the date was set before, it will be overwritten. If it was not, it will be set. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @remarks This function can be called only for alarms whose app control launches an UI application. + /// If this condition is not met, #ALARM_ERROR_NOT_PERMITTED_APP is returned. + /// @param[in] alarm_id The ID which uniquely identifies the scheduled alarm + /// @param[in] date The time value of the next alarm event + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_INVALID_TIME Triggered time is invalid + /// @retval #ALARM_ERROR_INVALID_DATE Triggered time is invalid + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ALARM_ERROR_NOT_PERMITTED_APP App control does not launch an UI application + int alarm_update_date( + int alarm_id, + ffi.Pointer date, + ) { + return _alarm_update_date( + alarm_id, + date, + ); + } + + late final _alarm_update_date_ptr = + _lookup>('alarm_update_date'); + late final _dart_alarm_update_date _alarm_update_date = + _alarm_update_date_ptr.asFunction<_dart_alarm_update_date>(); + + /// @brief Updates the period of the registered alarm. + /// @details The alarm will then go off every @a period seconds until canceled. + /// This function can be called for any alarm. + /// If the week recurrence flag was set before, it will be removed and the period will be set. + /// If the period was set before, it will be overwritten. If it was not, it will be set. + /// If the @a period argument is 0 and the period was previously set, + /// the period attribute will be cleared and the alarm will be changed to one-time. + /// If the @a period argument is 0 and the period was not set, + /// or the week recurrence flag was set, the alarm will be unchanged. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @param[in] alarm_id The ID which uniquely identifies the scheduled alarm + /// @param[in] period The amount of time between subsequent alarms (in seconds). + /// Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif, this + /// value does not guarantee the accuracy. The actual interval + /// is calculated by the OS. The minimum value is 600sec. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + int alarm_update_period( + int alarm_id, + int period, + ) { + return _alarm_update_period( + alarm_id, + period, + ); + } + + late final _alarm_update_period_ptr = + _lookup>( + 'alarm_update_period'); + late final _dart_alarm_update_period _alarm_update_period = + _alarm_update_period_ptr.asFunction<_dart_alarm_update_period>(); + + /// @brief Updates the week recurrence flag of the registered alarm. + /// @details @a week_flag is the repeat value of the days of the week. + /// For example, if @a week_flag is #ALARM_WEEK_FLAG_TUESDAY, the alarm will repeat every + /// Tuesday at a specific time. + /// This function can be called for any alarm. + /// If the period was set before, it will be removed and the week recurrence flag will be set. + /// If the week recurrence flag was set before, it will be overwritten. If it was not, it will be set. + /// If the @a week_flag argument is 0 and the flag was previously set, + /// the flag attribute will be cleared and the alarm will be changed to one-time. + /// If the @a week_flag argument is 0 and the flag was not set, + /// or the period was set, the alarm will be unchanged. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/alarm.set + /// @remarks This function can be called only for alarms whose app control launches an UI application. + /// If this condition is not met, #ALARM_ERROR_NOT_PERMITTED_APP is returned. + /// @param[in] alarm_id The ID which uniquely identifies the scheduled alarm + /// @param[in] week_flag The day of the week, @a week_flag may be a combination + /// of days, like #ALARM_WEEK_FLAG_TUESDAY | #ALARM_WEEK_FLAG_FRIDAY + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #ALARM_ERROR_NONE Successful + /// @retval #ALARM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ALARM_ERROR_CONNECTION_FAIL Failed to connect to an alarm server + /// @retval #ALARM_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ALARM_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ALARM_ERROR_NOT_PERMITTED_APP App control does not launch an UI application + int alarm_update_week_flag( + int alarm_id, + int week_flag, + ) { + return _alarm_update_week_flag( + alarm_id, + week_flag, + ); + } + + late final _alarm_update_week_flag_ptr = + _lookup>( + 'alarm_update_week_flag'); + late final _dart_alarm_update_week_flag _alarm_update_week_flag = + _alarm_update_week_flag_ptr.asFunction<_dart_alarm_update_week_flag>(); + + /// @brief Adds the event handler for receiving event-data of interested events. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks If you want to add the privileged event, you MUST declare right privilege first. Unless that, this function returns #EVENT_ERROR_PERMISSION_DENIED. The privileged events are commented on remarks of it's definitions. + /// @param[in] event_name The interested event name + /// @param[in] callback The event callback called when the event occurs + /// @param[in] user_data The user data for passing to callback + /// @param[out] event_handler The event handler + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EVENT_ERROR_NONE Successful + /// @retval #EVENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EVENT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #EVENT_ERROR_IO_ERROR Adding handler failed + /// @retval #EVENT_ERROR_OUT_OF_MEMORY Out of memory + int event_add_event_handler( + ffi.Pointer event_name, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer> event_handler, + ) { + return _event_add_event_handler( + event_name, + callback, + user_data, + event_handler, + ); + } + + late final _event_add_event_handler_ptr = + _lookup>( + 'event_add_event_handler'); + late final _dart_event_add_event_handler _event_add_event_handler = + _event_add_event_handler_ptr.asFunction<_dart_event_add_event_handler>(); + + /// @brief Removes the registered event handler. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] event_handler The event handler + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EVENT_ERROR_NONE Successful + /// @retval #EVENT_ERROR_INVALID_PARAMETER Invalid parameter + int event_remove_event_handler( + ffi.Pointer event_handler, + ) { + return _event_remove_event_handler( + event_handler, + ); + } + + late final _event_remove_event_handler_ptr = + _lookup>( + 'event_remove_event_handler'); + late final _dart_event_remove_event_handler _event_remove_event_handler = + _event_remove_event_handler_ptr + .asFunction<_dart_event_remove_event_handler>(); + + /// @brief Sends the User-Event to receiver applications. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks The format of User-Event's name MUST be "event.{sender's appid}.{user-defined name}", refer to 'The name-format of User-Event' section, If the event_name is invalid, the function returns #EVENT_ERROR_IO_ERROR. + /// @param[in] event_name The event's name to send + /// @param[in] event_data The event's data to send + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EVENT_ERROR_NONE Successful + /// @retval #EVENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EVENT_ERROR_IO_ERROR Sending operation failed + int event_publish_app_event( + ffi.Pointer event_name, + ffi.Pointer event_data, + ) { + return _event_publish_app_event( + event_name, + event_data, + ); + } + + late final _event_publish_app_event_ptr = + _lookup>( + 'event_publish_app_event'); + late final _dart_event_publish_app_event _event_publish_app_event = + _event_publish_app_event_ptr.asFunction<_dart_event_publish_app_event>(); + + /// @brief Sends the User-Event to trusted receiver-applications. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks The application which has same certification with sender can receive the event. + /// @remarks The format of User-Event's name MUST be "event.{sender's appid}.{user-defined name}", refer to 'The name-format of User-Event' section, If the event_name is invalid, the function returns #EVENT_ERROR_IO_ERROR. + /// @param[in] event_name The event's name to send + /// @param[in] event_data The event's data to send + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EVENT_ERROR_NONE Successful + /// @retval #EVENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EVENT_ERROR_IO_ERROR Sending operation failed + int event_publish_trusted_app_event( + ffi.Pointer event_name, + ffi.Pointer event_data, + ) { + return _event_publish_trusted_app_event( + event_name, + event_data, + ); + } + + late final _event_publish_trusted_app_event_ptr = + _lookup>( + 'event_publish_trusted_app_event'); + late final _dart_event_publish_trusted_app_event + _event_publish_trusted_app_event = _event_publish_trusted_app_event_ptr + .asFunction<_dart_event_publish_trusted_app_event>(); + + /// @brief Keeps last User-Event data for receiver applications. + /// + /// @since_tizen 3.0 + /// @remarks The receiver applications will receive this last event data after adding their new handlers via event_add_event_handler() API since the sender application called this API. + /// @remarks If a sender application sends same event via trusted API and non-trusted API, then a trusted receiver will get latest data regardless of trusted or non-trusted, but non-trusted receiver will get the last data only from non-trusted API. + /// @remarks The effect of this API continues during runtime. That means when the sender application process restarts, the sender application needs to call this api again to make the event to keep the last event. + /// @param[in] event_name The event's name to keep last event data + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EVENT_ERROR_NONE Successful + /// @retval #EVENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EVENT_ERROR_IO_ERROR Sending operation failed + /// @retval #EVENT_ERROR_OUT_OF_MEMORY Out of memory + int event_keep_last_event_data( + ffi.Pointer event_name, + ) { + return _event_keep_last_event_data( + event_name, + ); + } + + late final _event_keep_last_event_data_ptr = + _lookup>( + 'event_keep_last_event_data'); + late final _dart_event_keep_last_event_data _event_keep_last_event_data = + _event_keep_last_event_data_ptr + .asFunction<_dart_event_keep_last_event_data>(); + + /// @brief Creates the job info handle. + /// @since_tizen 4.0 + /// @remarks The @a job_info must be released by using job_info_destroy(). + /// The job will be started by the periodic interval or the trigger events. + /// @param[out] job_info The job info handle to be newly created on success + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #JOB_ERROR_OUT_OF_MEMORY Out of memory + /// @see job_info_destroy() + /// @see job_info_set_periodic() + /// @see job_info_add_trigger_event() + int job_info_create( + ffi.Pointer> job_info, + ) { + return _job_info_create( + job_info, + ); + } + + late final _job_info_create_ptr = + _lookup>('job_info_create'); + late final _dart_job_info_create _job_info_create = + _job_info_create_ptr.asFunction<_dart_job_info_create>(); + + /// @brief Destroys the job info handle and releases all its resources. + /// @since_tizen 4.0 + /// @param[in] job_info The job info handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @see job_info_create() + int job_info_destroy( + ffi.Pointer job_info, + ) { + return _job_info_destroy( + job_info, + ); + } + + late final _job_info_destroy_ptr = + _lookup>('job_info_destroy'); + late final _dart_job_info_destroy _job_info_destroy = + _job_info_destroy_ptr.asFunction<_dart_job_info_destroy>(); + + /// @brief Sets the periodic interval of the job. + /// @since_tizen 4.0 + /// @remarks The platform does not guarantee the accuracy of the given interval for minimizing the wakeups of the device. + /// Thus you should not rely on it for timing. + /// If this function is called after adding the job trigger events by using job_info_add_trigger_event(), + /// the function returns a negative error value. + /// @param[in] job_info The job info handle + /// @param[in] interval The periodic interval (in minutes) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @see job_info_destroy() + int job_info_set_periodic( + ffi.Pointer job_info, + int interval, + ) { + return _job_info_set_periodic( + job_info, + interval, + ); + } + + late final _job_info_set_periodic_ptr = + _lookup>( + 'job_info_set_periodic'); + late final _dart_job_info_set_periodic _job_info_set_periodic = + _job_info_set_periodic_ptr.asFunction<_dart_job_info_set_periodic>(); + + /// @brief Sets the job to be automatically scheduled after the device reboots. + /// @since_tizen 4.0 + /// @remarks If it's a one-time job, setting it to a persistent job returns + /// a negative error value on scheduling by using job_scheduler_schedule(). + /// @param[in] job_info The job info handle + /// @param[in] persistent @c true, if the job needs to be automatically scheduled + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @see job_info_set_once() + /// @see job_scheduler_schedule() + int job_info_set_persistent( + ffi.Pointer job_info, + bool persistent, + ) { + return _job_info_set_persistent( + job_info, + persistent ? 1 : 0, + ); + } + + late final _job_info_set_persistent_ptr = + _lookup>( + 'job_info_set_persistent'); + late final _dart_job_info_set_persistent _job_info_set_persistent = + _job_info_set_persistent_ptr.asFunction<_dart_job_info_set_persistent>(); + + /// @brief Sets the job not to be repeated. + /// @since_tizen 4.0 + /// @remarks If it's a persistent job, setting it to a one-time job returns + /// a negative error value on scheduling by using job_scheduler_schedule(). + /// @param[in] job_info The job info handle + /// @param[in] once @c true, if the job does not need to be repeated + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @see job_info_set_persistent() + /// @see job_scheduler_schedule() + int job_info_set_once( + ffi.Pointer job_info, + bool once, + ) { + return _job_info_set_once( + job_info, + once ? 1 : 0, + ); + } + + late final _job_info_set_once_ptr = + _lookup>('job_info_set_once'); + late final _dart_job_info_set_once _job_info_set_once = + _job_info_set_once_ptr.asFunction<_dart_job_info_set_once>(); + + /// @brief Sets the timeout interval of the requirements. + /// @since_tizen 4.0 + /// @remarks If the requirements are not satisfied within the timeout value, + /// the job does not start. + /// @param[in] job_info The job info handle + /// @param[in] timeout The timeout interval (ms) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + int job_info_set_requirement_timeout( + ffi.Pointer job_info, + int timeout, + ) { + return _job_info_set_requirement_timeout( + job_info, + timeout, + ); + } + + late final _job_info_set_requirement_timeout_ptr = + _lookup>( + 'job_info_set_requirement_timeout'); + late final _dart_job_info_set_requirement_timeout + _job_info_set_requirement_timeout = _job_info_set_requirement_timeout_ptr + .asFunction<_dart_job_info_set_requirement_timeout>(); + + /// @brief Sets that the battery level must not be low to run the job. + /// @since_tizen 4.0 + /// @param[in] job_info The job info handle + /// @param[in] battery_not_low @c true, the battery level must not be low. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #JOB_ERROR_IO_ERROR IO error + /// @retval #JOB_ERROR_NOT_INITIALIZED Not initialized + /// @retval #JOB_ERROR_NOT_SUPPORTED Not supported + /// @pre job_scheduler_init() must be called. + /// @see job_scheduler_init() + int job_info_set_requires_battery_not_low( + ffi.Pointer job_info, + bool battery_not_low, + ) { + return _job_info_set_requires_battery_not_low( + job_info, + battery_not_low ? 1 : 0, + ); + } + + late final _job_info_set_requires_battery_not_low_ptr = + _lookup>( + 'job_info_set_requires_battery_not_low'); + late final _dart_job_info_set_requires_battery_not_low + _job_info_set_requires_battery_not_low = + _job_info_set_requires_battery_not_low_ptr + .asFunction<_dart_job_info_set_requires_battery_not_low>(); + + /// @brief Sets that the battery must be charging to run the job. + /// @since_tizen 4.0 + /// @param[in] job_info The job info handle + /// @param[in] charging @c true, the battery must be charging. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #JOB_ERROR_IO_ERROR IO error + /// @retval #JOB_ERROR_NOT_INITIALIZED Not initialized + /// @retval #JOB_ERROR_NOT_SUPPORTED Not supported + /// @pre job_scheduler_init() must be called. + /// @see job_scheduler_init() + int job_info_set_requires_charging( + ffi.Pointer job_info, + bool charging, + ) { + return _job_info_set_requires_charging( + job_info, + charging ? 1 : 0, + ); + } + + late final _job_info_set_requires_charging_ptr = + _lookup>( + 'job_info_set_requires_charging'); + late final _dart_job_info_set_requires_charging + _job_info_set_requires_charging = _job_info_set_requires_charging_ptr + .asFunction<_dart_job_info_set_requires_charging>(); + + /// @brief Sets that the WiFi must be connected to run the job. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @param[in] job_info The job info handle + /// @param[in] wifi_connection @c true, the WiFi must be connected. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #JOB_ERROR_IO_ERROR IO error + /// @retval #JOB_ERROR_NOT_INITIALIZED Not initialized + /// @retval #JOB_ERROR_NOT_SUPPORTED Not supported + /// @retval #JOB_ERROR_PERMISSION_DENIED Permission denied + /// @pre job_scheduler_init() must be called. + /// @see job_scheduler_init() + int job_info_set_requires_wifi_connection( + ffi.Pointer job_info, + bool wifi_connection, + ) { + return _job_info_set_requires_wifi_connection( + job_info, + wifi_connection ? 1 : 0, + ); + } + + late final _job_info_set_requires_wifi_connection_ptr = + _lookup>( + 'job_info_set_requires_wifi_connection'); + late final _dart_job_info_set_requires_wifi_connection + _job_info_set_requires_wifi_connection = + _job_info_set_requires_wifi_connection_ptr + .asFunction<_dart_job_info_set_requires_wifi_connection>(); + + /// @brief Adds the trigger event to the job info handle. + /// @since_tizen 4.0 + /// @remarks The periodic interval of the job info handle must be 0. + /// If the interval of the job info handle is not 0, this function returns a negative error value. + /// Regarding the @a event, the application may require the following privilege: + /// http://tizen.org/privilege/network.get @n + /// If the application does not have the necessary privilege, this function returns #JOB_ERROR_PERMISSION_DENIED. + /// See #job_trigger_event_e to find the corresponding privilege of each event. + /// @param[in] job_info The job info handle + /// @param[in] event The job trigger event + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #JOB_ERROR_IO_ERROR IO error + /// @retval #JOB_ERROR_NOT_INITIALIZED Not initialized + /// @retval #JOB_ERROR_NOT_SUPPORTED Not supported + /// @retval #JOB_ERROR_ALREADY_EXIST Already exist + /// @retval #JOB_ERROR_PERMISSION_DENIED Permission denied + /// @pre job_scheduler_init() must be called. + /// @see job_scheduler_init() + /// @see job_info_remove_trigger_event() + /// @see job_trigger_event_e + int job_info_add_trigger_event( + ffi.Pointer job_info, + int event, + ) { + return _job_info_add_trigger_event( + job_info, + event, + ); + } + + late final _job_info_add_trigger_event_ptr = + _lookup>( + 'job_info_add_trigger_event'); + late final _dart_job_info_add_trigger_event _job_info_add_trigger_event = + _job_info_add_trigger_event_ptr + .asFunction<_dart_job_info_add_trigger_event>(); + + /// @brief Removes the trigger event from the job info handle. + /// @since_tizen 4.0 + /// @remarks The periodic interval of the job info handle must be 0. + /// If the interval of the job info handle is not 0, this function returns a negative error value. + /// @param[in] job_info The job info handle + /// @param[in] event The job trigger event + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @see job_info_add_trigger_event() + /// @see job_trigger_event_e + int job_info_remove_trigger_event( + ffi.Pointer job_info, + int event, + ) { + return _job_info_remove_trigger_event( + job_info, + event, + ); + } + + late final _job_info_remove_trigger_event_ptr = + _lookup>( + 'job_info_remove_trigger_event'); + late final _dart_job_info_remove_trigger_event + _job_info_remove_trigger_event = _job_info_remove_trigger_event_ptr + .asFunction<_dart_job_info_remove_trigger_event>(); + + /// @brief Gets the ID of the job. + /// @since_tizen 4.0 + /// @remarks The @a job_info must be scheduled by using job_scheduler_schedule(). + /// If the job_info is not scheduled, this function returns a negative error value. + /// The @a job_id must be released by using free(). + /// @param[in] job_info The job info handle + /// @param[out] job_id The ID of the job + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #JOB_ERROR_OUT_OF_MEMORY Out of memory + /// @see job_scheduler_schedule() + int job_info_get_job_id( + ffi.Pointer job_info, + ffi.Pointer> job_id, + ) { + return _job_info_get_job_id( + job_info, + job_id, + ); + } + + late final _job_info_get_job_id_ptr = + _lookup>( + 'job_info_get_job_id'); + late final _dart_job_info_get_job_id _job_info_get_job_id = + _job_info_get_job_id_ptr.asFunction<_dart_job_info_get_job_id>(); + + /// @brief Clones the given job_info handle. + /// @since_tizen 4.0 + /// @remarks The newly created job_info handle must be released by using job_info_destroy(). + /// @param[in] job_info The job info handle + /// @param[out] clone If successful, a newly created job info handle will be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #JOB_ERROR_OUT_OF_MEMORY Out of memory + /// @see job_info_destroy() + int job_info_clone( + ffi.Pointer job_info, + ffi.Pointer> clone, + ) { + return _job_info_clone( + job_info, + clone, + ); + } + + late final _job_info_clone_ptr = + _lookup>('job_info_clone'); + late final _dart_job_info_clone _job_info_clone = + _job_info_clone_ptr.asFunction<_dart_job_info_clone>(); + + /// @brief Initializes the job scheduler. + /// @since_tizen 4.0 + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_IO_ERROR IO error + /// @retval #JOB_ERROR_OUT_OF_MEMORY Out of memory + /// @see job_scheduler_finish() + int job_scheduler_init() { + return _job_scheduler_init(); + } + + late final _job_scheduler_init_ptr = + _lookup>('job_scheduler_init'); + late final _dart_job_scheduler_init _job_scheduler_init = + _job_scheduler_init_ptr.asFunction<_dart_job_scheduler_init>(); + + /// @brief Finalizes the job scheduler. + /// @since_tizen 4.0 + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_NOT_INITIALIZED Not initialized + /// @see job_scheduler_init() + int job_scheduler_finish() { + return _job_scheduler_finish(); + } + + late final _job_scheduler_finish_ptr = + _lookup>( + 'job_scheduler_finish'); + late final _dart_job_scheduler_finish _job_scheduler_finish = + _job_scheduler_finish_ptr.asFunction<_dart_job_scheduler_finish>(); + + /// @brief Schedules the job. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/appmanager.launch + /// @param[in] job_info The job info handle + /// @param[in] job_id The ID of the job + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #JOB_ERROR_NOT_INITIALIZED Not initialized + /// @retval #JOB_ERROR_IO_ERROR IO error + /// @retval #JOB_ERROR_ALREADY_EXIST Already exist + /// @retval #JOB_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #JOB_ERROR_PERMISSION_DENIED Permission denied + /// @pre job_scheduler_init() MUST be called. + /// @see job_scheduler_init() + /// @see job_info_create() + int job_scheduler_schedule( + ffi.Pointer job_info, + ffi.Pointer job_id, + ) { + return _job_scheduler_schedule( + job_info, + job_id, + ); + } + + late final _job_scheduler_schedule_ptr = + _lookup>( + 'job_scheduler_schedule'); + late final _dart_job_scheduler_schedule _job_scheduler_schedule = + _job_scheduler_schedule_ptr.asFunction<_dart_job_scheduler_schedule>(); + + /// @brief Cancels the scheduled job. + /// @since_tizen 4.0 + /// @param[in] job_id The ID of the scheduled job + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #JOB_ERROR_NOT_INITIALIZED Not initialized + /// @retval #JOB_ERROR_IO_ERROR IO error + /// @retval #JOB_ERROR_NO_SUCH_JOB No such job + /// @pre job_scheduler_init() MUST be called. + /// @see job_scheduler_init() + int job_scheduler_cancel( + ffi.Pointer job_id, + ) { + return _job_scheduler_cancel( + job_id, + ); + } + + late final _job_scheduler_cancel_ptr = + _lookup>( + 'job_scheduler_cancel'); + late final _dart_job_scheduler_cancel _job_scheduler_cancel = + _job_scheduler_cancel_ptr.asFunction<_dart_job_scheduler_cancel>(); + + /// @brief Cancels all scheduled jobs. + /// @since_tizen 4.0 + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_NOT_INITIALIZED Not initialized + /// @retval #JOB_ERROR_IO_ERROR IO error + /// @pre job_scheduler_init() MUST be called. + /// @see job_scheduler_init() + int job_scheduler_cancel_all() { + return _job_scheduler_cancel_all(); + } + + late final _job_scheduler_cancel_all_ptr = + _lookup>( + 'job_scheduler_cancel_all'); + late final _dart_job_scheduler_cancel_all _job_scheduler_cancel_all = + _job_scheduler_cancel_all_ptr + .asFunction<_dart_job_scheduler_cancel_all>(); + + /// @brief Notifies that the job is finished. + /// @since_tizen 4.0 + /// @remarks If the job has been launched, the system kept awake for a while. + /// It is highly recommended to notify that the job is done, + /// the system thus knows it does not need to be kept awake. + /// @param[in] job_id The ID of the scheduled job + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #JOB_ERROR_NOT_INITIALIZED Not initialized + /// @retval #JOB_ERROR_NO_SUCH_JOB No such job + /// @retval #JOB_ERROR_IO_ERROR IO error + /// @pre job_scheduler_init() MUST be called. + /// @see job_scheduler_init() + int job_scheduler_notify_job_finished( + ffi.Pointer job_id, + ) { + return _job_scheduler_notify_job_finished( + job_id, + ); + } + + late final _job_scheduler_notify_job_finished_ptr = + _lookup>( + 'job_scheduler_notify_job_finished'); + late final _dart_job_scheduler_notify_job_finished + _job_scheduler_notify_job_finished = + _job_scheduler_notify_job_finished_ptr + .asFunction<_dart_job_scheduler_notify_job_finished>(); + + /// @brief Retrieves all scheduled jobs. + /// @since_tizen 4.0 + /// @param[in] callback The iteration callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #JOB_ERROR_NOT_INITIALIZED Not initialized + /// @retval #JOB_ERROR_NO_SUCH_JOB No scheduled jobs + /// @pre job_scheduler_init() MUST be called. + /// @see job_scheduler_init() + int job_scheduler_foreach_job( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _job_scheduler_foreach_job( + callback, + user_data, + ); + } + + late final _job_scheduler_foreach_job_ptr = + _lookup>( + 'job_scheduler_foreach_job'); + late final _dart_job_scheduler_foreach_job _job_scheduler_foreach_job = + _job_scheduler_foreach_job_ptr + .asFunction<_dart_job_scheduler_foreach_job>(); + + /// @brief Adds job service handler for receiving the information of the scheduled job. + /// @since_tizen 4.0 + /// @remarks The @a job_service handle should be released using job_scheduler_service_remove(). + /// @param[in] job_id The ID of the job + /// @param[in] callback The set of callback functions to handle jobs + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] job_service The job service handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #JOB_ERROR_NOT_INITIALIZED Not initialized + /// @retval #JOB_ERROR_OUT_OF_MEMORY Out of memory + /// @pre job_scheduler_init() MUST be called. + /// @see job_scheduler_init() + /// @see job_scheduler_service_remove() + /// @see job_service_start_cb() + /// @see job_service_stop_cb() + /// @see job_scheduler_job_finished() + /// @see #job_service_callback_s + int job_scheduler_service_add( + ffi.Pointer job_id, + ffi.Pointer callback, + ffi.Pointer user_data, + ffi.Pointer> job_service, + ) { + return _job_scheduler_service_add( + job_id, + callback, + user_data, + job_service, + ); + } + + late final _job_scheduler_service_add_ptr = + _lookup>( + 'job_scheduler_service_add'); + late final _dart_job_scheduler_service_add _job_scheduler_service_add = + _job_scheduler_service_add_ptr + .asFunction<_dart_job_scheduler_service_add>(); + + /// @brief Removes registered job service handler. + /// @since_tizen 4.0 + /// @param[in] job_service The job service handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #JOB_ERROR_NONE Successful + /// @retval #JOB_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #JOB_ERROR_NOT_INITIALIZED Not initialized + /// @pre job_scheduler_init() MUST be called. + /// @see job_scheduler_init() + /// @see job_scheduler_service_add() + int job_scheduler_service_remove( + ffi.Pointer job_service, + ) { + return _job_scheduler_service_remove( + job_service, + ); + } + + late final _job_scheduler_service_remove_ptr = + _lookup>( + 'job_scheduler_service_remove'); + late final _dart_job_scheduler_service_remove _job_scheduler_service_remove = + _job_scheduler_service_remove_ptr + .asFunction<_dart_job_scheduler_service_remove>(); + + /// @brief Sets an integer value in the preference. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] key The name of the key to modify + /// @param[in] value The new @c int value for the given key + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PREFERENCE_ERROR_NONE Successful + /// @retval #PREFERENCE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PREFERENCE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PREFERENCE_ERROR_IO_ERROR Internal I/O Error + /// @see preference_get_int() + int preference_set_int( + ffi.Pointer key, + int value, + ) { + return _preference_set_int( + key, + value, + ); + } + + late final _preference_set_int_ptr = + _lookup>('preference_set_int'); + late final _dart_preference_set_int _preference_set_int = + _preference_set_int_ptr.asFunction<_dart_preference_set_int>(); + + /// @brief Gets an integer value from the preference. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] key The name of the key to retrieve + /// @param[out] value The @c int value for the given key + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PREFERENCE_ERROR_NONE Successful + /// @retval #PREFERENCE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PREFERENCE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PREFERENCE_ERROR_NO_KEY Required key not available + /// @retval #PREFERENCE_ERROR_IO_ERROR Internal I/O Error + /// @see preference_set_int() + int preference_get_int( + ffi.Pointer key, + ffi.Pointer value, + ) { + return _preference_get_int( + key, + value, + ); + } + + late final _preference_get_int_ptr = + _lookup>('preference_get_int'); + late final _dart_preference_get_int _preference_get_int = + _preference_get_int_ptr.asFunction<_dart_preference_get_int>(); + + /// @brief Sets a double value in the preference. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] key The name of the key to modify + /// @param[in] value The new @c double value associated with the given key + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PREFERENCE_ERROR_NONE Successful + /// @retval #PREFERENCE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PREFERENCE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PREFERENCE_ERROR_IO_ERROR Internal I/O Error + /// @see preference_get_double() + int preference_set_double( + ffi.Pointer key, + double value, + ) { + return _preference_set_double( + key, + value, + ); + } + + late final _preference_set_double_ptr = + _lookup>( + 'preference_set_double'); + late final _dart_preference_set_double _preference_set_double = + _preference_set_double_ptr.asFunction<_dart_preference_set_double>(); + + /// @brief Gets a double value from the preference. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] key The name of the key to retrieve + /// @param[out] value The @c double value associated with the given key + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PREFERENCE_ERROR_NONE Successful + /// @retval #PREFERENCE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PREFERENCE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PREFERENCE_ERROR_NO_KEY Required key not available + /// @retval #PREFERENCE_ERROR_IO_ERROR Internal I/O Error + /// @see preference_set_double() + int preference_get_double( + ffi.Pointer key, + ffi.Pointer value, + ) { + return _preference_get_double( + key, + value, + ); + } + + late final _preference_get_double_ptr = + _lookup>( + 'preference_get_double'); + late final _dart_preference_get_double _preference_get_double = + _preference_get_double_ptr.asFunction<_dart_preference_get_double>(); + + /// @brief Sets a string value in the preference. + /// @details It makes a deep copy of the added string value. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] key The name of the key to modify + /// @param[in] value The new @c string value associated with the given key + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PREFERENCE_ERROR_NONE Successful + /// @retval #PREFERENCE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PREFERENCE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PREFERENCE_ERROR_IO_ERROR Internal I/O Error + /// @see preference_get_string() + int preference_set_string( + ffi.Pointer key, + ffi.Pointer value, + ) { + return _preference_set_string( + key, + value, + ); + } + + late final _preference_set_string_ptr = + _lookup>( + 'preference_set_string'); + late final _dart_preference_set_string _preference_set_string = + _preference_set_string_ptr.asFunction<_dart_preference_set_string>(); + + /// @brief Gets a string value from the preference. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks @a value must be released using free(). + /// @param[in] key The name of the key to retrieve + /// @param[out] value The @c string value associated with the given key + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PREFERENCE_ERROR_NONE Successful + /// @retval #PREFERENCE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PREFERENCE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PREFERENCE_ERROR_NO_KEY Required key not available + /// @retval #PREFERENCE_ERROR_IO_ERROR Internal I/O Error + /// @see preference_set_string() + int preference_get_string( + ffi.Pointer key, + ffi.Pointer> value, + ) { + return _preference_get_string( + key, + value, + ); + } + + late final _preference_get_string_ptr = + _lookup>( + 'preference_get_string'); + late final _dart_preference_get_string _preference_get_string = + _preference_get_string_ptr.asFunction<_dart_preference_get_string>(); + + /// @brief Sets a boolean value in the preference. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] key The name of the key to modify + /// @param[in] value The new @c boolean value associated with the given key + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PREFERENCE_ERROR_NONE Successful + /// @retval #PREFERENCE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PREFERENCE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PREFERENCE_ERROR_IO_ERROR Internal I/O Error + /// @see preference_get_boolean() + int preference_set_boolean( + ffi.Pointer key, + bool value, + ) { + return _preference_set_boolean( + key, + value ? 1 : 0, + ); + } + + late final _preference_set_boolean_ptr = + _lookup>( + 'preference_set_boolean'); + late final _dart_preference_set_boolean _preference_set_boolean = + _preference_set_boolean_ptr.asFunction<_dart_preference_set_boolean>(); + + /// @brief Gets a boolean value from the preference. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] key The name of the key to retrieve + /// @param[out] value The @c boolean value associated with the given key + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PREFERENCE_ERROR_NONE Successful + /// @retval #PREFERENCE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PREFERENCE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PREFERENCE_ERROR_NO_KEY Required key not available + /// @retval #PREFERENCE_ERROR_IO_ERROR Internal I/O Error + /// @see preference_set_boolean() + int preference_get_boolean( + ffi.Pointer key, + ffi.Pointer value, + ) { + return _preference_get_boolean( + key, + value, + ); + } + + late final _preference_get_boolean_ptr = + _lookup>( + 'preference_get_boolean'); + late final _dart_preference_get_boolean _preference_get_boolean = + _preference_get_boolean_ptr.asFunction<_dart_preference_get_boolean>(); + + /// @brief Removes any value with the given @a key from the preference. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] key The name of the key to remove + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PREFERENCE_ERROR_NONE Successful + /// @retval #PREFERENCE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PREFERENCE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PREFERENCE_ERROR_NO_KEY Required key not available + /// @retval #PREFERENCE_ERROR_IO_ERROR Internal I/O Error + int preference_remove( + ffi.Pointer key, + ) { + return _preference_remove( + key, + ); + } + + late final _preference_remove_ptr = + _lookup>('preference_remove'); + late final _dart_preference_remove _preference_remove = + _preference_remove_ptr.asFunction<_dart_preference_remove>(); + + /// @brief Checks whether the given @a key exists in the preference. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] key The name of the key to check + /// @param[out] existing If @c true the @a key exists in the preference, + /// otherwise @c false + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PREFERENCE_ERROR_NONE Successful + /// @retval #PREFERENCE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PREFERENCE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PREFERENCE_ERROR_IO_ERROR Internal I/O Error + int preference_is_existing( + ffi.Pointer key, + ffi.Pointer existing, + ) { + return _preference_is_existing( + key, + existing, + ); + } + + late final _preference_is_existing_ptr = + _lookup>( + 'preference_is_existing'); + late final _dart_preference_is_existing _preference_is_existing = + _preference_is_existing_ptr.asFunction<_dart_preference_is_existing>(); + + /// @brief Removes all key-value pairs from the preference. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PREFERENCE_ERROR_NONE Successful + /// @retval #PREFERENCE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PREFERENCE_ERROR_IO_ERROR Internal I/O Error + /// @see preference_remove() + int preference_remove_all() { + return _preference_remove_all(); + } + + late final _preference_remove_all_ptr = + _lookup>( + 'preference_remove_all'); + late final _dart_preference_remove_all _preference_remove_all = + _preference_remove_all_ptr.asFunction<_dart_preference_remove_all>(); + + /// @brief Registers a callback function to be invoked when value of the given key in the preference changes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] key The name of the key to monitor + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PREFERENCE_ERROR_NONE Successful + /// @retval #PREFERENCE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PREFERENCE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PREFERENCE_ERROR_NO_KEY Required key not available + /// @retval #PREFERENCE_ERROR_IO_ERROR Internal I/O Error + /// @post preference_changed_cb() will be invoked. + /// @see preference_unset_changed_cb() + /// @see preference_changed_cb() + int preference_set_changed_cb( + ffi.Pointer key, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _preference_set_changed_cb( + key, + callback, + user_data, + ); + } + + late final _preference_set_changed_cb_ptr = + _lookup>( + 'preference_set_changed_cb'); + late final _dart_preference_set_changed_cb _preference_set_changed_cb = + _preference_set_changed_cb_ptr + .asFunction<_dart_preference_set_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] key The name of the key to monitor + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PREFERENCE_ERROR_NONE Successful + /// @retval #PREFERENCE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PREFERENCE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PREFERENCE_ERROR_NO_KEY Required key not available + /// @retval #PREFERENCE_ERROR_IO_ERROR Internal I/O Error + /// @see preference_set_changed_cb() + int preference_unset_changed_cb( + ffi.Pointer key, + ) { + return _preference_unset_changed_cb( + key, + ); + } + + late final _preference_unset_changed_cb_ptr = + _lookup>( + 'preference_unset_changed_cb'); + late final _dart_preference_unset_changed_cb _preference_unset_changed_cb = + _preference_unset_changed_cb_ptr + .asFunction<_dart_preference_unset_changed_cb>(); + + /// @brief Retrieves all key-value pairs in the preference by invoking the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] callback The callback function to get key value once for each key-value pair in the preference + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PREFERENCE_ERROR_NONE Successful + /// @retval #PREFERENCE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PREFERENCE_ERROR_IO_ERROR Internal I/O Error + /// @post This function invokes preference_item_cb() repeatedly to get each key-value pair in the preference. + /// @see preference_item_cb() + int preference_foreach_item( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _preference_foreach_item( + callback, + user_data, + ); + } + + late final _preference_foreach_item_ptr = + _lookup>( + 'preference_foreach_item'); + late final _dart_preference_foreach_item _preference_foreach_item = + _preference_foreach_item_ptr.asFunction<_dart_preference_foreach_item>(); + + /// @brief Creates resource manager and get from db. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks If resource manager already exists, + /// It will just return APP_RESOURCE_ERROR_NONE + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_RESOURCE_ERROR_NONE Successful + /// @retval #APP_RESOURCE_ERROR_IO_ERROR IO Internal I/O Error + /// @retval #APP_RESOURCE_ERROR_OUT_OF_MEMORY Out of memory + /// @see app_resource_manager_release() + int app_resource_manager_init() { + return _app_resource_manager_init(); + } + + late final _app_resource_manager_init_ptr = + _lookup>( + 'app_resource_manager_init'); + late final _dart_app_resource_manager_init _app_resource_manager_init = + _app_resource_manager_init_ptr + .asFunction<_dart_app_resource_manager_init>(); + + /// @brief Converts resource ID to path name + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks If resource manager is not created yet, + /// app_resource_manager_init() will be invoked automatically. + /// Caller should free the returned pointer. + /// @param[in] type Resource type @see app_resource_e + /// @param[in] id Resource ID + /// @param[out] path The name of requested resource on success, otherwise NULL + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_RESOURCE_ERROR_NONE Successful + /// @retval #APP_RESOURCE_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_RESOURCE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #APP_RESOURCE_ERROR_IO_ERROR Internal I/O Error or failed to find valid resource + /// @see app_resource_manager_init() + int app_resource_manager_get( + int type, + ffi.Pointer id, + ffi.Pointer> path, + ) { + return _app_resource_manager_get( + type, + id, + path, + ); + } + + late final _app_resource_manager_get_ptr = + _lookup>( + 'app_resource_manager_get'); + late final _dart_app_resource_manager_get _app_resource_manager_get = + _app_resource_manager_get_ptr + .asFunction<_dart_app_resource_manager_get>(); + + /// @brief Destroys resource manager. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks Please note that the instance of resource manager should only be released when the application is closing. + /// It is a highly recommended way to improve run-time performance. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_RESOURCE_ERROR_NONE Successful + /// @see app_resource_manager_init() + int app_resource_manager_release() { + return _app_resource_manager_release(); + } + + late final _app_resource_manager_release_ptr = + _lookup>( + 'app_resource_manager_release'); + late final _dart_app_resource_manager_release _app_resource_manager_release = + _app_resource_manager_release_ptr + .asFunction<_dart_app_resource_manager_release>(); + + /// @brief Destroys the application context handle and releases all its resources. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_context The application context handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see app_manager_foreach_app_context() + /// @see app_manager_get_app_context() + int app_context_destroy( + ffi.Pointer app_context, + ) { + return _app_context_destroy( + app_context, + ); + } + + late final _app_context_destroy_ptr = + _lookup>( + 'app_context_destroy'); + late final _dart_app_context_destroy _app_context_destroy = + _app_context_destroy_ptr.asFunction<_dart_app_context_destroy>(); + + /// @deprecated Deprecated since 2.3.1. Use app_context_get_app_id() instead. + /// @brief Gets the application ID with the given application context. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a package using free(). + /// @param[in] app_context The application context + /// @param[out] package The application ID of the given application context + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_context_get_package( + ffi.Pointer app_context, + ffi.Pointer> package, + ) { + return _app_context_get_package( + app_context, + package, + ); + } + + late final _app_context_get_package_ptr = + _lookup>( + 'app_context_get_package'); + late final _dart_app_context_get_package _app_context_get_package = + _app_context_get_package_ptr.asFunction<_dart_app_context_get_package>(); + + /// @brief Gets the application ID with the given application context. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a app_id using free(). + /// @param[in] app_context The application context + /// @param[out] app_id The application ID of the given application context + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_context_get_app_id( + ffi.Pointer app_context, + ffi.Pointer> app_id, + ) { + return _app_context_get_app_id( + app_context, + app_id, + ); + } + + late final _app_context_get_app_id_ptr = + _lookup>( + 'app_context_get_app_id'); + late final _dart_app_context_get_app_id _app_context_get_app_id = + _app_context_get_app_id_ptr.asFunction<_dart_app_context_get_app_id>(); + + /// @brief Gets the process ID with the given application context. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_context The application context + /// @param[out] pid The process ID of the given application context + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int app_context_get_pid( + ffi.Pointer app_context, + ffi.Pointer pid, + ) { + return _app_context_get_pid( + app_context, + pid, + ); + } + + late final _app_context_get_pid_ptr = + _lookup>( + 'app_context_get_pid'); + late final _dart_app_context_get_pid _app_context_get_pid = + _app_context_get_pid_ptr.asFunction<_dart_app_context_get_pid>(); + + /// @brief Gets the package id with the given application context. + /// @since_tizen 3.0 + /// @remarks You must release @a pkg_id using free(). + /// @param[in] app_context The application context + /// @param[out] pkg_id The package ID of the given application context + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_context_get_package_id( + ffi.Pointer app_context, + ffi.Pointer> pkg_id, + ) { + return _app_context_get_package_id( + app_context, + pkg_id, + ); + } + + late final _app_context_get_package_id_ptr = + _lookup>( + 'app_context_get_package_id'); + late final _dart_app_context_get_package_id _app_context_get_package_id = + _app_context_get_package_id_ptr + .asFunction<_dart_app_context_get_package_id>(); + + /// @brief Gets the application state with the given application context. + /// @since_tizen 3.0 + /// @remarks Note that application's state might be changed after you get app_context. + /// This API just returns the state of application when you get the app_context. + /// @param[in] app_context The application context + /// @param[out] state The application state of the given application context + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int app_context_get_app_state( + ffi.Pointer app_context, + ffi.Pointer state, + ) { + return _app_context_get_app_state( + app_context, + state, + ); + } + + late final _app_context_get_app_state_ptr = + _lookup>( + 'app_context_get_app_state'); + late final _dart_app_context_get_app_state _app_context_get_app_state = + _app_context_get_app_state_ptr + .asFunction<_dart_app_context_get_app_state>(); + + /// @brief Checks whether the application with the given application context is terminated. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_context The application context + /// @param[out] terminated @c true if the application is terminated, \n + /// otherwise @c false if the application is running + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int app_context_is_terminated( + ffi.Pointer app_context, + ffi.Pointer terminated, + ) { + return _app_context_is_terminated( + app_context, + terminated, + ); + } + + late final _app_context_is_terminated_ptr = + _lookup>( + 'app_context_is_terminated'); + late final _dart_app_context_is_terminated _app_context_is_terminated = + _app_context_is_terminated_ptr + .asFunction<_dart_app_context_is_terminated>(); + + /// @brief Checks whether two application contexts are equal. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] lhs The first application context to compare + /// @param[in] rhs The second application context to compare + /// @param[out] equal @c true if the application contexts are equal, \n + /// otherwise @c false if they are not equal + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int app_context_is_equal( + ffi.Pointer lhs, + ffi.Pointer rhs, + ffi.Pointer equal, + ) { + return _app_context_is_equal( + lhs, + rhs, + equal, + ); + } + + late final _app_context_is_equal_ptr = + _lookup>( + 'app_context_is_equal'); + late final _dart_app_context_is_equal _app_context_is_equal = + _app_context_is_equal_ptr.asFunction<_dart_app_context_is_equal>(); + + /// @brief Checks whether the application is running as a sub application of the application group. + /// @since_tizen 3.0 + /// @param[in] app_context The application context + /// @param[out] is_sub_app @c true if the sub application of the group, \n + /// otherwise @c false if the main application of the group + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int app_context_is_sub_app( + ffi.Pointer app_context, + ffi.Pointer is_sub_app, + ) { + return _app_context_is_sub_app( + app_context, + is_sub_app, + ); + } + + late final _app_context_is_sub_app_ptr = + _lookup>( + 'app_context_is_sub_app'); + late final _dart_app_context_is_sub_app _app_context_is_sub_app = + _app_context_is_sub_app_ptr.asFunction<_dart_app_context_is_sub_app>(); + + /// @brief Clones the application context handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] clone The newly created application context handle, if cloning is successful + /// @param[in] app_context The application context + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_context_clone( + ffi.Pointer> clone, + ffi.Pointer app_context, + ) { + return _app_context_clone( + clone, + app_context, + ); + } + + late final _app_context_clone_ptr = + _lookup>('app_context_clone'); + late final _dart_app_context_clone _app_context_clone = + _app_context_clone_ptr.asFunction<_dart_app_context_clone>(); + + /// @brief Creates the application information handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_id The application ID + /// @param[out] app_info The application information handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_NO_SUCH_APP The app is not installed + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @see app_manager_foreach_app_info() + /// @see app_manager_get_app_info() + int app_info_create( + ffi.Pointer app_id, + ffi.Pointer> app_info, + ) { + return _app_info_create( + app_id, + app_info, + ); + } + + late final _app_info_create_ptr = + _lookup>('app_info_create'); + late final _dart_app_info_create _app_info_create = + _app_info_create_ptr.asFunction<_dart_app_info_create>(); + + /// @brief Destroys the application information handle and releases all its resources. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_info The application information handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see app_manager_foreach_app_info() + /// @see app_manager_get_app_info() + int app_info_destroy( + ffi.Pointer app_info, + ) { + return _app_info_destroy( + app_info, + ); + } + + late final _app_info_destroy_ptr = + _lookup>('app_info_destroy'); + late final _dart_app_info_destroy _app_info_destroy = + _app_info_destroy_ptr.asFunction<_dart_app_info_destroy>(); + + /// @brief Gets the application ID with the given application context. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a app_id using free(). + /// @param[in] app_info The application information + /// @param[out] app_id The application ID of the given application context + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_info_get_app_id( + ffi.Pointer app_info, + ffi.Pointer> app_id, + ) { + return _app_info_get_app_id( + app_info, + app_id, + ); + } + + late final _app_info_get_app_id_ptr = + _lookup>( + 'app_info_get_app_id'); + late final _dart_app_info_get_app_id _app_info_get_app_id = + _app_info_get_app_id_ptr.asFunction<_dart_app_info_get_app_id>(); + + /// @brief Gets the executable path of the application + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a exec path using free(). + /// @param[in] app_info The application information + /// @param[out] exec The executable path of the application + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_info_get_exec( + ffi.Pointer app_info, + ffi.Pointer> exec, + ) { + return _app_info_get_exec( + app_info, + exec, + ); + } + + late final _app_info_get_exec_ptr = + _lookup>('app_info_get_exec'); + late final _dart_app_info_get_exec _app_info_get_exec = + _app_info_get_exec_ptr.asFunction<_dart_app_info_get_exec>(); + + /// @brief Gets the label of the application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a label using free(). + /// @param[in] app_info The application information + /// @param[out] label The label of the application + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_info_get_label( + ffi.Pointer app_info, + ffi.Pointer> label, + ) { + return _app_info_get_label( + app_info, + label, + ); + } + + late final _app_info_get_label_ptr = + _lookup>('app_info_get_label'); + late final _dart_app_info_get_label _app_info_get_label = + _app_info_get_label_ptr.asFunction<_dart_app_info_get_label>(); + + /// @brief Gets the localed name of the application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release localed name using free(). + /// @param[in] app_id The application ID + /// @param[in] locale The locale information + /// @param[out] label The localed name of the application + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_info_get_localed_label( + ffi.Pointer app_id, + ffi.Pointer locale, + ffi.Pointer> label, + ) { + return _app_info_get_localed_label( + app_id, + locale, + label, + ); + } + + late final _app_info_get_localed_label_ptr = + _lookup>( + 'app_info_get_localed_label'); + late final _dart_app_info_get_localed_label _app_info_get_localed_label = + _app_info_get_localed_label_ptr + .asFunction<_dart_app_info_get_localed_label>(); + + /// @brief Gets the absolute path to the icon image. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a path using free(). + /// @param[in] app_info The application information + /// @param[out] path The absolute path to the icon + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_info_get_icon( + ffi.Pointer app_info, + ffi.Pointer> path, + ) { + return _app_info_get_icon( + app_info, + path, + ); + } + + late final _app_info_get_icon_ptr = + _lookup>('app_info_get_icon'); + late final _dart_app_info_get_icon _app_info_get_icon = + _app_info_get_icon_ptr.asFunction<_dart_app_info_get_icon>(); + + /// @brief Gets the package name. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a package name using free(). + /// @param[in] app_info The application information + /// @param[out] package The package name + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_info_get_package( + ffi.Pointer app_info, + ffi.Pointer> package, + ) { + return _app_info_get_package( + app_info, + package, + ); + } + + late final _app_info_get_package_ptr = + _lookup>( + 'app_info_get_package'); + late final _dart_app_info_get_package _app_info_get_package = + _app_info_get_package_ptr.asFunction<_dart_app_info_get_package>(); + + /// @brief Gets the package type name. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release package @a type name using free(). + /// @param[in] app_info The application information + /// @param[out] type The package type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_info_get_type( + ffi.Pointer app_info, + ffi.Pointer> type, + ) { + return _app_info_get_type( + app_info, + type, + ); + } + + late final _app_info_get_type_ptr = + _lookup>('app_info_get_type'); + late final _dart_app_info_get_type _app_info_get_type = + _app_info_get_type_ptr.asFunction<_dart_app_info_get_type>(); + + /// @brief Gets the application component type. + /// @since_tizen 4.0 + /// @param[in] app_info The application information + /// @param[out] type The application component type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_IO_ERROR I/O error + /// @see #PACKAGE_INFO_PROP_APP_COMPONENT_TYPE + /// @see #app_info_app_component_type_e + int app_info_get_app_component_type( + ffi.Pointer app_info, + ffi.Pointer type, + ) { + return _app_info_get_app_component_type( + app_info, + type, + ); + } + + late final _app_info_get_app_component_type_ptr = + _lookup>( + 'app_info_get_app_component_type'); + late final _dart_app_info_get_app_component_type + _app_info_get_app_component_type = _app_info_get_app_component_type_ptr + .asFunction<_dart_app_info_get_app_component_type>(); + + /// @brief Gets the list of metadata for a particular application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_info The application information + /// @param[in] callback The callback function for list + /// @param[in] user_data The user data to be passed to callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_IO_ERROR I/O error + int app_info_foreach_metadata( + ffi.Pointer app_info, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _app_info_foreach_metadata( + app_info, + callback, + user_data, + ); + } + + late final _app_info_foreach_metadata_ptr = + _lookup>( + 'app_info_foreach_metadata'); + late final _dart_app_info_foreach_metadata _app_info_foreach_metadata = + _app_info_foreach_metadata_ptr + .asFunction<_dart_app_info_foreach_metadata>(); + + /// @brief Checks whether application information is nodisplay. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_info The application information + /// @param[out] nodisplay @c true if the application is nodisplay, \n + /// otherwise @c false + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int app_info_is_nodisplay( + ffi.Pointer app_info, + ffi.Pointer nodisplay, + ) { + return _app_info_is_nodisplay( + app_info, + nodisplay, + ); + } + + late final _app_info_is_nodisplay_ptr = + _lookup>( + 'app_info_is_nodisplay'); + late final _dart_app_info_is_nodisplay _app_info_is_nodisplay = + _app_info_is_nodisplay_ptr.asFunction<_dart_app_info_is_nodisplay>(); + + /// @brief Checks whether two application information are equal. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] lhs The first application information to compare + /// @param[in] rhs The second application information to compare + /// @param[out] equal @c true if the application information are equal, \n + /// otherwise @c false + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int app_info_is_equal( + ffi.Pointer lhs, + ffi.Pointer rhs, + ffi.Pointer equal, + ) { + return _app_info_is_equal( + lhs, + rhs, + equal, + ); + } + + late final _app_info_is_equal_ptr = + _lookup>('app_info_is_equal'); + late final _dart_app_info_is_equal _app_info_is_equal = + _app_info_is_equal_ptr.asFunction<_dart_app_info_is_equal>(); + + /// @brief Checks whether application is enabled. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_info The application information + /// @param[out] enabled @c true if the application is enabled, \n + /// otherwise @c false + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int app_info_is_enabled( + ffi.Pointer app_info, + ffi.Pointer enabled, + ) { + return _app_info_is_enabled( + app_info, + enabled, + ); + } + + late final _app_info_is_enabled_ptr = + _lookup>( + 'app_info_is_enabled'); + late final _dart_app_info_is_enabled _app_info_is_enabled = + _app_info_is_enabled_ptr.asFunction<_dart_app_info_is_enabled>(); + + /// @brief Checks whether application is launched on booting time. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_info The application information + /// @param[out] onboot @c true if the application is launched on booting time, \n + /// otherwise @c false + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int app_info_is_onboot( + ffi.Pointer app_info, + ffi.Pointer onboot, + ) { + return _app_info_is_onboot( + app_info, + onboot, + ); + } + + late final _app_info_is_onboot_ptr = + _lookup>('app_info_is_onboot'); + late final _dart_app_info_is_onboot _app_info_is_onboot = + _app_info_is_onboot_ptr.asFunction<_dart_app_info_is_onboot>(); + + /// @brief Checks whether application is preloaded. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_info The application information + /// @param[out] preload @c true if the application is preloaded, \n + /// otherwise @c false + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int app_info_is_preload( + ffi.Pointer app_info, + ffi.Pointer preload, + ) { + return _app_info_is_preload( + app_info, + preload, + ); + } + + late final _app_info_is_preload_ptr = + _lookup>( + 'app_info_is_preload'); + late final _dart_app_info_is_preload _app_info_is_preload = + _app_info_is_preload_ptr.asFunction<_dart_app_info_is_preload>(); + + /// @brief Clones the application information handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] clone A newly created application information handle, if successfully cloned + /// @param[in] app_info The application information + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #APP_MANAGER_ERROR_NO_SUCH_APP The app is not installed + int app_info_clone( + ffi.Pointer> clone, + ffi.Pointer app_info, + ) { + return _app_info_clone( + clone, + app_info, + ); + } + + late final _app_info_clone_ptr = + _lookup>('app_info_clone'); + late final _dart_app_info_clone _app_info_clone = + _app_info_clone_ptr.asFunction<_dart_app_info_clone>(); + + /// @platform + /// @brief Runs a callback for each category which the given application belongs to. + /// @since_tizen 4.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @param[in] app_info The application information + /// @param[in] callback The callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_IO_ERROR I/O error + /// @retval #APP_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @see app_info_create() + int app_info_foreach_category( + ffi.Pointer app_info, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _app_info_foreach_category( + app_info, + callback, + user_data, + ); + } + + late final _app_info_foreach_category_ptr = + _lookup>( + 'app_info_foreach_category'); + late final _dart_app_info_foreach_category _app_info_foreach_category = + _app_info_foreach_category_ptr + .asFunction<_dart_app_info_foreach_category>(); + + /// @brief Creates the application information filter handle from DB. + /// All filter properties will be ANDed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] handle The pointer to the application info filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #APP_MANAGER_ERROR_IO_ERROR I/O error + int app_info_filter_create( + ffi.Pointer> handle, + ) { + return _app_info_filter_create( + handle, + ); + } + + late final _app_info_filter_create_ptr = + _lookup>( + 'app_info_filter_create'); + late final _dart_app_info_filter_create _app_info_filter_create = + _app_info_filter_create_ptr.asFunction<_dart_app_info_filter_create>(); + + /// @brief Destroys the application information filter handle, freeing up all the resources. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] handle The pointer to the application info filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_IO_ERROR I/O error + int app_info_filter_destroy( + ffi.Pointer handle, + ) { + return _app_info_filter_destroy( + handle, + ); + } + + late final _app_info_filter_destroy_ptr = + _lookup>( + 'app_info_filter_destroy'); + late final _dart_app_info_filter_destroy _app_info_filter_destroy = + _app_info_filter_destroy_ptr.asFunction<_dart_app_info_filter_destroy>(); + + /// @brief Adds a boolean filter property to the filter handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] handle The pointer to the application info filter handle + /// @param[in] property The integer property name + /// @param[in] value The value corresponding to the property + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_IO_ERROR I/O error + int app_info_filter_add_bool( + ffi.Pointer handle, + ffi.Pointer property, + bool value, + ) { + return _app_info_filter_add_bool( + handle, + property, + value ? 1 : 0, + ); + } + + late final _app_info_filter_add_bool_ptr = + _lookup>( + 'app_info_filter_add_bool'); + late final _dart_app_info_filter_add_bool _app_info_filter_add_bool = + _app_info_filter_add_bool_ptr + .asFunction<_dart_app_info_filter_add_bool>(); + + /// @brief Adds a string filter property to the filter handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] handle The pointer to the application info filter handle + /// @param[in] property The integer property name + /// @param[in] value The value corresponding to the property + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_IO_ERROR I/O error + int app_info_filter_add_string( + ffi.Pointer handle, + ffi.Pointer property, + ffi.Pointer value, + ) { + return _app_info_filter_add_string( + handle, + property, + value, + ); + } + + late final _app_info_filter_add_string_ptr = + _lookup>( + 'app_info_filter_add_string'); + late final _dart_app_info_filter_add_string _app_info_filter_add_string = + _app_info_filter_add_string_ptr + .asFunction<_dart_app_info_filter_add_string>(); + + /// @brief Gets the count of filtered apps. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] handle The pointer to the application info filter handle + /// @param[out] count The pointer to the variable for count + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_IO_ERROR I/O error + int app_info_filter_count_appinfo( + ffi.Pointer handle, + ffi.Pointer count, + ) { + return _app_info_filter_count_appinfo( + handle, + count, + ); + } + + late final _app_info_filter_count_appinfo_ptr = + _lookup>( + 'app_info_filter_count_appinfo'); + late final _dart_app_info_filter_count_appinfo + _app_info_filter_count_appinfo = _app_info_filter_count_appinfo_ptr + .asFunction<_dart_app_info_filter_count_appinfo>(); + + /// @brief Executes the user supplied callback function for each application that satisfy the filter conditions. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] handle The pointer to the application info filter handle + /// @param[in] callback The callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_IO_ERROR I/O error + int app_info_filter_foreach_appinfo( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _app_info_filter_foreach_appinfo( + handle, + callback, + user_data, + ); + } + + late final _app_info_filter_foreach_appinfo_ptr = + _lookup>( + 'app_info_filter_foreach_appinfo'); + late final _dart_app_info_filter_foreach_appinfo + _app_info_filter_foreach_appinfo = _app_info_filter_foreach_appinfo_ptr + .asFunction<_dart_app_info_filter_foreach_appinfo>(); + + /// @brief Creates the application's metadata information filter handle from DB. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] handle The pointer to the application metadata info filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #APP_MANAGER_ERROR_IO_ERROR I/O error + int app_info_metadata_filter_create( + ffi.Pointer> handle, + ) { + return _app_info_metadata_filter_create( + handle, + ); + } + + late final _app_info_metadata_filter_create_ptr = + _lookup>( + 'app_info_metadata_filter_create'); + late final _dart_app_info_metadata_filter_create + _app_info_metadata_filter_create = _app_info_metadata_filter_create_ptr + .asFunction<_dart_app_info_metadata_filter_create>(); + + /// @brief Destroys the application's metadata information filter handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] handle The pointer to the application info filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_IO_ERROR I/O error + int app_info_metadata_filter_destroy( + ffi.Pointer handle, + ) { + return _app_info_metadata_filter_destroy( + handle, + ); + } + + late final _app_info_metadata_filter_destroy_ptr = + _lookup>( + 'app_info_metadata_filter_destroy'); + late final _dart_app_info_metadata_filter_destroy + _app_info_metadata_filter_destroy = _app_info_metadata_filter_destroy_ptr + .asFunction<_dart_app_info_metadata_filter_destroy>(); + + /// @brief Adds filter condition for the query API. + /// @details The query will search the entire application metadata information collected from + /// the manifest file of all the installed packages. You can specify value as @c NULL to search based on key only. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] handle The pointer to the application metadata info filter handle + /// @param[in] key The pointer to metadata key + /// @param[in] value The pointer to metadata value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_IO_ERROR I/O error + int app_info_metadata_filter_add( + ffi.Pointer handle, + ffi.Pointer key, + ffi.Pointer value, + ) { + return _app_info_metadata_filter_add( + handle, + key, + value, + ); + } + + late final _app_info_metadata_filter_add_ptr = + _lookup>( + 'app_info_metadata_filter_add'); + late final _dart_app_info_metadata_filter_add _app_info_metadata_filter_add = + _app_info_metadata_filter_add_ptr + .asFunction<_dart_app_info_metadata_filter_add>(); + + /// @brief Executes the filter query. + /// @details The query will search the entire application metadata information collected from + /// the manifest file of all the installed packages. For each application returned by the query, the callback will be called. If callback returns + /// negative value, no more callbacks will be called and API will return. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] handle The pointer to the application metadata info filter handle + /// @param[in] callback The function pointer to callback + /// @param[in] user_data The pointer to user data + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_IO_ERROR I/O error + int app_info_metadata_filter_foreach( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _app_info_metadata_filter_foreach( + handle, + callback, + user_data, + ); + } + + late final _app_info_metadata_filter_foreach_ptr = + _lookup>( + 'app_info_metadata_filter_foreach'); + late final _dart_app_info_metadata_filter_foreach + _app_info_metadata_filter_foreach = _app_info_metadata_filter_foreach_ptr + .asFunction<_dart_app_info_metadata_filter_foreach>(); + + /// @brief Registers a callback function to be invoked when the applications get launched or terminated. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #APP_MANAGER_ERROR_IO_ERROR Internal I/O error + /// @post It will invoke app_manager_app_context_event_cb() when the application is launched or terminated. + /// @see app_manager_unset_app_context_event_cb() + /// @see app_manager_app_context_event_cb() + int app_manager_set_app_context_event_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _app_manager_set_app_context_event_cb( + callback, + user_data, + ); + } + + late final _app_manager_set_app_context_event_cb_ptr = + _lookup>( + 'app_manager_set_app_context_event_cb'); + late final _dart_app_manager_set_app_context_event_cb + _app_manager_set_app_context_event_cb = + _app_manager_set_app_context_event_cb_ptr + .asFunction<_dart_app_manager_set_app_context_event_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @see app_manager_app_context_event_cb() + void app_manager_unset_app_context_event_cb() { + return _app_manager_unset_app_context_event_cb(); + } + + late final _app_manager_unset_app_context_event_cb_ptr = + _lookup>( + 'app_manager_unset_app_context_event_cb'); + late final _dart_app_manager_unset_app_context_event_cb + _app_manager_unset_app_context_event_cb = + _app_manager_unset_app_context_event_cb_ptr + .asFunction<_dart_app_manager_unset_app_context_event_cb>(); + + /// @brief Retrieves all application contexts of running applications. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_IO_ERROR Internal I/O error + /// @post This function invokes app_manager_app_context_cb() for each application context. + /// @see app_manager_app_context_cb() + /// @remarks In case of ui applications, sub apps in application groups will not be shown. + int app_manager_foreach_app_context( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _app_manager_foreach_app_context( + callback, + user_data, + ); + } + + late final _app_manager_foreach_app_context_ptr = + _lookup>( + 'app_manager_foreach_app_context'); + late final _dart_app_manager_foreach_app_context + _app_manager_foreach_app_context = _app_manager_foreach_app_context_ptr + .asFunction<_dart_app_manager_foreach_app_context>(); + + /// @brief Retrieves all application contexts of running applications including sub apps. + /// @details You can iterate all the running application contexts using this API. + /// This API is similar to app_manager_foreach_app_context() except that this API iterates application contexts including sub apps in application groups. + /// @since_tizen 3.0 + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_IO_ERROR Internal I/O error + /// @post This function invokes app_manager_app_context_cb() for each application context. + /// @see app_manager_app_context_cb() + int app_manager_foreach_running_app_context( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _app_manager_foreach_running_app_context( + callback, + user_data, + ); + } + + late final _app_manager_foreach_running_app_context_ptr = + _lookup>( + 'app_manager_foreach_running_app_context'); + late final _dart_app_manager_foreach_running_app_context + _app_manager_foreach_running_app_context = + _app_manager_foreach_running_app_context_ptr + .asFunction<_dart_app_manager_foreach_running_app_context>(); + + /// @brief Gets the application context for the given ID of the application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This function returns #APP_MANAGER_ERROR_NO_SUCH_APP if the application with the given application ID is not running. \n + /// You must release @a app_context using app_context_destroy(). + /// @param[in] app_id The ID of the application + /// @param[out] app_context The application context of the given application ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #APP_MANAGER_ERROR_NO_SUCH_APP No such application + int app_manager_get_app_context( + ffi.Pointer app_id, + ffi.Pointer> app_context, + ) { + return _app_manager_get_app_context( + app_id, + app_context, + ); + } + + late final _app_manager_get_app_context_ptr = + _lookup>( + 'app_manager_get_app_context'); + late final _dart_app_manager_get_app_context _app_manager_get_app_context = + _app_manager_get_app_context_ptr + .asFunction<_dart_app_manager_get_app_context>(); + + /// @brief Gets the ID of the application for the given process ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This function returns #APP_MANAGER_ERROR_NO_SUCH_APP if the application with the given process ID is not valid. \n + /// You must release @a app_id using free(). + /// @param[in] pid The process ID of the application + /// @param[out] app_id The ID of the application + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_manager_get_app_id( + int pid, + ffi.Pointer> app_id, + ) { + return _app_manager_get_app_id( + pid, + app_id, + ); + } + + late final _app_manager_get_app_id_ptr = + _lookup>( + 'app_manager_get_app_id'); + late final _dart_app_manager_get_app_id _app_manager_get_app_id = + _app_manager_get_app_id_ptr.asFunction<_dart_app_manager_get_app_id>(); + + /// @brief Checks whether the application with the given ID of the application is running. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] app_id The ID of the application + /// @param[out] running @c true if the application is running, \n + /// otherwise @c false if not running + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int app_manager_is_running( + ffi.Pointer app_id, + ffi.Pointer running, + ) { + return _app_manager_is_running( + app_id, + running, + ); + } + + late final _app_manager_is_running_ptr = + _lookup>( + 'app_manager_is_running'); + late final _dart_app_manager_is_running _app_manager_is_running = + _app_manager_is_running_ptr.asFunction<_dart_app_manager_is_running>(); + + /// @brief Resumes the application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/appmanager.launch + /// @param[in] app_context The application context + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_APP_NO_RUNNING App is not running + /// @retval #APP_MANAGER_ERROR_REQUEST_FAILED Internal resume error + /// @retval #APP_MANAGER_ERROR_PERMISSION_DENIED Permission denied + int app_manager_resume_app( + ffi.Pointer app_context, + ) { + return _app_manager_resume_app( + app_context, + ); + } + + late final _app_manager_resume_app_ptr = + _lookup>( + 'app_manager_resume_app'); + late final _dart_app_manager_resume_app _app_manager_resume_app = + _app_manager_resume_app_ptr.asFunction<_dart_app_manager_resume_app>(); + + /// @brief Terminates the back ground application.\n + /// UI applications that are in paused state or some service applications could be required to terminate by this API. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/appmanager.kill.bgapp + /// @remarks This function returns after it just sends a request for terminating a background application.\n + /// Platform will decide if the target application could be terminated or not according to the state of the target application. + /// @param[in] app_context The application context + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_REQUEST_FAILED Failed to send terminate request + /// @retval #APP_MANAGER_ERROR_PERMISSION_DENIED Permission denied + int app_manager_request_terminate_bg_app( + ffi.Pointer app_context, + ) { + return _app_manager_request_terminate_bg_app( + app_context, + ); + } + + late final _app_manager_request_terminate_bg_app_ptr = + _lookup>( + 'app_manager_request_terminate_bg_app'); + late final _dart_app_manager_request_terminate_bg_app + _app_manager_request_terminate_bg_app = + _app_manager_request_terminate_bg_app_ptr + .asFunction<_dart_app_manager_request_terminate_bg_app>(); + + /// @brief Retrieves all installed applications information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @post This function invokes app_manager_app_info_cb() for each application information. + /// @see app_manager_app_info_cb() + int app_manager_foreach_app_info( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _app_manager_foreach_app_info( + callback, + user_data, + ); + } + + late final _app_manager_foreach_app_info_ptr = + _lookup>( + 'app_manager_foreach_app_info'); + late final _dart_app_manager_foreach_app_info _app_manager_foreach_app_info = + _app_manager_foreach_app_info_ptr + .asFunction<_dart_app_manager_foreach_app_info>(); + + /// @brief Gets the application information for the given application ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a app_info using app_info_destroy(). + /// @param[in] app_id The ID of the application + /// @param[out] app_info The application information for the given application ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #APP_MANAGER_ERROR_NO_SUCH_APP No such application + int app_manager_get_app_info( + ffi.Pointer app_id, + ffi.Pointer> app_info, + ) { + return _app_manager_get_app_info( + app_id, + app_info, + ); + } + + late final _app_manager_get_app_info_ptr = + _lookup>( + 'app_manager_get_app_info'); + late final _dart_app_manager_get_app_info _app_manager_get_app_info = + _app_manager_get_app_info_ptr + .asFunction<_dart_app_manager_get_app_info>(); + + /// @brief Gets the absolute path to the shared data directory of the application specified + /// with an application ID. + /// @details An application can only read the files of other application's shared data directory. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specified @a path should be released with free(). @n + /// Since Tizen 3.0, the shared/data directory is supported only for the applications that declare the http://tizen.org/privilege/appdir.shareddata privilege. + /// The function will fail with #APP_MANAGER_ERROR_NOT_SUPPORTED if the privilege is not declared. + /// + /// @param[in] app_id The ID of the application + /// @param[in,out] path The absolute path to the shared data directory of the application + /// specified with the @a app_id + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_NO_SUCH_APP No such application + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #APP_MANAGER_ERROR_NOT_SUPPORTED Not supported + int app_manager_get_shared_data_path( + ffi.Pointer app_id, + ffi.Pointer> path, + ) { + return _app_manager_get_shared_data_path( + app_id, + path, + ); + } + + late final _app_manager_get_shared_data_path_ptr = + _lookup>( + 'app_manager_get_shared_data_path'); + late final _dart_app_manager_get_shared_data_path + _app_manager_get_shared_data_path = _app_manager_get_shared_data_path_ptr + .asFunction<_dart_app_manager_get_shared_data_path>(); + + /// @brief Gets the absolute path to the shared resource directory of the application specified + /// with an application ID. + /// @details An application can only read the files of other application's shared resource directory. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specified @a path should be released with free(). + /// + /// @param[in] app_id The ID of the application + /// @param[in,out] path The absolute path to the shared resource directory of the application + /// specified with the @a app_id + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_NO_SUCH_APP No such application + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_manager_get_shared_resource_path( + ffi.Pointer app_id, + ffi.Pointer> path, + ) { + return _app_manager_get_shared_resource_path( + app_id, + path, + ); + } + + late final _app_manager_get_shared_resource_path_ptr = + _lookup>( + 'app_manager_get_shared_resource_path'); + late final _dart_app_manager_get_shared_resource_path + _app_manager_get_shared_resource_path = + _app_manager_get_shared_resource_path_ptr + .asFunction<_dart_app_manager_get_shared_resource_path>(); + + /// @brief Gets the absolute path to the shared trusted directory of the application specified + /// with an application ID. + /// @details An application signed with the same certificate can read and write the files of + /// other application's shared trusted directory. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specified @a path should be released with free(). + /// + /// @param[in] app_id The ID of the application + /// @param[in,out] path The absolute path to the shared trusted directory of the application + /// specified with the @a app_id + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_NO_SUCH_APP No such application + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_manager_get_shared_trusted_path( + ffi.Pointer app_id, + ffi.Pointer> path, + ) { + return _app_manager_get_shared_trusted_path( + app_id, + path, + ); + } + + late final _app_manager_get_shared_trusted_path_ptr = + _lookup>( + 'app_manager_get_shared_trusted_path'); + late final _dart_app_manager_get_shared_trusted_path + _app_manager_get_shared_trusted_path = + _app_manager_get_shared_trusted_path_ptr + .asFunction<_dart_app_manager_get_shared_trusted_path>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. + /// @brief Gets the absolute path to the shared data directory of the application specified + /// with an application ID. + /// @details An application can only read the files of other application's shared data directory. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specified @a path should be released with free(). + /// @remarks To access the path returned by this function may not work as intended in certain devices due to some implementation issues. + /// + /// @param[in] app_id The ID of the application + /// @param[in,out] path The absolute path to the shared data directory of the application + /// specified with the @a app_id + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_NO_SUCH_APP No such application + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int app_manager_get_external_shared_data_path( + ffi.Pointer app_id, + ffi.Pointer> path, + ) { + return _app_manager_get_external_shared_data_path( + app_id, + path, + ); + } + + late final _app_manager_get_external_shared_data_path_ptr = + _lookup>( + 'app_manager_get_external_shared_data_path'); + late final _dart_app_manager_get_external_shared_data_path + _app_manager_get_external_shared_data_path = + _app_manager_get_external_shared_data_path_ptr + .asFunction<_dart_app_manager_get_external_shared_data_path>(); + + /// @brief Creates a app manager event handle. + /// @since_tizen 3.0 + /// @remarks You must release @a handle using app_manager_event_destroy(). + /// + /// @param[out] handle The app manager event handle that is newly created on success + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see app_manager_event_destroy() + int app_manager_event_create( + ffi.Pointer> handle, + ) { + return _app_manager_event_create( + handle, + ); + } + + late final _app_manager_event_create_ptr = + _lookup>( + 'app_manager_event_create'); + late final _dart_app_manager_event_create _app_manager_event_create = + _app_manager_event_create_ptr + .asFunction<_dart_app_manager_event_create>(); + + /// @brief Sets the event to handle to listen. + /// You can combine multiple status using OR operation which you want to listen. + /// @since_tizen 3.0 + /// + /// @param [in] handle The app manager event handle + /// @param [in] status_type The status of the application + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_REQUEST_FAILED Internal error + /// + /// @see app_manager_event_status_type_e + /// @see app_manager_set_event_cb() + int app_manager_event_set_status( + ffi.Pointer handle, + int status_type, + ) { + return _app_manager_event_set_status( + handle, + status_type, + ); + } + + late final _app_manager_event_set_status_ptr = + _lookup>( + 'app_manager_event_set_status'); + late final _dart_app_manager_event_set_status _app_manager_event_set_status = + _app_manager_event_set_status_ptr + .asFunction<_dart_app_manager_event_set_status>(); + + /// @brief Registers a callback function to be invoked when the app is event has occurred + /// @since_tizen 3.0 + /// @param[in] handle The app manager event handle + /// @param[in] callback The callback function to be registered + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_REQUEST_FAILED Internal error + /// @post app_manager_event_cb() will be invoked. + /// + /// @see app_manager_event_set_status() + /// @see app_manager_event_cb() + /// @see app_manager_unset_event_cb() + int app_manager_set_event_cb( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _app_manager_set_event_cb( + handle, + callback, + user_data, + ); + } + + late final _app_manager_set_event_cb_ptr = + _lookup>( + 'app_manager_set_event_cb'); + late final _dart_app_manager_set_event_cb _app_manager_set_event_cb = + _app_manager_set_event_cb_ptr + .asFunction<_dart_app_manager_set_event_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen 3.0 + /// + /// @param[in] handle The app manager event handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_MANAGER_ERROR_REQUEST_FAILED Internal error + /// + /// @see app_manager_event_cb() + /// @see app_manager_set_event_cb() + int app_manager_unset_event_cb( + ffi.Pointer handle, + ) { + return _app_manager_unset_event_cb( + handle, + ); + } + + late final _app_manager_unset_event_cb_ptr = + _lookup>( + 'app_manager_unset_event_cb'); + late final _dart_app_manager_unset_event_cb _app_manager_unset_event_cb = + _app_manager_unset_event_cb_ptr + .asFunction<_dart_app_manager_unset_event_cb>(); + + /// @brief Destroys the app manager event handle. + /// @since_tizen 3.0 + /// + /// @param[in] handle The app manager event handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #APP_MANAGER_ERROR_NONE Successful + /// @retval #APP_MANAGER_ERROR_REQUEST_FAILED Internal error + /// @retval #APP_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see app_manager_event_create() + int app_manager_event_destroy( + ffi.Pointer handle, + ) { + return _app_manager_event_destroy( + handle, + ); + } + + late final _app_manager_event_destroy_ptr = + _lookup>( + 'app_manager_event_destroy'); + late final _dart_app_manager_event_destroy _app_manager_event_destroy = + _app_manager_event_destroy_ptr + .asFunction<_dart_app_manager_event_destroy>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif Use badge_add instead. + /// @brief Creates a badge for the application itself. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/notification + /// @details Creates new badge to display. + /// @param[in] writable_app_id The id of application which is authorized to change the badge + /// @return #BADGE_ERROR_NONE if success, other value if failure + /// @retval BADGE_ERROR_NONE Success + /// @retval BADGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval BADGE_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval BADGE_ERROR_IO_ERROR Error from I/O + /// @retval BADGE_ERROR_SERVICE_NOT_READY Service is not ready + /// @retval BADGE_ERROR_NOT_SUPPORTED Not supported + /// @see #badge_error_e + /// @par Sample code: + /// @code + /// #include + /// + /// { + /// int err = BADGE_ERROR_NONE; + /// + /// err = badge_new(app_id); + /// if (err != BADGE_ERROR_NONE) + /// return; + /// + /// } + /// @endcode + int badge_new( + ffi.Pointer writable_app_id, + ) { + return _badge_new( + writable_app_id, + ); + } + + late final _badge_new_ptr = + _lookup>('badge_new'); + late final _dart_badge_new _badge_new = + _badge_new_ptr.asFunction<_dart_badge_new>(); + + /// @brief Creates a badge for the application specified by the badge_app_id. + /// @remarks Creating and updating a badge of the other application is allowed only when both applications are signed with the same certificate. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/notification + /// @param[in] badge_app_id The id of the application for which the badge will be created. This parameter can be null when creating a badge for itself. + /// @return #BADGE_ERROR_NONE If success, other value if failure + /// @retval #BADGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BADGE_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #BADGE_ERROR_IO_ERROR Error from I/O + /// @retval #BADGE_ERROR_SERVICE_NOT_READY Service is not ready + /// @retval #BADGE_ERROR_INVALID_PACKAGE The caller application is not signed with the certificate of the badge_app_id + /// @retval BADGE_ERROR_NOT_SUPPORTED Not supported + /// @see #badge_error_e + /// @par Sample code: + /// @code + /// #include + /// + /// { + /// int err = BADGE_ERROR_NONE; + /// + /// err = badge_add("org.tizen.email"); + /// if (err != BADGE_ERROR_NONE) + /// return; + /// } + /// @endcode + int badge_add( + ffi.Pointer badge_app_id, + ) { + return _badge_add( + badge_app_id, + ); + } + + late final _badge_add_ptr = + _lookup>('badge_add'); + late final _dart_badge_add _badge_add = + _badge_add_ptr.asFunction<_dart_badge_add>(); + + /// @brief Removes the badge for the designated application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/notification + /// @param[in] app_id The name of the designated application + /// @return #BADGE_ERROR_NONE if success, other value if failure + /// @retval BADGE_ERROR_NONE Success + /// @retval BADGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval BADGE_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval BADGE_ERROR_IO_ERROR Error from I/O + /// @retval BADGE_ERROR_SERVICE_NOT_READY Service is not ready + /// @retval BADGE_ERROR_NOT_SUPPORTED Not supported + /// @see #badge_error_e + /// @par Sample code: + /// @code + /// #include + /// + /// { + /// int err = BADGE_ERROR_NONE; + /// + /// err = badge_remove(app_id); + /// if (err != BADGE_ERROR_NONE) + /// return; + /// + /// } + /// @endcode + int badge_remove( + ffi.Pointer app_id, + ) { + return _badge_remove( + app_id, + ); + } + + late final _badge_remove_ptr = + _lookup>('badge_remove'); + late final _dart_badge_remove _badge_remove = + _badge_remove_ptr.asFunction<_dart_badge_remove>(); + + /// @brief Sets badge count for the designated application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/notification + /// @param[in] app_id The name of the designated application + /// @param[in] count The count of the badge + /// @return #BADGE_ERROR_NONE if success, other value if failure + /// @retval BADGE_ERROR_NONE Success + /// @retval BADGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval BADGE_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval BADGE_ERROR_IO_ERROR Error from I/O + /// @retval BADGE_ERROR_SERVICE_NOT_READY Service is not ready + /// @retval BADGE_ERROR_NOT_SUPPORTED Not supported + /// @see #badge_error_e + /// @see badge_new() + /// @par Sample code: + /// @code + /// #include + /// + /// { + /// int err = BADGE_ERROR_NONE; + /// + /// err = badge_set_count(app_id, 1); + /// if (err != BADGE_ERROR_NONE) + /// return; + /// + /// } + /// @endcode + int badge_set_count( + ffi.Pointer app_id, + int count, + ) { + return _badge_set_count( + app_id, + count, + ); + } + + late final _badge_set_count_ptr = + _lookup>('badge_set_count'); + late final _dart_badge_set_count _badge_set_count = + _badge_set_count_ptr.asFunction<_dart_badge_set_count>(); + + /// @brief Gets badge count for the designated application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/notification + /// @param[in] app_id The name of the designated application + /// @param[out] count The count of the badge + /// @return #BADGE_ERROR_NONE if success, other value if failure + /// @retval BADGE_ERROR_NONE Success + /// @retval BADGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval BADGE_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval BADGE_ERROR_FROM_DB Error from DB + /// @retval BADGE_ERROR_ALREADY_EXIST Already exist + /// @retval BADGE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval BADGE_ERROR_NOT_SUPPORTED Not supported + /// @see #badge_error_e + /// @see badge_new() + /// @see badge_set_count() + /// @par Sample code: + /// @code + /// #include + /// + /// { + /// int err = BADGE_ERROR_NONE; + /// int count = 0; + /// + /// err = badge_get_count(app_id, &count); + /// if (err != BADGE_ERROR_NONE) + /// return; + /// + /// } + /// @endcode + int badge_get_count( + ffi.Pointer app_id, + ffi.Pointer count, + ) { + return _badge_get_count( + app_id, + count, + ); + } + + late final _badge_get_count_ptr = + _lookup>('badge_get_count'); + late final _dart_badge_get_count _badge_get_count = + _badge_get_count_ptr.asFunction<_dart_badge_get_count>(); + + /// @brief Sets the display option for the designated application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/notification + /// @param[in] app_id The name of the designated application + /// @param[in] is_display The display option (1 = display, 0 = not display) + /// @return #BADGE_ERROR_NONE if success, other value if failure + /// @retval BADGE_ERROR_NONE Success + /// @retval BADGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval BADGE_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval BADGE_ERROR_IO_ERROR Error from I/O + /// @retval BADGE_ERROR_SERVICE_NOT_READY Service is not ready + /// @retval BADGE_ERROR_NOT_SUPPORTED Not supported + /// @see #badge_error_e + /// @see badge_new() + /// @par Sample code: + /// @code + /// #include + /// + /// { + /// int err = BADGE_ERROR_NONE; + /// + /// err = badge_set_display(app_id, 1); + /// if (err != BADGE_ERROR_NONE) + /// return; + /// + /// } + /// @endcode + int badge_set_display( + ffi.Pointer app_id, + int is_display, + ) { + return _badge_set_display( + app_id, + is_display, + ); + } + + late final _badge_set_display_ptr = + _lookup>('badge_set_display'); + late final _dart_badge_set_display _badge_set_display = + _badge_set_display_ptr.asFunction<_dart_badge_set_display>(); + + /// @brief Gets the display option for the designated application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/notification + /// @param[in] app_id The name of the designated application + /// @param[out] is_display The display option (1 = display, 0 = not display) + /// @return #BADGE_ERROR_NONE if success, other value if failure + /// @retval BADGE_ERROR_NONE Success + /// @retval BADGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval BADGE_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval BADGE_ERROR_FROM_DB Error from DB + /// @retval BADGE_ERROR_NOT_EXIST Not exist + /// @retval BADGE_ERROR_SERVICE_NOT_READY Service is not ready + /// @retval BADGE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval BADGE_ERROR_NOT_SUPPORTED Not supported + /// @see #badge_error_e + /// @see badge_new() + /// @see badge_set_count() + /// @par Sample code: + /// @code + /// #include + /// + /// { + /// int is_display = 0; + /// int err = BADGE_ERROR_NONE; + /// + /// err = badge_get_display(app_id, &is_display); + /// if (err != BADGE_ERROR_NONE) + /// return; + /// } + /// @endcode + int badge_get_display( + ffi.Pointer app_id, + ffi.Pointer is_display, + ) { + return _badge_get_display( + app_id, + is_display, + ); + } + + late final _badge_get_display_ptr = + _lookup>('badge_get_display'); + late final _dart_badge_get_display _badge_get_display = + _badge_get_display_ptr.asFunction<_dart_badge_get_display>(); + + /// @brief Retrieves all existing badges. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/notification + /// @param[in] callback The callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return #BADGE_ERROR_NONE if success, other value if failure + /// @retval BADGE_ERROR_NONE Success + /// @retval BADGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval BADGE_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval BADGE_ERROR_FROM_DB Error form DB + /// @retval BADGE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval BADGE_ERROR_NOT_EXIST Not exist + /// @retval BADGE_ERROR_NOT_SUPPORTED Not supported + /// @see #badge_error_e + /// @see badge_foreach_cb() + int badge_foreach( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _badge_foreach( + callback, + user_data, + ); + } + + late final _badge_foreach_ptr = + _lookup>('badge_foreach'); + late final _dart_badge_foreach _badge_foreach = + _badge_foreach_ptr.asFunction<_dart_badge_foreach>(); + + /// @brief Registers a callback function to receive badge change event. + /// @remarks Should be used in the homescreen.\n + /// Prospective Clients : Homescreen. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/notification + /// @param[in] callback The callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return #BADGE_ERROR_NONE if success, other value if failure + /// @retval BADGE_ERROR_NONE Success + /// @retval BADGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval BADGE_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval BADGE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval BADGE_ERROR_NOT_SUPPORTED Not supported + /// @see #badge_error_e + /// @see badge_new() + /// @see badge_remove() + /// @see badge_set_count() + int badge_register_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _badge_register_changed_cb( + callback, + user_data, + ); + } + + late final _badge_register_changed_cb_ptr = + _lookup>( + 'badge_register_changed_cb'); + late final _dart_badge_register_changed_cb _badge_register_changed_cb = + _badge_register_changed_cb_ptr + .asFunction<_dart_badge_register_changed_cb>(); + + /// @brief Unregisters a callback function to receive badge change event. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/notification + /// @param[in] callback The callback function + /// @return #BADGE_ERROR_NONE if success, other value if failure + /// @retval BADGE_ERROR_NONE Success + /// @retval BADGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval BADGE_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval BADGE_ERROR_NOT_EXIST Not exist + /// @retval BADGE_ERROR_NOT_SUPPORTED Not supported + /// @see #badge_error_e + /// @see badge_register_changed_cb() + int badge_unregister_changed_cb( + ffi.Pointer> callback, + ) { + return _badge_unregister_changed_cb( + callback, + ); + } + + late final _badge_unregister_changed_cb_ptr = + _lookup>( + 'badge_unregister_changed_cb'); + late final _dart_badge_unregister_changed_cb _badge_unregister_changed_cb = + _badge_unregister_changed_cb_ptr + .asFunction<_dart_badge_unregister_changed_cb>(); + + /// @brief Moves the cursor to the first position. + /// @since_tizen 2.3 + /// @remarks The following example demonstrates how to use the %data_control_sql_step_first() method: + /// + /// @code + /// + /// void + /// sql_select_response_cb(int request_id, data_control_h provider, result_set_cursor cursor, + /// bool provider_result, const char *error) + /// { + /// char person_name[32] = {0,}; + /// long long person_number = -1; + /// + /// data_control_sql_step_first(cursor); + /// data_control_sql_get_text_data(cursor, 0, person_name); + /// data_control_sql_get_int64_data(cursor, 1, &person_number); + /// printf("The person %s has the number %l", person_name, person_number); + /// } + /// + /// @endcode + /// + /// @param[in] cursor The cursor that navigates the result of the request for the select operation + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_sql_step_first( + ffi.Pointer cursor, + ) { + return _data_control_sql_step_first( + cursor, + ); + } + + late final _data_control_sql_step_first_ptr = + _lookup>( + 'data_control_sql_step_first'); + late final _dart_data_control_sql_step_first _data_control_sql_step_first = + _data_control_sql_step_first_ptr + .asFunction<_dart_data_control_sql_step_first>(); + + /// @brief Moves the cursor to the last position. + /// @since_tizen 2.3 + /// @remarks The following example demonstrates how to use the %data_control_sql_step_last() method: + /// + /// @code + /// + /// void + /// sql_select_response_cb(int request_id, data_control_h provider, result_set_cursor cursor, + /// bool provider_result, const char *error) + /// { + /// char person_name[32] = {0,}; + /// long long person_number = -1; + /// + /// data_control_sql_step_last(cursor); + /// data_control_sql_get_text_data(cursor, 0, person_name); + /// data_control_sql_get_int64_data(cursor, 1, &person_number); + /// printf("The person %s has the number %l", person_name, person_number); + /// } + /// + /// @endcode + /// + /// @param[in] cursor The cursor that navigates the result of data control select request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_sql_step_last( + ffi.Pointer cursor, + ) { + return _data_control_sql_step_last( + cursor, + ); + } + + late final _data_control_sql_step_last_ptr = + _lookup>( + 'data_control_sql_step_last'); + late final _dart_data_control_sql_step_last _data_control_sql_step_last = + _data_control_sql_step_last_ptr + .asFunction<_dart_data_control_sql_step_last>(); + + /// @brief Moves the cursor to the next position. + /// @since_tizen 2.3 + /// @remarks The following example demonstrates how to use the %data_control_sql_step_next() method: + /// + /// @code + /// + /// void + /// sql_select_response_cb(int request_id, data_control_h provider, result_set_cursor cursor, + /// bool provider_result, const char *error) + /// { + /// char person_name[32] = {0,}; + /// long long person_number = -1; + /// while (data_control_sql_step_next(cursor) == DATA_CONTROL_ERROR_NONE) { + /// data_control_sql_get_text_data(cursor, 0, person_name); + /// data_control_sql_get_int64_data(cursor, 1, &person_number); + /// printf("The person %s has the number %l", person_name, person_number); + /// } + /// } + /// + /// @endcode + /// + /// @param[in] cursor The cursor that navigates the result of the request for the select operation + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_sql_step_next( + ffi.Pointer cursor, + ) { + return _data_control_sql_step_next( + cursor, + ); + } + + late final _data_control_sql_step_next_ptr = + _lookup>( + 'data_control_sql_step_next'); + late final _dart_data_control_sql_step_next _data_control_sql_step_next = + _data_control_sql_step_next_ptr + .asFunction<_dart_data_control_sql_step_next>(); + + /// @brief Moves the cursor to the previous position. + /// @since_tizen 2.3 + /// @param[in] cursor The cursor that navigates the result of the request for the select operation + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_sql_step_previous( + ffi.Pointer cursor, + ) { + return _data_control_sql_step_previous( + cursor, + ); + } + + late final _data_control_sql_step_previous_ptr = + _lookup>( + 'data_control_sql_step_previous'); + late final _dart_data_control_sql_step_previous + _data_control_sql_step_previous = _data_control_sql_step_previous_ptr + .asFunction<_dart_data_control_sql_step_previous>(); + + /// @brief Gets the number of columns for this cursor. + /// @since_tizen 2.3 + /// @param[in] cursor The cursor that navigates the result of the request for the select operation + /// @return The number of columns in the calling cursor + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_sql_get_column_count( + ffi.Pointer cursor, + ) { + return _data_control_sql_get_column_count( + cursor, + ); + } + + late final _data_control_sql_get_column_count_ptr = + _lookup>( + 'data_control_sql_get_column_count'); + late final _dart_data_control_sql_get_column_count + _data_control_sql_get_column_count = + _data_control_sql_get_column_count_ptr + .asFunction<_dart_data_control_sql_get_column_count>(); + + /// @brief Gets the name of the column indicated by the specified index. + /// @since_tizen 2.3 + /// @param[in] cursor The cursor that navigates the result of the request for the select operation + /// @param[in] column_index The index of the destination column + /// @param[out] name The name of the destination column. You should provide a buffer for the column name. The limit of column name length is 4096 bytes + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_sql_get_column_name( + ffi.Pointer cursor, + int column_index, + ffi.Pointer name, + ) { + return _data_control_sql_get_column_name( + cursor, + column_index, + name, + ); + } + + late final _data_control_sql_get_column_name_ptr = + _lookup>( + 'data_control_sql_get_column_name'); + late final _dart_data_control_sql_get_column_name + _data_control_sql_get_column_name = _data_control_sql_get_column_name_ptr + .asFunction<_dart_data_control_sql_get_column_name>(); + + /// @brief Gets the size of the data in the column indicated by the specified index. + /// @since_tizen 2.3 + /// @param[in] cursor The cursor that navigates the result of the request for the select operation + /// @param[in] column_index The index of the destination column + /// @return The size of data in the column indicated by the specified index \n + /// If an error is occurred, then a negative value is returned + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_sql_get_column_item_size( + ffi.Pointer cursor, + int column_index, + ) { + return _data_control_sql_get_column_item_size( + cursor, + column_index, + ); + } + + late final _data_control_sql_get_column_item_size_ptr = + _lookup>( + 'data_control_sql_get_column_item_size'); + late final _dart_data_control_sql_get_column_item_size + _data_control_sql_get_column_item_size = + _data_control_sql_get_column_item_size_ptr + .asFunction<_dart_data_control_sql_get_column_item_size>(); + + /// @brief Gets the type of the column indicated by the specified index. + /// @since_tizen 2.3 + /// @param[in] cursor The cursor that navigates the result of the request for the select operation + /// @param[in] column_index The index of the destination column + /// @param[out] type The type of the destination column + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_sql_get_column_item_type( + ffi.Pointer cursor, + int column_index, + ffi.Pointer type, + ) { + return _data_control_sql_get_column_item_type( + cursor, + column_index, + type, + ); + } + + late final _data_control_sql_get_column_item_type_ptr = + _lookup>( + 'data_control_sql_get_column_item_type'); + late final _dart_data_control_sql_get_column_item_type + _data_control_sql_get_column_item_type = + _data_control_sql_get_column_item_type_ptr + .asFunction<_dart_data_control_sql_get_column_item_type>(); + + /// @brief Gets a blob data from the column indicated by the specified index. + /// @since_tizen 2.3 + /// @param[in] cursor The cursor that navigates the result of the request for the select operation + /// @param[in] column_index The index of the destination column + /// @param[out] data The blob value obtained from the column + /// @param[out] size The size of the data + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_MAX_EXCEEDED Too long argument + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_sql_get_blob_data( + ffi.Pointer cursor, + int column_index, + ffi.Pointer data, + int size, + ) { + return _data_control_sql_get_blob_data( + cursor, + column_index, + data, + size, + ); + } + + late final _data_control_sql_get_blob_data_ptr = + _lookup>( + 'data_control_sql_get_blob_data'); + late final _dart_data_control_sql_get_blob_data + _data_control_sql_get_blob_data = _data_control_sql_get_blob_data_ptr + .asFunction<_dart_data_control_sql_get_blob_data>(); + + /// @brief Gets an int value from the column indicated by the specified index. + /// @since_tizen 2.3 + /// @param[in] cursor The cursor that navigates the result of the request for the select operation + /// @param[in] column_index The index of the destination column + /// @param[out] data The integer value obtained from the column + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_sql_get_int_data( + ffi.Pointer cursor, + int column_index, + ffi.Pointer data, + ) { + return _data_control_sql_get_int_data( + cursor, + column_index, + data, + ); + } + + late final _data_control_sql_get_int_data_ptr = + _lookup>( + 'data_control_sql_get_int_data'); + late final _dart_data_control_sql_get_int_data + _data_control_sql_get_int_data = _data_control_sql_get_int_data_ptr + .asFunction<_dart_data_control_sql_get_int_data>(); + + /// @brief Gets a long long value from the column indicated by the specified index. + /// @since_tizen 2.3 + /// @param[in] cursor The cursor that navigates the result of the request for the select operation + /// @param[in] column_index The index of the destination column + /// @param[out] data The 64-bit integer value obtained from the column + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_sql_get_int64_data( + ffi.Pointer cursor, + int column_index, + ffi.Pointer data, + ) { + return _data_control_sql_get_int64_data( + cursor, + column_index, + data, + ); + } + + late final _data_control_sql_get_int64_data_ptr = + _lookup>( + 'data_control_sql_get_int64_data'); + late final _dart_data_control_sql_get_int64_data + _data_control_sql_get_int64_data = _data_control_sql_get_int64_data_ptr + .asFunction<_dart_data_control_sql_get_int64_data>(); + + /// @brief Gets a double value from the column indicated by the specified index. + /// @since_tizen 2.3 + /// @param[in] cursor The cursor that navigates the result of the request for the select operation + /// @param[in] column_index The index of the destination column + /// @param[out] data The value obtained from the column as double + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_sql_get_double_data( + ffi.Pointer cursor, + int column_index, + ffi.Pointer data, + ) { + return _data_control_sql_get_double_data( + cursor, + column_index, + data, + ); + } + + late final _data_control_sql_get_double_data_ptr = + _lookup>( + 'data_control_sql_get_double_data'); + late final _dart_data_control_sql_get_double_data + _data_control_sql_get_double_data = _data_control_sql_get_double_data_ptr + .asFunction<_dart_data_control_sql_get_double_data>(); + + /// @brief Gets a text value from the column indicated by the specified index. + /// @since_tizen 2.3 + /// @param[in] cursor The cursor that navigates the result of the request for the select operation + /// @param[in] column_index The index of the destination column + /// @param[out] data The value obtained from the column as text. You should provide a buffer for the data. You can get the size of data via data_control_sql_get_column_item_size() + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + int data_control_sql_get_text_data( + ffi.Pointer cursor, + int column_index, + ffi.Pointer data, + ) { + return _data_control_sql_get_text_data( + cursor, + column_index, + data, + ); + } + + late final _data_control_sql_get_text_data_ptr = + _lookup>( + 'data_control_sql_get_text_data'); + late final _dart_data_control_sql_get_text_data + _data_control_sql_get_text_data = _data_control_sql_get_text_data_ptr + .asFunction<_dart_data_control_sql_get_text_data>(); + + /// @brief Gets the n-th bundle from bulk data. + /// @since_tizen 3.0 + /// @remarks The @a data should not be released. \n + /// It will be released when data_control_bulk_data_destroy() is called. + /// @param[in] bulk_data The bulk data handle + /// @param[in] idx The bundle index. Index starts at 0 + /// @param[out] data The n-th bundle. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_bulk_data_add() + /// @see data_control_bulk_data_destroy() + int data_control_bulk_data_get_data( + ffi.Pointer bulk_data, + int idx, + ffi.Pointer> data, + ) { + return _data_control_bulk_data_get_data( + bulk_data, + idx, + data, + ); + } + + late final _data_control_bulk_data_get_data_ptr = + _lookup>( + 'data_control_bulk_data_get_data'); + late final _dart_data_control_bulk_data_get_data + _data_control_bulk_data_get_data = _data_control_bulk_data_get_data_ptr + .asFunction<_dart_data_control_bulk_data_get_data>(); + + /// @brief Gets the bulk data bundle count. + /// @since_tizen 3.0 + /// @param[in] bulk_data The bulk data handle + /// @param[out] count The bundle count + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_bulk_data_get_count( + ffi.Pointer bulk_data, + ffi.Pointer count, + ) { + return _data_control_bulk_data_get_count( + bulk_data, + count, + ); + } + + late final _data_control_bulk_data_get_count_ptr = + _lookup>( + 'data_control_bulk_data_get_count'); + late final _dart_data_control_bulk_data_get_count + _data_control_bulk_data_get_count = _data_control_bulk_data_get_count_ptr + .asFunction<_dart_data_control_bulk_data_get_count>(); + + /// @brief Adds a bundle to bulk data. + /// @since_tizen 3.0 + /// @remarks The order in which bundles are added is preserved. Bundle indexes start from 0. + /// @param[in] bulk_data The bulk data handle + /// @param[in] data The bundle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_bulk_data_add( + ffi.Pointer bulk_data, + ffi.Pointer data, + ) { + return _data_control_bulk_data_add( + bulk_data, + data, + ); + } + + late final _data_control_bulk_data_add_ptr = + _lookup>( + 'data_control_bulk_data_add'); + late final _dart_data_control_bulk_data_add _data_control_bulk_data_add = + _data_control_bulk_data_add_ptr + .asFunction<_dart_data_control_bulk_data_add>(); + + /// @brief Creates bulk data. + /// @since_tizen 3.0 + /// @remarks The @a bulk_data should be released using data_control_bulk_data_destroy(). + /// @param[out] bulk_data The bulk data handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_bulk_data_create( + ffi.Pointer> bulk_data, + ) { + return _data_control_bulk_data_create( + bulk_data, + ); + } + + late final _data_control_bulk_data_create_ptr = + _lookup>( + 'data_control_bulk_data_create'); + late final _dart_data_control_bulk_data_create + _data_control_bulk_data_create = _data_control_bulk_data_create_ptr + .asFunction<_dart_data_control_bulk_data_create>(); + + /// @brief Destroys bulk data. + /// @since_tizen 3.0 + /// @param[in] bulk_data The bulk data handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_bulk_data_destroy( + ffi.Pointer bulk_data, + ) { + return _data_control_bulk_data_destroy( + bulk_data, + ); + } + + late final _data_control_bulk_data_destroy_ptr = + _lookup>( + 'data_control_bulk_data_destroy'); + late final _dart_data_control_bulk_data_destroy + _data_control_bulk_data_destroy = _data_control_bulk_data_destroy_ptr + .asFunction<_dart_data_control_bulk_data_destroy>(); + + /// @brief Gets the n-th bundle from bulk result data. + /// @since_tizen 3.0 + /// @remarks The @a data should not be released. \n + /// It will be released when data_control_bulk_result_data_destroy() is called. + /// @param[in] result_data The bulk result data handle + /// @param[in] idx The bundle index. Index starts at 0 + /// @param[out] data The n-th bundle + /// @param[out] result Bulk operation result. Possible values and their meaning are defined by the developer. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_bulk_result_data_add() + /// @see data_control_bulk_result_data_destroy() + int data_control_bulk_result_data_get_result_data( + ffi.Pointer result_data, + int idx, + ffi.Pointer> data, + ffi.Pointer result, + ) { + return _data_control_bulk_result_data_get_result_data( + result_data, + idx, + data, + result, + ); + } + + late final _data_control_bulk_result_data_get_result_data_ptr = _lookup< + ffi.NativeFunction<_c_data_control_bulk_result_data_get_result_data>>( + 'data_control_bulk_result_data_get_result_data'); + late final _dart_data_control_bulk_result_data_get_result_data + _data_control_bulk_result_data_get_result_data = + _data_control_bulk_result_data_get_result_data_ptr + .asFunction<_dart_data_control_bulk_result_data_get_result_data>(); + + /// @brief Gets the bulk result data bundle count. + /// @since_tizen 3.0 + /// @param[in] result_data The bulk result data handle + /// @param[out] count The bundle count + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_bulk_result_data_get_count( + ffi.Pointer result_data, + ffi.Pointer count, + ) { + return _data_control_bulk_result_data_get_count( + result_data, + count, + ); + } + + late final _data_control_bulk_result_data_get_count_ptr = + _lookup>( + 'data_control_bulk_result_data_get_count'); + late final _dart_data_control_bulk_result_data_get_count + _data_control_bulk_result_data_get_count = + _data_control_bulk_result_data_get_count_ptr + .asFunction<_dart_data_control_bulk_result_data_get_count>(); + + /// @brief Adds bulk data + /// @since_tizen 3.0 + /// @remarks The order in which bundles are added is preserved. Bundle indexes start from 0. + /// @param[in] result_data The bulk result data handle + /// @param[in] data The bundle + /// @param[in] result Bulk operation result. Possible values and their meaning are defined by the developer. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_bulk_result_data_get_result_data() + int data_control_bulk_result_data_add( + ffi.Pointer result_data, + ffi.Pointer data, + int result, + ) { + return _data_control_bulk_result_data_add( + result_data, + data, + result, + ); + } + + late final _data_control_bulk_result_data_add_ptr = + _lookup>( + 'data_control_bulk_result_data_add'); + late final _dart_data_control_bulk_result_data_add + _data_control_bulk_result_data_add = + _data_control_bulk_result_data_add_ptr + .asFunction<_dart_data_control_bulk_result_data_add>(); + + /// @brief Creates bulk result data. + /// @since_tizen 3.0 + /// @remarks The @a result_data should be released using data_control_bulk_result_data_destroy(). + /// @param[out] result_data The bulk result data handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_bulk_result_data_create( + ffi.Pointer> result_data, + ) { + return _data_control_bulk_result_data_create( + result_data, + ); + } + + late final _data_control_bulk_result_data_create_ptr = + _lookup>( + 'data_control_bulk_result_data_create'); + late final _dart_data_control_bulk_result_data_create + _data_control_bulk_result_data_create = + _data_control_bulk_result_data_create_ptr + .asFunction<_dart_data_control_bulk_result_data_create>(); + + /// @brief Destroys bulk result data. + /// @since_tizen 3.0 + /// @param[in] result_data The bulk result data handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_bulk_result_data_destroy( + ffi.Pointer result_data, + ) { + return _data_control_bulk_result_data_destroy( + result_data, + ); + } + + late final _data_control_bulk_result_data_destroy_ptr = + _lookup>( + 'data_control_bulk_result_data_destroy'); + late final _dart_data_control_bulk_result_data_destroy + _data_control_bulk_result_data_destroy = + _data_control_bulk_result_data_destroy_ptr + .asFunction<_dart_data_control_bulk_result_data_destroy>(); + + /// @brief Creates a provider handle. + /// @since_tizen 2.3 + /// + /// @remarks @a provider should be destroyed with data_control_sql_destroy(). + /// The following example demonstrates how to use the %data_control_sql_create() method: + /// + /// @code + /// + /// { + /// const char *provider_id = "http://tizen.org/datacontrol/provider/example"; + /// const char *data_id = "table"; + /// data_control_h provider; + /// int result = 0; + /// + /// result = data_control_sql_create(&provider); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Creating data control provider is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// result = data_control_sql_set_provider_id(provider, provider_id); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Setting providerID is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// result = data_control_sql_set_data_id(provider, data_id); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Setting dataID is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// // Executes some operations + /// + /// result = data_control_sql_destroy(provider); + /// if (result != DATA_CONTROL_ERROR_NONE) + /// LOGE("Destroying data control provider is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// @endcode + /// + /// @param[out] provider The provider handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see data_control_sql_destroy() + int data_control_sql_create( + ffi.Pointer> provider, + ) { + return _data_control_sql_create( + provider, + ); + } + + late final _data_control_sql_create_ptr = + _lookup>( + 'data_control_sql_create'); + late final _dart_data_control_sql_create _data_control_sql_create = + _data_control_sql_create_ptr.asFunction<_dart_data_control_sql_create>(); + + /// @brief Destroys the provider handle and releases all its resources. + /// @since_tizen 2.3 + /// + /// @remarks When operations of data control are finished, this function must be called to prevent the memory leak. + /// + /// @param[in] provider The provider handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_sql_create() + int data_control_sql_destroy( + ffi.Pointer provider, + ) { + return _data_control_sql_destroy( + provider, + ); + } + + late final _data_control_sql_destroy_ptr = + _lookup>( + 'data_control_sql_destroy'); + late final _dart_data_control_sql_destroy _data_control_sql_destroy = + _data_control_sql_destroy_ptr + .asFunction<_dart_data_control_sql_destroy>(); + + /// @brief Sets the Provider ID. + /// @since_tizen 2.3 + /// + /// @param[in] provider The provider handle + /// @param[in] provider_id The data control provider ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see data_control_sql_get_provider_id() + int data_control_sql_set_provider_id( + ffi.Pointer provider, + ffi.Pointer provider_id, + ) { + return _data_control_sql_set_provider_id( + provider, + provider_id, + ); + } + + late final _data_control_sql_set_provider_id_ptr = + _lookup>( + 'data_control_sql_set_provider_id'); + late final _dart_data_control_sql_set_provider_id + _data_control_sql_set_provider_id = _data_control_sql_set_provider_id_ptr + .asFunction<_dart_data_control_sql_set_provider_id>(); + + /// @brief Gets the Provider ID. + /// @since_tizen 2.3 + /// + /// @remarks You must release @a provider_id using free() after it is used. + /// + /// @param[in] provider The provider handle + /// @param[out] provider_id The data control provider ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see data_control_sql_set_provider_id() + int data_control_sql_get_provider_id( + ffi.Pointer provider, + ffi.Pointer> provider_id, + ) { + return _data_control_sql_get_provider_id( + provider, + provider_id, + ); + } + + late final _data_control_sql_get_provider_id_ptr = + _lookup>( + 'data_control_sql_get_provider_id'); + late final _dart_data_control_sql_get_provider_id + _data_control_sql_get_provider_id = _data_control_sql_get_provider_id_ptr + .asFunction<_dart_data_control_sql_get_provider_id>(); + + /// @brief Sets the data ID. + /// @since_tizen 2.3 + /// + /// @param[in] provider The provider handle + /// @param[in] data_id A string for identifying a specific table to operate \n + /// The string consists of one or more components separated by a slash('/') + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see data_control_sql_get_data_id() + /// + /// @code + /// + /// { + /// bundle *b; + /// int ret; + /// + /// // Insert data to Note table + /// ret = data_control_sql_set_data_id(ad->provider_h, "Note"); + /// if (ret != DATA_CONTROL_ERROR_NONE) + /// dlog_print(DLOG_ERROR, LOG_TAG, "setting data id failed with error: %d", ret); + /// + /// b = bundle_create(); + /// bundle_add_str(b, ""TITLE"", "test"); + /// bundle_add_str(b, "CONTENTS", "test contents"); + /// data_control_sql_insert(ad->provider_h, b, &req_id); + /// bundle_free(b); + /// + /// // Insert data to Dictionary table + /// ret = data_control_sql_set_data_id(ad->provider_h, "Dictionary"); + /// if (ret != DATA_CONTROL_ERROR_NONE) + /// dlog_print(DLOG_ERROR, LOG_TAG, "setting data id failed with error: %d", ret); + /// + /// b = bundle_create(); + /// bundle_add_str(b, "WORD", "test"); + /// bundle_add_str(b, "WORD_DESC", "test desc"); + /// data_control_sql_insert(ad->provider_h, b, &req_id); + /// bundle_free(b); + /// } + /// + /// @endcode + int data_control_sql_set_data_id( + ffi.Pointer provider, + ffi.Pointer data_id, + ) { + return _data_control_sql_set_data_id( + provider, + data_id, + ); + } + + late final _data_control_sql_set_data_id_ptr = + _lookup>( + 'data_control_sql_set_data_id'); + late final _dart_data_control_sql_set_data_id _data_control_sql_set_data_id = + _data_control_sql_set_data_id_ptr + .asFunction<_dart_data_control_sql_set_data_id>(); + + /// @brief Gets the data ID. + /// @since_tizen 2.3 + /// + /// @remarks You must release @a data_id using free() after it is used. + /// + /// @param[in] provider The provider handle + /// @param[out] data_id A string for identifying a specific table to operate \n + /// The string consists of one or more components separated by a slash('/') + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see data_control_sql_set_data_id() + int data_control_sql_get_data_id( + ffi.Pointer provider, + ffi.Pointer> data_id, + ) { + return _data_control_sql_get_data_id( + provider, + data_id, + ); + } + + late final _data_control_sql_get_data_id_ptr = + _lookup>( + 'data_control_sql_get_data_id'); + late final _dart_data_control_sql_get_data_id _data_control_sql_get_data_id = + _data_control_sql_get_data_id_ptr + .asFunction<_dart_data_control_sql_get_data_id>(); + + /// @brief Registers a callback function for the SQL data control response. + /// @since_tizen 2.3 + /// + /// @remarks The application is notified when a data control response is received from the @a provider. + /// @remarks Only one callback can be registered for each provider id with this API. + /// @remarks If you register multiple callback for same provider id, it will be overwritten by latest one. + /// + /// + /// @param[in] provider The provider handle + /// @param[in] callback The callback function to be called when a response is received + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see data_control_sql_unregister_response_cb() + /// @see data_control_sql_bind_response_cb() + int data_control_sql_register_response_cb( + ffi.Pointer provider, + ffi.Pointer callback, + ffi.Pointer user_data, + ) { + return _data_control_sql_register_response_cb( + provider, + callback, + user_data, + ); + } + + late final _data_control_sql_register_response_cb_ptr = + _lookup>( + 'data_control_sql_register_response_cb'); + late final _dart_data_control_sql_register_response_cb + _data_control_sql_register_response_cb = + _data_control_sql_register_response_cb_ptr + .asFunction<_dart_data_control_sql_register_response_cb>(); + + /// @brief Unregisters the callback function in the @a provider. + /// @since_tizen 2.3 + /// + /// @param[in] provider The provider handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see data_control_sql_register_response_cb() + int data_control_sql_unregister_response_cb( + ffi.Pointer provider, + ) { + return _data_control_sql_unregister_response_cb( + provider, + ); + } + + late final _data_control_sql_unregister_response_cb_ptr = + _lookup>( + 'data_control_sql_unregister_response_cb'); + late final _dart_data_control_sql_unregister_response_cb + _data_control_sql_unregister_response_cb = + _data_control_sql_unregister_response_cb_ptr + .asFunction<_dart_data_control_sql_unregister_response_cb>(); + + /// @brief Deletes rows of a table owned by the SQL-type data control provider. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing \n + /// %http://tizen.org/privilege/appmanager.launch + /// + /// @remarks If you want to use this api, you must add privileges. + /// @remarks If the value is a string, then the value must be wrapped in single quotes, else it does not need to be wrapped in single quotes. + /// @remarks The following example demonstrates how to use the %data_control_sql_delete() method: + /// + /// @code + /// + /// void + /// sql_delete_response_cb(int request_id, data_control_h provider, bool provider_result, const char *error, void *user_data) + /// { + /// if (provider_result) + /// LOGI(The delete operation is successful"); + /// else + /// LOGI("The delete operation for the request %d is failed. error message: %s", request_id, error); + /// } + /// + /// data_control_sql_response_cb sql_callback; + /// + /// { + /// const char *where = "group = 'friend'"; + /// int result = 0; + /// int req_id = 0; + /// + /// sql_callback.delete_cb = sql_delete_response_cb; + /// result = data_control_sql_register_response_cb(provider, &sql_callback, void *user_data); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Registering the callback function is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// result = data_control_sql_delete(provider, where, &req_id); + /// if (result != DATA_CONTROL_ERROR_NONE) + /// LOGE("Deleting is failed with error: %d", result); + /// else + /// LOGI("req_id is %d", req_id); + /// + /// return result; + /// } + /// + /// @endcode + /// + /// @param[in] provider The provider handle + /// @param[in] where A filter to select the desired rows to delete \n + /// It is an SQL 'WHERE' clause excluding the 'WHERE' itself such as column1 = 'stringValue' and column2 = numericValue + /// @param[out] request_id The request ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + int data_control_sql_delete( + ffi.Pointer provider, + ffi.Pointer where, + ffi.Pointer request_id, + ) { + return _data_control_sql_delete( + provider, + where, + request_id, + ); + } + + late final _data_control_sql_delete_ptr = + _lookup>( + 'data_control_sql_delete'); + late final _dart_data_control_sql_delete _data_control_sql_delete = + _data_control_sql_delete_ptr.asFunction<_dart_data_control_sql_delete>(); + + /// @brief Inserts new rows in a table owned by the SQL-type data control provider. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing \n + /// %http://tizen.org/privilege/appmanager.launch + /// + /// @remarks If you want to use this api, you must add privileges. + /// @remarks The following example demonstrates how to use the %data_control_sql_insert() method: + /// + /// @code + /// + /// void + /// sql_insert_response_cb(int request_id, data_control_h provider, long long inserted_row_id, + /// bool provider_result, const char *error, void *user_data) + /// { + /// if (provider_result) + /// LOGI("The insert operation is successful"); + /// else + /// LOGI("The insert operation for the request %d is failed. error message: %s", request_id, error); + /// } + /// + /// data_control_sql_response_cb sql_callback; + /// + /// { + /// int result = 0; + /// int req_id = 0; + /// bundle *b = NULL; + /// + /// sql_callback.insert_cb = sql_insert_response_cb; + /// result = data_control_sql_register_response_cb(provider, &sql_callback, void *user_data); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Registering the callback function is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// b = bundle_create(); + /// bundle_add(b, "WORD", "test"); + /// bundle_add(b, "WORD_DESC", "test description"); + /// + /// result = data_control_sql_insert(provider, b, &req_id); + /// if (result != DATA_CONTROL_ERROR_NONE) + /// LOGE("Inserting is failed with error: %d", result); + /// else + /// LOGI("req_id is %d", req_id); + /// + /// bundle_free(b); + /// + /// return result; + /// } + /// + /// @endcode + /// + /// @param[in] provider The provider handle + /// @param[in] insert_data The column-value pairs to insert \n + /// If the value is a string, then the value must be wrapped in single quotes, + /// else it does not need to be wrapped in single quotes + /// @param[out] request_id The request ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DATA_CONTROL_ERROR_MAX_EXCEEDED Too long argument + int data_control_sql_insert( + ffi.Pointer provider, + ffi.Pointer insert_data, + ffi.Pointer request_id, + ) { + return _data_control_sql_insert( + provider, + insert_data, + request_id, + ); + } + + late final _data_control_sql_insert_ptr = + _lookup>( + 'data_control_sql_insert'); + late final _dart_data_control_sql_insert _data_control_sql_insert = + _data_control_sql_insert_ptr.asFunction<_dart_data_control_sql_insert>(); + + /// @brief Selects the specified columns to be queried. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing \n + /// %http://tizen.org/privilege/appmanager.launch + /// + /// @remarks If you want to use this api, you must add privileges. + /// @remarks The following example demonstrates how to use the %data_control_sql_select() method: + /// + /// @code + /// + /// void + /// sql_select_response_cb(int request_id, data_control_h provider, result_set_cursor *enumerator, + /// bool provider_result, const char *error, void *user_data) + /// { + /// if (provider_result) + /// LOGI("The select operation is successful"); + /// else + /// LOGI("The select operation for the request %d is failed. error message: %s", request_id, error); + /// } + /// + /// data_control_sql_response_cb sql_callback; + /// + /// { + /// int result = 0; + /// int req_id = 0; + /// char *column_list[2]; + /// column_list[0] = "WORD"; + /// column_list[1] = "WORD_DESC"; + /// const char *where = "WORD = 'test'"; + /// const char *order = "WORD ASC"; + /// + /// sql_callback.select_cb = sql_select_response_cb; + /// result = data_control_sql_register_response_cb(provider, &sql_callback, void *user_data); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Registering the callback function is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// result = data_control_sql_select(provider, column_list, 2, where, order, &req_id); + /// if (result != DATA_CONTROL_ERROR_NONE) + /// LOGE("Selecting is failed with error: %d", result); + /// else + /// LOGI("req_id is %d", req_id); + /// + /// return result; + /// } + /// + /// @endcode + /// + /// + /// @param[in] provider The provider handle + /// @param[in] column_list The column list to query + /// @param[in] column_count The total number of columns to be queried + /// @param[in] where A filter to select the desired rows \n + /// It is an SQL 'WHERE' clause excluding the 'WHERE' itself such as column1 = 'stringValue' and column2 = numericValue + /// @param[in] order The sorting order of the rows to query \n + /// It is an SQL 'ORDER BY' clause excluding the 'ORDER BY' itself. + /// @param[out] request_id The request ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + int data_control_sql_select( + ffi.Pointer provider, + ffi.Pointer> column_list, + int column_count, + ffi.Pointer where, + ffi.Pointer order, + ffi.Pointer request_id, + ) { + return _data_control_sql_select( + provider, + column_list, + column_count, + where, + order, + request_id, + ); + } + + late final _data_control_sql_select_ptr = + _lookup>( + 'data_control_sql_select'); + late final _dart_data_control_sql_select _data_control_sql_select = + _data_control_sql_select_ptr.asFunction<_dart_data_control_sql_select>(); + + /// @brief Selects the specified columns to be queried, with partition into pages. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing \n + /// %http://tizen.org/privilege/appmanager.launch + /// + /// @remarks If you want to use this api, you must add privileges. + /// + /// @param[in] provider The provider handle + /// @param[in] column_list The column list to query + /// @param[in] column_count The total number of columns to be queried + /// @param[in] where A filter to select the desired rows \n + /// It is an SQL 'WHERE' clause excluding the 'WHERE' itself such as column1 = 'stringValue' and column2 = numericValue + /// @param[in] order The sorting order of the rows to query \n + /// It is an SQL 'ORDER BY' clause excluding the 'ORDER BY' itself + /// @param[in] page_number The page number of the result set \n + /// It starts from @c 1 + /// @param[in] count_per_page The desired maximum count of rows on a page + /// @param[out] request_id The request ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + /// @see data_control_sql_select() + int data_control_sql_select_with_page( + ffi.Pointer provider, + ffi.Pointer> column_list, + int column_count, + ffi.Pointer where, + ffi.Pointer order, + int page_number, + int count_per_page, + ffi.Pointer request_id, + ) { + return _data_control_sql_select_with_page( + provider, + column_list, + column_count, + where, + order, + page_number, + count_per_page, + request_id, + ); + } + + late final _data_control_sql_select_with_page_ptr = + _lookup>( + 'data_control_sql_select_with_page'); + late final _dart_data_control_sql_select_with_page + _data_control_sql_select_with_page = + _data_control_sql_select_with_page_ptr + .asFunction<_dart_data_control_sql_select_with_page>(); + + /// @brief Updates values of a table owned by the SQL-type data control provider. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing \n + /// %http://tizen.org/privilege/appmanager.launch + /// + /// @remarks If you want to use this api, you must add privileges. + /// @remarks The following example demonstrates how to use the %data_control_sql_update() method: + /// + /// @code + /// + /// void + /// sql_update_response_cb(int request_id, data_control_h provider, bool provider_result, const char *error, void *user_data) + /// { + /// if (provider_result) + /// LOGI("The update operation is successful"); + /// else + /// LOGI("The update operation for the request %d is failed. error message: %s", request_id, error); + /// } + /// + /// data_control_sql_response_cb sql_callback; + /// + /// { + /// int result = 0; + /// int req_id = 0; + /// const char *where = "WORD = 'test'"; + /// bundle *b = NULL; + /// + /// sql_callback.update_cb = sql_update_response_cb; + /// result = data_control_sql_register_response_cb(provider, &sql_callback, void *user_data); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Registering the callback function is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// b = bundle_create(); + /// bundle_add(b, "WORD", "test_new"); + /// + /// result = data_control_sql_update(provider, b, where, &req_id); + /// if (result != DATA_CONTROL_ERROR_NONE) + /// LOGE("Updating is failed with error: %d", result); + /// else + /// LOGI("req_id is %d", req_id); + /// + /// bundle_free(b); + /// + /// return result; + /// } + /// + /// @endcode + /// + /// + /// @param[in] provider The provider handle + /// @param[in] update_data The column-value pairs to update \n + /// If the value is a string, the value must be wrapped in single quotes, + /// else it does not need to be wrapped in single quotes + /// @param[in] where A filter to select the desired rows to update \n + /// It is an SQL 'WHERE' clause excluding the 'WHERE' itself such as column1 = 'stringValue' and column2 = numericValue + /// @param[out] request_id The request ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DATA_CONTROL_ERROR_MAX_EXCEEDED Too long argument + int data_control_sql_update( + ffi.Pointer provider, + ffi.Pointer update_data, + ffi.Pointer where, + ffi.Pointer request_id, + ) { + return _data_control_sql_update( + provider, + update_data, + where, + request_id, + ); + } + + late final _data_control_sql_update_ptr = + _lookup>( + 'data_control_sql_update'); + late final _dart_data_control_sql_update _data_control_sql_update = + _data_control_sql_update_ptr.asFunction<_dart_data_control_sql_update>(); + + /// @brief Inserts multiple rows in one request. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing \n + /// %http://tizen.org/privilege/appmanager.launch + /// + /// @remarks If you want to use this function, you must add privileges. + /// @remarks The following example demonstrates how to use the %data_control_sql_insert_bulk_data() method: + /// + /// @code + /// + /// void + /// sql_bulk_insert_response_cb(int request_id, data_control_h provider, data_control_bulk_result_data_h bulk_results, + /// bool provider_result, const char *error, void *user_data) + /// { + /// if (provider_result) + /// LOGI("The bulk insert operation is successful"); + /// else + /// LOGI("The bulk insert operation for the request %d is failed. error message: %s", request_id, error); + /// } + /// + /// data_control_sql_response_cb sql_callback; + /// + /// { + /// data_control_bulk_data_h bulk_data; + /// int req_id; + /// bundle *b1; + /// bundle *b2; + /// int result = 0; + /// int req_id = 0; + /// int bulk_count = 0; + /// + /// result = data_control_sql_register_insert_bulk_data_response_cb(provider, sql_bulk_insert_response_cb, user_data); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Registering the callback function is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// b1 = bundle_create(); + /// bundle_add_str(b1, "WORD", "'test'"); + /// bundle_add_str(b1, "WORD_DESC", "'test description'"); + /// b2 = bundle_create(); + /// bundle_add_str(b2, "WORD", "'test2'"); + /// bundle_add_str(b2, "WORD_DESC", "'test2 description'"); + /// + /// data_control_bulk_data_create(&bulk_data); + /// data_control_bulk_data_add(bulk_data, b1); + /// data_control_bulk_data_add(bulk_data, b2); + /// data_control_bulk_data_get_count(bulk_data, &bulk_count); + /// + /// dlog_print(DLOG_INFO, LOG_TAG, "bulk insert count %d ", bulk_count); + /// + /// data_control_sql_insert_bulk_data(provider, bulk_data, &req_id); + /// data_control_bulk_data_destroy(bulk_data); + /// + /// bundle_free(b1); + /// bundle_free(b2); + /// + /// return result; + /// } + /// + /// @endcode + /// + /// @param[in] provider The provider handle + /// @param[in] bulk_data The bulk data handle + /// @param[out] request_id The request ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DATA_CONTROL_ERROR_MAX_EXCEEDED Too long argument + int data_control_sql_insert_bulk_data( + ffi.Pointer provider, + ffi.Pointer bulk_data, + ffi.Pointer request_id, + ) { + return _data_control_sql_insert_bulk_data( + provider, + bulk_data, + request_id, + ); + } + + late final _data_control_sql_insert_bulk_data_ptr = + _lookup>( + 'data_control_sql_insert_bulk_data'); + late final _dart_data_control_sql_insert_bulk_data + _data_control_sql_insert_bulk_data = + _data_control_sql_insert_bulk_data_ptr + .asFunction<_dart_data_control_sql_insert_bulk_data>(); + + /// @brief Registers an insert bulk data callback for the SQL data control response. + /// The application is notified when a data control response is + /// received from the @a provider. + /// @since_tizen 3.0 + /// + /// @remarks Only one callback can be registered for each provider id with this + /// function. If you call this function multiple times for the same + /// provider id, any previously set callback will be overwritten. + /// + /// @param[in] provider The provider handle + /// @param[in] callback The callback function to be called when a response is received + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see data_control_sql_unregister_insert_bulk_data_response_cb() + /// @see data_control_sql_bind_insert_bulk_data_response_cb() + int data_control_sql_register_insert_bulk_data_response_cb( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _data_control_sql_register_insert_bulk_data_response_cb( + provider, + callback, + user_data, + ); + } + + late final _data_control_sql_register_insert_bulk_data_response_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_data_control_sql_register_insert_bulk_data_response_cb>>( + 'data_control_sql_register_insert_bulk_data_response_cb'); + late final _dart_data_control_sql_register_insert_bulk_data_response_cb + _data_control_sql_register_insert_bulk_data_response_cb = + _data_control_sql_register_insert_bulk_data_response_cb_ptr.asFunction< + _dart_data_control_sql_register_insert_bulk_data_response_cb>(); + + /// @brief Unregisters the insert bulk data callback. + /// @since_tizen 3.0 + /// + /// @param[in] provider The provider handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see data_control_sql_register_insert_bulk_data_response_cb() + int data_control_sql_unregister_insert_bulk_data_response_cb( + ffi.Pointer provider, + ) { + return _data_control_sql_unregister_insert_bulk_data_response_cb( + provider, + ); + } + + late final _data_control_sql_unregister_insert_bulk_data_response_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_data_control_sql_unregister_insert_bulk_data_response_cb>>( + 'data_control_sql_unregister_insert_bulk_data_response_cb'); + late final _dart_data_control_sql_unregister_insert_bulk_data_response_cb + _data_control_sql_unregister_insert_bulk_data_response_cb = + _data_control_sql_unregister_insert_bulk_data_response_cb_ptr.asFunction< + _dart_data_control_sql_unregister_insert_bulk_data_response_cb>(); + + /// @brief Binds a callback function to the SQL data control response. + /// @details This function is very similar to + /// data_control_sql_register_response_cb(), which can register a + /// callback for a given provider id. Calling + /// data_control_sql_register_response_cb() again overwrites the + /// callback previously set for the provider id, which means that only + /// one callback can be set for a given id. + /// data_control_sql_bind_response_cb() binds a callback to the handle + /// of a provider, which allows registering multiple callbacks for a + /// given provider id. To do that, you can create new #data_control_h + /// for the same provider id and register callback for the + /// #data_control_h. + /// + /// @since_tizen 4.0 + /// @remarks You can bind a callback function to @a provider. If you call this + /// function multiple times for the same handle, any previously set + /// callback will be overwritten. + /// + /// @param[in] provider The provider handle + /// @param[in] callback The callback function to be called + /// when a response is received + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_sql_register_response_cb() + /// @see data_control_sql_unbind_response_cb() + int data_control_sql_bind_response_cb( + ffi.Pointer provider, + ffi.Pointer callback, + ffi.Pointer user_data, + ) { + return _data_control_sql_bind_response_cb( + provider, + callback, + user_data, + ); + } + + late final _data_control_sql_bind_response_cb_ptr = + _lookup>( + 'data_control_sql_bind_response_cb'); + late final _dart_data_control_sql_bind_response_cb + _data_control_sql_bind_response_cb = + _data_control_sql_bind_response_cb_ptr + .asFunction<_dart_data_control_sql_bind_response_cb>(); + + /// @brief Unbinds the callback function in the @a provider. + /// @since_tizen 4.0 + /// + /// @param[in] provider The provider handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_sql_bind_response_cb() + int data_control_sql_unbind_response_cb( + ffi.Pointer provider, + ) { + return _data_control_sql_unbind_response_cb( + provider, + ); + } + + late final _data_control_sql_unbind_response_cb_ptr = + _lookup>( + 'data_control_sql_unbind_response_cb'); + late final _dart_data_control_sql_unbind_response_cb + _data_control_sql_unbind_response_cb = + _data_control_sql_unbind_response_cb_ptr + .asFunction<_dart_data_control_sql_unbind_response_cb>(); + + /// @brief Binds the insert bulk data callback to the SQL data control response. + /// @details This function is very similar to + /// data_control_sql_register_insert_bulk_data_response_cb(), which can + /// register a callback for a given provider id. Calling + /// data_control_sql_register_insert_bulk_data_response_cb() again + /// overwrites the callback previously set for the provider id, which + /// means that only one callback can be set for a given id. + /// data_control_sql_bind_insert_bulk_data_response_cb() binds a + /// callback to the handle of a provider, which allows registering + /// multiple callbacks for a given provider id. To do that, you can + /// create new #data_control_h for the same provider id and register + /// callback for the #data_control_h. + /// + /// @since_tizen 4.0 + /// @remarks You can bind a callback function to @a provider. If you call this + /// function multiple times for the same handle, any previously set + /// callback will be overwritten. + /// + /// @param[in] provider The provider handle + /// @param[in] callback The callback function to be called + /// when a response is received + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see data_control_sql_register_insert_bulk_data_response_cb() + /// @see data_control_sql_unbind_insert_bulk_data_response_cb() + int data_control_sql_bind_insert_bulk_data_response_cb( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _data_control_sql_bind_insert_bulk_data_response_cb( + provider, + callback, + user_data, + ); + } + + late final _data_control_sql_bind_insert_bulk_data_response_cb_ptr = _lookup< + ffi.NativeFunction< + _c_data_control_sql_bind_insert_bulk_data_response_cb>>( + 'data_control_sql_bind_insert_bulk_data_response_cb'); + late final _dart_data_control_sql_bind_insert_bulk_data_response_cb + _data_control_sql_bind_insert_bulk_data_response_cb = + _data_control_sql_bind_insert_bulk_data_response_cb_ptr.asFunction< + _dart_data_control_sql_bind_insert_bulk_data_response_cb>(); + + /// @brief Unbinds the insert bulk data callback in the @a provider. + /// @since_tizen 4.0 + /// + /// @param[in] provider The provider handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_sql_unbind_insert_bulk_data_response_cb() + int data_control_sql_unbind_insert_bulk_data_response_cb( + ffi.Pointer provider, + ) { + return _data_control_sql_unbind_insert_bulk_data_response_cb( + provider, + ); + } + + late final _data_control_sql_unbind_insert_bulk_data_response_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_data_control_sql_unbind_insert_bulk_data_response_cb>>( + 'data_control_sql_unbind_insert_bulk_data_response_cb'); + late final _dart_data_control_sql_unbind_insert_bulk_data_response_cb + _data_control_sql_unbind_insert_bulk_data_response_cb = + _data_control_sql_unbind_insert_bulk_data_response_cb_ptr.asFunction< + _dart_data_control_sql_unbind_insert_bulk_data_response_cb>(); + + /// @brief Gets the handle ID for @a provider. + /// @since_tizen 4.0 + /// + /// @remarks @a handle_id is generated internally and it is unique for each + /// handle. This function can be used in callbacks to know for which + /// handle the callback was called. + /// + /// @param[in] provider The provider handle + /// @param[out] handle_id The handle ID for @a provider + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_sql_get_handle_id( + ffi.Pointer provider, + ffi.Pointer handle_id, + ) { + return _data_control_sql_get_handle_id( + provider, + handle_id, + ); + } + + late final _data_control_sql_get_handle_id_ptr = + _lookup>( + 'data_control_sql_get_handle_id'); + late final _dart_data_control_sql_get_handle_id + _data_control_sql_get_handle_id = _data_control_sql_get_handle_id_ptr + .asFunction<_dart_data_control_sql_get_handle_id>(); + + /// @brief Creates a provider handle. + /// @since_tizen 2.3 + /// @remarks @a provider should be destroyed with data_control_map_destroy(). + /// The following example demonstrates how to use the %data_control_map_create() method. + /// + /// @code + /// + /// { + /// const char *provider_id = "http://tizen.org/datacontrol/provider/example"; + /// const char *data_id = "table"; + /// data_control_h provider; + /// int result = 0; + /// + /// result = data_control_map_create(&provider); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Creating data control provider is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// result = data_control_map_set_provider_id(provider, provider_id); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Setting providerID is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// result = data_control_map_set_data_id(provider, data_id); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Setting dataID is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// // Executes some operations + /// + /// result = data_control_map_destroy(provider); + /// if (result != DATA_CONTROL_ERROR_NONE) + /// LOGE("Destroying data control provider is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// @endcode + /// + /// @param[out] provider The provider handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see data_control_map_destroy() + int data_control_map_create( + ffi.Pointer> provider, + ) { + return _data_control_map_create( + provider, + ); + } + + late final _data_control_map_create_ptr = + _lookup>( + 'data_control_map_create'); + late final _dart_data_control_map_create _data_control_map_create = + _data_control_map_create_ptr.asFunction<_dart_data_control_map_create>(); + + /// @brief Destroys the provider handle and releases all its resources. + /// @since_tizen 2.3 + /// @remarks When operations of data control are finished, this function must be called to prevent memory leak. + /// @param[in] provider The provider handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_map_create() + int data_control_map_destroy( + ffi.Pointer provider, + ) { + return _data_control_map_destroy( + provider, + ); + } + + late final _data_control_map_destroy_ptr = + _lookup>( + 'data_control_map_destroy'); + late final _dart_data_control_map_destroy _data_control_map_destroy = + _data_control_map_destroy_ptr + .asFunction<_dart_data_control_map_destroy>(); + + /// @brief Sets the Provider ID. + /// @since_tizen 2.3 + /// @param[in] provider The provider handle + /// @param[in] provider_id The data control provider ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see data_control_map_get_provider_id() + int data_control_map_set_provider_id( + ffi.Pointer provider, + ffi.Pointer provider_id, + ) { + return _data_control_map_set_provider_id( + provider, + provider_id, + ); + } + + late final _data_control_map_set_provider_id_ptr = + _lookup>( + 'data_control_map_set_provider_id'); + late final _dart_data_control_map_set_provider_id + _data_control_map_set_provider_id = _data_control_map_set_provider_id_ptr + .asFunction<_dart_data_control_map_set_provider_id>(); + + /// @brief Gets the Provider ID. + /// @since_tizen 2.3 + /// @remarks You must release @a provider_id using free() after it is used. + /// @param[in] provider The provider handle + /// @param[out] provider_id The data control provider ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see data_control_map_set_provider_id() + int data_control_map_get_provider_id( + ffi.Pointer provider, + ffi.Pointer> provider_id, + ) { + return _data_control_map_get_provider_id( + provider, + provider_id, + ); + } + + late final _data_control_map_get_provider_id_ptr = + _lookup>( + 'data_control_map_get_provider_id'); + late final _dart_data_control_map_get_provider_id + _data_control_map_get_provider_id = _data_control_map_get_provider_id_ptr + .asFunction<_dart_data_control_map_get_provider_id>(); + + /// @brief Sets the Data ID. + /// @since_tizen 2.3 + /// @param[in] provider The provider handle + /// @param[in] data_id A string for identifying a specific table to operate \n + /// The string consists of one or more components separated by a slash('/'). + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see data_control_map_get_data_id() + int data_control_map_set_data_id( + ffi.Pointer provider, + ffi.Pointer data_id, + ) { + return _data_control_map_set_data_id( + provider, + data_id, + ); + } + + late final _data_control_map_set_data_id_ptr = + _lookup>( + 'data_control_map_set_data_id'); + late final _dart_data_control_map_set_data_id _data_control_map_set_data_id = + _data_control_map_set_data_id_ptr + .asFunction<_dart_data_control_map_set_data_id>(); + + /// @brief Gets the data ID. + /// @since_tizen 2.3 + /// @remarks You must release @a data_id using free() after it is used. + /// @param[in] provider The provider handle + /// @param[out] data_id A string for identifying a specific table to operate \n + /// The string consists of one or more components separated by a slash('/'). + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see data_control_map_set_data_id() + int data_control_map_get_data_id( + ffi.Pointer provider, + ffi.Pointer> data_id, + ) { + return _data_control_map_get_data_id( + provider, + data_id, + ); + } + + late final _data_control_map_get_data_id_ptr = + _lookup>( + 'data_control_map_get_data_id'); + late final _dart_data_control_map_get_data_id _data_control_map_get_data_id = + _data_control_map_get_data_id_ptr + .asFunction<_dart_data_control_map_get_data_id>(); + + /// @brief Registers a callback function for the key-value structured data control response. + /// The application is notified when a data control response is received from the @a provider. + /// @since_tizen 2.3 + /// + /// @remarks The application is notified when a data control response is received from the @a provider. + /// @remarks Only one callback can be registered for each provider id with this API. + /// @remarks If you register multiple callback for same provider id, it will be overwritten by latest one. + /// + /// @param[in] provider The provider handle + /// @param[in] callback The callback function to be called when a response is received + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @see data_control_map_unregister_response_cb() + /// @see data_control_map_bind_response_cb() + int data_control_map_register_response_cb( + ffi.Pointer provider, + ffi.Pointer callback, + ffi.Pointer user_data, + ) { + return _data_control_map_register_response_cb( + provider, + callback, + user_data, + ); + } + + late final _data_control_map_register_response_cb_ptr = + _lookup>( + 'data_control_map_register_response_cb'); + late final _dart_data_control_map_register_response_cb + _data_control_map_register_response_cb = + _data_control_map_register_response_cb_ptr + .asFunction<_dart_data_control_map_register_response_cb>(); + + /// @brief Unregisters the callback function in the @a provider. + /// @since_tizen 2.3 + /// @param[in] provider The provider handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_map_register_response_cb() + int data_control_map_unregister_response_cb( + ffi.Pointer provider, + ) { + return _data_control_map_unregister_response_cb( + provider, + ); + } + + late final _data_control_map_unregister_response_cb_ptr = + _lookup>( + 'data_control_map_unregister_response_cb'); + late final _dart_data_control_map_unregister_response_cb + _data_control_map_unregister_response_cb = + _data_control_map_unregister_response_cb_ptr + .asFunction<_dart_data_control_map_unregister_response_cb>(); + + /// @brief Gets the value list associated with the specified @a key from the key-values map owned by the key-value structured data control provider. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing \n + /// %http://tizen.org/privilege/appmanager.launch + /// @remarks If you want to use this api, you must add privileges. + /// @remarks If the length of value list associated with the @a key is larger than 20, this API only returns the first 20 values. + /// @remarks The following example demonstrates how to use the %data_control_map_get() method. + /// + /// @code + /// + /// void + /// map_get_response_cb(int request_id, data_control_h provider, char **result_value_list, + /// int ret_value_count, bool provider_result, const char *error, void *user_data) + /// { + /// if (provider_result) + /// LOGI("The get operation is successful"); + /// else + /// LOGI("The get operation for the request %d is failed. error message: %s", request_id, error); + /// } + /// + /// data_control_map_response_cb map_callback; + /// + /// { + /// int result = 0; + /// int req_id = 0; + /// char *key = "key"; + /// + /// map_callback.get_cb = map_get_response_cb; + /// result = data_control_map_register_response_cb(provider, &map_callback, NULL); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Registering the callback function is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// result = data_control_map_get(provider, key, &req_id); + /// if (result != DATA_CONTROL_ERROR_NONE) + /// LOGE("Getting the value list of the key(%s) is failed with error: %d", key, result); + /// else + /// LOGI("req_id is %d", req_id); + /// + /// return result; + /// } + /// + /// @endcode + /// + /// @param[in] provider The provider handle + /// @param[in] key The key of the value list to obtain + /// @param[out] request_id The request ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_MAX_EXCEEDED Too long argument + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + /// @see data_control_map_get_with_page() + int data_control_map_get( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer request_id, + ) { + return _data_control_map_get( + provider, + key, + request_id, + ); + } + + late final _data_control_map_get_ptr = + _lookup>( + 'data_control_map_get'); + late final _dart_data_control_map_get _data_control_map_get = + _data_control_map_get_ptr.asFunction<_dart_data_control_map_get>(); + + /// @brief Gets the value list associated with the specified @a key from the key-values map owned by the key-value structured data control provider, with partition into pages. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing \n + /// %http://tizen.org/privilege/appmanager.launch + /// + /// @remarks If you want to use this api, you must add privileges. + /// @param[in] provider The provider handle + /// @param[in] key The key of the value list to obtain + /// @param[out] request_id The request ID + /// @param[in] page_number The page number of the value set \n + /// It starts from @c 1. + /// @param[in] count_per_page The desired maximum count of the data items per page + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_MAX_EXCEEDED Too long argument + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + /// @see data_control_map_get() + int data_control_map_get_with_page( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer request_id, + int page_number, + int count_per_page, + ) { + return _data_control_map_get_with_page( + provider, + key, + request_id, + page_number, + count_per_page, + ); + } + + late final _data_control_map_get_with_page_ptr = + _lookup>( + 'data_control_map_get_with_page'); + late final _dart_data_control_map_get_with_page + _data_control_map_get_with_page = _data_control_map_get_with_page_ptr + .asFunction<_dart_data_control_map_get_with_page>(); + + /// @brief Sets the value associated with the specified @a key to a new value. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing \n + /// %http://tizen.org/privilege/appmanager.launch + /// @remarks If you want to use this api, you must add privileges. + /// @remarks The following example demonstrates how to use the %data_control_map_set() method. + /// + /// @code + /// + /// void + /// map_set_response_cb(int request_id, data_control_h provider, bool provider_result, const char *error, void *user_data) + /// { + /// if (provider_result) + /// LOGI("The set operation is successful"); + /// else + /// LOGI("The set operation for the request %d is failed. error message: %s", request_id, error); + /// } + /// + /// data_control_map_response_cb map_callback; + /// + /// { + /// int result = 0; + /// int req_id = 0; + /// char *key = "key"; + /// char *old_value = "old value"; + /// char *new_value = "new value"; + /// + /// map_callback.set_cb = map_set_response_cb; + /// result = data_control_map_register_response_cb(provider, &map_callback, NULL); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Registering the callback function is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// result = data_control_map_set(provider, key, old_value, new_value, &req_id); + /// if (result != DATA_CONTROL_ERROR_NONE) + /// LOGE("Replacing old_value(%s) with new_value(%s) is failed with error: %d", old_value, new_value, result); + /// else + /// LOGI("req_id is %d", req_id); + /// + /// return result; + /// } + /// + /// @endcode + /// + /// @param[in] provider The provider handle + /// @param[in] key The key of the value to replace + /// @param[in] old_value The value to replace + /// @param[in] new_value The new value that replaces the existing value + /// @param[out] request_id The request ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_MAX_EXCEEDED Too long argument + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + int data_control_map_set( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer old_value, + ffi.Pointer new_value, + ffi.Pointer request_id, + ) { + return _data_control_map_set( + provider, + key, + old_value, + new_value, + request_id, + ); + } + + late final _data_control_map_set_ptr = + _lookup>( + 'data_control_map_set'); + late final _dart_data_control_map_set _data_control_map_set = + _data_control_map_set_ptr.asFunction<_dart_data_control_map_set>(); + + /// @brief Adds the @a value associated with the specified @a key to the key-values map owned by the key-value structured data control provider. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing \n + /// %http://tizen.org/privilege/appmanager.launch + /// @remarks If you want to use this api, you must add privileges. + /// @remarks The following example demonstrates how to use the %data_control_map_add() method. + /// + /// @code + /// + /// void + /// map_add_response_cb(int request_id, data_control_h provider, bool provider_result, const char *error, void *user_data) + /// { + /// if (provider_result) + /// LOGI("The add operation is successful"); + /// else + /// LOGI("The add operation for the request %d is failed. error message: %s", request_id, error); + /// } + /// + /// data_control_map_response_cb map_callback; + /// + /// { + /// int result = 0; + /// int req_id = 0; + /// const char *key = "key"; + /// const char *value = "value"; + /// + /// map_callback.add_cb = map_add_response_cb; + /// result = data_control_map_register_response_cb(provider, &map_callback, NULL); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Registering the callback function is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// result = data_control_map_add(provider, key, value, &req_id); + /// if (result != DATA_CONTROL_ERROR_NONE) + /// LOGE("Adding %s-%s pair is failed with error: %d", key, value, result); + /// else + /// LOGI("req_id is %d", req_id); + /// + /// return result; + /// } + /// + /// @endcode + /// + /// @param[in] provider The provider handle + /// @param[in] key The key of the value to add + /// @param[in] value The value to add + /// @param[out] request_id The request ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_MAX_EXCEEDED Too long argument + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + int data_control_map_add( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer value, + ffi.Pointer request_id, + ) { + return _data_control_map_add( + provider, + key, + value, + request_id, + ); + } + + late final _data_control_map_add_ptr = + _lookup>( + 'data_control_map_add'); + late final _dart_data_control_map_add _data_control_map_add = + _data_control_map_add_ptr.asFunction<_dart_data_control_map_add>(); + + /// @brief Removes the @a value associated with the specified @a key from the key-values map owned by the key-value structured data control provider. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing \n + /// %http://tizen.org/privilege/appmanager.launch + /// @remarks If you want to use this api, you must add privileges. + /// @remarks The following example demonstrates how to use the %data_control_map_remove() method. + /// + /// @code + /// + /// void + /// map_remove_response_cb(int request_id, data_control_h provider, bool provider_result, const char *error, void *user_data) + /// { + /// if (provider_result) + /// LOGI("The remove operation is successful"); + /// else + /// LOGI("The remove operation for the request %d is failed. error message: %s", request_id, error); + /// } + /// + /// data_control_map_response_cb map_callback; + /// + /// { + /// int result = 0; + /// int req_id = 0; + /// const char *key = "key"; + /// const char *value = "value"; + /// + /// map_callback.remove_cb = map_remove_response_cb; + /// result = data_control_map_register_response_cb(provider, &map_callback, NULL); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Registering the callback function is failed with error: %d", result); + /// + /// return result; + /// } + /// + /// result = data_control_map_remove(provider, key, value, &req_id); + /// if (result != DATA_CONTROL_ERROR_NONE) + /// LOGE("Removing %s-%s pair is failed with error: %d", key, value, result); + /// else + /// LOGI("req_id is %d", req_id); + /// + /// return result; + /// } + /// + /// @endcode + /// + /// @param[in] provider The provider handle + /// @param[in] key The key of the value to remove + /// @param[in] value The value to remove + /// @param[out] request_id The request ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_MAX_EXCEEDED Too long argument + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + int data_control_map_remove( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer value, + ffi.Pointer request_id, + ) { + return _data_control_map_remove( + provider, + key, + value, + request_id, + ); + } + + late final _data_control_map_remove_ptr = + _lookup>( + 'data_control_map_remove'); + late final _dart_data_control_map_remove _data_control_map_remove = + _data_control_map_remove_ptr.asFunction<_dart_data_control_map_remove>(); + + /// @brief Adds multiple key-value pairs in one request. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing \n + /// %http://tizen.org/privilege/appmanager.launch + /// @remarks If you want to use this function, you must add privileges. + /// @remarks The following example demonstrates how to use the %data_control_map_add_bulk_data() method. + /// + /// @code + /// + /// void + /// map_bulk_add_response_cb(int request_id, data_control_h provider, data_control_bulk_result_data_h bulk_results, + /// bool provider_result, const char *error, void *user_data) + /// { + /// if (provider_result) + /// LOGI("The add operation is successful"); + /// else + /// LOGI("The add operation for the request %d is failed. error message: %s", request_id, error); + /// } + /// + /// data_control_map_response_cb map_callback; + /// { + /// data_control_bulk_data_h bulk_data; + /// int req_id; + /// bundle *b1; + /// bundle *b2; + /// int result = 0; + /// int req_id = 0; + /// int count; + /// + /// result = data_control_map_register_add_bulk_data_response_cb(provider, map_bulk_add_response_cb, user_data); + /// if (result != DATA_CONTROL_ERROR_NONE) { + /// LOGE("Registering the callback function is failed with error: %d", result); + /// return result; + /// } + /// + /// b1 = bundle_create(); + /// bundle_add_str(b1, "key", "test key"); + /// bundle_add_str(b1, "value", "test value"); + /// b2 = bundle_create(); + /// bundle_add_str(b2, "key", "test key2"); + /// bundle_add_str(b2, "value", "test value2"); + /// + /// data_control_bulk_data_create(&bulk_data); + /// data_control_bulk_data_add(bulk_data, b1); + /// data_control_bulk_data_add(bulk_data, b2); + /// + /// data_control_bulk_data_get_count(bulk_data, &count); + /// dlog_print(DLOG_INFO, LOG_TAG, "bulk add count %d ", count); + /// + /// data_control_map_add_bulk_data(provider, bulk_data, &req_id); + /// data_control_bulk_data_destroy(bulk_data); + /// + /// bundle_free(b1); + /// bundle_free(b2); + /// return result; + /// } + /// + /// @endcode + /// + /// @param[in] provider The provider handle + /// @param[in] bulk_data The bulk data handle + /// @param[out] request_id The request ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_MAX_EXCEEDED Too long argument. Bulk data total length cannot exceed 1MB + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + int data_control_map_add_bulk_data( + ffi.Pointer provider, + ffi.Pointer bulk_data, + ffi.Pointer request_id, + ) { + return _data_control_map_add_bulk_data( + provider, + bulk_data, + request_id, + ); + } + + late final _data_control_map_add_bulk_data_ptr = + _lookup>( + 'data_control_map_add_bulk_data'); + late final _dart_data_control_map_add_bulk_data + _data_control_map_add_bulk_data = _data_control_map_add_bulk_data_ptr + .asFunction<_dart_data_control_map_add_bulk_data>(); + + /// @brief Registers an add bulk data callback for the MAP data control response. + /// The application is notified when a data control response is received + /// from the @a provider. + /// @since_tizen 3.0 + /// + /// @remarks Only one callback can be registered for each provider id with this + /// function. If you call this function multiple times for the same + /// provider id, any previously set callback will be overwritten. + /// @param[in] provider The provider handle + /// @param[in] callback The callback function to be called when a response is received + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_map_unregister_add_bulk_data_response_cb() + /// @see data_control_map_bind_add_bulk_data_response_cb() + int data_control_map_register_add_bulk_data_response_cb( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _data_control_map_register_add_bulk_data_response_cb( + provider, + callback, + user_data, + ); + } + + late final _data_control_map_register_add_bulk_data_response_cb_ptr = _lookup< + ffi.NativeFunction< + _c_data_control_map_register_add_bulk_data_response_cb>>( + 'data_control_map_register_add_bulk_data_response_cb'); + late final _dart_data_control_map_register_add_bulk_data_response_cb + _data_control_map_register_add_bulk_data_response_cb = + _data_control_map_register_add_bulk_data_response_cb_ptr.asFunction< + _dart_data_control_map_register_add_bulk_data_response_cb>(); + + /// @brief Unregisters the add bulk data callback. + /// @since_tizen 3.0 + /// @param[in] provider The provider handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_map_register_add_bulk_data_response_cb() + int data_control_map_unregister_add_bulk_data_response_cb( + ffi.Pointer provider, + ) { + return _data_control_map_unregister_add_bulk_data_response_cb( + provider, + ); + } + + late final _data_control_map_unregister_add_bulk_data_response_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_data_control_map_unregister_add_bulk_data_response_cb>>( + 'data_control_map_unregister_add_bulk_data_response_cb'); + late final _dart_data_control_map_unregister_add_bulk_data_response_cb + _data_control_map_unregister_add_bulk_data_response_cb = + _data_control_map_unregister_add_bulk_data_response_cb_ptr.asFunction< + _dart_data_control_map_unregister_add_bulk_data_response_cb>(); + + /// @brief Binds a response callback function to a data control provider handle. + /// The application is notified when a data control response is received + /// from the @a provider. + /// @details This function is very similar to + /// data_control_map_register_response_cb(), which can register a + /// callback for a given provider id. Calling + /// data_control_map_register_response_cb() again overwrites the + /// callback previously set for the provider id, which means that only + /// one callback can be set for a given id. + /// data_control_map_bind_response_cb() binds a callback to the handle + /// of a provider, which allows registering multiple callbacks for a + /// given provider id. To do that, you can create new #data_control_h + /// for the same provider id and register callback for the + /// #data_control_h. + /// + /// @since_tizen 4.0 + /// + /// @remarks If you call this function multiple times for the same handle, any + /// previously set callback will be overwritten. + /// + /// @param[in] provider The provider handle + /// @param[in] callback The callback function to be called + /// when a response is received + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_map_register_response_cb() + /// @see data_control_map_unbind_response_cb() + int data_control_map_bind_response_cb( + ffi.Pointer provider, + ffi.Pointer callback, + ffi.Pointer user_data, + ) { + return _data_control_map_bind_response_cb( + provider, + callback, + user_data, + ); + } + + late final _data_control_map_bind_response_cb_ptr = + _lookup>( + 'data_control_map_bind_response_cb'); + late final _dart_data_control_map_bind_response_cb + _data_control_map_bind_response_cb = + _data_control_map_bind_response_cb_ptr + .asFunction<_dart_data_control_map_bind_response_cb>(); + + /// @brief Unbinds the callback function in the @a provider. + /// @since_tizen 4.0 + /// + /// @param[in] provider The provider handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_bind_map_response_cb() + int data_control_map_unbind_response_cb( + ffi.Pointer provider, + ) { + return _data_control_map_unbind_response_cb( + provider, + ); + } + + late final _data_control_map_unbind_response_cb_ptr = + _lookup>( + 'data_control_map_unbind_response_cb'); + late final _dart_data_control_map_unbind_response_cb + _data_control_map_unbind_response_cb = + _data_control_map_unbind_response_cb_ptr + .asFunction<_dart_data_control_map_unbind_response_cb>(); + + /// @brief Binds the add bulk data callback to the map data control response. + /// @details This function is very similar to + /// data_control_map_register_add_bulk_data_response_cb(), which can + /// register a callback for a given provider id. Calling + /// data_control_map_register_add_bulk_data_response_cb() again + /// overwrites the callback previously set for the provider id, which + /// means that only one callback can be set for a given id. + /// data_control_map_bind_add_bulk_data_response_cb() binds a + /// callback to the handle of a provider, which allows registering + /// multiple callbacks for a given provider id. To do that, you can + /// create new #data_control_h for the same provider id and register + /// callback for the #data_control_h. + /// + /// @since_tizen 4.0 + /// @remarks If you call this function multiple times for the same handle, + /// any previously set callback will be overwritten. + /// + /// @param[in] provider The provider handle + /// @param[in] callback The callback function to be called + /// when a response is received + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_map_register_add_bulk_data_response_cb() + /// @see data_control_map_unbind_add_bulk_data_response_cb() + int data_control_map_bind_add_bulk_data_response_cb( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _data_control_map_bind_add_bulk_data_response_cb( + provider, + callback, + user_data, + ); + } + + late final _data_control_map_bind_add_bulk_data_response_cb_ptr = _lookup< + ffi.NativeFunction< + _c_data_control_map_bind_add_bulk_data_response_cb>>( + 'data_control_map_bind_add_bulk_data_response_cb'); + late final _dart_data_control_map_bind_add_bulk_data_response_cb + _data_control_map_bind_add_bulk_data_response_cb = + _data_control_map_bind_add_bulk_data_response_cb_ptr + .asFunction<_dart_data_control_map_bind_add_bulk_data_response_cb>(); + + /// @brief Unbinds the add bulk data callback in the @a provider. + /// @since_tizen 4.0 + /// + /// @param[in] provider The provider handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_map_bind_add_bulk_data_response_cb() + int data_control_map_unbind_add_bulk_data_response_cb( + ffi.Pointer provider, + ) { + return _data_control_map_unbind_add_bulk_data_response_cb( + provider, + ); + } + + late final _data_control_map_unbind_add_bulk_data_response_cb_ptr = _lookup< + ffi.NativeFunction< + _c_data_control_map_unbind_add_bulk_data_response_cb>>( + 'data_control_map_unbind_add_bulk_data_response_cb'); + late final _dart_data_control_map_unbind_add_bulk_data_response_cb + _data_control_map_unbind_add_bulk_data_response_cb = + _data_control_map_unbind_add_bulk_data_response_cb_ptr.asFunction< + _dart_data_control_map_unbind_add_bulk_data_response_cb>(); + + /// @brief Gets the handle ID for @a provider. + /// @since_tizen 4.0 + /// + /// @remarks @a handle_id is generated internally and it is unique for each + /// handle. This function can be used in callbacks to know for which + /// handle the callback was called. + /// + /// @param[in] provider The provider handle + /// @param[out] handle_id The handle ID for @a provider + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_map_get_handle_id( + ffi.Pointer provider, + ffi.Pointer handle_id, + ) { + return _data_control_map_get_handle_id( + provider, + handle_id, + ); + } + + late final _data_control_map_get_handle_id_ptr = + _lookup>( + 'data_control_map_get_handle_id'); + late final _dart_data_control_map_get_handle_id + _data_control_map_get_handle_id = _data_control_map_get_handle_id_ptr + .asFunction<_dart_data_control_map_get_handle_id>(); + + /// @brief Registers a callback function for the SQL data control request. + /// The provider is notified when a data control request is received from the client applications. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing + /// + /// @param[in] callback The callback function to be called when a data control request is received + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + int data_control_provider_sql_register_cb( + ffi.Pointer callback, + ffi.Pointer user_data, + ) { + return _data_control_provider_sql_register_cb( + callback, + user_data, + ); + } + + late final _data_control_provider_sql_register_cb_ptr = + _lookup>( + 'data_control_provider_sql_register_cb'); + late final _dart_data_control_provider_sql_register_cb + _data_control_provider_sql_register_cb = + _data_control_provider_sql_register_cb_ptr + .asFunction<_dart_data_control_provider_sql_register_cb>(); + + /// @brief Unregisters the SQL data control request callback functions. + /// @since_tizen 2.3 + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + int data_control_provider_sql_unregister_cb() { + return _data_control_provider_sql_unregister_cb(); + } + + late final _data_control_provider_sql_unregister_cb_ptr = + _lookup>( + 'data_control_provider_sql_unregister_cb'); + late final _dart_data_control_provider_sql_unregister_cb + _data_control_provider_sql_unregister_cb = + _data_control_provider_sql_unregister_cb_ptr + .asFunction<_dart_data_control_provider_sql_unregister_cb>(); + + /// @brief Registers a callback function for the map data control request. + /// The provider is notified when a data control request is received from the client applications. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing + /// + /// @param[in] callback The callback function to be called when a data control request is received + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + int data_control_provider_map_register_cb( + ffi.Pointer callback, + ffi.Pointer user_data, + ) { + return _data_control_provider_map_register_cb( + callback, + user_data, + ); + } + + late final _data_control_provider_map_register_cb_ptr = + _lookup>( + 'data_control_provider_map_register_cb'); + late final _dart_data_control_provider_map_register_cb + _data_control_provider_map_register_cb = + _data_control_provider_map_register_cb_ptr + .asFunction<_dart_data_control_provider_map_register_cb>(); + + /// @brief Unregisters the map data control request callback functions. + /// @since_tizen 2.3 + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + int data_control_provider_map_unregister_cb() { + return _data_control_provider_map_unregister_cb(); + } + + late final _data_control_provider_map_unregister_cb_ptr = + _lookup>( + 'data_control_provider_map_unregister_cb'); + late final _dart_data_control_provider_map_unregister_cb + _data_control_provider_map_unregister_cb = + _data_control_provider_map_unregister_cb_ptr + .asFunction<_dart_data_control_provider_map_unregister_cb>(); + + /// @brief Gets the application ID which sends the data control request. + /// @since_tizen 2.3 + /// + /// @remarks You must release @a appid using free() after it is used. + /// + /// @param[in] request_id The request ID + /// @param[out] appid The application ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_provider_get_client_appid( + int request_id, + ffi.Pointer> appid, + ) { + return _data_control_provider_get_client_appid( + request_id, + appid, + ); + } + + late final _data_control_provider_get_client_appid_ptr = + _lookup>( + 'data_control_provider_get_client_appid'); + late final _dart_data_control_provider_get_client_appid + _data_control_provider_get_client_appid = + _data_control_provider_get_client_appid_ptr + .asFunction<_dart_data_control_provider_get_client_appid>(); + + /// @brief Sends the success result and the result set of the select request to the client application. + /// @since_tizen 2.3 + /// + /// @param[in] request_id The request ID + /// @param[in] db_handle The result DB handle for the result set + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_provider_send_select_result( + int request_id, + ffi.Pointer db_handle, + ) { + return _data_control_provider_send_select_result( + request_id, + db_handle, + ); + } + + late final _data_control_provider_send_select_result_ptr = + _lookup>( + 'data_control_provider_send_select_result'); + late final _dart_data_control_provider_send_select_result + _data_control_provider_send_select_result = + _data_control_provider_send_select_result_ptr + .asFunction<_dart_data_control_provider_send_select_result>(); + + /// @brief Sends the success result of the insert request and the last inserted row ID to the client application. + /// @since_tizen 2.3 + /// + /// @param[in] request_id The request ID + /// @param[in] row_id The row ID of the database changed by the insert request + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_provider_send_insert_result( + int request_id, + int row_id, + ) { + return _data_control_provider_send_insert_result( + request_id, + row_id, + ); + } + + late final _data_control_provider_send_insert_result_ptr = + _lookup>( + 'data_control_provider_send_insert_result'); + late final _dart_data_control_provider_send_insert_result + _data_control_provider_send_insert_result = + _data_control_provider_send_insert_result_ptr + .asFunction<_dart_data_control_provider_send_insert_result>(); + + /// @brief Sends the success result of the update request to the client application. + /// @since_tizen 2.3 + /// + /// @param[in] request_id The request ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_provider_send_update_result( + int request_id, + ) { + return _data_control_provider_send_update_result( + request_id, + ); + } + + late final _data_control_provider_send_update_result_ptr = + _lookup>( + 'data_control_provider_send_update_result'); + late final _dart_data_control_provider_send_update_result + _data_control_provider_send_update_result = + _data_control_provider_send_update_result_ptr + .asFunction<_dart_data_control_provider_send_update_result>(); + + /// @brief Sends the success result of the delete request to the client application. + /// @since_tizen 2.3 + /// + /// @param[in] request_id The request ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_provider_send_delete_result( + int request_id, + ) { + return _data_control_provider_send_delete_result( + request_id, + ); + } + + late final _data_control_provider_send_delete_result_ptr = + _lookup>( + 'data_control_provider_send_delete_result'); + late final _dart_data_control_provider_send_delete_result + _data_control_provider_send_delete_result = + _data_control_provider_send_delete_result_ptr + .asFunction<_dart_data_control_provider_send_delete_result>(); + + /// @brief Sends the provider error message to the client application. + /// @since_tizen 2.3 + /// + /// @param[in] request_id The request ID + /// @param[in] error The provider-defined error message + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_provider_send_error( + int request_id, + ffi.Pointer error, + ) { + return _data_control_provider_send_error( + request_id, + error, + ); + } + + late final _data_control_provider_send_error_ptr = + _lookup>( + 'data_control_provider_send_error'); + late final _dart_data_control_provider_send_error + _data_control_provider_send_error = _data_control_provider_send_error_ptr + .asFunction<_dart_data_control_provider_send_error>(); + + /// @brief Sends the success result of the request for setting, adding, and removing the key-value structured data to the client application. + /// @since_tizen 2.3 + /// + /// @param[in] request_id The request ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_provider_send_map_result( + int request_id, + ) { + return _data_control_provider_send_map_result( + request_id, + ); + } + + late final _data_control_provider_send_map_result_ptr = + _lookup>( + 'data_control_provider_send_map_result'); + late final _dart_data_control_provider_send_map_result + _data_control_provider_send_map_result = + _data_control_provider_send_map_result_ptr + .asFunction<_dart_data_control_provider_send_map_result>(); + + /// @brief Sends the success result of the request for getting the value list to the client application. + /// @since_tizen 2.3 + /// + /// @param[in] request_id The request ID + /// @param[in] value_list The result value list + /// @param[in] value_count The number of the values + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_provider_send_map_get_value_result( + int request_id, + ffi.Pointer> value_list, + int value_count, + ) { + return _data_control_provider_send_map_get_value_result( + request_id, + value_list, + value_count, + ); + } + + late final _data_control_provider_send_map_get_value_result_ptr = _lookup< + ffi.NativeFunction< + _c_data_control_provider_send_map_get_value_result>>( + 'data_control_provider_send_map_get_value_result'); + late final _dart_data_control_provider_send_map_get_value_result + _data_control_provider_send_map_get_value_result = + _data_control_provider_send_map_get_value_result_ptr + .asFunction<_dart_data_control_provider_send_map_get_value_result>(); + + /// @brief Creates SQL INSERT statement. + /// + /// @since_tizen 2.3 + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] provider The provider handle + /// @param[in] insert_map The column-value pairs to insert + /// + /// @return The SQL INSERT statement on success, + /// otherwise NULL + /// @exception DATA_CONTROL_ERROR_NONE Success + /// @exception DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @exception DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + ffi.Pointer data_control_provider_create_insert_statement( + ffi.Pointer provider, + ffi.Pointer insert_map, + ) { + return _data_control_provider_create_insert_statement( + provider, + insert_map, + ); + } + + late final _data_control_provider_create_insert_statement_ptr = _lookup< + ffi.NativeFunction<_c_data_control_provider_create_insert_statement>>( + 'data_control_provider_create_insert_statement'); + late final _dart_data_control_provider_create_insert_statement + _data_control_provider_create_insert_statement = + _data_control_provider_create_insert_statement_ptr + .asFunction<_dart_data_control_provider_create_insert_statement>(); + + /// @brief Creates SQL DELETE statement. + /// + /// @since_tizen 2.3 + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] provider The provider handle + /// @param[in] where A filter to select the desired rows to delete \n + /// Pass @c NULL if all rows need to be deleted + /// + /// @return The SQL DELETE statement on success, + /// otherwise NULL + /// @exception DATA_CONTROL_ERROR_NONE Success + /// @exception DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @exception DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + ffi.Pointer data_control_provider_create_delete_statement( + ffi.Pointer provider, + ffi.Pointer where, + ) { + return _data_control_provider_create_delete_statement( + provider, + where, + ); + } + + late final _data_control_provider_create_delete_statement_ptr = _lookup< + ffi.NativeFunction<_c_data_control_provider_create_delete_statement>>( + 'data_control_provider_create_delete_statement'); + late final _dart_data_control_provider_create_delete_statement + _data_control_provider_create_delete_statement = + _data_control_provider_create_delete_statement_ptr + .asFunction<_dart_data_control_provider_create_delete_statement>(); + + /// @brief Creates SQL UPDATE statement. + /// + /// @since_tizen 2.3 + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] provider The provider handle + /// @param[in] update_map The column-value pairs to update + /// @param[in] where A filter to select the desired rows to update + /// + /// @return The SQL UPDATE statement on success, + /// otherwise NULL + /// @exception DATA_CONTROL_ERROR_NONE Success + /// @exception DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @exception DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + ffi.Pointer data_control_provider_create_update_statement( + ffi.Pointer provider, + ffi.Pointer update_map, + ffi.Pointer where, + ) { + return _data_control_provider_create_update_statement( + provider, + update_map, + where, + ); + } + + late final _data_control_provider_create_update_statement_ptr = _lookup< + ffi.NativeFunction<_c_data_control_provider_create_update_statement>>( + 'data_control_provider_create_update_statement'); + late final _dart_data_control_provider_create_update_statement + _data_control_provider_create_update_statement = + _data_control_provider_create_update_statement_ptr + .asFunction<_dart_data_control_provider_create_update_statement>(); + + /// @brief Creates SQL SELECT statement. + /// + /// @since_tizen 2.3 + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] provider The provider handle + /// @param[in] column_list The column names to query \n + /// Pass @c NULL if all columns need to be selected + /// @param[in] column_count The total number of columns to be queried + /// @param[in] where A filter to select the desired rows + /// @param[in] order The sorting order of rows to query + /// + /// @return The SQL SELECT statement on success, + /// otherwise NULL + /// @exception DATA_CONTROL_ERROR_NONE Success + /// @exception DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @exception DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + ffi.Pointer data_control_provider_create_select_statement( + ffi.Pointer provider, + ffi.Pointer> column_list, + int column_count, + ffi.Pointer where, + ffi.Pointer order, + ) { + return _data_control_provider_create_select_statement( + provider, + column_list, + column_count, + where, + order, + ); + } + + late final _data_control_provider_create_select_statement_ptr = _lookup< + ffi.NativeFunction<_c_data_control_provider_create_select_statement>>( + 'data_control_provider_create_select_statement'); + late final _dart_data_control_provider_create_select_statement + _data_control_provider_create_select_statement = + _data_control_provider_create_select_statement_ptr + .asFunction<_dart_data_control_provider_create_select_statement>(); + + /// @brief Checks whether the given provider ID matches the provider handle's provider ID. + /// + /// @since_tizen 2.3 + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] provider The provider handle + /// @param[in] provider_id The provider ID to be compared with handle's provider ID + /// + /// @return @c true if the provider_id matches, + /// otherwise @c false if it does not match + /// @exception DATA_CONTROL_ERROR_NONE Success + /// @exception DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @exception DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + bool data_control_provider_match_provider_id( + ffi.Pointer provider, + ffi.Pointer provider_id, + ) { + return _data_control_provider_match_provider_id( + provider, + provider_id, + ) != + 0; + } + + late final _data_control_provider_match_provider_id_ptr = + _lookup>( + 'data_control_provider_match_provider_id'); + late final _dart_data_control_provider_match_provider_id + _data_control_provider_match_provider_id = + _data_control_provider_match_provider_id_ptr + .asFunction<_dart_data_control_provider_match_provider_id>(); + + /// @brief Checks whether the given data ID matches the provider handle's data ID. + /// + /// @since_tizen 2.3 + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] provider The provider handle + /// @param[in] data_id The data ID to be compared with handle's data ID + /// + /// @return @c true if the @a data_id matches, + /// otherwise @c false if it does not match + /// @exception DATA_CONTROL_ERROR_NONE Success + /// @exception DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @exception DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + bool data_control_provider_match_data_id( + ffi.Pointer provider, + ffi.Pointer data_id, + ) { + return _data_control_provider_match_data_id( + provider, + data_id, + ) != + 0; + } + + late final _data_control_provider_match_data_id_ptr = + _lookup>( + 'data_control_provider_match_data_id'); + late final _dart_data_control_provider_match_data_id + _data_control_provider_match_data_id = + _data_control_provider_match_data_id_ptr + .asFunction<_dart_data_control_provider_match_data_id>(); + + /// @brief Sends a data change notification to consumer applications which have successfully added a data change callback. + /// @details If the function is successful, data_control_data_change_cb() callback will be called under certain conditions. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing + /// + /// @param[in] provider Target provider handle + /// @param[in] type Changed data type + /// @param[in] data Customized information about changed data + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre The consumer should call data_control_add_data_change_cb() to receive data change notifications + /// @see data_control_data_change_cb() + /// @see data_control_add_data_change_cb() + int data_control_provider_send_data_change_noti( + ffi.Pointer provider, + int type, + ffi.Pointer data, + ) { + return _data_control_provider_send_data_change_noti( + provider, + type, + data, + ); + } + + late final _data_control_provider_send_data_change_noti_ptr = _lookup< + ffi.NativeFunction<_c_data_control_provider_send_data_change_noti>>( + 'data_control_provider_send_data_change_noti'); + late final _dart_data_control_provider_send_data_change_noti + _data_control_provider_send_data_change_noti = + _data_control_provider_send_data_change_noti_ptr + .asFunction<_dart_data_control_provider_send_data_change_noti>(); + + /// @brief Adds a consumer filter for the data changed callback addition process. + /// @since_tizen 3.0 + /// @remarks If the provider does not add any filters by calling this function, all requests to add a data change callback will be granted. \n + /// If filters are added, and at least one filter returns false for a consumer application, the application will not be able to add data change callbacks. + /// + /// @param[in] callback Consumer filter callback, filtering consumers which try to add data changed callback + /// @param[in] user_data The user data to be passed to the list_cb function + /// @param[out] callback_id Added callback ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @see data_control_provider_data_change_consumer_filter_cb() + int data_control_provider_add_data_change_consumer_filter_cb( + ffi.Pointer< + ffi.NativeFunction< + data_control_provider_data_change_consumer_filter_cb>> + callback, + ffi.Pointer user_data, + ffi.Pointer callback_id, + ) { + return _data_control_provider_add_data_change_consumer_filter_cb( + callback, + user_data, + callback_id, + ); + } + + late final _data_control_provider_add_data_change_consumer_filter_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_data_control_provider_add_data_change_consumer_filter_cb>>( + 'data_control_provider_add_data_change_consumer_filter_cb'); + late final _dart_data_control_provider_add_data_change_consumer_filter_cb + _data_control_provider_add_data_change_consumer_filter_cb = + _data_control_provider_add_data_change_consumer_filter_cb_ptr.asFunction< + _dart_data_control_provider_add_data_change_consumer_filter_cb>(); + + /// @brief Removes a consumer filter for the data changed callback addition process. + /// @since_tizen 3.0 + /// + /// @param[in] callback_id Target callback ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_provider_remove_data_change_consumer_filter_cb( + int callback_id, + ) { + return _data_control_provider_remove_data_change_consumer_filter_cb( + callback_id, + ); + } + + late final _data_control_provider_remove_data_change_consumer_filter_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_data_control_provider_remove_data_change_consumer_filter_cb>>( + 'data_control_provider_remove_data_change_consumer_filter_cb'); + late final _dart_data_control_provider_remove_data_change_consumer_filter_cb + _data_control_provider_remove_data_change_consumer_filter_cb = + _data_control_provider_remove_data_change_consumer_filter_cb_ptr.asFunction< + _dart_data_control_provider_remove_data_change_consumer_filter_cb>(); + + /// @brief Retrieves ids of all applications which receive data change notifications from a given provider. + /// @details This function calls data_control_provider_data_change_consumer_cb() once for each provider's notification target consumer id. \n + /// If the data_control_provider_data_change_consumer_cb() callback function returns @c false, then iteration will be finished. + /// @since_tizen 3.0 + /// + /// @param[in] provider Target provider handle + /// @param[in] list_cb The iteration callback function + /// @param[in] user_data The user data to be passed to the list_cb function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @post This function invokes data_control_provider_data_change_consumer_cb(). + /// @see data_control_provider_data_change_consumer_cb() + int data_control_provider_foreach_data_change_consumer( + ffi.Pointer provider, + ffi.Pointer< + ffi.NativeFunction> + list_cb, + ffi.Pointer user_data, + ) { + return _data_control_provider_foreach_data_change_consumer( + provider, + list_cb, + user_data, + ); + } + + late final _data_control_provider_foreach_data_change_consumer_ptr = _lookup< + ffi.NativeFunction< + _c_data_control_provider_foreach_data_change_consumer>>( + 'data_control_provider_foreach_data_change_consumer'); + late final _dart_data_control_provider_foreach_data_change_consumer + _data_control_provider_foreach_data_change_consumer = + _data_control_provider_foreach_data_change_consumer_ptr.asFunction< + _dart_data_control_provider_foreach_data_change_consumer>(); + + /// @brief Sends the result of the bulk insert request to the client application. + /// @since_tizen 3.0 + /// + /// @param[in] request_id The request ID + /// @param[in] bulk_results The bulk add result for each data + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_provider_send_bulk_insert_result( + int request_id, + ffi.Pointer bulk_results, + ) { + return _data_control_provider_send_bulk_insert_result( + request_id, + bulk_results, + ); + } + + late final _data_control_provider_send_bulk_insert_result_ptr = _lookup< + ffi.NativeFunction<_c_data_control_provider_send_bulk_insert_result>>( + 'data_control_provider_send_bulk_insert_result'); + late final _dart_data_control_provider_send_bulk_insert_result + _data_control_provider_send_bulk_insert_result = + _data_control_provider_send_bulk_insert_result_ptr + .asFunction<_dart_data_control_provider_send_bulk_insert_result>(); + + /// @brief Sends the result of the bulk add request to the client application. + /// @since_tizen 3.0 + /// + /// @param[in] request_id The request ID + /// @param[in] bulk_results The bulk add result for each data + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + int data_control_provider_send_map_bulk_add_result( + int request_id, + ffi.Pointer bulk_results, + ) { + return _data_control_provider_send_map_bulk_add_result( + request_id, + bulk_results, + ); + } + + late final _data_control_provider_send_map_bulk_add_result_ptr = _lookup< + ffi.NativeFunction< + _c_data_control_provider_send_map_bulk_add_result>>( + 'data_control_provider_send_map_bulk_add_result'); + late final _dart_data_control_provider_send_map_bulk_add_result + _data_control_provider_send_map_bulk_add_result = + _data_control_provider_send_map_bulk_add_result_ptr + .asFunction<_dart_data_control_provider_send_map_bulk_add_result>(); + + /// @brief Registers a callback for the SQL bulk data request. + /// @details The provider is notified when a data control request is received from the client applications. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing + /// + /// @param[in] callback The callback function to be called when a data control request is received + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + int data_control_provider_sql_register_insert_bulk_data_request_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _data_control_provider_sql_register_insert_bulk_data_request_cb( + callback, + user_data, + ); + } + + late final _data_control_provider_sql_register_insert_bulk_data_request_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_data_control_provider_sql_register_insert_bulk_data_request_cb>>( + 'data_control_provider_sql_register_insert_bulk_data_request_cb'); + late final _dart_data_control_provider_sql_register_insert_bulk_data_request_cb + _data_control_provider_sql_register_insert_bulk_data_request_cb = + _data_control_provider_sql_register_insert_bulk_data_request_cb_ptr + .asFunction< + _dart_data_control_provider_sql_register_insert_bulk_data_request_cb>(); + + /// @brief Unregisters the callback for the SQL bulk data request. + /// @since_tizen 3.0 + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @see data_control_provider_sql_register_insert_bulk_data_request_cb() + int data_control_provider_sql_unregister_insert_bulk_data_request_cb() { + return _data_control_provider_sql_unregister_insert_bulk_data_request_cb(); + } + + late final _data_control_provider_sql_unregister_insert_bulk_data_request_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_data_control_provider_sql_unregister_insert_bulk_data_request_cb>>( + 'data_control_provider_sql_unregister_insert_bulk_data_request_cb'); + late final _dart_data_control_provider_sql_unregister_insert_bulk_data_request_cb + _data_control_provider_sql_unregister_insert_bulk_data_request_cb = + _data_control_provider_sql_unregister_insert_bulk_data_request_cb_ptr + .asFunction< + _dart_data_control_provider_sql_unregister_insert_bulk_data_request_cb>(); + + /// @brief Registers a callback for the MAP bulk data request. + /// @details The provider is notified when a data control request is received from the client applications. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing + /// + /// @param[in] callback The callback function to be called when a data control request is received + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + int data_control_provider_map_register_add_bulk_data_request_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _data_control_provider_map_register_add_bulk_data_request_cb( + callback, + user_data, + ); + } + + late final _data_control_provider_map_register_add_bulk_data_request_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_data_control_provider_map_register_add_bulk_data_request_cb>>( + 'data_control_provider_map_register_add_bulk_data_request_cb'); + late final _dart_data_control_provider_map_register_add_bulk_data_request_cb + _data_control_provider_map_register_add_bulk_data_request_cb = + _data_control_provider_map_register_add_bulk_data_request_cb_ptr.asFunction< + _dart_data_control_provider_map_register_add_bulk_data_request_cb>(); + + /// @brief Unregisters the callback for the MAP bulk data request. + /// @since_tizen 3.0 + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @see data_control_provider_map_register_add_bulk_data_request_cb() + int data_control_provider_map_unregister_add_bulk_data_request_cb() { + return _data_control_provider_map_unregister_add_bulk_data_request_cb(); + } + + late final _data_control_provider_map_unregister_add_bulk_data_request_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_data_control_provider_map_unregister_add_bulk_data_request_cb>>( + 'data_control_provider_map_unregister_add_bulk_data_request_cb'); + late final _dart_data_control_provider_map_unregister_add_bulk_data_request_cb + _data_control_provider_map_unregister_add_bulk_data_request_cb = + _data_control_provider_map_unregister_add_bulk_data_request_cb_ptr.asFunction< + _dart_data_control_provider_map_unregister_add_bulk_data_request_cb>(); + + /// @brief Asynchronously adds a data changed callback, which is called whenever the provider's data is changed. + /// @details The function attempts to add the callback asynchronously and calls result_callback to inform about the result of the attempt. \n + /// If the function is successful, result_callback will be called. \n + /// The provider will call any filters which were added for the callback addition process. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing \n + /// %http://tizen.org/privilege/appmanager.launch + /// @remarks If you want to use this function, you must add privileges. + /// @param[in] provider Target provider handle + /// @param[in] callback The callback function to be called when consumer receives data change notification + /// @param[in] user_data The user data to be passed to the callback function + /// @param[in] result_callback The callback function to be called when consumer receives add data change callback process result + /// @param[in] result_cb_user_data The user data to be passed to the result_callback function + /// @param[out] callback_id Added callback ID, it can be used to remove the callback + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + /// @see data_control_data_change_cb() + /// @see data_control_add_callback_result_cb() + /// @see data_control_provider_add_data_change_consumer_filter_cb() + int data_control_add_data_change_cb( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer> + result_callback, + ffi.Pointer result_cb_user_data, + ffi.Pointer callback_id, + ) { + return _data_control_add_data_change_cb( + provider, + callback, + user_data, + result_callback, + result_cb_user_data, + callback_id, + ); + } + + late final _data_control_add_data_change_cb_ptr = + _lookup>( + 'data_control_add_data_change_cb'); + late final _dart_data_control_add_data_change_cb + _data_control_add_data_change_cb = _data_control_add_data_change_cb_ptr + .asFunction<_dart_data_control_add_data_change_cb>(); + + /// @brief Removes data change callback function. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/datasharing \n + /// %http://tizen.org/privilege/appmanager.launch + /// @remarks If you want to use this function, you must add privileges. + /// @param[in] provider Target provider handle + /// @param[in] callback_id Target callback ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DATA_CONTROL_ERROR_NONE Successful + /// @retval #DATA_CONTROL_ERROR_IO_ERROR I/O error + /// @retval #DATA_CONTROL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DATA_CONTROL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DATA_CONTROL_ERROR_PERMISSION_DENIED Permission denied + int data_control_remove_data_change_cb( + ffi.Pointer provider, + int callback_id, + ) { + return _data_control_remove_data_change_cb( + provider, + callback_id, + ); + } + + late final _data_control_remove_data_change_cb_ptr = + _lookup>( + 'data_control_remove_data_change_cb'); + late final _dart_data_control_remove_data_change_cb + _data_control_remove_data_change_cb = + _data_control_remove_data_change_cb_ptr + .asFunction<_dart_data_control_remove_data_change_cb>(); + + /// @brief Registers the local message port. + /// @details If the message port name is already registered, the previous local message port ID returns and the callback function is changed. \n + /// Multiple message ports can be registered. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specified callback is called only in the main thread. + /// @param[in] local_port The name of the local message port + /// @param[in] callback The callback function to be called when a message is received + /// @param[in] user_data The user data to be passed to the callback function + /// @return A local message port ID on success, + /// otherwise a negative error value + /// @retval #MESSAGE_PORT_ERROR_INVALID_PARAMETER The specified @a local_port or @a callback is NULL + /// @retval #MESSAGE_PORT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval MESSAGE_PORT_ERROR_IO_ERROR Internal I/O error + /// @see message_port_unregister_local_port() + int message_port_register_local_port( + ffi.Pointer local_port, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _message_port_register_local_port( + local_port, + callback, + user_data, + ); + } + + late final _message_port_register_local_port_ptr = + _lookup>( + 'message_port_register_local_port'); + late final _dart_message_port_register_local_port + _message_port_register_local_port = _message_port_register_local_port_ptr + .asFunction<_dart_message_port_register_local_port>(); + + /// @brief Registers the trusted local message port. + /// @details If the message port name is already registered, the previous local message port ID returns and the callback function is changed. @n + /// It allows communications only if the applications are signed with the same certificate, which is uniquely assigned to the developer. @n + /// Multiple message ports can be registered. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specified callback is called only in the main thread. + /// @param[in] trusted_local_port The name of the trusted local message port + /// @param[in] callback The callback function to be called when a trusted message is received + /// @param[in] user_data The user data to be passed to the callback function + /// @return A trusted local message port ID on success, + /// otherwise a negative error value + /// @retval #MESSAGE_PORT_ERROR_INVALID_PARAMETER The specified @a trusted_local_port or @a callback is NULL + /// @retval #MESSAGE_PORT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGE_PORT_ERROR_IO_ERROR Internal I/O error + /// @see message_port_unregister_trusted_local_port() + int message_port_register_trusted_local_port( + ffi.Pointer trusted_local_port, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _message_port_register_trusted_local_port( + trusted_local_port, + callback, + user_data, + ); + } + + late final _message_port_register_trusted_local_port_ptr = + _lookup>( + 'message_port_register_trusted_local_port'); + late final _dart_message_port_register_trusted_local_port + _message_port_register_trusted_local_port = + _message_port_register_trusted_local_port_ptr + .asFunction<_dart_message_port_register_trusted_local_port>(); + + /// @brief Unregisters the local message port. + /// @details This method unregisters the callback function with the specified local port ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] local_port_id The local message port ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGE_PORT_ERROR_NONE Successful + /// @retval #MESSAGE_PORT_ERROR_INVALID_PARAMETER The specified @a local_port_id is not positive + /// @retval #MESSAGE_PORT_ERROR_PORT_NOT_FOUND The specified @a local_port_id cannot be found + /// @retval #MESSAGE_PORT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGE_PORT_ERROR_IO_ERROR Internal I/O error + /// @see message_port_register_local_port() + int message_port_unregister_local_port( + int local_port_id, + ) { + return _message_port_unregister_local_port( + local_port_id, + ); + } + + late final _message_port_unregister_local_port_ptr = + _lookup>( + 'message_port_unregister_local_port'); + late final _dart_message_port_unregister_local_port + _message_port_unregister_local_port = + _message_port_unregister_local_port_ptr + .asFunction<_dart_message_port_unregister_local_port>(); + + /// @brief Registers the trusted local message port. + /// @details This method unregisters the callback function with the specified local port ID. @n + /// It allows communications only if the applications are signed with the same certificate, which is uniquely assigned to the developer. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] trusted_local_port_id The trusted local message port ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGE_PORT_ERROR_NONE Successful + /// @retval #MESSAGE_PORT_ERROR_INVALID_PARAMETER The specified @a trusted_local_port_id is not positive + /// @retval #MESSAGE_PORT_ERROR_PORT_NOT_FOUND The specified @a trusted_local_port_id cannot be found + /// @retval #MESSAGE_PORT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGE_PORT_ERROR_IO_ERROR Internal I/O error + /// @see message_port_register_trusted_local_port() + int message_port_unregister_trusted_local_port( + int trusted_local_port_id, + ) { + return _message_port_unregister_trusted_local_port( + trusted_local_port_id, + ); + } + + late final _message_port_unregister_trusted_local_port_ptr = _lookup< + ffi.NativeFunction<_c_message_port_unregister_trusted_local_port>>( + 'message_port_unregister_trusted_local_port'); + late final _dart_message_port_unregister_trusted_local_port + _message_port_unregister_trusted_local_port = + _message_port_unregister_trusted_local_port_ptr + .asFunction<_dart_message_port_unregister_trusted_local_port>(); + + /// @brief Checks whether the message port of a remote application is registered. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If this function returns a negative error value, the out parameter @a exist will not be changed. + /// @param[in] remote_app_id The ID of the remote application + /// @param[in] remote_port The name of the remote message port + /// @param[out] exist If @c true, the message port of the remote application exists; + /// otherwise @c false + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGE_PORT_ERROR_NONE Successful + /// @retval #MESSAGE_PORT_ERROR_INVALID_PARAMETER The specified @a remote_app_id or @a remote_port is NULL + /// @retval #MESSAGE_PORT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGE_PORT_ERROR_IO_ERROR Internal I/O error + int message_port_check_remote_port( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer exist, + ) { + return _message_port_check_remote_port( + remote_app_id, + remote_port, + exist, + ); + } + + late final _message_port_check_remote_port_ptr = + _lookup>( + 'message_port_check_remote_port'); + late final _dart_message_port_check_remote_port + _message_port_check_remote_port = _message_port_check_remote_port_ptr + .asFunction<_dart_message_port_check_remote_port>(); + + /// @brief Checks whether the trusted message port of a remote application is registered. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If this function returns a negative error value, the out parameter @a exist will not be changed. + /// @param[in] remote_app_id The ID of the remote application + /// @param[in] remote_port The name of the remote message port + /// @param[out] exist If @c true, the message port of the remote application exists; + /// otherwise @c false + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGE_PORT_ERROR_NONE Successful + /// @retval #MESSAGE_PORT_ERROR_INVALID_PARAMETER The specified @a remote_app_id or @a remote_port is @c NULL + /// @retval #MESSAGE_PORT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGE_PORT_ERROR_CERTIFICATE_NOT_MATCH The remote application is not signed with the same certificate + /// @retval #MESSAGE_PORT_ERROR_IO_ERROR Internal I/O error + int message_port_check_trusted_remote_port( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer exist, + ) { + return _message_port_check_trusted_remote_port( + remote_app_id, + remote_port, + exist, + ); + } + + late final _message_port_check_trusted_remote_port_ptr = + _lookup>( + 'message_port_check_trusted_remote_port'); + late final _dart_message_port_check_trusted_remote_port + _message_port_check_trusted_remote_port = + _message_port_check_trusted_remote_port_ptr + .asFunction<_dart_message_port_check_trusted_remote_port>(); + + /// @brief Sends a message to the message port of a remote application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks @a message must be released with bundle_free() after sending the message. + /// @param[in] remote_app_id The ID of the remote application + /// @param[in] remote_port The name of the remote message port + /// @param[in] message The message to be passed to the remote application, the recommended message size is under 4KB + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGE_PORT_ERROR_NONE Successful + /// @retval #MESSAGE_PORT_ERROR_INVALID_PARAMETER The specified @a remote_app_id, @a remote_port or @a message is NULL + /// @retval #MESSAGE_PORT_ERROR_PORT_NOT_FOUND The message port of the remote application cannot be found + /// @retval #MESSAGE_PORT_ERROR_MAX_EXCEEDED The size of message has exceeded the maximum limit + /// @retval #MESSAGE_PORT_ERROR_RESOURCE_UNAVAILABLE Resource temporarily unavailable + /// @retval #MESSAGE_PORT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGE_PORT_ERROR_IO_ERROR Internal I/O error + /// @post It invokes message_port_message_cb() on the remote application. + /// @see message_port_message_cb() + /// @see message_port_register_local_port() + /// @see message_port_unregister_local_port() + /// + /// @code + /// #include + /// bundle *b = bundle_create(); + /// bundle_add(b, "key1", "value1"); + /// bundle_add(b, "key2", "value2"); + /// int ret = message_port_send_message("0123456789.BasicApp", "BasicAppPort", b); + /// bundle_free(b); + /// @endcode + int message_port_send_message( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer message, + ) { + return _message_port_send_message( + remote_app_id, + remote_port, + message, + ); + } + + late final _message_port_send_message_ptr = + _lookup>( + 'message_port_send_message'); + late final _dart_message_port_send_message _message_port_send_message = + _message_port_send_message_ptr + .asFunction<_dart_message_port_send_message>(); + + /// @brief Sends a trusted message to the message port of a remote application. + /// @details This method allows communication only if the applications are signed with the same certificate, which is uniquely assigned to the developer. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a message using bundle_free() after sending the message. + /// @param[in] remote_app_id The ID of the remote application + /// @param[in] remote_port The name of the remote message port + /// @param[in] message The message to be passed to the remote application, the recommended message size is under 4KB + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGE_PORT_ERROR_NONE Successful + /// @retval #MESSAGE_PORT_ERROR_INVALID_PARAMETER The specified @a remote_app_id, @a remote_port or @a message is @c NULL + /// @retval #MESSAGE_PORT_ERROR_PORT_NOT_FOUND The message port of the remote application cannot be found + /// @retval #MESSAGE_PORT_ERROR_CERTIFICATE_NOT_MATCH The remote application is not signed with the same certificate + /// @retval #MESSAGE_PORT_ERROR_MAX_EXCEEDED The size of the message has exceeded the maximum limit + /// @retval #MESSAGE_PORT_ERROR_RESOURCE_UNAVAILABLE Resource is temporarily unavailable + /// @retval #MESSAGE_PORT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGE_PORT_ERROR_IO_ERROR Internal I/O error + /// @post It invokes message_port_trusted_message_cb() on the remote application. + /// @see message_port_trusted_message_cb() + /// @see message_port_register_trusted_local_port() + /// @see message_port_unregister_trusted_local_port() + int message_port_send_trusted_message( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer message, + ) { + return _message_port_send_trusted_message( + remote_app_id, + remote_port, + message, + ); + } + + late final _message_port_send_trusted_message_ptr = + _lookup>( + 'message_port_send_trusted_message'); + late final _dart_message_port_send_trusted_message + _message_port_send_trusted_message = + _message_port_send_trusted_message_ptr + .asFunction<_dart_message_port_send_trusted_message>(); + + /// @brief Sends a message with local port information to the message port of a remote application. + /// @details This method is used for bidirectional communication. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a message using bundle_free() after sending the message. + /// @param[in] remote_app_id The ID of the remote application + /// @param[in] remote_port The name of the remote message port + /// @param[in] message The message to be passed to the remote application, the recommended message size is under 4KB + /// @param[in] local_port_id The message port ID returned by message_port_register_local_port() or message_port_register_trusted_local_port() + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGE_PORT_ERROR_NONE Successful + /// @retval #MESSAGE_PORT_ERROR_INVALID_PARAMETER The specified @a remote_app_id, @a remote_port or @a message is @c NULL and + /// The specified @a local_port_id is not positive + /// @retval #MESSAGE_PORT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGE_PORT_ERROR_PORT_NOT_FOUND The port of the local or remote application cannot be found + /// @retval #MESSAGE_PORT_ERROR_MAX_EXCEEDED The size of the message has exceeded the maximum limit + /// @retval #MESSAGE_PORT_ERROR_IO_ERROR Internal I/O error + /// @post It invokes message_port_message_cb() on the remote application. + /// @see message_port_message_cb() + /// @see message_port_register_local_port() + /// @see message_port_unregister_local_port() + /// + /// @code + /// #include + /// + /// static void message_port_receive_cb(int local_port_id, const char *remote_app_id, const char *remote_port, bundle *message) {} + /// + /// int + /// main(int argc, char *argv[]) + /// { + /// bundle *b = bundle_create(); + /// bundle_add(b, "key1", "value1"); + /// bundle_add(b, "key2", "value2"); + /// + /// int local_port_id = message_port_register_local_port("HelloPort", message_port_receive_cb); + /// + /// int ret = message_port_send_message_with_local_port("0123456789.BasicApp", "BasicAppPort", b, local_port_id); + /// + /// bundle_free(b); + /// } + /// @endcode + int message_port_send_message_with_local_port( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer message, + int local_port_id, + ) { + return _message_port_send_message_with_local_port( + remote_app_id, + remote_port, + message, + local_port_id, + ); + } + + late final _message_port_send_message_with_local_port_ptr = + _lookup>( + 'message_port_send_message_with_local_port'); + late final _dart_message_port_send_message_with_local_port + _message_port_send_message_with_local_port = + _message_port_send_message_with_local_port_ptr + .asFunction<_dart_message_port_send_message_with_local_port>(); + + /// @brief Sends a trusted message with local port information to the message port of a remote application. + /// @details This method is used for bidirectional communication. @n + /// It allows communications only if the applications are signed with the same certificate, which is uniquely assigned to the developer. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You muse release @a message using bundle_free() after sending the message. + /// @param[in] remote_app_id The ID of the remote application + /// @param[in] remote_port The name of the remote message port + /// @param[in] message The message to be passed to the remote application, the recommended message size is under 4KB + /// @param[in] local_port_id The message port ID returned by message_port_register_local_port() or message_port_register_trusted_local_port() + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGE_PORT_ERROR_NONE Successful + /// @retval #MESSAGE_PORT_ERROR_INVALID_PARAMETER The specified @a remote_app_id, @a remote_port or @a message is @c NULL and + /// specified @a local_port_id is not positive + /// @retval #MESSAGE_PORT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGE_PORT_ERROR_PORT_NOT_FOUND The port of the local or remote application cannot be found + /// @retval #MESSAGE_PORT_ERROR_CERTIFICATE_NOT_MATCH The remote application is not signed with the same certificate + /// @retval #MESSAGE_PORT_ERROR_MAX_EXCEEDED The size of the message has exceeded the maximum limit + /// @retval #MESSAGE_PORT_ERROR_IO_ERROR Internal I/O error + /// @post It invokes message_port_trusted_message_cb() on the remote application. + /// @see message_port_trusted_message_cb() + /// @see message_port_register_trusted_local_port() + /// @see message_port_unregister_trusted_local_port() + int message_port_send_trusted_message_with_local_port( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer message, + int local_port_id, + ) { + return _message_port_send_trusted_message_with_local_port( + remote_app_id, + remote_port, + message, + local_port_id, + ); + } + + late final _message_port_send_trusted_message_with_local_port_ptr = _lookup< + ffi.NativeFunction< + _c_message_port_send_trusted_message_with_local_port>>( + 'message_port_send_trusted_message_with_local_port'); + late final _dart_message_port_send_trusted_message_with_local_port + _message_port_send_trusted_message_with_local_port = + _message_port_send_trusted_message_with_local_port_ptr.asFunction< + _dart_message_port_send_trusted_message_with_local_port>(); + + /// @brief Adds a callback called when a remote port is registered. + /// @details When remote port is registered, @a registered_cb function is called. + /// Each added callback has its own separate watcher. + /// @since_tizen 4.0 + /// @remarks The specified callback is called only in the main thread. + /// @param[in] remote_app_id The ID of the remote application + /// @param[in] remote_port The name of the remote message port + /// @param[in] trusted_remote_port Indicates whether remote port is trusted + /// @param[in] registered_cb The callback function to be called + /// when remote port is registered + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] watcher_id The ID of the watcher which is monitoring the remote port + /// registration events + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGE_PORT_ERROR_INVALID_PARAMETER The specified @a remote_app_id or @a remote_port + /// or @a registered_cb is NULL + /// @retval #MESSAGE_PORT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGE_PORT_ERROR_IO_ERROR Internal I/O error + /// @see message_port_registration_event_cb() + /// @see message_port_add_unregistered_cb() + /// @see message_port_remove_registration_event_cb() + int message_port_add_registered_cb( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + bool trusted_remote_port, + ffi.Pointer> + registered_cb, + ffi.Pointer user_data, + ffi.Pointer watcher_id, + ) { + return _message_port_add_registered_cb( + remote_app_id, + remote_port, + trusted_remote_port ? 1 : 0, + registered_cb, + user_data, + watcher_id, + ); + } + + late final _message_port_add_registered_cb_ptr = + _lookup>( + 'message_port_add_registered_cb'); + late final _dart_message_port_add_registered_cb + _message_port_add_registered_cb = _message_port_add_registered_cb_ptr + .asFunction<_dart_message_port_add_registered_cb>(); + + /// @brief Adds a callback called when a remote port is unregistered. + /// @details When the remote port is unregistered, @a unregistered_cb function is called. + /// Each added callback has its own separate watcher. + /// @remarks The specified callback is called only in the main thread. + /// @since_tizen 4.0 + /// @param[in] remote_app_id The ID of the remote application + /// @param[in] remote_port The name of the remote message port + /// @param[in] trusted_remote_port Indicates whether remote port is trusted + /// @param[in] unregistered_cb The callback function to be called + /// when remote port is unregistered + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] watcher_id The ID of the watcher which is monitoring the remote port + /// unregistration events + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGE_PORT_ERROR_INVALID_PARAMETER The specified @a remote_app_id or @a remote_port + /// or @a unregistered_cb is NULL + /// @retval #MESSAGE_PORT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGE_PORT_ERROR_IO_ERROR Internal I/O error + /// @see message_port_registration_event_cb() + /// @see message_port_add_registered_cb() + /// @see message_port_remove_registration_event_cb() + int message_port_add_unregistered_cb( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + bool trusted_remote_port, + ffi.Pointer> + unregistered_cb, + ffi.Pointer user_data, + ffi.Pointer watcher_id, + ) { + return _message_port_add_unregistered_cb( + remote_app_id, + remote_port, + trusted_remote_port ? 1 : 0, + unregistered_cb, + user_data, + watcher_id, + ); + } + + late final _message_port_add_unregistered_cb_ptr = + _lookup>( + 'message_port_add_unregistered_cb'); + late final _dart_message_port_add_unregistered_cb + _message_port_add_unregistered_cb = _message_port_add_unregistered_cb_ptr + .asFunction<_dart_message_port_add_unregistered_cb>(); + + /// @brief Removes the registration/unregistration callback associated with the given watcher. + /// @since_tizen 4.0 + /// @param[in] watcher_id The ID of watcher which is monitoring remote port + /// registration/unregistration events + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGE_PORT_ERROR_INVALID_PARAMETER The specified @a watcher_id is not correct + /// @retval #MESSAGE_PORT_ERROR_IO_ERROR Internal I/O error + /// @see message_port_registration_event_cb() + /// @see message_port_add_registered_cb() + /// @see message_port_add_unregistered_cb() + int message_port_remove_registration_event_cb( + int watcher_id, + ) { + return _message_port_remove_registration_event_cb( + watcher_id, + ); + } + + late final _message_port_remove_registration_event_cb_ptr = + _lookup>( + 'message_port_remove_registration_event_cb'); + late final _dart_message_port_remove_registration_event_cb + _message_port_remove_registration_event_cb = + _message_port_remove_registration_event_cb_ptr + .asFunction<_dart_message_port_remove_registration_event_cb>(); + + /// @brief Retrieves all application IDs of each package. + /// @since_tizen 2.3 + /// @param[in] package_info The package info handle + /// @param[in] comp_type The application component type + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_NO_SUCH_PACKAGE No such package + /// @post This function invokes package_info_app_cb() repeatedly for each package. + /// @see package_info_app_cb() + int package_info_foreach_app_from_package( + ffi.Pointer package_info, + int comp_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _package_info_foreach_app_from_package( + package_info, + comp_type, + callback, + user_data, + ); + } + + late final _package_info_foreach_app_from_package_ptr = + _lookup>( + 'package_info_foreach_app_from_package'); + late final _dart_package_info_foreach_app_from_package + _package_info_foreach_app_from_package = + _package_info_foreach_app_from_package_ptr + .asFunction<_dart_package_info_foreach_app_from_package>(); + + /// @brief Destroys the package information handle and releases all its resources. + /// @since_tizen 2.3 + /// @param[in] package_info The package information handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see package_manager_foreach_package_info() + /// @see package_manager_get_package_info() + int package_info_destroy( + ffi.Pointer package_info, + ) { + return _package_info_destroy( + package_info, + ); + } + + late final _package_info_destroy_ptr = + _lookup>( + 'package_info_destroy'); + late final _dart_package_info_destroy _package_info_destroy = + _package_info_destroy_ptr.asFunction<_dart_package_info_destroy>(); + + /// @brief Gets the package name. + /// @since_tizen 2.3 + /// @remarks You must release @a package using free(). + /// @param[in] package_info The package information + /// @param[out] package The package name + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int package_info_get_package( + ffi.Pointer package_info, + ffi.Pointer> package, + ) { + return _package_info_get_package( + package_info, + package, + ); + } + + late final _package_info_get_package_ptr = + _lookup>( + 'package_info_get_package'); + late final _dart_package_info_get_package _package_info_get_package = + _package_info_get_package_ptr + .asFunction<_dart_package_info_get_package>(); + + /// @brief Gets the main application ID of the package. + /// @since_tizen 4.0 + /// @remarks You must release @a main_app_id using free(). + /// @param[in] package_info The package information + /// @param[out] main_app_id The main application ID of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_info_get_main_app_id( + ffi.Pointer package_info, + ffi.Pointer> main_app_id, + ) { + return _package_info_get_main_app_id( + package_info, + main_app_id, + ); + } + + late final _package_info_get_main_app_id_ptr = + _lookup>( + 'package_info_get_main_app_id'); + late final _dart_package_info_get_main_app_id _package_info_get_main_app_id = + _package_info_get_main_app_id_ptr + .asFunction<_dart_package_info_get_main_app_id>(); + + /// @brief Gets the label of the package. + /// @since_tizen 2.3 + /// @remarks You must release @a label using free(). + /// @param[in] package_info The package information + /// @param[out] label The label of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_info_get_label( + ffi.Pointer package_info, + ffi.Pointer> label, + ) { + return _package_info_get_label( + package_info, + label, + ); + } + + late final _package_info_get_label_ptr = + _lookup>( + 'package_info_get_label'); + late final _dart_package_info_get_label _package_info_get_label = + _package_info_get_label_ptr.asFunction<_dart_package_info_get_label>(); + + /// @brief Gets the absolute path to the icon image. + /// @since_tizen 2.3 + /// @remarks You must release @a path using free(). + /// @param[in] package_info The package information + /// @param[out] path The path of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_info_get_icon( + ffi.Pointer package_info, + ffi.Pointer> path, + ) { + return _package_info_get_icon( + package_info, + path, + ); + } + + late final _package_info_get_icon_ptr = + _lookup>( + 'package_info_get_icon'); + late final _dart_package_info_get_icon _package_info_get_icon = + _package_info_get_icon_ptr.asFunction<_dart_package_info_get_icon>(); + + /// @brief Gets the version of the package. + /// @since_tizen 2.3 + /// @remarks You must release @a version using free(). + /// @param[in] package_info The package information + /// @param[out] version The version of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_info_get_version( + ffi.Pointer package_info, + ffi.Pointer> version, + ) { + return _package_info_get_version( + package_info, + version, + ); + } + + late final _package_info_get_version_ptr = + _lookup>( + 'package_info_get_version'); + late final _dart_package_info_get_version _package_info_get_version = + _package_info_get_version_ptr + .asFunction<_dart_package_info_get_version>(); + + /// @brief Gets the type of the package. + /// @since_tizen 2.3 + /// @remarks You must release @a type using free(). + /// @param[in] package_info The package information + /// @param[out] type The type of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_info_get_type( + ffi.Pointer package_info, + ffi.Pointer> type, + ) { + return _package_info_get_type( + package_info, + type, + ); + } + + late final _package_info_get_type_ptr = + _lookup>( + 'package_info_get_type'); + late final _dart_package_info_get_type _package_info_get_type = + _package_info_get_type_ptr.asFunction<_dart_package_info_get_type>(); + + /// @brief Gets the installed storage for the given package. + /// @since_tizen 2.3 + /// @param[in] package_info The package information + /// @param[out] storage The installed storage + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int package_info_get_installed_storage( + ffi.Pointer package_info, + ffi.Pointer storage, + ) { + return _package_info_get_installed_storage( + package_info, + storage, + ); + } + + late final _package_info_get_installed_storage_ptr = + _lookup>( + 'package_info_get_installed_storage'); + late final _dart_package_info_get_installed_storage + _package_info_get_installed_storage = + _package_info_get_installed_storage_ptr + .asFunction<_dart_package_info_get_installed_storage>(); + + /// @brief Gets the root path of the package. + /// @since_tizen 2.3 + /// @remarks You must release @a path using free(). + /// @param[in] package_info The package information + /// @param[out] path The root path of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_info_get_root_path( + ffi.Pointer package_info, + ffi.Pointer> path, + ) { + return _package_info_get_root_path( + package_info, + path, + ); + } + + late final _package_info_get_root_path_ptr = + _lookup>( + 'package_info_get_root_path'); + late final _dart_package_info_get_root_path _package_info_get_root_path = + _package_info_get_root_path_ptr + .asFunction<_dart_package_info_get_root_path>(); + + /// @platform + /// @brief Gets the name of the TEP(Tizen Expansion Package). + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @remarks Name must be released using free(). + /// @param[in] package_info The package information + /// @param[out] name The name of the tep + /// @return 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_SYSTEM_ERROR Severe system error + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + int package_info_get_tep_name( + ffi.Pointer package_info, + ffi.Pointer> name, + ) { + return _package_info_get_tep_name( + package_info, + name, + ); + } + + late final _package_info_get_tep_name_ptr = + _lookup>( + 'package_info_get_tep_name'); + late final _dart_package_info_get_tep_name _package_info_get_tep_name = + _package_info_get_tep_name_ptr + .asFunction<_dart_package_info_get_tep_name>(); + + /// @brief Checks whether the package is system package. + /// @since_tizen 2.3 + /// @param[in] package_info The package information + /// @param[out] system @c true if the package is system package, + /// otherwise @c false if the package is not system package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_info_is_system_package( + ffi.Pointer package_info, + ffi.Pointer system, + ) { + return _package_info_is_system_package( + package_info, + system, + ); + } + + late final _package_info_is_system_package_ptr = + _lookup>( + 'package_info_is_system_package'); + late final _dart_package_info_is_system_package + _package_info_is_system_package = _package_info_is_system_package_ptr + .asFunction<_dart_package_info_is_system_package>(); + + /// @brief Checks whether the package is removable. + /// @since_tizen 2.3 + /// @param[in] package_info The package information + /// @param[out] removable The removable info of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR IO error + int package_info_is_removable_package( + ffi.Pointer package_info, + ffi.Pointer removable, + ) { + return _package_info_is_removable_package( + package_info, + removable, + ); + } + + late final _package_info_is_removable_package_ptr = + _lookup>( + 'package_info_is_removable_package'); + late final _dart_package_info_is_removable_package + _package_info_is_removable_package = + _package_info_is_removable_package_ptr + .asFunction<_dart_package_info_is_removable_package>(); + + /// @brief Checks whether the package is preloaded. + /// @since_tizen 2.3 + /// @param[in] package_info The package information + /// @param[out] preload The preload info of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_info_is_preload_package( + ffi.Pointer package_info, + ffi.Pointer preload, + ) { + return _package_info_is_preload_package( + package_info, + preload, + ); + } + + late final _package_info_is_preload_package_ptr = + _lookup>( + 'package_info_is_preload_package'); + late final _dart_package_info_is_preload_package + _package_info_is_preload_package = _package_info_is_preload_package_ptr + .asFunction<_dart_package_info_is_preload_package>(); + + /// @brief Checks whether two package information is equal. + /// @since_tizen 2.3 + /// @param[in] lhs The first package information to be compared + /// @param[in] rhs The second package information to be compared + /// @param[out] equal @c true if the package information are equal, + /// otherwise @c false if package information are not equal + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Database error occurred + int package_info_is_equal( + ffi.Pointer lhs, + ffi.Pointer rhs, + ffi.Pointer equal, + ) { + return _package_info_is_equal( + lhs, + rhs, + equal, + ); + } + + late final _package_info_is_equal_ptr = + _lookup>( + 'package_info_is_equal'); + late final _dart_package_info_is_equal _package_info_is_equal = + _package_info_is_equal_ptr.asFunction<_dart_package_info_is_equal>(); + + /// @brief Checks whether the package info is accessible for the given package. + /// @since_tizen 2.3 + /// @param[in] package_info The package information + /// @param[out] accessible @c true if the package info is accessible, + /// otherwise @c false if the package info is not accessible + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int package_info_is_accessible( + ffi.Pointer package_info, + ffi.Pointer accessible, + ) { + return _package_info_is_accessible( + package_info, + accessible, + ); + } + + late final _package_info_is_accessible_ptr = + _lookup>( + 'package_info_is_accessible'); + late final _dart_package_info_is_accessible _package_info_is_accessible = + _package_info_is_accessible_ptr + .asFunction<_dart_package_info_is_accessible>(); + + /// @brief Gets the installed time for the given package. + /// @details If the package was updated, the @a installed_time represents updated time. + /// So, the meaning of 'installed time' corresponds with 'last modified time'. + /// @since_tizen 4.0 + /// @param[in] package_info The package information + /// @param[out] installed_time The integer value of time_t type for installed time + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Database error occurred + int package_info_get_installed_time( + ffi.Pointer package_info, + ffi.Pointer installed_time, + ) { + return _package_info_get_installed_time( + package_info, + installed_time, + ); + } + + late final _package_info_get_installed_time_ptr = + _lookup>( + 'package_info_get_installed_time'); + late final _dart_package_info_get_installed_time + _package_info_get_installed_time = _package_info_get_installed_time_ptr + .asFunction<_dart_package_info_get_installed_time>(); + + /// @brief Clones the package information handle. + /// @since_tizen 2.3 + /// @param[out] clone The newly created package information handle + /// @param[in] package_info The package information + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_NO_SUCH_PACKAGE The package is not installed + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int package_info_clone( + ffi.Pointer> clone, + ffi.Pointer package_info, + ) { + return _package_info_clone( + clone, + package_info, + ); + } + + late final _package_info_clone_ptr = + _lookup>('package_info_clone'); + late final _dart_package_info_clone _package_info_clone = + _package_info_clone_ptr.asFunction<_dart_package_info_clone>(); + + /// @brief Gets the package information for the given package + /// @since_tizen 2.3 + /// @remarks You must release @a package_info using package_info_destroy(). + /// @param[in] package The ID of the package + /// @param[out] package_info The package information for the given package ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_NO_SUCH_PACKAGE The package is not installed + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int package_info_create( + ffi.Pointer package, + ffi.Pointer> package_info, + ) { + return _package_info_create( + package, + package_info, + ); + } + + late final _package_info_create_ptr = + _lookup>( + 'package_info_create'); + late final _dart_package_info_create _package_info_create = + _package_info_create_ptr.asFunction<_dart_package_info_create>(); + + /// @brief Retrieves certification information of the package. + /// @since_tizen 2.3 + /// @param[in] package_info The package information + /// @param[in] callback The iteration callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_info_foreach_cert_info( + ffi.Pointer package_info, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _package_info_foreach_cert_info( + package_info, + callback, + user_data, + ); + } + + late final _package_info_foreach_cert_info_ptr = + _lookup>( + 'package_info_foreach_cert_info'); + late final _dart_package_info_foreach_cert_info + _package_info_foreach_cert_info = _package_info_foreach_cert_info_ptr + .asFunction<_dart_package_info_foreach_cert_info>(); + + /// @brief Retrieves privilege information of the package. + /// @since_tizen 2.3 + /// @param[in] package_info The package information + /// @param[in] callback The iteration callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_info_foreach_privilege_info( + ffi.Pointer package_info, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _package_info_foreach_privilege_info( + package_info, + callback, + user_data, + ); + } + + late final _package_info_foreach_privilege_info_ptr = + _lookup>( + 'package_info_foreach_privilege_info'); + late final _dart_package_info_foreach_privilege_info + _package_info_foreach_privilege_info = + _package_info_foreach_privilege_info_ptr + .asFunction<_dart_package_info_foreach_privilege_info>(); + + /// @brief Gets the package update information for the given package. + /// @since_tizen 4.0 + /// @remarks You must release @a info using package_info_updateinfo_destroy(). + /// @param[in] pkgid The ID of the package + /// @param[out] info The package update information for the given package ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_NO_SUCH_PACKAGE The package is not installed + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Database error occurred + /// @see package_info_updateinfo_destroy() + int package_info_updateinfo_create( + ffi.Pointer pkgid, + ffi.Pointer> info, + ) { + return _package_info_updateinfo_create( + pkgid, + info, + ); + } + + late final _package_info_updateinfo_create_ptr = + _lookup>( + 'package_info_updateinfo_create'); + late final _dart_package_info_updateinfo_create + _package_info_updateinfo_create = _package_info_updateinfo_create_ptr + .asFunction<_dart_package_info_updateinfo_create>(); + + /// @brief Gets the package name. + /// @since_tizen 4.0 + /// @remarks You must release @a package using free(). + /// @param[in] info The package update information + /// @param[out] package The package name + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Internal I/O error occurred + int package_info_updateinfo_get_pkgid( + ffi.Pointer info, + ffi.Pointer> package, + ) { + return _package_info_updateinfo_get_pkgid( + info, + package, + ); + } + + late final _package_info_updateinfo_get_pkgid_ptr = + _lookup>( + 'package_info_updateinfo_get_pkgid'); + late final _dart_package_info_updateinfo_get_pkgid + _package_info_updateinfo_get_pkgid = + _package_info_updateinfo_get_pkgid_ptr + .asFunction<_dart_package_info_updateinfo_get_pkgid>(); + + /// @brief Gets the update version of package. + /// @since_tizen 4.0 + /// @remarks You must release @a version using free(). + /// @param[in] info The package update information + /// @param[out] version The package update version + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Internal I/O error occurred + int package_info_updateinfo_get_version( + ffi.Pointer info, + ffi.Pointer> version, + ) { + return _package_info_updateinfo_get_version( + info, + version, + ); + } + + late final _package_info_updateinfo_get_version_ptr = + _lookup>( + 'package_info_updateinfo_get_version'); + late final _dart_package_info_updateinfo_get_version + _package_info_updateinfo_get_version = + _package_info_updateinfo_get_version_ptr + .asFunction<_dart_package_info_updateinfo_get_version>(); + + /// @brief Gets the update type of package. + /// @since_tizen 4.0 + /// @param[in] info The package update information + /// @param[out] type The package update type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Internal I/O error occurred + int package_info_updateinfo_get_type( + ffi.Pointer info, + ffi.Pointer type, + ) { + return _package_info_updateinfo_get_type( + info, + type, + ); + } + + late final _package_info_updateinfo_get_type_ptr = + _lookup>( + 'package_info_updateinfo_get_type'); + late final _dart_package_info_updateinfo_get_type + _package_info_updateinfo_get_type = _package_info_updateinfo_get_type_ptr + .asFunction<_dart_package_info_updateinfo_get_type>(); + + /// @brief Destroys the package update information handle and releases all its resources. + /// @since_tizen 4.0 + /// @param[in] info The package update information handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see package_info_updateinfo_create() + int package_info_updateinfo_destroy( + ffi.Pointer info, + ) { + return _package_info_updateinfo_destroy( + info, + ); + } + + late final _package_info_updateinfo_destroy_ptr = + _lookup>( + 'package_info_updateinfo_destroy'); + late final _dart_package_info_updateinfo_destroy + _package_info_updateinfo_destroy = _package_info_updateinfo_destroy_ptr + .asFunction<_dart_package_info_updateinfo_destroy>(); + + /// @brief Retrieve update information of all packages and invoke callback for each of it. + /// @since_tizen 4.0 + /// @param[in] callback The iteration callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_info_updateinfo_foreach_info( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _package_info_updateinfo_foreach_info( + callback, + user_data, + ); + } + + late final _package_info_updateinfo_foreach_info_ptr = + _lookup>( + 'package_info_updateinfo_foreach_info'); + late final _dart_package_info_updateinfo_foreach_info + _package_info_updateinfo_foreach_info = + _package_info_updateinfo_foreach_info_ptr + .asFunction<_dart_package_info_updateinfo_foreach_info>(); + + /// @brief Creates a package manager handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/packagemanager.info + /// @remarks You must release @a manager using package_manager_destroy(). + /// @param[out] manager The package manager handle that is newly created on success + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Internal I/O error + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @see package_manager_destroy() + int package_manager_create( + ffi.Pointer> manager, + ) { + return _package_manager_create( + manager, + ); + } + + late final _package_manager_create_ptr = + _lookup>( + 'package_manager_create'); + late final _dart_package_manager_create _package_manager_create = + _package_manager_create_ptr.asFunction<_dart_package_manager_create>(); + + /// @brief Destroys the package manager handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The package manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see package_manager_create() + int package_manager_destroy( + ffi.Pointer manager, + ) { + return _package_manager_destroy( + manager, + ); + } + + late final _package_manager_destroy_ptr = + _lookup>( + 'package_manager_destroy'); + late final _dart_package_manager_destroy _package_manager_destroy = + _package_manager_destroy_ptr.asFunction<_dart_package_manager_destroy>(); + + /// @brief Sets the event status of the package when the package is installed, uninstalled, or updated. + /// @details You can combine multiple status using OR operation which you want to listen. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param [in] manager The package manager handle + /// @param [in] status_type The status of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Internal I/O error + /// @see package_manager_status_type_e + /// @see package_manager_set_event_cb() + int package_manager_set_event_status( + ffi.Pointer manager, + int status_type, + ) { + return _package_manager_set_event_status( + manager, + status_type, + ); + } + + late final _package_manager_set_event_status_ptr = + _lookup>( + 'package_manager_set_event_status'); + late final _dart_package_manager_set_event_status + _package_manager_set_event_status = _package_manager_set_event_status_ptr + .asFunction<_dart_package_manager_set_event_status>(); + + /// @brief Registers a callback function to be invoked when the package is installed, uninstalled, or updated. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/packagemanager.info + /// @param[in] manager The package manager handle + /// @param[in] callback The callback function to be registered + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @post package_manager_event_cb() will be invoked. + /// @see package_manager_set_event_status() + /// @see package_manager_event_cb() + /// @see package_manager_unset_event_cb() + int package_manager_set_event_cb( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _package_manager_set_event_cb( + manager, + callback, + user_data, + ); + } + + late final _package_manager_set_event_cb_ptr = + _lookup>( + 'package_manager_set_event_cb'); + late final _dart_package_manager_set_event_cb _package_manager_set_event_cb = + _package_manager_set_event_cb_ptr + .asFunction<_dart_package_manager_set_event_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The package manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see package_manager_event_cb() + /// @see package_manager_set_event_cb() + int package_manager_unset_event_cb( + ffi.Pointer manager, + ) { + return _package_manager_unset_event_cb( + manager, + ); + } + + late final _package_manager_unset_event_cb_ptr = + _lookup>( + 'package_manager_unset_event_cb'); + late final _dart_package_manager_unset_event_cb + _package_manager_unset_event_cb = _package_manager_unset_event_cb_ptr + .asFunction<_dart_package_manager_unset_event_cb>(); + + /// @brief Retrieves all package information of installed packages. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/packagemanager.info + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @post This function invokes package_manager_package_info_cb() repeatedly for each package information. + /// @see package_manager_package_info_cb() + int package_manager_foreach_package_info( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _package_manager_foreach_package_info( + callback, + user_data, + ); + } + + late final _package_manager_foreach_package_info_ptr = + _lookup>( + 'package_manager_foreach_package_info'); + late final _dart_package_manager_foreach_package_info + _package_manager_foreach_package_info = + _package_manager_foreach_package_info_ptr + .asFunction<_dart_package_manager_foreach_package_info>(); + + /// @brief Gets the package ID for the given app ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/packagemanager.info + /// @param[in] app_id The ID of the application + /// @param[out] package_id The ID of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + int package_manager_get_package_id_by_app_id( + ffi.Pointer app_id, + ffi.Pointer> package_id, + ) { + return _package_manager_get_package_id_by_app_id( + app_id, + package_id, + ); + } + + late final _package_manager_get_package_id_by_app_id_ptr = + _lookup>( + 'package_manager_get_package_id_by_app_id'); + late final _dart_package_manager_get_package_id_by_app_id + _package_manager_get_package_id_by_app_id = + _package_manager_get_package_id_by_app_id_ptr + .asFunction<_dart_package_manager_get_package_id_by_app_id>(); + + /// @brief Gets the package information for the given package. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/packagemanager.info + /// @remarks You must release @a package_info using package_info_destroy(). + /// @param[in] package_id The ID of the package + /// @param[out] package_info The package information for the given package ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Database error occurred + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + int package_manager_get_package_info( + ffi.Pointer package_id, + ffi.Pointer> package_info, + ) { + return _package_manager_get_package_info( + package_id, + package_info, + ); + } + + late final _package_manager_get_package_info_ptr = + _lookup>( + 'package_manager_get_package_info'); + late final _dart_package_manager_get_package_info + _package_manager_get_package_info = _package_manager_get_package_info_ptr + .asFunction<_dart_package_manager_get_package_info>(); + + /// @brief Compares whether two package certifications are matched. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] lhs_package_id The first package ID to compare + /// @param[in] rhs_package_id The second package ID to compare + /// @param[out] compare_result @c 0 if the certification information are matched, + /// otherwise the compared result + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Database error occurred + int package_manager_compare_package_cert_info( + ffi.Pointer lhs_package_id, + ffi.Pointer rhs_package_id, + ffi.Pointer compare_result, + ) { + return _package_manager_compare_package_cert_info( + lhs_package_id, + rhs_package_id, + compare_result, + ); + } + + late final _package_manager_compare_package_cert_info_ptr = + _lookup>( + 'package_manager_compare_package_cert_info'); + late final _dart_package_manager_compare_package_cert_info + _package_manager_compare_package_cert_info = + _package_manager_compare_package_cert_info_ptr + .asFunction<_dart_package_manager_compare_package_cert_info>(); + + /// @brief Compares whether two app certifications are matched. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] lhs_app_id The first app ID to compare + /// @param[in] rhs_app_id The second app ID to compare + /// @param[out] compare_result @c 0 if the certification information are matched, + /// otherwise the compared result + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Database error occurred + int package_manager_compare_app_cert_info( + ffi.Pointer lhs_app_id, + ffi.Pointer rhs_app_id, + ffi.Pointer compare_result, + ) { + return _package_manager_compare_app_cert_info( + lhs_app_id, + rhs_app_id, + compare_result, + ); + } + + late final _package_manager_compare_app_cert_info_ptr = + _lookup>( + 'package_manager_compare_app_cert_info'); + late final _dart_package_manager_compare_app_cert_info + _package_manager_compare_app_cert_info = + _package_manager_compare_app_cert_info_ptr + .asFunction<_dart_package_manager_compare_app_cert_info>(); + + /// @brief Checks whether the package is preloaded by @a app_id. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/packagemanager.info + /// @param[in] app_id The ID of the application + /// @param[out] preload The preload info of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + int package_manager_is_preload_package_by_app_id( + ffi.Pointer app_id, + ffi.Pointer preload, + ) { + return _package_manager_is_preload_package_by_app_id( + app_id, + preload, + ); + } + + late final _package_manager_is_preload_package_by_app_id_ptr = _lookup< + ffi.NativeFunction<_c_package_manager_is_preload_package_by_app_id>>( + 'package_manager_is_preload_package_by_app_id'); + late final _dart_package_manager_is_preload_package_by_app_id + _package_manager_is_preload_package_by_app_id = + _package_manager_is_preload_package_by_app_id_ptr + .asFunction<_dart_package_manager_is_preload_package_by_app_id>(); + + /// @brief Gets the package permission type by @a app_id. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/packagemanager.info + /// @param[in] app_id The ID of the application + /// @param[out] permission_type The package permission type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + int package_manager_get_permission_type( + ffi.Pointer app_id, + ffi.Pointer permission_type, + ) { + return _package_manager_get_permission_type( + app_id, + permission_type, + ); + } + + late final _package_manager_get_permission_type_ptr = + _lookup>( + 'package_manager_get_permission_type'); + late final _dart_package_manager_get_permission_type + _package_manager_get_permission_type = + _package_manager_get_permission_type_ptr + .asFunction<_dart_package_manager_get_permission_type>(); + + /// @brief Clears the application's internal and external cache directory, asynchronously. + /// @details All files stored in the cache directory of the application specified with the package ID are removed. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/packagemanager.clearcache + /// @param[in] package_id The package ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_NO_SUCH_PACKAGE No such package + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @retval #PACKAGE_MANAGER_ERROR_SYSTEM_ERROR Severe system error + int package_manager_clear_cache_dir( + ffi.Pointer package_id, + ) { + return _package_manager_clear_cache_dir( + package_id, + ); + } + + late final _package_manager_clear_cache_dir_ptr = + _lookup>( + 'package_manager_clear_cache_dir'); + late final _dart_package_manager_clear_cache_dir + _package_manager_clear_cache_dir = _package_manager_clear_cache_dir_ptr + .asFunction<_dart_package_manager_clear_cache_dir>(); + + /// @platform + /// @brief Clears all applications' internal and external cache directory, asynchronously. + /// @details All files stored in the cache directory of each application are removed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_NO_SUCH_PACKAGE No such package + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @retval #PACKAGE_MANAGER_ERROR_SYSTEM_ERROR Severe system error + int package_manager_clear_all_cache_dir() { + return _package_manager_clear_all_cache_dir(); + } + + late final _package_manager_clear_all_cache_dir_ptr = + _lookup>( + 'package_manager_clear_all_cache_dir'); + late final _dart_package_manager_clear_all_cache_dir + _package_manager_clear_all_cache_dir = + _package_manager_clear_all_cache_dir_ptr + .asFunction<_dart_package_manager_clear_all_cache_dir>(); + + /// @platform + /// @brief Clears internal and external data directories used by applications in the given package. + /// @details All files stored in data directories used by applications in the package specified with the @a package_id are removed. + /// @since_tizen 4.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @param[in] package_id The package ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_NO_SUCH_PACKAGE No such package + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @retval #PACKAGE_MANAGER_ERROR_SYSTEM_ERROR Severe system error + int package_manager_clear_data_dir( + ffi.Pointer package_id, + ) { + return _package_manager_clear_data_dir( + package_id, + ); + } + + late final _package_manager_clear_data_dir_ptr = + _lookup>( + 'package_manager_clear_data_dir'); + late final _dart_package_manager_clear_data_dir + _package_manager_clear_data_dir = _package_manager_clear_data_dir_ptr + .asFunction<_dart_package_manager_clear_data_dir>(); + + /// @brief Gets the package size information, asynchronously. + /// @details The package size info is asynchronously obtained by the callback function. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/packagemanager.info + /// @param[in] package_id The package ID + /// @param[in] callback The asynchronous callback function to get the package size information + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_NO_SUCH_PACKAGE No such package + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @retval #PACKAGE_MANAGER_ERROR_SYSTEM_ERROR Severe system error + int package_manager_get_package_size_info( + ffi.Pointer package_id, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _package_manager_get_package_size_info( + package_id, + callback, + user_data, + ); + } + + late final _package_manager_get_package_size_info_ptr = + _lookup>( + 'package_manager_get_package_size_info'); + late final _dart_package_manager_get_package_size_info + _package_manager_get_package_size_info = + _package_manager_get_package_size_info_ptr + .asFunction<_dart_package_manager_get_package_size_info>(); + + /// @brief Gets the total package size information, asynchronously. + /// @details The total package size info is asynchronously obtained by the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/packagemanager.info + /// @param[in] callback The asynchronous callback function to get the total package size information + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_NO_SUCH_PACKAGE No such package + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @retval #PACKAGE_MANAGER_ERROR_SYSTEM_ERROR Severe system error + int package_manager_get_total_package_size_info( + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _package_manager_get_total_package_size_info( + callback, + user_data, + ); + } + + late final _package_manager_get_total_package_size_info_ptr = _lookup< + ffi.NativeFunction<_c_package_manager_get_total_package_size_info>>( + 'package_manager_get_total_package_size_info'); + late final _dart_package_manager_get_total_package_size_info + _package_manager_get_total_package_size_info = + _package_manager_get_total_package_size_info_ptr + .asFunction<_dart_package_manager_get_total_package_size_info>(); + + /// @brief Creates the package information filter handle from db. + /// @details The filtered result will be based on AND operation of all added filter properties. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/packagemanager.info + /// @param[out] handle Pointer to the package info filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @post package_manager_filter_destroy() + /// @see package_manager_filter_add_bool() + /// @see package_manager_filter_foreach_pkginfo() + int package_manager_filter_create( + ffi.Pointer> handle, + ) { + return _package_manager_filter_create( + handle, + ); + } + + late final _package_manager_filter_create_ptr = + _lookup>( + 'package_manager_filter_create'); + late final _dart_package_manager_filter_create + _package_manager_filter_create = _package_manager_filter_create_ptr + .asFunction<_dart_package_manager_filter_create>(); + + /// @brief This API destroys the package information filter handle freeing up all the resources + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] handle Pointer to the package info filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @pre package_manager_filter_create() + /// @see package_manager_filter_count() + /// @see package_manager_filter_foreach_package_info() + int package_manager_filter_destroy( + ffi.Pointer handle, + ) { + return _package_manager_filter_destroy( + handle, + ); + } + + late final _package_manager_filter_destroy_ptr = + _lookup>( + 'package_manager_filter_destroy'); + late final _dart_package_manager_filter_destroy + _package_manager_filter_destroy = _package_manager_filter_destroy_ptr + .asFunction<_dart_package_manager_filter_destroy>(); + + /// @brief This API adds a boolean filter property to the filter handle + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] handle Pointer to the package info filter handle + /// @param[in] property boolean property name + /// @param[in] value value corresponding to the property + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @pre package_manager_filter_create() + /// @post package_manager_filter_destroy() + /// @see package_manager_filter_count() + /// @see package_manager_filter_foreach_package_info() + int package_manager_filter_add_bool( + ffi.Pointer handle, + ffi.Pointer property, + bool value, + ) { + return _package_manager_filter_add_bool( + handle, + property, + value ? 1 : 0, + ); + } + + late final _package_manager_filter_add_bool_ptr = + _lookup>( + 'package_manager_filter_add_bool'); + late final _dart_package_manager_filter_add_bool + _package_manager_filter_add_bool = _package_manager_filter_add_bool_ptr + .asFunction<_dart_package_manager_filter_add_bool>(); + + /// @brief This API counts the package that satisfy the filter conditions + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/packagemanager.info + /// @param[in] handle Pointer to the package info filter handle + /// @param[out] count Pointer to store the count value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @pre package_manager_filter_create() + /// @post package_manager_filter_destroy() + /// @see package_manager_filter_foreach_package_info() + int package_manager_filter_count( + ffi.Pointer handle, + ffi.Pointer count, + ) { + return _package_manager_filter_count( + handle, + count, + ); + } + + late final _package_manager_filter_count_ptr = + _lookup>( + 'package_manager_filter_count'); + late final _dart_package_manager_filter_count _package_manager_filter_count = + _package_manager_filter_count_ptr + .asFunction<_dart_package_manager_filter_count>(); + + /// @brief This API executes the user supplied callback function for each package that satisfy the filter conditions + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/packagemanager.info + /// @param[in] handle Pointer to the package info filter handle + /// @param[in] callback callback function + /// @param[in] user_data user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @pre package_manager_filter_create() + /// @post package_manager_filter_destroy() + /// @post This function invokes package_manager_package_info_cb() repeatedly for each package information. + /// @see package_manager_package_info_cb() + /// @see package_manager_filter_count() + int package_manager_filter_foreach_package_info( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _package_manager_filter_foreach_package_info( + handle, + callback, + user_data, + ); + } + + late final _package_manager_filter_foreach_package_info_ptr = _lookup< + ffi.NativeFunction<_c_package_manager_filter_foreach_package_info>>( + 'package_manager_filter_foreach_package_info'); + late final _dart_package_manager_filter_foreach_package_info + _package_manager_filter_foreach_package_info = + _package_manager_filter_foreach_package_info_ptr + .asFunction<_dart_package_manager_filter_foreach_package_info>(); + + /// @platform + /// @brief Generates request for getting License, asynchronously. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @remarks You must release @a req_data and @a license_url by yourself. + /// @param[in] resp_data The response data string of the purchase request + /// @param[out] req_data License request data + /// @param[out] license_url License acquisition url data + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Internal I/O error + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @post package_manager_drm_register_license + int package_manager_drm_generate_license_request( + ffi.Pointer resp_data, + ffi.Pointer> req_data, + ffi.Pointer> license_url, + ) { + return _package_manager_drm_generate_license_request( + resp_data, + req_data, + license_url, + ); + } + + late final _package_manager_drm_generate_license_request_ptr = _lookup< + ffi.NativeFunction<_c_package_manager_drm_generate_license_request>>( + 'package_manager_drm_generate_license_request'); + late final _dart_package_manager_drm_generate_license_request + _package_manager_drm_generate_license_request = + _package_manager_drm_generate_license_request_ptr + .asFunction<_dart_package_manager_drm_generate_license_request>(); + + /// @platform + /// @brief Registers encrypted license, asynchronously. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @param[in] resp_data The response data string of the rights request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Internal I/O error + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @pre package_manager_drm_generate_license_request + int package_manager_drm_register_license( + ffi.Pointer resp_data, + ) { + return _package_manager_drm_register_license( + resp_data, + ); + } + + late final _package_manager_drm_register_license_ptr = + _lookup>( + 'package_manager_drm_register_license'); + late final _dart_package_manager_drm_register_license + _package_manager_drm_register_license = + _package_manager_drm_register_license_ptr + .asFunction<_dart_package_manager_drm_register_license>(); + + /// @platform + /// @brief Decrypts contents which is encrypted, asynchronously. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @param[in] drm_file_path DRM file path + /// @param[in] decrypted_file_path Decrypted file path + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Internal I/O error + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + int package_manager_drm_decrypt_package( + ffi.Pointer drm_file_path, + ffi.Pointer decrypted_file_path, + ) { + return _package_manager_drm_decrypt_package( + drm_file_path, + decrypted_file_path, + ); + } + + late final _package_manager_drm_decrypt_package_ptr = + _lookup>( + 'package_manager_drm_decrypt_package'); + late final _dart_package_manager_drm_decrypt_package + _package_manager_drm_decrypt_package = + _package_manager_drm_decrypt_package_ptr + .asFunction<_dart_package_manager_drm_decrypt_package>(); + + /// @brief Retrieves data size from given handle + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] handle Package size info handle + /// @param[out] data_size Data size will be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int package_size_info_get_data_size( + ffi.Pointer handle, + ffi.Pointer data_size, + ) { + return _package_size_info_get_data_size( + handle, + data_size, + ); + } + + late final _package_size_info_get_data_size_ptr = + _lookup>( + 'package_size_info_get_data_size'); + late final _dart_package_size_info_get_data_size + _package_size_info_get_data_size = _package_size_info_get_data_size_ptr + .asFunction<_dart_package_size_info_get_data_size>(); + + /// @brief Retrieves cache size from given handle + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] handle Package size info handle + /// @param[out] cache_size Cache size will be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int package_size_info_get_cache_size( + ffi.Pointer handle, + ffi.Pointer cache_size, + ) { + return _package_size_info_get_cache_size( + handle, + cache_size, + ); + } + + late final _package_size_info_get_cache_size_ptr = + _lookup>( + 'package_size_info_get_cache_size'); + late final _dart_package_size_info_get_cache_size + _package_size_info_get_cache_size = _package_size_info_get_cache_size_ptr + .asFunction<_dart_package_size_info_get_cache_size>(); + + /// @brief Retrieves application size from given handle + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] handle Package size info handle + /// @param[out] app_size App size will be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int package_size_info_get_app_size( + ffi.Pointer handle, + ffi.Pointer app_size, + ) { + return _package_size_info_get_app_size( + handle, + app_size, + ); + } + + late final _package_size_info_get_app_size_ptr = + _lookup>( + 'package_size_info_get_app_size'); + late final _dart_package_size_info_get_app_size + _package_size_info_get_app_size = _package_size_info_get_app_size_ptr + .asFunction<_dart_package_size_info_get_app_size>(); + + /// @brief Retrieves external data size from given handle + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] handle Package size info handle + /// @param[out] ext_data_size External data size will be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int package_size_info_get_external_data_size( + ffi.Pointer handle, + ffi.Pointer ext_data_size, + ) { + return _package_size_info_get_external_data_size( + handle, + ext_data_size, + ); + } + + late final _package_size_info_get_external_data_size_ptr = + _lookup>( + 'package_size_info_get_external_data_size'); + late final _dart_package_size_info_get_external_data_size + _package_size_info_get_external_data_size = + _package_size_info_get_external_data_size_ptr + .asFunction<_dart_package_size_info_get_external_data_size>(); + + /// @brief Retrieves external cache size from given handle + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] handle Package size info handle + /// @param[out] ext_cache_size External cache size will be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int package_size_info_get_external_cache_size( + ffi.Pointer handle, + ffi.Pointer ext_cache_size, + ) { + return _package_size_info_get_external_cache_size( + handle, + ext_cache_size, + ); + } + + late final _package_size_info_get_external_cache_size_ptr = + _lookup>( + 'package_size_info_get_external_cache_size'); + late final _dart_package_size_info_get_external_cache_size + _package_size_info_get_external_cache_size = + _package_size_info_get_external_cache_size_ptr + .asFunction<_dart_package_size_info_get_external_cache_size>(); + + /// @brief Retrieves external application size from given handle + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] handle Package size info handle + /// @param[out] ext_app_size External app size will be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int package_size_info_get_external_app_size( + ffi.Pointer handle, + ffi.Pointer ext_app_size, + ) { + return _package_size_info_get_external_app_size( + handle, + ext_app_size, + ); + } + + late final _package_size_info_get_external_app_size_ptr = + _lookup>( + 'package_size_info_get_external_app_size'); + late final _dart_package_size_info_get_external_app_size + _package_size_info_get_external_app_size = + _package_size_info_get_external_app_size_ptr + .asFunction<_dart_package_size_info_get_external_app_size>(); + + /// @platform + /// @brief Creates a request handle to the package manager. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a request using package_manager_request_destroy(). + /// @param[out] request The request handle that is newly created on success + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Internal I/O error + /// @see package_manager_request_destroy() + int package_manager_request_create( + ffi.Pointer> request, + ) { + return _package_manager_request_create( + request, + ); + } + + late final _package_manager_request_create_ptr = + _lookup>( + 'package_manager_request_create'); + late final _dart_package_manager_request_create + _package_manager_request_create = _package_manager_request_create_ptr + .asFunction<_dart_package_manager_request_create>(); + + /// @platform + /// @brief Destroys the request handle to the package manager. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] request The request handle to the package manager + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see package_manager_request_create() + int package_manager_request_destroy( + ffi.Pointer request, + ) { + return _package_manager_request_destroy( + request, + ); + } + + late final _package_manager_request_destroy_ptr = + _lookup>( + 'package_manager_request_destroy'); + late final _dart_package_manager_request_destroy + _package_manager_request_destroy = _package_manager_request_destroy_ptr + .asFunction<_dart_package_manager_request_destroy>(); + + /// @platform + /// @brief Registers a callback function to be invoked when the progress of the request changes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/packagemanager.info + /// @param[in] request The request handle + /// @param[in] callback The callback function to be registered + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @post package_manager_request_event_cb() will be invoked. + /// @see package_manager_request_event_cb() + /// @see package_manager_request_unset_event_cb() + int package_manager_request_set_event_cb( + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _package_manager_request_set_event_cb( + request, + callback, + user_data, + ); + } + + late final _package_manager_request_set_event_cb_ptr = + _lookup>( + 'package_manager_request_set_event_cb'); + late final _dart_package_manager_request_set_event_cb + _package_manager_request_set_event_cb = + _package_manager_request_set_event_cb_ptr + .asFunction<_dart_package_manager_request_set_event_cb>(); + + /// @platform + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] request The request handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see package_manager_request_event_cb() + /// @see package_manager_request_set_event_cb() + int package_manager_request_unset_event_cb( + ffi.Pointer request, + ) { + return _package_manager_request_unset_event_cb( + request, + ); + } + + late final _package_manager_request_unset_event_cb_ptr = + _lookup>( + 'package_manager_request_unset_event_cb'); + late final _dart_package_manager_request_unset_event_cb + _package_manager_request_unset_event_cb = + _package_manager_request_unset_event_cb_ptr + .asFunction<_dart_package_manager_request_unset_event_cb>(); + + /// @platform + /// @brief Sets the type of the package to install, uninstall, or update. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] request The request handle + /// @param[in] type The type of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int package_manager_request_set_type( + ffi.Pointer request, + ffi.Pointer type, + ) { + return _package_manager_request_set_type( + request, + type, + ); + } + + late final _package_manager_request_set_type_ptr = + _lookup>( + 'package_manager_request_set_type'); + late final _dart_package_manager_request_set_type + _package_manager_request_set_type = _package_manager_request_set_type_ptr + .asFunction<_dart_package_manager_request_set_type>(); + + /// @platform + /// @brief Sets the mode of the request. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] request The request handle + /// @param[in] mode The mode of the request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int package_manager_request_set_mode( + ffi.Pointer request, + int mode, + ) { + return _package_manager_request_set_mode( + request, + mode, + ); + } + + late final _package_manager_request_set_mode_ptr = + _lookup>( + 'package_manager_request_set_mode'); + late final _dart_package_manager_request_set_mode + _package_manager_request_set_mode = _package_manager_request_set_mode_ptr + .asFunction<_dart_package_manager_request_set_mode>(); + + /// @platform + /// @brief Sets the path of TEP file to the request. The TEP file that is set will be installed when the package is installed. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @param[in] request The request handle + /// @param[in] tep_path The TEP path to set. If this is NULL on update, installed TEP will be removed. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #PACKAGE_MANAGER_ERROR_SYSTEM_ERROR Severe system error + int package_manager_request_set_tep( + ffi.Pointer request, + ffi.Pointer tep_path, + ) { + return _package_manager_request_set_tep( + request, + tep_path, + ); + } + + late final _package_manager_request_set_tep_ptr = + _lookup>( + 'package_manager_request_set_tep'); + late final _dart_package_manager_request_set_tep + _package_manager_request_set_tep = _package_manager_request_set_tep_ptr + .asFunction<_dart_package_manager_request_set_tep>(); + + /// @platform + /// @brief Installs the package located at the given path, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @param[in] request The request handle + /// @param[in] path The absolute path to the package to be installed + /// @param[out] id The ID of the request to the package manager + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @see package_manager_request_uninstall() + int package_manager_request_install( + ffi.Pointer request, + ffi.Pointer path, + ffi.Pointer id, + ) { + return _package_manager_request_install( + request, + path, + id, + ); + } + + late final _package_manager_request_install_ptr = + _lookup>( + 'package_manager_request_install'); + late final _dart_package_manager_request_install + _package_manager_request_install = _package_manager_request_install_ptr + .asFunction<_dart_package_manager_request_install>(); + + /// @platform + /// @brief Installs the package located at the given path, asynchronously. + /// @details The progress of the request is asynchronously received by the callback function. + /// The @a callback is the individual callback only called for the current API call. + /// The @a callback is the only callback called, even if another callback was set for this request + /// with package_manager_request_set_event_cb(). + /// @since_tizen 4.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @param[in] request The request handle + /// @param[in] path The absolute path to the package to be installed + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] id The ID of the request to the package manager + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + int package_manager_request_install_with_cb( + ffi.Pointer request, + ffi.Pointer path, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, + ) { + return _package_manager_request_install_with_cb( + request, + path, + callback, + user_data, + id, + ); + } + + late final _package_manager_request_install_with_cb_ptr = + _lookup>( + 'package_manager_request_install_with_cb'); + late final _dart_package_manager_request_install_with_cb + _package_manager_request_install_with_cb = + _package_manager_request_install_with_cb_ptr + .asFunction<_dart_package_manager_request_install_with_cb>(); + + /// @platform + /// @brief Uninstalls the package with the given name, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @param[in] request The request handle + /// @param[in] name The name of the package to be uninstalled + /// @param[out] id The ID of the request to the package manager + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + int package_manager_request_uninstall( + ffi.Pointer request, + ffi.Pointer name, + ffi.Pointer id, + ) { + return _package_manager_request_uninstall( + request, + name, + id, + ); + } + + late final _package_manager_request_uninstall_ptr = + _lookup>( + 'package_manager_request_uninstall'); + late final _dart_package_manager_request_uninstall + _package_manager_request_uninstall = + _package_manager_request_uninstall_ptr + .asFunction<_dart_package_manager_request_uninstall>(); + + /// @platform + /// @brief Uninstalls the package with the given name, asynchronously. + /// @details The progress of the request is asynchronously received by the callback function. + /// The @a callback is the individual callback only called for the current API call. + /// The @a callback is the only callback called, even if another callback was set for this request + /// with package_manager_request_set_event_cb(). + /// @since_tizen 4.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @param[in] request The request handle + /// @param[in] name The name of the package to be uninstalled + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] id The ID of the request to the package manager + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + int package_manager_request_uninstall_with_cb( + ffi.Pointer request, + ffi.Pointer name, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, + ) { + return _package_manager_request_uninstall_with_cb( + request, + name, + callback, + user_data, + id, + ); + } + + late final _package_manager_request_uninstall_with_cb_ptr = + _lookup>( + 'package_manager_request_uninstall_with_cb'); + late final _dart_package_manager_request_uninstall_with_cb + _package_manager_request_uninstall_with_cb = + _package_manager_request_uninstall_with_cb_ptr + .asFunction<_dart_package_manager_request_uninstall_with_cb>(); + + /// @platform + /// @brief Moves the package from SD card to the internal memory and vice versa, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @param[in] request The request handle + /// @param[in] name The name of the package to be moved + /// @param[in] move_type The move type [enum package_manager_move_type_e], [external to internal/internal to external] + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + int package_manager_request_move( + ffi.Pointer request, + ffi.Pointer name, + int move_type, + ) { + return _package_manager_request_move( + request, + name, + move_type, + ); + } + + late final _package_manager_request_move_ptr = + _lookup>( + 'package_manager_request_move'); + late final _dart_package_manager_request_move _package_manager_request_move = + _package_manager_request_move_ptr + .asFunction<_dart_package_manager_request_move>(); + + /// @platform + /// @brief Moves the package from SD card to the internal memory and vice versa, asynchronously. + /// @details The progress of the request is asynchronously received by the callback function. + /// The @a callback is the individual callback only called for the current API call. + /// The @a callback is the only callback called, even if another callback was set for this request + /// with package_manager_request_set_event_cb(). + /// @since_tizen 4.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @param[in] request The request handle + /// @param[in] name The name of the package to be moved + /// @param[in] move_type The move type [enum package_manager_move_type_e], [external to internal/internal to external] + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] id The ID of the request to the package manager + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + int package_manager_request_move_with_cb( + ffi.Pointer request, + ffi.Pointer name, + int move_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, + ) { + return _package_manager_request_move_with_cb( + request, + name, + move_type, + callback, + user_data, + id, + ); + } + + late final _package_manager_request_move_with_cb_ptr = + _lookup>( + 'package_manager_request_move_with_cb'); + late final _dart_package_manager_request_move_with_cb + _package_manager_request_move_with_cb = + _package_manager_request_move_with_cb_ptr + .asFunction<_dart_package_manager_request_move_with_cb>(); + + /// @platform + /// @brief Creates a package update info request. + /// @since_tizen 4.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/packagemanager.admin + /// @remarks You must release @a pkg_updateinfo_req using package_manager_updateinfo_request_destroy(). + /// @param[out] pkg_updateinfo_req The package update info request handle that is newly created on success + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @see package_manager_updateinfo_request_destroy() + int package_manager_updateinfo_request_create( + ffi.Pointer> pkg_updateinfo_req, + ) { + return _package_manager_updateinfo_request_create( + pkg_updateinfo_req, + ); + } + + late final _package_manager_updateinfo_request_create_ptr = + _lookup>( + 'package_manager_updateinfo_request_create'); + late final _dart_package_manager_updateinfo_request_create + _package_manager_updateinfo_request_create = + _package_manager_updateinfo_request_create_ptr + .asFunction<_dart_package_manager_updateinfo_request_create>(); + + /// @brief Sets the package ID to the package update info request. + /// @since_tizen 4.0 + /// @param[in] pkg_updateinfo_req The update info request handle + /// @param[in] pkgid The package ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see package_manager_updateinfo_request_create() + int package_manager_updateinfo_set_pkgid( + ffi.Pointer pkg_updateinfo_req, + ffi.Pointer pkgid, + ) { + return _package_manager_updateinfo_set_pkgid( + pkg_updateinfo_req, + pkgid, + ); + } + + late final _package_manager_updateinfo_set_pkgid_ptr = + _lookup>( + 'package_manager_updateinfo_set_pkgid'); + late final _dart_package_manager_updateinfo_set_pkgid + _package_manager_updateinfo_set_pkgid = + _package_manager_updateinfo_set_pkgid_ptr + .asFunction<_dart_package_manager_updateinfo_set_pkgid>(); + + /// @brief Sets the package version to the package update info request. + /// @since_tizen 4.0 + /// @param[in] pkg_updateinfo_req The update info request handle + /// @param[in] version The package version + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see package_manager_updateinfo_request_create() + int package_manager_updateinfo_set_version( + ffi.Pointer pkg_updateinfo_req, + ffi.Pointer version, + ) { + return _package_manager_updateinfo_set_version( + pkg_updateinfo_req, + version, + ); + } + + late final _package_manager_updateinfo_set_version_ptr = + _lookup>( + 'package_manager_updateinfo_set_version'); + late final _dart_package_manager_updateinfo_set_version + _package_manager_updateinfo_set_version = + _package_manager_updateinfo_set_version_ptr + .asFunction<_dart_package_manager_updateinfo_set_version>(); + + /// @brief Sets the package update type to the package update info request. + /// @since_tizen 4.0 + /// @param[in] pkg_updateinfo_req The update info request handle + /// @param[in] type The package update type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see package_manager_updateinfo_request_create() + /// @see package_updateinfo_type_e + int package_manager_updateinfo_set_type( + ffi.Pointer pkg_updateinfo_req, + int type, + ) { + return _package_manager_updateinfo_set_type( + pkg_updateinfo_req, + type, + ); + } + + late final _package_manager_updateinfo_set_type_ptr = + _lookup>( + 'package_manager_updateinfo_set_type'); + late final _dart_package_manager_updateinfo_set_type + _package_manager_updateinfo_set_type = + _package_manager_updateinfo_set_type_ptr + .asFunction<_dart_package_manager_updateinfo_set_type>(); + + /// @brief Request to register package update info in platform. + /// @since_tizen 4.0 + /// @param[in] pkg_updateinfo_req The update info request handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @retval #PACKAGE_MANAGER_ERROR_SYSTEM_ERROR Severe system error + /// @see package_manager_updateinfo_request_create() + /// @see package_manager_updateinfo_request_destroy() + int package_manager_updateinfo_request_register( + ffi.Pointer pkg_updateinfo_req, + ) { + return _package_manager_updateinfo_request_register( + pkg_updateinfo_req, + ); + } + + late final _package_manager_updateinfo_request_register_ptr = _lookup< + ffi.NativeFunction<_c_package_manager_updateinfo_request_register>>( + 'package_manager_updateinfo_request_register'); + late final _dart_package_manager_updateinfo_request_register + _package_manager_updateinfo_request_register = + _package_manager_updateinfo_request_register_ptr + .asFunction<_dart_package_manager_updateinfo_request_register>(); + + /// @brief Destroys the package update info request. + /// @since_tizen 4.0 + /// @param[in] pkg_updateinfo_req The update info request handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see package_manager_updateinfo_request_create() + int package_manager_updateinfo_request_destroy( + ffi.Pointer pkg_updateinfo_req, + ) { + return _package_manager_updateinfo_request_destroy( + pkg_updateinfo_req, + ); + } + + late final _package_manager_updateinfo_request_destroy_ptr = _lookup< + ffi.NativeFunction<_c_package_manager_updateinfo_request_destroy>>( + 'package_manager_updateinfo_request_destroy'); + late final _dart_package_manager_updateinfo_request_destroy + _package_manager_updateinfo_request_destroy = + _package_manager_updateinfo_request_destroy_ptr + .asFunction<_dart_package_manager_updateinfo_request_destroy>(); + + /// @brief Request to unregister update info in platform for given package id. + /// @since_tizen 4.0 + /// @param[in] pkg_updateinfo_req The update info request handle + /// @param[in] pkgid The package id to request unregister update info + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @retval #PACKAGE_MANAGER_ERROR_SYSTEM_ERROR Severe system error + int package_manager_updateinfo_request_unregister( + ffi.Pointer pkg_updateinfo_req, + ffi.Pointer pkgid, + ) { + return _package_manager_updateinfo_request_unregister( + pkg_updateinfo_req, + pkgid, + ); + } + + late final _package_manager_updateinfo_request_unregister_ptr = _lookup< + ffi.NativeFunction<_c_package_manager_updateinfo_request_unregister>>( + 'package_manager_updateinfo_request_unregister'); + late final _dart_package_manager_updateinfo_request_unregister + _package_manager_updateinfo_request_unregister = + _package_manager_updateinfo_request_unregister_ptr + .asFunction<_dart_package_manager_updateinfo_request_unregister>(); + + /// @brief Request to unregister update info of all packages in platform. + /// @since_tizen 4.0 + /// @param[in] pkg_updateinfo_req The update info request handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + /// @retval #PACKAGE_MANAGER_ERROR_SYSTEM_ERROR Severe system error + int package_manager_updateinfo_request_unregister_all( + ffi.Pointer pkg_updateinfo_req, + ) { + return _package_manager_updateinfo_request_unregister_all( + pkg_updateinfo_req, + ); + } + + late final _package_manager_updateinfo_request_unregister_all_ptr = _lookup< + ffi.NativeFunction< + _c_package_manager_updateinfo_request_unregister_all>>( + 'package_manager_updateinfo_request_unregister_all'); + late final _dart_package_manager_updateinfo_request_unregister_all + _package_manager_updateinfo_request_unregister_all = + _package_manager_updateinfo_request_unregister_all_ptr.asFunction< + _dart_package_manager_updateinfo_request_unregister_all>(); + + /// @brief Creates the package archive information for the given package. + /// @since_tizen 4.0 + /// @remarks If the given path is relevant to media storage, the privilege + /// http://tizen.org/privilege/mediastorage is needed. + /// @remarks If the given path is relevant to external storage, the privilege + /// http://tizen.org/privilege/externalstorage is needed. + /// @remarks You must release @a archive_info + /// using package_archive_info_destroy(). + /// @param[in] path The path of the package + /// @param[out] archive_info The package archive information for + /// the given package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR Internal I/O error + /// @see package_archive_info_destroy() + int package_archive_info_create( + ffi.Pointer path, + ffi.Pointer> archive_info, + ) { + return _package_archive_info_create( + path, + archive_info, + ); + } + + late final _package_archive_info_create_ptr = + _lookup>( + 'package_archive_info_create'); + late final _dart_package_archive_info_create _package_archive_info_create = + _package_archive_info_create_ptr + .asFunction<_dart_package_archive_info_create>(); + + /// @brief Destroys the package archive information handle. + /// @since_tizen 4.0 + /// @param[in] archive_info The package archive information handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see package_archive_info_create() + int package_archive_info_destroy( + ffi.Pointer archive_info, + ) { + return _package_archive_info_destroy( + archive_info, + ); + } + + late final _package_archive_info_destroy_ptr = + _lookup>( + 'package_archive_info_destroy'); + late final _dart_package_archive_info_destroy _package_archive_info_destroy = + _package_archive_info_destroy_ptr + .asFunction<_dart_package_archive_info_destroy>(); + + /// @brief Gets the package name. + /// @since_tizen 4.0 + /// @remarks You must release @a package using free(). + /// @param[in] archive_info The package archive information + /// @param[out] package The package name + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int package_archive_info_get_package( + ffi.Pointer archive_info, + ffi.Pointer> package, + ) { + return _package_archive_info_get_package( + archive_info, + package, + ); + } + + late final _package_archive_info_get_package_ptr = + _lookup>( + 'package_archive_info_get_package'); + late final _dart_package_archive_info_get_package + _package_archive_info_get_package = _package_archive_info_get_package_ptr + .asFunction<_dart_package_archive_info_get_package>(); + + /// @brief Gets the type of the package. + /// @since_tizen 4.0 + /// @remarks You must release @a type using free(). + /// @param[in] archive_info The package archive information + /// @param[out] type The type of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int package_archive_info_get_type( + ffi.Pointer archive_info, + ffi.Pointer> type, + ) { + return _package_archive_info_get_type( + archive_info, + type, + ); + } + + late final _package_archive_info_get_type_ptr = + _lookup>( + 'package_archive_info_get_type'); + late final _dart_package_archive_info_get_type + _package_archive_info_get_type = _package_archive_info_get_type_ptr + .asFunction<_dart_package_archive_info_get_type>(); + + /// @brief Gets the version of the package. + /// @since_tizen 4.0 + /// @remarks You must release @a version using free(). + /// @param[in] archive_info The package archive information + /// @param[out] version The version of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int package_archive_info_get_version( + ffi.Pointer archive_info, + ffi.Pointer> version, + ) { + return _package_archive_info_get_version( + archive_info, + version, + ); + } + + late final _package_archive_info_get_version_ptr = + _lookup>( + 'package_archive_info_get_version'); + late final _dart_package_archive_info_get_version + _package_archive_info_get_version = _package_archive_info_get_version_ptr + .asFunction<_dart_package_archive_info_get_version>(); + + /// @brief Gets the API version of the package. + /// @since_tizen 4.0 + /// @remarks You must release @a api_version using free(). + /// @param[in] archive_info The package archive information + /// @param[out] api_version The API version of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + int package_archive_info_get_api_version( + ffi.Pointer archive_info, + ffi.Pointer> api_version, + ) { + return _package_archive_info_get_api_version( + archive_info, + api_version, + ); + } + + late final _package_archive_info_get_api_version_ptr = + _lookup>( + 'package_archive_info_get_api_version'); + late final _dart_package_archive_info_get_api_version + _package_archive_info_get_api_version = + _package_archive_info_get_api_version_ptr + .asFunction<_dart_package_archive_info_get_api_version>(); + + /// @brief Gets the description of the package. + /// @since_tizen 4.0 + /// @remarks You must release @a description using free(). + /// @param[in] archive_info The package archive information + /// @param[out] description The description of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_archive_info_get_description( + ffi.Pointer archive_info, + ffi.Pointer> description, + ) { + return _package_archive_info_get_description( + archive_info, + description, + ); + } + + late final _package_archive_info_get_description_ptr = + _lookup>( + 'package_archive_info_get_description'); + late final _dart_package_archive_info_get_description + _package_archive_info_get_description = + _package_archive_info_get_description_ptr + .asFunction<_dart_package_archive_info_get_description>(); + + /// @brief Gets the label of the package. + /// @since_tizen 4.0 + /// @remarks You must release @a label using free(). + /// @param[in] archive_info The package archive information + /// @param[out] label The label of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_archive_info_get_label( + ffi.Pointer archive_info, + ffi.Pointer> label, + ) { + return _package_archive_info_get_label( + archive_info, + label, + ); + } + + late final _package_archive_info_get_label_ptr = + _lookup>( + 'package_archive_info_get_label'); + late final _dart_package_archive_info_get_label + _package_archive_info_get_label = _package_archive_info_get_label_ptr + .asFunction<_dart_package_archive_info_get_label>(); + + /// @brief Gets the author of the package. + /// @since_tizen 4.0 + /// @remarks You must release @a author using free(). + /// @param[in] archive_info The package archive information + /// @param[out] author The author of the package + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_archive_info_get_author( + ffi.Pointer archive_info, + ffi.Pointer> author, + ) { + return _package_archive_info_get_author( + archive_info, + author, + ); + } + + late final _package_archive_info_get_author_ptr = + _lookup>( + 'package_archive_info_get_author'); + late final _dart_package_archive_info_get_author + _package_archive_info_get_author = _package_archive_info_get_author_ptr + .asFunction<_dart_package_archive_info_get_author>(); + + /// @brief Gets the raw icon of the package. + /// @since_tizen 4.0 + /// @remarks You must release @a icon using free(). + /// @param[in] archive_info The package archive information + /// @param[out] icon The raw icon of the package + /// @param[out] icon_size The size of the icon + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PACKAGE_MANAGER_ERROR_NONE Successful + /// @retval #PACKAGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PACKAGE_MANAGER_ERROR_IO_ERROR I/O error + int package_archive_info_get_icon( + ffi.Pointer archive_info, + ffi.Pointer> icon, + ffi.Pointer icon_size, + ) { + return _package_archive_info_get_icon( + archive_info, + icon, + icon_size, + ); + } + + late final _package_archive_info_get_icon_ptr = + _lookup>( + 'package_archive_info_get_icon'); + late final _dart_package_archive_info_get_icon + _package_archive_info_get_icon = _package_archive_info_get_icon_ptr + .asFunction<_dart_package_archive_info_get_icon>(); + + /// @brief Adds the system event handler + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The service application can handle low memory event, low battery event, language setting changed event and region format changed event. + /// @param[out] handler The event handler + /// @param[in] event_type The system event type + /// @param[in] callback The callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_OUT_OF_MEMORY Out of memory + /// @see app_event_type_e + /// @see app_event_cb + /// @see service_app_remove_event_handler + int service_app_add_event_handler( + ffi.Pointer> handler, + int event_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _service_app_add_event_handler( + handler, + event_type, + callback, + user_data, + ); + } + + late final _service_app_add_event_handler_ptr = + _lookup>( + 'service_app_add_event_handler'); + late final _dart_service_app_add_event_handler + _service_app_add_event_handler = _service_app_add_event_handler_ptr + .asFunction<_dart_service_app_add_event_handler>(); + + /// @brief Removes registered event handler + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] event_handler The event handler + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @see service_app_add_event_handler + int service_app_remove_event_handler( + ffi.Pointer event_handler, + ) { + return _service_app_remove_event_handler( + event_handler, + ); + } + + late final _service_app_remove_event_handler_ptr = + _lookup>( + 'service_app_remove_event_handler'); + late final _dart_service_app_remove_event_handler + _service_app_remove_event_handler = _service_app_remove_event_handler_ptr + .asFunction<_dart_service_app_remove_event_handler>(); + + /// @brief Runs the main loop of the application until service_app_exit() is called. + /// @details This function is the main entry point of the Tizen service application. + /// This main loop supports event handling for the GMainLoop and the Ecore Main Loop. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] argc The argument count + /// @param[in] argv The argument vector + /// @param[in] callback The set of callback functions to handle application events + /// @param[in] user_data The user data to be passed to the callback functions + /// @return @c 0 on success, + /// otherwise a negative error value. + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_INVALID_CONTEXT The application is launched illegally, not launched by the launch system. + /// @retval #APP_ERROR_ALREADY_RUNNING The main loop has already started + /// @see service_app_create_cb() + /// @see service_app_terminate_cb() + /// @see service_app_control_cb() + /// @see service_app_exit() + /// @see #service_app_lifecycle_callback_s + int service_app_main( + int argc, + ffi.Pointer> argv, + ffi.Pointer callback, + ffi.Pointer user_data, + ) { + return _service_app_main( + argc, + argv, + callback, + user_data, + ); + } + + late final _service_app_main_ptr = + _lookup>('service_app_main'); + late final _dart_service_app_main _service_app_main = + _service_app_main_ptr.asFunction<_dart_service_app_main>(); + + /// @brief Exits the main loop of the application. + /// @details The main loop of the application stops and service_app_terminate_cb() is invoked. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @see service_app_main() + /// @see service_app_terminate_cb() + void service_app_exit() { + return _service_app_exit(); + } + + late final _service_app_exit_ptr = + _lookup>('service_app_exit'); + late final _dart_service_app_exit _service_app_exit = + _service_app_exit_ptr.asFunction<_dart_service_app_exit>(); + + /// @brief Adds the system event handler + /// @since_tizen 2.3.1 + /// @param[out] handler The event handler + /// @param[in] event_type The system event type + /// @param[in] callback The callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + /// @see app_event_type_e + /// @see app_event_cb + /// @see watch_app_remove_event_handler + int watch_app_add_event_handler( + ffi.Pointer> handler, + int event_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _watch_app_add_event_handler( + handler, + event_type, + callback, + user_data, + ); + } + + late final _watch_app_add_event_handler_ptr = + _lookup>( + 'watch_app_add_event_handler'); + late final _dart_watch_app_add_event_handler _watch_app_add_event_handler = + _watch_app_add_event_handler_ptr + .asFunction<_dart_watch_app_add_event_handler>(); + + /// @brief Removes registered event handler + /// @since_tizen 2.3.1 + /// @param[in] event_handler The event handler + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + /// @see watch_app_add_event_handler + int watch_app_remove_event_handler( + ffi.Pointer event_handler, + ) { + return _watch_app_remove_event_handler( + event_handler, + ); + } + + late final _watch_app_remove_event_handler_ptr = + _lookup>( + 'watch_app_remove_event_handler'); + late final _dart_watch_app_remove_event_handler + _watch_app_remove_event_handler = _watch_app_remove_event_handler_ptr + .asFunction<_dart_watch_app_remove_event_handler>(); + + /// @brief Runs the main loop of the application until watch_app_exit() is called. + /// @since_tizen 2.3.1 + /// @remarks http://tizen.org/privilege/alarm.set privilege is needed to receive ambient ticks at each minute. The watch_app_ambient_tick_cb() will be ignored if your app doesn't have the privilege. + /// @param[in] argc The argument count + /// @param[in] argv The argument vector + /// @param[in] callback The set of callback functions to handle application events + /// @param[in] user_data The user data to be passed to the callback functions + /// @return @c 0 on success, + /// otherwise a negative error value. + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #APP_ERROR_INVALID_CONTEXT The application is illegally launched, not launched by the launch system. + /// @retval #APP_ERROR_ALREADY_RUNNING The main loop has already started + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + /// @see watch_app_main() + /// @see watch_app_create_cb() + /// @see watch_app_control_cb() + /// @see watch_app_pause_cb() + /// @see watch_app_resume_cb() + /// @see watch_app_time_tick_cb() + /// @see watch_app_ambient_tick_cb() + /// @see watch_app_ambient_changed_cb() + /// @see watch_app_terminate_cb() + /// @see #watch_app_lifecycle_callback_s + int watch_app_main( + int argc, + ffi.Pointer> argv, + ffi.Pointer callback, + ffi.Pointer user_data, + ) { + return _watch_app_main( + argc, + argv, + callback, + user_data, + ); + } + + late final _watch_app_main_ptr = + _lookup>('watch_app_main'); + late final _dart_watch_app_main _watch_app_main = + _watch_app_main_ptr.asFunction<_dart_watch_app_main>(); + + /// @brief Exits the main loop of the application. + /// @details The main loop of the application stops and watch_app_terminate_cb() is invoked. + /// @since_tizen 2.3.1 + /// @see watch_app_main() + /// @see watch_app_terminate_cb() + void watch_app_exit() { + return _watch_app_exit(); + } + + late final _watch_app_exit_ptr = + _lookup>('watch_app_exit'); + late final _dart_watch_app_exit _watch_app_exit = + _watch_app_exit_ptr.asFunction<_dart_watch_app_exit>(); + + /// @brief Sets the frequency of watch_app_time_tick_cb() calls. + /// @details If watch_app_set_time_tick_frequency() is not called, watch_app_time_tick_cb() will be called every second. + /// @since_tizen 3.0 + /// @param[in] ticks The number of ticks per given resolution type + /// @param[in] type The resolution type + /// @return 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + /// @see watch_app_time_tick_resolution_e + /// @see watch_app_get_time_tick_frequency() + int watch_app_set_time_tick_frequency( + int ticks, + int type, + ) { + return _watch_app_set_time_tick_frequency( + ticks, + type, + ); + } + + late final _watch_app_set_time_tick_frequency_ptr = + _lookup>( + 'watch_app_set_time_tick_frequency'); + late final _dart_watch_app_set_time_tick_frequency + _watch_app_set_time_tick_frequency = + _watch_app_set_time_tick_frequency_ptr + .asFunction<_dart_watch_app_set_time_tick_frequency>(); + + /// @brief Gets the frequency of watch_app_time_tick_cb() calls. + /// @since_tizen 3.0 + /// @param[out] ticks The number of ticks per given resolution type + /// @param[out] type The resolution type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + /// @see watch_app_time_tick_resolution_e + /// @see watch_app_set_time_tick_frequency() + int watch_app_get_time_tick_frequency( + ffi.Pointer ticks, + ffi.Pointer type, + ) { + return _watch_app_get_time_tick_frequency( + ticks, + type, + ); + } + + late final _watch_app_get_time_tick_frequency_ptr = + _lookup>( + 'watch_app_get_time_tick_frequency'); + late final _dart_watch_app_get_time_tick_frequency + _watch_app_get_time_tick_frequency = + _watch_app_get_time_tick_frequency_ptr + .asFunction<_dart_watch_app_get_time_tick_frequency>(); + + /// @brief Sets the type of periodic ambient tick. + /// @since_tizen 2.3.2 + /// @remarks If you do not set specific tick type with this function, the watch_app_ambient_tick_cb() will be called every minute by default. + /// @param[in] type The type of periodic ambient tick + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + /// @see watch_app_ambient_tick_cb() + int watch_app_set_ambient_tick_type( + int type, + ) { + return _watch_app_set_ambient_tick_type( + type, + ); + } + + late final _watch_app_set_ambient_tick_type_ptr = + _lookup>( + 'watch_app_set_ambient_tick_type'); + late final _dart_watch_app_set_ambient_tick_type + _watch_app_set_ambient_tick_type = _watch_app_set_ambient_tick_type_ptr + .asFunction<_dart_watch_app_set_ambient_tick_type>(); + + /// @brief Gets the type of periodic ambient tick. + /// @since_tizen 2.3.2 + /// @remarks If you do not set specific tick type with watch_app_set_ambient_tick_type(), this function will set @a type to #WATCH_APP_AMBIENT_TICK_EVERY_MINUTE. * @param[out] type The type of periodic ambient tick + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + /// @see watch_app_ambient_tick_cb() + /// @see watch_app_set_ambient_tick_type() + int watch_app_get_ambient_tick_type( + ffi.Pointer type, + ) { + return _watch_app_get_ambient_tick_type( + type, + ); + } + + late final _watch_app_get_ambient_tick_type_ptr = + _lookup>( + 'watch_app_get_ambient_tick_type'); + late final _dart_watch_app_get_ambient_tick_type + _watch_app_get_ambient_tick_type = _watch_app_get_ambient_tick_type_ptr + .asFunction<_dart_watch_app_get_ambient_tick_type>(); + + /// @brief Gets the current time. + /// @since_tizen 2.3.1 + /// @remarks You must release @a watch_time using watch_time_delete() after using it. + /// @param[out] watch_time The watch_time handle to be newly created on success + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_get_current_time( + ffi.Pointer> watch_time, + ) { + return _watch_time_get_current_time( + watch_time, + ); + } + + late final _watch_time_get_current_time_ptr = + _lookup>( + 'watch_time_get_current_time'); + late final _dart_watch_time_get_current_time _watch_time_get_current_time = + _watch_time_get_current_time_ptr + .asFunction<_dart_watch_time_get_current_time>(); + + /// @brief Deletes the watch time handle and releases all its resources. + /// @since_tizen 2.3.1 + /// @param[in] watch_time The watch_time handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_delete( + ffi.Pointer<_watch_time_s> watch_time, + ) { + return _watch_time_delete( + watch_time, + ); + } + + late final _watch_time_delete_ptr = + _lookup>('watch_time_delete'); + late final _dart_watch_time_delete _watch_time_delete = + _watch_time_delete_ptr.asFunction<_dart_watch_time_delete>(); + + /// @brief Gets the year info. + /// @since_tizen 2.3.1 + /// @param[in] watch_time The watch_time handle + /// @param[out] year The year info + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_get_year( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer year, + ) { + return _watch_time_get_year( + watch_time, + year, + ); + } + + late final _watch_time_get_year_ptr = + _lookup>( + 'watch_time_get_year'); + late final _dart_watch_time_get_year _watch_time_get_year = + _watch_time_get_year_ptr.asFunction<_dart_watch_time_get_year>(); + + /// @brief Gets the month info. + /// @since_tizen 2.3.1 + /// @param[in] watch_time The watch_time handle + /// @param[out] month The month info + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_get_month( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer month, + ) { + return _watch_time_get_month( + watch_time, + month, + ); + } + + late final _watch_time_get_month_ptr = + _lookup>( + 'watch_time_get_month'); + late final _dart_watch_time_get_month _watch_time_get_month = + _watch_time_get_month_ptr.asFunction<_dart_watch_time_get_month>(); + + /// @brief Gets the day info. + /// @since_tizen 2.3.1 + /// @param[in] watch_time The watch_time handle + /// @param[out] day The day info + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_get_day( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer day, + ) { + return _watch_time_get_day( + watch_time, + day, + ); + } + + late final _watch_time_get_day_ptr = + _lookup>('watch_time_get_day'); + late final _dart_watch_time_get_day _watch_time_get_day = + _watch_time_get_day_ptr.asFunction<_dart_watch_time_get_day>(); + + /// @brief Gets the day of week info. + /// @since_tizen 2.3.1 + /// @param[in] watch_time The watch_time handle + /// @param[out] day_of_week The day of week info. The value returns from 1 (Sunday) to 7 (Saturday). + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_get_day_of_week( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer day_of_week, + ) { + return _watch_time_get_day_of_week( + watch_time, + day_of_week, + ); + } + + late final _watch_time_get_day_of_week_ptr = + _lookup>( + 'watch_time_get_day_of_week'); + late final _dart_watch_time_get_day_of_week _watch_time_get_day_of_week = + _watch_time_get_day_of_week_ptr + .asFunction<_dart_watch_time_get_day_of_week>(); + + /// @brief Gets the hour info. + /// @since_tizen 2.3.1 + /// @param[in] watch_time The watch_time handle + /// @param[out] hour The hour info + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_get_hour( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer hour, + ) { + return _watch_time_get_hour( + watch_time, + hour, + ); + } + + late final _watch_time_get_hour_ptr = + _lookup>( + 'watch_time_get_hour'); + late final _dart_watch_time_get_hour _watch_time_get_hour = + _watch_time_get_hour_ptr.asFunction<_dart_watch_time_get_hour>(); + + /// @brief Gets the hour info in 24-hour presentation. + /// @since_tizen 2.3.1 + /// @param[in] watch_time The watch_time handle + /// @param[out] hour24 The hour info + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_get_hour24( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer hour24, + ) { + return _watch_time_get_hour24( + watch_time, + hour24, + ); + } + + late final _watch_time_get_hour24_ptr = + _lookup>( + 'watch_time_get_hour24'); + late final _dart_watch_time_get_hour24 _watch_time_get_hour24 = + _watch_time_get_hour24_ptr.asFunction<_dart_watch_time_get_hour24>(); + + /// @brief Gets the minute info. + /// @since_tizen 2.3.1 + /// @param[in] watch_time The watch_time handle + /// @param[out] minute The minute info + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_get_minute( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer minute, + ) { + return _watch_time_get_minute( + watch_time, + minute, + ); + } + + late final _watch_time_get_minute_ptr = + _lookup>( + 'watch_time_get_minute'); + late final _dart_watch_time_get_minute _watch_time_get_minute = + _watch_time_get_minute_ptr.asFunction<_dart_watch_time_get_minute>(); + + /// @brief Gets the second info. + /// @since_tizen 2.3.1 + /// @param[in] watch_time The watch_time handle + /// @param[out] second The second info + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_get_second( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer second, + ) { + return _watch_time_get_second( + watch_time, + second, + ); + } + + late final _watch_time_get_second_ptr = + _lookup>( + 'watch_time_get_second'); + late final _dart_watch_time_get_second _watch_time_get_second = + _watch_time_get_second_ptr.asFunction<_dart_watch_time_get_second>(); + + /// @brief Gets the millisecond info. + /// @since_tizen 2.3.1 + /// @param[in] watch_time The watch_time handle + /// @param[out] millisecond The millisecond info + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_get_millisecond( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer millisecond, + ) { + return _watch_time_get_millisecond( + watch_time, + millisecond, + ); + } + + late final _watch_time_get_millisecond_ptr = + _lookup>( + 'watch_time_get_millisecond'); + late final _dart_watch_time_get_millisecond _watch_time_get_millisecond = + _watch_time_get_millisecond_ptr + .asFunction<_dart_watch_time_get_millisecond>(); + + /// @brief Gets the UTC time. + /// @since_tizen 2.3.1 + /// @param[in] watch_time The watch_time handle + /// @param[out] utc_time The UTC time + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_get_utc_time( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer utc_time, + ) { + return _watch_time_get_utc_time( + watch_time, + utc_time, + ); + } + + late final _watch_time_get_utc_time_ptr = + _lookup>( + 'watch_time_get_utc_time'); + late final _dart_watch_time_get_utc_time _watch_time_get_utc_time = + _watch_time_get_utc_time_ptr.asFunction<_dart_watch_time_get_utc_time>(); + + /// @brief Gets the UTC timestamp. + /// @since_tizen 2.3.1 + /// @param[in] watch_time The watch_time handle + /// @param[out] utc_timestamp The UTC timestamp + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_get_utc_timestamp( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer utc_timestamp, + ) { + return _watch_time_get_utc_timestamp( + watch_time, + utc_timestamp, + ); + } + + late final _watch_time_get_utc_timestamp_ptr = + _lookup>( + 'watch_time_get_utc_timestamp'); + late final _dart_watch_time_get_utc_timestamp _watch_time_get_utc_timestamp = + _watch_time_get_utc_timestamp_ptr + .asFunction<_dart_watch_time_get_utc_timestamp>(); + + /// @brief Gets the ID of timezone for the @a watch_time handle. + /// @since_tizen 2.3.1 + /// @remarks You must release @a time_zone_id using free() after using it. + /// @param[in] watch_time The watch_time handle + /// @param[out] time_zone_id The Timezone ID, such as "America/Los_Angeles" + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_get_time_zone( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer> time_zone_id, + ) { + return _watch_time_get_time_zone( + watch_time, + time_zone_id, + ); + } + + late final _watch_time_get_time_zone_ptr = + _lookup>( + 'watch_time_get_time_zone'); + late final _dart_watch_time_get_time_zone _watch_time_get_time_zone = + _watch_time_get_time_zone_ptr + .asFunction<_dart_watch_time_get_time_zone>(); + + /// @brief Gets the daylight saving time status. + /// @since_tizen 4.0 + /// @param[in] watch_time The watch_time handle + /// @param[out] status The daylight saving time status; + /// @c true if DST is in effect, @c false otherwise + /// @return 0 on success, otherwise a negative error value + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_time_get_dst_status( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer status, + ) { + return _watch_time_get_dst_status( + watch_time, + status, + ); + } + + late final _watch_time_get_dst_status_ptr = + _lookup>( + 'watch_time_get_dst_status'); + late final _dart_watch_time_get_dst_status _watch_time_get_dst_status = + _watch_time_get_dst_status_ptr + .asFunction<_dart_watch_time_get_dst_status>(); + + /// @brief Gets Evas_Object for a Elementary window of watch application. You must use this window to draw watch UI on the idle screen. + /// @since_tizen 2.3.1 + /// @param[out] win The pointer of Evas_Object for a Elementary window. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #APP_ERROR_INVALID_PARAMETER Invalid Parameter + /// @retval #APP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #APP_ERROR_INVALID_CONTEXT Watch app is not initialized properly + /// @retval #APP_ERROR_NONE Successful + /// @retval #APP_ERROR_NOT_SUPPORTED Not supported + int watch_app_get_elm_win( + ffi.Pointer> win, + ) { + return _watch_app_get_elm_win( + win, + ); + } + + late final _watch_app_get_elm_win_ptr = + _lookup>( + 'watch_app_get_elm_win'); + late final _dart_watch_app_get_elm_win _watch_app_get_elm_win = + _watch_app_get_elm_win_ptr.asFunction<_dart_watch_app_get_elm_win>(); + + /// @brief Initializes the widget system. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @param[in] win Window object + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #WIDGET_ERROR_NONE If success + /// @retval #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #WIDGET_ERROR_ALREADY_EXIST Already initialized + /// @retval #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @see #widget_viewer_evas_fini + int widget_viewer_evas_init( + ffi.Pointer win, + ) { + return _widget_viewer_evas_init( + win, + ); + } + + late final _widget_viewer_evas_init_ptr = + _lookup>( + 'widget_viewer_evas_init'); + late final _dart_widget_viewer_evas_init _widget_viewer_evas_init = + _widget_viewer_evas_init_ptr.asFunction<_dart_widget_viewer_evas_init>(); + + /// @brief Finalizes the widget system. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #WIDGET_ERROR_NONE If success + /// @retval #WIDGET_ERROR_FAULT Unrecoverable error occurred + /// @retval #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @see #widget_viewer_evas_init + int widget_viewer_evas_fini() { + return _widget_viewer_evas_fini(); + } + + late final _widget_viewer_evas_fini_ptr = + _lookup>( + 'widget_viewer_evas_fini'); + late final _dart_widget_viewer_evas_fini _widget_viewer_evas_fini = + _widget_viewer_evas_fini_ptr.asFunction<_dart_widget_viewer_evas_fini>(); + + /// @brief Creates a new widget object. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] parent Evas Object of parent + /// @param[in] widget_id Widget id + /// @param[in] content_info Contents that will be given to the widget instance. This value is result of bundle_encode. + /// @param[in] period Update period (@c WIDGET_VIEWER_EVAS_DEFAULT_PERIOD can be used for this; this argument will be used to specify the period of updating contents of a widget) + /// @return Widget Object. NULL on error + /// @exception #WIDGET_ERROR_NONE Successfully added + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @exception #WIDGET_ERROR_FAULT Failed to create instance + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @exception #WIDGET_ERROR_MAX_EXCEEDED Maximum number of instances exceeded + /// @see get_last_result() + /// @see #widget_service_get_widget_id + ffi.Pointer widget_viewer_evas_add_widget( + ffi.Pointer parent, + ffi.Pointer widget_id, + ffi.Pointer content_info, + double period, + ) { + return _widget_viewer_evas_add_widget( + parent, + widget_id, + content_info, + period, + ); + } + + late final _widget_viewer_evas_add_widget_ptr = + _lookup>( + 'widget_viewer_evas_add_widget'); + late final _dart_widget_viewer_evas_add_widget + _widget_viewer_evas_add_widget = _widget_viewer_evas_add_widget_ptr + .asFunction<_dart_widget_viewer_evas_add_widget>(); + + /// @brief Notifies the status of the viewer to all providers. + /// @details If you call this, all providers will gets "resumed" event. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #WIDGET_ERROR_NONE If success + /// @retval #WIDGET_ERROR_FAULT If it failed to send state (paused) info + /// @retval #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @see widget_viewer_evas_notify_paused_status_of_viewer() + int widget_viewer_evas_notify_resumed_status_of_viewer() { + return _widget_viewer_evas_notify_resumed_status_of_viewer(); + } + + late final _widget_viewer_evas_notify_resumed_status_of_viewer_ptr = _lookup< + ffi.NativeFunction< + _c_widget_viewer_evas_notify_resumed_status_of_viewer>>( + 'widget_viewer_evas_notify_resumed_status_of_viewer'); + late final _dart_widget_viewer_evas_notify_resumed_status_of_viewer + _widget_viewer_evas_notify_resumed_status_of_viewer = + _widget_viewer_evas_notify_resumed_status_of_viewer_ptr.asFunction< + _dart_widget_viewer_evas_notify_resumed_status_of_viewer>(); + + /// @brief Notifies the status of the viewer to all providers. + /// @details If you call this, all providers will gets "paused" event. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #WIDGET_ERROR_NONE If success + /// @retval #WIDGET_ERROR_FAULT If it failed to send state (resumed) info + /// @retval #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @see widget_viewer_evas_notify_resumed_status_of_viewer() + int widget_viewer_evas_notify_paused_status_of_viewer() { + return _widget_viewer_evas_notify_paused_status_of_viewer(); + } + + late final _widget_viewer_evas_notify_paused_status_of_viewer_ptr = _lookup< + ffi.NativeFunction< + _c_widget_viewer_evas_notify_paused_status_of_viewer>>( + 'widget_viewer_evas_notify_paused_status_of_viewer'); + late final _dart_widget_viewer_evas_notify_paused_status_of_viewer + _widget_viewer_evas_notify_paused_status_of_viewer = + _widget_viewer_evas_notify_paused_status_of_viewer_ptr.asFunction< + _dart_widget_viewer_evas_notify_paused_status_of_viewer>(); + + /// @brief Notifies the orientation of the viewer to all providers. + /// @details If you call this, all providers will gets "rotated" event. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @param[in] orientation Orientation of viewer + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #WIDGET_ERROR_NONE If success + /// @retval #WIDGET_ERROR_FAULT If it failed to send state (resumed) info + /// @retval #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIDGET_ERROR_NOT_SUPPORTED Not supported + int widget_viewer_evas_notify_orientation_of_viewer( + int orientation, + ) { + return _widget_viewer_evas_notify_orientation_of_viewer( + orientation, + ); + } + + late final _widget_viewer_evas_notify_orientation_of_viewer_ptr = _lookup< + ffi.NativeFunction< + _c_widget_viewer_evas_notify_orientation_of_viewer>>( + 'widget_viewer_evas_notify_orientation_of_viewer'); + late final _dart_widget_viewer_evas_notify_orientation_of_viewer + _widget_viewer_evas_notify_orientation_of_viewer = + _widget_viewer_evas_notify_orientation_of_viewer_ptr + .asFunction<_dart_widget_viewer_evas_notify_orientation_of_viewer>(); + + /// @brief Pauses given widget. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @param[in] widget A widget object + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #WIDGET_ERROR_NONE If success + /// @retval #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIDGET_ERROR_FAULT If it failed to send state (resumed) info + /// @retval #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @retval #WIDGET_ERROR_DISABLED Widget is frozen by widget_viewer_evas_freeze_visibility() + /// @see widget_viewer_evas_freeze_visibility() + int widget_viewer_evas_pause_widget( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_pause_widget( + widget, + ); + } + + late final _widget_viewer_evas_pause_widget_ptr = + _lookup>( + 'widget_viewer_evas_pause_widget'); + late final _dart_widget_viewer_evas_pause_widget + _widget_viewer_evas_pause_widget = _widget_viewer_evas_pause_widget_ptr + .asFunction<_dart_widget_viewer_evas_pause_widget>(); + + /// @brief Resumes given widget. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @param[in] widget a widget object + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #WIDGET_ERROR_NONE If success + /// @retval #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #WIDGET_ERROR_FAULT If it failed to send state (resumed) info + /// @retval #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @retval #WIDGET_ERROR_DISABLED Widget is frozen by widget_viewer_evas_freeze_visibility() + /// @see widget_viewer_evas_freeze_visibility() + int widget_viewer_evas_resume_widget( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_resume_widget( + widget, + ); + } + + late final _widget_viewer_evas_resume_widget_ptr = + _lookup>( + 'widget_viewer_evas_resume_widget'); + late final _dart_widget_viewer_evas_resume_widget + _widget_viewer_evas_resume_widget = _widget_viewer_evas_resume_widget_ptr + .asFunction<_dart_widget_viewer_evas_resume_widget>(); + + /// @brief Changes the configurable values of widget system. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @param[in] type Configuration item + /// @param[in] value Its value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #WIDGET_ERROR_NONE If success + /// @retval #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @see #widget_evas_conf + int widget_viewer_evas_set_option( + int type, + int value, + ) { + return _widget_viewer_evas_set_option( + type, + value, + ); + } + + late final _widget_viewer_evas_set_option_ptr = + _lookup>( + 'widget_viewer_evas_set_option'); + late final _dart_widget_viewer_evas_set_option + _widget_viewer_evas_set_option = _widget_viewer_evas_set_option_ptr + .asFunction<_dart_widget_viewer_evas_set_option>(); + + /// @brief Gets content string of widget. + /// @details This string can be used for creating contents of widget again after rebooting a device or it can be recovered from crash(abnormal status). + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @remarks Returned string should not be freed. + /// @remarks The returned string is usable only before the widget is destroyed. If it's going to be needed after that, it should be copied. + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] widget A widget object + /// @return Content string to be recognized content of the widget. This value is result of bundle_encode. + /// @retval NULL if there is no specific content string + /// @exception #WIDGET_ERROR_NONE Successfully get content string + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @exception #WIDGET_ERROR_FAULT Not initialized + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @post Returned string should not be freed. + /// @see get_last_result() + ffi.Pointer widget_viewer_evas_get_content_info( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_get_content_info( + widget, + ); + } + + late final _widget_viewer_evas_get_content_info_ptr = + _lookup>( + 'widget_viewer_evas_get_content_info'); + late final _dart_widget_viewer_evas_get_content_info + _widget_viewer_evas_get_content_info = + _widget_viewer_evas_get_content_info_ptr + .asFunction<_dart_widget_viewer_evas_get_content_info>(); + + /// @brief Gets summarized string of the widget content for accessibility. + /// @details If the accessibility feature is turned On, a viewer can use this text to describe the widget. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @remarks Returned string should not be freed. + /// @remarks The returned string is usable only before the widget is destroyed. If it's going to be needed after that, it should be copied. + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] widget A widget object + /// @return Title string to be used for summarizing the widget + /// @retval NULL if there is no summarized text for content of given widget + /// @exception #WIDGET_ERROR_NONE Successfully get title string + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @exception #WIDGET_ERROR_FAULT Not initialized + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @see get_last_result() + ffi.Pointer widget_viewer_evas_get_title_string( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_get_title_string( + widget, + ); + } + + late final _widget_viewer_evas_get_title_string_ptr = + _lookup>( + 'widget_viewer_evas_get_title_string'); + late final _dart_widget_viewer_evas_get_title_string + _widget_viewer_evas_get_title_string = + _widget_viewer_evas_get_title_string_ptr + .asFunction<_dart_widget_viewer_evas_get_title_string>(); + + /// @brief Gets the ID of the widget. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @remarks Returned string should not be freed. + /// @remarks The returned string is usable only before the widget is destroyed. If it's going to be needed after that, it should be copied. + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] widget A widget object + /// @return Widget ID + /// @retval NULL if an error occurred and you can get the reason of failure using get_last_result() + /// @exception #WIDGET_ERROR_NONE Successfully get widget ID + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_FAULT Not initialized + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @see get_last_result() + ffi.Pointer widget_viewer_evas_get_widget_id( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_get_widget_id( + widget, + ); + } + + late final _widget_viewer_evas_get_widget_id_ptr = + _lookup>( + 'widget_viewer_evas_get_widget_id'); + late final _dart_widget_viewer_evas_get_widget_id + _widget_viewer_evas_get_widget_id = _widget_viewer_evas_get_widget_id_ptr + .asFunction<_dart_widget_viewer_evas_get_widget_id>(); + + /// @brief Gets the update period of the widget. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] widget A widget object + /// @return Period the update period of the widget. + /// @retval The update interval of the widget + /// @exception #WIDGET_ERROR_NONE Successfully get period + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @exception #WIDGET_ERROR_FAULT Not initialized + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @see get_last_result() + double widget_viewer_evas_get_period( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_get_period( + widget, + ); + } + + late final _widget_viewer_evas_get_period_ptr = + _lookup>( + 'widget_viewer_evas_get_period'); + late final _dart_widget_viewer_evas_get_period + _widget_viewer_evas_get_period = _widget_viewer_evas_get_period_ptr + .asFunction<_dart_widget_viewer_evas_get_period>(); + + /// @brief Cancels click event procedure. + /// @details If you call this function after feeding the mouse_down(or mouse_set) event, the widget will get ON_HOLD events.\n + /// If a widget gets ON_HOLD event, it will not do anything even if you feed mouse_up(or mouse_unset) event.\n + /// @since_tizen 2.3.1 + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @param[in] widget A widget object + /// @exception #WIDGET_ERROR_NONE Successfully get period + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @exception #WIDGET_ERROR_FAULT Not initialized + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @see get_last_result() + void widget_viewer_evas_cancel_click_event( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_cancel_click_event( + widget, + ); + } + + late final _widget_viewer_evas_cancel_click_event_ptr = + _lookup>( + 'widget_viewer_evas_cancel_click_event'); + late final _dart_widget_viewer_evas_cancel_click_event + _widget_viewer_evas_cancel_click_event = + _widget_viewer_evas_cancel_click_event_ptr + .asFunction<_dart_widget_viewer_evas_cancel_click_event>(); + + /// @brief Hides the preview of the widget. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @remarks This function should be called right after creating the widget object before resizing it. + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] widget A widget object + /// @exception #WIDGET_ERROR_NONE Successfully disabled preview + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @exception #WIDGET_ERROR_FAULT Not initialized + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @see get_last_result() + void widget_viewer_evas_disable_preview( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_disable_preview( + widget, + ); + } + + late final _widget_viewer_evas_disable_preview_ptr = + _lookup>( + 'widget_viewer_evas_disable_preview'); + late final _dart_widget_viewer_evas_disable_preview + _widget_viewer_evas_disable_preview = + _widget_viewer_evas_disable_preview_ptr + .asFunction<_dart_widget_viewer_evas_disable_preview>(); + + /// @brief Hides the help text of the widget. + /// @details While loading a box, hide the help text. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @remarks This function should be called right after creating the widget object before resizing it. + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] widget A widget object + /// @exception #WIDGET_ERROR_NONE Successfully disabled overlay text + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @exception #WIDGET_ERROR_FAULT Not initialized + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @see get_last_result() + void widget_viewer_evas_disable_overlay_text( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_disable_overlay_text( + widget, + ); + } + + late final _widget_viewer_evas_disable_overlay_text_ptr = + _lookup>( + 'widget_viewer_evas_disable_overlay_text'); + late final _dart_widget_viewer_evas_disable_overlay_text + _widget_viewer_evas_disable_overlay_text = + _widget_viewer_evas_disable_overlay_text_ptr + .asFunction<_dart_widget_viewer_evas_disable_overlay_text>(); + + /// @brief Hides the loading message of the widget. + /// @details If you disable it, there is no preview & help text while creating a widget object. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @remarks This function should be called right after creating the widget object before resizing it. + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] widget A widget object + /// @exception #WIDGET_ERROR_NONE Successfully disabled loading text + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @exception #WIDGET_ERROR_FAULT Not initialized + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @see get_last_result() + void widget_viewer_evas_disable_loading( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_disable_loading( + widget, + ); + } + + late final _widget_viewer_evas_disable_loading_ptr = + _lookup>( + 'widget_viewer_evas_disable_loading'); + late final _dart_widget_viewer_evas_disable_loading + _widget_viewer_evas_disable_loading = + _widget_viewer_evas_disable_loading_ptr + .asFunction<_dart_widget_viewer_evas_disable_loading>(); + + /// @brief Feeds the mouse_up event to the provider of the widget + /// @details This is very similar with widget_viewer_evas_cancel_click(), but this will sends mouse_up event explicitly.\n + /// Also feed the ON_HOLD event before feeds mouse_up event. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @param[in] widget a widget object + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #WIDGET_ERROR_NONE if success + /// @retval #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #WIDGET_ERROR_FAULT Not initialized + /// @retval #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @retval #WIDGET_ERROR_PERMISSION_DENIED Permission denied + int widget_viewer_evas_feed_mouse_up_event( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_feed_mouse_up_event( + widget, + ); + } + + late final _widget_viewer_evas_feed_mouse_up_event_ptr = + _lookup>( + 'widget_viewer_evas_feed_mouse_up_event'); + late final _dart_widget_viewer_evas_feed_mouse_up_event + _widget_viewer_evas_feed_mouse_up_event = + _widget_viewer_evas_feed_mouse_up_event_ptr + .asFunction<_dart_widget_viewer_evas_feed_mouse_up_event>(); + + /// @brief Activate a widget in faulted state. + /// @details A widget in faulted state MUST be activated before adding the widget. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] widget A widget object faulted + /// @exception #WIDGET_ERROR_NONE Successfully activate faulted widget + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @exception #WIDGET_ERROR_FAULT Not initialized + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @see get_last_result() + void widget_viewer_evas_activate_faulted_widget( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_activate_faulted_widget( + widget, + ); + } + + late final _widget_viewer_evas_activate_faulted_widget_ptr = _lookup< + ffi.NativeFunction<_c_widget_viewer_evas_activate_faulted_widget>>( + 'widget_viewer_evas_activate_faulted_widget'); + late final _dart_widget_viewer_evas_activate_faulted_widget + _widget_viewer_evas_activate_faulted_widget = + _widget_viewer_evas_activate_faulted_widget_ptr + .asFunction<_dart_widget_viewer_evas_activate_faulted_widget>(); + + /// @brief Checks whether the widget is faulted. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] widget A widget object + /// @return Faulted state of the widget and you can get the result state of this function by using get_last_result() + /// @retval True for faulted state + /// @retval False for not faulted state + /// @exception #WIDGET_ERROR_NONE Successfully get the faulted state of the widget + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @exception #WIDGET_ERROR_FAULT Not initialized + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @see get_last_result() + bool widget_viewer_evas_is_faulted( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_is_faulted( + widget, + ) != + 0; + } + + late final _widget_viewer_evas_is_faulted_ptr = + _lookup>( + 'widget_viewer_evas_is_faulted'); + late final _dart_widget_viewer_evas_is_faulted + _widget_viewer_evas_is_faulted = _widget_viewer_evas_is_faulted_ptr + .asFunction<_dart_widget_viewer_evas_is_faulted>(); + + /// @brief Freezes visibility of the widget. + /// @details If you don't want to change the visibility automatically, freeze it.\n + /// The visibility will not be changed even though a box disappeared(hidden)/displayed(shown) from/on the screen. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @param[in] widget A widget object + /// @param[in] status A visibility status of the widget + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #WIDGET_ERROR_NONE If success + /// @retval #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #WIDGET_ERROR_FAULT Not initialized + /// @retval #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @retval #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @see #widget_visibility_status_e + int widget_viewer_evas_freeze_visibility( + ffi.Pointer widget, + int status, + ) { + return _widget_viewer_evas_freeze_visibility( + widget, + status, + ); + } + + late final _widget_viewer_evas_freeze_visibility_ptr = + _lookup>( + 'widget_viewer_evas_freeze_visibility'); + late final _dart_widget_viewer_evas_freeze_visibility + _widget_viewer_evas_freeze_visibility = + _widget_viewer_evas_freeze_visibility_ptr + .asFunction<_dart_widget_viewer_evas_freeze_visibility>(); + + /// @brief Thaws visibility of the widget. + /// @details If you want to let the visibility change automatically again, call this function. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @param[in] widget A widget object + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #WIDGET_ERROR_NONE If success + /// @retval #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #WIDGET_ERROR_FAULT Not initialized + /// @retval #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @retval #WIDGET_ERROR_PERMISSION_DENIED Permission denied + int widget_viewer_evas_thaw_visibility( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_thaw_visibility( + widget, + ); + } + + late final _widget_viewer_evas_thaw_visibility_ptr = + _lookup>( + 'widget_viewer_evas_thaw_visibility'); + late final _dart_widget_viewer_evas_thaw_visibility + _widget_viewer_evas_thaw_visibility = + _widget_viewer_evas_thaw_visibility_ptr + .asFunction<_dart_widget_viewer_evas_thaw_visibility>(); + + /// @brief Gets the frozen state of visibility option. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] widget A widget object + /// @return Fixed state of visibility and you can get the result state of this function by using get_last_result() + /// @retval True for frozen state + /// @retval False for not frozen state + /// @exception #WIDGET_ERROR_NONE Successfully get the state of visibility + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @exception #WIDGET_ERROR_FAULT Not initialized + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @see get_last_result() + bool widget_viewer_evas_is_visibility_frozen( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_is_visibility_frozen( + widget, + ) != + 0; + } + + late final _widget_viewer_evas_is_visibility_frozen_ptr = + _lookup>( + 'widget_viewer_evas_is_visibility_frozen'); + late final _dart_widget_viewer_evas_is_visibility_frozen + _widget_viewer_evas_is_visibility_frozen = + _widget_viewer_evas_is_visibility_frozen_ptr + .asFunction<_dart_widget_viewer_evas_is_visibility_frozen>(); + + /// @brief Validate the object, whether it is a widget object or not. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] widget A widget object + /// @return Result of validation and you can get the result state of this function by using get_last_result() + /// @retval True this is a widget + /// @retval False this is not a widget + /// @exception #WIDGET_ERROR_NONE Successfully get result of validation + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @exception #WIDGET_ERROR_FAULT Not initialized + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @see get_last_result() + bool widget_viewer_evas_is_widget( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_is_widget( + widget, + ) != + 0; + } + + late final _widget_viewer_evas_is_widget_ptr = + _lookup>( + 'widget_viewer_evas_is_widget'); + late final _dart_widget_viewer_evas_is_widget _widget_viewer_evas_is_widget = + _widget_viewer_evas_is_widget_ptr + .asFunction<_dart_widget_viewer_evas_is_widget>(); + + /// @brief Before deleting a widget, set the deletion mode. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] widget A widget object which will be deleted soon + /// @param[in] flag Pass 1 if you delete this widget instance permanently, or pass 0 if you want to keep it and it will be re-created soon + /// @exception #WIDGET_ERROR_NONE Successfully set the flag + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @exception #WIDGET_ERROR_FAULT Not initialized + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @see get_last_result() + void widget_viewer_evas_set_permanent_delete( + ffi.Pointer widget, + int flag, + ) { + return _widget_viewer_evas_set_permanent_delete( + widget, + flag, + ); + } + + late final _widget_viewer_evas_set_permanent_delete_ptr = + _lookup>( + 'widget_viewer_evas_set_permanent_delete'); + late final _dart_widget_viewer_evas_set_permanent_delete + _widget_viewer_evas_set_permanent_delete = + _widget_viewer_evas_set_permanent_delete_ptr + .asFunction<_dart_widget_viewer_evas_set_permanent_delete>(); + + /// @brief Gets the widget object's instance ID. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/widget.viewer + /// @remarks The returned instance ID should not be freed. + /// @remarks The returned widget instance ID is volatile. If the device reboots or the widget's process restarts, it will be changed.\n + /// So, you should not assume this value is a persistent one. + /// @remarks The returned string is usable only before the widget is destroyed. If it's going to be needed after that, it should be copied. + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] widget A widget object + /// @return The widget's instance ID as a string, NULL in case of errors + /// @exception #WIDGET_ERROR_NONE Successfully retrieved the widget instance ID + /// @exception #WIDGET_ERROR_NOT_SUPPORTED Not supported + /// @exception #WIDGET_ERROR_FAULT Widget is not ready + /// @exception #WIDGET_ERROR_PERMISSION_DENIED Permission denied + /// @exception #WIDGET_ERROR_INVALID_PARAMETER Invalid argument + /// @see get_last_result() + ffi.Pointer widget_viewer_evas_get_widget_instance_id( + ffi.Pointer widget, + ) { + return _widget_viewer_evas_get_widget_instance_id( + widget, + ); + } + + late final _widget_viewer_evas_get_widget_instance_id_ptr = + _lookup>( + 'widget_viewer_evas_get_widget_instance_id'); + late final _dart_widget_viewer_evas_get_widget_instance_id + _widget_viewer_evas_get_widget_instance_id = + _widget_viewer_evas_get_widget_instance_id_ptr + .asFunction<_dart_widget_viewer_evas_get_widget_instance_id>(); + + /// @brief Gets the MIME type for the given file extension. + /// + /// @remarks The @a mime_type must be released with free() by you. + /// @param[in] file_extension The file extension without the leading dot ('.') + /// @param[out] mime_type The MIME type for the given file extension \n + /// The MIME type is 'application/octet-stream' if the given file extension is not associated with specific file formats + /// @return 0 on success, otherwise a negative error value. + /// @retval #MIME_TYPE_ERROR_NONE Successful + /// @retval #MIME_TYPE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MIME_TYPE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MIME_TYPE_ERROR_IO_ERROR Internal I/O error + /// @see mime_type_get_file_extension() + int mime_type_get_mime_type( + ffi.Pointer file_extension, + ffi.Pointer> mime_type, + ) { + return _mime_type_get_mime_type( + file_extension, + mime_type, + ); + } + + late final _mime_type_get_mime_type_ptr = + _lookup>( + 'mime_type_get_mime_type'); + late final _dart_mime_type_get_mime_type _mime_type_get_mime_type = + _mime_type_get_mime_type_ptr.asFunction<_dart_mime_type_get_mime_type>(); + + /// @brief Gets the file extensions for the given MIME type. + /// + /// @remarks The @a file_extension must be released with free() by you. + /// @param[in] mime_type The MIME type + /// @param[out] file_extension The array of file extension without the leading dot ('.') + /// @param[out] length The length of the array of file extension or zero if there is none + /// @return 0 on success, otherwise a negative error value. + /// @retval #MIME_TYPE_ERROR_NONE Successful + /// @retval #MIME_TYPE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MIME_TYPE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MIME_TYPE_ERROR_IO_ERROR Internal I/O error + /// @see mime_type_get_mime_type() + int mime_type_get_file_extension( + ffi.Pointer mime_type, + ffi.Pointer>> file_extension, + ffi.Pointer length, + ) { + return _mime_type_get_file_extension( + mime_type, + file_extension, + length, + ); + } + + late final _mime_type_get_file_extension_ptr = + _lookup>( + 'mime_type_get_file_extension'); + late final _dart_mime_type_get_file_extension _mime_type_get_file_extension = + _mime_type_get_file_extension_ptr + .asFunction<_dart_mime_type_get_file_extension>(); + + /// @brief Gets the MIME type for the given data. + /// + /// @since_tizen 4.0 + /// @remarks The @a mime_type must be released with free() by you. + /// @param[in] data The stream of file data + /// @param[in] len The length of data + /// @param[out] mime_type The MIME type for the given file extension \n + /// The MIME type is 'application/octet-stream' if the given file extension is not associated with specific file formats + /// @return 0 on success, otherwise a negative error value. + /// @retval #MIME_TYPE_ERROR_NONE Successful + /// @retval #MIME_TYPE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MIME_TYPE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MIME_TYPE_ERROR_IO_ERROR Internal I/O error + int mime_type_get_mime_type_for_data( + ffi.Pointer data, + int len, + ffi.Pointer> mime_type, + ) { + return _mime_type_get_mime_type_for_data( + data, + len, + mime_type, + ); + } + + late final _mime_type_get_mime_type_for_data_ptr = + _lookup>( + 'mime_type_get_mime_type_for_data'); + late final _dart_mime_type_get_mime_type_for_data + _mime_type_get_mime_type_for_data = _mime_type_get_mime_type_for_data_ptr + .asFunction<_dart_mime_type_get_mime_type_for_data>(); + + /// @brief Gets the MIME type for the given file path. + /// + /// @since_tizen 4.0 + /// @remarks The @a mime_type must be released with free() by you. + /// @remarks http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage. + /// @remarks http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. + /// @param[in] file_path The path of target file + /// @param[out] mime_type The MIME type for the given file extension \n + /// The MIME type is 'application/octet-stream' if the given file extension is not associated with specific file formats + /// @return 0 on success, otherwise a negative error value. + /// @retval #MIME_TYPE_ERROR_NONE Successful + /// @retval #MIME_TYPE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MIME_TYPE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MIME_TYPE_ERROR_IO_ERROR Internal I/O error + /// @retval #MIME_TYPE_ERROR_PERMISSION_DENIED Permission denied + int mime_type_get_mime_type_for_file( + ffi.Pointer file_path, + ffi.Pointer> mime_type, + ) { + return _mime_type_get_mime_type_for_file( + file_path, + mime_type, + ); + } + + late final _mime_type_get_mime_type_for_file_ptr = + _lookup>( + 'mime_type_get_mime_type_for_file'); + late final _dart_mime_type_get_mime_type_for_file + _mime_type_get_mime_type_for_file = _mime_type_get_mime_type_for_file_ptr + .asFunction<_dart_mime_type_get_mime_type_for_file>(); + + /// @brief Clones the audio metadata. + /// @details This function copies the audio metadata handle from a source to destination. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a dst should be released using audio_meta_destroy(). + /// + /// @param[out] dst The destination handle to the audio metadata + /// @param[in] src The source handle to the audio metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see audio_meta_destroy() + int audio_meta_clone( + ffi.Pointer> dst, + ffi.Pointer src, + ) { + return _audio_meta_clone( + dst, + src, + ); + } + + late final _audio_meta_clone_ptr = + _lookup>('audio_meta_clone'); + late final _dart_audio_meta_clone _audio_meta_clone = + _audio_meta_clone_ptr.asFunction<_dart_audio_meta_clone>(); + + /// @brief Destroys the audio metadata. + /// @details This function frees all resources related to the audio metadata handle. This handle + /// no longer can be used to perform any operation. A new handle has to + /// be created before the next use. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] audio The handle to the audio metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre Get a copy of audio metadata handle handle by calling audio_meta_clone(). + /// + /// @see audio_meta_clone() + int audio_meta_destroy( + ffi.Pointer audio, + ) { + return _audio_meta_destroy( + audio, + ); + } + + late final _audio_meta_destroy_ptr = + _lookup>('audio_meta_destroy'); + late final _dart_audio_meta_destroy _audio_meta_destroy = + _audio_meta_destroy_ptr.asFunction<_dart_audio_meta_destroy>(); + + /// @brief Gets the ID of the media of the given audio metadata. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a media_id should be released using free(). + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] media_id The media ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int audio_meta_get_media_id( + ffi.Pointer audio, + ffi.Pointer> media_id, + ) { + return _audio_meta_get_media_id( + audio, + media_id, + ); + } + + late final _audio_meta_get_media_id_ptr = + _lookup>( + 'audio_meta_get_media_id'); + late final _dart_audio_meta_get_media_id _audio_meta_get_media_id = + _audio_meta_get_media_id_ptr.asFunction<_dart_audio_meta_get_media_id>(); + + /// @brief Gets the album of the given audio metadata. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no album info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a album should be released using free(). + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] album The album of the audio metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int audio_meta_get_album( + ffi.Pointer audio, + ffi.Pointer> album, + ) { + return _audio_meta_get_album( + audio, + album, + ); + } + + late final _audio_meta_get_album_ptr = + _lookup>( + 'audio_meta_get_album'); + late final _dart_audio_meta_get_album _audio_meta_get_album = + _audio_meta_get_album_ptr.asFunction<_dart_audio_meta_get_album>(); + + /// @brief Gets the artist of the given audio metadata. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no artist info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a artist should be released using free(). + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] artist The artist of the audio metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int audio_meta_get_artist( + ffi.Pointer audio, + ffi.Pointer> artist, + ) { + return _audio_meta_get_artist( + audio, + artist, + ); + } + + late final _audio_meta_get_artist_ptr = + _lookup>( + 'audio_meta_get_artist'); + late final _dart_audio_meta_get_artist _audio_meta_get_artist = + _audio_meta_get_artist_ptr.asFunction<_dart_audio_meta_get_artist>(); + + /// @brief Gets the album artist of the given audio metadata. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no album artist info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a album_artist should be released using free(). + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] album_artist The album artist of the audio metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int audio_meta_get_album_artist( + ffi.Pointer audio, + ffi.Pointer> album_artist, + ) { + return _audio_meta_get_album_artist( + audio, + album_artist, + ); + } + + late final _audio_meta_get_album_artist_ptr = + _lookup>( + 'audio_meta_get_album_artist'); + late final _dart_audio_meta_get_album_artist _audio_meta_get_album_artist = + _audio_meta_get_album_artist_ptr + .asFunction<_dart_audio_meta_get_album_artist>(); + + /// @brief Gets the genre of the given audio metadata. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no genre info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a genre should be released using free(). + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] genre The genre of the audio metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int audio_meta_get_genre( + ffi.Pointer audio, + ffi.Pointer> genre, + ) { + return _audio_meta_get_genre( + audio, + genre, + ); + } + + late final _audio_meta_get_genre_ptr = + _lookup>( + 'audio_meta_get_genre'); + late final _dart_audio_meta_get_genre _audio_meta_get_genre = + _audio_meta_get_genre_ptr.asFunction<_dart_audio_meta_get_genre>(); + + /// @brief Gets the composer of the given audio metadata. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no composer info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a composer should be released using free(). + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] composer The composer of the audio metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int audio_meta_get_composer( + ffi.Pointer audio, + ffi.Pointer> composer, + ) { + return _audio_meta_get_composer( + audio, + composer, + ); + } + + late final _audio_meta_get_composer_ptr = + _lookup>( + 'audio_meta_get_composer'); + late final _dart_audio_meta_get_composer _audio_meta_get_composer = + _audio_meta_get_composer_ptr.asFunction<_dart_audio_meta_get_composer>(); + + /// @brief Gets the year of the given audio metadata. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no year info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a year should be released using free(). + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] year The year of the audio metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int audio_meta_get_year( + ffi.Pointer audio, + ffi.Pointer> year, + ) { + return _audio_meta_get_year( + audio, + year, + ); + } + + late final _audio_meta_get_year_ptr = + _lookup>( + 'audio_meta_get_year'); + late final _dart_audio_meta_get_year _audio_meta_get_year = + _audio_meta_get_year_ptr.asFunction<_dart_audio_meta_get_year>(); + + /// @brief Gets the recorded date of the given audio metadata. + /// @details The recorded date is got from audio file's metadata. Some formats like mp4 use UTC and the rest can be different. \n + /// So, please refer to the format specification if needed. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a recorded_date should be released using free(). + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] recorded_date The recorded date of the audio metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int audio_meta_get_recorded_date( + ffi.Pointer audio, + ffi.Pointer> recorded_date, + ) { + return _audio_meta_get_recorded_date( + audio, + recorded_date, + ); + } + + late final _audio_meta_get_recorded_date_ptr = + _lookup>( + 'audio_meta_get_recorded_date'); + late final _dart_audio_meta_get_recorded_date _audio_meta_get_recorded_date = + _audio_meta_get_recorded_date_ptr + .asFunction<_dart_audio_meta_get_recorded_date>(); + + /// @brief Gets the copyright notice of the given audio metadata. + /// @details If the media content has no copyright info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a copyright should be released using free(). + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] copyright The copyright of the audio metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int audio_meta_get_copyright( + ffi.Pointer audio, + ffi.Pointer> copyright, + ) { + return _audio_meta_get_copyright( + audio, + copyright, + ); + } + + late final _audio_meta_get_copyright_ptr = + _lookup>( + 'audio_meta_get_copyright'); + late final _dart_audio_meta_get_copyright _audio_meta_get_copyright = + _audio_meta_get_copyright_ptr + .asFunction<_dart_audio_meta_get_copyright>(); + + /// @brief Gets the track number of the given audio metadata. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no track info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a track_num should be released using free(). + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] track_num The audio track number of the audio metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int audio_meta_get_track_num( + ffi.Pointer audio, + ffi.Pointer> track_num, + ) { + return _audio_meta_get_track_num( + audio, + track_num, + ); + } + + late final _audio_meta_get_track_num_ptr = + _lookup>( + 'audio_meta_get_track_num'); + late final _dart_audio_meta_get_track_num _audio_meta_get_track_num = + _audio_meta_get_track_num_ptr + .asFunction<_dart_audio_meta_get_track_num>(); + + /// @brief Gets the bitrate of the given audio metadata in bitrate per second. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] bit_rate The audio bitrate in bit per second [bps] + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int audio_meta_get_bit_rate( + ffi.Pointer audio, + ffi.Pointer bit_rate, + ) { + return _audio_meta_get_bit_rate( + audio, + bit_rate, + ); + } + + late final _audio_meta_get_bit_rate_ptr = + _lookup>( + 'audio_meta_get_bit_rate'); + late final _dart_audio_meta_get_bit_rate _audio_meta_get_bit_rate = + _audio_meta_get_bit_rate_ptr.asFunction<_dart_audio_meta_get_bit_rate>(); + + /// @brief Gets bit per sample of the given audio metadata. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] bitpersample The audio bit per sample + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int audio_meta_get_bitpersample( + ffi.Pointer audio, + ffi.Pointer bitpersample, + ) { + return _audio_meta_get_bitpersample( + audio, + bitpersample, + ); + } + + late final _audio_meta_get_bitpersample_ptr = + _lookup>( + 'audio_meta_get_bitpersample'); + late final _dart_audio_meta_get_bitpersample _audio_meta_get_bitpersample = + _audio_meta_get_bitpersample_ptr + .asFunction<_dart_audio_meta_get_bitpersample>(); + + /// @brief Gets the sample rate of the given audio metadata. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] sample_rate The audio sample rate[hz] + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int audio_meta_get_sample_rate( + ffi.Pointer audio, + ffi.Pointer sample_rate, + ) { + return _audio_meta_get_sample_rate( + audio, + sample_rate, + ); + } + + late final _audio_meta_get_sample_rate_ptr = + _lookup>( + 'audio_meta_get_sample_rate'); + late final _dart_audio_meta_get_sample_rate _audio_meta_get_sample_rate = + _audio_meta_get_sample_rate_ptr + .asFunction<_dart_audio_meta_get_sample_rate>(); + + /// @brief Gets the channel of the given audio metadata. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] channel The channel of the audio + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int audio_meta_get_channel( + ffi.Pointer audio, + ffi.Pointer channel, + ) { + return _audio_meta_get_channel( + audio, + channel, + ); + } + + late final _audio_meta_get_channel_ptr = + _lookup>( + 'audio_meta_get_channel'); + late final _dart_audio_meta_get_channel _audio_meta_get_channel = + _audio_meta_get_channel_ptr.asFunction<_dart_audio_meta_get_channel>(); + + /// @brief Gets the track duration of the given audio metadata. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] audio The handle to the audio metadata + /// @param[out] duration The audio file duration + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int audio_meta_get_duration( + ffi.Pointer audio, + ffi.Pointer duration, + ) { + return _audio_meta_get_duration( + audio, + duration, + ); + } + + late final _audio_meta_get_duration_ptr = + _lookup>( + 'audio_meta_get_duration'); + late final _dart_audio_meta_get_duration _audio_meta_get_duration = + _audio_meta_get_duration_ptr.asFunction<_dart_audio_meta_get_duration>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. \n + /// This function does not guarantee independence of the played count value between applications. It is recommended that the value is managed by the application. + /// @brief Gets the number of times the given audio has been played. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] audio The audio metadata handle + /// @param[out] played_count The counter of the audio played + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int audio_meta_get_played_count( + ffi.Pointer audio, + ffi.Pointer played_count, + ) { + return _audio_meta_get_played_count( + audio, + played_count, + ); + } + + late final _audio_meta_get_played_count_ptr = + _lookup>( + 'audio_meta_get_played_count'); + late final _dart_audio_meta_get_played_count _audio_meta_get_played_count = + _audio_meta_get_played_count_ptr + .asFunction<_dart_audio_meta_get_played_count>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. \n + /// This function does not guarantee independence of the played time value between applications. It is recommended that the value is managed by the application. + /// @brief Gets the last played time parameter of the audio. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] audio The audio metadata handle + /// @param[out] played_time The last played time of the audio + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int audio_meta_get_played_time( + ffi.Pointer audio, + ffi.Pointer played_time, + ) { + return _audio_meta_get_played_time( + audio, + played_time, + ); + } + + late final _audio_meta_get_played_time_ptr = + _lookup>( + 'audio_meta_get_played_time'); + late final _dart_audio_meta_get_played_time _audio_meta_get_played_time = + _audio_meta_get_played_time_ptr + .asFunction<_dart_audio_meta_get_played_time>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. \n + /// This function does not guarantee independence of the played position value between applications. It is recommended that the value is managed by the application. + /// @brief Gets the played position parameter of the audio. + /// @details This function returns the elapsed playback position parameter of the audio as a period + /// starting from the beginning of the track. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] audio The audio metadata handle + /// @param[out] played_position The elapsed time of the audio + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int audio_meta_get_played_position( + ffi.Pointer audio, + ffi.Pointer played_position, + ) { + return _audio_meta_get_played_position( + audio, + played_position, + ); + } + + late final _audio_meta_get_played_position_ptr = + _lookup>( + 'audio_meta_get_played_position'); + late final _dart_audio_meta_get_played_position + _audio_meta_get_played_position = _audio_meta_get_played_position_ptr + .asFunction<_dart_audio_meta_get_played_position>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. \n + /// This function does not guarantee independence of the played count value between applications. It is recommended that the value is managed by the application. + /// @brief Sets the played count of the audio. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] audio The audio metadata handle + /// @param[in] played_count The played count of the audio + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int audio_meta_set_played_count( + ffi.Pointer audio, + int played_count, + ) { + return _audio_meta_set_played_count( + audio, + played_count, + ); + } + + late final _audio_meta_set_played_count_ptr = + _lookup>( + 'audio_meta_set_played_count'); + late final _dart_audio_meta_set_played_count _audio_meta_set_played_count = + _audio_meta_set_played_count_ptr + .asFunction<_dart_audio_meta_set_played_count>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. \n + /// This function does not guarantee independence of the played time value between applications. It is recommended that the value is managed by the application. + /// @brief Sets the last played time of the audio. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] audio The audio metadata handle + /// @param[in] played_time The last played time of the audio + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int audio_meta_set_played_time( + ffi.Pointer audio, + int played_time, + ) { + return _audio_meta_set_played_time( + audio, + played_time, + ); + } + + late final _audio_meta_set_played_time_ptr = + _lookup>( + 'audio_meta_set_played_time'); + late final _dart_audio_meta_set_played_time _audio_meta_set_played_time = + _audio_meta_set_played_time_ptr + .asFunction<_dart_audio_meta_set_played_time>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. \n + /// This function does not guarantee independence of the played position value between applications. It is recommended that the value is managed by the application. + /// @brief Sets the played position of the audio. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks It is NOT recommended to use this attribute for your application-specific purpose because this attribute can be overwritten by other applications (even 0). + /// + /// @param[in] audio The audio metadata handle + /// @param[in] played_position The played position of the audio + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int audio_meta_set_played_position( + ffi.Pointer audio, + int played_position, + ) { + return _audio_meta_set_played_position( + audio, + played_position, + ); + } + + late final _audio_meta_set_played_position_ptr = + _lookup>( + 'audio_meta_set_played_position'); + late final _dart_audio_meta_set_played_position + _audio_meta_set_played_position = _audio_meta_set_played_position_ptr + .asFunction<_dart_audio_meta_set_played_position>(); + + /// @deprecated Deprecated since 4.0. Related setter functions are deprecated, therefore this function is not needed anymore. + /// @brief Updates an audio metadata with modified attributes in the media database. + /// @details The function updates the given audio meta in the media database. The function should be called after any change in audio attributes, to be updated to the media + /// database. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @remarks Do not call this function in callback function of foreach function like media_info_foreach_media_from_db(). + /// + /// @param[in] audio The handle to the audio metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int audio_meta_update_to_db( + ffi.Pointer audio, + ) { + return _audio_meta_update_to_db( + audio, + ); + } + + late final _audio_meta_update_to_db_ptr = + _lookup>( + 'audio_meta_update_to_db'); + late final _dart_audio_meta_update_to_db _audio_meta_update_to_db = + _audio_meta_update_to_db_ptr.asFunction<_dart_audio_meta_update_to_db>(); + + /// @brief Creates a media filter handle. + /// @details This function creates a media filter handle. The handle can be + /// used to get the filtered information based on filter properties i.e. offset, count, condition for searching and order. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a filter should be released using media_info_filter_destroy(). + /// + /// @param[out] filter The handle to the media filter + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see media_filter_destroy() + int media_filter_create( + ffi.Pointer> filter, + ) { + return _media_filter_create( + filter, + ); + } + + late final _media_filter_create_ptr = + _lookup>( + 'media_filter_create'); + late final _dart_media_filter_create _media_filter_create = + _media_filter_create_ptr.asFunction<_dart_media_filter_create>(); + + /// @brief Destroys a media filter handle. + /// @details The function frees all resources related to the media filter handle. The filter + /// handle no longer can be used to perform any operation. A new filter handle + /// has to be created before the next usage. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_filter_create() + int media_filter_destroy( + ffi.Pointer filter, + ) { + return _media_filter_destroy( + filter, + ); + } + + late final _media_filter_destroy_ptr = + _lookup>( + 'media_filter_destroy'); + late final _dart_media_filter_destroy _media_filter_destroy = + _media_filter_destroy_ptr.asFunction<_dart_media_filter_destroy>(); + + /// @brief Sets the media filter offset and count. + /// @details This function sets the @a offset and @a count for the given filter used to limit number of items returned. + /// For example, if you set the @a offset as @c 10 and @a count as @c 5, then only searched data from @c 10 to @c 14 will be returned when the filter is used with foreach functions. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[in] offset The start position of the given media filter (Starting from zero) + /// @param[in] count The number of items to be searched with respect to the offset + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_filter_create() + /// @see media_filter_destroy() + int media_filter_set_offset( + ffi.Pointer filter, + int offset, + int count, + ) { + return _media_filter_set_offset( + filter, + offset, + count, + ); + } + + late final _media_filter_set_offset_ptr = + _lookup>( + 'media_filter_set_offset'); + late final _dart_media_filter_set_offset _media_filter_set_offset = + _media_filter_set_offset_ptr.asFunction<_dart_media_filter_set_offset>(); + + /// @brief Sets the @a condition for the given @a filter. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[in] condition The condition which is used WHERE clause on a query + /// @param[in] collate_type The collate type for comparing two strings + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_filter_create() + /// @see media_filter_destroy() + int media_filter_set_condition( + ffi.Pointer filter, + ffi.Pointer condition, + int collate_type, + ) { + return _media_filter_set_condition( + filter, + condition, + collate_type, + ); + } + + late final _media_filter_set_condition_ptr = + _lookup>( + 'media_filter_set_condition'); + late final _dart_media_filter_set_condition _media_filter_set_condition = + _media_filter_set_condition_ptr + .asFunction<_dart_media_filter_set_condition>(); + + /// @brief Sets the media filter content @a order_type and @a order_keyword i.e. either descending or ascending. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[in] order_type The search order type + /// @param[in] order_keyword The search order keyword + /// @param[in] collate_type The collate type for comparing two strings + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_filter_create() + /// @see media_filter_destroy() + int media_filter_set_order( + ffi.Pointer filter, + int order_type, + ffi.Pointer order_keyword, + int collate_type, + ) { + return _media_filter_set_order( + filter, + order_type, + order_keyword, + collate_type, + ); + } + + late final _media_filter_set_order_ptr = + _lookup>( + 'media_filter_set_order'); + late final _dart_media_filter_set_order _media_filter_set_order = + _media_filter_set_order_ptr.asFunction<_dart_media_filter_set_order>(); + + /// @brief Sets the @a storage_id for the given @a filter. + /// @details You can use this function when you want to search items only in the specific storage + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[in] storage_id The ID of the media storage + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_filter_create() + /// @see media_filter_destroy() + int media_filter_set_storage( + ffi.Pointer filter, + ffi.Pointer storage_id, + ) { + return _media_filter_set_storage( + filter, + storage_id, + ); + } + + late final _media_filter_set_storage_ptr = + _lookup>( + 'media_filter_set_storage'); + late final _dart_media_filter_set_storage _media_filter_set_storage = + _media_filter_set_storage_ptr + .asFunction<_dart_media_filter_set_storage>(); + + /// @brief Gets the @a offset and @a count for the given @a filter used to limit the number of items returned. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[out] offset The start position of the given media filter (Starting from zero) + /// @param[out] count The number of items to be searched with respect to the offset + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_filter_create() + /// @see media_filter_destroy() + int media_filter_get_offset( + ffi.Pointer filter, + ffi.Pointer offset, + ffi.Pointer count, + ) { + return _media_filter_get_offset( + filter, + offset, + count, + ); + } + + late final _media_filter_get_offset_ptr = + _lookup>( + 'media_filter_get_offset'); + late final _dart_media_filter_get_offset _media_filter_get_offset = + _media_filter_get_offset_ptr.asFunction<_dart_media_filter_get_offset>(); + + /// @brief Gets the @a condition for the given @a filter. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a condition should be released using free(). + /// + /// @param[in] filter The handle to the media filter + /// @param[out] condition The condition which is used WHERE clause on a query + /// @param[out] collate_type The collate type for comparing two strings + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_filter_create() + /// @see media_filter_destroy() + int media_filter_get_condition( + ffi.Pointer filter, + ffi.Pointer> condition, + ffi.Pointer collate_type, + ) { + return _media_filter_get_condition( + filter, + condition, + collate_type, + ); + } + + late final _media_filter_get_condition_ptr = + _lookup>( + 'media_filter_get_condition'); + late final _dart_media_filter_get_condition _media_filter_get_condition = + _media_filter_get_condition_ptr + .asFunction<_dart_media_filter_get_condition>(); + + /// @brief Gets the media filter's content @a order_type and @a order_keyword i.e. either descending or ascending. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a order_keyword should be released using free(). + /// + /// @param[in] filter The handle to the media filter + /// @param[out] order_type The search order type + /// @param[out] order_keyword The search order keyword + /// @param[out] collate_type The collate type for comparing two strings + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_filter_create() + /// @see media_filter_destroy() + int media_filter_get_order( + ffi.Pointer filter, + ffi.Pointer order_type, + ffi.Pointer> order_keyword, + ffi.Pointer collate_type, + ) { + return _media_filter_get_order( + filter, + order_type, + order_keyword, + collate_type, + ); + } + + late final _media_filter_get_order_ptr = + _lookup>( + 'media_filter_get_order'); + late final _dart_media_filter_get_order _media_filter_get_order = + _media_filter_get_order_ptr.asFunction<_dart_media_filter_get_order>(); + + /// @brief Gets the @a storage_id for given @a filter. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a storage_id should be released using free(). + /// + /// @param[in] filter The handle to the media filter + /// @param[out] storage_id The ID of the media storage + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_filter_create() + /// @see media_filter_destroy() + int media_filter_get_storage( + ffi.Pointer filter, + ffi.Pointer> storage_id, + ) { + return _media_filter_get_storage( + filter, + storage_id, + ); + } + + late final _media_filter_get_storage_ptr = + _lookup>( + 'media_filter_get_storage'); + late final _dart_media_filter_get_storage _media_filter_get_storage = + _media_filter_get_storage_ptr + .asFunction<_dart_media_filter_get_storage>(); + + /// @brief Gets the count of folder for the passed @a filter from the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[out] folder_count The count of the media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_folder_get_folder_count_from_db( + ffi.Pointer filter, + ffi.Pointer folder_count, + ) { + return _media_folder_get_folder_count_from_db( + filter, + folder_count, + ); + } + + late final _media_folder_get_folder_count_from_db_ptr = + _lookup>( + 'media_folder_get_folder_count_from_db'); + late final _dart_media_folder_get_folder_count_from_db + _media_folder_get_folder_count_from_db = + _media_folder_get_folder_count_from_db_ptr + .asFunction<_dart_media_folder_get_folder_count_from_db>(); + + /// @brief Iterates through available media folders with optional @a filter from the media database. + /// @details This function gets the media folder meeting the given @a filter. + /// The @a callback function will be invoked for every retrieved + /// folder. If @c NULL is passed to the @a filter, no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks Do not call updating DB function like media_folder_update_to_db() in your callback function, your callback function is invoked as inline function.\n + /// So, your callback function is in read state in SQLite. When you are in read state, sometimes you do not update DB. \n + /// We do not recommend you call updating DB function in callback of foreach function. + /// + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @pre A filter handle has to be created by calling media_filter_create(). + /// @post This function invokes media_folder_cb(). + /// + /// @see media_content_connect() + /// @see media_folder_cb() + /// @see media_filter_create() + int media_folder_foreach_folder_from_db( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_folder_foreach_folder_from_db( + filter, + callback, + user_data, + ); + } + + late final _media_folder_foreach_folder_from_db_ptr = + _lookup>( + 'media_folder_foreach_folder_from_db'); + late final _dart_media_folder_foreach_folder_from_db + _media_folder_foreach_folder_from_db = + _media_folder_foreach_folder_from_db_ptr + .asFunction<_dart_media_folder_foreach_folder_from_db>(); + + /// @brief Gets the count of media files for the passed @a filter in the given @a folder_id from the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] folder_id The ID of the media folder + /// @param[in] filter The handle to the media filter + /// @param[out] media_count The count of media folder items + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_folder_get_media_count_from_db( + ffi.Pointer folder_id, + ffi.Pointer filter, + ffi.Pointer media_count, + ) { + return _media_folder_get_media_count_from_db( + folder_id, + filter, + media_count, + ); + } + + late final _media_folder_get_media_count_from_db_ptr = + _lookup>( + 'media_folder_get_media_count_from_db'); + late final _dart_media_folder_get_media_count_from_db + _media_folder_get_media_count_from_db = + _media_folder_get_media_count_from_db_ptr + .asFunction<_dart_media_folder_get_media_count_from_db>(); + + /// @brief Iterates through the media files with an optional @a filter in the given @a folder_id from the media database. + /// @details This function gets all media files associated with the given folder and + /// meeting desired filter option and calls @a callback for + /// every retrieved media item. If @c NULL is passed to the @a filter, no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks Do not call updating DB function like media_info_update_to_db(), media_info_refresh_metadata_to_db(), audio_meta_update_to_db(), image_meta_update_to_db() and video_meta_update_to_db() in your callback function, + /// your callback function is invoked as inline function. \n + /// So, your callback function is in read state in SQLite. When you are in read state, sometimes you do not update DB. \n + /// We do not recommend you call updating DB function in callback of foreach function. + /// + /// @param[in] folder_id The ID of the media folder + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_info_cb(). + /// + /// @see #media_info_cb + /// @see media_content_connect() + /// @see media_filter_create() + int media_folder_foreach_media_from_db( + ffi.Pointer folder_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_folder_foreach_media_from_db( + folder_id, + filter, + callback, + user_data, + ); + } + + late final _media_folder_foreach_media_from_db_ptr = + _lookup>( + 'media_folder_foreach_media_from_db'); + late final _dart_media_folder_foreach_media_from_db + _media_folder_foreach_media_from_db = + _media_folder_foreach_media_from_db_ptr + .asFunction<_dart_media_folder_foreach_media_from_db>(); + + /// @brief Clones the media folder. + /// @details This function copies the media folder handle from a source to + /// destination. There is no media_folder_create() function. The media_folder_h is created internally and available through + /// media folder foreach function such as media_folder_foreach_folder_from_db(). To use this handle outside of these foreach functions, + /// use this function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a dst should be released using media_folder_destroy(). + /// + /// @param[out] dst The destination handle to the media folder + /// @param[in] src The source handle to the media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_folder_destroy() + /// @see media_folder_foreach_folder_from_db() + int media_folder_clone( + ffi.Pointer> dst, + ffi.Pointer src, + ) { + return _media_folder_clone( + dst, + src, + ); + } + + late final _media_folder_clone_ptr = + _lookup>('media_folder_clone'); + late final _dart_media_folder_clone _media_folder_clone = + _media_folder_clone_ptr.asFunction<_dart_media_folder_clone>(); + + /// @brief Destroys the media folder. + /// @details The function frees all resources related to the folder handle. This handle + /// no longer can be used to perform any operation. A new handle has to + /// be created before the next use. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] folder The handle to the media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre A copy of the media folder handle created by calling media_folder_clone(). + /// + /// @see media_folder_clone() + int media_folder_destroy( + ffi.Pointer folder, + ) { + return _media_folder_destroy( + folder, + ); + } + + late final _media_folder_destroy_ptr = + _lookup>( + 'media_folder_destroy'); + late final _dart_media_folder_destroy _media_folder_destroy = + _media_folder_destroy_ptr.asFunction<_dart_media_folder_destroy>(); + + /// @brief Gets the media folder ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a folder_id should be released using free(). + /// + /// @param[in] folder The handle to the media folder + /// @param[out] folder_id The ID of the media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_folder_get_folder_id( + ffi.Pointer folder, + ffi.Pointer> folder_id, + ) { + return _media_folder_get_folder_id( + folder, + folder_id, + ); + } + + late final _media_folder_get_folder_id_ptr = + _lookup>( + 'media_folder_get_folder_id'); + late final _dart_media_folder_get_folder_id _media_folder_get_folder_id = + _media_folder_get_folder_id_ptr + .asFunction<_dart_media_folder_get_folder_id>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Gets the parent folder ID. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a parent_folder_id should be released using free(). + /// + /// @param[in] folder The handle to the media folder + /// @param[out] parent_folder_id The ID of the upper media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_folder_get_parent_folder_id( + ffi.Pointer folder, + ffi.Pointer> parent_folder_id, + ) { + return _media_folder_get_parent_folder_id( + folder, + parent_folder_id, + ); + } + + late final _media_folder_get_parent_folder_id_ptr = + _lookup>( + 'media_folder_get_parent_folder_id'); + late final _dart_media_folder_get_parent_folder_id + _media_folder_get_parent_folder_id = + _media_folder_get_parent_folder_id_ptr + .asFunction<_dart_media_folder_get_parent_folder_id>(); + + /// @brief Gets the absolute path to the media folder. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a path should be released using free(). + /// + /// @param[in] folder The handle to the media folder + /// @param[out] path The path of the media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_folder_get_path( + ffi.Pointer folder, + ffi.Pointer> path, + ) { + return _media_folder_get_path( + folder, + path, + ); + } + + late final _media_folder_get_path_ptr = + _lookup>( + 'media_folder_get_path'); + late final _dart_media_folder_get_path _media_folder_get_path = + _media_folder_get_path_ptr.asFunction<_dart_media_folder_get_path>(); + + /// @brief Gets the media folder name. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a folder_name should be released using free(). + /// + /// @param[in] folder The handle to the media folder + /// @param[out] folder_name The name of the media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_folder_get_name( + ffi.Pointer folder, + ffi.Pointer> folder_name, + ) { + return _media_folder_get_name( + folder, + folder_name, + ); + } + + late final _media_folder_get_name_ptr = + _lookup>( + 'media_folder_get_name'); + late final _dart_media_folder_get_name _media_folder_get_name = + _media_folder_get_name_ptr.asFunction<_dart_media_folder_get_name>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Gets the modified date of the folder. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] folder The handle to the media folder + /// @param[out] date The modified date of the media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_folder_get_modified_time( + ffi.Pointer folder, + ffi.Pointer date, + ) { + return _media_folder_get_modified_time( + folder, + date, + ); + } + + late final _media_folder_get_modified_time_ptr = + _lookup>( + 'media_folder_get_modified_time'); + late final _dart_media_folder_get_modified_time + _media_folder_get_modified_time = _media_folder_get_modified_time_ptr + .asFunction<_dart_media_folder_get_modified_time>(); + + /// @brief Gets the folder storage type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] folder The handle to the media folder + /// @param[out] storage_type The storage type of the media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_folder_get_storage_type( + ffi.Pointer folder, + ffi.Pointer storage_type, + ) { + return _media_folder_get_storage_type( + folder, + storage_type, + ); + } + + late final _media_folder_get_storage_type_ptr = + _lookup>( + 'media_folder_get_storage_type'); + late final _dart_media_folder_get_storage_type + _media_folder_get_storage_type = _media_folder_get_storage_type_ptr + .asFunction<_dart_media_folder_get_storage_type>(); + + /// @brief Gets the storage id of the folder. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a storage_id should be released using free(). + /// + /// @param[in] folder The handle to the media folder + /// @param[out] storage_id The storage id of the media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_folder_get_storage_id( + ffi.Pointer folder, + ffi.Pointer> storage_id, + ) { + return _media_folder_get_storage_id( + folder, + storage_id, + ); + } + + late final _media_folder_get_storage_id_ptr = + _lookup>( + 'media_folder_get_storage_id'); + late final _dart_media_folder_get_storage_id _media_folder_get_storage_id = + _media_folder_get_storage_id_ptr + .asFunction<_dart_media_folder_get_storage_id>(); + + /// @deprecated Deprecated since 4.0. \n + /// This function does not guarantee order independence between applications. It is recommended that the viewing order is managed by the application. + /// + /// @brief Gets the folder viewing order. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] folder The handle to the media folder + /// @param[out] order The viewing order of the media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_folder_update_to_db() + int media_folder_get_order( + ffi.Pointer folder, + ffi.Pointer order, + ) { + return _media_folder_get_order( + folder, + order, + ); + } + + late final _media_folder_get_order_ptr = + _lookup>( + 'media_folder_get_order'); + late final _dart_media_folder_get_order _media_folder_get_order = + _media_folder_get_order_ptr.asFunction<_dart_media_folder_get_order>(); + + /// @brief Gets the media folder from the media database. + /// + /// @details This function creates a new media folder handle from the media database by the given @a folder_id. + /// Media folder will be created, which is filled with folder information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a folder should be released using media_folder_destroy(). + /// + /// @param[in] folder_id The ID of the media folder + /// @param[out] folder The handle to the media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_folder_destroy() + int media_folder_get_folder_from_db( + ffi.Pointer folder_id, + ffi.Pointer> folder, + ) { + return _media_folder_get_folder_from_db( + folder_id, + folder, + ); + } + + late final _media_folder_get_folder_from_db_ptr = + _lookup>( + 'media_folder_get_folder_from_db'); + late final _dart_media_folder_get_folder_from_db + _media_folder_get_folder_from_db = _media_folder_get_folder_from_db_ptr + .asFunction<_dart_media_folder_get_folder_from_db>(); + + /// @deprecated Deprecated since 4.0. Use media_content_scan_folder() or media_info_move_to_db() instead. + /// @brief Sets the folder name. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] folder The handle to the media folder + /// @param[in] name The name of the media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_folder_set_name( + ffi.Pointer folder, + ffi.Pointer name, + ) { + return _media_folder_set_name( + folder, + name, + ); + } + + late final _media_folder_set_name_ptr = + _lookup>( + 'media_folder_set_name'); + late final _dart_media_folder_set_name _media_folder_set_name = + _media_folder_set_name_ptr.asFunction<_dart_media_folder_set_name>(); + + /// @deprecated Deprecated since 4.0. \n + /// This function does not guarantee order independence between applications. It is recommended that the viewing order is managed by the application. + /// @brief Sets the folder viewing order. + /// @details If you set the order value for each folder, you can sort in ascending or descending order as the set order values using the filter. \n + /// Moreover, more detailed settings are possible when used with the filter. \n + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks If you don't set the order value, the order value will be set default value. Default is 0. \n + /// If you don't use the filter, the set order value does not effect the folder viewing order. + /// + /// @param[in] folder The handle to the media folder + /// @param[in] order The viewing order of the media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_folder_set_order( + ffi.Pointer folder, + int order, + ) { + return _media_folder_set_order( + folder, + order, + ); + } + + late final _media_folder_set_order_ptr = + _lookup>( + 'media_folder_set_order'); + late final _dart_media_folder_set_order _media_folder_set_order = + _media_folder_set_order_ptr.asFunction<_dart_media_folder_set_order>(); + + /// @deprecated Deprecated since 4.0. Related setter functions are deprecated, therefore this function is not needed anymore. + /// @brief Updates the media folder to the media database. + /// + /// @details The function updates the given media folder in the media database. The function should be called after any change in folder attributes, to be updated to the media + /// database. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @param[in] folder The handle to the media folder + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_folder_destroy() + int media_folder_update_to_db( + ffi.Pointer folder, + ) { + return _media_folder_update_to_db( + folder, + ); + } + + late final _media_folder_update_to_db_ptr = + _lookup>( + 'media_folder_update_to_db'); + late final _dart_media_folder_update_to_db _media_folder_update_to_db = + _media_folder_update_to_db_ptr + .asFunction<_dart_media_folder_update_to_db>(); + + /// @brief Clones the image metadata. + /// @details The function copies the image metadata handle from a source to destination. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a dst should be released using image_meta_destroy(). + /// + /// @param[out] dst The destination handle to the image metadata + /// @param[in] src The source handle to the image metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see image_meta_destroy() + int image_meta_clone( + ffi.Pointer> dst, + ffi.Pointer src, + ) { + return _image_meta_clone( + dst, + src, + ); + } + + late final _image_meta_clone_ptr = + _lookup>('image_meta_clone'); + late final _dart_image_meta_clone _image_meta_clone = + _image_meta_clone_ptr.asFunction<_dart_image_meta_clone>(); + + /// @brief Destroys the image metadata. + /// @details The function frees all resources related to the image metadata handle. This handle + /// no longer can be used to perform any operation. A new handle has to + /// be created before next usage. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] image The handle to the image metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre Get a copy of image_meta handle by calling image_meta_clone(). + /// + /// @see image_meta_clone() + int image_meta_destroy( + ffi.Pointer image, + ) { + return _image_meta_destroy( + image, + ); + } + + late final _image_meta_destroy_ptr = + _lookup>('image_meta_destroy'); + late final _dart_image_meta_destroy _image_meta_destroy = + _image_meta_destroy_ptr.asFunction<_dart_image_meta_destroy>(); + + /// @brief Gets the ID of an image. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a media_id should be released using free(). + /// + /// @param[in] image The handle to the image metadata + /// @param[out] media_id The media ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int image_meta_get_media_id( + ffi.Pointer image, + ffi.Pointer> media_id, + ) { + return _image_meta_get_media_id( + image, + media_id, + ); + } + + late final _image_meta_get_media_id_ptr = + _lookup>( + 'image_meta_get_media_id'); + late final _dart_image_meta_get_media_id _image_meta_get_media_id = + _image_meta_get_media_id_ptr.asFunction<_dart_image_meta_get_media_id>(); + + /// @brief Gets the image width in pixels. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] image The handle to the image metadata + /// @param[out] width The image width in pixels + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int image_meta_get_width( + ffi.Pointer image, + ffi.Pointer width, + ) { + return _image_meta_get_width( + image, + width, + ); + } + + late final _image_meta_get_width_ptr = + _lookup>( + 'image_meta_get_width'); + late final _dart_image_meta_get_width _image_meta_get_width = + _image_meta_get_width_ptr.asFunction<_dart_image_meta_get_width>(); + + /// @brief Gets the image height in pixels. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] image The handle to the image metadata + /// @param[out] height The image height in pixels + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int image_meta_get_height( + ffi.Pointer image, + ffi.Pointer height, + ) { + return _image_meta_get_height( + image, + height, + ); + } + + late final _image_meta_get_height_ptr = + _lookup>( + 'image_meta_get_height'); + late final _dart_image_meta_get_height _image_meta_get_height = + _image_meta_get_height_ptr.asFunction<_dart_image_meta_get_height>(); + + /// @brief Gets the image orientation. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] image The handle to the image metadata + /// @param[out] orientation The image orientation + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int image_meta_get_orientation( + ffi.Pointer image, + ffi.Pointer orientation, + ) { + return _image_meta_get_orientation( + image, + orientation, + ); + } + + late final _image_meta_get_orientation_ptr = + _lookup>( + 'image_meta_get_orientation'); + late final _dart_image_meta_get_orientation _image_meta_get_orientation = + _image_meta_get_orientation_ptr + .asFunction<_dart_image_meta_get_orientation>(); + + /// @brief Gets the image creation time. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a date_taken should be released using free(). + /// + /// @param[in] image The handle to the image metadata + /// @param[out] date_taken The time, when image was taken (in seconds, since the Epoch) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int image_meta_get_date_taken( + ffi.Pointer image, + ffi.Pointer> date_taken, + ) { + return _image_meta_get_date_taken( + image, + date_taken, + ); + } + + late final _image_meta_get_date_taken_ptr = + _lookup>( + 'image_meta_get_date_taken'); + late final _dart_image_meta_get_date_taken _image_meta_get_date_taken = + _image_meta_get_date_taken_ptr + .asFunction<_dart_image_meta_get_date_taken>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Gets the burst shot ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a burst_id should be released using free(). + /// + /// @param[in] image The handle to the image metadata + /// @param[out] burst_id The ID of the burst shot\ n + /// If @a burst_id is @c NULL, this is not burst shot + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int image_meta_get_burst_id( + ffi.Pointer image, + ffi.Pointer> burst_id, + ) { + return _image_meta_get_burst_id( + image, + burst_id, + ); + } + + late final _image_meta_get_burst_id_ptr = + _lookup>( + 'image_meta_get_burst_id'); + late final _dart_image_meta_get_burst_id _image_meta_get_burst_id = + _image_meta_get_burst_id_ptr.asFunction<_dart_image_meta_get_burst_id>(); + + /// @brief Gets the exposure time from EXIF. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a exposure_time should be released using free(). + /// + /// @param[in] image The handle to the image metadata + /// @param[out] exposure_time The value of exposure_time, getting from EXIF + /// + /// @return 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int image_meta_get_exposure_time( + ffi.Pointer image, + ffi.Pointer> exposure_time, + ) { + return _image_meta_get_exposure_time( + image, + exposure_time, + ); + } + + late final _image_meta_get_exposure_time_ptr = + _lookup>( + 'image_meta_get_exposure_time'); + late final _dart_image_meta_get_exposure_time _image_meta_get_exposure_time = + _image_meta_get_exposure_time_ptr + .asFunction<_dart_image_meta_get_exposure_time>(); + + /// @brief Gets the fnumber from EXIF. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] image The handle to the image metadata + /// @param[out] fnumber The value of fnumber, getting from EXIF + /// + /// @return 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int image_meta_get_fnumber( + ffi.Pointer image, + ffi.Pointer fnumber, + ) { + return _image_meta_get_fnumber( + image, + fnumber, + ); + } + + late final _image_meta_get_fnumber_ptr = + _lookup>( + 'image_meta_get_fnumber'); + late final _dart_image_meta_get_fnumber _image_meta_get_fnumber = + _image_meta_get_fnumber_ptr.asFunction<_dart_image_meta_get_fnumber>(); + + /// @brief Gets the iso from EXIF. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] image The handle to the image metadata + /// @param[out] iso The value of iso, getting from EXIF + /// + /// @return 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int image_meta_get_iso( + ffi.Pointer image, + ffi.Pointer iso, + ) { + return _image_meta_get_iso( + image, + iso, + ); + } + + late final _image_meta_get_iso_ptr = + _lookup>('image_meta_get_iso'); + late final _dart_image_meta_get_iso _image_meta_get_iso = + _image_meta_get_iso_ptr.asFunction<_dart_image_meta_get_iso>(); + + /// @brief Gets the model from EXIF. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a model should be released using free(). + /// + /// @param[in] image The handle to the image metadata + /// @param[out] model The value of model, getting from EXIF + /// + /// @return 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int image_meta_get_model( + ffi.Pointer image, + ffi.Pointer> model, + ) { + return _image_meta_get_model( + image, + model, + ); + } + + late final _image_meta_get_model_ptr = + _lookup>( + 'image_meta_get_model'); + late final _dart_image_meta_get_model _image_meta_get_model = + _image_meta_get_model_ptr.asFunction<_dart_image_meta_get_model>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Checks whether the media is a burst shot image. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] image The handle to the image metadata + /// @param[out] is_burst_shot @c true if the media is a burst shot image, + /// otherwise @c false if the media is not a burst shot image + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int image_meta_is_burst_shot( + ffi.Pointer image, + ffi.Pointer is_burst_shot, + ) { + return _image_meta_is_burst_shot( + image, + is_burst_shot, + ); + } + + late final _image_meta_is_burst_shot_ptr = + _lookup>( + 'image_meta_is_burst_shot'); + late final _dart_image_meta_is_burst_shot _image_meta_is_burst_shot = + _image_meta_is_burst_shot_ptr + .asFunction<_dart_image_meta_is_burst_shot>(); + + /// @deprecated Deprecated since 4.0. This data cannot be saved to the file. + /// @brief Sets an orientation of the image. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] image The handle to the image metadata + /// @param[in] orientation The image orientation + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int image_meta_set_orientation( + ffi.Pointer image, + int orientation, + ) { + return _image_meta_set_orientation( + image, + orientation, + ); + } + + late final _image_meta_set_orientation_ptr = + _lookup>( + 'image_meta_set_orientation'); + late final _dart_image_meta_set_orientation _image_meta_set_orientation = + _image_meta_set_orientation_ptr + .asFunction<_dart_image_meta_set_orientation>(); + + /// @deprecated Deprecated since 4.0. Related setter functions are deprecated, therefore this function is not needed anymore. + /// @brief Updates the image to the media database. + /// + /// @details The function updates the given image meta in the media database. \n + /// The function should be called after any change in image attributes, to be updated to the media database. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @remarks Do not call this function in callback function of foreach function like media_info_foreach_media_from_db(). + /// + /// @param[in] image The handle to the image metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int image_meta_update_to_db( + ffi.Pointer image, + ) { + return _image_meta_update_to_db( + image, + ); + } + + late final _image_meta_update_to_db_ptr = + _lookup>( + 'image_meta_update_to_db'); + late final _dart_image_meta_update_to_db _image_meta_update_to_db = + _image_meta_update_to_db_ptr.asFunction<_dart_image_meta_update_to_db>(); + + /// @brief Inserts the content file into the media database. + /// @details In general, you can use this function to insert content files into the media database. \n + /// You can use media_content_scan_file()/media_content_scan_folder() function instead of this function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write \n + /// %http://tizen.org/privilege/mediastorage \n + /// %http://tizen.org/privilege/externalstorage + /// + /// @remarks The @a info should be released using media_info_destroy(). \n + /// You must add privilege http://tizen.org/privilege/content.write. And You add more privilege depending on your choice of contents path. \n + /// If you want to access only internal storage by using this function, you should add privilege http://tizen.org/privilege/mediastorage. \n + /// Or if you want to access only external storage by using this function, you should add privilege http://tizen.org/privilege/externalstorage. \n + /// If you can access both storage, you must add all privilege. \n + /// Since 4.0, This function does not allow a symbolic link. \n + /// @remarks Since 4.0, this function is related to the following feature:\n + /// %http://tizen.org/feature/content.scanning.others\n + /// If this feature is not supported on the device, MEDIA_CONTENT_TYPE_OTHERS type file is not scanned. + /// + /// @param[in] path The path of the content file to add + /// @param[out] info The handle of the inserted content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_CONTENT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_content_scan_file() + /// @see media_content_scan_folder() + int media_info_insert_to_db( + ffi.Pointer path, + ffi.Pointer> info, + ) { + return _media_info_insert_to_db( + path, + info, + ); + } + + late final _media_info_insert_to_db_ptr = + _lookup>( + 'media_info_insert_to_db'); + late final _dart_media_info_insert_to_db _media_info_insert_to_db = + _media_info_insert_to_db_ptr.asFunction<_dart_media_info_insert_to_db>(); + + /// @brief Inserts content files into the media database, asynchronously. + /// @details This function can insert multiple content files into the media database. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write \n + /// %http://tizen.org/privilege/mediastorage \n + /// %http://tizen.org/privilege/externalstorage + /// + /// @remarks You must add privilege http://tizen.org/privilege/content.write. And You add more privilege depending on your choice of contents path. \n + /// If you want to access only internal storage by using this function, you should add privilege http://tizen.org/privilege/mediastorage. \n + /// Or if you want to access only external storage by using this function, you should add privilege http://tizen.org/privilege/externalstorage. \n + /// If you can access both storage, you must add all privilege. \n + /// Since 4.0, This function does not allow a symbolic link. \n + /// @remarks Since 4.0, this function is related to the following feature:\n + /// %http://tizen.org/feature/content.scanning.others\n + /// If this feature is not supported on the device, MEDIA_CONTENT_TYPE_OTHERS type file is not scanned. + /// + /// @param[in] path_array The path array of the content files to add + /// @param[in] array_length The length of the array + /// @param[in] callback The callback function to be invoked when media items inserted completely + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_CONTENT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_insert_completed_cb() + int media_info_insert_batch_to_db( + ffi.Pointer> path_array, + int array_length, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_info_insert_batch_to_db( + path_array, + array_length, + callback, + user_data, + ); + } + + late final _media_info_insert_batch_to_db_ptr = + _lookup>( + 'media_info_insert_batch_to_db'); + late final _dart_media_info_insert_batch_to_db + _media_info_insert_batch_to_db = _media_info_insert_batch_to_db_ptr + .asFunction<_dart_media_info_insert_batch_to_db>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Inserts the burst shot images into the media database, asynchronously. + /// @details This function inserts burst images into the media database. + /// media_insert_burst_shot_completed_cb() will be called when insertion to media database is finished. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write \n + /// %http://tizen.org/privilege/mediastorage \n + /// %http://tizen.org/privilege/externalstorage + /// + /// @remarks You must add privilege http://tizen.org/privilege/content.write. And You add more privilege depending on your choice of contents path. \n + /// If you want to access only internal storage with this function, you should add privilege http://tizen.org/privilege/mediastorage. \n + /// Or if you want to access only external storage with this function, you should add privilege http://tizen.org/privilege/externalstorage. \n + /// If you can access both storage, you must add all privilege. \n + /// Since 4.0, This function does not allow a symbolic link. \n + /// + /// @param[in] path_array The path array of the burst shot images to add + /// @param[in] array_length The length of the array + /// @param[in] callback The callback function to be invoked when the images are inserted completely + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_insert_burst_shot_completed_cb() + int media_info_insert_burst_shot_to_db( + ffi.Pointer> path_array, + int array_length, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _media_info_insert_burst_shot_to_db( + path_array, + array_length, + callback, + user_data, + ); + } + + late final _media_info_insert_burst_shot_to_db_ptr = + _lookup>( + 'media_info_insert_burst_shot_to_db'); + late final _dart_media_info_insert_burst_shot_to_db + _media_info_insert_burst_shot_to_db = + _media_info_insert_burst_shot_to_db_ptr + .asFunction<_dart_media_info_insert_burst_shot_to_db>(); + + /// @brief Deletes the media information from the media database. + /// @details This function only remove media information in the media database. \n + /// You can use media_content_scan_file()/media_content_scan_folder() function instead of this function if file is removed from the file system. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @param[in] media_id The media ID. It can get from media info handle. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_content_scan_file() + /// @see media_content_scan_folder() + int media_info_delete_from_db( + ffi.Pointer media_id, + ) { + return _media_info_delete_from_db( + media_id, + ); + } + + late final _media_info_delete_from_db_ptr = + _lookup>( + 'media_info_delete_from_db'); + late final _dart_media_info_delete_from_db _media_info_delete_from_db = + _media_info_delete_from_db_ptr + .asFunction<_dart_media_info_delete_from_db>(); + + /// @deprecated Deprecated since 4.0. Use media_content_scan_folder() or media_info_delete_from_db() instead. + /// @brief Deletes media information that meets the conditions of the filter from the media database. + /// @details This function can delete multiple media information from the media database. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @param[in] filter The handle to the media filter + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_filter_create() + int media_info_delete_batch_from_db( + ffi.Pointer filter, + ) { + return _media_info_delete_batch_from_db( + filter, + ); + } + + late final _media_info_delete_batch_from_db_ptr = + _lookup>( + 'media_info_delete_batch_from_db'); + late final _dart_media_info_delete_batch_from_db + _media_info_delete_batch_from_db = _media_info_delete_batch_from_db_ptr + .asFunction<_dart_media_info_delete_batch_from_db>(); + + /// @brief Destroys media info. + /// @details The function frees all resources related to the media info handle. This handle + /// can no longer be used to perform any operation. New media info handle has to + /// be created before the next usage. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre Get copy of media_info handle by calling media_info_clone(). + /// + /// @see media_info_clone() + int media_info_destroy( + ffi.Pointer media, + ) { + return _media_info_destroy( + media, + ); + } + + late final _media_info_destroy_ptr = + _lookup>('media_info_destroy'); + late final _dart_media_info_destroy _media_info_destroy = + _media_info_destroy_ptr.asFunction<_dart_media_info_destroy>(); + + /// @brief Clones the media info handle. + /// + /// @details This function copies the media info handle from a source to the destination. + /// There is no media_info_create() function. The media_info_h is created internally and + /// available through media info foreach function such as media_info_foreach_media_from_db() or media_info_insert_to_db(). + /// To use this handle outside of these foreach functions, use this function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a dst should be released using media_info_destroy(). + /// + /// @param[out] dst The destination handle to the media info + /// @param[in] src The source handle to the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_info_destroy() + /// @see media_album_foreach_media_from_db() + /// @see media_playlist_foreach_media_from_db() + /// @see media_group_foreach_media_from_db() + /// @see media_tag_foreach_media_from_db() + /// @see media_info_foreach_media_from_db() + /// @see media_info_insert_to_db() + /// @see media_folder_foreach_media_from_db() + int media_info_clone( + ffi.Pointer> dst, + ffi.Pointer src, + ) { + return _media_info_clone( + dst, + src, + ); + } + + late final _media_info_clone_ptr = + _lookup>('media_info_clone'); + late final _dart_media_info_clone _media_info_clone = + _media_info_clone_ptr.asFunction<_dart_media_info_clone>(); + + /// @brief Gets the count of media info for the passed @a filter from the media database. + /// @details If @c NULL is passed to the @a filter, then no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// + /// @param[in] filter The handle to the media filter + /// @param[out] media_count The count of media + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_filter_create() + int media_info_get_media_count_from_db( + ffi.Pointer filter, + ffi.Pointer media_count, + ) { + return _media_info_get_media_count_from_db( + filter, + media_count, + ); + } + + late final _media_info_get_media_count_from_db_ptr = + _lookup>( + 'media_info_get_media_count_from_db'); + late final _dart_media_info_get_media_count_from_db + _media_info_get_media_count_from_db = + _media_info_get_media_count_from_db_ptr + .asFunction<_dart_media_info_get_media_count_from_db>(); + + /// @brief Iterates through media info from the media database. + /// @details This function gets all media info handles meeting the given @a filter. + /// The @a callback function will be invoked for every retrieved media info. + /// If @c NULL is passed to the @a filter, then no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks Do not call updating DB function like media_info_update_to_db(), media_info_refresh_metadata_to_db(), audio_meta_update_to_db(), image_meta_update_to_db() and video_meta_update_to_db() in your callback function, + /// your callback function is invoked as inline function. + /// So, your callback function is in read state in SQLite. When you are in read state, sometimes you do not update DB. + /// We do not recommend you call updating DB function in callback of foreach function. + /// + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_info_cb(). + /// + /// @see media_content_connect() + /// @see #media_info_cb + /// @see media_filter_create() + int media_info_foreach_media_from_db( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_info_foreach_media_from_db( + filter, + callback, + user_data, + ); + } + + late final _media_info_foreach_media_from_db_ptr = + _lookup>( + 'media_info_foreach_media_from_db'); + late final _dart_media_info_foreach_media_from_db + _media_info_foreach_media_from_db = _media_info_foreach_media_from_db_ptr + .asFunction<_dart_media_info_foreach_media_from_db>(); + + /// @brief Gets the count of media tags for the passed @a filter in the given @a media_id from the media database. + /// @details If @c NULL is passed to the @a filter, then no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media_id The media ID + /// @param[in] filter The handle to the media filter + /// @param[out] tag_count The count of the media tag + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_filter_create() + int media_info_get_tag_count_from_db( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer tag_count, + ) { + return _media_info_get_tag_count_from_db( + media_id, + filter, + tag_count, + ); + } + + late final _media_info_get_tag_count_from_db_ptr = + _lookup>( + 'media_info_get_tag_count_from_db'); + late final _dart_media_info_get_tag_count_from_db + _media_info_get_tag_count_from_db = _media_info_get_tag_count_from_db_ptr + .asFunction<_dart_media_info_get_tag_count_from_db>(); + + /// @brief Iterates through the media tag in the given media info from the media database. + /// @details This function gets all the media tags associated with the given @a media_id and calls @a callback for every retrieved media tag. \n + /// If @c NULL is passed to the @a filter, then no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media_id The media ID + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_tag_cb(). + /// + /// @see media_content_connect() + /// @see #media_tag_cb + /// @see media_filter_create() + int media_info_foreach_tag_from_db( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_info_foreach_tag_from_db( + media_id, + filter, + callback, + user_data, + ); + } + + late final _media_info_foreach_tag_from_db_ptr = + _lookup>( + 'media_info_foreach_tag_from_db'); + late final _dart_media_info_foreach_tag_from_db + _media_info_foreach_tag_from_db = _media_info_foreach_tag_from_db_ptr + .asFunction<_dart_media_info_foreach_tag_from_db>(); + + /// @brief Gets the number of bookmarks for the passed @a filter in the given media ID from the media database. + /// @details If @c NULL is passed to the @a filter, then no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media_id The media ID + /// @param[in] filter The handle to the media filter + /// @param[out] bookmark_count The count of the media tag + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_filter_create() + int media_info_get_bookmark_count_from_db( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer bookmark_count, + ) { + return _media_info_get_bookmark_count_from_db( + media_id, + filter, + bookmark_count, + ); + } + + late final _media_info_get_bookmark_count_from_db_ptr = + _lookup>( + 'media_info_get_bookmark_count_from_db'); + late final _dart_media_info_get_bookmark_count_from_db + _media_info_get_bookmark_count_from_db = + _media_info_get_bookmark_count_from_db_ptr + .asFunction<_dart_media_info_get_bookmark_count_from_db>(); + + /// @brief Iterates through the media bookmark in the given media info from the media database. + /// @details This function gets all media bookmarks associated with the given media and calls @a callback for every retrieved media bookmark. + /// If @c NULL is passed to the @a filter, then no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media_id The media ID + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_bookmark_cb(). + /// + /// @see media_content_connect() + /// @see media_bookmark_cb() + /// @see media_filter_create() + int media_info_foreach_bookmark_from_db( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_info_foreach_bookmark_from_db( + media_id, + filter, + callback, + user_data, + ); + } + + late final _media_info_foreach_bookmark_from_db_ptr = + _lookup>( + 'media_info_foreach_bookmark_from_db'); + late final _dart_media_info_foreach_bookmark_from_db + _media_info_foreach_bookmark_from_db = + _media_info_foreach_bookmark_from_db_ptr + .asFunction<_dart_media_info_foreach_bookmark_from_db>(); + + /// @brief Gets the number of face for the passed @a media_id from the media database. + /// @details If @c NULL is passed to the @a filter, then no filtering is applied. + /// + /// @since_tizen 3.0 + /// + /// @param[in] media_id The media ID + /// @param[in] filter The handle to the media filter + /// @param[out] face_count The count of media face + /// + /// @return 0 on success, otherwise a negative error value. + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB operation failed + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @see media_content_connect() + /// @see media_filter_create() + int media_info_get_face_count_from_db( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer face_count, + ) { + return _media_info_get_face_count_from_db( + media_id, + filter, + face_count, + ); + } + + late final _media_info_get_face_count_from_db_ptr = + _lookup>( + 'media_info_get_face_count_from_db'); + late final _dart_media_info_get_face_count_from_db + _media_info_get_face_count_from_db = + _media_info_get_face_count_from_db_ptr + .asFunction<_dart_media_info_get_face_count_from_db>(); + + /// @brief Iterates through the media files with optional @a filter in the given @a media_id from the media database. + /// @details This function gets all media face info associated with the given media id and + /// meeting desired filter option and calls @a callback for + /// every retrieved media face info. If NULL is passed to the @a filter, no filtering is applied. + /// + /// @since_tizen 3.0 + /// + /// @param[in] media_id The media ID + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @see media_content_connect() + /// @see media_filter_create() + int media_info_foreach_face_from_db( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_info_foreach_face_from_db( + media_id, + filter, + callback, + user_data, + ); + } + + late final _media_info_foreach_face_from_db_ptr = + _lookup>( + 'media_info_foreach_face_from_db'); + late final _dart_media_info_foreach_face_from_db + _media_info_foreach_face_from_db = _media_info_foreach_face_from_db_ptr + .asFunction<_dart_media_info_foreach_face_from_db>(); + + /// @brief Gets the image metadata handle for a given media info. + /// @details This function returns an image metadata handle retrieved from the media info. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a image should be released using image_meta_destroy(). + /// + /// @param[in] media The handle to the media info + /// @param[out] image The handle to the image metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see image_meta_destroy() + int media_info_get_image( + ffi.Pointer media, + ffi.Pointer> image, + ) { + return _media_info_get_image( + media, + image, + ); + } + + late final _media_info_get_image_ptr = + _lookup>( + 'media_info_get_image'); + late final _dart_media_info_get_image _media_info_get_image = + _media_info_get_image_ptr.asFunction<_dart_media_info_get_image>(); + + /// @brief Gets a video metadata handle for a given media info. + /// @details This function returns a video metadata handle retrieved from the media info handle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a video should be released using video_meta_destroy(). + /// + /// @param[in] media The handle to the media info + /// @param[out] video The handle to the video metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see video_meta_destroy() + int media_info_get_video( + ffi.Pointer media, + ffi.Pointer> video, + ) { + return _media_info_get_video( + media, + video, + ); + } + + late final _media_info_get_video_ptr = + _lookup>( + 'media_info_get_video'); + late final _dart_media_info_get_video _media_info_get_video = + _media_info_get_video_ptr.asFunction<_dart_media_info_get_video>(); + + /// @brief Gets an audio metadata handle for a given media info. + /// @details This function returns an audio metadata handle retrieved from the media info handle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a audio should be released using audio_meta_destroy(). + /// + /// @param[in] media The handle to the media info + /// @param[out] audio The handle to the audio metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see audio_meta_destroy() + int media_info_get_audio( + ffi.Pointer media, + ffi.Pointer> audio, + ) { + return _media_info_get_audio( + media, + audio, + ); + } + + late final _media_info_get_audio_ptr = + _lookup>( + 'media_info_get_audio'); + late final _dart_media_info_get_audio _media_info_get_audio = + _media_info_get_audio_ptr.asFunction<_dart_media_info_get_audio>(); + + /// @brief Gets the media ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The @a media_id should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] media_id The media ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_media_id( + ffi.Pointer media, + ffi.Pointer> media_id, + ) { + return _media_info_get_media_id( + media, + media_id, + ); + } + + late final _media_info_get_media_id_ptr = + _lookup>( + 'media_info_get_media_id'); + late final _dart_media_info_get_media_id _media_info_get_media_id = + _media_info_get_media_id_ptr.asFunction<_dart_media_info_get_media_id>(); + + /// @brief Gets the full path of the content file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a path should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] path The full path of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_file_path( + ffi.Pointer media, + ffi.Pointer> path, + ) { + return _media_info_get_file_path( + media, + path, + ); + } + + late final _media_info_get_file_path_ptr = + _lookup>( + 'media_info_get_file_path'); + late final _dart_media_info_get_file_path _media_info_get_file_path = + _media_info_get_file_path_ptr + .asFunction<_dart_media_info_get_file_path>(); + + /// @brief Gets the file name including the extension of the content file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a name should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] name The file name including the extension of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_display_name( + ffi.Pointer media, + ffi.Pointer> name, + ) { + return _media_info_get_display_name( + media, + name, + ); + } + + late final _media_info_get_display_name_ptr = + _lookup>( + 'media_info_get_display_name'); + late final _dart_media_info_get_display_name _media_info_get_display_name = + _media_info_get_display_name_ptr + .asFunction<_dart_media_info_get_display_name>(); + + /// @brief Gets the content type of the content file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[out] type The content type of the content file (#media_content_type_e) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see #media_content_type_e + int media_info_get_media_type( + ffi.Pointer media, + ffi.Pointer type, + ) { + return _media_info_get_media_type( + media, + type, + ); + } + + late final _media_info_get_media_type_ptr = + _lookup>( + 'media_info_get_media_type'); + late final _dart_media_info_get_media_type _media_info_get_media_type = + _media_info_get_media_type_ptr + .asFunction<_dart_media_info_get_media_type>(); + + /// @brief Gets the MIME type of the content file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a mime_type should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] mime_type The MIME type of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_mime_type( + ffi.Pointer media, + ffi.Pointer> mime_type, + ) { + return _media_info_get_mime_type( + media, + mime_type, + ); + } + + late final _media_info_get_mime_type_ptr = + _lookup>( + 'media_info_get_mime_type'); + late final _dart_media_info_get_mime_type _media_info_get_mime_type = + _media_info_get_mime_type_ptr + .asFunction<_dart_media_info_get_mime_type>(); + + /// @brief Gets the content file size. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[out] size The content file size + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_size( + ffi.Pointer media, + ffi.Pointer size, + ) { + return _media_info_get_size( + media, + size, + ); + } + + late final _media_info_get_size_ptr = + _lookup>( + 'media_info_get_size'); + late final _dart_media_info_get_size _media_info_get_size = + _media_info_get_size_ptr.asFunction<_dart_media_info_get_size>(); + + /// @brief Gets the added time of the content file. + /// @details The added time refers to the time that content file was first added to media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[out] added_time The added time to the media database + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_added_time( + ffi.Pointer media, + ffi.Pointer added_time, + ) { + return _media_info_get_added_time( + media, + added_time, + ); + } + + late final _media_info_get_added_time_ptr = + _lookup>( + 'media_info_get_added_time'); + late final _dart_media_info_get_added_time _media_info_get_added_time = + _media_info_get_added_time_ptr + .asFunction<_dart_media_info_get_added_time>(); + + /// @brief Gets the modified time of the content file. + /// @details The modified time refers to the last modification time provided by the file system. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[out] time The last modification time of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_modified_time( + ffi.Pointer media, + ffi.Pointer time, + ) { + return _media_info_get_modified_time( + media, + time, + ); + } + + late final _media_info_get_modified_time_ptr = + _lookup>( + 'media_info_get_modified_time'); + late final _dart_media_info_get_modified_time _media_info_get_modified_time = + _media_info_get_modified_time_ptr + .asFunction<_dart_media_info_get_modified_time>(); + + /// @brief Gets the timeline of content file. + /// @details If the content file has the creation time information (like Content recored date or Image creation date), that value is timeline. \n + /// Otherwise, timeline value is the same as modified time. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[out] time The timeline of content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_timeline( + ffi.Pointer media, + ffi.Pointer time, + ) { + return _media_info_get_timeline( + media, + time, + ); + } + + late final _media_info_get_timeline_ptr = + _lookup>( + 'media_info_get_timeline'); + late final _dart_media_info_get_timeline _media_info_get_timeline = + _media_info_get_timeline_ptr.asFunction<_dart_media_info_get_timeline>(); + + /// @brief Gets the thumbnail path of content file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a path should be released using free(). \n + /// If the thumbnail extraction for the given media has not been requested yet, this function returns NULL. To create a thumbnail, you should use media_info_create_thumbnail() function. \n + /// Since 3.0, this function returns an empty string if media_info_create_thumbnail() has failed to create a thumbnail for the given media. + /// + /// @param[in] media The handle to the media info + /// @param[out] path The thumbnail path + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_thumbnail_path( + ffi.Pointer media, + ffi.Pointer> path, + ) { + return _media_info_get_thumbnail_path( + media, + path, + ); + } + + late final _media_info_get_thumbnail_path_ptr = + _lookup>( + 'media_info_get_thumbnail_path'); + late final _dart_media_info_get_thumbnail_path + _media_info_get_thumbnail_path = _media_info_get_thumbnail_path_ptr + .asFunction<_dart_media_info_get_thumbnail_path>(); + + /// @brief Gets the description of content file. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media info has no description, the method returns empty string. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a description should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] description The description of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_description( + ffi.Pointer media, + ffi.Pointer> description, + ) { + return _media_info_get_description( + media, + description, + ); + } + + late final _media_info_get_description_ptr = + _lookup>( + 'media_info_get_description'); + late final _dart_media_info_get_description _media_info_get_description = + _media_info_get_description_ptr + .asFunction<_dart_media_info_get_description>(); + + /// @brief Gets the longitude of content file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[out] longitude The longitude of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_longitude( + ffi.Pointer media, + ffi.Pointer longitude, + ) { + return _media_info_get_longitude( + media, + longitude, + ); + } + + late final _media_info_get_longitude_ptr = + _lookup>( + 'media_info_get_longitude'); + late final _dart_media_info_get_longitude _media_info_get_longitude = + _media_info_get_longitude_ptr + .asFunction<_dart_media_info_get_longitude>(); + + /// @brief Gets the latitude of content file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[out] latitude The latitude of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_latitude( + ffi.Pointer media, + ffi.Pointer latitude, + ) { + return _media_info_get_latitude( + media, + latitude, + ); + } + + late final _media_info_get_latitude_ptr = + _lookup>( + 'media_info_get_latitude'); + late final _dart_media_info_get_latitude _media_info_get_latitude = + _media_info_get_latitude_ptr.asFunction<_dart_media_info_get_latitude>(); + + /// @brief Gets the altitude of content file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[out] altitude The altitude of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_altitude( + ffi.Pointer media, + ffi.Pointer altitude, + ) { + return _media_info_get_altitude( + media, + altitude, + ); + } + + late final _media_info_get_altitude_ptr = + _lookup>( + 'media_info_get_altitude'); + late final _dart_media_info_get_altitude _media_info_get_altitude = + _media_info_get_altitude_ptr.asFunction<_dart_media_info_get_altitude>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Gets the weather of content file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The @a weather should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] weather The weather of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_weather( + ffi.Pointer media, + ffi.Pointer> weather, + ) { + return _media_info_get_weather( + media, + weather, + ); + } + + late final _media_info_get_weather_ptr = + _lookup>( + 'media_info_get_weather'); + late final _dart_media_info_get_weather _media_info_get_weather = + _media_info_get_weather_ptr.asFunction<_dart_media_info_get_weather>(); + + /// @brief Gets the rating of content file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[out] rating The rating of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_rating( + ffi.Pointer media, + ffi.Pointer rating, + ) { + return _media_info_get_rating( + media, + rating, + ); + } + + late final _media_info_get_rating_ptr = + _lookup>( + 'media_info_get_rating'); + late final _dart_media_info_get_rating _media_info_get_rating = + _media_info_get_rating_ptr.asFunction<_dart_media_info_get_rating>(); + + /// @brief Gets the favorite status of content file which User set. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[out] favorite @c true if content file is set as favorite, + /// otherwise @c false if content file is not set as favorite + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_info_set_favorite() + int media_info_get_favorite( + ffi.Pointer media, + ffi.Pointer favorite, + ) { + return _media_info_get_favorite( + media, + favorite, + ); + } + + late final _media_info_get_favorite_ptr = + _lookup>( + 'media_info_get_favorite'); + late final _dart_media_info_get_favorite _media_info_get_favorite = + _media_info_get_favorite_ptr.asFunction<_dart_media_info_get_favorite>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Gets the author of content file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a author should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] author The author of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_author( + ffi.Pointer media, + ffi.Pointer> author, + ) { + return _media_info_get_author( + media, + author, + ); + } + + late final _media_info_get_author_ptr = + _lookup>( + 'media_info_get_author'); + late final _dart_media_info_get_author _media_info_get_author = + _media_info_get_author_ptr.asFunction<_dart_media_info_get_author>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Gets the provider of content file which User set. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a provider should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] provider The provider of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_provider( + ffi.Pointer media, + ffi.Pointer> provider, + ) { + return _media_info_get_provider( + media, + provider, + ); + } + + late final _media_info_get_provider_ptr = + _lookup>( + 'media_info_get_provider'); + late final _dart_media_info_get_provider _media_info_get_provider = + _media_info_get_provider_ptr.asFunction<_dart_media_info_get_provider>(); + + /// @deprecated Deprecated since 4.0. Redundant, use media_info_get_display_name() instead. + /// @brief Gets the content name of content file which User set. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a content_name should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] content_name The content name of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_content_name( + ffi.Pointer media, + ffi.Pointer> content_name, + ) { + return _media_info_get_content_name( + media, + content_name, + ); + } + + late final _media_info_get_content_name_ptr = + _lookup>( + 'media_info_get_content_name'); + late final _dart_media_info_get_content_name _media_info_get_content_name = + _media_info_get_content_name_ptr + .asFunction<_dart_media_info_get_content_name>(); + + /// @brief Gets the title of content file. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the content file has no title, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a title should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] title The title of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_title( + ffi.Pointer media, + ffi.Pointer> title, + ) { + return _media_info_get_title( + media, + title, + ); + } + + late final _media_info_get_title_ptr = + _lookup>( + 'media_info_get_title'); + late final _dart_media_info_get_title _media_info_get_title = + _media_info_get_title_ptr.asFunction<_dart_media_info_get_title>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Gets the category of content file which User set. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a category should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] category The category of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_category( + ffi.Pointer media, + ffi.Pointer> category, + ) { + return _media_info_get_category( + media, + category, + ); + } + + late final _media_info_get_category_ptr = + _lookup>( + 'media_info_get_category'); + late final _dart_media_info_get_category _media_info_get_category = + _media_info_get_category_ptr.asFunction<_dart_media_info_get_category>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Gets the location tag of content file which User set. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a location_tag should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] location_tag The location of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_location_tag( + ffi.Pointer media, + ffi.Pointer> location_tag, + ) { + return _media_info_get_location_tag( + media, + location_tag, + ); + } + + late final _media_info_get_location_tag_ptr = + _lookup>( + 'media_info_get_location_tag'); + late final _dart_media_info_get_location_tag _media_info_get_location_tag = + _media_info_get_location_tag_ptr + .asFunction<_dart_media_info_get_location_tag>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Gets the age_rating of content file which User set. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a age_rating should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] age_rating The age rating of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_age_rating( + ffi.Pointer media, + ffi.Pointer> age_rating, + ) { + return _media_info_get_age_rating( + media, + age_rating, + ); + } + + late final _media_info_get_age_rating_ptr = + _lookup>( + 'media_info_get_age_rating'); + late final _dart_media_info_get_age_rating _media_info_get_age_rating = + _media_info_get_age_rating_ptr + .asFunction<_dart_media_info_get_age_rating>(); + + /// @deprecated Deprecated since 4.0. Use media_tag_insert_to_db() instead. + /// @brief Gets the keyword of content file which User set. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a keyword should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] keyword The keyword of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_keyword( + ffi.Pointer media, + ffi.Pointer> keyword, + ) { + return _media_info_get_keyword( + media, + keyword, + ); + } + + late final _media_info_get_keyword_ptr = + _lookup>( + 'media_info_get_keyword'); + late final _dart_media_info_get_keyword _media_info_get_keyword = + _media_info_get_keyword_ptr.asFunction<_dart_media_info_get_keyword>(); + + /// @brief Gets the storage id of content file. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a storage_id should be released using free(). + /// + /// @param[in] media The handle to the media info + /// @param[out] storage_id The ID of the media storage + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_storage_id( + ffi.Pointer media, + ffi.Pointer> storage_id, + ) { + return _media_info_get_storage_id( + media, + storage_id, + ); + } + + late final _media_info_get_storage_id_ptr = + _lookup>( + 'media_info_get_storage_id'); + late final _dart_media_info_get_storage_id _media_info_get_storage_id = + _media_info_get_storage_id_ptr + .asFunction<_dart_media_info_get_storage_id>(); + + /// @brief Checks whether the media is protected via DRM. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[out] is_drm @c true if media is DRM media, + /// otherwise @c false if media is not DRM media + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_is_drm( + ffi.Pointer media, + ffi.Pointer is_drm, + ) { + return _media_info_is_drm( + media, + is_drm, + ); + } + + late final _media_info_is_drm_ptr = + _lookup>('media_info_is_drm'); + late final _dart_media_info_is_drm _media_info_is_drm = + _media_info_is_drm_ptr.asFunction<_dart_media_info_is_drm>(); + + /// @brief Checks whether the content file is 360 content. + /// @since_tizen 3.0 + /// + /// @param[in] media The handle to the media info + /// @param[out] is_360 @c true if media is 360 content, + /// otherwise @c false if media is not 360 content + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_is_360_content( + ffi.Pointer media, + ffi.Pointer is_360, + ) { + return _media_info_is_360_content( + media, + is_360, + ); + } + + late final _media_info_is_360_content_ptr = + _lookup>( + 'media_info_is_360_content'); + late final _dart_media_info_is_360_content _media_info_is_360_content = + _media_info_is_360_content_ptr + .asFunction<_dart_media_info_is_360_content>(); + + /// @brief Gets the storage type of content file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[out] storage_type The storage type of the content file + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_storage_type( + ffi.Pointer media, + ffi.Pointer storage_type, + ) { + return _media_info_get_storage_type( + media, + storage_type, + ); + } + + late final _media_info_get_storage_type_ptr = + _lookup>( + 'media_info_get_storage_type'); + late final _dart_media_info_get_storage_type _media_info_get_storage_type = + _media_info_get_storage_type_ptr + .asFunction<_dart_media_info_get_storage_type>(); + + /// @deprecated Deprecated since 4.0. \n + /// This function does not guarantee independence of the played count value between applications. It is recommended that the value is managed by the application. + /// @brief Gets number which represents how many times given content has been played. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] media The handle to the media info + /// @param[out] played_count The counter of content played + /// + /// @return 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_played_count( + ffi.Pointer media, + ffi.Pointer played_count, + ) { + return _media_info_get_played_count( + media, + played_count, + ); + } + + late final _media_info_get_played_count_ptr = + _lookup>( + 'media_info_get_played_count'); + late final _dart_media_info_get_played_count _media_info_get_played_count = + _media_info_get_played_count_ptr + .asFunction<_dart_media_info_get_played_count>(); + + /// @deprecated Deprecated since 4.0. \n + /// This function does not guarantee independence of the played time value between applications. It is recommended that the value is managed by the application. + /// @brief Gets the content's played time parameter. + /// @details Function returns content's elapsed playback time parameter as period + /// starting from the beginning of the track. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] media The handle to the media info + /// @param[out] played_time The elapsed time of the content + /// + /// @return 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_get_played_time( + ffi.Pointer media, + ffi.Pointer played_time, + ) { + return _media_info_get_played_time( + media, + played_time, + ); + } + + late final _media_info_get_played_time_ptr = + _lookup>( + 'media_info_get_played_time'); + late final _dart_media_info_get_played_time _media_info_get_played_time = + _media_info_get_played_time_ptr + .asFunction<_dart_media_info_get_played_time>(); + + /// @brief Gets the media info from the media database. + /// + /// @details This function creates a new media handle from the media database by the given @a media_id. + /// Media info will be created and filled with information. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a media should be released using media_info_destroy(). + /// + /// @param[in] media_id The media ID + /// @param[out] media The handle to the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_info_destroy() + int media_info_get_media_from_db( + ffi.Pointer media_id, + ffi.Pointer> media, + ) { + return _media_info_get_media_from_db( + media_id, + media, + ); + } + + late final _media_info_get_media_from_db_ptr = + _lookup>( + 'media_info_get_media_from_db'); + late final _dart_media_info_get_media_from_db _media_info_get_media_from_db = + _media_info_get_media_from_db_ptr + .asFunction<_dart_media_info_get_media_from_db>(); + + /// @deprecated Deprecated since 4.0. \n + /// This function does not guarantee independence of the played count value between applications. It is recommended that the value is managed by the application. + /// @brief Increments the played count to content meta handle. + /// @details You can increase the played(opened) count of the content file. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] media The handle to the media info + /// + /// @return 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db() + int media_info_increase_played_count( + ffi.Pointer media, + ) { + return _media_info_increase_played_count( + media, + ); + } + + late final _media_info_increase_played_count_ptr = + _lookup>( + 'media_info_increase_played_count'); + late final _dart_media_info_increase_played_count + _media_info_increase_played_count = _media_info_increase_played_count_ptr + .asFunction<_dart_media_info_increase_played_count>(); + + /// @deprecated Deprecated since 4.0. \n + /// This function does not guarantee independence of the played time value between applications. It is recommended that the value is managed by the application. + /// @brief Sets the played time to content meta handle. + /// @details You can set the latest played(opened) time of the content file. the latest played time to be set the current time on the system. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] media The handle to the media info + /// + /// @return 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db() + int media_info_set_played_time( + ffi.Pointer media, + ) { + return _media_info_set_played_time( + media, + ); + } + + late final _media_info_set_played_time_ptr = + _lookup>( + 'media_info_set_played_time'); + late final _dart_media_info_set_played_time _media_info_set_played_time = + _media_info_set_played_time_ptr + .asFunction<_dart_media_info_set_played_time>(); + + /// @deprecated Deprecated since 4.0. Redundant, use media_info_move_to_db() instead. + /// @brief Sets the file name including the extension of the content file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] display_name The file name including the extension of the content file. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db(). + int media_info_set_display_name( + ffi.Pointer media, + ffi.Pointer display_name, + ) { + return _media_info_set_display_name( + media, + display_name, + ); + } + + late final _media_info_set_display_name_ptr = + _lookup>( + 'media_info_set_display_name'); + late final _dart_media_info_set_display_name _media_info_set_display_name = + _media_info_set_display_name_ptr + .asFunction<_dart_media_info_set_display_name>(); + + /// @deprecated Deprecated since 4.0. This data cannot be saved to the file. + /// @brief Sets the description of media info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] description The description of the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db(). + int media_info_set_description( + ffi.Pointer media, + ffi.Pointer description, + ) { + return _media_info_set_description( + media, + description, + ); + } + + late final _media_info_set_description_ptr = + _lookup>( + 'media_info_set_description'); + late final _dart_media_info_set_description _media_info_set_description = + _media_info_set_description_ptr + .asFunction<_dart_media_info_set_description>(); + + /// @deprecated Deprecated since 4.0. This data cannot be saved to the file. + /// @brief Sets the longitude of media info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] longitude The longitude of the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db(). + int media_info_set_longitude( + ffi.Pointer media, + double longitude, + ) { + return _media_info_set_longitude( + media, + longitude, + ); + } + + late final _media_info_set_longitude_ptr = + _lookup>( + 'media_info_set_longitude'); + late final _dart_media_info_set_longitude _media_info_set_longitude = + _media_info_set_longitude_ptr + .asFunction<_dart_media_info_set_longitude>(); + + /// @deprecated Deprecated since 4.0. This data cannot be saved to the file. + /// @brief Sets the latitude of media info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] latitude The latitude of the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db(). + int media_info_set_latitude( + ffi.Pointer media, + double latitude, + ) { + return _media_info_set_latitude( + media, + latitude, + ); + } + + late final _media_info_set_latitude_ptr = + _lookup>( + 'media_info_set_latitude'); + late final _dart_media_info_set_latitude _media_info_set_latitude = + _media_info_set_latitude_ptr.asFunction<_dart_media_info_set_latitude>(); + + /// @deprecated Deprecated since 4.0. This data cannot be saved to the file. + /// @brief Sets the altitude of media info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] altitude The altitude of the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db(). + int media_info_set_altitude( + ffi.Pointer media, + double altitude, + ) { + return _media_info_set_altitude( + media, + altitude, + ); + } + + late final _media_info_set_altitude_ptr = + _lookup>( + 'media_info_set_altitude'); + late final _dart_media_info_set_altitude _media_info_set_altitude = + _media_info_set_altitude_ptr.asFunction<_dart_media_info_set_altitude>(); + + /// @deprecated Deprecated since 4.0. This data cannot be saved to the file. + /// @brief Sets the weather of media info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] weather The weather of the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db(). + int media_info_set_weather( + ffi.Pointer media, + ffi.Pointer weather, + ) { + return _media_info_set_weather( + media, + weather, + ); + } + + late final _media_info_set_weather_ptr = + _lookup>( + 'media_info_set_weather'); + late final _dart_media_info_set_weather _media_info_set_weather = + _media_info_set_weather_ptr.asFunction<_dart_media_info_set_weather>(); + + /// @deprecated Deprecated since 4.0. This data cannot be saved to the file. + /// @brief Sets the rating of media info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] rating The rating of the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db(). + int media_info_set_rating( + ffi.Pointer media, + int rating, + ) { + return _media_info_set_rating( + media, + rating, + ); + } + + late final _media_info_set_rating_ptr = + _lookup>( + 'media_info_set_rating'); + late final _dart_media_info_set_rating _media_info_set_rating = + _media_info_set_rating_ptr.asFunction<_dart_media_info_set_rating>(); + + /// @brief Sets the favorite of media info. + /// @details This function can mark favorite of the media. If set to @c true, this function record the time of the change moment. \n + /// So, If you use it in order parameter, you can sort the order of the time was a favorite. \n + /// Or, if you use it in condition parameter, you can get the result of the favorite media. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] favorite Set @c true to set the media info as favorite, + /// otherwise set @c false to not set the media info as favorite + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_set_favorite( + ffi.Pointer media, + bool favorite, + ) { + return _media_info_set_favorite( + media, + favorite ? 1 : 0, + ); + } + + late final _media_info_set_favorite_ptr = + _lookup>( + 'media_info_set_favorite'); + late final _dart_media_info_set_favorite _media_info_set_favorite = + _media_info_set_favorite_ptr.asFunction<_dart_media_info_set_favorite>(); + + /// @deprecated Deprecated since 4.0. This data cannot be saved to the file. + /// @brief Sets the author of media info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] author The author of the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_set_author( + ffi.Pointer media, + ffi.Pointer author, + ) { + return _media_info_set_author( + media, + author, + ); + } + + late final _media_info_set_author_ptr = + _lookup>( + 'media_info_set_author'); + late final _dart_media_info_set_author _media_info_set_author = + _media_info_set_author_ptr.asFunction<_dart_media_info_set_author>(); + + /// @deprecated Deprecated since 4.0. This data cannot be saved to the file. + /// @brief Sets the provider of media info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] provider The provider of the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_set_provider( + ffi.Pointer media, + ffi.Pointer provider, + ) { + return _media_info_set_provider( + media, + provider, + ); + } + + late final _media_info_set_provider_ptr = + _lookup>( + 'media_info_set_provider'); + late final _dart_media_info_set_provider _media_info_set_provider = + _media_info_set_provider_ptr.asFunction<_dart_media_info_set_provider>(); + + /// @deprecated Deprecated since 4.0. Redundant, use media_info_move_to_db() instead. + /// @brief Sets the content name of media info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] content_name The content name of the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db() + int media_info_set_content_name( + ffi.Pointer media, + ffi.Pointer content_name, + ) { + return _media_info_set_content_name( + media, + content_name, + ); + } + + late final _media_info_set_content_name_ptr = + _lookup>( + 'media_info_set_content_name'); + late final _dart_media_info_set_content_name _media_info_set_content_name = + _media_info_set_content_name_ptr + .asFunction<_dart_media_info_set_content_name>(); + + /// @deprecated Deprecated since 4.0. This data cannot be saved to the file. + /// @brief Sets the category of media info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] category The category of the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db() + int media_info_set_category( + ffi.Pointer media, + ffi.Pointer category, + ) { + return _media_info_set_category( + media, + category, + ); + } + + late final _media_info_set_category_ptr = + _lookup>( + 'media_info_set_category'); + late final _dart_media_info_set_category _media_info_set_category = + _media_info_set_category_ptr.asFunction<_dart_media_info_set_category>(); + + /// @deprecated Deprecated since 4.0. This data cannot be saved to the file. + /// @brief Sets the location tag of media info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] location_tag The location of the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db() + int media_info_set_location_tag( + ffi.Pointer media, + ffi.Pointer location_tag, + ) { + return _media_info_set_location_tag( + media, + location_tag, + ); + } + + late final _media_info_set_location_tag_ptr = + _lookup>( + 'media_info_set_location_tag'); + late final _dart_media_info_set_location_tag _media_info_set_location_tag = + _media_info_set_location_tag_ptr + .asFunction<_dart_media_info_set_location_tag>(); + + /// @deprecated Deprecated since 4.0. This data cannot be saved to the file. + /// @brief Sets the age rating of media info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] age_rating The age rating of the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db() + int media_info_set_age_rating( + ffi.Pointer media, + ffi.Pointer age_rating, + ) { + return _media_info_set_age_rating( + media, + age_rating, + ); + } + + late final _media_info_set_age_rating_ptr = + _lookup>( + 'media_info_set_age_rating'); + late final _dart_media_info_set_age_rating _media_info_set_age_rating = + _media_info_set_age_rating_ptr + .asFunction<_dart_media_info_set_age_rating>(); + + /// @deprecated Deprecated since 4.0. Use media_tag_insert_to_db() instead. + /// @brief Sets the keyword of media info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] keyword The keyword of the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db() + int media_info_set_keyword( + ffi.Pointer media, + ffi.Pointer keyword, + ) { + return _media_info_set_keyword( + media, + keyword, + ); + } + + late final _media_info_set_keyword_ptr = + _lookup>( + 'media_info_set_keyword'); + late final _dart_media_info_set_keyword _media_info_set_keyword = + _media_info_set_keyword_ptr.asFunction<_dart_media_info_set_keyword>(); + + /// @brief Updates the media info to the media database. + /// + /// @details The function updates the given media info in the media database. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @remarks The function should be called after any change in media, to be updated to the media + /// database. For example, after using media_info_set_favorite() + /// for setting the name of the media, the media_info_update_to_db() function should be called so as to update + /// the given media info attributes in the media database. + /// + /// @param[in] media The handle to the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_info_set_favorite() + int media_info_update_to_db( + ffi.Pointer media, + ) { + return _media_info_update_to_db( + media, + ); + } + + late final _media_info_update_to_db_ptr = + _lookup>( + 'media_info_update_to_db'); + late final _dart_media_info_update_to_db _media_info_update_to_db = + _media_info_update_to_db_ptr.asFunction<_dart_media_info_update_to_db>(); + + /// @deprecated Deprecated since 4.0. Use media_content_scan_file() instead. + /// @brief Refreshes the media metadata to the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write \n + /// %http://tizen.org/privilege/mediastorage \n + /// %http://tizen.org/privilege/externalstorage + /// + /// @remarks You must add privilege http://tizen.org/privilege/content.write. And You add more privilege depending on your choice of contents path. \n + /// If you want to access only internal storage by using this function, you should add privilege http://tizen.org/privilege/mediastorage. \n + /// Or if you want to access only external storage by using this function, you should add privilege http://tizen.org/privilege/externalstorage. \n + /// If you can access both storage, you should add all privilege. + /// + /// @param[in] media_id The media ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_info_refresh_metadata_to_db( + ffi.Pointer media_id, + ) { + return _media_info_refresh_metadata_to_db( + media_id, + ); + } + + late final _media_info_refresh_metadata_to_db_ptr = + _lookup>( + 'media_info_refresh_metadata_to_db'); + late final _dart_media_info_refresh_metadata_to_db + _media_info_refresh_metadata_to_db = + _media_info_refresh_metadata_to_db_ptr + .asFunction<_dart_media_info_refresh_metadata_to_db>(); + + /// @deprecated Deprecated since 4.0. This data cannot be saved to the file. + /// @brief Sets the added time of media info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] media The handle to the media info + /// @param[in] added_time The added time of the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_info_update_to_db() + int media_info_set_added_time( + ffi.Pointer media, + int added_time, + ) { + return _media_info_set_added_time( + media, + added_time, + ); + } + + late final _media_info_set_added_time_ptr = + _lookup>( + 'media_info_set_added_time'); + late final _dart_media_info_set_added_time _media_info_set_added_time = + _media_info_set_added_time_ptr + .asFunction<_dart_media_info_set_added_time>(); + + /// @brief Moves the media info to the given destination path in the media database. + /// @details After moving or renaming a file in the filesystem, call this function to update the database. \n + /// If the source path and destination path are the same, then this function does nothing. + /// If you want to refresh media information, you should use media_content_scan_file() function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write \n + /// %http://tizen.org/privilege/mediastorage \n + /// %http://tizen.org/privilege/externalstorage + /// + /// @remarks You must add privilege http://tizen.org/privilege/content.write. And You add more privilege depending on your choice of contents path. \n + /// If you want to access only internal storage by using this function, you should add privilege http://tizen.org/privilege/mediastorage. \n + /// Or if you want to access only external storage by using this function, you should add privilege http://tizen.org/privilege/externalstorage. \n + /// If you can access both storage, you should add all privilege. \n + /// This function does not support USB storage. \n + /// Since 4.0, This function does not allow a symbolic link. + /// + /// @param[in] media The handle to the media info + /// @param[in] dst_path The path of destination + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter (Especially, if the request is duplicated, this error returns.) + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_content_scan_folder() + int media_info_move_to_db( + ffi.Pointer media, + ffi.Pointer dst_path, + ) { + return _media_info_move_to_db( + media, + dst_path, + ); + } + + late final _media_info_move_to_db_ptr = + _lookup>( + 'media_info_move_to_db'); + late final _dart_media_info_move_to_db _media_info_move_to_db = + _media_info_move_to_db_ptr.asFunction<_dart_media_info_move_to_db>(); + + /// @brief Creates a thumbnail file for the given media, asynchronously. + /// @details This function creates an thumbnail file for given media item and calls @a callback for completion of creating the thumbnail. + /// If a thumbnail already exists for the given media, then the path of thumbnail will be returned in callback function. \n + /// Since 3.0, a thumbnail is not automatically extracted during media scanning. \n + /// Therefore, if there exists no thumbnail for the given media, you MUST call this function to create a thumbnail. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @remarks If you want to destroy media handle before callback invoked, you must cancel thumbnail request by using media_info_cancel_thumbnail() \n + /// Since 3.0, if creation of a thumbnail is failed, empty string will be passed through media_thumbnail_completed_cb(). + /// Items in external storage except MMC not supported. + /// + /// @param[in] media The handle to the media info + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_info_create_thumbnail( + ffi.Pointer media, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_info_create_thumbnail( + media, + callback, + user_data, + ); + } + + late final _media_info_create_thumbnail_ptr = + _lookup>( + 'media_info_create_thumbnail'); + late final _dart_media_info_create_thumbnail _media_info_create_thumbnail = + _media_info_create_thumbnail_ptr + .asFunction<_dart_media_info_create_thumbnail>(); + + /// @brief Cancels the creation of thumbnail file for the given media. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @remarks If you request cancel for the already thumbnail created media, this function returns #MEDIA_CONTENT_ERROR_INVALID_OPERATION + /// + /// @param[in] media The handle to the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @see media_content_connect() + int media_info_cancel_thumbnail( + ffi.Pointer media, + ) { + return _media_info_cancel_thumbnail( + media, + ); + } + + late final _media_info_cancel_thumbnail_ptr = + _lookup>( + 'media_info_cancel_thumbnail'); + late final _dart_media_info_cancel_thumbnail _media_info_cancel_thumbnail = + _media_info_cancel_thumbnail_ptr + .asFunction<_dart_media_info_cancel_thumbnail>(); + + /// @ingroup CAPI_CONTENT_MEDIA_FACE_DETECTION_MODULE + /// @brief Starts face detection for the given image, asynchronously. + /// @details This function detects faces for given image item and calls the given callback function when the detection is completed. \n + /// The given callback function is called when the detection is completed. \n + /// To obtain the detected faces, call the media_info_foreach_face_from_db() function. + /// + /// @since_tizen 3.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write \n + /// %http://tizen.org/privilege/mediastorage + /// + /// @remarks If you want to destroy the media handle before callback invoked, you must cancel the face detection request by using media_info_cancel_face_detection(). \n + /// If face detection fails, the @a face_count argument in media_face_detection_completed_cb() will be set to 0. + /// Media items in external storage are not supported, with the exception of MMC items. + /// + /// @param[in] media The handle to the media info + /// @param[in] callback The callback function to be invoked when detection is completed + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_CONTENT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_info_cancel_face_detection() + int media_info_start_face_detection( + ffi.Pointer media, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_info_start_face_detection( + media, + callback, + user_data, + ); + } + + late final _media_info_start_face_detection_ptr = + _lookup>( + 'media_info_start_face_detection'); + late final _dart_media_info_start_face_detection + _media_info_start_face_detection = _media_info_start_face_detection_ptr + .asFunction<_dart_media_info_start_face_detection>(); + + /// @ingroup CAPI_CONTENT_MEDIA_FACE_DETECTION_MODULE + /// @brief Cancels face detection of image for the given media. + /// @details This function cancels face detection for given media item. \n + /// If you cancel face detection request before callback is invoked, the callback registered by media_info_start_face_detection() function will not be invoked. + /// + /// @since_tizen 3.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @remarks If face detection is already done when you request the cancellation, this function returns #MEDIA_CONTENT_ERROR_INVALID_OPERATION + /// + /// @param[in] media The handle to the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_info_start_face_detection() + int media_info_cancel_face_detection( + ffi.Pointer media, + ) { + return _media_info_cancel_face_detection( + media, + ); + } + + late final _media_info_cancel_face_detection_ptr = + _lookup>( + 'media_info_cancel_face_detection'); + late final _dart_media_info_cancel_face_detection + _media_info_cancel_face_detection = _media_info_cancel_face_detection_ptr + .asFunction<_dart_media_info_cancel_face_detection>(); + + /// @deprecated Deprecated since 4.0. Use media_info_insert_to_db() instead. + /// @brief Creates the media info handle. + /// @details If the information about the file that is already known, you can use this function to generate empty handler. + /// @since_tizen 3.0 + /// + /// + /// @privilege %http://tizen.org/privilege/mediastorage \n + /// %http://tizen.org/privilege/externalstorage + /// + /// @remarks The @a media should be released using media_info_destroy(). + /// @remarks If you want to access only internal storage with this function, you should add privilege http://tizen.org/privilege/mediastorage. \n + /// Or if you want to access only external storage with this function, you should add privilege http://tizen.org/privilege/externalstorage. \n + /// If you can access both storage, you must add all privilege. + /// + /// @param[in] path The path to create the media info handle + /// @param[out] media The handle to the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB operation failed + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see media_info_destroy() + int media_info_create( + ffi.Pointer path, + ffi.Pointer> media, + ) { + return _media_info_create( + path, + media, + ); + } + + late final _media_info_create_ptr = + _lookup>('media_info_create'); + late final _dart_media_info_create _media_info_create = + _media_info_create_ptr.asFunction<_dart_media_info_create>(); + + /// @deprecated Deprecated since 4.0. Use media_info_insert_to_db() instead. + /// @brief Inserts media info to database with media info data. + /// @since_tizen 3.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @remarks The @a media should be released using media_info_destroy(). + /// + /// @param[in] media The handle to the media info + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB operation failed + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + int media_info_insert_to_db_with_data( + ffi.Pointer media, + ) { + return _media_info_insert_to_db_with_data( + media, + ); + } + + late final _media_info_insert_to_db_with_data_ptr = + _lookup>( + 'media_info_insert_to_db_with_data'); + late final _dart_media_info_insert_to_db_with_data + _media_info_insert_to_db_with_data = + _media_info_insert_to_db_with_data_ptr + .asFunction<_dart_media_info_insert_to_db_with_data>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Sets the title of media info handle. + /// @since_tizen 3.0 + /// + /// @param[in] media The handle to the media info + /// @param[in] title The title of media info handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_set_title( + ffi.Pointer media, + ffi.Pointer title, + ) { + return _media_info_set_title( + media, + title, + ); + } + + late final _media_info_set_title_ptr = + _lookup>( + 'media_info_set_title'); + late final _dart_media_info_set_title _media_info_set_title = + _media_info_set_title_ptr.asFunction<_dart_media_info_set_title>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Sets the album of media info handle. + /// @since_tizen 3.0 + /// + /// @param[in] media The handle to the media info + /// @param[in] album The album of the media + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_set_album( + ffi.Pointer media, + ffi.Pointer album, + ) { + return _media_info_set_album( + media, + album, + ); + } + + late final _media_info_set_album_ptr = + _lookup>( + 'media_info_set_album'); + late final _dart_media_info_set_album _media_info_set_album = + _media_info_set_album_ptr.asFunction<_dart_media_info_set_album>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Sets the artist of media info handle. + /// @since_tizen 3.0 + /// + /// @param[in] media The handle to the media info + /// @param[in] artist The artist of media info handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_set_artist( + ffi.Pointer media, + ffi.Pointer artist, + ) { + return _media_info_set_artist( + media, + artist, + ); + } + + late final _media_info_set_artist_ptr = + _lookup>( + 'media_info_set_artist'); + late final _dart_media_info_set_artist _media_info_set_artist = + _media_info_set_artist_ptr.asFunction<_dart_media_info_set_artist>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Sets the genre of media info handle. + /// @since_tizen 3.0 + /// + /// @param[in] media The handle to the media info + /// @param[in] genre The genre of media info handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_set_genre( + ffi.Pointer media, + ffi.Pointer genre, + ) { + return _media_info_set_genre( + media, + genre, + ); + } + + late final _media_info_set_genre_ptr = + _lookup>( + 'media_info_set_genre'); + late final _dart_media_info_set_genre _media_info_set_genre = + _media_info_set_genre_ptr.asFunction<_dart_media_info_set_genre>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Sets the recorded date of media info handle. + /// @since_tizen 3.0 + /// + /// @param[in] media The handle to the media info + /// @param[in] recorded_date The recorded date of media info handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_info_set_recorded_date( + ffi.Pointer media, + ffi.Pointer recorded_date, + ) { + return _media_info_set_recorded_date( + media, + recorded_date, + ); + } + + late final _media_info_set_recorded_date_ptr = + _lookup>( + 'media_info_set_recorded_date'); + late final _dart_media_info_set_recorded_date _media_info_set_recorded_date = + _media_info_set_recorded_date_ptr + .asFunction<_dart_media_info_set_recorded_date>(); + + /// @brief Inserts a new tag in the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @remarks The @a tag should be released using media_tag_destroy(). + /// + /// @param[in] tag_name The tag name to be inserted + /// @param[out] tag The handle to the media tag + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_tag_delete_from_db() + /// @see media_tag_destroy() + int media_tag_insert_to_db( + ffi.Pointer tag_name, + ffi.Pointer> tag, + ) { + return _media_tag_insert_to_db( + tag_name, + tag, + ); + } + + late final _media_tag_insert_to_db_ptr = + _lookup>( + 'media_tag_insert_to_db'); + late final _dart_media_tag_insert_to_db _media_tag_insert_to_db = + _media_tag_insert_to_db_ptr.asFunction<_dart_media_tag_insert_to_db>(); + + /// @brief Deletes a given tag from the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @param[in] tag_id The ID of the media tag + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_tag_insert_to_db() + int media_tag_delete_from_db( + int tag_id, + ) { + return _media_tag_delete_from_db( + tag_id, + ); + } + + late final _media_tag_delete_from_db_ptr = + _lookup>( + 'media_tag_delete_from_db'); + late final _dart_media_tag_delete_from_db _media_tag_delete_from_db = + _media_tag_delete_from_db_ptr + .asFunction<_dart_media_tag_delete_from_db>(); + + /// @brief Gets the count of the tag for the passed @a filter from the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[out] tag_count The count of the media tag + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_tag_get_tag_count_from_db( + ffi.Pointer filter, + ffi.Pointer tag_count, + ) { + return _media_tag_get_tag_count_from_db( + filter, + tag_count, + ); + } + + late final _media_tag_get_tag_count_from_db_ptr = + _lookup>( + 'media_tag_get_tag_count_from_db'); + late final _dart_media_tag_get_tag_count_from_db + _media_tag_get_tag_count_from_db = _media_tag_get_tag_count_from_db_ptr + .asFunction<_dart_media_tag_get_tag_count_from_db>(); + + /// @brief Iterates through tags from the media database. + /// @details This function gets all tags meeting a desired @a filter + /// and calls a registered callback function for every retrieved tag. + /// If @c NULL is passed to the @a filter, no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_tag_cb(). + /// + /// @see media_content_connect() + /// @see #media_tag_cb + /// @see media_filter_create() + int media_tag_foreach_tag_from_db( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_tag_foreach_tag_from_db( + filter, + callback, + user_data, + ); + } + + late final _media_tag_foreach_tag_from_db_ptr = + _lookup>( + 'media_tag_foreach_tag_from_db'); + late final _dart_media_tag_foreach_tag_from_db + _media_tag_foreach_tag_from_db = _media_tag_foreach_tag_from_db_ptr + .asFunction<_dart_media_tag_foreach_tag_from_db>(); + + /// @brief Gets the number of media files for the passed @a filter in the given @a tag_id from the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] tag_id The ID of the media tag + /// @param[in] filter The handle to the media filter + /// @param[out] media_count The count of media items + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_tag_get_media_count_from_db( + int tag_id, + ffi.Pointer filter, + ffi.Pointer media_count, + ) { + return _media_tag_get_media_count_from_db( + tag_id, + filter, + media_count, + ); + } + + late final _media_tag_get_media_count_from_db_ptr = + _lookup>( + 'media_tag_get_media_count_from_db'); + late final _dart_media_tag_get_media_count_from_db + _media_tag_get_media_count_from_db = + _media_tag_get_media_count_from_db_ptr + .asFunction<_dart_media_tag_get_media_count_from_db>(); + + /// @brief Iterates through media items for a given tag from the media database. + /// @details This function gets all media items associated with a given tag and + /// meeting a desired @a filter and calls a registered callback function for + /// every retrieved media item. If @c NULL is passed to the @a filter, no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] tag_id The ID of the media tag + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_info_cb(). + /// + /// @see media_content_connect() + /// @see media_info_cb() + /// @see media_filter_create() + int media_tag_foreach_media_from_db( + int tag_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_tag_foreach_media_from_db( + tag_id, + filter, + callback, + user_data, + ); + } + + late final _media_tag_foreach_media_from_db_ptr = + _lookup>( + 'media_tag_foreach_media_from_db'); + late final _dart_media_tag_foreach_media_from_db + _media_tag_foreach_media_from_db = _media_tag_foreach_media_from_db_ptr + .asFunction<_dart_media_tag_foreach_media_from_db>(); + + /// @brief Clones the media tag. + /// @details This function copies the media tag handle from a source to destination. + /// There is no media_tag_create() function. The media_tag_h is created internally and available through media tag foreach function + /// such as media_tag_foreach_tag_from_db(). + /// To use this handle outside of these foreach functions, use this function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a dst should be released using media_tag_destroy(). + /// + /// @param[out] dst The destination handle to the media tag + /// @param[in] src The source handle to the media tag + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_tag_destroy() + int media_tag_clone( + ffi.Pointer> dst, + ffi.Pointer src, + ) { + return _media_tag_clone( + dst, + src, + ); + } + + late final _media_tag_clone_ptr = + _lookup>('media_tag_clone'); + late final _dart_media_tag_clone _media_tag_clone = + _media_tag_clone_ptr.asFunction<_dart_media_tag_clone>(); + + /// @brief Destroys the media tag. + /// @details This function frees all resources related to the tag handle. The tag handle can no longer + /// be used for any operation. A new tag handle has to be created before next usage. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] tag The handle to the media tag + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre A copy of the media tag handle created by calling media_tag_clone() or media_tag_insert_to_db(). + /// + /// @see media_tag_clone() + /// @see media_tag_insert_to_db() + int media_tag_destroy( + ffi.Pointer tag, + ) { + return _media_tag_destroy( + tag, + ); + } + + late final _media_tag_destroy_ptr = + _lookup>('media_tag_destroy'); + late final _dart_media_tag_destroy _media_tag_destroy = + _media_tag_destroy_ptr.asFunction<_dart_media_tag_destroy>(); + + /// @brief Gets the media tag ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] tag The handle to the media tag + /// @param[out] tag_id The ID of the media tag + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_tag_get_tag_id( + ffi.Pointer tag, + ffi.Pointer tag_id, + ) { + return _media_tag_get_tag_id( + tag, + tag_id, + ); + } + + late final _media_tag_get_tag_id_ptr = + _lookup>( + 'media_tag_get_tag_id'); + late final _dart_media_tag_get_tag_id _media_tag_get_tag_id = + _media_tag_get_tag_id_ptr.asFunction<_dart_media_tag_get_tag_id>(); + + /// @brief Gets the tag name. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a tag_name should be released using free(). + /// + /// @param[in] tag The handle to the media tag + /// @param[out] tag_name The name of the media tag + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_tag_get_name( + ffi.Pointer tag, + ffi.Pointer> tag_name, + ) { + return _media_tag_get_name( + tag, + tag_name, + ); + } + + late final _media_tag_get_name_ptr = + _lookup>('media_tag_get_name'); + late final _dart_media_tag_get_name _media_tag_get_name = + _media_tag_get_name_ptr.asFunction<_dart_media_tag_get_name>(); + + /// @brief Gets the media tag from the media database. + /// + /// @details This function creates a new media tag handle from the media database by the given @a tag_id. + /// Media tag will be created and will be filled with tag information. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a tag should be released using media_tag_destroy(). + /// + /// @param[in] tag_id The ID of the media tag + /// @param[out] tag The handle to the media tag + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_tag_destroy() + int media_tag_get_tag_from_db( + int tag_id, + ffi.Pointer> tag, + ) { + return _media_tag_get_tag_from_db( + tag_id, + tag, + ); + } + + late final _media_tag_get_tag_from_db_ptr = + _lookup>( + 'media_tag_get_tag_from_db'); + late final _dart_media_tag_get_tag_from_db _media_tag_get_tag_from_db = + _media_tag_get_tag_from_db_ptr + .asFunction<_dart_media_tag_get_tag_from_db>(); + + /// @brief Adds a new media info to the tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] tag The handle to the media tag + /// @param[in] media_id The media ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post media_tag_update_to_db() + /// + /// @see media_content_connect() + /// @see media_tag_remove_media() + int media_tag_add_media( + ffi.Pointer tag, + ffi.Pointer media_id, + ) { + return _media_tag_add_media( + tag, + media_id, + ); + } + + late final _media_tag_add_media_ptr = + _lookup>( + 'media_tag_add_media'); + late final _dart_media_tag_add_media _media_tag_add_media = + _media_tag_add_media_ptr.asFunction<_dart_media_tag_add_media>(); + + /// @brief Removes the media info from the given tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] tag The handle to the media tag + /// @param[in] media_id The media ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post media_tag_update_to_db() + /// + /// @see media_content_connect() + /// @see media_tag_add_media() + int media_tag_remove_media( + ffi.Pointer tag, + ffi.Pointer media_id, + ) { + return _media_tag_remove_media( + tag, + media_id, + ); + } + + late final _media_tag_remove_media_ptr = + _lookup>( + 'media_tag_remove_media'); + late final _dart_media_tag_remove_media _media_tag_remove_media = + _media_tag_remove_media_ptr.asFunction<_dart_media_tag_remove_media>(); + + /// @brief Sets the name of the tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] tag The handle to the media tag + /// @param[in] tag_name The name of the media tag + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @post media_tag_update_to_db() + int media_tag_set_name( + ffi.Pointer tag, + ffi.Pointer tag_name, + ) { + return _media_tag_set_name( + tag, + tag_name, + ); + } + + late final _media_tag_set_name_ptr = + _lookup>('media_tag_set_name'); + late final _dart_media_tag_set_name _media_tag_set_name = + _media_tag_set_name_ptr.asFunction<_dart_media_tag_set_name>(); + + /// @brief Updates the media tag to the media database. + /// + /// @details The function updates the given media tag in the media database. The function should be called after any change in tag attributes, to be updated to the media + /// database. For example, after using media_tag_set_name() for setting the name of the tag, the media_tag_update_to_db() function should be called so as to update + /// the given tag attributes in the media database. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @param[in] tag The handle to the media tag + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_tag_destroy() + /// @see media_tag_add_media() + /// @see media_tag_remove_media() + /// @see media_tag_set_name() + int media_tag_update_to_db( + ffi.Pointer tag, + ) { + return _media_tag_update_to_db( + tag, + ); + } + + late final _media_tag_update_to_db_ptr = + _lookup>( + 'media_tag_update_to_db'); + late final _dart_media_tag_update_to_db _media_tag_update_to_db = + _media_tag_update_to_db_ptr.asFunction<_dart_media_tag_update_to_db>(); + + /// @brief Clones the video metadata. + /// @details This function copies the video metadata handle from a source to destination. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a dst should be released using video_meta_destroy(). + /// + /// @param[out] dst The destination handle to the video metadata + /// @param[in] src The source handle to the video metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see video_meta_destroy() + int video_meta_clone( + ffi.Pointer> dst, + ffi.Pointer src, + ) { + return _video_meta_clone( + dst, + src, + ); + } + + late final _video_meta_clone_ptr = + _lookup>('video_meta_clone'); + late final _dart_video_meta_clone _video_meta_clone = + _video_meta_clone_ptr.asFunction<_dart_video_meta_clone>(); + + /// @brief Destroys the video metadata. + /// @details This function frees all resources related to the video metadata handle. This handle + /// no longer can be used to perform any operation. A new handle has to + /// be created before the next use. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] video The handle to the video metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre Get copy of video metadata handle by calling video_meta_clone(). + /// + /// @see video_meta_clone() + int video_meta_destroy( + ffi.Pointer video, + ) { + return _video_meta_destroy( + video, + ); + } + + late final _video_meta_destroy_ptr = + _lookup>('video_meta_destroy'); + late final _dart_video_meta_destroy _video_meta_destroy = + _video_meta_destroy_ptr.asFunction<_dart_video_meta_destroy>(); + + /// @brief Gets the ID of the media of the given video metadata. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a media_id should be released using free(). + /// + /// @param[in] video The handle to the video metadata + /// @param[out] media_id The media ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int video_meta_get_media_id( + ffi.Pointer video, + ffi.Pointer> media_id, + ) { + return _video_meta_get_media_id( + video, + media_id, + ); + } + + late final _video_meta_get_media_id_ptr = + _lookup>( + 'video_meta_get_media_id'); + late final _dart_video_meta_get_media_id _video_meta_get_media_id = + _video_meta_get_media_id_ptr.asFunction<_dart_video_meta_get_media_id>(); + + /// @brief Gets the album of the given video metadata. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no album info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a album should be released using free(). + /// + /// @param[in] video The handle to the video metadata + /// @param[out] album The album of the video metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int video_meta_get_album( + ffi.Pointer video, + ffi.Pointer> album, + ) { + return _video_meta_get_album( + video, + album, + ); + } + + late final _video_meta_get_album_ptr = + _lookup>( + 'video_meta_get_album'); + late final _dart_video_meta_get_album _video_meta_get_album = + _video_meta_get_album_ptr.asFunction<_dart_video_meta_get_album>(); + + /// @brief Gets the artist of the given video metadata. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no artist info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a artist should be released using free(). + /// + /// @param[in] video The handle to the video metadata + /// @param[out] artist The artist of the video metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int video_meta_get_artist( + ffi.Pointer video, + ffi.Pointer> artist, + ) { + return _video_meta_get_artist( + video, + artist, + ); + } + + late final _video_meta_get_artist_ptr = + _lookup>( + 'video_meta_get_artist'); + late final _dart_video_meta_get_artist _video_meta_get_artist = + _video_meta_get_artist_ptr.asFunction<_dart_video_meta_get_artist>(); + + /// @brief Gets the video album artist. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no album artist info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a album_artist should be released using free(). + /// + /// @param[in] video The handle to the video metadata + /// @param[out] album_artist The album artist of the video metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int video_meta_get_album_artist( + ffi.Pointer video, + ffi.Pointer> album_artist, + ) { + return _video_meta_get_album_artist( + video, + album_artist, + ); + } + + late final _video_meta_get_album_artist_ptr = + _lookup>( + 'video_meta_get_album_artist'); + late final _dart_video_meta_get_album_artist _video_meta_get_album_artist = + _video_meta_get_album_artist_ptr + .asFunction<_dart_video_meta_get_album_artist>(); + + /// @brief Gets the genre of the given video metadata. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no genre info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a genre should be released using free(). + /// + /// @param[in] video The handle to the video metadata + /// @param[out] genre The genre of the video metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int video_meta_get_genre( + ffi.Pointer video, + ffi.Pointer> genre, + ) { + return _video_meta_get_genre( + video, + genre, + ); + } + + late final _video_meta_get_genre_ptr = + _lookup>( + 'video_meta_get_genre'); + late final _dart_video_meta_get_genre _video_meta_get_genre = + _video_meta_get_genre_ptr.asFunction<_dart_video_meta_get_genre>(); + + /// @brief Gets the composer of the given video metadata. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no composer info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a composer should be released using free(). + /// + /// @param[in] video The handle to the video metadata + /// @param[out] composer The composer of the video metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int video_meta_get_composer( + ffi.Pointer video, + ffi.Pointer> composer, + ) { + return _video_meta_get_composer( + video, + composer, + ); + } + + late final _video_meta_get_composer_ptr = + _lookup>( + 'video_meta_get_composer'); + late final _dart_video_meta_get_composer _video_meta_get_composer = + _video_meta_get_composer_ptr.asFunction<_dart_video_meta_get_composer>(); + + /// @brief Gets the year of the given video metadata. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no year info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a year should be released using free(). + /// + /// @param[in] video The handle to the video metadata + /// @param[out] year The year of the video metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int video_meta_get_year( + ffi.Pointer video, + ffi.Pointer> year, + ) { + return _video_meta_get_year( + video, + year, + ); + } + + late final _video_meta_get_year_ptr = + _lookup>( + 'video_meta_get_year'); + late final _dart_video_meta_get_year _video_meta_get_year = + _video_meta_get_year_ptr.asFunction<_dart_video_meta_get_year>(); + + /// @brief Gets the recorded date of the video. + /// @details The recorded date is got from video file's metadata. Some formats like mp4 use UTC and the rest can be different. \n + /// So, please refer to the format specification if needed. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a recorded_date should be released using free(). + /// + /// @param[in] video The handle to the video metadata + /// @param[out] recorded_date The recorded date of the video metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int video_meta_get_recorded_date( + ffi.Pointer video, + ffi.Pointer> recorded_date, + ) { + return _video_meta_get_recorded_date( + video, + recorded_date, + ); + } + + late final _video_meta_get_recorded_date_ptr = + _lookup>( + 'video_meta_get_recorded_date'); + late final _dart_video_meta_get_recorded_date _video_meta_get_recorded_date = + _video_meta_get_recorded_date_ptr + .asFunction<_dart_video_meta_get_recorded_date>(); + + /// @brief Gets the copyright notice of the given video metadata. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no copyright info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a copyright should be released using free(). + /// + /// @param[in] video The handle to the video metadata + /// @param[out] copyright The copyright of the video metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int video_meta_get_copyright( + ffi.Pointer video, + ffi.Pointer> copyright, + ) { + return _video_meta_get_copyright( + video, + copyright, + ); + } + + late final _video_meta_get_copyright_ptr = + _lookup>( + 'video_meta_get_copyright'); + late final _dart_video_meta_get_copyright _video_meta_get_copyright = + _video_meta_get_copyright_ptr + .asFunction<_dart_video_meta_get_copyright>(); + + /// @brief Gets the track number of the given video metadata. + /// @details If the value is an empty string, the method returns "Unknown". \n + /// Since 3.0, if the media content has no track info, the method returns empty string. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a track_num should be released using free(). + /// + /// @param[in] video The handle to the video metadata + /// @param[out] track_num The track number of the video metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int video_meta_get_track_num( + ffi.Pointer video, + ffi.Pointer> track_num, + ) { + return _video_meta_get_track_num( + video, + track_num, + ); + } + + late final _video_meta_get_track_num_ptr = + _lookup>( + 'video_meta_get_track_num'); + late final _dart_video_meta_get_track_num _video_meta_get_track_num = + _video_meta_get_track_num_ptr + .asFunction<_dart_video_meta_get_track_num>(); + + /// @brief Gets the bitrate of the given video metadata in bitrate per second. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] video The handle to the video metadata + /// @param[out] bit_rate The video bit rate in bit per second [bps] + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int video_meta_get_bit_rate( + ffi.Pointer video, + ffi.Pointer bit_rate, + ) { + return _video_meta_get_bit_rate( + video, + bit_rate, + ); + } + + late final _video_meta_get_bit_rate_ptr = + _lookup>( + 'video_meta_get_bit_rate'); + late final _dart_video_meta_get_bit_rate _video_meta_get_bit_rate = + _video_meta_get_bit_rate_ptr.asFunction<_dart_video_meta_get_bit_rate>(); + + /// @brief Gets the track duration of the given video metadata. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] video The handle to the video metadata + /// @param[out] duration The video duration in milliseconds + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int video_meta_get_duration( + ffi.Pointer video, + ffi.Pointer duration, + ) { + return _video_meta_get_duration( + video, + duration, + ); + } + + late final _video_meta_get_duration_ptr = + _lookup>( + 'video_meta_get_duration'); + late final _dart_video_meta_get_duration _video_meta_get_duration = + _video_meta_get_duration_ptr.asFunction<_dart_video_meta_get_duration>(); + + /// @brief Gets the width of the given video metadata. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] video The handle to the video metadata + /// @param[out] width The video width in pixels + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int video_meta_get_width( + ffi.Pointer video, + ffi.Pointer width, + ) { + return _video_meta_get_width( + video, + width, + ); + } + + late final _video_meta_get_width_ptr = + _lookup>( + 'video_meta_get_width'); + late final _dart_video_meta_get_width _video_meta_get_width = + _video_meta_get_width_ptr.asFunction<_dart_video_meta_get_width>(); + + /// @brief Gets the height of the given video metadata. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] video The handle to the video metadata + /// @param[out] height The video height in pixels + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int video_meta_get_height( + ffi.Pointer video, + ffi.Pointer height, + ) { + return _video_meta_get_height( + video, + height, + ); + } + + late final _video_meta_get_height_ptr = + _lookup>( + 'video_meta_get_height'); + late final _dart_video_meta_get_height _video_meta_get_height = + _video_meta_get_height_ptr.asFunction<_dart_video_meta_get_height>(); + + /// @brief Gets the rotation of the given video metadata. + /// @since_tizen 4.0 + /// + /// @param[in] video The handle to the video metadata + /// @param[out] rotation The clockwise rotation angle of the video in degrees (can be returned from 0 to less than 360) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int video_meta_get_rotation( + ffi.Pointer video, + ffi.Pointer rotation, + ) { + return _video_meta_get_rotation( + video, + rotation, + ); + } + + late final _video_meta_get_rotation_ptr = + _lookup>( + 'video_meta_get_rotation'); + late final _dart_video_meta_get_rotation _video_meta_get_rotation = + _video_meta_get_rotation_ptr.asFunction<_dart_video_meta_get_rotation>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. \n + /// This function does not guarantee independence of the played count value between applications. It is recommended that the value is managed by the application. + /// @brief Gets the played count of the video. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] video The video metadata handle + /// @param[out] played_count The counter of the video played + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int video_meta_get_played_count( + ffi.Pointer video, + ffi.Pointer played_count, + ) { + return _video_meta_get_played_count( + video, + played_count, + ); + } + + late final _video_meta_get_played_count_ptr = + _lookup>( + 'video_meta_get_played_count'); + late final _dart_video_meta_get_played_count _video_meta_get_played_count = + _video_meta_get_played_count_ptr + .asFunction<_dart_video_meta_get_played_count>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. \n + /// This function does not guarantee independence of the played time value between applications. It is recommended that the value is managed by the application. + /// @brief Gets the last played time parameter of the video. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] video The video metadata handle + /// @param[out] played_time The last played time of the video + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int video_meta_get_played_time( + ffi.Pointer video, + ffi.Pointer played_time, + ) { + return _video_meta_get_played_time( + video, + played_time, + ); + } + + late final _video_meta_get_played_time_ptr = + _lookup>( + 'video_meta_get_played_time'); + late final _dart_video_meta_get_played_time _video_meta_get_played_time = + _video_meta_get_played_time_ptr + .asFunction<_dart_video_meta_get_played_time>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. \n + /// This function does not guarantee independence of the played position value between applications. It is recommended that the value is managed by the application. + /// @brief Gets the played position parameter of the video. + /// @details This function returns the elapsed playback position parameter of the video as period + /// starting from the beginning of the movie. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] video The video metadata handle + /// @param[out] played_position The elapsed time of the video + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int video_meta_get_played_position( + ffi.Pointer video, + ffi.Pointer played_position, + ) { + return _video_meta_get_played_position( + video, + played_position, + ); + } + + late final _video_meta_get_played_position_ptr = + _lookup>( + 'video_meta_get_played_position'); + late final _dart_video_meta_get_played_position + _video_meta_get_played_position = _video_meta_get_played_position_ptr + .asFunction<_dart_video_meta_get_played_position>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. \n + /// This function does not guarantee independence of the played count value between applications. It is recommended that the value is managed by the application. + /// @brief Sets the played count of the video. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] video The video metadata handle + /// @param[in] played_count The number of played + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int video_meta_set_played_count( + ffi.Pointer video, + int played_count, + ) { + return _video_meta_set_played_count( + video, + played_count, + ); + } + + late final _video_meta_set_played_count_ptr = + _lookup>( + 'video_meta_set_played_count'); + late final _dart_video_meta_set_played_count _video_meta_set_played_count = + _video_meta_set_played_count_ptr + .asFunction<_dart_video_meta_set_played_count>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. \n + /// This function does not guarantee independence of the played time value between applications. It is recommended that the value is managed by the application. + /// @brief Sets the last played time of the video. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] video The video metadata handle + /// @param[in] played_time The last played time of the video + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int video_meta_set_played_time( + ffi.Pointer video, + int played_time, + ) { + return _video_meta_set_played_time( + video, + played_time, + ); + } + + late final _video_meta_set_played_time_ptr = + _lookup>( + 'video_meta_set_played_time'); + late final _dart_video_meta_set_played_time _video_meta_set_played_time = + _video_meta_set_played_time_ptr + .asFunction<_dart_video_meta_set_played_time>(); + + /// @deprecated Deprecated since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. \n + /// This function does not guarantee independence of the played position value between applications. It is recommended that the value is managed by the application. + /// @brief Sets the played position of the video. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks It is NOT recommended to use this attribute for your application-specific purpose because this attribute can be overwritten by other applications (even 0). + /// + /// @param[in] video The video metadata handle + /// @param[in] played_position The position from the beginning of the video (in milliseconds) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int video_meta_set_played_position( + ffi.Pointer video, + int played_position, + ) { + return _video_meta_set_played_position( + video, + played_position, + ); + } + + late final _video_meta_set_played_position_ptr = + _lookup>( + 'video_meta_set_played_position'); + late final _dart_video_meta_set_played_position + _video_meta_set_played_position = _video_meta_set_played_position_ptr + .asFunction<_dart_video_meta_set_played_position>(); + + /// @deprecated Deprecated since 4.0. Related setter functions are deprecated, therefore this function is not needed anymore. + /// @brief Updates an video metadata with modified attributes in the media database. + /// @details The function updates the given video meta in the media database. The function should be called after any change in video attributes, to be updated to the media + /// database. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @remarks Do not call this function in callback function of foreach function like media_info_foreach_media_from_db(). + /// + /// @param[in] video The handle to the video metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int video_meta_update_to_db( + ffi.Pointer video, + ) { + return _video_meta_update_to_db( + video, + ); + } + + late final _video_meta_update_to_db_ptr = + _lookup>( + 'video_meta_update_to_db'); + late final _dart_video_meta_update_to_db _video_meta_update_to_db = + _video_meta_update_to_db_ptr.asFunction<_dart_video_meta_update_to_db>(); + + /// @brief Gets the number of the album for the passed @a filter from the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[out] album_count The count of the media album + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_album_get_album_count_from_db( + ffi.Pointer filter, + ffi.Pointer album_count, + ) { + return _media_album_get_album_count_from_db( + filter, + album_count, + ); + } + + late final _media_album_get_album_count_from_db_ptr = + _lookup>( + 'media_album_get_album_count_from_db'); + late final _dart_media_album_get_album_count_from_db + _media_album_get_album_count_from_db = + _media_album_get_album_count_from_db_ptr + .asFunction<_dart_media_album_get_album_count_from_db>(); + + /// @brief Iterates through the media album with optional @a filter from the media database. + /// @details This function gets all media album handles meeting the given filter. + /// The callback function will be invoked for every retrieved media album. + /// If @c NULL is passed to the filter, no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_album_cb(). + /// + /// @see #media_album_cb + /// @see media_content_connect() + /// @see media_filter_create() + int media_album_foreach_album_from_db( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_album_foreach_album_from_db( + filter, + callback, + user_data, + ); + } + + late final _media_album_foreach_album_from_db_ptr = + _lookup>( + 'media_album_foreach_album_from_db'); + late final _dart_media_album_foreach_album_from_db + _media_album_foreach_album_from_db = + _media_album_foreach_album_from_db_ptr + .asFunction<_dart_media_album_foreach_album_from_db>(); + + /// @brief Gets the number of media info for the given album present in the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] album_id The ID of the media album + /// @param[in] filter The handle to the media filter + /// @param[out] media_count The count of the media album + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_album_get_media_count_from_db( + int album_id, + ffi.Pointer filter, + ffi.Pointer media_count, + ) { + return _media_album_get_media_count_from_db( + album_id, + filter, + media_count, + ); + } + + late final _media_album_get_media_count_from_db_ptr = + _lookup>( + 'media_album_get_media_count_from_db'); + late final _dart_media_album_get_media_count_from_db + _media_album_get_media_count_from_db = + _media_album_get_media_count_from_db_ptr + .asFunction<_dart_media_album_get_media_count_from_db>(); + + /// @brief Iterates through the media files with an optional @a filter in the given media album from the media database. + /// @details This function gets all media files associated with the given media album and + /// meeting desired filter option and calls @a callback for + /// every retrieved media info. If @c NULL is passed to the @a filter, no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] album_id The ID of the media album + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_info_cb(). + /// + /// @see #media_info_cb + /// @see media_content_connect() + /// @see media_filter_create() + int media_album_foreach_media_from_db( + int album_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_album_foreach_media_from_db( + album_id, + filter, + callback, + user_data, + ); + } + + late final _media_album_foreach_media_from_db_ptr = + _lookup>( + 'media_album_foreach_media_from_db'); + late final _dart_media_album_foreach_media_from_db + _media_album_foreach_media_from_db = + _media_album_foreach_media_from_db_ptr + .asFunction<_dart_media_album_foreach_media_from_db>(); + + /// @brief Destroys the album handle. + /// @details This function frees all resources related to the album handle. This handle + /// can no longer be used to perform any operation. A new handle has to + /// be created before the next use. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] album The handle to the media album + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre Get copy of album handle by calling media_album_clone(). + /// + /// @see media_album_clone() + int media_album_destroy( + ffi.Pointer album, + ) { + return _media_album_destroy( + album, + ); + } + + late final _media_album_destroy_ptr = + _lookup>( + 'media_album_destroy'); + late final _dart_media_album_destroy _media_album_destroy = + _media_album_destroy_ptr.asFunction<_dart_media_album_destroy>(); + + /// @brief Clones a media album. + /// @details This function copies the media album handle from a source to + /// destination. There is no media_album_create() function. The media_album_h is created internally and available through + /// media album foreach function such as media_album_foreach_album_from_db(). To use this handle outside of these foreach functions, + /// use this function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a dst should be released using media_album_destroy(). + /// + /// @param[out] dst The destination handle to the media album + /// @param[in] src The source handle to the media album + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see media_album_destroy() + /// @see media_album_foreach_album_from_db() + int media_album_clone( + ffi.Pointer> dst, + ffi.Pointer src, + ) { + return _media_album_clone( + dst, + src, + ); + } + + late final _media_album_clone_ptr = + _lookup>('media_album_clone'); + late final _dart_media_album_clone _media_album_clone = + _media_album_clone_ptr.asFunction<_dart_media_album_clone>(); + + /// @brief Gets the ID of the album. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] album The handle to the media album + /// @param[out] album_id The ID of the media album + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_album_foreach_album_from_db() + int media_album_get_album_id( + ffi.Pointer album, + ffi.Pointer album_id, + ) { + return _media_album_get_album_id( + album, + album_id, + ); + } + + late final _media_album_get_album_id_ptr = + _lookup>( + 'media_album_get_album_id'); + late final _dart_media_album_get_album_id _media_album_get_album_id = + _media_album_get_album_id_ptr + .asFunction<_dart_media_album_get_album_id>(); + + /// @brief Gets the name of the album. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a album_name should be released using free(). + /// + /// @param[in] album The handle to the media album + /// @param[out] album_name The name of the media album handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_album_get_name( + ffi.Pointer album, + ffi.Pointer> album_name, + ) { + return _media_album_get_name( + album, + album_name, + ); + } + + late final _media_album_get_name_ptr = + _lookup>( + 'media_album_get_name'); + late final _dart_media_album_get_name _media_album_get_name = + _media_album_get_name_ptr.asFunction<_dart_media_album_get_name>(); + + /// @brief Gets the name of the artist from the given album. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a artist should be released using free(). + /// + /// @param[in] album The handle to the media album + /// @param[out] artist The name of the media artist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_album_get_artist( + ffi.Pointer album, + ffi.Pointer> artist, + ) { + return _media_album_get_artist( + album, + artist, + ); + } + + late final _media_album_get_artist_ptr = + _lookup>( + 'media_album_get_artist'); + late final _dart_media_album_get_artist _media_album_get_artist = + _media_album_get_artist_ptr.asFunction<_dart_media_album_get_artist>(); + + /// @brief Gets the album art path from the album. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a album_art should be released using free(). + /// + /// @param[in] album The handle to the media album + /// @param[out] album_art The path of the media album_art + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_album_get_album_art( + ffi.Pointer album, + ffi.Pointer> album_art, + ) { + return _media_album_get_album_art( + album, + album_art, + ); + } + + late final _media_album_get_album_art_ptr = + _lookup>( + 'media_album_get_album_art'); + late final _dart_media_album_get_album_art _media_album_get_album_art = + _media_album_get_album_art_ptr + .asFunction<_dart_media_album_get_album_art>(); + + /// @brief Gets the media album from the media database. + /// + /// @details This function creates a new media album handle from the media database by the given @a album_id. + /// Media album will be created and will be filled with the album information. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a album should be released using media_album_destroy(). + /// + /// @param[in] album_id The ID of the media album + /// @param[out] album The handle to the media album + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_album_destroy() + int media_album_get_album_from_db( + int album_id, + ffi.Pointer> album, + ) { + return _media_album_get_album_from_db( + album_id, + album, + ); + } + + late final _media_album_get_album_from_db_ptr = + _lookup>( + 'media_album_get_album_from_db'); + late final _dart_media_album_get_album_from_db + _media_album_get_album_from_db = _media_album_get_album_from_db_ptr + .asFunction<_dart_media_album_get_album_from_db>(); + + /// @brief Gets the number of the group for the passed @a filter from the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[in] group The type of the media group + /// @param[out] group_count The count of the media group + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_group_get_group_count_from_db( + ffi.Pointer filter, + int group, + ffi.Pointer group_count, + ) { + return _media_group_get_group_count_from_db( + filter, + group, + group_count, + ); + } + + late final _media_group_get_group_count_from_db_ptr = + _lookup>( + 'media_group_get_group_count_from_db'); + late final _dart_media_group_get_group_count_from_db + _media_group_get_group_count_from_db = + _media_group_get_group_count_from_db_ptr + .asFunction<_dart_media_group_get_group_count_from_db>(); + + /// @brief Iterates through the media group with an optional @a filter from the media database. + /// @details This function gets names of media group meeting the given filter. + /// The callback function will be invoked for every retrieved media group. + /// If @c NULL is passed to the filter, no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[in] group The type of the media group + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_group_cb(). + /// + /// @see #media_group_cb + /// @see media_content_connect() + /// @see media_filter_create() + int media_group_foreach_group_from_db( + ffi.Pointer filter, + int group, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_group_foreach_group_from_db( + filter, + group, + callback, + user_data, + ); + } + + late final _media_group_foreach_group_from_db_ptr = + _lookup>( + 'media_group_foreach_group_from_db'); + late final _dart_media_group_foreach_group_from_db + _media_group_foreach_group_from_db = + _media_group_foreach_group_from_db_ptr + .asFunction<_dart_media_group_foreach_group_from_db>(); + + /// @brief Gets the count of the media info for the given media group present in the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] group_name The name of the media group + /// @param[in] group The type of the media group + /// @param[in] filter The handle to the media filter + /// @param[out] media_count The count of the media + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_group_get_media_count_from_db( + ffi.Pointer group_name, + int group, + ffi.Pointer filter, + ffi.Pointer media_count, + ) { + return _media_group_get_media_count_from_db( + group_name, + group, + filter, + media_count, + ); + } + + late final _media_group_get_media_count_from_db_ptr = + _lookup>( + 'media_group_get_media_count_from_db'); + late final _dart_media_group_get_media_count_from_db + _media_group_get_media_count_from_db = + _media_group_get_media_count_from_db_ptr + .asFunction<_dart_media_group_get_media_count_from_db>(); + + /// @brief Iterates through the media files with an optional @a filter in the given @a group from the media database. + /// @details This function gets all media files associated with the given group and + /// meeting desired filter option and calls @a callback for + /// every retrieved media info. If @c NULL is passed to the @a filter, no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] group_name The name of the media group + /// @param[in] group The type of the media group + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_info_cb(). + /// + /// @see media_info_cb() + /// @see media_content_connect() + /// @see media_filter_create() + int media_group_foreach_media_from_db( + ffi.Pointer group_name, + int group, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_group_foreach_media_from_db( + group_name, + group, + filter, + callback, + user_data, + ); + } + + late final _media_group_foreach_media_from_db_ptr = + _lookup>( + 'media_group_foreach_media_from_db'); + late final _dart_media_group_foreach_media_from_db + _media_group_foreach_media_from_db = + _media_group_foreach_media_from_db_ptr + .asFunction<_dart_media_group_foreach_media_from_db>(); + + /// @brief Gets the number of playlists for the passed @a filter from the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[out] playlist_count The count of the media playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_playlist_get_playlist_count_from_db( + ffi.Pointer filter, + ffi.Pointer playlist_count, + ) { + return _media_playlist_get_playlist_count_from_db( + filter, + playlist_count, + ); + } + + late final _media_playlist_get_playlist_count_from_db_ptr = + _lookup>( + 'media_playlist_get_playlist_count_from_db'); + late final _dart_media_playlist_get_playlist_count_from_db + _media_playlist_get_playlist_count_from_db = + _media_playlist_get_playlist_count_from_db_ptr + .asFunction<_dart_media_playlist_get_playlist_count_from_db>(); + + /// @brief Iterates through the media playlists with an optional @a filter from the media database. + /// @details This function gets all media playlists meeting the given filter. + /// The callback function will be invoked for every retrieved media playlist. + /// If @c NULL is passed to the filter, no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_playlist_cb(). + /// + /// @see media_playlist_cb() + /// @see media_content_connect() + /// @see media_filter_create() + int media_playlist_foreach_playlist_from_db( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_playlist_foreach_playlist_from_db( + filter, + callback, + user_data, + ); + } + + late final _media_playlist_foreach_playlist_from_db_ptr = + _lookup>( + 'media_playlist_foreach_playlist_from_db'); + late final _dart_media_playlist_foreach_playlist_from_db + _media_playlist_foreach_playlist_from_db = + _media_playlist_foreach_playlist_from_db_ptr + .asFunction<_dart_media_playlist_foreach_playlist_from_db>(); + + /// @brief Gets the number of the media info for the given playlist present in the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] playlist_id The ID of the media playlist + /// @param[in] filter The handle to the media filter + /// @param[out] media_count The number of media items + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_playlist_get_media_count_from_db( + int playlist_id, + ffi.Pointer filter, + ffi.Pointer media_count, + ) { + return _media_playlist_get_media_count_from_db( + playlist_id, + filter, + media_count, + ); + } + + late final _media_playlist_get_media_count_from_db_ptr = + _lookup>( + 'media_playlist_get_media_count_from_db'); + late final _dart_media_playlist_get_media_count_from_db + _media_playlist_get_media_count_from_db = + _media_playlist_get_media_count_from_db_ptr + .asFunction<_dart_media_playlist_get_media_count_from_db>(); + + /// @brief Iterates through the media files with an optional @a filter in the given audio playlist from the media database. + /// @details This function gets all media files associated with the given media playlist and + /// meeting desired filter option and calls @a callback for + /// every retrieved media info. If @c NULL is passed to the @a filter, no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] playlist_id The ID of the media playlist + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_info_cb(). + /// + /// @see media_info_cb() + /// @see media_content_connect() + /// @see media_filter_create() + int media_playlist_foreach_media_from_db( + int playlist_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_playlist_foreach_media_from_db( + playlist_id, + filter, + callback, + user_data, + ); + } + + late final _media_playlist_foreach_media_from_db_ptr = + _lookup>( + 'media_playlist_foreach_media_from_db'); + late final _dart_media_playlist_foreach_media_from_db + _media_playlist_foreach_media_from_db = + _media_playlist_foreach_media_from_db_ptr + .asFunction<_dart_media_playlist_foreach_media_from_db>(); + + /// @brief Inserts a new playlist with the given name into the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @remarks The @a playlist should be released using media_playlist_destroy(). + /// + /// @param[in] name The name of the inserted playlist + /// @param[out] playlist The handle to the media playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_playlist_delete_from_db() + int media_playlist_insert_to_db( + ffi.Pointer name, + ffi.Pointer> playlist, + ) { + return _media_playlist_insert_to_db( + name, + playlist, + ); + } + + late final _media_playlist_insert_to_db_ptr = + _lookup>( + 'media_playlist_insert_to_db'); + late final _dart_media_playlist_insert_to_db _media_playlist_insert_to_db = + _media_playlist_insert_to_db_ptr + .asFunction<_dart_media_playlist_insert_to_db>(); + + /// @brief Deletes the given playlist from the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @param[in] playlist_id The ID of media playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_playlist_insert_to_db() + int media_playlist_delete_from_db( + int playlist_id, + ) { + return _media_playlist_delete_from_db( + playlist_id, + ); + } + + late final _media_playlist_delete_from_db_ptr = + _lookup>( + 'media_playlist_delete_from_db'); + late final _dart_media_playlist_delete_from_db + _media_playlist_delete_from_db = _media_playlist_delete_from_db_ptr + .asFunction<_dart_media_playlist_delete_from_db>(); + + /// @brief Gets the media playlist from the media database. + /// + /// @details This function creates a new media playlist handle from the media database by the given @a playlist_id. + /// The media playlist will be created and will be filled with the playlist information. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a playlist should be released using media_playlist_destroy(). + /// + /// @param[in] playlist_id The ID of the media playlist + /// @param[out] playlist The handle to the media playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_playlist_destroy() + int media_playlist_get_playlist_from_db( + int playlist_id, + ffi.Pointer> playlist, + ) { + return _media_playlist_get_playlist_from_db( + playlist_id, + playlist, + ); + } + + late final _media_playlist_get_playlist_from_db_ptr = + _lookup>( + 'media_playlist_get_playlist_from_db'); + late final _dart_media_playlist_get_playlist_from_db + _media_playlist_get_playlist_from_db = + _media_playlist_get_playlist_from_db_ptr + .asFunction<_dart_media_playlist_get_playlist_from_db>(); + + /// @brief Destroys a playlist handle. + /// @details This function frees all resources related to the playlist handle. This + /// handle no longer can be used to perform any operation. A new handle has to + /// be created before next usage. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] playlist The handle to the media playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre Get a copy of playlist handle by calling media_playlist_clone() or media_playlist_insert_to_db(). + /// + /// @see media_playlist_clone() + int media_playlist_destroy( + ffi.Pointer playlist, + ) { + return _media_playlist_destroy( + playlist, + ); + } + + late final _media_playlist_destroy_ptr = + _lookup>( + 'media_playlist_destroy'); + late final _dart_media_playlist_destroy _media_playlist_destroy = + _media_playlist_destroy_ptr.asFunction<_dart_media_playlist_destroy>(); + + /// @brief Clones a playlist handle. + /// @details This function copies the media playlist handle from a source to + /// destination. There is no media_playlist_create() function. The media_playlist_h is created internally and available through + /// media playlist foreach function such as media_playlist_foreach_playlist_from_db(). + /// To use this handle outside of these foreach functions, use this function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @ a dst should be released using media_playlist_destroy(). + /// + /// @param[out] dst The destination handle to the media playlist + /// @param[in] src The source handle to the media playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see media_playlist_destroy() + /// @see media_playlist_foreach_playlist_from_db() + int media_playlist_clone( + ffi.Pointer> dst, + ffi.Pointer src, + ) { + return _media_playlist_clone( + dst, + src, + ); + } + + late final _media_playlist_clone_ptr = + _lookup>( + 'media_playlist_clone'); + late final _dart_media_playlist_clone _media_playlist_clone = + _media_playlist_clone_ptr.asFunction<_dart_media_playlist_clone>(); + + /// @brief Gets the media playlist ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] playlist The handle to the media playlist + /// @param[out] playlist_id The ID of the media playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_playlist_get_playlist_id( + ffi.Pointer playlist, + ffi.Pointer playlist_id, + ) { + return _media_playlist_get_playlist_id( + playlist, + playlist_id, + ); + } + + late final _media_playlist_get_playlist_id_ptr = + _lookup>( + 'media_playlist_get_playlist_id'); + late final _dart_media_playlist_get_playlist_id + _media_playlist_get_playlist_id = _media_playlist_get_playlist_id_ptr + .asFunction<_dart_media_playlist_get_playlist_id>(); + + /// @brief Gets a name of the playlist. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a playlist_name should be released using free(). + /// + /// @param[in] playlist The handle to the media playlist + /// @param[out] playlist_name The playlist name + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_playlist_get_name( + ffi.Pointer playlist, + ffi.Pointer> playlist_name, + ) { + return _media_playlist_get_name( + playlist, + playlist_name, + ); + } + + late final _media_playlist_get_name_ptr = + _lookup>( + 'media_playlist_get_name'); + late final _dart_media_playlist_get_name _media_playlist_get_name = + _media_playlist_get_name_ptr.asFunction<_dart_media_playlist_get_name>(); + + /// @brief Sets the name of the playlist. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] playlist The handle to the media playlist + /// @param[in] playlist_name The name of the media playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @post media_playlist_update_to_db() + int media_playlist_set_name( + ffi.Pointer playlist, + ffi.Pointer playlist_name, + ) { + return _media_playlist_set_name( + playlist, + playlist_name, + ); + } + + late final _media_playlist_set_name_ptr = + _lookup>( + 'media_playlist_set_name'); + late final _dart_media_playlist_set_name _media_playlist_set_name = + _media_playlist_set_name_ptr.asFunction<_dart_media_playlist_set_name>(); + + /// @brief Gets a thumbnail path of the playlist. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a path should be released using free(). + /// + /// @param[in] playlist The handle to the media playlist + /// @param[out] path The path of the thumbnail + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_playlist_get_thumbnail_path( + ffi.Pointer playlist, + ffi.Pointer> path, + ) { + return _media_playlist_get_thumbnail_path( + playlist, + path, + ); + } + + late final _media_playlist_get_thumbnail_path_ptr = + _lookup>( + 'media_playlist_get_thumbnail_path'); + late final _dart_media_playlist_get_thumbnail_path + _media_playlist_get_thumbnail_path = + _media_playlist_get_thumbnail_path_ptr + .asFunction<_dart_media_playlist_get_thumbnail_path>(); + + /// @brief Sets the thumbnail path of the playlist. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] playlist The handle to the media playlist + /// @param[in] path The path of the thumbnail + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @post media_playlist_update_to_db() + int media_playlist_set_thumbnail_path( + ffi.Pointer playlist, + ffi.Pointer path, + ) { + return _media_playlist_set_thumbnail_path( + playlist, + path, + ); + } + + late final _media_playlist_set_thumbnail_path_ptr = + _lookup>( + 'media_playlist_set_thumbnail_path'); + late final _dart_media_playlist_set_thumbnail_path + _media_playlist_set_thumbnail_path = + _media_playlist_set_thumbnail_path_ptr + .asFunction<_dart_media_playlist_set_thumbnail_path>(); + + /// @brief Sets the playing order in the playlist. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] playlist The handle to the media playlist + /// @param[in] playlist_member_id The ID of the playlist member + /// @param[in] play_order The playing order + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @post media_playlist_update_to_db() + int media_playlist_set_play_order( + ffi.Pointer playlist, + int playlist_member_id, + int play_order, + ) { + return _media_playlist_set_play_order( + playlist, + playlist_member_id, + play_order, + ); + } + + late final _media_playlist_set_play_order_ptr = + _lookup>( + 'media_playlist_set_play_order'); + late final _dart_media_playlist_set_play_order + _media_playlist_set_play_order = _media_playlist_set_play_order_ptr + .asFunction<_dart_media_playlist_set_play_order>(); + + /// @brief Adds a new media info to the playlist. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] playlist The handle to the media playlist + /// @param[in] media_id The media ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post media_playlist_update_to_db() + /// + /// @see media_content_connect() + /// @see media_playlist_remove_media() + int media_playlist_add_media( + ffi.Pointer playlist, + ffi.Pointer media_id, + ) { + return _media_playlist_add_media( + playlist, + media_id, + ); + } + + late final _media_playlist_add_media_ptr = + _lookup>( + 'media_playlist_add_media'); + late final _dart_media_playlist_add_media _media_playlist_add_media = + _media_playlist_add_media_ptr + .asFunction<_dart_media_playlist_add_media>(); + + /// @brief Removes the playlist members related with the media from the given playlist. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] playlist The handle to the media playlist + /// @param[in] playlist_member_id The ID of the playlist member + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post media_playlist_update_to_db() + /// + /// @see media_content_connect() + /// @see media_playlist_add_media() + int media_playlist_remove_media( + ffi.Pointer playlist, + int playlist_member_id, + ) { + return _media_playlist_remove_media( + playlist, + playlist_member_id, + ); + } + + late final _media_playlist_remove_media_ptr = + _lookup>( + 'media_playlist_remove_media'); + late final _dart_media_playlist_remove_media _media_playlist_remove_media = + _media_playlist_remove_media_ptr + .asFunction<_dart_media_playlist_remove_media>(); + + /// @brief Gets the played order of the playlist. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] playlist The handle to the media playlist + /// @param[in] playlist_member_id The ID of the playlist member + /// @param[out] play_order The played order + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_playlist_get_play_order( + ffi.Pointer playlist, + int playlist_member_id, + ffi.Pointer play_order, + ) { + return _media_playlist_get_play_order( + playlist, + playlist_member_id, + play_order, + ); + } + + late final _media_playlist_get_play_order_ptr = + _lookup>( + 'media_playlist_get_play_order'); + late final _dart_media_playlist_get_play_order + _media_playlist_get_play_order = _media_playlist_get_play_order_ptr + .asFunction<_dart_media_playlist_get_play_order>(); + + /// @brief Updates the media playlist to the media database. + /// + /// @details The function updates the given media playlist in the media database. + /// The function should be called after any change in the playlist, to be updated to the media database. + /// For example, after using media_playlist_set_name() for setting the name of the playlist, the + /// media_playlist_update_to_db() function should be called so as to update + /// the given playlist attributes in the media database. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @param[in] playlist The handle to the media playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_playlist_destroy() + /// @see media_playlist_add_media() + /// @see media_playlist_remove_media() + /// @see media_playlist_set_name() + /// @see media_playlist_set_play_order() + int media_playlist_update_to_db( + ffi.Pointer playlist, + ) { + return _media_playlist_update_to_db( + playlist, + ); + } + + late final _media_playlist_update_to_db_ptr = + _lookup>( + 'media_playlist_update_to_db'); + late final _dart_media_playlist_update_to_db _media_playlist_update_to_db = + _media_playlist_update_to_db_ptr + .asFunction<_dart_media_playlist_update_to_db>(); + + /// @brief Imports the playlist from m3u playlist file. + /// @details This function reads a playlist from the m3u playlist file and insert into the db. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @remarks The @ a playlist should be released using media_playlist_destroy(). + /// @remarks http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage. \n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. \n + /// This function does not support the file of extended m3u playlist. + /// + /// @param[in] playlist_name The name of the media playlist to save + /// @param[in] path The path to import the playlist file + /// @param[out] playlist The handle to the media playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + int media_playlist_import_from_file( + ffi.Pointer playlist_name, + ffi.Pointer path, + ffi.Pointer> playlist, + ) { + return _media_playlist_import_from_file( + playlist_name, + path, + playlist, + ); + } + + late final _media_playlist_import_from_file_ptr = + _lookup>( + 'media_playlist_import_from_file'); + late final _dart_media_playlist_import_from_file + _media_playlist_import_from_file = _media_playlist_import_from_file_ptr + .asFunction<_dart_media_playlist_import_from_file>(); + + /// @brief Exports the playlist to m3u playlist file. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage. \n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. + /// + /// @param[in] playlist The handle to the media playlist + /// @param[in] path path The path to export the playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + int media_playlist_export_to_file( + ffi.Pointer playlist, + ffi.Pointer path, + ) { + return _media_playlist_export_to_file( + playlist, + path, + ); + } + + late final _media_playlist_export_to_file_ptr = + _lookup>( + 'media_playlist_export_to_file'); + late final _dart_media_playlist_export_to_file + _media_playlist_export_to_file = _media_playlist_export_to_file_ptr + .asFunction<_dart_media_playlist_export_to_file>(); + + /// @brief Inserts a new bookmark in media on the specified time offset to the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @param[in] media_id The media ID + /// @param[in] time The bookmark time offset (in seconds) + /// @param[in] thumbnail_path The thumbnail path of video bookmark\ n + /// If the media type is audio, then thumbnail is null. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_bookmark_delete_from_db() + int media_bookmark_insert_to_db( + ffi.Pointer media_id, + int time, + ffi.Pointer thumbnail_path, + ) { + return _media_bookmark_insert_to_db( + media_id, + time, + thumbnail_path, + ); + } + + late final _media_bookmark_insert_to_db_ptr = + _lookup>( + 'media_bookmark_insert_to_db'); + late final _dart_media_bookmark_insert_to_db _media_bookmark_insert_to_db = + _media_bookmark_insert_to_db_ptr + .asFunction<_dart_media_bookmark_insert_to_db>(); + + /// @brief Removes a media bookmark from the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @param[in] bookmark_id The ID of the media bookmark + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_bookmark_insert_to_db() + int media_bookmark_delete_from_db( + int bookmark_id, + ) { + return _media_bookmark_delete_from_db( + bookmark_id, + ); + } + + late final _media_bookmark_delete_from_db_ptr = + _lookup>( + 'media_bookmark_delete_from_db'); + late final _dart_media_bookmark_delete_from_db + _media_bookmark_delete_from_db = _media_bookmark_delete_from_db_ptr + .asFunction<_dart_media_bookmark_delete_from_db>(); + + /// @brief Gets the number of bookmarks with an optional filter from the media database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[out] bookmark_count The count of the media bookmark + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_bookmark_get_bookmark_count_from_db( + ffi.Pointer filter, + ffi.Pointer bookmark_count, + ) { + return _media_bookmark_get_bookmark_count_from_db( + filter, + bookmark_count, + ); + } + + late final _media_bookmark_get_bookmark_count_from_db_ptr = + _lookup>( + 'media_bookmark_get_bookmark_count_from_db'); + late final _dart_media_bookmark_get_bookmark_count_from_db + _media_bookmark_get_bookmark_count_from_db = + _media_bookmark_get_bookmark_count_from_db_ptr + .asFunction<_dart_media_bookmark_get_bookmark_count_from_db>(); + + /// @brief Iterates through the bookmarks with an optional filter from the media database. + /// @details This function gets all bookmarks associated with the given filter and calls @a callback for every retrieved media bookmark. + /// If @c NULL is passed to the @a filter, then no filtering is applied. + /// @since_tizen 4.0 + /// + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_bookmark_cb(). + /// + /// @see media_content_connect() + /// @see media_bookmark_cb() + /// @see media_filter_create() + int media_bookmark_foreach_bookmark_from_db( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_bookmark_foreach_bookmark_from_db( + filter, + callback, + user_data, + ); + } + + late final _media_bookmark_foreach_bookmark_from_db_ptr = + _lookup>( + 'media_bookmark_foreach_bookmark_from_db'); + late final _dart_media_bookmark_foreach_bookmark_from_db + _media_bookmark_foreach_bookmark_from_db = + _media_bookmark_foreach_bookmark_from_db_ptr + .asFunction<_dart_media_bookmark_foreach_bookmark_from_db>(); + + /// @brief Clones a media bookmark. + /// @details This function copies the media bookmark handle from a source to destination. There is no media_bookmark_create() function. + /// The media_bookmark_h is created internally and available through media bookmark foreach function such as media_info_foreach_bookmark_from_db(). + /// To use this handle outside of these foreach functions, use this function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a dst should be released using media_bookmark_destroy(). + /// + /// @param[out] dst The destination handle to the media bookmark + /// @param[in] src The source handle to the media bookmark + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see media_bookmark_destroy() + /// @see media_info_foreach_bookmark_from_db() + int media_bookmark_clone( + ffi.Pointer> dst, + ffi.Pointer src, + ) { + return _media_bookmark_clone( + dst, + src, + ); + } + + late final _media_bookmark_clone_ptr = + _lookup>( + 'media_bookmark_clone'); + late final _dart_media_bookmark_clone _media_bookmark_clone = + _media_bookmark_clone_ptr.asFunction<_dart_media_bookmark_clone>(); + + /// @brief Destroys a media bookmark. + /// @details This function frees all the resources related to the bookmark handle. This handle + /// no longer can be used to perform any operation. A new handle has to + /// be created before the next use. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] bookmark The handle to the media bookmark + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre Get copy of bookmark handle by calling media_bookmark_clone(). + /// + /// @see media_bookmark_clone() + int media_bookmark_destroy( + ffi.Pointer bookmark, + ) { + return _media_bookmark_destroy( + bookmark, + ); + } + + late final _media_bookmark_destroy_ptr = + _lookup>( + 'media_bookmark_destroy'); + late final _dart_media_bookmark_destroy _media_bookmark_destroy = + _media_bookmark_destroy_ptr.asFunction<_dart_media_bookmark_destroy>(); + + /// @brief Gets the bookmark ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] bookmark The handle to the media bookmark + /// @param[out] bookmark_id The ID of the media bookmark + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_bookmark_get_bookmark_id( + ffi.Pointer bookmark, + ffi.Pointer bookmark_id, + ) { + return _media_bookmark_get_bookmark_id( + bookmark, + bookmark_id, + ); + } + + late final _media_bookmark_get_bookmark_id_ptr = + _lookup>( + 'media_bookmark_get_bookmark_id'); + late final _dart_media_bookmark_get_bookmark_id + _media_bookmark_get_bookmark_id = _media_bookmark_get_bookmark_id_ptr + .asFunction<_dart_media_bookmark_get_bookmark_id>(); + + /// @brief Gets the bookmark time marked parameter. + /// @details This function returns time offset in seconds from beginning of the movie on which bookmark + /// was placed. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] bookmark The handle to the media bookmark + /// @param[out] marked_time The bookmark time offset (in seconds) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_bookmark_get_marked_time( + ffi.Pointer bookmark, + ffi.Pointer marked_time, + ) { + return _media_bookmark_get_marked_time( + bookmark, + marked_time, + ); + } + + late final _media_bookmark_get_marked_time_ptr = + _lookup>( + 'media_bookmark_get_marked_time'); + late final _dart_media_bookmark_get_marked_time + _media_bookmark_get_marked_time = _media_bookmark_get_marked_time_ptr + .asFunction<_dart_media_bookmark_get_marked_time>(); + + /// @brief Gets the media bookmark thumbnail. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a path should be released using free(). + /// + /// @param[in] bookmark The handle to the media bookmark + /// @param[out] path The thumbnail path of media bookmark + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_bookmark_get_thumbnail_path( + ffi.Pointer bookmark, + ffi.Pointer> path, + ) { + return _media_bookmark_get_thumbnail_path( + bookmark, + path, + ); + } + + late final _media_bookmark_get_thumbnail_path_ptr = + _lookup>( + 'media_bookmark_get_thumbnail_path'); + late final _dart_media_bookmark_get_thumbnail_path + _media_bookmark_get_thumbnail_path = + _media_bookmark_get_thumbnail_path_ptr + .asFunction<_dart_media_bookmark_get_thumbnail_path>(); + + /// @brief Gets the media bookmark name which user set. + /// @since_tizen 4.0 + /// + /// @remarks The @a name should be released using free(). + /// + /// @param[in] bookmark The handle to the media bookmark + /// @param[out] name The name of media bookmark. If name was not set, empty string is returned. + /// If User set bookmark name to NULL, name will be empty string also. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_bookmark_get_name( + ffi.Pointer bookmark, + ffi.Pointer> name, + ) { + return _media_bookmark_get_name( + bookmark, + name, + ); + } + + late final _media_bookmark_get_name_ptr = + _lookup>( + 'media_bookmark_get_name'); + late final _dart_media_bookmark_get_name _media_bookmark_get_name = + _media_bookmark_get_name_ptr.asFunction<_dart_media_bookmark_get_name>(); + + /// @brief Sets the media bookmark name. + /// @since_tizen 4.0 + /// + /// @param[in] bookmark The handle to the media bookmark + /// @param[in] name The name of media bookmark. Can be NULL, empty or non-empty string. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @post media_bookmark_update_to_db() + int media_bookmark_set_name( + ffi.Pointer bookmark, + ffi.Pointer name, + ) { + return _media_bookmark_set_name( + bookmark, + name, + ); + } + + late final _media_bookmark_set_name_ptr = + _lookup>( + 'media_bookmark_set_name'); + late final _dart_media_bookmark_set_name _media_bookmark_set_name = + _media_bookmark_set_name_ptr.asFunction<_dart_media_bookmark_set_name>(); + + /// @brief Updates bookmark information to the media database. + /// @details The function updates the given bookmark meta in the media database. \n + /// The function should be called after any change in bookmark attributes, to be updated to the media database. \n + /// For example, after using media_bookmark_set_name() for setting the name of the bookmark, \n + /// the media_bookmark_update_to_db() function should be called so as to update the given bookmark attributes in the media database. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @remarks Do not call this function in callback function of foreach function like media_info_foreach_bookmark_from_db(). + /// @param[in] bookmark The handle to the media bookmark + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied when Application has no privilege + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_bookmark_set_name() + int media_bookmark_update_to_db( + ffi.Pointer bookmark, + ) { + return _media_bookmark_update_to_db( + bookmark, + ); + } + + late final _media_bookmark_update_to_db_ptr = + _lookup>( + 'media_bookmark_update_to_db'); + late final _dart_media_bookmark_update_to_db _media_bookmark_update_to_db = + _media_bookmark_update_to_db_ptr + .asFunction<_dart_media_bookmark_update_to_db>(); + + /// @brief Gets media storage from database. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a storage should be released using media_storage_destroy(). + /// + /// @param[in] storage_id The ID of the media storage + /// @param[out] storage The media storage handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_storage_get_storage_info_from_db( + ffi.Pointer storage_id, + ffi.Pointer> storage, + ) { + return _media_storage_get_storage_info_from_db( + storage_id, + storage, + ); + } + + late final _media_storage_get_storage_info_from_db_ptr = + _lookup>( + 'media_storage_get_storage_info_from_db'); + late final _dart_media_storage_get_storage_info_from_db + _media_storage_get_storage_info_from_db = + _media_storage_get_storage_info_from_db_ptr + .asFunction<_dart_media_storage_get_storage_info_from_db>(); + + /// @brief Gets the count of media storage for the passed @a filter from the media database. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[out] storage_count The count of storage + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_storage_get_storage_count_from_db( + ffi.Pointer filter, + ffi.Pointer storage_count, + ) { + return _media_storage_get_storage_count_from_db( + filter, + storage_count, + ); + } + + late final _media_storage_get_storage_count_from_db_ptr = + _lookup>( + 'media_storage_get_storage_count_from_db'); + late final _dart_media_storage_get_storage_count_from_db + _media_storage_get_storage_count_from_db = + _media_storage_get_storage_count_from_db_ptr + .asFunction<_dart_media_storage_get_storage_count_from_db>(); + + /// @brief Iterates through media storage from the media database. + /// @details This function gets all media storage handles meeting the given @a filter. + /// The @a callback function will be invoked for every retrieved media storage. + /// If @c NULL is passed to the @a filter, then no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_storage_destroy(). + /// + /// @see media_content_connect() + /// @see media_storage_destroy() + int media_storage_foreach_storage_from_db( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_storage_foreach_storage_from_db( + filter, + callback, + user_data, + ); + } + + late final _media_storage_foreach_storage_from_db_ptr = + _lookup>( + 'media_storage_foreach_storage_from_db'); + late final _dart_media_storage_foreach_storage_from_db + _media_storage_foreach_storage_from_db = + _media_storage_foreach_storage_from_db_ptr + .asFunction<_dart_media_storage_foreach_storage_from_db>(); + + /// @brief Gets the count of media files for the passed @a filter in the given @a storage_id from the media database. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] storage_id The ID of the media storage + /// @param[in] filter The handle to the media filter + /// @param[out] media_count The count of media storage items + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + int media_storage_get_media_count_from_db( + ffi.Pointer storage_id, + ffi.Pointer filter, + ffi.Pointer media_count, + ) { + return _media_storage_get_media_count_from_db( + storage_id, + filter, + media_count, + ); + } + + late final _media_storage_get_media_count_from_db_ptr = + _lookup>( + 'media_storage_get_media_count_from_db'); + late final _dart_media_storage_get_media_count_from_db + _media_storage_get_media_count_from_db = + _media_storage_get_media_count_from_db_ptr + .asFunction<_dart_media_storage_get_media_count_from_db>(); + + /// @brief Iterates through the media files with an optional @a filter in the given @a storage_id from the media database. + /// @details This function gets all media files associated with the given storage and + /// meeting desired filter option and calls @a callback for + /// every retrieved media item. If @c NULL is passed to the @a filter, no filtering is applied. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks Do not call updating DB function like media_info_update_to_db(), media_info_refresh_metadata_to_db(), audio_meta_update_to_db(), image_meta_update_to_db() and video_meta_update_to_db() in your callback function, + /// your callback function is invoked as inline function. \n + /// So, your callback function is in read state in SQLite. When you are in read state, sometimes you do not update DB. \n + /// We do not recommend you call updating DB function in callback of foreach function. + /// + /// @param[in] storage_id The ID of the media storage + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_info_cb(). + /// + /// @see #media_info_cb + /// @see media_content_connect() + /// @see media_filter_create() + int media_storage_foreach_media_from_db( + ffi.Pointer storage_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_storage_foreach_media_from_db( + storage_id, + filter, + callback, + user_data, + ); + } + + late final _media_storage_foreach_media_from_db_ptr = + _lookup>( + 'media_storage_foreach_media_from_db'); + late final _dart_media_storage_foreach_media_from_db + _media_storage_foreach_media_from_db = + _media_storage_foreach_media_from_db_ptr + .asFunction<_dart_media_storage_foreach_media_from_db>(); + + /// @brief Destroys media storage handle. + /// @details The function frees all resources related to the media storage handle. This handle + /// can no longer be used to perform any operation. New media storage handle has to + /// be created before the next usage. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] storage The media storage handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre Get copy of media_storage_h handle by calling media_storage_clone(). + /// + /// @see media_storage_clone() + int media_storage_destroy( + ffi.Pointer storage, + ) { + return _media_storage_destroy( + storage, + ); + } + + late final _media_storage_destroy_ptr = + _lookup>( + 'media_storage_destroy'); + late final _dart_media_storage_destroy _media_storage_destroy = + _media_storage_destroy_ptr.asFunction<_dart_media_storage_destroy>(); + + /// @brief Clones the media storage handle. + /// + /// @details This function copies the media storage handle from a source to the destination. + /// There is no media_storage_create() function. The media_storage_h is created internally and + /// available through media storage foreach function such as media_storage_foreach_storage_from_db(). + /// To use this handle outside of these foreach functions, use this function. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a dst should be released using media_storage_destroy(). + /// + /// @param[out] dst The destination handle to the media storage + /// @param[in] src The source handle to the media storage + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_storage_destroy() + /// @see media_storage_foreach_storage_from_db() + /// @see media_storage_get_storage_info_from_db() + int media_storage_clone( + ffi.Pointer> dst, + ffi.Pointer src, + ) { + return _media_storage_clone( + dst, + src, + ); + } + + late final _media_storage_clone_ptr = + _lookup>( + 'media_storage_clone'); + late final _dart_media_storage_clone _media_storage_clone = + _media_storage_clone_ptr.asFunction<_dart_media_storage_clone>(); + + /// @brief Gets the storage id of media storage. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a storage_id should be released using free(). + /// + /// @param[in] storage The media storage handle + /// @param[out] storage_id The ID of the media storage + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_storage_get_id( + ffi.Pointer storage, + ffi.Pointer> storage_id, + ) { + return _media_storage_get_id( + storage, + storage_id, + ); + } + + late final _media_storage_get_id_ptr = + _lookup>( + 'media_storage_get_id'); + late final _dart_media_storage_get_id _media_storage_get_id = + _media_storage_get_id_ptr.asFunction<_dart_media_storage_get_id>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Gets the storage name of media storage. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a storage_name should be released using free(). + /// If the requested storage is not the cloud storage, this function returns NULL. + /// + /// @param[in] storage The media storage handle + /// @param[out] storage_name The storage name of the media storage + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_storage_get_name( + ffi.Pointer storage, + ffi.Pointer> storage_name, + ) { + return _media_storage_get_name( + storage, + storage_name, + ); + } + + late final _media_storage_get_name_ptr = + _lookup>( + 'media_storage_get_name'); + late final _dart_media_storage_get_name _media_storage_get_name = + _media_storage_get_name_ptr.asFunction<_dart_media_storage_get_name>(); + + /// @brief Gets the storage path of media storage. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a storage_path should be released using free(). + /// + /// @param[in] storage The media storage handle + /// @param[out] storage_path The storage path of the media storage + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + int media_storage_get_path( + ffi.Pointer storage, + ffi.Pointer> storage_path, + ) { + return _media_storage_get_path( + storage, + storage_path, + ); + } + + late final _media_storage_get_path_ptr = + _lookup>( + 'media_storage_get_path'); + late final _dart_media_storage_get_path _media_storage_get_path = + _media_storage_get_path_ptr.asFunction<_dart_media_storage_get_path>(); + + /// @brief Gets the storage type of media storage. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] storage The media storage handle + /// @param[out] storage_type The storage type of the media storage + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_storage_get_type( + ffi.Pointer storage, + ffi.Pointer storage_type, + ) { + return _media_storage_get_type( + storage, + storage_type, + ); + } + + late final _media_storage_get_type_ptr = + _lookup>( + 'media_storage_get_type'); + late final _dart_media_storage_get_type _media_storage_get_type = + _media_storage_get_type_ptr.asFunction<_dart_media_storage_get_type>(); + + /// @brief Clones the media face handle. + /// @details This function copies the media face handle from a source to + /// destination. There is no media_face_create() function. The media_face_h is created internally and available through + /// media face foreach function such as media_face_foreach_face_from_db(). To use this handle outside of these foreach functions, + /// use this function. + /// + /// @since_tizen 3.0 + /// @remarks The @a dst should be released using media_face_destroy(). + /// + /// @param[out] dst The destination handle to the media face + /// @param[in] src The source handle to the media face + /// + /// @return 0 on success, otherwise a negative error value. + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see media_face_destroy() + /// @see media_face_foreach_face_from_db() + int media_face_clone( + ffi.Pointer> dst, + ffi.Pointer src, + ) { + return _media_face_clone( + dst, + src, + ); + } + + late final _media_face_clone_ptr = + _lookup>('media_face_clone'); + late final _dart_media_face_clone _media_face_clone = + _media_face_clone_ptr.asFunction<_dart_media_face_clone>(); + + /// @brief Destroys the media face handle. + /// @details Function frees all resources related to media face handle. This + /// handle no longer can be used to perform any operation. New handle has to + /// be created before next usage. + /// + /// @since_tizen 3.0 + /// + /// @param[in] face The media face handle + /// + /// @return 0 on success, otherwise a negative error value. + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre Get copy of media face handle by calling media_face_clone() or Get media face handle by calling media_info_foreach_face_from_db() + /// + /// @see media_face_clone() + int media_face_destroy( + ffi.Pointer face, + ) { + return _media_face_destroy( + face, + ); + } + + late final _media_face_destroy_ptr = + _lookup>('media_face_destroy'); + late final _dart_media_face_destroy _media_face_destroy = + _media_face_destroy_ptr.asFunction<_dart_media_face_destroy>(); + + /// @brief Gets the face id from the media face handle. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a face_id should be released using free(). + /// + /// @param[in] face The media face handle + /// @param[out] face_id The ID of the media face + /// + /// @return 0 on success, otherwise a negative error value. + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_face_get_face_id( + ffi.Pointer face, + ffi.Pointer> face_id, + ) { + return _media_face_get_face_id( + face, + face_id, + ); + } + + late final _media_face_get_face_id_ptr = + _lookup>( + 'media_face_get_face_id'); + late final _dart_media_face_get_face_id _media_face_get_face_id = + _media_face_get_face_id_ptr.asFunction<_dart_media_face_get_face_id>(); + + /// @brief Gets the media id from the media face handle. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a media_id should be released using free(). + /// + /// @param[in] face The media face handle + /// @param[out] media_id The media ID + /// + /// @return 0 on success, otherwise a negative error value. + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_face_get_media_id( + ffi.Pointer face, + ffi.Pointer> media_id, + ) { + return _media_face_get_media_id( + face, + media_id, + ); + } + + late final _media_face_get_media_id_ptr = + _lookup>( + 'media_face_get_media_id'); + late final _dart_media_face_get_media_id _media_face_get_media_id = + _media_face_get_media_id_ptr.asFunction<_dart_media_face_get_media_id>(); + + /// @brief Gets the face's rectangle from the media face handle. + /// @details This function can get the face's rectangle information. returned rectangle information includes the orientation value. + /// + /// @since_tizen 3.0 + /// + /// @param[in] face The media face handle + /// @param[out] rect_x The x position of the media face + /// @param[out] rect_y The y position of the media face + /// @param[out] rect_w The width of the media face + /// @param[out] rect_h The height of the media face + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_face_get_face_rect( + ffi.Pointer face, + ffi.Pointer rect_x, + ffi.Pointer rect_y, + ffi.Pointer rect_w, + ffi.Pointer rect_h, + ) { + return _media_face_get_face_rect( + face, + rect_x, + rect_y, + rect_w, + rect_h, + ); + } + + late final _media_face_get_face_rect_ptr = + _lookup>( + 'media_face_get_face_rect'); + late final _dart_media_face_get_face_rect _media_face_get_face_rect = + _media_face_get_face_rect_ptr + .asFunction<_dart_media_face_get_face_rect>(); + + /// @brief Gets the orientation from the media face handle. + /// @details This function can get the orientation value from the original image. + /// + /// @since_tizen 3.0 + /// + /// @param[in] face The media face handle + /// @param[out] orientation The orientation of the media face + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_face_get_orientation( + ffi.Pointer face, + ffi.Pointer orientation, + ) { + return _media_face_get_orientation( + face, + orientation, + ); + } + + late final _media_face_get_orientation_ptr = + _lookup>( + 'media_face_get_orientation'); + late final _dart_media_face_get_orientation _media_face_get_orientation = + _media_face_get_orientation_ptr + .asFunction<_dart_media_face_get_orientation>(); + + /// @brief Gets the tag from the media face handle. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a tag should be released using free(). + /// + /// @param[in] face The media face handle + /// @param[out] tag The tag of the media face + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + int media_face_get_tag( + ffi.Pointer face, + ffi.Pointer> tag, + ) { + return _media_face_get_tag( + face, + tag, + ); + } + + late final _media_face_get_tag_ptr = + _lookup>('media_face_get_tag'); + late final _dart_media_face_get_tag _media_face_get_tag = + _media_face_get_tag_ptr.asFunction<_dart_media_face_get_tag>(); + + /// @brief Creates the media face handle. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a face should be released using media_face_destroy(). + /// + /// @param[in] media_id The media ID + /// @param[out] face The media face handle + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_face_destroy() + int media_face_create( + ffi.Pointer media_id, + ffi.Pointer> face, + ) { + return _media_face_create( + media_id, + face, + ); + } + + late final _media_face_create_ptr = + _lookup>('media_face_create'); + late final _dart_media_face_create _media_face_create = + _media_face_create_ptr.asFunction<_dart_media_face_create>(); + + /// @brief Sets the face rectangle of the media face handle. + /// + /// @since_tizen 3.0 + /// + /// @param[in] face The media face handle + /// @param[in] rect_x The integer to set as a position x of face rectangle + /// @param[in] rect_y The integer to set as a position y of face rectangle + /// @param[in] rect_w The integer to set as a width of face rectangle + /// @param[in] rect_h The integer to set as a height of face rectangle + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_face_insert_to_db() + /// @post media_face_update_to_db() + int media_face_set_face_rect( + ffi.Pointer face, + int rect_x, + int rect_y, + int rect_w, + int rect_h, + ) { + return _media_face_set_face_rect( + face, + rect_x, + rect_y, + rect_w, + rect_h, + ); + } + + late final _media_face_set_face_rect_ptr = + _lookup>( + 'media_face_set_face_rect'); + late final _dart_media_face_set_face_rect _media_face_set_face_rect = + _media_face_set_face_rect_ptr + .asFunction<_dart_media_face_set_face_rect>(); + + /// @brief Sets the orientation of the media face handle. + /// @details This function may set the value of the original image orientation. + /// + /// @since_tizen 3.0 + /// + /// @param[in] face The media face handle + /// @param[in] orientation The integer to set as an orientation + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post media_face_insert_to_db() + /// @post media_face_update_to_db() + int media_face_set_orientation( + ffi.Pointer face, + int orientation, + ) { + return _media_face_set_orientation( + face, + orientation, + ); + } + + late final _media_face_set_orientation_ptr = + _lookup>( + 'media_face_set_orientation'); + late final _dart_media_face_set_orientation _media_face_set_orientation = + _media_face_set_orientation_ptr + .asFunction<_dart_media_face_set_orientation>(); + + /// @brief Sets the tag of the media face handle. + /// + /// @since_tizen 3.0 + /// + /// @param[in] face The media face handle + /// @param[in] tag The tag of the media face + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @post media_face_insert_to_db() + /// @post media_face_update_to_db() + int media_face_set_tag( + ffi.Pointer face, + ffi.Pointer tag, + ) { + return _media_face_set_tag( + face, + tag, + ); + } + + late final _media_face_set_tag_ptr = + _lookup>('media_face_set_tag'); + late final _dart_media_face_set_tag _media_face_set_tag = + _media_face_set_tag_ptr.asFunction<_dart_media_face_set_tag>(); + + /// @brief Inserts a new face in the media database. + /// @since_tizen 3.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @remarks The @a face should be released using media_face_destroy(). + /// + /// @param[in] face The media face handle + /// + /// @return 0 on success, otherwise a negative error value. + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// + /// @see media_content_connect() + /// @see media_face_destroy() + /// @see media_face_set_xxx() + int media_face_insert_to_db( + ffi.Pointer face, + ) { + return _media_face_insert_to_db( + face, + ); + } + + late final _media_face_insert_to_db_ptr = + _lookup>( + 'media_face_insert_to_db'); + late final _dart_media_face_insert_to_db _media_face_insert_to_db = + _media_face_insert_to_db_ptr.asFunction<_dart_media_face_insert_to_db>(); + + /// @brief Updates the face details to the media database. + /// + /// @details The function updates the given media face in the media database. The function should be called after any change in face, to be updated to the media + /// database. For example, after using media_face_set_orientation() for setting the orientation of the face, media_face_update_to_db() function should be called so as to update + /// the given face attributes in the media database. + /// @since_tizen 3.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @param[in] face The media face handle to update + /// + /// @return 0 on success, otherwise a negative error value. + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_face_destroy() + /// @see media_face_set_xxx() + int media_face_update_to_db( + ffi.Pointer face, + ) { + return _media_face_update_to_db( + face, + ); + } + + late final _media_face_update_to_db_ptr = + _lookup>( + 'media_face_update_to_db'); + late final _dart_media_face_update_to_db _media_face_update_to_db = + _media_face_update_to_db_ptr.asFunction<_dart_media_face_update_to_db>(); + + /// @brief Deletes the face with given face id from the media database. + /// + /// @since_tizen 3.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write + /// + /// @param[in] face_id The ID of the media face + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @see media_content_connect() + int media_face_delete_from_db( + ffi.Pointer face_id, + ) { + return _media_face_delete_from_db( + face_id, + ); + } + + late final _media_face_delete_from_db_ptr = + _lookup>( + 'media_face_delete_from_db'); + late final _dart_media_face_delete_from_db _media_face_delete_from_db = + _media_face_delete_from_db_ptr + .asFunction<_dart_media_face_delete_from_db>(); + + /// @brief Gets the number of media faces with an optional filter from the media database. + /// @since_tizen 4.0 + /// + /// @param[in] filter The handle to the media filter + /// @param[out] face_count The count of the media faces + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// + /// @see media_content_connect() + /// @see media_filter_create() + int media_face_get_face_count_from_db( + ffi.Pointer filter, + ffi.Pointer face_count, + ) { + return _media_face_get_face_count_from_db( + filter, + face_count, + ); + } + + late final _media_face_get_face_count_from_db_ptr = + _lookup>( + 'media_face_get_face_count_from_db'); + late final _dart_media_face_get_face_count_from_db + _media_face_get_face_count_from_db = + _media_face_get_face_count_from_db_ptr + .asFunction<_dart_media_face_get_face_count_from_db>(); + + /// @brief Iterates through the faces with an optional filter from the media database. + /// @details This function gets all faces associated with the given filter and calls @a callback for every retrieved media face. + /// If @c NULL is passed to the @a filter, then no filtering is applied. + /// @since_tizen 4.0 + /// + /// @param[in] filter The handle to the media filter + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @post This function invokes media_face_cb(). + /// + /// @see media_content_connect() + /// @see media_face_cb() + /// @see media_filter_create() + int media_face_foreach_face_from_db( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_face_foreach_face_from_db( + filter, + callback, + user_data, + ); + } + + late final _media_face_foreach_face_from_db_ptr = + _lookup>( + 'media_face_foreach_face_from_db'); + late final _dart_media_face_foreach_face_from_db + _media_face_foreach_face_from_db = _media_face_foreach_face_from_db_ptr + .asFunction<_dart_media_face_foreach_face_from_db>(); + + /// @brief Connects to the media content service. + /// @details Any media content related function call should be invoked after this function call. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB operation failed + /// + /// @post media_content_disconnect() + /// + /// @see media_content_disconnect() + int media_content_connect() { + return _media_content_connect(); + } + + late final _media_content_connect_ptr = + _lookup>( + 'media_content_connect'); + late final _dart_media_content_connect _media_content_connect = + _media_content_connect_ptr.asFunction<_dart_media_content_connect>(); + + /// @brief Disconnects from the media content service. + /// @details This function closes connection to the media content service. Any further media content related operation + /// cannot be performed after this function is called. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB operation failed + /// + /// @pre media_content_connect() + /// + /// @see media_content_connect() + int media_content_disconnect() { + return _media_content_disconnect(); + } + + late final _media_content_disconnect_ptr = + _lookup>( + 'media_content_disconnect'); + late final _dart_media_content_disconnect _media_content_disconnect = + _media_content_disconnect_ptr + .asFunction<_dart_media_content_disconnect>(); + + /// @brief Requests to scan a media file. + /// @details This function requests to scan a media file to the media server. + /// If media file is not registered to DB yet, that media file information will be added to the media DB. If it is already registered to the DB, then this tries to refresh information. \n + /// If requested file does not exist on file system, information of the media file will be removed from the media DB. \n + /// If file information does not exist in DB, this function will be return #MEDIA_CONTENT_ERROR_INVALID_PARAMETER. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write \n + /// %http://tizen.org/privilege/mediastorage \n + /// %http://tizen.org/privilege/externalstorage + /// + /// @remarks You must add privilege http://tizen.org/privilege/content.write. And You add more privilege depending on your choice of contents path. \n + /// If you want to access only internal storage by using this function, you should add privilege http://tizen.org/privilege/mediastorage. \n + /// Or if you want to access only external storage by using this function, you should add privilege http://tizen.org/privilege/externalstorage. \n + /// If you can access both storage, you must add all privilege. \n + /// Since 4.0, This function does not allow a symbolic link.\n + /// @remarks Since 4.0, this function is related to the following feature:\n + /// %http://tizen.org/feature/content.scanning.others\n + /// If this feature is not supported on the device, MEDIA_CONTENT_TYPE_OTHERS type file is not scanned. + /// + /// @param[in] path The file path + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @see media_content_connect() + int media_content_scan_file( + ffi.Pointer path, + ) { + return _media_content_scan_file( + path, + ); + } + + late final _media_content_scan_file_ptr = + _lookup>( + 'media_content_scan_file'); + late final _dart_media_content_scan_file _media_content_scan_file = + _media_content_scan_file_ptr.asFunction<_dart_media_content_scan_file>(); + + /// @brief Requests to scan a media folder, asynchronously. + /// @details This function requests to scan a media folder to the media server with given completed callback function. + /// media_scan_completed_cb() function will be called when the scanning is finished. + /// The sub folders are also scanned, if there are sub folders in that folder. \n + /// If any folder must not be scanned, a blank file ".scan_ignore" has to be created in that folder. + /// After adding or removing a folder from the filesystem, call this function on its source location + /// (this will add or remove an entry from the database). \n + /// After moving or renaming a folder in the filesystem, call this function on its source location + /// (this will remove an entry from the database) and call this function again on its destination location + /// (this will add a new entry to the database).\n + /// Alternatively, you can call this function on any parent of source location and on any parent of destination location.\n + /// You can also call the function once, on a folder which is a parent of both source and destination.\n + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/content.write \n + /// %http://tizen.org/privilege/mediastorage \n + /// %http://tizen.org/privilege/externalstorage + /// + /// @remarks You must add privilege http://tizen.org/privilege/content.write. And You add more privilege depending on your choice of contents path. \n + /// If you want to access only internal storage by using this function, you should add privilege http://tizen.org/privilege/mediastorage. \n + /// Or if you want to access only external storage by using this function, you should add privilege http://tizen.org/privilege/externalstorage. \n + /// If you can access both storage, you must add all privilege. \n + /// Since 4.0, This function does not allow a symbolic link. + /// + /// @param[in] path The folder path + /// @param[in] is_recursive Set @c true to scan recursively subdirectories, + /// otherwise @c false to scan only the current directory + /// @param[in] callback The callback to be invoked when the scanning is finished + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTENT_ERROR_DB_FAILED DB Operation failed + /// @retval #MEDIA_CONTENT_ERROR_DB_BUSY DB Operation busy + /// @retval #MEDIA_CONTENT_ERROR_NETWORK Network fail + /// + /// @pre This function requires opened connection to content service by media_content_connect(). + /// @see media_scan_completed_cb() + /// @see media_content_connect() + int media_content_scan_folder( + ffi.Pointer path, + bool is_recursive, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_content_scan_folder( + path, + is_recursive ? 1 : 0, + callback, + user_data, + ); + } + + late final _media_content_scan_folder_ptr = + _lookup>( + 'media_content_scan_folder'); + late final _dart_media_content_scan_folder _media_content_scan_folder = + _media_content_scan_folder_ptr + .asFunction<_dart_media_content_scan_folder>(); + + /// @brief Requests to cancel the media folder scanning. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] path The folder path + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre media_content_scan_folder() + int media_content_cancel_scan_folder( + ffi.Pointer path, + ) { + return _media_content_cancel_scan_folder( + path, + ); + } + + late final _media_content_cancel_scan_folder_ptr = + _lookup>( + 'media_content_cancel_scan_folder'); + late final _dart_media_content_cancel_scan_folder + _media_content_cancel_scan_folder = _media_content_cancel_scan_folder_ptr + .asFunction<_dart_media_content_cancel_scan_folder>(); + + /// @deprecated Deprecated since 3.0. Use media_content_add_db_updated_cb() instead. + /// @brief Subscribes notifications of the media DB change. + /// @details This function subscribes notifications of the media DB change which are published by the media server or other apps. + /// media_content_db_update_cb() function will be called when notification of the media DB change is subscribed. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] callback The callback to be invoked when the scanning is finished + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see media_content_db_update_cb() + /// @see media_content_unset_db_updated_cb() + int media_content_set_db_updated_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_content_set_db_updated_cb( + callback, + user_data, + ); + } + + late final _media_content_set_db_updated_cb_ptr = + _lookup>( + 'media_content_set_db_updated_cb'); + late final _dart_media_content_set_db_updated_cb + _media_content_set_db_updated_cb = _media_content_set_db_updated_cb_ptr + .asFunction<_dart_media_content_set_db_updated_cb>(); + + /// @deprecated Deprecated since 3.0. Use media_content_remove_db_updated_cb() instead. + /// @brief Unsubscribes notifications of the media DB change. + /// @details This function unsubscribes notifications of the media DB change which are published by the media server or other apps. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// + /// @pre media_content_set_db_updated_cb() + /// + /// @see media_content_set_db_updated_cb() + int media_content_unset_db_updated_cb() { + return _media_content_unset_db_updated_cb(); + } + + late final _media_content_unset_db_updated_cb_ptr = + _lookup>( + 'media_content_unset_db_updated_cb'); + late final _dart_media_content_unset_db_updated_cb + _media_content_unset_db_updated_cb = + _media_content_unset_db_updated_cb_ptr + .asFunction<_dart_media_content_unset_db_updated_cb>(); + + /// @brief Subscribes notifications of the media DB change. + /// @details This function subscribes notifications of the media DB change which are published by the media server or other apps. \n + /// media_content_db_update_cb() function will be called when notification of the media DB change is subscribed. \n + /// Using this function, multiple callback is possible to register in one process. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a noti_handle should be released using media_content_remove_db_updated_cb(). \n + /// If you set the same callback that you previously added, this function returns MEDIA_CONTENT_ERROR_INVALID_OPERATION error. \n + /// + /// @param[in] callback The callback to be invoked when the scanning is finished + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] noti_handle The handle to db updated notification + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTENT_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTENT_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see media_content_db_update_cb() + /// @see media_content_remove_db_updated_cb() + int media_content_add_db_updated_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer> noti_handle, + ) { + return _media_content_add_db_updated_cb( + callback, + user_data, + noti_handle, + ); + } + + late final _media_content_add_db_updated_cb_ptr = + _lookup>( + 'media_content_add_db_updated_cb'); + late final _dart_media_content_add_db_updated_cb + _media_content_add_db_updated_cb = _media_content_add_db_updated_cb_ptr + .asFunction<_dart_media_content_add_db_updated_cb>(); + + /// @brief Removes notifications of the media DB change. + /// @details This function unsubscribes notifications of the media DB change which are published by the media server or other apps. + /// + /// @since_tizen 3.0 + /// + /// @param[in] noti_handle The handle to db updated notification + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTENT_ERROR_NONE Successful + /// @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre media_content_add_db_updated_cb() + /// + /// @see media_content_add_db_updated_cb() + int media_content_remove_db_updated_cb( + ffi.Pointer noti_handle, + ) { + return _media_content_remove_db_updated_cb( + noti_handle, + ); + } + + late final _media_content_remove_db_updated_cb_ptr = + _lookup>( + 'media_content_remove_db_updated_cb'); + late final _dart_media_content_remove_db_updated_cb + _media_content_remove_db_updated_cb = + _media_content_remove_db_updated_cb_ptr + .asFunction<_dart_media_content_remove_db_updated_cb>(); + + /// @brief Check whether the activity is supported or not. + /// @details Check if the given activity type is supported in the current device. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] activity Activity type to be checked + /// @param[out] supported @c true if the activity is recognizable in the current device,@n + /// @c false otherwise + /// + /// @return @c 0 if the @c activity is supported, otherwise a negative error value + /// @retval #ACTIVITY_ERROR_NONE Supported + /// @retval #ACTIVITY_ERROR_INVALID_PARAMETER Invalid parameter used + /// @retval #ACTIVITY_ERROR_NOT_SUPPORTED The @c activity is not supported + /// @retval #ACTIVITY_ERROR_OPERATION_FAILED Operation failed because of a system error + /// @retval #ACTIVITY_ERROR_PERMISSION_DENIED Does not have permission to use this + int activity_is_supported( + int activity, + ffi.Pointer supported, + ) { + return _activity_is_supported( + activity, + supported, + ); + } + + late final _activity_is_supported_ptr = + _lookup>( + 'activity_is_supported'); + late final _dart_activity_is_supported _activity_is_supported = + _activity_is_supported_ptr.asFunction<_dart_activity_is_supported>(); + + /// @brief Initializes an activity handle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[out] handle Activity handle to be initialized + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #ACTIVITY_ERROR_NONE Successful + /// @retval #ACTIVITY_ERROR_INVALID_PARAMETER Invalid parameter used + /// @retval #ACTIVITY_ERROR_NOT_SUPPORTED Activity recognition is not supported + /// @retval #ACTIVITY_ERROR_OPERATION_FAILED Operation failed because of a system error, e.g., out of memory + /// + /// @see activity_release() + int activity_create( + ffi.Pointer> handle, + ) { + return _activity_create( + handle, + ); + } + + late final _activity_create_ptr = + _lookup>('activity_create'); + late final _dart_activity_create _activity_create = + _activity_create_ptr.asFunction<_dart_activity_create>(); + + /// @brief Releases the resources occupied by the activity handle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] handle Activity handle to be released + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #ACTIVITY_ERROR_NONE Successful + /// @retval #ACTIVITY_ERROR_INVALID_PARAMETER Invalid parameter used + /// @retval #ACTIVITY_ERROR_NOT_SUPPORTED Activity recognition is not supported + /// @retval #ACTIVITY_ERROR_OPERATION_FAILED Operation failed because of a system error + /// + /// @pre activity_create() + int activity_release( + ffi.Pointer<_activity_handle_s> handle, + ) { + return _activity_release( + handle, + ); + } + + late final _activity_release_ptr = + _lookup>('activity_release'); + late final _dart_activity_release _activity_release = + _activity_release_ptr.asFunction<_dart_activity_release>(); + + /// @brief Starts to recognize an activity. + /// @details Sets a callback function to be invoked when the activity is detected, + /// and starts to monitor occurrences of the activity. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] handle Activity handle to be used to control the activity event + /// @param[in] activity Activity type to be monitored + /// @param[in] callback Callback function to receive activity events + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #ACTIVITY_ERROR_NONE Successful + /// @retval #ACTIVITY_ERROR_INVALID_PARAMETER Invalid parameter used + /// @retval #ACTIVITY_ERROR_NOT_SUPPORTED Activity recognition is not supported + /// @retval #ACTIVITY_ERROR_ALREADY_STARTED The @c handle is being used already + /// @retval #ACTIVITY_ERROR_OPERATION_FAILED Operation failed because of a system error + /// @retval #ACTIVITY_ERROR_PERMISSION_DENIED Does not have permission to use this + /// + /// @pre activity_create() + /// @post activity_recognition_cb() + /// @see activity_stop_recognition() + int activity_start_recognition( + ffi.Pointer<_activity_handle_s> handle, + int activity, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _activity_start_recognition( + handle, + activity, + callback, + user_data, + ); + } + + late final _activity_start_recognition_ptr = + _lookup>( + 'activity_start_recognition'); + late final _dart_activity_start_recognition _activity_start_recognition = + _activity_start_recognition_ptr + .asFunction<_dart_activity_start_recognition>(); + + /// @brief Stops recognizing the activity registered to the activity handle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] handle Activity handle to release its callback function registered + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #ACTIVITY_ERROR_NONE Successful + /// @retval #ACTIVITY_ERROR_INVALID_PARAMETER Invalid parameter used + /// @retval #ACTIVITY_ERROR_NOT_SUPPORTED Activity recognition is not supported + /// @retval #ACTIVITY_ERROR_NOT_STARTED Nothing is started using the @c handle + /// @retval #ACTIVITY_ERROR_OPERATION_FAILED Operation failed because of a system error + int activity_stop_recognition( + ffi.Pointer<_activity_handle_s> handle, + ) { + return _activity_stop_recognition( + handle, + ); + } + + late final _activity_stop_recognition_ptr = + _lookup>( + 'activity_stop_recognition'); + late final _dart_activity_stop_recognition _activity_stop_recognition = + _activity_stop_recognition_ptr + .asFunction<_dart_activity_stop_recognition>(); + + /// @brief Gets the recognition accuracy. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] data Activity data received through activity_cb() + /// @param[out] accuracy Accuracy + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #ACTIVITY_ERROR_NONE Successful + /// @retval #ACTIVITY_ERROR_INVALID_PARAMETER Invalid parameter used + /// @retval #ACTIVITY_ERROR_NOT_SUPPORTED Activity recognition is not supported + /// @retval #ACTIVITY_ERROR_OPERATION_FAILED Operation failed because of a system error + int activity_get_accuracy( + ffi.Pointer<_activity_data_s> data, + ffi.Pointer accuracy, + ) { + return _activity_get_accuracy( + data, + accuracy, + ); + } + + late final _activity_get_accuracy_ptr = + _lookup>( + 'activity_get_accuracy'); + late final _dart_activity_get_accuracy _activity_get_accuracy = + _activity_get_accuracy_ptr.asFunction<_dart_activity_get_accuracy>(); + + /// @brief Check whether the gesture is supported or not. + /// @details Check if the given gesture type is supported in the current device. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] gesture Gesture type to be checked + /// @param[out] supported @c true if the gesture is recognizable in the current device,@n + /// @c false otherwise + /// + /// @return @c 0 if the @c gesture is supported, otherwise a negative error value + /// @retval #GESTURE_ERROR_NONE Supported + /// @retval #GESTURE_ERROR_INVALID_PARAMETER Invalid parameter used + /// @retval #GESTURE_ERROR_NOT_SUPPORTED The @c gesture is not supported + /// @retval #GESTURE_ERROR_OPERATION_FAILED Operation failed because of a system error + /// @retval #GESTURE_ERROR_PERMISSION_DENIED Does not have permission to use this + int gesture_is_supported( + int gesture, + ffi.Pointer supported, + ) { + return _gesture_is_supported( + gesture, + supported, + ); + } + + late final _gesture_is_supported_ptr = + _lookup>( + 'gesture_is_supported'); + late final _dart_gesture_is_supported _gesture_is_supported = + _gesture_is_supported_ptr.asFunction<_dart_gesture_is_supported>(); + + /// @brief Initializes a gesture handle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[out] handle Gesture handle to be initialized + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #GESTURE_ERROR_NONE Successful + /// @retval #GESTURE_ERROR_INVALID_PARAMETER Invalid parameter used + /// @retval #GESTURE_ERROR_NOT_SUPPORTED Gesture recognition is not supported + /// @retval #GESTURE_ERROR_OPERATION_FAILED Operation failed because of a system error, e.g., out of memory + /// + /// @see gesture_release() + int gesture_create( + ffi.Pointer> handle, + ) { + return _gesture_create( + handle, + ); + } + + late final _gesture_create_ptr = + _lookup>('gesture_create'); + late final _dart_gesture_create _gesture_create = + _gesture_create_ptr.asFunction<_dart_gesture_create>(); + + /// @brief Releases the resources occupied by the gesture handle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] handle Gesture handle to be released + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #GESTURE_ERROR_NONE Successful + /// @retval #GESTURE_ERROR_INVALID_PARAMETER Invalid parameter used + /// @retval #GESTURE_ERROR_NOT_SUPPORTED Gesture recognition is not supported + /// @retval #GESTURE_ERROR_OPERATION_FAILED Operation failed because of a system error + /// + /// @pre gesture_create() + int gesture_release( + ffi.Pointer<_gesture_handle_s> handle, + ) { + return _gesture_release( + handle, + ); + } + + late final _gesture_release_ptr = + _lookup>('gesture_release'); + late final _dart_gesture_release _gesture_release = + _gesture_release_ptr.asFunction<_dart_gesture_release>(); + + /// @brief Starts to recognize a gesture. + /// @details Sets a callback function to be invoked when the gesture is detected, + /// and starts to monitor occurrences of the gesture. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] handle Gesture handle to be used to control the gesture event + /// @param[in] gesture Gesture type to be monitored + /// @param[in] option Detection option + /// @param[in] callback Callback function to receive gesture events + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #GESTURE_ERROR_NONE Successful + /// @retval #GESTURE_ERROR_INVALID_PARAMETER Invalid parameter used + /// @retval #GESTURE_ERROR_NOT_SUPPORTED Gesture recognition is not supported + /// @retval #GESTURE_ERROR_ALREADY_STARTED The @c handle is being used already + /// @retval #GESTURE_ERROR_OPERATION_FAILED Operation failed because of a system error + /// @retval #GESTURE_ERROR_PERMISSION_DENIED Does not have permission to use this + /// + /// @pre gesture_create() + /// @post gesture_recognition_cb() + /// @see gesture_stop_recognition() + int gesture_start_recognition( + ffi.Pointer<_gesture_handle_s> handle, + int gesture, + int option, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _gesture_start_recognition( + handle, + gesture, + option, + callback, + user_data, + ); + } + + late final _gesture_start_recognition_ptr = + _lookup>( + 'gesture_start_recognition'); + late final _dart_gesture_start_recognition _gesture_start_recognition = + _gesture_start_recognition_ptr + .asFunction<_dart_gesture_start_recognition>(); + + /// @brief Stops recognizing the gesture registered to the gesture handle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] handle Gesture handle to release its callback function registered + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #GESTURE_ERROR_NONE Successful + /// @retval #GESTURE_ERROR_INVALID_PARAMETER Invalid parameter used + /// @retval #GESTURE_ERROR_NOT_SUPPORTED Gesture recognition is not supported + /// @retval #GESTURE_ERROR_NOT_STARTED Nothing is started using the @c handle + /// @retval #GESTURE_ERROR_OPERATION_FAILED Operation failed because of a system error + int gesture_stop_recognition( + ffi.Pointer<_gesture_handle_s> handle, + ) { + return _gesture_stop_recognition( + handle, + ); + } + + late final _gesture_stop_recognition_ptr = + _lookup>( + 'gesture_stop_recognition'); + late final _dart_gesture_stop_recognition _gesture_stop_recognition = + _gesture_stop_recognition_ptr + .asFunction<_dart_gesture_stop_recognition>(); + + /// @brief Gets the gesture event from the gesture data received. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] data Gesture data received through a callback function + /// @param[out] event Gesture event data + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #GESTURE_ERROR_NONE Successful + /// @retval #GESTURE_ERROR_INVALID_PARAMETER Invalid parameter used + /// @retval #GESTURE_ERROR_NOT_SUPPORTED Gesture recognition is not supported + /// @retval #GESTURE_ERROR_OPERATION_FAILED Operation failed because of a system error + int gesture_get_event( + ffi.Pointer<_gesture_data_s> data, + ffi.Pointer event, + ) { + return _gesture_get_event( + data, + event, + ); + } + + late final _gesture_get_event_ptr = + _lookup>('gesture_get_event'); + late final _dart_gesture_get_event _gesture_get_event = + _gesture_get_event_ptr.asFunction<_dart_gesture_get_event>(); + + /// @brief Gets the tilting degrees from #GESTURE_TILT data received. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] data Tilt gesture data received through a callback function + /// @param[out] x Tilting degree on X-axis + /// @param[out] y Tilting degree on Y-axis + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #GESTURE_ERROR_NONE Successful + /// @retval #GESTURE_ERROR_INVALID_PARAMETER Invalid parameter used + /// @retval #GESTURE_ERROR_NOT_SUPPORTED Gesture recognition is not supported + /// @retval #GESTURE_ERROR_OPERATION_FAILED Operation failed because of a system error + int gesture_get_tilt( + ffi.Pointer<_gesture_data_s> data, + ffi.Pointer x, + ffi.Pointer y, + ) { + return _gesture_get_tilt( + data, + x, + y, + ); + } + + late final _gesture_get_tilt_ptr = + _lookup>('gesture_get_tilt'); + late final _dart_gesture_get_tilt _gesture_get_tilt = + _gesture_get_tilt_ptr.asFunction<_dart_gesture_get_tilt>(); + + /// @brief Creates a rect type of new location bounds. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a bounds using location_bounds_destroy(). + /// @param[in] top_left The top left position + /// @param[in] bottom_right The bottom right position + /// @param[out] bounds The location bounds handle that is newly created + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATION_BOUNDS_ERROR_NONE Successful + /// @retval #LOCATION_BOUNDS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #LOCATION_BOUNDS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATION_BOUNDS_ERROR_NOT_SUPPORTED Not supported + /// @see location_bounds_get_rect_coords() + /// @see location_bounds_destroy() + int location_bounds_create_rect( + location_coords_s top_left, + location_coords_s bottom_right, + ffi.Pointer> bounds, + ) { + return _location_bounds_create_rect( + top_left, + bottom_right, + bounds, + ); + } + + late final _location_bounds_create_rect_ptr = + _lookup>( + 'location_bounds_create_rect'); + late final _dart_location_bounds_create_rect _location_bounds_create_rect = + _location_bounds_create_rect_ptr + .asFunction<_dart_location_bounds_create_rect>(); + + /// @brief Creates a circle type of new location bounds. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a bounds using location_bounds_destroy(). + /// @param[in] center The center position + /// @param[in] radius The radius of a circle (meters) + /// @param[out] bounds The location bounds handle that is newly created + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATION_BOUNDS_ERROR_NONE Successful + /// @retval #LOCATION_BOUNDS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #LOCATION_BOUNDS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATION_BOUNDS_ERROR_NOT_SUPPORTED Not supported + /// @see location_bounds_get_circle_coords() + /// @see location_bounds_destroy() + int location_bounds_create_circle( + location_coords_s center, + double radius, + ffi.Pointer> bounds, + ) { + return _location_bounds_create_circle( + center, + radius, + bounds, + ); + } + + late final _location_bounds_create_circle_ptr = + _lookup>( + 'location_bounds_create_circle'); + late final _dart_location_bounds_create_circle + _location_bounds_create_circle = _location_bounds_create_circle_ptr + .asFunction<_dart_location_bounds_create_circle>(); + + /// @brief Creates a polygon type of new location bounds. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a bounds using location_bounds_destroy(). + /// @remarks @a length should be more than @c 3 to represent polygon. + /// @param[in] coords_list The list of coordinates + /// @param[in] length The length of the coordinates list + /// @param[out] bounds The location bounds handle that is newly created on success + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATION_BOUNDS_ERROR_NONE Successful + /// @retval #LOCATION_BOUNDS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #LOCATION_BOUNDS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATION_BOUNDS_ERROR_NOT_SUPPORTED Not supported + /// @see location_bounds_foreach_polygon_coords() + /// @see location_bounds_destroy() + int location_bounds_create_polygon( + ffi.Pointer coords_list, + int length, + ffi.Pointer> bounds, + ) { + return _location_bounds_create_polygon( + coords_list, + length, + bounds, + ); + } + + late final _location_bounds_create_polygon_ptr = + _lookup>( + 'location_bounds_create_polygon'); + late final _dart_location_bounds_create_polygon + _location_bounds_create_polygon = _location_bounds_create_polygon_ptr + .asFunction<_dart_location_bounds_create_polygon>(); + + /// @brief Checks whether the bounds contains the specified coordinates. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] bounds The location bounds handle + /// @param[in] coords The coordinates + /// @return @c true if the bounds contains the specified coordinates, + /// otherwise else @c false + /// @exception #LOCATION_BOUNDS_ERROR_NONE Successful + /// @exception #LOCATION_BOUNDS_ERROR_OUT_OF_MEMORY Out of memory + /// @exception #LOCATION_BOUNDS_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #LOCATION_BOUNDS_ERROR_NOT_SUPPORTED Not supported + /// @see location_bounds_create_rect() + /// @see location_bounds_create_circle() + /// @see location_bounds_create_polygon() + bool location_bounds_contains_coordinates( + ffi.Pointer bounds, + location_coords_s coords, + ) { + return _location_bounds_contains_coordinates( + bounds, + coords, + ) != + 0; + } + + late final _location_bounds_contains_coordinates_ptr = + _lookup>( + 'location_bounds_contains_coordinates'); + late final _dart_location_bounds_contains_coordinates + _location_bounds_contains_coordinates = + _location_bounds_contains_coordinates_ptr + .asFunction<_dart_location_bounds_contains_coordinates>(); + + /// @brief Gets the type of location bounds. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] bounds The location bounds handle + /// @param[out] type The type of location bounds + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATION_BOUNDS_ERROR_NONE Successful + /// @retval #LOCATION_BOUNDS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATION_BOUNDS_ERROR_NOT_SUPPORTED Not supported + /// @see location_bounds_create_rect() + /// @see location_bounds_create_circle() + /// @see location_bounds_create_polygon() + int location_bounds_get_type( + ffi.Pointer bounds, + ffi.Pointer type, + ) { + return _location_bounds_get_type( + bounds, + type, + ); + } + + late final _location_bounds_get_type_ptr = + _lookup>( + 'location_bounds_get_type'); + late final _dart_location_bounds_get_type _location_bounds_get_type = + _location_bounds_get_type_ptr + .asFunction<_dart_location_bounds_get_type>(); + + /// @brief Gets the center position and radius of circle bounds. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] bounds The location bounds handle + /// @param[out] top_left The top left position + /// @param[out] bottom_right The bottom right position + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATION_BOUNDS_ERROR_NONE Successful + /// @retval #LOCATION_BOUNDS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATION_BOUNDS_ERROR_NOT_SUPPORTED Not supported + /// @retval #LOCATION_BOUNDS_ERROR_INCORRECT_TYPE Incorrect bounds type + /// @see location_bounds_create_rect() + int location_bounds_get_rect_coords( + ffi.Pointer bounds, + ffi.Pointer top_left, + ffi.Pointer bottom_right, + ) { + return _location_bounds_get_rect_coords( + bounds, + top_left, + bottom_right, + ); + } + + late final _location_bounds_get_rect_coords_ptr = + _lookup>( + 'location_bounds_get_rect_coords'); + late final _dart_location_bounds_get_rect_coords + _location_bounds_get_rect_coords = _location_bounds_get_rect_coords_ptr + .asFunction<_dart_location_bounds_get_rect_coords>(); + + /// @brief Gets the center position and radius of circle bounds. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] bounds The location bounds handle + /// @param[out] center The center position of the circle + /// @param[out] radius The radius of the circle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATION_BOUNDS_ERROR_NONE Successful + /// @retval #LOCATION_BOUNDS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATION_BOUNDS_ERROR_NOT_SUPPORTED Not supported + /// @retval #LOCATION_BOUNDS_ERROR_INCORRECT_TYPE Incorrect bounds type + /// @see location_bounds_create_circle() + int location_bounds_get_circle_coords( + ffi.Pointer bounds, + ffi.Pointer center, + ffi.Pointer radius, + ) { + return _location_bounds_get_circle_coords( + bounds, + center, + radius, + ); + } + + late final _location_bounds_get_circle_coords_ptr = + _lookup>( + 'location_bounds_get_circle_coords'); + late final _dart_location_bounds_get_circle_coords + _location_bounds_get_circle_coords = + _location_bounds_get_circle_coords_ptr + .asFunction<_dart_location_bounds_get_circle_coords>(); + + /// @brief Get the coordinates of a polygon. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] bounds The location bounds handle + /// @param[in] callback The iteration callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATION_BOUNDS_ERROR_NONE Successful + /// @retval #LOCATION_BOUNDS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATION_BOUNDS_ERROR_NOT_SUPPORTED Not supported + /// @retval #LOCATION_BOUNDS_ERROR_INCORRECT_TYPE Incorrect bounds type + /// @post It invokes polygon_coords_cb() to get coordinates of polygon. + /// @see polygon_coords_cb() + /// @see location_bounds_create_polygon() + int location_bounds_foreach_polygon_coords( + ffi.Pointer bounds, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _location_bounds_foreach_polygon_coords( + bounds, + callback, + user_data, + ); + } + + late final _location_bounds_foreach_polygon_coords_ptr = + _lookup>( + 'location_bounds_foreach_polygon_coords'); + late final _dart_location_bounds_foreach_polygon_coords + _location_bounds_foreach_polygon_coords = + _location_bounds_foreach_polygon_coords_ptr + .asFunction<_dart_location_bounds_foreach_polygon_coords>(); + + /// @brief Releases the location bounds. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] bounds The location bounds handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATION_BOUNDS_ERROR_NONE Successful + /// @retval #LOCATION_BOUNDS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATION_BOUNDS_ERROR_NOT_SUPPORTED Not supported + /// @see location_bounds_create_rect() + /// @see location_bounds_create_circle() + /// @see location_bounds_create_polygon() + int location_bounds_destroy( + ffi.Pointer bounds, + ) { + return _location_bounds_destroy( + bounds, + ); + } + + late final _location_bounds_destroy_ptr = + _lookup>( + 'location_bounds_destroy'); + late final _dart_location_bounds_destroy _location_bounds_destroy = + _location_bounds_destroy_ptr.asFunction<_dart_location_bounds_destroy>(); + + /// @brief Registers a callback function to be invoked when the boundary area is entered or exited. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] bounds The location bounds handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATION_BOUNDS_ERROR_NONE Successful + /// @retval #LOCATION_BOUNDS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATION_BOUNDS_ERROR_NOT_SUPPORTED Not supported + /// @post location_bounds_state_changed_cb() will be invoked. + /// @see location_bounds_unset_state_changed_cb() + /// @see location_bounds_state_changed_cb() + int location_bounds_set_state_changed_cb( + ffi.Pointer bounds, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _location_bounds_set_state_changed_cb( + bounds, + callback, + user_data, + ); + } + + late final _location_bounds_set_state_changed_cb_ptr = + _lookup>( + 'location_bounds_set_state_changed_cb'); + late final _dart_location_bounds_set_state_changed_cb + _location_bounds_set_state_changed_cb = + _location_bounds_set_state_changed_cb_ptr + .asFunction<_dart_location_bounds_set_state_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] bounds The location bounds handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATION_BOUNDS_ERROR_NONE Successful + /// @retval #LOCATION_BOUNDS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATION_BOUNDS_ERROR_NOT_SUPPORTED Not supported + /// @see location_bounds_set_state_changed_cb() + int location_bounds_unset_state_changed_cb( + ffi.Pointer bounds, + ) { + return _location_bounds_unset_state_changed_cb( + bounds, + ); + } + + late final _location_bounds_unset_state_changed_cb_ptr = + _lookup>( + 'location_bounds_unset_state_changed_cb'); + late final _dart_location_bounds_unset_state_changed_cb + _location_bounds_unset_state_changed_cb = + _location_bounds_unset_state_changed_cb_ptr + .asFunction<_dart_location_bounds_unset_state_changed_cb>(); + + /// @brief Checks whether the given location method is available. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remark The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] method The location method to be checked + /// @return @c true if the specified location method is supported, + /// otherwise @c false if it is not available + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @retval #LOCATIONS_ERROR_INCORRECT_METHOD Incorrect method + /// @see location_manager_create() + /// @see location_manager_get_method() + bool location_manager_is_supported_method( + int method, + ) { + return _location_manager_is_supported_method( + method, + ) != + 0; + } + + late final _location_manager_is_supported_method_ptr = + _lookup>( + 'location_manager_is_supported_method'); + late final _dart_location_manager_is_supported_method + _location_manager_is_supported_method = + _location_manager_is_supported_method_ptr + .asFunction<_dart_location_manager_is_supported_method>(); + + /// @brief Checks whether the given location method is enabled or not on setting. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] method The location method to be checked + /// @param[out] enable The result value of checking the given location method + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INCORRECT_METHOD Incorrect method + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_create() + /// @see location_manager_set_setting_changed_cb() + /// @see location_manager_unset_setting_changed_cb() + int location_manager_is_enabled_method( + int method, + ffi.Pointer enable, + ) { + return _location_manager_is_enabled_method( + method, + enable, + ); + } + + late final _location_manager_is_enabled_method_ptr = + _lookup>( + 'location_manager_is_enabled_method'); + late final _dart_location_manager_is_enabled_method + _location_manager_is_enabled_method = + _location_manager_is_enabled_method_ptr + .asFunction<_dart_location_manager_is_enabled_method>(); + + /// @platform + /// @brief Enables the given location method. + /// @since_tizen 2.3.1 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/location.enable + /// @param[in] method The location method to be checked + /// @param[in] enable The value to set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INCORRECT_METHOD Incorrect method + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED Permission denied + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_is_enabled_method() + /// @see location_manager_create() + int location_manager_enable_method( + int method, + bool enable, + ) { + return _location_manager_enable_method( + method, + enable ? 1 : 0, + ); + } + + late final _location_manager_enable_method_ptr = + _lookup>( + 'location_manager_enable_method'); + late final _dart_location_manager_enable_method + _location_manager_enable_method = _location_manager_enable_method_ptr + .asFunction<_dart_location_manager_enable_method>(); + + /// @brief Creates a new location manager. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a manager using location_manager_destroy(). + /// @param[in] method The location method + /// @param[out] manager The location manager handle that is newly created + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_destroy() + int location_manager_create( + int method, + ffi.Pointer> manager, + ) { + return _location_manager_create( + method, + manager, + ); + } + + late final _location_manager_create_ptr = + _lookup>( + 'location_manager_create'); + late final _dart_location_manager_create _location_manager_create = + _location_manager_create_ptr.asFunction<_dart_location_manager_create>(); + + /// @brief Releases the location manager. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The location manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_create() + int location_manager_destroy( + ffi.Pointer manager, + ) { + return _location_manager_destroy( + manager, + ); + } + + late final _location_manager_destroy_ptr = + _lookup>( + 'location_manager_destroy'); + late final _dart_location_manager_destroy _location_manager_destroy = + _location_manager_destroy_ptr + .asFunction<_dart_location_manager_destroy>(); + + /// @brief Requests to update current location once. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @remarks Do not request to start the location service using the same manager handler. + /// Calling this function invokes a location service event. When the location service is updated, location_updated_cb. + /// @param[in] manager The location manager handle + /// @param[in] timeout Timeout to stop requesting single location after + /// @param[in] callback The location callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_INCORRECT_METHOD Incorrect method + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_NETWORK_FAILED Network failed + /// @retval #LOCATIONS_ERROR_GPS_SETTING_OFF GPS is not enabled + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @post It invokes location_updated_cb(). + int location_manager_request_single_location( + ffi.Pointer manager, + int timeout, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _location_manager_request_single_location( + manager, + timeout, + callback, + user_data, + ); + } + + late final _location_manager_request_single_location_ptr = + _lookup>( + 'location_manager_request_single_location'); + late final _dart_location_manager_request_single_location + _location_manager_request_single_location = + _location_manager_request_single_location_ptr + .asFunction<_dart_location_manager_request_single_location>(); + + /// @brief Starts the location service. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @remarks There is no limit on number of location managers for which this function was called. + /// @remarks Calling this function invokes a location service event. When the location service is enabled, the service state change callback + /// (set using location_manager_set_service_state_changed_cb()) notifies the user with #LOCATIONS_SERVICE_ENABLED as + /// the first argument, and the service starts. + /// @remarks The started service is a requirement for calling these functions: + /// location_manager_get_position(), location_manager_get_velocity(), location_manager_get_accuracy(), + /// gps_status_get_nmea(), gps_status_get_satellite(), gps_status_foreach_satellites_in_view(). + /// @remarks Once you stop the service using location_manager_stop(), you can no longer call the functions listed above. + /// @remarks Starting and stopping the service is in the scope of the given location manager only (if there is more than one manager, + /// starting and stopping should be executed for each of them separately). + /// @param[in] manager The location manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_NETWORK_FAILED Network failed + /// @retval #LOCATIONS_ERROR_GPS_SETTING_OFF GPS is not enabled + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @post It invokes location_position_updated_cb(), location_velocity_updated_cb(), location_zone_changed_cb(), and location_service_state_changed_cb(). + /// @see location_manager_stop() + /// @see location_manager_get_position() + /// @see location_manager_get_velocity() + /// @see location_manager_get_accuracy() + /// @see location_manager_set_service_state_changed_cb() + /// @see location_manager_set_position_updated_cb() + /// @see location_position_updated_cb() + /// @see location_manager_set_velocity_updated_cb() + /// @see location_velocity_updated_cb() + /// @see location_manager_set_zone_changed_cb() + /// @see location_zone_changed_cb() + int location_manager_start( + ffi.Pointer manager, + ) { + return _location_manager_start( + manager, + ); + } + + late final _location_manager_start_ptr = + _lookup>( + 'location_manager_start'); + late final _dart_location_manager_start _location_manager_start = + _location_manager_start_ptr.asFunction<_dart_location_manager_start>(); + + /// @brief Stops the location service. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This function initiates the process of stopping the service. When the process is finished, callback set using + /// #location_manager_set_service_state_changed_cb() will be called, with #LOCATIONS_SERVICE_DISABLED as first argument. + /// When that happens, the service is stopped and the user is notified. + /// @remarks You can stop and start the location manager as needed. + /// @param[in] manager The location manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_NETWORK_FAILED Network failed + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_start() + /// @see location_manager_set_service_state_changed_cb() + /// @see location_service_state_changed_cb() + int location_manager_stop( + ffi.Pointer manager, + ) { + return _location_manager_stop( + manager, + ); + } + + late final _location_manager_stop_ptr = + _lookup>( + 'location_manager_stop'); + late final _dart_location_manager_stop _location_manager_stop = + _location_manager_stop_ptr.asFunction<_dart_location_manager_stop>(); + + /// @brief Adds bounds for a given location manager. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The location manager handle + /// @param[in] bounds The location bounds handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @post It invokes location_manager_set_zone_changed_cb() when a boundary is entered or exited, if you set a callback with location_manager_set_zone_changed_cb(). + /// @see location_manager_remove_boundary() + /// @see location_manager_set_zone_changed_cb() + int location_manager_add_boundary( + ffi.Pointer manager, + ffi.Pointer bounds, + ) { + return _location_manager_add_boundary( + manager, + bounds, + ); + } + + late final _location_manager_add_boundary_ptr = + _lookup>( + 'location_manager_add_boundary'); + late final _dart_location_manager_add_boundary + _location_manager_add_boundary = _location_manager_add_boundary_ptr + .asFunction<_dart_location_manager_add_boundary>(); + + /// @brief Deletes bounds for a given location manager. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The location manager handle + /// @param[in] bounds The location bounds handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_add_boundary() + int location_manager_remove_boundary( + ffi.Pointer manager, + ffi.Pointer bounds, + ) { + return _location_manager_remove_boundary( + manager, + bounds, + ); + } + + late final _location_manager_remove_boundary_ptr = + _lookup>( + 'location_manager_remove_boundary'); + late final _dart_location_manager_remove_boundary + _location_manager_remove_boundary = _location_manager_remove_boundary_ptr + .asFunction<_dart_location_manager_remove_boundary>(); + + /// @brief Retrieves all location bounds by invoking a specific callback for each location bounds + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The location manager handle + /// @param[in] callback The iteration callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @post location_bounds_cb() will be invoked. + /// @see location_manager_add_boundary() + /// @see location_manager_remove_boundary() + /// @see location_bounds_cb() + int location_manager_foreach_boundary( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _location_manager_foreach_boundary( + manager, + callback, + user_data, + ); + } + + late final _location_manager_foreach_boundary_ptr = + _lookup>( + 'location_manager_foreach_boundary'); + late final _dart_location_manager_foreach_boundary + _location_manager_foreach_boundary = + _location_manager_foreach_boundary_ptr + .asFunction<_dart_location_manager_foreach_boundary>(); + + /// @brief Gets the given location manager's method. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The location manager handle + /// @param[out] method The location method + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_create() + int location_manager_get_method( + ffi.Pointer manager, + ffi.Pointer method, + ) { + return _location_manager_get_method( + manager, + method, + ); + } + + late final _location_manager_get_method_ptr = + _lookup>( + 'location_manager_get_method'); + late final _dart_location_manager_get_method _location_manager_get_method = + _location_manager_get_method_ptr + .asFunction<_dart_location_manager_get_method>(); + + /// @brief Gets the current position information. + /// @details The result contains the current altitude, latitude, and longitude with a measurement timestamp. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @param[in] manager The location manager handle + /// @param[out] altitude The current altitude (meters) + /// @param[out] latitude The current latitude [-90.0 ~ 90.0] (degrees) + /// @param[out] longitude The current longitude [-180.0 ~ 180.0] (degrees) + /// @param[out] timestamp The timestamp (time when measurement took place or @c 0 if valid) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_GPS_SETTING_OFF GPS is not enabled + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre The location service state must be #LOCATIONS_SERVICE_ENABLED with location_manager_start(). + int location_manager_get_position( + ffi.Pointer manager, + ffi.Pointer altitude, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer timestamp, + ) { + return _location_manager_get_position( + manager, + altitude, + latitude, + longitude, + timestamp, + ); + } + + late final _location_manager_get_position_ptr = + _lookup>( + 'location_manager_get_position'); + late final _dart_location_manager_get_position + _location_manager_get_position = _location_manager_get_position_ptr + .asFunction<_dart_location_manager_get_position>(); + + /// @brief Gets the current position information. + /// @details The result contains the current altitude, latitude, longitude, climb, direction, speed, level, horizontal, and vertical with a measurement timestamp. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @param[in] manager The location manager handle + /// @param[out] altitude The current altitude (meters) + /// @param[out] latitude The current latitude [-90.0 ~ 90.0] (degrees) + /// @param[out] longitude The current longitude [-180.0 ~ 180.0] (degrees) + /// @param[out] climb The climb (km/h) + /// @param[out] direction The direction, degrees from the north + /// @param[out] speed The speed (km/h) + /// @param[out] level The accuracy level + /// @param[out] horizontal The horizontal accuracy (meters) + /// @param[out] vertical The vertical accuracy (meters) + /// @param[out] timestamp The timestamp (time when measurement took place or @c 0 if valid) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_GPS_SETTING_OFF GPS is not enabled + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre The location service state must be #LOCATIONS_SERVICE_ENABLED with location_manager_start(). + int location_manager_get_location( + ffi.Pointer manager, + ffi.Pointer altitude, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer climb, + ffi.Pointer direction, + ffi.Pointer speed, + ffi.Pointer level, + ffi.Pointer horizontal, + ffi.Pointer vertical, + ffi.Pointer timestamp, + ) { + return _location_manager_get_location( + manager, + altitude, + latitude, + longitude, + climb, + direction, + speed, + level, + horizontal, + vertical, + timestamp, + ); + } + + late final _location_manager_get_location_ptr = + _lookup>( + 'location_manager_get_location'); + late final _dart_location_manager_get_location + _location_manager_get_location = _location_manager_get_location_ptr + .asFunction<_dart_location_manager_get_location>(); + + /// @brief Gets the current velocity information. + /// @details The result contains the current climb, direction, and speed with a measurement timestamp. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @param[in] manager The location manager handle + /// @param[out] climb The climb (km/h) + /// @param[out] direction The direction, degrees from the north + /// @param[out] speed The speed (km/h) + /// @param[out] timestamp The timestamp (time when measurement took place or @c 0 if valid) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_GPS_SETTING_OFF GPS is not enabled + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre The location service state must be #LOCATIONS_SERVICE_ENABLED with location_manager_start(). + int location_manager_get_velocity( + ffi.Pointer manager, + ffi.Pointer climb, + ffi.Pointer direction, + ffi.Pointer speed, + ffi.Pointer timestamp, + ) { + return _location_manager_get_velocity( + manager, + climb, + direction, + speed, + timestamp, + ); + } + + late final _location_manager_get_velocity_ptr = + _lookup>( + 'location_manager_get_velocity'); + late final _dart_location_manager_get_velocity + _location_manager_get_velocity = _location_manager_get_velocity_ptr + .asFunction<_dart_location_manager_get_velocity>(); + + /// @brief Gets the current accuracy information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @param[in] manager The location manager handle + /// @param[out] level The accuracy level + /// @param[out] horizontal The horizontal accuracy (meters) + /// @param[out] vertical The vertical accuracy (meters) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_GPS_SETTING_OFF GPS is not enabled + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre The location service state must be #LOCATIONS_SERVICE_ENABLED with location_manager_start(). + int location_manager_get_accuracy( + ffi.Pointer manager, + ffi.Pointer level, + ffi.Pointer horizontal, + ffi.Pointer vertical, + ) { + return _location_manager_get_accuracy( + manager, + level, + horizontal, + vertical, + ); + } + + late final _location_manager_get_accuracy_ptr = + _lookup>( + 'location_manager_get_accuracy'); + late final _dart_location_manager_get_accuracy + _location_manager_get_accuracy = _location_manager_get_accuracy_ptr + .asFunction<_dart_location_manager_get_accuracy>(); + + /// @brief Gets the last position information which is recorded. + /// @details The @a altitude, @a latitude, @a longitude, and @c timestamp values should be 0, if there is no record of any previous position information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @param[in] manager The location manager handle + /// @param[out] altitude The last altitude (meters) + /// @param[out] latitude The last latitude [-90.0 ~ 90.0] (degrees) + /// @param[out] longitude The last longitude [-180.0 ~ 180.0] (degrees) + /// @param[out] timestamp The timestamp (time when measurement took place or @c 0 if valid) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre The location manager handle must be created by location_manager_create(). + int location_manager_get_last_position( + ffi.Pointer manager, + ffi.Pointer altitude, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer timestamp, + ) { + return _location_manager_get_last_position( + manager, + altitude, + latitude, + longitude, + timestamp, + ); + } + + late final _location_manager_get_last_position_ptr = + _lookup>( + 'location_manager_get_last_position'); + late final _dart_location_manager_get_last_position + _location_manager_get_last_position = + _location_manager_get_last_position_ptr + .asFunction<_dart_location_manager_get_last_position>(); + + /// @brief Gets the last location information. + /// @details The @a altitude, @a latitude, @a longitude, @a climb, @a direction, @a speed, and @c timestamp values should be 0, if there is no record of any previous position information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @param[in] manager The location manager handle + /// @param[out] altitude The current altitude (meters) + /// @param[out] latitude The current latitude [-90.0 ~ 90.0] (degrees) + /// @param[out] longitude The current longitude [-180.0 ~ 180.0] (degrees) + /// @param[out] climb The climb (km/h) + /// @param[out] direction The direction, degrees from the north + /// @param[out] speed The speed (km/h) + /// @param[out] level The accuracy level + /// @param[out] horizontal The horizontal accuracy (meters) + /// @param[out] vertical The vertical accuracy (meters) + /// @param[out] timestamp The timestamp (time when measurement took place or @c 0 if valid) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre The location manager handle must be created by location_manager_create(). + int location_manager_get_last_location( + ffi.Pointer manager, + ffi.Pointer altitude, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer climb, + ffi.Pointer direction, + ffi.Pointer speed, + ffi.Pointer level, + ffi.Pointer horizontal, + ffi.Pointer vertical, + ffi.Pointer timestamp, + ) { + return _location_manager_get_last_location( + manager, + altitude, + latitude, + longitude, + climb, + direction, + speed, + level, + horizontal, + vertical, + timestamp, + ); + } + + late final _location_manager_get_last_location_ptr = + _lookup>( + 'location_manager_get_last_location'); + late final _dart_location_manager_get_last_location + _location_manager_get_last_location = + _location_manager_get_last_location_ptr + .asFunction<_dart_location_manager_get_last_location>(); + + /// @brief Gets the last velocity information which is recorded. + /// @details The @a climb, @a direction, and @a speed values should be @c 0, if there is no record of any previous velocity information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @param[in] manager The location manager handle + /// @param[out] climb The last climb (km/h) + /// @param[out] direction The last direction, degrees from the north + /// @param[out] speed The last speed (km/h) + /// @param[out] timestamp The timestamp (time when measurement took place or @c 0 if valid) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre The location manager handle must be created by location_manager_create(). + int location_manager_get_last_velocity( + ffi.Pointer manager, + ffi.Pointer climb, + ffi.Pointer direction, + ffi.Pointer speed, + ffi.Pointer timestamp, + ) { + return _location_manager_get_last_velocity( + manager, + climb, + direction, + speed, + timestamp, + ); + } + + late final _location_manager_get_last_velocity_ptr = + _lookup>( + 'location_manager_get_last_velocity'); + late final _dart_location_manager_get_last_velocity + _location_manager_get_last_velocity = + _location_manager_get_last_velocity_ptr + .asFunction<_dart_location_manager_get_last_velocity>(); + + /// @brief Gets the last accuracy information which is recorded. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @param[in] manager The location manager handle + /// @param[out] level The last accuracy level + /// @param[out] horizontal The last horizontal accuracy (meters) + /// @param[out] vertical The last vertical accuracy (meters) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre The location manager handle must be created by location_manager_create(). + int location_manager_get_last_accuracy( + ffi.Pointer manager, + ffi.Pointer level, + ffi.Pointer horizontal, + ffi.Pointer vertical, + ) { + return _location_manager_get_last_accuracy( + manager, + level, + horizontal, + vertical, + ); + } + + late final _location_manager_get_last_accuracy_ptr = + _lookup>( + 'location_manager_get_last_accuracy'); + late final _dart_location_manager_get_last_accuracy + _location_manager_get_last_accuracy = + _location_manager_get_last_accuracy_ptr + .asFunction<_dart_location_manager_get_last_accuracy>(); + + /// @deprecated Deprecated since 3.0 + /// @brief Gets the current application's location accessibility status. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] state The current location service accessibility status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + int location_manager_get_accessibility_state( + ffi.Pointer state, + ) { + return _location_manager_get_accessibility_state( + state, + ); + } + + late final _location_manager_get_accessibility_state_ptr = + _lookup>( + 'location_manager_get_accessibility_state'); + late final _dart_location_manager_get_accessibility_state + _location_manager_get_accessibility_state = + _location_manager_get_accessibility_state_ptr + .asFunction<_dart_location_manager_get_accessibility_state>(); + + /// @brief Registers a callback function to be invoked at defined interval with updated position information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The location manager handle + /// @param[in] callback The callback function to register + /// @param[in] interval The interval [1 ~ 120] (seconds) + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @post location_position_updated_cb() will be invoked. + /// @see location_manager_unset_position_updated_cb() + /// @see location_position_updated_cb() + int location_manager_set_position_updated_cb( + ffi.Pointer manager, + ffi.Pointer> callback, + int interval, + ffi.Pointer user_data, + ) { + return _location_manager_set_position_updated_cb( + manager, + callback, + interval, + user_data, + ); + } + + late final _location_manager_set_position_updated_cb_ptr = + _lookup>( + 'location_manager_set_position_updated_cb'); + late final _dart_location_manager_set_position_updated_cb + _location_manager_set_position_updated_cb = + _location_manager_set_position_updated_cb_ptr + .asFunction<_dart_location_manager_set_position_updated_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The location manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_set_position_updated_cb() + int location_manager_unset_position_updated_cb( + ffi.Pointer manager, + ) { + return _location_manager_unset_position_updated_cb( + manager, + ); + } + + late final _location_manager_unset_position_updated_cb_ptr = _lookup< + ffi.NativeFunction<_c_location_manager_unset_position_updated_cb>>( + 'location_manager_unset_position_updated_cb'); + late final _dart_location_manager_unset_position_updated_cb + _location_manager_unset_position_updated_cb = + _location_manager_unset_position_updated_cb_ptr + .asFunction<_dart_location_manager_unset_position_updated_cb>(); + + /// @brief Registers a callback function to be invoked at defined interval with updated velocity information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The location manager handle + /// @param[in] callback The callback function to register + /// @param[in] interval The interval [1 ~ 120] (seconds) + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @post location_velocity_updated_cb() will be invoked. + /// @see location_manager_unset_velocity_updated_cb() + /// @see location_velocity_updated_cb() + int location_manager_set_velocity_updated_cb( + ffi.Pointer manager, + ffi.Pointer> callback, + int interval, + ffi.Pointer user_data, + ) { + return _location_manager_set_velocity_updated_cb( + manager, + callback, + interval, + user_data, + ); + } + + late final _location_manager_set_velocity_updated_cb_ptr = + _lookup>( + 'location_manager_set_velocity_updated_cb'); + late final _dart_location_manager_set_velocity_updated_cb + _location_manager_set_velocity_updated_cb = + _location_manager_set_velocity_updated_cb_ptr + .asFunction<_dart_location_manager_set_velocity_updated_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The location manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_set_velocity_updated_cb() + int location_manager_unset_velocity_updated_cb( + ffi.Pointer manager, + ) { + return _location_manager_unset_velocity_updated_cb( + manager, + ); + } + + late final _location_manager_unset_velocity_updated_cb_ptr = _lookup< + ffi.NativeFunction<_c_location_manager_unset_velocity_updated_cb>>( + 'location_manager_unset_velocity_updated_cb'); + late final _dart_location_manager_unset_velocity_updated_cb + _location_manager_unset_velocity_updated_cb = + _location_manager_unset_velocity_updated_cb_ptr + .asFunction<_dart_location_manager_unset_velocity_updated_cb>(); + + /// @brief Registers a callback function to be invoked when the location service state is changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The location manager handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @post location_service_state_changed_cb() will be invoked. + /// @see location_manager_unset_service_state_changed_cb() + /// @see location_service_state_changed_cb() + /// @see location_manager_start() + /// @see location_manager_stop() + /// @see #location_service_state_e + int location_manager_set_service_state_changed_cb( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _location_manager_set_service_state_changed_cb( + manager, + callback, + user_data, + ); + } + + late final _location_manager_set_service_state_changed_cb_ptr = _lookup< + ffi.NativeFunction<_c_location_manager_set_service_state_changed_cb>>( + 'location_manager_set_service_state_changed_cb'); + late final _dart_location_manager_set_service_state_changed_cb + _location_manager_set_service_state_changed_cb = + _location_manager_set_service_state_changed_cb_ptr + .asFunction<_dart_location_manager_set_service_state_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The location manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_set_service_state_changed_cb() + int location_manager_unset_service_state_changed_cb( + ffi.Pointer manager, + ) { + return _location_manager_unset_service_state_changed_cb( + manager, + ); + } + + late final _location_manager_unset_service_state_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_location_manager_unset_service_state_changed_cb>>( + 'location_manager_unset_service_state_changed_cb'); + late final _dart_location_manager_unset_service_state_changed_cb + _location_manager_unset_service_state_changed_cb = + _location_manager_unset_service_state_changed_cb_ptr + .asFunction<_dart_location_manager_unset_service_state_changed_cb>(); + + /// @brief Registers a callback function to be invoked when the previously set boundary area is entered or left. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The location manager handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre location_manager_add_boundary() is called before. + /// @post location_zone_changed_cb() will be invoked. + /// @see location_manager_unset_zone_changed_cb() + /// @see location_zone_changed_cb() + int location_manager_set_zone_changed_cb( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _location_manager_set_zone_changed_cb( + manager, + callback, + user_data, + ); + } + + late final _location_manager_set_zone_changed_cb_ptr = + _lookup>( + 'location_manager_set_zone_changed_cb'); + late final _dart_location_manager_set_zone_changed_cb + _location_manager_set_zone_changed_cb = + _location_manager_set_zone_changed_cb_ptr + .asFunction<_dart_location_manager_set_zone_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The location manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_set_zone_changed_cb() + int location_manager_unset_zone_changed_cb( + ffi.Pointer manager, + ) { + return _location_manager_unset_zone_changed_cb( + manager, + ); + } + + late final _location_manager_unset_zone_changed_cb_ptr = + _lookup>( + 'location_manager_unset_zone_changed_cb'); + late final _dart_location_manager_unset_zone_changed_cb + _location_manager_unset_zone_changed_cb = + _location_manager_unset_zone_changed_cb_ptr + .asFunction<_dart_location_manager_unset_zone_changed_cb>(); + + /// @brief Registers a callback function to be invoked when the location setting is changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] method The method to observe + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_INCORRECT_METHOD Incorrect method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @post location_setting_changed_cb() will be invoked. + /// @see location_manager_unset_setting_changed_cb() + /// @see location_setting_changed_cb() + int location_manager_set_setting_changed_cb( + int method, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _location_manager_set_setting_changed_cb( + method, + callback, + user_data, + ); + } + + late final _location_manager_set_setting_changed_cb_ptr = + _lookup>( + 'location_manager_set_setting_changed_cb'); + late final _dart_location_manager_set_setting_changed_cb + _location_manager_set_setting_changed_cb = + _location_manager_set_setting_changed_cb_ptr + .asFunction<_dart_location_manager_set_setting_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] method The method to observe + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_INCORRECT_METHOD Incorrect method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_set_setting_changed_cb() + int location_manager_unset_setting_changed_cb( + int method, + ) { + return _location_manager_unset_setting_changed_cb( + method, + ); + } + + late final _location_manager_unset_setting_changed_cb_ptr = + _lookup>( + 'location_manager_unset_setting_changed_cb'); + late final _dart_location_manager_unset_setting_changed_cb + _location_manager_unset_setting_changed_cb = + _location_manager_unset_setting_changed_cb_ptr + .asFunction<_dart_location_manager_unset_setting_changed_cb>(); + + /// @brief Gets the distance in meters between two locations. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] start_latitude The starting latitude [-90.0 ~ 90.0] (degrees) + /// @param[in] start_longitude The starting longitude [-180.0 ~ 180.0] (degrees) + /// @param[in] end_latitude The ending latitude [-90.0 ~ 90.0] (degrees) + /// @param[in] end_longitude The ending longitude [-180.0 ~ 180.0] (degrees) + /// @param[out] distance The distance between two locations (meters) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + int location_manager_get_distance( + double start_latitude, + double start_longitude, + double end_latitude, + double end_longitude, + ffi.Pointer distance, + ) { + return _location_manager_get_distance( + start_latitude, + start_longitude, + end_latitude, + end_longitude, + distance, + ); + } + + late final _location_manager_get_distance_ptr = + _lookup>( + 'location_manager_get_distance'); + late final _dart_location_manager_get_distance + _location_manager_get_distance = _location_manager_get_distance_ptr + .asFunction<_dart_location_manager_get_distance>(); + + /// @brief Registers a callback function to be invoked at minimum interval or minimum distance with updated position information. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] manager The location manager handle + /// @param[in] callback The callback function to register + /// @param[in] interval The minimum interval between position updates [1 ~ 120] (seconds) + /// @param[in] distance The minimum distance between position updates [1 ~ 120] (meters) + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @post location_changed_cb() will be invoked. + /// @see location_manager_unset_distance_based_location_changed_cb() + /// @see location_changed_cb() + int location_manager_set_distance_based_location_changed_cb( + ffi.Pointer manager, + ffi.Pointer> callback, + int interval, + double distance, + ffi.Pointer user_data, + ) { + return _location_manager_set_distance_based_location_changed_cb( + manager, + callback, + interval, + distance, + user_data, + ); + } + + late final _location_manager_set_distance_based_location_changed_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_location_manager_set_distance_based_location_changed_cb>>( + 'location_manager_set_distance_based_location_changed_cb'); + late final _dart_location_manager_set_distance_based_location_changed_cb + _location_manager_set_distance_based_location_changed_cb = + _location_manager_set_distance_based_location_changed_cb_ptr.asFunction< + _dart_location_manager_set_distance_based_location_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] manager The location manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_set_distance_based_location_changed_cb() + int location_manager_unset_distance_based_location_changed_cb( + ffi.Pointer manager, + ) { + return _location_manager_unset_distance_based_location_changed_cb( + manager, + ); + } + + late final _location_manager_unset_distance_based_location_changed_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_location_manager_unset_distance_based_location_changed_cb>>( + 'location_manager_unset_distance_based_location_changed_cb'); + late final _dart_location_manager_unset_distance_based_location_changed_cb + _location_manager_unset_distance_based_location_changed_cb = + _location_manager_unset_distance_based_location_changed_cb_ptr.asFunction< + _dart_location_manager_unset_distance_based_location_changed_cb>(); + + /// @brief Registers a callback function to be invoked at defined interval with updated location information. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] manager The location manager handle + /// @param[in] callback The callback function to register + /// @param[in] interval The interval [1 ~ 120] (seconds) + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @post location_changed_cb() will be invoked. + /// @see location_manager_unset_location_changed_cb() + /// @see location_changed_cb() + int location_manager_set_location_changed_cb( + ffi.Pointer manager, + ffi.Pointer> callback, + int interval, + ffi.Pointer user_data, + ) { + return _location_manager_set_location_changed_cb( + manager, + callback, + interval, + user_data, + ); + } + + late final _location_manager_set_location_changed_cb_ptr = + _lookup>( + 'location_manager_set_location_changed_cb'); + late final _dart_location_manager_set_location_changed_cb + _location_manager_set_location_changed_cb = + _location_manager_set_location_changed_cb_ptr + .asFunction<_dart_location_manager_set_location_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] manager The location manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_set_location_changed_cb() + int location_manager_unset_location_changed_cb( + ffi.Pointer manager, + ) { + return _location_manager_unset_location_changed_cb( + manager, + ); + } + + late final _location_manager_unset_location_changed_cb_ptr = _lookup< + ffi.NativeFunction<_c_location_manager_unset_location_changed_cb>>( + 'location_manager_unset_location_changed_cb'); + late final _dart_location_manager_unset_location_changed_cb + _location_manager_unset_location_changed_cb = + _location_manager_unset_location_changed_cb_ptr + .asFunction<_dart_location_manager_unset_location_changed_cb>(); + + /// @brief Registers a callback function to be invoked when batch_period is expired. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The batch_period should be greater than or equal to the batch_interval. + /// In addition, sometimes the period may not work as you intended, the maximum permissible value for batch_period is device specific. + /// @param[in] manager The location manager handle + /// @param[in] callback The callback function to register + /// @param[in] batch_interval The batch sampling interval [1 ~ 255] (seconds) + /// @param[in] batch_period The batch period [1 ~ 60000] (seconds) + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @post location_batch_cb() will be invoked. + /// @see location_manager_start_batch() + /// @see location_batch_cb() + /// @see location_manager_unset_location_batch_cb() + int location_manager_set_location_batch_cb( + ffi.Pointer manager, + ffi.Pointer> callback, + int batch_interval, + int batch_period, + ffi.Pointer user_data, + ) { + return _location_manager_set_location_batch_cb( + manager, + callback, + batch_interval, + batch_period, + user_data, + ); + } + + late final _location_manager_set_location_batch_cb_ptr = + _lookup>( + 'location_manager_set_location_batch_cb'); + late final _dart_location_manager_set_location_batch_cb + _location_manager_set_location_batch_cb = + _location_manager_set_location_batch_cb_ptr + .asFunction<_dart_location_manager_set_location_batch_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] manager The location manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_set_location_batch_cb() + int location_manager_unset_location_batch_cb( + ffi.Pointer manager, + ) { + return _location_manager_unset_location_batch_cb( + manager, + ); + } + + late final _location_manager_unset_location_batch_cb_ptr = + _lookup>( + 'location_manager_unset_location_batch_cb'); + late final _dart_location_manager_unset_location_batch_cb + _location_manager_unset_location_batch_cb = + _location_manager_unset_location_batch_cb_ptr + .asFunction<_dart_location_manager_unset_location_batch_cb>(); + + /// @brief Starts the location batch service. + /// @details Calling this function starts location batch service, location_batch_cb() will be invoked every @a batch_period seconds. + /// After that, you can obtain all locations with location_manager_foreach_location_batch(). + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @remarks Calling this function invokes a location service event. When the location service is enabled, the service state change callback + /// (set using location_manager_set_service_state_changed_cb()) notifies the user with #LOCATIONS_SERVICE_ENABLED as the first argument, and the service starts. + /// @param[in] manager The location manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_INCORRECT_METHOD Incorrect method + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_NETWORK_FAILED Network failed + /// @retval #LOCATIONS_ERROR_GPS_SETTING_OFF GPS is not enabled + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre location_manager_set_location_batch_cb() + /// @see location_manager_set_service_state_changed_cb() + /// @see location_service_state_changed_cb() + /// @see location_manager_foreach_location_batch() + /// @see location_manager_stop_batch() + int location_manager_start_batch( + ffi.Pointer manager, + ) { + return _location_manager_start_batch( + manager, + ); + } + + late final _location_manager_start_batch_ptr = + _lookup>( + 'location_manager_start_batch'); + late final _dart_location_manager_start_batch _location_manager_start_batch = + _location_manager_start_batch_ptr + .asFunction<_dart_location_manager_start_batch>(); + + /// @brief Stops the location batch service. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks This function initiates the process of stopping the service. When the process is finished, callback set using + /// #location_manager_set_service_state_changed_cb() will be called, with #LOCATIONS_SERVICE_DISABLED as the first argument. + /// @param[in] manager The location manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_NETWORK_FAILED Network failed + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_start_batch() + /// @see location_manager_set_service_state_changed_cb() + /// @see location_service_state_changed_cb() + int location_manager_stop_batch( + ffi.Pointer manager, + ) { + return _location_manager_stop_batch( + manager, + ); + } + + late final _location_manager_stop_batch_ptr = + _lookup>( + 'location_manager_stop_batch'); + late final _dart_location_manager_stop_batch _location_manager_stop_batch = + _location_manager_stop_batch_ptr + .asFunction<_dart_location_manager_stop_batch>(); + + /// @brief Retrieves all location information by invoking a specific callback for each location data. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @param[in] manager The location manager handle + /// @param[in] callback The iteration callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre location_manager_foreach_location_batch() is available after location_batch_cb() is invoked. + /// @post location_batch_get_location_cb() will be invoked. + /// @see location_manager_start_batch() + /// @see location_batch_cb() + /// @see location_batch_get_location_cb() + int location_manager_foreach_location_batch( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _location_manager_foreach_location_batch( + manager, + callback, + user_data, + ); + } + + late final _location_manager_foreach_location_batch_ptr = + _lookup>( + 'location_manager_foreach_location_batch'); + late final _dart_location_manager_foreach_location_batch + _location_manager_foreach_location_batch = + _location_manager_foreach_location_batch_ptr + .asFunction<_dart_location_manager_foreach_location_batch>(); + + /// @brief Checks whether the mock location is enabled. + /// @since_tizen 3.0 + /// @param[out] enabled Indicates whether the mock location is enabled + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_enable_mock_location() + /// @see location_manager_set_mock_location() + /// @see location_manager_clear_mock_location() + int location_manager_is_enabled_mock_location( + ffi.Pointer enabled, + ) { + return _location_manager_is_enabled_mock_location( + enabled, + ); + } + + late final _location_manager_is_enabled_mock_location_ptr = + _lookup>( + 'location_manager_is_enabled_mock_location'); + late final _dart_location_manager_is_enabled_mock_location + _location_manager_is_enabled_mock_location = + _location_manager_is_enabled_mock_location_ptr + .asFunction<_dart_location_manager_is_enabled_mock_location>(); + + /// @brief Enables mock location. + /// @details The mock location is a testing function to make location API and callback deliver a mock location + /// set by location_manager_set_mock_location() instead of real positioning data even in the other applications. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @remarks The mock location can only be enabled if developer mode is enabled. + /// @param[in] enable The value to set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_SETTING_OFF MOCK location is not enabled + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED Permission denied + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_is_enabled_mock_location() + /// @see location_manager_set_mock_location() + /// @see location_manager_clear_mock_location() + int location_manager_enable_mock_location( + bool enable, + ) { + return _location_manager_enable_mock_location( + enable ? 1 : 0, + ); + } + + late final _location_manager_enable_mock_location_ptr = + _lookup>( + 'location_manager_enable_mock_location'); + late final _dart_location_manager_enable_mock_location + _location_manager_enable_mock_location = + _location_manager_enable_mock_location_ptr + .asFunction<_dart_location_manager_enable_mock_location>(); + + /// @brief Sets a mock location for the given location method. + /// @details The location sets the given altitude, latitude, longitude, climb, direction, speed, level, horizontal, and vertical accuracy. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @param[in] manager The location manager handle + /// @param[in] latitude The current latitude [-90.0 ~ 90.0] (degrees) + /// @param[in] longitude The current longitude [-180.0 ~ 180.0] (degrees) + /// @param[in] altitude The current altitude (meters) + /// @param[in] speed The speed (km/h) + /// @param[in] direction The direction, degrees from the north [0.0 ~ 360.0] + /// @param[in] accuracy The horizontal accuracy (meters) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_SETTING_OFF MOCK location is not enabled + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_create() + /// @see location_manager_is_enabled_mock_location() + /// @see location_manager_enable_mock_location() + /// @see location_manager_clear_mock_location() + int location_manager_set_mock_location( + ffi.Pointer manager, + double latitude, + double longitude, + double altitude, + double speed, + double direction, + double accuracy, + ) { + return _location_manager_set_mock_location( + manager, + latitude, + longitude, + altitude, + speed, + direction, + accuracy, + ); + } + + late final _location_manager_set_mock_location_ptr = + _lookup>( + 'location_manager_set_mock_location'); + late final _dart_location_manager_set_mock_location + _location_manager_set_mock_location = + _location_manager_set_mock_location_ptr + .asFunction<_dart_location_manager_set_mock_location>(); + + /// @brief Clears a mock location. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @param[in] manager The location manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_SETTING_OFF MOCK location is not enabled + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_create() + /// @see location_manager_is_enabled_mock_location() + /// @see location_manager_enable_mock_location() + /// @see location_manager_set_mock_location() + int location_manager_clear_mock_location( + ffi.Pointer manager, + ) { + return _location_manager_clear_mock_location( + manager, + ); + } + + late final _location_manager_clear_mock_location_ptr = + _lookup>( + 'location_manager_clear_mock_location'); + late final _dart_location_manager_clear_mock_location + _location_manager_clear_mock_location = + _location_manager_clear_mock_location_ptr + .asFunction<_dart_location_manager_clear_mock_location>(); + + /// @brief Changes behavior of the location source selection in the fused location method. + /// @since_tizen 4.0 + /// @param[in] manager The location manager handle + /// @param[in] mode The fused mode. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_INCORRECT_METHOD Incorrect method + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE The service is not available + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see location_manager_create() + int location_manager_set_fused_mode( + ffi.Pointer manager, + int mode, + ) { + return _location_manager_set_fused_mode( + manager, + mode, + ); + } + + late final _location_manager_set_fused_mode_ptr = + _lookup>( + 'location_manager_set_fused_mode'); + late final _dart_location_manager_set_fused_mode + _location_manager_set_fused_mode = _location_manager_set_fused_mode_ptr + .asFunction<_dart_location_manager_set_fused_mode>(); + + /// @brief Gets the GPS NMEA data. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This call is valid only for location managers with #LOCATIONS_METHOD_GPS method. + /// You must release @a nmea using @c free(). + /// @param[in] manager The location manager handle + /// @param[out] nmea The NMEA data + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre The location service state must be #LOCATIONS_SERVICE_ENABLED with location_manager_start(). + /// @see location_manager_start() + int gps_status_get_nmea( + ffi.Pointer manager, + ffi.Pointer> nmea, + ) { + return _gps_status_get_nmea( + manager, + nmea, + ); + } + + late final _gps_status_get_nmea_ptr = + _lookup>( + 'gps_status_get_nmea'); + late final _dart_gps_status_get_nmea _gps_status_get_nmea = + _gps_status_get_nmea_ptr.asFunction<_dart_gps_status_get_nmea>(); + + /// @brief Gets the information of satellites. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @remarks This call is valid only for location managers with #LOCATIONS_METHOD_GPS method. + /// @param[in] manager The location manager handle + /// @param[out] num_of_active The number of active satellites + /// @param[out] num_of_inview The number of satellites in view + /// @param[out] timestamp The timestamp (time when measurement took place or @c 0 if valid) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre The location service state must be #LOCATIONS_SERVICE_ENABLED with location_manager_start(). + /// @pre The gps_status_satellite_updated_cb must be set with gps_status_set_satellite_updated_cb(). + /// @see gps_status_foreach_satellites_in_view() + int gps_status_get_satellite( + ffi.Pointer manager, + ffi.Pointer num_of_active, + ffi.Pointer num_of_inview, + ffi.Pointer timestamp, + ) { + return _gps_status_get_satellite( + manager, + num_of_active, + num_of_inview, + timestamp, + ); + } + + late final _gps_status_get_satellite_ptr = + _lookup>( + 'gps_status_get_satellite'); + late final _dart_gps_status_get_satellite _gps_status_get_satellite = + _gps_status_get_satellite_ptr + .asFunction<_dart_gps_status_get_satellite>(); + + /// @brief Registers a callback function to be invoked at defined interval with updated satellite information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @param[in] manager The location manager handle + /// @param[in] callback The callback function to register + /// @param[in] interval The interval [1 ~ 120] (seconds) + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @post gps_status_satellite_updated_cb() will be invoked. + /// @see gps_status_unset_satellite_updated_cb() + /// @see gps_status_satellite_updated_cb() + /// @see gps_status_get_satellite() + /// @see gps_status_foreach_satellites_in_view() + /// @see gps_status_get_last_satellite() + /// @see gps_status_foreach_last_satellites_in_view() + int gps_status_set_satellite_updated_cb( + ffi.Pointer manager, + ffi.Pointer> callback, + int interval, + ffi.Pointer user_data, + ) { + return _gps_status_set_satellite_updated_cb( + manager, + callback, + interval, + user_data, + ); + } + + late final _gps_status_set_satellite_updated_cb_ptr = + _lookup>( + 'gps_status_set_satellite_updated_cb'); + late final _dart_gps_status_set_satellite_updated_cb + _gps_status_set_satellite_updated_cb = + _gps_status_set_satellite_updated_cb_ptr + .asFunction<_dart_gps_status_set_satellite_updated_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] manager The location manager handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @see gps_status_set_satellite_updated_cb() + int gps_status_unset_satellite_updated_cb( + ffi.Pointer manager, + ) { + return _gps_status_unset_satellite_updated_cb( + manager, + ); + } + + late final _gps_status_unset_satellite_updated_cb_ptr = + _lookup>( + 'gps_status_unset_satellite_updated_cb'); + late final _dart_gps_status_unset_satellite_updated_cb + _gps_status_unset_satellite_updated_cb = + _gps_status_unset_satellite_updated_cb_ptr + .asFunction<_dart_gps_status_unset_satellite_updated_cb>(); + + /// @brief Invokes the callback function for each satellite. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @remarks This function is valid only for location managers with the #LOCATIONS_METHOD_GPS method. + /// @param[in] manager The location manager handle + /// @param[in] callback The iteration callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_INCORRECT_METHOD Incorrect method + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre The location service state must be #LOCATIONS_SERVICE_ENABLED with location_manager_start(). + /// @pre The gps_status_satellite_updated_cb must be set with gps_status_set_satellite_updated_cb(). + /// @post It invokes gps_status_get_satellites_cb(). + /// @see gps_status_get_satellite() + /// @see gps_status_get_satellites_cb() + int gps_status_foreach_satellites_in_view( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _gps_status_foreach_satellites_in_view( + manager, + callback, + user_data, + ); + } + + late final _gps_status_foreach_satellites_in_view_ptr = + _lookup>( + 'gps_status_foreach_satellites_in_view'); + late final _dart_gps_status_foreach_satellites_in_view + _gps_status_foreach_satellites_in_view = + _gps_status_foreach_satellites_in_view_ptr + .asFunction<_dart_gps_status_foreach_satellites_in_view>(); + + /// @brief Gets the last information of satellites. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @remarks This call is valid only for location managers with #LOCATIONS_METHOD_GPS method. + /// @param[in] manager The location manager handle + /// @param[out] num_of_active The last number of active satellites + /// @param[out] num_of_inview The last number of satellites in view + /// @param[out] timestamp The last timestamp (time when last measurement took place or @c 0 if valid) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_INCORRECT_METHOD Incorrect method + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre The location service state must be #LOCATIONS_SERVICE_ENABLED with location_manager_start(). + /// @pre The gps_status_satellite_updated_cb must be set with gps_status_set_satellite_updated_cb(). + /// @see gps_status_foreach_satellites_in_view() + int gps_status_get_last_satellite( + ffi.Pointer manager, + ffi.Pointer num_of_active, + ffi.Pointer num_of_inview, + ffi.Pointer timestamp, + ) { + return _gps_status_get_last_satellite( + manager, + num_of_active, + num_of_inview, + timestamp, + ); + } + + late final _gps_status_get_last_satellite_ptr = + _lookup>( + 'gps_status_get_last_satellite'); + late final _dart_gps_status_get_last_satellite + _gps_status_get_last_satellite = _gps_status_get_last_satellite_ptr + .asFunction<_dart_gps_status_get_last_satellite>(); + + /// @brief Invokes the callback function for each last satellite which is recorded. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location + /// @remarks This function is valid only for location managers with the #LOCATIONS_METHOD_GPS method. + /// @param[in] manager The location manager handle + /// @param[in] callback The iteration callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #LOCATIONS_ERROR_NONE Successful + /// @retval #LOCATIONS_ERROR_INVALID_PARAMETER Invalid argument + /// @retval #LOCATIONS_ERROR_INCORRECT_METHOD Incorrect method + /// @retval #LOCATIONS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #LOCATIONS_ERROR_ACCESSIBILITY_NOT_ALLOWED The application does not have the privilege to call this method + /// @retval #LOCATIONS_ERROR_NOT_SUPPORTED Not supported + /// @pre The location service state must be #LOCATIONS_SERVICE_ENABLED with location_manager_start(). + /// @pre The gps_status_satellite_updated_cb must be set with gps_status_set_satellite_updated_cb(). + /// @post It invokes gps_status_get_satellites_cb(). + /// @see gps_status_get_last_satellite() + /// @see gps_status_get_satellites_cb() + int gps_status_foreach_last_satellites_in_view( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _gps_status_foreach_last_satellites_in_view( + manager, + callback, + user_data, + ); + } + + late final _gps_status_foreach_last_satellites_in_view_ptr = _lookup< + ffi.NativeFunction<_c_gps_status_foreach_last_satellites_in_view>>( + 'gps_status_foreach_last_satellites_in_view'); + late final _dart_gps_status_foreach_last_satellites_in_view + _gps_status_foreach_last_satellites_in_view = + _gps_status_foreach_last_satellites_in_view_ptr + .asFunction<_dart_gps_status_foreach_last_satellites_in_view>(); + + /// @brief Creates a new address handle. + /// @details This function creates a new address handle and allocates all needed resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a address must be released using maps_address_destroy().\n + /// @a address may be cloned using maps_address_clone(). + /// @param[out] address The address handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_address_destroy() + /// @see maps_address_clone() + int maps_address_create( + ffi.Pointer> address, + ) { + return _maps_address_create( + address, + ); + } + + late final _maps_address_create_ptr = + _lookup>( + 'maps_address_create'); + late final _dart_maps_address_create _maps_address_create = + _maps_address_create_ptr.asFunction<_dart_maps_address_create>(); + + /// @brief Destroys the address handle and releases all its resources. + /// @details This function destroys the address handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] address The address handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_create() + /// @see maps_address_clone() + int maps_address_destroy( + ffi.Pointer address, + ) { + return _maps_address_destroy( + address, + ); + } + + late final _maps_address_destroy_ptr = + _lookup>( + 'maps_address_destroy'); + late final _dart_maps_address_destroy _maps_address_destroy = + _maps_address_destroy_ptr.asFunction<_dart_maps_address_destroy>(); + + /// @brief Clones the address handle. + /// @details This function clones the address handle @a origin and all its resources.\n + /// Address handle @a origin may be created using maps_address_create(). + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_address_destroy(). + /// @param[in] origin The original address handle + /// @param[out] cloned A cloned address handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a origin is created using maps_address_create(). + /// @see maps_address_create() + /// @see maps_address_destroy() + int maps_address_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_address_clone( + origin, + cloned, + ); + } + + late final _maps_address_clone_ptr = + _lookup>('maps_address_clone'); + late final _dart_maps_address_clone _maps_address_clone = + _maps_address_clone_ptr.asFunction<_dart_maps_address_clone>(); + + /// @brief Gets the building number of the address handle. + /// @details This function gets the building number of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a building_number must be released using free(). + /// @param[in] address The address handle + /// @param[out] building_number The building number of the address handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_set_building_number() + /// @see maps_address_create() + int maps_address_get_building_number( + ffi.Pointer address, + ffi.Pointer> building_number, + ) { + return _maps_address_get_building_number( + address, + building_number, + ); + } + + late final _maps_address_get_building_number_ptr = + _lookup>( + 'maps_address_get_building_number'); + late final _dart_maps_address_get_building_number + _maps_address_get_building_number = _maps_address_get_building_number_ptr + .asFunction<_dart_maps_address_get_building_number>(); + + /// @brief Gets the street name of the address handle. + /// @details This function gets the street name of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a street must be released using free(). + /// @param[in] address The address handle + /// @param[out] street The street name of the address handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_set_street() + /// @see maps_address_create() + int maps_address_get_street( + ffi.Pointer address, + ffi.Pointer> street, + ) { + return _maps_address_get_street( + address, + street, + ); + } + + late final _maps_address_get_street_ptr = + _lookup>( + 'maps_address_get_street'); + late final _dart_maps_address_get_street _maps_address_get_street = + _maps_address_get_street_ptr.asFunction<_dart_maps_address_get_street>(); + + /// @brief Gets the district name of the address handle. + /// @details This function gets the district name of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a district must be released using free(). + /// @param[in] address The address handle + /// @param[out] district The district name of the address handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_set_district() + /// @see maps_address_create() + int maps_address_get_district( + ffi.Pointer address, + ffi.Pointer> district, + ) { + return _maps_address_get_district( + address, + district, + ); + } + + late final _maps_address_get_district_ptr = + _lookup>( + 'maps_address_get_district'); + late final _dart_maps_address_get_district _maps_address_get_district = + _maps_address_get_district_ptr + .asFunction<_dart_maps_address_get_district>(); + + /// @brief Gets the city name of the address handle. + /// @details This function gets the city name of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a city must be released using free(). + /// @param[in] address The address handle + /// @param[out] city The city name of the address handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_set_city() + /// @see maps_address_create() + int maps_address_get_city( + ffi.Pointer address, + ffi.Pointer> city, + ) { + return _maps_address_get_city( + address, + city, + ); + } + + late final _maps_address_get_city_ptr = + _lookup>( + 'maps_address_get_city'); + late final _dart_maps_address_get_city _maps_address_get_city = + _maps_address_get_city_ptr.asFunction<_dart_maps_address_get_city>(); + + /// @brief Gets the state name of the address handle. + /// @details This function gets the state name of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a state must be released using free(). + /// @param[in] address The address handle + /// @param[out] state The state name of the address handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_set_state() + /// @see maps_address_create() + int maps_address_get_state( + ffi.Pointer address, + ffi.Pointer> state, + ) { + return _maps_address_get_state( + address, + state, + ); + } + + late final _maps_address_get_state_ptr = + _lookup>( + 'maps_address_get_state'); + late final _dart_maps_address_get_state _maps_address_get_state = + _maps_address_get_state_ptr.asFunction<_dart_maps_address_get_state>(); + + /// @brief Gets the country name of the address handle. + /// @details This function gets the country name of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a country must be released using free(). + /// @param[in] address The address handle + /// @param[out] country The country name of the address handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_set_country() + /// @see maps_address_create() + int maps_address_get_country( + ffi.Pointer address, + ffi.Pointer> country, + ) { + return _maps_address_get_country( + address, + country, + ); + } + + late final _maps_address_get_country_ptr = + _lookup>( + 'maps_address_get_country'); + late final _dart_maps_address_get_country _maps_address_get_country = + _maps_address_get_country_ptr + .asFunction<_dart_maps_address_get_country>(); + + /// @brief Gets the country code of the address handle. + /// @details This function gets the country code of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a country_code must be released using free(). + /// @param[in] address The address handle + /// @param[out] country_code The country code of the address handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_set_country_code() + /// @see maps_address_create() + int maps_address_get_country_code( + ffi.Pointer address, + ffi.Pointer> country_code, + ) { + return _maps_address_get_country_code( + address, + country_code, + ); + } + + late final _maps_address_get_country_code_ptr = + _lookup>( + 'maps_address_get_country_code'); + late final _dart_maps_address_get_country_code + _maps_address_get_country_code = _maps_address_get_country_code_ptr + .asFunction<_dart_maps_address_get_country_code>(); + + /// @brief Gets the county of the address handle. + /// @details This function gets the county of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a county must be released using free(). + /// @param[in] address The address handle + /// @param[out] county The county of the address handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_set_county() + /// @see maps_address_create() + int maps_address_get_county( + ffi.Pointer address, + ffi.Pointer> county, + ) { + return _maps_address_get_county( + address, + county, + ); + } + + late final _maps_address_get_county_ptr = + _lookup>( + 'maps_address_get_county'); + late final _dart_maps_address_get_county _maps_address_get_county = + _maps_address_get_county_ptr.asFunction<_dart_maps_address_get_county>(); + + /// @brief Gets the postal code of the address handle. + /// @details This function gets the postal code of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a postal_code must be released using free(). + /// @param[in] address The address handle + /// @param[out] postal_code The postal code of the address handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_set_postal_code() + /// @see maps_address_create() + int maps_address_get_postal_code( + ffi.Pointer address, + ffi.Pointer> postal_code, + ) { + return _maps_address_get_postal_code( + address, + postal_code, + ); + } + + late final _maps_address_get_postal_code_ptr = + _lookup>( + 'maps_address_get_postal_code'); + late final _dart_maps_address_get_postal_code _maps_address_get_postal_code = + _maps_address_get_postal_code_ptr + .asFunction<_dart_maps_address_get_postal_code>(); + + /// @brief Gets the free text of the address handle. + /// @details This function gets the free text of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a freetext must be released using free(). + /// @param[in] address The address handle + /// @param[out] freetext The free text of the address handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_set_freetext() + /// @see maps_address_create() + int maps_address_get_freetext( + ffi.Pointer address, + ffi.Pointer> freetext, + ) { + return _maps_address_get_freetext( + address, + freetext, + ); + } + + late final _maps_address_get_freetext_ptr = + _lookup>( + 'maps_address_get_freetext'); + late final _dart_maps_address_get_freetext _maps_address_get_freetext = + _maps_address_get_freetext_ptr + .asFunction<_dart_maps_address_get_freetext>(); + + /// @brief Sets the building number of the address handle. + /// @details This function sets the building number of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] address The address handle + /// @param[in] building_number The building number to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_create() + /// @see maps_address_get_number() + int maps_address_set_building_number( + ffi.Pointer address, + ffi.Pointer building_number, + ) { + return _maps_address_set_building_number( + address, + building_number, + ); + } + + late final _maps_address_set_building_number_ptr = + _lookup>( + 'maps_address_set_building_number'); + late final _dart_maps_address_set_building_number + _maps_address_set_building_number = _maps_address_set_building_number_ptr + .asFunction<_dart_maps_address_set_building_number>(); + + /// @brief Sets the street name of the address handle. + /// @details This function sets the street name of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] address The address handle + /// @param[in] street The street name to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_create() + /// @see maps_address_get_street() + int maps_address_set_street( + ffi.Pointer address, + ffi.Pointer street, + ) { + return _maps_address_set_street( + address, + street, + ); + } + + late final _maps_address_set_street_ptr = + _lookup>( + 'maps_address_set_street'); + late final _dart_maps_address_set_street _maps_address_set_street = + _maps_address_set_street_ptr.asFunction<_dart_maps_address_set_street>(); + + /// @brief Sets the district name of the address handle. + /// @details This function sets the district name of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] address The address handle + /// @param[in] district The district name to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_create() + /// @see maps_address_get_district() + int maps_address_set_district( + ffi.Pointer address, + ffi.Pointer district, + ) { + return _maps_address_set_district( + address, + district, + ); + } + + late final _maps_address_set_district_ptr = + _lookup>( + 'maps_address_set_district'); + late final _dart_maps_address_set_district _maps_address_set_district = + _maps_address_set_district_ptr + .asFunction<_dart_maps_address_set_district>(); + + /// @brief Sets the city name of the address handle. + /// @details This function sets the city name of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] address The address handle + /// @param[in] city The city name to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_create() + /// @see maps_address_get_city() + int maps_address_set_city( + ffi.Pointer address, + ffi.Pointer city, + ) { + return _maps_address_set_city( + address, + city, + ); + } + + late final _maps_address_set_city_ptr = + _lookup>( + 'maps_address_set_city'); + late final _dart_maps_address_set_city _maps_address_set_city = + _maps_address_set_city_ptr.asFunction<_dart_maps_address_set_city>(); + + /// @brief Sets the state name of the address handle. + /// @details This function sets the state name of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] address The address handle + /// @param[in] state The state name to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_create() + /// @see maps_address_get_state() + int maps_address_set_state( + ffi.Pointer address, + ffi.Pointer state, + ) { + return _maps_address_set_state( + address, + state, + ); + } + + late final _maps_address_set_state_ptr = + _lookup>( + 'maps_address_set_state'); + late final _dart_maps_address_set_state _maps_address_set_state = + _maps_address_set_state_ptr.asFunction<_dart_maps_address_set_state>(); + + /// @brief Sets the country name of the address handle. + /// @details This function sets the country name of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] address The address handle + /// @param[in] country The country name to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_create() + /// @see maps_address_get_country() + int maps_address_set_country( + ffi.Pointer address, + ffi.Pointer country, + ) { + return _maps_address_set_country( + address, + country, + ); + } + + late final _maps_address_set_country_ptr = + _lookup>( + 'maps_address_set_country'); + late final _dart_maps_address_set_country _maps_address_set_country = + _maps_address_set_country_ptr + .asFunction<_dart_maps_address_set_country>(); + + /// @brief Sets the country code of the address handle. + /// @details This function sets the country code of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] address The address handle + /// @param[in] country_code The country code to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_create() + /// @see maps_address_get_country_code() + int maps_address_set_country_code( + ffi.Pointer address, + ffi.Pointer country_code, + ) { + return _maps_address_set_country_code( + address, + country_code, + ); + } + + late final _maps_address_set_country_code_ptr = + _lookup>( + 'maps_address_set_country_code'); + late final _dart_maps_address_set_country_code + _maps_address_set_country_code = _maps_address_set_country_code_ptr + .asFunction<_dart_maps_address_set_country_code>(); + + /// @brief Sets the county of the address handle. + /// @details This function sets the county of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] address The address handle + /// @param[in] county The county to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_create() + /// @see maps_address_get_county() + int maps_address_set_county( + ffi.Pointer address, + ffi.Pointer county, + ) { + return _maps_address_set_county( + address, + county, + ); + } + + late final _maps_address_set_county_ptr = + _lookup>( + 'maps_address_set_county'); + late final _dart_maps_address_set_county _maps_address_set_county = + _maps_address_set_county_ptr.asFunction<_dart_maps_address_set_county>(); + + /// @brief Sets the postal code of the address handle. + /// @details This function sets the postal code of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] address The address handle + /// @param[in] postal_code The postal code to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_create() + /// @see maps_address_get_postal_code() + int maps_address_set_postal_code( + ffi.Pointer address, + ffi.Pointer postal_code, + ) { + return _maps_address_set_postal_code( + address, + postal_code, + ); + } + + late final _maps_address_set_postal_code_ptr = + _lookup>( + 'maps_address_set_postal_code'); + late final _dart_maps_address_set_postal_code _maps_address_set_postal_code = + _maps_address_set_postal_code_ptr + .asFunction<_dart_maps_address_set_postal_code>(); + + /// @brief Sets the free text of the address handle. + /// @details This function sets the free text of the address handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] address The address handle + /// @param[in] freetext The free text to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a address is created using maps_address_create(). + /// @see maps_address_create() + /// @see maps_address_get_freetext() + int maps_address_set_freetext( + ffi.Pointer address, + ffi.Pointer freetext, + ) { + return _maps_address_set_freetext( + address, + freetext, + ); + } + + late final _maps_address_set_freetext_ptr = + _lookup>( + 'maps_address_set_freetext'); + late final _dart_maps_address_set_freetext _maps_address_set_freetext = + _maps_address_set_freetext_ptr + .asFunction<_dart_maps_address_set_freetext>(); + + /// @brief Creates an address list having a set of addresses. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[out] address_list The address list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_address_list_destroy() + int maps_address_list_create( + ffi.Pointer> address_list, + ) { + return _maps_address_list_create( + address_list, + ); + } + + late final _maps_address_list_create_ptr = + _lookup>( + 'maps_address_list_create'); + late final _dart_maps_address_list_create _maps_address_list_create = + _maps_address_list_create_ptr + .asFunction<_dart_maps_address_list_create>(); + + /// @brief Appends an address to an address list. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks Don't release @a address before removed from the list using maps_address_list_remove(). + /// @param[in] address_list The address list handle + /// @param[in] address The address handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_address_list_create() + /// @see maps_address_list_destroy() + /// @see maps_address_create() + int maps_address_list_append( + ffi.Pointer address_list, + ffi.Pointer address, + ) { + return _maps_address_list_append( + address_list, + address, + ); + } + + late final _maps_address_list_append_ptr = + _lookup>( + 'maps_address_list_append'); + late final _dart_maps_address_list_append _maps_address_list_append = + _maps_address_list_append_ptr + .asFunction<_dart_maps_address_list_append>(); + + /// @brief Removes an address from an address list. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a address is just excepted from the list.\n + /// It must be released using maps_address_destroy(). + /// @param[in] address_list The address list handle + /// @param[in] address The address handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_address_list_create() + /// @see maps_address_list_destroy() + /// @see maps_address_destroy() + int maps_address_list_remove( + ffi.Pointer address_list, + ffi.Pointer address, + ) { + return _maps_address_list_remove( + address_list, + address, + ); + } + + late final _maps_address_list_remove_ptr = + _lookup>( + 'maps_address_list_remove'); + late final _dart_maps_address_list_remove _maps_address_list_remove = + _maps_address_list_remove_ptr + .asFunction<_dart_maps_address_list_remove>(); + + /// @brief Gets the number of elements in an address list. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] address_list The address list handle + /// @param[out] length The number of elements in the address list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_address_list_create() + /// @see maps_address_list_destroy() + int maps_address_list_get_length( + ffi.Pointer address_list, + ffi.Pointer length, + ) { + return _maps_address_list_get_length( + address_list, + length, + ); + } + + late final _maps_address_list_get_length_ptr = + _lookup>( + 'maps_address_list_get_length'); + late final _dart_maps_address_list_get_length _maps_address_list_get_length = + _maps_address_list_get_length_ptr + .asFunction<_dart_maps_address_list_get_length>(); + + /// @brief Retrieves all addresses by invoking a specific callback for each address of address list. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] address_list The address list handle + /// @param[in] callback The iteration callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_address_list_create() + /// @see maps_address_list_destroy() + /// @see maps_address_list_get_length() + int maps_address_list_foreach( + ffi.Pointer address_list, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_address_list_foreach( + address_list, + callback, + user_data, + ); + } + + late final _maps_address_list_foreach_ptr = + _lookup>( + 'maps_address_list_foreach'); + late final _dart_maps_address_list_foreach _maps_address_list_foreach = + _maps_address_list_foreach_ptr + .asFunction<_dart_maps_address_list_foreach>(); + + /// @brief Frees all of the memory used by an address list. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] address_list The address list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_address_list_create() + int maps_address_list_destroy( + ffi.Pointer address_list, + ) { + return _maps_address_list_destroy( + address_list, + ); + } + + late final _maps_address_list_destroy_ptr = + _lookup>( + 'maps_address_list_destroy'); + late final _dart_maps_address_list_destroy _maps_address_list_destroy = + _maps_address_list_destroy_ptr + .asFunction<_dart_maps_address_list_destroy>(); + + /// @brief Creates a new instance of Geographical Coordinates and initiates a handle with it. + /// @details This function creates @a coordinates, a new instance of Geographical Coordinates of type #maps_coordinates_h with a specified @a latitude and @a longitude.\n + /// New handle is assigned with this instance. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a coordinates must be released using maps_coordinates_destroy().\n + /// @a coordinates may be cloned using maps_coordinates_clone(). + /// @param[in] latitude The latitude [-90.0 ~ 90.0] (degrees) + /// @param[in] longitude The longitude [-180.0 ~ 180.0] (degrees) + /// @param[out] coordinates The coordinates handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_coordinates_clone() + /// @see maps_coordinates_destroy() + int maps_coordinates_create( + double latitude, + double longitude, + ffi.Pointer> coordinates, + ) { + return _maps_coordinates_create( + latitude, + longitude, + coordinates, + ); + } + + late final _maps_coordinates_create_ptr = + _lookup>( + 'maps_coordinates_create'); + late final _dart_maps_coordinates_create _maps_coordinates_create = + _maps_coordinates_create_ptr.asFunction<_dart_maps_coordinates_create>(); + + /// @brief Destroys the Geographical Coordinates and releases all its resources. + /// @details This function destroys the Geographical Coordinates #maps_coordinates_h and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] coordinates The coordinate handle to destroy + /// @return @c 0 on coordinates, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a coordinates are created using maps_coordinates_create_rectangle(). + /// @see maps_coordinates_create() + /// @see maps_coordinates_clone() + int maps_coordinates_destroy( + ffi.Pointer coordinates, + ) { + return _maps_coordinates_destroy( + coordinates, + ); + } + + late final _maps_coordinates_destroy_ptr = + _lookup>( + 'maps_coordinates_destroy'); + late final _dart_maps_coordinates_destroy _maps_coordinates_destroy = + _maps_coordinates_destroy_ptr + .asFunction<_dart_maps_coordinates_destroy>(); + + /// @brief Clones the Geographical Coordinates. + /// @details This function makes a clone of the @a origin Geographical Coordinates of type #maps_coordinates_h. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_coordinates_destroy(). + /// @param[in] origin The original coordinate handle + /// @param[out] cloned A cloned coordinate handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a origin is created using maps_coordinates_create(). + /// @see maps_coordinates_create() + /// @see maps_coordinates_destroy() + int maps_coordinates_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_coordinates_clone( + origin, + cloned, + ); + } + + late final _maps_coordinates_clone_ptr = + _lookup>( + 'maps_coordinates_clone'); + late final _dart_maps_coordinates_clone _maps_coordinates_clone = + _maps_coordinates_clone_ptr.asFunction<_dart_maps_coordinates_clone>(); + + /// @brief Gets the latitude of the coordinates. + /// @details This function gets the @a latitude value of the coordinates handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] coordinates The coordinate handle + /// @param[out] latitude The latitude of the coordinate handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a coordinates are created using maps_coordinates_create(). + /// @see maps_coordinates_create() + /// @see maps_coordinates_set_latitude() + int maps_coordinates_get_latitude( + ffi.Pointer coordinates, + ffi.Pointer latitude, + ) { + return _maps_coordinates_get_latitude( + coordinates, + latitude, + ); + } + + late final _maps_coordinates_get_latitude_ptr = + _lookup>( + 'maps_coordinates_get_latitude'); + late final _dart_maps_coordinates_get_latitude + _maps_coordinates_get_latitude = _maps_coordinates_get_latitude_ptr + .asFunction<_dart_maps_coordinates_get_latitude>(); + + /// @brief Gets the longitude of the coordinates. + /// @details This function gets the @a longitude value of the coordinates handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] coordinates The coordinate handle + /// @param[out] longitude The longitude of the coordinate handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a coordinates are created using maps_coordinates_create(). + /// @see maps_coordinates_create() + /// @see maps_coordinates_set_longitude() + int maps_coordinates_get_longitude( + ffi.Pointer coordinates, + ffi.Pointer longitude, + ) { + return _maps_coordinates_get_longitude( + coordinates, + longitude, + ); + } + + late final _maps_coordinates_get_longitude_ptr = + _lookup>( + 'maps_coordinates_get_longitude'); + late final _dart_maps_coordinates_get_longitude + _maps_coordinates_get_longitude = _maps_coordinates_get_longitude_ptr + .asFunction<_dart_maps_coordinates_get_longitude>(); + + /// @brief Gets the latitude and longitude of the coordinates. + /// @details This function gets the @a longitude and @a longitude value of the coordinates handle. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] coordinates The coordinate handle + /// @param[out] latitude The latitude of the coordinate handle + /// @param[out] longitude The longitude of the coordinate handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a coordinates are created using maps_coordinates_create(). + /// @see maps_coordinates_create() + /// @see maps_coordinates_set_latitude_longitude() + int maps_coordinates_get_latitude_longitude( + ffi.Pointer coordinates, + ffi.Pointer latitude, + ffi.Pointer longitude, + ) { + return _maps_coordinates_get_latitude_longitude( + coordinates, + latitude, + longitude, + ); + } + + late final _maps_coordinates_get_latitude_longitude_ptr = + _lookup>( + 'maps_coordinates_get_latitude_longitude'); + late final _dart_maps_coordinates_get_latitude_longitude + _maps_coordinates_get_latitude_longitude = + _maps_coordinates_get_latitude_longitude_ptr + .asFunction<_dart_maps_coordinates_get_latitude_longitude>(); + + /// @brief Sets the latitude of the coordinates. + /// @details This function sets the @a latitude value of the coordinates handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] coordinates The coordinate handle + /// @param[in] latitude The latitude of the coordinate handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a coordinates are created using maps_coordinates_create(). + /// @see maps_coordinates_create() + /// @see maps_coordinates_get_latitude() + int maps_coordinates_set_latitude( + ffi.Pointer coordinates, + double latitude, + ) { + return _maps_coordinates_set_latitude( + coordinates, + latitude, + ); + } + + late final _maps_coordinates_set_latitude_ptr = + _lookup>( + 'maps_coordinates_set_latitude'); + late final _dart_maps_coordinates_set_latitude + _maps_coordinates_set_latitude = _maps_coordinates_set_latitude_ptr + .asFunction<_dart_maps_coordinates_set_latitude>(); + + /// @brief Sets the longitude of the coordinates. + /// @details This function sets the @a longitude value of the coordinates handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] coordinates The coordinate handle + /// @param[out] longitude The longitude of the coordinate handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a coordinates are created using maps_coordinates_create(). + /// @see maps_coordinates_create() + /// @see maps_coordinates_get_longitude() + int maps_coordinates_set_longitude( + ffi.Pointer coordinates, + double longitude, + ) { + return _maps_coordinates_set_longitude( + coordinates, + longitude, + ); + } + + late final _maps_coordinates_set_longitude_ptr = + _lookup>( + 'maps_coordinates_set_longitude'); + late final _dart_maps_coordinates_set_longitude + _maps_coordinates_set_longitude = _maps_coordinates_set_longitude_ptr + .asFunction<_dart_maps_coordinates_set_longitude>(); + + /// @brief Sets the latitude and longitude of the coordinates. + /// @details This function sets the @a latitude and @a latitude value of the coordinates handle. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] coordinates The coordinates handle + /// @param[in] latitude The latitude [-90.0 ~ 90.0] (degrees) + /// @param[in] longitude The longitude [-180.0 ~ 180.0] (degrees) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a coordinates are created using maps_coordinates_create(). + /// @see maps_coordinates_create() + /// @see maps_coordinates_get_latitude_longitude() + int maps_coordinates_set_latitude_longitude( + ffi.Pointer coordinates, + double latitude, + double longitude, + ) { + return _maps_coordinates_set_latitude_longitude( + coordinates, + latitude, + longitude, + ); + } + + late final _maps_coordinates_set_latitude_longitude_ptr = + _lookup>( + 'maps_coordinates_set_latitude_longitude'); + late final _dart_maps_coordinates_set_latitude_longitude + _maps_coordinates_set_latitude_longitude = + _maps_coordinates_set_latitude_longitude_ptr + .asFunction<_dart_maps_coordinates_set_latitude_longitude>(); + + /// @brief Creates a coordinates list having a set of coordinates. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[out] coordinates_list The coordinates list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_coordinates_list_destroy() + int maps_coordinates_list_create( + ffi.Pointer> coordinates_list, + ) { + return _maps_coordinates_list_create( + coordinates_list, + ); + } + + late final _maps_coordinates_list_create_ptr = + _lookup>( + 'maps_coordinates_list_create'); + late final _dart_maps_coordinates_list_create _maps_coordinates_list_create = + _maps_coordinates_list_create_ptr + .asFunction<_dart_maps_coordinates_list_create>(); + + /// @brief Frees all of the memory used by a coordinates list. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] coordinates_list The coordinates list handle + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_coordinates_list_create() + int maps_coordinates_list_destroy( + ffi.Pointer coordinates_list, + ) { + return _maps_coordinates_list_destroy( + coordinates_list, + ); + } + + late final _maps_coordinates_list_destroy_ptr = + _lookup>( + 'maps_coordinates_list_destroy'); + late final _dart_maps_coordinates_list_destroy + _maps_coordinates_list_destroy = _maps_coordinates_list_destroy_ptr + .asFunction<_dart_maps_coordinates_list_destroy>(); + + /// @brief Appends a coordinates to a coordinates list. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] coordinates_list The coordinates list handle + /// @param[in] coordinates The coordinates handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_coordinates_list_create() + /// @see maps_coordinates_list_destroy() + int maps_coordinates_list_append( + ffi.Pointer coordinates_list, + ffi.Pointer coordinates, + ) { + return _maps_coordinates_list_append( + coordinates_list, + coordinates, + ); + } + + late final _maps_coordinates_list_append_ptr = + _lookup>( + 'maps_coordinates_list_append'); + late final _dart_maps_coordinates_list_append _maps_coordinates_list_append = + _maps_coordinates_list_append_ptr + .asFunction<_dart_maps_coordinates_list_append>(); + + /// @brief Removes a coordinates from a coordinates list. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] coordinates_list The coordinates list handle + /// @param[in] coordinates The coordinates handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_coordinates_list_create() + /// @see maps_coordinates_list_destroy() + int maps_coordinates_list_remove( + ffi.Pointer coordinates_list, + ffi.Pointer coordinates, + ) { + return _maps_coordinates_list_remove( + coordinates_list, + coordinates, + ); + } + + late final _maps_coordinates_list_remove_ptr = + _lookup>( + 'maps_coordinates_list_remove'); + late final _dart_maps_coordinates_list_remove _maps_coordinates_list_remove = + _maps_coordinates_list_remove_ptr + .asFunction<_dart_maps_coordinates_list_remove>(); + + /// @brief Gets the number of elements in a coordinates list. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] coordinates_list The coordinates list handle + /// @param[out] length The number of elements in the coordinates list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_coordinates_list_create() + /// @see maps_coordinates_list_destroy() + int maps_coordinates_list_get_length( + ffi.Pointer coordinates_list, + ffi.Pointer length, + ) { + return _maps_coordinates_list_get_length( + coordinates_list, + length, + ); + } + + late final _maps_coordinates_list_get_length_ptr = + _lookup>( + 'maps_coordinates_list_get_length'); + late final _dart_maps_coordinates_list_get_length + _maps_coordinates_list_get_length = _maps_coordinates_list_get_length_ptr + .asFunction<_dart_maps_coordinates_list_get_length>(); + + /// @brief Retrieves all coordinates by invoking a specific callback for each coordinates of coordinates list. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] coordinates_list The coordinates list handle + /// @param[in] callback The iteration callback + /// @param[in] user_data The user data to be passed to the callback function + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_coordinates_list_create() + /// @see maps_coordinates_list_destroy() + /// @see maps_coordinates_list_get_length() + int maps_coordinates_list_foreach( + ffi.Pointer coordinates_list, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_coordinates_list_foreach( + coordinates_list, + callback, + user_data, + ); + } + + late final _maps_coordinates_list_foreach_ptr = + _lookup>( + 'maps_coordinates_list_foreach'); + late final _dart_maps_coordinates_list_foreach + _maps_coordinates_list_foreach = _maps_coordinates_list_foreach_ptr + .asFunction<_dart_maps_coordinates_list_foreach>(); + + /// @brief Creates a rectangular type of new Geographical Area with a specified information. + /// @details This function creates a rectangular type of new #maps_area_h with a specified left top and right bottom coordinates. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a area must be released using maps_area_destroy().\n + /// @a area may be cloned using maps_area_clone().\n + /// @a top_left and @a bottom_right must be released using maps_coordinates_destroy(). + /// @param[in] top_left The left top position + /// @param[in] bottom_right The right bottom position + /// @param[out] area The area handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a top_left and @a bottom_right are created using maps_coordinates_create(). + /// @see maps_area_clone() + /// @see maps_area_destroy() + /// @see maps_area_create_circle() + /// @see maps_coordinates_create() + /// @see maps_coordinates_destroy() + int maps_area_create_rectangle( + ffi.Pointer top_left, + ffi.Pointer bottom_right, + ffi.Pointer> area, + ) { + return _maps_area_create_rectangle( + top_left, + bottom_right, + area, + ); + } + + late final _maps_area_create_rectangle_ptr = + _lookup>( + 'maps_area_create_rectangle'); + late final _dart_maps_area_create_rectangle _maps_area_create_rectangle = + _maps_area_create_rectangle_ptr + .asFunction<_dart_maps_area_create_rectangle>(); + + /// @brief Creates a circular type of new Geographical Area with a specified information. + /// @details This function creates a circular type of new #maps_area_h Geographical Area with a specified center coordinates and a radius. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a area must be released using maps_area_destroy().\n + /// @a center must be released using maps_coordinates_destroy().\n + /// The @a radius is specified in units, listed in #maps_distance_unit_e.\n + /// To get and set distance units use maps_preference_get_distance_unit() and maps_preference_set_distance_unit() respectively. + /// @param[in] center The central position of the area + /// @param[in] radius The radius of the area + /// @param[out] area The area handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a center is created using maps_coordinates_create(). + /// @see maps_area_clone() + /// @see maps_area_destroy() + /// @see maps_area_create_rectangle() + /// @see maps_coordinates_create() + /// @see maps_coordinates_destroy() + /// @see maps_preference_get_distance_unit() + /// @see maps_preference_set_distance_unit() + int maps_area_create_circle( + ffi.Pointer center, + double radius, + ffi.Pointer> area, + ) { + return _maps_area_create_circle( + center, + radius, + area, + ); + } + + late final _maps_area_create_circle_ptr = + _lookup>( + 'maps_area_create_circle'); + late final _dart_maps_area_create_circle _maps_area_create_circle = + _maps_area_create_circle_ptr.asFunction<_dart_maps_area_create_circle>(); + + /// @brief Destroys the Geographical Area and releases all its resources. + /// @details This function destroys the Geographical Area #maps_area_h and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] area The area #maps_area_h + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a area can be created using maps_area_create_rectangle() or maps_area_create_circle(). + /// @see maps_area_create_rectangle() + /// @see maps_area_create_circle() + int maps_area_destroy( + ffi.Pointer area, + ) { + return _maps_area_destroy( + area, + ); + } + + late final _maps_area_destroy_ptr = + _lookup>('maps_area_destroy'); + late final _dart_maps_area_destroy _maps_area_destroy = + _maps_area_destroy_ptr.asFunction<_dart_maps_area_destroy>(); + + /// @brief Clones the Geographical Area. + /// @details This function makes a clone of the @a origin Geographical Area of type #maps_area_h. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_area_destroy(). + /// @param[in] origin The area #maps_area_h to be copied + /// @param[out] cloned The cloned area #maps_area_h handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a origin is created using maps_area_create_rectangle() or maps_area_create_circle(). + /// @see maps_area_create_rectangle() + /// @see maps_area_create_circle() + /// @see maps_area_destroy() + int maps_area_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_area_clone( + origin, + cloned, + ); + } + + late final _maps_area_clone_ptr = + _lookup>('maps_area_clone'); + late final _dart_maps_area_clone _maps_area_clone = + _maps_area_clone_ptr.asFunction<_dart_maps_area_clone>(); + + /// @brief Creates a new place category handle. + /// @details This function creates a new place category handle and allocates all needed resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a category must be released using maps_place_category_destroy().\n + /// @a category may be cloned using maps_place_category_clone(). + /// @param[out] category A handle of a new place category on success + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_category_destroy() + /// @see maps_place_category_clone() + int maps_place_category_create( + ffi.Pointer> category, + ) { + return _maps_place_category_create( + category, + ); + } + + late final _maps_place_category_create_ptr = + _lookup>( + 'maps_place_category_create'); + late final _dart_maps_place_category_create _maps_place_category_create = + _maps_place_category_create_ptr + .asFunction<_dart_maps_place_category_create>(); + + /// @brief Clones the place category handle. + /// @details This function clones the place category handle @a origin and all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_place_category_destroy(). + /// @param[in] origin The original place category handle + /// @param[out] cloned A cloned place category handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_category_destroy() + int maps_place_category_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_place_category_clone( + origin, + cloned, + ); + } + + late final _maps_place_category_clone_ptr = + _lookup>( + 'maps_place_category_clone'); + late final _dart_maps_place_category_clone _maps_place_category_clone = + _maps_place_category_clone_ptr + .asFunction<_dart_maps_place_category_clone>(); + + /// @brief Destroys the place category handle and releases all its resources. + /// @details This function destroys the place category handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] category The place category handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_category_clone() + int maps_place_category_destroy( + ffi.Pointer category, + ) { + return _maps_place_category_destroy( + category, + ); + } + + late final _maps_place_category_destroy_ptr = + _lookup>( + 'maps_place_category_destroy'); + late final _dart_maps_place_category_destroy _maps_place_category_destroy = + _maps_place_category_destroy_ptr + .asFunction<_dart_maps_place_category_destroy>(); + + /// @brief Gets the place category ID. + /// @details This function gets the place category ID. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a id must be released using free(). + /// @param[in] category The handle of place category + /// @param[out] id The place category ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_category_get_id( + ffi.Pointer category, + ffi.Pointer> id, + ) { + return _maps_place_category_get_id( + category, + id, + ); + } + + late final _maps_place_category_get_id_ptr = + _lookup>( + 'maps_place_category_get_id'); + late final _dart_maps_place_category_get_id _maps_place_category_get_id = + _maps_place_category_get_id_ptr + .asFunction<_dart_maps_place_category_get_id>(); + + /// @brief Gets the place category name. + /// @details This function gets the place category name. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a name must be released using free(). + /// @param[in] category The handle of place category + /// @param[out] name The place category name + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_category_get_name( + ffi.Pointer category, + ffi.Pointer> name, + ) { + return _maps_place_category_get_name( + category, + name, + ); + } + + late final _maps_place_category_get_name_ptr = + _lookup>( + 'maps_place_category_get_name'); + late final _dart_maps_place_category_get_name _maps_place_category_get_name = + _maps_place_category_get_name_ptr + .asFunction<_dart_maps_place_category_get_name>(); + + /// @brief Gets the place category URL. + /// @details This function gets the place category URL. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a url must be released using free(). + /// @param[in] category The handle of place category + /// @param[out] url The place category URL + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_category_get_url( + ffi.Pointer category, + ffi.Pointer> url, + ) { + return _maps_place_category_get_url( + category, + url, + ); + } + + late final _maps_place_category_get_url_ptr = + _lookup>( + 'maps_place_category_get_url'); + late final _dart_maps_place_category_get_url _maps_place_category_get_url = + _maps_place_category_get_url_ptr + .asFunction<_dart_maps_place_category_get_url>(); + + /// @brief Sets the place category ID. + /// @details This function sets the place category ID. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] category The handle of place category + /// @param[in] id The place category ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a category is created using maps_place_category_create(). + /// @see maps_place_category_create() + /// @see maps_place_category_get_id() + int maps_place_category_set_id( + ffi.Pointer category, + ffi.Pointer id, + ) { + return _maps_place_category_set_id( + category, + id, + ); + } + + late final _maps_place_category_set_id_ptr = + _lookup>( + 'maps_place_category_set_id'); + late final _dart_maps_place_category_set_id _maps_place_category_set_id = + _maps_place_category_set_id_ptr + .asFunction<_dart_maps_place_category_set_id>(); + + /// @brief Sets the place category name. + /// @details This function sets the place category name. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] category The handle of place category + /// @param[in] name The place category name + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a category is created using maps_place_category_create(). + /// @see maps_place_category_create() + /// @see maps_place_category_get_name() + int maps_place_category_set_name( + ffi.Pointer category, + ffi.Pointer name, + ) { + return _maps_place_category_set_name( + category, + name, + ); + } + + late final _maps_place_category_set_name_ptr = + _lookup>( + 'maps_place_category_set_name'); + late final _dart_maps_place_category_set_name _maps_place_category_set_name = + _maps_place_category_set_name_ptr + .asFunction<_dart_maps_place_category_set_name>(); + + /// @brief Sets the place category URL. + /// @details This function sets the place category URL. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] category The handle of place category + /// @param[in] url The place category URL + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a category is created using maps_place_category_create(). + /// @see maps_place_category_create() + /// @see maps_place_category_get_url() + int maps_place_category_set_url( + ffi.Pointer category, + ffi.Pointer url, + ) { + return _maps_place_category_set_url( + category, + url, + ); + } + + late final _maps_place_category_set_url_ptr = + _lookup>( + 'maps_place_category_set_url'); + late final _dart_maps_place_category_set_url _maps_place_category_set_url = + _maps_place_category_set_url_ptr + .asFunction<_dart_maps_place_category_set_url>(); + + /// @brief Destroys the place attribute handle and releases all its resources. + /// @details This function destroys the place attribute handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] attribute The place attribute handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_attribute_clone() + int maps_place_attribute_destroy( + ffi.Pointer attribute, + ) { + return _maps_place_attribute_destroy( + attribute, + ); + } + + late final _maps_place_attribute_destroy_ptr = + _lookup>( + 'maps_place_attribute_destroy'); + late final _dart_maps_place_attribute_destroy _maps_place_attribute_destroy = + _maps_place_attribute_destroy_ptr + .asFunction<_dart_maps_place_attribute_destroy>(); + + /// @brief Clones the place attribute handle. + /// @details This function clones the place attribute handle @a origin and all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_place_attribute_destroy(). + /// @param[in] origin The original place attribute handle + /// @param[out] cloned A cloned place attribute handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_attribute_destroy() + int maps_place_attribute_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_place_attribute_clone( + origin, + cloned, + ); + } + + late final _maps_place_attribute_clone_ptr = + _lookup>( + 'maps_place_attribute_clone'); + late final _dart_maps_place_attribute_clone _maps_place_attribute_clone = + _maps_place_attribute_clone_ptr + .asFunction<_dart_maps_place_attribute_clone>(); + + /// @brief Gets the place attribute ID. + /// @details This function gets the place attribute ID. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a id must be released using free(). + /// @param[in] attribute The handle to place attribute + /// @param[out] id The place attribute ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_attribute_get_id( + ffi.Pointer attribute, + ffi.Pointer> id, + ) { + return _maps_place_attribute_get_id( + attribute, + id, + ); + } + + late final _maps_place_attribute_get_id_ptr = + _lookup>( + 'maps_place_attribute_get_id'); + late final _dart_maps_place_attribute_get_id _maps_place_attribute_get_id = + _maps_place_attribute_get_id_ptr + .asFunction<_dart_maps_place_attribute_get_id>(); + + /// @brief Gets the place attribute label. + /// @details This function gets the place attribute label. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a label must be released using free(). + /// @param[in] attribute The handle to place attribute + /// @param[out] label The place attribute label + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_attribute_get_label( + ffi.Pointer attribute, + ffi.Pointer> label, + ) { + return _maps_place_attribute_get_label( + attribute, + label, + ); + } + + late final _maps_place_attribute_get_label_ptr = + _lookup>( + 'maps_place_attribute_get_label'); + late final _dart_maps_place_attribute_get_label + _maps_place_attribute_get_label = _maps_place_attribute_get_label_ptr + .asFunction<_dart_maps_place_attribute_get_label>(); + + /// @brief Gets the place attribute text. + /// @details This function gets the place attribute text. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a text must be released using free(). + /// @param[in] attribute The handle to place attribute + /// @param[out] text The place attribute text + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_attribute_get_text( + ffi.Pointer attribute, + ffi.Pointer> text, + ) { + return _maps_place_attribute_get_text( + attribute, + text, + ); + } + + late final _maps_place_attribute_get_text_ptr = + _lookup>( + 'maps_place_attribute_get_text'); + late final _dart_maps_place_attribute_get_text + _maps_place_attribute_get_text = _maps_place_attribute_get_text_ptr + .asFunction<_dart_maps_place_attribute_get_text>(); + + /// @brief Destroys the place contact handle and releases all its resources. + /// @details This function destroys the place contact handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] contact The place contact handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_contact_clone() + int maps_place_contact_destroy( + ffi.Pointer contact, + ) { + return _maps_place_contact_destroy( + contact, + ); + } + + late final _maps_place_contact_destroy_ptr = + _lookup>( + 'maps_place_contact_destroy'); + late final _dart_maps_place_contact_destroy _maps_place_contact_destroy = + _maps_place_contact_destroy_ptr + .asFunction<_dart_maps_place_contact_destroy>(); + + /// @brief Clones the place contact handle. + /// @details This function clones the place contact handle @a origin and all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_place_contact_destroy(). + /// @param[in] origin The original place contact handle + /// @param[out] cloned A cloned place contact handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_contact_destroy() + int maps_place_contact_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_place_contact_clone( + origin, + cloned, + ); + } + + late final _maps_place_contact_clone_ptr = + _lookup>( + 'maps_place_contact_clone'); + late final _dart_maps_place_contact_clone _maps_place_contact_clone = + _maps_place_contact_clone_ptr + .asFunction<_dart_maps_place_contact_clone>(); + + /// @brief Gets the place contact label. + /// @details This function gets the place contact label. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a label must be released using free(). + /// @param[in] contact The handle to place contact + /// @param[out] label The place contact label + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_contact_get_label( + ffi.Pointer contact, + ffi.Pointer> label, + ) { + return _maps_place_contact_get_label( + contact, + label, + ); + } + + late final _maps_place_contact_get_label_ptr = + _lookup>( + 'maps_place_contact_get_label'); + late final _dart_maps_place_contact_get_label _maps_place_contact_get_label = + _maps_place_contact_get_label_ptr + .asFunction<_dart_maps_place_contact_get_label>(); + + /// @brief Gets the place contact type. + /// @details This function gets the place contact type. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a type must be released using free(). + /// @param[in] contact The handle to place contact + /// @param[out] type The place contact type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_contact_get_type( + ffi.Pointer contact, + ffi.Pointer> type, + ) { + return _maps_place_contact_get_type( + contact, + type, + ); + } + + late final _maps_place_contact_get_type_ptr = + _lookup>( + 'maps_place_contact_get_type'); + late final _dart_maps_place_contact_get_type _maps_place_contact_get_type = + _maps_place_contact_get_type_ptr + .asFunction<_dart_maps_place_contact_get_type>(); + + /// @brief Gets the place contact value. + /// @details This function gets the place contact value. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a value must be released using free(). + /// @param[in] contact The handle to place contact + /// @param[out] value The place contact value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_contact_get_value( + ffi.Pointer contact, + ffi.Pointer> value, + ) { + return _maps_place_contact_get_value( + contact, + value, + ); + } + + late final _maps_place_contact_get_value_ptr = + _lookup>( + 'maps_place_contact_get_value'); + late final _dart_maps_place_contact_get_value _maps_place_contact_get_value = + _maps_place_contact_get_value_ptr + .asFunction<_dart_maps_place_contact_get_value>(); + + /// @brief Destroys the place link object handle and releases all its resources. + /// @details This function destroys the place link object handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] link The place link object handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_link_object_clone() + int maps_place_link_object_destroy( + ffi.Pointer link, + ) { + return _maps_place_link_object_destroy( + link, + ); + } + + late final _maps_place_link_object_destroy_ptr = + _lookup>( + 'maps_place_link_object_destroy'); + late final _dart_maps_place_link_object_destroy + _maps_place_link_object_destroy = _maps_place_link_object_destroy_ptr + .asFunction<_dart_maps_place_link_object_destroy>(); + + /// @brief Clones the place link object handle. + /// @details This function clones the place link object handle @a origin and all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_place_link_object_destroy(). + /// @param[in] origin The original place link object handle + /// @param[out] cloned A cloned place link object handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_link_object_destroy() + int maps_place_link_object_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_place_link_object_clone( + origin, + cloned, + ); + } + + late final _maps_place_link_object_clone_ptr = + _lookup>( + 'maps_place_link_object_clone'); + late final _dart_maps_place_link_object_clone _maps_place_link_object_clone = + _maps_place_link_object_clone_ptr + .asFunction<_dart_maps_place_link_object_clone>(); + + /// @brief Gets the place link object ID. + /// @details This function gets the place link object ID. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a id must be released using free(). + /// @param[in] link The handle of place link object + /// @param[out] id The place link object ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_link_object_get_id( + ffi.Pointer link, + ffi.Pointer> id, + ) { + return _maps_place_link_object_get_id( + link, + id, + ); + } + + late final _maps_place_link_object_get_id_ptr = + _lookup>( + 'maps_place_link_object_get_id'); + late final _dart_maps_place_link_object_get_id + _maps_place_link_object_get_id = _maps_place_link_object_get_id_ptr + .asFunction<_dart_maps_place_link_object_get_id>(); + + /// @brief Gets the place link object name. + /// @details This function gets the place link object name. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a name must be released using free(). + /// @param[in] link The handle of place link object + /// @param[out] name The place link object name + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_link_object_get_name( + ffi.Pointer link, + ffi.Pointer> name, + ) { + return _maps_place_link_object_get_name( + link, + name, + ); + } + + late final _maps_place_link_object_get_name_ptr = + _lookup>( + 'maps_place_link_object_get_name'); + late final _dart_maps_place_link_object_get_name + _maps_place_link_object_get_name = _maps_place_link_object_get_name_ptr + .asFunction<_dart_maps_place_link_object_get_name>(); + + /// @brief Gets the place link object string. + /// @details This function gets the place link object string. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a string must be released using free(). + /// @param[in] link The handle of place link object + /// @param[out] string The place link object string + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_link_object_get_string( + ffi.Pointer link, + ffi.Pointer> string, + ) { + return _maps_place_link_object_get_string( + link, + string, + ); + } + + late final _maps_place_link_object_get_string_ptr = + _lookup>( + 'maps_place_link_object_get_string'); + late final _dart_maps_place_link_object_get_string + _maps_place_link_object_get_string = + _maps_place_link_object_get_string_ptr + .asFunction<_dart_maps_place_link_object_get_string>(); + + /// @brief Gets the place link object type. + /// @details This function gets the place link object type. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a type must be released using free(). + /// @param[in] link The handle of place link object + /// @param[out] type The place link object type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_link_object_get_type( + ffi.Pointer link, + ffi.Pointer> type, + ) { + return _maps_place_link_object_get_type( + link, + type, + ); + } + + late final _maps_place_link_object_get_type_ptr = + _lookup>( + 'maps_place_link_object_get_type'); + late final _dart_maps_place_link_object_get_type + _maps_place_link_object_get_type = _maps_place_link_object_get_type_ptr + .asFunction<_dart_maps_place_link_object_get_type>(); + + /// @brief Destroys the place media handle and releases all its resources. + /// @details This function destroys the place media handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] media The place media handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_media_clone() + int maps_place_media_destroy( + ffi.Pointer media, + ) { + return _maps_place_media_destroy( + media, + ); + } + + late final _maps_place_media_destroy_ptr = + _lookup>( + 'maps_place_media_destroy'); + late final _dart_maps_place_media_destroy _maps_place_media_destroy = + _maps_place_media_destroy_ptr + .asFunction<_dart_maps_place_media_destroy>(); + + /// @brief Clones the place media handle. + /// @details This function clones the place media handle @a origin and all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_place_media_destroy(). + /// @param[in] origin The original place media handle + /// @param[out] cloned A cloned place media handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_media_destroy() + int maps_place_media_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_place_media_clone( + origin, + cloned, + ); + } + + late final _maps_place_media_clone_ptr = + _lookup>( + 'maps_place_media_clone'); + late final _dart_maps_place_media_clone _maps_place_media_clone = + _maps_place_media_clone_ptr.asFunction<_dart_maps_place_media_clone>(); + + /// @brief Gets the place media attribution. + /// @details This function gets the place media attribution. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a attribution must be released using free(). + /// @param[in] media The handle of place media + /// @param[out] attribution The place media attribution + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_media_get_attribution( + ffi.Pointer media, + ffi.Pointer> attribution, + ) { + return _maps_place_media_get_attribution( + media, + attribution, + ); + } + + late final _maps_place_media_get_attribution_ptr = + _lookup>( + 'maps_place_media_get_attribution'); + late final _dart_maps_place_media_get_attribution + _maps_place_media_get_attribution = _maps_place_media_get_attribution_ptr + .asFunction<_dart_maps_place_media_get_attribution>(); + + /// @brief Gets the place media supplier link. + /// @details This function gets the place media supplier link. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a supplier must be released using maps_place_link_object_destroy(). + /// @param[in] media The handle of place media + /// @param[out] supplier The place media supplier link + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_place_link_object_h + int maps_place_media_get_supplier( + ffi.Pointer media, + ffi.Pointer> supplier, + ) { + return _maps_place_media_get_supplier( + media, + supplier, + ); + } + + late final _maps_place_media_get_supplier_ptr = + _lookup>( + 'maps_place_media_get_supplier'); + late final _dart_maps_place_media_get_supplier + _maps_place_media_get_supplier = _maps_place_media_get_supplier_ptr + .asFunction<_dart_maps_place_media_get_supplier>(); + + /// @brief Gets the place media "via" link. + /// @details This function gets the place media "via" link. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a via must be released using maps_place_link_object_destroy(). + /// @param[in] media The handle of place media + /// @param[out] via The place media via link + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_place_link_object_h + int maps_place_media_get_via( + ffi.Pointer media, + ffi.Pointer> via, + ) { + return _maps_place_media_get_via( + media, + via, + ); + } + + late final _maps_place_media_get_via_ptr = + _lookup>( + 'maps_place_media_get_via'); + late final _dart_maps_place_media_get_via _maps_place_media_get_via = + _maps_place_media_get_via_ptr + .asFunction<_dart_maps_place_media_get_via>(); + + /// @brief Destroys the place editorial handle and releases all its resources. + /// @details This function destroys the place editorial handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] editorial The place editorial handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_editorial_clone() + int maps_place_editorial_destroy( + ffi.Pointer editorial, + ) { + return _maps_place_editorial_destroy( + editorial, + ); + } + + late final _maps_place_editorial_destroy_ptr = + _lookup>( + 'maps_place_editorial_destroy'); + late final _dart_maps_place_editorial_destroy _maps_place_editorial_destroy = + _maps_place_editorial_destroy_ptr + .asFunction<_dart_maps_place_editorial_destroy>(); + + /// @brief Clones the place editorial handle. + /// @details This function clones the place editorial handle @a origin and all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_place_editorial_destroy(). + /// @param[in] origin The original place editorial handle + /// @param[out] cloned A cloned place editorial handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_editorial_destroy() + int maps_place_editorial_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_place_editorial_clone( + origin, + cloned, + ); + } + + late final _maps_place_editorial_clone_ptr = + _lookup>( + 'maps_place_editorial_clone'); + late final _dart_maps_place_editorial_clone _maps_place_editorial_clone = + _maps_place_editorial_clone_ptr + .asFunction<_dart_maps_place_editorial_clone>(); + + /// @brief Gets the place editorial description. + /// @details This function gets the place editorial description. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a description must be released using free(). + /// @param[in] editorial The handle of place editorial + /// @param[out] description The place editorial description + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_editorial_get_description( + ffi.Pointer editorial, + ffi.Pointer> description, + ) { + return _maps_place_editorial_get_description( + editorial, + description, + ); + } + + late final _maps_place_editorial_get_description_ptr = + _lookup>( + 'maps_place_editorial_get_description'); + late final _dart_maps_place_editorial_get_description + _maps_place_editorial_get_description = + _maps_place_editorial_get_description_ptr + .asFunction<_dart_maps_place_editorial_get_description>(); + + /// @brief Gets the place editorial language. + /// @details This function gets the place editorial language. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a language must be released using free(). + /// @param[in] editorial The handle of place editorial + /// @param[out] language The place editorial language + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_editorial_get_language( + ffi.Pointer editorial, + ffi.Pointer> language, + ) { + return _maps_place_editorial_get_language( + editorial, + language, + ); + } + + late final _maps_place_editorial_get_language_ptr = + _lookup>( + 'maps_place_editorial_get_language'); + late final _dart_maps_place_editorial_get_language + _maps_place_editorial_get_language = + _maps_place_editorial_get_language_ptr + .asFunction<_dart_maps_place_editorial_get_language>(); + + /// @brief Gets the place editorial media. + /// @details This function gets the place editorial media. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a media must be released using maps_place_media_destroy(). + /// @param[in] editorial The handle of place editorial + /// @param[out] media The place editorial media + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_place_media_h + int maps_place_editorial_get_media( + ffi.Pointer editorial, + ffi.Pointer> media, + ) { + return _maps_place_editorial_get_media( + editorial, + media, + ); + } + + late final _maps_place_editorial_get_media_ptr = + _lookup>( + 'maps_place_editorial_get_media'); + late final _dart_maps_place_editorial_get_media + _maps_place_editorial_get_media = _maps_place_editorial_get_media_ptr + .asFunction<_dart_maps_place_editorial_get_media>(); + + /// @brief Destroys the place image handle and releases all its resources. + /// @details This function destroys the place image handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] image The place image handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_image_clone() + int maps_place_image_destroy( + ffi.Pointer image, + ) { + return _maps_place_image_destroy( + image, + ); + } + + late final _maps_place_image_destroy_ptr = + _lookup>( + 'maps_place_image_destroy'); + late final _dart_maps_place_image_destroy _maps_place_image_destroy = + _maps_place_image_destroy_ptr + .asFunction<_dart_maps_place_image_destroy>(); + + /// @brief Clones the place image handle. + /// @details This function clones the place image handle @a origin and all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_place_image_destroy(). + /// @param[in] origin The original place image handle + /// @param[out] cloned A cloned place image handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_image_destroy() + int maps_place_image_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_place_image_clone( + origin, + cloned, + ); + } + + late final _maps_place_image_clone_ptr = + _lookup>( + 'maps_place_image_clone'); + late final _dart_maps_place_image_clone _maps_place_image_clone = + _maps_place_image_clone_ptr.asFunction<_dart_maps_place_image_clone>(); + + /// @brief Gets the place image ID. + /// @details This function gets the place image ID. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a id must be released using free(). + /// @param[in] image The handle of place image + /// @param[out] id The place image ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_image_get_id( + ffi.Pointer image, + ffi.Pointer> id, + ) { + return _maps_place_image_get_id( + image, + id, + ); + } + + late final _maps_place_image_get_id_ptr = + _lookup>( + 'maps_place_image_get_id'); + late final _dart_maps_place_image_get_id _maps_place_image_get_id = + _maps_place_image_get_id_ptr.asFunction<_dart_maps_place_image_get_id>(); + + /// @brief Gets the place image URL. + /// @details This function gets the place image URL. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a url must be released using free(). + /// @param[in] image The handle of place image + /// @param[out] url The place image url + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_image_get_url( + ffi.Pointer image, + ffi.Pointer> url, + ) { + return _maps_place_image_get_url( + image, + url, + ); + } + + late final _maps_place_image_get_url_ptr = + _lookup>( + 'maps_place_image_get_url'); + late final _dart_maps_place_image_get_url _maps_place_image_get_url = + _maps_place_image_get_url_ptr + .asFunction<_dart_maps_place_image_get_url>(); + + /// @brief Gets the place image width. + /// @details This function gets the place image width. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] image The handle of place image + /// @param[out] width The place image width + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_image_get_width( + ffi.Pointer image, + ffi.Pointer width, + ) { + return _maps_place_image_get_width( + image, + width, + ); + } + + late final _maps_place_image_get_width_ptr = + _lookup>( + 'maps_place_image_get_width'); + late final _dart_maps_place_image_get_width _maps_place_image_get_width = + _maps_place_image_get_width_ptr + .asFunction<_dart_maps_place_image_get_width>(); + + /// @brief Gets the place image height. + /// @details This function gets the place image height. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] image The handle of place image + /// @param[out] height The place image height + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_image_get_height( + ffi.Pointer image, + ffi.Pointer height, + ) { + return _maps_place_image_get_height( + image, + height, + ); + } + + late final _maps_place_image_get_height_ptr = + _lookup>( + 'maps_place_image_get_height'); + late final _dart_maps_place_image_get_height _maps_place_image_get_height = + _maps_place_image_get_height_ptr + .asFunction<_dart_maps_place_image_get_height>(); + + /// @brief Gets the place image user link. + /// @details This function gets the place image user link. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a user must be released using maps_place_link_object_destroy(). + /// @param[in] image The handle of place image + /// @param[out] user The place image user link + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_place_link_object_h + int maps_place_image_get_user_link( + ffi.Pointer image, + ffi.Pointer> user, + ) { + return _maps_place_image_get_user_link( + image, + user, + ); + } + + late final _maps_place_image_get_user_link_ptr = + _lookup>( + 'maps_place_image_get_user_link'); + late final _dart_maps_place_image_get_user_link + _maps_place_image_get_user_link = _maps_place_image_get_user_link_ptr + .asFunction<_dart_maps_place_image_get_user_link>(); + + /// @brief Gets the place image media. + /// @details This function gets the place image media. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a media must be released using maps_place_media_destroy(). + /// @param[in] image The handle of place image + /// @param[out] media The place image media + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_place_media_h + int maps_place_image_get_media( + ffi.Pointer image, + ffi.Pointer> media, + ) { + return _maps_place_image_get_media( + image, + media, + ); + } + + late final _maps_place_image_get_media_ptr = + _lookup>( + 'maps_place_image_get_media'); + late final _dart_maps_place_image_get_media _maps_place_image_get_media = + _maps_place_image_get_media_ptr + .asFunction<_dart_maps_place_image_get_media>(); + + /// @brief Destroys the place review handle and releases all its resources. + /// @details This function destroys the place review handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] review The place review handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_review_clone() + int maps_place_review_destroy( + ffi.Pointer review, + ) { + return _maps_place_review_destroy( + review, + ); + } + + late final _maps_place_review_destroy_ptr = + _lookup>( + 'maps_place_review_destroy'); + late final _dart_maps_place_review_destroy _maps_place_review_destroy = + _maps_place_review_destroy_ptr + .asFunction<_dart_maps_place_review_destroy>(); + + /// @brief Clones the place review handle. + /// @details This function clones the place review handle @a origin and all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_place_review_destroy(). + /// @param[in] origin The original place review handle + /// @param[out] cloned A cloned place review handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_review_destroy() + int maps_place_review_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_place_review_clone( + origin, + cloned, + ); + } + + late final _maps_place_review_clone_ptr = + _lookup>( + 'maps_place_review_clone'); + late final _dart_maps_place_review_clone _maps_place_review_clone = + _maps_place_review_clone_ptr.asFunction<_dart_maps_place_review_clone>(); + + /// @brief Gets the place review date. + /// @details This function gets the place review date. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a date must be released using free(). + /// @param[in] review The handle to place review + /// @param[out] date The place review date + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_review_get_date( + ffi.Pointer review, + ffi.Pointer> date, + ) { + return _maps_place_review_get_date( + review, + date, + ); + } + + late final _maps_place_review_get_date_ptr = + _lookup>( + 'maps_place_review_get_date'); + late final _dart_maps_place_review_get_date _maps_place_review_get_date = + _maps_place_review_get_date_ptr + .asFunction<_dart_maps_place_review_get_date>(); + + /// @brief Gets the place review title. + /// @details This function gets the place review title. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a title must be released using free(). + /// @param[in] review The handle to place review + /// @param[out] title The place review title + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_review_get_title( + ffi.Pointer review, + ffi.Pointer> title, + ) { + return _maps_place_review_get_title( + review, + title, + ); + } + + late final _maps_place_review_get_title_ptr = + _lookup>( + 'maps_place_review_get_title'); + late final _dart_maps_place_review_get_title _maps_place_review_get_title = + _maps_place_review_get_title_ptr + .asFunction<_dart_maps_place_review_get_title>(); + + /// @brief Gets the place review rating. + /// @details This function gets the place review rating. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] review The handle to place review + /// @param[out] rating The place review rating + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_review_get_rating( + ffi.Pointer review, + ffi.Pointer rating, + ) { + return _maps_place_review_get_rating( + review, + rating, + ); + } + + late final _maps_place_review_get_rating_ptr = + _lookup>( + 'maps_place_review_get_rating'); + late final _dart_maps_place_review_get_rating _maps_place_review_get_rating = + _maps_place_review_get_rating_ptr + .asFunction<_dart_maps_place_review_get_rating>(); + + /// @brief Gets the place review description. + /// @details This function gets the place review description. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a description must be released using free(). + /// @param[in] review The handle to place review + /// @param[out] description The place review description + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_review_get_description( + ffi.Pointer review, + ffi.Pointer> description, + ) { + return _maps_place_review_get_description( + review, + description, + ); + } + + late final _maps_place_review_get_description_ptr = + _lookup>( + 'maps_place_review_get_description'); + late final _dart_maps_place_review_get_description + _maps_place_review_get_description = + _maps_place_review_get_description_ptr + .asFunction<_dart_maps_place_review_get_description>(); + + /// @brief Gets the place review language. + /// @details This function gets the place review language. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a language must be released using free(). + /// @param[in] review The handle to place review + /// @param[out] language The place review language + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_review_get_language( + ffi.Pointer review, + ffi.Pointer> language, + ) { + return _maps_place_review_get_language( + review, + language, + ); + } + + late final _maps_place_review_get_language_ptr = + _lookup>( + 'maps_place_review_get_language'); + late final _dart_maps_place_review_get_language + _maps_place_review_get_language = _maps_place_review_get_language_ptr + .asFunction<_dart_maps_place_review_get_language>(); + + /// @brief Gets the place review media. + /// @details This function gets the place review media. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a media must be released using maps_place_media_destroy(). + /// @param[in] review The handle to place review + /// @param[out] media The place review media + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_place_media_h + int maps_place_review_get_media( + ffi.Pointer review, + ffi.Pointer> media, + ) { + return _maps_place_review_get_media( + review, + media, + ); + } + + late final _maps_place_review_get_media_ptr = + _lookup>( + 'maps_place_review_get_media'); + late final _dart_maps_place_review_get_media _maps_place_review_get_media = + _maps_place_review_get_media_ptr + .asFunction<_dart_maps_place_review_get_media>(); + + /// @brief Gets the place review user link. + /// @details This function gets the place review user link. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a user must be released using maps_place_link_object_destroy(). + /// @param[in] review The handle to place review + /// @param[out] user The place review user link + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_place_link_object_h + int maps_place_review_get_user_link( + ffi.Pointer review, + ffi.Pointer> user, + ) { + return _maps_place_review_get_user_link( + review, + user, + ); + } + + late final _maps_place_review_get_user_link_ptr = + _lookup>( + 'maps_place_review_get_user_link'); + late final _dart_maps_place_review_get_user_link + _maps_place_review_get_user_link = _maps_place_review_get_user_link_ptr + .asFunction<_dart_maps_place_review_get_user_link>(); + + /// @brief Destroys the place rating handle and releases all its resources. + /// @details This function destroys the place rating handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] rating The place rating handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_rating_clone() + int maps_place_rating_destroy( + ffi.Pointer rating, + ) { + return _maps_place_rating_destroy( + rating, + ); + } + + late final _maps_place_rating_destroy_ptr = + _lookup>( + 'maps_place_rating_destroy'); + late final _dart_maps_place_rating_destroy _maps_place_rating_destroy = + _maps_place_rating_destroy_ptr + .asFunction<_dart_maps_place_rating_destroy>(); + + /// @brief Clones the place rating handle. + /// @details This function clones the place rating handle @a origin and all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_place_rating_destroy(). + /// @param[in] origin The original place rating handle + /// @param[out] cloned A cloned place rating handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_rating_destroy() + int maps_place_rating_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_place_rating_clone( + origin, + cloned, + ); + } + + late final _maps_place_rating_clone_ptr = + _lookup>( + 'maps_place_rating_clone'); + late final _dart_maps_place_rating_clone _maps_place_rating_clone = + _maps_place_rating_clone_ptr.asFunction<_dart_maps_place_rating_clone>(); + + /// @brief Gets the place rating count. + /// @details This function gets the place rating count. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] rating The handle to place rating handle + /// @param[out] count The place rating count + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_rating_get_count( + ffi.Pointer rating, + ffi.Pointer count, + ) { + return _maps_place_rating_get_count( + rating, + count, + ); + } + + late final _maps_place_rating_get_count_ptr = + _lookup>( + 'maps_place_rating_get_count'); + late final _dart_maps_place_rating_get_count _maps_place_rating_get_count = + _maps_place_rating_get_count_ptr + .asFunction<_dart_maps_place_rating_get_count>(); + + /// @brief Gets the place rating average. + /// @details This function gets the place rating average. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] rating The handle to place rating handle + /// @param[out] average The place average rating + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_rating_get_average( + ffi.Pointer rating, + ffi.Pointer average, + ) { + return _maps_place_rating_get_average( + rating, + average, + ); + } + + late final _maps_place_rating_get_average_ptr = + _lookup>( + 'maps_place_rating_get_average'); + late final _dart_maps_place_rating_get_average + _maps_place_rating_get_average = _maps_place_rating_get_average_ptr + .asFunction<_dart_maps_place_rating_get_average>(); + + /// @brief Destroys the place handle and releases all its resources. + /// @details This function destroys the place handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] place The place handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_clone() + int maps_place_destroy( + ffi.Pointer place, + ) { + return _maps_place_destroy( + place, + ); + } + + late final _maps_place_destroy_ptr = + _lookup>('maps_place_destroy'); + late final _dart_maps_place_destroy _maps_place_destroy = + _maps_place_destroy_ptr.asFunction<_dart_maps_place_destroy>(); + + /// @brief Clones the place handle. + /// @details This function clones the place handle @a origin and all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_place_destroy(). + /// @param[in] origin The original place handle + /// @param[out] cloned A cloned place handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_destroy() + int maps_place_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_place_clone( + origin, + cloned, + ); + } + + late final _maps_place_clone_ptr = + _lookup>('maps_place_clone'); + late final _dart_maps_place_clone _maps_place_clone = + _maps_place_clone_ptr.asFunction<_dart_maps_place_clone>(); + + /// @brief Gets the place ID. + /// @details This function gets the place ID. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a id must be released using free(). + /// @param[in] place The place handle + /// @param[out] id The place ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_get_id( + ffi.Pointer place, + ffi.Pointer> id, + ) { + return _maps_place_get_id( + place, + id, + ); + } + + late final _maps_place_get_id_ptr = + _lookup>('maps_place_get_id'); + late final _dart_maps_place_get_id _maps_place_get_id = + _maps_place_get_id_ptr.asFunction<_dart_maps_place_get_id>(); + + /// @brief Gets the place name. + /// @details This function gets the place name. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a name must be released using free(). + /// @param[in] place The place handle + /// @param[out] name The place name + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_get_name( + ffi.Pointer place, + ffi.Pointer> name, + ) { + return _maps_place_get_name( + place, + name, + ); + } + + late final _maps_place_get_name_ptr = + _lookup>( + 'maps_place_get_name'); + late final _dart_maps_place_get_name _maps_place_get_name = + _maps_place_get_name_ptr.asFunction<_dart_maps_place_get_name>(); + + /// @brief Gets the place view URI. + /// @details This function gets the place view URI. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a uri must be released using free(). + /// @param[in] place The place handle + /// @param[out] uri The place view URI + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_get_uri( + ffi.Pointer place, + ffi.Pointer> uri, + ) { + return _maps_place_get_uri( + place, + uri, + ); + } + + late final _maps_place_get_uri_ptr = + _lookup>('maps_place_get_uri'); + late final _dart_maps_place_get_uri _maps_place_get_uri = + _maps_place_get_uri_ptr.asFunction<_dart_maps_place_get_uri>(); + + /// @brief Gets the place location. + /// @details This function gets the place location. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a location must be released using maps_coordinates_destroy(). + /// @param[in] place The place handle + /// @param[out] location The place location + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_get_location( + ffi.Pointer place, + ffi.Pointer> location, + ) { + return _maps_place_get_location( + place, + location, + ); + } + + late final _maps_place_get_location_ptr = + _lookup>( + 'maps_place_get_location'); + late final _dart_maps_place_get_location _maps_place_get_location = + _maps_place_get_location_ptr.asFunction<_dart_maps_place_get_location>(); + + /// @brief Gets the place distance from the center of the location. + /// @details This function gets the place distance from the center of the location. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] place The place handle + /// @param[out] distance The place distance in meters + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_get_distance( + ffi.Pointer place, + ffi.Pointer distance, + ) { + return _maps_place_get_distance( + place, + distance, + ); + } + + late final _maps_place_get_distance_ptr = + _lookup>( + 'maps_place_get_distance'); + late final _dart_maps_place_get_distance _maps_place_get_distance = + _maps_place_get_distance_ptr.asFunction<_dart_maps_place_get_distance>(); + + /// @brief Gets the place address. + /// @details This function gets the place address. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a address must be released using maps_address_destroy(). + /// @param[in] place The place handle + /// @param[out] address The place address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_get_address( + ffi.Pointer place, + ffi.Pointer> address, + ) { + return _maps_place_get_address( + place, + address, + ); + } + + late final _maps_place_get_address_ptr = + _lookup>( + 'maps_place_get_address'); + late final _dart_maps_place_get_address _maps_place_get_address = + _maps_place_get_address_ptr.asFunction<_dart_maps_place_get_address>(); + + /// @brief Gets the place rating. + /// @details This function gets the place rating. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a rating must be released using maps_place_rating_destroy(). + /// @param[in] place The place handle + /// @param[out] rating The place rating handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_get_rating( + ffi.Pointer place, + ffi.Pointer> rating, + ) { + return _maps_place_get_rating( + place, + rating, + ); + } + + late final _maps_place_get_rating_ptr = + _lookup>( + 'maps_place_get_rating'); + late final _dart_maps_place_get_rating _maps_place_get_rating = + _maps_place_get_rating_ptr.asFunction<_dart_maps_place_get_rating>(); + + /// @brief Retrieves all properties. + /// @details This function retrieves all place properties. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The properties will be delivered via maps_place_properties_cb(). + /// @param[in] place The place handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_place_properties_cb() repeatedly to retrieve each property. + /// @see maps_place_properties_cb() + int maps_place_foreach_property( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_place_foreach_property( + place, + callback, + user_data, + ); + } + + late final _maps_place_foreach_property_ptr = + _lookup>( + 'maps_place_foreach_property'); + late final _dart_maps_place_foreach_property _maps_place_foreach_property = + _maps_place_foreach_property_ptr + .asFunction<_dart_maps_place_foreach_property>(); + + /// @brief Retrieves all categories + /// @details This function retrieves all place categories. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The categories will be delivered via maps_place_categories_cb(). + /// @param[in] place The place handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_place_categories_cb() repeatedly to retrieve each category. + /// @see maps_place_categories_cb() + int maps_place_foreach_category( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_place_foreach_category( + place, + callback, + user_data, + ); + } + + late final _maps_place_foreach_category_ptr = + _lookup>( + 'maps_place_foreach_category'); + late final _dart_maps_place_foreach_category _maps_place_foreach_category = + _maps_place_foreach_category_ptr + .asFunction<_dart_maps_place_foreach_category>(); + + /// @brief Retrieves all attributes. + /// @details This function retrieves all place attributes. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The attributes will be delivered via maps_place_attributes_cb(). + /// @param[in] place The place handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_place_attributes_cb() repeatedly to retrieve each attribute. + /// @see maps_place_attributes_cb() + int maps_place_foreach_attribute( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_place_foreach_attribute( + place, + callback, + user_data, + ); + } + + late final _maps_place_foreach_attribute_ptr = + _lookup>( + 'maps_place_foreach_attribute'); + late final _dart_maps_place_foreach_attribute _maps_place_foreach_attribute = + _maps_place_foreach_attribute_ptr + .asFunction<_dart_maps_place_foreach_attribute>(); + + /// @brief Retrieves all contacts. + /// @details This function retrieves all place contacts. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The contacts will be delivered via maps_place_contacts_cb(). + /// @param[in] place The place handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_place_contacts_cb() repeatedly to retrieve each contact. + /// @see maps_place_contacts_cb() + int maps_place_foreach_contact( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_place_foreach_contact( + place, + callback, + user_data, + ); + } + + late final _maps_place_foreach_contact_ptr = + _lookup>( + 'maps_place_foreach_contact'); + late final _dart_maps_place_foreach_contact _maps_place_foreach_contact = + _maps_place_foreach_contact_ptr + .asFunction<_dart_maps_place_foreach_contact>(); + + /// @brief Retrieves all editorials. + /// @details This function retrieves all place editorials. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The editorials will be delivered via maps_place_editorials_cb(). + /// @param[in] place The place handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_place_editorials_cb() repeatedly to retrieve each editorial. + /// @see maps_place_editorials_cb() + int maps_place_foreach_editorial( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_place_foreach_editorial( + place, + callback, + user_data, + ); + } + + late final _maps_place_foreach_editorial_ptr = + _lookup>( + 'maps_place_foreach_editorial'); + late final _dart_maps_place_foreach_editorial _maps_place_foreach_editorial = + _maps_place_foreach_editorial_ptr + .asFunction<_dart_maps_place_foreach_editorial>(); + + /// @brief Retrieves all images. + /// @details This function retrieves all place images. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The images will be delivered via maps_place_images_cb(). + /// @param[in] place The place handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_place_images_cb() repeatedly to retrieve each image. + /// @see maps_place_images_cb() + int maps_place_foreach_image( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_place_foreach_image( + place, + callback, + user_data, + ); + } + + late final _maps_place_foreach_image_ptr = + _lookup>( + 'maps_place_foreach_image'); + late final _dart_maps_place_foreach_image _maps_place_foreach_image = + _maps_place_foreach_image_ptr + .asFunction<_dart_maps_place_foreach_image>(); + + /// @brief Retrieves all reviews. + /// @details This function retrieves all place reviews. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The reviews will be delivered via maps_place_reviews_cb(). + /// @param[in] place The place handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_place_reviews_cb() repeatedly to retrieve each review. + /// @see maps_place_reviews_cb() + int maps_place_foreach_review( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_place_foreach_review( + place, + callback, + user_data, + ); + } + + late final _maps_place_foreach_review_ptr = + _lookup>( + 'maps_place_foreach_review'); + late final _dart_maps_place_foreach_review _maps_place_foreach_review = + _maps_place_foreach_review_ptr + .asFunction<_dart_maps_place_foreach_review>(); + + /// @brief Gets the place supplier link. + /// @details This function gets the place supplier link. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a supplier must be released using maps_place_link_object_destroy(). + /// @param[in] place The place handle + /// @param[out] supplier The place supplier link + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_get_supplier_link( + ffi.Pointer place, + ffi.Pointer> supplier, + ) { + return _maps_place_get_supplier_link( + place, + supplier, + ); + } + + late final _maps_place_get_supplier_link_ptr = + _lookup>( + 'maps_place_get_supplier_link'); + late final _dart_maps_place_get_supplier_link _maps_place_get_supplier_link = + _maps_place_get_supplier_link_ptr + .asFunction<_dart_maps_place_get_supplier_link>(); + + /// @brief Gets the place related link. + /// @details This function gets the place related link. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a related must be released using maps_place_link_object_destroy(). + /// @param[in] place The place handle + /// @param[out] related The place related link + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_place_get_related_link( + ffi.Pointer place, + ffi.Pointer> related, + ) { + return _maps_place_get_related_link( + place, + related, + ); + } + + late final _maps_place_get_related_link_ptr = + _lookup>( + 'maps_place_get_related_link'); + late final _dart_maps_place_get_related_link _maps_place_get_related_link = + _maps_place_get_related_link_ptr + .asFunction<_dart_maps_place_get_related_link>(); + + /// @brief Retrieves all places. + /// @details This function retrieves all places. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The places will be delivered via maps_place_cb().\n + /// @a place_list must be released using maps_place_list_destroy(). + /// @param[in] place_list The place list handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_place_cb() repeatedly to retrieve each place. + /// @see maps_place_cb() + /// @see maps_place_list_destroy() + int maps_place_list_foreach( + ffi.Pointer place_list, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_place_list_foreach( + place_list, + callback, + user_data, + ); + } + + late final _maps_place_list_foreach_ptr = + _lookup>( + 'maps_place_list_foreach'); + late final _dart_maps_place_list_foreach _maps_place_list_foreach = + _maps_place_list_foreach_ptr.asFunction<_dart_maps_place_list_foreach>(); + + /// @brief Frees all of the memory used by a place list. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] place_list The place list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_list_foreach() + int maps_place_list_destroy( + ffi.Pointer place_list, + ) { + return _maps_place_list_destroy( + place_list, + ); + } + + late final _maps_place_list_destroy_ptr = + _lookup>( + 'maps_place_list_destroy'); + late final _dart_maps_place_list_destroy _maps_place_list_destroy = + _maps_place_list_destroy_ptr.asFunction<_dart_maps_place_list_destroy>(); + + /// @brief Creates a new Place Filter handle. + /// @details This function creates a new place filter handle and allocates all needed resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a filter must be released using maps_place_filter_destroy().\n + /// @a filter may be cloned using maps_place_filter_clone(). + /// @param[out] filter A handle of a new place filter on success + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_place_filter_destroy() + /// @see maps_place_filter_clone() + int maps_place_filter_create( + ffi.Pointer> filter, + ) { + return _maps_place_filter_create( + filter, + ); + } + + late final _maps_place_filter_create_ptr = + _lookup>( + 'maps_place_filter_create'); + late final _dart_maps_place_filter_create _maps_place_filter_create = + _maps_place_filter_create_ptr + .asFunction<_dart_maps_place_filter_create>(); + + /// @brief Destroys the place filter handle and releases all its resources. + /// @details This function destroys the place filter handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] filter The place filter handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a filter is created using maps_place_filter_create(). + /// @see maps_place_filter_create() + /// @see maps_place_filter_clone() + int maps_place_filter_destroy( + ffi.Pointer filter, + ) { + return _maps_place_filter_destroy( + filter, + ); + } + + late final _maps_place_filter_destroy_ptr = + _lookup>( + 'maps_place_filter_destroy'); + late final _dart_maps_place_filter_destroy _maps_place_filter_destroy = + _maps_place_filter_destroy_ptr + .asFunction<_dart_maps_place_filter_destroy>(); + + /// @brief Clones the place filter handle. + /// @details This function clones the place filter handle @a origin and all its resources.\n + /// Place filter handle @a origin may be created using maps_place_filter_create(). + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_place_filter_destroy(). + /// @param[in] origin The place filter handle to be cloned + /// @param[out] cloned A handle of a newly cloned place filter on success + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a origin is created using maps_place_filter_create(). + /// @see maps_place_filter_create() + /// @see maps_place_filter_destroy() + int maps_place_filter_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_place_filter_clone( + origin, + cloned, + ); + } + + late final _maps_place_filter_clone_ptr = + _lookup>( + 'maps_place_filter_clone'); + late final _dart_maps_place_filter_clone _maps_place_filter_clone = + _maps_place_filter_clone_ptr.asFunction<_dart_maps_place_filter_clone>(); + + /// @brief Gets the value of the specified key in the place filter. + /// @details This function gets the value of the specified key in the place filter. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a value must be released using free(). + /// @param[in] filter The handle of the place filter + /// @param[in] key The key of filter + /// @param[out] value The filter value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a filter is created using maps_place_filter_create(). + /// @see maps_place_filter_set() + /// @see maps_place_filter_create() + int maps_place_filter_get( + ffi.Pointer filter, + ffi.Pointer key, + ffi.Pointer> value, + ) { + return _maps_place_filter_get( + filter, + key, + value, + ); + } + + late final _maps_place_filter_get_ptr = + _lookup>( + 'maps_place_filter_get'); + late final _dart_maps_place_filter_get _maps_place_filter_get = + _maps_place_filter_get_ptr.asFunction<_dart_maps_place_filter_get>(); + + /// @brief Gets the value of keyword. + /// @details This function gets the value of keyword. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a keyword must be released using free(). + /// @param[in] filter The handle of the place filter + /// @param[out] keyword The key of filter + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a filter is created using maps_place_filter_create(). + /// @see maps_place_filter_set_keyword() + /// @see maps_place_filter_create() + int maps_place_filter_get_keyword( + ffi.Pointer filter, + ffi.Pointer> keyword, + ) { + return _maps_place_filter_get_keyword( + filter, + keyword, + ); + } + + late final _maps_place_filter_get_keyword_ptr = + _lookup>( + 'maps_place_filter_get_keyword'); + late final _dart_maps_place_filter_get_keyword + _maps_place_filter_get_keyword = _maps_place_filter_get_keyword_ptr + .asFunction<_dart_maps_place_filter_get_keyword>(); + + /// @brief Gets the place name. + /// @details This function gets the place name. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a place_name must be released using free(). + /// @param[in] filter The handle of the place filter + /// @param[out] place_name The place name + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a filter is created using maps_place_filter_create(). + /// @see maps_place_filter_set_place_name() + /// @see maps_place_filter_create() + int maps_place_filter_get_place_name( + ffi.Pointer filter, + ffi.Pointer> place_name, + ) { + return _maps_place_filter_get_place_name( + filter, + place_name, + ); + } + + late final _maps_place_filter_get_place_name_ptr = + _lookup>( + 'maps_place_filter_get_place_name'); + late final _dart_maps_place_filter_get_place_name + _maps_place_filter_get_place_name = _maps_place_filter_get_place_name_ptr + .asFunction<_dart_maps_place_filter_get_place_name>(); + + /// @brief Gets the category. + /// @details This function gets the category.\n + /// For allowed values of keys, see the macros above. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a category must be released using maps_place_category_destroy(). + /// @param[in] filter The handle of the place filter + /// @param[out] category The category + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a filter is created using maps_place_filter_create(). + /// @see maps_place_filter_set_category() + /// @see maps_place_filter_create() + int maps_place_filter_get_category( + ffi.Pointer filter, + ffi.Pointer> category, + ) { + return _maps_place_filter_get_category( + filter, + category, + ); + } + + late final _maps_place_filter_get_category_ptr = + _lookup>( + 'maps_place_filter_get_category'); + late final _dart_maps_place_filter_get_category + _maps_place_filter_get_category = _maps_place_filter_get_category_ptr + .asFunction<_dart_maps_place_filter_get_category>(); + + /// @brief Retrieves all filter properties. + /// @details This function retrieves all place filter properties. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] filter The handle of the place filter + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a filter is created using maps_place_filter_create(). + /// @post This function invokes maps_place_filter_properties_cb() repeatedly to retrieve each available filter keys. + /// @see maps_place_filter_properties_cb() + /// @see maps_place_filter_get() + /// @see maps_place_filter_set() + /// @see maps_place_filter_create() + int maps_place_filter_foreach_property( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_place_filter_foreach_property( + filter, + callback, + user_data, + ); + } + + late final _maps_place_filter_foreach_property_ptr = + _lookup>( + 'maps_place_filter_foreach_property'); + late final _dart_maps_place_filter_foreach_property + _maps_place_filter_foreach_property = + _maps_place_filter_foreach_property_ptr + .asFunction<_dart_maps_place_filter_foreach_property>(); + + /// @brief Gets the place address. + /// @details This function gets the place address. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a place_address must be released using free(). + /// @param[in] filter The handle of the place filter + /// @param[out] place_address The place address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a filter is created using maps_place_filter_create(). + /// @see maps_place_filter_set_place_address() + /// @see maps_place_filter_create() + int maps_place_filter_get_place_address( + ffi.Pointer filter, + ffi.Pointer> place_address, + ) { + return _maps_place_filter_get_place_address( + filter, + place_address, + ); + } + + late final _maps_place_filter_get_place_address_ptr = + _lookup>( + 'maps_place_filter_get_place_address'); + late final _dart_maps_place_filter_get_place_address + _maps_place_filter_get_place_address = + _maps_place_filter_get_place_address_ptr + .asFunction<_dart_maps_place_filter_get_place_address>(); + + /// @brief Sets the filter value. + /// @details This function sets the filter value in an assignment with a specified string key. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] filter The handle of the place filter + /// @param[in] key The key of filter + /// @param[in] value The filter value to set, could be NULL if want remove value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a filter is created using maps_place_filter_create(). + /// @see maps_place_filter_get() + /// @see maps_place_filter_create() + int maps_place_filter_set( + ffi.Pointer filter, + ffi.Pointer key, + ffi.Pointer value, + ) { + return _maps_place_filter_set( + filter, + key, + value, + ); + } + + late final _maps_place_filter_set_ptr = + _lookup>( + 'maps_place_filter_set'); + late final _dart_maps_place_filter_set _maps_place_filter_set = + _maps_place_filter_set_ptr.asFunction<_dart_maps_place_filter_set>(); + + /// @brief Sets the keyword. + /// @details This function sets the keyword. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] filter The handle of the place filter + /// @param[in] keyword The keyword + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a filter is created using maps_place_filter_create(). + /// @see maps_place_filter_get_keyword() + /// @see maps_place_filter_create() + int maps_place_filter_set_keyword( + ffi.Pointer filter, + ffi.Pointer keyword, + ) { + return _maps_place_filter_set_keyword( + filter, + keyword, + ); + } + + late final _maps_place_filter_set_keyword_ptr = + _lookup>( + 'maps_place_filter_set_keyword'); + late final _dart_maps_place_filter_set_keyword + _maps_place_filter_set_keyword = _maps_place_filter_set_keyword_ptr + .asFunction<_dart_maps_place_filter_set_keyword>(); + + /// @brief Sets the place name. + /// @details This function sets the place name. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] filter The handle of the place filter + /// @param[in] place_name The place name + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a filter is created using maps_place_filter_create(). + /// @see maps_place_filter_get_place_name() + /// @see maps_place_filter_create() + int maps_place_filter_set_place_name( + ffi.Pointer filter, + ffi.Pointer place_name, + ) { + return _maps_place_filter_set_place_name( + filter, + place_name, + ); + } + + late final _maps_place_filter_set_place_name_ptr = + _lookup>( + 'maps_place_filter_set_place_name'); + late final _dart_maps_place_filter_set_place_name + _maps_place_filter_set_place_name = _maps_place_filter_set_place_name_ptr + .asFunction<_dart_maps_place_filter_set_place_name>(); + + /// @brief Sets the category. + /// @details This function sets the place name. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] filter The handle of the place filter + /// @param[in] category The category + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a filter is created using maps_place_filter_create(). + /// @see maps_place_filter_get_category() + /// @see maps_place_filter_create() + int maps_place_filter_set_category( + ffi.Pointer filter, + ffi.Pointer category, + ) { + return _maps_place_filter_set_category( + filter, + category, + ); + } + + late final _maps_place_filter_set_category_ptr = + _lookup>( + 'maps_place_filter_set_category'); + late final _dart_maps_place_filter_set_category + _maps_place_filter_set_category = _maps_place_filter_set_category_ptr + .asFunction<_dart_maps_place_filter_set_category>(); + + /// @brief Sets the place address. + /// @details This function sets the place address. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] filter The handle of the place filter + /// @param[in] place_address The place address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a filter is created using maps_place_filter_create(). + /// @see maps_place_filter_get_place_address() + /// @see maps_place_filter_create() + int maps_place_filter_set_place_address( + ffi.Pointer filter, + ffi.Pointer place_address, + ) { + return _maps_place_filter_set_place_address( + filter, + place_address, + ); + } + + late final _maps_place_filter_set_place_address_ptr = + _lookup>( + 'maps_place_filter_set_place_address'); + late final _dart_maps_place_filter_set_place_address + _maps_place_filter_set_place_address = + _maps_place_filter_set_place_address_ptr + .asFunction<_dart_maps_place_filter_set_place_address>(); + + /// @brief Destroys the route Maneuver handle and releases all its resources. + /// @details This function destroys the route Maneuver handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] maneuver The Maneuver handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_route_maneuver_clone() + int maps_route_maneuver_destroy( + ffi.Pointer maneuver, + ) { + return _maps_route_maneuver_destroy( + maneuver, + ); + } + + late final _maps_route_maneuver_destroy_ptr = + _lookup>( + 'maps_route_maneuver_destroy'); + late final _dart_maps_route_maneuver_destroy _maps_route_maneuver_destroy = + _maps_route_maneuver_destroy_ptr + .asFunction<_dart_maps_route_maneuver_destroy>(); + + /// @brief Clones the route Maneuver handle. + /// @details This function clones the route Maneuver handle @a origin and all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_route_maneuver_destroy(). + /// @param[in] origin The original Maneuver handle + /// @param[out] cloned A cloned Maneuver handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_route_maneuver_destroy() + int maps_route_maneuver_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_route_maneuver_clone( + origin, + cloned, + ); + } + + late final _maps_route_maneuver_clone_ptr = + _lookup>( + 'maps_route_maneuver_clone'); + late final _dart_maps_route_maneuver_clone _maps_route_maneuver_clone = + _maps_route_maneuver_clone_ptr + .asFunction<_dart_maps_route_maneuver_clone>(); + + /// @brief Gets the route Maneuver direction ID. + /// @details This function gets the route Maneuver direction ID. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] maneuver The Maneuver handle + /// @param[out] direction_id The direction ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_route_direction_e + int maps_route_maneuver_get_direction_id( + ffi.Pointer maneuver, + ffi.Pointer direction_id, + ) { + return _maps_route_maneuver_get_direction_id( + maneuver, + direction_id, + ); + } + + late final _maps_route_maneuver_get_direction_id_ptr = + _lookup>( + 'maps_route_maneuver_get_direction_id'); + late final _dart_maps_route_maneuver_get_direction_id + _maps_route_maneuver_get_direction_id = + _maps_route_maneuver_get_direction_id_ptr + .asFunction<_dart_maps_route_maneuver_get_direction_id>(); + + /// @brief Gets the route Maneuver turn type. + /// @details This function gets the route Maneuver turn type. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] maneuver The Maneuver handle + /// @param[out] turn_type The turn type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_route_turn_type_e + int maps_route_maneuver_get_turn_type( + ffi.Pointer maneuver, + ffi.Pointer turn_type, + ) { + return _maps_route_maneuver_get_turn_type( + maneuver, + turn_type, + ); + } + + late final _maps_route_maneuver_get_turn_type_ptr = + _lookup>( + 'maps_route_maneuver_get_turn_type'); + late final _dart_maps_route_maneuver_get_turn_type + _maps_route_maneuver_get_turn_type = + _maps_route_maneuver_get_turn_type_ptr + .asFunction<_dart_maps_route_maneuver_get_turn_type>(); + + /// @brief Gets the route Maneuver position. + /// @details This function gets the route Maneuver position. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a position must be released using maps_coordinates_destroy(). + /// @param[in] maneuver The Maneuver handle + /// @param[out] position The start position of the Maneuver + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_coordinates_h + int maps_route_maneuver_get_position( + ffi.Pointer maneuver, + ffi.Pointer> position, + ) { + return _maps_route_maneuver_get_position( + maneuver, + position, + ); + } + + late final _maps_route_maneuver_get_position_ptr = + _lookup>( + 'maps_route_maneuver_get_position'); + late final _dart_maps_route_maneuver_get_position + _maps_route_maneuver_get_position = _maps_route_maneuver_get_position_ptr + .asFunction<_dart_maps_route_maneuver_get_position>(); + + /// @brief Gets the road name of the route Maneuver. + /// @details This function gets the road name of the route Maneuver. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a road_name must be released using free(). + /// @param[in] maneuver The Maneuver handle + /// @param[out] road_name The current road name of the Maneuver handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_route_maneuver_get_road_name( + ffi.Pointer maneuver, + ffi.Pointer> road_name, + ) { + return _maps_route_maneuver_get_road_name( + maneuver, + road_name, + ); + } + + late final _maps_route_maneuver_get_road_name_ptr = + _lookup>( + 'maps_route_maneuver_get_road_name'); + late final _dart_maps_route_maneuver_get_road_name + _maps_route_maneuver_get_road_name = + _maps_route_maneuver_get_road_name_ptr + .asFunction<_dart_maps_route_maneuver_get_road_name>(); + + /// @brief Gets the instruction text (narrative) of the route Maneuver. + /// @details This function gets the instruction text (narrative) of the route Maneuver. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a instruction_text must be released using free(). + /// @param[in] maneuver The Maneuver handle + /// @param[in] instruction_text The instruction text + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_route_maneuver_get_instruction_text( + ffi.Pointer maneuver, + ffi.Pointer> instruction_text, + ) { + return _maps_route_maneuver_get_instruction_text( + maneuver, + instruction_text, + ); + } + + late final _maps_route_maneuver_get_instruction_text_ptr = + _lookup>( + 'maps_route_maneuver_get_instruction_text'); + late final _dart_maps_route_maneuver_get_instruction_text + _maps_route_maneuver_get_instruction_text = + _maps_route_maneuver_get_instruction_text_ptr + .asFunction<_dart_maps_route_maneuver_get_instruction_text>(); + + /// @brief Gets the route Maneuver locale. + /// @details This function gets the route Maneuver locale. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a locale must be released using free(). + /// @param[in] maneuver The Maneuver handle + /// @param[out] locale The languages of instruction text and street name + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_route_maneuver_get_locale( + ffi.Pointer maneuver, + ffi.Pointer> locale, + ) { + return _maps_route_maneuver_get_locale( + maneuver, + locale, + ); + } + + late final _maps_route_maneuver_get_locale_ptr = + _lookup>( + 'maps_route_maneuver_get_locale'); + late final _dart_maps_route_maneuver_get_locale + _maps_route_maneuver_get_locale = _maps_route_maneuver_get_locale_ptr + .asFunction<_dart_maps_route_maneuver_get_locale>(); + + /// @brief Gets the time to next instruction of the route Maneuver. + /// @details This function gets the time to next instruction of the route Maneuver. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] maneuver The Maneuver handle + /// @param[out] time_to_next_instruction The time to next instruction on the given Maneuver handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_route_maneuver_get_time_to_next_instruction( + ffi.Pointer maneuver, + ffi.Pointer time_to_next_instruction, + ) { + return _maps_route_maneuver_get_time_to_next_instruction( + maneuver, + time_to_next_instruction, + ); + } + + late final _maps_route_maneuver_get_time_to_next_instruction_ptr = _lookup< + ffi.NativeFunction< + _c_maps_route_maneuver_get_time_to_next_instruction>>( + 'maps_route_maneuver_get_time_to_next_instruction'); + late final _dart_maps_route_maneuver_get_time_to_next_instruction + _maps_route_maneuver_get_time_to_next_instruction = + _maps_route_maneuver_get_time_to_next_instruction_ptr + .asFunction<_dart_maps_route_maneuver_get_time_to_next_instruction>(); + + /// @brief Gets the distance to next instruction of the route Maneuver. + /// @details This function gets the distance to next instruction of the route Maneuver. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] maneuver The Maneuver handle + /// @param[out] distance_to_next_instruction The distance from the current Maneuver to the next Maneuver + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_route_maneuver_get_distance_to_next_instruction( + ffi.Pointer maneuver, + ffi.Pointer distance_to_next_instruction, + ) { + return _maps_route_maneuver_get_distance_to_next_instruction( + maneuver, + distance_to_next_instruction, + ); + } + + late final _maps_route_maneuver_get_distance_to_next_instruction_ptr = + _lookup< + ffi.NativeFunction< + _c_maps_route_maneuver_get_distance_to_next_instruction>>( + 'maps_route_maneuver_get_distance_to_next_instruction'); + late final _dart_maps_route_maneuver_get_distance_to_next_instruction + _maps_route_maneuver_get_distance_to_next_instruction = + _maps_route_maneuver_get_distance_to_next_instruction_ptr.asFunction< + _dart_maps_route_maneuver_get_distance_to_next_instruction>(); + + /// @brief Destroys the route segment handle and releases all its resources. + /// @details This function destroys the route segment handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] segment The segment handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_route_segment_clone() + int maps_route_segment_destroy( + ffi.Pointer segment, + ) { + return _maps_route_segment_destroy( + segment, + ); + } + + late final _maps_route_segment_destroy_ptr = + _lookup>( + 'maps_route_segment_destroy'); + late final _dart_maps_route_segment_destroy _maps_route_segment_destroy = + _maps_route_segment_destroy_ptr + .asFunction<_dart_maps_route_segment_destroy>(); + + /// @brief Clones the route segment handle. + /// @details This function clones the route handle @a origin and all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_route_segment_destroy(). + /// @param[in] origin The original segment handle + /// @param[out] cloned A cloned segment handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_route_segment_destroy() + int maps_route_segment_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_route_segment_clone( + origin, + cloned, + ); + } + + late final _maps_route_segment_clone_ptr = + _lookup>( + 'maps_route_segment_clone'); + late final _dart_maps_route_segment_clone _maps_route_segment_clone = + _maps_route_segment_clone_ptr + .asFunction<_dart_maps_route_segment_clone>(); + + /// @brief Gets the route segment origin. + /// @details This function gets the route segment origin. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a origin must be released using maps_coordinates_destroy(). + /// @param[in] segment The segment handle + /// @param[out] origin The origin of segment + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_coordinates_h + int maps_route_segment_get_origin( + ffi.Pointer segment, + ffi.Pointer> origin, + ) { + return _maps_route_segment_get_origin( + segment, + origin, + ); + } + + late final _maps_route_segment_get_origin_ptr = + _lookup>( + 'maps_route_segment_get_origin'); + late final _dart_maps_route_segment_get_origin + _maps_route_segment_get_origin = _maps_route_segment_get_origin_ptr + .asFunction<_dart_maps_route_segment_get_origin>(); + + /// @brief Gets the route segment destination. + /// @details This function gets the route segment destination. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a destination must be released using maps_coordinates_destroy(). + /// @param[in] segment The segment handle + /// @param[out] destination The destination of segment + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_coordinates_h + int maps_route_segment_get_destination( + ffi.Pointer segment, + ffi.Pointer> destination, + ) { + return _maps_route_segment_get_destination( + segment, + destination, + ); + } + + late final _maps_route_segment_get_destination_ptr = + _lookup>( + 'maps_route_segment_get_destination'); + late final _dart_maps_route_segment_get_destination + _maps_route_segment_get_destination = + _maps_route_segment_get_destination_ptr + .asFunction<_dart_maps_route_segment_get_destination>(); + + /// @brief Gets the route segment bounding box. + /// @details This function gets the route segment bounding box. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a bounding_box must be released using maps_area_destroy(). + /// @param[in] segment The segment handle + /// @param[out] bounding_box The bounding box of segment + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_area_h + int maps_route_segment_get_bounding_box( + ffi.Pointer segment, + ffi.Pointer> bounding_box, + ) { + return _maps_route_segment_get_bounding_box( + segment, + bounding_box, + ); + } + + late final _maps_route_segment_get_bounding_box_ptr = + _lookup>( + 'maps_route_segment_get_bounding_box'); + late final _dart_maps_route_segment_get_bounding_box + _maps_route_segment_get_bounding_box = + _maps_route_segment_get_bounding_box_ptr + .asFunction<_dart_maps_route_segment_get_bounding_box>(); + + /// @brief Gets the route segment distance. + /// @details This function gets the route segment distance. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] segment The segment handle + /// @param[out] distance The distance of segment + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_route_segment_get_distance( + ffi.Pointer segment, + ffi.Pointer distance, + ) { + return _maps_route_segment_get_distance( + segment, + distance, + ); + } + + late final _maps_route_segment_get_distance_ptr = + _lookup>( + 'maps_route_segment_get_distance'); + late final _dart_maps_route_segment_get_distance + _maps_route_segment_get_distance = _maps_route_segment_get_distance_ptr + .asFunction<_dart_maps_route_segment_get_distance>(); + + /// @brief Gets the route segment duration. + /// @details This function gets the route segment duration. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] segment The segment handle + /// @param[out] duration The distance of segment + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_route_segment_get_duration( + ffi.Pointer segment, + ffi.Pointer duration, + ) { + return _maps_route_segment_get_duration( + segment, + duration, + ); + } + + late final _maps_route_segment_get_duration_ptr = + _lookup>( + 'maps_route_segment_get_duration'); + late final _dart_maps_route_segment_get_duration + _maps_route_segment_get_duration = _maps_route_segment_get_duration_ptr + .asFunction<_dart_maps_route_segment_get_duration>(); + + /// @brief Retrieves all coordinates of the path. + /// @details This function retrieves all coordinates of the route segment path. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The coordinates will be delivered via maps_route_segment_path_cb(). + /// @param[in] segment The segment handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_route_segment_path_cb() repeatedly to retrieve each coordinate point. + /// @see maps_route_segment_path_cb() + int maps_route_segment_foreach_path( + ffi.Pointer segment, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_route_segment_foreach_path( + segment, + callback, + user_data, + ); + } + + late final _maps_route_segment_foreach_path_ptr = + _lookup>( + 'maps_route_segment_foreach_path'); + late final _dart_maps_route_segment_foreach_path + _maps_route_segment_foreach_path = _maps_route_segment_foreach_path_ptr + .asFunction<_dart_maps_route_segment_foreach_path>(); + + /// @brief Retrieves all Maneuvers of the path. + /// @details This function retrieves all Maneuvers of the route segment path. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The coordinates will be delivered via maps_route_segment_maneuver_cb(). + /// @param[in] segment The segment handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_route_segment_maneuver_cb() repeatedly to retrieve each coordinate point. + /// @see maps_route_segment_maneuver_cb() + int maps_route_segment_foreach_maneuver( + ffi.Pointer segment, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_route_segment_foreach_maneuver( + segment, + callback, + user_data, + ); + } + + late final _maps_route_segment_foreach_maneuver_ptr = + _lookup>( + 'maps_route_segment_foreach_maneuver'); + late final _dart_maps_route_segment_foreach_maneuver + _maps_route_segment_foreach_maneuver = + _maps_route_segment_foreach_maneuver_ptr + .asFunction<_dart_maps_route_segment_foreach_maneuver>(); + + /// @brief Creates a new maps preference handle. + /// @details This function creates a new maps preference handle and allocates all needed resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a preference must be released using maps_preference_destroy().\n + /// @a preference may be cloned using maps_preference_clone(). + /// @param[out] preference A newly created preference handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_preference_destroy() + /// @see maps_preference_clone() + int maps_preference_create( + ffi.Pointer> preference, + ) { + return _maps_preference_create( + preference, + ); + } + + late final _maps_preference_create_ptr = + _lookup>( + 'maps_preference_create'); + late final _dart_maps_preference_create _maps_preference_create = + _maps_preference_create_ptr.asFunction<_dart_maps_preference_create>(); + + /// @brief Destroys the maps preference handle and releases all its resources. + /// @details This function destroys the maps preference handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_preference_clone() + int maps_preference_destroy( + ffi.Pointer preference, + ) { + return _maps_preference_destroy( + preference, + ); + } + + late final _maps_preference_destroy_ptr = + _lookup>( + 'maps_preference_destroy'); + late final _dart_maps_preference_destroy _maps_preference_destroy = + _maps_preference_destroy_ptr.asFunction<_dart_maps_preference_destroy>(); + + /// @brief Clones the maps preference handle. + /// @details This function clones the maps preference handle @a origin and all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_preference_destroy(). + /// @param[in] origin The original preference handle + /// @param[out] cloned A cloned preference handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_preference_destroy() + int maps_preference_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_preference_clone( + origin, + cloned, + ); + } + + late final _maps_preference_clone_ptr = + _lookup>( + 'maps_preference_clone'); + late final _dart_maps_preference_clone _maps_preference_clone = + _maps_preference_clone_ptr.asFunction<_dart_maps_preference_clone>(); + + /// @brief Gets the distance unit. + /// @details This function gets the maps distance unit. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[out] unit The distance unit + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_preference_get_distance_unit( + ffi.Pointer preference, + ffi.Pointer unit, + ) { + return _maps_preference_get_distance_unit( + preference, + unit, + ); + } + + late final _maps_preference_get_distance_unit_ptr = + _lookup>( + 'maps_preference_get_distance_unit'); + late final _dart_maps_preference_get_distance_unit + _maps_preference_get_distance_unit = + _maps_preference_get_distance_unit_ptr + .asFunction<_dart_maps_preference_get_distance_unit>(); + + /// @brief Gets the language. + /// @details This function gets the maps language. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a language must be released using free(). + /// @param[in] preference The preference handle + /// @param[out] language The language + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_preference_get_language( + ffi.Pointer preference, + ffi.Pointer> language, + ) { + return _maps_preference_get_language( + preference, + language, + ); + } + + late final _maps_preference_get_language_ptr = + _lookup>( + 'maps_preference_get_language'); + late final _dart_maps_preference_get_language _maps_preference_get_language = + _maps_preference_get_language_ptr + .asFunction<_dart_maps_preference_get_language>(); + + /// @brief Gets the max amount of results. + /// @details This function gets the max amount of results. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[out] max_results The max amount of results + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_preference_get_max_results( + ffi.Pointer preference, + ffi.Pointer max_results, + ) { + return _maps_preference_get_max_results( + preference, + max_results, + ); + } + + late final _maps_preference_get_max_results_ptr = + _lookup>( + 'maps_preference_get_max_results'); + late final _dart_maps_preference_get_max_results + _maps_preference_get_max_results = _maps_preference_get_max_results_ptr + .asFunction<_dart_maps_preference_get_max_results>(); + + /// @brief Gets the country code. + /// @details This function gets the country code. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a country_code must be released using free(). + /// @param[in] preference The preference handle + /// @param[out] country_code The country code + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_preference_get_country_code( + ffi.Pointer preference, + ffi.Pointer> country_code, + ) { + return _maps_preference_get_country_code( + preference, + country_code, + ); + } + + late final _maps_preference_get_country_code_ptr = + _lookup>( + 'maps_preference_get_country_code'); + late final _dart_maps_preference_get_country_code + _maps_preference_get_country_code = _maps_preference_get_country_code_ptr + .asFunction<_dart_maps_preference_get_country_code>(); + + /// @brief Gets the route optimization. + /// @details This function gets the route optimization. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[out] optimization The route optimization + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_preference_get_route_optimization( + ffi.Pointer preference, + ffi.Pointer optimization, + ) { + return _maps_preference_get_route_optimization( + preference, + optimization, + ); + } + + late final _maps_preference_get_route_optimization_ptr = + _lookup>( + 'maps_preference_get_route_optimization'); + late final _dart_maps_preference_get_route_optimization + _maps_preference_get_route_optimization = + _maps_preference_get_route_optimization_ptr + .asFunction<_dart_maps_preference_get_route_optimization>(); + + /// @brief Gets the route transport mode. + /// @details This function gets the route transport mode. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[out] transport_mode The transport mode + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_preference_get_route_transport_mode( + ffi.Pointer preference, + ffi.Pointer transport_mode, + ) { + return _maps_preference_get_route_transport_mode( + preference, + transport_mode, + ); + } + + late final _maps_preference_get_route_transport_mode_ptr = + _lookup>( + 'maps_preference_get_route_transport_mode'); + late final _dart_maps_preference_get_route_transport_mode + _maps_preference_get_route_transport_mode = + _maps_preference_get_route_transport_mode_ptr + .asFunction<_dart_maps_preference_get_route_transport_mode>(); + + /// @brief Gets the route feature weight. + /// @details This function gets the route feature weight. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[out] feature_weight The feature weight + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_preference_get_route_feature_weight( + ffi.Pointer preference, + ffi.Pointer feature_weight, + ) { + return _maps_preference_get_route_feature_weight( + preference, + feature_weight, + ); + } + + late final _maps_preference_get_route_feature_weight_ptr = + _lookup>( + 'maps_preference_get_route_feature_weight'); + late final _dart_maps_preference_get_route_feature_weight + _maps_preference_get_route_feature_weight = + _maps_preference_get_route_feature_weight_ptr + .asFunction<_dart_maps_preference_get_route_feature_weight>(); + + /// @brief Gets the route feature. + /// @details This function gets the route feature. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[out] feature The feature + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_preference_get_route_feature( + ffi.Pointer preference, + ffi.Pointer feature, + ) { + return _maps_preference_get_route_feature( + preference, + feature, + ); + } + + late final _maps_preference_get_route_feature_ptr = + _lookup>( + 'maps_preference_get_route_feature'); + late final _dart_maps_preference_get_route_feature + _maps_preference_get_route_feature = + _maps_preference_get_route_feature_ptr + .asFunction<_dart_maps_preference_get_route_feature>(); + + /// @brief Gets the enable status of alternative routes. + /// @details This function retrieves the enable status of alternative route. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[out] enable The enable status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_preference_get_route_alternatives_enabled( + ffi.Pointer preference, + ffi.Pointer enable, + ) { + return _maps_preference_get_route_alternatives_enabled( + preference, + enable, + ); + } + + late final _maps_preference_get_route_alternatives_enabled_ptr = _lookup< + ffi.NativeFunction< + _c_maps_preference_get_route_alternatives_enabled>>( + 'maps_preference_get_route_alternatives_enabled'); + late final _dart_maps_preference_get_route_alternatives_enabled + _maps_preference_get_route_alternatives_enabled = + _maps_preference_get_route_alternatives_enabled_ptr + .asFunction<_dart_maps_preference_get_route_alternatives_enabled>(); + + /// @brief Gets the maps preference value by key. + /// @details This function gets the maps preference value by key. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a value must be released using free(). + /// @param[in] preference The preference handle + /// @param[in] key The preference key + /// @param[out] value The preference value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_preference_get( + ffi.Pointer preference, + ffi.Pointer key, + ffi.Pointer> value, + ) { + return _maps_preference_get( + preference, + key, + value, + ); + } + + late final _maps_preference_get_ptr = + _lookup>( + 'maps_preference_get'); + late final _dart_maps_preference_get _maps_preference_get = + _maps_preference_get_ptr.asFunction<_dart_maps_preference_get>(); + + /// @brief Retrieves all maps properties. + /// @details This function retrieves all maps properties. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The properties will be delivered via maps_preference_properties_cb(). + /// @param[in] preference The preference handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_preference_properties_cb() repeatedly to retrieve each property. + /// @see maps_preference_properties_cb() + int maps_preference_foreach_property( + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_preference_foreach_property( + preference, + callback, + user_data, + ); + } + + late final _maps_preference_foreach_property_ptr = + _lookup>( + 'maps_preference_foreach_property'); + late final _dart_maps_preference_foreach_property + _maps_preference_foreach_property = _maps_preference_foreach_property_ptr + .asFunction<_dart_maps_preference_foreach_property>(); + + /// @brief Sets the maps distance unit. + /// @details This function sets the maps distance unit. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[in] unit The distance unit + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a preference is created using maps_preference_create(). + /// @see maps_preference_create() + /// @see maps_preference_get_distance_unit() + int maps_preference_set_distance_unit( + ffi.Pointer preference, + int unit, + ) { + return _maps_preference_set_distance_unit( + preference, + unit, + ); + } + + late final _maps_preference_set_distance_unit_ptr = + _lookup>( + 'maps_preference_set_distance_unit'); + late final _dart_maps_preference_set_distance_unit + _maps_preference_set_distance_unit = + _maps_preference_set_distance_unit_ptr + .asFunction<_dart_maps_preference_set_distance_unit>(); + + /// @brief Sets the maps language. + /// @details This function sets the maps language. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[in] language The maps language. + /// A language is specified as an ISO 3166 alpha-2 two letter country-code + /// followed by ISO 639-1 for the two-letter language code. + /// Each language tag is composed of one or more "subtags" separated by hyphens (-). + /// Each subtag is composed of basic Latin letters or digits only. + /// For example, "ko-KR" for Korean, "en-US" for American English. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a preference is created using maps_preference_create(). + /// @see maps_preference_create() + /// @see maps_preference_get_language() + int maps_preference_set_language( + ffi.Pointer preference, + ffi.Pointer language, + ) { + return _maps_preference_set_language( + preference, + language, + ); + } + + late final _maps_preference_set_language_ptr = + _lookup>( + 'maps_preference_set_language'); + late final _dart_maps_preference_set_language _maps_preference_set_language = + _maps_preference_set_language_ptr + .asFunction<_dart_maps_preference_set_language>(); + + /// @brief Sets the max amount of results. + /// @details This function sets the max amount of results. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[in] max_results The max amount of results + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a preference is created using maps_preference_create(). + /// @see maps_preference_create() + /// @see maps_preference_get_max_results() + int maps_preference_set_max_results( + ffi.Pointer preference, + int max_results, + ) { + return _maps_preference_set_max_results( + preference, + max_results, + ); + } + + late final _maps_preference_set_max_results_ptr = + _lookup>( + 'maps_preference_set_max_results'); + late final _dart_maps_preference_set_max_results + _maps_preference_set_max_results = _maps_preference_set_max_results_ptr + .asFunction<_dart_maps_preference_set_max_results>(); + + /// @brief Sets the maps country code. + /// @details This function sets the maps country code. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[in] country_code The maps country code + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a preference is created using maps_preference_create(). + /// @see maps_preference_create() + /// @see maps_preference_get_country_code() + int maps_preference_set_country_code( + ffi.Pointer preference, + ffi.Pointer country_code, + ) { + return _maps_preference_set_country_code( + preference, + country_code, + ); + } + + late final _maps_preference_set_country_code_ptr = + _lookup>( + 'maps_preference_set_country_code'); + late final _dart_maps_preference_set_country_code + _maps_preference_set_country_code = _maps_preference_set_country_code_ptr + .asFunction<_dart_maps_preference_set_country_code>(); + + /// @brief Sets the route optimization. + /// @details This function sets the route optimization. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[in] optimization The route optimization + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a preference is created using maps_preference_create(). + /// @see maps_preference_create() + /// @see maps_preference_get_route_optimization() + int maps_preference_set_route_optimization( + ffi.Pointer preference, + int optimization, + ) { + return _maps_preference_set_route_optimization( + preference, + optimization, + ); + } + + late final _maps_preference_set_route_optimization_ptr = + _lookup>( + 'maps_preference_set_route_optimization'); + late final _dart_maps_preference_set_route_optimization + _maps_preference_set_route_optimization = + _maps_preference_set_route_optimization_ptr + .asFunction<_dart_maps_preference_set_route_optimization>(); + + /// @brief Sets the route transport mode. + /// @details This function sets the route transport mode. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[in] transport_mode The route transport mode + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a preference is created using maps_preference_create(). + /// @see maps_preference_create() + /// @see maps_preference_get_route_optimization() + int maps_preference_set_route_transport_mode( + ffi.Pointer preference, + int transport_mode, + ) { + return _maps_preference_set_route_transport_mode( + preference, + transport_mode, + ); + } + + late final _maps_preference_set_route_transport_mode_ptr = + _lookup>( + 'maps_preference_set_route_transport_mode'); + late final _dart_maps_preference_set_route_transport_mode + _maps_preference_set_route_transport_mode = + _maps_preference_set_route_transport_mode_ptr + .asFunction<_dart_maps_preference_set_route_transport_mode>(); + + /// @brief Sets the route feature weight. + /// @details This function sets the route feature weight. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[in] feature_weight The route feature weight + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a preference is created using maps_preference_create(). + /// @see maps_preference_create() + /// @see maps_preference_get_route_feature_weight() + int maps_preference_set_route_feature_weight( + ffi.Pointer preference, + int feature_weight, + ) { + return _maps_preference_set_route_feature_weight( + preference, + feature_weight, + ); + } + + late final _maps_preference_set_route_feature_weight_ptr = + _lookup>( + 'maps_preference_set_route_feature_weight'); + late final _dart_maps_preference_set_route_feature_weight + _maps_preference_set_route_feature_weight = + _maps_preference_set_route_feature_weight_ptr + .asFunction<_dart_maps_preference_set_route_feature_weight>(); + + /// @brief Sets the route feature. + /// @details This function sets the route feature. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[in] feature The route feature + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a preference is created using maps_preference_create(). + /// @see maps_preference_create() + /// @see maps_preference_get_route_feature() + int maps_preference_set_route_feature( + ffi.Pointer preference, + int feature, + ) { + return _maps_preference_set_route_feature( + preference, + feature, + ); + } + + late final _maps_preference_set_route_feature_ptr = + _lookup>( + 'maps_preference_set_route_feature'); + late final _dart_maps_preference_set_route_feature + _maps_preference_set_route_feature = + _maps_preference_set_route_feature_ptr + .asFunction<_dart_maps_preference_set_route_feature>(); + + /// @brief Sets the enable status of alternative routes. + /// @details This function sets the alternative routes status. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[in] enable The value to set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a preference is created using maps_preference_create(). + /// @see maps_preference_create() + /// @see maps_preference_get_route_alternatives_enabled() + int maps_preference_set_route_alternatives_enabled( + ffi.Pointer preference, + bool enable, + ) { + return _maps_preference_set_route_alternatives_enabled( + preference, + enable ? 1 : 0, + ); + } + + late final _maps_preference_set_route_alternatives_enabled_ptr = _lookup< + ffi.NativeFunction< + _c_maps_preference_set_route_alternatives_enabled>>( + 'maps_preference_set_route_alternatives_enabled'); + late final _dart_maps_preference_set_route_alternatives_enabled + _maps_preference_set_route_alternatives_enabled = + _maps_preference_set_route_alternatives_enabled_ptr + .asFunction<_dart_maps_preference_set_route_alternatives_enabled>(); + + /// @brief Sets the preference value by key. + /// @details This function sets the preference value assigned with a specified key. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] preference The preference handle + /// @param[in] key The key + /// @param[in] value The value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a preference is created using maps_preference_create(). + /// @see maps_preference_create() + /// @see maps_preference_get_property() + /// @see maps_preference_foreach_property() + int maps_preference_set_property( + ffi.Pointer preference, + ffi.Pointer key, + ffi.Pointer value, + ) { + return _maps_preference_set_property( + preference, + key, + value, + ); + } + + late final _maps_preference_set_property_ptr = + _lookup>( + 'maps_preference_set_property'); + late final _dart_maps_preference_set_property _maps_preference_set_property = + _maps_preference_set_property_ptr + .asFunction<_dart_maps_preference_set_property>(); + + /// @brief Destroys the route handle and releases all its resources. + /// @details This function destroys the route handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] route The route handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_route_clone() + int maps_route_destroy( + ffi.Pointer route, + ) { + return _maps_route_destroy( + route, + ); + } + + late final _maps_route_destroy_ptr = + _lookup>('maps_route_destroy'); + late final _dart_maps_route_destroy _maps_route_destroy = + _maps_route_destroy_ptr.asFunction<_dart_maps_route_destroy>(); + + /// @brief Clones the route handle. + /// @details This function clones the route handle @a origin and all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_route_destroy(). + /// @param[in] origin The original route handle + /// @param[out] cloned A cloned route handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_route_destroy() + int maps_route_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_route_clone( + origin, + cloned, + ); + } + + late final _maps_route_clone_ptr = + _lookup>('maps_route_clone'); + late final _dart_maps_route_clone _maps_route_clone = + _maps_route_clone_ptr.asFunction<_dart_maps_route_clone>(); + + /// @brief Gets the route ID. + /// @details This function gets the route ID. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a id must be released using free(). + /// @param[in] route The route handle + /// @param[out] route_id The ID of route + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + int maps_route_get_route_id( + ffi.Pointer route, + ffi.Pointer> route_id, + ) { + return _maps_route_get_route_id( + route, + route_id, + ); + } + + late final _maps_route_get_route_id_ptr = + _lookup>( + 'maps_route_get_route_id'); + late final _dart_maps_route_get_route_id _maps_route_get_route_id = + _maps_route_get_route_id_ptr.asFunction<_dart_maps_route_get_route_id>(); + + /// @brief Gets the route origin. + /// @details This function gets the route origin. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a origin must be released using maps_coordinates_destroy(). + /// @param[in] route The route handle + /// @param[out] origin The origin of route + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_route_get_destination() + /// @see #maps_coordinates_h + int maps_route_get_origin( + ffi.Pointer route, + ffi.Pointer> origin, + ) { + return _maps_route_get_origin( + route, + origin, + ); + } + + late final _maps_route_get_origin_ptr = + _lookup>( + 'maps_route_get_origin'); + late final _dart_maps_route_get_origin _maps_route_get_origin = + _maps_route_get_origin_ptr.asFunction<_dart_maps_route_get_origin>(); + + /// @brief Gets the route destination. + /// @details This function gets the route destination. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a destination must be released using maps_coordinates_destroy(). + /// @param[in] route The route handle + /// @param[out] destination The destination of route + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_route_get_origin() + /// @see #maps_coordinates_h + int maps_route_get_destination( + ffi.Pointer route, + ffi.Pointer> destination, + ) { + return _maps_route_get_destination( + route, + destination, + ); + } + + late final _maps_route_get_destination_ptr = + _lookup>( + 'maps_route_get_destination'); + late final _dart_maps_route_get_destination _maps_route_get_destination = + _maps_route_get_destination_ptr + .asFunction<_dart_maps_route_get_destination>(); + + /// @brief Gets the route bounding box. + /// @details This function gets the route bounding box. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a bounding_box must be released using maps_area_destroy(). + /// @param[in] route The route handle + /// @param[out] bounding_box The bounding box of route + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_area_h + int maps_route_get_bounding_box( + ffi.Pointer route, + ffi.Pointer> bounding_box, + ) { + return _maps_route_get_bounding_box( + route, + bounding_box, + ); + } + + late final _maps_route_get_bounding_box_ptr = + _lookup>( + 'maps_route_get_bounding_box'); + late final _dart_maps_route_get_bounding_box _maps_route_get_bounding_box = + _maps_route_get_bounding_box_ptr + .asFunction<_dart_maps_route_get_bounding_box>(); + + /// @brief Gets the route transport mode. + /// @details This function gets the route transport mode. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] route The route handle + /// @param[out] transport_mode The transport mode + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_route_transport_mode_e + int maps_route_get_transport_mode( + ffi.Pointer route, + ffi.Pointer transport_mode, + ) { + return _maps_route_get_transport_mode( + route, + transport_mode, + ); + } + + late final _maps_route_get_transport_mode_ptr = + _lookup>( + 'maps_route_get_transport_mode'); + late final _dart_maps_route_get_transport_mode + _maps_route_get_transport_mode = _maps_route_get_transport_mode_ptr + .asFunction<_dart_maps_route_get_transport_mode>(); + + /// @brief Gets the route total distance. + /// @details This function gets the route total distance. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] route The route handle + /// @param[out] total_distance The distance of route. You can get the distance unit by route_get_distance_unit() + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_route_get_total_duration() + int maps_route_get_total_distance( + ffi.Pointer route, + ffi.Pointer total_distance, + ) { + return _maps_route_get_total_distance( + route, + total_distance, + ); + } + + late final _maps_route_get_total_distance_ptr = + _lookup>( + 'maps_route_get_total_distance'); + late final _dart_maps_route_get_total_distance + _maps_route_get_total_distance = _maps_route_get_total_distance_ptr + .asFunction<_dart_maps_route_get_total_distance>(); + + /// @brief Gets the route total duration. + /// @details This function gets the route total duration. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] route The route handle + /// @param[out] total_duration The duration + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see maps_route_get_total_distance() + int maps_route_get_total_duration( + ffi.Pointer route, + ffi.Pointer total_duration, + ) { + return _maps_route_get_total_duration( + route, + total_duration, + ); + } + + late final _maps_route_get_total_duration_ptr = + _lookup>( + 'maps_route_get_total_duration'); + late final _dart_maps_route_get_total_duration + _maps_route_get_total_duration = _maps_route_get_total_duration_ptr + .asFunction<_dart_maps_route_get_total_duration>(); + + /// @brief Gets the route distance units. + /// @details This function gets the route distance units. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] route The route handle + /// @param[out] distance_unit The distance units + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_distance_unit_e + int maps_route_get_distance_unit( + ffi.Pointer route, + ffi.Pointer distance_unit, + ) { + return _maps_route_get_distance_unit( + route, + distance_unit, + ); + } + + late final _maps_route_get_distance_unit_ptr = + _lookup>( + 'maps_route_get_distance_unit'); + late final _dart_maps_route_get_distance_unit _maps_route_get_distance_unit = + _maps_route_get_distance_unit_ptr + .asFunction<_dart_maps_route_get_distance_unit>(); + + /// @brief Retrieves all properties. + /// @details This function retrieves all route properties. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The properties will be delivered via maps_route_properties_cb(). + /// @param[in] route The route handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_route_properties_cb() repeatedly to retrieve each property. + /// @see maps_route_properties_cb() + int maps_route_foreach_property( + ffi.Pointer route, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_route_foreach_property( + route, + callback, + user_data, + ); + } + + late final _maps_route_foreach_property_ptr = + _lookup>( + 'maps_route_foreach_property'); + late final _dart_maps_route_foreach_property _maps_route_foreach_property = + _maps_route_foreach_property_ptr + .asFunction<_dart_maps_route_foreach_property>(); + + /// @brief Retrieves all coordinates of the path. + /// @details This function retrieves all coordinates of the route path. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The coordinates will be delivered via maps_route_path_cb(). + /// @param[in] route The route handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_route_path_cb() repeatedly to retrieve each coordinate point. + /// @see maps_route_path_cb() + int maps_route_foreach_path( + ffi.Pointer route, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_route_foreach_path( + route, + callback, + user_data, + ); + } + + late final _maps_route_foreach_path_ptr = + _lookup>( + 'maps_route_foreach_path'); + late final _dart_maps_route_foreach_path _maps_route_foreach_path = + _maps_route_foreach_path_ptr.asFunction<_dart_maps_route_foreach_path>(); + + /// @brief Retrieves all segments of the route. + /// @details This function retrieves all segments of the route. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The segments will be delivered via maps_route_path_cb(). + /// @param[in] route The route handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_route_segment_cb() repeatedly to retrieve each segment. + /// @see maps_route_segment_cb() + int maps_route_foreach_segment( + ffi.Pointer route, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_route_foreach_segment( + route, + callback, + user_data, + ); + } + + late final _maps_route_foreach_segment_ptr = + _lookup>( + 'maps_route_foreach_segment'); + late final _dart_maps_route_foreach_segment _maps_route_foreach_segment = + _maps_route_foreach_segment_ptr + .asFunction<_dart_maps_route_foreach_segment>(); + + /// @brief Creates a marker visual object. + /// @details This function creates a marker on a given geographical coordinates. + /// The marker is specified with a given image file and a type. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a marker can be released by using maps_view_object_destroy().\n + /// If added to the View using maps_view_add_object(), @a marker will be released automatically when the View is destroyed.\n + /// http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage.\n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. + /// @param[in] coordinates The geographical coordinates to add marker on + /// @param[in] image_file_path The file name with the image for the marker + /// @param[in] type The type of the marker, one of listed in maps_view_marker_type_e + /// @param[out] marker The handle of newly created marker + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a coordinates are created using map_coordinates_create(). + /// @see #maps_view_object_h + /// @see #maps_view_marker_type_e + /// @see maps_view_object_create_polygon() + /// @see maps_view_object_create_polyline() + /// @see maps_view_add_object() + /// @see maps_view_object_destroy() + /// @see #maps_coordinates_h + int maps_view_object_create_marker( + ffi.Pointer coordinates, + ffi.Pointer image_file_path, + int type, + ffi.Pointer> marker, + ) { + return _maps_view_object_create_marker( + coordinates, + image_file_path, + type, + marker, + ); + } + + late final _maps_view_object_create_marker_ptr = + _lookup>( + 'maps_view_object_create_marker'); + late final _dart_maps_view_object_create_marker + _maps_view_object_create_marker = _maps_view_object_create_marker_ptr + .asFunction<_dart_maps_view_object_create_marker>(); + + /// @brief Creates a polyline visual object. + /// @details This function creates a polyline visual object, specified with a list of geographical coordinates, line width and color. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a polyline can be released by using maps_view_object_destroy().\n + /// If added to the View using maps_view_add_object(), @a polyline will be released automatically when the View is destroyed. + /// @param[in] coordinates The list of geographical coordinates + /// @param[in] r The red component of polyline color [0 ~ 255] + /// @param[in] g The green component of polyline color [0 ~ 255] + /// @param[in] b The blue component of polyline color [0 ~ 255] + /// @param[in] a The alpha component of polyline color [0 ~ 255] + /// @param[in] width The width of line [1 ~ 100] (pixels) + /// @param[out] polyline The handle of newly added polyline + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a coordinates is created using maps_coordinates_list_create(). + /// @see #maps_view_object_h + /// @see maps_view_object_create_marker() + /// @see maps_view_object_create_polygon() + /// @see maps_view_add_object() + /// @see maps_view_object_destroy() + /// @see #maps_coordinates_list_h + /// @see maps_coordinates_list_create() + int maps_view_object_create_polyline( + ffi.Pointer coordinates, + int r, + int g, + int b, + int a, + int width, + ffi.Pointer> polyline, + ) { + return _maps_view_object_create_polyline( + coordinates, + r, + g, + b, + a, + width, + polyline, + ); + } + + late final _maps_view_object_create_polyline_ptr = + _lookup>( + 'maps_view_object_create_polyline'); + late final _dart_maps_view_object_create_polyline + _maps_view_object_create_polyline = _maps_view_object_create_polyline_ptr + .asFunction<_dart_maps_view_object_create_polyline>(); + + /// @brief Creates a polygon visual object. + /// @details This function creates a polygon visual object, specified with a list of geographical coordinates and fill color. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a polygon can be released by using maps_view_object_destroy().\n + /// If added to the View using maps_view_add_object(), @a polygon will be released automatically when the View is destroyed. + /// @param[in] coordinates The list of geographical coordinates + /// @param[in] r The red component of polygon background color [0 ~ 255] + /// @param[in] g The green component of polygon background color [0 ~ 255] + /// @param[in] b The blue component of polygon background color [0 ~ 255] + /// @param[in] a The alpha component of polygon background color [0 ~ 255] + /// @param[out] polygon The handle of newly created polygon + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a coordinates is created using maps_coordinates_list_create(). + /// @see #maps_view_object_h + /// @see maps_view_object_create_marker() + /// @see maps_view_object_create_polyline() + /// @see maps_view_add_object() + /// @see maps_view_object_destroy() + /// @see #maps_coordinates_list_h + /// @see maps_coordinates_list_create() + int maps_view_object_create_polygon( + ffi.Pointer coordinates, + int r, + int g, + int b, + int a, + ffi.Pointer> polygon, + ) { + return _maps_view_object_create_polygon( + coordinates, + r, + g, + b, + a, + polygon, + ); + } + + late final _maps_view_object_create_polygon_ptr = + _lookup>( + 'maps_view_object_create_polygon'); + late final _dart_maps_view_object_create_polygon + _maps_view_object_create_polygon = _maps_view_object_create_polygon_ptr + .asFunction<_dart_maps_view_object_create_polygon>(); + + /// @brief Creates an overlay object. + /// @details This function creates an overlay object to contain Evas objects. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a overlay can be released by using maps_view_object_destroy().\n + /// If added to the View using maps_view_add_object(), @a overlay will be released automatically when the View is destroyed. + /// @param[in] coordinates The list of geographical coordinates + /// @param[in] object The Evas object to be contained + /// @param[in] type The type of boxing the @a object + /// @param[out] overlay The handle of newly created polygon + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a coordinates is created using maps_coordinates_list_create(). + /// @see #maps_view_object_h + /// @see maps_view_object_create_marker() + /// @see maps_view_object_create_polyline() + /// @see maps_view_object_create_polygon() + /// @see maps_view_add_object() + /// @see maps_view_object_destroy() + /// @see #maps_coordinates_h + /// @see maps_coordinates_create() + int maps_view_object_create_overlay( + ffi.Pointer coordinates, + ffi.Pointer object, + int type, + ffi.Pointer> overlay, + ) { + return _maps_view_object_create_overlay( + coordinates, + object, + type, + overlay, + ); + } + + late final _maps_view_object_create_overlay_ptr = + _lookup>( + 'maps_view_object_create_overlay'); + late final _dart_maps_view_object_create_overlay + _maps_view_object_create_overlay = _maps_view_object_create_overlay_ptr + .asFunction<_dart_maps_view_object_create_overlay>(); + + /// @brief Destroys the object. + /// @details This function destroys the object handle and releases all its resources. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] object The object handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @see #maps_view_object_h + /// @see maps_view_object_create_marker() + /// @see maps_view_object_create_polygon() + /// @see maps_view_object_create_polyline() + int maps_view_object_destroy( + ffi.Pointer object, + ) { + return _maps_view_object_destroy( + object, + ); + } + + late final _maps_view_object_destroy_ptr = + _lookup>( + 'maps_view_object_destroy'); + late final _dart_maps_view_object_destroy _maps_view_object_destroy = + _maps_view_object_destroy_ptr + .asFunction<_dart_maps_view_object_destroy>(); + + /// @brief Gets the object type. + /// @details This function gets the object type. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] object The object handle + /// @param[out] type The pointer to #maps_view_object_type_e in which to store the object type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a object is created using maps_view_object_create_marker(), maps_view_object_create_polyline() or maps_view_object_create_polygon(). + /// @see #maps_view_object_h + /// @see maps_view_object_create_marker() + /// @see maps_view_object_create_polyline() + /// @see maps_view_object_create_polygon() + int maps_view_object_get_type( + ffi.Pointer object, + ffi.Pointer type, + ) { + return _maps_view_object_get_type( + object, + type, + ); + } + + late final _maps_view_object_get_type_ptr = + _lookup>( + 'maps_view_object_get_type'); + late final _dart_maps_view_object_get_type _maps_view_object_get_type = + _maps_view_object_get_type_ptr + .asFunction<_dart_maps_view_object_get_type>(); + + /// @brief Shows the object. + /// @details This function changes the visibility of the given object on the View. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] object The object handle + /// @param[in] visible The new visibility of the object + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a object is created using maps_view_object_create_marker(), maps_view_object_create_polyline(), maps_view_object_create_polygon(). + /// @see #maps_view_object_h + /// @see maps_view_object_get_visible() + int maps_view_object_set_visible( + ffi.Pointer object, + bool visible, + ) { + return _maps_view_object_set_visible( + object, + visible ? 1 : 0, + ); + } + + late final _maps_view_object_set_visible_ptr = + _lookup>( + 'maps_view_object_set_visible'); + late final _dart_maps_view_object_set_visible _maps_view_object_set_visible = + _maps_view_object_set_visible_ptr + .asFunction<_dart_maps_view_object_set_visible>(); + + /// @brief Gets the object visibility. + /// @details This function retrieves whether or not the given object is visible. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] object The object handle + /// @param[out] visible The pointer to a boolean in which to store the object visibility + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a object is created using maps_view_object_create_marker(), maps_view_object_create_polyline(), maps_view_object_create_polygon(). + /// @see #maps_view_object_h + /// @see maps_view_object_set_visible() + int maps_view_object_get_visible( + ffi.Pointer object, + ffi.Pointer visible, + ) { + return _maps_view_object_get_visible( + object, + visible, + ); + } + + late final _maps_view_object_get_visible_ptr = + _lookup>( + 'maps_view_object_get_visible'); + late final _dart_maps_view_object_get_visible _maps_view_object_get_visible = + _maps_view_object_get_visible_ptr + .asFunction<_dart_maps_view_object_get_visible>(); + + /// @brief Sets points to the polyline. + /// @details This function sets point list to the polyline. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] polyline The polyline object handle + /// @param[in] points The points to set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a polyline is created using maps_view_object_create_polyline(). + /// @pre @a points are created using maps_coordinates_list_create(). + /// @post Previous points will be destroyed automatically. + /// @see #maps_view_object_h + /// @see #maps_coordinates_list_h + /// @see maps_coordinates_list_create() + /// @see maps_view_object_create_polyline() + /// @see maps_view_object_polyline_foreach_point() + int maps_view_object_polyline_set_polyline( + ffi.Pointer polyline, + ffi.Pointer points, + ) { + return _maps_view_object_polyline_set_polyline( + polyline, + points, + ); + } + + late final _maps_view_object_polyline_set_polyline_ptr = + _lookup>( + 'maps_view_object_polyline_set_polyline'); + late final _dart_maps_view_object_polyline_set_polyline + _maps_view_object_polyline_set_polyline = + _maps_view_object_polyline_set_polyline_ptr + .asFunction<_dart_maps_view_object_polyline_set_polyline>(); + + /// @brief Retrieves all points, added to the polyline. + /// @details This function retrieves all points, added to the polyline. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The points will be delivered via maps_view_object_polyline_point_cb(). + /// @param[in] polyline The polyline object handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data pointer to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a polyline is created using maps_view_object_create_polyline(). + /// @post This function invokes maps_view_object_polyline_point_cb() repeatedly to retrieve each point. + /// @see #maps_view_object_h + /// @see maps_view_object_create_polyline() + /// @see maps_view_object_polyline_set_polyline() + /// @see maps_view_object_polyline_point_cb() + int maps_view_object_polyline_foreach_point( + ffi.Pointer polyline, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_view_object_polyline_foreach_point( + polyline, + callback, + user_data, + ); + } + + late final _maps_view_object_polyline_foreach_point_ptr = + _lookup>( + 'maps_view_object_polyline_foreach_point'); + late final _dart_maps_view_object_polyline_foreach_point + _maps_view_object_polyline_foreach_point = + _maps_view_object_polyline_foreach_point_ptr + .asFunction<_dart_maps_view_object_polyline_foreach_point>(); + + /// @brief Sets the polyline color. + /// @details This function sets the polyline color on canvas. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] polyline The polyline object handle + /// @param[in] r The red component of the color + /// @param[in] g The green component of the color + /// @param[in] b The blue component of the color + /// @param[in] a The alpha component of the color + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a polyline is created using maps_view_object_create_polyline(). + /// @see maps_view_object_polyline_get_color() + /// @see maps_view_object_polyline_set_width() + /// @see maps_view_object_create_polyline() + int maps_view_object_polyline_set_color( + ffi.Pointer polyline, + int r, + int g, + int b, + int a, + ) { + return _maps_view_object_polyline_set_color( + polyline, + r, + g, + b, + a, + ); + } + + late final _maps_view_object_polyline_set_color_ptr = + _lookup>( + 'maps_view_object_polyline_set_color'); + late final _dart_maps_view_object_polyline_set_color + _maps_view_object_polyline_set_color = + _maps_view_object_polyline_set_color_ptr + .asFunction<_dart_maps_view_object_polyline_set_color>(); + + /// @brief Gets the polyline color. + /// @details This function gets the polyline color on canvas. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] polyline The polyline object handle + /// @param[out] r The unsigned char pointer in which to store the red component of the color, or NULL if not interested + /// @param[out] g The unsigned char pointer in which to store the green component of the color, or NULL if not interested + /// @param[out] b The unsigned char pointer in which to store the blue component of the color, or NULL if not interested + /// @param[out] a The unsigned char pointer in which to store the alpha component of the color, or NULL if not interested + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a polyline is created using maps_view_object_create_polyline(). + /// @pre color components may be previously set using maps_view_object_polyline_set_color(). + /// @see maps_view_object_polyline_set_color() + /// @see maps_view_object_polyline_get_width() + /// @see maps_view_object_create_polyline() + int maps_view_object_polyline_get_color( + ffi.Pointer polyline, + ffi.Pointer r, + ffi.Pointer g, + ffi.Pointer b, + ffi.Pointer a, + ) { + return _maps_view_object_polyline_get_color( + polyline, + r, + g, + b, + a, + ); + } + + late final _maps_view_object_polyline_get_color_ptr = + _lookup>( + 'maps_view_object_polyline_get_color'); + late final _dart_maps_view_object_polyline_get_color + _maps_view_object_polyline_get_color = + _maps_view_object_polyline_get_color_ptr + .asFunction<_dart_maps_view_object_polyline_get_color>(); + + /// @brief Sets the polyline width. + /// @details This function sets the polyline width on canvas. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] polyline The polyline object handle + /// @param[in] width The new width of line [1 ~ 100] (pixels) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a polyline is created using maps_view_object_create_polyline(). + /// @see maps_view_object_polyline_get_width() + /// @see maps_view_object_polyline_set_color() + /// @see maps_view_object_create_polyline() + int maps_view_object_polyline_set_width( + ffi.Pointer polyline, + int width, + ) { + return _maps_view_object_polyline_set_width( + polyline, + width, + ); + } + + late final _maps_view_object_polyline_set_width_ptr = + _lookup>( + 'maps_view_object_polyline_set_width'); + late final _dart_maps_view_object_polyline_set_width + _maps_view_object_polyline_set_width = + _maps_view_object_polyline_set_width_ptr + .asFunction<_dart_maps_view_object_polyline_set_width>(); + + /// @brief Gets the polyline width. + /// @details This function gets the polyline width on canvas. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] polyline The polyline object handle + /// @param[out] width The width of line [1 ~ 100] (pixels) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a polyline is created using maps_view_object_create_polyline(). + /// @pre @a width may be previously set using maps_view_object_polyline_set_width(). + /// @see maps_view_object_polyline_set_width() + /// @see maps_view_object_polyline_get_color() + /// @see maps_view_object_create_polyline() + int maps_view_object_polyline_get_width( + ffi.Pointer polyline, + ffi.Pointer width, + ) { + return _maps_view_object_polyline_get_width( + polyline, + width, + ); + } + + late final _maps_view_object_polyline_get_width_ptr = + _lookup>( + 'maps_view_object_polyline_get_width'); + late final _dart_maps_view_object_polyline_get_width + _maps_view_object_polyline_get_width = + _maps_view_object_polyline_get_width_ptr + .asFunction<_dart_maps_view_object_polyline_get_width>(); + + /// @brief Sets points to the polygon. + /// @details This function sets point list to the polygon. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] polygon The polygon object handle + /// @param[in] points The points to set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a polygon is created using maps_view_object_create_polygon(). + /// @pre @a points are created using maps_coordinates_list_create(). + /// @see maps_view_object_create_polygon() + /// @see #maps_view_object_h + /// @see #maps_coordinates_list_h + /// @see maps_coordinates_list_create() + /// @see maps_view_object_polygon_foreach_point() + int maps_view_object_polygon_set_polygon( + ffi.Pointer polygon, + ffi.Pointer points, + ) { + return _maps_view_object_polygon_set_polygon( + polygon, + points, + ); + } + + late final _maps_view_object_polygon_set_polygon_ptr = + _lookup>( + 'maps_view_object_polygon_set_polygon'); + late final _dart_maps_view_object_polygon_set_polygon + _maps_view_object_polygon_set_polygon = + _maps_view_object_polygon_set_polygon_ptr + .asFunction<_dart_maps_view_object_polygon_set_polygon>(); + + /// @brief Retrieves all points, added to the polygon. + /// @details This function retrieves all points, added to the polygon. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The objects will be delivered via maps_view_object_polygon_point_cb(). + /// @param[in] polygon The polygon object handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a polygon is created using maps_view_object_create_polygon(). + /// @post This function invokes maps_view_object_polygon_point_cb() repeatedly to retrieve each point. + /// @see maps_view_object_polygon_point_cb() + /// @see maps_view_object_create_polygon() + /// @see #maps_view_object_h + /// @see maps_view_object_polygon_set_polygon() + int maps_view_object_polygon_foreach_point( + ffi.Pointer polygon, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_view_object_polygon_foreach_point( + polygon, + callback, + user_data, + ); + } + + late final _maps_view_object_polygon_foreach_point_ptr = + _lookup>( + 'maps_view_object_polygon_foreach_point'); + late final _dart_maps_view_object_polygon_foreach_point + _maps_view_object_polygon_foreach_point = + _maps_view_object_polygon_foreach_point_ptr + .asFunction<_dart_maps_view_object_polygon_foreach_point>(); + + /// @brief Sets polygon fill color. + /// @details This function sets the polygon fill color on canvas. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] polygon The polygon object handle + /// @param[in] r The red component of the fill color + /// @param[in] g The green component of the fill color + /// @param[in] b The blue component of the fill color + /// @param[in] a The alpha component of the fill color + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a polygon is created using maps_view_object_create_polygon(). + /// @see maps_view_object_polygon_get_fill_color() + /// @see maps_view_object_create_polygon() + int maps_view_object_polygon_set_fill_color( + ffi.Pointer polygon, + int r, + int g, + int b, + int a, + ) { + return _maps_view_object_polygon_set_fill_color( + polygon, + r, + g, + b, + a, + ); + } + + late final _maps_view_object_polygon_set_fill_color_ptr = + _lookup>( + 'maps_view_object_polygon_set_fill_color'); + late final _dart_maps_view_object_polygon_set_fill_color + _maps_view_object_polygon_set_fill_color = + _maps_view_object_polygon_set_fill_color_ptr + .asFunction<_dart_maps_view_object_polygon_set_fill_color>(); + + /// @brief Gets polygon fill color. + /// @details This function gets the polygon fill color on canvas. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] polygon The polygon data handle + /// @param[in] r The unsigned char pointer in which to store the red component of the background color + /// @param[in] g The unsigned char pointer in which to store the green component of the background color + /// @param[in] b The unsigned char pointer in which to store the blue component of the background color + /// @param[in] a The unsigned char pointer in which to store the alpha component of the background color + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a polygon is created using maps_view_object_create_polygon(). + /// @pre Fill color components may be previously set using maps_view_object_polygon_set_fill_color(). + /// @see maps_view_object_polygon_set_fill_color() + /// @see maps_view_object_create_polygon() + int maps_view_object_polygon_get_fill_color( + ffi.Pointer polygon, + ffi.Pointer r, + ffi.Pointer g, + ffi.Pointer b, + ffi.Pointer a, + ) { + return _maps_view_object_polygon_get_fill_color( + polygon, + r, + g, + b, + a, + ); + } + + late final _maps_view_object_polygon_get_fill_color_ptr = + _lookup>( + 'maps_view_object_polygon_get_fill_color'); + late final _dart_maps_view_object_polygon_get_fill_color + _maps_view_object_polygon_get_fill_color = + _maps_view_object_polygon_get_fill_color_ptr + .asFunction<_dart_maps_view_object_polygon_get_fill_color>(); + + /// @brief Sets the marker coordinates. + /// @details This function sets the marker geographical coordinates. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] marker The marker object handle + /// @param[in] coordinates The marker geographical coordinates handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a marker is created using maps_view_object_create_marker(). + /// @pre @a coordinates are created using maps_coordinates_create(). + /// @see maps_view_object_create_marker() + /// @see maps_view_object_marker_get_coordinates() + /// @see #maps_coordinates_h + /// @see maps_coordinates_create() + int maps_view_object_marker_set_coordinates( + ffi.Pointer marker, + ffi.Pointer coordinates, + ) { + return _maps_view_object_marker_set_coordinates( + marker, + coordinates, + ); + } + + late final _maps_view_object_marker_set_coordinates_ptr = + _lookup>( + 'maps_view_object_marker_set_coordinates'); + late final _dart_maps_view_object_marker_set_coordinates + _maps_view_object_marker_set_coordinates = + _maps_view_object_marker_set_coordinates_ptr + .asFunction<_dart_maps_view_object_marker_set_coordinates>(); + + /// @brief Sets the marker screen size. + /// @details This function sets the marker screen size. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks To make the marker size proportionally, use 0 as the value for the @a width or @a height parameter. + /// For instance, to make the width of an marker 150 pixels, and change the height using the same proportion, + /// use maps_view_object_marker_resize(marker, 150, 0). + /// @param[in] marker The marker object handle + /// @param[in] width The resized marker pixels in width on the screen + /// @param[in] height The resized marker pixels in height on the screen + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a marker is created using maps_view_object_create_marker(). + /// @see maps_view_object_create_marker() + /// @see maps_view_object_marker_get_size() + int maps_view_object_marker_resize( + ffi.Pointer marker, + int width, + int height, + ) { + return _maps_view_object_marker_resize( + marker, + width, + height, + ); + } + + late final _maps_view_object_marker_resize_ptr = + _lookup>( + 'maps_view_object_marker_resize'); + late final _dart_maps_view_object_marker_resize + _maps_view_object_marker_resize = _maps_view_object_marker_resize_ptr + .asFunction<_dart_maps_view_object_marker_resize>(); + + /// @brief Sets the marker image file path. + /// @details This function sets the marker image file path. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage.\n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. + /// @param[in] marker The marker object handle + /// @param[in] file_path The marker image file path + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a marker is created using maps_view_object_create_marker(). + /// @see maps_view_object_marker_get_image_file() + /// @see maps_view_object_create_marker() + int maps_view_object_marker_set_image_file( + ffi.Pointer marker, + ffi.Pointer file_path, + ) { + return _maps_view_object_marker_set_image_file( + marker, + file_path, + ); + } + + late final _maps_view_object_marker_set_image_file_ptr = + _lookup>( + 'maps_view_object_marker_set_image_file'); + late final _dart_maps_view_object_marker_set_image_file + _maps_view_object_marker_set_image_file = + _maps_view_object_marker_set_image_file_ptr + .asFunction<_dart_maps_view_object_marker_set_image_file>(); + + /// @brief Gets the marker image file path. + /// @details This function gets the marker image file path. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The @a file_path should be freed using free(). + /// @param[in] marker The marker object handle + /// @param[out] file_path The marker image file path + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a marker is created using maps_view_object_create_marker(). + /// @pre @a file_path may be set previously using maps_view_object_marker_set_image_file(). + /// @see maps_view_object_marker_set_image_file() + /// @see maps_view_object_create_marker() + int maps_view_object_marker_get_image_file( + ffi.Pointer marker, + ffi.Pointer> file_path, + ) { + return _maps_view_object_marker_get_image_file( + marker, + file_path, + ); + } + + late final _maps_view_object_marker_get_image_file_ptr = + _lookup>( + 'maps_view_object_marker_get_image_file'); + late final _dart_maps_view_object_marker_get_image_file + _maps_view_object_marker_get_image_file = + _maps_view_object_marker_get_image_file_ptr + .asFunction<_dart_maps_view_object_marker_get_image_file>(); + + /// @brief Gets the marker coordinates. + /// @details This function gets the marker geographical coordinates. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The @a coordinates should be freed using maps_coordinates_destroy(). + /// @param[in] marker The marker object handle + /// @param[out] coordinates The pointer to #maps_coordinates_h in which to store the marker geographical coordinates + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a marker is created using maps_view_object_create_marker(). + /// @pre @a coordinates may be set previously using maps_view_object_marker_set_coordinates(). + /// @see maps_view_object_marker_set_coordinates() + /// @see #maps_coordinates_h + /// @see maps_view_object_create_marker() + int maps_view_object_marker_get_coordinates( + ffi.Pointer marker, + ffi.Pointer> coordinates, + ) { + return _maps_view_object_marker_get_coordinates( + marker, + coordinates, + ); + } + + late final _maps_view_object_marker_get_coordinates_ptr = + _lookup>( + 'maps_view_object_marker_get_coordinates'); + late final _dart_maps_view_object_marker_get_coordinates + _maps_view_object_marker_get_coordinates = + _maps_view_object_marker_get_coordinates_ptr + .asFunction<_dart_maps_view_object_marker_get_coordinates>(); + + /// @brief Gets the marker screen size. + /// @details This function gets the marker size on the screen. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] marker The marker object handle + /// @param[out] width The pointer to an integer in which to store the marker width on the screen in pixels + /// @param[out] height The pointer to an integer in which to store the marker height on the screen in pixels + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a marker is created using maps_view_object_create_marker(). + /// @pre @a width and @a height may be set previously using maps_view_object_marker_resize(). + /// @see maps_view_object_marker_resize() + /// @see maps_view_object_create_marker() + int maps_view_object_marker_get_size( + ffi.Pointer marker, + ffi.Pointer width, + ffi.Pointer height, + ) { + return _maps_view_object_marker_get_size( + marker, + width, + height, + ); + } + + late final _maps_view_object_marker_get_size_ptr = + _lookup>( + 'maps_view_object_marker_get_size'); + late final _dart_maps_view_object_marker_get_size + _maps_view_object_marker_get_size = _maps_view_object_marker_get_size_ptr + .asFunction<_dart_maps_view_object_marker_get_size>(); + + /// @brief Gets the marker type. + /// @details This function gets the marker type. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] marker The marker object handle + /// @param[out] type The pointer to a maps_view_marker_type_e in which to store the marker type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a marker is created using maps_view_object_create_marker(). + /// @see #maps_view_marker_type_e + /// @see maps_view_object_create_marker() + int maps_view_object_marker_get_type( + ffi.Pointer marker, + ffi.Pointer type, + ) { + return _maps_view_object_marker_get_type( + marker, + type, + ); + } + + late final _maps_view_object_marker_get_type_ptr = + _lookup>( + 'maps_view_object_marker_get_type'); + late final _dart_maps_view_object_marker_get_type + _maps_view_object_marker_get_type = _maps_view_object_marker_get_type_ptr + .asFunction<_dart_maps_view_object_marker_get_type>(); + + /// @brief Sets the marker z-order. + /// @details This function sets the z-order. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The @a z_order must be in range of [-100, 100]. + /// @param[in] marker The marker object handle + /// @param[in] z_order The z-order + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a marker is created using maps_view_object_create_marker(). + /// @see maps_view_object_create_marker() + /// @see maps_view_object_marker_get_z_order() + int maps_view_object_marker_set_z_order( + ffi.Pointer marker, + int z_order, + ) { + return _maps_view_object_marker_set_z_order( + marker, + z_order, + ); + } + + late final _maps_view_object_marker_set_z_order_ptr = + _lookup>( + 'maps_view_object_marker_set_z_order'); + late final _dart_maps_view_object_marker_set_z_order + _maps_view_object_marker_set_z_order = + _maps_view_object_marker_set_z_order_ptr + .asFunction<_dart_maps_view_object_marker_set_z_order>(); + + /// @brief Gets the marker z-order. + /// @details This function gets the z-order. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] marker The marker object handle + /// @param[out] z_order The z-order + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a marker is created using maps_view_object_create_marker(). + /// @see maps_view_object_create_marker() + /// @see maps_view_object_marker_set_z_order() + int maps_view_object_marker_get_z_order( + ffi.Pointer marker, + ffi.Pointer z_order, + ) { + return _maps_view_object_marker_get_z_order( + marker, + z_order, + ); + } + + late final _maps_view_object_marker_get_z_order_ptr = + _lookup>( + 'maps_view_object_marker_get_z_order'); + late final _dart_maps_view_object_marker_get_z_order + _maps_view_object_marker_get_z_order = + _maps_view_object_marker_get_z_order_ptr + .asFunction<_dart_maps_view_object_marker_get_z_order>(); + + /// @brief Gets the Evas object. + /// @details This function gets the Evas object. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The @a object must not be released. + /// @param[in] overlay The overlay object handle + /// @param[out] object The Evas object handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a marker is created using maps_view_object_create_overlay(). + /// @see maps_view_object_create_overlay() + int maps_view_object_overlay_get_object( + ffi.Pointer overlay, + ffi.Pointer> object, + ) { + return _maps_view_object_overlay_get_object( + overlay, + object, + ); + } + + late final _maps_view_object_overlay_get_object_ptr = + _lookup>( + 'maps_view_object_overlay_get_object'); + late final _dart_maps_view_object_overlay_get_object + _maps_view_object_overlay_get_object = + _maps_view_object_overlay_get_object_ptr + .asFunction<_dart_maps_view_object_overlay_get_object>(); + + /// @brief Sets the overlay coordinates. + /// @details This function sets the overlay geographical coordinates. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] overlay The overlay object handle + /// @param[in] coordinates The overlay geographical coordinates handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a overlay is created using maps_view_object_create_overlay(). + /// @pre @a coordinates are created using maps_coordinates_create(). + /// @see maps_view_object_create_overlay() + /// @see maps_view_object_overlay_get_coordinates() + /// @see #maps_coordinates_h + /// @see maps_coordinates_create() + int maps_view_object_overlay_set_coordinates( + ffi.Pointer overlay, + ffi.Pointer coordinates, + ) { + return _maps_view_object_overlay_set_coordinates( + overlay, + coordinates, + ); + } + + late final _maps_view_object_overlay_set_coordinates_ptr = + _lookup>( + 'maps_view_object_overlay_set_coordinates'); + late final _dart_maps_view_object_overlay_set_coordinates + _maps_view_object_overlay_set_coordinates = + _maps_view_object_overlay_set_coordinates_ptr + .asFunction<_dart_maps_view_object_overlay_set_coordinates>(); + + /// @brief Gets the overlay coordinates. + /// @details This function gets the overlay geographical coordinates. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The @a coordinates should be freed using maps_coordinates_destroy(). + /// @param[in] overlay The overlay object handle + /// @param[out] coordinates The pointer to #maps_coordinates_h in which to store the overlay geographical coordinates + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a overlay is created using maps_view_object_create_overlay(). + /// @pre @a coordinates may be set previously using maps_view_object_overlay_set_coordinates(). + /// @see maps_view_object_create_overlay() + /// @see maps_view_object_overlay_set_coordinates() + /// @see #maps_coordinates_h + /// @see maps_coordinates_destroy() + int maps_view_object_overlay_get_coordinates( + ffi.Pointer overlay, + ffi.Pointer> coordinates, + ) { + return _maps_view_object_overlay_get_coordinates( + overlay, + coordinates, + ); + } + + late final _maps_view_object_overlay_get_coordinates_ptr = + _lookup>( + 'maps_view_object_overlay_get_coordinates'); + late final _dart_maps_view_object_overlay_get_coordinates + _maps_view_object_overlay_get_coordinates = + _maps_view_object_overlay_get_coordinates_ptr + .asFunction<_dart_maps_view_object_overlay_get_coordinates>(); + + /// @brief Sets the minimal zoom level for overlay. + /// @details This function sets the minimally allowed zoom level of the map to show the overlay. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] overlay The overlay object handle + /// @param[in] zoom The new minimal zoom level + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a overlay is created using maps_view_object_create_overlay(). + /// @see maps_view_object_create_overlay() + /// @see maps_view_object_overlay_get_min_zoom_level() + /// @see maps_view_object_overlay_set_max_zoom_level() + /// @see maps_view_object_overlay_get_max_zoom_level() + int maps_view_object_overlay_set_min_zoom_level( + ffi.Pointer overlay, + int zoom, + ) { + return _maps_view_object_overlay_set_min_zoom_level( + overlay, + zoom, + ); + } + + late final _maps_view_object_overlay_set_min_zoom_level_ptr = _lookup< + ffi.NativeFunction<_c_maps_view_object_overlay_set_min_zoom_level>>( + 'maps_view_object_overlay_set_min_zoom_level'); + late final _dart_maps_view_object_overlay_set_min_zoom_level + _maps_view_object_overlay_set_min_zoom_level = + _maps_view_object_overlay_set_min_zoom_level_ptr + .asFunction<_dart_maps_view_object_overlay_set_min_zoom_level>(); + + /// @brief Gets the minimal zoom level for overlay. + /// @details This function gets the minimally allowed zoom level of the map to show the overlay. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] overlay The overlay object handle + /// @param[out] zoom The pointer to an integer in which to store the minimally allowed zoom level. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a overlay is created using maps_view_object_create_overlay(). + /// @see maps_view_object_create_overlay() + /// @see maps_view_object_overlay_set_min_zoom_level() + /// @see maps_view_object_overlay_set_max_zoom_level() + /// @see maps_view_object_overlay_get_max_zoom_level() + int maps_view_object_overlay_get_min_zoom_level( + ffi.Pointer overlay, + ffi.Pointer zoom, + ) { + return _maps_view_object_overlay_get_min_zoom_level( + overlay, + zoom, + ); + } + + late final _maps_view_object_overlay_get_min_zoom_level_ptr = _lookup< + ffi.NativeFunction<_c_maps_view_object_overlay_get_min_zoom_level>>( + 'maps_view_object_overlay_get_min_zoom_level'); + late final _dart_maps_view_object_overlay_get_min_zoom_level + _maps_view_object_overlay_get_min_zoom_level = + _maps_view_object_overlay_get_min_zoom_level_ptr + .asFunction<_dart_maps_view_object_overlay_get_min_zoom_level>(); + + /// @brief Sets the minimal zoom level for overlay. + /// @details This function sets the minimally allowed zoom level of the map to show the overlay. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] overlay The overlay object handle + /// @param[in] zoom The new minimal zoom level + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a overlay is created using maps_view_object_create_overlay(). + /// @see maps_view_object_create_overlay() + /// @see maps_view_object_overlay_get_min_zoom_level() + /// @see maps_view_object_overlay_set_min_zoom_level() + /// @see maps_view_object_overlay_get_max_zoom_level() + int maps_view_object_overlay_set_max_zoom_level( + ffi.Pointer overlay, + int zoom, + ) { + return _maps_view_object_overlay_set_max_zoom_level( + overlay, + zoom, + ); + } + + late final _maps_view_object_overlay_set_max_zoom_level_ptr = _lookup< + ffi.NativeFunction<_c_maps_view_object_overlay_set_max_zoom_level>>( + 'maps_view_object_overlay_set_max_zoom_level'); + late final _dart_maps_view_object_overlay_set_max_zoom_level + _maps_view_object_overlay_set_max_zoom_level = + _maps_view_object_overlay_set_max_zoom_level_ptr + .asFunction<_dart_maps_view_object_overlay_set_max_zoom_level>(); + + /// @brief Gets the minimal zoom level for overlay. + /// @details This function gets the minimally allowed zoom level of the map to show the overlay. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] overlay The overlay object handle + /// @param[out] zoom The pointer to an integer in which to store the minimally allowed zoom level + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a overlay is created using maps_view_object_create_overlay(). + /// @see maps_view_object_create_overlay() + /// @see maps_view_object_overlay_get_min_zoom_level() + /// @see maps_view_object_overlay_set_min_zoom_level() + /// @see maps_view_object_overlay_set_max_zoom_level() + int maps_view_object_overlay_get_max_zoom_level( + ffi.Pointer overlay, + ffi.Pointer zoom, + ) { + return _maps_view_object_overlay_get_max_zoom_level( + overlay, + zoom, + ); + } + + late final _maps_view_object_overlay_get_max_zoom_level_ptr = _lookup< + ffi.NativeFunction<_c_maps_view_object_overlay_get_max_zoom_level>>( + 'maps_view_object_overlay_get_max_zoom_level'); + late final _dart_maps_view_object_overlay_get_max_zoom_level + _maps_view_object_overlay_get_max_zoom_level = + _maps_view_object_overlay_get_max_zoom_level_ptr + .asFunction<_dart_maps_view_object_overlay_get_max_zoom_level>(); + + /// @brief Destroys the event data handle. + /// @details This function destroys the event data handle and releases all its resources. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] event The event data handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a event may be obtained in maps_view_on_event_cb(). + /// @see #maps_view_event_data_h + /// @see maps_view_event_data_clone() + int maps_view_event_data_destroy( + ffi.Pointer event, + ) { + return _maps_view_event_data_destroy( + event, + ); + } + + late final _maps_view_event_data_destroy_ptr = + _lookup>( + 'maps_view_event_data_destroy'); + late final _dart_maps_view_event_data_destroy _maps_view_event_data_destroy = + _maps_view_event_data_destroy_ptr + .asFunction<_dart_maps_view_event_data_destroy>(); + + /// @brief Clones the event handle. + /// @details This function clones the event handle @a origin and all its resources. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a cloned must be released using maps_view_event_data_destroy(). + /// @param[in] origin The original event handle + /// @param[out] cloned A cloned event handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a event may be obtained in maps_view_on_event_cb(). + /// @see #maps_view_event_data_h + /// @see maps_view_event_data_destroy() + /// @see maps_view_on_event_cb() + int maps_view_event_data_clone( + ffi.Pointer origin, + ffi.Pointer> cloned, + ) { + return _maps_view_event_data_clone( + origin, + cloned, + ); + } + + late final _maps_view_event_data_clone_ptr = + _lookup>( + 'maps_view_event_data_clone'); + late final _dart_maps_view_event_data_clone _maps_view_event_data_clone = + _maps_view_event_data_clone_ptr + .asFunction<_dart_maps_view_event_data_clone>(); + + /// @brief Gets the event type. + /// @details This function gets the event type. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] event The event data handle + /// @param[out] event_type The pointer to the #maps_view_event_type_e in which to store the event type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a event may be obtained in maps_view_on_event_cb(). + /// @see #maps_view_event_type_e + /// @see #maps_view_event_data_h + /// @see maps_view_event_data_destroy() + /// @see maps_view_on_event_cb() + int maps_view_event_data_get_type( + ffi.Pointer event, + ffi.Pointer event_type, + ) { + return _maps_view_event_data_get_type( + event, + event_type, + ); + } + + late final _maps_view_event_data_get_type_ptr = + _lookup>( + 'maps_view_event_data_get_type'); + late final _dart_maps_view_event_data_get_type + _maps_view_event_data_get_type = _maps_view_event_data_get_type_ptr + .asFunction<_dart_maps_view_event_data_get_type>(); + + /// @brief Gets the event gesture type. + /// @details This function gets the event gesture type if the event type is #MAPS_VIEW_EVENT_GESTURE or #MAPS_VIEW_EVENT_OBJECT. + /// Otherwise it returns #MAPS_ERROR_INVALID_PARAMETER. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] event The event data handle + /// @param[out] gesture_type The pointer to the #maps_view_gesture_e in which to store the gesture type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a event may be obtained in maps_view_on_event_cb(). + /// @see #maps_view_gesture_e + /// @see #maps_view_event_data_h + /// @see maps_view_event_data_get_type() + /// @see maps_view_on_event_cb() + int maps_view_event_data_get_gesture_type( + ffi.Pointer event, + ffi.Pointer gesture_type, + ) { + return _maps_view_event_data_get_gesture_type( + event, + gesture_type, + ); + } + + late final _maps_view_event_data_get_gesture_type_ptr = + _lookup>( + 'maps_view_event_data_get_gesture_type'); + late final _dart_maps_view_event_data_get_gesture_type + _maps_view_event_data_get_gesture_type = + _maps_view_event_data_get_gesture_type_ptr + .asFunction<_dart_maps_view_event_data_get_gesture_type>(); + + /// @brief Gets the event action type. + /// @details This function gets the event action type if the event type is #MAPS_VIEW_EVENT_ACTION. + /// Otherwise, it returns #MAPS_ERROR_INVALID_PARAMETER. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] event The event data handle + /// @param[out] action_type The pointer to the #maps_view_action_e in which to store the action type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a event may be obtained in maps_view_on_event_cb(). + /// @see #maps_view_action_e + /// @see #maps_view_event_data_h + /// @see maps_view_event_data_get_type() + /// @see maps_view_on_event_cb() + int maps_view_event_data_get_action_type( + ffi.Pointer event, + ffi.Pointer action_type, + ) { + return _maps_view_event_data_get_action_type( + event, + action_type, + ); + } + + late final _maps_view_event_data_get_action_type_ptr = + _lookup>( + 'maps_view_event_data_get_action_type'); + late final _dart_maps_view_event_data_get_action_type + _maps_view_event_data_get_action_type = + _maps_view_event_data_get_action_type_ptr + .asFunction<_dart_maps_view_event_data_get_action_type>(); + + /// @brief Gets the new map center coordinates. + /// @details This function gets the new map center coordinates if the event type is #MAPS_VIEW_EVENT_ACTION. + /// Otherwise, it returns #MAPS_ERROR_INVALID_PARAMETER. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The @a center should be freed using maps_coordinates_destroy(). + /// @param[in] event The event data handle + /// @param[out] center The pointer to the #maps_coordinates_h in which to store the new center coordinates + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a event may be obtained in maps_view_on_event_cb(). + /// @see #maps_view_event_type_e + /// @see #maps_view_event_data_h + /// @see #maps_coordinates_h + /// @see maps_view_event_data_get_type() + /// @see maps_view_on_event_cb() + int maps_view_event_data_get_center( + ffi.Pointer event, + ffi.Pointer> center, + ) { + return _maps_view_event_data_get_center( + event, + center, + ); + } + + late final _maps_view_event_data_get_center_ptr = + _lookup>( + 'maps_view_event_data_get_center'); + late final _dart_maps_view_event_data_get_center + _maps_view_event_data_get_center = _maps_view_event_data_get_center_ptr + .asFunction<_dart_maps_view_event_data_get_center>(); + + /// @brief Gets the new map center movement coordinates delta. + /// @details This function gets the screen coordinates delta of map center movement if the event type is #MAPS_VIEW_EVENT_ACTION. + /// Otherwise, it returns #MAPS_ERROR_INVALID_PARAMETER. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] event The event data handle + /// @param[out] delta_x The pointer to an integer in which to store the delta x + /// @param[out] delta_y The pointer to an integer in which to store the delta y + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a event may be obtained in maps_view_on_event_cb(). + /// @see #maps_view_event_type_e + /// @see #maps_view_event_data_h + /// @see maps_view_event_data_get_type() + /// @see maps_view_on_event_cb() + int maps_view_event_data_get_delta( + ffi.Pointer event, + ffi.Pointer delta_x, + ffi.Pointer delta_y, + ) { + return _maps_view_event_data_get_delta( + event, + delta_x, + delta_y, + ); + } + + late final _maps_view_event_data_get_delta_ptr = + _lookup>( + 'maps_view_event_data_get_delta'); + late final _dart_maps_view_event_data_get_delta + _maps_view_event_data_get_delta = _maps_view_event_data_get_delta_ptr + .asFunction<_dart_maps_view_event_data_get_delta>(); + + /// @brief Gets the event screen coordinates. + /// @details This function gets the event screen coordinates if the event type is #MAPS_VIEW_EVENT_GESTURE or #MAPS_VIEW_EVENT_OBJECT. + /// Otherwise, it returns #MAPS_ERROR_INVALID_PARAMETER. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] event The event data handle + /// @param[out] x The pointer to an integer in which to store the x position of the event + /// @param[out] y The pointer to an integer in which to store the y position of the event + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a event may be obtained in maps_view_on_event_cb(). + /// @see #maps_view_event_type_e + /// @see #maps_view_event_data_h + /// @see maps_view_event_data_get_type() + /// @see maps_view_on_event_cb() + int maps_view_event_data_get_position( + ffi.Pointer event, + ffi.Pointer x, + ffi.Pointer y, + ) { + return _maps_view_event_data_get_position( + event, + x, + y, + ); + } + + late final _maps_view_event_data_get_position_ptr = + _lookup>( + 'maps_view_event_data_get_position'); + late final _dart_maps_view_event_data_get_position + _maps_view_event_data_get_position = + _maps_view_event_data_get_position_ptr + .asFunction<_dart_maps_view_event_data_get_position>(); + + /// @brief Gets the event geographic coordinates. + /// @details This function gets the event geographic coordinates if the event type is #MAPS_VIEW_EVENT_GESTURE. + /// Otherwise, it returns #MAPS_ERROR_INVALID_PARAMETER. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The @a coordinates should be freed using maps_coordinates_destroy(). + /// @param[in] event The event data handle + /// @param[out] coordinates The pointer to the #maps_coordinates_h in which to store the coordinates + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a event may be obtained in maps_view_on_event_cb(). + /// @see #maps_view_event_type_e + /// @see #maps_view_event_data_h + /// @see #maps_coordinates_h + /// @see maps_view_event_data_get_type() + /// @see maps_view_on_event_cb() + int maps_view_event_data_get_coordinates( + ffi.Pointer event, + ffi.Pointer> coordinates, + ) { + return _maps_view_event_data_get_coordinates( + event, + coordinates, + ); + } + + late final _maps_view_event_data_get_coordinates_ptr = + _lookup>( + 'maps_view_event_data_get_coordinates'); + late final _dart_maps_view_event_data_get_coordinates + _maps_view_event_data_get_coordinates = + _maps_view_event_data_get_coordinates_ptr + .asFunction<_dart_maps_view_event_data_get_coordinates>(); + + /// @brief Gets the number of fingers, detected in the event. + /// @details This function gets the number of user's fingers detected in the event if the event type is #MAPS_VIEW_EVENT_GESTURE or #MAPS_VIEW_EVENT_OBJECT. + /// Otherwise, it returns #MAPS_ERROR_INVALID_PARAMETER. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] event The event data handle + /// @param[out] fingers The pointer to an integer in which to store the number of fingers, detected in the gesture + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a event may be obtained in maps_view_on_event_cb(). + /// @see #maps_view_event_type_e + /// @see #maps_view_event_data_h + /// @see maps_view_event_data_get_type() + /// @see maps_view_on_event_cb() + int maps_view_event_data_get_fingers( + ffi.Pointer event, + ffi.Pointer fingers, + ) { + return _maps_view_event_data_get_fingers( + event, + fingers, + ); + } + + late final _maps_view_event_data_get_fingers_ptr = + _lookup>( + 'maps_view_event_data_get_fingers'); + late final _dart_maps_view_event_data_get_fingers + _maps_view_event_data_get_fingers = _maps_view_event_data_get_fingers_ptr + .asFunction<_dart_maps_view_event_data_get_fingers>(); + + /// @brief Gets zoom factor of zoom gesture or action. + /// @details This function gets the corresponding zoom factor if the event type is #MAPS_VIEW_EVENT_GESTURE or #MAPS_VIEW_EVENT_ACTION. + /// Otherwise, it returns the #MAPS_ERROR_INVALID_PARAMETER. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] event The event data handle + /// @param[out] zoom_factor The pointer to a double in which to store the zoom factor + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a event may be obtained in maps_view_on_event_cb(). + /// @see #maps_view_event_type_e + /// @see #maps_view_event_data_h + /// @see maps_view_event_data_get_type() + /// @see maps_view_on_event_cb() + int maps_view_event_data_get_zoom_factor( + ffi.Pointer event, + ffi.Pointer zoom_factor, + ) { + return _maps_view_event_data_get_zoom_factor( + event, + zoom_factor, + ); + } + + late final _maps_view_event_data_get_zoom_factor_ptr = + _lookup>( + 'maps_view_event_data_get_zoom_factor'); + late final _dart_maps_view_event_data_get_zoom_factor + _maps_view_event_data_get_zoom_factor = + _maps_view_event_data_get_zoom_factor_ptr + .asFunction<_dart_maps_view_event_data_get_zoom_factor>(); + + /// @brief Gets rotation angle of rotation gesture or action. + /// @details This function gets the corresponding rotation angle if the event type is #MAPS_VIEW_EVENT_GESTURE or #MAPS_VIEW_EVENT_ACTION. + /// Otherwise, it returns #MAPS_ERROR_INVALID_PARAMETER. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] event The event data handle + /// @param[out] rotation_angle The pointer to a double in which to store the rotation angle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a event may be obtained in maps_view_on_event_cb(). + /// @see #maps_view_event_type_e + /// @see #maps_view_event_data_h + /// @see maps_view_event_data_get_type() + /// @see maps_view_on_event_cb() + int maps_view_event_data_get_rotation_angle( + ffi.Pointer event, + ffi.Pointer rotation_angle, + ) { + return _maps_view_event_data_get_rotation_angle( + event, + rotation_angle, + ); + } + + late final _maps_view_event_data_get_rotation_angle_ptr = + _lookup>( + 'maps_view_event_data_get_rotation_angle'); + late final _dart_maps_view_event_data_get_rotation_angle + _maps_view_event_data_get_rotation_angle = + _maps_view_event_data_get_rotation_angle_ptr + .asFunction<_dart_maps_view_event_data_get_rotation_angle>(); + + /// @brief Gets object of event. + /// @details When the event type is #MAPS_VIEW_EVENT_OBJECT, this function gets the corresponding object handle. + /// Otherwise, it returns #MAPS_ERROR_INVALID_PARAMETER. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The @a object must not be released. + /// @param[in] event The event data handle + /// @param[out] object The pointer to #maps_view_object_h in which to store the object handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a event may be obtained in maps_view_on_event_cb(). + /// @see #maps_view_event_type_e + /// @see #maps_view_event_data_h + /// @see maps_view_event_data_get_type() + /// @see maps_view_on_event_cb() + int maps_view_event_data_get_object( + ffi.Pointer event, + ffi.Pointer> object, + ) { + return _maps_view_event_data_get_object( + event, + object, + ); + } + + late final _maps_view_event_data_get_object_ptr = + _lookup>( + 'maps_view_event_data_get_object'); + late final _dart_maps_view_event_data_get_object + _maps_view_event_data_get_object = _maps_view_event_data_get_object_ptr + .asFunction<_dart_maps_view_event_data_get_object>(); + + /// @brief Captures a snapshot of the Map View.\n + /// The request is synchronous. + /// @details This function retrieves an image of a map currently represented on the Map View. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice + /// @remarks To check if Maps Provider is capable of capturing snapshots use + /// maps_service_provider_is_service_supported() with + /// #MAPS_SERVICE_VIEW_SNAPSHOT passed as @a service parameter.\n + /// It returns MAPS_ERROR_PERMISSION_DENIED if application doesn't have permission + /// to write to the path. + /// @param[in] view The Map View handle + /// @param[in] type The type of file format + /// @param[in] quality The quality for encoding (1~100) + /// @param[in] path The file path to be created callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre Call maps_service_create() and map_view_create() to issue Maps Service and Map View handles respectively. + /// @post It invokes map_view_snapshot_cb() to deliver requested snapshot. + /// @see maps_view_create() + /// @see maps_service_create() + int maps_view_capture_snapshot( + ffi.Pointer view, + int type, + int quality, + ffi.Pointer path, + ) { + return _maps_view_capture_snapshot( + view, + type, + quality, + path, + ); + } + + late final _maps_view_capture_snapshot_ptr = + _lookup>( + 'maps_view_capture_snapshot'); + late final _dart_maps_view_capture_snapshot _maps_view_capture_snapshot = + _maps_view_capture_snapshot_ptr + .asFunction<_dart_maps_view_capture_snapshot>(); + + /// @brief Creates the View and link it to the instance of maps service. + /// @details This function creates a new View widget, allocates all needed resources and issues its handle.\n + /// The newly created View is linked to the specified map's service.\n + /// The View by default is resized to fill whole parent area.\n + /// To center the map on a specific geographical coordinates with a desired + /// zoom level and rotation angle, use maps_view_set_center(), + /// maps_view_set_zoom_level() and maps_view_set_orientation() respectively.\n + /// To change View theme, size and visibility properties use + /// maps_view_set_type() and maps_view_set_visibility() respectively. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice + /// @remarks The @a View must be released using maps_view_destroy(). + /// @param[in] maps The maps service handle + /// @param[in] obj The evas object to be drawn + /// @param[out] view The handle pointer to a maps_view_h, in which to store the newly created View handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a maps is created using maps_service_create(). + /// @pre @a obj is recommended using a smart object. + /// @see maps_view_destroy() + /// @see maps_service_create() + /// @see maps_view_set_center() + /// @see maps_view_set_zoom_level() + /// @see maps_view_set_orientation() + /// @see maps_view_set_type() + /// @see maps_view_set_visibility() + /// @see elm_layout_add() + int maps_view_create( + ffi.Pointer maps, + ffi.Pointer obj, + ffi.Pointer> view, + ) { + return _maps_view_create( + maps, + obj, + view, + ); + } + + late final _maps_view_create_ptr = + _lookup>('maps_view_create'); + late final _dart_maps_view_create _maps_view_create = + _maps_view_create_ptr.asFunction<_dart_maps_view_create>(); + + /// @brief Destroys the View. + /// @details This function destroys the View, releases its handle and all allocated resources, unlinks the View from the instance of maps service. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice + /// @param[in] view The View handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a View is created using maps_view_create(). + /// @see maps_view_create() + int maps_view_destroy( + ffi.Pointer view, + ) { + return _maps_view_destroy( + view, + ); + } + + late final _maps_view_destroy_ptr = + _lookup>('maps_view_destroy'); + late final _dart_maps_view_destroy _maps_view_destroy = + _maps_view_destroy_ptr.asFunction<_dart_maps_view_destroy>(); + + /// @brief Centers the map on a given geographical coordinates. + /// @details This function centers the map on a given geographical coordinates using current zoom and orientation. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @param[in] view The view handle + /// @param[in] coordinates The geographical coordinates of the position to be centered on the View + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network unavailable + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @pre @a coordinates are created using maps_coordinates_create(). + /// @see maps_view_get_center() + /// @see maps_view_set_zoom_level() + /// @see maps_view_set_orientation() + /// @see maps_coordinates_create() + /// @see maps_view_create() + int maps_view_set_center( + ffi.Pointer view, + ffi.Pointer coordinates, + ) { + return _maps_view_set_center( + view, + coordinates, + ); + } + + late final _maps_view_set_center_ptr = + _lookup>( + 'maps_view_set_center'); + late final _dart_maps_view_set_center _maps_view_set_center = + _maps_view_set_center_ptr.asFunction<_dart_maps_view_set_center>(); + + /// @brief Gets the central coordinates of a map. + /// @details This function gets the current central coordinates of a map. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The @a coordinates must be released using maps_coordinates_destroy(). + /// @param[in] view The view handle + /// @param[out] coordinates The pointer to #maps_coordinates_h in which to + /// store the geographical coordinates of the central position of the map + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_set_center() + /// @see maps_view_get_zoom_level() + /// @see maps_view_get_orientation() + /// @see maps_coordinates_destroy() + /// @see maps_view_create() + int maps_view_get_center( + ffi.Pointer view, + ffi.Pointer> coordinates, + ) { + return _maps_view_get_center( + view, + coordinates, + ); + } + + late final _maps_view_get_center_ptr = + _lookup>( + 'maps_view_get_center'); + late final _dart_maps_view_get_center _maps_view_get_center = + _maps_view_get_center_ptr.asFunction<_dart_maps_view_get_center>(); + + /// @brief Sets zoom level of the map. + /// @details This function sets the integer zoom level of the map.\n + /// If the specified zoom level exceeds the maps Provider allowed zoom range, + /// the function returns #MAPS_ERROR_INVALID_PARAMETER error.\n + /// To check the range of allowed zoom level use maps_view_get_min_zoom_level() + /// and maps_view_get_max_zoom_level(). + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @param[in] view The view handle + /// @param[in] level The new zoom level + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network unavailable + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_get_zoom_level() + /// @see maps_view_set_orientation() + /// @see maps_view_get_min_zoom_level() + /// @see maps_view_get_max_zoom_level() + /// @see maps_view_create() + int maps_view_set_zoom_level( + ffi.Pointer view, + int level, + ) { + return _maps_view_set_zoom_level( + view, + level, + ); + } + + late final _maps_view_set_zoom_level_ptr = + _lookup>( + 'maps_view_set_zoom_level'); + late final _dart_maps_view_set_zoom_level _maps_view_set_zoom_level = + _maps_view_set_zoom_level_ptr + .asFunction<_dart_maps_view_set_zoom_level>(); + + /// @brief Gets zoom level of the map. + /// @details This function gets the current integer zoom level of the map. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[out] level The pointer to an integer in which to store the current zoom level + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_set_zoom_level() + /// @see maps_view_get_min_zoom_level() + /// @see maps_view_get_max_zoom_level() + /// @see maps_view_create() + int maps_view_get_zoom_level( + ffi.Pointer view, + ffi.Pointer level, + ) { + return _maps_view_get_zoom_level( + view, + level, + ); + } + + late final _maps_view_get_zoom_level_ptr = + _lookup>( + 'maps_view_get_zoom_level'); + late final _dart_maps_view_get_zoom_level _maps_view_get_zoom_level = + _maps_view_get_zoom_level_ptr + .asFunction<_dart_maps_view_get_zoom_level>(); + + /// @brief Sets the minimal zoom level of the map. + /// @details This function sets the minimally allowed zoom level of the map. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice + /// @param[in] view The view handle + /// @param[out] level The new minimal zoom level + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_get_min_zoom_level() + /// @see maps_view_set_max_zoom_level() + /// @see maps_view_get_max_zoom_level() + /// @see maps_view_get_zoom_level() + /// @see maps_view_set_zoom_level() + /// @see maps_view_create() + int maps_view_set_min_zoom_level( + ffi.Pointer view, + int level, + ) { + return _maps_view_set_min_zoom_level( + view, + level, + ); + } + + late final _maps_view_set_min_zoom_level_ptr = + _lookup>( + 'maps_view_set_min_zoom_level'); + late final _dart_maps_view_set_min_zoom_level _maps_view_set_min_zoom_level = + _maps_view_set_min_zoom_level_ptr + .asFunction<_dart_maps_view_set_min_zoom_level>(); + + /// @brief Gets the minimal zoom level of the map. + /// @details This function gets the minimally allowed zoom level of the map. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[out] min_zoom_level The pointer to an integer in which to store the minimally allowed zoom level + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_get_max_zoom_level() + /// @see maps_view_get_zoom_level() + /// @see maps_view_set_zoom_level() + /// @see maps_view_create() + int maps_view_get_min_zoom_level( + ffi.Pointer view, + ffi.Pointer min_zoom_level, + ) { + return _maps_view_get_min_zoom_level( + view, + min_zoom_level, + ); + } + + late final _maps_view_get_min_zoom_level_ptr = + _lookup>( + 'maps_view_get_min_zoom_level'); + late final _dart_maps_view_get_min_zoom_level _maps_view_get_min_zoom_level = + _maps_view_get_min_zoom_level_ptr + .asFunction<_dart_maps_view_get_min_zoom_level>(); + + /// @brief Sets the maximal zoom level of the map. + /// @details This function sets the maximally allowed zoom level of the map. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice + /// @param[in] view The view handle + /// @param[out] level The new maximal zoom level + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_set_min_zoom_level() + /// @see maps_view_get_min_zoom_level() + /// @see maps_view_get_max_zoom_level() + /// @see maps_view_get_zoom_level() + /// @see maps_view_set_zoom_level() + /// @see maps_view_create() + int maps_view_set_max_zoom_level( + ffi.Pointer view, + int level, + ) { + return _maps_view_set_max_zoom_level( + view, + level, + ); + } + + late final _maps_view_set_max_zoom_level_ptr = + _lookup>( + 'maps_view_set_max_zoom_level'); + late final _dart_maps_view_set_max_zoom_level _maps_view_set_max_zoom_level = + _maps_view_set_max_zoom_level_ptr + .asFunction<_dart_maps_view_set_max_zoom_level>(); + + /// @brief Gets the maximal zoom level of the map. + /// @details This function gets the maximally allowed zoom level of the map. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[out] max_zoom_level The pointer to an integer in which to store the maximally allowed zoom level + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_get_min_zoom_level() + /// @see maps_view_get_zoom_level() + /// @see maps_view_set_zoom_level() + /// @see maps_view_create() + int maps_view_get_max_zoom_level( + ffi.Pointer view, + ffi.Pointer max_zoom_level, + ) { + return _maps_view_get_max_zoom_level( + view, + max_zoom_level, + ); + } + + late final _maps_view_get_max_zoom_level_ptr = + _lookup>( + 'maps_view_get_max_zoom_level'); + late final _dart_maps_view_get_max_zoom_level _maps_view_get_max_zoom_level = + _maps_view_get_max_zoom_level_ptr + .asFunction<_dart_maps_view_get_max_zoom_level>(); + + /// @brief Sets the orientation on the View. + /// @details This function sets the rotation angle of the View.\n + /// If the specified rotation angle exceeds the [0..360] range, + /// the function returns #MAPS_ERROR_INVALID_PARAMETER error. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @param[in] view The view handle + /// @param[in] angle The new orientation angle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network unavailable + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_get_orientation() + /// @see maps_view_set_zoom_level() + /// @see maps_view_create() + int maps_view_set_orientation( + ffi.Pointer view, + double angle, + ) { + return _maps_view_set_orientation( + view, + angle, + ); + } + + late final _maps_view_set_orientation_ptr = + _lookup>( + 'maps_view_set_orientation'); + late final _dart_maps_view_set_orientation _maps_view_set_orientation = + _maps_view_set_orientation_ptr + .asFunction<_dart_maps_view_set_orientation>(); + + /// @brief Gets the orientation. + /// @details This function gets the current map rotation angle on the View. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[out] rotation_angle The pointer to a double in which to store the current rotation angle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_set_orientation() + /// @see maps_view_get_zoom_level() + /// @see maps_view_create() + int maps_view_get_orientation( + ffi.Pointer view, + ffi.Pointer rotation_angle, + ) { + return _maps_view_get_orientation( + view, + rotation_angle, + ); + } + + late final _maps_view_get_orientation_ptr = + _lookup>( + 'maps_view_get_orientation'); + late final _dart_maps_view_get_orientation _maps_view_get_orientation = + _maps_view_get_orientation_ptr + .asFunction<_dart_maps_view_get_orientation>(); + + /// @brief Converts screen coordinates to the geographical coordinates. + /// @details This function converts screen coordinates to the geographical coordinates accordingly to the current map zoom and orientation. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice + /// @remarks The @a coordinates must be released using maps_coordinates_destroy(). + /// @param[in] view The view handle + /// @param[in] x The x coordinate on the screen + /// @param[in] y The y coordinate on the screen + /// @param[out] coordinates The pointer to a #maps_coordinates_h in which to store the handle of geographical coordinates, + /// corresponding to given screen coordinates + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_geolocation_to_screen() + /// @see #maps_coordinates_h + /// @see maps_coordinates_destroy() + /// @see maps_view_create() + int maps_view_screen_to_geolocation( + ffi.Pointer view, + int x, + int y, + ffi.Pointer> coordinates, + ) { + return _maps_view_screen_to_geolocation( + view, + x, + y, + coordinates, + ); + } + + late final _maps_view_screen_to_geolocation_ptr = + _lookup>( + 'maps_view_screen_to_geolocation'); + late final _dart_maps_view_screen_to_geolocation + _maps_view_screen_to_geolocation = _maps_view_screen_to_geolocation_ptr + .asFunction<_dart_maps_view_screen_to_geolocation>(); + + /// @brief Converts geographical coordinates to the screen coordinates. + /// @details This function converts geographical coordinates to the screen + /// coordinates accordingly to the current map zoom and orientation. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice + /// @param[in] view The view handle + /// @param[in] coordinates The geographical coordinates + /// @param[out] x The pointer to an integer in which to store the x coordinate on the screen, + /// corresponding to given geographical coordinates + /// @param[out] y The pointer to an integer in which to store the y coordinate on the screen, + /// corresponding to given geographical coordinates + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @pre @a coordinates is created using maps_coordinates_create(). + /// @see maps_view_screen_to_geolocation() + /// @see #maps_coordinates_h + /// @see maps_coordinates_create() + /// @see maps_view_create() + int maps_view_geolocation_to_screen( + ffi.Pointer view, + ffi.Pointer coordinates, + ffi.Pointer x, + ffi.Pointer y, + ) { + return _maps_view_geolocation_to_screen( + view, + coordinates, + x, + y, + ); + } + + late final _maps_view_geolocation_to_screen_ptr = + _lookup>( + 'maps_view_geolocation_to_screen'); + late final _dart_maps_view_geolocation_to_screen + _maps_view_geolocation_to_screen = _maps_view_geolocation_to_screen_ptr + .asFunction<_dart_maps_view_geolocation_to_screen>(); + + /// @brief Sets View type. + /// @details This function switches the View to a specified type, one of listed in #maps_view_type_e enumeration. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @param[in] view The view handle + /// @param[in] type The view type, one of listed in #maps_view_type_e + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network unavailable + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see #maps_view_type_e + /// @see maps_view_get_type() + /// @see maps_view_set_language() + /// @see maps_view_create() + int maps_view_set_type( + ffi.Pointer view, + int type, + ) { + return _maps_view_set_type( + view, + type, + ); + } + + late final _maps_view_set_type_ptr = + _lookup>('maps_view_set_type'); + late final _dart_maps_view_set_type _maps_view_set_type = + _maps_view_set_type_ptr.asFunction<_dart_maps_view_set_type>(); + + /// @brief Gets View type. + /// @details This function gets the type of the given View.\n + /// The type options are defined in the #maps_view_type_e enumeration. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[out] type The pointer to a #maps_view_type_e in which to store current view type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see #maps_view_type_e + /// @see maps_view_set_type() + /// @see maps_view_get_language() + /// @see maps_view_create() + int maps_view_get_type( + ffi.Pointer view, + ffi.Pointer type, + ) { + return _maps_view_get_type( + view, + type, + ); + } + + late final _maps_view_get_type_ptr = + _lookup>('maps_view_get_type'); + late final _dart_maps_view_get_type _maps_view_get_type = + _maps_view_get_type_ptr.asFunction<_dart_maps_view_get_type>(); + + /// @brief Indicates whether the map should show the 3D buildings layer. + /// @details This function is called to indicate whether 3D buildings should be shown as a layer on the map. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks To check if Maps Provider is capable of drawing 3D buildings, + /// use maps_service_provider_is_data_supported() with + /// #MAPS_VIEW_BUILDING passed as a service data parameter. + /// @param[in] view The view handle + /// @param[in] enable The enable status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network unavailable + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_create() + /// @see maps_view_get_buildings_enabled() + /// @see maps_service_provider_is_data_supported() + int maps_view_set_buildings_enabled( + ffi.Pointer view, + bool enable, + ) { + return _maps_view_set_buildings_enabled( + view, + enable ? 1 : 0, + ); + } + + late final _maps_view_set_buildings_enabled_ptr = + _lookup>( + 'maps_view_set_buildings_enabled'); + late final _dart_maps_view_set_buildings_enabled + _maps_view_set_buildings_enabled = _maps_view_set_buildings_enabled_ptr + .asFunction<_dart_maps_view_set_buildings_enabled>(); + + /// @brief Queries whether the map has the 3D buildings layer enabled. + /// @details This function checks whether the map is set to show the 3D buildings layer. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[out] enable The pointer to a boolean in which to store the enable status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_create() + /// @see maps_view_set_buildings_enabled() + /// @see maps_service_provider_is_data_supported() + int maps_view_get_buildings_enabled( + ffi.Pointer view, + ffi.Pointer enable, + ) { + return _maps_view_get_buildings_enabled( + view, + enable, + ); + } + + late final _maps_view_get_buildings_enabled_ptr = + _lookup>( + 'maps_view_get_buildings_enabled'); + late final _dart_maps_view_get_buildings_enabled + _maps_view_get_buildings_enabled = _maps_view_get_buildings_enabled_ptr + .asFunction<_dart_maps_view_get_buildings_enabled>(); + + /// @brief Indicates whether the map should show the traffic layer. + /// @details This function is called to indicate whether traffic conditions should be shown as a layer on the map. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks To check if Maps Provider is capable of drawing traffic conditions, + /// use maps_service_provider_is_data_supported() with + /// #MAPS_VIEW_TRAFFIC passed as a service data parameter. + /// @param[in] view The view handle + /// @param[in] enable The enable status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network unavailable + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_create() + /// @see maps_view_get_traffic_enabled() + /// @see maps_service_provider_is_data_supported() + int maps_view_set_traffic_enabled( + ffi.Pointer view, + bool enable, + ) { + return _maps_view_set_traffic_enabled( + view, + enable ? 1 : 0, + ); + } + + late final _maps_view_set_traffic_enabled_ptr = + _lookup>( + 'maps_view_set_traffic_enabled'); + late final _dart_maps_view_set_traffic_enabled + _maps_view_set_traffic_enabled = _maps_view_set_traffic_enabled_ptr + .asFunction<_dart_maps_view_set_traffic_enabled>(); + + /// @brief Queries whether the map has the traffic layer enabled. + /// @details This function checks whether the map is set to show the traffic layer. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[out] enable The pointer to a boolean in which to store the enable status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_create() + /// @see maps_view_set_traffic_enabled() + /// @see maps_service_provider_is_data_supported() + int maps_view_get_traffic_enabled( + ffi.Pointer view, + ffi.Pointer enable, + ) { + return _maps_view_get_traffic_enabled( + view, + enable, + ); + } + + late final _maps_view_get_traffic_enabled_ptr = + _lookup>( + 'maps_view_get_traffic_enabled'); + late final _dart_maps_view_get_traffic_enabled + _maps_view_get_traffic_enabled = _maps_view_get_traffic_enabled_ptr + .asFunction<_dart_maps_view_get_traffic_enabled>(); + + /// @brief Indicates whether the map should show the public transit layer. + /// @details This function is called to indicate whether public transit routes should be shown as a layer on the map. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks To check if Maps Provider is capable of drawing public transit routes, + /// use maps_service_provider_is_data_supported() with + /// #MAPS_VIEW_PUBLIC_TRANSIT passed as a service data parameter. + /// @param[in] view The view handle + /// @param[in] enable The enable status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network unavailable + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_create() + /// @see maps_view_get_public_transit_enabled() + /// @see maps_service_provider_is_data_supported() + int maps_view_set_public_transit_enabled( + ffi.Pointer view, + bool enable, + ) { + return _maps_view_set_public_transit_enabled( + view, + enable ? 1 : 0, + ); + } + + late final _maps_view_set_public_transit_enabled_ptr = + _lookup>( + 'maps_view_set_public_transit_enabled'); + late final _dart_maps_view_set_public_transit_enabled + _maps_view_set_public_transit_enabled = + _maps_view_set_public_transit_enabled_ptr + .asFunction<_dart_maps_view_set_public_transit_enabled>(); + + /// @brief Queries whether the map has the public transit layer enabled. + /// @details This function checks whether the map is set to show the public transit routes layer. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[out] enable The pointer to a boolean in which to store the enable status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_create() + /// @see maps_view_set_public_transit_enabled() + /// @see maps_service_provider_is_data_supported() + int maps_view_get_public_transit_enabled( + ffi.Pointer view, + ffi.Pointer enable, + ) { + return _maps_view_get_public_transit_enabled( + view, + enable, + ); + } + + late final _maps_view_get_public_transit_enabled_ptr = + _lookup>( + 'maps_view_get_public_transit_enabled'); + late final _dart_maps_view_get_public_transit_enabled + _maps_view_get_public_transit_enabled = + _maps_view_get_public_transit_enabled_ptr + .asFunction<_dart_maps_view_get_public_transit_enabled>(); + + /// @brief Sets View language. + /// @details This function sets the language to the given View.\n + /// Note that map display language is different from places and route language. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks If specific language wasn't set explicitly or map tile doesn't support the requested language, + /// the default language of your Maps Provider is used.\n + /// In general, Map Provider set the default language as the mother tongue of the country or English. + /// @param[in] view The view handle + /// @param[in] language The display language in the map. + /// A language is specified as an ISO 3166 alpha-2 two letter country-code + /// followed by ISO 639-1 for the two-letter language code. + /// Each language tag is composed of one or more "subtags" separated by hyphens (-). + /// Each subtag is composed of basic Latin letters or digits only. + /// For example, "ko-KR" for Korean, "en-US" for American English + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network unavailable + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_get_language() + /// @see maps_view_set_type() + /// @see maps_view_create() + int maps_view_set_language( + ffi.Pointer view, + ffi.Pointer language, + ) { + return _maps_view_set_language( + view, + language, + ); + } + + late final _maps_view_set_language_ptr = + _lookup>( + 'maps_view_set_language'); + late final _dart_maps_view_set_language _maps_view_set_language = + _maps_view_set_language_ptr.asFunction<_dart_maps_view_set_language>(); + + /// @brief Gets View language. + /// @details This function gets the language set to the View.\n + /// Note that map display language is different from places and route language. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The @a language should be freed using free(). + /// @param[in] view The view handle + /// @param[out] language The pointer to a char* in which to store the language string value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_set_language() + /// @see maps_view_get_type() + /// @see maps_view_create() + int maps_view_get_language( + ffi.Pointer view, + ffi.Pointer> language, + ) { + return _maps_view_get_language( + view, + language, + ); + } + + late final _maps_view_get_language_ptr = + _lookup>( + 'maps_view_get_language'); + late final _dart_maps_view_get_language _maps_view_get_language = + _maps_view_get_language_ptr.asFunction<_dart_maps_view_get_language>(); + + /// @brief Enables or disables scalebar. + /// @details This function enables or disables scalebar. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @param[in] view The view handle + /// @param[in] enable The enable status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network unavailable + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_create() + /// @see maps_view_get_scalebar_enabled() + int maps_view_set_scalebar_enabled( + ffi.Pointer view, + bool enable, + ) { + return _maps_view_set_scalebar_enabled( + view, + enable ? 1 : 0, + ); + } + + late final _maps_view_set_scalebar_enabled_ptr = + _lookup>( + 'maps_view_set_scalebar_enabled'); + late final _dart_maps_view_set_scalebar_enabled + _maps_view_set_scalebar_enabled = _maps_view_set_scalebar_enabled_ptr + .asFunction<_dart_maps_view_set_scalebar_enabled>(); + + /// @brief Gets whether the scalebar is enabled or not. + /// @details This function gets whether the scalebar is enabled or not. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[out] enabled The pointer to a boolean in which to store the enable status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_create() + /// @see maps_view_set_scalebar_enabled() + int maps_view_get_scalebar_enabled( + ffi.Pointer view, + ffi.Pointer enabled, + ) { + return _maps_view_get_scalebar_enabled( + view, + enabled, + ); + } + + late final _maps_view_get_scalebar_enabled_ptr = + _lookup>( + 'maps_view_get_scalebar_enabled'); + late final _dart_maps_view_get_scalebar_enabled + _maps_view_get_scalebar_enabled = _maps_view_get_scalebar_enabled_ptr + .asFunction<_dart_maps_view_get_scalebar_enabled>(); + + /// @brief Gets the View port. + /// @details This function gets the View port as a pointer on Evas_Object. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[out] viewport The pointer to Evas_Object in which to store the View port + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_create() + /// @see Evas_Object + int maps_view_get_viewport( + ffi.Pointer view, + ffi.Pointer> viewport, + ) { + return _maps_view_get_viewport( + view, + viewport, + ); + } + + late final _maps_view_get_viewport_ptr = + _lookup>( + 'maps_view_get_viewport'); + late final _dart_maps_view_get_viewport _maps_view_get_viewport = + _maps_view_get_viewport_ptr.asFunction<_dart_maps_view_get_viewport>(); + + /// @brief Sets geometry of View port. + /// @details This function set the position and (rectangular) size of the given View.\n + /// The position, naturally, will be relative to the top left corner of the parent window. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @param[in] view The view handle + /// @param[in] x X screen coordinate for the top left corner of View + /// @param[in] y Y screen coordinate for the top left corner of View + /// @param[in] width The new width of View in screen units + /// @param[in] height The new height of View in screen units + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network unavailable + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_get_screen_location() + /// @see maps_view_resize() + /// @see maps_view_set_visibility() + /// @see maps_view_create() + int maps_view_set_screen_location( + ffi.Pointer view, + int x, + int y, + int width, + int height, + ) { + return _maps_view_set_screen_location( + view, + x, + y, + width, + height, + ); + } + + late final _maps_view_set_screen_location_ptr = + _lookup>( + 'maps_view_set_screen_location'); + late final _dart_maps_view_set_screen_location + _maps_view_set_screen_location = _maps_view_set_screen_location_ptr + .asFunction<_dart_maps_view_set_screen_location>(); + + /// @brief Gets geometry of View port. + /// @details This function retrieves the position and (rectangular) size of the given View.\n + /// The position, naturally, will be relative to the top left corner of the parent window. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks Use NULL pointers on the geometry components you're not interested in. + /// @param[in] view The view handle + /// @param[out] x X screen coordinate for the top left corner of View + /// @param[out] y Y screen coordinate for the left top corner of View + /// @param[out] width The pointer to an integer in which to store the width of the view + /// @param[out] height The pointer to an integer in which to store the height of the view + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_set_screen_location() + /// @see maps_view_resize() + /// @see maps_view_get_visibility() + /// @see maps_view_create() + int maps_view_get_screen_location( + ffi.Pointer view, + ffi.Pointer x, + ffi.Pointer y, + ffi.Pointer width, + ffi.Pointer height, + ) { + return _maps_view_get_screen_location( + view, + x, + y, + width, + height, + ); + } + + late final _maps_view_get_screen_location_ptr = + _lookup>( + 'maps_view_get_screen_location'); + late final _dart_maps_view_get_screen_location + _maps_view_get_screen_location = _maps_view_get_screen_location_ptr + .asFunction<_dart_maps_view_get_screen_location>(); + + /// @brief Moves the View. + /// @details This function moves View. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks Newly created View port has the size of its parent. + /// @param[in] view The view handle + /// @param[in] x The new x position, in screen units + /// @param[in] y The new y position, in screen units + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_set_screen_location() + /// @see maps_view_get_screen_location() + /// @see maps_view_set_visibility() + /// @see maps_view_create() + int maps_view_move( + ffi.Pointer view, + int x, + int y, + ) { + return _maps_view_move( + view, + x, + y, + ); + } + + late final _maps_view_move_ptr = + _lookup>('maps_view_move'); + late final _dart_maps_view_move _maps_view_move = + _maps_view_move_ptr.asFunction<_dart_maps_view_move>(); + + /// @brief Resizes the View. + /// @details This function changes the size of the given View. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks Newly created View port has the size of its parent. + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @param[in] view The view handle + /// @param[in] width The new new width in screen units + /// @param[in] height The new new height in screen units + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network unavailable + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_set_screen_location() + /// @see maps_view_get_screen_location() + /// @see maps_view_set_visibility() + /// @see maps_view_create() + int maps_view_resize( + ffi.Pointer view, + int width, + int height, + ) { + return _maps_view_resize( + view, + width, + height, + ); + } + + late final _maps_view_resize_ptr = + _lookup>('maps_view_resize'); + late final _dart_maps_view_resize _maps_view_resize = + _maps_view_resize_ptr.asFunction<_dart_maps_view_resize>(); + + /// @brief Shows or hides the View. + /// @details This function changes the visibility of View on the screen. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[in] visible The new visibility of the View + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_get_visibility() + /// @see maps_view_set_screen_location() + /// @see maps_view_create() + int maps_view_set_visibility( + ffi.Pointer view, + bool visible, + ) { + return _maps_view_set_visibility( + view, + visible ? 1 : 0, + ); + } + + late final _maps_view_set_visibility_ptr = + _lookup>( + 'maps_view_set_visibility'); + late final _dart_maps_view_set_visibility _maps_view_set_visibility = + _maps_view_set_visibility_ptr + .asFunction<_dart_maps_view_set_visibility>(); + + /// @brief Gets the View visibility. + /// @details This function retrieves whether or not the given View is visible. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[out] visible The pointer to a boolean in which to store the visibility of the View + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_set_visibility() + /// @see maps_view_set_screen_location() + /// @see maps_view_create() + int maps_view_get_visibility( + ffi.Pointer view, + ffi.Pointer visible, + ) { + return _maps_view_get_visibility( + view, + visible, + ); + } + + late final _maps_view_get_visibility_ptr = + _lookup>( + 'maps_view_get_visibility'); + late final _dart_maps_view_get_visibility _maps_view_get_visibility = + _maps_view_get_visibility_ptr + .asFunction<_dart_maps_view_get_visibility>(); + + /// @brief Sets the event callback. + /// @details This function sets the callback which will be invoked every time the View processes the user's gesture, action and objects over the map. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks To unregister the callback use maps_view_unset_event_cb(). + /// @param[in] view The view handle + /// @param[in] type The event type + /// @param[in] callback The callback, matching the maps_view_on_event_cb() prototype + /// @param[in] user_data The user data pointer to be passed to the callback + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see maps_view_unset_event_cb() + /// @see maps_view_on_event_cb() + /// @see maps_view_set_gesture_enabled() + /// @see maps_view_create() + int maps_view_set_event_cb( + ffi.Pointer view, + int type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_view_set_event_cb( + view, + type, + callback, + user_data, + ); + } + + late final _maps_view_set_event_cb_ptr = + _lookup>( + 'maps_view_set_event_cb'); + late final _dart_maps_view_set_event_cb _maps_view_set_event_cb = + _maps_view_set_event_cb_ptr.asFunction<_dart_maps_view_set_event_cb>(); + + /// @brief Unsets the event callback. + /// @details This function unsets the event callback. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[in] type The event type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @pre the event callback is registered using maps_view_set_event_cb() + /// @see maps_view_set_event_cb() + /// @see maps_view_get_gesture_enabled() + /// @see maps_view_create() + int maps_view_unset_event_cb( + ffi.Pointer view, + int type, + ) { + return _maps_view_unset_event_cb( + view, + type, + ); + } + + late final _maps_view_unset_event_cb_ptr = + _lookup>( + 'maps_view_unset_event_cb'); + late final _dart_maps_view_unset_event_cb _maps_view_unset_event_cb = + _maps_view_unset_event_cb_ptr + .asFunction<_dart_maps_view_unset_event_cb>(); + + /// @brief Enables or disables the map gesture. + /// @details This function enables or disables the map gesture. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[in] gesture The user gesture, one of listed in #maps_view_gesture_e + /// @param[in] enabled The enable status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @see #maps_view_gesture_e + /// @see maps_view_get_gesture_enabled() + /// @see maps_view_create() + int maps_view_set_gesture_enabled( + ffi.Pointer view, + int gesture, + bool enabled, + ) { + return _maps_view_set_gesture_enabled( + view, + gesture, + enabled ? 1 : 0, + ); + } + + late final _maps_view_set_gesture_enabled_ptr = + _lookup>( + 'maps_view_set_gesture_enabled'); + late final _dart_maps_view_set_gesture_enabled + _maps_view_set_gesture_enabled = _maps_view_set_gesture_enabled_ptr + .asFunction<_dart_maps_view_set_gesture_enabled>(); + + /// @brief Checks whether the map gesture is enabled or not. + /// @details This function checks whether the map gesture is enabled or not. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] view The view handle + /// @param[in] gesture The user gesture, one of listed in #maps_view_gesture_e + /// @param[out] enabled The pointer to a boolean in which to store the enable status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @pre @a enabled status set ad default or modified using + /// maps_view_set_gesture_enabled(). + /// @see #maps_view_gesture_e + /// @see maps_view_set_gesture_enabled() + /// @see maps_view_create() + int maps_view_get_gesture_enabled( + ffi.Pointer view, + int gesture, + ffi.Pointer enabled, + ) { + return _maps_view_get_gesture_enabled( + view, + gesture, + enabled, + ); + } + + late final _maps_view_get_gesture_enabled_ptr = + _lookup>( + 'maps_view_get_gesture_enabled'); + late final _dart_maps_view_get_gesture_enabled + _maps_view_get_gesture_enabled = _maps_view_get_gesture_enabled_ptr + .asFunction<_dart_maps_view_get_gesture_enabled>(); + + /// @brief Adds a visual object on the map. + /// @details This function adds a visual object on the map. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice + /// @remarks The @a object handle will be released automatically when the view is destroyed in the maps_view_destroy(). + /// @param[in] view The view handle + /// @param[in] object The handle of the object to add + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @pre @a object is created using #maps_view_object_create_marker(), maps_view_object_create_polygon(), + /// maps_view_object_create_polyline() or maps_view_object_create_group(). + /// @see #maps_view_object_h + /// @see maps_view_object_create_marker() + /// @see maps_view_object_create_polygon() + /// @see maps_view_object_create_polyline() + /// @see maps_view_remove_object() + /// @see maps_view_remove_all_objects() + /// @see maps_view_create() + int maps_view_add_object( + ffi.Pointer view, + ffi.Pointer object, + ) { + return _maps_view_add_object( + view, + object, + ); + } + + late final _maps_view_add_object_ptr = + _lookup>( + 'maps_view_add_object'); + late final _dart_maps_view_add_object _maps_view_add_object = + _maps_view_add_object_ptr.asFunction<_dart_maps_view_add_object>(); + + /// @brief Removes a visual object from the map. + /// @details This function removes a visual object from the map. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice + /// @remarks The @a object handle will be released automatically by the View. + /// @param[in] view The view handle + /// @param[in] object The object to remove + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @pre @a object is added using maps_view_add_object(). + /// @see maps_view_add_object() + /// @see maps_view_remove_all_objects() + /// @see #maps_view_object_h + /// @see maps_view_create() + int maps_view_remove_object( + ffi.Pointer view, + ffi.Pointer object, + ) { + return _maps_view_remove_object( + view, + object, + ); + } + + late final _maps_view_remove_object_ptr = + _lookup>( + 'maps_view_remove_object'); + late final _dart_maps_view_remove_object _maps_view_remove_object = + _maps_view_remove_object_ptr.asFunction<_dart_maps_view_remove_object>(); + + /// @brief Removes all visual objects from the map. + /// @details This function removes all visual object from the map. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice + /// @remarks All object handles will be released automatically by the View. + /// @param[in] view The view handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @pre objects are added using maps_view_add_object(). + /// @see #maps_view_object_h + /// @see maps_view_add_object() + /// @see maps_view_remove_all_objects() + /// @see maps_view_create() + int maps_view_remove_all_objects( + ffi.Pointer view, + ) { + return _maps_view_remove_all_objects( + view, + ); + } + + late final _maps_view_remove_all_objects_ptr = + _lookup>( + 'maps_view_remove_all_objects'); + late final _dart_maps_view_remove_all_objects _maps_view_remove_all_objects = + _maps_view_remove_all_objects_ptr + .asFunction<_dart_maps_view_remove_all_objects>(); + + /// @brief Retrieves all visual objects on the map. + /// @details This function retrieves all visual objects previously added to the map. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The objects will be delivered via maps_view_object_cb(). + /// @param[in] view The view handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data pointer to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre @a view is created using maps_view_create(). + /// @pre objects are added using maps_view_add_object(). + /// @post This function invokes maps_view_object_cb() repeatedly to retrieve each visual object. + /// @see #maps_view_object_h + /// @see maps_view_object_cb() + /// @see maps_view_add_object() + /// @see maps_view_remove_object() + /// @see maps_view_remove_all_objects() + /// @see maps_view_create() + int maps_view_foreach_object( + ffi.Pointer view, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_view_foreach_object( + view, + callback, + user_data, + ); + } + + late final _maps_view_foreach_object_ptr = + _lookup>( + 'maps_view_foreach_object'); + late final _dart_maps_view_foreach_object _maps_view_foreach_object = + _maps_view_foreach_object_ptr + .asFunction<_dart_maps_view_foreach_object>(); + + /// @brief Gets available Maps Providers. + /// @details This function delivers available Maps Providers via maps_service_provider_info_cb() callback. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] callback The callback function to receive available Maps Providers information + /// @param[out] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes maps_service_provider_info_cb() to deliver Maps Provider information. + /// @see maps_service_provider_info_cb() + /// @see maps_service_create() + int maps_service_foreach_provider( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _maps_service_foreach_provider( + callback, + user_data, + ); + } + + late final _maps_service_foreach_provider_ptr = + _lookup>( + 'maps_service_foreach_provider'); + late final _dart_maps_service_foreach_provider + _maps_service_foreach_provider = _maps_service_foreach_provider_ptr + .asFunction<_dart_maps_service_foreach_provider>(); + + /// @brief Gets the user's consent to use maps data. + /// @details The function gets information whether the user agreed that the application can use maps data. + /// If maps_service_request_user_consent() is called when the user didn't agree yet, a popup is shown and + /// the user can decide whether to agree or not. Then the result is saved and maps_service_request_user_consent_cb() + /// is called. If the user has already agreed, the popup is not shown and only the callback is called. + /// The request is asynchronous. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice + /// @remarks Available map providers can be obtained with maps_service_foreach_provider(). + /// @param[in] maps_provider The name of Maps Provider + /// @param[in] callback The callback which receives the user's consent decision + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @post This function invokes maps_service_request_user_consent_cb() to provide information about user consent. + /// @see maps_service_foreach_provider() + /// @see maps_service_request_user_consent_cb() + /// @see maps_service_create() + int maps_service_request_user_consent( + ffi.Pointer maps_provider, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _maps_service_request_user_consent( + maps_provider, + callback, + user_data, + ); + } + + late final _maps_service_request_user_consent_ptr = + _lookup>( + 'maps_service_request_user_consent'); + late final _dart_maps_service_request_user_consent + _maps_service_request_user_consent = + _maps_service_request_user_consent_ptr + .asFunction<_dart_maps_service_request_user_consent>(); + + /// @brief Creates a new Maps Service and assigns it with a handle. + /// @details While Maps Service is being created, a Maps Provider is initialized and linked with Maps Service handle. + /// A Maps Service handle is used to query Maps Provider performing services, such as Geocoding, Searching Places, and Routing. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/network.get + /// @remarks @a maps service handle must be released using maps_service_destroy().\n + /// Use maps_service_foreach_provider() to choose one of available Providers.\n + /// Use maps_service_set_provider_key() to set provider's key.\n + /// Use maps_service_set_preference() to set various options of Maps Provider.\n + /// Use maps_service_provider_is_service_supported() and + /// maps_service_provider_is_data_supported() to check the Maps Provider's capabilities. + /// @param[in] maps_provider The name of Maps Provider + /// @param[out] maps A handle of the new Maps Service on success + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_USER_NOT_CONSENTED The user did not consent + /// @pre Call maps_service_foreach_provider() to get a available Maps Providers. + /// @see maps_service_foreach_provider() + /// @see maps_service_destroy() + /// @see maps_service_geocode() + /// @see maps_service_geocode_inside_area() + /// @see maps_service_reverse_geocode() + /// @see maps_service_search_place() + /// @see maps_service_search_place_by_area() + /// @see maps_service_search_place_by_address() + /// @see maps_service_search_route() + /// @see maps_service_search_route_waypoints() + /// @see maps_service_set_provider_key() + /// @see maps_service_set_preference() + /// @see maps_service_provider_is_service_supported() + /// @see maps_service_provider_is_data_supported() + int maps_service_create( + ffi.Pointer maps_provider, + ffi.Pointer> maps, + ) { + return _maps_service_create( + maps_provider, + maps, + ); + } + + late final _maps_service_create_ptr = + _lookup>( + 'maps_service_create'); + late final _dart_maps_service_create _maps_service_create = + _maps_service_create_ptr.asFunction<_dart_maps_service_create>(); + + /// @brief Destroys the Maps Service handle and releases all its resources. + /// @details This function releases all used resources of the Maps Service and Maps Provider. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice + /// @param[in] maps The Maps Service handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @pre Call maps_service_create() to create Maps Service and get its handle. + /// @see maps_service_create() + int maps_service_destroy( + ffi.Pointer maps, + ) { + return _maps_service_destroy( + maps, + ); + } + + late final _maps_service_destroy_ptr = + _lookup>( + 'maps_service_destroy'); + late final _dart_maps_service_destroy _maps_service_destroy = + _maps_service_destroy_ptr.asFunction<_dart_maps_service_destroy>(); + + /// @brief Sets the Maps Key to be used in the requests of Maps Service. + /// @details This function sets the Maps Provider's Key which will be used in each Maps Service request to Maps Provider.\n + /// Maps Key can be obtained with maps_service_get_provider_key(). + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks To get the @a provider_key, refer to corresponding Maps Provider documentation.\n + /// To get app_id and app_code of HERE, visit + /// https://developer.here.com/, + /// https://developer.here.com/rest-apis. + /// @param[in] maps The Maps Service handle + /// @param[in] provider_key The Maps Key to be used.\n + /// In case of combining two more strings, use slash("/") as a delimiter.\n + /// e.g. For HERE "app_id/app_code" + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre Call maps_service_create() to create Maps Service and get its handle. + /// @see maps_service_create() + /// @see maps_service_get_provider_key() + int maps_service_set_provider_key( + ffi.Pointer maps, + ffi.Pointer provider_key, + ) { + return _maps_service_set_provider_key( + maps, + provider_key, + ); + } + + late final _maps_service_set_provider_key_ptr = + _lookup>( + 'maps_service_set_provider_key'); + late final _dart_maps_service_set_provider_key + _maps_service_set_provider_key = _maps_service_set_provider_key_ptr + .asFunction<_dart_maps_service_set_provider_key>(); + + /// @brief Gets the Maps Key which is to be used in the Maps Service requests + /// @details This function gets the Maps Key which is to be used in each Maps Service request to Maps Provider.\n + /// Maps Key can be set with maps_service_set_provider_key(). + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The string @a provider_key must be released using free().\n + /// @a maps_service_get_provider_key is always synchronous function. + /// @param[in] maps The Maps Service handle + /// @param[out] provider_key The Maps Key + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre Call maps_service_create() to create Maps Service and get its handle. + /// @see maps_service_set_provider_key() + /// @see maps_service_create() + int maps_service_get_provider_key( + ffi.Pointer maps, + ffi.Pointer> provider_key, + ) { + return _maps_service_get_provider_key( + maps, + provider_key, + ); + } + + late final _maps_service_get_provider_key_ptr = + _lookup>( + 'maps_service_get_provider_key'); + late final _dart_maps_service_get_provider_key + _maps_service_get_provider_key = _maps_service_get_provider_key_ptr + .asFunction<_dart_maps_service_get_provider_key>(); + + /// @brief Sets the Maps Preference. + /// @details This function sets the Maps Preferences which are used in each Maps Service request to Maps Provider. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @param[in] maps The handle of Maps Service + /// @param[in] preference The handle of Maps Preference + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @pre Call maps_service_create() to create Maps Service and get its handle. + /// @see maps_service_get_preference() + /// @see maps_service_create() + int maps_service_set_preference( + ffi.Pointer maps, + ffi.Pointer preference, + ) { + return _maps_service_set_preference( + maps, + preference, + ); + } + + late final _maps_service_set_preference_ptr = + _lookup>( + 'maps_service_set_preference'); + late final _dart_maps_service_set_preference _maps_service_set_preference = + _maps_service_set_preference_ptr + .asFunction<_dart_maps_service_set_preference>(); + + /// @brief Gets the Maps Preference. + /// @details This function gets the Maps Preferences which are used in each Maps Service request to Maps Provider.\n + /// Preferences can be set with maps_service_set_preference(). + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a preference must be released using maps_preference_destroy().\n + /// @a maps_service_get_preference is always synchronous function. + /// @param[in] maps The handle of Maps Service + /// @param[out] preference The handle of Maps Preference + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre Call maps_service_create() to create Maps Service and get its handle. + /// @see maps_service_set_preference() + /// @see maps_service_create() + int maps_service_get_preference( + ffi.Pointer maps, + ffi.Pointer> preference, + ) { + return _maps_service_get_preference( + maps, + preference, + ); + } + + late final _maps_service_get_preference_ptr = + _lookup>( + 'maps_service_get_preference'); + late final _dart_maps_service_get_preference _maps_service_get_preference = + _maps_service_get_preference_ptr + .asFunction<_dart_maps_service_get_preference>(); + + /// @brief Checks if the Maps Service supports a request. + /// @details This function checks if the Maps Service supports a specified request. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a maps_service_provider_is_service_supported is always synchronous function. + /// @param[in] maps The handle of Maps Service + /// @param[in] service The service to be checked + /// @param[out] supported Is the service supported + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre Call maps_service_create() to create Maps Service and get its handle. + /// @see maps_service_create() + int maps_service_provider_is_service_supported( + ffi.Pointer maps, + int service, + ffi.Pointer supported, + ) { + return _maps_service_provider_is_service_supported( + maps, + service, + supported, + ); + } + + late final _maps_service_provider_is_service_supported_ptr = _lookup< + ffi.NativeFunction<_c_maps_service_provider_is_service_supported>>( + 'maps_service_provider_is_service_supported'); + late final _dart_maps_service_provider_is_service_supported + _maps_service_provider_is_service_supported = + _maps_service_provider_is_service_supported_ptr + .asFunction<_dart_maps_service_provider_is_service_supported>(); + + /// @brief Checks if the Maps Service supports a data feature. + /// @details This function checks if the Maps Service supports a specified data feature. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks @a maps_service_provider_is_data_supported is always a synchronous function. + /// @param[in] maps The handle of Maps Service + /// @param[in] data The data feature to be checked + /// @param[out] supported Is the data feature supported + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @pre Call maps_service_create() to create Maps Service and get its handle. + /// @see maps_service_create() + int maps_service_provider_is_data_supported( + ffi.Pointer maps, + int data, + ffi.Pointer supported, + ) { + return _maps_service_provider_is_data_supported( + maps, + data, + supported, + ); + } + + late final _maps_service_provider_is_data_supported_ptr = + _lookup>( + 'maps_service_provider_is_data_supported'); + late final _dart_maps_service_provider_is_data_supported + _maps_service_provider_is_data_supported = + _maps_service_provider_is_data_supported_ptr + .asFunction<_dart_maps_service_provider_is_data_supported>(); + + /// @brief Cancels the service request. + /// @details This function cancels the service request initiated by geocoding and searching places and routes. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice + /// @param[in] maps The Maps Service handle + /// @param[in] request_id The ID of request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network connection failed + /// @retval #MAPS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_KEY_NOT_AVAILABLE Invalid key + /// @retval #MAPS_ERROR_UNKNOWN Unknown error + /// @pre @a request_id is obtained from one of followings: + /// - maps_service_geocode() + /// - maps_service_geocode_inside_area() + /// - maps_service_geocode_by_structured_address() + /// - maps_service_reverse_geocode() + /// - maps_service_search_place() + /// - maps_service_search_place_by_area() + /// - maps_service_search_place_by_address() + /// - maps_service_search_route() + /// - maps_service_search_route_waypoints() + /// @pre Call maps_service_create() to create Maps Service and get its handle. + /// @see maps_service_geocode() + /// @see maps_service_geocode_inside_area() + /// @see maps_service_geocode_by_structured_address() + /// @see maps_service_reverse_geocode() + /// @see maps_service_search_place() + /// @see maps_service_search_place_by_area() + /// @see maps_service_search_place_by_address() + /// @see maps_service_search_route() + /// @see maps_service_search_route_waypoints() + int maps_service_cancel_request( + ffi.Pointer maps, + int request_id, + ) { + return _maps_service_cancel_request( + maps, + request_id, + ); + } + + late final _maps_service_cancel_request_ptr = + _lookup>( + 'maps_service_cancel_request'); + late final _dart_maps_service_cancel_request _maps_service_cancel_request = + _maps_service_cancel_request_ptr + .asFunction<_dart_maps_service_cancel_request>(); + + /// @brief Gets the position coordinates for a given address.\n + /// The request is asynchronous. + /// @details This function obtains position coordinates for a given free-formed address string. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks To cancel the request, use maps_service_cancel_request().\n + /// To check if Maps Provider is capable of geocoding, + /// use maps_service_provider_is_service_supported() with + /// #MAPS_SERVICE_GEOCODE passed as @a service parameter. + /// @param[in] maps The Maps Service handle + /// @param[in] address The free-formed address + /// @param[in] preference The set of preferences for processing geocoding + /// @param[in] callback The callback which will receive position coordinates + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] request_id The ID of request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network connection failed + /// @retval #MAPS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_KEY_NOT_AVAILABLE Invalid key + /// @retval #MAPS_ERROR_UNKNOWN Unknown error + /// @pre Call maps_service_create() to create Maps Service and obtain its handle. + /// @post It invokes maps_service_geocode_cb() to deliver obtained position coordinates. + /// @see maps_service_geocode_inside_area() + /// @see maps_service_geocode_cb() + /// @see maps_service_cancel_request() + /// @see maps_service_reverse_geocode() + /// @see maps_service_provider_is_service_supported() + int maps_service_geocode( + ffi.Pointer maps, + ffi.Pointer address, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, + ) { + return _maps_service_geocode( + maps, + address, + preference, + callback, + user_data, + request_id, + ); + } + + late final _maps_service_geocode_ptr = + _lookup>( + 'maps_service_geocode'); + late final _dart_maps_service_geocode _maps_service_geocode = + _maps_service_geocode_ptr.asFunction<_dart_maps_service_geocode>(); + + /// @brief Gets the position for a given address within the specified bounding box.\n + /// The request is asynchronous. + /// @details This function obtains position coordinates for a given free-formed address string within the specified bounding box. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks Polygonal bounding box is not supported.\n + /// To cancel the request, use maps_service_cancel_request().\n + /// To check if Maps Provider is capable of geocoding inside area, + /// use maps_service_provider_is_service_supported() with + /// #MAPS_SERVICE_GEOCODE_INSIDE_AREA passed as @a service parameter. + /// @param[in] maps The Maps Service handle + /// @param[in] address The free-formed address + /// @param[in] bounds The bounding box + /// @param[in] preference The set of preferences for processing geocoding + /// @param[in] callback The callback which will receive position coordinates + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] request_id The ID of request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network connection failed + /// @retval #MAPS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_KEY_NOT_AVAILABLE Invalid key + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_KEY_NOT_AVAILABLE Invalid key + /// @retval #MAPS_ERROR_UNKNOWN Unknown error + /// @pre Call maps_service_create() to create Maps Service and obtain its handle. + /// @post It invokes maps_service_geocode_cb() to deliver obtained position coordinates. + /// @see maps_service_geocode_by_structured_address() + /// @see maps_service_geocode_inside_area() + /// @see maps_service_geocode_cb() + /// @see maps_service_geocode() + /// @see maps_service_cancel_request() + /// @see maps_service_reverse_geocode() + /// @see maps_service_provider_is_service_supported() + int maps_service_geocode_inside_area( + ffi.Pointer maps, + ffi.Pointer address, + ffi.Pointer bounds, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, + ) { + return _maps_service_geocode_inside_area( + maps, + address, + bounds, + preference, + callback, + user_data, + request_id, + ); + } + + late final _maps_service_geocode_inside_area_ptr = + _lookup>( + 'maps_service_geocode_inside_area'); + late final _dart_maps_service_geocode_inside_area + _maps_service_geocode_inside_area = _maps_service_geocode_inside_area_ptr + .asFunction<_dart_maps_service_geocode_inside_area>(); + + /// @brief Gets the position coordinates for a given address.\n + /// The request is asynchronous. + /// @details This function obtains position coordinates for a given structured address. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks To cancel the request, use maps_service_cancel_request().\n + /// To check if Maps Provider is capable of geocoding by structured address, + /// use maps_service_provider_is_service_supported() with + /// #MAPS_SERVICE_GEOCODE_BY_STRUCTURED_ADDRESS passed as @a service parameter. + /// @param[in] maps The Maps Service handle + /// @param[in] address The structured address + /// @param[in] preference The set of preferences for processing geocoding + /// @param[in] callback The callback which will receive position coordinates + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] request_id The ID of request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network connection failed + /// @retval #MAPS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_KEY_NOT_AVAILABLE Invalid key + /// @retval #MAPS_ERROR_UNKNOWN Unknown error + /// @pre Call maps_service_create() to create Maps Service and obtain its handle. + /// @post It invokes maps_service_geocode_cb() to deliver obtained position coordinates. + /// @see maps_service_geocode() + /// @see maps_service_geocode_inside_area() + /// @see maps_service_geocode_cb() + /// @see maps_service_cancel_request() + /// @see maps_service_reverse_geocode() + /// @see maps_service_provider_is_service_supported() + int maps_service_geocode_by_structured_address( + ffi.Pointer maps, + ffi.Pointer address, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, + ) { + return _maps_service_geocode_by_structured_address( + maps, + address, + preference, + callback, + user_data, + request_id, + ); + } + + late final _maps_service_geocode_by_structured_address_ptr = _lookup< + ffi.NativeFunction<_c_maps_service_geocode_by_structured_address>>( + 'maps_service_geocode_by_structured_address'); + late final _dart_maps_service_geocode_by_structured_address + _maps_service_geocode_by_structured_address = + _maps_service_geocode_by_structured_address_ptr + .asFunction<_dart_maps_service_geocode_by_structured_address>(); + + /// @brief Gets the address for a given position coordinates.\n + /// The request is asynchronous. + /// @details This function obtains structured address information for a given position coordinates. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks To cancel the request, use maps_service_cancel_request().\n + /// To check if Maps Provider is capable of reverse geocoding, + /// use maps_service_provider_is_service_supported() with + /// #MAPS_SERVICE_REVERSE_GEOCODE passed as @a service parameter. + /// @param[in] maps The Maps Service handle + /// @param[in] latitude The latitude [-90.0 ~ 90.0] (degrees) + /// @param[in] longitude The longitude [-180.0 ~ 180.0] (degrees) + /// @param[in] preference The set of preferences for processing reverse geocoding + /// @param[in] callback The callback which will receive address information + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] request_id The ID of request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network connection failed + /// @retval #MAPS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_KEY_NOT_AVAILABLE Invalid key + /// @retval #MAPS_ERROR_UNKNOWN Unknown error + /// @pre Call maps_service_create() to create Maps Service and obtain its handle. + /// @post This function invokes maps_service_reverse_geocode_cb(). + /// @see maps_service_reverse_geocode_cb() + /// @see maps_service_cancel_request() + /// @see maps_service_geocode() + /// @see maps_service_provider_is_service_supported() + int maps_service_reverse_geocode( + ffi.Pointer maps, + double latitude, + double longitude, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, + ) { + return _maps_service_reverse_geocode( + maps, + latitude, + longitude, + preference, + callback, + user_data, + request_id, + ); + } + + late final _maps_service_reverse_geocode_ptr = + _lookup>( + 'maps_service_reverse_geocode'); + late final _dart_maps_service_reverse_geocode _maps_service_reverse_geocode = + _maps_service_reverse_geocode_ptr + .asFunction<_dart_maps_service_reverse_geocode>(); + + /// @brief Gets the address list for a given position coordinates list.\n + /// The request is asynchronous. + /// @details This function obtains structured address information. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks To cancel the request, use maps_service_cancel_request().\n + /// To check if Maps Provider is capable of multi reverse geocoding, + /// use maps_service_provider_is_service_supported() with + /// #MAPS_SERVICE_MULTI_REVERSE_GEOCODE passed as @a service parameter. + /// @param[in] maps The Maps Service handle + /// @param[in] coordinates_list The coordinates list [2 ~ 100] (a set of coordinates) + /// @param[in] preference The set of preferences for processing Reverse Geocode + /// @param[in] callback The callback which will retrieve address list + /// @param[in] user_data The user data pointer to be passed to the callback + /// @param[out] request_id The ID of request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NETWORK_UNREACHABLE Network connection failed + /// @retval #MAPS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_KEY_NOT_AVAILABLE Invalid key + /// @retval #MAPS_ERROR_UNKNOWN Unknown error + /// @pre Call maps_service_create() to create Maps Service and obtain its handle. + /// @post This function invokes maps_service_multi_reverse_geocode_cb(). + /// @see maps_service_multi_reverse_geocode_cb() + /// @see maps_service_cancel_request() + /// @see maps_service_reverse_geocode() + /// @see maps_service_provider_is_service_supported() + int maps_service_multi_reverse_geocode( + ffi.Pointer maps, + ffi.Pointer coordinates_list, + ffi.Pointer preference, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ffi.Pointer request_id, + ) { + return _maps_service_multi_reverse_geocode( + maps, + coordinates_list, + preference, + callback, + user_data, + request_id, + ); + } + + late final _maps_service_multi_reverse_geocode_ptr = + _lookup>( + 'maps_service_multi_reverse_geocode'); + late final _dart_maps_service_multi_reverse_geocode + _maps_service_multi_reverse_geocode = + _maps_service_multi_reverse_geocode_ptr + .asFunction<_dart_maps_service_multi_reverse_geocode>(); + + /// @brief Queries a Place information by a coordinates position and a distance.\n + /// The request is asynchronous. + /// @details This function obtains the Place information for a specified distance around a given coordinates position. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks To cancel the search request, use maps_service_cancel_request().\n + /// To check if Maps Provider is capable of searching places, use + /// maps_service_provider_is_service_supported() with + /// #MAPS_SERVICE_SEARCH_PLACE passed as @a service parameter.\n + /// Check available data features in the search result using + /// maps_service_provider_is_data_supported() with values, listed in + /// #maps_service_data_e passed as @a data parameter. + /// @param[in] maps The Maps Service handle + /// @param[in] position The interested position + /// @param[in] distance The search area distance + /// @param[in] filter The filter handle + /// @param[in] preference The place preference handle + /// @param[in] callback The result callback + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] request_id The request ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_KEY_NOT_AVAILABLE Invalid key + /// @retval #MAPS_ERROR_RESOURCE_BUSY Places service busy + /// @retval #MAPS_ERROR_CANCELED Places service aborted + /// @retval #MAPS_ERROR_UNKNOWN Unknown error + /// @pre Call maps_service_create() to create Maps Service and obtain its handle. + /// @post It invokes maps_service_search_place_cb() to deliver obtained Place information. + /// @see maps_service_search_place_by_area() + /// @see maps_service_search_place_by_address() + /// @see maps_service_cancel_request() + /// @see maps_service_search_place_cb() + /// @see maps_service_provider_is_service_supported() + /// @see maps_service_provider_is_data_supported() + int maps_service_search_place( + ffi.Pointer maps, + ffi.Pointer position, + int distance, + ffi.Pointer filter, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, + ) { + return _maps_service_search_place( + maps, + position, + distance, + filter, + preference, + callback, + user_data, + request_id, + ); + } + + late final _maps_service_search_place_ptr = + _lookup>( + 'maps_service_search_place'); + late final _dart_maps_service_search_place _maps_service_search_place = + _maps_service_search_place_ptr + .asFunction<_dart_maps_service_search_place>(); + + /// @brief Queries a Place information by a coordinates boundary.\n + /// The request is asynchronous. + /// @details This function obtains the Place information for a specified coordinates boundary. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks @a boundary is supporting only circle type bounds for search.\n + /// To cancel the search request, use maps_service_cancel_request().\n + /// To check if Maps Provider is capable of searching places by coordinates + /// boundaries, use maps_service_provider_is_service_supported() with + /// #MAPS_SERVICE_SEARCH_PLACE_BY_AREA passed as @a service parameter.\n + /// Check available data features in the search result using + /// maps_service_provider_is_data_supported() with values, listed in + /// #maps_service_data_e passed as @a data parameter. + /// @param[in] maps The Maps Service handle + /// @param[in] boundary The interested area + /// @param[in] filter The filter handle + /// @param[in] preference The place preference handle + /// @param[in] callback The result callback + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] request_id The request ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_KEY_NOT_AVAILABLE Invalid key + /// @retval #MAPS_ERROR_RESOURCE_BUSY Places service busy + /// @retval #MAPS_ERROR_CANCELED Places service aborted + /// @retval #MAPS_ERROR_UNKNOWN Unknown error + /// @pre Call maps_service_create() to create Maps Service and obtain its handle. + /// @post It invokes maps_service_search_place_cb() to deliver obtained Place information. + /// @see maps_service_search_place() + /// @see maps_service_search_place_by_address() + /// @see maps_service_cancel_request() + /// @see maps_service_search_place_cb() + /// @see maps_service_provider_is_service_supported() + /// @see maps_service_provider_is_data_supported() + int maps_service_search_place_by_area( + ffi.Pointer maps, + ffi.Pointer boundary, + ffi.Pointer filter, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, + ) { + return _maps_service_search_place_by_area( + maps, + boundary, + filter, + preference, + callback, + user_data, + request_id, + ); + } + + late final _maps_service_search_place_by_area_ptr = + _lookup>( + 'maps_service_search_place_by_area'); + late final _dart_maps_service_search_place_by_area + _maps_service_search_place_by_area = + _maps_service_search_place_by_area_ptr + .asFunction<_dart_maps_service_search_place_by_area>(); + + /// @brief Queries a Place information by a free-formed address string.\n + /// The request is asynchronous. + /// @details This function obtains the Place information for a specified free-formed address string. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks @a boundary supports only circle type bounds for search.\n + /// To cancel the search request, use maps_service_cancel_request().\n + /// To check if Maps Provider is capable of searching places by free-formed + /// address, use maps_service_provider_is_service_supported() with + /// #MAPS_SERVICE_SEARCH_PLACE_BY_ADDRESS passed as @a service parameter.\n + /// Check available data features in the search result using + /// maps_service_provider_is_data_supported() with values, listed in + /// #maps_service_data_e passed as @a data parameter. + /// @param[in] maps The Maps Service handle + /// @param[in] address The interested address + /// @param[in] boundary The interested area + /// @param[in] filter The filter handle + /// @param[in] preference The place preference handle + /// @param[in] callback The result callback + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] request_id The request ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_KEY_NOT_AVAILABLE Invalid key + /// @retval #MAPS_ERROR_RESOURCE_BUSY Places service busy + /// @retval #MAPS_ERROR_CANCELED Places service aborted + /// @retval #MAPS_ERROR_UNKNOWN Unknown error + /// @pre Call maps_service_create() to create Maps Service and obtain its handle. + /// @post It invokes maps_service_search_place_cb() to deliver obtained Place information. + /// @see maps_service_search_place() + /// @see maps_service_search_place_by_area() + /// @see maps_service_cancel_request() + /// @see maps_service_search_place_cb() + /// @see maps_service_provider_is_service_supported() + /// @see maps_service_provider_is_data_supported() + int maps_service_search_place_by_address( + ffi.Pointer maps, + ffi.Pointer address, + ffi.Pointer boundary, + ffi.Pointer filter, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, + ) { + return _maps_service_search_place_by_address( + maps, + address, + boundary, + filter, + preference, + callback, + user_data, + request_id, + ); + } + + late final _maps_service_search_place_by_address_ptr = + _lookup>( + 'maps_service_search_place_by_address'); + late final _dart_maps_service_search_place_by_address + _maps_service_search_place_by_address = + _maps_service_search_place_by_address_ptr + .asFunction<_dart_maps_service_search_place_by_address>(); + + /// @brief Queries a brief Place information by a coordinates boundary./n + /// The request is asynchronous. + /// @details This function obtains the brief Place information for a specified coordinates boundary. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks To cancel the search request use maps_service_cancel_request().\n + /// To check if Maps Provider is capable of Place Search and which Place preferences are supported, + /// see the lists of capacities and preferences above. + /// @param[in] maps The Maps Service handle + /// @param[in] boundary The interested area + /// @param[in] filter The filter handle + /// @param[in] preference The place preference handle + /// @param[in] callback The result callback + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] request_id The request ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_KEY_NOT_AVAILABLE Invalid key + /// @retval #MAPS_ERROR_RESOURCE_BUSY Places service busy + /// @retval #MAPS_ERROR_CANCELED Places service aborted + /// @retval #MAPS_ERROR_UNKNOWN Unknown error + /// @pre Call maps_service_create() to create Maps Service and obtain its handle. + /// @post It invokes maps_service_search_place_list_cb() to deliver obtained Place information. + /// @see maps_service_get_place_details() + /// @see maps_service_search_place_list_cb() + /// @see maps_service_cancel_request() + /// @see maps_service_provider_is_service_supported() + int maps_service_search_place_list( + ffi.Pointer maps, + ffi.Pointer boundary, + ffi.Pointer filter, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, + ) { + return _maps_service_search_place_list( + maps, + boundary, + filter, + preference, + callback, + user_data, + request_id, + ); + } + + late final _maps_service_search_place_list_ptr = + _lookup>( + 'maps_service_search_place_list'); + late final _dart_maps_service_search_place_list + _maps_service_search_place_list = _maps_service_search_place_list_ptr + .asFunction<_dart_maps_service_search_place_list>(); + + /// @brief Queries a Detail Place information by a place uri.\n + /// The request is asynchronous. + /// @details This function obtains the Detail Place information for a specified place uri. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks To cancel the search request, use maps_service_cancel_request().\n + /// To check if Maps Provider is capable of Place Search and which Place preferences are supported, + /// see the lists of capacities and preferences above. + /// @param[in] maps The Maps Service handle + /// @param[in] uri The interested place uri + /// @param[in] callback The result callback + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] request_id The request ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_SERVICE_NOT_AVAILABLE Service not available + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_KEY_NOT_AVAILABLE Invalid key + /// @retval #MAPS_ERROR_RESOURCE_BUSY Places service busy + /// @retval #MAPS_ERROR_CANCELED Places service aborted + /// @retval #MAPS_ERROR_UNKNOWN Unknown error + /// @pre Call maps_service_create() to create Maps Service and obtain its handle. + /// @pre @a uri is obtained from maps_service_search_place_list() + /// @post It invokes maps_service_get_place_details_cb() to deliver obtained Place information. + /// @see maps_service_search_place_list() + /// @see maps_service_get_place_details_cb() + /// @see maps_service_cancel_request() + /// @see maps_service_provider_is_service_supported() + int maps_service_get_place_details( + ffi.Pointer maps, + ffi.Pointer uri, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, + ) { + return _maps_service_get_place_details( + maps, + uri, + callback, + user_data, + request_id, + ); + } + + late final _maps_service_get_place_details_ptr = + _lookup>( + 'maps_service_get_place_details'); + late final _dart_maps_service_get_place_details + _maps_service_get_place_details = _maps_service_get_place_details_ptr + .asFunction<_dart_maps_service_get_place_details>(); + + /// @brief Queries the Route from origin coordinates to destination.\n + /// The request is asynchronous. + /// @details This function gets the Route information for a specified origin and destination coordinates. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks To cancel the search request, use maps_service_cancel_request().\n + /// To check if Maps Provider is capable of searching routes, use + /// maps_service_provider_is_service_supported() with + /// #MAPS_SERVICE_SEARCH_ROUTE passed as @a service parameter.\n + /// Check available data features in the search result using + /// maps_service_provider_is_data_supported() with values, listed in + /// #maps_service_data_e passed as @a data parameter. + /// @param[in] maps The Maps Service handle + /// @param[in] origin The starting point + /// @param[in] destination The destination + /// @param[in] preference The Route preference handle + /// @param[in] callback The result callback + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] request_id The request ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_NOT_SUPPORTED Not supported + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_KEY_NOT_AVAILABLE Invalid key + /// @retval #MAPS_ERROR_UNKNOWN Unknown error + /// @pre Call maps_service_create() to create Maps Service and get its handle. + /// @post It invokes maps_service_search_route_cb() to deliver obtained Route information. + /// @see maps_service_search_route_waypoints() + /// @see maps_service_cancel_request() + /// @see maps_service_search_route_cb() + /// @see maps_service_provider_is_service_supported() + /// @see maps_service_provider_is_data_supported() + int maps_service_search_route( + ffi.Pointer maps, + ffi.Pointer origin, + ffi.Pointer destination, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, + ) { + return _maps_service_search_route( + maps, + origin, + destination, + preference, + callback, + user_data, + request_id, + ); + } + + late final _maps_service_search_route_ptr = + _lookup>( + 'maps_service_search_route'); + late final _dart_maps_service_search_route _maps_service_search_route = + _maps_service_search_route_ptr + .asFunction<_dart_maps_service_search_route>(); + + /// @brief Queries the Route, passing through a specified way points.\n + /// The request is asynchronous. + /// @details This function gets the Route information for the Route, passing through a specified set of way points. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mapservice \n + /// %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @remarks To cancel the search request, use maps_service_cancel_request().\n + /// To check if Maps Provider is capable of searching the route passing + /// through the specified way points, use + /// maps_service_provider_is_service_supported() with + /// #MAPS_SERVICE_SEARCH_ROUTE_WAYPOINTS passed as @a service parameter.\n + /// Check available data features in the search result using + /// maps_service_provider_is_data_supported() with values, listed in + /// #maps_service_data_e passed as @a data parameter. + /// @param[in] maps The Maps Service handle + /// @param[in] waypoint_list The list of way points to go through + /// @param[in] waypoint_num The number of way points to go through + /// @param[in] preference The Route preference handle + /// @param[in] callback The result callback + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] request_id The request ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MAPS_ERROR_NONE Successful + /// @retval #MAPS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MAPS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MAPS_ERROR_NOT_SUPPORTED Service unavailable + /// @retval #MAPS_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #MAPS_ERROR_CONNECTION_TIME_OUT Timeout error, no answer + /// @retval #MAPS_ERROR_INVALID_OPERATION Operation is not valid + /// @retval #MAPS_ERROR_NOT_FOUND Result not found + /// @retval #MAPS_ERROR_KEY_NOT_AVAILABLE Invalid key + /// @retval #MAPS_ERROR_UNKNOWN Unknown error + /// @pre Call maps_service_create() to create Maps Service and get its handle. + /// @post It invokes maps_service_search_route_cb() to deliver obtained Route information. + /// @see maps_service_search_route() + /// @see maps_service_cancel_request() + /// @see maps_service_search_route_cb() + /// @see maps_service_provider_is_service_supported() + /// @see maps_service_provider_is_data_supported() + int maps_service_search_route_waypoints( + ffi.Pointer maps, + ffi.Pointer> waypoint_list, + int waypoint_num, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, + ) { + return _maps_service_search_route_waypoints( + maps, + waypoint_list, + waypoint_num, + preference, + callback, + user_data, + request_id, + ); + } + + late final _maps_service_search_route_waypoints_ptr = + _lookup>( + 'maps_service_search_route_waypoints'); + late final _dart_maps_service_search_route_waypoints + _maps_service_search_route_waypoints = + _maps_service_search_route_waypoints_ptr + .asFunction<_dart_maps_service_search_route_waypoints>(); + + /// @brief Creates an email message handle for sending an email message. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/email + /// @remarks You must release @a email using email_destroy_message(). + /// @param[out] email A handle to the email message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EMAILS_ERROR_NONE Successful + /// @retval #EMAILS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #EMAILS_ERROR_ACCOUNT_NOT_FOUND Email account not found + /// @retval #EMAILS_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #EMAILS_ERROR_NOT_SUPPORTED Not supported + /// @pre At least one email account should be set up on the device. + /// @see email_destroy_message() + int email_create_message( + ffi.Pointer> email, + ) { + return _email_create_message( + email, + ); + } + + late final _email_create_message_ptr = + _lookup>( + 'email_create_message'); + late final _dart_email_create_message _email_create_message = + _email_create_message_ptr.asFunction<_dart_email_create_message>(); + + /// @brief Destroys the email message handle and releases all its resources. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] email The handle to the email message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EMAILS_ERROR_NONE Successful + /// @retval #EMAILS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EMAILS_ERROR_OPERATION_FAILED Operation failed + /// @retval #EMAILS_ERROR_NOT_SUPPORTED Not supported + /// @see email_create_message() + int email_destroy_message( + ffi.Pointer email, + ) { + return _email_destroy_message( + email, + ); + } + + late final _email_destroy_message_ptr = + _lookup>( + 'email_destroy_message'); + late final _dart_email_destroy_message _email_destroy_message = + _email_destroy_message_ptr.asFunction<_dart_email_destroy_message>(); + + /// @brief Sets a subject of the email message. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/email + /// @param[in] email The handle to the email message + /// @param[in] subject The subject of the email message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EMAILS_ERROR_NONE Successful + /// @retval #EMAILS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EMAILS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #EMAILS_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #EMAILS_ERROR_NOT_SUPPORTED Not supported + /// @pre An email message handle is created using email_create_message(). + /// @see email_create_message() + int email_set_subject( + ffi.Pointer email, + ffi.Pointer subject, + ) { + return _email_set_subject( + email, + subject, + ); + } + + late final _email_set_subject_ptr = + _lookup>('email_set_subject'); + late final _dart_email_set_subject _email_set_subject = + _email_set_subject_ptr.asFunction<_dart_email_set_subject>(); + + /// @brief Populates a body of the email message. + /// @details Email message body means the text data to be delivered. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediastorage + /// @param[in] email The handle to the email message + /// @param[in] body The message body + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EMAILS_ERROR_NONE Successful + /// @retval #EMAILS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EMAILS_ERROR_OPERATION_FAILED Operation failed + /// @retval #EMAILS_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #EMAILS_ERROR_NOT_SUPPORTED Not supported + /// @pre An email message handle is created using email_create_message(). + /// @see email_create_message() + int email_set_body( + ffi.Pointer email, + ffi.Pointer body, + ) { + return _email_set_body( + email, + body, + ); + } + + late final _email_set_body_ptr = + _lookup>('email_set_body'); + late final _dart_email_set_body _email_set_body = + _email_set_body_ptr.asFunction<_dart_email_set_body>(); + + /// @brief Adds a recipient to the email message. + /// @details The email API supports sending an email message to multiple recipients. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks Email address should be in standard format (as described in + /// Internet standards RFC 5321 and RFC 5322). + /// @param[in] email The handle to the email message + /// @param[in] type The recipient type + /// @param[in] address The recipient email address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EMAILS_ERROR_NONE Successful + /// @retval #EMAILS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EMAILS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #EMAILS_ERROR_NOT_SUPPORTED Not supported + /// @pre An email message handle is created using email_create_message(). + /// @see email_create_message() + /// @see email_remove_all_recipients() + int email_add_recipient( + ffi.Pointer email, + int type, + ffi.Pointer address, + ) { + return _email_add_recipient( + email, + type, + address, + ); + } + + late final _email_add_recipient_ptr = + _lookup>( + 'email_add_recipient'); + late final _dart_email_add_recipient _email_add_recipient = + _email_add_recipient_ptr.asFunction<_dart_email_add_recipient>(); + + /// @brief Removes all recipients for the email message. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] email The handle to the email message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EMAILS_ERROR_NONE Successful + /// @retval #EMAILS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EMAILS_ERROR_NOT_SUPPORTED Not supported + /// @pre An email message handle is created using email_create_message(). + /// @see email_add_recipient() + int email_remove_all_recipients( + ffi.Pointer email, + ) { + return _email_remove_all_recipients( + email, + ); + } + + late final _email_remove_all_recipients_ptr = + _lookup>( + 'email_remove_all_recipients'); + late final _dart_email_remove_all_recipients _email_remove_all_recipients = + _email_remove_all_recipients_ptr + .asFunction<_dart_email_remove_all_recipients>(); + + /// @brief Adds a file as an attachment to the email message. + /// @details It should be used to add a file to the attachment list + /// of the email message. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks The maximum attachment file size is 10MB. + /// http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. + /// @param[in] email The handle to the email message + /// @param[in] filepath The absolute full path of the file to be attached + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EMAILS_ERROR_NONE Successful + /// @retval #EMAILS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EMAILS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #EMAILS_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #EMAILS_ERROR_NOT_SUPPORTED Not supported + /// @pre An email message handle is created using email_create_message(). + /// @see email_remove_all_attachments() + int email_add_attach( + ffi.Pointer email, + ffi.Pointer filepath, + ) { + return _email_add_attach( + email, + filepath, + ); + } + + late final _email_add_attach_ptr = + _lookup>('email_add_attach'); + late final _dart_email_add_attach _email_add_attach = + _email_add_attach_ptr.asFunction<_dart_email_add_attach>(); + + /// @brief Clears all attachments of the email message. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] email The handle to the email message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EMAILS_ERROR_NONE Successful + /// @retval #EMAILS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EMAILS_ERROR_NOT_SUPPORTED Not supported + /// @pre An email message handle is created using email_create_message(). + /// @see email_create_message() + /// @see email_add_attach() + int email_remove_all_attachments( + ffi.Pointer email, + ) { + return _email_remove_all_attachments( + email, + ); + } + + late final _email_remove_all_attachments_ptr = + _lookup>( + 'email_remove_all_attachments'); + late final _dart_email_remove_all_attachments _email_remove_all_attachments = + _email_remove_all_attachments_ptr + .asFunction<_dart_email_remove_all_attachments>(); + + /// @brief Saves the email message at outbox. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/email + /// @param[in] email The handle to the email message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EMAILS_ERROR_NONE Successful + /// @retval #EMAILS_ERROR_COMMUNICATION_WITH_SERVER_FAILED Communication with server failed. + /// @retval #EMAILS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EMAILS_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #EMAILS_ERROR_NOT_SUPPORTED Not supported + /// @pre An email message handle is created using email_create_message(). + /// @see email_create_message() + /// @see email_add_recipient() + /// @see email_set_body() + /// @see email_save_message + int email_save_message( + ffi.Pointer email, + ) { + return _email_save_message( + email, + ); + } + + late final _email_save_message_ptr = + _lookup>('email_save_message'); + late final _dart_email_save_message _email_save_message = + _email_save_message_ptr.asFunction<_dart_email_save_message>(); + + /// @brief Sends the email message. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks In order to check whether sending a message succeeds, + /// you should register email_message_sent_cb() using email_set_message_sent_cb(). + /// @param[in] email The handle to the email message + /// @param[in] save_to_sentbox Set to @c true to save the message in the sentbox, + /// otherwise set to @c false to not save the message in the sentbox + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EMAILS_ERROR_NONE Successful + /// @retval #EMAILS_ERROR_COMMUNICATION_WITH_SERVER_FAILED Communication with server failed + /// @retval #EMAILS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EMAILS_ERROR_NOT_SUPPORTED Not supported + /// @pre An email message is stored using email_save_message(). + /// @see email_save_message() + /// @see email_set_message_sent_cb() + int email_send_message( + ffi.Pointer email, + bool save_to_sentbox, + ) { + return _email_send_message( + email, + save_to_sentbox ? 1 : 0, + ); + } + + late final _email_send_message_ptr = + _lookup>('email_send_message'); + late final _dart_email_send_message _email_send_message = + _email_send_message_ptr.asFunction<_dart_email_send_message>(); + + /// @brief Registers a callback function to be invoked when an email message is sent. + /// @details You will be notified when sending a message finishes and check whether it succeeds using this function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] email The handle to the email message + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EMAILS_ERROR_NONE Successful + /// @retval #EMAILS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EMAILS_ERROR_NOT_SUPPORTED Not supported + /// @post It will invoke email_message_sent_cb(). + /// @see email_message_sent_cb() + /// @see email_unset_message_sent_cb() + /// @see email_send_message() + int email_set_message_sent_cb( + ffi.Pointer email, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _email_set_message_sent_cb( + email, + callback, + user_data, + ); + } + + late final _email_set_message_sent_cb_ptr = + _lookup>( + 'email_set_message_sent_cb'); + late final _dart_email_set_message_sent_cb _email_set_message_sent_cb = + _email_set_message_sent_cb_ptr + .asFunction<_dart_email_set_message_sent_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] msg The handle to the email message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #EMAILS_ERROR_NONE Successful + /// @retval #EMAILS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #EMAILS_ERROR_NOT_SUPPORTED Not supported + /// @see email_message_sent_cb() + /// @see email_set_message_sent_cb() + /// @see email_send_message() + int email_unset_message_sent_cb( + ffi.Pointer msg, + ) { + return _email_unset_message_sent_cb( + msg, + ); + } + + late final _email_unset_message_sent_cb_ptr = + _lookup>( + 'email_unset_message_sent_cb'); + late final _dart_email_unset_message_sent_cb _email_unset_message_sent_cb = + _email_unset_message_sent_cb_ptr + .asFunction<_dart_email_unset_message_sent_cb>(); + + /// @brief Opens a handle for the messaging service. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.read + /// @remarks You must release @a service using messages_close_service(). + /// @param[out] service The message service handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_SERVER_NOT_READY Server is not ready + /// @retval #MESSAGES_ERROR_COMMUNICATION_WITH_SERVER_FAILED Communication with server failed + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_close_service() + int messages_open_service( + ffi.Pointer> service, + ) { + return _messages_open_service( + service, + ); + } + + late final _messages_open_service_ptr = + _lookup>( + 'messages_open_service'); + late final _dart_messages_open_service _messages_open_service = + _messages_open_service_ptr.asFunction<_dart_messages_open_service>(); + + /// @brief Closes a handle for the messaging service. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.read + /// @param[in] service The message service handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_COMMUNICATION_WITH_SERVER_FAILED Communication with server failed + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_open_service() + int messages_close_service( + ffi.Pointer service, + ) { + return _messages_close_service( + service, + ); + } + + late final _messages_close_service_ptr = + _lookup>( + 'messages_close_service'); + late final _dart_messages_close_service _messages_close_service = + _messages_close_service_ptr.asFunction<_dart_messages_close_service>(); + + /// @brief Creates a message handle. + /// @since_tizen 2.3 + /// @remarks You must release @a msg using messages_destroy_message(). + /// @param[in] type The message type (#MESSAGES_TYPE_SMS or #MESSAGES_TYPE_MMS) \n + /// If @a type is #MESSAGES_TYPE_UNKNOWN, #MESSAGES_ERROR_INVALID_PARAMETER occurs + /// @param[out] msg The message handle that is newly created if successful + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_destroy_message() + int messages_create_message( + int type, + ffi.Pointer> msg, + ) { + return _messages_create_message( + type, + msg, + ); + } + + late final _messages_create_message_ptr = + _lookup>( + 'messages_create_message'); + late final _dart_messages_create_message _messages_create_message = + _messages_create_message_ptr.asFunction<_dart_messages_create_message>(); + + /// @brief Destroys a message handle and releases all its resources. + /// @since_tizen 2.3 + /// @param[in] msg The message handle to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_create_message() + int messages_destroy_message( + ffi.Pointer msg, + ) { + return _messages_destroy_message( + msg, + ); + } + + late final _messages_destroy_message_ptr = + _lookup>( + 'messages_destroy_message'); + late final _dart_messages_destroy_message _messages_destroy_message = + _messages_destroy_message_ptr + .asFunction<_dart_messages_destroy_message>(); + + /// @brief Adds the message to message database. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.write + /// @param[in] service The message service handle + /// @param[in] msg The message handle + /// @param[out] msg_id The message ID of added message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OPERATION_FAILED Messaging operation failed + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_create_message() + int messages_add_message( + ffi.Pointer service, + ffi.Pointer msg, + ffi.Pointer msg_id, + ) { + return _messages_add_message( + service, + msg, + msg_id, + ); + } + + late final _messages_add_message_ptr = + _lookup>( + 'messages_add_message'); + late final _dart_messages_add_message _messages_add_message = + _messages_add_message_ptr.asFunction<_dart_messages_add_message>(); + + /// @brief Gets the message ID of the message. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @param[out] msg_id The message ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OPERATION_FAILED Messaging operation failed + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_search_message_by_id() + int messages_get_message_id( + ffi.Pointer msg, + ffi.Pointer msg_id, + ) { + return _messages_get_message_id( + msg, + msg_id, + ); + } + + late final _messages_get_message_id_ptr = + _lookup>( + 'messages_get_message_id'); + late final _dart_messages_get_message_id _messages_get_message_id = + _messages_get_message_id_ptr.asFunction<_dart_messages_get_message_id>(); + + /// @brief Sets the SIM ID of the sending message. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @param[in] sim_id The SIM ID to send message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OPERATION_FAILED Messaging operation failed + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_get_sim_id() + int messages_set_sim_id( + ffi.Pointer msg, + int sim_id, + ) { + return _messages_set_sim_id( + msg, + sim_id, + ); + } + + late final _messages_set_sim_id_ptr = + _lookup>( + 'messages_set_sim_id'); + late final _dart_messages_set_sim_id _messages_set_sim_id = + _messages_set_sim_id_ptr.asFunction<_dart_messages_set_sim_id>(); + + /// @brief Gets the SIM ID of the message. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @param[out] sim_id The SIM ID of message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OPERATION_FAILED Messaging operation failed + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_set_sim_id() + int messages_get_sim_id( + ffi.Pointer msg, + ffi.Pointer sim_id, + ) { + return _messages_get_sim_id( + msg, + sim_id, + ); + } + + late final _messages_get_sim_id_ptr = + _lookup>( + 'messages_get_sim_id'); + late final _dart_messages_get_sim_id _messages_get_sim_id = + _messages_get_sim_id_ptr.asFunction<_dart_messages_get_sim_id>(); + + /// @brief Sets the message box type of the message. + /// @since_tizen 3.0 + /// @param[in] msg The message handle + /// @param[in] mbox The message box type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + int messages_set_mbox_type( + ffi.Pointer msg, + int mbox, + ) { + return _messages_set_mbox_type( + msg, + mbox, + ); + } + + late final _messages_set_mbox_type_ptr = + _lookup>( + 'messages_set_mbox_type'); + late final _dart_messages_set_mbox_type _messages_set_mbox_type = + _messages_set_mbox_type_ptr.asFunction<_dart_messages_set_mbox_type>(); + + /// @brief Gets the message box type of the message. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @param[out] mbox The message box type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + int messages_get_mbox_type( + ffi.Pointer msg, + ffi.Pointer mbox, + ) { + return _messages_get_mbox_type( + msg, + mbox, + ); + } + + late final _messages_get_mbox_type_ptr = + _lookup>( + 'messages_get_mbox_type'); + late final _dart_messages_get_mbox_type _messages_get_mbox_type = + _messages_get_mbox_type_ptr.asFunction<_dart_messages_get_mbox_type>(); + + /// @brief Gets the destination port of the message. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @param[out] port The destination port of the message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_add_sms_listening_port() + int messages_get_message_port( + ffi.Pointer msg, + ffi.Pointer port, + ) { + return _messages_get_message_port( + msg, + port, + ); + } + + late final _messages_get_message_port_ptr = + _lookup>( + 'messages_get_message_port'); + late final _dart_messages_get_message_port _messages_get_message_port = + _messages_get_message_port_ptr + .asFunction<_dart_messages_get_message_port>(); + + /// @brief Gets the type of the message. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @param[out] type The message type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + int messages_get_message_type( + ffi.Pointer msg, + ffi.Pointer type, + ) { + return _messages_get_message_type( + msg, + type, + ); + } + + late final _messages_get_message_type_ptr = + _lookup>( + 'messages_get_message_type'); + late final _dart_messages_get_message_type _messages_get_message_type = + _messages_get_message_type_ptr + .asFunction<_dart_messages_get_message_type>(); + + /// @brief Adds an recipient's address(phone number) to the message. + /// @details The maximum number of recipients per message is 10. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @param[in] address The recipient's address to receive a message \n + /// The maximum length of @a address is @c 254. + /// @param[in] type The recipient's type of the @a address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_get_address() + /// @see messages_remove_all_addresses() + int messages_add_address( + ffi.Pointer msg, + ffi.Pointer address, + int type, + ) { + return _messages_add_address( + msg, + address, + type, + ); + } + + late final _messages_add_address_ptr = + _lookup>( + 'messages_add_address'); + late final _dart_messages_add_address _messages_add_address = + _messages_add_address_ptr.asFunction<_dart_messages_add_address>(); + + /// @brief Gets the total number of recipients in the message. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @param[out] count The total number of recipients + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_add_address() + /// @see messages_remove_all_addresses() + int messages_get_address_count( + ffi.Pointer msg, + ffi.Pointer count, + ) { + return _messages_get_address_count( + msg, + count, + ); + } + + late final _messages_get_address_count_ptr = + _lookup>( + 'messages_get_address_count'); + late final _dart_messages_get_address_count _messages_get_address_count = + _messages_get_address_count_ptr + .asFunction<_dart_messages_get_address_count>(); + + /// @brief Gets a recipient's address with specified index. + /// @since_tizen 2.3 + /// @remarks You must release @a address using free(). + /// @param[in] msg The message handle + /// @param[in] index The zero-based index of an address to receive a message + /// @param[out] address The recipient's address with specified index + /// @param[out] type The recipient's type of the @a address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_add_address() + /// @see messages_remove_all_addresses() + int messages_get_address( + ffi.Pointer msg, + int index, + ffi.Pointer> address, + ffi.Pointer type, + ) { + return _messages_get_address( + msg, + index, + address, + type, + ); + } + + late final _messages_get_address_ptr = + _lookup>( + 'messages_get_address'); + late final _dart_messages_get_address _messages_get_address = + _messages_get_address_ptr.asFunction<_dart_messages_get_address>(); + + /// @brief Removes all recipients in the message. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_add_address() + /// @see messages_get_address() + int messages_remove_all_addresses( + ffi.Pointer msg, + ) { + return _messages_remove_all_addresses( + msg, + ); + } + + late final _messages_remove_all_addresses_ptr = + _lookup>( + 'messages_remove_all_addresses'); + late final _dart_messages_remove_all_addresses + _messages_remove_all_addresses = _messages_remove_all_addresses_ptr + .asFunction<_dart_messages_remove_all_addresses>(); + + /// @brief Sets the text of the message. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @param[in] text The text of the message \n + /// The maximum length of @a text is @c 1530 + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_get_text() + int messages_set_text( + ffi.Pointer msg, + ffi.Pointer text, + ) { + return _messages_set_text( + msg, + text, + ); + } + + late final _messages_set_text_ptr = + _lookup>('messages_set_text'); + late final _dart_messages_set_text _messages_set_text = + _messages_set_text_ptr.asFunction<_dart_messages_set_text>(); + + /// @brief Gets the text of the message. + /// @since_tizen 2.3 + /// @remarks You must release @a text using free(). + /// @param[in] msg The message handle + /// @param[out] text The text of the message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_set_text() + int messages_get_text( + ffi.Pointer msg, + ffi.Pointer> text, + ) { + return _messages_get_text( + msg, + text, + ); + } + + late final _messages_get_text_ptr = + _lookup>('messages_get_text'); + late final _dart_messages_get_text _messages_get_text = + _messages_get_text_ptr.asFunction<_dart_messages_get_text>(); + + /// @brief Sets the time of the message. + /// @since_tizen 3.0 + /// @param[in] msg The message handle + /// @param[in] time The time of the message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + int messages_set_time( + ffi.Pointer msg, + int time, + ) { + return _messages_set_time( + msg, + time, + ); + } + + late final _messages_set_time_ptr = + _lookup>('messages_set_time'); + late final _dart_messages_set_time _messages_set_time = + _messages_set_time_ptr.asFunction<_dart_messages_set_time>(); + + /// @brief Gets the time of the message. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @param[out] time The time of the message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + int messages_get_time( + ffi.Pointer msg, + ffi.Pointer time, + ) { + return _messages_get_time( + msg, + time, + ); + } + + late final _messages_get_time_ptr = + _lookup>('messages_get_time'); + late final _dart_messages_get_time _messages_get_time = + _messages_get_time_ptr.asFunction<_dart_messages_get_time>(); + + /// @brief Sends the message to all recipients. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.write + /// @param[in] service The message service handle + /// @param[in] msg The message handle + /// @param[in] save_to_sentbox Set to @c true to save the message in the sentbox, + /// otherwise set to @c false to not save the message in the sentbox + /// @param[in] callback The callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_SENDING_FAILED Sending message failed + /// @retval #MESSAGES_ERROR_OPERATION_FAILED Messaging operation failed + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_sent_cb() + int messages_send_message( + ffi.Pointer service, + ffi.Pointer msg, + bool save_to_sentbox, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _messages_send_message( + service, + msg, + save_to_sentbox ? 1 : 0, + callback, + user_data, + ); + } + + late final _messages_send_message_ptr = + _lookup>( + 'messages_send_message'); + late final _dart_messages_send_message _messages_send_message = + _messages_send_message_ptr.asFunction<_dart_messages_send_message>(); + + /// @brief Gets the message count in the specific message box. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.read + /// @param[in] service The message service handle + /// @param[in] mbox The message box type + /// @param[in] type The message type \n + /// If @a type is #MESSAGES_TYPE_UNKNOWN, all SMS and MMS messages are counted + /// @param[out] count The number of messages + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OPERATION_FAILED Messaging operation failed + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + int messages_get_message_count( + ffi.Pointer service, + int mbox, + int type, + ffi.Pointer count, + ) { + return _messages_get_message_count( + service, + mbox, + type, + count, + ); + } + + late final _messages_get_message_count_ptr = + _lookup>( + 'messages_get_message_count'); + late final _dart_messages_get_message_count _messages_get_message_count = + _messages_get_message_count_ptr + .asFunction<_dart_messages_get_message_count>(); + + /// @brief Searches for messages. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.read + /// @remarks You must release @a message_array using messages_free_message_array(). + /// @param[in] service The message service handle + /// @param[in] mbox The message box type + /// @param[in] type The message type \n + /// If @a type is #MESSAGES_TYPE_UNKNOWN, all SMS and MMS messages are searched + /// @param[in] keyword The keyword search in the text and subject + /// @param[in] address The recipient address + /// @param[in] offset The start position (base @c 0) + /// @param[in] limit The maximum amount of messages to get \n + /// In case of @c 0, this method passes to the callback all searched messages + /// @param[out] message_array The array of the message handle + /// @param[out] length The number of messages of the @a message_array + /// @param[out] total The count of the messages that have been retrieved as a result without applying @a limit and @a offset \n + /// The value can be used to calculate the total number of page views for the searched messages \n + /// For example, if the count of message search is @c 50 and the limit is @c 20, then using this value, you can notice the total page is @c 3 + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGES_ERROR_OPERATION_FAILED Messaging operation failed + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_free_message_array() + int messages_search_message( + ffi.Pointer service, + int mbox, + int type, + ffi.Pointer keyword, + ffi.Pointer address, + int offset, + int limit, + ffi.Pointer>> message_array, + ffi.Pointer length, + ffi.Pointer total, + ) { + return _messages_search_message( + service, + mbox, + type, + keyword, + address, + offset, + limit, + message_array, + length, + total, + ); + } + + late final _messages_search_message_ptr = + _lookup>( + 'messages_search_message'); + late final _dart_messages_search_message _messages_search_message = + _messages_search_message_ptr.asFunction<_dart_messages_search_message>(); + + /// @brief Searches a message with the given message ID. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.read + /// @remarks You must release @a msg using messages_destroy_message(). + /// @param[in] service The message service handle + /// @param[in] msg_id The message ID + /// @param[out] msg The message handle that is newly created if successful + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_get_message_id() + int messages_search_message_by_id( + ffi.Pointer service, + int msg_id, + ffi.Pointer> msg, + ) { + return _messages_search_message_by_id( + service, + msg_id, + msg, + ); + } + + late final _messages_search_message_by_id_ptr = + _lookup>( + 'messages_search_message_by_id'); + late final _dart_messages_search_message_by_id + _messages_search_message_by_id = _messages_search_message_by_id_ptr + .asFunction<_dart_messages_search_message_by_id>(); + + /// @brief Frees the message array. + /// @since_tizen 2.3 + /// @param[in] message_array The array of the message handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_search_message() + int messages_free_message_array( + ffi.Pointer> message_array, + ) { + return _messages_free_message_array( + message_array, + ); + } + + late final _messages_free_message_array_ptr = + _lookup>( + 'messages_free_message_array'); + late final _dart_messages_free_message_array _messages_free_message_array = + _messages_free_message_array_ptr + .asFunction<_dart_messages_free_message_array>(); + + /// @brief Retrieves the searched messages by invoking the given callback function iteratively. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.read + /// @param[in] service The message service handle + /// @param[in] mbox The message box type + /// @param[in] type The message type \n + /// If @a type is #MESSAGES_TYPE_UNKNOWN, all SMS and MMS messages are searched + /// @param[in] keyword The keyword search in the text and subject + /// @param[in] address The recipient address + /// @param[in] offset The start position (base 0) + /// @param[in] limit The maximum amount of messages to get \n + /// In case of @c 0, this method passes to the callback all searched messages + /// @param[in] callback The callback function to get a message + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGES_ERROR_OPERATION_FAILED Messaging operation failed + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @post It invokes messages_search_cb(). + /// @see messages_search_cb() + int messages_foreach_message( + ffi.Pointer service, + int mbox, + int type, + ffi.Pointer keyword, + ffi.Pointer address, + int offset, + int limit, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _messages_foreach_message( + service, + mbox, + type, + keyword, + address, + offset, + limit, + callback, + user_data, + ); + } + + late final _messages_foreach_message_ptr = + _lookup>( + 'messages_foreach_message'); + late final _dart_messages_foreach_message _messages_foreach_message = + _messages_foreach_message_ptr + .asFunction<_dart_messages_foreach_message>(); + + /// @brief Registers a callback to be invoked when an incoming message is received. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.read + /// @param[in] service The message service handle + /// @param[in] callback The callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OPERATION_FAILED Messaging operation failed + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @post It will invoke messages_incoming_cb(). + /// @see messages_unset_message_incoming_cb() + /// @see messages_incoming_cb() + int messages_set_message_incoming_cb( + ffi.Pointer service, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _messages_set_message_incoming_cb( + service, + callback, + user_data, + ); + } + + late final _messages_set_message_incoming_cb_ptr = + _lookup>( + 'messages_set_message_incoming_cb'); + late final _dart_messages_set_message_incoming_cb + _messages_set_message_incoming_cb = _messages_set_message_incoming_cb_ptr + .asFunction<_dart_messages_set_message_incoming_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.write + /// @param[in] service The message service handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_set_message_incoming_cb() + /// @see messages_incoming_cb() + int messages_unset_message_incoming_cb( + ffi.Pointer service, + ) { + return _messages_unset_message_incoming_cb( + service, + ); + } + + late final _messages_unset_message_incoming_cb_ptr = + _lookup>( + 'messages_unset_message_incoming_cb'); + late final _dart_messages_unset_message_incoming_cb + _messages_unset_message_incoming_cb = + _messages_unset_message_incoming_cb_ptr + .asFunction<_dart_messages_unset_message_incoming_cb>(); + + /// @brief Adds an additional listening port for the incoming SMS messages. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.read + /// @param[in] service The message service handle + /// @param[in] port The listening port for the SMS messages + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @see messages_set_message_incoming_cb() + /// @see messages_get_message_port() + int messages_add_sms_listening_port( + ffi.Pointer service, + int port, + ) { + return _messages_add_sms_listening_port( + service, + port, + ); + } + + late final _messages_add_sms_listening_port_ptr = + _lookup>( + 'messages_add_sms_listening_port'); + late final _dart_messages_add_sms_listening_port + _messages_add_sms_listening_port = _messages_add_sms_listening_port_ptr + .asFunction<_dart_messages_add_sms_listening_port>(); + + /// @brief Sets the subject of the message. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @param[in] subject The subject of the message \n + /// The maximum length of @a subject is @c 120 + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @pre @a msg is created as a #MESSAGES_TYPE_MMS. + /// @see messages_mms_get_subject() + int messages_mms_set_subject( + ffi.Pointer msg, + ffi.Pointer subject, + ) { + return _messages_mms_set_subject( + msg, + subject, + ); + } + + late final _messages_mms_set_subject_ptr = + _lookup>( + 'messages_mms_set_subject'); + late final _dart_messages_mms_set_subject _messages_mms_set_subject = + _messages_mms_set_subject_ptr + .asFunction<_dart_messages_mms_set_subject>(); + + /// @brief Gets the subject of the message. + /// @since_tizen 2.3 + /// @remarks You must release @a subject using free(). + /// @param[in] msg The message handle + /// @param[out] subject The subject of the message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @pre @a msg is created as a #MESSAGES_TYPE_MMS. + /// @see messages_mms_set_subject() + int messages_mms_get_subject( + ffi.Pointer msg, + ffi.Pointer> subject, + ) { + return _messages_mms_get_subject( + msg, + subject, + ); + } + + late final _messages_mms_get_subject_ptr = + _lookup>( + 'messages_mms_get_subject'); + late final _dart_messages_mms_get_subject _messages_mms_get_subject = + _messages_mms_get_subject_ptr + .asFunction<_dart_messages_mms_get_subject>(); + + /// @brief Adds the attachment to the MMS message. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @param[in] type The attachment type + /// @param[in] path The file path to attach \n + /// The maximum length of @a path is @c 1024 + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @pre @a msg is created as a #MESSAGES_TYPE_MMS. + /// @see messages_mms_get_attachment() + /// @see messages_mms_get_attachment_count() + /// @see messages_mms_remove_all_attachments() + int messages_mms_add_attachment( + ffi.Pointer msg, + int type, + ffi.Pointer path, + ) { + return _messages_mms_add_attachment( + msg, + type, + path, + ); + } + + late final _messages_mms_add_attachment_ptr = + _lookup>( + 'messages_mms_add_attachment'); + late final _dart_messages_mms_add_attachment _messages_mms_add_attachment = + _messages_mms_add_attachment_ptr + .asFunction<_dart_messages_mms_add_attachment>(); + + /// @brief Gets the file path of the attachment with the specified index. + /// @since_tizen 2.3 + /// @remarks You must release @a path using free(). + /// @param[in] msg The message handle + /// @param[in] index The zero-based index of the attachment + /// @param[out] type The attachment type + /// @param[out] path The file path to attach + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @pre @a msg is created as a #MESSAGES_TYPE_MMS. + /// @see messages_mms_add_attachment() + /// @see messages_mms_get_attachment_count() + /// @see messages_mms_remove_all_attachments() + int messages_mms_get_attachment( + ffi.Pointer msg, + int index, + ffi.Pointer type, + ffi.Pointer> path, + ) { + return _messages_mms_get_attachment( + msg, + index, + type, + path, + ); + } + + late final _messages_mms_get_attachment_ptr = + _lookup>( + 'messages_mms_get_attachment'); + late final _dart_messages_mms_get_attachment _messages_mms_get_attachment = + _messages_mms_get_attachment_ptr + .asFunction<_dart_messages_mms_get_attachment>(); + + /// @brief Gets the attachment with the specified index. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @param[out] count The total number of attachments + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @pre @a msg is created as a #MESSAGES_TYPE_MMS. + /// @see messages_mms_add_attachment() + /// @see messages_mms_get_attachment() + /// @see messages_mms_remove_all_attachments() + int messages_mms_get_attachment_count( + ffi.Pointer msg, + ffi.Pointer count, + ) { + return _messages_mms_get_attachment_count( + msg, + count, + ); + } + + late final _messages_mms_get_attachment_count_ptr = + _lookup>( + 'messages_mms_get_attachment_count'); + late final _dart_messages_mms_get_attachment_count + _messages_mms_get_attachment_count = + _messages_mms_get_attachment_count_ptr + .asFunction<_dart_messages_mms_get_attachment_count>(); + + /// @brief Removes all attachments to the MMS message. + /// @since_tizen 2.3 + /// @param[in] msg The message handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + /// @pre @a msg is created as a #MESSAGES_TYPE_MMS. + /// @see messages_mms_add_attachment() + /// @see messages_mms_get_attachment() + /// @see messages_mms_get_attachment_count() + int messages_mms_remove_all_attachments( + ffi.Pointer msg, + ) { + return _messages_mms_remove_all_attachments( + msg, + ); + } + + late final _messages_mms_remove_all_attachments_ptr = + _lookup>( + 'messages_mms_remove_all_attachments'); + late final _dart_messages_mms_remove_all_attachments + _messages_mms_remove_all_attachments = + _messages_mms_remove_all_attachments_ptr + .asFunction<_dart_messages_mms_remove_all_attachments>(); + + /// @brief Registers a callback to be invoked when an WAP Push message is received. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.read + /// @param[in] service The message service handle + /// @param[in] app_id The "X-WAP-Application-ID" to indicate a destination WAP Push application ID + /// @param[in] callback The callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + int messages_push_add_incoming_cb( + ffi.Pointer service, + ffi.Pointer app_id, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _messages_push_add_incoming_cb( + service, + app_id, + callback, + user_data, + ); + } + + late final _messages_push_add_incoming_cb_ptr = + _lookup>( + 'messages_push_add_incoming_cb'); + late final _dart_messages_push_add_incoming_cb + _messages_push_add_incoming_cb = _messages_push_add_incoming_cb_ptr + .asFunction<_dart_messages_push_add_incoming_cb>(); + + /// @brief Unregisters the WAP push incoming callback function. + /// @since_tizen 2.3 + /// @param[in] service The message service handle + /// @param[in] app_id The "X-WAP-Application-ID" to indicate a destination WAP Push application ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + int messages_push_remove_incoming_cb( + ffi.Pointer service, + ffi.Pointer app_id, + ) { + return _messages_push_remove_incoming_cb( + service, + app_id, + ); + } + + late final _messages_push_remove_incoming_cb_ptr = + _lookup>( + 'messages_push_remove_incoming_cb'); + late final _dart_messages_push_remove_incoming_cb + _messages_push_remove_incoming_cb = _messages_push_remove_incoming_cb_ptr + .asFunction<_dart_messages_push_remove_incoming_cb>(); + + /// @brief Registers an application to the mapping table of the WAP Push service. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.write + /// @param[in] service The message service handle + /// @param[in] content_type The MIME content type of the content + /// @param[in] app_id The "X-WAP-Application-ID" to indicate a destination WAP Push application ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + int messages_push_register( + ffi.Pointer service, + ffi.Pointer content_type, + ffi.Pointer app_id, + ) { + return _messages_push_register( + service, + content_type, + app_id, + ); + } + + late final _messages_push_register_ptr = + _lookup>( + 'messages_push_register'); + late final _dart_messages_push_register _messages_push_register = + _messages_push_register_ptr.asFunction<_dart_messages_push_register>(); + + /// @brief De-registers an application from the mapping table of the WAP Push service. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.write + /// @param[in] service The message service handle + /// @param[in] content_type The MIME content type of the content + /// @param[in] app_id The "X-WAP-Application-ID" to indicate a destination WAP Push application ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + int messages_push_deregister( + ffi.Pointer service, + ffi.Pointer content_type, + ffi.Pointer app_id, + ) { + return _messages_push_deregister( + service, + content_type, + app_id, + ); + } + + late final _messages_push_deregister_ptr = + _lookup>( + 'messages_push_deregister'); + late final _dart_messages_push_deregister _messages_push_deregister = + _messages_push_deregister_ptr + .asFunction<_dart_messages_push_deregister>(); + + /// @brief Re-registers an application to the mapping table of the WAP Push service. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/message.write + /// @param[in] service The message service handle + /// @param[in] content_type An element of the composite key for searching registered entry \n + /// The MIME content type of the content + /// @param[in] app_id The composite key for searching mapping information \n + /// The "X-WAP-Application-ID" to indicate a destination WAP Push application ID + /// @param[in] dst_content_type The MIME content type of the content + /// @param[in] dst_app_id The "X-WAP-Application-ID" to indicate a destination WAP Push application ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MESSAGES_ERROR_NONE Successful + /// @retval #MESSAGES_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MESSAGES_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method + /// @retval #MESSAGES_ERROR_NOT_SUPPORTED Not supported + int messages_push_reregister( + ffi.Pointer service, + ffi.Pointer content_type, + ffi.Pointer app_id, + ffi.Pointer dst_content_type, + ffi.Pointer dst_app_id, + ) { + return _messages_push_reregister( + service, + content_type, + app_id, + dst_content_type, + dst_app_id, + ); + } + + late final _messages_push_reregister_ptr = + _lookup>( + 'messages_push_reregister'); + late final _dart_messages_push_reregister _messages_push_reregister = + _messages_push_reregister_ptr + .asFunction<_dart_messages_push_reregister>(); + + /// @brief Connects to the push service and sets callback functions. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/push + /// @remarks If there is a connection between an application and the push service,\n + /// the notify callback passes the notification upon its arrival.\n + /// Otherwise, the push service posts a UI notification to alert users.\n + /// The connection should be freed with push_service_disconnect() by you. + /// @param[in] push_app_id App id received from Tizen Push Server team + /// @param[in] state_callback State callback function + /// @param[in] notify_callback Notify callback function + /// @param[in] user_data User data to pass to state_cb and notify_cb + /// @param[out] connection The connection handle to the push service + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PUSH_SERVICE_ERROR_NONE Successful + /// @retval #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PUSH_SERVICE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PUSH_SERVICE_ERROR_NOT_CONNECTED Connection to the daemon failed + /// @retval #PUSH_SERVICE_ERROR_PERMISSION_DENIED No push privilege + /// @retval #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// @pre There is no connection to the push service for the app_id. + /// @post The state callback will be called to let you know the current + /// registration state immediately. + /// @see push_service_disconnect() + int push_service_connect( + ffi.Pointer push_app_id, + ffi.Pointer> state_callback, + ffi.Pointer> notify_callback, + ffi.Pointer user_data, + ffi.Pointer> connection, + ) { + return _push_service_connect( + push_app_id, + state_callback, + notify_callback, + user_data, + connection, + ); + } + + late final _push_service_connect_ptr = + _lookup>( + 'push_service_connect'); + late final _dart_push_service_connect _push_service_connect = + _push_service_connect_ptr.asFunction<_dart_push_service_connect>(); + + /// @brief Closes the connection and releases all its resources + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If you call this function in the push callback functions,\n + /// it may cause your application to crash.\n + /// The specific error code can be obtained using the get_last_result()\n + /// Error codes are described in the exception section. + /// @param[in] connection The connection handle to the push service + /// @exception #PUSH_SERVICE_ERROR_NONE Successful + /// @exception #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// @see push_service_connect() + void push_service_disconnect( + ffi.Pointer connection, + ) { + return _push_service_disconnect( + connection, + ); + } + + late final _push_service_disconnect_ptr = + _lookup>( + 'push_service_disconnect'); + late final _dart_push_service_disconnect _push_service_disconnect = + _push_service_disconnect_ptr.asFunction<_dart_push_service_disconnect>(); + + /// @brief Registers an application to the push server. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] connection The connection handle to the push service + /// @param[in] result_callback Result callback function + /// @param[in] user_data User data to pass to result_cb + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PUSH_SERVICE_ERROR_NONE Successful + /// @retval #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PUSH_SERVICE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PUSH_SERVICE_ERROR_NOT_CONNECTED No connection to the push service + /// @retval #PUSH_SERVICE_ERROR_OPERATION_FAILED Operation failed + /// @retval #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// @pre The application should be connected to the push service. + /// @post As a result, the state callback will be invoked. + /// @see push_service_deregister() + int push_service_register( + ffi.Pointer connection, + ffi.Pointer> result_callback, + ffi.Pointer user_data, + ) { + return _push_service_register( + connection, + result_callback, + user_data, + ); + } + + late final _push_service_register_ptr = + _lookup>( + 'push_service_register'); + late final _dart_push_service_register _push_service_register = + _push_service_register_ptr.asFunction<_dart_push_service_register>(); + + /// @brief Deregisters an application from the Push server. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] connection The connection handle to the push service + /// @param[in] result_callback Result callback function + /// @param[in] user_data User data to pass to result_cb + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PUSH_SERVICE_ERROR_NONE Successful + /// @retval #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PUSH_SERVICE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PUSH_SERVICE_ERROR_NOT_CONNECTED No connection to the push service + /// @retval #PUSH_SERVICE_ERROR_OPERATION_FAILED Operation failed + /// @retval #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// @pre The application should be connected to the push service. + /// @post As a result, the state callback will be invoked. + /// @see push_service_register() + int push_service_deregister( + ffi.Pointer connection, + ffi.Pointer> result_callback, + ffi.Pointer user_data, + ) { + return _push_service_deregister( + connection, + result_callback, + user_data, + ); + } + + late final _push_service_deregister_ptr = + _lookup>( + 'push_service_deregister'); + late final _dart_push_service_deregister _push_service_deregister = + _push_service_deregister_ptr.asFunction<_dart_push_service_deregister>(); + + /// @brief Retrieves the payload data of a notification that forcibly launched the app. + /// @details When a notification arrives at the device with the "LAUNCH"\n + /// option or a user clicks a notification in the quick panel,\n + /// the push daemon forcibly launches the app and delivers the\n + /// notification to the app as a bundle. This function returns\n + /// the payload data in the notification. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/push + /// @remark This function must be called in the app control callback function.\n + /// You must release the payload data using free().\n + /// push_service_app_control_to_notification() is preferred to this API.\n + /// The specific error code can be obtained using the get_last_result()\n + /// Error codes are described in the exception section. + /// @param[in] app_control The app control handle that is handed over in the\n + /// app control callback function + /// @param[in] operation The operation in the app control handle retrieved by\n + /// app_control_get_operation() + /// @return The payload data (appData) in the notification\n + /// NULL if the app is not launched by a push notification. + /// @exception #PUSH_SERVICE_ERROR_NONE Successful + /// @exception #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #PUSH_SERVICE_ERROR_NO_DATA Not launched by a notification + /// @exception #PUSH_SERVICE_ERROR_OPERATION_FAILED Operation fail + /// @exception #PUSH_SERVICE_ERROR_OUT_OF_MEMORY Out of memory + /// @exception #PUSH_SERVICE_ERROR_NOT_CONNECTED Connection to the daemon failed + /// @exception #PUSH_SERVICE_ERROR_PERMISSION_DENIED No push privilege + /// @exception #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// @see app_control_get_operation() + ffi.Pointer push_service_app_control_to_noti_data( + ffi.Pointer app_control, + ffi.Pointer operation, + ) { + return _push_service_app_control_to_noti_data( + app_control, + operation, + ); + } + + late final _push_service_app_control_to_noti_data_ptr = + _lookup>( + 'push_service_app_control_to_noti_data'); + late final _dart_push_service_app_control_to_noti_data + _push_service_app_control_to_noti_data = + _push_service_app_control_to_noti_data_ptr + .asFunction<_dart_push_service_app_control_to_noti_data>(); + + /// @brief Retrieves the notification that forcibly launched the app. + /// @details When a notification arrives at the device with the "LAUNCH"\n + /// option or a user clicks a notification in the quick panel,\n + /// the push daemon forcibly launches the app and delivers the\n + /// notification to the app as a bundle. This function returns\n + /// the notification from the bundle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/push + /// @remark This function must be called in the app control callback function.\n + /// You must release the notification using push_service_free_notification(). + /// @param[in] app_control The app control handle that is handed over in the\n + /// app control callback function + /// @param[in] operation The operation in the app control handle retrieved by\n + /// app_control_get_operation() + /// @param[out] noti The handle of the notification that forcibly launched the app + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PUSH_SERVICE_ERROR_NONE Successful + /// @retval #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PUSH_SERVICE_ERROR_NO_DATA Not launched by a notification + /// @retval #PUSH_SERVICE_ERROR_OPERATION_FAILED Operation fail + /// @retval #PUSH_SERVICE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PUSH_SERVICE_ERROR_NOT_CONNECTED Connection to the daemon failed + /// @retval #PUSH_SERVICE_ERROR_PERMISSION_DENIED No push privilege + /// @retval #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// @see push_service_free_notification() + /// @see app_control_get_operation() + int push_service_app_control_to_notification( + ffi.Pointer app_control, + ffi.Pointer operation, + ffi.Pointer> noti, + ) { + return _push_service_app_control_to_notification( + app_control, + operation, + noti, + ); + } + + late final _push_service_app_control_to_notification_ptr = + _lookup>( + 'push_service_app_control_to_notification'); + late final _dart_push_service_app_control_to_notification + _push_service_app_control_to_notification = + _push_service_app_control_to_notification_ptr + .asFunction<_dart_push_service_app_control_to_notification>(); + + /// @brief Gets notification data sent by the server. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a data using free(). + /// @param[in] notification The notification handle + /// @param[out] data The notification data\n + /// Set NULL if error but PUSH_SERVICE_ERROR_INVALID_PARAMETER + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PUSH_SERVICE_ERROR_NONE Successful + /// @retval #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PUSH_SERVICE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PUSH_SERVICE_ERROR_NO_DATA No data available + /// @retval #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// @see push_service_notify_cb() + /// @see push_service_request_unread_notification() + int push_service_get_notification_data( + ffi.Pointer notification, + ffi.Pointer> data, + ) { + return _push_service_get_notification_data( + notification, + data, + ); + } + + late final _push_service_get_notification_data_ptr = + _lookup>( + 'push_service_get_notification_data'); + late final _dart_push_service_get_notification_data + _push_service_get_notification_data = + _push_service_get_notification_data_ptr + .asFunction<_dart_push_service_get_notification_data>(); + + /// @brief Gets the notification message sent by the server. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remark The msg must be released with free().\n + /// push_service_request_unread_notification() is\n + /// preferred to this API. + /// @param[in] notification The notification handle + /// @param[out] msg The notification message\n + /// Set NULL if error but PUSH_SERVICE_ERROR_INVALID_PARAMETER + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PUSH_SERVICE_ERROR_NONE Successful + /// @retval #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PUSH_SERVICE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PUSH_SERVICE_ERROR_NO_DATA No data available + /// @retval #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// @see push_service_notify_cb() + /// @see push_service_get_unread_notification() + int push_service_get_notification_message( + ffi.Pointer notification, + ffi.Pointer> msg, + ) { + return _push_service_get_notification_message( + notification, + msg, + ); + } + + late final _push_service_get_notification_message_ptr = + _lookup>( + 'push_service_get_notification_message'); + late final _dart_push_service_get_notification_message + _push_service_get_notification_message = + _push_service_get_notification_message_ptr + .asFunction<_dart_push_service_get_notification_message>(); + + /// @brief Gets the received time of the notification message. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] notification The notification handle + /// @param[out] received_time The received time of the notification message \n + /// The @a received_time is based on UTC. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PUSH_SERVICE_ERROR_NONE Successful + /// @retval #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PUSH_SERVICE_ERROR_NO_DATA No data available + /// @retval #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// @see push_service_notify_cb() + /// @see push_service_request_unread_notification() + int push_service_get_notification_time( + ffi.Pointer notification, + ffi.Pointer received_time, + ) { + return _push_service_get_notification_time( + notification, + received_time, + ); + } + + late final _push_service_get_notification_time_ptr = + _lookup>( + 'push_service_get_notification_time'); + late final _dart_push_service_get_notification_time + _push_service_get_notification_time = + _push_service_get_notification_time_ptr + .asFunction<_dart_push_service_get_notification_time>(); + + /// @brief Gets the sender of the notification. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a sender using free(). + /// @param[in] notification The notification handle + /// @param[out] sender The sender\n + /// Set @c NULL if error but #PUSH_SERVICE_ERROR_INVALID_PARAMETER + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PUSH_SERVICE_ERROR_NONE Successful + /// @retval #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PUSH_SERVICE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PUSH_SERVICE_ERROR_NO_DATA No data available + /// @retval #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// @see push_service_notify_cb() + /// @see push_serivce_get_unread_notification() + int push_service_get_notification_sender( + ffi.Pointer notification, + ffi.Pointer> sender, + ) { + return _push_service_get_notification_sender( + notification, + sender, + ); + } + + late final _push_service_get_notification_sender_ptr = + _lookup>( + 'push_service_get_notification_sender'); + late final _dart_push_service_get_notification_sender + _push_service_get_notification_sender = + _push_service_get_notification_sender_ptr + .asFunction<_dart_push_service_get_notification_sender>(); + + /// @brief Gets the session ID of the notification. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a session_info using free(). + /// @param[in] notification The notification handle + /// @param[out] session_info The session ID\n + /// Set @c NULL if error but #PUSH_SERVICE_ERROR_INVALID_PARAMETER + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PUSH_SERVICE_ERROR_NONE Successful + /// @retval #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PUSH_SERVICE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PUSH_SERVICE_ERROR_NO_DATA No data available + /// @retval #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// @see push_service_notify_cb() + /// @see push_service_request_unread_notification() + int push_service_get_notification_session_info( + ffi.Pointer notification, + ffi.Pointer> session_info, + ) { + return _push_service_get_notification_session_info( + notification, + session_info, + ); + } + + late final _push_service_get_notification_session_info_ptr = _lookup< + ffi.NativeFunction<_c_push_service_get_notification_session_info>>( + 'push_service_get_notification_session_info'); + late final _dart_push_service_get_notification_session_info + _push_service_get_notification_session_info = + _push_service_get_notification_session_info_ptr + .asFunction<_dart_push_service_get_notification_session_info>(); + + /// @brief Gets the request ID assigned by the sender. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a request_id using free(). + /// @param[in] notification The notification handle + /// @param[out] request_id The request ID\n + /// Set @c NULL if error but #PUSH_SERVICE_ERROR_INVALID_PARAMETER + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PUSH_SERVICE_ERROR_NONE Successful + /// @retval #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PUSH_SERVICE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PUSH_SERVICE_ERROR_NO_DATA No data available + /// @retval #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// @see push_service_notify_cb() + /// @see push_service_request_unread_notification() + int push_service_get_notification_request_id( + ffi.Pointer notification, + ffi.Pointer> request_id, + ) { + return _push_service_get_notification_request_id( + notification, + request_id, + ); + } + + late final _push_service_get_notification_request_id_ptr = + _lookup>( + 'push_service_get_notification_request_id'); + late final _dart_push_service_get_notification_request_id + _push_service_get_notification_request_id = + _push_service_get_notification_request_id_ptr + .asFunction<_dart_push_service_get_notification_request_id>(); + + /// @brief Gets the value in the type field of the notification + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] notification The notification handle + /// @param[out] type The type value assigned by the sender + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PUSH_SERVICE_ERROR_NONE Successful + /// @retval #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PUSH_SERVICE_ERROR_NO_DATA No data available + /// @retval #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// @see push_service_notify_cb() + /// @see push_service_request_unread_notification() + int push_service_get_notification_type( + ffi.Pointer notification, + ffi.Pointer type, + ) { + return _push_service_get_notification_type( + notification, + type, + ); + } + + late final _push_service_get_notification_type_ptr = + _lookup>( + 'push_service_get_notification_type'); + late final _dart_push_service_get_notification_type + _push_service_get_notification_type = + _push_service_get_notification_type_ptr + .asFunction<_dart_push_service_get_notification_type>(); + + /// @brief Gets an unread notification message from the push server. + /// @details If an application receives an unread message with this method, the message is removed from the system. \n + /// This method can be called repeatedly until it returns PUSH_SERVICE_ERROR_NO_DATA \n + /// But, this method does NOT guarantee order and reliability of notification messages. \n + /// Some notification messages can be dropped when the system message queue is full. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks It is recommended to use push_service_request_unread_notification(). + /// @remarks You must release @a noti using push_service_free_notification(). + /// @param[in] connection The connection handle to the push service + /// @param[out] noti The notification handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PUSH_SERVICE_ERROR_NONE Successful + /// @retval #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PUSH_SERVICE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PUSH_SERVICE_ERROR_NO_DATA No data available + /// @retval #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// + /// @see push_service_get_notification_message() + /// @see push_service_get_notification_time() + /// @see push_service_get_notification_data() + int push_service_get_unread_notification( + ffi.Pointer connection, + ffi.Pointer> noti, + ) { + return _push_service_get_unread_notification( + connection, + noti, + ); + } + + late final _push_service_get_unread_notification_ptr = + _lookup>( + 'push_service_get_unread_notification'); + late final _dart_push_service_get_unread_notification + _push_service_get_unread_notification = + _push_service_get_unread_notification_ptr + .asFunction<_dart_push_service_get_unread_notification>(); + + /// @brief Requests unread notification messages to the push server. + /// @details When the app wants to receive messages that arrived before it launched, this \n + /// method should be called. Upon receiving this request, the daemon sends messages\n + /// stored in its DB to the app. The notify_callback() method assigned in push_service_connect()\n + /// will be called when these messages arrive. No need to call this method multiple\n + /// times to receive multiple messages. This method does NOT guarantee order and\n + /// reliability of notification messages. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This method is preferred to push_service_get_unread_notification(). + /// @param[in] connection The connection handle to the push service + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PUSH_SERVICE_ERROR_NONE Successful + /// @retval #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PUSH_SERVICE_ERROR_NOT_CONNECTED Not connected to the daemon + /// @retval #PUSH_SERVICE_ERROR_OPERATION_FAILED Error when sending the request + /// @retval #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + /// + /// @see push_service_get_unread_notification() + /// @see push_service_connect() + int push_service_request_unread_notification( + ffi.Pointer connection, + ) { + return _push_service_request_unread_notification( + connection, + ); + } + + late final _push_service_request_unread_notification_ptr = + _lookup>( + 'push_service_request_unread_notification'); + late final _dart_push_service_request_unread_notification + _push_service_request_unread_notification = + _push_service_request_unread_notification_ptr + .asFunction<_dart_push_service_request_unread_notification>(); + + /// @brief Gets the registration ID in the PUSH_SERVICE_STATE_REGISTERED state. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a reg_id using free(). + /// @param[in] connection The connection handle to the push service + /// @param[out] reg_id The registration ID\n + /// Set NULL if error but PUSH_SERVICE_ERROR_INVALID_PARAMETER + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PUSH_SERVICE_ERROR_NONE Successful + /// @retval #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PUSH_SERVICE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PUSH_SERVICE_ERROR_NO_DATA No registration ID available + /// @retval #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + int push_service_get_registration_id( + ffi.Pointer connection, + ffi.Pointer> reg_id, + ) { + return _push_service_get_registration_id( + connection, + reg_id, + ); + } + + late final _push_service_get_registration_id_ptr = + _lookup>( + 'push_service_get_registration_id'); + late final _dart_push_service_get_registration_id + _push_service_get_registration_id = _push_service_get_registration_id_ptr + .asFunction<_dart_push_service_get_registration_id>(); + + /// @brief Frees the notification handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remark The specific error code can be obtained using the get_last_result()\n + /// Error codes are described in the exception section. + /// @param[in] noti The notification handle + /// @exception #PUSH_SERVICE_ERROR_NONE Successful + /// @exception #PUSH_SERVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #PUSH_SERVICE_ERROR_NOT_SUPPORTED Not supported feature + void push_service_free_notification( + ffi.Pointer noti, + ) { + return _push_service_free_notification( + noti, + ); + } + + late final _push_service_free_notification_ptr = + _lookup>( + 'push_service_free_notification'); + late final _dart_push_service_free_notification + _push_service_free_notification = _push_service_free_notification_ptr + .asFunction<_dart_push_service_free_notification>(); + + /// @brief Gets the maximum volume level supported for a particular sound type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] type The sound type + /// @param[out] max The maximum volume level + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see sound_manager_set_volume() + /// @see sound_manager_get_volume() + int sound_manager_get_max_volume( + int type, + ffi.Pointer max, + ) { + return _sound_manager_get_max_volume( + type, + max, + ); + } + + late final _sound_manager_get_max_volume_ptr = + _lookup>( + 'sound_manager_get_max_volume'); + late final _dart_sound_manager_get_max_volume _sound_manager_get_max_volume = + _sound_manager_get_max_volume_ptr + .asFunction<_dart_sound_manager_get_max_volume>(); + + /// @brief Sets the volume level specified for a particular sound type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/volume.set + /// @param[in] type The sound type + /// @param[in] volume The volume level to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_get_max_volume() + /// @see sound_manager_get_volume() + int sound_manager_set_volume( + int type, + int volume, + ) { + return _sound_manager_set_volume( + type, + volume, + ); + } + + late final _sound_manager_set_volume_ptr = + _lookup>( + 'sound_manager_set_volume'); + late final _dart_sound_manager_set_volume _sound_manager_set_volume = + _sound_manager_set_volume_ptr + .asFunction<_dart_sound_manager_set_volume>(); + + /// @brief Gets the volume level specified for a particular sound type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] type The sound type + /// @param[out] volume The current volume level + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_get_max_volume() + /// @see sound_manager_set_volume() + int sound_manager_get_volume( + int type, + ffi.Pointer volume, + ) { + return _sound_manager_get_volume( + type, + volume, + ); + } + + late final _sound_manager_get_volume_ptr = + _lookup>( + 'sound_manager_get_volume'); + late final _dart_sound_manager_get_volume _sound_manager_get_volume = + _sound_manager_get_volume_ptr + .asFunction<_dart_sound_manager_get_volume>(); + + /// @deprecated Deprecated since 3.0. + /// @brief Sets the type of the sound being currently played. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] type The sound type to set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_get_current_sound_type() + /// @see sound_manager_unset_current_sound_type() + int sound_manager_set_current_sound_type( + int type, + ) { + return _sound_manager_set_current_sound_type( + type, + ); + } + + late final _sound_manager_set_current_sound_type_ptr = + _lookup>( + 'sound_manager_set_current_sound_type'); + late final _dart_sound_manager_set_current_sound_type + _sound_manager_set_current_sound_type = + _sound_manager_set_current_sound_type_ptr + .asFunction<_dart_sound_manager_set_current_sound_type>(); + + /// @brief Gets the type of the sound being currently played. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] type The current sound type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_NO_PLAYING_SOUND No playing sound + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + int sound_manager_get_current_sound_type( + ffi.Pointer type, + ) { + return _sound_manager_get_current_sound_type( + type, + ); + } + + late final _sound_manager_get_current_sound_type_ptr = + _lookup>( + 'sound_manager_get_current_sound_type'); + late final _dart_sound_manager_get_current_sound_type + _sound_manager_get_current_sound_type = + _sound_manager_get_current_sound_type_ptr + .asFunction<_dart_sound_manager_get_current_sound_type>(); + + /// @deprecated Deprecated since 3.0. + /// @brief Unsets the type of the sound being currently played. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_set_current_sound_type() + /// @see sound_manager_get_current_sound_type() + int sound_manager_unset_current_sound_type() { + return _sound_manager_unset_current_sound_type(); + } + + late final _sound_manager_unset_current_sound_type_ptr = + _lookup>( + 'sound_manager_unset_current_sound_type'); + late final _dart_sound_manager_unset_current_sound_type + _sound_manager_unset_current_sound_type = + _sound_manager_unset_current_sound_type_ptr + .asFunction<_dart_sound_manager_unset_current_sound_type>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_add_volume_changed_cb() instead. + /// @brief Registers a callback function to be invoked when the volume level is changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] callback Callback function to indicate change in volume + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @post sound_manager_volume_changed_cb() will be invoked. + /// @see sound_manager_unset_volume_changed_cb() + /// @see sound_manager_volume_changed_cb() + int sound_manager_set_volume_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _sound_manager_set_volume_changed_cb( + callback, + user_data, + ); + } + + late final _sound_manager_set_volume_changed_cb_ptr = + _lookup>( + 'sound_manager_set_volume_changed_cb'); + late final _dart_sound_manager_set_volume_changed_cb + _sound_manager_set_volume_changed_cb = + _sound_manager_set_volume_changed_cb_ptr + .asFunction<_dart_sound_manager_set_volume_changed_cb>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_remove_volume_changed_cb() instead. + /// @brief Unregisters the volume change callback. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @return 0 on success, otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_set_volume_changed_cb() + int sound_manager_unset_volume_changed_cb() { + return _sound_manager_unset_volume_changed_cb(); + } + + late final _sound_manager_unset_volume_changed_cb_ptr = + _lookup>( + 'sound_manager_unset_volume_changed_cb'); + late final _dart_sound_manager_unset_volume_changed_cb + _sound_manager_unset_volume_changed_cb = + _sound_manager_unset_volume_changed_cb_ptr + .asFunction<_dart_sound_manager_unset_volume_changed_cb>(); + + /// @brief Adds a callback function to be invoked when the volume level is changed. + /// @since_tizen 3.0 + /// @param[in] callback Callback function to indicate change in volume + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] id The callback id + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @post sound_manager_volume_changed_cb() will be invoked. + /// @see sound_manager_remove_volume_changed_cb() + /// @see sound_manager_volume_changed_cb() + int sound_manager_add_volume_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, + ) { + return _sound_manager_add_volume_changed_cb( + callback, + user_data, + id, + ); + } + + late final _sound_manager_add_volume_changed_cb_ptr = + _lookup>( + 'sound_manager_add_volume_changed_cb'); + late final _dart_sound_manager_add_volume_changed_cb + _sound_manager_add_volume_changed_cb = + _sound_manager_add_volume_changed_cb_ptr + .asFunction<_dart_sound_manager_add_volume_changed_cb>(); + + /// @brief Removes the volume change callback. + /// @since_tizen 3.0 + /// @param[in] id The id of the callback to remove + /// @return 0 on success, otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_add_volume_changed_cb() + int sound_manager_remove_volume_changed_cb( + int id, + ) { + return _sound_manager_remove_volume_changed_cb( + id, + ); + } + + late final _sound_manager_remove_volume_changed_cb_ptr = + _lookup>( + 'sound_manager_remove_volume_changed_cb'); + late final _dart_sound_manager_remove_volume_changed_cb + _sound_manager_remove_volume_changed_cb = + _sound_manager_remove_volume_changed_cb_ptr + .asFunction<_dart_sound_manager_remove_volume_changed_cb>(); + + /// @brief Creates a handle for stream information. + /// @since_tizen 3.0 + /// + /// @remarks The registered callback is issued in the internal thread of the sound manager.\n + /// Do not call this function within sound_stream_focus_state_changed_cb() or sound_stream_focus_state_watch_cb(),\n + /// otherwise #SOUND_MANAGER_ERROR_INVALID_OPERATION will be returned.\n + /// To apply the stream policy according to this stream information, this handle should be passed to other APIs\n + /// related to playback or recording.(e.g. player, wav-player, audio-io, etc.) + /// + /// @param[in] stream_type The type of stream + /// @param[in] callback The focus state change callback function (optional, this can be NULL) + /// @param[in] user_data The user data to be passed to the callback function (optional, this can be NULL) + /// @param[out] stream_info The handle of stream information + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #SOUND_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_destroy_stream_information() + /// @see sound_manager_add_device_for_stream_routing() + /// @see sound_manager_remove_device_for_stream_routing() + /// @see sound_manager_remove_all_devices_for_stream_routing() + /// @see sound_manager_apply_stream_routing() + /// @see sound_manager_acquire_focus() + /// @see sound_manager_release_focus() + /// @see sound_manager_get_focus_state() + int sound_manager_create_stream_information( + int stream_type, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ffi.Pointer> stream_info, + ) { + return _sound_manager_create_stream_information( + stream_type, + callback, + user_data, + stream_info, + ); + } + + late final _sound_manager_create_stream_information_ptr = + _lookup>( + 'sound_manager_create_stream_information'); + late final _dart_sound_manager_create_stream_information + _sound_manager_create_stream_information = + _sound_manager_create_stream_information_ptr + .asFunction<_dart_sound_manager_create_stream_information>(); + + /// @brief Destroys the handle for stream information. + /// @since_tizen 3.0 + /// + /// @remarks Do not call this function within sound_stream_focus_state_changed_cb() or sound_stream_focus_state_watch_cb(),\n + /// otherwise #SOUND_MANAGER_ERROR_INVALID_OPERATION will be returned. + /// + /// @param[in] stream_info The handle of stream information + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_create_stream_information() + /// @see sound_manager_add_device_for_stream_routing() + /// @see sound_manager_remove_device_for_stream_routing() + /// @see sound_manager_remove_all_devices_for_stream_routing() + /// @see sound_manager_apply_stream_routing() + /// @see sound_manager_acquire_focus() + /// @see sound_manager_release_focus() + /// @see sound_manager_get_focus_state() + int sound_manager_destroy_stream_information( + ffi.Pointer stream_info, + ) { + return _sound_manager_destroy_stream_information( + stream_info, + ); + } + + late final _sound_manager_destroy_stream_information_ptr = + _lookup>( + 'sound_manager_destroy_stream_information'); + late final _dart_sound_manager_destroy_stream_information + _sound_manager_destroy_stream_information = + _sound_manager_destroy_stream_information_ptr + .asFunction<_dart_sound_manager_destroy_stream_information>(); + + /// @brief Gets the sound type of the stream information. + /// @since_tizen 3.0 + /// + /// @remarks In case of a @a stream_info made with #SOUND_STREAM_TYPE_EMERGENCY, it'll return #SOUND_MANAGER_ERROR_NO_DATA.\n + /// The reason is that there is no #sound_type_e matched with this @a stream_info. + /// + /// @param[in] stream_info The handle of stream information + /// @param[out] sound_type The sound type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_NO_DATA No data + /// @pre Call sound_manager_create_stream_information() before calling this function. + /// @see sound_manager_create_stream_information() + /// @see sound_manager_set_volume() + /// @see sound_manager_get_max_volume() + /// @see sound_manager_get_volume() + int sound_manager_get_sound_type( + ffi.Pointer stream_info, + ffi.Pointer sound_type, + ) { + return _sound_manager_get_sound_type( + stream_info, + sound_type, + ); + } + + late final _sound_manager_get_sound_type_ptr = + _lookup>( + 'sound_manager_get_sound_type'); + late final _dart_sound_manager_get_sound_type _sound_manager_get_sound_type = + _sound_manager_get_sound_type_ptr + .asFunction<_dart_sound_manager_get_sound_type>(); + + /// @brief Adds the device to the stream information for the stream routing. + /// @since_tizen 3.0 + /// + /// @remarks Use sound_manager_get_device_list() and sound_manager_get_next_device() to get the device.\n + /// #SOUND_MANAGER_ERROR_POLICY could be returned according to the stream type of the @a stream_info.\n + /// The available types of the @a stream_info for this function are #SOUND_STREAM_TYPE_VOIP and #SOUND_STREAM_TYPE_MEDIA_EXTERNAL_ONLY. + /// + /// @param[in] stream_info The handle of stream information + /// @param[in] device The device item from sound_device_list_h + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy + /// @pre Call sound_manager_create_stream_information() before calling this function. + /// @post You can apply this setting by calling sound_manager_apply_stream_routing(). + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + /// @see sound_manager_remove_device_for_stream_routing() + /// @see sound_manager_remove_all_devices_for_stream_routing() + /// @see sound_manager_apply_stream_routing() + int sound_manager_add_device_for_stream_routing( + ffi.Pointer stream_info, + ffi.Pointer device, + ) { + return _sound_manager_add_device_for_stream_routing( + stream_info, + device, + ); + } + + late final _sound_manager_add_device_for_stream_routing_ptr = _lookup< + ffi.NativeFunction<_c_sound_manager_add_device_for_stream_routing>>( + 'sound_manager_add_device_for_stream_routing'); + late final _dart_sound_manager_add_device_for_stream_routing + _sound_manager_add_device_for_stream_routing = + _sound_manager_add_device_for_stream_routing_ptr + .asFunction<_dart_sound_manager_add_device_for_stream_routing>(); + + /// @brief Removes the device from the stream information for the stream routing. + /// @since_tizen 3.0 + /// + /// @remarks Use sound_manager_get_device_list() and sound_manager_get_next_device() to get the device.\n + /// + /// @param[in] stream_info The handle of stream information + /// @param[in] device The device item from sound_device_list_h + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre Call sound_manager_create_stream_information() and sound_manager_add_device_for_stream_routing() before calling this function. + /// @post You can apply this setting by calling sound_manager_apply_stream_routing(). + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + /// @see sound_manager_add_device_for_stream_routing() + /// @see sound_manager_remove_all_devices_for_stream_routing() + /// @see sound_manager_apply_stream_routing() + int sound_manager_remove_device_for_stream_routing( + ffi.Pointer stream_info, + ffi.Pointer device, + ) { + return _sound_manager_remove_device_for_stream_routing( + stream_info, + device, + ); + } + + late final _sound_manager_remove_device_for_stream_routing_ptr = _lookup< + ffi.NativeFunction< + _c_sound_manager_remove_device_for_stream_routing>>( + 'sound_manager_remove_device_for_stream_routing'); + late final _dart_sound_manager_remove_device_for_stream_routing + _sound_manager_remove_device_for_stream_routing = + _sound_manager_remove_device_for_stream_routing_ptr + .asFunction<_dart_sound_manager_remove_device_for_stream_routing>(); + + /// @brief Removes all devices from the stream information for the stream routing. + /// @since_tizen 4.0 + /// + /// @param[in] stream_info The handle of stream information + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy + /// @pre Call sound_manager_create_stream_information() before calling this function. + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + /// @see sound_manager_add_device_for_stream_routing() + /// @see sound_manager_remove_device_for_stream_routing() + /// @see sound_manager_apply_stream_routing() + int sound_manager_remove_all_devices_for_stream_routing( + ffi.Pointer stream_info, + ) { + return _sound_manager_remove_all_devices_for_stream_routing( + stream_info, + ); + } + + late final _sound_manager_remove_all_devices_for_stream_routing_ptr = _lookup< + ffi.NativeFunction< + _c_sound_manager_remove_all_devices_for_stream_routing>>( + 'sound_manager_remove_all_devices_for_stream_routing'); + late final _dart_sound_manager_remove_all_devices_for_stream_routing + _sound_manager_remove_all_devices_for_stream_routing = + _sound_manager_remove_all_devices_for_stream_routing_ptr.asFunction< + _dart_sound_manager_remove_all_devices_for_stream_routing>(); + + /// @brief Applies the stream routing. + /// @since_tizen 3.0 + /// + /// @remarks If the stream has not been made yet, this setting will be applied when the stream starts to play.\n + /// + /// @param[in] stream_info The handle of stream information + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INVALID_STATE Invalid state + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @pre Call sound_manager_create_stream_information() and sound_manager_add_device_for_stream_routing() before calling this function. + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + /// @see sound_manager_add_device_for_stream_routing() + /// @see sound_manager_remove_device_for_stream_routing() + /// @see sound_manager_remove_all_devices_for_stream_routing() + int sound_manager_apply_stream_routing( + ffi.Pointer stream_info, + ) { + return _sound_manager_apply_stream_routing( + stream_info, + ); + } + + late final _sound_manager_apply_stream_routing_ptr = + _lookup>( + 'sound_manager_apply_stream_routing'); + late final _dart_sound_manager_apply_stream_routing + _sound_manager_apply_stream_routing = + _sound_manager_apply_stream_routing_ptr + .asFunction<_dart_sound_manager_apply_stream_routing>(); + + /// @brief Acquires the stream focus. + /// @since_tizen 3.0 + /// + /// @remarks Do not call this function within sound_stream_focus_state_changed_cb() or sound_stream_focus_state_watch_cb(),\n + /// otherwise #SOUND_MANAGER_ERROR_INVALID_OPERATION will be returned. Since 4.0, it is allowed and does not return the error. + /// + /// @param[in] stream_info The handle of stream information + /// @param[in] focus_mask The focus mask that user wants to acquire + /// @param[in] sound_behavior The requesting sound behavior, values of #sound_behavior_e combined with bitwise 'or' + /// @param[in] extra_info The extra information for this request (optional, this can be NULL) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #SOUND_MANAGER_ERROR_INVALID_STATE Invalid state + /// @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @pre Call sound_manager_create_stream_information() with its parameter for sound_stream_focus_state_changed_cb\n + /// before calling this function. + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + /// @see sound_manager_acquire_focus_all() + /// @see sound_manager_release_focus() + /// @see sound_manager_release_focus_all() + /// @see sound_manager_get_focus_state() + int sound_manager_acquire_focus( + ffi.Pointer stream_info, + int focus_mask, + int sound_behavior, + ffi.Pointer extra_info, + ) { + return _sound_manager_acquire_focus( + stream_info, + focus_mask, + sound_behavior, + extra_info, + ); + } + + late final _sound_manager_acquire_focus_ptr = + _lookup>( + 'sound_manager_acquire_focus'); + late final _dart_sound_manager_acquire_focus _sound_manager_acquire_focus = + _sound_manager_acquire_focus_ptr + .asFunction<_dart_sound_manager_acquire_focus>(); + + /// @brief Releases the acquired stream focus. + /// @since_tizen 3.0 + /// + /// @remarks Do not call this function within sound_stream_focus_state_changed_cb() or sound_stream_focus_state_watch_cb(),\n + /// otherwise #SOUND_MANAGER_ERROR_INVALID_OPERATION will be returned. Since 4.0, it is allowed and does not return the error. + /// + /// @param[in] stream_info The handle of stream information + /// @param[in] focus_mask The focus mask that user wants to release + /// @param[in] sound_behavior The requesting sound behavior, values of #sound_behavior_e combined with bitwise 'or' + /// @param[in] extra_info The extra information for this request (optional, this can be NULL) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #SOUND_MANAGER_ERROR_INVALID_STATE Invalid state + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @pre Call sound_manager_create_stream_information() and sound_manager_acquire_focus() before calling this function. + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + /// @see sound_manager_acquire_focus() + /// @see sound_manager_acquire_focus_all() + /// @see sound_manager_release_focus_all() + /// @see sound_manager_get_focus_state() + int sound_manager_release_focus( + ffi.Pointer stream_info, + int focus_mask, + int sound_behavior, + ffi.Pointer extra_info, + ) { + return _sound_manager_release_focus( + stream_info, + focus_mask, + sound_behavior, + extra_info, + ); + } + + late final _sound_manager_release_focus_ptr = + _lookup>( + 'sound_manager_release_focus'); + late final _dart_sound_manager_release_focus _sound_manager_release_focus = + _sound_manager_release_focus_ptr + .asFunction<_dart_sound_manager_release_focus>(); + + /// @brief Acquires all the stream focuses. + /// @since_tizen 4.0 + /// + /// @remarks This function does not return error even though one or all of focuses have already been acquired.\n + /// Use sound_manager_get_focus_state() to get acquired focus state if it returns #SOUND_MANAGER_ERROR_POLICY. + /// + /// @param[in] stream_info The handle of stream information + /// @param[in] sound_behavior The requesting sound behavior, values of #sound_behavior_e combined with bitwise 'or' + /// @param[in] extra_info The extra information for this request (optional, this can be NULL) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @pre Call sound_manager_create_stream_information() with its parameter for sound_stream_focus_state_changed_cb\n + /// before calling this function. + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + /// @see sound_manager_acquire_focus() + /// @see sound_manager_release_focus() + /// @see sound_manager_release_focus_all() + /// @see sound_manager_get_focus_state() + int sound_manager_acquire_focus_all( + ffi.Pointer stream_info, + int sound_behavior, + ffi.Pointer extra_info, + ) { + return _sound_manager_acquire_focus_all( + stream_info, + sound_behavior, + extra_info, + ); + } + + late final _sound_manager_acquire_focus_all_ptr = + _lookup>( + 'sound_manager_acquire_focus_all'); + late final _dart_sound_manager_acquire_focus_all + _sound_manager_acquire_focus_all = _sound_manager_acquire_focus_all_ptr + .asFunction<_dart_sound_manager_acquire_focus_all>(); + + /// @brief Releases all the acquired stream focuses. + /// @since_tizen 4.0 + /// + /// @remarks This function does not return error even though one or all of focuses have already been released. + /// + /// @param[in] stream_info The handle of stream information + /// @param[in] sound_behavior The requesting sound behavior, values of #sound_behavior_e combined with bitwise 'or' + /// @param[in] extra_info The extra information for this request (optional, this can be NULL) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @pre Call sound_manager_create_stream_information(), sound_manager_acquire_focus() and sound_manager_acquire_focus_all()\n + /// before calling this function. + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + /// @see sound_manager_acquire_focus() + /// @see sound_manager_acquire_focus_all() + /// @see sound_manager_release_focus() + /// @see sound_manager_get_focus_state() + int sound_manager_release_focus_all( + ffi.Pointer stream_info, + int sound_behavior, + ffi.Pointer extra_info, + ) { + return _sound_manager_release_focus_all( + stream_info, + sound_behavior, + extra_info, + ); + } + + late final _sound_manager_release_focus_all_ptr = + _lookup>( + 'sound_manager_release_focus_all'); + late final _dart_sound_manager_release_focus_all + _sound_manager_release_focus_all = _sound_manager_release_focus_all_ptr + .asFunction<_dart_sound_manager_release_focus_all>(); + + /// @brief Gets the state of focus. + /// @since_tizen 3.0 + /// @param[in] stream_info The handle of stream information + /// @param[out] state_for_playback The state of playback focus + /// @param[out] state_for_recording The state of recording focus + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre Call sound_manager_create_stream_information() before calling this function. + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + /// @see sound_manager_acquire_focus() + /// @see sound_manager_release_focus() + int sound_manager_get_focus_state( + ffi.Pointer stream_info, + ffi.Pointer state_for_playback, + ffi.Pointer state_for_recording, + ) { + return _sound_manager_get_focus_state( + stream_info, + state_for_playback, + state_for_recording, + ); + } + + late final _sound_manager_get_focus_state_ptr = + _lookup>( + 'sound_manager_get_focus_state'); + late final _dart_sound_manager_get_focus_state + _sound_manager_get_focus_state = _sound_manager_get_focus_state_ptr + .asFunction<_dart_sound_manager_get_focus_state>(); + + /// @brief Sets auto focus reacquisition property. + /// @since_tizen 3.0 + /// + /// @remarks The focus reacquisition is set as default. + /// If you don't want to reacquire the focus you've lost automatically, disable the focus reacquisition setting by using this function and vice versa. + /// + /// @param[in] stream_info The handle of stream information + /// @param[in] enable The auto focus reacquisition property to set : (@c true = enable, @c false = disable) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre Call sound_manager_create_stream_information() before calling this function. + /// @see sound_manager_create_stream_information() + int sound_manager_set_focus_reacquisition( + ffi.Pointer stream_info, + bool enable, + ) { + return _sound_manager_set_focus_reacquisition( + stream_info, + enable ? 1 : 0, + ); + } + + late final _sound_manager_set_focus_reacquisition_ptr = + _lookup>( + 'sound_manager_set_focus_reacquisition'); + late final _dart_sound_manager_set_focus_reacquisition + _sound_manager_set_focus_reacquisition = + _sound_manager_set_focus_reacquisition_ptr + .asFunction<_dart_sound_manager_set_focus_reacquisition>(); + + /// @brief Gets auto focus reacquisition property. + /// @since_tizen 3.0 + /// + /// @remarks The default value is true. + /// + /// @param[in] stream_info The handle of stream information + /// @param[out] enabled The value of focus auto reacquisition property : (@c true = enabled, @c false = disabled) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre Call sound_manager_create_stream_information() before calling this function. + /// @see sound_manager_create_stream_information() + int sound_manager_get_focus_reacquisition( + ffi.Pointer stream_info, + ffi.Pointer enabled, + ) { + return _sound_manager_get_focus_reacquisition( + stream_info, + enabled, + ); + } + + late final _sound_manager_get_focus_reacquisition_ptr = + _lookup>( + 'sound_manager_get_focus_reacquisition'); + late final _dart_sound_manager_get_focus_reacquisition + _sound_manager_get_focus_reacquisition = + _sound_manager_get_focus_reacquisition_ptr + .asFunction<_dart_sound_manager_get_focus_reacquisition>(); + + /// @brief Delivers focuses to another stream information. + /// @since_tizen 4.0 + /// + /// @remarks This function does not affect any invocation of sound_stream_focus_state_changed_cb() or\n + /// sound_stream_focus_state_watch_cb(). Do not call this function within sound_stream_focus_state_changed_cb() or\n + /// sound_stream_focus_state_watch_cb(), otherwise #SOUND_MANAGER_ERROR_INVALID_OPERATION will be returned. + /// + /// @param[in] source The source handle of stream information which has focuses + /// @param[in] destination The destination handle of stream information which will receive focuses + /// @param[in] focus_mask The focus mask to deliver + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #SOUND_MANAGER_ERROR_INVALID_STATE Invalid state + /// @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @pre Call sound_manager_create_stream_information(), sound_manager_acquire_focus() and sound_manager_acquire_focus_all()\n + /// before calling this function. + /// @see sound_manager_create_stream_information() + /// @see sound_manager_acquire_focus() + /// @see sound_manager_acquire_focus_all() + int sound_manager_deliver_focus( + ffi.Pointer source, + ffi.Pointer destination, + int focus_mask, + ) { + return _sound_manager_deliver_focus( + source, + destination, + focus_mask, + ); + } + + late final _sound_manager_deliver_focus_ptr = + _lookup>( + 'sound_manager_deliver_focus'); + late final _dart_sound_manager_deliver_focus _sound_manager_deliver_focus = + _sound_manager_deliver_focus_ptr + .asFunction<_dart_sound_manager_deliver_focus>(); + + /// @brief Checks if the stream information is using the device. + /// @since_tizen 3.0 + /// + /// @param[in] stream_info The handle of stream information + /// @param[in] device The device item + /// @param[out] is_on Whether the stream info is using the device or not : (@c true = use, @c false = not use) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_get_device_list() + /// @see sound_manager_get_next_device() + /// @see sound_manager_get_prev_device() + /// @see sound_manager_get_device_type() + /// @see sound_manager_get_device_io_direction() + /// @see sound_manager_get_device_id() + /// @see sound_manager_get_device_name() + /// @see sound_manager_free_device_list() + int sound_manager_is_stream_on_device( + ffi.Pointer stream_info, + ffi.Pointer device, + ffi.Pointer is_on, + ) { + return _sound_manager_is_stream_on_device( + stream_info, + device, + is_on, + ); + } + + late final _sound_manager_is_stream_on_device_ptr = + _lookup>( + 'sound_manager_is_stream_on_device'); + late final _dart_sound_manager_is_stream_on_device + _sound_manager_is_stream_on_device = + _sound_manager_is_stream_on_device_ptr + .asFunction<_dart_sound_manager_is_stream_on_device>(); + + /// @brief Gets the current device type for media playback stream. + /// @since_tizen 3.0 + /// + /// @param[out] device_type The output device type that a media playback stream can go out + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_NO_DATA No data + /// @see sound_manager_get_device_type() + /// @see sound_manager_get_device_io_direction() + /// @see sound_manager_get_device_id() + /// @see sound_manager_get_device_name() + int sound_manager_get_current_media_playback_device_type( + ffi.Pointer device_type, + ) { + return _sound_manager_get_current_media_playback_device_type( + device_type, + ); + } + + late final _sound_manager_get_current_media_playback_device_type_ptr = + _lookup< + ffi.NativeFunction< + _c_sound_manager_get_current_media_playback_device_type>>( + 'sound_manager_get_current_media_playback_device_type'); + late final _dart_sound_manager_get_current_media_playback_device_type + _sound_manager_get_current_media_playback_device_type = + _sound_manager_get_current_media_playback_device_type_ptr.asFunction< + _dart_sound_manager_get_current_media_playback_device_type>(); + + /// @brief Gets the reason for the current acquired playback focus. + /// @since_tizen 3.0 + /// + /// @remarks If there is no acquired playback focus in this system, it'll return #SOUND_MANAGER_ERROR_NO_DATA.\n + /// Do not call this function within sound_stream_focus_state_changed_cb() or sound_stream_focus_state_watch_cb(),\n + /// otherwise #SOUND_MANAGER_ERROR_INVALID_OPERATION will be returned.\n + /// The @a extra_info should be released using free(). + /// + /// @param[out] acquired_by The reason for the current acquired playback focus + /// @param[out] sound_behavior The requested sound behavior that should be followed, values of #sound_behavior_e combined with bitwise 'or' + /// @param[out] extra_info The extra information of the acquired playback focus (optional, this can be NULL) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #SOUND_MANAGER_ERROR_NO_DATA No data + /// @see sound_manager_get_current_recording_focus() + int sound_manager_get_current_playback_focus( + ffi.Pointer acquired_by, + ffi.Pointer sound_behavior, + ffi.Pointer> extra_info, + ) { + return _sound_manager_get_current_playback_focus( + acquired_by, + sound_behavior, + extra_info, + ); + } + + late final _sound_manager_get_current_playback_focus_ptr = + _lookup>( + 'sound_manager_get_current_playback_focus'); + late final _dart_sound_manager_get_current_playback_focus + _sound_manager_get_current_playback_focus = + _sound_manager_get_current_playback_focus_ptr + .asFunction<_dart_sound_manager_get_current_playback_focus>(); + + /// @brief Gets the reason for the current acquired recording focus. + /// @since_tizen 3.0 + /// + /// @remarks If there is no acquired recording focus in this system, it'll return #SOUND_MANAGER_ERROR_NO_DATA.\n + /// Do not call this function within sound_stream_focus_state_changed_cb() or sound_stream_focus_state_watch_cb(),\n + /// otherwise #SOUND_MANAGER_ERROR_INVALID_OPERATION will be returned.\n + /// The @a extra_info should be released using free(). + /// + /// @param[out] acquired_by The reason for the current acquired recording focus + /// @param[out] sound_behavior The requested sound behavior that should be followed, values of #sound_behavior_e combined with bitwise 'or' + /// @param[out] extra_info The extra information of the acquired recording focus (optional, this can be NULL) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #SOUND_MANAGER_ERROR_NO_DATA No data + /// @see sound_manager_get_current_playback_focus() + int sound_manager_get_current_recording_focus( + ffi.Pointer acquired_by, + ffi.Pointer sound_behavior, + ffi.Pointer> extra_info, + ) { + return _sound_manager_get_current_recording_focus( + acquired_by, + sound_behavior, + extra_info, + ); + } + + late final _sound_manager_get_current_recording_focus_ptr = + _lookup>( + 'sound_manager_get_current_recording_focus'); + late final _dart_sound_manager_get_current_recording_focus + _sound_manager_get_current_recording_focus = + _sound_manager_get_current_recording_focus_ptr + .asFunction<_dart_sound_manager_get_current_recording_focus>(); + + /// @brief Registers the watch callback function to be invoked when the focus state for each sound stream type is changed regardless of the process. + /// @since_tizen 3.0 + /// + /// @remarks The registered callback is invoked by the internal thread of the sound manager.\n + /// Do not call this function within sound_stream_focus_state_changed_cb() or sound_stream_focus_state_watch_cb(),\n + /// otherwise #SOUND_MANAGER_ERROR_INVALID_OPERATION will be returned. + /// + /// @param[in] focus_mask The focus mask that user wants to watch + /// @param[in] callback The focus state change watch callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] id The focus state change watch callback id + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_remove_focus_state_watch_cb() + int sound_manager_add_focus_state_watch_cb( + int focus_mask, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, + ) { + return _sound_manager_add_focus_state_watch_cb( + focus_mask, + callback, + user_data, + id, + ); + } + + late final _sound_manager_add_focus_state_watch_cb_ptr = + _lookup>( + 'sound_manager_add_focus_state_watch_cb'); + late final _dart_sound_manager_add_focus_state_watch_cb + _sound_manager_add_focus_state_watch_cb = + _sound_manager_add_focus_state_watch_cb_ptr + .asFunction<_dart_sound_manager_add_focus_state_watch_cb>(); + + /// @brief Unregisters the focus state change watch callback. + /// @since_tizen 3.0 + /// + /// @remarks Do not call this function within sound_stream_focus_state_changed_cb() or sound_stream_focus_state_watch_cb(),\n + /// otherwise #SOUND_MANAGER_ERROR_INVALID_OPERATION will be returned. + /// + /// @param[in] id The focus state change watch callback id + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_add_focus_state_watch_cb() + int sound_manager_remove_focus_state_watch_cb( + int id, + ) { + return _sound_manager_remove_focus_state_watch_cb( + id, + ); + } + + late final _sound_manager_remove_focus_state_watch_cb_ptr = + _lookup>( + 'sound_manager_remove_focus_state_watch_cb'); + late final _dart_sound_manager_remove_focus_state_watch_cb + _sound_manager_remove_focus_state_watch_cb = + _sound_manager_remove_focus_state_watch_cb_ptr + .asFunction<_dart_sound_manager_remove_focus_state_watch_cb>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_create_stream_information() instead. + /// @brief Sets the application's sound session type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] type The session type to set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy + /// @see sound_manager_get_session_type() + /// @see sound_manager_set_media_session_option() + /// @see sound_manager_get_media_session_option() + /// @see sound_manager_set_media_session_resumption_option() + /// @see sound_manager_get_media_session_resumption_option() + /// @see sound_manager_set_voip_session_mode() + /// @see sound_manager_get_voip_session_mode() + int sound_manager_set_session_type( + int type, + ) { + return _sound_manager_set_session_type( + type, + ); + } + + late final _sound_manager_set_session_type_ptr = + _lookup>( + 'sound_manager_set_session_type'); + late final _dart_sound_manager_set_session_type + _sound_manager_set_session_type = _sound_manager_set_session_type_ptr + .asFunction<_dart_sound_manager_set_session_type>(); + + /// @deprecated Deprecated since 3.0. + /// @brief Gets the application's sound session type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] type The session type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see sound_manager_set_session_type() + /// @see sound_manager_set_media_session_option() + /// @see sound_manager_get_media_session_option() + /// @see sound_manager_set_media_session_resumption_option() + /// @see sound_manager_get_media_session_resumption_option() + /// @see sound_manager_set_voip_session_mode() + /// @see sound_manager_get_voip_session_mode() + int sound_manager_get_session_type( + ffi.Pointer type, + ) { + return _sound_manager_get_session_type( + type, + ); + } + + late final _sound_manager_get_session_type_ptr = + _lookup>( + 'sound_manager_get_session_type'); + late final _dart_sound_manager_get_session_type + _sound_manager_get_session_type = _sound_manager_get_session_type_ptr + .asFunction<_dart_sound_manager_get_session_type>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_create_stream_information() instead. + /// @brief Sets the media sound session option. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] s_option The session option for starting + /// @param[in] d_option The session option for during play + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy + /// @see sound_manager_set_session_type() + /// @see sound_manager_get_session_type() + /// @see sound_manager_get_media_session_option() + /// @see sound_manager_set_media_session_resumption_option() + /// @see sound_manager_get_media_session_resumption_option() + int sound_manager_set_media_session_option( + int s_option, + int d_option, + ) { + return _sound_manager_set_media_session_option( + s_option, + d_option, + ); + } + + late final _sound_manager_set_media_session_option_ptr = + _lookup>( + 'sound_manager_set_media_session_option'); + late final _dart_sound_manager_set_media_session_option + _sound_manager_set_media_session_option = + _sound_manager_set_media_session_option_ptr + .asFunction<_dart_sound_manager_set_media_session_option>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_create_stream_information() instead. + /// @brief Gets the media sound session option. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] s_option The session option for starting + /// @param[out] d_option The session option for during play + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy + /// @see sound_manager_set_session_type() + /// @see sound_manager_get_session_type() + /// @see sound_manager_set_media_session_option() + /// @see sound_manager_set_media_session_resumption_option() + /// @see sound_manager_get_media_session_resumption_option() + int sound_manager_get_media_session_option( + ffi.Pointer s_option, + ffi.Pointer d_option, + ) { + return _sound_manager_get_media_session_option( + s_option, + d_option, + ); + } + + late final _sound_manager_get_media_session_option_ptr = + _lookup>( + 'sound_manager_get_media_session_option'); + late final _dart_sound_manager_get_media_session_option + _sound_manager_get_media_session_option = + _sound_manager_get_media_session_option_ptr + .asFunction<_dart_sound_manager_get_media_session_option>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_create_stream_information() instead. + /// @brief Sets the media sound session resumption option. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] option The session resumption option + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy + /// @see sound_manager_set_session_type() + /// @see sound_manager_get_session_type() + /// @see sound_manager_set_media_session_option() + /// @see sound_manager_get_media_session_option() + /// @see sound_manager_get_media_session_resumption_option() + int sound_manager_set_media_session_resumption_option( + int option, + ) { + return _sound_manager_set_media_session_resumption_option( + option, + ); + } + + late final _sound_manager_set_media_session_resumption_option_ptr = _lookup< + ffi.NativeFunction< + _c_sound_manager_set_media_session_resumption_option>>( + 'sound_manager_set_media_session_resumption_option'); + late final _dart_sound_manager_set_media_session_resumption_option + _sound_manager_set_media_session_resumption_option = + _sound_manager_set_media_session_resumption_option_ptr.asFunction< + _dart_sound_manager_set_media_session_resumption_option>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_create_stream_information() instead. + /// @brief Gets the media sound session resumption option. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] option The session resumption option + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy + /// @see sound_manager_set_session_type() + /// @see sound_manager_get_session_type() + /// @see sound_manager_set_media_session_option() + /// @see sound_manager_get_media_session_option() + /// @see sound_manager_set_media_session_resumption_option() + int sound_manager_get_media_session_resumption_option( + ffi.Pointer option, + ) { + return _sound_manager_get_media_session_resumption_option( + option, + ); + } + + late final _sound_manager_get_media_session_resumption_option_ptr = _lookup< + ffi.NativeFunction< + _c_sound_manager_get_media_session_resumption_option>>( + 'sound_manager_get_media_session_resumption_option'); + late final _dart_sound_manager_get_media_session_resumption_option + _sound_manager_get_media_session_resumption_option = + _sound_manager_get_media_session_resumption_option_ptr.asFunction< + _dart_sound_manager_get_media_session_resumption_option>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_create_stream_information() instead. + /// @brief Sets the mode of the voip sound session. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mode The voip session mode + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy + /// @pre Call sound_manager_set_session_type(#SOUND_SESSION_TYPE_VOIP) before calling this function. + /// @see sound_manager_set_session_type() + /// @see sound_manager_get_session_type() + /// @see sound_manager_get_voip_session_mode() + int sound_manager_set_voip_session_mode( + int mode, + ) { + return _sound_manager_set_voip_session_mode( + mode, + ); + } + + late final _sound_manager_set_voip_session_mode_ptr = + _lookup>( + 'sound_manager_set_voip_session_mode'); + late final _dart_sound_manager_set_voip_session_mode + _sound_manager_set_voip_session_mode = + _sound_manager_set_voip_session_mode_ptr + .asFunction<_dart_sound_manager_set_voip_session_mode>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_create_stream_information() instead. + /// @brief Gets the mode of the voip sound session. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] mode The voip session mode + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy + /// @pre Call sound_manager_set_session_type(#SOUND_SESSION_TYPE_VOIP) before calling this function. + /// @see sound_manager_set_session_type() + /// @see sound_manager_get_session_type() + /// @see sound_manager_set_voip_session_mode() + int sound_manager_get_voip_session_mode( + ffi.Pointer mode, + ) { + return _sound_manager_get_voip_session_mode( + mode, + ); + } + + late final _sound_manager_get_voip_session_mode_ptr = + _lookup>( + 'sound_manager_get_voip_session_mode'); + late final _dart_sound_manager_get_voip_session_mode + _sound_manager_get_voip_session_mode = + _sound_manager_get_voip_session_mode_ptr + .asFunction<_dart_sound_manager_get_voip_session_mode>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_create_stream_information() instead. + /// @brief Registers a callback function to be invoked when the sound session being played was interrupted. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] callback The interrupted callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy + /// @post sound_session_interrupted_cb() will be invoked. + /// @see sound_manager_unset_session_interrupted_cb() + /// @see sound_session_interrupted_cb() + int sound_manager_set_session_interrupted_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _sound_manager_set_session_interrupted_cb( + callback, + user_data, + ); + } + + late final _sound_manager_set_session_interrupted_cb_ptr = + _lookup>( + 'sound_manager_set_session_interrupted_cb'); + late final _dart_sound_manager_set_session_interrupted_cb + _sound_manager_set_session_interrupted_cb = + _sound_manager_set_session_interrupted_cb_ptr + .asFunction<_dart_sound_manager_set_session_interrupted_cb>(); + + /// @deprecated Deprecated since 3.0. + /// @brief Unregisters the callback function which is called when the sound session being played is interrupted. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @return 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_set_session_interrupted_cb() + int sound_manager_unset_session_interrupted_cb() { + return _sound_manager_unset_session_interrupted_cb(); + } + + late final _sound_manager_unset_session_interrupted_cb_ptr = _lookup< + ffi.NativeFunction<_c_sound_manager_unset_session_interrupted_cb>>( + 'sound_manager_unset_session_interrupted_cb'); + late final _dart_sound_manager_unset_session_interrupted_cb + _sound_manager_unset_session_interrupted_cb = + _sound_manager_unset_session_interrupted_cb_ptr + .asFunction<_dart_sound_manager_unset_session_interrupted_cb>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_get_device_list() instead. + /// @brief Gets the list consisting of connected devices. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks @a Calling this API will deallocate previously obtained list and each item.\n + /// Use sound_manager_get_next_device() to get the first node of the list. + /// + /// @param[in] device_mask The mask value + /// @param[out] device_list The list of connected devices + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_NO_DATA No data + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_get_next_device() + /// @see sound_manager_get_prev_device() + /// @see sound_manager_get_device_type() + /// @see sound_manager_get_device_io_direction() + /// @see sound_manager_get_device_id() + /// @see sound_manager_get_device_name() + int sound_manager_get_current_device_list( + int device_mask, + ffi.Pointer> device_list, + ) { + return _sound_manager_get_current_device_list( + device_mask, + device_list, + ); + } + + late final _sound_manager_get_current_device_list_ptr = + _lookup>( + 'sound_manager_get_current_device_list'); + late final _dart_sound_manager_get_current_device_list + _sound_manager_get_current_device_list = + _sound_manager_get_current_device_list_ptr + .asFunction<_dart_sound_manager_get_current_device_list>(); + + /// @brief Gets the list consisting of connected devices. + /// @since_tizen 3.0 + /// + /// @remarks @a device_list should be freed using sound_manager_free_device_list().\n + /// Use sound_manager_get_next_device() to get the first node of the list. + /// + /// @param[in] device_mask The mask values of #sound_device_mask_e combined with bitwise 'or' + /// @param[out] device_list The list of connected devices + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_NO_DATA No data + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_get_next_device() + /// @see sound_manager_get_prev_device() + /// @see sound_manager_get_device_type() + /// @see sound_manager_get_device_io_direction() + /// @see sound_manager_get_device_id() + /// @see sound_manager_get_device_name() + /// @see sound_manager_free_device_list() + int sound_manager_get_device_list( + int device_mask, + ffi.Pointer> device_list, + ) { + return _sound_manager_get_device_list( + device_mask, + device_list, + ); + } + + late final _sound_manager_get_device_list_ptr = + _lookup>( + 'sound_manager_get_device_list'); + late final _dart_sound_manager_get_device_list + _sound_manager_get_device_list = _sound_manager_get_device_list_ptr + .asFunction<_dart_sound_manager_get_device_list>(); + + /// @brief Frees device list and each item of list. + /// @since_tizen 3.0 + /// + /// @remarks This function will deallocate not only device list itself but also each item. + /// + /// @param[in] device_list The device list got with sound_manager_get_device_list. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// + /// @see sound_manager_get_device_list() + /// @see sound_manager_get_next_device() + /// @see sound_manager_get_prev_device() + /// @see sound_manager_get_device_type() + /// @see sound_manager_get_device_io_direction() + /// @see sound_manager_get_device_id() + /// @see sound_manager_get_device_name() + int sound_manager_free_device_list( + ffi.Pointer device_list, + ) { + return _sound_manager_free_device_list( + device_list, + ); + } + + late final _sound_manager_free_device_list_ptr = + _lookup>( + 'sound_manager_free_device_list'); + late final _dart_sound_manager_free_device_list + _sound_manager_free_device_list = _sound_manager_free_device_list_ptr + .asFunction<_dart_sound_manager_free_device_list>(); + + /// @brief Gets the next item of the device list. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] device_list The list of connected devices + /// @param[out] device The device item + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_NO_DATA No data + /// @see sound_manager_get_device_list() + /// @see sound_manager_get_prev_device() + /// @see sound_manager_get_device_type() + /// @see sound_manager_get_device_io_direction() + /// @see sound_manager_get_device_id() + /// @see sound_manager_get_device_name() + /// @see sound_manager_free_device_list() + int sound_manager_get_next_device( + ffi.Pointer device_list, + ffi.Pointer> device, + ) { + return _sound_manager_get_next_device( + device_list, + device, + ); + } + + late final _sound_manager_get_next_device_ptr = + _lookup>( + 'sound_manager_get_next_device'); + late final _dart_sound_manager_get_next_device + _sound_manager_get_next_device = _sound_manager_get_next_device_ptr + .asFunction<_dart_sound_manager_get_next_device>(); + + /// @brief Gets the previous item of the device list. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] device_list The list of connected devices + /// @param[out] device The device item + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_NO_DATA No data + /// @see sound_manager_get_device_list() + /// @see sound_manager_get_next_device() + /// @see sound_manager_get_device_type() + /// @see sound_manager_get_device_io_direction() + /// @see sound_manager_get_device_id() + /// @see sound_manager_get_device_name() + /// @see sound_manager_free_device_list() + int sound_manager_get_prev_device( + ffi.Pointer device_list, + ffi.Pointer> device, + ) { + return _sound_manager_get_prev_device( + device_list, + device, + ); + } + + late final _sound_manager_get_prev_device_ptr = + _lookup>( + 'sound_manager_get_prev_device'); + late final _dart_sound_manager_get_prev_device + _sound_manager_get_prev_device = _sound_manager_get_prev_device_ptr + .asFunction<_dart_sound_manager_get_prev_device>(); + + /// @brief Gets the type of the device. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] device The device item + /// @param[out] type The type of the device + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see sound_manager_get_device_list() + /// @see sound_manager_get_next_device() + /// @see sound_manager_get_prev_device() + /// @see sound_manager_get_device_io_direction() + /// @see sound_manager_get_device_id() + /// @see sound_manager_get_device_name() + /// @see sound_manager_free_device_list() + int sound_manager_get_device_type( + ffi.Pointer device, + ffi.Pointer type, + ) { + return _sound_manager_get_device_type( + device, + type, + ); + } + + late final _sound_manager_get_device_type_ptr = + _lookup>( + 'sound_manager_get_device_type'); + late final _dart_sound_manager_get_device_type + _sound_manager_get_device_type = _sound_manager_get_device_type_ptr + .asFunction<_dart_sound_manager_get_device_type>(); + + /// @brief Gets the io direction of the device. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] device The device item + /// @param[out] io_direction The io direction of the device + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see sound_manager_get_device_list() + /// @see sound_manager_get_next_device() + /// @see sound_manager_get_prev_device() + /// @see sound_manager_get_device_type() + /// @see sound_manager_get_device_id() + /// @see sound_manager_get_device_name() + /// @see sound_manager_free_device_list() + int sound_manager_get_device_io_direction( + ffi.Pointer device, + ffi.Pointer io_direction, + ) { + return _sound_manager_get_device_io_direction( + device, + io_direction, + ); + } + + late final _sound_manager_get_device_io_direction_ptr = + _lookup>( + 'sound_manager_get_device_io_direction'); + late final _dart_sound_manager_get_device_io_direction + _sound_manager_get_device_io_direction = + _sound_manager_get_device_io_direction_ptr + .asFunction<_dart_sound_manager_get_device_io_direction>(); + + /// @brief Gets the id of the device. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] device The device item + /// @param[out] id The id of the device + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see sound_manager_get_device_list() + /// @see sound_manager_get_next_device() + /// @see sound_manager_get_prev_device() + /// @see sound_manager_get_device_type() + /// @see sound_manager_get_device_io_direction() + /// @see sound_manager_get_device_name() + /// @see sound_manager_free_device_list() + int sound_manager_get_device_id( + ffi.Pointer device, + ffi.Pointer id, + ) { + return _sound_manager_get_device_id( + device, + id, + ); + } + + late final _sound_manager_get_device_id_ptr = + _lookup>( + 'sound_manager_get_device_id'); + late final _dart_sound_manager_get_device_id _sound_manager_get_device_id = + _sound_manager_get_device_id_ptr + .asFunction<_dart_sound_manager_get_device_id>(); + + /// @brief Gets the name of the device. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] device The device item + /// @param[out] name The name of the device + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_get_device_list() + /// @see sound_manager_get_next_device() + /// @see sound_manager_get_prev_device() + /// @see sound_manager_get_device_type() + /// @see sound_manager_get_device_io_direction() + /// @see sound_manager_get_device_id() + /// @see sound_manager_free_device_list() + int sound_manager_get_device_name( + ffi.Pointer device, + ffi.Pointer> name, + ) { + return _sound_manager_get_device_name( + device, + name, + ); + } + + late final _sound_manager_get_device_name_ptr = + _lookup>( + 'sound_manager_get_device_name'); + late final _dart_sound_manager_get_device_name + _sound_manager_get_device_name = _sound_manager_get_device_name_ptr + .asFunction<_dart_sound_manager_get_device_name>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Gets the state of the device. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] device The device item + /// @param[out] state The state of the device + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see sound_manager_get_device_list() + /// @see sound_manager_get_next_device() + /// @see sound_manager_get_prev_device() + /// @see sound_manager_get_device_type() + /// @see sound_manager_get_device_io_direction() + /// @see sound_manager_get_device_id() + /// @see sound_manager_get_device_name() + /// @see sound_manager_free_device_list() + int sound_manager_get_device_state( + ffi.Pointer device, + ffi.Pointer state, + ) { + return _sound_manager_get_device_state( + device, + state, + ); + } + + late final _sound_manager_get_device_state_ptr = + _lookup>( + 'sound_manager_get_device_state'); + late final _dart_sound_manager_get_device_state + _sound_manager_get_device_state = _sound_manager_get_device_state_ptr + .asFunction<_dart_sound_manager_get_device_state>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_add_device_connection_changed_cb() instead. + /// @brief Registers a callback function to be invoked when the state of connection of a sound device was changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The initial state of sound devices connected is deactivated. + /// + /// @param[in] device_mask The mask value + /// @param[in] callback The interrupted callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @post sound_device_connected_cb() will be invoked. + /// @see sound_manager_unset_device_connected_cb() + /// @see sound_device_connected_cb() + int sound_manager_set_device_connected_cb( + int device_mask, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _sound_manager_set_device_connected_cb( + device_mask, + callback, + user_data, + ); + } + + late final _sound_manager_set_device_connected_cb_ptr = + _lookup>( + 'sound_manager_set_device_connected_cb'); + late final _dart_sound_manager_set_device_connected_cb + _sound_manager_set_device_connected_cb = + _sound_manager_set_device_connected_cb_ptr + .asFunction<_dart_sound_manager_set_device_connected_cb>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_remove_device_connection_changed_cb() instead. + /// @brief Unregisters the callback function which is called when the state of connection of a sound device was changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_set_device_connected_cb() + int sound_manager_unset_device_connected_cb() { + return _sound_manager_unset_device_connected_cb(); + } + + late final _sound_manager_unset_device_connected_cb_ptr = + _lookup>( + 'sound_manager_unset_device_connected_cb'); + late final _dart_sound_manager_unset_device_connected_cb + _sound_manager_unset_device_connected_cb = + _sound_manager_unset_device_connected_cb_ptr + .asFunction<_dart_sound_manager_unset_device_connected_cb>(); + + /// @brief Adds a callback function to be invoked when the connection state of a sound device was changed. + /// @since_tizen 3.0 + /// + /// @param[in] device_mask Device masks for which changes should be tracked, values of #sound_device_mask_e combined with bitwise 'or' + /// @param[in] callback The device connection state changed callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] id The callback id + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @post sound_device_connected_cb() will be invoked. + /// @see sound_manager_remove_device_connection_changed_cb() + /// @see sound_device_connection_changed_cb() + int sound_manager_add_device_connection_changed_cb( + int device_mask, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ffi.Pointer id, + ) { + return _sound_manager_add_device_connection_changed_cb( + device_mask, + callback, + user_data, + id, + ); + } + + late final _sound_manager_add_device_connection_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_sound_manager_add_device_connection_changed_cb>>( + 'sound_manager_add_device_connection_changed_cb'); + late final _dart_sound_manager_add_device_connection_changed_cb + _sound_manager_add_device_connection_changed_cb = + _sound_manager_add_device_connection_changed_cb_ptr + .asFunction<_dart_sound_manager_add_device_connection_changed_cb>(); + + /// @brief Removes a callback function invoked when the connection of a sound device was changed. + /// @since_tizen 3.0 + /// + /// @param[in] id The id of the callback to remove + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_add_device_connection_changed_cb() + int sound_manager_remove_device_connection_changed_cb( + int id, + ) { + return _sound_manager_remove_device_connection_changed_cb( + id, + ); + } + + late final _sound_manager_remove_device_connection_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_sound_manager_remove_device_connection_changed_cb>>( + 'sound_manager_remove_device_connection_changed_cb'); + late final _dart_sound_manager_remove_device_connection_changed_cb + _sound_manager_remove_device_connection_changed_cb = + _sound_manager_remove_device_connection_changed_cb_ptr.asFunction< + _dart_sound_manager_remove_device_connection_changed_cb>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_add_device_state_changed_cb() instead. + /// @brief Registers a callback function to be invoked when the information of a sound device was changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] device_mask The mask value + /// @param[in] callback The interrupted callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @post sound_device_information_changed_cb() will be invoked. + /// @see sound_manager_unset_device_information_changed_cb() + /// @see sound_device_information_changed_cb() + int sound_manager_set_device_information_changed_cb( + int device_mask, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _sound_manager_set_device_information_changed_cb( + device_mask, + callback, + user_data, + ); + } + + late final _sound_manager_set_device_information_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_sound_manager_set_device_information_changed_cb>>( + 'sound_manager_set_device_information_changed_cb'); + late final _dart_sound_manager_set_device_information_changed_cb + _sound_manager_set_device_information_changed_cb = + _sound_manager_set_device_information_changed_cb_ptr + .asFunction<_dart_sound_manager_set_device_information_changed_cb>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_remove_device_state_changed_cb() instead. + /// @brief Unregisters the callback function which is called when the information of a sound device was changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_set_device_information_changed_cb() + int sound_manager_unset_device_information_changed_cb() { + return _sound_manager_unset_device_information_changed_cb(); + } + + late final _sound_manager_unset_device_information_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_sound_manager_unset_device_information_changed_cb>>( + 'sound_manager_unset_device_information_changed_cb'); + late final _dart_sound_manager_unset_device_information_changed_cb + _sound_manager_unset_device_information_changed_cb = + _sound_manager_unset_device_information_changed_cb_ptr.asFunction< + _dart_sound_manager_unset_device_information_changed_cb>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Adds a callback function to be invoked when the state of a sound device was changed. + /// @since_tizen 3.0 + /// + /// @param[in] device_mask Device masks for which changes should be tracked, values of #sound_device_mask_e combined with bitwise 'or' + /// @param[in] callback The device state changed callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] id The callback id + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @post sound_device_state_changed_cb() will be invoked. + /// @see sound_manager_remove_device_state_changed_cb() + /// @see sound_device_state_connected_cb() + int sound_manager_add_device_state_changed_cb( + int device_mask, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, + ) { + return _sound_manager_add_device_state_changed_cb( + device_mask, + callback, + user_data, + id, + ); + } + + late final _sound_manager_add_device_state_changed_cb_ptr = + _lookup>( + 'sound_manager_add_device_state_changed_cb'); + late final _dart_sound_manager_add_device_state_changed_cb + _sound_manager_add_device_state_changed_cb = + _sound_manager_add_device_state_changed_cb_ptr + .asFunction<_dart_sound_manager_add_device_state_changed_cb>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Removes a callback function invoked when the state of a sound device was changed. + /// @since_tizen 3.0 + /// + /// @param[in] id The id of the callback to remove + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SOUND_MANAGER_ERROR_NONE Success + /// @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system + /// @see sound_manager_add_device_state_changed_cb() + int sound_manager_remove_device_state_changed_cb( + int id, + ) { + return _sound_manager_remove_device_state_changed_cb( + id, + ); + } + + late final _sound_manager_remove_device_state_changed_cb_ptr = _lookup< + ffi.NativeFunction<_c_sound_manager_remove_device_state_changed_cb>>( + 'sound_manager_remove_device_state_changed_cb'); + late final _dart_sound_manager_remove_device_state_changed_cb + _sound_manager_remove_device_state_changed_cb = + _sound_manager_remove_device_state_changed_cb_ptr + .asFunction<_dart_sound_manager_remove_device_state_changed_cb>(); + + /// @brief Creates an audio device instance and returns an input handle to record PCM (pulse-code modulation) data. + /// + /// @details This function is used for audio input initialization. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// + /// @remarks @a input must be released using audio_in_destroy(). + /// + /// @param[in] sample_rate The audio sample rate in 8000[Hz] ~ 48000[Hz] + /// @param[in] channel The audio channel type (mono or stereo) + /// @param[in] type The type of audio sample (8- or 16-bit) + /// @param[out] input An audio input handle is created on success + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_PERMISSION_DENIED Permission denied + /// @retval #AUDIO_IO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #AUDIO_IO_ERROR_DEVICE_NOT_OPENED Device not opened + /// @retval #AUDIO_IO_ERROR_SOUND_POLICY Sound policy error + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// + /// @post The state will be #AUDIO_IO_STATE_IDLE.\n + /// audio_in_set_sound_stream_info() is recommended to be called after this API. + /// @see audio_in_destroy() + int audio_in_create( + int sample_rate, + int channel, + int type, + ffi.Pointer> input, + ) { + return _audio_in_create( + sample_rate, + channel, + type, + input, + ); + } + + late final _audio_in_create_ptr = + _lookup>('audio_in_create'); + late final _dart_audio_in_create _audio_in_create = + _audio_in_create_ptr.asFunction<_dart_audio_in_create>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_create_stream_information() instead. + /// @brief Creates an audio loopback device instance and returns an input handle to record PCM (pulse-code modulation) data. + /// + /// @details This function is used for audio loopback input initialization. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// + /// @remarks @a input must be released using audio_in_destroy(). + /// + /// @param[in] sample_rate The audio sample rate in 8000[Hz] ~ 48000[Hz] + /// @param[in] channel The audio channel type, mono, or stereo + /// @param[in] type The type of audio sample (8- or 16-bit) + /// @param[out] input An audio input handle will be created, if successful + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_PERMISSION_DENIED Permission denied + /// @retval #AUDIO_IO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #AUDIO_IO_ERROR_DEVICE_NOT_OPENED Device not opened + /// @retval #AUDIO_IO_ERROR_SOUND_POLICY Sound policy error + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// + /// @see audio_in_destroy() + int audio_in_create_loopback( + int sample_rate, + int channel, + int type, + ffi.Pointer> input, + ) { + return _audio_in_create_loopback( + sample_rate, + channel, + type, + input, + ); + } + + late final _audio_in_create_loopback_ptr = + _lookup>( + 'audio_in_create_loopback'); + late final _dart_audio_in_create_loopback _audio_in_create_loopback = + _audio_in_create_loopback_ptr + .asFunction<_dart_audio_in_create_loopback>(); + + /// @brief Releases the audio input handle and all its resources associated with an audio stream. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] input The handle to the audio input to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_DEVICE_NOT_CLOSED Device not closed + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// + /// @see audio_in_create() + int audio_in_destroy( + ffi.Pointer input, + ) { + return _audio_in_destroy( + input, + ); + } + + late final _audio_in_destroy_ptr = + _lookup>('audio_in_destroy'); + late final _dart_audio_in_destroy _audio_in_destroy = + _audio_in_destroy_ptr.asFunction<_dart_audio_in_destroy>(); + + /// @brief Sets the sound stream information to the audio input. + /// + /// @since_tizen 3.0 + /// + /// @remarks @a the sound stream information includes audio routing and volume type. + /// For more details, you can refer to @ref CAPI_MEDIA_SOUND_MANAGER_MODULE + /// System, Alarm, Notification, Emergency, Voice Information, Ringtone VOIP and Ringtone Call stream types are not supported in this API. + /// + /// @param[in] input The handle to the audio input + /// @param[in] stream_info The handle of stream information + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED_TYPE Not supported stream type + /// + /// @pre The state should be #AUDIO_IO_STATE_IDLE.\n + /// Call audio_in_create() before calling this function. + /// @post Call audio_in_prepare() after calling this function. + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + int audio_in_set_sound_stream_info( + ffi.Pointer input, + ffi.Pointer stream_info, + ) { + return _audio_in_set_sound_stream_info( + input, + stream_info, + ); + } + + late final _audio_in_set_sound_stream_info_ptr = + _lookup>( + 'audio_in_set_sound_stream_info'); + late final _dart_audio_in_set_sound_stream_info + _audio_in_set_sound_stream_info = _audio_in_set_sound_stream_info_ptr + .asFunction<_dart_audio_in_set_sound_stream_info>(); + + /// @brief Prepares the audio input for reading audio data by starting buffering of audio data from the device. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] input The handle to the audio input + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// @retval #AUDIO_IO_ERROR_DEVICE_POLICY_RESTRICTION Device policy restriction + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// + /// @post The state will be #AUDIO_IO_STATE_RUNNING. + /// @see audio_in_unprepare() + int audio_in_prepare( + ffi.Pointer input, + ) { + return _audio_in_prepare( + input, + ); + } + + late final _audio_in_prepare_ptr = + _lookup>('audio_in_prepare'); + late final _dart_audio_in_prepare _audio_in_prepare = + _audio_in_prepare_ptr.asFunction<_dart_audio_in_prepare>(); + + /// @brief Unprepares the audio input. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] input The handle to the audio input + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// + /// @post The state will be #AUDIO_IO_STATE_IDLE. + /// @see audio_in_prepare() + int audio_in_unprepare( + ffi.Pointer input, + ) { + return _audio_in_unprepare( + input, + ); + } + + late final _audio_in_unprepare_ptr = + _lookup>('audio_in_unprepare'); + late final _dart_audio_in_unprepare _audio_in_unprepare = + _audio_in_unprepare_ptr.asFunction<_dart_audio_in_unprepare>(); + + /// @brief Pauses buffering of audio data from the device. + /// + /// @since_tizen 3.0 + /// + /// @param[in] input The handle to the audio input + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// + /// @pre The state should be #AUDIO_IO_STATE_RUNNING. + /// @post The state will be #AUDIO_IO_STATE_PAUSED. + /// @see audio_in_resume() + int audio_in_pause( + ffi.Pointer input, + ) { + return _audio_in_pause( + input, + ); + } + + late final _audio_in_pause_ptr = + _lookup>('audio_in_pause'); + late final _dart_audio_in_pause _audio_in_pause = + _audio_in_pause_ptr.asFunction<_dart_audio_in_pause>(); + + /// @brief Resumes buffering audio data from the device. + /// + /// @since_tizen 3.0 + /// + /// @param[in] input The handle to the audio input + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// + /// @pre The state should be #AUDIO_IO_STATE_PAUSED. + /// @post The state will be #AUDIO_IO_STATE_RUNNING. + /// @see audio_in_pause() + int audio_in_resume( + ffi.Pointer input, + ) { + return _audio_in_resume( + input, + ); + } + + late final _audio_in_resume_ptr = + _lookup>('audio_in_resume'); + late final _dart_audio_in_resume _audio_in_resume = + _audio_in_resume_ptr.asFunction<_dart_audio_in_resume>(); + + /// @brief Flushes and discards buffered audio data from the input stream. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] input The handle to the audio input + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// + /// @pre The state should be #AUDIO_IO_STATE_RUNNING or #AUDIO_IO_STATE_PAUSED. + int audio_in_flush( + ffi.Pointer input, + ) { + return _audio_in_flush( + input, + ); + } + + late final _audio_in_flush_ptr = + _lookup>('audio_in_flush'); + late final _dart_audio_in_flush _audio_in_flush = + _audio_in_flush_ptr.asFunction<_dart_audio_in_flush>(); + + /// @brief Reads audio data from the audio input buffer. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] input The handle to the audio input + /// @param[out] buffer The PCM buffer address + /// @param[in] length The length of the PCM data buffer (in bytes) + /// @return The number of read bytes on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_BUFFER Invalid buffer pointer + /// @retval #AUDIO_IO_ERROR_SOUND_POLICY Sound policy error + /// @retval #AUDIO_IO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state should be #AUDIO_IO_STATE_RUNNING. + int audio_in_read( + ffi.Pointer input, + ffi.Pointer buffer, + int length, + ) { + return _audio_in_read( + input, + buffer, + length, + ); + } + + late final _audio_in_read_ptr = + _lookup>('audio_in_read'); + late final _dart_audio_in_read _audio_in_read = + _audio_in_read_ptr.asFunction<_dart_audio_in_read>(); + + /// @brief Gets the size to be allocated for the audio input buffer. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] input The handle to the audio input + /// @param[out] size The buffer size (in bytes, the maximum size is 1 MB) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// @see audio_in_read() + int audio_in_get_buffer_size( + ffi.Pointer input, + ffi.Pointer size, + ) { + return _audio_in_get_buffer_size( + input, + size, + ); + } + + late final _audio_in_get_buffer_size_ptr = + _lookup>( + 'audio_in_get_buffer_size'); + late final _dart_audio_in_get_buffer_size _audio_in_get_buffer_size = + _audio_in_get_buffer_size_ptr + .asFunction<_dart_audio_in_get_buffer_size>(); + + /// @brief Gets the sample rate of the audio input data stream. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] input The handle to the audio input + /// @param[out] sample_rate The audio sample rate in Hertz (8000 ~ 48000) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + int audio_in_get_sample_rate( + ffi.Pointer input, + ffi.Pointer sample_rate, + ) { + return _audio_in_get_sample_rate( + input, + sample_rate, + ); + } + + late final _audio_in_get_sample_rate_ptr = + _lookup>( + 'audio_in_get_sample_rate'); + late final _dart_audio_in_get_sample_rate _audio_in_get_sample_rate = + _audio_in_get_sample_rate_ptr + .asFunction<_dart_audio_in_get_sample_rate>(); + + /// @brief Gets the channel type of the audio input data stream. + /// + /// @details The audio channel type defines whether the audio is mono or stereo. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] input The handle to the audio input + /// @param[out] channel The audio channel type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + int audio_in_get_channel( + ffi.Pointer input, + ffi.Pointer channel, + ) { + return _audio_in_get_channel( + input, + channel, + ); + } + + late final _audio_in_get_channel_ptr = + _lookup>( + 'audio_in_get_channel'); + late final _dart_audio_in_get_channel _audio_in_get_channel = + _audio_in_get_channel_ptr.asFunction<_dart_audio_in_get_channel>(); + + /// @brief Gets the sample audio format (8-bit or 16-bit) of the audio input data stream. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] input The handle to the audio input + /// @param[out] type The audio sample type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + int audio_in_get_sample_type( + ffi.Pointer input, + ffi.Pointer type, + ) { + return _audio_in_get_sample_type( + input, + type, + ); + } + + late final _audio_in_get_sample_type_ptr = + _lookup>( + 'audio_in_get_sample_type'); + late final _dart_audio_in_get_sample_type _audio_in_get_sample_type = + _audio_in_get_sample_type_ptr + .asFunction<_dart_audio_in_get_sample_type>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_create_stream_information() instead. + /// @brief Registers a callback function to be invoked when the audio input handle is interrupted or the interrupt is completed. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] input The handle to the audio input + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// @post audio_io_interrupted_cb() will be invoked. + /// + /// @see audio_in_unset_interrupted_cb() + /// @see audio_io_interrupted_cb() + int audio_in_set_interrupted_cb( + ffi.Pointer input, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _audio_in_set_interrupted_cb( + input, + callback, + user_data, + ); + } + + late final _audio_in_set_interrupted_cb_ptr = + _lookup>( + 'audio_in_set_interrupted_cb'); + late final _dart_audio_in_set_interrupted_cb _audio_in_set_interrupted_cb = + _audio_in_set_interrupted_cb_ptr + .asFunction<_dart_audio_in_set_interrupted_cb>(); + + /// @deprecated Deprecated since 3.0 + /// @brief Unregisters the callback function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] input The handle to the audio input + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// + /// @see audio_in_set_interrupted_cb() + int audio_in_unset_interrupted_cb( + ffi.Pointer input, + ) { + return _audio_in_unset_interrupted_cb( + input, + ); + } + + late final _audio_in_unset_interrupted_cb_ptr = + _lookup>( + 'audio_in_unset_interrupted_cb'); + late final _dart_audio_in_unset_interrupted_cb + _audio_in_unset_interrupted_cb = _audio_in_unset_interrupted_cb_ptr + .asFunction<_dart_audio_in_unset_interrupted_cb>(); + + /// @deprecated Deprecated since 3.0 + /// @brief Ignores session for input. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] input The handle to the audio input + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + int audio_in_ignore_session( + ffi.Pointer input, + ) { + return _audio_in_ignore_session( + input, + ); + } + + late final _audio_in_ignore_session_ptr = + _lookup>( + 'audio_in_ignore_session'); + late final _dart_audio_in_ignore_session _audio_in_ignore_session = + _audio_in_ignore_session_ptr.asFunction<_dart_audio_in_ignore_session>(); + + /// @brief Sets an asynchronous(event) callback function to handle recording PCM (pulse-code modulation) data. + /// + /// @details @a callback will be called when you can read a PCM data. + /// It might cause dead lock if change the state of audio handle in callback. + /// (ex: audio_in_destroy, audio_in_prepare, audio_in_unprepare) + /// Recommend to use as a VOIP only. + /// Recommend not to hold callback too long.(it affects latency) + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks @a input must be created using audio_in_create(). + /// + /// @param[in] input An audio input handle + /// @param[in] callback notify stream callback when user can read data (#audio_in_stream_cb) + /// @param[in] user_data user data to be retrieved when callback is called + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #AUDIO_IO_ERROR_DEVICE_NOT_OPENED Device not opened + /// @retval #AUDIO_IO_ERROR_SOUND_POLICY Sound policy error + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// + /// @see audio_out_set_stream_cb() + int audio_in_set_stream_cb( + ffi.Pointer input, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _audio_in_set_stream_cb( + input, + callback, + user_data, + ); + } + + late final _audio_in_set_stream_cb_ptr = + _lookup>( + 'audio_in_set_stream_cb'); + late final _dart_audio_in_set_stream_cb _audio_in_set_stream_cb = + _audio_in_set_stream_cb_ptr.asFunction<_dart_audio_in_set_stream_cb>(); + + /// @brief Unregisters the callback function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] input The handle to the audio input + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// + /// @see audio_in_set_interrupted_cb() + int audio_in_unset_stream_cb( + ffi.Pointer input, + ) { + return _audio_in_unset_stream_cb( + input, + ); + } + + late final _audio_in_unset_stream_cb_ptr = + _lookup>( + 'audio_in_unset_stream_cb'); + late final _dart_audio_in_unset_stream_cb _audio_in_unset_stream_cb = + _audio_in_unset_stream_cb_ptr + .asFunction<_dart_audio_in_unset_stream_cb>(); + + /// @brief peek from audio in buffer + /// + /// @details This function works correctly only with read, write callback. Otherwise it won't operate as intended. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks @a Works only in asynchronous(event) mode. This will just retrieve buffer pointer from audio in buffer. Drop after use. + /// + /// @param[in] input The handle to the audio input + /// @param[out] buffer start buffer pointer of peeked audio in data + /// @param[out] length amount of audio in data to be peeked + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// + /// @pre The state should be #AUDIO_IO_STATE_RUNNING. + /// @see audio_in_drop() + int audio_in_peek( + ffi.Pointer input, + ffi.Pointer> buffer, + ffi.Pointer length, + ) { + return _audio_in_peek( + input, + buffer, + length, + ); + } + + late final _audio_in_peek_ptr = + _lookup>('audio_in_peek'); + late final _dart_audio_in_peek _audio_in_peek = + _audio_in_peek_ptr.asFunction<_dart_audio_in_peek>(); + + /// @brief drop peeked audio buffer. + /// + /// @details This function works correctly only with read, write callback. Otherwise it won't operate as intended. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks @a Works only in asynchronous(event) mode. This will remove audio in data from actual stream buffer. Use this if peeked data is not needed anymore. + /// + /// @param[in] input The handle to the audio input + /// @return 0 on success, otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// + /// @pre The state should be #AUDIO_IO_STATE_RUNNING. + /// @see audio_in_peek() + int audio_in_drop( + ffi.Pointer input, + ) { + return _audio_in_drop( + input, + ); + } + + late final _audio_in_drop_ptr = + _lookup>('audio_in_drop'); + late final _dart_audio_in_drop _audio_in_drop = + _audio_in_drop_ptr.asFunction<_dart_audio_in_drop>(); + + /// @brief Sets the state changed callback function to the audio input handle. + /// + /// @since_tizen 3.0 + /// + /// @remarks @a input must be created using audio_in_create(). + /// + /// @param[in] input The audio input handle + /// @param[in] callback the state changed callback called when the state of the handle is changed (#audio_in_state_changed_cb) + /// @param[in] user_data user data to be retrieved when callback is called + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// + /// @see audio_in_unset_state_changed_cb() + int audio_in_set_state_changed_cb( + ffi.Pointer input, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _audio_in_set_state_changed_cb( + input, + callback, + user_data, + ); + } + + late final _audio_in_set_state_changed_cb_ptr = + _lookup>( + 'audio_in_set_state_changed_cb'); + late final _dart_audio_in_set_state_changed_cb + _audio_in_set_state_changed_cb = _audio_in_set_state_changed_cb_ptr + .asFunction<_dart_audio_in_set_state_changed_cb>(); + + /// @brief Unregisters the state changed callback function of the audio input handle. + /// + /// @since_tizen 3.0 + /// + /// @param[in] input The handle to the audio input + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// + /// @see audio_in_set_state_changed_cb() + int audio_in_unset_state_changed_cb( + ffi.Pointer input, + ) { + return _audio_in_unset_state_changed_cb( + input, + ); + } + + late final _audio_in_unset_state_changed_cb_ptr = + _lookup>( + 'audio_in_unset_state_changed_cb'); + late final _dart_audio_in_unset_state_changed_cb + _audio_in_unset_state_changed_cb = _audio_in_unset_state_changed_cb_ptr + .asFunction<_dart_audio_in_unset_state_changed_cb>(); + + /// @deprecated Deprecated since 3.0. Use audio_out_create_new() instead. + /// @brief Creates an audio device instance and returns an output handle to play PCM (pulse-code modulation) data. + /// + /// @details This function is used for audio output initialization. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks @a output must be released by audio_out_destroy(). + /// + /// @param[in] sample_rate The audio sample rate in 8000[Hz] ~ 48000[Hz] + /// @param[in] channel The audio channel type (mono or stereo) + /// @param[in] type The type of audio sample (8-bit or 16-bit) + /// @param[in] sound_type The type of sound (#sound_type_e) + /// @param[out] output An audio output handle is created on success + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #AUDIO_IO_ERROR_DEVICE_NOT_OPENED Device not opened + /// @retval #AUDIO_IO_ERROR_SOUND_POLICY Sound policy error + /// + /// @see audio_out_destroy() + int audio_out_create( + int sample_rate, + int channel, + int type, + int sound_type, + ffi.Pointer> output, + ) { + return _audio_out_create( + sample_rate, + channel, + type, + sound_type, + output, + ); + } + + late final _audio_out_create_ptr = + _lookup>('audio_out_create'); + late final _dart_audio_out_create _audio_out_create = + _audio_out_create_ptr.asFunction<_dart_audio_out_create>(); + + /// @brief Creates an audio device instance and returns an output handle to play PCM (pulse-code modulation) data. + /// + /// @details This function is used for audio output initialization. + /// + /// @since_tizen 3.0 + /// + /// @remarks @a output must be released by audio_out_destroy(). + /// It is recommended to call audio_out_set_sound_stream_info() after this API. + /// + /// @param[in] sample_rate The audio sample rate in 8000[Hz] ~ 48000[Hz] + /// @param[in] channel The audio channel type (mono or stereo) + /// @param[in] type The type of audio sample (8-bit or 16-bit) + /// @param[out] output An audio output handle is created on success + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #AUDIO_IO_ERROR_DEVICE_NOT_OPENED Device not opened + /// @retval #AUDIO_IO_ERROR_SOUND_POLICY Sound policy error + /// + /// @post The state will be #AUDIO_IO_STATE_IDLE.\n + /// audio_out_set_sound_stream_info() is recommended to be called after this API. + /// @see audio_out_destroy() + int audio_out_create_new( + int sample_rate, + int channel, + int type, + ffi.Pointer> output, + ) { + return _audio_out_create_new( + sample_rate, + channel, + type, + output, + ); + } + + late final _audio_out_create_new_ptr = + _lookup>( + 'audio_out_create_new'); + late final _dart_audio_out_create_new _audio_out_create_new = + _audio_out_create_new_ptr.asFunction<_dart_audio_out_create_new>(); + + /// @brief Releases the audio output handle, along with all its resources. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] output The handle to the audio output to destroy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #AUDIO_IO_ERROR_DEVICE_NOT_CLOSED Device not closed + /// + /// @see audio_out_create() + int audio_out_destroy( + ffi.Pointer output, + ) { + return _audio_out_destroy( + output, + ); + } + + late final _audio_out_destroy_ptr = + _lookup>('audio_out_destroy'); + late final _dart_audio_out_destroy _audio_out_destroy = + _audio_out_destroy_ptr.asFunction<_dart_audio_out_destroy>(); + + /// @brief Sets the sound stream information to the audio output. + /// + /// @since_tizen 3.0 + /// + /// @remarks @a the sound stream information includes audio routing and volume type. + /// For more details, you can refer to @ref CAPI_MEDIA_SOUND_MANAGER_MODULE + /// Voice Recognition and Loopback stream types are not supported in this API. + /// + /// @param[in] output The handle to the audio output + /// @param[in] stream_info The handle of stream information + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED Not supported + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// @retval #AUDIO_IO_ERROR_NOT_SUPPORTED_TYPE Not supported stream type + /// + /// @pre The state should be #AUDIO_IO_STATE_IDLE.\n + /// Call audio_out_create_new() before calling this function. + /// @post Call audio_out_prepare() after calling this function. + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + int audio_out_set_sound_stream_info( + ffi.Pointer output, + ffi.Pointer stream_info, + ) { + return _audio_out_set_sound_stream_info( + output, + stream_info, + ); + } + + late final _audio_out_set_sound_stream_info_ptr = + _lookup>( + 'audio_out_set_sound_stream_info'); + late final _dart_audio_out_set_sound_stream_info + _audio_out_set_sound_stream_info = _audio_out_set_sound_stream_info_ptr + .asFunction<_dart_audio_out_set_sound_stream_info>(); + + /// @brief Prepares the audio output for playback, this must be called before audio_out_write(). + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] output The handle to the audio output + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// + /// @post The state will be #AUDIO_IO_STATE_RUNNING. + /// @see audio_out_unprepare() + int audio_out_prepare( + ffi.Pointer output, + ) { + return _audio_out_prepare( + output, + ); + } + + late final _audio_out_prepare_ptr = + _lookup>('audio_out_prepare'); + late final _dart_audio_out_prepare _audio_out_prepare = + _audio_out_prepare_ptr.asFunction<_dart_audio_out_prepare>(); + + /// @brief Unprepares the audio output. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] output The handle to the audio output + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// + /// @post The state will be #AUDIO_IO_STATE_IDLE. + /// @see audio_out_prepare() + int audio_out_unprepare( + ffi.Pointer output, + ) { + return _audio_out_unprepare( + output, + ); + } + + late final _audio_out_unprepare_ptr = + _lookup>( + 'audio_out_unprepare'); + late final _dart_audio_out_unprepare _audio_out_unprepare = + _audio_out_unprepare_ptr.asFunction<_dart_audio_out_unprepare>(); + + /// @brief Pauses feeding of audio data to the device. + /// + /// @since_tizen 3.0 + /// + /// @param[in] output The handle to the audio output + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// + /// @pre The state should be #AUDIO_IO_STATE_RUNNING. + /// @post The state will be #AUDIO_IO_STATE_PAUSED. + /// @see audio_out_resume() + int audio_out_pause( + ffi.Pointer output, + ) { + return _audio_out_pause( + output, + ); + } + + late final _audio_out_pause_ptr = + _lookup>('audio_out_pause'); + late final _dart_audio_out_pause _audio_out_pause = + _audio_out_pause_ptr.asFunction<_dart_audio_out_pause>(); + + /// @brief Resumes feeding of audio data to the device. + /// + /// @since_tizen 3.0 + /// + /// @param[in] output The handle to the audio output + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// + /// @pre The state should be #AUDIO_IO_STATE_PAUSED. + /// @post The state will be #AUDIO_IO_STATE_RUNNING. + /// @see audio_out_pause() + int audio_out_resume( + ffi.Pointer output, + ) { + return _audio_out_resume( + output, + ); + } + + late final _audio_out_resume_ptr = + _lookup>('audio_out_resume'); + late final _dart_audio_out_resume _audio_out_resume = + _audio_out_resume_ptr.asFunction<_dart_audio_out_resume>(); + + /// @brief Drains buffered audio data from the output stream. + /// + /// @details This function waits until drains stream buffer completely. (e.g end of playback) + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] output The handle to the audio output + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// + /// @pre The state should be #AUDIO_IO_STATE_RUNNING or #AUDIO_IO_STATE_PAUSED. + /// @see audio_out_flush() + int audio_out_drain( + ffi.Pointer output, + ) { + return _audio_out_drain( + output, + ); + } + + late final _audio_out_drain_ptr = + _lookup>('audio_out_drain'); + late final _dart_audio_out_drain _audio_out_drain = + _audio_out_drain_ptr.asFunction<_dart_audio_out_drain>(); + + /// @brief Flushes and discards buffered audio data from the output stream. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] output The handle to the audio output + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// + /// @pre The state should be #AUDIO_IO_STATE_RUNNING or #AUDIO_IO_STATE_PAUSED. + /// @see audio_out_drain() + int audio_out_flush( + ffi.Pointer output, + ) { + return _audio_out_flush( + output, + ); + } + + late final _audio_out_flush_ptr = + _lookup>('audio_out_flush'); + late final _dart_audio_out_flush _audio_out_flush = + _audio_out_flush_ptr.asFunction<_dart_audio_out_flush>(); + + /// @brief Starts writing the audio data to the device. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] output The handle to the audio output + /// @param[in,out] buffer The PCM buffer address + /// @param[in] length The length of the PCM buffer (in bytes) + /// @return The written data size on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_BUFFER Invalid buffer pointer + /// @retval #AUDIO_IO_ERROR_SOUND_POLICY Sound policy error + /// @retval #AUDIO_IO_ERROR_INVALID_STATE Invalid state + /// + /// @pre The state should be #AUDIO_IO_STATE_RUNNING. + int audio_out_write( + ffi.Pointer output, + ffi.Pointer buffer, + int length, + ) { + return _audio_out_write( + output, + buffer, + length, + ); + } + + late final _audio_out_write_ptr = + _lookup>('audio_out_write'); + late final _dart_audio_out_write _audio_out_write = + _audio_out_write_ptr.asFunction<_dart_audio_out_write>(); + + /// @brief Gets the size to be allocated for the audio output buffer. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] output The handle to the audio output + /// @param[out] size The suggested buffer size (in bytes, the maximum size is 1 MB) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see audio_out_write() + int audio_out_get_buffer_size( + ffi.Pointer output, + ffi.Pointer size, + ) { + return _audio_out_get_buffer_size( + output, + size, + ); + } + + late final _audio_out_get_buffer_size_ptr = + _lookup>( + 'audio_out_get_buffer_size'); + late final _dart_audio_out_get_buffer_size _audio_out_get_buffer_size = + _audio_out_get_buffer_size_ptr + .asFunction<_dart_audio_out_get_buffer_size>(); + + /// @brief Gets the sample rate of the audio output data stream. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] output The handle to the audio output + /// @param[out] sample_rate The audio sample rate in Hertz (8000 ~ 48000) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + int audio_out_get_sample_rate( + ffi.Pointer output, + ffi.Pointer sample_rate, + ) { + return _audio_out_get_sample_rate( + output, + sample_rate, + ); + } + + late final _audio_out_get_sample_rate_ptr = + _lookup>( + 'audio_out_get_sample_rate'); + late final _dart_audio_out_get_sample_rate _audio_out_get_sample_rate = + _audio_out_get_sample_rate_ptr + .asFunction<_dart_audio_out_get_sample_rate>(); + + /// @brief Gets the channel type of the audio output data stream. + /// + /// @details The audio channel type defines whether the audio is mono or stereo. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] output The handle to the audio output + /// @param[out] channel The audio channel type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + int audio_out_get_channel( + ffi.Pointer output, + ffi.Pointer channel, + ) { + return _audio_out_get_channel( + output, + channel, + ); + } + + late final _audio_out_get_channel_ptr = + _lookup>( + 'audio_out_get_channel'); + late final _dart_audio_out_get_channel _audio_out_get_channel = + _audio_out_get_channel_ptr.asFunction<_dart_audio_out_get_channel>(); + + /// @brief Gets the sample audio format (8-bit or 16-bit) of the audio output data stream. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] output The handle to the audio output + /// @param[out] type The audio sample type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + int audio_out_get_sample_type( + ffi.Pointer output, + ffi.Pointer type, + ) { + return _audio_out_get_sample_type( + output, + type, + ); + } + + late final _audio_out_get_sample_type_ptr = + _lookup>( + 'audio_out_get_sample_type'); + late final _dart_audio_out_get_sample_type _audio_out_get_sample_type = + _audio_out_get_sample_type_ptr + .asFunction<_dart_audio_out_get_sample_type>(); + + /// @brief Gets the sound type supported by the audio output device. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] output The handle to the audio output + /// @param[out] type The sound type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + int audio_out_get_sound_type( + ffi.Pointer output, + ffi.Pointer type, + ) { + return _audio_out_get_sound_type( + output, + type, + ); + } + + late final _audio_out_get_sound_type_ptr = + _lookup>( + 'audio_out_get_sound_type'); + late final _dart_audio_out_get_sound_type _audio_out_get_sound_type = + _audio_out_get_sound_type_ptr + .asFunction<_dart_audio_out_get_sound_type>(); + + /// @deprecated Deprecated since 3.0. Use sound_manager_create_stream_information() instead. + /// @brief Registers a callback function to be invoked when the audio output handle is interrupted or the interrupt is completed. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] output The handle to the audio output + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_OPERATION Invalid operation + /// + /// @post audio_io_interrupted_cb() will be invoked. + /// @see audio_out_unset_interrupted_cb() + /// @see audio_io_interrupted_cb() + int audio_out_set_interrupted_cb( + ffi.Pointer output, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _audio_out_set_interrupted_cb( + output, + callback, + user_data, + ); + } + + late final _audio_out_set_interrupted_cb_ptr = + _lookup>( + 'audio_out_set_interrupted_cb'); + late final _dart_audio_out_set_interrupted_cb _audio_out_set_interrupted_cb = + _audio_out_set_interrupted_cb_ptr + .asFunction<_dart_audio_out_set_interrupted_cb>(); + + /// @deprecated Deprecated since 3.0 + /// @brief Unregisters the callback function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] output The handle to the audio output + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see audio_out_set_interrupted_cb() + int audio_out_unset_interrupted_cb( + ffi.Pointer output, + ) { + return _audio_out_unset_interrupted_cb( + output, + ); + } + + late final _audio_out_unset_interrupted_cb_ptr = + _lookup>( + 'audio_out_unset_interrupted_cb'); + late final _dart_audio_out_unset_interrupted_cb + _audio_out_unset_interrupted_cb = _audio_out_unset_interrupted_cb_ptr + .asFunction<_dart_audio_out_unset_interrupted_cb>(); + + /// @deprecated Deprecated since 3.0 + /// @brief Ignores session for output. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] output The handle to the audio output + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_OPERATION Invalid operation + int audio_out_ignore_session( + ffi.Pointer output, + ) { + return _audio_out_ignore_session( + output, + ); + } + + late final _audio_out_ignore_session_ptr = + _lookup>( + 'audio_out_ignore_session'); + late final _dart_audio_out_ignore_session _audio_out_ignore_session = + _audio_out_ignore_session_ptr + .asFunction<_dart_audio_out_ignore_session>(); + + /// @brief Sets an asynchronous(event) callback function to handle playing PCM (pulse-code modulation) data. + /// + /// @details @a callback will be called when you can write a PCM data. + /// It might cause dead lock if change the state of audio handle in callback. + /// (ex: audio_out_destroy, audio_out_prepare, audio_out_unprepare) + /// Recommend to use as a VOIP only. + /// Recommend not to hold callback too long.(it affects latency) + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks @a output must be created using audio_out_create(). + /// + /// @param[in] output An audio output handle + /// @param[in] callback notify stream callback when user can write data (#audio_out_stream_cb) + /// @param[in] user_data user data to be retrieved when callback is called + /// @return 0 on success, otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #AUDIO_IO_ERROR_DEVICE_NOT_OPENED Device not opened + /// @retval #AUDIO_IO_ERROR_SOUND_POLICY Sound policy error + /// + /// @see audio_out_unset_stream_cb() + int audio_out_set_stream_cb( + ffi.Pointer output, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _audio_out_set_stream_cb( + output, + callback, + user_data, + ); + } + + late final _audio_out_set_stream_cb_ptr = + _lookup>( + 'audio_out_set_stream_cb'); + late final _dart_audio_out_set_stream_cb _audio_out_set_stream_cb = + _audio_out_set_stream_cb_ptr.asFunction<_dart_audio_out_set_stream_cb>(); + + /// @brief Unregisters the callback function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] output The handle to the audio output + /// @return 0 on success, otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #AUDIO_IO_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see audio_out_set_stream_cb() + int audio_out_unset_stream_cb( + ffi.Pointer output, + ) { + return _audio_out_unset_stream_cb( + output, + ); + } + + late final _audio_out_unset_stream_cb_ptr = + _lookup>( + 'audio_out_unset_stream_cb'); + late final _dart_audio_out_unset_stream_cb _audio_out_unset_stream_cb = + _audio_out_unset_stream_cb_ptr + .asFunction<_dart_audio_out_unset_stream_cb>(); + + /// @brief Sets the state changed callback function to the audio output handle. + /// + /// @since_tizen 3.0 + /// + /// @remarks @a input must be created using audio_out_create_new(). + /// + /// @param[in] output The audio output handle + /// @param[in] callback the state changed callback called when the state of the handle is changed (#audio_out_state_changed_cb) + /// @param[in] user_data user data to be retrieved when callback is called + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see audio_out_unset_state_changed_cb() + int audio_out_set_state_changed_cb( + ffi.Pointer output, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _audio_out_set_state_changed_cb( + output, + callback, + user_data, + ); + } + + late final _audio_out_set_state_changed_cb_ptr = + _lookup>( + 'audio_out_set_state_changed_cb'); + late final _dart_audio_out_set_state_changed_cb + _audio_out_set_state_changed_cb = _audio_out_set_state_changed_cb_ptr + .asFunction<_dart_audio_out_set_state_changed_cb>(); + + /// @brief Unregisters the state changed callback function of the audio output handle. + /// + /// @since_tizen 3.0 + /// + /// @param[in] output The handle to the audio output + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #AUDIO_IO_ERROR_NONE Successful + /// @retval #AUDIO_IO_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see audio_out_set_state_changed_cb() + int audio_out_unset_state_changed_cb( + ffi.Pointer output, + ) { + return _audio_out_unset_state_changed_cb( + output, + ); + } + + late final _audio_out_unset_state_changed_cb_ptr = + _lookup>( + 'audio_out_unset_state_changed_cb'); + late final _dart_audio_out_unset_state_changed_cb + _audio_out_unset_state_changed_cb = _audio_out_unset_state_changed_cb_ptr + .asFunction<_dart_audio_out_unset_state_changed_cb>(); + + /// @brief Creates a media format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @details It creates media format. and reference count will be set to 1 + /// For destroying media_format_h handle, use media_format_unref(). + /// @param[out] fmt allocated media_format_h + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_ref() + /// @see media_format_unref() + int media_format_create( + ffi.Pointer> fmt, + ) { + return _media_format_create( + fmt, + ); + } + + late final _media_format_create_ptr = + _lookup>( + 'media_format_create'); + late final _dart_media_format_create _media_format_create = + _media_format_create_ptr.asFunction<_dart_media_format_create>(); + + /// @brief Gets format type of media format. + /// @since_tizen 3.0 + /// @param[in] fmt The media_format_h to get format type + /// @param[out] formattype The media_format_type_e, ex) MEDIA_FORMAT_AUDIO + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + int media_format_get_type( + ffi.Pointer fmt, + ffi.Pointer formattype, + ) { + return _media_format_get_type( + fmt, + formattype, + ); + } + + late final _media_format_get_type_ptr = + _lookup>( + 'media_format_get_type'); + late final _dart_media_format_get_type _media_format_get_type = + _media_format_get_type_ptr.asFunction<_dart_media_format_get_type>(); + + /// @brief Gets container MIME type of media format. + /// @since_tizen 3.0 + /// @param[in] fmt The media_format_h to get container mime type + /// @param[out] mimetype The media_format_mimetype_e, ex) MEDIA_FORMAT_CONTAINER_MP4 + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_set_container_mime() + int media_format_get_container_mime( + ffi.Pointer fmt, + ffi.Pointer mimetype, + ) { + return _media_format_get_container_mime( + fmt, + mimetype, + ); + } + + late final _media_format_get_container_mime_ptr = + _lookup>( + 'media_format_get_container_mime'); + late final _dart_media_format_get_container_mime + _media_format_get_container_mime = _media_format_get_container_mime_ptr + .asFunction<_dart_media_format_get_container_mime>(); + + /// @brief Gets text track information of media format. + /// @since_tizen 3.0 + /// @param[in] fmt The media_format_h to get text information + /// @param[out] mimetype The media_format_mimetype_e, ex) MEDIA_FORMAT_TEXT_MP4 + /// @param[out] type The media_format_text_type_e + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_set_text_mime() + int media_format_get_text_info( + ffi.Pointer fmt, + ffi.Pointer mimetype, + ffi.Pointer type, + ) { + return _media_format_get_text_info( + fmt, + mimetype, + type, + ); + } + + late final _media_format_get_text_info_ptr = + _lookup>( + 'media_format_get_text_info'); + late final _dart_media_format_get_text_info _media_format_get_text_info = + _media_format_get_text_info_ptr + .asFunction<_dart_media_format_get_text_info>(); + + /// @brief Gets video information of media format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @details returns mimetype, width, height, average bps, max bps of this media format. + /// @param[in] fmt media_format_h to get video information + /// @param[out] mimetype media_format_mimetype_e , ex) MEDIA_FORMAT_H264_HP + /// @param[out] width width of the video + /// @param[out] height height of the video + /// @param[out] avg_bps average bps of the video + /// @param[out] max_bps max bps of the video + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_set_video_mime() + /// @see media_format_set_video_width() + /// @see media_format_set_video_height() + /// @see media_format_set_video_avg_bps() + /// @see media_format_set_video_max_bps() + int media_format_get_video_info( + ffi.Pointer fmt, + ffi.Pointer mimetype, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer avg_bps, + ffi.Pointer max_bps, + ) { + return _media_format_get_video_info( + fmt, + mimetype, + width, + height, + avg_bps, + max_bps, + ); + } + + late final _media_format_get_video_info_ptr = + _lookup>( + 'media_format_get_video_info'); + late final _dart_media_format_get_video_info _media_format_get_video_info = + _media_format_get_video_info_ptr + .asFunction<_dart_media_format_get_video_info>(); + + /// @brief Gets audio information of media format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @details returns mimetype, channels, height, samplerate bps, max bps of this media format. + /// @param[in] fmt media_format_h to get audio information + /// @param[out] mimetype media_format_mimetype_e , ex) MEDIA_FORMAT_PCM + /// @param[out] channel channel of the audio + /// @param[out] samplerate sampling rate of the audio + /// @param[out] bit bit resolution of the audio + /// @param[out] avg_bps average bps of the audio + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_set_audio_mime() + /// @see media_format_set_audio_channel() + /// @see media_format_set_audio_samplerate() + /// @see media_format_set_audio_bit() + /// @see media_format_set_audio_avg_bps() + int media_format_get_audio_info( + ffi.Pointer fmt, + ffi.Pointer mimetype, + ffi.Pointer channel, + ffi.Pointer samplerate, + ffi.Pointer bit, + ffi.Pointer avg_bps, + ) { + return _media_format_get_audio_info( + fmt, + mimetype, + channel, + samplerate, + bit, + avg_bps, + ); + } + + late final _media_format_get_audio_info_ptr = + _lookup>( + 'media_format_get_audio_info'); + late final _dart_media_format_get_audio_info _media_format_get_audio_info = + _media_format_get_audio_info_ptr + .asFunction<_dart_media_format_get_audio_info>(); + + /// @brief Gets audio aac type of media format. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] fmt media_format_h to get audio information + /// @param[out] is_adts AAC ADTS flag of the audio + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_set_audio_aac_type() + int media_format_get_audio_aac_type( + ffi.Pointer fmt, + ffi.Pointer is_adts, + ) { + return _media_format_get_audio_aac_type( + fmt, + is_adts, + ); + } + + late final _media_format_get_audio_aac_type_ptr = + _lookup>( + 'media_format_get_audio_aac_type'); + late final _dart_media_format_get_audio_aac_type + _media_format_get_audio_aac_type = _media_format_get_audio_aac_type_ptr + .asFunction<_dart_media_format_get_audio_aac_type>(); + + /// @brief Gets audio aac header type of media format. + /// @since_tizen 3.0 + /// @param[in] fmt The media_format_h to get audio information + /// @param[out] aac_header_type The media_format_aac_header_type_e, ex) MEDIA_FORMAT_AAC_HEADER_ADTS + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_set_audio_aac_header_type() + int media_format_get_audio_aac_header_type( + ffi.Pointer fmt, + ffi.Pointer aac_header_type, + ) { + return _media_format_get_audio_aac_header_type( + fmt, + aac_header_type, + ); + } + + late final _media_format_get_audio_aac_header_type_ptr = + _lookup>( + 'media_format_get_audio_aac_header_type'); + late final _dart_media_format_get_audio_aac_header_type + _media_format_get_audio_aac_header_type = + _media_format_get_audio_aac_header_type_ptr + .asFunction<_dart_media_format_get_audio_aac_header_type>(); + + /// @brief Gets video frame rate of media format. + /// @since_tizen 3.0 + /// @param[in] fmt The media_format_h to get + /// @param[out] frame_rate The video frame rate + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + int media_format_get_video_frame_rate( + ffi.Pointer fmt, + ffi.Pointer frame_rate, + ) { + return _media_format_get_video_frame_rate( + fmt, + frame_rate, + ); + } + + late final _media_format_get_video_frame_rate_ptr = + _lookup>( + 'media_format_get_video_frame_rate'); + late final _dart_media_format_get_video_frame_rate + _media_format_get_video_frame_rate = + _media_format_get_video_frame_rate_ptr + .asFunction<_dart_media_format_get_video_frame_rate>(); + + /// @brief Sets container MIME type of media format. + /// @since_tizen 3.0 + /// @param[in] fmt The media_format_h to set + /// @param[in] mimetype The media_format_mimetype_e, ex) MEDIA_FORMAT_MP4 + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_container_mime() + int media_format_set_container_mime( + ffi.Pointer fmt, + int mimetype, + ) { + return _media_format_set_container_mime( + fmt, + mimetype, + ); + } + + late final _media_format_set_container_mime_ptr = + _lookup>( + 'media_format_set_container_mime'); + late final _dart_media_format_set_container_mime + _media_format_set_container_mime = _media_format_set_container_mime_ptr + .asFunction<_dart_media_format_set_container_mime>(); + + /// @brief Sets text MIME type of media format. + /// @since_tizen 3.0 + /// @param[in] fmt The media_format_h to set + /// @param[in] mimetype The media_format_mimetype_e, ex) MEDIA_FORMAT_TEXT* + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_text_info() + int media_format_set_text_mime( + ffi.Pointer fmt, + int mimetype, + ) { + return _media_format_set_text_mime( + fmt, + mimetype, + ); + } + + late final _media_format_set_text_mime_ptr = + _lookup>( + 'media_format_set_text_mime'); + late final _dart_media_format_set_text_mime _media_format_set_text_mime = + _media_format_set_text_mime_ptr + .asFunction<_dart_media_format_set_text_mime>(); + + /// @brief Sets text type of media format. + /// @since_tizen 3.0 + /// @param[in] fmt The media_format_h to set + /// @param[in] type The text type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_text_info() + int media_format_set_text_type( + ffi.Pointer fmt, + int type, + ) { + return _media_format_set_text_type( + fmt, + type, + ); + } + + late final _media_format_set_text_type_ptr = + _lookup>( + 'media_format_set_text_type'); + late final _dart_media_format_set_text_type _media_format_set_text_type = + _media_format_set_text_type_ptr + .asFunction<_dart_media_format_set_text_type>(); + + /// @brief Sets video MIME type of media format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] fmt media_format_h to set + /// @param[in] mimetype media_format_mimetype_e , ex) MEDIA_FORMAT_H264_HP + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_video() + int media_format_set_video_mime( + ffi.Pointer fmt, + int mimetype, + ) { + return _media_format_set_video_mime( + fmt, + mimetype, + ); + } + + late final _media_format_set_video_mime_ptr = + _lookup>( + 'media_format_set_video_mime'); + late final _dart_media_format_set_video_mime _media_format_set_video_mime = + _media_format_set_video_mime_ptr + .asFunction<_dart_media_format_set_video_mime>(); + + /// @brief Sets video width of media format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] fmt media_format_h to set + /// @param[in] width width of the video + /// @pre must set video MIME type by media_format_set_video_mime() + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_video() + int media_format_set_video_width( + ffi.Pointer fmt, + int width, + ) { + return _media_format_set_video_width( + fmt, + width, + ); + } + + late final _media_format_set_video_width_ptr = + _lookup>( + 'media_format_set_video_width'); + late final _dart_media_format_set_video_width _media_format_set_video_width = + _media_format_set_video_width_ptr + .asFunction<_dart_media_format_set_video_width>(); + + /// @brief Sets video height of media format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] fmt media_format_h to set + /// @param[in] height height of the video + /// @pre must set video MIME type by media_format_set_video_mime() + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_video() + int media_format_set_video_height( + ffi.Pointer fmt, + int height, + ) { + return _media_format_set_video_height( + fmt, + height, + ); + } + + late final _media_format_set_video_height_ptr = + _lookup>( + 'media_format_set_video_height'); + late final _dart_media_format_set_video_height + _media_format_set_video_height = _media_format_set_video_height_ptr + .asFunction<_dart_media_format_set_video_height>(); + + /// @brief Sets video avg_bps of media format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] fmt media_format_h to set + /// @param[in] avg_bps average bps of the video + /// @pre must set video MIME type by media_format_set_video_mime() + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_video() + int media_format_set_video_avg_bps( + ffi.Pointer fmt, + int avg_bps, + ) { + return _media_format_set_video_avg_bps( + fmt, + avg_bps, + ); + } + + late final _media_format_set_video_avg_bps_ptr = + _lookup>( + 'media_format_set_video_avg_bps'); + late final _dart_media_format_set_video_avg_bps + _media_format_set_video_avg_bps = _media_format_set_video_avg_bps_ptr + .asFunction<_dart_media_format_set_video_avg_bps>(); + + /// @brief Sets video max_bps of media format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] fmt media_format_h to set + /// @param[in] max_bps max bps of the video + /// @pre must set video MIME type by media_format_set_video_mime() + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_video() + int media_format_set_video_max_bps( + ffi.Pointer fmt, + int max_bps, + ) { + return _media_format_set_video_max_bps( + fmt, + max_bps, + ); + } + + late final _media_format_set_video_max_bps_ptr = + _lookup>( + 'media_format_set_video_max_bps'); + late final _dart_media_format_set_video_max_bps + _media_format_set_video_max_bps = _media_format_set_video_max_bps_ptr + .asFunction<_dart_media_format_set_video_max_bps>(); + + /// @brief Sets video frame rate of media format. + /// @since_tizen 3.0 + /// @param[in] fmt The media_format_h to set + /// @param[in] frame_rate The video frame rate + /// @pre must set video MIME type by media_format_set_video_mime() + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + int media_format_set_video_frame_rate( + ffi.Pointer fmt, + int frame_rate, + ) { + return _media_format_set_video_frame_rate( + fmt, + frame_rate, + ); + } + + late final _media_format_set_video_frame_rate_ptr = + _lookup>( + 'media_format_set_video_frame_rate'); + late final _dart_media_format_set_video_frame_rate + _media_format_set_video_frame_rate = + _media_format_set_video_frame_rate_ptr + .asFunction<_dart_media_format_set_video_frame_rate>(); + + /// @brief Sets audio MIME type of media format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] fmt media_format_h to set audio information + /// @param[in] mimetype media_format_mimetype_e , ex) MEDIA_FORMAT_PCM + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_audio() + int media_format_set_audio_mime( + ffi.Pointer fmt, + int mimetype, + ) { + return _media_format_set_audio_mime( + fmt, + mimetype, + ); + } + + late final _media_format_set_audio_mime_ptr = + _lookup>( + 'media_format_set_audio_mime'); + late final _dart_media_format_set_audio_mime _media_format_set_audio_mime = + _media_format_set_audio_mime_ptr + .asFunction<_dart_media_format_set_audio_mime>(); + + /// @brief Sets audio channel of media format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] fmt media_format_h to set audio information + /// @param[in] channel channel of the audio + /// @pre must set audio MIME type by media_format_set_audio_mime() + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_audio() + int media_format_set_audio_channel( + ffi.Pointer fmt, + int channel, + ) { + return _media_format_set_audio_channel( + fmt, + channel, + ); + } + + late final _media_format_set_audio_channel_ptr = + _lookup>( + 'media_format_set_audio_channel'); + late final _dart_media_format_set_audio_channel + _media_format_set_audio_channel = _media_format_set_audio_channel_ptr + .asFunction<_dart_media_format_set_audio_channel>(); + + /// @brief Sets audio samplerate of media format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] fmt media_format_h to set + /// @param[in] samplerate sampling rate of the audio + /// @pre must set audio MIME type by media_format_set_audio_mime() + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_audio() + int media_format_set_audio_samplerate( + ffi.Pointer fmt, + int samplerate, + ) { + return _media_format_set_audio_samplerate( + fmt, + samplerate, + ); + } + + late final _media_format_set_audio_samplerate_ptr = + _lookup>( + 'media_format_set_audio_samplerate'); + late final _dart_media_format_set_audio_samplerate + _media_format_set_audio_samplerate = + _media_format_set_audio_samplerate_ptr + .asFunction<_dart_media_format_set_audio_samplerate>(); + + /// @brief Sets audio bit of media format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @details Sets audio bit resolution of this media format + /// @param[in] fmt media_format_h to set + /// @param[in] bit bit of the audio + /// @pre must set audio MIME type by media_format_set_audio_mime() + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_audio() + int media_format_set_audio_bit( + ffi.Pointer fmt, + int bit, + ) { + return _media_format_set_audio_bit( + fmt, + bit, + ); + } + + late final _media_format_set_audio_bit_ptr = + _lookup>( + 'media_format_set_audio_bit'); + late final _dart_media_format_set_audio_bit _media_format_set_audio_bit = + _media_format_set_audio_bit_ptr + .asFunction<_dart_media_format_set_audio_bit>(); + + /// @brief Sets audio avg_bps of media format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] fmt media_format_h to set + /// @param[in] avg_bps avg_bps of the audio + /// @pre must set audio MIME type by media_format_set_audio_mime() + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_audio() + int media_format_set_audio_avg_bps( + ffi.Pointer fmt, + int avg_bps, + ) { + return _media_format_set_audio_avg_bps( + fmt, + avg_bps, + ); + } + + late final _media_format_set_audio_avg_bps_ptr = + _lookup>( + 'media_format_set_audio_avg_bps'); + late final _dart_media_format_set_audio_avg_bps + _media_format_set_audio_avg_bps = _media_format_set_audio_avg_bps_ptr + .asFunction<_dart_media_format_set_audio_avg_bps>(); + + /// @brief Sets audio aac type of media format. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @details Sets audio aac data type of this media format + /// @param[in] fmt media_format_h to set + /// @param[in] is_adts aac adts flag of the audio + /// @pre must set audio MIME type by media_format_set_audio_mime() + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_audio_aac_type() + int media_format_set_audio_aac_type( + ffi.Pointer fmt, + bool is_adts, + ) { + return _media_format_set_audio_aac_type( + fmt, + is_adts ? 1 : 0, + ); + } + + late final _media_format_set_audio_aac_type_ptr = + _lookup>( + 'media_format_set_audio_aac_type'); + late final _dart_media_format_set_audio_aac_type + _media_format_set_audio_aac_type = _media_format_set_audio_aac_type_ptr + .asFunction<_dart_media_format_set_audio_aac_type>(); + + /// @brief Sets audio aac header type of media format. + /// @since_tizen 3.0 + /// @param[in] fmt The media_format_h to get audio information + /// @param[in] aac_header_type The media_format_aac_header_type_e, ex) MEDIA_FORMAT_AAC_HEADER_ADTS + /// @pre must set audio MIME type by media_format_set_audio_mime() + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_get_audio_aac_header_type() + int media_format_set_audio_aac_header_type( + ffi.Pointer fmt, + int aac_header_type, + ) { + return _media_format_set_audio_aac_header_type( + fmt, + aac_header_type, + ); + } + + late final _media_format_set_audio_aac_header_type_ptr = + _lookup>( + 'media_format_set_audio_aac_header_type'); + late final _dart_media_format_set_audio_aac_header_type + _media_format_set_audio_aac_header_type = + _media_format_set_audio_aac_header_type_ptr + .asFunction<_dart_media_format_set_audio_aac_header_type>(); + + /// @brief Increase reference count of media_format_h object. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @details increase ref_count of media_format_h + /// @param[in] fmt exist media_format_h + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_unref() + int media_format_ref( + ffi.Pointer fmt, + ) { + return _media_format_ref( + fmt, + ); + } + + late final _media_format_ref_ptr = + _lookup>('media_format_ref'); + late final _dart_media_format_ref _media_format_ref = + _media_format_ref_ptr.asFunction<_dart_media_format_ref>(); + + /// @brief Decrease reference count of media_format_h object. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] fmt exist media_format_h + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_ref() + int media_format_unref( + ffi.Pointer fmt, + ) { + return _media_format_unref( + fmt, + ); + } + + late final _media_format_unref_ptr = + _lookup>('media_format_unref'); + late final _dart_media_format_unref _media_format_unref = + _media_format_unref_ptr.asFunction<_dart_media_format_unref>(); + + /// @brief Check whether the media_format_h is writable or not. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] fmt exist media_format_h + /// @param[out] is_writable if ref_count is 1, return true. if not, return false + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + int media_format_is_writable( + ffi.Pointer fmt, + ffi.Pointer is_writable, + ) { + return _media_format_is_writable( + fmt, + is_writable, + ); + } + + late final _media_format_is_writable_ptr = + _lookup>( + 'media_format_is_writable'); + late final _dart_media_format_is_writable _media_format_is_writable = + _media_format_is_writable_ptr + .asFunction<_dart_media_format_is_writable>(); + + /// @brief Returns a writable copy of media_format_h. + /// @details If there is only one reference count on fmt, the caller must be the owner, + /// and so this function will return the object unchanged. + /// while, if there is more than one reference count on the object, a new object will be returned. + /// The caller will own a reference to the returned object. + /// In a nutshell, this function unrefs the fmt and refs the out_fmt returned. + /// Don't access fmt after calling this function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If a new object is returned, it will not have its own copy of extra data. + /// The new object's extra data object will be the original object's extra data. + /// @param[in] fmt exist media_format_h , don't access it after calling this function + /// @param[out] out_fmt new copied media_format_h, the caller is owner of this object + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_FORMAT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_FORMAT_ERROR_INVALID_OPERATION Invalid operation + int media_format_make_writable( + ffi.Pointer fmt, + ffi.Pointer> out_fmt, + ) { + return _media_format_make_writable( + fmt, + out_fmt, + ); + } + + late final _media_format_make_writable_ptr = + _lookup>( + 'media_format_make_writable'); + late final _dart_media_format_make_writable _media_format_make_writable = + _media_format_make_writable_ptr + .asFunction<_dart_media_format_make_writable>(); + + /// @brief Sets extra data of media format. + /// @details The user can set data that media format does not support. + /// @since_tizen 4.0 + /// @remarks The application is responsible for freeing @a extra_data. + /// For description of extra data behavior upon making an object writable, + /// see the description of media_format_make_writable(). + /// @param[in] fmt The media format handle + /// @param[in] extra_data The extra data to set + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @see media_format_get_extra() + int media_format_set_extra( + ffi.Pointer fmt, + ffi.Pointer extra_data, + ) { + return _media_format_set_extra( + fmt, + extra_data, + ); + } + + late final _media_format_set_extra_ptr = + _lookup>( + 'media_format_set_extra'); + late final _dart_media_format_set_extra _media_format_set_extra = + _media_format_set_extra_ptr.asFunction<_dart_media_format_set_extra>(); + + /// @brief Gets extra data of media format. + /// @details The user can get extra data which user sets value via media_format_set_extra(). + /// @since_tizen 4.0 + /// @remarks The application is responsible for freeing @a extra_data. + /// For description of extra data behavior upon making an object writable, + /// see the description of media_format_make_writable(). + /// @param[in] fmt The media format handle + /// @param[out] extra_data The extra data to get + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_FORMAT_ERROR_NONE Successful + /// @retval #MEDIA_FORMAT_ERROR_INVALID_PARAMETER Invalid parameter + /// @see media_format_set_extra() + int media_format_get_extra( + ffi.Pointer fmt, + ffi.Pointer> extra_data, + ) { + return _media_format_get_extra( + fmt, + extra_data, + ); + } + + late final _media_format_get_extra_ptr = + _lookup>( + 'media_format_get_extra'); + late final _dart_media_format_get_extra _media_format_get_extra = + _media_format_get_extra_ptr.asFunction<_dart_media_format_get_extra>(); + + /// @brief Creates a media packet handle and allocates buffer. + /// @details The buffer will be allocated to heap or tbm_surface. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @c packet must be released by using media_packet_destroy(). + /// @param[in] fmt The allocated #media_format_h by caller + /// @param[in] fcb The media_packet_finalize_cb() to register + /// @param[in] fcb_data The user data to be passed to the media_packet_finalize_cb() function + /// @param[out] packet A new handle for media packet + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre Must have media_format_h instance by media_format_create() + /// @post Must do media_format_unref() + /// + /// @see media_packet_destroy() + /// @see media_packet_finalize_cb() + /// @see media_format_unref() + /// @par Example + /// @code + /// #include + /// + /// { + /// media_format_h fmt; + /// media_packet_h packet; + /// + /// media_format_create(&fmt); + /// media_format_set_video_mime(fmt, MEDIA_FORMAT_H264_HP); + /// media_format_set_video_width(fmt, 640); + /// media_format_set_video_height(fmt, 480); + /// media_format_set_video_avg_bps(fmt, 10000000); + /// media_format_set_video_max_bps(fmt, 15000000); + /// + /// media_packet_create_alloc (fmt, _finalize_callback, fcb_data, &packet); + /// media_format_unref(fmt); + /// + /// ... + /// media_packet_destroy(packet); + /// } + /// + /// int _finalize_callback(media_packet_h packet, int err, void* userdata) + /// { + /// ... + /// return MEDIA_PACKET_FINALIZE; + /// } + /// + /// @endcode + int media_packet_create_alloc( + ffi.Pointer fmt, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> packet, + ) { + return _media_packet_create_alloc( + fmt, + fcb, + fcb_data, + packet, + ); + } + + late final _media_packet_create_alloc_ptr = + _lookup>( + 'media_packet_create_alloc'); + late final _dart_media_packet_create_alloc _media_packet_create_alloc = + _media_packet_create_alloc_ptr + .asFunction<_dart_media_packet_create_alloc>(); + + /// @brief Creates a media packet handle. + /// @details It creates only media packet handle without allocated buffer. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @c packet must be released by using media_packet_destroy(). + /// @param[in] fmt The allocated #media_format_h by caller + /// @param[in] fcb The media_packet_finalize_cb() to register + /// @param[in] fcb_data The user data to be passed to the media_packet_finalize_cb() function + /// @param[out] packet A new handle for media packet + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre Must have media_format_h instance by media_format_create() + /// @post Must do media_format_unref() + /// + /// @see media_packet_destroy() + /// @see media_packet_finalize_cb() + /// @see media_format_unref() + /// @par Example + /// @code + /// #include + /// + /// { + /// media_format_h fmt; + /// media_packet_h packet; + /// + /// media_format_create(&fmt); + /// media_format_set_video_mime(fmt, MEDIA_FORMAT_H264_HP); + /// media_format_set_video_width(fmt, 640); + /// media_format_set_video_height(fmt, 480); + /// media_format_set_video_avg_bps(fmt, 10000000); + /// media_format_set_video_max_bps(fmt, 15000000); + /// + /// media_packet_create (fmt, _finalize_callback, fcb_data, &packet); + /// media_format_unref(fmt); + /// + /// ... + /// media_packet_destroy(packet); + /// } + /// + /// int _finalize_callback(media_packet_h packet, int err, void* userdata) + /// { + /// ... + /// return MEDIA_PACKET_FINALIZE; + /// } + /// + /// @endcode + int media_packet_create( + ffi.Pointer fmt, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> packet, + ) { + return _media_packet_create( + fmt, + fcb, + fcb_data, + packet, + ); + } + + late final _media_packet_create_ptr = + _lookup>( + 'media_packet_create'); + late final _dart_media_packet_create _media_packet_create = + _media_packet_create_ptr.asFunction<_dart_media_packet_create>(); + + /// @brief Copies a media packet handle. + /// @details It re-creates only media packet handle with exist media packet handle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @c new_packet must be released by using media_packet_destroy(). + /// @param[in] org_packet The existing media packet handle + /// @param[in] fcb The media_packet_finalize_cb() to register + /// @param[in] fcb_data The user data to be passed to the media_packet_finalize_cb() function + /// @param[out] new_packet A new handle for media packet + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see media_packet_destroy() + /// @see media_packet_finalize_cb() + int media_packet_copy( + ffi.Pointer org_packet, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> new_packet, + ) { + return _media_packet_copy( + org_packet, + fcb, + fcb_data, + new_packet, + ); + } + + late final _media_packet_copy_ptr = + _lookup>('media_packet_copy'); + late final _dart_media_packet_copy _media_packet_copy = + _media_packet_copy_ptr.asFunction<_dart_media_packet_copy>(); + + /// @brief Allocates buffer with media packet handle. + /// @details Before using media_packet_alloc(), media packet handle must be exist. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The existing media packet handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see media_packet_create() + /// @see media_packet_destroy() + int media_packet_alloc( + ffi.Pointer packet, + ) { + return _media_packet_alloc( + packet, + ); + } + + late final _media_packet_alloc_ptr = + _lookup>('media_packet_alloc'); + late final _dart_media_packet_alloc _media_packet_alloc = + _media_packet_alloc_ptr.asFunction<_dart_media_packet_alloc>(); + + /// @brief Creates media packet handle and allocates buffer with #tbm_surface_h. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @c packet must be released by using media_packet_destroy(). + /// @param[in] fmt The allocated #media_format_h by caller + /// @param[in] surface The #tbm_surface_h by caller + /// @param[in] fcb The media_packet_finalize_cb() to register + /// @param[in] fcb_data The user data to be passed to the media_packet_finalize_cb() function + /// @param[out] packet A new handle for media packet + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre Must have media_format_h instance by media_format_create() + /// @post Must do media_format_unref() + /// + /// @see media_packet_destroy() + /// @see media_packet_finalize_cb() + /// @see media_format_unref() + /// @par Example + /// @code + /// #include + /// + /// { + /// media_format_h fmt; + /// media_packet_h packet; + /// + /// media_format_create(&fmt); + /// media_format_set_video_mime(fmt, MEDIA_FORMAT_H264_HP); + /// media_format_set_video_width(fmt, 640); + /// media_format_set_video_height(fmt, 480); + /// media_format_set_video_avg_bps(fmt, 10000000); + /// media_format_set_video_max_bps(fmt, 15000000); + /// + /// media_packet_create_from_tbm_surface (fmt, surface, _finalize_callback, fcb_data, &packet); + /// media_format_unref(fmt); + /// + /// ... + /// media_pacekt_destory(packet); + /// } + /// + /// int _finalize_callback(media_packet_h packet, int err, void* userdata) + /// { + /// ... + /// return MEDIA_PACKET_FINALIZE; + /// } + /// + /// @endcode + int media_packet_create_from_tbm_surface( + ffi.Pointer fmt, + ffi.Pointer surface, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> packet, + ) { + return _media_packet_create_from_tbm_surface( + fmt, + surface, + fcb, + fcb_data, + packet, + ); + } + + late final _media_packet_create_from_tbm_surface_ptr = + _lookup>( + 'media_packet_create_from_tbm_surface'); + late final _dart_media_packet_create_from_tbm_surface + _media_packet_create_from_tbm_surface = + _media_packet_create_from_tbm_surface_ptr + .asFunction<_dart_media_packet_create_from_tbm_surface>(); + + /// @brief Creates media packet handle with already allocated external buffer. + /// @details It does not support video's #MEDIA_FORMAT_RAW type. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @c packet must be released by using media_packet_destroy(). + /// @param[in] fmt The allocated #media_format_h by caller + /// @param[in] mem_ptr The memory pointer which is created by external module + /// @param[in] size The buffer size value to set + /// @param[in] fcb The media_packet_finalize_cb() to register + /// @param[in] fcb_data The user data to be passed to the media_packet_finalize_cb() function + /// @param[out] packet A new handle for media packet + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre Must have media_format_h instance by media_format_create() + /// @post Must do media_format_unref() + /// + /// @see media_packet_destroy() + /// @see media_packet_finalize_cb() + /// @see media_format_unref() + /// @par Example + /// @code + /// #include + /// + /// { + /// media_format_h fmt; + /// media_packet_h packet; + /// + /// media_format_create(&fmt); + /// media_format_set_video_mime(fmt, MEDIA_FORMAT_H264_HP); + /// media_format_set_video_width(fmt, 640); + /// media_format_set_video_height(fmt, 480); + /// media_format_set_video_avg_bps(fmt, 10000000); + /// media_format_set_video_max_bps(fmt, 15000000); + /// + /// media_packet_create_from_external_memory (fmt, mem_ptr, size, _finalize_callback, fcb_data, &packet); + /// media_format_unref(fmt); + /// + /// ... + /// media_packet_destroy(packet); + /// } + /// + /// int _finalize_callback(media_packet_h packet, int err, void* userdata) + /// { + /// ... + /// return MEDIA_PACKET_FINALIZE; + /// } + /// + /// @endcode + int media_packet_create_from_external_memory( + ffi.Pointer fmt, + ffi.Pointer mem_ptr, + int size, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> packet, + ) { + return _media_packet_create_from_external_memory( + fmt, + mem_ptr, + size, + fcb, + fcb_data, + packet, + ); + } + + late final _media_packet_create_from_external_memory_ptr = + _lookup>( + 'media_packet_create_from_external_memory'); + late final _dart_media_packet_create_from_external_memory + _media_packet_create_from_external_memory = + _media_packet_create_from_external_memory_ptr + .asFunction<_dart_media_packet_create_from_external_memory>(); + + /// @brief Gets #media_format_h of media packet + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] fmt The media format of media packet + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_format_unref() + /// @par Example + /// @code + /// #include + /// + /// { + /// media_format_h* fmt; + /// + /// media_packet_get_format (pakcet, &fmt); + /// .. + /// + /// media_format_unref(fmt); + /// ... + /// } + /// + /// @endcode + int media_packet_get_format( + ffi.Pointer packet, + ffi.Pointer> fmt, + ) { + return _media_packet_get_format( + packet, + fmt, + ); + } + + late final _media_packet_get_format_ptr = + _lookup>( + 'media_packet_get_format'); + late final _dart_media_packet_get_format _media_packet_get_format = + _media_packet_get_format_ptr.asFunction<_dart_media_packet_get_format>(); + + /// @brief Sets #media_format_h of media packet + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[in] fmt The #media_format_h to set + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see media_format_unref() + /// @par Example + /// @code + /// #include + /// + /// { + /// media_format_h fmt; + /// + /// media_packet_set_format (pakcet, fmt); + /// .. + /// + /// media_format_unref(fmt); + /// ... + /// } + /// + /// @endcode + int media_packet_set_format( + ffi.Pointer packet, + ffi.Pointer fmt, + ) { + return _media_packet_set_format( + packet, + fmt, + ); + } + + late final _media_packet_set_format_ptr = + _lookup>( + 'media_packet_set_format'); + late final _dart_media_packet_set_format _media_packet_set_format = + _media_packet_set_format_ptr.asFunction<_dart_media_packet_set_format>(); + + /// @brief Sets PTS of media packet. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[in] pts The PTS value to set + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_set_pts( + ffi.Pointer packet, + int pts, + ) { + return _media_packet_set_pts( + packet, + pts, + ); + } + + late final _media_packet_set_pts_ptr = + _lookup>( + 'media_packet_set_pts'); + late final _dart_media_packet_set_pts _media_packet_set_pts = + _media_packet_set_pts_ptr.asFunction<_dart_media_packet_set_pts>(); + + /// @brief Sets DTS of media packet handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[in] dts The DTS value to set + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_set_dts( + ffi.Pointer packet, + int dts, + ) { + return _media_packet_set_dts( + packet, + dts, + ); + } + + late final _media_packet_set_dts_ptr = + _lookup>( + 'media_packet_set_dts'); + late final _dart_media_packet_set_dts _media_packet_set_dts = + _media_packet_set_dts_ptr.asFunction<_dart_media_packet_set_dts>(); + + /// @brief Sets PTS of media packet. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[in] duration The duration value to set + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_set_duration( + ffi.Pointer packet, + int duration, + ) { + return _media_packet_set_duration( + packet, + duration, + ); + } + + late final _media_packet_set_duration_ptr = + _lookup>( + 'media_packet_set_duration'); + late final _dart_media_packet_set_duration _media_packet_set_duration = + _media_packet_set_duration_ptr + .asFunction<_dart_media_packet_set_duration>(); + + /// @brief Sets buffer size of media packet. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] size The buffer size value to set + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_set_buffer_size( + ffi.Pointer packet, + int size, + ) { + return _media_packet_set_buffer_size( + packet, + size, + ); + } + + late final _media_packet_set_buffer_size_ptr = + _lookup>( + 'media_packet_set_buffer_size'); + late final _dart_media_packet_set_buffer_size _media_packet_set_buffer_size = + _media_packet_set_buffer_size_ptr + .asFunction<_dart_media_packet_set_buffer_size>(); + + /// @brief Gets PTS of media packet. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] pts The PTS value to get + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + int media_packet_get_pts( + ffi.Pointer packet, + ffi.Pointer pts, + ) { + return _media_packet_get_pts( + packet, + pts, + ); + } + + late final _media_packet_get_pts_ptr = + _lookup>( + 'media_packet_get_pts'); + late final _dart_media_packet_get_pts _media_packet_get_pts = + _media_packet_get_pts_ptr.asFunction<_dart_media_packet_get_pts>(); + + /// @brief Gets DTS of media packet + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] dts The DTS value to get + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_get_dts( + ffi.Pointer packet, + ffi.Pointer dts, + ) { + return _media_packet_get_dts( + packet, + dts, + ); + } + + late final _media_packet_get_dts_ptr = + _lookup>( + 'media_packet_get_dts'); + late final _dart_media_packet_get_dts _media_packet_get_dts = + _media_packet_get_dts_ptr.asFunction<_dart_media_packet_get_dts>(); + + /// @brief Gets duration of media packet. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] duration The duration value to get + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_get_duration( + ffi.Pointer packet, + ffi.Pointer duration, + ) { + return _media_packet_get_duration( + packet, + duration, + ); + } + + late final _media_packet_get_duration_ptr = + _lookup>( + 'media_packet_get_duration'); + late final _dart_media_packet_get_duration _media_packet_get_duration = + _media_packet_get_duration_ptr + .asFunction<_dart_media_packet_get_duration>(); + + /// @brief Gets buffer size of media packet. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] size The buffer size value to get + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_get_buffer_size( + ffi.Pointer packet, + ffi.Pointer size, + ) { + return _media_packet_get_buffer_size( + packet, + size, + ); + } + + late final _media_packet_get_buffer_size_ptr = + _lookup>( + 'media_packet_get_buffer_size'); + late final _dart_media_packet_get_buffer_size _media_packet_get_buffer_size = + _media_packet_get_buffer_size_ptr + .asFunction<_dart_media_packet_get_buffer_size>(); + + /// @brief Gets buffer data pointer of media packet. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] data The allocated buffer data pointer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_get_buffer_data_ptr( + ffi.Pointer packet, + ffi.Pointer> data, + ) { + return _media_packet_get_buffer_data_ptr( + packet, + data, + ); + } + + late final _media_packet_get_buffer_data_ptr_ptr = + _lookup>( + 'media_packet_get_buffer_data_ptr'); + late final _dart_media_packet_get_buffer_data_ptr + _media_packet_get_buffer_data_ptr = _media_packet_get_buffer_data_ptr_ptr + .asFunction<_dart_media_packet_get_buffer_data_ptr>(); + + /// @brief Gets TBM surface data of media packet. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] surface The tbm_surface data pointer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_get_tbm_surface( + ffi.Pointer packet, + ffi.Pointer> surface, + ) { + return _media_packet_get_tbm_surface( + packet, + surface, + ); + } + + late final _media_packet_get_tbm_surface_ptr = + _lookup>( + 'media_packet_get_tbm_surface'); + late final _dart_media_packet_get_tbm_surface _media_packet_get_tbm_surface = + _media_packet_get_tbm_surface_ptr + .asFunction<_dart_media_packet_get_tbm_surface>(); + + /// @brief Sets extra data of media packet. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[in] extra The extra data to set + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_set_extra( + ffi.Pointer packet, + ffi.Pointer extra, + ) { + return _media_packet_set_extra( + packet, + extra, + ); + } + + late final _media_packet_set_extra_ptr = + _lookup>( + 'media_packet_set_extra'); + late final _dart_media_packet_set_extra _media_packet_set_extra = + _media_packet_set_extra_ptr.asFunction<_dart_media_packet_set_extra>(); + + /// @brief Gets extra data of media packet. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] extra The extra data to get + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_get_extra( + ffi.Pointer packet, + ffi.Pointer> extra, + ) { + return _media_packet_get_extra( + packet, + extra, + ); + } + + late final _media_packet_get_extra_ptr = + _lookup>( + 'media_packet_get_extra'); + late final _dart_media_packet_get_extra _media_packet_get_extra = + _media_packet_get_extra_ptr.asFunction<_dart_media_packet_get_extra>(); + + /// @brief Checks whether the given media packet is for video. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] is_video @c true if the given media packet is for video, + /// otherwise @c false if the given media packet is not for video + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see media_format_mimetype_e + /// @see media_format_type_e + int media_packet_is_video( + ffi.Pointer packet, + ffi.Pointer is_video, + ) { + return _media_packet_is_video( + packet, + is_video, + ); + } + + late final _media_packet_is_video_ptr = + _lookup>( + 'media_packet_is_video'); + late final _dart_media_packet_is_video _media_packet_is_video = + _media_packet_is_video_ptr.asFunction<_dart_media_packet_is_video>(); + + /// @brief Checks whether the given media packet is for audio. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] is_audio @c true if the given media packet is for audio, + /// otherwise @c false if the given media packet is not for audio + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_mimetype_e + /// @see media_format_type_e + int media_packet_is_audio( + ffi.Pointer packet, + ffi.Pointer is_audio, + ) { + return _media_packet_is_audio( + packet, + is_audio, + ); + } + + late final _media_packet_is_audio_ptr = + _lookup>( + 'media_packet_is_audio'); + late final _dart_media_packet_is_audio _media_packet_is_audio = + _media_packet_is_audio_ptr.asFunction<_dart_media_packet_is_audio>(); + + /// @brief Checks whether the given media packet is for text. + /// @since_tizen 3.0 + /// + /// @param[in] packet The media packet handle + /// @param[out] is_text @c true if the given media packet is for text, + /// otherwise @c false if the given media packet is not for text + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// @see media_format_mimetype_e + /// @see media_format_type_e + int media_packet_is_text( + ffi.Pointer packet, + ffi.Pointer is_text, + ) { + return _media_packet_is_text( + packet, + is_text, + ); + } + + late final _media_packet_is_text_ptr = + _lookup>( + 'media_packet_is_text'); + late final _dart_media_packet_is_text _media_packet_is_text = + _media_packet_is_text_ptr.asFunction<_dart_media_packet_is_text>(); + + /// @brief Checks whether the given media packet is encoded type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] is_encoded @c true if the given media packet is encoded, + /// otherwise @c false if the given media packet is not encoded + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see media_format_mimetype_e + /// @see media_format_data_type_e + int media_packet_is_encoded( + ffi.Pointer packet, + ffi.Pointer is_encoded, + ) { + return _media_packet_is_encoded( + packet, + is_encoded, + ); + } + + late final _media_packet_is_encoded_ptr = + _lookup>( + 'media_packet_is_encoded'); + late final _dart_media_packet_is_encoded _media_packet_is_encoded = + _media_packet_is_encoded_ptr.asFunction<_dart_media_packet_is_encoded>(); + + /// @brief Checks whether the given media packet is raw type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] is_raw @c true if the given media packet is for raw video, + /// otherwise @c false if the given media packet is not for raw video + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see media_format_mimetype_e + /// @see media_format_data_type_e + int media_packet_is_raw( + ffi.Pointer packet, + ffi.Pointer is_raw, + ) { + return _media_packet_is_raw( + packet, + is_raw, + ); + } + + late final _media_packet_is_raw_ptr = + _lookup>( + 'media_packet_is_raw'); + late final _dart_media_packet_is_raw _media_packet_is_raw = + _media_packet_is_raw_ptr.asFunction<_dart_media_packet_is_raw>(); + + /// @brief Gets #media_buffer_flags_e of media packet. + /// @since_tizen 3.0 + /// + /// @param[in] packet The media packet handle + /// @param[out] flags The media_buffer_flags_e of media packet to get + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see media_buffer_flags_e + /// @see media_packet_unset_flags() + int media_packet_get_flags( + ffi.Pointer packet, + ffi.Pointer flags, + ) { + return _media_packet_get_flags( + packet, + flags, + ); + } + + late final _media_packet_get_flags_ptr = + _lookup>( + 'media_packet_get_flags'); + late final _dart_media_packet_get_flags _media_packet_get_flags = + _media_packet_get_flags_ptr.asFunction<_dart_media_packet_get_flags>(); + + /// @brief Sets #media_buffer_flags_e of media packet. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[in] flags The media_buffer_flags_e of media packet to set + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see media_buffer_flags_e + /// @see media_packet_unset_flags() + int media_packet_set_flags( + ffi.Pointer packet, + int flags, + ) { + return _media_packet_set_flags( + packet, + flags, + ); + } + + late final _media_packet_set_flags_ptr = + _lookup>( + 'media_packet_set_flags'); + late final _dart_media_packet_set_flags _media_packet_set_flags = + _media_packet_set_flags_ptr.asFunction<_dart_media_packet_set_flags>(); + + /// @brief Unsets media_buffer_flags_e of media packet + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[in] flags The media_buffer_flags_e of media packet to unset + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see media_buffer_flags_e + /// @see media_packet_set_flags() + int media_packet_unset_flags( + ffi.Pointer packet, + int flags, + ) { + return _media_packet_unset_flags( + packet, + flags, + ); + } + + late final _media_packet_unset_flags_ptr = + _lookup>( + 'media_packet_unset_flags'); + late final _dart_media_packet_unset_flags _media_packet_unset_flags = + _media_packet_unset_flags_ptr + .asFunction<_dart_media_packet_unset_flags>(); + + /// @brief Checks whether the given media packet is codec data. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] is_codec_config @c true if the given media packet is for codec data, + /// otherwise @c false if the given media packet is not for codec data + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see media_format_mimetype_e + /// @see media_format_data_type_e + int media_packet_is_codec_config( + ffi.Pointer packet, + ffi.Pointer is_codec_config, + ) { + return _media_packet_is_codec_config( + packet, + is_codec_config, + ); + } + + late final _media_packet_is_codec_config_ptr = + _lookup>( + 'media_packet_is_codec_config'); + late final _dart_media_packet_is_codec_config _media_packet_is_codec_config = + _media_packet_is_codec_config_ptr + .asFunction<_dart_media_packet_is_codec_config>(); + + /// @brief Checks whether the given media packet is eos. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] is_eos @c true if the given media packet is for eos, + /// otherwise @c false if the given media packet is not for eos + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see media_format_mimetype_e + /// @see media_format_data_type_e + int media_packet_is_end_of_stream( + ffi.Pointer packet, + ffi.Pointer is_eos, + ) { + return _media_packet_is_end_of_stream( + packet, + is_eos, + ); + } + + late final _media_packet_is_end_of_stream_ptr = + _lookup>( + 'media_packet_is_end_of_stream'); + late final _dart_media_packet_is_end_of_stream + _media_packet_is_end_of_stream = _media_packet_is_end_of_stream_ptr + .asFunction<_dart_media_packet_is_end_of_stream>(); + + /// @brief Checks whether the given media packet is sync frame. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] is_sync @c true if the given media packet is for sync frame, + /// otherwise @c false if the given media packet is not for sync frame + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see media_format_mimetype_e + /// @see media_format_data_type_e + int media_packet_is_sync_frame( + ffi.Pointer packet, + ffi.Pointer is_sync, + ) { + return _media_packet_is_sync_frame( + packet, + is_sync, + ); + } + + late final _media_packet_is_sync_frame_ptr = + _lookup>( + 'media_packet_is_sync_frame'); + late final _dart_media_packet_is_sync_frame _media_packet_is_sync_frame = + _media_packet_is_sync_frame_ptr + .asFunction<_dart_media_packet_is_sync_frame>(); + + /// @brief Checks whether the allocated buffer is tbm surface or not. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] has_tbm_surface @c true if the given media packet's allocated buffer is tbm surface, + /// otherwise @c false if the given media packet's allocated buffer is not tbm surface + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_has_tbm_surface_buffer( + ffi.Pointer packet, + ffi.Pointer has_tbm_surface, + ) { + return _media_packet_has_tbm_surface_buffer( + packet, + has_tbm_surface, + ); + } + + late final _media_packet_has_tbm_surface_buffer_ptr = + _lookup>( + 'media_packet_has_tbm_surface_buffer'); + late final _dart_media_packet_has_tbm_surface_buffer + _media_packet_has_tbm_surface_buffer = + _media_packet_has_tbm_surface_buffer_ptr + .asFunction<_dart_media_packet_has_tbm_surface_buffer>(); + + /// @brief Gets the number of planes from tbm surface in the given media packet. + /// @details Use only if the media_format_h is #MEDIA_FORMAT_RAW and #MEDIA_FORMAT_VIDEO. + /// It means that media_packet_h's buffer is allocated on tbm_surface. + /// If not sure of that, use media_packet_is_video() and media_packet_is_raw() or media_packet_has_tbm_surface_buffer(). + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] num The number of planes from tbm_surface + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_get_number_of_video_planes( + ffi.Pointer packet, + ffi.Pointer num, + ) { + return _media_packet_get_number_of_video_planes( + packet, + num, + ); + } + + late final _media_packet_get_number_of_video_planes_ptr = + _lookup>( + 'media_packet_get_number_of_video_planes'); + late final _dart_media_packet_get_number_of_video_planes + _media_packet_get_number_of_video_planes = + _media_packet_get_number_of_video_planes_ptr + .asFunction<_dart_media_packet_get_number_of_video_planes>(); + + /// @brief Gets stride width from tbm surface in the given media packet. + /// @details Use only if the media_format_h is #MEDIA_FORMAT_RAW and #MEDIA_FORMAT_VIDEO. + /// It means that media_packet_h's buffer is allocated on tbm_surface. + /// If not sure of that, use media_packet_is_video() and media_packet_is_raw() or media_packet_has_tbm_surface_buffer(). + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] packet The media packet handle + /// @param[in] plane_idx The plane index value + /// @param[out] stride_width the stride value from tbm_surface + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_get_video_stride_width( + ffi.Pointer packet, + int plane_idx, + ffi.Pointer stride_width, + ) { + return _media_packet_get_video_stride_width( + packet, + plane_idx, + stride_width, + ); + } + + late final _media_packet_get_video_stride_width_ptr = + _lookup>( + 'media_packet_get_video_stride_width'); + late final _dart_media_packet_get_video_stride_width + _media_packet_get_video_stride_width = + _media_packet_get_video_stride_width_ptr + .asFunction<_dart_media_packet_get_video_stride_width>(); + + /// @brief Gets stride height from tbm surface in the given media packet. + /// @details Use only if the media_format_h is #MEDIA_FORMAT_RAW and #MEDIA_FORMAT_VIDEO. + /// It means that media_packet_h's buffer is allocated on tbm_surface. + /// If not sure of that, use media_packet_is_video() and media_packet_is_raw() or media_packet_has_tbm_surface_buffer(). + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] packet The media packet handle + /// @param[in] plane_idx The plane index value + /// @param[out] stride_height The stride height value from tbm_surface + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_get_video_stride_height( + ffi.Pointer packet, + int plane_idx, + ffi.Pointer stride_height, + ) { + return _media_packet_get_video_stride_height( + packet, + plane_idx, + stride_height, + ); + } + + late final _media_packet_get_video_stride_height_ptr = + _lookup>( + 'media_packet_get_video_stride_height'); + late final _dart_media_packet_get_video_stride_height + _media_packet_get_video_stride_height = + _media_packet_get_video_stride_height_ptr + .asFunction<_dart_media_packet_get_video_stride_height>(); + + /// @brief Gets plane data pointer from tbm surface in the given media packet. + /// @details Use only if the media_format_h is #MEDIA_FORMAT_RAW and #MEDIA_FORMAT_VIDEO. + /// It means that media_packet_h's buffer is allocated on tbm_surface. + /// If not sure of that, use media_packet_is_video() and media_packet_is_raw() or media_packet_has_tbm_surface_buffer(). + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @c plane_data_ptr must not be released by using free(). Note that It is released by media_packet_destory() or tbm_surface_destroy(). + /// @param[in] packet The media packet handle + /// @param[in] plane_idx The plane index value + /// @param[out] plane_data_ptr The plane data pointer from tbm_surface + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_get_video_plane_data_ptr( + ffi.Pointer packet, + int plane_idx, + ffi.Pointer> plane_data_ptr, + ) { + return _media_packet_get_video_plane_data_ptr( + packet, + plane_idx, + plane_data_ptr, + ); + } + + late final _media_packet_get_video_plane_data_ptr_ptr = + _lookup>( + 'media_packet_get_video_plane_data_ptr'); + late final _dart_media_packet_get_video_plane_data_ptr + _media_packet_get_video_plane_data_ptr = + _media_packet_get_video_plane_data_ptr_ptr + .asFunction<_dart_media_packet_get_video_plane_data_ptr>(); + + /// @brief Gets codec data and the codec data size of media packet. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] packet The media packet handle + /// @param[out] codec_data The codec data to get + /// @param[out] codec_data_size The codec data size to get + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + int media_packet_get_codec_data( + ffi.Pointer packet, + ffi.Pointer> codec_data, + ffi.Pointer codec_data_size, + ) { + return _media_packet_get_codec_data( + packet, + codec_data, + codec_data_size, + ); + } + + late final _media_packet_get_codec_data_ptr = + _lookup>( + 'media_packet_get_codec_data'); + late final _dart_media_packet_get_codec_data _media_packet_get_codec_data = + _media_packet_get_codec_data_ptr + .asFunction<_dart_media_packet_get_codec_data>(); + + /// @brief Destroys the media packet handle. + /// @details The registered finalize_callback() function will be invoked to destroy the media packet handle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] packet The handle to media packet to be destroyed + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see media_packet_create_alloc() + /// @see media_packet_create() + /// @see media_packet_copy() + /// @see media_packet_create_from_tbm_surface() + /// @see media_packet_create_from_external_memory() + int media_packet_destroy( + ffi.Pointer packet, + ) { + return _media_packet_destroy( + packet, + ); + } + + late final _media_packet_destroy_ptr = + _lookup>( + 'media_packet_destroy'); + late final _dart_media_packet_destroy _media_packet_destroy = + _media_packet_destroy_ptr.asFunction<_dart_media_packet_destroy>(); + + /// @brief Creates a new camera handle for controlling a camera. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks Multiple handles on a context at the same time are allowed to be created. However, + /// camera cannot guarantee proper operation because of limited resources, such as + /// camera device, audio device, and display device.\n. + /// A @a camera must be released using camera_destroy(). + /// @remarks The privilege %http://tizen.org/privilege/camera is not required since 4.0,\n + /// but it is required in all earlier versions. + /// @param[in] device The hardware camera to access + /// @param[out] camera A newly returned handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CAMERA_ERROR_SOUND_POLICY Sound policy error + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @post If it succeeds, the camera state will be #CAMERA_STATE_CREATED. + /// + /// @see camera_destroy() + int camera_create( + int device, + ffi.Pointer> camera, + ) { + return _camera_create( + device, + camera, + ); + } + + late final _camera_create_ptr = + _lookup>('camera_create'); + late final _dart_camera_create _camera_create = + _camera_create_ptr.asFunction<_dart_camera_create>(); + + /// @brief Changes the camera device. + /// + /// @since_tizen 3.0 + /// @remarks This function can be used to change camera device simply without camera_destroy() and camera_create().\n + /// If display reuse hint is set by camera_set_display_reuse_hint() before stopping the preview,\n + /// display handle will be reused and last frame on display can be kept even though camera device is changed. + /// @param[in] camera The handle to the camera + /// @param[in] device The hardware camera to access + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED. + /// @post If it succeeds, the camera attributes and settings will be reset. + /// + /// @see camera_set_display_reuse_hint() + /// @see camera_get_display_reuse_hint() + int camera_change_device( + ffi.Pointer camera, + int device, + ) { + return _camera_change_device( + camera, + device, + ); + } + + late final _camera_change_device_ptr = + _lookup>( + 'camera_change_device'); + late final _dart_camera_change_device _camera_change_device = + _camera_change_device_ptr.asFunction<_dart_camera_change_device>(); + + /// @brief Destroys the camera handle and releases all its resources. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @see camera_create() + int camera_destroy( + ffi.Pointer camera, + ) { + return _camera_destroy( + camera, + ); + } + + late final _camera_destroy_ptr = + _lookup>('camera_destroy'); + late final _dart_camera_destroy _camera_destroy = + _camera_destroy_ptr.asFunction<_dart_camera_destroy>(); + + /// @brief Starts capturing and drawing preview frames on the screen. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/camera + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_SOUND_POLICY Sound policy error + /// @retval #CAMERA_ERROR_RESOURCE_CONFLICT Resource conflict error + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_DEVICE_BUSY The device is being used in another application or is performing other operations + /// @retval #CAMERA_ERROR_DEVICE_NOT_FOUND No camera device + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_CAPTURED.\n + /// You must set the display handle. \n + /// If needed, modify preview FPS(camera_attr_set_preview_fps()), + /// preview resolution(camera_set_preview_resolution()), or preview format(camera_set_preview_format()). + /// @post If it succeeds, the camera state will be #CAMERA_STATE_PREVIEW.\n + /// camera_preview_cb() will be called when preview image data becomes available. + /// + /// @see camera_stop_preview() + /// @see camera_set_display() + /// @see camera_set_preview_cb() + /// @see camera_set_media_packet_preview_cb() + /// @see camera_foreach_supported_preview_resolution() + /// @see camera_set_preview_resolution() + /// @see camera_get_preview_resolution() + /// @see camera_foreach_supported_preview_format() + /// @see camera_set_preview_format() + /// @see camera_get_preview_format() + /// @see camera_attr_foreach_supported_fps() + /// @see camera_attr_set_preview_fps() + /// @see camera_attr_get_preview_fps() + int camera_start_preview( + ffi.Pointer camera, + ) { + return _camera_start_preview( + camera, + ); + } + + late final _camera_start_preview_ptr = + _lookup>( + 'camera_start_preview'); + late final _dart_camera_start_preview _camera_start_preview = + _camera_start_preview_ptr.asFunction<_dart_camera_start_preview>(); + + /// @brief Stops capturing and drawing preview frames. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/camera + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_PREVIEW. + /// @post The camera state will be #CAMERA_STATE_CREATED. + /// @see camera_start_preview() + /// @see camera_unset_preview_cb() + /// @see camera_unset_media_packet_preview_cb() + int camera_stop_preview( + ffi.Pointer camera, + ) { + return _camera_stop_preview( + camera, + ); + } + + late final _camera_stop_preview_ptr = + _lookup>( + 'camera_stop_preview'); + late final _dart_camera_stop_preview _camera_stop_preview = + _camera_stop_preview_ptr.asFunction<_dart_camera_stop_preview>(); + + /// @brief Starts capturing of still images. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/camera + /// @remarks This function causes the transition of the camera state from #CAMERA_STATE_CAPTURING to #CAMERA_STATE_CAPTURED automatically\n + /// and the corresponding callback function camera_capturing_cb() and camera_capture_completed_cb() will be invoked\n + /// The captured image will be delivered through camera_capturing_cb().\n + /// camera_capture_completed_cb() callback notifies about completion of camera_capturing_cb(). \n + /// The camera's preview should be restarted by calling camera_start_preview(). + /// @param[in] camera The handle to the camera + /// @param[in] capturing_cb The callback for capturing data + /// @param[in] completed_cb The callback for notification of completion + /// @param[in] user_data The user data + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_PREVIEW. \n + /// If needed, modify capture resolution(camera_set_capture_resolution()), + /// capture format(camera_set_capture_format()), or image quality(camera_attr_set_image_quality()). + /// @post If it succeeds the camera state will be #CAMERA_STATE_CAPTURED. + /// + /// @see camera_start_preview() + /// @see camera_start_continuous_capture(); + /// @see camera_foreach_supported_capture_resolution() + /// @see camera_set_capture_resolution() + /// @see camera_get_capture_resolution() + /// @see camera_foreach_supported_capture_format() + /// @see camera_set_capture_format() + /// @see camera_get_capture_format() + /// @see camera_attr_set_image_quality() + /// @see camera_attr_get_image_quality() + int camera_start_capture( + ffi.Pointer camera, + ffi.Pointer> capturing_cb, + ffi.Pointer> completed_cb, + ffi.Pointer user_data, + ) { + return _camera_start_capture( + camera, + capturing_cb, + completed_cb, + user_data, + ); + } + + late final _camera_start_capture_ptr = + _lookup>( + 'camera_start_capture'); + late final _dart_camera_start_capture _camera_start_capture = + _camera_start_capture_ptr.asFunction<_dart_camera_start_capture>(); + + /// @brief Starts continuously capturing still images. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/camera + /// @remarks If this is not supported zero shutter lag occurs. The capture resolution could be changed to the preview resolution.\n + /// This function causes the transition of the camera state from #CAMERA_STATE_CAPTURING to #CAMERA_STATE_CAPTURED automatically\n + /// and the corresponding callback function camera_capturing_cb() and camera_capture_completed_cb() will be invoked\n + /// Each Captured image will be delivered through camera_capturing_cb().\n + /// The camera_capture_completed_cb() callback notifies about the completion of an entire capture.\n + /// The camera's preview should be restarted by calling camera_start_preview().\n. + /// @param[in] camera The handle to the camera + /// @param[in] count The number of still images + /// @param[in] interval The interval of the capture (millisecond) + /// @param[in] capturing_cb The callback for capturing data + /// @param[in] completed_cb The callback for notification of completion + /// @param[in] user_data The user data + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post If it succeeds the camera state will be #CAMERA_STATE_CAPTURED. + /// + /// @see camera_start_preview() + /// @see camera_start_capture(); + /// @see camera_stop_continuous_capture() + /// @see camera_is_supported_zero_shutter_lag() + int camera_start_continuous_capture( + ffi.Pointer camera, + int count, + int interval, + ffi.Pointer> capturing_cb, + ffi.Pointer> completed_cb, + ffi.Pointer user_data, + ) { + return _camera_start_continuous_capture( + camera, + count, + interval, + capturing_cb, + completed_cb, + user_data, + ); + } + + late final _camera_start_continuous_capture_ptr = + _lookup>( + 'camera_start_continuous_capture'); + late final _dart_camera_start_continuous_capture + _camera_start_continuous_capture = _camera_start_continuous_capture_ptr + .asFunction<_dart_camera_start_continuous_capture>(); + + /// @brief Aborts continuous capturing. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/camera + /// @remarks The camera state will be changed to #CAMERA_STATE_CAPTURED. + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_PREVIEW. + /// + /// @see camera_start_continuous_capture() + int camera_stop_continuous_capture( + ffi.Pointer camera, + ) { + return _camera_stop_continuous_capture( + camera, + ); + } + + late final _camera_stop_continuous_capture_ptr = + _lookup>( + 'camera_stop_continuous_capture'); + late final _dart_camera_stop_continuous_capture + _camera_stop_continuous_capture = _camera_stop_continuous_capture_ptr + .asFunction<_dart_camera_stop_continuous_capture>(); + + /// @brief Gets the state of the camera. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] state The current state of the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_create() + /// @see camera_start_preview() + /// @see camera_stop_preview() + /// @see camera_start_capture() + int camera_get_state( + ffi.Pointer camera, + ffi.Pointer state, + ) { + return _camera_get_state( + camera, + state, + ); + } + + late final _camera_get_state_ptr = + _lookup>('camera_get_state'); + late final _dart_camera_get_state _camera_get_state = + _camera_get_state_ptr.asFunction<_dart_camera_get_state>(); + + /// @brief Starts camera auto-focusing, asynchronously. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/camera + /// @remarks If continuous status is @c true, the camera continuously tries to focus. + /// @param[in] camera The handle to the camera + /// @param[in] continuous The status of continuous focusing + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_PREVIEW. + /// @post The camera focus state will be #CAMERA_FOCUS_STATE_ONGOING. + /// + /// @see camera_cancel_focusing() + /// @see camera_set_focus_changed_cb() + /// @see camera_focus_changed_cb() + /// @see camera_attr_set_af_mode() + int camera_start_focusing( + ffi.Pointer camera, + bool continuous, + ) { + return _camera_start_focusing( + camera, + continuous ? 1 : 0, + ); + } + + late final _camera_start_focusing_ptr = + _lookup>( + 'camera_start_focusing'); + late final _dart_camera_start_focusing _camera_start_focusing = + _camera_start_focusing_ptr.asFunction<_dart_camera_start_focusing>(); + + /// @brief Stops camera auto focusing. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/camera + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_PREVIEW. + /// + /// @see camera_start_focusing() + /// @see camera_focus_changed_cb() + int camera_cancel_focusing( + ffi.Pointer camera, + ) { + return _camera_cancel_focusing( + camera, + ); + } + + late final _camera_cancel_focusing_ptr = + _lookup>( + 'camera_cancel_focusing'); + late final _dart_camera_cancel_focusing _camera_cancel_focusing = + _camera_cancel_focusing_ptr.asFunction<_dart_camera_cancel_focusing>(); + + /// @brief Sets the display handle to show preview images. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This function must be called before previewing (see camera_start_preview()). + /// In Custom ROI display mode, camera_attr_set_display_roi_area() function must be called before calling this function. + /// @param[in] camera The handle to the camera + /// @param[in] type The display type + /// @param[in] display The display handle from #GET_DISPLAY + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED. + /// + /// @see camera_start_preview() + /// @see #GET_DISPLAY + int camera_set_display( + ffi.Pointer camera, + int type, + ffi.Pointer display, + ) { + return _camera_set_display( + camera, + type, + display, + ); + } + + late final _camera_set_display_ptr = + _lookup>('camera_set_display'); + late final _dart_camera_set_display _camera_set_display = + _camera_set_display_ptr.asFunction<_dart_camera_set_display>(); + + /// @brief Sets the resolution of the preview. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This function should be called before previewing (camera_start_preview()). + /// @param[in] camera The handle to the camera + /// @param[in] width The preview width + /// @param[in] height The preview height + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// + /// @see camera_start_preview() + /// @see camera_get_preview_resolution() + /// @see camera_foreach_supported_preview_resolution() + int camera_set_preview_resolution( + ffi.Pointer camera, + int width, + int height, + ) { + return _camera_set_preview_resolution( + camera, + width, + height, + ); + } + + late final _camera_set_preview_resolution_ptr = + _lookup>( + 'camera_set_preview_resolution'); + late final _dart_camera_set_preview_resolution + _camera_set_preview_resolution = _camera_set_preview_resolution_ptr + .asFunction<_dart_camera_set_preview_resolution>(); + + /// @brief Gets the resolution of the preview. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] width The preview width + /// @param[out] height The preview height + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_preview_resolution() + /// @see camera_foreach_supported_preview_resolution() + int camera_get_preview_resolution( + ffi.Pointer camera, + ffi.Pointer width, + ffi.Pointer height, + ) { + return _camera_get_preview_resolution( + camera, + width, + height, + ); + } + + late final _camera_get_preview_resolution_ptr = + _lookup>( + 'camera_get_preview_resolution'); + late final _dart_camera_get_preview_resolution + _camera_get_preview_resolution = _camera_get_preview_resolution_ptr + .asFunction<_dart_camera_get_preview_resolution>(); + + /// @brief Gets the recommended preview resolution. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks Depending on the capture resolution aspect ratio and display resolution, the recommended preview resolution is determined. + /// @param[in] camera The handle to the camera + /// @param[out] width The preview width + /// @param[out] height The preview height + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_preview_resolution() + /// @see camera_foreach_supported_preview_resolution() + int camera_get_recommended_preview_resolution( + ffi.Pointer camera, + ffi.Pointer width, + ffi.Pointer height, + ) { + return _camera_get_recommended_preview_resolution( + camera, + width, + height, + ); + } + + late final _camera_get_recommended_preview_resolution_ptr = + _lookup>( + 'camera_get_recommended_preview_resolution'); + late final _dart_camera_get_recommended_preview_resolution + _camera_get_recommended_preview_resolution = + _camera_get_recommended_preview_resolution_ptr + .asFunction<_dart_camera_get_recommended_preview_resolution>(); + + /// @brief Starts face detection. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/camera + /// @remarks This should be called after the preview is started.\n + /// This callback will be invoked when the face is detected in the preview frame.\n + /// Internally it starts continuous focus and focusing on the detected face.\n + /// When face detection is running, the camera_start_focusing(), camera_cancel_focusing(), camera_attr_set_af_mode(), camera_attr_set_af_area(), camera_attr_set_exposure_mode(), and camera_attr_set_whitebalance() settings are ignored.\n + /// If camera_stop_preview() is invoked, face detection is stopped and then preview is resumed using camera_start_preview(), this method should be called again to resume face detection. + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback to notify face detection + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Not preview state + /// @retval #CAMERA_ERROR_INVALID_OPERATION Not supported this feature + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be #CAMERA_STATE_PREVIEW. + /// + /// @see camera_stop_face_detection() + /// @see camera_face_detected_cb() + /// @see camera_is_supported_face_detection() + int camera_start_face_detection( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_start_face_detection( + camera, + callback, + user_data, + ); + } + + late final _camera_start_face_detection_ptr = + _lookup>( + 'camera_start_face_detection'); + late final _dart_camera_start_face_detection _camera_start_face_detection = + _camera_start_face_detection_ptr + .asFunction<_dart_camera_start_face_detection>(); + + /// @brief Stops face detection. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/camera + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre This should be called after face detection is started. + /// + /// @see camera_start_face_detection() + /// @see camera_is_supported_face_detection() + int camera_stop_face_detection( + ffi.Pointer camera, + ) { + return _camera_stop_face_detection( + camera, + ); + } + + late final _camera_stop_face_detection_ptr = + _lookup>( + 'camera_stop_face_detection'); + late final _dart_camera_stop_face_detection _camera_stop_face_detection = + _camera_stop_face_detection_ptr + .asFunction<_dart_camera_stop_face_detection>(); + + /// @brief Gets continuous capture feature's supported state. + /// @ingroup CAPI_MEDIA_CAMERA_CAPABILITY_MODULE + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] camera The handle to the camera + /// @return @c true on supported, otherwise false + /// @exception #CAMERA_ERROR_NONE Successful + /// @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + bool camera_is_supported_continuous_capture( + ffi.Pointer camera, + ) { + return _camera_is_supported_continuous_capture( + camera, + ) != + 0; + } + + late final _camera_is_supported_continuous_capture_ptr = + _lookup>( + 'camera_is_supported_continuous_capture'); + late final _dart_camera_is_supported_continuous_capture + _camera_is_supported_continuous_capture = + _camera_is_supported_continuous_capture_ptr + .asFunction<_dart_camera_is_supported_continuous_capture>(); + + /// @brief Retrieves all supported camera preview resolutions by invoking the callback function once for each supported camera preview resolution. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_supported_preview_resolution_cb() repeatedly to retrieve each supported preview resolution. + /// + /// @see camera_set_preview_resolution() + /// @see camera_get_preview_resolution() + /// @see camera_supported_preview_resolution_cb() + int camera_foreach_supported_preview_resolution( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _camera_foreach_supported_preview_resolution( + camera, + callback, + user_data, + ); + } + + late final _camera_foreach_supported_preview_resolution_ptr = _lookup< + ffi.NativeFunction<_c_camera_foreach_supported_preview_resolution>>( + 'camera_foreach_supported_preview_resolution'); + late final _dart_camera_foreach_supported_preview_resolution + _camera_foreach_supported_preview_resolution = + _camera_foreach_supported_preview_resolution_ptr + .asFunction<_dart_camera_foreach_supported_preview_resolution>(); + + /// @ingroup CAPI_MEDIA_CAMERA_DISPLAY_MODULE + /// @brief Sets the display rotation. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This function should be called before previewing (see camera_start_preview()) + /// @param[in] camera The handle to the camera + /// @param[in] rotation The display rotation + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_INVALID_OPERATION Display type is incorrect + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_start_preview() + /// @see camera_get_display_rotation() + int camera_set_display_rotation( + ffi.Pointer camera, + int rotation, + ) { + return _camera_set_display_rotation( + camera, + rotation, + ); + } + + late final _camera_set_display_rotation_ptr = + _lookup>( + 'camera_set_display_rotation'); + late final _dart_camera_set_display_rotation _camera_set_display_rotation = + _camera_set_display_rotation_ptr + .asFunction<_dart_camera_set_display_rotation>(); + + /// @ingroup CAPI_MEDIA_CAMERA_DISPLAY_MODULE + /// @brief Gets the display rotation. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] rotation The display rotation + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_display_rotation() + int camera_get_display_rotation( + ffi.Pointer camera, + ffi.Pointer rotation, + ) { + return _camera_get_display_rotation( + camera, + rotation, + ); + } + + late final _camera_get_display_rotation_ptr = + _lookup>( + 'camera_get_display_rotation'); + late final _dart_camera_get_display_rotation _camera_get_display_rotation = + _camera_get_display_rotation_ptr + .asFunction<_dart_camera_get_display_rotation>(); + + /// @ingroup CAPI_MEDIA_CAMERA_DISPLAY_MODULE + /// @brief Sets the display flip. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] flip The display flip + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_INVALID_OPERATION Display type is incorrect + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_get_display_flip() + int camera_set_display_flip( + ffi.Pointer camera, + int flip, + ) { + return _camera_set_display_flip( + camera, + flip, + ); + } + + late final _camera_set_display_flip_ptr = + _lookup>( + 'camera_set_display_flip'); + late final _dart_camera_set_display_flip _camera_set_display_flip = + _camera_set_display_flip_ptr.asFunction<_dart_camera_set_display_flip>(); + + /// @ingroup CAPI_MEDIA_CAMERA_DISPLAY_MODULE + /// @brief Gets the display flip. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] flip The display flip + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_display_flip() + int camera_get_display_flip( + ffi.Pointer camera, + ffi.Pointer flip, + ) { + return _camera_get_display_flip( + camera, + flip, + ); + } + + late final _camera_get_display_flip_ptr = + _lookup>( + 'camera_get_display_flip'); + late final _dart_camera_get_display_flip _camera_get_display_flip = + _camera_get_display_flip_ptr.asFunction<_dart_camera_get_display_flip>(); + + /// @ingroup CAPI_MEDIA_CAMERA_DISPLAY_MODULE + /// @brief Sets the visible property for display. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] visible The display visibility property + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_is_display_visible() + int camera_set_display_visible( + ffi.Pointer camera, + bool visible, + ) { + return _camera_set_display_visible( + camera, + visible ? 1 : 0, + ); + } + + late final _camera_set_display_visible_ptr = + _lookup>( + 'camera_set_display_visible'); + late final _dart_camera_set_display_visible _camera_set_display_visible = + _camera_set_display_visible_ptr + .asFunction<_dart_camera_set_display_visible>(); + + /// @ingroup CAPI_MEDIA_CAMERA_DISPLAY_MODULE + /// @brief Gets the visible property of display. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] visible @c true if camera display is visible, otherwise @c false + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_display_visible() + int camera_is_display_visible( + ffi.Pointer camera, + ffi.Pointer visible, + ) { + return _camera_is_display_visible( + camera, + visible, + ); + } + + late final _camera_is_display_visible_ptr = + _lookup>( + 'camera_is_display_visible'); + late final _dart_camera_is_display_visible _camera_is_display_visible = + _camera_is_display_visible_ptr + .asFunction<_dart_camera_is_display_visible>(); + + /// @ingroup CAPI_MEDIA_CAMERA_DISPLAY_MODULE + /// @brief Sets the display mode. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] mode The display mode + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_get_display_mode() + int camera_set_display_mode( + ffi.Pointer camera, + int mode, + ) { + return _camera_set_display_mode( + camera, + mode, + ); + } + + late final _camera_set_display_mode_ptr = + _lookup>( + 'camera_set_display_mode'); + late final _dart_camera_set_display_mode _camera_set_display_mode = + _camera_set_display_mode_ptr.asFunction<_dart_camera_set_display_mode>(); + + /// @ingroup CAPI_MEDIA_CAMERA_DISPLAY_MODULE + /// @brief Gets the display mode. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] mode The display mode + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_display_mode() + int camera_get_display_mode( + ffi.Pointer camera, + ffi.Pointer mode, + ) { + return _camera_get_display_mode( + camera, + mode, + ); + } + + late final _camera_get_display_mode_ptr = + _lookup>( + 'camera_get_display_mode'); + late final _dart_camera_get_display_mode _camera_get_display_mode = + _camera_get_display_mode_ptr.asFunction<_dart_camera_get_display_mode>(); + + /// @brief Sets the hint for display reuse. + /// @since_tizen 3.0 + /// @details If the hint is set to true, the display will be reused when the camera device is changed with camera_change_device(). + /// @remarks If the current display type is #CAMERA_DISPLAY_TYPE_NONE, this function will return #CAMERA_ERROR_INVALID_OPERATION. + /// @param[in] camera The handle to the camera + /// @param[in] hint The hint for display reuse; true - reuse the display, false - do not reuse + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_PREVIEW. + /// @see camera_get_display_reuse_hint() + /// @see camera_change_device() + int camera_set_display_reuse_hint( + ffi.Pointer camera, + bool hint, + ) { + return _camera_set_display_reuse_hint( + camera, + hint ? 1 : 0, + ); + } + + late final _camera_set_display_reuse_hint_ptr = + _lookup>( + 'camera_set_display_reuse_hint'); + late final _dart_camera_set_display_reuse_hint + _camera_set_display_reuse_hint = _camera_set_display_reuse_hint_ptr + .asFunction<_dart_camera_set_display_reuse_hint>(); + + /// @brief Gets the hint for display reuse. + /// @since_tizen 3.0 + /// @remarks If the current display type is #CAMERA_DISPLAY_TYPE_NONE, this function will return #CAMERA_ERROR_INVALID_OPERATION. + /// @param[in] camera The handle to the camera + /// @param[out] hint The hint for display reuse; true - reuse the display, false - do not reuse + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_get_display_reuse_hint() + /// @see camera_change_device() + int camera_get_display_reuse_hint( + ffi.Pointer camera, + ffi.Pointer hint, + ) { + return _camera_get_display_reuse_hint( + camera, + hint, + ); + } + + late final _camera_get_display_reuse_hint_ptr = + _lookup>( + 'camera_get_display_reuse_hint'); + late final _dart_camera_get_display_reuse_hint + _camera_get_display_reuse_hint = _camera_get_display_reuse_hint_ptr + .asFunction<_dart_camera_get_display_reuse_hint>(); + + /// @brief Sets the resolution of the captured image. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] width The capture width + /// @param[in] height The capture height + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_start_capture() + /// @see camera_get_capture_resolution() + /// @see camera_foreach_supported_capture_resolution() + int camera_set_capture_resolution( + ffi.Pointer camera, + int width, + int height, + ) { + return _camera_set_capture_resolution( + camera, + width, + height, + ); + } + + late final _camera_set_capture_resolution_ptr = + _lookup>( + 'camera_set_capture_resolution'); + late final _dart_camera_set_capture_resolution + _camera_set_capture_resolution = _camera_set_capture_resolution_ptr + .asFunction<_dart_camera_set_capture_resolution>(); + + /// @brief Gets the resolution of the captured image. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] width The capture width + /// @param[out] height The capture height + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_capture_resolution() + /// @see camera_foreach_supported_capture_resolution() + int camera_get_capture_resolution( + ffi.Pointer camera, + ffi.Pointer width, + ffi.Pointer height, + ) { + return _camera_get_capture_resolution( + camera, + width, + height, + ); + } + + late final _camera_get_capture_resolution_ptr = + _lookup>( + 'camera_get_capture_resolution'); + late final _dart_camera_get_capture_resolution + _camera_get_capture_resolution = _camera_get_capture_resolution_ptr + .asFunction<_dart_camera_get_capture_resolution>(); + + /// @brief Retrieves all supported camera captured resolutions by invoking the callback function once for each supported camera capture resolution. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_supported_capture_resolution_cb() repeatedly to retrieve each supported capture resolution. + /// @see camera_set_capture_resolution() + /// @see camera_get_capture_resolution() + /// @see camera_supported_capture_resolution_cb() + int camera_foreach_supported_capture_resolution( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _camera_foreach_supported_capture_resolution( + camera, + callback, + user_data, + ); + } + + late final _camera_foreach_supported_capture_resolution_ptr = _lookup< + ffi.NativeFunction<_c_camera_foreach_supported_capture_resolution>>( + 'camera_foreach_supported_capture_resolution'); + late final _dart_camera_foreach_supported_capture_resolution + _camera_foreach_supported_capture_resolution = + _camera_foreach_supported_capture_resolution_ptr + .asFunction<_dart_camera_foreach_supported_capture_resolution>(); + + /// @brief Sets the format of an image to be captured. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This function should be called before capturing (see camera_start_capture()). + /// @param[in] camera The handle to the camera + /// @param[out] format The format of the image to be captured + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_start_capture() + /// @see camera_get_capture_format() + /// @see camera_foreach_supported_capture_format() + int camera_set_capture_format( + ffi.Pointer camera, + int format, + ) { + return _camera_set_capture_format( + camera, + format, + ); + } + + late final _camera_set_capture_format_ptr = + _lookup>( + 'camera_set_capture_format'); + late final _dart_camera_set_capture_format _camera_set_capture_format = + _camera_set_capture_format_ptr + .asFunction<_dart_camera_set_capture_format>(); + + /// @brief Gets the format of the image to be captured. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] format The format of the image to be captured + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_capture_format() + /// @see camera_foreach_supported_capture_format() + int camera_get_capture_format( + ffi.Pointer camera, + ffi.Pointer format, + ) { + return _camera_get_capture_format( + camera, + format, + ); + } + + late final _camera_get_capture_format_ptr = + _lookup>( + 'camera_get_capture_format'); + late final _dart_camera_get_capture_format _camera_get_capture_format = + _camera_get_capture_format_ptr + .asFunction<_dart_camera_get_capture_format>(); + + /// @brief Retrieves all supported camera capture formats by invoking the callback function once for each supported camera capture format. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_supported_capture_format_cb() repeatedly to retrieve each supported capture format. + /// @see camera_set_capture_format() + /// @see camera_get_capture_format() + /// @see camera_supported_capture_format_cb() + int camera_foreach_supported_capture_format( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _camera_foreach_supported_capture_format( + camera, + callback, + user_data, + ); + } + + late final _camera_foreach_supported_capture_format_ptr = + _lookup>( + 'camera_foreach_supported_capture_format'); + late final _dart_camera_foreach_supported_capture_format + _camera_foreach_supported_capture_format = + _camera_foreach_supported_capture_format_ptr + .asFunction<_dart_camera_foreach_supported_capture_format>(); + + /// @brief Sets the preview data format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This function should be called before previewing (see camera_start_preview()). + /// @param[in] camera The handle to the camera + /// @param[in] format The preview data format + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED. + /// @see camera_start_preview() + /// @see camera_get_preview_format() + /// @see camera_foreach_supported_preview_format() + int camera_set_preview_format( + ffi.Pointer camera, + int format, + ) { + return _camera_set_preview_format( + camera, + format, + ); + } + + late final _camera_set_preview_format_ptr = + _lookup>( + 'camera_set_preview_format'); + late final _dart_camera_set_preview_format _camera_set_preview_format = + _camera_set_preview_format_ptr + .asFunction<_dart_camera_set_preview_format>(); + + /// @brief Gets the format of the preview stream. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] format The preview data format + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_preview_format() + /// @see camera_foreach_supported_preview_format() + int camera_get_preview_format( + ffi.Pointer camera, + ffi.Pointer format, + ) { + return _camera_get_preview_format( + camera, + format, + ); + } + + late final _camera_get_preview_format_ptr = + _lookup>( + 'camera_get_preview_format'); + late final _dart_camera_get_preview_format _camera_get_preview_format = + _camera_get_preview_format_ptr + .asFunction<_dart_camera_get_preview_format>(); + + /// @brief Gets the facing direction of camera module. + /// @since_tizen 3.0 + /// @param[in] camera The handle to the camera + /// @param[out] facing_direction The facing direction of camera module + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + int camera_get_facing_direction( + ffi.Pointer camera, + ffi.Pointer facing_direction, + ) { + return _camera_get_facing_direction( + camera, + facing_direction, + ); + } + + late final _camera_get_facing_direction_ptr = + _lookup>( + 'camera_get_facing_direction'); + late final _dart_camera_get_facing_direction _camera_get_facing_direction = + _camera_get_facing_direction_ptr + .asFunction<_dart_camera_get_facing_direction>(); + + /// @brief Gets the camera's flash state. + /// @since_tizen 3.0 + /// @param[in] device The hardware camera to access + /// @param[out] state The current flash state + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @see camera_attr_set_flash_mode() + /// @see camera_attr_get_flash_mode() + int camera_get_flash_state( + int device, + ffi.Pointer state, + ) { + return _camera_get_flash_state( + device, + state, + ); + } + + late final _camera_get_flash_state_ptr = + _lookup>( + 'camera_get_flash_state'); + late final _dart_camera_get_flash_state _camera_get_flash_state = + _camera_get_flash_state_ptr.asFunction<_dart_camera_get_flash_state>(); + + /// @brief Retrieves all supported camera preview formats by invoking the callback function once for each supported camera preview format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_supported_preview_format_cb() repeatedly to retrieve each supported preview format. + /// @see camera_set_preview_format() + /// @see camera_get_preview_format() + /// @see camera_supported_preview_format_cb() + int camera_foreach_supported_preview_format( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _camera_foreach_supported_preview_format( + camera, + callback, + user_data, + ); + } + + late final _camera_foreach_supported_preview_format_ptr = + _lookup>( + 'camera_foreach_supported_preview_format'); + late final _dart_camera_foreach_supported_preview_format + _camera_foreach_supported_preview_format = + _camera_foreach_supported_preview_format_ptr + .asFunction<_dart_camera_foreach_supported_preview_format>(); + + /// @ingroup CAPI_MEDIA_CAMERA_CAPABILITY_MODULE + /// @brief Gets the face detection feature's supported state. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] camera The handle to the camera + /// @return @c true if supported, otherwise @c false + /// @see camera_start_face_detection() + /// @see camera_stop_face_detection() + /// @exception #CAMERA_ERROR_NONE Successful + /// @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + bool camera_is_supported_face_detection( + ffi.Pointer camera, + ) { + return _camera_is_supported_face_detection( + camera, + ) != + 0; + } + + late final _camera_is_supported_face_detection_ptr = + _lookup>( + 'camera_is_supported_face_detection'); + late final _dart_camera_is_supported_face_detection + _camera_is_supported_face_detection = + _camera_is_supported_face_detection_ptr + .asFunction<_dart_camera_is_supported_face_detection>(); + + /// @brief Gets the zero shutter lag feature's supported state. + /// @ingroup CAPI_MEDIA_CAMERA_CAPABILITY_MODULE + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If supporting zero shutter lag, continuous shot can be done with full capture size. \n + /// The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] camera The handle to the camera + /// @return @c true if supported, otherwise @c false + /// @exception #CAMERA_ERROR_NONE Successful + /// @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + bool camera_is_supported_zero_shutter_lag( + ffi.Pointer camera, + ) { + return _camera_is_supported_zero_shutter_lag( + camera, + ) != + 0; + } + + late final _camera_is_supported_zero_shutter_lag_ptr = + _lookup>( + 'camera_is_supported_zero_shutter_lag'); + late final _dart_camera_is_supported_zero_shutter_lag + _camera_is_supported_zero_shutter_lag = + _camera_is_supported_zero_shutter_lag_ptr + .asFunction<_dart_camera_is_supported_zero_shutter_lag>(); + + /// @ingroup CAPI_MEDIA_CAMERA_CAPABILITY_MODULE + /// @brief Gets the camera device count. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If the device supports primary and secondary camera, this returns @c 2. If @c 1 is returned, the device only supports primary camera. + /// @param[in] camera The handle to the camera + /// @param[out] device_count The device count + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + int camera_get_device_count( + ffi.Pointer camera, + ffi.Pointer device_count, + ) { + return _camera_get_device_count( + camera, + device_count, + ); + } + + late final _camera_get_device_count_ptr = + _lookup>( + 'camera_get_device_count'); + late final _dart_camera_get_device_count _camera_get_device_count = + _camera_get_device_count_ptr.asFunction<_dart_camera_get_device_count>(); + + /// @brief Gets the media packet preview callback feature's supported state. + /// @ingroup CAPI_MEDIA_CAMERA_CAPABILITY_MODULE + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] camera The handle to the camera + /// @return @c true if supported, otherwise @c false + /// @exception #CAMERA_ERROR_NONE Successful + /// @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + bool camera_is_supported_media_packet_preview_cb( + ffi.Pointer camera, + ) { + return _camera_is_supported_media_packet_preview_cb( + camera, + ) != + 0; + } + + late final _camera_is_supported_media_packet_preview_cb_ptr = _lookup< + ffi.NativeFunction<_c_camera_is_supported_media_packet_preview_cb>>( + 'camera_is_supported_media_packet_preview_cb'); + late final _dart_camera_is_supported_media_packet_preview_cb + _camera_is_supported_media_packet_preview_cb = + _camera_is_supported_media_packet_preview_cb_ptr + .asFunction<_dart_camera_is_supported_media_packet_preview_cb>(); + + /// @brief Registers a callback function to be called once per frame when previewing. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This callback does not work in the video recorder mode.\n + /// Before 4.0, the only allowed state for calling this function was #CAMERA_STATE_CREATED.\n + /// Since 4.0, #CAMERA_STATE_PREVIEW has been added as an allowed state,\n + /// so that this function could be called before previewing or even while previewing.\n + /// A registered callback is called on the internal thread of the camera.\n + /// A video frame can be retrieved using a registered callback,\n + /// and the buffer is only available in a registered callback.\n + /// Since tizen 3.0, if you change the buffer in a registered callback,\n + /// it could not be displayed on the device in case of copied buffer.\n + /// and if camera_is_supported_media_packet_preview_cb() returns false,\n + /// it's copied buffer case. + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to be registered + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre Before 4.0 : The camera state must be set to #CAMERA_STATE_CREATED.\n + /// Since 4.0 : The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_start_preview() + /// @see camera_unset_preview_cb() + /// @see camera_preview_cb() + int camera_set_preview_cb( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_set_preview_cb( + camera, + callback, + user_data, + ); + } + + late final _camera_set_preview_cb_ptr = + _lookup>( + 'camera_set_preview_cb'); + late final _dart_camera_set_preview_cb _camera_set_preview_cb = + _camera_set_preview_cb_ptr.asFunction<_dart_camera_set_preview_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_preview_cb() + int camera_unset_preview_cb( + ffi.Pointer camera, + ) { + return _camera_unset_preview_cb( + camera, + ); + } + + late final _camera_unset_preview_cb_ptr = + _lookup>( + 'camera_unset_preview_cb'); + late final _dart_camera_unset_preview_cb _camera_unset_preview_cb = + _camera_unset_preview_cb_ptr.asFunction<_dart_camera_unset_preview_cb>(); + + /// @brief Registers a media packet callback function to be called once per frame when previewing. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This callback does not work in video recorder mode.\n + /// This function should be called before previewing (see camera_start_preview())\n + /// A registered callback is called on the internal thread of the camera.\n + /// A video frame can be retrieved using a registered callback as a media packet.\n + /// The callback function holds the same buffer that will be drawn on the display device.\n + /// So if you change the media packet in a registered callback, it will be displayed on the device\n + /// and the media packet is available until it's destroyed by media_packet_destroy(). + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to be registered + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera's state should be #CAMERA_STATE_CREATED. + /// @see camera_start_preview() + /// @see camera_unset_media_packet_preview_cb() + /// @see camera_media_packet_preview_cb() + int camera_set_media_packet_preview_cb( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_set_media_packet_preview_cb( + camera, + callback, + user_data, + ); + } + + late final _camera_set_media_packet_preview_cb_ptr = + _lookup>( + 'camera_set_media_packet_preview_cb'); + late final _dart_camera_set_media_packet_preview_cb + _camera_set_media_packet_preview_cb = + _camera_set_media_packet_preview_cb_ptr + .asFunction<_dart_camera_set_media_packet_preview_cb>(); + + /// @brief Unregisters the media packet callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_media_packet_preview_cb() + int camera_unset_media_packet_preview_cb( + ffi.Pointer camera, + ) { + return _camera_unset_media_packet_preview_cb( + camera, + ); + } + + late final _camera_unset_media_packet_preview_cb_ptr = + _lookup>( + 'camera_unset_media_packet_preview_cb'); + late final _dart_camera_unset_media_packet_preview_cb + _camera_unset_media_packet_preview_cb = + _camera_unset_media_packet_preview_cb_ptr + .asFunction<_dart_camera_unset_media_packet_preview_cb>(); + + /// @brief Registers a callback function to be called when the camera state changes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function will invoke camera_state_changed_cb() when the camera state changes. + /// @see camera_unset_state_changed_cb() + /// @see camera_state_changed_cb() + int camera_set_state_changed_cb( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_set_state_changed_cb( + camera, + callback, + user_data, + ); + } + + late final _camera_set_state_changed_cb_ptr = + _lookup>( + 'camera_set_state_changed_cb'); + late final _dart_camera_set_state_changed_cb _camera_set_state_changed_cb = + _camera_set_state_changed_cb_ptr + .asFunction<_dart_camera_set_state_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_state_changed_cb() + int camera_unset_state_changed_cb( + ffi.Pointer camera, + ) { + return _camera_unset_state_changed_cb( + camera, + ); + } + + late final _camera_unset_state_changed_cb_ptr = + _lookup>( + 'camera_unset_state_changed_cb'); + late final _dart_camera_unset_state_changed_cb + _camera_unset_state_changed_cb = _camera_unset_state_changed_cb_ptr + .asFunction<_dart_camera_unset_state_changed_cb>(); + + /// @brief Registers a callback function to be called when the camera is interrupted by policy. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_unset_interrupted_cb() + /// @see camera_interrupted_cb() + int camera_set_interrupted_cb( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_set_interrupted_cb( + camera, + callback, + user_data, + ); + } + + late final _camera_set_interrupted_cb_ptr = + _lookup>( + 'camera_set_interrupted_cb'); + late final _dart_camera_set_interrupted_cb _camera_set_interrupted_cb = + _camera_set_interrupted_cb_ptr + .asFunction<_dart_camera_set_interrupted_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_interrupted_cb() + int camera_unset_interrupted_cb( + ffi.Pointer camera, + ) { + return _camera_unset_interrupted_cb( + camera, + ); + } + + late final _camera_unset_interrupted_cb_ptr = + _lookup>( + 'camera_unset_interrupted_cb'); + late final _dart_camera_unset_interrupted_cb _camera_unset_interrupted_cb = + _camera_unset_interrupted_cb_ptr + .asFunction<_dart_camera_unset_interrupted_cb>(); + + /// @brief Registers a callback function to be called when the camera interrupt is started by policy. + /// @since_tizen 4.0 + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @see camera_unset_interrupt_started_cb() + /// @see camera_interrupt_started_cb() + int camera_set_interrupt_started_cb( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_set_interrupt_started_cb( + camera, + callback, + user_data, + ); + } + + late final _camera_set_interrupt_started_cb_ptr = + _lookup>( + 'camera_set_interrupt_started_cb'); + late final _dart_camera_set_interrupt_started_cb + _camera_set_interrupt_started_cb = _camera_set_interrupt_started_cb_ptr + .asFunction<_dart_camera_set_interrupt_started_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen 4.0 + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @see camera_set_interrupt_started_cb() + int camera_unset_interrupt_started_cb( + ffi.Pointer camera, + ) { + return _camera_unset_interrupt_started_cb( + camera, + ); + } + + late final _camera_unset_interrupt_started_cb_ptr = + _lookup>( + 'camera_unset_interrupt_started_cb'); + late final _dart_camera_unset_interrupt_started_cb + _camera_unset_interrupt_started_cb = + _camera_unset_interrupt_started_cb_ptr + .asFunction<_dart_camera_unset_interrupt_started_cb>(); + + /// @brief Registers a callback function to be called when the auto-focus state changes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function will invoke camera_focus_changed_cb() when the auto-focus state changes. + /// @see camera_start_focusing() + /// @see camera_cancel_focusing() + /// @see camera_unset_focus_changed_cb() + /// @see camera_focus_changed_cb() + int camera_set_focus_changed_cb( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_set_focus_changed_cb( + camera, + callback, + user_data, + ); + } + + late final _camera_set_focus_changed_cb_ptr = + _lookup>( + 'camera_set_focus_changed_cb'); + late final _dart_camera_set_focus_changed_cb _camera_set_focus_changed_cb = + _camera_set_focus_changed_cb_ptr + .asFunction<_dart_camera_set_focus_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_focus_changed_cb() + int camera_unset_focus_changed_cb( + ffi.Pointer camera, + ) { + return _camera_unset_focus_changed_cb( + camera, + ); + } + + late final _camera_unset_focus_changed_cb_ptr = + _lookup>( + 'camera_unset_focus_changed_cb'); + late final _dart_camera_unset_focus_changed_cb + _camera_unset_focus_changed_cb = _camera_unset_focus_changed_cb_ptr + .asFunction<_dart_camera_unset_focus_changed_cb>(); + + /// @brief Registers a callback function to be called when an asynchronous operation error occurs. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This callback informs about a critical error situation.\n + /// When this callback is invoked, the user should release the resource and terminate the application.\n + /// In case of errors, one of the following codes will occur:\n + /// #CAMERA_ERROR_DEVICE,\n + /// #CAMERA_ERROR_INVALID_OPERATION,\n + /// #CAMERA_ERROR_OUT_OF_MEMORY. + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function will invoke camera_error_cb() when an asynchronous operation error occurs. + /// + /// @see camera_unset_error_cb() + /// @see camera_error_cb() + int camera_set_error_cb( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_set_error_cb( + camera, + callback, + user_data, + ); + } + + late final _camera_set_error_cb_ptr = + _lookup>( + 'camera_set_error_cb'); + late final _dart_camera_set_error_cb _camera_set_error_cb = + _camera_set_error_cb_ptr.asFunction<_dart_camera_set_error_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_error_cb() + int camera_unset_error_cb( + ffi.Pointer camera, + ) { + return _camera_unset_error_cb( + camera, + ); + } + + late final _camera_unset_error_cb_ptr = + _lookup>( + 'camera_unset_error_cb'); + late final _dart_camera_unset_error_cb _camera_unset_error_cb = + _camera_unset_error_cb_ptr.asFunction<_dart_camera_unset_error_cb>(); + + /// @brief Gets the state of camera device. + /// @since_tizen 3.0 + /// @param[in] device The hardware camera type + /// @param[out] state The current state of the device + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + int camera_get_device_state( + int device, + ffi.Pointer state, + ) { + return _camera_get_device_state( + device, + state, + ); + } + + late final _camera_get_device_state_ptr = + _lookup>( + 'camera_get_device_state'); + late final _dart_camera_get_device_state _camera_get_device_state = + _camera_get_device_state_ptr.asFunction<_dart_camera_get_device_state>(); + + /// @brief Registers a callback function to be called when the camera device state changes. + /// @since_tizen 3.0 + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] cb_id The id of registered callback + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @post This function will invoke camera_device_state_changed_cb() when the camera device's state changes. + /// @see camera_remove_device_state_changed_cb() + /// @see camera_device_state_changed_cb() + int camera_add_device_state_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer cb_id, + ) { + return _camera_add_device_state_changed_cb( + callback, + user_data, + cb_id, + ); + } + + late final _camera_add_device_state_changed_cb_ptr = + _lookup>( + 'camera_add_device_state_changed_cb'); + late final _dart_camera_add_device_state_changed_cb + _camera_add_device_state_changed_cb = + _camera_add_device_state_changed_cb_ptr + .asFunction<_dart_camera_add_device_state_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen 3.0 + /// @param[in] cb_id The id of registered callback + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @see camera_add_device_state_changed_cb() + int camera_remove_device_state_changed_cb( + int cb_id, + ) { + return _camera_remove_device_state_changed_cb( + cb_id, + ); + } + + late final _camera_remove_device_state_changed_cb_ptr = + _lookup>( + 'camera_remove_device_state_changed_cb'); + late final _dart_camera_remove_device_state_changed_cb + _camera_remove_device_state_changed_cb = + _camera_remove_device_state_changed_cb_ptr + .asFunction<_dart_camera_remove_device_state_changed_cb>(); + + /// @brief Sets the preview frame rate. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This function should be called before previewing (see camera_start_preview()). + /// @param[in] camera The handle to the camera + /// @param[in] fps The frame rate + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED. + /// @see camera_start_preview() + /// @see camera_attr_get_preview_fps() + /// @see camera_attr_foreach_supported_fps() + int camera_attr_set_preview_fps( + ffi.Pointer camera, + int fps, + ) { + return _camera_attr_set_preview_fps( + camera, + fps, + ); + } + + late final _camera_attr_set_preview_fps_ptr = + _lookup>( + 'camera_attr_set_preview_fps'); + late final _dart_camera_attr_set_preview_fps _camera_attr_set_preview_fps = + _camera_attr_set_preview_fps_ptr + .asFunction<_dart_camera_attr_set_preview_fps>(); + + /// @brief Gets the frames per second of a preview video stream. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] fps The frames per second of the preview video stream + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_preview_fps() + /// @see camera_attr_foreach_supported_fps() + int camera_attr_get_preview_fps( + ffi.Pointer camera, + ffi.Pointer fps, + ) { + return _camera_attr_get_preview_fps( + camera, + fps, + ); + } + + late final _camera_attr_get_preview_fps_ptr = + _lookup>( + 'camera_attr_get_preview_fps'); + late final _dart_camera_attr_get_preview_fps _camera_attr_get_preview_fps = + _camera_attr_get_preview_fps_ptr + .asFunction<_dart_camera_attr_get_preview_fps>(); + + /// @brief Retrieves all supported FPS modes by invoking the callback function once for each supported FPS mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_attr_supported_fps_cb() repeatedly to get each supported FPS mode. + /// @see camera_attr_set_preview_fps() + /// @see camera_attr_get_preview_fps() + /// @see camera_attr_supported_fps_cb() + int camera_attr_foreach_supported_fps( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_attr_foreach_supported_fps( + camera, + callback, + user_data, + ); + } + + late final _camera_attr_foreach_supported_fps_ptr = + _lookup>( + 'camera_attr_foreach_supported_fps'); + late final _dart_camera_attr_foreach_supported_fps + _camera_attr_foreach_supported_fps = + _camera_attr_foreach_supported_fps_ptr + .asFunction<_dart_camera_attr_foreach_supported_fps>(); + + /// @brief Retrieves all supported FPS modes by invoking the callback function once for each supported FPS mode. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] camera The handle to the camera + /// @param[in] width Required preview resolution's width + /// @param[in] height Required preview resolution's height + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_attr_supported_fps_cb() repeatedly to get each supported FPS mode. + /// @see camera_attr_set_preview_fps() + /// @see camera_attr_get_preview_fps() + /// @see camera_attr_supported_fps_cb() + int camera_attr_foreach_supported_fps_by_resolution( + ffi.Pointer camera, + int width, + int height, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_attr_foreach_supported_fps_by_resolution( + camera, + width, + height, + callback, + user_data, + ); + } + + late final _camera_attr_foreach_supported_fps_by_resolution_ptr = _lookup< + ffi.NativeFunction< + _c_camera_attr_foreach_supported_fps_by_resolution>>( + 'camera_attr_foreach_supported_fps_by_resolution'); + late final _dart_camera_attr_foreach_supported_fps_by_resolution + _camera_attr_foreach_supported_fps_by_resolution = + _camera_attr_foreach_supported_fps_by_resolution_ptr + .asFunction<_dart_camera_attr_foreach_supported_fps_by_resolution>(); + + /// @brief Sets quality of the image. + /// @details The range for image quality is 1 to 100. If @a quality is out of range, #CAMERA_ERROR_INVALID_PARAMETER error occurred. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] quality The quality of image (1 ~ 100) + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_start_preview() + /// @see camera_attr_get_image_quality() + int camera_attr_set_image_quality( + ffi.Pointer camera, + int quality, + ) { + return _camera_attr_set_image_quality( + camera, + quality, + ); + } + + late final _camera_attr_set_image_quality_ptr = + _lookup>( + 'camera_attr_set_image_quality'); + late final _dart_camera_attr_set_image_quality + _camera_attr_set_image_quality = _camera_attr_set_image_quality_ptr + .asFunction<_dart_camera_attr_set_image_quality>(); + + /// @brief Gets the quality of a still image, which is captured. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] quality The quality of the image(1 ~ 100) + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_image_quality() + int camera_attr_get_image_quality( + ffi.Pointer camera, + ffi.Pointer quality, + ) { + return _camera_attr_get_image_quality( + camera, + quality, + ); + } + + late final _camera_attr_get_image_quality_ptr = + _lookup>( + 'camera_attr_get_image_quality'); + late final _dart_camera_attr_get_image_quality + _camera_attr_get_image_quality = _camera_attr_get_image_quality_ptr + .asFunction<_dart_camera_attr_get_image_quality>(); + + /// @brief Gets the bit rate of encoded preview. + /// @since_tizen 3.0 + /// @param[in] camera The handle to the camera + /// @param[out] bitrate The bit rate of encoded preview + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_encoded_preview_bitrate() + int camera_attr_get_encoded_preview_bitrate( + ffi.Pointer camera, + ffi.Pointer bitrate, + ) { + return _camera_attr_get_encoded_preview_bitrate( + camera, + bitrate, + ); + } + + late final _camera_attr_get_encoded_preview_bitrate_ptr = + _lookup>( + 'camera_attr_get_encoded_preview_bitrate'); + late final _dart_camera_attr_get_encoded_preview_bitrate + _camera_attr_get_encoded_preview_bitrate = + _camera_attr_get_encoded_preview_bitrate_ptr + .asFunction<_dart_camera_attr_get_encoded_preview_bitrate>(); + + /// @brief Sets the bit rate of encoded preview. + /// @since_tizen 3.0 + /// @param[in] camera The handle to the camera + /// @param[in] bitrate The bit rate of encoded preview + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_get_encoded_preview_bitrate() + int camera_attr_set_encoded_preview_bitrate( + ffi.Pointer camera, + int bitrate, + ) { + return _camera_attr_set_encoded_preview_bitrate( + camera, + bitrate, + ); + } + + late final _camera_attr_set_encoded_preview_bitrate_ptr = + _lookup>( + 'camera_attr_set_encoded_preview_bitrate'); + late final _dart_camera_attr_set_encoded_preview_bitrate + _camera_attr_set_encoded_preview_bitrate = + _camera_attr_set_encoded_preview_bitrate_ptr + .asFunction<_dart_camera_attr_set_encoded_preview_bitrate>(); + + /// @brief Gets the GOP(Group Of Pictures) interval of encoded preview. + /// @since_tizen 3.0 + /// @param[in] camera The handle to the camera + /// @param[out] interval the GOP interval of encoded preview (millisecond) + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_get_encoded_preview_gop_interval() + int camera_attr_get_encoded_preview_gop_interval( + ffi.Pointer camera, + ffi.Pointer interval, + ) { + return _camera_attr_get_encoded_preview_gop_interval( + camera, + interval, + ); + } + + late final _camera_attr_get_encoded_preview_gop_interval_ptr = _lookup< + ffi.NativeFunction<_c_camera_attr_get_encoded_preview_gop_interval>>( + 'camera_attr_get_encoded_preview_gop_interval'); + late final _dart_camera_attr_get_encoded_preview_gop_interval + _camera_attr_get_encoded_preview_gop_interval = + _camera_attr_get_encoded_preview_gop_interval_ptr + .asFunction<_dart_camera_attr_get_encoded_preview_gop_interval>(); + + /// @brief Sets the GOP(Group Of Pictures) interval of encoded preview. + /// @since_tizen 3.0 + /// @param[in] camera The handle to the camera + /// @param[in] interval the GOP interval of encoded preview (millisecond) + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_encoded_preview_gop_interval() + int camera_attr_set_encoded_preview_gop_interval( + ffi.Pointer camera, + int interval, + ) { + return _camera_attr_set_encoded_preview_gop_interval( + camera, + interval, + ); + } + + late final _camera_attr_set_encoded_preview_gop_interval_ptr = _lookup< + ffi.NativeFunction<_c_camera_attr_set_encoded_preview_gop_interval>>( + 'camera_attr_set_encoded_preview_gop_interval'); + late final _dart_camera_attr_set_encoded_preview_gop_interval + _camera_attr_set_encoded_preview_gop_interval = + _camera_attr_set_encoded_preview_gop_interval_ptr + .asFunction<_dart_camera_attr_set_encoded_preview_gop_interval>(); + + /// @brief Sets the zoom level. + /// @details The range for the zoom level is received from camera_attr_get_zoom_range(). If @a zoom is out of range, the #CAMERA_ERROR_INVALID_PARAMETER error occurs. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] zoom The zoom level + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_get_zoom() + /// @see camera_attr_get_zoom_range() + int camera_attr_set_zoom( + ffi.Pointer camera, + int zoom, + ) { + return _camera_attr_set_zoom( + camera, + zoom, + ); + } + + late final _camera_attr_set_zoom_ptr = + _lookup>( + 'camera_attr_set_zoom'); + late final _dart_camera_attr_set_zoom _camera_attr_set_zoom = + _camera_attr_set_zoom_ptr.asFunction<_dart_camera_attr_set_zoom>(); + + /// @brief Gets the zoom level. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] zoom The zoom level + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_zoom() + /// @see camera_attr_get_zoom_range() + int camera_attr_get_zoom( + ffi.Pointer camera, + ffi.Pointer zoom, + ) { + return _camera_attr_get_zoom( + camera, + zoom, + ); + } + + late final _camera_attr_get_zoom_ptr = + _lookup>( + 'camera_attr_get_zoom'); + late final _dart_camera_attr_get_zoom _camera_attr_get_zoom = + _camera_attr_get_zoom_ptr.asFunction<_dart_camera_attr_get_zoom>(); + + /// @brief Gets the available zoom level. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If the min value is greater than the max value, it means that this feature is not supported. + /// @param[in] camera The handle to the camera + /// @param[out] min The minimum zoom level + /// @param[out] max The maximum zoom level + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_zoom() + /// @see camera_attr_get_zoom() + int camera_attr_get_zoom_range( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, + ) { + return _camera_attr_get_zoom_range( + camera, + min, + max, + ); + } + + late final _camera_attr_get_zoom_range_ptr = + _lookup>( + 'camera_attr_get_zoom_range'); + late final _dart_camera_attr_get_zoom_range _camera_attr_get_zoom_range = + _camera_attr_get_zoom_range_ptr + .asFunction<_dart_camera_attr_get_zoom_range>(); + + /// @brief Sets the auto focus mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] mode The auto focus mode + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_get_af_mode() + /// @see camera_attr_foreach_supported_af_mode() + /// @see #camera_attr_af_mode_e + int camera_attr_set_af_mode( + ffi.Pointer camera, + int mode, + ) { + return _camera_attr_set_af_mode( + camera, + mode, + ); + } + + late final _camera_attr_set_af_mode_ptr = + _lookup>( + 'camera_attr_set_af_mode'); + late final _dart_camera_attr_set_af_mode _camera_attr_set_af_mode = + _camera_attr_set_af_mode_ptr.asFunction<_dart_camera_attr_set_af_mode>(); + + /// @brief Gets the auto focus mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] mode The auto focus mode + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_foreach_supported_af_mode() + /// @see camera_attr_set_af_mode() + /// @see #camera_attr_af_mode_e + int camera_attr_get_af_mode( + ffi.Pointer camera, + ffi.Pointer mode, + ) { + return _camera_attr_get_af_mode( + camera, + mode, + ); + } + + late final _camera_attr_get_af_mode_ptr = + _lookup>( + 'camera_attr_get_af_mode'); + late final _dart_camera_attr_get_af_mode _camera_attr_get_af_mode = + _camera_attr_get_af_mode_ptr.asFunction<_dart_camera_attr_get_af_mode>(); + + /// @brief Sets auto focus area. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This API is invalid in the #CAMERA_ATTR_AF_NONE mode.\n + /// The coordinates are mapped to preview area. + /// @param[in] camera The handle to the camera + /// @param[in] x The x coordinates of the focus area + /// @param[in] y The y coordinates of the focus area + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_set_af_mode() + /// @see camera_attr_clear_af_area() + int camera_attr_set_af_area( + ffi.Pointer camera, + int x, + int y, + ) { + return _camera_attr_set_af_area( + camera, + x, + y, + ); + } + + late final _camera_attr_set_af_area_ptr = + _lookup>( + 'camera_attr_set_af_area'); + late final _dart_camera_attr_set_af_area _camera_attr_set_af_area = + _camera_attr_set_af_area_ptr.asFunction<_dart_camera_attr_set_af_area>(); + + /// @brief Clears the auto focus area. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The focusing area is set to the center. + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_af_mode() + /// @see camera_attr_set_af_area() + int camera_attr_clear_af_area( + ffi.Pointer camera, + ) { + return _camera_attr_clear_af_area( + camera, + ); + } + + late final _camera_attr_clear_af_area_ptr = + _lookup>( + 'camera_attr_clear_af_area'); + late final _dart_camera_attr_clear_af_area _camera_attr_clear_af_area = + _camera_attr_clear_af_area_ptr + .asFunction<_dart_camera_attr_clear_af_area>(); + + /// @brief Retrieves all supported auto focus modes by invoking the callback function once for each supported auto focus mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_attr_supported_af_mode_cb() to get all the supported auto focus modes. + /// @see camera_attr_set_af_mode() + /// @see camera_attr_get_af_mode() + /// @see camera_attr_supported_af_mode_cb() + int camera_attr_foreach_supported_af_mode( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_attr_foreach_supported_af_mode( + camera, + callback, + user_data, + ); + } + + late final _camera_attr_foreach_supported_af_mode_ptr = + _lookup>( + 'camera_attr_foreach_supported_af_mode'); + late final _dart_camera_attr_foreach_supported_af_mode + _camera_attr_foreach_supported_af_mode = + _camera_attr_foreach_supported_af_mode_ptr + .asFunction<_dart_camera_attr_foreach_supported_af_mode>(); + + /// @brief Sets the exposure mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] mode The exposure mode + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_get_exposure_mode() + /// @see camera_attr_foreach_supported_exposure_mode() + int camera_attr_set_exposure_mode( + ffi.Pointer camera, + int mode, + ) { + return _camera_attr_set_exposure_mode( + camera, + mode, + ); + } + + late final _camera_attr_set_exposure_mode_ptr = + _lookup>( + 'camera_attr_set_exposure_mode'); + late final _dart_camera_attr_set_exposure_mode + _camera_attr_set_exposure_mode = _camera_attr_set_exposure_mode_ptr + .asFunction<_dart_camera_attr_set_exposure_mode>(); + + /// @brief Gets the exposure mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] mode The exposure mode + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_exposure_mode() + /// @see camera_attr_foreach_supported_exposure_mode() + int camera_attr_get_exposure_mode( + ffi.Pointer camera, + ffi.Pointer mode, + ) { + return _camera_attr_get_exposure_mode( + camera, + mode, + ); + } + + late final _camera_attr_get_exposure_mode_ptr = + _lookup>( + 'camera_attr_get_exposure_mode'); + late final _dart_camera_attr_get_exposure_mode + _camera_attr_get_exposure_mode = _camera_attr_get_exposure_mode_ptr + .asFunction<_dart_camera_attr_get_exposure_mode>(); + + /// @brief Retrieves all supported exposure modes by invoking the callback function once for each supported exposure mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_attr_supported_exposure_mode_cb() to get all the supported exposure modes. + /// @see camera_attr_set_exposure_mode() + /// @see camera_attr_get_exposure_mode() + /// @see camera_attr_supported_exposure_mode_cb() + int camera_attr_foreach_supported_exposure_mode( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _camera_attr_foreach_supported_exposure_mode( + camera, + callback, + user_data, + ); + } + + late final _camera_attr_foreach_supported_exposure_mode_ptr = _lookup< + ffi.NativeFunction<_c_camera_attr_foreach_supported_exposure_mode>>( + 'camera_attr_foreach_supported_exposure_mode'); + late final _dart_camera_attr_foreach_supported_exposure_mode + _camera_attr_foreach_supported_exposure_mode = + _camera_attr_foreach_supported_exposure_mode_ptr + .asFunction<_dart_camera_attr_foreach_supported_exposure_mode>(); + + /// @brief Sets the exposure value. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] value The exposure value + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_get_exposure() + int camera_attr_set_exposure( + ffi.Pointer camera, + int value, + ) { + return _camera_attr_set_exposure( + camera, + value, + ); + } + + late final _camera_attr_set_exposure_ptr = + _lookup>( + 'camera_attr_set_exposure'); + late final _dart_camera_attr_set_exposure _camera_attr_set_exposure = + _camera_attr_set_exposure_ptr + .asFunction<_dart_camera_attr_set_exposure>(); + + /// @brief Gets the exposure value. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] value The exposure value + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_exposure() + int camera_attr_get_exposure( + ffi.Pointer camera, + ffi.Pointer value, + ) { + return _camera_attr_get_exposure( + camera, + value, + ); + } + + late final _camera_attr_get_exposure_ptr = + _lookup>( + 'camera_attr_get_exposure'); + late final _dart_camera_attr_get_exposure _camera_attr_get_exposure = + _camera_attr_get_exposure_ptr + .asFunction<_dart_camera_attr_get_exposure>(); + + /// @brief Gets the available exposure value. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If the min value is greater than the max value, it means that this feature is not supported. + /// @param[in] camera The handle to the camera + /// @param[out] min The minimum exposure value + /// @param[out] max The maximum exposure value + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_exposure() + int camera_attr_get_exposure_range( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, + ) { + return _camera_attr_get_exposure_range( + camera, + min, + max, + ); + } + + late final _camera_attr_get_exposure_range_ptr = + _lookup>( + 'camera_attr_get_exposure_range'); + late final _dart_camera_attr_get_exposure_range + _camera_attr_get_exposure_range = _camera_attr_get_exposure_range_ptr + .asFunction<_dart_camera_attr_get_exposure_range>(); + + /// @brief Sets the ISO level. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] iso The ISO level + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_get_iso() + /// @see camera_attr_foreach_supported_iso() + int camera_attr_set_iso( + ffi.Pointer camera, + int iso, + ) { + return _camera_attr_set_iso( + camera, + iso, + ); + } + + late final _camera_attr_set_iso_ptr = + _lookup>( + 'camera_attr_set_iso'); + late final _dart_camera_attr_set_iso _camera_attr_set_iso = + _camera_attr_set_iso_ptr.asFunction<_dart_camera_attr_set_iso>(); + + /// @brief Gets the ISO level. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] iso The ISO level + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_iso() + /// @see camera_attr_foreach_supported_iso() + int camera_attr_get_iso( + ffi.Pointer camera, + ffi.Pointer iso, + ) { + return _camera_attr_get_iso( + camera, + iso, + ); + } + + late final _camera_attr_get_iso_ptr = + _lookup>( + 'camera_attr_get_iso'); + late final _dart_camera_attr_get_iso _camera_attr_get_iso = + _camera_attr_get_iso_ptr.asFunction<_dart_camera_attr_get_iso>(); + + /// @brief Retrieves all supported ISO levels by invoking the callback function once for each supported ISO level. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_attr_supported_iso_cb() to get all the supported ISO levels. + /// @see camera_attr_set_iso() + /// @see camera_attr_get_iso() + /// @see camera_attr_supported_iso_cb() + int camera_attr_foreach_supported_iso( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_attr_foreach_supported_iso( + camera, + callback, + user_data, + ); + } + + late final _camera_attr_foreach_supported_iso_ptr = + _lookup>( + 'camera_attr_foreach_supported_iso'); + late final _dart_camera_attr_foreach_supported_iso + _camera_attr_foreach_supported_iso = + _camera_attr_foreach_supported_iso_ptr + .asFunction<_dart_camera_attr_foreach_supported_iso>(); + + /// @brief Sets the theater mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If you want to display the preview image on the external display with the full screen mode, use this function. + /// @param[in] camera The handle to the camera + /// @param[in] mode The mode to change + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre This function is valid only when the external display is connected. + /// @see camera_attr_get_theater_mode() + int camera_attr_set_theater_mode( + ffi.Pointer camera, + int mode, + ) { + return _camera_attr_set_theater_mode( + camera, + mode, + ); + } + + late final _camera_attr_set_theater_mode_ptr = + _lookup>( + 'camera_attr_set_theater_mode'); + late final _dart_camera_attr_set_theater_mode _camera_attr_set_theater_mode = + _camera_attr_set_theater_mode_ptr + .asFunction<_dart_camera_attr_set_theater_mode>(); + + /// @brief Gets the theater mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] mode Current theater mode + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_get_theater_mode() + int camera_attr_get_theater_mode( + ffi.Pointer camera, + ffi.Pointer mode, + ) { + return _camera_attr_get_theater_mode( + camera, + mode, + ); + } + + late final _camera_attr_get_theater_mode_ptr = + _lookup>( + 'camera_attr_get_theater_mode'); + late final _dart_camera_attr_get_theater_mode _camera_attr_get_theater_mode = + _camera_attr_get_theater_mode_ptr + .asFunction<_dart_camera_attr_get_theater_mode>(); + + /// @brief Retrieves all supported theater modes by invoking callback function once for each supported theater modes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_attr_supported_theater_mode_cb() to get all supported theater modes. + /// @see camera_attr_set_theater_mode() + /// @see camera_attr_get_theater_mode() + /// @see camera_attr_supported_theater_mode_cb() + int camera_attr_foreach_supported_theater_mode( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _camera_attr_foreach_supported_theater_mode( + camera, + callback, + user_data, + ); + } + + late final _camera_attr_foreach_supported_theater_mode_ptr = _lookup< + ffi.NativeFunction<_c_camera_attr_foreach_supported_theater_mode>>( + 'camera_attr_foreach_supported_theater_mode'); + late final _dart_camera_attr_foreach_supported_theater_mode + _camera_attr_foreach_supported_theater_mode = + _camera_attr_foreach_supported_theater_mode_ptr + .asFunction<_dart_camera_attr_foreach_supported_theater_mode>(); + + /// @brief Sets the brightness level. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If the min value is greater than the max value from camera_attr_get_brightness_range(), \n + /// it means that this feature is not supported. + /// @param[in] camera The handle to the camera + /// @param[in] level The brightness level + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_get_brightness() + /// @see camera_attr_get_brightness_range() + int camera_attr_set_brightness( + ffi.Pointer camera, + int level, + ) { + return _camera_attr_set_brightness( + camera, + level, + ); + } + + late final _camera_attr_set_brightness_ptr = + _lookup>( + 'camera_attr_set_brightness'); + late final _dart_camera_attr_set_brightness _camera_attr_set_brightness = + _camera_attr_set_brightness_ptr + .asFunction<_dart_camera_attr_set_brightness>(); + + /// @brief Gets the brightness level. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] level The brightness level + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_brightness() + /// @see camera_attr_get_brightness_range() + int camera_attr_get_brightness( + ffi.Pointer camera, + ffi.Pointer level, + ) { + return _camera_attr_get_brightness( + camera, + level, + ); + } + + late final _camera_attr_get_brightness_ptr = + _lookup>( + 'camera_attr_get_brightness'); + late final _dart_camera_attr_get_brightness _camera_attr_get_brightness = + _camera_attr_get_brightness_ptr + .asFunction<_dart_camera_attr_get_brightness>(); + + /// @brief Gets the available brightness level. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If the min value is greater than the max value, it means that this feature is not supported. + /// @param[in] camera The handle to the camera + /// @param[out] min The minimum brightness level + /// @param[out] max The maximum brightness level + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_brightness() + /// @see camera_attr_get_brightness() + int camera_attr_get_brightness_range( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, + ) { + return _camera_attr_get_brightness_range( + camera, + min, + max, + ); + } + + late final _camera_attr_get_brightness_range_ptr = + _lookup>( + 'camera_attr_get_brightness_range'); + late final _dart_camera_attr_get_brightness_range + _camera_attr_get_brightness_range = _camera_attr_get_brightness_range_ptr + .asFunction<_dart_camera_attr_get_brightness_range>(); + + /// @brief Sets the contrast level. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] level The contrast level + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_get_contrast() + /// @see camera_attr_get_contrast_range() + int camera_attr_set_contrast( + ffi.Pointer camera, + int level, + ) { + return _camera_attr_set_contrast( + camera, + level, + ); + } + + late final _camera_attr_set_contrast_ptr = + _lookup>( + 'camera_attr_set_contrast'); + late final _dart_camera_attr_set_contrast _camera_attr_set_contrast = + _camera_attr_set_contrast_ptr + .asFunction<_dart_camera_attr_set_contrast>(); + + /// @brief Gets the contrast level. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] level The contrast level + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_contrast() + /// @see camera_attr_get_contrast_range() + int camera_attr_get_contrast( + ffi.Pointer camera, + ffi.Pointer level, + ) { + return _camera_attr_get_contrast( + camera, + level, + ); + } + + late final _camera_attr_get_contrast_ptr = + _lookup>( + 'camera_attr_get_contrast'); + late final _dart_camera_attr_get_contrast _camera_attr_get_contrast = + _camera_attr_get_contrast_ptr + .asFunction<_dart_camera_attr_get_contrast>(); + + /// @brief Gets the available contrast level. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If the min value is greater than the max value, it means that this feature is not supported. + /// @param[in] camera The handle to the camera + /// @param[out] min The minimum contrast level + /// @param[out] max The maximum contrast level + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_contrast() + /// @see camera_attr_get_contrast() + int camera_attr_get_contrast_range( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, + ) { + return _camera_attr_get_contrast_range( + camera, + min, + max, + ); + } + + late final _camera_attr_get_contrast_range_ptr = + _lookup>( + 'camera_attr_get_contrast_range'); + late final _dart_camera_attr_get_contrast_range + _camera_attr_get_contrast_range = _camera_attr_get_contrast_range_ptr + .asFunction<_dart_camera_attr_get_contrast_range>(); + + /// @brief Sets the hue level. + /// @since_tizen 4.0 + /// @param[in] camera The handle to the camera + /// @param[in] level The hue level + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @see camera_attr_get_hue() + /// @see camera_attr_get_hue_range() + int camera_attr_set_hue( + ffi.Pointer camera, + int level, + ) { + return _camera_attr_set_hue( + camera, + level, + ); + } + + late final _camera_attr_set_hue_ptr = + _lookup>( + 'camera_attr_set_hue'); + late final _dart_camera_attr_set_hue _camera_attr_set_hue = + _camera_attr_set_hue_ptr.asFunction<_dart_camera_attr_set_hue>(); + + /// @brief Gets the hue level. + /// @since_tizen 4.0 + /// @param[in] camera The handle to the camera + /// @param[out] level The hue level + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @see camera_attr_set_hue() + /// @see camera_attr_get_hue_range() + int camera_attr_get_hue( + ffi.Pointer camera, + ffi.Pointer level, + ) { + return _camera_attr_get_hue( + camera, + level, + ); + } + + late final _camera_attr_get_hue_ptr = + _lookup>( + 'camera_attr_get_hue'); + late final _dart_camera_attr_get_hue _camera_attr_get_hue = + _camera_attr_get_hue_ptr.asFunction<_dart_camera_attr_get_hue>(); + + /// @brief Gets the available hue level. + /// @since_tizen 4.0 + /// @remarks If the min value is greater than the max value, it means that this feature is not supported. + /// @param[in] camera The handle to the camera + /// @param[out] min The minimum hue level + /// @param[out] max The maximum hue level + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @see camera_attr_set_hue() + /// @see camera_attr_get_hue() + int camera_attr_get_hue_range( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, + ) { + return _camera_attr_get_hue_range( + camera, + min, + max, + ); + } + + late final _camera_attr_get_hue_range_ptr = + _lookup>( + 'camera_attr_get_hue_range'); + late final _dart_camera_attr_get_hue_range _camera_attr_get_hue_range = + _camera_attr_get_hue_range_ptr + .asFunction<_dart_camera_attr_get_hue_range>(); + + /// @brief Sets the white balance mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] whitebalance The white balance mode + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_foreach_supported_whitebalance() + /// @see camera_attr_get_whitebalance() + int camera_attr_set_whitebalance( + ffi.Pointer camera, + int whitebalance, + ) { + return _camera_attr_set_whitebalance( + camera, + whitebalance, + ); + } + + late final _camera_attr_set_whitebalance_ptr = + _lookup>( + 'camera_attr_set_whitebalance'); + late final _dart_camera_attr_set_whitebalance _camera_attr_set_whitebalance = + _camera_attr_set_whitebalance_ptr + .asFunction<_dart_camera_attr_set_whitebalance>(); + + /// @brief Gets the white balance mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] whitebalance The white balance mode + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_foreach_supported_whitebalance() + /// @see camera_attr_set_whitebalance() + int camera_attr_get_whitebalance( + ffi.Pointer camera, + ffi.Pointer whitebalance, + ) { + return _camera_attr_get_whitebalance( + camera, + whitebalance, + ); + } + + late final _camera_attr_get_whitebalance_ptr = + _lookup>( + 'camera_attr_get_whitebalance'); + late final _dart_camera_attr_get_whitebalance _camera_attr_get_whitebalance = + _camera_attr_get_whitebalance_ptr + .asFunction<_dart_camera_attr_get_whitebalance>(); + + /// @brief Retrieves all supported white balances by invoking the callback function once for each supported white balance. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_attr_supported_whitebalance_cb() to get all the supported white balances. + /// @see camera_attr_set_whitebalance() + /// @see camera_attr_get_whitebalance() + /// @see camera_attr_supported_whitebalance_cb() + int camera_attr_foreach_supported_whitebalance( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _camera_attr_foreach_supported_whitebalance( + camera, + callback, + user_data, + ); + } + + late final _camera_attr_foreach_supported_whitebalance_ptr = _lookup< + ffi.NativeFunction<_c_camera_attr_foreach_supported_whitebalance>>( + 'camera_attr_foreach_supported_whitebalance'); + late final _dart_camera_attr_foreach_supported_whitebalance + _camera_attr_foreach_supported_whitebalance = + _camera_attr_foreach_supported_whitebalance_ptr + .asFunction<_dart_camera_attr_foreach_supported_whitebalance>(); + + /// @brief Sets the camera effect mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] effect The camera effect mode + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_foreach_supported_effect() + /// @see camera_attr_get_effect() + int camera_attr_set_effect( + ffi.Pointer camera, + int effect, + ) { + return _camera_attr_set_effect( + camera, + effect, + ); + } + + late final _camera_attr_set_effect_ptr = + _lookup>( + 'camera_attr_set_effect'); + late final _dart_camera_attr_set_effect _camera_attr_set_effect = + _camera_attr_set_effect_ptr.asFunction<_dart_camera_attr_set_effect>(); + + /// @brief Gets the camera effect mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] effect The camera effect mode + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_foreach_supported_effect() + /// @see camera_attr_set_effect() + int camera_attr_get_effect( + ffi.Pointer camera, + ffi.Pointer effect, + ) { + return _camera_attr_get_effect( + camera, + effect, + ); + } + + late final _camera_attr_get_effect_ptr = + _lookup>( + 'camera_attr_get_effect'); + late final _dart_camera_attr_get_effect _camera_attr_get_effect = + _camera_attr_get_effect_ptr.asFunction<_dart_camera_attr_get_effect>(); + + /// @brief Retrieves all supported effect modes by invoking the callback function once for each supported effect mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_attr_supported_effect_cb() to get all the supported effect modes. + /// @see camera_attr_set_effect() + /// @see camera_attr_get_effect() + /// @see camera_attr_supported_effect_cb() + int camera_attr_foreach_supported_effect( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_attr_foreach_supported_effect( + camera, + callback, + user_data, + ); + } + + late final _camera_attr_foreach_supported_effect_ptr = + _lookup>( + 'camera_attr_foreach_supported_effect'); + late final _dart_camera_attr_foreach_supported_effect + _camera_attr_foreach_supported_effect = + _camera_attr_foreach_supported_effect_ptr + .asFunction<_dart_camera_attr_foreach_supported_effect>(); + + /// @brief Sets the scene mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] mode The scene mode + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_foreach_supported_scene_mode() + /// @see camera_attr_get_scene_mode() + int camera_attr_set_scene_mode( + ffi.Pointer camera, + int mode, + ) { + return _camera_attr_set_scene_mode( + camera, + mode, + ); + } + + late final _camera_attr_set_scene_mode_ptr = + _lookup>( + 'camera_attr_set_scene_mode'); + late final _dart_camera_attr_set_scene_mode _camera_attr_set_scene_mode = + _camera_attr_set_scene_mode_ptr + .asFunction<_dart_camera_attr_set_scene_mode>(); + + /// @brief Gets the scene mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] mode The scene mode + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_foreach_supported_scene_mode() + /// @see camera_attr_set_scene_mode() + int camera_attr_get_scene_mode( + ffi.Pointer camera, + ffi.Pointer mode, + ) { + return _camera_attr_get_scene_mode( + camera, + mode, + ); + } + + late final _camera_attr_get_scene_mode_ptr = + _lookup>( + 'camera_attr_get_scene_mode'); + late final _dart_camera_attr_get_scene_mode _camera_attr_get_scene_mode = + _camera_attr_get_scene_mode_ptr + .asFunction<_dart_camera_attr_get_scene_mode>(); + + /// @brief Retrieves all supported scene modes by invoking the callback function once for each supported scene mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_attr_supported_scene_mode_cb() to get all the supported scene modes. + /// @see camera_attr_set_scene_mode() + /// @see camera_attr_get_scene_mode() + /// @see camera_attr_supported_scene_mode_cb() + int camera_attr_foreach_supported_scene_mode( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _camera_attr_foreach_supported_scene_mode( + camera, + callback, + user_data, + ); + } + + late final _camera_attr_foreach_supported_scene_mode_ptr = + _lookup>( + 'camera_attr_foreach_supported_scene_mode'); + late final _dart_camera_attr_foreach_supported_scene_mode + _camera_attr_foreach_supported_scene_mode = + _camera_attr_foreach_supported_scene_mode_ptr + .asFunction<_dart_camera_attr_foreach_supported_scene_mode>(); + + /// @brief Enables to write EXIF(Exchangeable image file format) tags in a JPEG file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] enable If @c true writing EXIF tags in a JPEG file is enabled, otherwise @c false + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_is_enabled_tag() + int camera_attr_enable_tag( + ffi.Pointer camera, + bool enable, + ) { + return _camera_attr_enable_tag( + camera, + enable ? 1 : 0, + ); + } + + late final _camera_attr_enable_tag_ptr = + _lookup>( + 'camera_attr_enable_tag'); + late final _dart_camera_attr_enable_tag _camera_attr_enable_tag = + _camera_attr_enable_tag_ptr.asFunction<_dart_camera_attr_enable_tag>(); + + /// @brief Gets the value that indicates whether writing EXIF(Exchangeable image file format) tags in a JPEG file is enabled. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] enabled If @c true camera information is enabled, otherwise @c false + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_enable_tag() + int camera_attr_is_enabled_tag( + ffi.Pointer camera, + ffi.Pointer enabled, + ) { + return _camera_attr_is_enabled_tag( + camera, + enabled, + ); + } + + late final _camera_attr_is_enabled_tag_ptr = + _lookup>( + 'camera_attr_is_enabled_tag'); + late final _dart_camera_attr_is_enabled_tag _camera_attr_is_enabled_tag = + _camera_attr_is_enabled_tag_ptr + .asFunction<_dart_camera_attr_is_enabled_tag>(); + + /// @brief Sets the camera image description in the EXIF(Exchangeable image file format) tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] description The string with description + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_get_tag_image_description() + int camera_attr_set_tag_image_description( + ffi.Pointer camera, + ffi.Pointer description, + ) { + return _camera_attr_set_tag_image_description( + camera, + description, + ); + } + + late final _camera_attr_set_tag_image_description_ptr = + _lookup>( + 'camera_attr_set_tag_image_description'); + late final _dart_camera_attr_set_tag_image_description + _camera_attr_set_tag_image_description = + _camera_attr_set_tag_image_description_ptr + .asFunction<_dart_camera_attr_set_tag_image_description>(); + + /// @brief Gets the camera image description in EXIF(Exchangeable image file format) tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a description using free(). + /// @param[in] camera The handle to the camera + /// @param[out] description A pointer to a string + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_tag_image_description() + int camera_attr_get_tag_image_description( + ffi.Pointer camera, + ffi.Pointer> description, + ) { + return _camera_attr_get_tag_image_description( + camera, + description, + ); + } + + late final _camera_attr_get_tag_image_description_ptr = + _lookup>( + 'camera_attr_get_tag_image_description'); + late final _dart_camera_attr_get_tag_image_description + _camera_attr_get_tag_image_description = + _camera_attr_get_tag_image_description_ptr + .asFunction<_dart_camera_attr_get_tag_image_description>(); + + /// @brief Sets the camera orientation in the EXIF(Exchangeable image file format) tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] orientation The camera orientation + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_get_tag_orientation() + int camera_attr_set_tag_orientation( + ffi.Pointer camera, + int orientation, + ) { + return _camera_attr_set_tag_orientation( + camera, + orientation, + ); + } + + late final _camera_attr_set_tag_orientation_ptr = + _lookup>( + 'camera_attr_set_tag_orientation'); + late final _dart_camera_attr_set_tag_orientation + _camera_attr_set_tag_orientation = _camera_attr_set_tag_orientation_ptr + .asFunction<_dart_camera_attr_set_tag_orientation>(); + + /// @brief Gets the camera orientation in the EXIF(Exchangeable image file format) tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] orientation The camera orientation + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_tag_orientation() + int camera_attr_get_tag_orientation( + ffi.Pointer camera, + ffi.Pointer orientation, + ) { + return _camera_attr_get_tag_orientation( + camera, + orientation, + ); + } + + late final _camera_attr_get_tag_orientation_ptr = + _lookup>( + 'camera_attr_get_tag_orientation'); + late final _dart_camera_attr_get_tag_orientation + _camera_attr_get_tag_orientation = _camera_attr_get_tag_orientation_ptr + .asFunction<_dart_camera_attr_get_tag_orientation>(); + + /// @brief Sets the software information in the EXIF(Exchangeable image file format) tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] software The software information tag + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_get_tag_software() + int camera_attr_set_tag_software( + ffi.Pointer camera, + ffi.Pointer software, + ) { + return _camera_attr_set_tag_software( + camera, + software, + ); + } + + late final _camera_attr_set_tag_software_ptr = + _lookup>( + 'camera_attr_set_tag_software'); + late final _dart_camera_attr_set_tag_software _camera_attr_set_tag_software = + _camera_attr_set_tag_software_ptr + .asFunction<_dart_camera_attr_set_tag_software>(); + + /// @brief Gets the software information in the EXIF(Exchangeable image file format) tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a software using free(). + /// @param[in] camera The handle to the camera + /// @param[out] software A pointer to a string + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_tag_software() + int camera_attr_get_tag_software( + ffi.Pointer camera, + ffi.Pointer> software, + ) { + return _camera_attr_get_tag_software( + camera, + software, + ); + } + + late final _camera_attr_get_tag_software_ptr = + _lookup>( + 'camera_attr_get_tag_software'); + late final _dart_camera_attr_get_tag_software _camera_attr_get_tag_software = + _camera_attr_get_tag_software_ptr + .asFunction<_dart_camera_attr_get_tag_software>(); + + /// @brief Sets the geotag(GPS data) in the EXIF(Exchangeable image file format) tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] latitude The latitude data + /// @param[in] longitude The longitude data + /// @param[in] altitude The altitude data + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_get_geotag() + /// @see camera_attr_remove_geotag() + int camera_attr_set_geotag( + ffi.Pointer camera, + double latitude, + double longitude, + double altitude, + ) { + return _camera_attr_set_geotag( + camera, + latitude, + longitude, + altitude, + ); + } + + late final _camera_attr_set_geotag_ptr = + _lookup>( + 'camera_attr_set_geotag'); + late final _dart_camera_attr_set_geotag _camera_attr_set_geotag = + _camera_attr_set_geotag_ptr.asFunction<_dart_camera_attr_set_geotag>(); + + /// @brief Gets the geotag(GPS data) in the EXIF(Exchangeable image file format) tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] latitude The latitude data + /// @param[out] longitude The longitude data + /// @param[out] altitude The altitude data + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_geotag() + /// @see camera_attr_remove_geotag() + int camera_attr_get_geotag( + ffi.Pointer camera, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer altitude, + ) { + return _camera_attr_get_geotag( + camera, + latitude, + longitude, + altitude, + ); + } + + late final _camera_attr_get_geotag_ptr = + _lookup>( + 'camera_attr_get_geotag'); + late final _dart_camera_attr_get_geotag _camera_attr_get_geotag = + _camera_attr_get_geotag_ptr.asFunction<_dart_camera_attr_get_geotag>(); + + /// @brief Removes the geotag(GPS data) in the EXIF(Exchangeable image file format) tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_set_geotag() + /// @see camera_attr_get_geotag() + int camera_attr_remove_geotag( + ffi.Pointer camera, + ) { + return _camera_attr_remove_geotag( + camera, + ); + } + + late final _camera_attr_remove_geotag_ptr = + _lookup>( + 'camera_attr_remove_geotag'); + late final _dart_camera_attr_remove_geotag _camera_attr_remove_geotag = + _camera_attr_remove_geotag_ptr + .asFunction<_dart_camera_attr_remove_geotag>(); + + /// @brief Sets the camera's flash mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif, while setting the flash mode, if the flash was preempted by other APIs,\n + /// then this function returns #CAMERA_ERROR_DEVICE_BUSY error. + /// @param[in] camera The handle to the camera + /// @param[in] mode The flash mode + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @retval #CAMERA_ERROR_DEVICE_BUSY The flash was preempted by other API + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_foreach_supported_flash_mode() + /// @see camera_attr_get_flash_mode() + int camera_attr_set_flash_mode( + ffi.Pointer camera, + int mode, + ) { + return _camera_attr_set_flash_mode( + camera, + mode, + ); + } + + late final _camera_attr_set_flash_mode_ptr = + _lookup>( + 'camera_attr_set_flash_mode'); + late final _dart_camera_attr_set_flash_mode _camera_attr_set_flash_mode = + _camera_attr_set_flash_mode_ptr + .asFunction<_dart_camera_attr_set_flash_mode>(); + + /// @brief Gets the camera's flash mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] mode The flash mode + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_foreach_supported_flash_mode() + /// @see camera_attr_set_flash_mode() + int camera_attr_get_flash_mode( + ffi.Pointer camera, + ffi.Pointer mode, + ) { + return _camera_attr_get_flash_mode( + camera, + mode, + ); + } + + late final _camera_attr_get_flash_mode_ptr = + _lookup>( + 'camera_attr_get_flash_mode'); + late final _dart_camera_attr_get_flash_mode _camera_attr_get_flash_mode = + _camera_attr_get_flash_mode_ptr + .asFunction<_dart_camera_attr_get_flash_mode>(); + + /// @brief Retrieves all supported flash modes by invoking the callback function once for each supported flash mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data passed to the callback registration function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_attr_supported_flash_mode_cb() to get all supported flash modes. + /// @see camera_attr_set_flash_mode() + /// @see camera_attr_get_flash_mode() + /// @see camera_attr_supported_flash_mode_cb() + int camera_attr_foreach_supported_flash_mode( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _camera_attr_foreach_supported_flash_mode( + camera, + callback, + user_data, + ); + } + + late final _camera_attr_foreach_supported_flash_mode_ptr = + _lookup>( + 'camera_attr_foreach_supported_flash_mode'); + late final _dart_camera_attr_foreach_supported_flash_mode + _camera_attr_foreach_supported_flash_mode = + _camera_attr_foreach_supported_flash_mode_ptr + .asFunction<_dart_camera_attr_foreach_supported_flash_mode>(); + + /// @brief Gets the camera len's orientation angle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] angle The orientation angle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_set_display_rotation() + int camera_attr_get_lens_orientation( + ffi.Pointer camera, + ffi.Pointer angle, + ) { + return _camera_attr_get_lens_orientation( + camera, + angle, + ); + } + + late final _camera_attr_get_lens_orientation_ptr = + _lookup>( + 'camera_attr_get_lens_orientation'); + late final _dart_camera_attr_get_lens_orientation + _camera_attr_get_lens_orientation = _camera_attr_get_lens_orientation_ptr + .asFunction<_dart_camera_attr_get_lens_orientation>(); + + /// @brief Sets the stream rotation. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] rotation The stream rotation + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED. + /// @see camera_attr_get_stream_rotation() + int camera_attr_set_stream_rotation( + ffi.Pointer camera, + int rotation, + ) { + return _camera_attr_set_stream_rotation( + camera, + rotation, + ); + } + + late final _camera_attr_set_stream_rotation_ptr = + _lookup>( + 'camera_attr_set_stream_rotation'); + late final _dart_camera_attr_set_stream_rotation + _camera_attr_set_stream_rotation = _camera_attr_set_stream_rotation_ptr + .asFunction<_dart_camera_attr_set_stream_rotation>(); + + /// @brief Gets the stream rotation. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] rotation The stream rotation + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED. + /// @see camera_attr_set_stream_rotation() + int camera_attr_get_stream_rotation( + ffi.Pointer camera, + ffi.Pointer rotation, + ) { + return _camera_attr_get_stream_rotation( + camera, + rotation, + ); + } + + late final _camera_attr_get_stream_rotation_ptr = + _lookup>( + 'camera_attr_get_stream_rotation'); + late final _dart_camera_attr_get_stream_rotation + _camera_attr_get_stream_rotation = _camera_attr_get_stream_rotation_ptr + .asFunction<_dart_camera_attr_get_stream_rotation>(); + + /// @brief Retrieves all supported stream rotation modes by invoking callback function once for each supported stream rotation mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_attr_supported_stream_rotation_cb() to get all supported stream rotation mode. + /// @see camera_attr_set_stream_rotation() + /// @see camera_attr_get_stream_rotation() + /// @see camera_attr_supported_stream_rotation_cb() + int camera_attr_foreach_supported_stream_rotation( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _camera_attr_foreach_supported_stream_rotation( + camera, + callback, + user_data, + ); + } + + late final _camera_attr_foreach_supported_stream_rotation_ptr = _lookup< + ffi.NativeFunction<_c_camera_attr_foreach_supported_stream_rotation>>( + 'camera_attr_foreach_supported_stream_rotation'); + late final _dart_camera_attr_foreach_supported_stream_rotation + _camera_attr_foreach_supported_stream_rotation = + _camera_attr_foreach_supported_stream_rotation_ptr + .asFunction<_dart_camera_attr_foreach_supported_stream_rotation>(); + + /// @brief Sets the stream flip. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] flip The stream flip + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED. + /// @see camera_attr_set_stream_rotation() + int camera_attr_set_stream_flip( + ffi.Pointer camera, + int flip, + ) { + return _camera_attr_set_stream_flip( + camera, + flip, + ); + } + + late final _camera_attr_set_stream_flip_ptr = + _lookup>( + 'camera_attr_set_stream_flip'); + late final _dart_camera_attr_set_stream_flip _camera_attr_set_stream_flip = + _camera_attr_set_stream_flip_ptr + .asFunction<_dart_camera_attr_set_stream_flip>(); + + /// @brief Gets the stream flip. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] flip The stream flip + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED. + /// @see camera_attr_set_stream_rotation() + int camera_attr_get_stream_flip( + ffi.Pointer camera, + ffi.Pointer flip, + ) { + return _camera_attr_get_stream_flip( + camera, + flip, + ); + } + + late final _camera_attr_get_stream_flip_ptr = + _lookup>( + 'camera_attr_get_stream_flip'); + late final _dart_camera_attr_get_stream_flip _camera_attr_get_stream_flip = + _camera_attr_get_stream_flip_ptr + .asFunction<_dart_camera_attr_get_stream_flip>(); + + /// @brief Retrieves all supported stream flip modes by invoking callback function once for each supported stream flip mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_attr_supported_stream_flip_cb() to get all supported stream flip mode. + /// @see camera_attr_set_stream_flip() + /// @see camera_attr_get_stream_flip() + /// @see camera_attr_supported_stream_flip_cb() + int camera_attr_foreach_supported_stream_flip( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _camera_attr_foreach_supported_stream_flip( + camera, + callback, + user_data, + ); + } + + late final _camera_attr_foreach_supported_stream_flip_ptr = + _lookup>( + 'camera_attr_foreach_supported_stream_flip'); + late final _dart_camera_attr_foreach_supported_stream_flip + _camera_attr_foreach_supported_stream_flip = + _camera_attr_foreach_supported_stream_flip_ptr + .asFunction<_dart_camera_attr_foreach_supported_stream_flip>(); + + /// @brief Sets the mode of HDR(High dynamic range) capture. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks Taking multiple pictures at different exposure levels and intelligently stitching them together so that we eventually arrive at a picture that is representative in both dark and bright areas.\n + /// If this attribute is set to @c true. camera_attr_hdr_progress_cb() is invoked during capture.\n + /// If you set #CAMERA_ATTR_HDR_MODE_KEEP_ORIGINAL, the capturing callback is invoked twice. The first callback is delivering origin image data. The second callback is delivering improved image data. + /// @param[in] camera The handle to the camera + /// @param[in] mode The mode of HDR capture + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_get_hdr_mode() + /// @see camera_attr_set_hdr_capture_progress_cb() + /// @see camera_attr_unset_hdr_capture_progress_cb() + /// @see camera_attr_is_supported_hdr_capture() + int camera_attr_set_hdr_mode( + ffi.Pointer camera, + int mode, + ) { + return _camera_attr_set_hdr_mode( + camera, + mode, + ); + } + + late final _camera_attr_set_hdr_mode_ptr = + _lookup>( + 'camera_attr_set_hdr_mode'); + late final _dart_camera_attr_set_hdr_mode _camera_attr_set_hdr_mode = + _camera_attr_set_hdr_mode_ptr + .asFunction<_dart_camera_attr_set_hdr_mode>(); + + /// @brief Gets the mode of HDR(High dynamic range) capture. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] mode The mode of HDR capture + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_hdr_mode() + /// @see camera_attr_set_hdr_capture_progress_cb() + /// @see camera_attr_unset_hdr_capture_progress_cb() + /// @see camera_attr_is_supported_hdr_capture() + int camera_attr_get_hdr_mode( + ffi.Pointer camera, + ffi.Pointer mode, + ) { + return _camera_attr_get_hdr_mode( + camera, + mode, + ); + } + + late final _camera_attr_get_hdr_mode_ptr = + _lookup>( + 'camera_attr_get_hdr_mode'); + late final _dart_camera_attr_get_hdr_mode _camera_attr_get_hdr_mode = + _camera_attr_get_hdr_mode_ptr + .asFunction<_dart_camera_attr_get_hdr_mode>(); + + /// @brief Registers a callback function to be called when HDR capture is progressing. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This callback notifies progress of the HDR process. + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data passed to the callback registration function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_hdr_mode() + /// @see camera_attr_get_hdr_mode() + /// @see camera_attr_unset_hdr_capture_progress_cb() + /// @see camera_attr_is_supported_hdr_capture() + int camera_attr_set_hdr_capture_progress_cb( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_attr_set_hdr_capture_progress_cb( + camera, + callback, + user_data, + ); + } + + late final _camera_attr_set_hdr_capture_progress_cb_ptr = + _lookup>( + 'camera_attr_set_hdr_capture_progress_cb'); + late final _dart_camera_attr_set_hdr_capture_progress_cb + _camera_attr_set_hdr_capture_progress_cb = + _camera_attr_set_hdr_capture_progress_cb_ptr + .asFunction<_dart_camera_attr_set_hdr_capture_progress_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_hdr_mode() + /// @see camera_attr_get_hdr_mode() + /// @see camera_attr_set_hdr_capture_progress_cb() + /// @see camera_attr_is_supported_hdr_capture() + int camera_attr_unset_hdr_capture_progress_cb( + ffi.Pointer camera, + ) { + return _camera_attr_unset_hdr_capture_progress_cb( + camera, + ); + } + + late final _camera_attr_unset_hdr_capture_progress_cb_ptr = + _lookup>( + 'camera_attr_unset_hdr_capture_progress_cb'); + late final _dart_camera_attr_unset_hdr_capture_progress_cb + _camera_attr_unset_hdr_capture_progress_cb = + _camera_attr_unset_hdr_capture_progress_cb_ptr + .asFunction<_dart_camera_attr_unset_hdr_capture_progress_cb>(); + + /// @ingroup CAPI_MEDIA_CAMERA_CAPABILITY_MODULE + /// @brief Gets the support state of HDR capture. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] camera The handle to the camera + /// @return @c true if supported, otherwise @c false + /// @exception #CAMERA_ERROR_NONE Successful + /// @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @see camera_attr_set_hdr_mode() + /// @see camera_attr_get_hdr_mode() + /// @see camera_attr_set_hdr_capture_progress_cb() + /// @see camera_attr_unset_hdr_capture_progress_cb() + bool camera_attr_is_supported_hdr_capture( + ffi.Pointer camera, + ) { + return _camera_attr_is_supported_hdr_capture( + camera, + ) != + 0; + } + + late final _camera_attr_is_supported_hdr_capture_ptr = + _lookup>( + 'camera_attr_is_supported_hdr_capture'); + late final _dart_camera_attr_is_supported_hdr_capture + _camera_attr_is_supported_hdr_capture = + _camera_attr_is_supported_hdr_capture_ptr + .asFunction<_dart_camera_attr_is_supported_hdr_capture>(); + + /// @brief Enables/Disables the anti-shake feature. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This feature is used for image capture. + /// @param[in] camera The handle to the camera + /// @param[in] enable If @c true the anti-shake feature is enabled, otherwise @c false + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_is_enabled_anti_shake() + /// @see camera_attr_is_supported_anti_shake() + int camera_attr_enable_anti_shake( + ffi.Pointer camera, + bool enable, + ) { + return _camera_attr_enable_anti_shake( + camera, + enable ? 1 : 0, + ); + } + + late final _camera_attr_enable_anti_shake_ptr = + _lookup>( + 'camera_attr_enable_anti_shake'); + late final _dart_camera_attr_enable_anti_shake + _camera_attr_enable_anti_shake = _camera_attr_enable_anti_shake_ptr + .asFunction<_dart_camera_attr_enable_anti_shake>(); + + /// @brief Gets the state of the anti-shake feature. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] enabled The state of anti-shake + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_enable_anti_shake() + /// @see camera_attr_is_supported_anti_shake() + int camera_attr_is_enabled_anti_shake( + ffi.Pointer camera, + ffi.Pointer enabled, + ) { + return _camera_attr_is_enabled_anti_shake( + camera, + enabled, + ); + } + + late final _camera_attr_is_enabled_anti_shake_ptr = + _lookup>( + 'camera_attr_is_enabled_anti_shake'); + late final _dart_camera_attr_is_enabled_anti_shake + _camera_attr_is_enabled_anti_shake = + _camera_attr_is_enabled_anti_shake_ptr + .asFunction<_dart_camera_attr_is_enabled_anti_shake>(); + + /// @ingroup CAPI_MEDIA_CAMERA_CAPABILITY_MODULE + /// @brief Gets the support state of the anti-shake feature. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] camera The handle to the camera + /// @return @c true if supported, otherwise @c false + /// @exception #CAMERA_ERROR_NONE Successful + /// @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @see camera_attr_enable_anti_shake() + /// @see camera_attr_is_enabled_anti_shake() + bool camera_attr_is_supported_anti_shake( + ffi.Pointer camera, + ) { + return _camera_attr_is_supported_anti_shake( + camera, + ) != + 0; + } + + late final _camera_attr_is_supported_anti_shake_ptr = + _lookup>( + 'camera_attr_is_supported_anti_shake'); + late final _dart_camera_attr_is_supported_anti_shake + _camera_attr_is_supported_anti_shake = + _camera_attr_is_supported_anti_shake_ptr + .asFunction<_dart_camera_attr_is_supported_anti_shake>(); + + /// @brief Enables/Disables the video stabilization feature. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If video stabilization is enabled, zero shutter lag is disabled.\n + /// This feature is used to record a video. + /// @param[in] camera The handle to the camera + /// @param[in] enable If @c true video stabilization is enabled, otherwise @c false + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_is_enabled_video_stabilization() + /// @see camera_attr_is_supported_video_stabilization() + int camera_attr_enable_video_stabilization( + ffi.Pointer camera, + bool enable, + ) { + return _camera_attr_enable_video_stabilization( + camera, + enable ? 1 : 0, + ); + } + + late final _camera_attr_enable_video_stabilization_ptr = + _lookup>( + 'camera_attr_enable_video_stabilization'); + late final _dart_camera_attr_enable_video_stabilization + _camera_attr_enable_video_stabilization = + _camera_attr_enable_video_stabilization_ptr + .asFunction<_dart_camera_attr_enable_video_stabilization>(); + + /// @brief Gets the state of the video stabilization feature. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] enabled The state of video stabilization + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_enable_video_stabilization() + /// @see camera_attr_is_supported_video_stabilization() + int camera_attr_is_enabled_video_stabilization( + ffi.Pointer camera, + ffi.Pointer enabled, + ) { + return _camera_attr_is_enabled_video_stabilization( + camera, + enabled, + ); + } + + late final _camera_attr_is_enabled_video_stabilization_ptr = _lookup< + ffi.NativeFunction<_c_camera_attr_is_enabled_video_stabilization>>( + 'camera_attr_is_enabled_video_stabilization'); + late final _dart_camera_attr_is_enabled_video_stabilization + _camera_attr_is_enabled_video_stabilization = + _camera_attr_is_enabled_video_stabilization_ptr + .asFunction<_dart_camera_attr_is_enabled_video_stabilization>(); + + /// @ingroup CAPI_MEDIA_CAMERA_CAPABILITY_MODULE + /// @brief Gets the support state of the video stabilization feature. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] camera The handle to the camera + /// @return @c true if supported, otherwise @c false + /// @exception #CAMERA_ERROR_NONE Successful + /// @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @see camera_attr_enable_video_stabilization() + /// @see camera_attr_is_enabled_video_stabilization() + bool camera_attr_is_supported_video_stabilization( + ffi.Pointer camera, + ) { + return _camera_attr_is_supported_video_stabilization( + camera, + ) != + 0; + } + + late final _camera_attr_is_supported_video_stabilization_ptr = _lookup< + ffi.NativeFunction<_c_camera_attr_is_supported_video_stabilization>>( + 'camera_attr_is_supported_video_stabilization'); + late final _dart_camera_attr_is_supported_video_stabilization + _camera_attr_is_supported_video_stabilization = + _camera_attr_is_supported_video_stabilization_ptr + .asFunction<_dart_camera_attr_is_supported_video_stabilization>(); + + /// @brief Enables/Disables auto contrast. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[in] enable If @c true auto contrast is enabled, otherwise @c false + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW. + /// @see camera_attr_is_enabled_auto_contrast() + int camera_attr_enable_auto_contrast( + ffi.Pointer camera, + bool enable, + ) { + return _camera_attr_enable_auto_contrast( + camera, + enable ? 1 : 0, + ); + } + + late final _camera_attr_enable_auto_contrast_ptr = + _lookup>( + 'camera_attr_enable_auto_contrast'); + late final _dart_camera_attr_enable_auto_contrast + _camera_attr_enable_auto_contrast = _camera_attr_enable_auto_contrast_ptr + .asFunction<_dart_camera_attr_enable_auto_contrast>(); + + /// @brief Gets the state of auto contrast. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] camera The handle to the camera + /// @param[out] enabled The state of auto contrast + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_enable_auto_contrast() + int camera_attr_is_enabled_auto_contrast( + ffi.Pointer camera, + ffi.Pointer enabled, + ) { + return _camera_attr_is_enabled_auto_contrast( + camera, + enabled, + ); + } + + late final _camera_attr_is_enabled_auto_contrast_ptr = + _lookup>( + 'camera_attr_is_enabled_auto_contrast'); + late final _dart_camera_attr_is_enabled_auto_contrast + _camera_attr_is_enabled_auto_contrast = + _camera_attr_is_enabled_auto_contrast_ptr + .asFunction<_dart_camera_attr_is_enabled_auto_contrast>(); + + /// @brief Gets state of support of auto contrast feature. + /// @ingroup CAPI_MEDIA_CAMERA_CAPABILITY_MODULE + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] camera The handle to the camera + /// @return true on supported, otherwise false + /// @exception #CAMERA_ERROR_NONE Successful + /// @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @see camera_attr_enable_auto_contrast() + /// @see camera_attr_is_enabled_auto_contrast() + bool camera_attr_is_supported_auto_contrast( + ffi.Pointer camera, + ) { + return _camera_attr_is_supported_auto_contrast( + camera, + ) != + 0; + } + + late final _camera_attr_is_supported_auto_contrast_ptr = + _lookup>( + 'camera_attr_is_supported_auto_contrast'); + late final _dart_camera_attr_is_supported_auto_contrast + _camera_attr_is_supported_auto_contrast = + _camera_attr_is_supported_auto_contrast_ptr + .asFunction<_dart_camera_attr_is_supported_auto_contrast>(); + + /// @brief Disables shutter sound. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks In some countries, this operation is not permitted. + /// @param[in] camera The handle to the camera + /// @param[in] disable If @c true shutter sound is disabled, otherwise @c false + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_OPERATION Disabling shutter sound is not permitted + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + int camera_attr_disable_shutter_sound( + ffi.Pointer camera, + bool disable, + ) { + return _camera_attr_disable_shutter_sound( + camera, + disable ? 1 : 0, + ); + } + + late final _camera_attr_disable_shutter_sound_ptr = + _lookup>( + 'camera_attr_disable_shutter_sound'); + late final _dart_camera_attr_disable_shutter_sound + _camera_attr_disable_shutter_sound = + _camera_attr_disable_shutter_sound_ptr + .asFunction<_dart_camera_attr_disable_shutter_sound>(); + + /// @brief Sets the position to move horizontally. + /// @since_tizen 3.0 + /// @param[in] camera The handle to the camera + /// @param[in] move_type The PTZ(Pan Tilt Zoom) move type + /// @param[in] pan_step The step to move the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_PREVIEW. + /// @see camera_attr_get_pan() + /// @see camera_attr_get_pan_range() + int camera_attr_set_pan( + ffi.Pointer camera, + int move_type, + int pan_step, + ) { + return _camera_attr_set_pan( + camera, + move_type, + pan_step, + ); + } + + late final _camera_attr_set_pan_ptr = + _lookup>( + 'camera_attr_set_pan'); + late final _dart_camera_attr_set_pan _camera_attr_set_pan = + _camera_attr_set_pan_ptr.asFunction<_dart_camera_attr_set_pan>(); + + /// @brief Gets the current position of the camera. + /// @since_tizen 3.0 + /// @param[in] camera The handle to the camera + /// @param[out] pan_step The current horizontal distance from the starting point. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_pan() + /// @see camera_attr_get_pan_range() + int camera_attr_get_pan( + ffi.Pointer camera, + ffi.Pointer pan_step, + ) { + return _camera_attr_get_pan( + camera, + pan_step, + ); + } + + late final _camera_attr_get_pan_ptr = + _lookup>( + 'camera_attr_get_pan'); + late final _dart_camera_attr_get_pan _camera_attr_get_pan = + _camera_attr_get_pan_ptr.asFunction<_dart_camera_attr_get_pan>(); + + /// @brief Gets lower limit and upper limit for pan position. + /// @since_tizen 3.0 + /// @remarks If the min value is greater than the max value, it means that this feature is not supported. + /// @param[in] camera The handle to the camera + /// @param[out] min The lower limit for pan + /// @param[out] max The upper limit for pan + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_pan() + /// @see camera_attr_get_pan() + int camera_attr_get_pan_range( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, + ) { + return _camera_attr_get_pan_range( + camera, + min, + max, + ); + } + + late final _camera_attr_get_pan_range_ptr = + _lookup>( + 'camera_attr_get_pan_range'); + late final _dart_camera_attr_get_pan_range _camera_attr_get_pan_range = + _camera_attr_get_pan_range_ptr + .asFunction<_dart_camera_attr_get_pan_range>(); + + /// @brief Sets the position to move vertically. + /// @since_tizen 3.0 + /// @param[in] camera The handle to the camera + /// @param[in] move_type The PTZ(Pan Tilt Zoom) move type + /// @param[in] tilt_step The step to move the camera + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_PREVIEW. + /// @see camera_attr_get_tilt() + /// @see camera_attr_get_tilt_range() + int camera_attr_set_tilt( + ffi.Pointer camera, + int move_type, + int tilt_step, + ) { + return _camera_attr_set_tilt( + camera, + move_type, + tilt_step, + ); + } + + late final _camera_attr_set_tilt_ptr = + _lookup>( + 'camera_attr_set_tilt'); + late final _dart_camera_attr_set_tilt _camera_attr_set_tilt = + _camera_attr_set_tilt_ptr.asFunction<_dart_camera_attr_set_tilt>(); + + /// @brief Gets the current position of the camera. + /// @since_tizen 3.0 + /// @param[in] camera The handle to the camera + /// @param[out] tilt_step The current vertical distance from the starting point. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_tilt() + /// @see camera_attr_get_tilt_range() + int camera_attr_get_tilt( + ffi.Pointer camera, + ffi.Pointer tilt_step, + ) { + return _camera_attr_get_tilt( + camera, + tilt_step, + ); + } + + late final _camera_attr_get_tilt_ptr = + _lookup>( + 'camera_attr_get_tilt'); + late final _dart_camera_attr_get_tilt _camera_attr_get_tilt = + _camera_attr_get_tilt_ptr.asFunction<_dart_camera_attr_get_tilt>(); + + /// @brief Gets lower limit and upper limit for tilt position. + /// @since_tizen 3.0 + /// @remarks If the min value is greater than the max value, it means that this feature is not supported. + /// @param[in] camera The handle to the camera + /// @param[out] min The lower limit for tilt + /// @param[out] max The upper limit for tilt + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_tilt() + /// @see camera_attr_get_tilt() + int camera_attr_get_tilt_range( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, + ) { + return _camera_attr_get_tilt_range( + camera, + min, + max, + ); + } + + late final _camera_attr_get_tilt_range_ptr = + _lookup>( + 'camera_attr_get_tilt_range'); + late final _dart_camera_attr_get_tilt_range _camera_attr_get_tilt_range = + _camera_attr_get_tilt_range_ptr + .asFunction<_dart_camera_attr_get_tilt_range>(); + + /// @brief Sets the type of PTZ(Pan Tilt Zoom). + /// @since_tizen 3.0 + /// @param[in] camera The handle to the camera + /// @param[in] ptz_type PTZ type + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_INVALID_STATE Invalid state + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The camera state must be set to #CAMERA_STATE_PREVIEW. + /// @see camera_attr_get_pan() + /// @see camera_attr_set_pan() + /// @see camera_attr_get_pan_range() + /// @see camera_attr_get_tilt() + /// @see camera_attr_set_tilt() + /// @see camera_attr_get_tilt_range() + /// @see camera_attr_foreach_supported_ptz_type() + int camera_attr_set_ptz_type( + ffi.Pointer camera, + int ptz_type, + ) { + return _camera_attr_set_ptz_type( + camera, + ptz_type, + ); + } + + late final _camera_attr_set_ptz_type_ptr = + _lookup>( + 'camera_attr_set_ptz_type'); + late final _dart_camera_attr_set_ptz_type _camera_attr_set_ptz_type = + _camera_attr_set_ptz_type_ptr + .asFunction<_dart_camera_attr_set_ptz_type>(); + + /// @brief Retrieves all supported PTZ(Pan Tilt Zoom) types by invoking callback function once for each supported ptz type. + /// @since_tizen 3.0 + /// @param[in] camera The handle to the camera + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes camera_attr_supported_ptz_type_cb() to get all supported ptz type. + /// @see camera_attr_set_ptz_type() + int camera_attr_foreach_supported_ptz_type( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _camera_attr_foreach_supported_ptz_type( + camera, + callback, + user_data, + ); + } + + late final _camera_attr_foreach_supported_ptz_type_ptr = + _lookup>( + 'camera_attr_foreach_supported_ptz_type'); + late final _dart_camera_attr_foreach_supported_ptz_type + _camera_attr_foreach_supported_ptz_type = + _camera_attr_foreach_supported_ptz_type_ptr + .asFunction<_dart_camera_attr_foreach_supported_ptz_type>(); + + /// @brief Sets the ROI(Region Of Interest) area of display. + /// @since_tizen 3.0 + /// @remarks If no display is set, no operation is performed and + /// the ROI area is valid only in #CAMERA_DISPLAY_MODE_CUSTOM_ROI display mode. + /// @remarks The minimum value of width and height are 1. + /// @remarks ROI area can be set before setting ROI display mode. (since 4.0) + /// @param[in] camera The handle to the camera + /// @param[in] x X coordinate of area + /// @param[in] y Y coordinate of area + /// @param[in] width Width of area + /// @param[in] height Height of area + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_get_display_roi_area() + int camera_attr_set_display_roi_area( + ffi.Pointer camera, + int x, + int y, + int width, + int height, + ) { + return _camera_attr_set_display_roi_area( + camera, + x, + y, + width, + height, + ); + } + + late final _camera_attr_set_display_roi_area_ptr = + _lookup>( + 'camera_attr_set_display_roi_area'); + late final _dart_camera_attr_set_display_roi_area + _camera_attr_set_display_roi_area = _camera_attr_set_display_roi_area_ptr + .asFunction<_dart_camera_attr_set_display_roi_area>(); + + /// @brief Gets the ROI(Region Of Interest) area of display. + /// @since_tizen 3.0 + /// @param[in] camera The handle to the camera + /// @param[out] x X coordinate of area + /// @param[out] y Y coordinate of area + /// @param[out] width Width of area + /// @param[out] height Height of area + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CAMERA_ERROR_NONE Successful + /// @retval #CAMERA_ERROR_INVALID_OPERATION Internal error + /// @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see camera_attr_set_display_roi_area() + int camera_attr_get_display_roi_area( + ffi.Pointer camera, + ffi.Pointer x, + ffi.Pointer y, + ffi.Pointer width, + ffi.Pointer height, + ) { + return _camera_attr_get_display_roi_area( + camera, + x, + y, + width, + height, + ); + } + + late final _camera_attr_get_display_roi_area_ptr = + _lookup>( + 'camera_attr_get_display_roi_area'); + late final _dart_camera_attr_get_display_roi_area + _camera_attr_get_display_roi_area = _camera_attr_get_display_roi_area_ptr + .asFunction<_dart_camera_attr_get_display_roi_area>(); + + /// @brief Creates a handle to image util decoding. + /// @details This function creates a handle to image util decoding. + /// @since_tizen 3.0 + /// + /// @remarks The @a handle should be released using image_util_decode_destroy(). + /// + /// @param[out] handle A handle to image util decoding + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see image_util_decode_destroy() + int image_util_decode_create( + ffi.Pointer> handle, + ) { + return _image_util_decode_create( + handle, + ); + } + + late final _image_util_decode_create_ptr = + _lookup>( + 'image_util_decode_create'); + late final _dart_image_util_decode_create _image_util_decode_create = + _image_util_decode_create_ptr + .asFunction<_dart_image_util_decode_create>(); + + /// @brief Sets the input file path from which to decode. + /// @since_tizen 3.0 + /// + /// @remarks One of image_util_decode_set_input_path() or image_util_decode_set_input_buffer() should be set.\n + /// If both are set then the latest input set, is considered.\n + /// http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage.\n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage.\n + /// Finds out image type by reading the header of the image provided in input path. + /// + /// @param[in] handle The handle to image util decoding + /// @param[in] path The path to input image + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_NO_SUCH_FILE No such file + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// @retval #IMAGE_UTIL_ERROR_PERMISSION_DENIED The application does not have the privilege to call this funtion + /// @retval #IMAGE_UTIL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// + /// @pre image_util_decode_create() + /// + /// @post image_util_decode_run() / image_util_decode_run_async() + /// @post image_util_decode_destroy() + /// + /// @see image_util_decode_create() + /// @see image_util_decode_set_output_buffer() + /// @see image_util_decode_run() + /// @see image_util_decode_run_async() + /// @see image_util_decode_destroy() + int image_util_decode_set_input_path( + ffi.Pointer handle, + ffi.Pointer path, + ) { + return _image_util_decode_set_input_path( + handle, + path, + ); + } + + late final _image_util_decode_set_input_path_ptr = + _lookup>( + 'image_util_decode_set_input_path'); + late final _dart_image_util_decode_set_input_path + _image_util_decode_set_input_path = _image_util_decode_set_input_path_ptr + .asFunction<_dart_image_util_decode_set_input_path>(); + + /// @brief Sets the input buffer from which to decode. + /// @since_tizen 3.0 + /// + /// @remarks One of image_util_decode_set_input_path() or image_util_decode_set_input_buffer() should be set.\n + /// If both are set then the latest input set, is considered.\n + /// Finds out image type by reading the header of the image provided in input buffer. + /// + /// @param[in] handle The handle to image util decoding + /// @param[in] src_buffer The input image buffer + /// @param[in] src_size The input image buffer size + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// @retval #IMAGE_UTIL_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// + /// @pre image_util_decode_create() + /// + /// @post image_util_decode_run() / image_util_decode_run_async() + /// @post image_util_decode_destroy() + /// + /// @see image_util_decode_create() + /// @see image_util_decode_set_output_buffer() + /// @see image_util_decode_run() + /// @see image_util_decode_run_async() + /// @see image_util_decode_destroy() + int image_util_decode_set_input_buffer( + ffi.Pointer handle, + ffi.Pointer src_buffer, + int src_size, + ) { + return _image_util_decode_set_input_buffer( + handle, + src_buffer, + src_size, + ); + } + + late final _image_util_decode_set_input_buffer_ptr = + _lookup>( + 'image_util_decode_set_input_buffer'); + late final _dart_image_util_decode_set_input_buffer + _image_util_decode_set_input_buffer = + _image_util_decode_set_input_buffer_ptr + .asFunction<_dart_image_util_decode_set_input_buffer>(); + + /// @brief Sets the output buffer to which the decoded buffer will be written to. + /// @since_tizen 3.0 + /// + /// @remarks Either image_util_decode_set_input_path() or image_util_decode_set_input_buffer() should be set.\n + /// By default the decoded output buffer colorspace will be IMAGE_UTIL_COLORSPACE_RGBA8888. + /// Use image_util_decode_set_colorspace to change the colorspace. + /// @a dst_buffer should be released after @c image_util_decode_run() or @c image_util_decode_run_async(). + /// + /// @param[in] handle The handle to image util decoding + /// @param[in] dst_buffer The decoded output buffer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_decode_create() + /// + /// @post image_util_decode_run() / image_util_decode_run_async() + /// @post image_util_decode_destroy() + /// + /// @see image_util_decode_create() + /// @see image_util_decode_set_input_path() + /// @see image_util_decode_set_input_buffer() + /// @see image_util_decode_run() + /// @see image_util_decode_run_async() + /// @see image_util_decode_destroy() + int image_util_decode_set_output_buffer( + ffi.Pointer handle, + ffi.Pointer> dst_buffer, + ) { + return _image_util_decode_set_output_buffer( + handle, + dst_buffer, + ); + } + + late final _image_util_decode_set_output_buffer_ptr = + _lookup>( + 'image_util_decode_set_output_buffer'); + late final _dart_image_util_decode_set_output_buffer + _image_util_decode_set_output_buffer = + _image_util_decode_set_output_buffer_ptr + .asFunction<_dart_image_util_decode_set_output_buffer>(); + + /// @brief Sets the decoded image colorspace format. + /// @since_tizen 3.0 + /// + /// @remarks The default colorspace is IMAGE_UTIL_COLORSPACE_RGBA8888.\n + /// Use image_util_foreach_supported_colorspace to get supported colorspaces for each image format.\n + /// Errors would be returned if not supported. + /// + /// @param[in] handle The handle to image util decoding + /// @param[in] colorspace The decoded image colorspace + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// + /// @pre image_util_decode_create() + /// @pre image_util_decode_set_input_path() / image_util_decode_set_input_buffer() + /// + /// @post image_util_decode_run() / image_util_decode_run_async() + /// @post image_util_decode_destroy() + /// + /// @see image_util_supported_colorspace_cb() + /// @see image_util_foreach_supported_colorspace() + /// @see image_util_decode_create() + /// @see image_util_decode_set_input_path() + /// @see image_util_decode_set_input_buffer() + /// @see image_util_decode_set_output_buffer() + /// @see image_util_decode_run() + /// @see image_util_decode_run_async() + /// @see image_util_decode_destroy() + int image_util_decode_set_colorspace( + ffi.Pointer handle, + int colorspace, + ) { + return _image_util_decode_set_colorspace( + handle, + colorspace, + ); + } + + late final _image_util_decode_set_colorspace_ptr = + _lookup>( + 'image_util_decode_set_colorspace'); + late final _dart_image_util_decode_set_colorspace + _image_util_decode_set_colorspace = _image_util_decode_set_colorspace_ptr + .asFunction<_dart_image_util_decode_set_colorspace>(); + + /// @brief Sets the downscale value at which JPEG image should be decoded. + /// @since_tizen 3.0 + /// + /// @remarks This is API is supported only for JPEG decoding. + /// + /// @param[in] handle The handle to image util decoding + /// @param[in] down_scale The downscale at which image is to be decoded + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// + /// @pre image_util_decode_create() + /// @pre image_util_decode_set_input_path() / image_util_decode_set_input_buffer() + /// + /// @post image_util_decode_run() / image_util_decode_run_async() + /// @post image_util_decode_destroy() + /// + /// @see image_util_decode_create() + /// @see image_util_decode_set_input_path() + /// @see image_util_decode_set_input_buffer() + /// @see image_util_decode_set_output_buffer() + /// @see image_util_decode_run() + /// @see image_util_decode_run_async() + /// @see image_util_decode_destroy() + int image_util_decode_set_jpeg_downscale( + ffi.Pointer handle, + int down_scale, + ) { + return _image_util_decode_set_jpeg_downscale( + handle, + down_scale, + ); + } + + late final _image_util_decode_set_jpeg_downscale_ptr = + _lookup>( + 'image_util_decode_set_jpeg_downscale'); + late final _dart_image_util_decode_set_jpeg_downscale + _image_util_decode_set_jpeg_downscale = + _image_util_decode_set_jpeg_downscale_ptr + .asFunction<_dart_image_util_decode_set_jpeg_downscale>(); + + /// @brief Starts decoding of the image and fills the output buffer set using image_util_decode_set_output_buffer(). + /// @since_tizen 3.0 + /// + /// @remarks The output will be stored in the pointer set using image_util_decode_set_output_buffer().\n + /// The function executes synchronously.\n + /// When any of the @pre functions are not called, IMAGE_UTIL_ERROR_INVALID_PARAMETER is returned. + /// + /// @param[in] handle The handle to image util decoding + /// @param[out] width Width of the decoded image + /// @param[out] height Height of the decoded image + /// @param[out] size Size of the decoded image + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_decode_create() + /// @pre image_util_decode_set_input_buffer() / image_util_decode_set_input_path(). + /// @pre image_util_decode_set_output_buffer() + /// + /// @post image_util_decode_destroy() + /// + /// @see image_util_decode_create() + /// @see image_util_decode_set_input_path() + /// @see image_util_decode_set_input_buffer() + /// @see image_util_decode_set_output_buffer() + /// @see image_util_decode_destroy() + int image_util_decode_run( + ffi.Pointer handle, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, + ) { + return _image_util_decode_run( + handle, + width, + height, + size, + ); + } + + late final _image_util_decode_run_ptr = + _lookup>( + 'image_util_decode_run'); + late final _dart_image_util_decode_run _image_util_decode_run = + _image_util_decode_run_ptr.asFunction<_dart_image_util_decode_run>(); + + /// @brief Starts decoding of the image and fills the output buffer set using image_util_decode_set_output_buffer(). + /// @since_tizen 3.0 + /// + /// @remarks The output will be stored in the pointer set using image_util_decode_set_output_buffer().\n + /// The function executes asynchronously, which contains complete callback.\n + /// When any of the @pre functions are not called, IMAGE_UTIL_ERROR_INVALID_PARAMETER is returned. + /// + /// @param[in] handle The handle to image util decoding + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_decode_create() + /// @pre image_util_decode_set_input_buffer() / image_util_decode_set_input_path(). + /// @pre image_util_decode_set_output_buffer() + /// + /// @post image_util_decode_destroy() + /// + /// @see image_util_decode_create() + /// @see image_util_decode_set_input_path() + /// @see image_util_decode_set_input_buffer() + /// @see image_util_decode_set_output_buffer() + /// @see image_util_decode_destroy() + int image_util_decode_run_async( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _image_util_decode_run_async( + handle, + callback, + user_data, + ); + } + + late final _image_util_decode_run_async_ptr = + _lookup>( + 'image_util_decode_run_async'); + late final _dart_image_util_decode_run_async _image_util_decode_run_async = + _image_util_decode_run_async_ptr + .asFunction<_dart_image_util_decode_run_async>(); + + /// @brief Destroys the image decoding handle. + /// @since_tizen 3.0 + /// + /// @remarks Any image handle created should be destroyed. + /// + /// @param[in] handle The handle to image util decoding + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_decode_create() + /// + /// @see image_util_decode_create() + int image_util_decode_destroy( + ffi.Pointer handle, + ) { + return _image_util_decode_destroy( + handle, + ); + } + + late final _image_util_decode_destroy_ptr = + _lookup>( + 'image_util_decode_destroy'); + late final _dart_image_util_decode_destroy _image_util_decode_destroy = + _image_util_decode_destroy_ptr + .asFunction<_dart_image_util_decode_destroy>(); + + /// @deprecated Deprecated since 3.0. Use image_util_decode_create() instead. + /// @brief Decodes the JPEG image to the buffer. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a image_buffer should be released using free().\n + /// http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage.\n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage.\n + /// If you decode the JPEG image which has odd numbered width or height to YUV colorspace, \n + /// the width or height of decoded data will be rounded down to even numbered width or height. + /// + /// @param[in] path The image file path + /// @param[in] colorspace The decoded image colorspace + /// @param[out] image_buffer The image buffer for the decoded image + /// @param[out] width The image width + /// @param[out] height The image height + /// @param[out] size The image buffer size + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_OUT_OF_MEMORY out of memory + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// @retval #IMAGE_UTIL_ERROR_PERMISSION_DENIED The application does not have the privilege to call this funtion + /// + /// @see image_util_supported_jpeg_colorspace_cb() + /// @see image_util_decode_jpeg_from_memory() + /// @see image_util_foreach_supported_jpeg_colorspace() + int image_util_decode_jpeg( + ffi.Pointer path, + int colorspace, + ffi.Pointer> image_buffer, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, + ) { + return _image_util_decode_jpeg( + path, + colorspace, + image_buffer, + width, + height, + size, + ); + } + + late final _image_util_decode_jpeg_ptr = + _lookup>( + 'image_util_decode_jpeg'); + late final _dart_image_util_decode_jpeg _image_util_decode_jpeg = + _image_util_decode_jpeg_ptr.asFunction<_dart_image_util_decode_jpeg>(); + + /// @deprecated Deprecated since 3.0. Use image_util_decode_create() instead. + /// @brief Decodes the JPEG image(in memory) to the buffer. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a image_buffer should be released using free().\n + /// If you decode the JPEG image which has odd numbered width or height to YUV colorspace, \n + /// the width or height of decoded data will be rounded down to even numbered width or height. + /// + /// @param[in] jpeg_buffer The JPEG image buffer + /// @param[in] jpeg_size The JPEG image buffer size + /// @param[in] colorspace The decoded image colorspace + /// @param[out] image_buffer The image buffer for the decoded image + /// @param[out] width The image width + /// @param[out] height The image height + /// @param[out] size The image buffer size + /// + /// @return 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_OUT_OF_MEMORY out of memory + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// @retval #IMAGE_UTIL_ERROR_PERMISSION_DENIED The application does not have the privilege to call this funtion + /// + /// @see image_util_supported_jpeg_colorspace_cb() + /// @see image_util_decode_jpeg() + /// @see image_util_foreach_supported_jpeg_colorspace() + int image_util_decode_jpeg_from_memory( + ffi.Pointer jpeg_buffer, + int jpeg_size, + int colorspace, + ffi.Pointer> image_buffer, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, + ) { + return _image_util_decode_jpeg_from_memory( + jpeg_buffer, + jpeg_size, + colorspace, + image_buffer, + width, + height, + size, + ); + } + + late final _image_util_decode_jpeg_from_memory_ptr = + _lookup>( + 'image_util_decode_jpeg_from_memory'); + late final _dart_image_util_decode_jpeg_from_memory + _image_util_decode_jpeg_from_memory = + _image_util_decode_jpeg_from_memory_ptr + .asFunction<_dart_image_util_decode_jpeg_from_memory>(); + + /// @deprecated Deprecated since 3.0. Use image_util_decode_create() instead. + /// @brief Decodes the JPEG image to the buffer with downscale decoding option. + /// @since_tizen @if WEARABLE @else 2.4 @endif + /// + /// @remarks The @a image_buffer should be released using free().\n + /// http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage.\n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage.\n + /// If you decode the JPEG image which has odd numbered width or height to YUV colorspace, \n + /// the width or height of decoded data will be rounded down to even numbered width or height. + /// + /// @param[in] path The image file path + /// @param[in] colorspace The decoded image colorspace + /// @param[in] downscale The downscale value + /// @param[out] image_buffer The image buffer for the decoded image + /// @param[out] width The image width + /// @param[out] height The image height + /// @param[out] size The image buffer size + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_OUT_OF_MEMORY out of memory + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// @retval #IMAGE_UTIL_ERROR_PERMISSION_DENIED The application does not have the privilege to call this funtion + /// + /// @see image_util_supported_jpeg_colorspace_cb() + /// @see image_util_decode_jpeg_from_memory() + /// @see image_util_foreach_supported_jpeg_colorspace() + int image_util_decode_jpeg_with_downscale( + ffi.Pointer path, + int colorspace, + int downscale, + ffi.Pointer> image_buffer, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, + ) { + return _image_util_decode_jpeg_with_downscale( + path, + colorspace, + downscale, + image_buffer, + width, + height, + size, + ); + } + + late final _image_util_decode_jpeg_with_downscale_ptr = + _lookup>( + 'image_util_decode_jpeg_with_downscale'); + late final _dart_image_util_decode_jpeg_with_downscale + _image_util_decode_jpeg_with_downscale = + _image_util_decode_jpeg_with_downscale_ptr + .asFunction<_dart_image_util_decode_jpeg_with_downscale>(); + + /// @deprecated Deprecated since 3.0. Use image_util_decode_create() instead. + /// @brief Decodes the JPEG image(in memory) to the buffer with downscale decoding option. + /// @since_tizen @if WEARABLE @else 2.4 @endif + /// + /// @remarks The @a image_buffer should be released using free().\n + /// If you decode the JPEG image which has odd numbered width or height to YUV colorspace, \n + /// the width or height of decoded data will be rounded down to even numbered width or height. + /// + /// @param[in] jpeg_buffer The JPEG image buffer + /// @param[in] jpeg_size The JPEG image buffer size + /// @param[in] colorspace The decoded image colorspace + /// @param[in] downscale The downscale value + /// @param[out] image_buffer The image buffer for the decoded image + /// @param[out] width The image width + /// @param[out] height The image height + /// @param[out] size The image buffer size + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_OUT_OF_MEMORY out of memory + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// @retval #IMAGE_UTIL_ERROR_PERMISSION_DENIED The application does not have the privilege to call this funtion + /// + /// @see image_util_supported_jpeg_colorspace_cb() + /// @see image_util_decode_jpeg() + /// @see image_util_foreach_supported_jpeg_colorspace() + int image_util_decode_jpeg_from_memory_with_downscale( + ffi.Pointer jpeg_buffer, + int jpeg_size, + int colorspace, + int downscale, + ffi.Pointer> image_buffer, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, + ) { + return _image_util_decode_jpeg_from_memory_with_downscale( + jpeg_buffer, + jpeg_size, + colorspace, + downscale, + image_buffer, + width, + height, + size, + ); + } + + late final _image_util_decode_jpeg_from_memory_with_downscale_ptr = _lookup< + ffi.NativeFunction< + _c_image_util_decode_jpeg_from_memory_with_downscale>>( + 'image_util_decode_jpeg_from_memory_with_downscale'); + late final _dart_image_util_decode_jpeg_from_memory_with_downscale + _image_util_decode_jpeg_from_memory_with_downscale = + _image_util_decode_jpeg_from_memory_with_downscale_ptr.asFunction< + _dart_image_util_decode_jpeg_from_memory_with_downscale>(); + + /// @brief Creates a handle to image util encoding. + /// @details This function creates a handle to image util encoding. + /// @since_tizen 3.0 + /// + /// @remarks The @a handle should be released using image_util_encode_destroy(). + /// + /// @param[in] image_type The type of output image for which to create encode handle. + /// @param[out] handle A handle to image util encoding + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see image_util_encode_destroy() + int image_util_encode_create( + int image_type, + ffi.Pointer> handle, + ) { + return _image_util_encode_create( + image_type, + handle, + ); + } + + late final _image_util_encode_create_ptr = + _lookup>( + 'image_util_encode_create'); + late final _dart_image_util_encode_create _image_util_encode_create = + _image_util_encode_create_ptr + .asFunction<_dart_image_util_encode_create>(); + + /// @brief Sets the resolution of the encoded image. + /// @since_tizen 3.0 + /// + /// @remarks This should be called before calling image_util_encode_run().\n + /// While encoding animated gif image, resolution should be set for each frame. + /// + /// @param[in] handle The handle to image util encoding + /// @param[in] width Width of the original image + /// @param[in] height Height of the original image + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_encode_create() + /// + /// @post image_util_encode_run() / image_util_encode_run_async() + /// @post image_util_encode_destroy() + /// + /// @see image_util_encode_create() + /// @see image_util_encode_set_input_buffer() + /// @see image_util_encode_set_output_path() + /// @see image_util_encode_set_output_buffer() + /// @see image_util_encode_run() + /// @see image_util_encode_run_async() + /// @see image_util_encode_destroy() + int image_util_encode_set_resolution( + ffi.Pointer handle, + int width, + int height, + ) { + return _image_util_encode_set_resolution( + handle, + width, + height, + ); + } + + late final _image_util_encode_set_resolution_ptr = + _lookup>( + 'image_util_encode_set_resolution'); + late final _dart_image_util_encode_set_resolution + _image_util_encode_set_resolution = _image_util_encode_set_resolution_ptr + .asFunction<_dart_image_util_encode_set_resolution>(); + + /// @brief Sets the colorspace format for image encoding. + /// @since_tizen 3.0 + /// + /// @remarks The default colorspace is IMAGE_UTIL_COLORSPACE_RGBA8888.\n + /// Use image_util_foreach_supported_colorspace to get supported colorspaces for each image format.\n + /// Errors would be returned if not supported. + /// + /// @param[in] handle The handle to image util encoding + /// @param[in] colorspace The colorspace of the input image to encode + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre image_util_encode_create() + /// + /// @post image_util_encode_run() / image_util_encode_run_async() + /// @post image_util_encode_destroy() + /// + /// @see image_util_supported_colorspace_cb() + /// @see image_util_foreach_supported_colorspace() + /// @see image_util_encode_create() + /// @see image_util_encode_set_resolution() + /// @see image_util_encode_set_input_buffer() + /// @see image_util_encode_set_output_path() + /// @see image_util_encode_set_output_buffer() + /// @see image_util_encode_run() + /// @see image_util_encode_run_async() + /// @see image_util_encode_destroy() + int image_util_encode_set_colorspace( + ffi.Pointer handle, + int colorspace, + ) { + return _image_util_encode_set_colorspace( + handle, + colorspace, + ); + } + + late final _image_util_encode_set_colorspace_ptr = + _lookup>( + 'image_util_encode_set_colorspace'); + late final _dart_image_util_encode_set_colorspace + _image_util_encode_set_colorspace = _image_util_encode_set_colorspace_ptr + .asFunction<_dart_image_util_encode_set_colorspace>(); + + /// @brief Sets the quality for image encoding. + /// @since_tizen 3.0 + /// + /// @remarks If application does not set this, then by default quality of 75 is set.\n + /// Quality is supported for JPEG format. IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT will be returned for other formats. + /// + /// @param[in] handle The handle to image util encoding + /// @param[in] quality Encoding quality from 1~100 + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre image_util_encode_create() + /// + /// @post image_util_encode_run() / image_util_encode_run_async() + /// @post image_util_encode_destroy() + /// + /// @see image_util_encode_create() + /// @see image_util_encode_set_resolution() + /// @see image_util_encode_set_input_buffer() + /// @see image_util_encode_set_output_path() + /// @see image_util_encode_set_output_buffer() + /// @see image_util_encode_run() + /// @see image_util_encode_run_async() + /// @see image_util_encode_destroy() + int image_util_encode_set_quality( + ffi.Pointer handle, + int quality, + ) { + return _image_util_encode_set_quality( + handle, + quality, + ); + } + + late final _image_util_encode_set_quality_ptr = + _lookup>( + 'image_util_encode_set_quality'); + late final _dart_image_util_encode_set_quality + _image_util_encode_set_quality = _image_util_encode_set_quality_ptr + .asFunction<_dart_image_util_encode_set_quality>(); + + /// @brief Sets the compression value of png image encoding(0~9). + /// @since_tizen 3.0 + /// + /// @remarks If application does not set this, then default compression of 6 is set. + /// + /// @param[in] handle The handle to image util encoding + /// @param[in] compression The compression value valid from 0~9 + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_encode_create() + /// + /// @post image_util_encode_run() / image_util_encode_run_async() + /// @post image_util_encode_destroy() + /// + /// @see image_util_encode_create() + /// @see image_util_encode_set_resolution() + /// @see image_util_encode_set_input_buffer() + /// @see image_util_encode_set_output_path() + /// @see image_util_encode_set_output_buffer() + /// @see image_util_encode_run() + /// @see image_util_encode_run_async() + /// @see image_util_encode_destroy() + int image_util_encode_set_png_compression( + ffi.Pointer handle, + int compression, + ) { + return _image_util_encode_set_png_compression( + handle, + compression, + ); + } + + late final _image_util_encode_set_png_compression_ptr = + _lookup>( + 'image_util_encode_set_png_compression'); + late final _dart_image_util_encode_set_png_compression + _image_util_encode_set_png_compression = + _image_util_encode_set_png_compression_ptr + .asFunction<_dart_image_util_encode_set_png_compression>(); + + /// @brief Sets the time delay between each frame in the encoded animated gif image. + /// @since_tizen 3.0 + /// + /// @remarks In case animated gif image if this is not set then there will be no delay between each frame.\n + /// This should be set for each frame in the animated gif image.\n + /// This can be set a different value for each frame, which results in different delay time between different frames. + /// + /// @param[in] handle The handle to image util encoding + /// @param[in] delay_time Time delay between each frame in the encoded image, in 0.01sec units. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre image_util_encode_create() + /// + /// @post image_util_encode_run() / image_util_encode_run_async() + /// @post image_util_encode_destroy() + /// + /// @see image_util_encode_create() + /// @see image_util_encode_set_resolution() + /// @see image_util_encode_set_input_buffer() + /// @see image_util_encode_set_output_path() + /// @see image_util_encode_set_output_buffer() + /// @see image_util_encode_run() + /// @see image_util_encode_run_async() + /// @see image_util_encode_destroy() + int image_util_encode_set_gif_frame_delay_time( + ffi.Pointer handle, + int delay_time, + ) { + return _image_util_encode_set_gif_frame_delay_time( + handle, + delay_time, + ); + } + + late final _image_util_encode_set_gif_frame_delay_time_ptr = _lookup< + ffi.NativeFunction<_c_image_util_encode_set_gif_frame_delay_time>>( + 'image_util_encode_set_gif_frame_delay_time'); + late final _dart_image_util_encode_set_gif_frame_delay_time + _image_util_encode_set_gif_frame_delay_time = + _image_util_encode_set_gif_frame_delay_time_ptr + .asFunction<_dart_image_util_encode_set_gif_frame_delay_time>(); + + /// @brief Sets the input buffer from which to encode. + /// @since_tizen 3.0 + /// + /// @remarks Either image_util_encode_set_output_path() or image_util_encode_set_output_buffer() should be set.\n + /// By default the input buffer colorspace will be considered as IMAGE_UTIL_COLORSPACE_RGBA8888.\n + /// Use image_util_encode_set_colorspace to change the colorspace.\n + /// While encoding animated gif image, input buffer should be set for each frame. + /// + /// @param[in] handle The handle to image util decoding + /// @param[in] src_buffer The input image buffer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_encode_create() + /// + /// @post image_util_encode_run() / image_util_encode_run_async() + /// @post image_util_encode_destroy() + /// + /// @see image_util_encode_create() + /// @see image_util_encode_set_resolution() + /// @see image_util_encode_set_input_buffer() + /// @see image_util_encode_set_output_path() + /// @see image_util_encode_set_output_buffer() + /// @see image_util_encode_run() + /// @see image_util_encode_run_async() + /// @see image_util_encode_destroy() + int image_util_encode_set_input_buffer( + ffi.Pointer handle, + ffi.Pointer src_buffer, + ) { + return _image_util_encode_set_input_buffer( + handle, + src_buffer, + ); + } + + late final _image_util_encode_set_input_buffer_ptr = + _lookup>( + 'image_util_encode_set_input_buffer'); + late final _dart_image_util_encode_set_input_buffer + _image_util_encode_set_input_buffer = + _image_util_encode_set_input_buffer_ptr + .asFunction<_dart_image_util_encode_set_input_buffer>(); + + /// @brief Sets the output path to which to encoded buffer will be written to. + /// @since_tizen 3.0 + /// + /// @remarks One of image_util_encode_set_output_path() or image_util_encode_set_output_buffer() should be set.\n + /// If both are set then the latest output set is considered.\n + /// http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage.\n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. + /// + /// @param[in] handle The handle to image util encoding + /// @param[in] path The output file path + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_NO_SUCH_FILE No such file + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// @retval #IMAGE_UTIL_ERROR_PERMISSION_DENIED The application does not have the privilege to call this funtion + /// + /// @pre image_util_encode_create() + /// + /// @post image_util_encode_run() / image_util_encode_run_async() + /// @post image_util_encode_destroy() + /// + /// @see image_util_encode_create() + /// @see image_util_encode_set_resolution() + /// @see image_util_encode_set_input_buffer() + /// @see image_util_encode_run() + /// @see image_util_encode_run_async() + /// @see image_util_encode_destroy() + int image_util_encode_set_output_path( + ffi.Pointer handle, + ffi.Pointer path, + ) { + return _image_util_encode_set_output_path( + handle, + path, + ); + } + + late final _image_util_encode_set_output_path_ptr = + _lookup>( + 'image_util_encode_set_output_path'); + late final _dart_image_util_encode_set_output_path + _image_util_encode_set_output_path = + _image_util_encode_set_output_path_ptr + .asFunction<_dart_image_util_encode_set_output_path>(); + + /// @brief Sets the output buffer to which to encoded buffer will be written to. + /// @since_tizen 3.0 + /// + /// @remarks One of image_util_encode_set_output_path() or image_util_encode_set_output_buffer() should be set.\n + /// If both are set then the latest output set is considered.\n + /// Before 4.0, output buffer setting is not supported for bmp. IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT will be returned for bmp.\n + /// Since 4.0, output buffer setting has been supported for bmp. Applications can set the output buffer to write encoded bmp.\n + /// In case of gif encoding, the output buffer will be completely available only after image_util_encode_destroy(). + /// @a dst_buffer should be released after @c image_util_encode_run() or @c image_util_encode_run_async(). + /// + /// @param[in] handle The handle to image util encoding + /// @param[in] dst_buffer The output image buffer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// + /// @pre image_util_encode_create() + /// + /// @post image_util_encode_run() / image_util_encode_run_async() + /// @post image_util_encode_destroy() + /// + /// @see image_util_encode_create() + /// @see image_util_encode_set_resolution() + /// @see image_util_encode_set_input_buffer() + /// @see image_util_encode_run() + /// @see image_util_encode_run_async() + /// @see image_util_encode_destroy() + int image_util_encode_set_output_buffer( + ffi.Pointer handle, + ffi.Pointer> dst_buffer, + ) { + return _image_util_encode_set_output_buffer( + handle, + dst_buffer, + ); + } + + late final _image_util_encode_set_output_buffer_ptr = + _lookup>( + 'image_util_encode_set_output_buffer'); + late final _dart_image_util_encode_set_output_buffer + _image_util_encode_set_output_buffer = + _image_util_encode_set_output_buffer_ptr + .asFunction<_dart_image_util_encode_set_output_buffer>(); + + /// @brief Starts encoding of the image and fills the output buffer, set using image_util_encode_set_output_buffer() or image_util_encode_set_output_path(). + /// @since_tizen 3.0 + /// + /// @remarks The output will be stored in the pointer set to image_util_encode_set_output_buffer() or image_util_encode_set_output_path().\n + /// The function executes synchronously.\n + /// When any of the @pre functions are not called, IMAGE_UTIL_ERROR_INVALID_PARAMETER is returned.\n + /// In case of animated gif encoding, image_util_encode_set_resolution(), image_util_encode_set_input_buffer() and\n + /// image_util_encode_set_gif_frame_delay_time() MUST be called for each frame. + /// In case of animated gif encoding, call image_util_encode_run() for each frame to encode progressively. + /// + /// @param[in] handle The handle to image util encoding + /// @param[out] size Size of the encoded image + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_encode_create() + /// @pre image_util_encode_set_resolution() + /// @pre image_util_encode_set_input_buffer() + /// @pre image_util_encode_set_output_buffer() / image_util_encode_set_output_path() + /// + /// @post image_util_encode_destroy() + /// + /// @see image_util_encode_create() + /// @see image_util_encode_set_resolution() + /// @see image_util_encode_set_input_buffer() + /// @see image_util_encode_set_gif_frame_delay_time() + /// @see image_util_encode_set_output_path() + /// @see image_util_encode_set_output_buffer() + /// @see image_util_encode_destroy() + int image_util_encode_run( + ffi.Pointer handle, + ffi.Pointer size, + ) { + return _image_util_encode_run( + handle, + size, + ); + } + + late final _image_util_encode_run_ptr = + _lookup>( + 'image_util_encode_run'); + late final _dart_image_util_encode_run _image_util_encode_run = + _image_util_encode_run_ptr.asFunction<_dart_image_util_encode_run>(); + + /// @brief Starts encoding of the image and fills the output buffer, set using image_util_encode_set_output_buffer() or image_util_encode_set_output_path(). + /// @since_tizen 3.0 + /// + /// @remarks The output will be stored in the pointer set to image_util_encode_set_output_buffer() or image_util_encode_set_output_path().\n + /// The function executes asynchronously, which contains complete callback.\n + /// When any of the @pre functions are not called, IMAGE_UTIL_ERROR_INVALID_PARAMETER is returned.\n + /// In case of animated gif encoding, image_util_encode_set_resolution(), image_util_encode_set_input_buffer() and\n + /// image_util_encode_set_gif_frame_delay_time() MUST be called for each frame. + /// In case of animated gif encoding, call image_util_encode_run_async() for each frame to encode progressively. + /// + /// @param[in] handle The handle to image util encoding + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_encode_create() + /// @pre image_util_encode_set_resolution() + /// @pre image_util_encode_set_input_buffer() + /// @pre image_util_encode_set_output_buffer() / image_util_encode_set_output_path() + /// + /// @post image_util_encode_destroy() + /// + /// @see image_util_encode_create() + /// @see image_util_encode_set_resolution() + /// @see image_util_encode_set_input_buffer() + /// @see image_util_encode_set_gif_frame_delay_time() + /// @see image_util_encode_set_output_path() + /// @see image_util_encode_set_output_buffer() + /// @see image_util_encode_destroy() + int image_util_encode_run_async( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _image_util_encode_run_async( + handle, + callback, + user_data, + ); + } + + late final _image_util_encode_run_async_ptr = + _lookup>( + 'image_util_encode_run_async'); + late final _dart_image_util_encode_run_async _image_util_encode_run_async = + _image_util_encode_run_async_ptr + .asFunction<_dart_image_util_encode_run_async>(); + + /// @brief Destroys the image encoding handle. + /// @since_tizen 3.0 + /// + /// @remarks Any image handle created should be destroyed. + /// + /// @param[in] handle The handle to image util encoding + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_encode_create() + /// + /// @see image_util_encode_create() + int image_util_encode_destroy( + ffi.Pointer handle, + ) { + return _image_util_encode_destroy( + handle, + ); + } + + late final _image_util_encode_destroy_ptr = + _lookup>( + 'image_util_encode_destroy'); + late final _dart_image_util_encode_destroy _image_util_encode_destroy = + _image_util_encode_destroy_ptr + .asFunction<_dart_image_util_encode_destroy>(); + + /// @deprecated Deprecated since 3.0. Use image_util_encode_create() instead. + /// @brief Encodes the image to the JPEG image. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage.\n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. + /// + /// @param[in] buffer The original image buffer + /// @param[in] width The original image width + /// @param[in] height The original image height + /// @param[in] colorspace The original image colorspace + /// @param[in] quality The quality for JPEG image encoding(1 ~ 100) + /// @param[in] path The file path to be created + /// + /// @return 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_NO_SUCH_FILE No such file + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// @retval #IMAGE_UTIL_ERROR_PERMISSION_DENIED The application does not have the privilege to call this funtion + /// + /// @see image_util_supported_jpeg_colorspace_cb() + /// @see image_util_foreach_supported_jpeg_colorspace() + /// @see image_util_encode_jpeg_to_memory() + int image_util_encode_jpeg( + ffi.Pointer buffer, + int width, + int height, + int colorspace, + int quality, + ffi.Pointer path, + ) { + return _image_util_encode_jpeg( + buffer, + width, + height, + colorspace, + quality, + path, + ); + } + + late final _image_util_encode_jpeg_ptr = + _lookup>( + 'image_util_encode_jpeg'); + late final _dart_image_util_encode_jpeg _image_util_encode_jpeg = + _image_util_encode_jpeg_ptr.asFunction<_dart_image_util_encode_jpeg>(); + + /// @deprecated Deprecated since 3.0. Use image_util_encode_create() instead. + /// @brief Encodes the image to the JPEG image + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a jpeg_buffer should be released using free(). + /// + /// @param[in] image_buffer The original image buffer + /// @param[in] width The image width + /// @param[in] height The image height + /// @param[in] colorspace The original image colorspace + /// @param[in] quality The quality for JPEG image encoding(1 ~ 100) + /// @param[out] jpeg_buffer The created JPEG image buffer \n + /// The buffer is created by frameworks + /// @param[out] jpeg_size The created jpeg image buffer size + /// + /// @return 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_OUT_OF_MEMORY out of memory + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Format not supported + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// @retval #IMAGE_UTIL_ERROR_PERMISSION_DENIED The application does not have the privilege to call this funtion + /// + /// @see image_util_supported_jpeg_colorspace_cb() + /// @see image_util_foreach_supported_jpeg_colorspace() + /// @see image_util_encode_jpeg() + int image_util_encode_jpeg_to_memory( + ffi.Pointer image_buffer, + int width, + int height, + int colorspace, + int quality, + ffi.Pointer> jpeg_buffer, + ffi.Pointer jpeg_size, + ) { + return _image_util_encode_jpeg_to_memory( + image_buffer, + width, + height, + colorspace, + quality, + jpeg_buffer, + jpeg_size, + ); + } + + late final _image_util_encode_jpeg_to_memory_ptr = + _lookup>( + 'image_util_encode_jpeg_to_memory'); + late final _dart_image_util_encode_jpeg_to_memory + _image_util_encode_jpeg_to_memory = _image_util_encode_jpeg_to_memory_ptr + .asFunction<_dart_image_util_encode_jpeg_to_memory>(); + + /// @brief Calculates the size of the image buffer for the specified resolution and colorspace. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] width The image width + /// @param[in] height The image height + /// @param[in] colorspace The image colorspace + /// @param[out] size The Calculated buffer size + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see image_util_transform_run() + /// @see image_util_decode_jpeg() + /// @see image_util_decode_jpeg_from_memory() + /// @see image_util_encode_jpeg() + /// @see image_util_encode_jpeg_to_memory() + int image_util_calculate_buffer_size( + int width, + int height, + int colorspace, + ffi.Pointer size, + ) { + return _image_util_calculate_buffer_size( + width, + height, + colorspace, + size, + ); + } + + late final _image_util_calculate_buffer_size_ptr = + _lookup>( + 'image_util_calculate_buffer_size'); + late final _dart_image_util_calculate_buffer_size + _image_util_calculate_buffer_size = _image_util_calculate_buffer_size_ptr + .asFunction<_dart_image_util_calculate_buffer_size>(); + + /// @brief Extracts representative color from an image buffer + /// @since_tizen 3.0 + /// @remarks @a image_buffer should be RGB888 colorspace. + /// + /// @param[in] image_buffer The original image buffer + /// @param[in] width The image width + /// @param[in] height The image height + /// @param[out] rgb_r The red color in RGB color space + /// @param[out] rgb_g The green color in RGB color space + /// @param[out] rgb_b The blue color in RGB color space + /// + /// @return 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_OUT_OF_MEMORY out of memory + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + int image_util_extract_color_from_memory( + ffi.Pointer image_buffer, + int width, + int height, + ffi.Pointer rgb_r, + ffi.Pointer rgb_g, + ffi.Pointer rgb_b, + ) { + return _image_util_extract_color_from_memory( + image_buffer, + width, + height, + rgb_r, + rgb_g, + rgb_b, + ); + } + + late final _image_util_extract_color_from_memory_ptr = + _lookup>( + 'image_util_extract_color_from_memory'); + late final _dart_image_util_extract_color_from_memory + _image_util_extract_color_from_memory = + _image_util_extract_color_from_memory_ptr + .asFunction<_dart_image_util_extract_color_from_memory>(); + + /// @brief Creates a handle to image util transform. + /// @details This function creates a handle to image util transform. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a handle should be released using image_util_transform_destroy(). + /// + /// @param[out] handle A handle to image util transform + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see image_util_transform_destroy() + int image_util_transform_create( + ffi.Pointer> handle, + ) { + return _image_util_transform_create( + handle, + ); + } + + late final _image_util_transform_create_ptr = + _lookup>( + 'image_util_transform_create'); + late final _dart_image_util_transform_create _image_util_transform_create = + _image_util_transform_create_ptr + .asFunction<_dart_image_util_transform_create>(); + + /// @brief Sets the image util's accurate mode. + /// @details This function set if you use hardware acceleration or not. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// + /// @remarks The value returned will be IMAGE_UTIL_ERROR_NOT_SUPPORTED, if H/W acceleration doesn't support on the device. + /// + /// @param[in] handle The handle to image util + /// @param[in] mode Set @c true, user can use the hardware acceleration\n + /// otherwise set @c false if user can only software image processing + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED The application does not have the hardware acceleration + /// + /// @pre image_util_transform_create(). + /// + /// @see image_util_transform_create() + /// @see image_util_transform_destroy() + int image_util_transform_set_hardware_acceleration( + ffi.Pointer handle, + bool mode, + ) { + return _image_util_transform_set_hardware_acceleration( + handle, + mode ? 1 : 0, + ); + } + + late final _image_util_transform_set_hardware_acceleration_ptr = _lookup< + ffi.NativeFunction< + _c_image_util_transform_set_hardware_acceleration>>( + 'image_util_transform_set_hardware_acceleration'); + late final _dart_image_util_transform_set_hardware_acceleration + _image_util_transform_set_hardware_acceleration = + _image_util_transform_set_hardware_acceleration_ptr + .asFunction<_dart_image_util_transform_set_hardware_acceleration>(); + + /// @brief Sets the information of the converting. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] handle The handle to image util transform + /// @param[in] colorspace The colorspace of the image buffer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Not supported format + /// + /// @pre image_util_transform_create(). + /// + /// @see image_util_transform_create() + /// @see image_util_transform_run() + /// @see image_util_transform_destroy() + int image_util_transform_set_colorspace( + ffi.Pointer handle, + int colorspace, + ) { + return _image_util_transform_set_colorspace( + handle, + colorspace, + ); + } + + late final _image_util_transform_set_colorspace_ptr = + _lookup>( + 'image_util_transform_set_colorspace'); + late final _dart_image_util_transform_set_colorspace + _image_util_transform_set_colorspace = + _image_util_transform_set_colorspace_ptr + .asFunction<_dart_image_util_transform_set_colorspace>(); + + /// @brief Sets the information of the resizing. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks image_util_transform_set_resolution and image_util_transform_set_crop_area can't do that at the same time. + /// + /// @param[in] handle The handle to image util transform + /// @param[in] width The width of image buffer + /// @param[in] height The height of image buffer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_transform_create(). + /// + /// @see image_util_transform_create() + /// @see image_util_transform_run() + /// @see image_util_transform_destroy() + int image_util_transform_set_resolution( + ffi.Pointer handle, + int width, + int height, + ) { + return _image_util_transform_set_resolution( + handle, + width, + height, + ); + } + + late final _image_util_transform_set_resolution_ptr = + _lookup>( + 'image_util_transform_set_resolution'); + late final _dart_image_util_transform_set_resolution + _image_util_transform_set_resolution = + _image_util_transform_set_resolution_ptr + .asFunction<_dart_image_util_transform_set_resolution>(); + + /// @brief Sets the information of the rotating. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] handle The handle to image util transform + /// @param[in] rotation The rotation value of image buffer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_transform_create(). + /// + /// @see image_util_transform_create() + /// @see image_util_transform_run() + /// @see image_util_transform_destroy() + int image_util_transform_set_rotation( + ffi.Pointer handle, + int rotation, + ) { + return _image_util_transform_set_rotation( + handle, + rotation, + ); + } + + late final _image_util_transform_set_rotation_ptr = + _lookup>( + 'image_util_transform_set_rotation'); + late final _dart_image_util_transform_set_rotation + _image_util_transform_set_rotation = + _image_util_transform_set_rotation_ptr + .asFunction<_dart_image_util_transform_set_rotation>(); + + /// @brief Sets the information of the cropping. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks image_util_transform_set_resolution and image_util_transform_set_crop_area can't do that at the same time. + /// + /// @param[in] handle The handle to image util transform + /// @param[in] start_x The start x position of cropped image buffer + /// @param[in] start_y The start y position of cropped image buffer + /// @param[in] end_x The end x position of cropped image buffer + /// @param[in] end_y The end y position of cropped image buffer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_transform_create(). + /// + /// @see image_util_transform_create() + /// @see image_util_transform_run() + /// @see image_util_transform_destroy() + int image_util_transform_set_crop_area( + ffi.Pointer handle, + int start_x, + int start_y, + int end_x, + int end_y, + ) { + return _image_util_transform_set_crop_area( + handle, + start_x, + start_y, + end_x, + end_y, + ); + } + + late final _image_util_transform_set_crop_area_ptr = + _lookup>( + 'image_util_transform_set_crop_area'); + late final _dart_image_util_transform_set_crop_area + _image_util_transform_set_crop_area = + _image_util_transform_set_crop_area_ptr + .asFunction<_dart_image_util_transform_set_crop_area>(); + + /// @brief Gets the colorspace of the image buffer. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] handle The handle to image util transform + /// @param[in,out] colorspace The colorspace of the image buffer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// @retval #IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT Not supported format + /// + /// @pre image_util_transform_create().\n + /// image_util_transform_set_crop_area(). + /// + /// @see image_util_transform_create() + /// @see image_util_transform_destroy() + int image_util_transform_get_colorspace( + ffi.Pointer handle, + ffi.Pointer colorspace, + ) { + return _image_util_transform_get_colorspace( + handle, + colorspace, + ); + } + + late final _image_util_transform_get_colorspace_ptr = + _lookup>( + 'image_util_transform_get_colorspace'); + late final _dart_image_util_transform_get_colorspace + _image_util_transform_get_colorspace = + _image_util_transform_get_colorspace_ptr + .asFunction<_dart_image_util_transform_get_colorspace>(); + + /// @brief Gets the resolution of the image buffer. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] handle The handle to image util transform + /// @param[in,out] width The width of source image buffer + /// @param[in,out] height The height of source image buffer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_transform_create().\n + /// image_util_transform_set_resolution(). + /// + /// @see image_util_transform_create() + /// @see image_util_transform_destroy() + int image_util_transform_get_resolution( + ffi.Pointer handle, + ffi.Pointer width, + ffi.Pointer height, + ) { + return _image_util_transform_get_resolution( + handle, + width, + height, + ); + } + + late final _image_util_transform_get_resolution_ptr = + _lookup>( + 'image_util_transform_get_resolution'); + late final _dart_image_util_transform_get_resolution + _image_util_transform_get_resolution = + _image_util_transform_get_resolution_ptr + .asFunction<_dart_image_util_transform_get_resolution>(); + + /// @brief Gets the information of the rotating. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] handle The handle to image util transform + /// @param[in,out] rotation The rotation value of image buffer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_transform_create().\n + /// image_util_transform_set_rotation(). + /// + /// @see image_util_transform_create() + /// @see image_util_transform_destroy() + int image_util_transform_get_rotation( + ffi.Pointer handle, + ffi.Pointer rotation, + ) { + return _image_util_transform_get_rotation( + handle, + rotation, + ); + } + + late final _image_util_transform_get_rotation_ptr = + _lookup>( + 'image_util_transform_get_rotation'); + late final _dart_image_util_transform_get_rotation + _image_util_transform_get_rotation = + _image_util_transform_get_rotation_ptr + .asFunction<_dart_image_util_transform_get_rotation>(); + + /// @brief Gets the information of the cropping. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] handle The handle to image util transform + /// @param[in,out] start_x The start x position of cropped source image buffer + /// @param[in,out] start_y The start y position of cropped source image buffer + /// @param[in,out] end_x The end x position of cropped source image buffer + /// @param[in,out] end_y The end y position of cropped source image buffer + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre image_util_transform_create().\n + /// image_util_transform_set_crop_area(). + /// + /// @see image_util_transform_create() + /// @see image_util_transform_destroy() + int image_util_transform_get_crop_area( + ffi.Pointer handle, + ffi.Pointer start_x, + ffi.Pointer start_y, + ffi.Pointer end_x, + ffi.Pointer end_y, + ) { + return _image_util_transform_get_crop_area( + handle, + start_x, + start_y, + end_x, + end_y, + ); + } + + late final _image_util_transform_get_crop_area_ptr = + _lookup>( + 'image_util_transform_get_crop_area'); + late final _dart_image_util_transform_get_crop_area + _image_util_transform_get_crop_area = + _image_util_transform_get_crop_area_ptr + .asFunction<_dart_image_util_transform_get_crop_area>(); + + /// @brief Transforms the image for given image util handle. + /// @details The function execute asynchronously, which contains complete callback \n + /// If you set more than two transforming, the order of running is crop or resolution, colorspace converting, rotation. \n + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks If H/W acceleration is not set, transformation is done via S/W acceleration. + /// + /// @param[in] handle The handle of transform + /// @param[in] src The handle to image util transform + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IMAGE_UTIL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see image_util_transform_create() + /// @see image_util_transform_set_hardware_acceleration + /// @see image_util_transform_destroy() + int image_util_transform_run( + ffi.Pointer handle, + ffi.Pointer src, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _image_util_transform_run( + handle, + src, + callback, + user_data, + ); + } + + late final _image_util_transform_run_ptr = + _lookup>( + 'image_util_transform_run'); + late final _dart_image_util_transform_run _image_util_transform_run = + _image_util_transform_run_ptr + .asFunction<_dart_image_util_transform_run>(); + + /// @brief Destroys a handle to image util. + /// @details The function frees all resources related to the image util handle. The image util + /// handle no longer can be used to perform any operation. A new image util handle + /// has to be created before the next usage. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] handle The handle to image util transform + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see image_util_transform_create() + int image_util_transform_destroy( + ffi.Pointer handle, + ) { + return _image_util_transform_destroy( + handle, + ); + } + + late final _image_util_transform_destroy_ptr = + _lookup>( + 'image_util_transform_destroy'); + late final _dart_image_util_transform_destroy _image_util_transform_destroy = + _image_util_transform_destroy_ptr + .asFunction<_dart_image_util_transform_destroy>(); + + /// @deprecated Deprecated since 3.0. Use image_util_foreach_supported_colorspace() instead. + /// @brief Retrieves all supported JPEG encoding/decoding colorspace by invoking a callback function once for each one. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @post This function invokes image_util_supported_jpeg_colorspace_cb() repeatedly to retrieve each supported JPEG encoding/decoding colorspace. + /// + /// @see image_util_supported_jpeg_colorspace_cb() + /// @see image_util_encode_jpeg() + /// @see image_util_encode_jpeg_to_memory() + /// @see image_util_decode_jpeg() + /// @see image_util_decode_jpeg_from_memory() + int image_util_foreach_supported_jpeg_colorspace( + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _image_util_foreach_supported_jpeg_colorspace( + callback, + user_data, + ); + } + + late final _image_util_foreach_supported_jpeg_colorspace_ptr = _lookup< + ffi.NativeFunction<_c_image_util_foreach_supported_jpeg_colorspace>>( + 'image_util_foreach_supported_jpeg_colorspace'); + late final _dart_image_util_foreach_supported_jpeg_colorspace + _image_util_foreach_supported_jpeg_colorspace = + _image_util_foreach_supported_jpeg_colorspace_ptr + .asFunction<_dart_image_util_foreach_supported_jpeg_colorspace>(); + + /// @brief Retrieves all supported image encoding/decoding colorspace by invoking a callback function once for each one. + /// @since_tizen 3.0 + /// + /// @param[in] image_type The type of supported image for which to create encode/decode handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, + /// otherwise a negative error value + /// + /// @retval #IMAGE_UTIL_ERROR_NONE Successful + /// @retval #IMAGE_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @post This function invokes image_util_supported_colorspace_cb() repeatedly to retrieve each supported image encoding/decoding colorspace. + /// + /// @see image_util_supported_colorspace_cb() + /// @see image_util_encode_create() + /// @see image_util_decode_create() + int image_util_foreach_supported_colorspace( + int image_type, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _image_util_foreach_supported_colorspace( + image_type, + callback, + user_data, + ); + } + + late final _image_util_foreach_supported_colorspace_ptr = + _lookup>( + 'image_util_foreach_supported_colorspace'); + late final _dart_image_util_foreach_supported_colorspace + _image_util_foreach_supported_colorspace = + _image_util_foreach_supported_colorspace_ptr + .asFunction<_dart_image_util_foreach_supported_colorspace>(); + + /// @brief Creates a media packet pool to handle the media packets. + /// @details It creates a media packet pool instance + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a pool must be released by using packet_pool_destroy(). + /// @param[out] pool The media packet pool handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_OUT_OF_MEMORY Out of memory + int media_packet_pool_create( + ffi.Pointer> pool, + ) { + return _media_packet_pool_create( + pool, + ); + } + + late final _media_packet_pool_create_ptr = + _lookup>( + 'media_packet_pool_create'); + late final _dart_media_packet_pool_create _media_packet_pool_create = + _media_packet_pool_create_ptr + .asFunction<_dart_media_packet_pool_create>(); + + /// @brief Sets the media format for the media packet pool. + /// + /// @since_tizen 3.0 + /// + /// @param[in] pool The media packet pool handle + /// @param[in] fmt The #media_format_h allocated by the caller + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre Must have media_format_h instance by media_format_create(). + /// @post Must do media_format_unref(). + int media_packet_pool_set_media_format( + ffi.Pointer pool, + ffi.Pointer fmt, + ) { + return _media_packet_pool_set_media_format( + pool, + fmt, + ); + } + + late final _media_packet_pool_set_media_format_ptr = + _lookup>( + 'media_packet_pool_set_media_format'); + late final _dart_media_packet_pool_set_media_format + _media_packet_pool_set_media_format = + _media_packet_pool_set_media_format_ptr + .asFunction<_dart_media_packet_pool_set_media_format>(); + + /// @brief Sets the media packet pool size. + /// @details Sets the number of packets to allocate with given parameters. + /// The media packet pool will be allocated with @a min_buffers when media_packet_pool_allocate() is called. + /// When there are no media packets available, it will be increased to @a max_buffers of given parameter. + /// + /// @since_tizen 3.0 + /// + /// @param[in] pool The allocated pool handle + /// @param[in] min_buffers The minimum number of buffers to allocate + /// @param[in] max_buffers The maximum number of buffers to allocate + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_OUT_OF_MEMORY Out of memory + /// @post After the pool has been configured, it can be allocated with media_packet_pool_allocate(). + /// @see media_packet_pool_get_size() + int media_packet_pool_set_size( + ffi.Pointer pool, + int min_buffers, + int max_buffers, + ) { + return _media_packet_pool_set_size( + pool, + min_buffers, + max_buffers, + ); + } + + late final _media_packet_pool_set_size_ptr = + _lookup>( + 'media_packet_pool_set_size'); + late final _dart_media_packet_pool_set_size _media_packet_pool_set_size = + _media_packet_pool_set_size_ptr + .asFunction<_dart_media_packet_pool_set_size>(); + + /// @brief Gets the media packet pool size. + /// @details Gets the configuration values from the pool. + /// + /// @since_tizen 3.0 + /// + /// @param[in] pool The allocated pool handle + /// @param[out] min_buffers The minimum number of buffers to allocate + /// @param[out] max_buffers The maximum number of buffers to allocate + /// @param[out] curr_buffers The current number of allocated buffers + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @post After the pool has been configured, it can be allocated with media_packet_pool_allocate(). + /// @see media_packet_pool_set_size() + int media_packet_pool_get_size( + ffi.Pointer pool, + ffi.Pointer min_buffers, + ffi.Pointer max_buffers, + ffi.Pointer curr_buffers, + ) { + return _media_packet_pool_get_size( + pool, + min_buffers, + max_buffers, + curr_buffers, + ); + } + + late final _media_packet_pool_get_size_ptr = + _lookup>( + 'media_packet_pool_get_size'); + late final _dart_media_packet_pool_get_size _media_packet_pool_get_size = + _media_packet_pool_get_size_ptr + .asFunction<_dart_media_packet_pool_get_size>(); + + /// @brief Allocates the media packet pool. + /// @details It will allocate media packets with @a min_buffers which given to media_packet_pool_set_size(). + /// + /// @since_tizen 3.0 + /// + /// @param[in] pool The allocated pool handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION The user set the invalid format with media_packet_pool_set_format() or set the invalid size with media_packet_pool_set_size().\n + /// The user already allocate the pool. + /// @pre media_packet_pool_set_media_format() and media_pool_set_size() should be called before calling media_packet_pool_allocate() + /// @post The pool will be allocated. When the pool is allocated, media_packet_pool_acquire_packet() can be used to retrieve a packet from the pool. + /// @see media_packet_pool_set_media_format() + /// @see media_packet_pool_set_size() + int media_packet_pool_allocate( + ffi.Pointer pool, + ) { + return _media_packet_pool_allocate( + pool, + ); + } + + late final _media_packet_pool_allocate_ptr = + _lookup>( + 'media_packet_pool_allocate'); + late final _dart_media_packet_pool_allocate _media_packet_pool_allocate = + _media_packet_pool_allocate_ptr + .asFunction<_dart_media_packet_pool_allocate>(); + + /// @brief Acquires a media packet from the media packet pool. + /// @details It will take a media packet from the queue and block until media packet is released into the pool again. + /// When there are no media packets available, it will be increased to @a max_buffers of given parameter. + /// + /// @since_tizen 3.0 + /// + /// @param[in] pool The media packet pool handle + /// @param[out] pkt The media packet handle + /// @param[in] timeout It indicates the millisecond-timeouts to block + /// while waiting for one of acquired packet to be released. + /// If the value of timeout is -1, the pool blocks indefinitely until media packet into the pool. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION The user does not allocate the pool.\n + /// The pool should be allocated with media_packet_pool_allocate() before acquiring media packet from the pool. + /// @retval #MEDIA_PACKET_ERROR_NO_AVAILABLE_PACKET No available packet + /// @see media_pakcet_pool_set_size() + /// @see media_packet_pool_release_packet() + int media_packet_pool_acquire_packet( + ffi.Pointer pool, + ffi.Pointer> pkt, + int timeout, + ) { + return _media_packet_pool_acquire_packet( + pool, + pkt, + timeout, + ); + } + + late final _media_packet_pool_acquire_packet_ptr = + _lookup>( + 'media_packet_pool_acquire_packet'); + late final _dart_media_packet_pool_acquire_packet + _media_packet_pool_acquire_packet = _media_packet_pool_acquire_packet_ptr + .asFunction<_dart_media_packet_pool_acquire_packet>(); + + /// @brief Releases the media packet to pool. + /// @details Rlease a packet back in the pool. It will put the packet back in the queue. + /// + /// @since_tizen 3.0 + /// + /// @param[in] pool The media packet pool handle + /// @param[in] pkt The packet to release, the pkt should have previously been acquired from the pool with media_packet_pool_acquire_packet() + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION The user releases media packet which is not associated with a given pool. + /// @see media_packet_pool_acquire_packet() + int media_packet_pool_release_packet( + ffi.Pointer pool, + ffi.Pointer pkt, + ) { + return _media_packet_pool_release_packet( + pool, + pkt, + ); + } + + late final _media_packet_pool_release_packet_ptr = + _lookup>( + 'media_packet_pool_release_packet'); + late final _dart_media_packet_pool_release_packet + _media_packet_pool_release_packet = _media_packet_pool_release_packet_ptr + .asFunction<_dart_media_packet_pool_release_packet>(); + + /// @brief Deallocates all the media packets. + /// @details Deallocates the packets allocated with media_packet_pool_allocate(). + /// + /// @since_tizen 3.0 + /// + /// @param[in] pool The media packet pool handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION The user does not release all media packets to the pool. + /// + /// @pre media packet should be released before calling media_packet_pool_deallocate(). + /// @post The pool will be deallocated. media_packet_pool_acquire_packet() calls will return an error. + /// @see media_packet_pool_allocate() + int media_packet_pool_deallocate( + ffi.Pointer pool, + ) { + return _media_packet_pool_deallocate( + pool, + ); + } + + late final _media_packet_pool_deallocate_ptr = + _lookup>( + 'media_packet_pool_deallocate'); + late final _dart_media_packet_pool_deallocate _media_packet_pool_deallocate = + _media_packet_pool_deallocate_ptr + .asFunction<_dart_media_packet_pool_deallocate>(); + + /// @brief Destroys the media packet pool. + /// @details Destroys the media packet pool handle and releases all its resources. + /// + /// @since_tizen 3.0 + /// + /// @param[in] pool The handle to media packet pool to be destroyed + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_PACKET_ERROR_NONE Successful + /// @retval #MEDIA_PACKET_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_PACKET_ERROR_INVALID_OPERATION The user does not create media packet pool instance, or not deallocate all media packets with media_packet_pool_deallocate(). + /// + /// @see media_packet_pool_create() + int media_packet_pool_destroy( + ffi.Pointer pool, + ) { + return _media_packet_pool_destroy( + pool, + ); + } + + late final _media_packet_pool_destroy_ptr = + _lookup>( + 'media_packet_pool_destroy'); + late final _dart_media_packet_pool_destroy _media_packet_pool_destroy = + _media_packet_pool_destroy_ptr + .asFunction<_dart_media_packet_pool_destroy>(); + + /// @brief Creates a mediacodec handle for decoding/encoding + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks you must release @a mediacodec using mediacodec_destroy().\n + /// Although you can create multiple mediacodec handles at the same time, + /// the mediacodec cannot guarantee proper operation because of limited resources, like + /// audio or display device. + /// + /// @param[out] mediacodec A new handle to mediacodec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIACODEC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + int mediacodec_create( + ffi.Pointer> mediacodec, + ) { + return _mediacodec_create( + mediacodec, + ); + } + + late final _mediacodec_create_ptr = + _lookup>('mediacodec_create'); + late final _dart_mediacodec_create _mediacodec_create = + _mediacodec_create_ptr.asFunction<_dart_mediacodec_create>(); + + /// @brief Destroys the mediacodec handle and releases all its resources. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks To completely shutdown the mediacodec operation, call this function with a valid player handle from any + /// mediacodec + /// + /// @param[in] mediacodec The handle to mediacodec to be destroyed. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIACODEC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + int mediacodec_destroy( + ffi.Pointer mediacodec, + ) { + return _mediacodec_destroy( + mediacodec, + ); + } + + late final _mediacodec_destroy_ptr = + _lookup>('mediacodec_destroy'); + late final _dart_mediacodec_destroy _mediacodec_destroy = + _mediacodec_destroy_ptr.asFunction<_dart_mediacodec_destroy>(); + + /// @brief Sets the codec type and decoder/encoder. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If this codec is to be used as a decoder, pass the #MEDIACODEC_DECODER flag. + /// If this codec is to be used as an encoder, pass the #MEDIACODEC_ENCODER flag.\n + /// The software codec is used as default setting(#MEDIACODEC_SUPPORT_TYPE_SW) if user doesn't set hardware flag. + /// If user wants to use h/w decoder, user needs to pass the #MEDIACODEC_DECODER | #MEDIACODEC_SUPPORT_TYPE_HW. + /// @param[in] mediacodec The handle of mediacodec + /// @param[in] codec_type The identifier of the codec type of the decoder/encoder + /// @param[in] flags The encoding/decoding scheme, defined by #mediacodec_support_type_e + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIACODEC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIACODEC_ERROR_CODEC_NOT_FOUND Codec not found + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + int mediacodec_set_codec( + ffi.Pointer mediacodec, + int codec_type, + int flags, + ) { + return _mediacodec_set_codec( + mediacodec, + codec_type, + flags, + ); + } + + late final _mediacodec_set_codec_ptr = + _lookup>( + 'mediacodec_set_codec'); + late final _dart_mediacodec_set_codec _mediacodec_set_codec = + _mediacodec_set_codec_ptr.asFunction<_dart_mediacodec_set_codec>(); + + /// @brief Sets the default info for the video decoder + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @param[in] width The width for video decoding. + /// @param[in] height The height for video decoding. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIACODEC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + int mediacodec_set_vdec_info( + ffi.Pointer mediacodec, + int width, + int height, + ) { + return _mediacodec_set_vdec_info( + mediacodec, + width, + height, + ); + } + + late final _mediacodec_set_vdec_info_ptr = + _lookup>( + 'mediacodec_set_vdec_info'); + late final _dart_mediacodec_set_vdec_info _mediacodec_set_vdec_info = + _mediacodec_set_vdec_info_ptr + .asFunction<_dart_mediacodec_set_vdec_info>(); + + /// @brief Sets the default info for the video encoder + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The frame rate is the speed of recording and the speed of playback. + /// If user wants the default setting for ratecontrol, set @a target_bits to @c 0. + /// @param[in] mediacodec The handle to mediacodec + /// @param[in] width The width for video encoding. + /// @param[in] height The height for video encoding. + /// @param[in] fps The frame rate in frames per second. + /// @param[in] target_bits The target bitrates in bits per second.(a unit of kbit) + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIACODEC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + int mediacodec_set_venc_info( + ffi.Pointer mediacodec, + int width, + int height, + int fps, + int target_bits, + ) { + return _mediacodec_set_venc_info( + mediacodec, + width, + height, + fps, + target_bits, + ); + } + + late final _mediacodec_set_venc_info_ptr = + _lookup>( + 'mediacodec_set_venc_info'); + late final _dart_mediacodec_set_venc_info _mediacodec_set_venc_info = + _mediacodec_set_venc_info_ptr + .asFunction<_dart_mediacodec_set_venc_info>(); + + /// @brief Sets the default info for the audio decoder + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @param[in] samplerate The samplerate for audio decoding. + /// @param[in] channel The channels for audio decoding. + /// @param[in] bit The bits resolution for audio decoding. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIACODEC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + int mediacodec_set_adec_info( + ffi.Pointer mediacodec, + int samplerate, + int channel, + int bit, + ) { + return _mediacodec_set_adec_info( + mediacodec, + samplerate, + channel, + bit, + ); + } + + late final _mediacodec_set_adec_info_ptr = + _lookup>( + 'mediacodec_set_adec_info'); + late final _dart_mediacodec_set_adec_info _mediacodec_set_adec_info = + _mediacodec_set_adec_info_ptr + .asFunction<_dart_mediacodec_set_adec_info>(); + + /// @brief Sets the default info for the audio encoder + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @param[in] samplerate The samplerate for audio encoding. + /// @param[in] channel The channels for audio encoding. + /// @param[in] bit The bits resolution for audio encoding. + /// @param[in] bitrate The bitrate for audio encoding. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIACODEC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + int mediacodec_set_aenc_info( + ffi.Pointer mediacodec, + int samplerate, + int channel, + int bit, + int bitrate, + ) { + return _mediacodec_set_aenc_info( + mediacodec, + samplerate, + channel, + bit, + bitrate, + ); + } + + late final _mediacodec_set_aenc_info_ptr = + _lookup>( + 'mediacodec_set_aenc_info'); + late final _dart_mediacodec_set_aenc_info _mediacodec_set_aenc_info = + _mediacodec_set_aenc_info_ptr + .asFunction<_dart_mediacodec_set_aenc_info>(); + + /// @brief Sets the codec type and codec default info via media format. + /// @details Sets the value via media format instead of mediacodec_set_codec(), mediacodec_set_venc_info(), + /// mediacodec_set_vdec_info(), mediacodec_set_aenc_info(), and mediacodec_set_adec_info(). + /// @since_tizen 4.0 + /// @remarks When using the @a format parameter from the output of the media demuxer, you can use media format via media_packet_get_format(). + /// Otherwise, you must set the following values after creating media format. + /// Set the audio or video codec type via media_format_set_video_mime() or media_format_set_audio_mime(). + /// For video decoding, width, height must be set via media_format_set_video_width() and media_format_set_video_height(). + /// For video encoding, width, height, target bitrate, and frame rate must be set via media_format_set_video_avg_bps() and media_format_set_video_frame_rate(). + /// For audio decoding, samplerate, channel, and bit must be set via media_format_set_audio_samplerate(), media_format_set_audio_channel() and media_format_set_audio_bit(). + /// For audio encoding, samplerate, channel, bit, and bitrate must be set via media_format_set_audio_avg_bps().\n + /// If this codec is to be used as a decoder, pass the #MEDIACODEC_DECODER flag. + /// If this codec is to be used as an encoder, pass the #MEDIACODEC_ENCODER flag.\n + /// The software codec is used as default setting (#MEDIACODEC_SUPPORT_TYPE_SW) if user doesn't set hardware flag. + /// If you wants to use h/w decoder, you needs to pass the #MEDIACODEC_DECODER | #MEDIACODEC_SUPPORT_TYPE_HW. + /// @param[in] mediacodec The mediacodec handle + /// @param[in] format The #media_format_h of input data + /// @param[in] flags The encoding/decoding scheme, + /// values of #mediacodec_support_type_e combined with bitwise 'or' + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_CODEC_NOT_FOUND Unsupported codec + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + /// @pre The media format has been created and the required values for configuration have been set. + /// @see media_format_set_video_mime() + /// @see media_format_set_audio_mime() + /// @see media_format_set_video_width() + /// @see media_format_set_video_height() + /// @see media_format_set_video_avg_bps() + /// @see media_format_set_video_frame_rate() + /// @see media_format_set_audio_channel() + /// @see media_format_set_audio_samplerate() + /// @see media_format_set_audio_bit() + /// @see media_format_set_audio_avg_bps() + int mediacodec_configure_from_media_format( + ffi.Pointer mediacodec, + ffi.Pointer format, + int flags, + ) { + return _mediacodec_configure_from_media_format( + mediacodec, + format, + flags, + ); + } + + late final _mediacodec_configure_from_media_format_ptr = + _lookup>( + 'mediacodec_configure_from_media_format'); + late final _dart_mediacodec_configure_from_media_format + _mediacodec_configure_from_media_format = + _mediacodec_configure_from_media_format_ptr + .asFunction<_dart_mediacodec_configure_from_media_format>(); + + /// @brief Prepares @a mediacodec for encoding/decoding. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIACODEC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + /// @pre The mediacodec should call mediacodec_set_codec()and mediacodec_set_vdec_info()/mediacodec_set_venc_info() before calling mediacodec_prepare() + /// If the decoder is set by mediacodec_set_codec(), mediacodec_set_vdec_info() should be called. If the encoder is set by + /// mediacodec_set_codec(), mediacodec_set_venc_info() should be called. + int mediacodec_prepare( + ffi.Pointer mediacodec, + ) { + return _mediacodec_prepare( + mediacodec, + ); + } + + late final _mediacodec_prepare_ptr = + _lookup>('mediacodec_prepare'); + late final _dart_mediacodec_prepare _mediacodec_prepare = + _mediacodec_prepare_ptr.asFunction<_dart_mediacodec_prepare>(); + + /// @brief Unprepares @a mediacodec for encoding/decoding. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIACODEC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + int mediacodec_unprepare( + ffi.Pointer mediacodec, + ) { + return _mediacodec_unprepare( + mediacodec, + ); + } + + late final _mediacodec_unprepare_ptr = + _lookup>( + 'mediacodec_unprepare'); + late final _dart_mediacodec_unprepare _mediacodec_unprepare = + _mediacodec_unprepare_ptr.asFunction<_dart_mediacodec_unprepare>(); + + /// @brief Decodes/Encodes a packet. The function passed undecoded/unencoded packet to the input queue and decode/encode a + /// frame sequentially. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @param[in] inbuf The current input format for the decoder/encoder + /// @param[in] timeOutUs The timeout in microseconds. \n + /// The input buffer wait up to "timeOutUs" microseconds. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIACODEC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIACODEC_ERROR_OVERFLOW_INBUFFER Overflow inputbuffer + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + int mediacodec_process_input( + ffi.Pointer mediacodec, + ffi.Pointer inbuf, + int timeOutUs, + ) { + return _mediacodec_process_input( + mediacodec, + inbuf, + timeOutUs, + ); + } + + late final _mediacodec_process_input_ptr = + _lookup>( + 'mediacodec_process_input'); + late final _dart_mediacodec_process_input _mediacodec_process_input = + _mediacodec_process_input_ptr + .asFunction<_dart_mediacodec_process_input>(); + + /// @brief Gets the decoded or encoded packet from the output queue. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @param[out] outbuf The current output of the decoder/encoder. + /// this function passed decoded/encoded frame to output queue. + /// @param[in] timeOutUs The timeout in microseconds. \n + /// The input buffer wait up to "timeOutUs" microseconds. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIACODEC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + int mediacodec_get_output( + ffi.Pointer mediacodec, + ffi.Pointer> outbuf, + int timeOutUs, + ) { + return _mediacodec_get_output( + mediacodec, + outbuf, + timeOutUs, + ); + } + + late final _mediacodec_get_output_ptr = + _lookup>( + 'mediacodec_get_output'); + late final _dart_mediacodec_get_output _mediacodec_get_output = + _mediacodec_get_output_ptr.asFunction<_dart_mediacodec_get_output>(); + + /// @brief Flushes both input and output buffers. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + int mediacodec_flush_buffers( + ffi.Pointer mediacodec, + ) { + return _mediacodec_flush_buffers( + mediacodec, + ); + } + + late final _mediacodec_flush_buffers_ptr = + _lookup>( + 'mediacodec_flush_buffers'); + late final _dart_mediacodec_flush_buffers _mediacodec_flush_buffers = + _mediacodec_flush_buffers_ptr + .asFunction<_dart_mediacodec_flush_buffers>(); + + /// @brief set empty buffer callback the media codec for process, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + /// @pre mediacodec_set_input_buffer_used_cb should be called before mediacodec_preare(). + /// @post mediacodec_input_buffer_used_cb will be invoked. + /// @see mediacodec_set_input_buffer_used_cb() + /// @see mediacodec_unset_input_buffer_used_cb() + int mediacodec_set_input_buffer_used_cb( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mediacodec_set_input_buffer_used_cb( + mediacodec, + callback, + user_data, + ); + } + + late final _mediacodec_set_input_buffer_used_cb_ptr = + _lookup>( + 'mediacodec_set_input_buffer_used_cb'); + late final _dart_mediacodec_set_input_buffer_used_cb + _mediacodec_set_input_buffer_used_cb = + _mediacodec_set_input_buffer_used_cb_ptr + .asFunction<_dart_mediacodec_set_input_buffer_used_cb>(); + + /// @brief unset input buffer used callback the media codec for process, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + /// @see mediacodec_set_input_buffer_used_cb() + int mediacodec_unset_input_buffer_used_cb( + ffi.Pointer mediacodec, + ) { + return _mediacodec_unset_input_buffer_used_cb( + mediacodec, + ); + } + + late final _mediacodec_unset_input_buffer_used_cb_ptr = + _lookup>( + 'mediacodec_unset_input_buffer_used_cb'); + late final _dart_mediacodec_unset_input_buffer_used_cb + _mediacodec_unset_input_buffer_used_cb = + _mediacodec_unset_input_buffer_used_cb_ptr + .asFunction<_dart_mediacodec_unset_input_buffer_used_cb>(); + + /// @brief set output buffer available callback the media codec for process, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + /// @pre mediacodec_set_output_buffer_available_cb should be called before mediacodec_preare(). + /// @post mediacodec_output_buffer_available_cb will be invoked. + /// @see mediacodec_set_output_buffer_available_cb() + /// @see mediacodec_unset_output_buffer_available_cb() + int mediacodec_set_output_buffer_available_cb( + ffi.Pointer mediacodec, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _mediacodec_set_output_buffer_available_cb( + mediacodec, + callback, + user_data, + ); + } + + late final _mediacodec_set_output_buffer_available_cb_ptr = + _lookup>( + 'mediacodec_set_output_buffer_available_cb'); + late final _dart_mediacodec_set_output_buffer_available_cb + _mediacodec_set_output_buffer_available_cb = + _mediacodec_set_output_buffer_available_cb_ptr + .asFunction<_dart_mediacodec_set_output_buffer_available_cb>(); + + /// @brief unset output buffer available callback the media codec for process, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + /// @see mediacodec_set_output_buffer_available_cb() + int mediacodec_unset_output_buffer_available_cb( + ffi.Pointer mediacodec, + ) { + return _mediacodec_unset_output_buffer_available_cb( + mediacodec, + ); + } + + late final _mediacodec_unset_output_buffer_available_cb_ptr = _lookup< + ffi.NativeFunction<_c_mediacodec_unset_output_buffer_available_cb>>( + 'mediacodec_unset_output_buffer_available_cb'); + late final _dart_mediacodec_unset_output_buffer_available_cb + _mediacodec_unset_output_buffer_available_cb = + _mediacodec_unset_output_buffer_available_cb_ptr + .asFunction<_dart_mediacodec_unset_output_buffer_available_cb>(); + + /// @brief set error callback the media codec for process, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + /// @pre mediacodec_set_error_cb should be called before mediacodec_preare(). + /// @post mediacodec_error_cb will be invoked. + /// @see mediacodec_set_error_cb() + /// @see mediacodec_unset_error_cb() + int mediacodec_set_error_cb( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mediacodec_set_error_cb( + mediacodec, + callback, + user_data, + ); + } + + late final _mediacodec_set_error_cb_ptr = + _lookup>( + 'mediacodec_set_error_cb'); + late final _dart_mediacodec_set_error_cb _mediacodec_set_error_cb = + _mediacodec_set_error_cb_ptr.asFunction<_dart_mediacodec_set_error_cb>(); + + /// @brief unset error callback the media codec for process, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + /// @see mediacodec_set_error_cb() + int mediacodec_unset_error_cb( + ffi.Pointer mediacodec, + ) { + return _mediacodec_unset_error_cb( + mediacodec, + ); + } + + late final _mediacodec_unset_error_cb_ptr = + _lookup>( + 'mediacodec_unset_error_cb'); + late final _dart_mediacodec_unset_error_cb _mediacodec_unset_error_cb = + _mediacodec_unset_error_cb_ptr + .asFunction<_dart_mediacodec_unset_error_cb>(); + + /// @brief set eos callback the media codec for process, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + /// @pre mediacodec_set_eos_cb should be called before mediacodec_preare(). + /// @post mediacodec_eos_cb will be invoked. + /// @see mediacodec_set_eos_cb() + /// @see mediacodec_unset_eos_cb() + int mediacodec_set_eos_cb( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mediacodec_set_eos_cb( + mediacodec, + callback, + user_data, + ); + } + + late final _mediacodec_set_eos_cb_ptr = + _lookup>( + 'mediacodec_set_eos_cb'); + late final _dart_mediacodec_set_eos_cb _mediacodec_set_eos_cb = + _mediacodec_set_eos_cb_ptr.asFunction<_dart_mediacodec_set_eos_cb>(); + + /// @brief unset eos callback the media codec for process, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + /// @see mediacodec_set_event_handler_cb() + int mediacodec_unset_eos_cb( + ffi.Pointer mediacodec, + ) { + return _mediacodec_unset_eos_cb( + mediacodec, + ); + } + + late final _mediacodec_unset_eos_cb_ptr = + _lookup>( + 'mediacodec_unset_eos_cb'); + late final _dart_mediacodec_unset_eos_cb _mediacodec_unset_eos_cb = + _mediacodec_unset_eos_cb_ptr.asFunction<_dart_mediacodec_unset_eos_cb>(); + + /// @brief Registers a callback function to be invoked when the mediacodec needs more data or has enough data. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + /// @pre mediacodec_set_buffer_status_cb should be called before mediacodec_preare(). + /// @post mediacodec_buffer_status_cb will be invoked. + /// @see mediacodec_set_buffer_status_cb() + /// @see mediacodec_unset_buffer_status_cb() + int mediacodec_set_buffer_status_cb( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mediacodec_set_buffer_status_cb( + mediacodec, + callback, + user_data, + ); + } + + late final _mediacodec_set_buffer_status_cb_ptr = + _lookup>( + 'mediacodec_set_buffer_status_cb'); + late final _dart_mediacodec_set_buffer_status_cb + _mediacodec_set_buffer_status_cb = _mediacodec_set_buffer_status_cb_ptr + .asFunction<_dart_mediacodec_set_buffer_status_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + int mediacodec_unset_buffer_status_cb( + ffi.Pointer mediacodec, + ) { + return _mediacodec_unset_buffer_status_cb( + mediacodec, + ); + } + + late final _mediacodec_unset_buffer_status_cb_ptr = + _lookup>( + 'mediacodec_unset_buffer_status_cb'); + late final _dart_mediacodec_unset_buffer_status_cb + _mediacodec_unset_buffer_status_cb = + _mediacodec_unset_buffer_status_cb_ptr + .asFunction<_dart_mediacodec_unset_buffer_status_cb>(); + + /// @brief Retrieves all supported codecs by invoking callback function once for each supported codecs. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + /// @see mediacodec_foreach_supported_codec() + int mediacodec_foreach_supported_codec( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mediacodec_foreach_supported_codec( + mediacodec, + callback, + user_data, + ); + } + + late final _mediacodec_foreach_supported_codec_ptr = + _lookup>( + 'mediacodec_foreach_supported_codec'); + late final _dart_mediacodec_foreach_supported_codec + _mediacodec_foreach_supported_codec = + _mediacodec_foreach_supported_codec_ptr + .asFunction<_dart_mediacodec_foreach_supported_codec>(); + + /// @brief Verifies whether encoding can be performed with codec_type or not. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] mediacodec The handle to mediacodec + /// @param[in] codec_type The identifier of the codec type of the encoder. + /// @param[in] encoder Whether the encoder or decoder : (@c true = encoder, @c false = decoder). + /// @param[out] support_type (@c MEDIACODEC_SUPPORT_TYPE_HW = mediacodec can be performed with hardware codec, @c MEDIACODEC_SUPPORT_TYPE_SW = mediacodec can be performed with software codec) + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + /// @code + /// #include + /// mediacodec_h mediacodec; + /// mediacodec_support_type_e type; + /// mediacodec_codec_type_e codec_type = MEDIACODEC_H264; + /// + /// mediacodec_create(&mediacodec); + /// mediacodec_get_supported_type(mediacodec, codec_type, 1, &type); + /// + /// if(type == MEDIACODEC_SUPPORT_TYPE_HW) + /// // only h/w supported + /// else if (type == MEDIACODEC_SUPPORT_TYPE_SW) + /// // only s/w supported + /// else if (type == (MEDIACODEC_SUPPORT_TYPE_HW|MEDIACODEC_SUPPORT_TYPE_SW) + /// // both supported + /// + /// mediacodec_set_codec(mediacodec, codec_type, MEDIACODEC_ENCODER | MEDIACODEC_SUPPORT_TYPE_HW); + /// @endcode + int mediacodec_get_supported_type( + ffi.Pointer mediacodec, + int codec_type, + bool encoder, + ffi.Pointer support_type, + ) { + return _mediacodec_get_supported_type( + mediacodec, + codec_type, + encoder ? 1 : 0, + support_type, + ); + } + + late final _mediacodec_get_supported_type_ptr = + _lookup>( + 'mediacodec_get_supported_type'); + late final _dart_mediacodec_get_supported_type + _mediacodec_get_supported_type = _mediacodec_get_supported_type_ptr + .asFunction<_dart_mediacodec_get_supported_type>(); + + /// @brief Gets the media packet pool allocated for recycling media packets. + /// @details The user can get the pool allocated with the number of packets are required to be used in codecs.\n + /// It is recommended to use media packet pool for better stability and performance. + /// @since_tizen 3.0 + /// @remarks The @a pool should be released using media_packet_pool_deallocate() and destroyed using media_packet_pool_destroy(). + /// @param[in] mediacodec The mediacodec handle + /// @param[out] pool The allocated pool handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIACODEC_ERROR_NONE Successful + /// @retval #MEDIACODEC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIACODEC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIACODEC_ERROR_INVALID_OPERATION The user calls mediacodec_get_packet_pool() before calling mediacodec_prepare(). + /// @retval #MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE Not supported on device (Since 4.0) + /// @pre mediacodec_get_packet_pool() should be called after calling mediacodec_prepare(). + /// @post If the pool is used, media_packet_pool_deallocate() and media_packet_pool_destroy() should be called. + /// @see media_packet_pool_acquire_packet() + /// @see media_packet_pool_release_packet() + /// @see media_packet_pool_deallocate() + /// @see media_packet_pool_destroy() + int mediacodec_get_packet_pool( + ffi.Pointer mediacodec, + ffi.Pointer> pool, + ) { + return _mediacodec_get_packet_pool( + mediacodec, + pool, + ); + } + + late final _mediacodec_get_packet_pool_ptr = + _lookup>( + 'mediacodec_get_packet_pool'); + late final _dart_mediacodec_get_packet_pool _mediacodec_get_packet_pool = + _mediacodec_get_packet_pool_ptr + .asFunction<_dart_mediacodec_get_packet_pool>(); + + /// @MOBILE_ONLY + /// @brief Gets the name of the playlist. + /// @since_tizen 4.0 + /// + /// @remarks The @a playlist_name should be released using free(). + /// + /// @param[in] playlist The handle to the media controller playlist + /// @param[out] playlist_name The name of the playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @pre You can get playlist handle using mc_server_foreach_playlist() if you are media controller server, or mc_client_foreach_server_playlist() if you are media controller client. + /// + /// @see mc_server_foreach_playlist() + /// @see mc_client_foreach_server_playlist() + /// @see mc_playlist_destroy() + int mc_playlist_get_name( + ffi.Pointer playlist, + ffi.Pointer> playlist_name, + ) { + return _mc_playlist_get_name( + playlist, + playlist_name, + ); + } + + late final _mc_playlist_get_name_ptr = + _lookup>( + 'mc_playlist_get_name'); + late final _dart_mc_playlist_get_name _mc_playlist_get_name = + _mc_playlist_get_name_ptr.asFunction<_dart_mc_playlist_get_name>(); + + /// @MOBILE_ONLY + /// @brief Iterates through media items in a playlist. + /// @details This function gets all items in a playlist. + /// The callback function will be invoked for every retrieved playlist item. + /// If there are no items on the playlist, the callback will not be invoked. + /// @since_tizen 4.0 + /// + /// @param[in] playlist The handle to the media controller playlist + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @pre You can get playlist handle using mc_server_foreach_playlist() if you are media controller server, or mc_client_foreach_server_playlist() if you are media controller client. + /// @post This function invokes mc_playlist_item_cb(). + /// + /// @see mc_server_foreach_playlist() + /// @see mc_client_foreach_server_playlist() + /// @see mc_playlist_item_cb() + /// @see mc_playlist_destroy() + int mc_playlist_foreach_item( + ffi.Pointer playlist, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_playlist_foreach_item( + playlist, + callback, + user_data, + ); + } + + late final _mc_playlist_foreach_item_ptr = + _lookup>( + 'mc_playlist_foreach_item'); + late final _dart_mc_playlist_foreach_item _mc_playlist_foreach_item = + _mc_playlist_foreach_item_ptr + .asFunction<_dart_mc_playlist_foreach_item>(); + + /// @MOBILE_ONLY + /// @brief Clones a media controller playlist handle. + /// @details This function copies the media controller playlist handle from a source to + /// destination. The mc_playlist_h is created internally and available through media controller playlist functions. + /// + /// @since_tizen 4.0 + /// + /// @remarks The @a dst should be released using mc_playlist_destroy(). + /// + /// @param[in] src The source handle to the media controller playlist + /// @param[out] dst The destination handle to the media controller playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see mc_playlist_destroy() + int mc_playlist_clone( + ffi.Pointer src, + ffi.Pointer> dst, + ) { + return _mc_playlist_clone( + src, + dst, + ); + } + + late final _mc_playlist_clone_ptr = + _lookup>('mc_playlist_clone'); + late final _dart_mc_playlist_clone _mc_playlist_clone = + _mc_playlist_clone_ptr.asFunction<_dart_mc_playlist_clone>(); + + /// @MOBILE_ONLY + /// @brief Destroys a media controller playlist handle. + /// @details This function frees all resources related to the media controller playlist handle. This + /// handle no longer can be used to perform any operations. A new handle has to + /// be created before next usage. + /// + /// @since_tizen 4.0 + /// + /// @param[in] playlist The handle to the media controller playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see mc_playlist_clone() + int mc_playlist_destroy( + ffi.Pointer playlist, + ) { + return _mc_playlist_destroy( + playlist, + ); + } + + late final _mc_playlist_destroy_ptr = + _lookup>( + 'mc_playlist_destroy'); + late final _dart_mc_playlist_destroy _mc_playlist_destroy = + _mc_playlist_destroy_ptr.asFunction<_dart_mc_playlist_destroy>(); + + /// @MOBILE_ONLY + /// @brief Clones a media controller metadata handle. + /// @details This function copies the media controller metadata handle from a source to + /// destination. The mc_metadata_h is created internally and available through media controller metadata functions. + /// + /// @since_tizen 4.0 + /// + /// @remarks The @a dst should be released using @c mc_metadata_destroy(). + /// + /// @param[in] src The source handle to the media controller metadata + /// @param[out] dst The destination handle to the media controller metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see mc_metadata_destroy() + int mc_metadata_clone( + ffi.Pointer src, + ffi.Pointer> dst, + ) { + return _mc_metadata_clone( + src, + dst, + ); + } + + late final _mc_metadata_clone_ptr = + _lookup>('mc_metadata_clone'); + late final _dart_mc_metadata_clone _mc_metadata_clone = + _mc_metadata_clone_ptr.asFunction<_dart_mc_metadata_clone>(); + + /// @MOBILE_ONLY + /// @brief Destroys a media controller metadata handle. + /// @details This function frees all resources related to the media controller metadata handle. This + /// handle no longer can be used to perform any operations. A new handle has to + /// be created before next usage. + /// + /// @since_tizen 4.0 + /// + /// @param[in] metadata The handle to the media controller metadata + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see mc_metadata_clone() + int mc_metadata_destroy( + ffi.Pointer metadata, + ) { + return _mc_metadata_destroy( + metadata, + ); + } + + late final _mc_metadata_destroy_ptr = + _lookup>( + 'mc_metadata_destroy'); + late final _dart_mc_metadata_destroy _mc_metadata_destroy = + _mc_metadata_destroy_ptr.asFunction<_dart_mc_metadata_destroy>(); + + /// @MOBILE_ONLY + /// @brief Gets the metadata. + /// @since_tizen 4.0 + /// + /// @remarks The @a value should be released using free(). \n + /// If the attribute value of the metadata is empty, return value is NULL. + /// + /// @param[in] metadata The handle to metadata + /// @param[in] attribute The key attribute name to get + /// @param[out] value The value of the attribute + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @pre Sets mc_client_set_metadata_update_cb() function to get the metadata if you are media controller client. \n + /// and also you can use this function when get the metadata when callback function invoked in @c mc_playlist_foreach_item(). + /// + /// @see mc_client_set_metadata_update_cb() + /// @see mc_playlist_foreach_item() + int mc_metadata_get( + ffi.Pointer metadata, + int attribute, + ffi.Pointer> value, + ) { + return _mc_metadata_get( + metadata, + attribute, + value, + ); + } + + late final _mc_metadata_get_ptr = + _lookup>('mc_metadata_get'); + late final _dart_mc_metadata_get _mc_metadata_get = + _mc_metadata_get_ptr.asFunction<_dart_mc_metadata_get>(); + + /// @brief Creates a media controller server. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @remarks The @a server should be released using mc_server_destroy(). You can create only one server handle for each process. + /// + /// @param[out] server The handle to media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @see mc_server_destroy() + int mc_server_create( + ffi.Pointer> server, + ) { + return _mc_server_create( + server, + ); + } + + late final _mc_server_create_ptr = + _lookup>('mc_server_create'); + late final _dart_mc_server_create _mc_server_create = + _mc_server_create_ptr.asFunction<_dart_mc_server_create>(); + + /// @brief Sets the playback state to update the latest state info. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] state The state to set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @post Apply the updated playback information by calling mc_server_update_playback_info(). + /// @see mc_server_create() + /// @see mc_server_destroy() + /// @see mc_server_update_playback_info() + int mc_server_set_playback_state( + ffi.Pointer server, + int state, + ) { + return _mc_server_set_playback_state( + server, + state, + ); + } + + late final _mc_server_set_playback_state_ptr = + _lookup>( + 'mc_server_set_playback_state'); + late final _dart_mc_server_set_playback_state _mc_server_set_playback_state = + _mc_server_set_playback_state_ptr + .asFunction<_dart_mc_server_set_playback_state>(); + + /// @brief Sets the playback position to update the latest playback info. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] position The position to set in milliseconds + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @post Apply the updated playback information by calling mc_server_update_playback_info(). + /// @see mc_server_create() + /// @see mc_server_destroy() + /// @see mc_server_update_playback_info() + int mc_server_set_playback_position( + ffi.Pointer server, + int position, + ) { + return _mc_server_set_playback_position( + server, + position, + ); + } + + late final _mc_server_set_playback_position_ptr = + _lookup>( + 'mc_server_set_playback_position'); + late final _dart_mc_server_set_playback_position + _mc_server_set_playback_position = _mc_server_set_playback_position_ptr + .asFunction<_dart_mc_server_set_playback_position>(); + + /// @MOBILE_ONLY + /// @brief Sets the index of the current playing media in the playlist to update the latest playback info. \n + /// @details If a media controller server has a playlist, the server can register and share it with media controller client. A playlist is a set of "index" and "media metadata".\n + /// The media controller server can let media controller clients know the index of current playing media by using this function. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] index The index of the current playing media in the playlist + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @post Apply the updated playback information by calling mc_server_update_playback_info(). + /// @see mc_server_create() + /// @see mc_server_destroy() + /// @see mc_server_update_playback_info() + /// @see mc_server_create_playlist() + int mc_server_set_playlist_item_index( + ffi.Pointer server, + ffi.Pointer index, + ) { + return _mc_server_set_playlist_item_index( + server, + index, + ); + } + + late final _mc_server_set_playlist_item_index_ptr = + _lookup>( + 'mc_server_set_playlist_item_index'); + late final _dart_mc_server_set_playlist_item_index + _mc_server_set_playlist_item_index = + _mc_server_set_playlist_item_index_ptr + .asFunction<_dart_mc_server_set_playlist_item_index>(); + + /// @brief Updates the modified playback info. + /// @details If this function is called, the updated playback information will be sent to the controller. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_update_playback_info( + ffi.Pointer server, + ) { + return _mc_server_update_playback_info( + server, + ); + } + + late final _mc_server_update_playback_info_ptr = + _lookup>( + 'mc_server_update_playback_info'); + late final _dart_mc_server_update_playback_info + _mc_server_update_playback_info = _mc_server_update_playback_info_ptr + .asFunction<_dart_mc_server_update_playback_info>(); + + /// @brief Sets the metadata to update the latest metadata info. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] attribute The key attribute name to set + /// @param[in] value The value of the attribute + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @post Apply the updated metadata information by calling mc_server_update_metadata(). + /// @see mc_server_create() + /// @see mc_server_destroy() + /// @see mc_server_update_metadata() + int mc_server_set_metadata( + ffi.Pointer server, + int attribute, + ffi.Pointer value, + ) { + return _mc_server_set_metadata( + server, + attribute, + value, + ); + } + + late final _mc_server_set_metadata_ptr = + _lookup>( + 'mc_server_set_metadata'); + late final _dart_mc_server_set_metadata _mc_server_set_metadata = + _mc_server_set_metadata_ptr.asFunction<_dart_mc_server_set_metadata>(); + + /// @brief Updates the modified metadata info. + /// @details If this function is called, the updated metadata will be sent to all clients. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_update_metadata( + ffi.Pointer server, + ) { + return _mc_server_update_metadata( + server, + ); + } + + late final _mc_server_update_metadata_ptr = + _lookup>( + 'mc_server_update_metadata'); + late final _dart_mc_server_update_metadata _mc_server_update_metadata = + _mc_server_update_metadata_ptr + .asFunction<_dart_mc_server_update_metadata>(); + + /// @brief Updates the modified shuffle mode. + /// @details If this function is called, the updated mode information will be sent to all clients. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] mode The shuffle mode to update the latest status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_update_shuffle_mode( + ffi.Pointer server, + int mode, + ) { + return _mc_server_update_shuffle_mode( + server, + mode, + ); + } + + late final _mc_server_update_shuffle_mode_ptr = + _lookup>( + 'mc_server_update_shuffle_mode'); + late final _dart_mc_server_update_shuffle_mode + _mc_server_update_shuffle_mode = _mc_server_update_shuffle_mode_ptr + .asFunction<_dart_mc_server_update_shuffle_mode>(); + + /// @brief Updates the modified repeat mode. + /// @details If this function is called, the updated mode information will be sent to all clients. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] mode The repeat mode to update the latest status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_update_repeat_mode( + ffi.Pointer server, + int mode, + ) { + return _mc_server_update_repeat_mode( + server, + mode, + ); + } + + late final _mc_server_update_repeat_mode_ptr = + _lookup>( + 'mc_server_update_repeat_mode'); + late final _dart_mc_server_update_repeat_mode _mc_server_update_repeat_mode = + _mc_server_update_repeat_mode_ptr + .asFunction<_dart_mc_server_update_repeat_mode>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_server_set_playback_action_cmd_received_cb() instead. @endif + /// @brief Sets the callback for receiving playback state command from client. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] callback The callback to be invoked when media controller server receives playback command from client. + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_set_playback_state_command_received_cb( + ffi.Pointer server, + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, + ) { + return _mc_server_set_playback_state_command_received_cb( + server, + callback, + user_data, + ); + } + + late final _mc_server_set_playback_state_command_received_cb_ptr = _lookup< + ffi.NativeFunction< + _c_mc_server_set_playback_state_command_received_cb>>( + 'mc_server_set_playback_state_command_received_cb'); + late final _dart_mc_server_set_playback_state_command_received_cb + _mc_server_set_playback_state_command_received_cb = + _mc_server_set_playback_state_command_received_cb_ptr + .asFunction<_dart_mc_server_set_playback_state_command_received_cb>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_server_unset_playback_action_cmd_received_cb() instead. @endif + /// @brief Unsets the callback for receiving playback state command from client. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_unset_playback_state_command_received_cb( + ffi.Pointer server, + ) { + return _mc_server_unset_playback_state_command_received_cb( + server, + ); + } + + late final _mc_server_unset_playback_state_command_received_cb_ptr = _lookup< + ffi.NativeFunction< + _c_mc_server_unset_playback_state_command_received_cb>>( + 'mc_server_unset_playback_state_command_received_cb'); + late final _dart_mc_server_unset_playback_state_command_received_cb + _mc_server_unset_playback_state_command_received_cb = + _mc_server_unset_playback_state_command_received_cb_ptr.asFunction< + _dart_mc_server_unset_playback_state_command_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for receiving playback action command from client. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] callback The callback to be invoked when media controller server receives playback action from client. + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_set_playback_action_cmd_received_cb( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _mc_server_set_playback_action_cmd_received_cb( + server, + callback, + user_data, + ); + } + + late final _mc_server_set_playback_action_cmd_received_cb_ptr = _lookup< + ffi.NativeFunction<_c_mc_server_set_playback_action_cmd_received_cb>>( + 'mc_server_set_playback_action_cmd_received_cb'); + late final _dart_mc_server_set_playback_action_cmd_received_cb + _mc_server_set_playback_action_cmd_received_cb = + _mc_server_set_playback_action_cmd_received_cb_ptr + .asFunction<_dart_mc_server_set_playback_action_cmd_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for receiving playback action command from client. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_unset_playback_action_cmd_received_cb( + ffi.Pointer server, + ) { + return _mc_server_unset_playback_action_cmd_received_cb( + server, + ); + } + + late final _mc_server_unset_playback_action_cmd_received_cb_ptr = _lookup< + ffi.NativeFunction< + _c_mc_server_unset_playback_action_cmd_received_cb>>( + 'mc_server_unset_playback_action_cmd_received_cb'); + late final _dart_mc_server_unset_playback_action_cmd_received_cb + _mc_server_unset_playback_action_cmd_received_cb = + _mc_server_unset_playback_action_cmd_received_cb_ptr + .asFunction<_dart_mc_server_unset_playback_action_cmd_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for receiving playback position command from client. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] callback The callback to be invoked when media controller server receives position command from client. + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_set_playback_position_cmd_received_cb( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _mc_server_set_playback_position_cmd_received_cb( + server, + callback, + user_data, + ); + } + + late final _mc_server_set_playback_position_cmd_received_cb_ptr = _lookup< + ffi.NativeFunction< + _c_mc_server_set_playback_position_cmd_received_cb>>( + 'mc_server_set_playback_position_cmd_received_cb'); + late final _dart_mc_server_set_playback_position_cmd_received_cb + _mc_server_set_playback_position_cmd_received_cb = + _mc_server_set_playback_position_cmd_received_cb_ptr + .asFunction<_dart_mc_server_set_playback_position_cmd_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for receiving playback position command from client. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_unset_playback_position_cmd_received_cb( + ffi.Pointer server, + ) { + return _mc_server_unset_playback_position_cmd_received_cb( + server, + ); + } + + late final _mc_server_unset_playback_position_cmd_received_cb_ptr = _lookup< + ffi.NativeFunction< + _c_mc_server_unset_playback_position_cmd_received_cb>>( + 'mc_server_unset_playback_position_cmd_received_cb'); + late final _dart_mc_server_unset_playback_position_cmd_received_cb + _mc_server_unset_playback_position_cmd_received_cb = + _mc_server_unset_playback_position_cmd_received_cb_ptr.asFunction< + _dart_mc_server_unset_playback_position_cmd_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for receiving shuffle mode command from client. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] callback The callback to be invoked when media controller server receives shuffle mode from client. + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_set_shuffle_mode_cmd_received_cb( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _mc_server_set_shuffle_mode_cmd_received_cb( + server, + callback, + user_data, + ); + } + + late final _mc_server_set_shuffle_mode_cmd_received_cb_ptr = _lookup< + ffi.NativeFunction<_c_mc_server_set_shuffle_mode_cmd_received_cb>>( + 'mc_server_set_shuffle_mode_cmd_received_cb'); + late final _dart_mc_server_set_shuffle_mode_cmd_received_cb + _mc_server_set_shuffle_mode_cmd_received_cb = + _mc_server_set_shuffle_mode_cmd_received_cb_ptr + .asFunction<_dart_mc_server_set_shuffle_mode_cmd_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for receiving shuffle mode command from client. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_unset_shuffle_mode_cmd_received_cb( + ffi.Pointer server, + ) { + return _mc_server_unset_shuffle_mode_cmd_received_cb( + server, + ); + } + + late final _mc_server_unset_shuffle_mode_cmd_received_cb_ptr = _lookup< + ffi.NativeFunction<_c_mc_server_unset_shuffle_mode_cmd_received_cb>>( + 'mc_server_unset_shuffle_mode_cmd_received_cb'); + late final _dart_mc_server_unset_shuffle_mode_cmd_received_cb + _mc_server_unset_shuffle_mode_cmd_received_cb = + _mc_server_unset_shuffle_mode_cmd_received_cb_ptr + .asFunction<_dart_mc_server_unset_shuffle_mode_cmd_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for receiving repeat mode command from client. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] callback The callback to be invoked when media controller server receives repeat mode from client. + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_set_repeat_mode_cmd_received_cb( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _mc_server_set_repeat_mode_cmd_received_cb( + server, + callback, + user_data, + ); + } + + late final _mc_server_set_repeat_mode_cmd_received_cb_ptr = + _lookup>( + 'mc_server_set_repeat_mode_cmd_received_cb'); + late final _dart_mc_server_set_repeat_mode_cmd_received_cb + _mc_server_set_repeat_mode_cmd_received_cb = + _mc_server_set_repeat_mode_cmd_received_cb_ptr + .asFunction<_dart_mc_server_set_repeat_mode_cmd_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for receiving repeat mode command from client. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_unset_repeat_mode_cmd_received_cb( + ffi.Pointer server, + ) { + return _mc_server_unset_repeat_mode_cmd_received_cb( + server, + ); + } + + late final _mc_server_unset_repeat_mode_cmd_received_cb_ptr = _lookup< + ffi.NativeFunction<_c_mc_server_unset_repeat_mode_cmd_received_cb>>( + 'mc_server_unset_repeat_mode_cmd_received_cb'); + late final _dart_mc_server_unset_repeat_mode_cmd_received_cb + _mc_server_unset_repeat_mode_cmd_received_cb = + _mc_server_unset_repeat_mode_cmd_received_cb_ptr + .asFunction<_dart_mc_server_unset_repeat_mode_cmd_received_cb>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_server_set_custom_cmd_received_cb() instead. @endif + /// @brief Sets the callback for receiving custom command from client. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] callback The callback to be invoked when media controller server receives custom command from client. + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_set_custom_command_received_cb( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _mc_server_set_custom_command_received_cb( + server, + callback, + user_data, + ); + } + + late final _mc_server_set_custom_command_received_cb_ptr = + _lookup>( + 'mc_server_set_custom_command_received_cb'); + late final _dart_mc_server_set_custom_command_received_cb + _mc_server_set_custom_command_received_cb = + _mc_server_set_custom_command_received_cb_ptr + .asFunction<_dart_mc_server_set_custom_command_received_cb>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_server_unset_custom_cmd_received_cb() instead. @endif + /// @brief Unsets the callback for receiving custom command from client. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_unset_custom_command_received_cb( + ffi.Pointer server, + ) { + return _mc_server_unset_custom_command_received_cb( + server, + ); + } + + late final _mc_server_unset_custom_command_received_cb_ptr = _lookup< + ffi.NativeFunction<_c_mc_server_unset_custom_command_received_cb>>( + 'mc_server_unset_custom_command_received_cb'); + late final _dart_mc_server_unset_custom_command_received_cb + _mc_server_unset_custom_command_received_cb = + _mc_server_unset_custom_command_received_cb_ptr + .asFunction<_dart_mc_server_unset_custom_command_received_cb>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_server_send_cmd_reply() instead. @endif + /// @brief Sends a reply for the requested command to the client. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @remarks When server receive command, this function can be called by mc_server_custom_command_received_cb(). + /// + /// @param[in] server The handle to media controller server + /// @param[in] client_name The app_id of the media controller client + /// @param[in] result_code The result code of custom command + /// @param[in] data The extra data + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @pre mc_server_set_custom_command_received_cb() + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_send_command_reply( + ffi.Pointer server, + ffi.Pointer client_name, + int result_code, + ffi.Pointer data, + ) { + return _mc_server_send_command_reply( + server, + client_name, + result_code, + data, + ); + } + + late final _mc_server_send_command_reply_ptr = + _lookup>( + 'mc_server_send_command_reply'); + late final _dart_mc_server_send_command_reply _mc_server_send_command_reply = + _mc_server_send_command_reply_ptr + .asFunction<_dart_mc_server_send_command_reply>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for receiving playlist command from client. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] callback The callback to be invoked when media controller server receives playlist command from client. + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_set_playlist_cmd_received_cb( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _mc_server_set_playlist_cmd_received_cb( + server, + callback, + user_data, + ); + } + + late final _mc_server_set_playlist_cmd_received_cb_ptr = + _lookup>( + 'mc_server_set_playlist_cmd_received_cb'); + late final _dart_mc_server_set_playlist_cmd_received_cb + _mc_server_set_playlist_cmd_received_cb = + _mc_server_set_playlist_cmd_received_cb_ptr + .asFunction<_dart_mc_server_set_playlist_cmd_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for receiving playlist command from client. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_unset_playlist_cmd_received_cb( + ffi.Pointer server, + ) { + return _mc_server_unset_playlist_cmd_received_cb( + server, + ); + } + + late final _mc_server_unset_playlist_cmd_received_cb_ptr = + _lookup>( + 'mc_server_unset_playlist_cmd_received_cb'); + late final _dart_mc_server_unset_playlist_cmd_received_cb + _mc_server_unset_playlist_cmd_received_cb = + _mc_server_unset_playlist_cmd_received_cb_ptr + .asFunction<_dart_mc_server_unset_playlist_cmd_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for receiving custom command from client. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] callback The callback to be invoked when media controller server receives custom command from client. + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_set_custom_cmd_received_cb( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_server_set_custom_cmd_received_cb( + server, + callback, + user_data, + ); + } + + late final _mc_server_set_custom_cmd_received_cb_ptr = + _lookup>( + 'mc_server_set_custom_cmd_received_cb'); + late final _dart_mc_server_set_custom_cmd_received_cb + _mc_server_set_custom_cmd_received_cb = + _mc_server_set_custom_cmd_received_cb_ptr + .asFunction<_dart_mc_server_set_custom_cmd_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for receiving custom command from client. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + int mc_server_unset_custom_cmd_received_cb( + ffi.Pointer server, + ) { + return _mc_server_unset_custom_cmd_received_cb( + server, + ); + } + + late final _mc_server_unset_custom_cmd_received_cb_ptr = + _lookup>( + 'mc_server_unset_custom_cmd_received_cb'); + late final _dart_mc_server_unset_custom_cmd_received_cb + _mc_server_unset_custom_cmd_received_cb = + _mc_server_unset_custom_cmd_received_cb_ptr + .asFunction<_dart_mc_server_unset_custom_cmd_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Replies the result of the requested command to the client. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @remarks When the server receives a command, this function can be called by mc_server_playback_action_cmd_received_cb(), mc_server_playback_position_cmd_received_cb(), mc_server_shuffle_mode_cmd_received_cb(), mc_server_repeat_mode_cmd_received_cb(), mc_server_playlist_cmd_received_cb() and mc_server_custom_cmd_received_cb().\n + /// If @a request_id is null, this function will return #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER. + /// + /// @param[in] server The handle to media controller server + /// @param[in] client_name The app_id of the media controller client + /// @param[in] request_id The id of the command request, received in the mc_server_custom_cmd_received_cb() function. + /// @param[in] result_code The result code of custom command + /// @param[in] data The extra data + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_playback_action_cmd_received_cb() + /// @see mc_server_playback_position_cmd_received_cb() + /// @see mc_server_shuffle_mode_cmd_received_cb() + /// @see mc_server_repeat_mode_cmd_received_cb() + /// @see mc_server_playlist_cmd_received_cb() + /// @see mc_server_custom_cmd_received_cb() + /// @see mc_server_destroy() + int mc_server_send_cmd_reply( + ffi.Pointer server, + ffi.Pointer client_name, + ffi.Pointer request_id, + int result_code, + ffi.Pointer data, + ) { + return _mc_server_send_cmd_reply( + server, + client_name, + request_id, + result_code, + data, + ); + } + + late final _mc_server_send_cmd_reply_ptr = + _lookup>( + 'mc_server_send_cmd_reply'); + late final _dart_mc_server_send_cmd_reply _mc_server_send_cmd_reply = + _mc_server_send_cmd_reply_ptr + .asFunction<_dart_mc_server_send_cmd_reply>(); + + /// @MOBILE_ONLY + /// @brief Retrieves all created clients. + /// @details This function gets all created media controller clients. + /// The callback function will be invoked for every created media controller client. + /// If there are no media controller clients, the callback will not be invoked. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] callback The callback function to be invoked, will be called for each client + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_activated_client_cb() + /// @see mc_server_destroy() + int mc_server_foreach_client( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_server_foreach_client( + server, + callback, + user_data, + ); + } + + late final _mc_server_foreach_client_ptr = + _lookup>( + 'mc_server_foreach_client'); + late final _dart_mc_server_foreach_client _mc_server_foreach_client = + _mc_server_foreach_client_ptr + .asFunction<_dart_mc_server_foreach_client>(); + + /// @MOBILE_ONLY + /// @brief Sends the customized event with the bundle data. + /// @details If the event is needed in the client, this function should be called. @a data is a bundle. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @remarks The @a request_id should be released using free().\n + /// If the @a request_id is null, the client will not send the reply of the custom event. + /// + /// @param[in] server The handle to media controller server + /// @param[in] client_name The name of the client which receive the event + /// @param[in] event The name of the event + /// @param[in] data The data can include other information associated with the event + /// @param[out] request_id The id of the event request, it will be passed to the mc_server_event_reply_received_cb() function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_event_reply_received_cb() + /// @see mc_server_set_event_reply_received_cb() + /// @see mc_server_destroy() + int mc_server_send_custom_event( + ffi.Pointer server, + ffi.Pointer client_name, + ffi.Pointer event, + ffi.Pointer data, + ffi.Pointer> request_id, + ) { + return _mc_server_send_custom_event( + server, + client_name, + event, + data, + request_id, + ); + } + + late final _mc_server_send_custom_event_ptr = + _lookup>( + 'mc_server_send_custom_event'); + late final _dart_mc_server_send_custom_event _mc_server_send_custom_event = + _mc_server_send_custom_event_ptr + .asFunction<_dart_mc_server_send_custom_event>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for receiving the result of the event from the media controller client. + /// @details The media controller server which calls this function will receive the result of the event from all media controller clients. + /// The media controller server can send event by using mc_server_send_custom_event(). + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to the media controller server + /// @param[in] callback The callback to be invoked when the reply is received + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @pre mc_server_send_custom_event(). + /// @see mc_server_create() + /// @see mc_server_unset_event_reply_received_cb() + /// @see mc_server_destroy() + int mc_server_set_event_reply_received_cb( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_server_set_event_reply_received_cb( + server, + callback, + user_data, + ); + } + + late final _mc_server_set_event_reply_received_cb_ptr = + _lookup>( + 'mc_server_set_event_reply_received_cb'); + late final _dart_mc_server_set_event_reply_received_cb + _mc_server_set_event_reply_received_cb = + _mc_server_set_event_reply_received_cb_ptr + .asFunction<_dart_mc_server_set_event_reply_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for receiving event reply of the media controller client. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to the media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_server_create() + /// @see mc_server_set_event_reply_received_cb() + /// @see mc_server_destroy() + int mc_server_unset_event_reply_received_cb( + ffi.Pointer server, + ) { + return _mc_server_unset_event_reply_received_cb( + server, + ); + } + + late final _mc_server_unset_event_reply_received_cb_ptr = + _lookup>( + 'mc_server_unset_event_reply_received_cb'); + late final _dart_mc_server_unset_event_reply_received_cb + _mc_server_unset_event_reply_received_cb = + _mc_server_unset_event_reply_received_cb_ptr + .asFunction<_dart_mc_server_unset_event_reply_received_cb>(); + + /// @brief Destroys media controller server. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] server The handle to media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #METADATA_EXTRACTOR_ERROR_NONE Successful + /// @retval #METADATA_EXTRACTOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + int mc_server_destroy( + ffi.Pointer server, + ) { + return _mc_server_destroy( + server, + ); + } + + late final _mc_server_destroy_ptr = + _lookup>('mc_server_destroy'); + late final _dart_mc_server_destroy _mc_server_destroy = + _mc_server_destroy_ptr.asFunction<_dart_mc_server_destroy>(); + + /// @MOBILE_ONLY + /// @brief Creates a new playlist with the given name. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @remarks The @a playlist should be released using mc_playlist_destroy(). + /// When the server is destroyed, all its playlists will be deleted automatically. + /// + /// @param[in] server The handle to media controller server + /// @param[in] playlist_name The name of the created playlist. It should not be NULL. + /// @param[out] playlist The handle to the media controller playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @post You can call mc_server_add_item_to_playlist() if you have items to add in the playlist and should call @c mc_server_update_playlist_done() to register it. + /// @see mc_server_create() + /// @see mc_server_destroy() + /// @see mc_server_add_item_to_playlist() + /// @see mc_server_update_playlist_done() + /// @see mc_server_delete_playlist() + /// @see mc_playlist_destroy() + int mc_server_create_playlist( + ffi.Pointer server, + ffi.Pointer playlist_name, + ffi.Pointer> playlist, + ) { + return _mc_server_create_playlist( + server, + playlist_name, + playlist, + ); + } + + late final _mc_server_create_playlist_ptr = + _lookup>( + 'mc_server_create_playlist'); + late final _dart_mc_server_create_playlist _mc_server_create_playlist = + _mc_server_create_playlist_ptr + .asFunction<_dart_mc_server_create_playlist>(); + + /// @MOBILE_ONLY + /// @brief Adds a new item to the playlist. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @remarks It's possible to add at most 100 items at once. \n + /// If you have more items, register the first 100 items by calling mc_server_update_playlist_done(), then add the remaining items. + /// + /// @param[in] server The handle to media controller server + /// @param[in] playlist The handle to the media controller playlist + /// @param[in] index The index of the playlist item. It should not be NULL + /// @param[in] attribute The key attribute name to set + /// @param[in] value The value of the attribute + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @pre Create a media controller playlist handle by calling mc_server_create_playlist(). + /// @post You should call @c mc_server_update_playlist_done() to register it. + /// @see mc_server_create() + /// @see mc_server_destroy() + /// @see mc_server_create_playlist() + /// @see mc_server_update_playlist_done() + /// @see mc_playlist_destroy() + int mc_server_add_item_to_playlist( + ffi.Pointer server, + ffi.Pointer playlist, + ffi.Pointer index, + int attribute, + ffi.Pointer value, + ) { + return _mc_server_add_item_to_playlist( + server, + playlist, + index, + attribute, + value, + ); + } + + late final _mc_server_add_item_to_playlist_ptr = + _lookup>( + 'mc_server_add_item_to_playlist'); + late final _dart_mc_server_add_item_to_playlist + _mc_server_add_item_to_playlist = _mc_server_add_item_to_playlist_ptr + .asFunction<_dart_mc_server_add_item_to_playlist>(); + + /// @MOBILE_ONLY + /// @brief Registers items to the playlist. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] playlist The handle to the media controller playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @pre Create a media controller playlist handle by calling mc_server_create_playlist(). + /// @see mc_server_create() + /// @see mc_server_destroy() + /// @see mc_server_create_playlist() + /// @see mc_playlist_destroy() + int mc_server_update_playlist_done( + ffi.Pointer server, + ffi.Pointer playlist, + ) { + return _mc_server_update_playlist_done( + server, + playlist, + ); + } + + late final _mc_server_update_playlist_done_ptr = + _lookup>( + 'mc_server_update_playlist_done'); + late final _dart_mc_server_update_playlist_done + _mc_server_update_playlist_done = _mc_server_update_playlist_done_ptr + .asFunction<_dart_mc_server_update_playlist_done>(); + + /// @MOBILE_ONLY + /// @brief Deletes the playlist of the media controller server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] playlist The handle to the media controller playlist + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @pre Create a media controller playlist handle by calling mc_server_create_playlist(). + /// @see mc_server_create() + /// @see mc_server_destroy() + /// @see mc_server_create_playlist() + /// @see mc_playlist_destroy() + int mc_server_delete_playlist( + ffi.Pointer server, + ffi.Pointer playlist, + ) { + return _mc_server_delete_playlist( + server, + playlist, + ); + } + + late final _mc_server_delete_playlist_ptr = + _lookup>( + 'mc_server_delete_playlist'); + late final _dart_mc_server_delete_playlist _mc_server_delete_playlist = + _mc_server_delete_playlist_ptr + .asFunction<_dart_mc_server_delete_playlist>(); + + /// @MOBILE_ONLY + /// @brief Retrieves all playlists of the media controller server. + /// @details This function gets all playlists of the media controller server. + /// The callback function will be invoked for every retrieved playlist. + /// If there are no playlists, callback will not be invoked. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.server + /// + /// @param[in] server The handle to media controller server + /// @param[in] callback The callback function to be invoked, will be called for each playlist + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_server_create() + /// @see mc_server_destroy() + /// @see mc_playlist_cb() + int mc_server_foreach_playlist( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_server_foreach_playlist( + server, + callback, + user_data, + ); + } + + late final _mc_server_foreach_playlist_ptr = + _lookup>( + 'mc_server_foreach_playlist'); + late final _dart_mc_server_foreach_playlist _mc_server_foreach_playlist = + _mc_server_foreach_playlist_ptr + .asFunction<_dart_mc_server_foreach_playlist>(); + + /// @brief Creates a media controller client. + /// @details The media controller client binds the latest media controller server when handlers are created. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @remarks The @a client should be released using @c mc_client_destroy(). You can create only one client handle for each process. + /// + /// @param[out] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @see mc_client_destroy() + int mc_client_create( + ffi.Pointer> client, + ) { + return _mc_client_create( + client, + ); + } + + late final _mc_client_create_ptr = + _lookup>('mc_client_create'); + late final _dart_mc_client_create _mc_client_create = + _mc_client_create_ptr.asFunction<_dart_mc_client_create>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_client_set_server_updated_cb() instead. @endif + /// @brief Sets the callback for monitoring status of the media controller server. + /// @details The media controller client which calls this function will receive notifications from all media controller servers. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] callback The callback to be invoked when the media controller server status is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_set_server_update_cb( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_set_server_update_cb( + client, + callback, + user_data, + ); + } + + late final _mc_client_set_server_update_cb_ptr = + _lookup>( + 'mc_client_set_server_update_cb'); + late final _dart_mc_client_set_server_update_cb + _mc_client_set_server_update_cb = _mc_client_set_server_update_cb_ptr + .asFunction<_dart_mc_client_set_server_update_cb>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_client_unset_server_updated_cb() instead. @endif + /// @brief Unsets the callback for monitoring status of the media controller server. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_unset_server_update_cb( + ffi.Pointer client, + ) { + return _mc_client_unset_server_update_cb( + client, + ); + } + + late final _mc_client_unset_server_update_cb_ptr = + _lookup>( + 'mc_client_unset_server_update_cb'); + late final _dart_mc_client_unset_server_update_cb + _mc_client_unset_server_update_cb = _mc_client_unset_server_update_cb_ptr + .asFunction<_dart_mc_client_unset_server_update_cb>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_client_set_playback_updated_cb() instead. @endif + /// @brief Sets the callback for monitoring playback status of the media controller server. + /// @details The media controller client which calls this function will receive notifications from all media controller servers. \n + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] callback The callback to be invoked when the playback status is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_set_playback_update_cb( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_set_playback_update_cb( + client, + callback, + user_data, + ); + } + + late final _mc_client_set_playback_update_cb_ptr = + _lookup>( + 'mc_client_set_playback_update_cb'); + late final _dart_mc_client_set_playback_update_cb + _mc_client_set_playback_update_cb = _mc_client_set_playback_update_cb_ptr + .asFunction<_dart_mc_client_set_playback_update_cb>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_client_unset_playback_updated_cb() instead. @endif + /// @brief Unsets the callback for monitoring playback status of the media controller server. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_unset_playback_update_cb( + ffi.Pointer client, + ) { + return _mc_client_unset_playback_update_cb( + client, + ); + } + + late final _mc_client_unset_playback_update_cb_ptr = + _lookup>( + 'mc_client_unset_playback_update_cb'); + late final _dart_mc_client_unset_playback_update_cb + _mc_client_unset_playback_update_cb = + _mc_client_unset_playback_update_cb_ptr + .asFunction<_dart_mc_client_unset_playback_update_cb>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_client_set_metadata_updated_cb() instead. @endif + /// @brief Sets the callback for monitoring metadata status of the media controller server. + /// @details The media controller client which calls this function will receive notifications from all media controller servers. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] callback The callback to be invoked when the metadata status is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_set_metadata_update_cb( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_set_metadata_update_cb( + client, + callback, + user_data, + ); + } + + late final _mc_client_set_metadata_update_cb_ptr = + _lookup>( + 'mc_client_set_metadata_update_cb'); + late final _dart_mc_client_set_metadata_update_cb + _mc_client_set_metadata_update_cb = _mc_client_set_metadata_update_cb_ptr + .asFunction<_dart_mc_client_set_metadata_update_cb>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_client_unset_metadata_updated_cb() instead. @endif + /// @brief Unsets the callback for monitoring metadata status of the media controller server. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_unset_metadata_update_cb( + ffi.Pointer client, + ) { + return _mc_client_unset_metadata_update_cb( + client, + ); + } + + late final _mc_client_unset_metadata_update_cb_ptr = + _lookup>( + 'mc_client_unset_metadata_update_cb'); + late final _dart_mc_client_unset_metadata_update_cb + _mc_client_unset_metadata_update_cb = + _mc_client_unset_metadata_update_cb_ptr + .asFunction<_dart_mc_client_unset_metadata_update_cb>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_client_set_shuffle_mode_updated_cb() instead. @endif + /// @brief Sets the callback for monitoring shuffle mode of the media controller server. + /// @details The media controller client which calls this function will receive notifications from all media controller servers. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] callback The callback to be invoked when the shuffle mode is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_set_shuffle_mode_update_cb( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_set_shuffle_mode_update_cb( + client, + callback, + user_data, + ); + } + + late final _mc_client_set_shuffle_mode_update_cb_ptr = + _lookup>( + 'mc_client_set_shuffle_mode_update_cb'); + late final _dart_mc_client_set_shuffle_mode_update_cb + _mc_client_set_shuffle_mode_update_cb = + _mc_client_set_shuffle_mode_update_cb_ptr + .asFunction<_dart_mc_client_set_shuffle_mode_update_cb>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_client_unset_shuffle_mode_updated_cb() instead. @endif + /// @brief Unsets the callback for monitoring shuffle mode of the media controller server. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_unset_shuffle_mode_update_cb( + ffi.Pointer client, + ) { + return _mc_client_unset_shuffle_mode_update_cb( + client, + ); + } + + late final _mc_client_unset_shuffle_mode_update_cb_ptr = + _lookup>( + 'mc_client_unset_shuffle_mode_update_cb'); + late final _dart_mc_client_unset_shuffle_mode_update_cb + _mc_client_unset_shuffle_mode_update_cb = + _mc_client_unset_shuffle_mode_update_cb_ptr + .asFunction<_dart_mc_client_unset_shuffle_mode_update_cb>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_client_set_repeat_mode_updated_cb() instead. @endif + /// @brief Sets the callback for monitoring repeat mode of the media controller server. + /// @details The media controller client which calls this function will receive notifications from all media controller servers. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] callback The callback to be invoked when the repeat mode is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_set_repeat_mode_update_cb( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_set_repeat_mode_update_cb( + client, + callback, + user_data, + ); + } + + late final _mc_client_set_repeat_mode_update_cb_ptr = + _lookup>( + 'mc_client_set_repeat_mode_update_cb'); + late final _dart_mc_client_set_repeat_mode_update_cb + _mc_client_set_repeat_mode_update_cb = + _mc_client_set_repeat_mode_update_cb_ptr + .asFunction<_dart_mc_client_set_repeat_mode_update_cb>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_client_unset_repeat_mode_updated_cb() instead. @endif + /// @brief Unsets the callback for monitoring repeat mode of the media controller server. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_unset_repeat_mode_update_cb( + ffi.Pointer client, + ) { + return _mc_client_unset_repeat_mode_update_cb( + client, + ); + } + + late final _mc_client_unset_repeat_mode_update_cb_ptr = + _lookup>( + 'mc_client_unset_repeat_mode_update_cb'); + late final _dart_mc_client_unset_repeat_mode_update_cb + _mc_client_unset_repeat_mode_update_cb = + _mc_client_unset_repeat_mode_update_cb_ptr + .asFunction<_dart_mc_client_unset_repeat_mode_update_cb>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for monitoring status of the media controller server. + /// @details The media controller client which calls this function will receive notifications from all media controller servers. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] callback The callback to be invoked when the media controller server status is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_set_server_updated_cb( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_set_server_updated_cb( + client, + callback, + user_data, + ); + } + + late final _mc_client_set_server_updated_cb_ptr = + _lookup>( + 'mc_client_set_server_updated_cb'); + late final _dart_mc_client_set_server_updated_cb + _mc_client_set_server_updated_cb = _mc_client_set_server_updated_cb_ptr + .asFunction<_dart_mc_client_set_server_updated_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for monitoring status of the media controller server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_unset_server_updated_cb( + ffi.Pointer client, + ) { + return _mc_client_unset_server_updated_cb( + client, + ); + } + + late final _mc_client_unset_server_updated_cb_ptr = + _lookup>( + 'mc_client_unset_server_updated_cb'); + late final _dart_mc_client_unset_server_updated_cb + _mc_client_unset_server_updated_cb = + _mc_client_unset_server_updated_cb_ptr + .asFunction<_dart_mc_client_unset_server_updated_cb>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for monitoring playback status of the media controller server. + /// @details The media controller client which calls this function will receive notifications from all media controller servers. \n + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] callback The callback to be invoked when the playback status is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_set_playback_updated_cb( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_set_playback_updated_cb( + client, + callback, + user_data, + ); + } + + late final _mc_client_set_playback_updated_cb_ptr = + _lookup>( + 'mc_client_set_playback_updated_cb'); + late final _dart_mc_client_set_playback_updated_cb + _mc_client_set_playback_updated_cb = + _mc_client_set_playback_updated_cb_ptr + .asFunction<_dart_mc_client_set_playback_updated_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for monitoring playback status of the media controller server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_unset_playback_updated_cb( + ffi.Pointer client, + ) { + return _mc_client_unset_playback_updated_cb( + client, + ); + } + + late final _mc_client_unset_playback_updated_cb_ptr = + _lookup>( + 'mc_client_unset_playback_updated_cb'); + late final _dart_mc_client_unset_playback_updated_cb + _mc_client_unset_playback_updated_cb = + _mc_client_unset_playback_updated_cb_ptr + .asFunction<_dart_mc_client_unset_playback_updated_cb>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for monitoring metadata status of the media controller server. + /// @details The media controller client which calls this function will receive notifications from all media controller servers. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] callback The callback to be invoked when the metadata status is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_set_metadata_updated_cb( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_set_metadata_updated_cb( + client, + callback, + user_data, + ); + } + + late final _mc_client_set_metadata_updated_cb_ptr = + _lookup>( + 'mc_client_set_metadata_updated_cb'); + late final _dart_mc_client_set_metadata_updated_cb + _mc_client_set_metadata_updated_cb = + _mc_client_set_metadata_updated_cb_ptr + .asFunction<_dart_mc_client_set_metadata_updated_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for monitoring metadata status of the media controller server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_unset_metadata_updated_cb( + ffi.Pointer client, + ) { + return _mc_client_unset_metadata_updated_cb( + client, + ); + } + + late final _mc_client_unset_metadata_updated_cb_ptr = + _lookup>( + 'mc_client_unset_metadata_updated_cb'); + late final _dart_mc_client_unset_metadata_updated_cb + _mc_client_unset_metadata_updated_cb = + _mc_client_unset_metadata_updated_cb_ptr + .asFunction<_dart_mc_client_unset_metadata_updated_cb>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for monitoring shuffle mode of the media controller server. + /// @details The media controller client which calls this function will receive notifications from all media controller servers. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] callback The callback to be invoked when the shuffle mode is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_set_shuffle_mode_updated_cb( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_set_shuffle_mode_updated_cb( + client, + callback, + user_data, + ); + } + + late final _mc_client_set_shuffle_mode_updated_cb_ptr = + _lookup>( + 'mc_client_set_shuffle_mode_updated_cb'); + late final _dart_mc_client_set_shuffle_mode_updated_cb + _mc_client_set_shuffle_mode_updated_cb = + _mc_client_set_shuffle_mode_updated_cb_ptr + .asFunction<_dart_mc_client_set_shuffle_mode_updated_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for monitoring shuffle mode of the media controller server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_unset_shuffle_mode_updated_cb( + ffi.Pointer client, + ) { + return _mc_client_unset_shuffle_mode_updated_cb( + client, + ); + } + + late final _mc_client_unset_shuffle_mode_updated_cb_ptr = + _lookup>( + 'mc_client_unset_shuffle_mode_updated_cb'); + late final _dart_mc_client_unset_shuffle_mode_updated_cb + _mc_client_unset_shuffle_mode_updated_cb = + _mc_client_unset_shuffle_mode_updated_cb_ptr + .asFunction<_dart_mc_client_unset_shuffle_mode_updated_cb>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for monitoring repeat mode of the media controller server. + /// @details The media controller client which calls this function will receive notifications from all media controller servers. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] callback The callback to be invoked when the repeat mode is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_set_repeat_mode_updated_cb( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_set_repeat_mode_updated_cb( + client, + callback, + user_data, + ); + } + + late final _mc_client_set_repeat_mode_updated_cb_ptr = + _lookup>( + 'mc_client_set_repeat_mode_updated_cb'); + late final _dart_mc_client_set_repeat_mode_updated_cb + _mc_client_set_repeat_mode_updated_cb = + _mc_client_set_repeat_mode_updated_cb_ptr + .asFunction<_dart_mc_client_set_repeat_mode_updated_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for monitoring repeat mode of the media controller server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + int mc_client_unset_repeat_mode_updated_cb( + ffi.Pointer client, + ) { + return _mc_client_unset_repeat_mode_updated_cb( + client, + ); + } + + late final _mc_client_unset_repeat_mode_updated_cb_ptr = + _lookup>( + 'mc_client_unset_repeat_mode_updated_cb'); + late final _dart_mc_client_unset_repeat_mode_updated_cb + _mc_client_unset_repeat_mode_updated_cb = + _mc_client_unset_repeat_mode_updated_cb_ptr + .asFunction<_dart_mc_client_unset_repeat_mode_updated_cb>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for receiving the result of the command from the media controller server. + /// @details The media controller client which calls this function will receives the result of the command from all media controller servers. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] callback The callback to be invoked when the reply is received + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_unset_cmd_reply_received_cb() + /// @see mc_client_destroy() + int mc_client_set_cmd_reply_received_cb( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_set_cmd_reply_received_cb( + client, + callback, + user_data, + ); + } + + late final _mc_client_set_cmd_reply_received_cb_ptr = + _lookup>( + 'mc_client_set_cmd_reply_received_cb'); + late final _dart_mc_client_set_cmd_reply_received_cb + _mc_client_set_cmd_reply_received_cb = + _mc_client_set_cmd_reply_received_cb_ptr + .asFunction<_dart_mc_client_set_cmd_reply_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for receiving common reply of the media controller server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_set_cmd_reply_received_cb() + /// @see mc_client_destroy() + int mc_client_unset_cmd_reply_received_cb( + ffi.Pointer client, + ) { + return _mc_client_unset_cmd_reply_received_cb( + client, + ); + } + + late final _mc_client_unset_cmd_reply_received_cb_ptr = + _lookup>( + 'mc_client_unset_cmd_reply_received_cb'); + late final _dart_mc_client_unset_cmd_reply_received_cb + _mc_client_unset_cmd_reply_received_cb = + _mc_client_unset_cmd_reply_received_cb_ptr + .asFunction<_dart_mc_client_unset_cmd_reply_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for monitoring playlist status of the media controller server. + /// @details The media controller client which calls this function will receive notifications from all media controller servers. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] callback The callback to be invoked when the playlist status is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + /// @see mc_playlist_updated_cb() + /// @see mc_client_unset_playlist_updated_cb() + int mc_client_set_playlist_updated_cb( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_set_playlist_updated_cb( + client, + callback, + user_data, + ); + } + + late final _mc_client_set_playlist_updated_cb_ptr = + _lookup>( + 'mc_client_set_playlist_updated_cb'); + late final _dart_mc_client_set_playlist_updated_cb + _mc_client_set_playlist_updated_cb = + _mc_client_set_playlist_updated_cb_ptr + .asFunction<_dart_mc_client_set_playlist_updated_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for monitoring playlist status of the media controller server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_destroy() + /// @see mc_client_set_playlist_updated_cb() + int mc_client_unset_playlist_updated_cb( + ffi.Pointer client, + ) { + return _mc_client_unset_playlist_updated_cb( + client, + ); + } + + late final _mc_client_unset_playlist_updated_cb_ptr = + _lookup>( + 'mc_client_unset_playlist_updated_cb'); + late final _dart_mc_client_unset_playlist_updated_cb + _mc_client_unset_playlist_updated_cb = + _mc_client_unset_playlist_updated_cb_ptr + .asFunction<_dart_mc_client_unset_playlist_updated_cb>(); + + /// @MOBILE_ONLY + /// @brief Sets the callback for receiving the custom event from a media controller server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to media controller client + /// @param[in] callback The callback to be invoked when the media controller client receives custom event from a media controller server. + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_client_create() + /// @see mc_client_custom_event_received_cb() + /// @see mc_client_unset_custom_event_received_cb() + /// @see mc_client_send_event_reply() + /// @see mc_client_destroy() + int mc_client_set_custom_event_received_cb( + ffi.Pointer client, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _mc_client_set_custom_event_received_cb( + client, + callback, + user_data, + ); + } + + late final _mc_client_set_custom_event_received_cb_ptr = + _lookup>( + 'mc_client_set_custom_event_received_cb'); + late final _dart_mc_client_set_custom_event_received_cb + _mc_client_set_custom_event_received_cb = + _mc_client_set_custom_event_received_cb_ptr + .asFunction<_dart_mc_client_set_custom_event_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Unsets the callback for receiving the custom event from a media controller server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_client_create() + /// @see mc_client_custom_event_received_cb() + /// @see mc_client_set_custom_event_received_cb() + /// @see mc_client_destroy() + int mc_client_unset_custom_event_received_cb( + ffi.Pointer client, + ) { + return _mc_client_unset_custom_event_received_cb( + client, + ); + } + + late final _mc_client_unset_custom_event_received_cb_ptr = + _lookup>( + 'mc_client_unset_custom_event_received_cb'); + late final _dart_mc_client_unset_custom_event_received_cb + _mc_client_unset_custom_event_received_cb = + _mc_client_unset_custom_event_received_cb_ptr + .asFunction<_dart_mc_client_unset_custom_event_received_cb>(); + + /// @MOBILE_ONLY + /// @brief Replies with the result of the requested event to the media controller server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @remarks The media controller client get the @a server_name and @a request_id through the mc_client_custom_event_received_cb(). + /// If @a request_id is not null there, the media controller client should send the reply to the media controller server with the @a request_id. \n + /// If @a request_id is null, this function will return #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER. + /// + /// @param[in] client The handle to the media controller client + /// @param[in] server_name The app_id of the media controller server + /// @param[in] request_id The id of the event request, received in the mc_client_set_custom_event_received_cb() function. + /// @param[in] result_code The result code of custom event + /// @param[in] data The extra data + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller server handle by calling mc_server_create(). + /// @see mc_client_create() + /// @see mc_client_set_custom_event_received_cb() + /// @see mc_client_unset_custom_event_received_cb() + /// @see mc_client_destroy() + int mc_client_send_event_reply( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer request_id, + int result_code, + ffi.Pointer data, + ) { + return _mc_client_send_event_reply( + client, + server_name, + request_id, + result_code, + data, + ); + } + + late final _mc_client_send_event_reply_ptr = + _lookup>( + 'mc_client_send_event_reply'); + late final _dart_mc_client_send_event_reply _mc_client_send_event_reply = + _mc_client_send_event_reply_ptr + .asFunction<_dart_mc_client_send_event_reply>(); + + /// @brief Subscribes media controller server for monitoring status. + /// @details If media controller client subscribe media controller server, \n + /// the media controller client receive callback from subscribed media controller server. \n + /// If media controller client subscribe media controller server one or more, \n + /// the media controller client can receive callback from only subscribed media controller server. \n + /// If you want to subscribe for the all media controller server again, \n + /// unset mode update callback and set the callback for the monitoring status again. \n + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] subscription_type The subscription type + /// @param[in] server_name The app_id of the media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create() + /// @pre Set the callback for monitoring status of the media controller server + /// @post Unsubscribe the media controller server for monitoring status by calling mc_client_unsubscribe() + /// @see mc_client_create() + /// @see mc_client_unsubscribe() + int mc_client_subscribe( + ffi.Pointer client, + int subscription_type, + ffi.Pointer server_name, + ) { + return _mc_client_subscribe( + client, + subscription_type, + server_name, + ); + } + + late final _mc_client_subscribe_ptr = + _lookup>( + 'mc_client_subscribe'); + late final _dart_mc_client_subscribe _mc_client_subscribe = + _mc_client_subscribe_ptr.asFunction<_dart_mc_client_subscribe>(); + + /// @brief Unsubscribes media controller server for monitoring status. + /// @details If media controller client unsubscribe media controller server, \n + /// the media controller client don't receive callback from unsubscribed media controller server. \n + /// If media controller client unsubscribe all subscribed media controller server, \n + /// the media controller client don't receive callback from all media controller server. \n + /// After unset and set update callback function is called again, the media controller client can receive callback from all media controller servers. \n + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] subscription_type The subscription type + /// @param[in] server_name The app_id of the media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create() + /// @pre Subscribe the media controller server for monitoring status by calling mc_client_subscribe() + /// @see mc_client_create() + /// @see mc_client_subscribe() + int mc_client_unsubscribe( + ffi.Pointer client, + int subscription_type, + ffi.Pointer server_name, + ) { + return _mc_client_unsubscribe( + client, + subscription_type, + server_name, + ); + } + + late final _mc_client_unsubscribe_ptr = + _lookup>( + 'mc_client_unsubscribe'); + late final _dart_mc_client_unsubscribe _mc_client_unsubscribe = + _mc_client_unsubscribe_ptr.asFunction<_dart_mc_client_unsubscribe>(); + + /// @brief Retrieves all subscribed Server. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] subscription_type The subscription type + /// @param[in] callback The callback to be invoked when the list of the subscribed media controller server. + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create() + /// @pre Subscribe the media controller server for monitoring status by calling mc_client_subscribe() + /// @see mc_client_create() + /// @see mc_client_subscribe() + int mc_client_foreach_server_subscribed( + ffi.Pointer client, + int subscription_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_foreach_server_subscribed( + client, + subscription_type, + callback, + user_data, + ); + } + + late final _mc_client_foreach_server_subscribed_ptr = + _lookup>( + 'mc_client_foreach_server_subscribed'); + late final _dart_mc_client_foreach_server_subscribed + _mc_client_foreach_server_subscribed = + _mc_client_foreach_server_subscribed_ptr + .asFunction<_dart_mc_client_foreach_server_subscribed>(); + + /// @brief Gets the playback state. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] playback The handle to playback + /// @param[out] state The state of the playback + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre The playback update callback should be set with @if MOBILE mc_client_set_playback_updated_cb() @elseif WEARABLE mc_client_set_playback_update_cb() @endif. + /// @see @if MOBILE mc_client_set_playback_updated_cb() @elseif WEARABLE mc_client_set_playback_update_cb() @endif + int mc_client_get_playback_state( + ffi.Pointer playback, + ffi.Pointer state, + ) { + return _mc_client_get_playback_state( + playback, + state, + ); + } + + late final _mc_client_get_playback_state_ptr = + _lookup>( + 'mc_client_get_playback_state'); + late final _dart_mc_client_get_playback_state _mc_client_get_playback_state = + _mc_client_get_playback_state_ptr + .asFunction<_dart_mc_client_get_playback_state>(); + + /// @brief Gets the playback position. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] playback The handle to playback + /// @param[out] position The position of the playback in milliseconds + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre The playback update callback should be set with @if MOBILE mc_client_set_playback_updated_cb() @elseif WEARABLE mc_client_set_playback_update_cb() @endif. + /// @see @if MOBILE mc_client_set_playback_updated_cb() @elseif WEARABLE mc_client_set_playback_update_cb() @endif + int mc_client_get_playback_position( + ffi.Pointer playback, + ffi.Pointer position, + ) { + return _mc_client_get_playback_position( + playback, + position, + ); + } + + late final _mc_client_get_playback_position_ptr = + _lookup>( + 'mc_client_get_playback_position'); + late final _dart_mc_client_get_playback_position + _mc_client_get_playback_position = _mc_client_get_playback_position_ptr + .asFunction<_dart_mc_client_get_playback_position>(); + + /// @MOBILE_ONLY + /// @brief Gets the index of the media in playlist. + /// @details Gets the index of the current playing media in a playlist. If the media controller server didn't set the index, the value is NULL. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @remarks The @a index should be released using free(). + /// + /// @param[in] playback The handle to playback + /// @param[out] index The index of the media + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre The playback update callback should be set with mc_client_set_playback_updated_cb(). + /// @see mc_client_set_playback_updated_cb() + /// @see mc_client_foreach_server_playlist() + int mc_client_get_playlist_item_index( + ffi.Pointer playback, + ffi.Pointer> index, + ) { + return _mc_client_get_playlist_item_index( + playback, + index, + ); + } + + late final _mc_client_get_playlist_item_index_ptr = + _lookup>( + 'mc_client_get_playlist_item_index'); + late final _dart_mc_client_get_playlist_item_index + _mc_client_get_playlist_item_index = + _mc_client_get_playlist_item_index_ptr + .asFunction<_dart_mc_client_get_playlist_item_index>(); + + /// @brief Destroys playback. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] playback The handle to playback + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see @if MOBILE mc_client_set_playback_updated_cb() @elseif WEARABLE mc_client_set_playback_update_cb() @endif + /// @see mc_client_get_server_playback_info() + int mc_client_destroy_playback( + ffi.Pointer playback, + ) { + return _mc_client_destroy_playback( + playback, + ); + } + + late final _mc_client_destroy_playback_ptr = + _lookup>( + 'mc_client_destroy_playback'); + late final _dart_mc_client_destroy_playback _mc_client_destroy_playback = + _mc_client_destroy_playback_ptr + .asFunction<_dart_mc_client_destroy_playback>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_metadata_get() instead. @endif + /// @brief Gets the metadata. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a metadata should be released using @c mc_client_destroy_metadata(). \n + /// And also The @a value should be released using free(). + /// If the attribute value of the metadata is empty, return value is NULL. + /// + /// @param[in] metadata The handle to metadata + /// @param[in] attribute The key attribute name to get + /// @param[out] value The value of the attribute + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre Sets mc_client_set_metadata_update_cb() function to get the metadata + /// @see mc_client_set_metadata_update_cb() + int mc_client_get_metadata( + ffi.Pointer metadata, + int attribute, + ffi.Pointer> value, + ) { + return _mc_client_get_metadata( + metadata, + attribute, + value, + ); + } + + late final _mc_client_get_metadata_ptr = + _lookup>( + 'mc_client_get_metadata'); + late final _dart_mc_client_get_metadata _mc_client_get_metadata = + _mc_client_get_metadata_ptr.asFunction<_dart_mc_client_get_metadata>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_metadata_destroy() instead. @endif + /// @brief Destroys metadata. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] metadata The handle to metadata + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre Sets mc_client_set_metadata_update_cb() function to create metadata + /// @see mc_client_set_metadata_update_cb() + int mc_client_destroy_metadata( + ffi.Pointer metadata, + ) { + return _mc_client_destroy_metadata( + metadata, + ); + } + + late final _mc_client_destroy_metadata_ptr = + _lookup>( + 'mc_client_destroy_metadata'); + late final _dart_mc_client_destroy_metadata _mc_client_destroy_metadata = + _mc_client_destroy_metadata_ptr + .asFunction<_dart_mc_client_destroy_metadata>(); + + /// @brief Gets the latest media controller server info. + /// @details The media controller client will get the most recently updated information by the server. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @remarks The @a server_name should be released using free(). \n + /// If there is no activated media controller server, return value of the server name is NULL. \n + /// Before a media controller server sets the playback state to #MC_PLAYBACK_STATE_PLAYING, the @a server_state is #MC_SERVER_STATE_NONE. + /// After a media controller server sets the playback state to #MC_PLAYBACK_STATE_PLAYING, the @a server_state is #MC_SERVER_STATE_ACTIVATE. + /// After a media controller server is destroyed, @a server_state is #MC_SERVER_STATE_DEACTIVATE. + /// + /// @param[in] client The handle to the media controller client + /// @param[out] server_name The app_id of the latest media controller server + /// @param[out] server_state The state of the latest media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + int mc_client_get_latest_server_info( + ffi.Pointer client, + ffi.Pointer> server_name, + ffi.Pointer server_state, + ) { + return _mc_client_get_latest_server_info( + client, + server_name, + server_state, + ); + } + + late final _mc_client_get_latest_server_info_ptr = + _lookup>( + 'mc_client_get_latest_server_info'); + late final _dart_mc_client_get_latest_server_info + _mc_client_get_latest_server_info = _mc_client_get_latest_server_info_ptr + .asFunction<_dart_mc_client_get_latest_server_info>(); + + /// @brief Gets the latest playback info. + /// @details The media controller client will get the most recently updated information from @a server_name. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @remarks The @a playback should be released using @c mc_client_destroy_playback(). \n + /// If there is no playback info, return value of the playback is NULL. + /// + /// @param[in] client The handle to the media controller client + /// @param[in] server_name The app_id of the media controller server + /// @param[out] playback The handle to playback + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + int mc_client_get_server_playback_info( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer> playback, + ) { + return _mc_client_get_server_playback_info( + client, + server_name, + playback, + ); + } + + late final _mc_client_get_server_playback_info_ptr = + _lookup>( + 'mc_client_get_server_playback_info'); + late final _dart_mc_client_get_server_playback_info + _mc_client_get_server_playback_info = + _mc_client_get_server_playback_info_ptr + .asFunction<_dart_mc_client_get_server_playback_info>(); + + /// @brief Gets the latest metadata. + /// @details The media controller client will get the most recently updated information from @a server_name. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @remarks The @a metadata should be released using @if MOBILE @c mc_metadata_destroy() @elseif @c mc_client_destroy_metadata(). @endif\n + /// If there is no metadata, return value of the metadata is NULL. + /// + /// @param[in] client The handle to the media controller client + /// @param[in] server_name The app_id of the media controller server + /// @param[out] metadata The handle to metadata + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + int mc_client_get_server_metadata( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer> metadata, + ) { + return _mc_client_get_server_metadata( + client, + server_name, + metadata, + ); + } + + late final _mc_client_get_server_metadata_ptr = + _lookup>( + 'mc_client_get_server_metadata'); + late final _dart_mc_client_get_server_metadata + _mc_client_get_server_metadata = _mc_client_get_server_metadata_ptr + .asFunction<_dart_mc_client_get_server_metadata>(); + + /// @brief Gets the latest shuffle mode. + /// @details The media controller client will get the most recently updated information from @a server_name. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @remarks If there is no shuffle mode info, return value is #MC_SHUFFLE_MODE_OFF. + /// + /// @param[in] client The handle to the media controller client + /// @param[in] server_name The app_id of the media controller server + /// @param[out] mode The info of the latest shuffle mode + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + int mc_client_get_server_shuffle_mode( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer mode, + ) { + return _mc_client_get_server_shuffle_mode( + client, + server_name, + mode, + ); + } + + late final _mc_client_get_server_shuffle_mode_ptr = + _lookup>( + 'mc_client_get_server_shuffle_mode'); + late final _dart_mc_client_get_server_shuffle_mode + _mc_client_get_server_shuffle_mode = + _mc_client_get_server_shuffle_mode_ptr + .asFunction<_dart_mc_client_get_server_shuffle_mode>(); + + /// @brief Gets the latest repeat mode. + /// @details The media controller client will get the most recently updated information from @a server_name. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @remarks If there is no repeat mode info, return value is #MC_REPEAT_MODE_OFF. + /// + /// @param[in] client The handle to the media controller client + /// @param[in] server_name The app_id of the media controller server + /// @param[out] mode The info of the latest shuffle mode + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + int mc_client_get_server_repeat_mode( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer mode, + ) { + return _mc_client_get_server_repeat_mode( + client, + server_name, + mode, + ); + } + + late final _mc_client_get_server_repeat_mode_ptr = + _lookup>( + 'mc_client_get_server_repeat_mode'); + late final _dart_mc_client_get_server_repeat_mode + _mc_client_get_server_repeat_mode = _mc_client_get_server_repeat_mode_ptr + .asFunction<_dart_mc_client_get_server_repeat_mode>(); + + /// @brief Retrieves all created servers. + /// @details This function gets all created media controller servers. + /// The callback function will be invoked for every created media controller server. + /// If there are no media controller servers, the callback will not be invoked. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] callback The callback function to be invoked, will be called for each server + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + int mc_client_foreach_server( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_foreach_server( + client, + callback, + user_data, + ); + } + + late final _mc_client_foreach_server_ptr = + _lookup>( + 'mc_client_foreach_server'); + late final _dart_mc_client_foreach_server _mc_client_foreach_server = + _mc_client_foreach_server_ptr + .asFunction<_dart_mc_client_foreach_server>(); + + /// @MOBILE_ONLY + /// @brief Retrieves all playlists of the media controller server. + /// @details This function gets all playlists of the media controller server. + /// The callback function will be invoked for every retrieved playlist. + /// If there are no playlists, the callback will not be invoked. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] server_name The app_id of the media controller server + /// @param[in] callback The callback function to be invoked. + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_playlist_cb() + int mc_client_foreach_server_playlist( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_foreach_server_playlist( + client, + server_name, + callback, + user_data, + ); + } + + late final _mc_client_foreach_server_playlist_ptr = + _lookup>( + 'mc_client_foreach_server_playlist'); + late final _dart_mc_client_foreach_server_playlist + _mc_client_foreach_server_playlist = + _mc_client_foreach_server_playlist_ptr + .asFunction<_dart_mc_client_foreach_server_playlist>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_client_send_playback_action_cmd() instead. @endif + /// @brief Sends the playback state command to server. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] server_name The app_id of the media controller server + /// @param[in] state The playback state to send to media controller server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_get_server_playback_info() + int mc_client_send_playback_state_command( + ffi.Pointer client, + ffi.Pointer server_name, + int state, + ) { + return _mc_client_send_playback_state_command( + client, + server_name, + state, + ); + } + + late final _mc_client_send_playback_state_command_ptr = + _lookup>( + 'mc_client_send_playback_state_command'); + late final _dart_mc_client_send_playback_state_command + _mc_client_send_playback_state_command = + _mc_client_send_playback_state_command_ptr + .asFunction<_dart_mc_client_send_playback_state_command>(); + + /// @MOBILE_ONLY + /// @brief Sends the playback action command to server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @remarks The @a request_id should be released using free().\n + /// If the @a request_id is null, the server will not send the reply of the command. + /// + /// @param[in] client The handle to the media controller client + /// @param[in] server_name The app_id of the media controller server + /// @param[in] action The playback action command to send to the media controller server + /// @param[out] request_id The id of the command request, it will be passed to the mc_cmd_reply_received_cb() function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_get_server_playback_info() + /// @see mc_client_set_cmd_reply_received_cb() + int mc_client_send_playback_action_cmd( + ffi.Pointer client, + ffi.Pointer server_name, + int action, + ffi.Pointer> request_id, + ) { + return _mc_client_send_playback_action_cmd( + client, + server_name, + action, + request_id, + ); + } + + late final _mc_client_send_playback_action_cmd_ptr = + _lookup>( + 'mc_client_send_playback_action_cmd'); + late final _dart_mc_client_send_playback_action_cmd + _mc_client_send_playback_action_cmd = + _mc_client_send_playback_action_cmd_ptr + .asFunction<_dart_mc_client_send_playback_action_cmd>(); + + /// @MOBILE_ONLY + /// @brief Sends the playback position command to server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @remarks The @a request_id should be released using free().\n + /// If the @a request_id is null, the server will not send the reply of the command. + /// + /// @param[in] client The handle to the media controller client + /// @param[in] server_name The app_id of the media controller server + /// @param[in] position The position of the playback in milliseconds to send to media controller server. + /// @param[out] request_id The id of the command request, it will be passed to the mc_cmd_reply_received_cb() function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_get_server_playback_info() + /// @see mc_client_set_cmd_reply_received_cb() + int mc_client_send_playback_position_cmd( + ffi.Pointer client, + ffi.Pointer server_name, + int position, + ffi.Pointer> request_id, + ) { + return _mc_client_send_playback_position_cmd( + client, + server_name, + position, + request_id, + ); + } + + late final _mc_client_send_playback_position_cmd_ptr = + _lookup>( + 'mc_client_send_playback_position_cmd'); + late final _dart_mc_client_send_playback_position_cmd + _mc_client_send_playback_position_cmd = + _mc_client_send_playback_position_cmd_ptr + .asFunction<_dart_mc_client_send_playback_position_cmd>(); + + /// @MOBILE_ONLY + /// @brief Sends the shuffle mode command to server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @remarks The @a request_id should be released using free().\n + /// If the @a request_id is null, the server will not send the reply of the command. + /// + /// @param[in] client The handle to the media controller client + /// @param[in] server_name The app_id of the media controller server + /// @param[in] shuffle_mode The shuffle mode to send to media controller server + /// @param[out] request_id The id of the command request, it will be passed to the mc_cmd_reply_received_cb() function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_get_server_playback_info() + /// @see mc_client_set_cmd_reply_received_cb() + int mc_client_send_shuffle_mode_cmd( + ffi.Pointer client, + ffi.Pointer server_name, + int shuffle_mode, + ffi.Pointer> request_id, + ) { + return _mc_client_send_shuffle_mode_cmd( + client, + server_name, + shuffle_mode, + request_id, + ); + } + + late final _mc_client_send_shuffle_mode_cmd_ptr = + _lookup>( + 'mc_client_send_shuffle_mode_cmd'); + late final _dart_mc_client_send_shuffle_mode_cmd + _mc_client_send_shuffle_mode_cmd = _mc_client_send_shuffle_mode_cmd_ptr + .asFunction<_dart_mc_client_send_shuffle_mode_cmd>(); + + /// @MOBILE_ONLY + /// @brief Sends the repeat mode command to server. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @remarks The @a request_id should be released using free().\n + /// If the @a request_id is null, the server will not send the reply of the command. + /// + /// @param[in] client The handle to the media controller client + /// @param[in] server_name The app_id of the media controller server + /// @param[in] repeat_mode The repeat mode to send to media controller server + /// @param[out] request_id The id of the command request, it will be passed to the mc_cmd_reply_received_cb() function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_get_server_playback_info() + /// @see mc_client_set_cmd_reply_received_cb() + int mc_client_send_repeat_mode_cmd( + ffi.Pointer client, + ffi.Pointer server_name, + int repeat_mode, + ffi.Pointer> request_id, + ) { + return _mc_client_send_repeat_mode_cmd( + client, + server_name, + repeat_mode, + request_id, + ); + } + + late final _mc_client_send_repeat_mode_cmd_ptr = + _lookup>( + 'mc_client_send_repeat_mode_cmd'); + late final _dart_mc_client_send_repeat_mode_cmd + _mc_client_send_repeat_mode_cmd = _mc_client_send_repeat_mode_cmd_ptr + .asFunction<_dart_mc_client_send_repeat_mode_cmd>(); + + /// @deprecated Deprecated since 4.0. @if MOBILE Use mc_client_send_custom_cmd() instead. @endif + /// @brief Sends the custom command to server. + /// @details If there is the result for command from server, the media controller client will get the result of the custom command by mc_command_reply_received_cb() callback. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @param[in] client The handle to the media controller client + /// @param[in] server_name The app_id of the media controller server + /// @param[in] command The command to be sent + /// @param[in] data The extra data + /// @param[in] callback The callback to be invoked when the custom command execute completely. + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + int mc_client_send_custom_command( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer command, + ffi.Pointer data, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mc_client_send_custom_command( + client, + server_name, + command, + data, + callback, + user_data, + ); + } + + late final _mc_client_send_custom_command_ptr = + _lookup>( + 'mc_client_send_custom_command'); + late final _dart_mc_client_send_custom_command + _mc_client_send_custom_command = _mc_client_send_custom_command_ptr + .asFunction<_dart_mc_client_send_custom_command>(); + + /// @MOBILE_ONLY + /// @brief Sends the playlist command to server. + /// @details The media controller client can send "index" of the playlist to the media controller server with playback action and position. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @remarks The @a request_id should be released using free().\n + /// If the @a request_id is null, the server will not send the reply of the command. + /// + /// @param[in] client The handle to the media controller client + /// @param[in] server_name The app_id of the media controller server + /// @param[in] playlist_name The playlist name of the server + /// @param[in] index The index of the media in playlist to send to the media controller server + /// @param[in] action The playback action command to send to the media controller server + /// @param[in] position The position of the playback in milliseconds to send to media controller server + /// @param[out] request_id The id of the command request, it will be passed to the mc_cmd_reply_received_cb() function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_set_cmd_reply_received_cb() + int mc_client_send_playlist_cmd( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer playlist_name, + ffi.Pointer index, + int action, + int position, + ffi.Pointer> request_id, + ) { + return _mc_client_send_playlist_cmd( + client, + server_name, + playlist_name, + index, + action, + position, + request_id, + ); + } + + late final _mc_client_send_playlist_cmd_ptr = + _lookup>( + 'mc_client_send_playlist_cmd'); + late final _dart_mc_client_send_playlist_cmd _mc_client_send_playlist_cmd = + _mc_client_send_playlist_cmd_ptr + .asFunction<_dart_mc_client_send_playlist_cmd>(); + + /// @MOBILE_ONLY + /// @brief Sends the custom command to server. + /// @details If the server sends the result of the command, the media controller client will get the result of the custom command by mc_cmd_reply_received_cb() callback. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/mediacontroller.client + /// + /// @remarks The @a request_id should be released using free().\n + /// If the @a request_id is null, the server will not send the reply of the command. + /// + /// @param[in] client The handle to the media controller client + /// @param[in] server_name The app_id of the media controller server + /// @param[in] command The command to be sent + /// @param[in] data The extra data + /// @param[out] request_id The id of the command request, it will be passed to the mc_cmd_reply_received_cb() function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_CONTROLLER_ERROR_NONE Successful + /// @retval #MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + /// @see mc_client_set_cmd_reply_received_cb() + int mc_client_send_custom_cmd( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer command, + ffi.Pointer data, + ffi.Pointer> request_id, + ) { + return _mc_client_send_custom_cmd( + client, + server_name, + command, + data, + request_id, + ); + } + + late final _mc_client_send_custom_cmd_ptr = + _lookup>( + 'mc_client_send_custom_cmd'); + late final _dart_mc_client_send_custom_cmd _mc_client_send_custom_cmd = + _mc_client_send_custom_cmd_ptr + .asFunction<_dart_mc_client_send_custom_cmd>(); + + /// @brief Destroys client. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] client The handle to the media controller client + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #METADATA_EXTRACTOR_ERROR_NONE Successful + /// @retval #METADATA_EXTRACTOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre Create a media controller client handle by calling mc_client_create(). + /// @see mc_client_create() + int mc_client_destroy( + ffi.Pointer client, + ) { + return _mc_client_destroy( + client, + ); + } + + late final _mc_client_destroy_ptr = + _lookup>('mc_client_destroy'); + late final _dart_mc_client_destroy _mc_client_destroy = + _mc_client_destroy_ptr.asFunction<_dart_mc_client_destroy>(); + + /// @brief Creates a media demuxer handle for demuxing. + /// @since_tizen 3.0 + /// @remarks You must release @a demuxer using mediademuxer_destroy() function. + /// @param[out] demuxer A new handle to media demuxer + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_OPERATION Invalid Operation + /// @retval #MEDIADEMUXER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @post The media demuxer state will be #MEDIADEMUXER_STATE_IDLE. + /// @see mediademuxer_destroy() + int mediademuxer_create( + ffi.Pointer> demuxer, + ) { + return _mediademuxer_create( + demuxer, + ); + } + + late final _mediademuxer_create_ptr = + _lookup>( + 'mediademuxer_create'); + late final _dart_mediademuxer_create _mediademuxer_create = + _mediademuxer_create_ptr.asFunction<_dart_mediademuxer_create>(); + + /// @brief Sets the source path of input stream. + /// @since_tizen 3.0 + /// @remarks The mediastorage privilege(http://tizen.org/privilege/mediastorage) should be added if any video/audio files are used to play located in the internal storage. + /// @remarks The externalstorage privilege(http://tizen.org/privilege/externalstorage) should be added if any video/audio files are used to play located in the external storage. + /// @remarks You must release @a demuxer using mediademuxer_destroy() function. + /// @param[in] demuxer The media demuxer handle + /// @param[in] path The content location, such as the file path + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIADEMUXER_ERROR_INVALID_OPERATION Invalid Operation + /// @retval #MEDIADEMUXER_ERROR_INVALID_PATH Invalid path + /// @pre The media muxer state will be #MEDIADEMUXER_STATE_IDLE by calling mediademuxer_create() function. + int mediademuxer_set_data_source( + ffi.Pointer demuxer, + ffi.Pointer path, + ) { + return _mediademuxer_set_data_source( + demuxer, + path, + ); + } + + late final _mediademuxer_set_data_source_ptr = + _lookup>( + 'mediademuxer_set_data_source'); + late final _dart_mediademuxer_set_data_source _mediademuxer_set_data_source = + _mediademuxer_set_data_source_ptr + .asFunction<_dart_mediademuxer_set_data_source>(); + + /// @brief Prepares the media demuxer for demuxing. + /// @since_tizen 3.0 + /// @remark User should call this before mediademuxer_start() function. + /// @param[in] demuxer The media demuxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIADEMUXER_ERROR_INVALID_OPERATION Invalid Operation + /// @pre The media demuxer state should be #MEDIADEMUXER_STATE_IDLE. + /// @pre mediademuxer_set_error_cb should be called before mediademuxer_prepare(). + /// @post The media demuxer state will be #MEDIADEMUXER_STATE_READY. + /// @see mediademuxer_set_data_source() + /// @see mediademuxer_unprepare() + int mediademuxer_prepare( + ffi.Pointer demuxer, + ) { + return _mediademuxer_prepare( + demuxer, + ); + } + + late final _mediademuxer_prepare_ptr = + _lookup>( + 'mediademuxer_prepare'); + late final _dart_mediademuxer_prepare _mediademuxer_prepare = + _mediademuxer_prepare_ptr.asFunction<_dart_mediademuxer_prepare>(); + + /// @brief Gets the total track count present in the container stream. + /// @since_tizen 3.0 + /// @param[in] demuxer The media demuxer handle + /// @param[out] count The number of tracks present + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIADEMUXER_ERROR_INVALID_OPERATION Invalid Operation + /// @pre The media demuxer state should be #MEDIADEMUXER_STATE_READY. + /// @see mediademuxer_prepare() + /// @see mediademuxer_select_track() + int mediademuxer_get_track_count( + ffi.Pointer demuxer, + ffi.Pointer count, + ) { + return _mediademuxer_get_track_count( + demuxer, + count, + ); + } + + late final _mediademuxer_get_track_count_ptr = + _lookup>( + 'mediademuxer_get_track_count'); + late final _dart_mediademuxer_get_track_count _mediademuxer_get_track_count = + _mediademuxer_get_track_count_ptr + .asFunction<_dart_mediademuxer_get_track_count>(); + + /// @brief Selects the track to be performed. + /// @since_tizen 3.0 + /// @param[in] demuxer The media demuxer handle + /// @param[in] track_index The track index on which is selected for read + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIADEMUXER_ERROR_INVALID_OPERATION Invalid Operation + /// @pre The media demuxer state should be #MEDIADEMUXER_STATE_READY. + /// @see mediademuxer_get_track_count() + /// @see mediademuxer_start() + int mediademuxer_select_track( + ffi.Pointer demuxer, + int track_index, + ) { + return _mediademuxer_select_track( + demuxer, + track_index, + ); + } + + late final _mediademuxer_select_track_ptr = + _lookup>( + 'mediademuxer_select_track'); + late final _dart_mediademuxer_select_track _mediademuxer_select_track = + _mediademuxer_select_track_ptr + .asFunction<_dart_mediademuxer_select_track>(); + + /// @brief Starts the media demuxer. + /// @since_tizen 3.0 + /// @remark User should call this before mediademuxer_read_sample() function. + /// @param[in] demuxer The media demuxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIADEMUXER_ERROR_INVALID_OPERATION Invalid Operation + /// @pre The media demuxer state should be #MEDIADEMUXER_STATE_READY. + /// @post The media demuxer state will be #MEDIADEMUXER_STATE_DEMUXING. + /// @see mediademuxer_prepare() + /// @see mediademuxer_get_track_count() + /// @see mediademuxer_select_track() + /// @see mediademuxer_get_track_info() + int mediademuxer_start( + ffi.Pointer demuxer, + ) { + return _mediademuxer_start( + demuxer, + ); + } + + late final _mediademuxer_start_ptr = + _lookup>('mediademuxer_start'); + late final _dart_mediademuxer_start _mediademuxer_start = + _mediademuxer_start_ptr.asFunction<_dart_mediademuxer_start>(); + + /// @brief Retrieves the track format of the read sample. + /// @since_tizen 3.0 + /// @remarks The @a format should be released using media_format_unref() function. + /// @param[in] demuxer The media demuxer handle + /// @param[in] track_index The index of the track + /// @param[out] format The media format handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIADEMUXER_ERROR_INVALID_OPERATION Invalid Operation + /// @pre The media demuxer state must be set to #MEDIADEMUXER_STATE_DEMUXING by calling + /// mediademuxer_start() or set to #MEDIADEMUXER_STATE_READY by calling mediademuxer_prepare(). + /// @see mediademuxer_get_track_count() + /// @see mediademuxer_select_track() + /// @see media_format_unref() + /// @see #media_format_h + int mediademuxer_get_track_info( + ffi.Pointer demuxer, + int track_index, + ffi.Pointer> format, + ) { + return _mediademuxer_get_track_info( + demuxer, + track_index, + format, + ); + } + + late final _mediademuxer_get_track_info_ptr = + _lookup>( + 'mediademuxer_get_track_info'); + late final _dart_mediademuxer_get_track_info _mediademuxer_get_track_info = + _mediademuxer_get_track_info_ptr + .asFunction<_dart_mediademuxer_get_track_info>(); + + /// @brief Reads a frame(sample) of one single track. + /// @since_tizen 3.0 + /// @remark The @a outbuf should be released using media_packet_destroy() function. + /// @remark Once this API is called, user app can call the mediatool APIs to extract + /// side information such as pts, size, duration, flags etc. + /// @param[in] demuxer The media demuxer handle + /// @param[in] track_index The index of track of which data is needed + /// @param[out] outbuf The media packet handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIADEMUXER_ERROR_INVALID_OPERATION Invalid Operation + /// @pre The media demuxer state should be #MEDIADEMUXER_STATE_DEMUXING. + /// @see mediademuxer_start() + /// @see mediademuxer_get_track_info() + /// @see mediademuxer_seek() if need to seek to a particular location + /// @see mediademuxer_unselect_track() + /// @see mediademuxer_stop() + /// @see media_packet_destroy() + /// @see #media_packet_h + int mediademuxer_read_sample( + ffi.Pointer demuxer, + int track_index, + ffi.Pointer> outbuf, + ) { + return _mediademuxer_read_sample( + demuxer, + track_index, + outbuf, + ); + } + + late final _mediademuxer_read_sample_ptr = + _lookup>( + 'mediademuxer_read_sample'); + late final _dart_mediademuxer_read_sample _mediademuxer_read_sample = + _mediademuxer_read_sample_ptr + .asFunction<_dart_mediademuxer_read_sample>(); + + /// @brief Seeks to a particular instance of time (in milli seconds). + /// @since_tizen 3.0 + /// @remark If mediademuxer_seek() is followed by mediademuxer_read_sample(), outbuf will be the key frame right before the seek position. + /// @param[in] demuxer The media demuxer handle + /// @param[in] pos The value of the new start position + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIADEMUXER_ERROR_INVALID_OPERATION Invalid Operation + /// @pre The media demuxer state should be #MEDIADEMUXER_STATE_DEMUXING. + /// @see mediademuxer_read_sample() + /// @see mediademuxer_stop() + int mediademuxer_seek( + ffi.Pointer demuxer, + int pos, + ) { + return _mediademuxer_seek( + demuxer, + pos, + ); + } + + late final _mediademuxer_seek_ptr = + _lookup>('mediademuxer_seek'); + late final _dart_mediademuxer_seek _mediademuxer_seek = + _mediademuxer_seek_ptr.asFunction<_dart_mediademuxer_seek>(); + + /// @brief Unselects the selected track. + /// @since_tizen 3.0 + /// @param[in] demuxer The media demuxer handle + /// @param[in] track_index The track index to be unselected + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIADEMUXER_ERROR_INVALID_OPERATION Invalid Operation + /// @pre The media demuxer state must be set to #MEDIADEMUXER_STATE_DEMUXING by calling + /// mediademuxer_read_sample() or set to #MEDIADEMUXER_STATE_READY by calling mediademuxer_select_track(). + /// @see mediademuxer_select_track() + /// @see mediademuxer_read_sample() + int mediademuxer_unselect_track( + ffi.Pointer demuxer, + int track_index, + ) { + return _mediademuxer_unselect_track( + demuxer, + track_index, + ); + } + + late final _mediademuxer_unselect_track_ptr = + _lookup>( + 'mediademuxer_unselect_track'); + late final _dart_mediademuxer_unselect_track _mediademuxer_unselect_track = + _mediademuxer_unselect_track_ptr + .asFunction<_dart_mediademuxer_unselect_track>(); + + /// @brief Stops the media demuxer. + /// @since_tizen 3.0 + /// @remark User can call this if need to stop demuxing if needed. + /// @param[in] demuxer The media demuxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIADEMUXER_ERROR_INVALID_OPERATION Invalid Operation + /// @pre The media demuxer state must be set to #MEDIADEMUXER_STATE_DEMUXING. + /// @post The media demuxer state will be in #MEDIADEMUXER_STATE_READY. + /// @see mediademuxer_start() + /// @see mediademuxer_unprepare() + int mediademuxer_stop( + ffi.Pointer demuxer, + ) { + return _mediademuxer_stop( + demuxer, + ); + } + + late final _mediademuxer_stop_ptr = + _lookup>('mediademuxer_stop'); + late final _dart_mediademuxer_stop _mediademuxer_stop = + _mediademuxer_stop_ptr.asFunction<_dart_mediademuxer_stop>(); + + /// @brief Resets the media demuxer. + /// @since_tizen 3.0 + /// @remarks User should call this before mediademuxer_destroy() function. + /// @param[in] demuxer The media demuxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIADEMUXER_ERROR_INVALID_OPERATION Invalid Operation + /// @pre The media demuxer state should be #MEDIADEMUXER_STATE_READY. + /// @post The media demuxer state will be #MEDIADEMUXER_STATE_IDLE. + /// @see mediademuxer_prepare() + int mediademuxer_unprepare( + ffi.Pointer demuxer, + ) { + return _mediademuxer_unprepare( + demuxer, + ); + } + + late final _mediademuxer_unprepare_ptr = + _lookup>( + 'mediademuxer_unprepare'); + late final _dart_mediademuxer_unprepare _mediademuxer_unprepare = + _mediademuxer_unprepare_ptr.asFunction<_dart_mediademuxer_unprepare>(); + + /// @brief Removes the instance of media demuxer and clear all its context memory. + /// @since_tizen 3.0 + /// @param[in] demuxer The media demuxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIADEMUXER_ERROR_INVALID_OPERATION Invalid Operation + /// @pre Create a media demuxer handle by calling mediademuxer_create() function. + /// @post The media demuxer state will be #MEDIADEMUXER_STATE_NONE. + /// @see mediademuxer_create() + int mediademuxer_destroy( + ffi.Pointer demuxer, + ) { + return _mediademuxer_destroy( + demuxer, + ); + } + + late final _mediademuxer_destroy_ptr = + _lookup>( + 'mediademuxer_destroy'); + late final _dart_mediademuxer_destroy _mediademuxer_destroy = + _mediademuxer_destroy_ptr.asFunction<_dart_mediademuxer_destroy>(); + + /// @brief Gets media demuxer state. + /// @since_tizen 3.0 + /// @param[in] demuxer The media demuxer handle + /// @param[out] state The media demuxer sate + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a media demuxer handle by calling mediademuxer_create() function. + /// @see #mediademuxer_state + int mediademuxer_get_state( + ffi.Pointer demuxer, + ffi.Pointer state, + ) { + return _mediademuxer_get_state( + demuxer, + state, + ); + } + + late final _mediademuxer_get_state_ptr = + _lookup>( + 'mediademuxer_get_state'); + late final _dart_mediademuxer_get_state _mediademuxer_get_state = + _mediademuxer_get_state_ptr.asFunction<_dart_mediademuxer_get_state>(); + + /// @brief Registers an error callback function to be invoked when an error occurs. + /// @since_tizen 3.0 + /// @param[in] demuxer The media demuxer handle + /// @param[in] callback Callback function pointer + /// @param[in] user_data The user data passed from the code where + /// mediademuxer_set_error_cb() was invoked + /// This data will be accessible from mediademuxer_error_cb() + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @pre Create a media demuxer handle by calling mediademuxer_create() function. + /// @post mediademuxer_error_cb() will be invoked. + /// @see mediademuxer_unset_error_cb() + /// @see mediademuxer_error_cb() + int mediademuxer_set_error_cb( + ffi.Pointer demuxer, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mediademuxer_set_error_cb( + demuxer, + callback, + user_data, + ); + } + + late final _mediademuxer_set_error_cb_ptr = + _lookup>( + 'mediademuxer_set_error_cb'); + late final _dart_mediademuxer_set_error_cb _mediademuxer_set_error_cb = + _mediademuxer_set_error_cb_ptr + .asFunction<_dart_mediademuxer_set_error_cb>(); + + /// @brief Unregisters the error callback function. + /// @since_tizen 3.0 + /// @param[in] demuxer The media demuxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @see mediademuxer_error_cb() + int mediademuxer_unset_error_cb( + ffi.Pointer demuxer, + ) { + return _mediademuxer_unset_error_cb( + demuxer, + ); + } + + late final _mediademuxer_unset_error_cb_ptr = + _lookup>( + 'mediademuxer_unset_error_cb'); + late final _dart_mediademuxer_unset_error_cb _mediademuxer_unset_error_cb = + _mediademuxer_unset_error_cb_ptr + .asFunction<_dart_mediademuxer_unset_error_cb>(); + + /// @brief Registers an eos callback function to be invoked when an eos occurs. + /// @since_tizen 3.0 + /// @param[in] demuxer The media demuxer handle + /// @param[in] callback Callback function pointer + /// @param[in] user_data The user data passed from the code where + /// mediademuxer_set_eos_cb() was invoked + /// This data will be accessible from mediademuxer_eos_cb() + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @pre Create a media demuxer handle by calling mediademuxer_create() function. + /// @post mediademuxer_eos_cb() will be invoked. + /// @see mediademuxer_unset_eos_cb() + /// @see mediademuxer_eos_cb() + int mediademuxer_set_eos_cb( + ffi.Pointer demuxer, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mediademuxer_set_eos_cb( + demuxer, + callback, + user_data, + ); + } + + late final _mediademuxer_set_eos_cb_ptr = + _lookup>( + 'mediademuxer_set_eos_cb'); + late final _dart_mediademuxer_set_eos_cb _mediademuxer_set_eos_cb = + _mediademuxer_set_eos_cb_ptr.asFunction<_dart_mediademuxer_set_eos_cb>(); + + /// @brief Unregisters the eos callback function. + /// @since_tizen 3.0 + /// @param[in] demuxer The media demuxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIADEMUXER_ERROR_NONE Successful + /// @retval #MEDIADEMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIADEMUXER_ERROR_INVALID_STATE Invalid state + /// @see mediademuxer_eos_cb() + int mediademuxer_unset_eos_cb( + ffi.Pointer demuxer, + ) { + return _mediademuxer_unset_eos_cb( + demuxer, + ); + } + + late final _mediademuxer_unset_eos_cb_ptr = + _lookup>( + 'mediademuxer_unset_eos_cb'); + late final _dart_mediademuxer_unset_eos_cb _mediademuxer_unset_eos_cb = + _mediademuxer_unset_eos_cb_ptr + .asFunction<_dart_mediademuxer_unset_eos_cb>(); + + /// @brief Creates a media muxer handle for muxing. + /// @since_tizen 3.0 + /// @param[out] muxer A new handle to media muxer + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_OPERATION Invalid Operation + /// @retval #MEDIAMUXER_ERROR_OUT_OF_MEMORY Allocation Failed, Out of Memory. + /// @post The media muxer state will be #MEDIAMUXER_STATE_IDLE. + /// @see mediamuxer_destroy() + int mediamuxer_create( + ffi.Pointer> muxer, + ) { + return _mediamuxer_create( + muxer, + ); + } + + late final _mediamuxer_create_ptr = + _lookup>('mediamuxer_create'); + late final _dart_mediamuxer_create _mediamuxer_create = + _mediamuxer_create_ptr.asFunction<_dart_mediamuxer_create>(); + + /// @brief Sets the sink path of output stream. + /// @since_tizen 3.0 + /// @remarks The mediastorage privilege(http://tizen.org/privilege/mediastorage) should be added if any video/audio files are to be saved in the internal storage. + /// @remarks The externalstorage privilege(http://tizen.org/privilege/externalstorage) should be added if any video/audio files are to be saved in the external storage. + /// @param[in] muxer A new handle to media muxer + /// @param[in] path The location of the output media file, such as the file path + /// This is the path at which the muxed file should be saved. + /// @param[in] format The format of the output media file + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIAMUXER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIAMUXER_ERROR_INVALID_PATH Invalid path + /// @pre The media muxer state will be #MEDIAMUXER_STATE_IDLE by calling mediamuxer_create + /// @see #mediamuxer_output_format_e + int mediamuxer_set_data_sink( + ffi.Pointer muxer, + ffi.Pointer path, + int format, + ) { + return _mediamuxer_set_data_sink( + muxer, + path, + format, + ); + } + + late final _mediamuxer_set_data_sink_ptr = + _lookup>( + 'mediamuxer_set_data_sink'); + late final _dart_mediamuxer_set_data_sink _mediamuxer_set_data_sink = + _mediamuxer_set_data_sink_ptr + .asFunction<_dart_mediamuxer_set_data_sink>(); + + /// @brief Adds the media track of interest to the muxer handle. + /// @since_tizen 3.0 + /// @param[in] muxer The media muxer handle + /// @param[in] media_format The format of media muxer + /// @param[out] track_index The index of the media track + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIAMUXER_ERROR_INVALID_STATE Invalid state + /// @pre The media muxer state must be set to #MEDIAMUXER_STATE_IDLE. + /// @see #media_format_h + /// @see mediamuxer_create() + /// @see mediamuxer_prepare() + int mediamuxer_add_track( + ffi.Pointer muxer, + ffi.Pointer media_format, + ffi.Pointer track_index, + ) { + return _mediamuxer_add_track( + muxer, + media_format, + track_index, + ); + } + + late final _mediamuxer_add_track_ptr = + _lookup>( + 'mediamuxer_add_track'); + late final _dart_mediamuxer_add_track _mediamuxer_add_track = + _mediamuxer_add_track_ptr.asFunction<_dart_mediamuxer_add_track>(); + + /// @brief Prepares the media muxer. + /// @remarks Initiates the necessary parameters. + /// @since_tizen 3.0 + /// @param[in] muxer The media muxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIAMUXER_ERROR_INVALID_STATE Invalid state + /// @pre The media muxer state must be set to #MEDIAMUXER_STATE_IDLE. + /// @post The media muxer state will be #MEDIAMUXER_STATE_READY. + /// @see mediamuxer_create() + /// @see mediamuxer_unprepare() + int mediamuxer_prepare( + ffi.Pointer muxer, + ) { + return _mediamuxer_prepare( + muxer, + ); + } + + late final _mediamuxer_prepare_ptr = + _lookup>('mediamuxer_prepare'); + late final _dart_mediamuxer_prepare _mediamuxer_prepare = + _mediamuxer_prepare_ptr.asFunction<_dart_mediamuxer_prepare>(); + + /// @brief Starts the media muxer. + /// @remarks Keeps the muxer ready for writing data. + /// @since_tizen 3.0 + /// @param[in] muxer The media muxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIAMUXER_ERROR_INVALID_STATE Invalid state + /// @pre The media muxer state must be set to #MEDIAMUXER_STATE_READY. + /// @post The media muxer state will be #MEDIAMUXER_STATE_MUXING. + /// @see mediamuxer_prepare() + /// @see mediamuxer_stop() + int mediamuxer_start( + ffi.Pointer muxer, + ) { + return _mediamuxer_start( + muxer, + ); + } + + late final _mediamuxer_start_ptr = + _lookup>('mediamuxer_start'); + late final _dart_mediamuxer_start _mediamuxer_start = + _mediamuxer_start_ptr.asFunction<_dart_mediamuxer_start>(); + + /// @brief Writes the media packet of interest to the muxer handle. + /// @since_tizen 3.0 + /// @param[in] muxer The media muxer handle + /// @param[in] track_index The index of the media track + /// @param[in] inbuf The packet of media muxer + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIAMUXER_ERROR_INVALID_STATE Invalid state + /// @pre The media muxer state must be set to #MEDIAMUXER_STATE_READY by calling mediamuxer_prepare() or + /// set to #MEDIAMUXER_STATE_PAUSED by calling mediamuxer_pause(). + /// @post The media muxer state will be #MEDIAMUXER_STATE_MUXING. + /// @see mediamuxer_prepare() + /// @see mediamuxer_close_track() + /// @see mediamuxer_pause() + /// @see #media_packet_h + int mediamuxer_write_sample( + ffi.Pointer muxer, + int track_index, + ffi.Pointer inbuf, + ) { + return _mediamuxer_write_sample( + muxer, + track_index, + inbuf, + ); + } + + late final _mediamuxer_write_sample_ptr = + _lookup>( + 'mediamuxer_write_sample'); + late final _dart_mediamuxer_write_sample _mediamuxer_write_sample = + _mediamuxer_write_sample_ptr.asFunction<_dart_mediamuxer_write_sample>(); + + /// @brief Closes the track from further writing of data. + /// @remarks For each added track, user needs to call this API to indicate the end of stream. + /// @since_tizen 3.0 + /// @param[in] muxer The media muxer handle + /// @param[in] track_index the selected track index + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIAMUXER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIAMUXER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The media muxer state must be set to #MEDIAMUXER_STATE_MUXING. + /// @see mediamuxer_write_sample() + /// @see mediamuxer_pause() + /// @see mediamuxer_unprepare() + /// @see #mediamuxer_error_e + int mediamuxer_close_track( + ffi.Pointer muxer, + int track_index, + ) { + return _mediamuxer_close_track( + muxer, + track_index, + ); + } + + late final _mediamuxer_close_track_ptr = + _lookup>( + 'mediamuxer_close_track'); + late final _dart_mediamuxer_close_track _mediamuxer_close_track = + _mediamuxer_close_track_ptr.asFunction<_dart_mediamuxer_close_track>(); + + /// @brief Pauses the media muxer. + /// @remarks To temporarily disable writing data for muxing. This API pauses a playing muxer + /// If the prior state of the muxer is not in PLAYING, no action will be taken. + /// @since_tizen 3.0 + /// @param[in] muxer The media muxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIAMUXER_ERROR_INVALID_STATE Invalid state + /// @pre The media muxer state must be set to #MEDIAMUXER_STATE_MUXING. + /// @post The media muxer state will be #MEDIAMUXER_STATE_PAUSED. + /// @see mediamuxer_write_sample() + /// @see mediamuxer_resume() + int mediamuxer_pause( + ffi.Pointer muxer, + ) { + return _mediamuxer_pause( + muxer, + ); + } + + late final _mediamuxer_pause_ptr = + _lookup>('mediamuxer_pause'); + late final _dart_mediamuxer_pause _mediamuxer_pause = + _mediamuxer_pause_ptr.asFunction<_dart_mediamuxer_pause>(); + + /// @brief Resumes the media muxer. + /// @remarks Make it ready for any further writing. This API will resume a paused muxer. + /// If the prior state of the muxer is not playing, no action will be taken. + /// @since_tizen 3.0 + /// @param[in] muxer The media muxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIAMUXER_ERROR_INVALID_STATE Invalid state + /// @pre The media muxer state must be set to #MEDIAMUXER_STATE_PAUSED. + /// @post The media muxer state will be #MEDIAMUXER_STATE_MUXING. + /// @see mediamuxer_pause() + int mediamuxer_resume( + ffi.Pointer muxer, + ) { + return _mediamuxer_resume( + muxer, + ); + } + + late final _mediamuxer_resume_ptr = + _lookup>('mediamuxer_resume'); + late final _dart_mediamuxer_resume _mediamuxer_resume = + _mediamuxer_resume_ptr.asFunction<_dart_mediamuxer_resume>(); + + /// @brief Stops the media muxer. + /// @remarks Keeps the muxer ready for writing data. + /// @since_tizen 3.0 + /// @param[in] muxer The media muxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIAMUXER_ERROR_INVALID_STATE Invalid state + /// @pre The media muxer state must be set to #MEDIAMUXER_STATE_MUXING + /// or #MEDIAMUXER_STATE_PAUSED. + /// @post The media muxer state will be #MEDIAMUXER_STATE_READY. + /// @see mediamuxer_start() + /// @see mediamuxer_unprepare() + int mediamuxer_stop( + ffi.Pointer muxer, + ) { + return _mediamuxer_stop( + muxer, + ); + } + + late final _mediamuxer_stop_ptr = + _lookup>('mediamuxer_stop'); + late final _dart_mediamuxer_stop _mediamuxer_stop = + _mediamuxer_stop_ptr.asFunction<_dart_mediamuxer_stop>(); + + /// @brief Unprepares the media muxer. + /// @remarks Unrefs the variables created after calling mediamuxer_prepare(). + /// @since_tizen 3.0 + /// @param[in] muxer The media muxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIAMUXER_ERROR_INVALID_STATE Invalid state + /// @pre The media muxer state must be set to #MEDIAMUXER_STATE_READY or + /// set to #MEDIAMUXER_STATE_PAUSED by calling mediamuxer_pause(). + /// @post The media muxer state will be #MEDIAMUXER_STATE_IDLE. + /// @see mediamuxer_write_sample() + /// @see mediamuxer_pause() + /// @see mediamuxer_destroy() + int mediamuxer_unprepare( + ffi.Pointer muxer, + ) { + return _mediamuxer_unprepare( + muxer, + ); + } + + late final _mediamuxer_unprepare_ptr = + _lookup>( + 'mediamuxer_unprepare'); + late final _dart_mediamuxer_unprepare _mediamuxer_unprepare = + _mediamuxer_unprepare_ptr.asFunction<_dart_mediamuxer_unprepare>(); + + /// @brief Removes the instance of media muxer and clear all its context memory. + /// @since_tizen 3.0 + /// @param[in] muxer The media muxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIAMUXER_ERROR_INVALID_STATE Invalid state + /// @pre Create a media muxer handle by calling mediamuxer_create() function. + /// @post The media muxer state will be #MEDIAMUXER_STATE_NONE. + /// @see mediamuxer_create() + int mediamuxer_destroy( + ffi.Pointer muxer, + ) { + return _mediamuxer_destroy( + muxer, + ); + } + + late final _mediamuxer_destroy_ptr = + _lookup>('mediamuxer_destroy'); + late final _dart_mediamuxer_destroy _mediamuxer_destroy = + _mediamuxer_destroy_ptr.asFunction<_dart_mediamuxer_destroy>(); + + /// @brief Gets media muxer state. + /// @since_tizen 3.0 + /// @param[in] muxer The media muxer handle + /// @param[out] state The media muxer sate + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a media muxer handle by calling mediamuxer_create() function. + /// @see #mediamuxer_state_e + int mediamuxer_get_state( + ffi.Pointer muxer, + ffi.Pointer state, + ) { + return _mediamuxer_get_state( + muxer, + state, + ); + } + + late final _mediamuxer_get_state_ptr = + _lookup>( + 'mediamuxer_get_state'); + late final _dart_mediamuxer_get_state _mediamuxer_get_state = + _mediamuxer_get_state_ptr.asFunction<_dart_mediamuxer_get_state>(); + + /// @brief Registers a error callback function to be invoked when an error occurs. + /// @since_tizen 3.0 + /// @param[in] muxer The media muxer handle + /// @param[in] callback Callback function pointer + /// @param[in] user_data The user data passed from the code where + /// mediamuxer_set_error_cb() was invoked + /// This data will be accessible from @a mediamuxer_error_cb + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre Create a media muxer handle by calling mediamuxer_create() function. + /// @post mediamuxer_error_cb() will be invoked. + /// @see mediamuxer_unset_error_cb() + /// @see mediamuxer_error_cb() + int mediamuxer_set_error_cb( + ffi.Pointer muxer, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mediamuxer_set_error_cb( + muxer, + callback, + user_data, + ); + } + + late final _mediamuxer_set_error_cb_ptr = + _lookup>( + 'mediamuxer_set_error_cb'); + late final _dart_mediamuxer_set_error_cb _mediamuxer_set_error_cb = + _mediamuxer_set_error_cb_ptr.asFunction<_dart_mediamuxer_set_error_cb>(); + + /// @brief Unregisters the error callback function. + /// @since_tizen 3.0 + /// @param[in] muxer The media muxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see mediamuxer_error_cb() + int mediamuxer_unset_error_cb( + ffi.Pointer muxer, + ) { + return _mediamuxer_unset_error_cb( + muxer, + ); + } + + late final _mediamuxer_unset_error_cb_ptr = + _lookup>( + 'mediamuxer_unset_error_cb'); + late final _dart_mediamuxer_unset_error_cb _mediamuxer_unset_error_cb = + _mediamuxer_unset_error_cb_ptr + .asFunction<_dart_mediamuxer_unset_error_cb>(); + + /// @brief Registers an EOS (end of stream) callback function to be invoked when an EOS occurs. + /// @since_tizen 4.0 + /// @param[in] muxer The media muxer handle + /// @param[in] callback Callback function pointer + /// @param[in] user_data The user data passed from the code where + /// mediamuxer_set_eos_cb() was invoked;\n + /// this data will be accessible from mediamuxer_eos_cb() + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_STATE Invalid state + /// @pre Create a media muxer handle by calling mediamuxer_create() function. + /// @post mediamuxer_eos_cb() will be invoked. + /// @see mediamuxer_unset_eos_cb() + /// @see mediamuxer_eos_cb() + int mediamuxer_set_eos_cb( + ffi.Pointer muxer, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mediamuxer_set_eos_cb( + muxer, + callback, + user_data, + ); + } + + late final _mediamuxer_set_eos_cb_ptr = + _lookup>( + 'mediamuxer_set_eos_cb'); + late final _dart_mediamuxer_set_eos_cb _mediamuxer_set_eos_cb = + _mediamuxer_set_eos_cb_ptr.asFunction<_dart_mediamuxer_set_eos_cb>(); + + /// @brief Unregisters the EOS (end of stream) callback function. + /// @since_tizen 4.0 + /// @param[in] muxer The media muxer handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIAMUXER_ERROR_NONE Successful + /// @retval #MEDIAMUXER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIAMUXER_ERROR_INVALID_STATE Invalid state + /// @see mediamuxer_eos_cb() + int mediamuxer_unset_eos_cb( + ffi.Pointer muxer, + ) { + return _mediamuxer_unset_eos_cb( + muxer, + ); + } + + late final _mediamuxer_unset_eos_cb_ptr = + _lookup>( + 'mediamuxer_unset_eos_cb'); + late final _dart_mediamuxer_unset_eos_cb _mediamuxer_unset_eos_cb = + _mediamuxer_unset_eos_cb_ptr.asFunction<_dart_mediamuxer_unset_eos_cb>(); + + /// @brief Sets a error callback function to be invoked when an error occurs. + /// @details Following error codes can be delivered by error callback. + /// #MEDIA_STREAMER_ERROR_INVALID_OPERATION, + /// #MEDIA_STREAMER_ERROR_FILE_NO_SPACE_ON_DEVICE, + /// #MEDIA_STREAMER_ERROR_NOT_SUPPORTED, + /// #MEDIA_STREAMER_ERROR_CONNECTION_FAILED, + /// #MEDIA_STREAMER_ERROR_RESOURCE_CONFLICT + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @param[in] callback Callback function pointer + /// @param[in] user_data The user data passed from the code where + /// media_streamer_set_error_cb() was invoked + /// This data will be accessible from media_streamer_error_cb + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a media streamer handle by calling media_streamer_create() function + /// @post media_streamer_error_cb() will be invoked. + /// @see media_streamer_unset_error_cb() + /// @see media_streamer_error_cb() + int media_streamer_set_error_cb( + ffi.Pointer streamer, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_streamer_set_error_cb( + streamer, + callback, + user_data, + ); + } + + late final _media_streamer_set_error_cb_ptr = + _lookup>( + 'media_streamer_set_error_cb'); + late final _dart_media_streamer_set_error_cb _media_streamer_set_error_cb = + _media_streamer_set_error_cb_ptr + .asFunction<_dart_media_streamer_set_error_cb>(); + + /// @brief Unsets the error callback function. + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @see media_streamer_error_cb() + int media_streamer_unset_error_cb( + ffi.Pointer streamer, + ) { + return _media_streamer_unset_error_cb( + streamer, + ); + } + + late final _media_streamer_unset_error_cb_ptr = + _lookup>( + 'media_streamer_unset_error_cb'); + late final _dart_media_streamer_unset_error_cb + _media_streamer_unset_error_cb = _media_streamer_unset_error_cb_ptr + .asFunction<_dart_media_streamer_unset_error_cb>(); + + /// @brief Sets a callback that will be triggered after media streamer state is changed. + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @param[in] callback Callback function pointer + /// @param[in] user_data The user data passed from the code + /// where media_streamer_set_state_change_cb() was invoked + /// This data will be accessible from media_streamer_state_changed_cb + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a media streamer handle by calling media_streamer_create() function + /// @post media_streamer_state_changed_cb() will be invoked. + /// @see media_streamer_unset_state_change_cb() + /// @see media_streamer_state_change_cb() + int media_streamer_set_state_change_cb( + ffi.Pointer streamer, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_streamer_set_state_change_cb( + streamer, + callback, + user_data, + ); + } + + late final _media_streamer_set_state_change_cb_ptr = + _lookup>( + 'media_streamer_set_state_change_cb'); + late final _dart_media_streamer_set_state_change_cb + _media_streamer_set_state_change_cb = + _media_streamer_set_state_change_cb_ptr + .asFunction<_dart_media_streamer_set_state_change_cb>(); + + /// @brief Unsets the state changed callback function. + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @see media_streamer_set_state_change_cb() + int media_streamer_unset_state_change_cb( + ffi.Pointer streamer, + ) { + return _media_streamer_unset_state_change_cb( + streamer, + ); + } + + late final _media_streamer_unset_state_change_cb_ptr = + _lookup>( + 'media_streamer_unset_state_change_cb'); + late final _dart_media_streamer_unset_state_change_cb + _media_streamer_unset_state_change_cb = + _media_streamer_unset_state_change_cb_ptr + .asFunction<_dart_media_streamer_unset_state_change_cb>(); + + /// @brief Sets a callback function to be invoked when the media streamer is interrupted. + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @post media_streamer_interrupted_cb() will be invoked. + /// @see media_streamer_unset_interrupted_cb() + /// @see #media_streamer_interrupted_code_e + int media_streamer_set_interrupted_cb( + ffi.Pointer streamer, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_streamer_set_interrupted_cb( + streamer, + callback, + user_data, + ); + } + + late final _media_streamer_set_interrupted_cb_ptr = + _lookup>( + 'media_streamer_set_interrupted_cb'); + late final _dart_media_streamer_set_interrupted_cb + _media_streamer_set_interrupted_cb = + _media_streamer_set_interrupted_cb_ptr + .asFunction<_dart_media_streamer_set_interrupted_cb>(); + + /// @brief Unsets the callback function. + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @see media_streamer_set_interrupted_cb() + int media_streamer_unset_interrupted_cb( + ffi.Pointer streamer, + ) { + return _media_streamer_unset_interrupted_cb( + streamer, + ); + } + + late final _media_streamer_unset_interrupted_cb_ptr = + _lookup>( + 'media_streamer_unset_interrupted_cb'); + late final _dart_media_streamer_unset_interrupted_cb + _media_streamer_unset_interrupted_cb = + _media_streamer_unset_interrupted_cb_ptr + .asFunction<_dart_media_streamer_unset_interrupted_cb>(); + + /// @brief Sets a callback function to be invoked when buffer underrun or overflow is occurred. + /// @details This function can be called only for MEDIA_STREAMER_NODE_SRC_TYPE_CUSTOM source type + /// @since_tizen 3.0 + /// @remarks This function is used for media stream playback only. + /// @param[in] source Media streamer source node handle + /// @param[in] callback The buffer status callback function to register + /// @param[in] user_data The user data passed from the code where + /// media_streamer_src_set_buffer_status_cb() was invoked + /// This data will be accessible from media_streamer_custom_buffer_status_cb() + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a media streamer source node handle by calling media_streamer_node_create_src() function + /// @pre Add created media streamer source node to media streamer by calling media_streamer_node_add() function + /// @post media_streamer_custom_buffer_status_cb() will be invoked. + /// @see media_streamer_src_unset_buffer_status_cb() + /// @see media_streamer_custom_buffer_status_cb() + int media_streamer_src_set_buffer_status_cb( + ffi.Pointer source, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _media_streamer_src_set_buffer_status_cb( + source, + callback, + user_data, + ); + } + + late final _media_streamer_src_set_buffer_status_cb_ptr = + _lookup>( + 'media_streamer_src_set_buffer_status_cb'); + late final _dart_media_streamer_src_set_buffer_status_cb + _media_streamer_src_set_buffer_status_cb = + _media_streamer_src_set_buffer_status_cb_ptr + .asFunction<_dart_media_streamer_src_set_buffer_status_cb>(); + + /// @brief Unsets the src buffer status callback function. + /// @since_tizen 3.0 + /// @param[in] source Media streamer source node handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @see media_streamer_src_set_buffer_status_cb() + int media_streamer_src_unset_buffer_status_cb( + ffi.Pointer source, + ) { + return _media_streamer_src_unset_buffer_status_cb( + source, + ); + } + + late final _media_streamer_src_unset_buffer_status_cb_ptr = + _lookup>( + 'media_streamer_src_unset_buffer_status_cb'); + late final _dart_media_streamer_src_unset_buffer_status_cb + _media_streamer_src_unset_buffer_status_cb = + _media_streamer_src_unset_buffer_status_cb_ptr + .asFunction<_dart_media_streamer_src_unset_buffer_status_cb>(); + + /// @brief Sets a callback function to be called when the custom sink is ready for data processing. + /// @details This function can be called only for MEDIA_STREAMER_NODE_SINK_TYPE_CUSTOM sink type + /// @since_tizen 3.0 + /// @param[in] sink Media streamer sink node handle + /// @param[in] callback Callback function pointer + /// @param[in] user_data The user data passed from the code where + /// media_streamer_sink_set_data_ready_cb() was invoked + /// This data will be accessible from media_streamer_sink_data_ready_cb + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a media streamer sink handle by calling media_streamer_node_create_sink() function + /// @pre Add created media streamer sink node to media streamer by calling media_streamer_node_add() function + /// @post media_streamer_sink_data_ready_cb() will be invoked. + /// @see media_streamer_sink_unset_data_ready_cb() + /// @see media_streamer_sink_data_ready_cb() + int media_streamer_sink_set_data_ready_cb( + ffi.Pointer sink, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_streamer_sink_set_data_ready_cb( + sink, + callback, + user_data, + ); + } + + late final _media_streamer_sink_set_data_ready_cb_ptr = + _lookup>( + 'media_streamer_sink_set_data_ready_cb'); + late final _dart_media_streamer_sink_set_data_ready_cb + _media_streamer_sink_set_data_ready_cb = + _media_streamer_sink_set_data_ready_cb_ptr + .asFunction<_dart_media_streamer_sink_set_data_ready_cb>(); + + /// @brief Unsets the sink data ready callback function. + /// @since_tizen 3.0 + /// @param[in] sink Media streamer sink node handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @see media_streamer_sink_set_data_ready_cb() + int media_streamer_sink_unset_data_ready_cb( + ffi.Pointer sink, + ) { + return _media_streamer_sink_unset_data_ready_cb( + sink, + ); + } + + late final _media_streamer_sink_unset_data_ready_cb_ptr = + _lookup>( + 'media_streamer_sink_unset_data_ready_cb'); + late final _dart_media_streamer_sink_unset_data_ready_cb + _media_streamer_sink_unset_data_ready_cb = + _media_streamer_sink_unset_data_ready_cb_ptr + .asFunction<_dart_media_streamer_sink_unset_data_ready_cb>(); + + /// @brief Sets a callback function to be called when custom sink detect the end-of-stream. + /// @since_tizen 3.0 + /// @param[in] sink Media streamer sink node handle + /// @param[in] callback Callback function pointer + /// @param[in] user_data The user data passed from the code where + /// media_streamer_sink_set_eos_cb() was invoked. + /// This data will be accessible from media_streamer_sink_eos_cb + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a media streamer sink handle by calling media_streamer_node_create_sink() function + /// @pre Add created media streamer sink node to media streamer by calling media_streamer_node_add() function + /// @post media_streamer_sink_eos_cb() will be invoked. + /// @see media_streamer_sink_unset_eos_cb() + /// @see media_streamer_sink_eos_cb() + int media_streamer_sink_set_eos_cb( + ffi.Pointer sink, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_streamer_sink_set_eos_cb( + sink, + callback, + user_data, + ); + } + + late final _media_streamer_sink_set_eos_cb_ptr = + _lookup>( + 'media_streamer_sink_set_eos_cb'); + late final _dart_media_streamer_sink_set_eos_cb + _media_streamer_sink_set_eos_cb = _media_streamer_sink_set_eos_cb_ptr + .asFunction<_dart_media_streamer_sink_set_eos_cb>(); + + /// @brief Unsets the sink end-of-stream callback function. + /// @since_tizen 3.0 + /// @param[in] sink Media streamer sink node handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @see media_streamer_sink_set_eos_cb() + int media_streamer_sink_unset_eos_cb( + ffi.Pointer sink, + ) { + return _media_streamer_sink_unset_eos_cb( + sink, + ); + } + + late final _media_streamer_sink_unset_eos_cb_ptr = + _lookup>( + 'media_streamer_sink_unset_eos_cb'); + late final _dart_media_streamer_sink_unset_eos_cb + _media_streamer_sink_unset_eos_cb = _media_streamer_sink_unset_eos_cb_ptr + .asFunction<_dart_media_streamer_sink_unset_eos_cb>(); + + /// @brief Creates an instance of media streamer and + /// passes the handle to the caller. + /// @since_tizen 3.0 + /// @remarks You must release @a streamer using media_streamer_destroy() + /// @param[out] streamer Media streamer handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @post The media streamer state will be #MEDIA_STREAMER_STATE_IDLE. + /// @see media_streamer_destroy() + int media_streamer_create( + ffi.Pointer> streamer, + ) { + return _media_streamer_create( + streamer, + ); + } + + late final _media_streamer_create_ptr = + _lookup>( + 'media_streamer_create'); + late final _dart_media_streamer_create _media_streamer_create = + _media_streamer_create_ptr.asFunction<_dart_media_streamer_create>(); + + /// @brief Sets media streamer state to MEDIA_STREAMER_STATE_READY. + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The media streamer state must be set to MEDIA_STREAMER_STATE_IDLE + /// by calling media_streamer_create() or media_streamer_unprepare(). + /// @pre At least one src and one sink should be added and linked in the streamer + /// by calling media_streamer_node_create_src(), media_streamer_node_create_sink() and media_streamer_node_link(). + /// @post The media streamer state will be #MEDIA_STREAMER_STATE_READY. + /// @see media_streamer_unprepare() + /// @see media_streamer_create() + int media_streamer_prepare( + ffi.Pointer streamer, + ) { + return _media_streamer_prepare( + streamer, + ); + } + + late final _media_streamer_prepare_ptr = + _lookup>( + 'media_streamer_prepare'); + late final _dart_media_streamer_prepare _media_streamer_prepare = + _media_streamer_prepare_ptr.asFunction<_dart_media_streamer_prepare>(); + + /// @brief Sets media streamer state to MEDIA_STREAMER_STATE_IDLE. + /// @details The most recently used media is reset and no longer associated with the media streamer. + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The media streamer state should be higher than #MEDIA_STREAMER_STATE_IDLE. + /// @post The media streamer state will be #MEDIA_STREAMER_STATE_IDLE. + /// @see media_streamer_prepare() + int media_streamer_unprepare( + ffi.Pointer streamer, + ) { + return _media_streamer_unprepare( + streamer, + ); + } + + late final _media_streamer_unprepare_ptr = + _lookup>( + 'media_streamer_unprepare'); + late final _dart_media_streamer_unprepare _media_streamer_unprepare = + _media_streamer_unprepare_ptr + .asFunction<_dart_media_streamer_unprepare>(); + + /// @brief Sets media streamer state to MEDIA_STREAMER_STATE_PLAYING. + /// @details Start running the current streamer, or resumes it if paused. + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The media streamer state must be set to #MEDIA_STREAMER_STATE_READY by calling media_streamer_prepare() or + /// set to #MEDIA_STREAMER_STATE_PAUSED by calling media_streamer_pause(). + /// @post The media streamer state will be #MEDIA_STREAMER_STATE_PLAYING. + /// @see media_streamer_create() + /// @see media_streamer_pause() + /// @see media_streamer_stop() + int media_streamer_play( + ffi.Pointer streamer, + ) { + return _media_streamer_play( + streamer, + ); + } + + late final _media_streamer_play_ptr = + _lookup>( + 'media_streamer_play'); + late final _dart_media_streamer_play _media_streamer_play = + _media_streamer_play_ptr.asFunction<_dart_media_streamer_play>(); + + /// @brief Pauses the media streamer. + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The media streamer state must be set to #MEDIA_STREAMER_STATE_PLAYING. + /// @post The media streamer state will be #MEDIA_STREAMER_STATE_READY. + /// @see media_streamer_create() + /// @see media_streamer_play() + int media_streamer_pause( + ffi.Pointer streamer, + ) { + return _media_streamer_pause( + streamer, + ); + } + + late final _media_streamer_pause_ptr = + _lookup>( + 'media_streamer_pause'); + late final _dart_media_streamer_pause _media_streamer_pause = + _media_streamer_pause_ptr.asFunction<_dart_media_streamer_pause>(); + + /// @brief Stops the media streamer. + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The media streamer state must be set to #MEDIA_STREAMER_STATE_PLAYING by calling media_streamer_play() or + /// set to #MEDIA_STREAMER_STATE_PAUSED by calling media_streamer_pause(). + /// @post The media streamer state will be #MEDIA_STREAMER_STATE_READY. + /// @see media_streamer_create() + /// @see media_streamer_play() + /// @see media_streamer_pause() + int media_streamer_stop( + ffi.Pointer streamer, + ) { + return _media_streamer_stop( + streamer, + ); + } + + late final _media_streamer_stop_ptr = + _lookup>( + 'media_streamer_stop'); + late final _dart_media_streamer_stop _media_streamer_stop = + _media_streamer_stop_ptr.asFunction<_dart_media_streamer_stop>(); + + /// @brief Destroys media streamer. + /// @since_tizen 3.0 + /// @remarks Nodes in streamer will be removed automatically. + /// Don't need to remove nodes by calling media_streamer_node_remove(). + /// If you want to change the node without destroying streamer handle, + /// you can call the media_streamer_node_remove() function + /// after setting the streamer state to MEDIA_STREAMER_STATE_IDLE state. + /// @param[in] streamer Media streamer handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a media streamer handle by calling media_streamer_create() function + /// @post The media streamer state will be #MEDIA_STREAMER_STATE_NONE. + /// @see media_streamer_create() + int media_streamer_destroy( + ffi.Pointer streamer, + ) { + return _media_streamer_destroy( + streamer, + ); + } + + late final _media_streamer_destroy_ptr = + _lookup>( + 'media_streamer_destroy'); + late final _dart_media_streamer_destroy _media_streamer_destroy = + _media_streamer_destroy_ptr.asFunction<_dart_media_streamer_destroy>(); + + /// @brief Changes playback position to the defined time value, asynchronously. + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @param[in] time Time in millisecond + /// @param[in] accurate If @c true, it will seek to the accurate position, but this might be considerably slower for some formats, + /// otherwise @c false, it will seek to the nearest keyframe + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_STREAMER_ERROR_SEEK_FAILED Seek operation failure + /// @pre The media streamer state must be one of these: #MEDIA_STREAMER_STATE_PAUSED, or #MEDIA_STREAMER_STATE_PLAYING. + /// @post It invokes media_streamer_set_play_position() when seek operation completes, if you set a callback. + /// @see media_streamer_get_play_position() + int media_streamer_set_play_position( + ffi.Pointer streamer, + int time, + bool accurate, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _media_streamer_set_play_position( + streamer, + time, + accurate ? 1 : 0, + callback, + user_data, + ); + } + + late final _media_streamer_set_play_position_ptr = + _lookup>( + 'media_streamer_set_play_position'); + late final _dart_media_streamer_set_play_position + _media_streamer_set_play_position = _media_streamer_set_play_position_ptr + .asFunction<_dart_media_streamer_set_play_position>(); + + /// @brief Gets the current position in milliseconds. + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @param[out] time The current position in milliseconds + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The media streamer state must be one of these: #MEDIA_STREAMER_STATE_PAUSED, or #MEDIA_STREAMER_STATE_PLAYING. + /// @see media_streamer_set_play_position() + int media_streamer_get_play_position( + ffi.Pointer streamer, + ffi.Pointer time, + ) { + return _media_streamer_get_play_position( + streamer, + time, + ); + } + + late final _media_streamer_get_play_position_ptr = + _lookup>( + 'media_streamer_get_play_position'); + late final _dart_media_streamer_get_play_position + _media_streamer_get_play_position = _media_streamer_get_play_position_ptr + .asFunction<_dart_media_streamer_get_play_position>(); + + /// @brief Gets the total running time of the associated media. + /// @since_tizen 3.0 + /// @remarks The streamer's src node type should be MEDIA_STREAMER_NODE_SRC_TYPE_FILE or MEDIA_STREAMER_NODE_SRC_TYPE_HTTP. + /// If not, return value will be MEDIA_STREAMER_ERROR_NONE and duration will be -1. + /// @param[in] streamer Media streamer handle + /// @param[out] duration The duration in milliseconds + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The media streamer state must be one of these: #MEDIA_STREAMER_STATE_PAUSED, or #MEDIA_STREAMER_STATE_PLAYING. + int media_streamer_get_duration( + ffi.Pointer streamer, + ffi.Pointer duration, + ) { + return _media_streamer_get_duration( + streamer, + duration, + ); + } + + late final _media_streamer_get_duration_ptr = + _lookup>( + 'media_streamer_get_duration'); + late final _dart_media_streamer_get_duration _media_streamer_get_duration = + _media_streamer_get_duration_ptr + .asFunction<_dart_media_streamer_get_duration>(); + + /// @brief Gets media streamer state. + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @param[out] state Media streamer state + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a media streamer handle by calling media_streamer_create() function + /// @see #media_streamer_state_e + int media_streamer_get_state( + ffi.Pointer streamer, + ffi.Pointer state, + ) { + return _media_streamer_get_state( + streamer, + state, + ); + } + + late final _media_streamer_get_state_ptr = + _lookup>( + 'media_streamer_get_state'); + late final _dart_media_streamer_get_state _media_streamer_get_state = + _media_streamer_get_state_ptr + .asFunction<_dart_media_streamer_get_state>(); + + /// @brief Creates media streamer source node. + /// @since_tizen 3.0 + /// @privilege http://tizen.org/privilege/internet + /// http://tizen.org/privilege/camera + /// http://tizen.org/privilege/recorder + /// @remarks The internet privilege(http://tizen.org/privilege/internet) should be added if any URIs are used to play from network. + /// The camera privilege(http://tizen.org/privilege/camera) should be added if the src node handle the camera device. + /// The recorder privilege(http://tizen.org/privilege/recorder) should be added if the src node handle the recorder device. + /// You can release source node using media_streamer_node_destroy() function. + /// @param[in] type Media streamer source node type + /// @param[out] src Media streamer source node handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_STREAMER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_STREAMER_ERROR_NOT_SUPPORTED Not supported + /// @see #media_streamer_node_src_type_e + /// @see media_streamer_node_destroy() + int media_streamer_node_create_src( + int type, + ffi.Pointer> src, + ) { + return _media_streamer_node_create_src( + type, + src, + ); + } + + late final _media_streamer_node_create_src_ptr = + _lookup>( + 'media_streamer_node_create_src'); + late final _dart_media_streamer_node_create_src + _media_streamer_node_create_src = _media_streamer_node_create_src_ptr + .asFunction<_dart_media_streamer_node_create_src>(); + + /// @brief Pushes packet into custom source node. + /// @details This function can be called only for MEDIA_STREAMER_NODE_SRC_TYPE_CUSTOM. + /// @since_tizen 3.0 + /// @param[in] src Media streamer source node handle + /// @param[in] packet Media packet handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a source node handle by calling media_streamer_node_create_src() function + /// @pre The media streamer state must be set to #MEDIA_STREAMER_STATE_IDLE at least. + /// @see #media_packet_h + int media_streamer_node_push_packet( + ffi.Pointer src, + ffi.Pointer packet, + ) { + return _media_streamer_node_push_packet( + src, + packet, + ); + } + + late final _media_streamer_node_push_packet_ptr = + _lookup>( + 'media_streamer_node_push_packet'); + late final _dart_media_streamer_node_push_packet + _media_streamer_node_push_packet = _media_streamer_node_push_packet_ptr + .asFunction<_dart_media_streamer_node_push_packet>(); + + /// @brief Creates media streamer sink node. + /// @since_tizen 3.0 + /// @privilege http://tizen.org/privilege/internet + /// @remarks The internet privilege(http://tizen.org/privilege/internet) should be added if any URIs are used to transmit the output data. + /// You can release @a sink node using media_streamer_node_destroy() + /// @remarks If @a type is #MEDIA_STREAMER_NODE_SINK_TYPE_ADAPTIVE, the HTTP server will be started and the server will be able to transmit the output data to the other device. + /// The application must have an authentication responsibility between a server and client because the data transmission is not secure. + /// @param[in] type Type of sink node to be created + /// @param[out] sink Media streamer sink node handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_STREAMER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_STREAMER_ERROR_NOT_SUPPORTED Not supported + /// @see #media_streamer_node_sink_type_e + /// @see media_streamer_node_destroy() + int media_streamer_node_create_sink( + int type, + ffi.Pointer> sink, + ) { + return _media_streamer_node_create_sink( + type, + sink, + ); + } + + late final _media_streamer_node_create_sink_ptr = + _lookup>( + 'media_streamer_node_create_sink'); + late final _dart_media_streamer_node_create_sink + _media_streamer_node_create_sink = _media_streamer_node_create_sink_ptr + .asFunction<_dart_media_streamer_node_create_sink>(); + + /// @brief Pulls packet from custom sink node. + /// @details This function can be called only for MEDIA_STREAMER_NODE_SINK_TYPE_CUSTOM + /// @since_tizen 3.0 + /// @param[in] sink Media streamer sink node handle + /// @param[out] packet Media packet handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a sink node handle by calling media_streamer_node_create_sink() function + /// @pre Set media_streamer_data_ready_cb by calling media_streamer_set_data_ready_cb() function. + /// @see #media_packet_h + /// @see media_streamer_node_create_sink() + int media_streamer_node_pull_packet( + ffi.Pointer sink, + ffi.Pointer> packet, + ) { + return _media_streamer_node_pull_packet( + sink, + packet, + ); + } + + late final _media_streamer_node_pull_packet_ptr = + _lookup>( + 'media_streamer_node_pull_packet'); + late final _dart_media_streamer_node_pull_packet + _media_streamer_node_pull_packet = _media_streamer_node_pull_packet_ptr + .asFunction<_dart_media_streamer_node_pull_packet>(); + + /// @brief Creates media streamer node except MEDIA_STREAMER_NODE_TYPE_SRC and MEDIA_STREAMER_NODE_TYPE_SINK. + /// @details Creates node specific @a type with specific format of input + /// and output data. + /// @since_tizen 3.0 + /// @remarks The node type should not be MEDIA_STREAMER_NODE_TYPE_SRC and MEDIA_STREAMER_NODE_TYPE_SINK. + /// To create src/sink type node, media_streamer_node_create_src()/media_streamer_node_create_sink() should be called. + /// You can release @a node using media_streamer_node_destroy() function + /// @param[in] type Created node type + /// @param[in] in_fmt Media format handle for input data + /// @param[in] out_fmt Media format handle for output data + /// @param[out] node Media streamer node handle to be created + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @see #media_streamer_node_type_e + /// @see #media_format_h + /// @see media_streamer_node_destroy() + int media_streamer_node_create( + int type, + ffi.Pointer in_fmt, + ffi.Pointer out_fmt, + ffi.Pointer> node, + ) { + return _media_streamer_node_create( + type, + in_fmt, + out_fmt, + node, + ); + } + + late final _media_streamer_node_create_ptr = + _lookup>( + 'media_streamer_node_create'); + late final _dart_media_streamer_node_create _media_streamer_node_create = + _media_streamer_node_create_ptr + .asFunction<_dart_media_streamer_node_create>(); + + /// @brief Adds node to media streamer. + /// @since_tizen 3.0 + /// @param[in] streamer Media streamer handle + /// @param[in] node Media streamer node handle to be added + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create media streamer handle by calling media_streamer_create() function + /// @pre Create node handle by calling media_streamer_node_create() function + /// @see media_streamer_create() + /// @see media_streamer_node_create() + /// @see media_streamer_node_create_src() + /// @see media_streamer_node_create_sink() + int media_streamer_node_add( + ffi.Pointer streamer, + ffi.Pointer node, + ) { + return _media_streamer_node_add( + streamer, + node, + ); + } + + late final _media_streamer_node_add_ptr = + _lookup>( + 'media_streamer_node_add'); + late final _dart_media_streamer_node_add _media_streamer_node_add = + _media_streamer_node_add_ptr.asFunction<_dart_media_streamer_node_add>(); + + /// @brief Destroys media streamer node. + /// @since_tizen 3.0 + /// @param[in] node Media streamer node handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create node handle by calling media_streamer_node_create() function + /// @pre If the node was added to media streamer, it have to be removed by calling media_streamer_node_remove() function + /// @see media_streamer_node_create() + /// @see media_streamer_node_create_src() + /// @see media_streamer_node_create_sink() + /// @see media_streamer_node_remove() + int media_streamer_node_destroy( + ffi.Pointer node, + ) { + return _media_streamer_node_destroy( + node, + ); + } + + late final _media_streamer_node_destroy_ptr = + _lookup>( + 'media_streamer_node_destroy'); + late final _dart_media_streamer_node_destroy _media_streamer_node_destroy = + _media_streamer_node_destroy_ptr + .asFunction<_dart_media_streamer_node_destroy>(); + + /// @brief Removes media streamer node from streamer. + /// @since_tizen 3.0 + /// @remarks To remove node without error posting, the state of streamer should be MEDIA_STREAMER_STATE_IDLE. + /// If the node is linked, it will be unlinked before removing. + /// @param[in] streamer Media streamer handle + /// @param[in] node Media streamer node handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Add node to streamer by calling media_streamer_node_add() function + /// @see media_streamer_node_add() + int media_streamer_node_remove( + ffi.Pointer streamer, + ffi.Pointer node, + ) { + return _media_streamer_node_remove( + streamer, + node, + ); + } + + late final _media_streamer_node_remove_ptr = + _lookup>( + 'media_streamer_node_remove'); + late final _dart_media_streamer_node_remove _media_streamer_node_remove = + _media_streamer_node_remove_ptr + .asFunction<_dart_media_streamer_node_remove>(); + + /// @brief Links two media streamer nodes. + /// @since_tizen 3.0 + /// @remarks Pads are node's input and output, where you can connect other nodes. + /// (src_node) - (sink_node) + /// src_node and sink_node is determined relatively. + /// In case of (A)-(B)-(C), + /// (B) can be sink_node with (A) or (B) can be src_node with (C). + /// However, src type node is always src node and sink type node is always sink node. + /// (A) is src node and can not be sink node at all. + /// (C) is sink node and can not be src node at all. + /// @param[in] src_node Media streamer node handle + /// @param[in] src_pad_name The name of the source pad of the source node + /// @param[in] dest_node The destination media streamer node handle + /// @param[in] sink_pad_name The name of the sink pad of the destination node + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a source node and a destination node handles + /// by calling media_streamer_node_create() function + /// and add the nodes into streamer by calling media_streamer_node_add() function. + /// @see media_streamer_node_create() + /// @see media_streamer_node_add() + int media_streamer_node_link( + ffi.Pointer src_node, + ffi.Pointer src_pad_name, + ffi.Pointer dest_node, + ffi.Pointer sink_pad_name, + ) { + return _media_streamer_node_link( + src_node, + src_pad_name, + dest_node, + sink_pad_name, + ); + } + + late final _media_streamer_node_link_ptr = + _lookup>( + 'media_streamer_node_link'); + late final _dart_media_streamer_node_link _media_streamer_node_link = + _media_streamer_node_link_ptr + .asFunction<_dart_media_streamer_node_link>(); + + /// @brief Sets media format for pad of media streamer node. + /// @since_tizen 3.0 + /// @param[in] node Media streamer node handle + /// @param[in] pad_name Pad name + /// @param[in] fmt Media format handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a node handle by calling media_streamer_node_createxxx() function + /// @pre Get pad name by calling media_streamer_node_get_pad_name() function + /// @see #media_format_h + int media_streamer_node_set_pad_format( + ffi.Pointer node, + ffi.Pointer pad_name, + ffi.Pointer fmt, + ) { + return _media_streamer_node_set_pad_format( + node, + pad_name, + fmt, + ); + } + + late final _media_streamer_node_set_pad_format_ptr = + _lookup>( + 'media_streamer_node_set_pad_format'); + late final _dart_media_streamer_node_set_pad_format + _media_streamer_node_set_pad_format = + _media_streamer_node_set_pad_format_ptr + .asFunction<_dart_media_streamer_node_set_pad_format>(); + + /// @brief Gets media format for pad of media streamer node. + /// @since_tizen 3.0 + /// @param[in] node Media streamer node handle + /// @param[in] pad_name Pad name + /// @param[out] fmt Media format handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a node handle by calling media_streamer_node_createxxx() function + /// @pre Get pad name by calling media_streamer_node_get_pad_name() function + /// @see #media_format_h + int media_streamer_node_get_pad_format( + ffi.Pointer node, + ffi.Pointer pad_name, + ffi.Pointer> fmt, + ) { + return _media_streamer_node_get_pad_format( + node, + pad_name, + fmt, + ); + } + + late final _media_streamer_node_get_pad_format_ptr = + _lookup>( + 'media_streamer_node_get_pad_format'); + late final _dart_media_streamer_node_get_pad_format + _media_streamer_node_get_pad_format = + _media_streamer_node_get_pad_format_ptr + .asFunction<_dart_media_streamer_node_get_pad_format>(); + + /// @brief Gets name of node pads. + /// @since_tizen 3.0 + /// @remarks After using the src_pad_name and sink_pad_name, it have to be free. + /// src_pad_name or sink_pad_name can be null according to the node type. + /// In case of src type node, sink_pad_name will be null. + /// In case of sink type node, src_pad_name will be null. + /// @param[in] node Media streamer node handle + /// @param[out] src_pad_name Array of source pad name + /// @param[out] src_pad_num The number of source pads + /// @param[out] sink_pad_name Array of sink pad name + /// @param[out] sink_pad_num The number of sink pads + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a node handle by calling media_streamer_node_createxxx() function + /// @see media_streamer_node_create() + /// @see media_streamer_node_create_src() + /// @see media_streamer_node_create_sink() + int media_streamer_node_get_pad_name( + ffi.Pointer node, + ffi.Pointer>> src_pad_name, + ffi.Pointer src_pad_num, + ffi.Pointer>> sink_pad_name, + ffi.Pointer sink_pad_num, + ) { + return _media_streamer_node_get_pad_name( + node, + src_pad_name, + src_pad_num, + sink_pad_name, + sink_pad_num, + ); + } + + late final _media_streamer_node_get_pad_name_ptr = + _lookup>( + 'media_streamer_node_get_pad_name'); + late final _dart_media_streamer_node_get_pad_name + _media_streamer_node_get_pad_name = _media_streamer_node_get_pad_name_ptr + .asFunction<_dart_media_streamer_node_get_pad_name>(); + + /// @brief Sets parameters of node. + /// @details Many parameters can be set at one time all together by using bundle. + /// @since_tizen 3.0 + /// @privilege http://tizen.org/privilege/mediastorage + /// http://tizen.org/privilege/externalstorage + /// @remarks The mediastorage privilege(http://tizen.org/privilege/mediastorage) should be added if any video/audio files are written in the internal storage devices. + /// The externalstorage privilege(http://tizen.org/privilege/externalstorage) should be added if any video/audio files are written in the external storage devices. + /// @param[in] node Media streamer node handle + /// @param[in] param_list Key value array of media streamer node parameters + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_STREAMER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a node handle by calling media_streamer_node_createXXX() function. + /// @pre Get param list to set by calling media_streamer_node_get_params() function. + /// @see media_streamer_node_create() + /// @see media_streamer_node_create_src() + /// @see media_streamer_node_create_sink() + /// @see media_streamer_node_get_params() + int media_streamer_node_set_params( + ffi.Pointer node, + ffi.Pointer param_list, + ) { + return _media_streamer_node_set_params( + node, + param_list, + ); + } + + late final _media_streamer_node_set_params_ptr = + _lookup>( + 'media_streamer_node_set_params'); + late final _dart_media_streamer_node_set_params + _media_streamer_node_set_params = _media_streamer_node_set_params_ptr + .asFunction<_dart_media_streamer_node_set_params>(); + + /// @brief Gets node parameter list. + /// @since_tizen 3.0 + /// @remarks After using param_list, it have to be free by calling bundle_free() in bundle.h + /// Refer to the "Parameter information of node" in this file to get info. + /// @param[in] node Media streamer node handle + /// @param[out] param_list Key value array of media streamer node parameters + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a node handle by calling media_streamer_node_createXXX() function + /// @post Set params which are needed to set by calling media_streamer_node_set_params() or media_streamer_node_set_param() function. + /// @see media_streamer_node_create() + /// @see media_streamer_src_create() + /// @see media_streamer_sink_create() + /// @see media_streamer_node_set_params() + /// @see media_streamer_node_set_param() + int media_streamer_node_get_params( + ffi.Pointer node, + ffi.Pointer> param_list, + ) { + return _media_streamer_node_get_params( + node, + param_list, + ); + } + + late final _media_streamer_node_get_params_ptr = + _lookup>( + 'media_streamer_node_get_params'); + late final _dart_media_streamer_node_get_params + _media_streamer_node_get_params = _media_streamer_node_get_params_ptr + .asFunction<_dart_media_streamer_node_get_params>(); + + /// @brief Sets single parameter of node. + /// @details Sets parameter one by one without creating param bundle. + /// @since_tizen 3.0 + /// @privilege http://tizen.org/privilege/mediastorage + /// http://tizen.org/privilege/externalstorage + /// @remarks The mediastorage privilege(http://tizen.org/privilege/mediastorage) should be added if any video/audio files are written in the internal storage devices. + /// The externalstorage privilege(http://tizen.org/privilege/externalstorage) should be added if any video/audio files are written in the external storage devices. + /// @param[in] node Media streamer node handle + /// @param[in] param_name Param name of node + /// @param[in] param_value Param value of node + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_STREAMER_ERROR_PERMISSION_DENIED Permission denied + /// @pre Create a node handle by calling media_streamer_node_createXXX() function. + /// @pre Get param list to set by calling media_streamer_node_get_params() function. + /// @see media_streamer_node_create() + /// @see media_streamer_src_create() + /// @see media_streamer_sink_create() + /// @see media_streamer_node_get_params() + /// @see media_streamer_node_get_param() + int media_streamer_node_set_param( + ffi.Pointer node, + ffi.Pointer param_name, + ffi.Pointer param_value, + ) { + return _media_streamer_node_set_param( + node, + param_name, + param_value, + ); + } + + late final _media_streamer_node_set_param_ptr = + _lookup>( + 'media_streamer_node_set_param'); + late final _dart_media_streamer_node_set_param + _media_streamer_node_set_param = _media_streamer_node_set_param_ptr + .asFunction<_dart_media_streamer_node_set_param>(); + + /// @brief Gets value of parameter. + /// @details Gets parameter one by one without creating param bundle. + /// @since_tizen 3.0 + /// @param[in] node Media streamer node handle + /// @param[in] param_name Param name of node + /// @param[out] param_value Param value of node + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_STREAMER_ERROR_NONE Successful + /// @retval #MEDIA_STREAMER_ERROR_INVALID_STATE Invalid state + /// @retval #MEDIA_STREAMER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_STREAMER_ERROR_INVALID_OPERATION Invalid operation + /// @pre Create a node handle by calling media_streamer_node_createXXX() function. + /// @pre Get param list to know the param name by calling media_streamer_node_get_params() function. + /// @see media_streamer_node_create() + /// @see media_streamer_src_create() + /// @see media_streamer_sink_create() + /// @see media_streamer_node_get_params() + /// @see media_streamer_node_set_param() + int media_streamer_node_get_param( + ffi.Pointer node, + ffi.Pointer param_name, + ffi.Pointer> param_value, + ) { + return _media_streamer_node_get_param( + node, + param_name, + param_value, + ); + } + + late final _media_streamer_node_get_param_ptr = + _lookup>( + 'media_streamer_node_get_param'); + late final _dart_media_streamer_node_get_param + _media_streamer_node_get_param = _media_streamer_node_get_param_ptr + .asFunction<_dart_media_streamer_node_get_param>(); + + /// @brief Creates a source handle. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @remarks You must release @a source by using @ref mv_destroy_source(). + /// @param [out] source A new handle to the source + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_destroy_source() + int mv_create_source( + ffi.Pointer> source, + ) { + return _mv_create_source( + source, + ); + } + + late final _mv_create_source_ptr = + _lookup>('mv_create_source'); + late final _dart_mv_create_source _mv_create_source = + _mv_create_source_ptr.asFunction<_dart_mv_create_source>(); + + /// @brief Destroys the source handle and releases all its resources. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in] source The handle to the source to be destroyed + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_create_source() + int mv_destroy_source( + ffi.Pointer source, + ) { + return _mv_destroy_source( + source, + ); + } + + late final _mv_destroy_source_ptr = + _lookup>('mv_destroy_source'); + late final _dart_mv_destroy_source _mv_destroy_source = + _mv_destroy_source_ptr.asFunction<_dart_mv_destroy_source>(); + + /// @brief Fills the media source based on the media packet. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in,out] source The handle to the source + /// @param [in] media_packet The handle to the media packet from which + /// will be filled the source + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Not supported format + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create a source handle by calling @ref mv_create_source() + /// + /// @see mv_create_source() + /// @see mv_destroy_source() + int mv_source_fill_by_media_packet( + ffi.Pointer source, + ffi.Pointer media_packet, + ) { + return _mv_source_fill_by_media_packet( + source, + media_packet, + ); + } + + late final _mv_source_fill_by_media_packet_ptr = + _lookup>( + 'mv_source_fill_by_media_packet'); + late final _dart_mv_source_fill_by_media_packet + _mv_source_fill_by_media_packet = _mv_source_fill_by_media_packet_ptr + .asFunction<_dart_mv_source_fill_by_media_packet>(); + + /// @brief Fills the media source based on the buffer and metadata. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in,out] source The handle to the source + /// @param [in] data_buffer The buffer of image data + /// @param [in] buffer_size The buffer size + /// @param [in] image_width The width of image data + /// @param [in] image_height The height of image data + /// @param [in] image_colorspace The image colorspace + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create a source handle by calling @ref mv_create_source() + /// + /// @see mv_source_clear() + int mv_source_fill_by_buffer( + ffi.Pointer source, + ffi.Pointer data_buffer, + int buffer_size, + int image_width, + int image_height, + int image_colorspace, + ) { + return _mv_source_fill_by_buffer( + source, + data_buffer, + buffer_size, + image_width, + image_height, + image_colorspace, + ); + } + + late final _mv_source_fill_by_buffer_ptr = + _lookup>( + 'mv_source_fill_by_buffer'); + late final _dart_mv_source_fill_by_buffer _mv_source_fill_by_buffer = + _mv_source_fill_by_buffer_ptr + .asFunction<_dart_mv_source_fill_by_buffer>(); + + /// @brief Clears the buffer of the media source. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in,out] source The handle to the source + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_source_fill_by_buffer() + int mv_source_clear( + ffi.Pointer source, + ) { + return _mv_source_clear( + source, + ); + } + + late final _mv_source_clear_ptr = + _lookup>('mv_source_clear'); + late final _dart_mv_source_clear _mv_source_clear = + _mv_source_clear_ptr.asFunction<_dart_mv_source_clear>(); + + /// @brief Gets buffer of the media source. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @remarks Note that the retrieved buffer will be destroyed when + /// @ref mv_destroy_source() or @ref mv_source_clear() function + /// is called for the @a source. + /// + /// @param [in] source The handle to the source + /// @param [out] data_buffer The buffer of the source + /// @param [out] buffer_size The size of buffer + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_source_get_width() + /// @see mv_source_get_height() + /// @see mv_source_get_colorspace() + int mv_source_get_buffer( + ffi.Pointer source, + ffi.Pointer> data_buffer, + ffi.Pointer buffer_size, + ) { + return _mv_source_get_buffer( + source, + data_buffer, + buffer_size, + ); + } + + late final _mv_source_get_buffer_ptr = + _lookup>( + 'mv_source_get_buffer'); + late final _dart_mv_source_get_buffer _mv_source_get_buffer = + _mv_source_get_buffer_ptr.asFunction<_dart_mv_source_get_buffer>(); + + /// @brief Gets height of the media source. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in] source The handle to the source + /// @param [out] image_height The height of an image in the source + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_source_get_width() + /// @see mv_source_get_colorspace() + /// @see mv_source_get_buffer() + int mv_source_get_height( + ffi.Pointer source, + ffi.Pointer image_height, + ) { + return _mv_source_get_height( + source, + image_height, + ); + } + + late final _mv_source_get_height_ptr = + _lookup>( + 'mv_source_get_height'); + late final _dart_mv_source_get_height _mv_source_get_height = + _mv_source_get_height_ptr.asFunction<_dart_mv_source_get_height>(); + + /// @brief Gets width of the media source. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in] source The handle to the source + /// @param [out] image_width The width of an image in the source + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_source_get_height() + /// @see mv_source_get_colorspace() + /// @see mv_source_get_buffer() + int mv_source_get_width( + ffi.Pointer source, + ffi.Pointer image_width, + ) { + return _mv_source_get_width( + source, + image_width, + ); + } + + late final _mv_source_get_width_ptr = + _lookup>( + 'mv_source_get_width'); + late final _dart_mv_source_get_width _mv_source_get_width = + _mv_source_get_width_ptr.asFunction<_dart_mv_source_get_width>(); + + /// @brief Gets colorspace of the media source. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in] source The handle to the source + /// @param [out] image_colorspace The colorspace of an image in the source + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_source_get_width() + /// @see mv_source_get_height() + /// @see mv_source_get_buffer() + int mv_source_get_colorspace( + ffi.Pointer source, + ffi.Pointer image_colorspace, + ) { + return _mv_source_get_colorspace( + source, + image_colorspace, + ); + } + + late final _mv_source_get_colorspace_ptr = + _lookup>( + 'mv_source_get_colorspace'); + late final _dart_mv_source_get_colorspace _mv_source_get_colorspace = + _mv_source_get_colorspace_ptr + .asFunction<_dart_mv_source_get_colorspace>(); + + /// @brief Creates the handle to the configuration of engine. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @remarks Available engine configuration attributes can be get by using + /// @ref mv_engine_config_foreach_supported_attribute(). + /// The attributes can be changed by @ref mv_engine_config_h + /// related setters. Default values are used if the attributes + /// are not changed. + /// @param [out] engine_cfg The handle to the engine to be created + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_engine_config_h + /// @see mv_destroy_engine_config() + /// @see mv_engine_config_set_double_attribute() + /// @see mv_engine_config_set_int_attribute() + /// @see mv_engine_config_set_bool_attribute() + /// @see mv_engine_config_set_string_attribute() + /// @see mv_engine_config_get_double_attribute() + /// @see mv_engine_config_get_int_attribute() + /// @see mv_engine_config_get_bool_attribute() + /// @see mv_engine_config_get_string_attribute() + int mv_create_engine_config( + ffi.Pointer> engine_cfg, + ) { + return _mv_create_engine_config( + engine_cfg, + ); + } + + late final _mv_create_engine_config_ptr = + _lookup>( + 'mv_create_engine_config'); + late final _dart_mv_create_engine_config _mv_create_engine_config = + _mv_create_engine_config_ptr.asFunction<_dart_mv_create_engine_config>(); + + /// @brief Destroys the engine configuration handle and releases all its + /// resources. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in] engine_cfg The handle to the engine configuration + /// to be destroyed + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_engine_config_h + /// @see mv_create_engine_config() + int mv_destroy_engine_config( + ffi.Pointer engine_cfg, + ) { + return _mv_destroy_engine_config( + engine_cfg, + ); + } + + late final _mv_destroy_engine_config_ptr = + _lookup>( + 'mv_destroy_engine_config'); + late final _dart_mv_destroy_engine_config _mv_destroy_engine_config = + _mv_destroy_engine_config_ptr + .asFunction<_dart_mv_destroy_engine_config>(); + + /// @brief Sets the double attribute to the configuration. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in] engine_cfg Engine configuration for which @a value has + /// to be set + /// @param [in] name String key of the attribute will be used for + /// storing the @a value into configuration + /// dictionary + /// @param [in] value The double value of the attribute + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_KEY_NOT_AVAILABLE Attribute key isn't available + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_engine_config_get_double_attribute() + /// @see mv_engine_config_set_int_attribute() + /// @see mv_engine_config_set_bool_attribute() + /// @see mv_engine_config_set_string_attribute() + int mv_engine_config_set_double_attribute( + ffi.Pointer engine_cfg, + ffi.Pointer name, + double value, + ) { + return _mv_engine_config_set_double_attribute( + engine_cfg, + name, + value, + ); + } + + late final _mv_engine_config_set_double_attribute_ptr = + _lookup>( + 'mv_engine_config_set_double_attribute'); + late final _dart_mv_engine_config_set_double_attribute + _mv_engine_config_set_double_attribute = + _mv_engine_config_set_double_attribute_ptr + .asFunction<_dart_mv_engine_config_set_double_attribute>(); + + /// @brief Sets the integer attribute to the configuration. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in] engine_cfg Engine configuration for which @a value has + /// to be set + /// @param [in] name String key of the attribute will be used for + /// storing the @a value into configuration + /// dictionary + /// @param [in] value The integer value of the attribute + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_KEY_NOT_AVAILABLE Attribute key isn't available + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_engine_config_get_int_attribute() + /// @see mv_engine_config_set_double_attribute() + /// @see mv_engine_config_set_bool_attribute() + /// @see mv_engine_config_set_string_attribute() + /// @see mv_barcode_detect_attr_target_e + /// @see mv_barcode_generate_attr_text_e + int mv_engine_config_set_int_attribute( + ffi.Pointer engine_cfg, + ffi.Pointer name, + int value, + ) { + return _mv_engine_config_set_int_attribute( + engine_cfg, + name, + value, + ); + } + + late final _mv_engine_config_set_int_attribute_ptr = + _lookup>( + 'mv_engine_config_set_int_attribute'); + late final _dart_mv_engine_config_set_int_attribute + _mv_engine_config_set_int_attribute = + _mv_engine_config_set_int_attribute_ptr + .asFunction<_dart_mv_engine_config_set_int_attribute>(); + + /// @brief Sets the boolean attribute to the configuration. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in] engine_cfg Engine configuration for which @a value has + /// to be set + /// @param [in] name String key of the attribute will be used for + /// storing the @a value into configuration + /// dictionary + /// @param [in] value The boolean value of the attribute + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_KEY_NOT_AVAILABLE Attribute key isn't available + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_engine_config_get_bool_attribute() + /// @see mv_engine_config_set_double_attribute() + /// @see mv_engine_config_set_int_attribute() + /// @see mv_engine_config_set_string_attribute() + int mv_engine_config_set_bool_attribute( + ffi.Pointer engine_cfg, + ffi.Pointer name, + bool value, + ) { + return _mv_engine_config_set_bool_attribute( + engine_cfg, + name, + value ? 1 : 0, + ); + } + + late final _mv_engine_config_set_bool_attribute_ptr = + _lookup>( + 'mv_engine_config_set_bool_attribute'); + late final _dart_mv_engine_config_set_bool_attribute + _mv_engine_config_set_bool_attribute = + _mv_engine_config_set_bool_attribute_ptr + .asFunction<_dart_mv_engine_config_set_bool_attribute>(); + + /// @brief Sets the string attribute to the configuration. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in] engine_cfg Engine configuration for which @a value has + /// to be set + /// @param [in] name String key of the attribute will be used for + /// storing the @a value into configuration + /// dictionary + /// @param [in] value The string value of the attribute + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_KEY_NOT_AVAILABLE Attribute key isn't available + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_engine_config_get_string_attribute() + /// @see mv_engine_config_set_double_attribute() + /// @see mv_engine_config_set_int_attribute() + /// @see mv_engine_config_set_bool_attribute() + int mv_engine_config_set_string_attribute( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer value, + ) { + return _mv_engine_config_set_string_attribute( + engine_cfg, + name, + value, + ); + } + + late final _mv_engine_config_set_string_attribute_ptr = + _lookup>( + 'mv_engine_config_set_string_attribute'); + late final _dart_mv_engine_config_set_string_attribute + _mv_engine_config_set_string_attribute = + _mv_engine_config_set_string_attribute_ptr + .asFunction<_dart_mv_engine_config_set_string_attribute>(); + + /// @brief Gets the double attribute from the configuration dictionary. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in] engine_cfg Engine configuration from which @a value + /// has to be gotten + /// @param [in] name String key of the attribute will be used for + /// getting the @a value from the + /// configuration dictionary + /// @param [out] value The attribute to be filled with double value + /// from dictionary + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_KEY_NOT_AVAILABLE Attribute key isn't available + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_engine_config_set_double_attribute() + /// @see mv_engine_config_get_int_attribute() + /// @see mv_engine_config_get_bool_attribute() + /// @see mv_engine_config_get_string_attribute() + int mv_engine_config_get_double_attribute( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer value, + ) { + return _mv_engine_config_get_double_attribute( + engine_cfg, + name, + value, + ); + } + + late final _mv_engine_config_get_double_attribute_ptr = + _lookup>( + 'mv_engine_config_get_double_attribute'); + late final _dart_mv_engine_config_get_double_attribute + _mv_engine_config_get_double_attribute = + _mv_engine_config_get_double_attribute_ptr + .asFunction<_dart_mv_engine_config_get_double_attribute>(); + + /// @brief Gets the integer attribute from the configuration dictionary. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in] engine_cfg Engine configuration from which @a value + /// has to be gotten + /// @param [in] name String key of the attribute will be used for + /// getting the @a value from the + /// configuration dictionary + /// @param [out] value The attribute to be filled with integer value + /// from dictionary + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_KEY_NOT_AVAILABLE Attribute key isn't available + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_engine_config_set_int_attribute() + /// @see mv_engine_config_get_double_attribute() + /// @see mv_engine_config_get_bool_attribute() + /// @see mv_engine_config_get_string_attribute() + /// @see mv_barcode_detect_attr_target_e + /// @see mv_barcode_generate_attr_text_e + int mv_engine_config_get_int_attribute( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer value, + ) { + return _mv_engine_config_get_int_attribute( + engine_cfg, + name, + value, + ); + } + + late final _mv_engine_config_get_int_attribute_ptr = + _lookup>( + 'mv_engine_config_get_int_attribute'); + late final _dart_mv_engine_config_get_int_attribute + _mv_engine_config_get_int_attribute = + _mv_engine_config_get_int_attribute_ptr + .asFunction<_dart_mv_engine_config_get_int_attribute>(); + + /// @brief Gets the boolean attribute from the configuration dictionary. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in] engine_cfg Engine configuration from which @a value + /// has to be gotten + /// @param [in] name String key of the attribute will be used for + /// getting the @a value from the + /// configuration dictionary + /// @param [out] value The attribute to be filled with boolean value + /// from dictionary + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_KEY_NOT_AVAILABLE Attribute key isn't available + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_engine_config_set_bool_attribute() + /// @see mv_engine_config_get_double_attribute() + /// @see mv_engine_config_get_int_attribute() + /// @see mv_engine_config_get_string_attribute() + int mv_engine_config_get_bool_attribute( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer value, + ) { + return _mv_engine_config_get_bool_attribute( + engine_cfg, + name, + value, + ); + } + + late final _mv_engine_config_get_bool_attribute_ptr = + _lookup>( + 'mv_engine_config_get_bool_attribute'); + late final _dart_mv_engine_config_get_bool_attribute + _mv_engine_config_get_bool_attribute = + _mv_engine_config_get_bool_attribute_ptr + .asFunction<_dart_mv_engine_config_get_bool_attribute>(); + + /// @brief Gets the string attribute from the configuration dictionary. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @remarks Function allocates memory required for output @a value, so + /// it has to be removed by the user himself. + /// @param [in] engine_cfg Engine configuration from which @a value + /// has to be gotten + /// @param [in] name String key of the attribute will be used for + /// getting the @a value from the + /// configuration dictionary + /// @param [out] value The attribute to be filled with string value + /// from dictionary + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_KEY_NOT_AVAILABLE Attribute key isn't available + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_engine_config_set_string_attribute() + /// @see mv_engine_config_get_double_attribute() + /// @see mv_engine_config_get_int_attribute() + /// @see mv_engine_config_get_bool_attribute() + int mv_engine_config_get_string_attribute( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer> value, + ) { + return _mv_engine_config_get_string_attribute( + engine_cfg, + name, + value, + ); + } + + late final _mv_engine_config_get_string_attribute_ptr = + _lookup>( + 'mv_engine_config_get_string_attribute'); + late final _dart_mv_engine_config_get_string_attribute + _mv_engine_config_get_string_attribute = + _mv_engine_config_get_string_attribute_ptr + .asFunction<_dart_mv_engine_config_get_string_attribute>(); + + /// @brief Traverses the list of supported attribute names and types. + /// @details Using this function names of supported attributes can be obtained. + /// Names of the attributes can be used with @ref mv_engine_config_h + /// related getters and setters to get/set appropriate attribute values. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @remarks If @a callback is called zero times after + /// @ref mv_engine_config_foreach_supported_attribute() call, then + /// engine configuration is not supported and setting of attributes will + /// cause no effect. In this case for all Media Vision functions which + /// require @ref mv_engine_config_h handle as in parameter this + /// parameter can be set NULL. + /// @remarks If @a callback is called at least once, then attribute names and + /// types obtained in the @ref mv_supported_attribute_cb callback can be + /// changed after mv_engine_config_h handle creation (with + /// @ref mv_create_engine_config() function) by corresponding setters. + /// Although, if attributes aren't changed by setters, then default + /// values will be used.\n + /// Changing of attribute values will affect internal functionality + /// provided by concrete library underlying Media Vision API. + /// @param [in] callback The iteration callback function + /// @param [in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_NO_DATA Can't determine list of supported attributes + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_engine_config_set_double_attribute() + /// @see mv_engine_config_set_int_attribute() + /// @see mv_engine_config_set_bool_attribute() + /// @see mv_engine_config_set_string_attribute() + /// @see mv_engine_config_get_double_attribute() + /// @see mv_engine_config_get_int_attribute() + /// @see mv_engine_config_get_bool_attribute() + /// @see mv_engine_config_get_string_attribute() + int mv_engine_config_foreach_supported_attribute( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mv_engine_config_foreach_supported_attribute( + callback, + user_data, + ); + } + + late final _mv_engine_config_foreach_supported_attribute_ptr = _lookup< + ffi.NativeFunction<_c_mv_engine_config_foreach_supported_attribute>>( + 'mv_engine_config_foreach_supported_attribute'); + late final _dart_mv_engine_config_foreach_supported_attribute + _mv_engine_config_foreach_supported_attribute = + _mv_engine_config_foreach_supported_attribute_ptr + .asFunction<_dart_mv_engine_config_foreach_supported_attribute>(); + + /// @brief Detects barcode(s) on source and reads message from it. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @param [in] source The media source handle + /// @param [in] engine_cfg The handle to the configuration of the engine + /// @param [in] roi Region of interest - rectangular area on the + /// @a source which will be used for barcode detection + /// Note that @a roi should be inside area on the + /// @a source. + /// @param [in] detect_cb The callback for result handling + /// @param [in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Not supported format + /// @retval #MEDIA_VISION_ERROR_INTERNAL Internal error + /// + /// @pre Create a source handle by calling @ref mv_create_source() + /// @pre Create an engine configuration handle by calling + /// @ref mv_create_engine_config(), otherwise use NULL + /// + /// @see mv_barcode_detected_cb() + int mv_barcode_detect( + ffi.Pointer source, + ffi.Pointer engine_cfg, + mv_rectangle_s roi, + ffi.Pointer> detect_cb, + ffi.Pointer user_data, + ) { + return _mv_barcode_detect( + source, + engine_cfg, + roi, + detect_cb, + user_data, + ); + } + + late final _mv_barcode_detect_ptr = + _lookup>('mv_barcode_detect'); + late final _dart_mv_barcode_detect _mv_barcode_detect = + _mv_barcode_detect_ptr.asFunction<_dart_mv_barcode_detect>(); + + /// @brief Generates @ref mv_source_h with barcode image. + /// @details Pay attention that for EAN-8 and EAN-13 barcode types the barcode + /// type may be selected automatically and this selection depends on the input + /// message length. Also for QR codes the version may be selected as minimum + /// required to generate QR code with the input message length. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @remarks If the text attribute of engine configuration is set to + /// MV_BARCODE_GENERATE_ATTR_TEXT_VISIBLE, + /// MEDIA_VISION_ERROR_INVALID_OPERATION will be return + /// when @a type is MV_BARCODE_QR + /// + /// @param [in] engine_cfg The handle to the configuration of the engine + /// @param [in] message The message to be encoded in the barcode + /// @param [in] type Type of the barcode to be generated + /// @param [in] qr_enc_mode Encoding mode for the message (only for QR codes; + /// for 1D barcodes set this parameter to + /// @a MV_BARCODE_QR_MODE_UNAVAILABLE) + /// @param [in] qr_ecc Error correction level (only for QR codes; for + /// 1D barcodes set this parameter to + /// @a MV_BARCODE_QR_ECC_UNAVAILABLE) + /// @param [in] qr_version QR code version (for 1D barcodes set this + /// parameter to 0) + /// @param [in, out] image The media source handle which will be used to + /// fill by the buffer with generated image + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_MSG_TOO_LONG Too long or short message + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// @retval #MEDIA_VISION_ERROR_INVALID_DATA Invalid data + /// @retval #MEDIA_VISION_ERROR_INTERNAL Internal error + /// @retval #MEDIA_VISION_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre Create an engine configuration handle by calling + /// @ref mv_create_engine_config(), otherwise use NULL + /// + /// @see mv_barcode_generate_image() + int mv_barcode_generate_source( + ffi.Pointer engine_cfg, + ffi.Pointer message, + int type, + int qr_enc_mode, + int qr_ecc, + int qr_version, + ffi.Pointer image, + ) { + return _mv_barcode_generate_source( + engine_cfg, + message, + type, + qr_enc_mode, + qr_ecc, + qr_version, + image, + ); + } + + late final _mv_barcode_generate_source_ptr = + _lookup>( + 'mv_barcode_generate_source'); + late final _dart_mv_barcode_generate_source _mv_barcode_generate_source = + _mv_barcode_generate_source_ptr + .asFunction<_dart_mv_barcode_generate_source>(); + + /// @brief Generates image file with barcode. + /// @details Pay attention that for EAN-8 and EAN-13 barcode types the barcode + /// type may be selected automatically and this selection depends on the input + /// message length. Also for QR codes the version may be selected as minimum + /// required to generate QR code with the input message length. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @remarks If the text attribute of engine configuration is set to + /// MV_BARCODE_GENERATE_ATTR_TEXT_VISIBLE, + /// MEDIA_VISION_ERROR_INVALID_OPERATION will be return + /// when @a type is MV_BARCODE_QR + /// + /// @remarks The mediastorage privilege http://tizen.org/privilege/mediastorage is needed \n + /// if @a image_path is relevant to media storage.\n + /// The externalstorage privilege http://tizen.org/privilege/externalstorage is needed \n + /// if @a image_path is relevant to external storage. + /// @param [in] engine_cfg The handle to the configuration of the engine + /// @param [in] message The message to be encoded in the barcode + /// @param [in] image_width The width of the generated image + /// @param [in] image_height The height of the generated image + /// @param [in] type Type of the barcode to be generated + /// @param [in] qr_enc_mode Encoding mode for the message (only for QR codes; + /// for 1D barcodes set this parameter to + /// @a MV_BARCODE_QR_MODE_UNAVAILABLE) + /// @param [in] qr_ecc Error correction level (only for QR codes; for + /// 1D barcodes set this parameter to + /// @a MV_BARCODE_QR_ECC_UNAVAILABLE) + /// @param [in] qr_version QR code version (for 1D barcodes set this + /// parameter to 0) + /// @param [in] image_path The path to the file that has to be generated + /// @param [in] image_format The format of the output image + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_MSG_TOO_LONG Too long or short message + /// @retval #MEDIA_VISION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// @retval #MEDIA_VISION_ERROR_INVALID_DATA Invalid data + /// @retval #MEDIA_VISION_ERROR_INVALID_PATH Invalid path + /// @retval #MEDIA_VISION_ERROR_INTERNAL Internal error + /// @retval #MEDIA_VISION_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre Create an engine configuration handle by calling + /// @ref mv_create_engine_config(), otherwise use NULL + /// + /// @see mv_barcode_generate_source() + int mv_barcode_generate_image( + ffi.Pointer engine_cfg, + ffi.Pointer message, + int image_width, + int image_height, + int type, + int qr_enc_mode, + int qr_ecc, + int qr_version, + ffi.Pointer image_path, + int image_format, + ) { + return _mv_barcode_generate_image( + engine_cfg, + message, + image_width, + image_height, + type, + qr_enc_mode, + qr_ecc, + qr_version, + image_path, + image_format, + ); + } + + late final _mv_barcode_generate_image_ptr = + _lookup>( + 'mv_barcode_generate_image'); + late final _dart_mv_barcode_generate_image _mv_barcode_generate_image = + _mv_barcode_generate_image_ptr + .asFunction<_dart_mv_barcode_generate_image>(); + + /// @brief Performs face detection on the @a source for the @a engine_conf. + /// @details Use this function to launch face detection algorithm configured by + /// @a engine_conf configuration. Each time when mv_face_detect is + /// called, @a detected_cb will receive a set of the detected + /// faces at the media source. + /// + /// @since_tizen 3.0 + /// @param [in] source The handle to the source of the media where faces + /// will be detected + /// @param [in] engine_cfg The handle to the configuration of engine will be + /// used for detecting. If NULL, then default settings + /// will be used. + /// @param [in] detected_cb The callback which will be called for all face + /// locations detected on media source. This callback + /// will receive detecting results + /// @param [in] user_data The user data passed from the code where + /// @ref mv_face_detect() is invoked. This data will + /// be accessible from @a detected_cb callback. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Source colorspace + /// isn't supported + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create a source handle by calling @ref mv_create_source() + /// @post @a detected_cb will be called to process detection results + /// + /// @see mv_face_detected_cb + int mv_face_detect( + ffi.Pointer source, + ffi.Pointer engine_cfg, + ffi.Pointer> detected_cb, + ffi.Pointer user_data, + ) { + return _mv_face_detect( + source, + engine_cfg, + detected_cb, + user_data, + ); + } + + late final _mv_face_detect_ptr = + _lookup>('mv_face_detect'); + late final _dart_mv_face_detect _mv_face_detect = + _mv_face_detect_ptr.asFunction<_dart_mv_face_detect>(); + + /// @brief Performs face recognition on the @a source image. + /// @details Use this function to launch face recognition algorithm configured by + /// @a engine_conf configuration using @a recognition_model recognition + /// model. Each time when @ref mv_face_recognize() is called, + /// @a recognized_cb will receive recognition results:\n + /// - Location in the @a source of the face has been recognized; + /// - Label of the face has been recognized; + /// - Confidence of the @a recognition_model that face has been + /// recognized correctly (value from 0.0 to 1.0). + /// + /// @since_tizen 3.0 + /// @remarks Using of untrained or weakly trained recognition models will cause + /// not accurate results even if resulting confidence will be high. + /// Use @ref mv_face_recognition_model_learn() function before + /// @ref mv_face_recognize() call. Best results can be achieved when big + /// set of face image examples were added by + /// @ref mv_face_recognition_model_add() before + /// @ref mv_face_recognition_model_learn() call. + /// @param [in] source The handle to the source of the media to + /// recognize face(s) for + /// @param [in] recognition_model The handle to the model will be used for + /// recognition + /// @param [in] engine_cfg The handle to the configuration of engine + /// will be used for recognition. If NULL, then + /// default settings will be used + /// @param [in] face_location Rectangular box bounding face image on the + /// @a source. If NULL, then full source will be + /// analyzed + /// @param [in] recognized_cb The callback which will be called for the + /// face recognition results on the @a source. + /// @param [in] user_data The user data passed from the code where + /// @ref mv_face_recognize() is invoked. This + /// data will be accessible from @a recognized_cb + /// callback + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Source colorspace + /// isn't supported + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create a source handle by calling @ref mv_create_source() + /// @pre Create a face recognition model handle by calling + /// @ref mv_face_recognition_model_create() + /// @post @a recognized_cb will be called to process recognition results + /// + /// @see mv_face_recognized_cb + int mv_face_recognize( + ffi.Pointer source, + ffi.Pointer recognition_model, + ffi.Pointer engine_cfg, + ffi.Pointer face_location, + ffi.Pointer> recognized_cb, + ffi.Pointer user_data, + ) { + return _mv_face_recognize( + source, + recognition_model, + engine_cfg, + face_location, + recognized_cb, + user_data, + ); + } + + late final _mv_face_recognize_ptr = + _lookup>('mv_face_recognize'); + late final _dart_mv_face_recognize _mv_face_recognize = + _mv_face_recognize_ptr.asFunction<_dart_mv_face_recognize>(); + + /// @brief Performs face tracking on the @a source for the @a tracking_model. + /// @details Use this function to launch face tracking algorithm configured by + /// @a engine_conf configuration using @a tracking_model tracking + /// model. Each time when this function is called, @a tracked_cb + /// will receive updated @a tracking_model, new location determined for + /// the tracked face and model confidence that location is determined + /// correctly. + /// + /// @since_tizen 3.0 + /// @remarks To allow correct tracking @a tracking_model has to be already used + /// in previous tracking process(es) or prepared with + /// @ref mv_face_tracking_model_prepare(). Preparation requires + /// specifying the face location for the @a source on which tracking was + /// started. I.e. @ref mv_face_tracking_model_prepare() function has to + /// be called at least once before this method call. + /// @param [in] source The handle to the source of the media to + /// recognize face for + /// @param [in] tracking_model The handle to the model will be used for + /// tracking + /// @param [in] engine_cfg The handle to the configuration of engine will + /// be used for tracking. If NULL, the default + /// configuration will be used. + /// @param [in] tracked_cb The callback which will be called for tracking + /// event on the @a source where face would be + /// tracked. This callback will receive tracking + /// results + /// @param [in] do_learn The model learning flag. If it is set @c true + /// then model will try to learn (if it supports + /// learning feature), otherwise model will be not + /// learned during the invoking tracking iteration. + /// Learning process improves tracking correctness, + /// but can decrease tracking performance + /// @param [in] user_data The user data passed from the code where + /// @ref mv_face_track() is invoked. This data will + /// be accessible from @a tracked_cb callback + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Source colorspace + /// isn't supported + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create a source handle by calling @ref mv_create_source() + /// @pre Create a face tracking model handle by calling + /// @ref mv_face_tracking_model_create() + /// @post @a tracked_cb will be called to process tracking results + /// + /// @see mv_face_tracked_cb + int mv_face_track( + ffi.Pointer source, + ffi.Pointer tracking_model, + ffi.Pointer engine_cfg, + ffi.Pointer> tracked_cb, + bool do_learn, + ffi.Pointer user_data, + ) { + return _mv_face_track( + source, + tracking_model, + engine_cfg, + tracked_cb, + do_learn ? 1 : 0, + user_data, + ); + } + + late final _mv_face_track_ptr = + _lookup>('mv_face_track'); + late final _dart_mv_face_track _mv_face_track = + _mv_face_track_ptr.asFunction<_dart_mv_face_track>(); + + /// @brief Determines eye-blink condition for @a face_location on media @a source. + /// @details Use this function to recognize eye-blink condition for the face + /// bounded by @a face_location at @a source. + /// + /// @since_tizen 3.0 + /// @param [in] source The handle to the source of the media to + /// recognize eye-blink condition for + /// @param [in] engine_cfg The handle to the configuration of engine + /// will be used for eye-blink condition + /// recognition. If NULL, the default configuration + /// will be used. + /// @param [in] face_location The location bounding the face at the @a source + /// @param [in] eye_condition_recognized_cb The callback for processing result + /// of eye-blink condition recognition + /// @param [in] user_data The user data passed from the code where + /// mv_face_eye_condition_recognize() is invoked. + /// This data will be accessible from + /// @a eye_condition_recognized_cb callback. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Source colorspace + /// isn't supported + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create a source handle by calling mv_create_source() + /// + /// @see mv_face_eye_condition_recognized_cb + int mv_face_eye_condition_recognize( + ffi.Pointer source, + ffi.Pointer engine_cfg, + mv_rectangle_s face_location, + ffi.Pointer> + eye_condition_recognized_cb, + ffi.Pointer user_data, + ) { + return _mv_face_eye_condition_recognize( + source, + engine_cfg, + face_location, + eye_condition_recognized_cb, + user_data, + ); + } + + late final _mv_face_eye_condition_recognize_ptr = + _lookup>( + 'mv_face_eye_condition_recognize'); + late final _dart_mv_face_eye_condition_recognize + _mv_face_eye_condition_recognize = _mv_face_eye_condition_recognize_ptr + .asFunction<_dart_mv_face_eye_condition_recognize>(); + + /// @brief Determines facial expression for @a face_location on media @a source. + /// @details Use this function to determine facial expression for the face + /// bounded by @a face_location at @a source. + /// + /// @since_tizen 3.0 + /// @param [in] source The handle to the source of the media + /// to recognize facial expression for + /// @param [in] engine_cfg The handle to the configuration of + /// engine will be used for expression recognition + /// @param [in] face_location The location bounding the face at the @a source + /// @param [in] expression_recognized_cb The callback for processing result + /// of facial expression determining + /// @param [in] user_data The user data passed from the code where + /// mv_face_facial_expression_recognize() is invoked. + /// This data will be accessible from + /// @a expression_recognized_cb callback. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Source colorspace + /// isn't supported + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create a source handle by calling mv_create_source() + /// @pre Create a face engine configuration handle by calling @ref mv_create_engine_config() + /// + /// @see mv_face_facial_expression_recognized_cb + int mv_face_facial_expression_recognize( + ffi.Pointer source, + ffi.Pointer engine_cfg, + mv_rectangle_s face_location, + ffi.Pointer> + expression_recognized_cb, + ffi.Pointer user_data, + ) { + return _mv_face_facial_expression_recognize( + source, + engine_cfg, + face_location, + expression_recognized_cb, + user_data, + ); + } + + late final _mv_face_facial_expression_recognize_ptr = + _lookup>( + 'mv_face_facial_expression_recognize'); + late final _dart_mv_face_facial_expression_recognize + _mv_face_facial_expression_recognize = + _mv_face_facial_expression_recognize_ptr + .asFunction<_dart_mv_face_facial_expression_recognize>(); + + /// @brief Creates a face recognition model handle. + /// @details Use this function to create default face recognition model. Creating + /// process is defined by concrete face engine library. After creation + /// recognition model has to be learned with + /// @ref mv_face_recognition_model_learn() function to provide + /// appropriate results of face recognition functionality. Or learned + /// earlier model can be loaded by @ref mv_face_recognition_model_load() + /// function. + /// + /// @since_tizen 3.0 + /// @remarks It can cause incompatibility issues when saved models (see + /// @ref mv_face_recognition_model_save(), + /// @ref mv_face_recognition_model_load() + /// functions documentation) are used in applications for different + /// platforms which use different computer vision libraries underlying + /// this API. + /// @remarks You must release @a recognition_model by using + /// @ref mv_face_recognition_model_destroy() function. + /// @param [out] recognition_model The handle to the recognition model to be + /// created + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @post Model can be loaded from the file after creation. Use + /// @ref mv_face_recognition_model_load() function to load it from file + /// @post Release @a recognition_model by using + /// @ref mv_face_recognition_model_destroy() function when it is not needed + /// anymore + /// + /// @see mv_face_recognition_model_destroy() + int mv_face_recognition_model_create( + ffi.Pointer> recognition_model, + ) { + return _mv_face_recognition_model_create( + recognition_model, + ); + } + + late final _mv_face_recognition_model_create_ptr = + _lookup>( + 'mv_face_recognition_model_create'); + late final _dart_mv_face_recognition_model_create + _mv_face_recognition_model_create = _mv_face_recognition_model_create_ptr + .asFunction<_dart_mv_face_recognition_model_create>(); + + /// @brief Destroys the face recognition model handle and releases all its + /// resources. + /// + /// @since_tizen 3.0 + /// @param [in] recognition_model The handle to the face recognition model to + /// be destroyed + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create recognition model by using @ref mv_face_recognition_model_create() + /// + /// @see mv_face_recognition_model_create() + int mv_face_recognition_model_destroy( + ffi.Pointer recognition_model, + ) { + return _mv_face_recognition_model_destroy( + recognition_model, + ); + } + + late final _mv_face_recognition_model_destroy_ptr = + _lookup>( + 'mv_face_recognition_model_destroy'); + late final _dart_mv_face_recognition_model_destroy + _mv_face_recognition_model_destroy = + _mv_face_recognition_model_destroy_ptr + .asFunction<_dart_mv_face_recognition_model_destroy>(); + + /// @brief Creates a copy of existed recognition model handle and clones all its + /// resources. + /// + /// @since_tizen 3.0 + /// @remarks Cloning perform not only handle copy, but also copies all internal + /// resources of the model. @a dst must be released using + /// @ref mv_face_recognition_model_destroy(). + /// @param [in] src The handle to the recognition model to be copied + /// @param [out] dst The handle to the copy of existed recognition model + /// specified as @a src + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create face recognition handles by calling + /// @ref mv_face_recognition_model_create() + /// + /// @see mv_face_recognition_model_create() + int mv_face_recognition_model_clone( + ffi.Pointer src, + ffi.Pointer> dst, + ) { + return _mv_face_recognition_model_clone( + src, + dst, + ); + } + + late final _mv_face_recognition_model_clone_ptr = + _lookup>( + 'mv_face_recognition_model_clone'); + late final _dart_mv_face_recognition_model_clone + _mv_face_recognition_model_clone = _mv_face_recognition_model_clone_ptr + .asFunction<_dart_mv_face_recognition_model_clone>(); + + /// @brief Saves recognition model to the file. + /// + /// @since_tizen 3.0 + /// @remarks This function doesn't save face image examples (image itself) added by + /// @ref mv_face_recognition_model_add() function. + /// This examples can be removed by + /// @ref mv_face_recognition_model_reset() function if + /// it is needed to clear the memory. + /// @remarks @a recognition_model is saved to the absolute path directory. + /// Use @ref app_get_data_path for the private app storage path. + /// After model is saved to the file, it can be loaded from this file + /// by @ref mv_face_recognition_model_load() function. + /// @param [in] file_name Name of the path/file to save the model + /// @param [in] recognition_model The handle to the recognition model to be + /// saved to the file + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_VISION_ERROR_INVALID_PATH Invalid path + /// @retval #MEDIA_VISION_ERROR_PERMISSION_DENIED Not permitted + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Not supported model format + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create a face recognition handle by calling + /// @ref mv_face_recognition_model_create() function + /// @post Saved model can be loaded later by calling + /// @ref mv_face_recognition_model_load() function + /// + /// @see mv_face_recognition_model_load() + /// @see mv_face_recognition_model_create() + /// @see app_get_data_path() + int mv_face_recognition_model_save( + ffi.Pointer file_name, + ffi.Pointer recognition_model, + ) { + return _mv_face_recognition_model_save( + file_name, + recognition_model, + ); + } + + late final _mv_face_recognition_model_save_ptr = + _lookup>( + 'mv_face_recognition_model_save'); + late final _dart_mv_face_recognition_model_save + _mv_face_recognition_model_save = _mv_face_recognition_model_save_ptr + .asFunction<_dart_mv_face_recognition_model_save>(); + + /// @brief Loads recognition model from file. + /// + /// @since_tizen 3.0 + /// @remarks This function doesn't modify the set of face image examples added + /// with @ref mv_face_recognition_model_add() function. + /// Model will be loaded from file without loss of collected examples. + /// If you want to free memory from examples, use + /// @ref mv_face_recognition_model_reset() function. It + /// is recommended to clear the memory if learning algorithm doesn't + /// support reinforcement learning. + /// @remarks @a recognition_model is loaded from the absolute path directory. + /// Use @ref app_get_data_path for the private app storage path. + /// @a recognition_model must be destroyed using + /// @ref mv_face_recognition_model_destroy(). + /// @param [in] file_name Name of path/file to load the model + /// @param [out] recognition_model The handle to the recognition model + /// to be loaded from the file + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_INVALID_PATH Invalid path + /// @retval #MEDIA_VISION_ERROR_PERMISSION_DENIED Not permitted + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Not supported model format + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Recognition model can be preliminary saved with + /// @ref mv_face_recognition_model_save() function + /// + /// @see mv_face_recognition_model_save() + /// @see mv_face_recognition_model_destroy() + /// @see app_get_data_path() + int mv_face_recognition_model_load( + ffi.Pointer file_name, + ffi.Pointer> recognition_model, + ) { + return _mv_face_recognition_model_load( + file_name, + recognition_model, + ); + } + + late final _mv_face_recognition_model_load_ptr = + _lookup>( + 'mv_face_recognition_model_load'); + late final _dart_mv_face_recognition_model_load + _mv_face_recognition_model_load = _mv_face_recognition_model_load_ptr + .asFunction<_dart_mv_face_recognition_model_load>(); + + /// @brief Adds face image example to be used for face recognition model learning + /// with @ref mv_face_recognition_model_learn(). + /// + /// @since_tizen 3.0 + /// @remarks It is possible to destroy @a source after calling this method. + /// Source isn't used for learning directly. + /// @remarks Face image @a example_location location can be determined using + /// @ref mv_face_detect function. + /// @param [in] source The handle to @a source that contains face + /// image + /// @param [in] recognition_model The handle to the recognition model which + /// could be learned based on example + /// @param [in] example_location The pointer to the rectangular location of + /// the face image at the source image. If NULL, + /// then full image will be analyzed as the face + /// image + /// @param [in] face_label The label that identifies face for which + /// example is adding. Specify the same labels + /// for the face images of a single person when + /// calling this method. Has to be unique for + /// each face + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Source colorspace + /// isn't supported + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create a face recognition handle by calling + /// @ref mv_face_recognition_model_create() function + /// @post When appropriate amount of face image examples is added to the + /// @a recognition_model, this model has to be learned by + /// @ref mv_face_recognition_model_learn() function call. Only after + /// learning of the model it can be used for face recognition with + /// @ref mv_face_recognize() function + /// + /// @see mv_face_recognition_model_reset() + /// @see mv_face_recognition_model_learn() + int mv_face_recognition_model_add( + ffi.Pointer source, + ffi.Pointer recognition_model, + ffi.Pointer example_location, + int face_label, + ) { + return _mv_face_recognition_model_add( + source, + recognition_model, + example_location, + face_label, + ); + } + + late final _mv_face_recognition_model_add_ptr = + _lookup>( + 'mv_face_recognition_model_add'); + late final _dart_mv_face_recognition_model_add + _mv_face_recognition_model_add = _mv_face_recognition_model_add_ptr + .asFunction<_dart_mv_face_recognition_model_add>(); + + /// @brief Removes from @a recognition_model all collected with + /// @ref mv_face_recognition_model_add() function + /// face examples labeled with @a face_label. + /// + /// @since_tizen 3.0 + /// @remarks Be aware that if this function is called before + /// @ref mv_face_recognition_model_learn() function call, all or part of + /// the required for learning data will be lost. It means that face + /// image examples determined by the @a face_label label will be removed + /// from the model and not taken into account when + /// @ref mv_face_recognition_model_learn() will be called next time. + /// @remarks Call of this function will free all the memory has been allocated + /// during previous @ref mv_face_recognition_model_add() + /// calls for the corresponding @a face_label label. + /// @param [in] recognition_model The handle to the recognition model for + /// which face image examples will be reset. + /// @param [in] face_label The label that identifies face for which + /// examples will be removed from the + /// @a recognition_model. If NULL, then all + /// known by @a recognition_model face image + /// examples will be removed + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_KEY_NOT_AVAILABLE Key not available + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_face_recognition_model_add() + /// @see mv_face_recognition_model_learn() + int mv_face_recognition_model_reset( + ffi.Pointer recognition_model, + ffi.Pointer face_label, + ) { + return _mv_face_recognition_model_reset( + recognition_model, + face_label, + ); + } + + late final _mv_face_recognition_model_reset_ptr = + _lookup>( + 'mv_face_recognition_model_reset'); + late final _dart_mv_face_recognition_model_reset + _mv_face_recognition_model_reset = _mv_face_recognition_model_reset_ptr + .asFunction<_dart_mv_face_recognition_model_reset>(); + + /// @brief Learns face recognition model. + /// @details Before you start learning process, face recognition models has to be + /// filled with training data - face image examples. These examples has + /// to be provided by + /// @ref mv_face_recognition_model_add() function. + /// Usually, recognition accuracy is increased when number of not + /// identical examples is large. But it depends on the used learning + /// algorithm. + /// + /// @since_tizen 3.0 + /// @remarks Common flow is to collect face examples as much as possible, add + /// them to the recognition model with + /// @ref mv_face_recognition_model_add(), then call + /// @ref mv_face_recognition_model_learn() for this recognition model to + /// learn it (or update the model if updating is supported by the used + /// algorithm). + /// @remarks Selection of the learning algorithm can be performed by setting + /// corresponding attributes for the @a engine_cfg. You can check + /// supported by @a engine_cfg attributes using + /// @ref mv_engine_config_foreach_supported_attribute() function call. + /// By default, Local Binary Patterns Histograms (LBPH) based + /// recognition algorithm will be used. + /// @param [in] engine_cfg The handle to the configuration of + /// engine will be used for learning of the + /// recognition models. If NULL, then + /// default settings will be used + /// @param [in,out] recognition_model The model which will be learned. After + /// learning process these model may be + /// changed, so @ref mv_face_recognize() + /// results may differ before and after + /// method call respectively to the face + /// examples collected for the + /// @a recognition_model + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NO_DATA No data + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create a face engine configuration handle by calling + /// @ref mv_create_engine_config() and set supported parameters if + /// needed. Or just set @a engine_cfg as NULL to learn with default settings + /// @pre Create a face recognition model handles by calling + /// @ref mv_face_recognition_model_create() function + /// @pre Add face image examples to the @a recognition_model by calling + /// @ref mv_face_recognition_model_add() function + /// @post If it is not planned to learn the model again, clear memory by + /// @ref mv_face_recognition_model_reset() function + /// @post When model has been learned, it can be used for face recognition with + /// @ref mv_face_recognize() function + /// + /// @see mv_face_recognition_model_add() + /// @see mv_face_recognition_model_reset() + /// @see mv_face_recognize() + int mv_face_recognition_model_learn( + ffi.Pointer engine_cfg, + ffi.Pointer recognition_model, + ) { + return _mv_face_recognition_model_learn( + engine_cfg, + recognition_model, + ); + } + + late final _mv_face_recognition_model_learn_ptr = + _lookup>( + 'mv_face_recognition_model_learn'); + late final _dart_mv_face_recognition_model_learn + _mv_face_recognition_model_learn = _mv_face_recognition_model_learn_ptr + .asFunction<_dart_mv_face_recognition_model_learn>(); + + /// @brief Queries labels list and number of labels had been learned by the model. + /// + /// @since_tizen 3.0 + /// @remarks @a labels array has to be released using free(). + /// @param [in] recognition_model The handle to the recognition model for + /// which set of the learned labels will be + /// queried + /// @param [out] labels The array which will be filled with labels + /// had been learned by the model + /// @param [out] number_of_labels The number of labels in @a labels array + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Add face image examples with labels to the @a recognition_model by + /// calling the @ref mv_face_recognition_model_add() function + /// @pre Learn the @a recognition_model by labeled examples using + /// @ref mv_face_recognition_model_learn() function + /// @post @a labels array has to be freed in the function invoking code + /// + /// @see mv_face_recognition_model_add() + /// @see mv_face_recognition_model_reset() + /// @see mv_face_recognition_model_learn() + int mv_face_recognition_model_query_labels( + ffi.Pointer recognition_model, + ffi.Pointer> labels, + ffi.Pointer number_of_labels, + ) { + return _mv_face_recognition_model_query_labels( + recognition_model, + labels, + number_of_labels, + ); + } + + late final _mv_face_recognition_model_query_labels_ptr = + _lookup>( + 'mv_face_recognition_model_query_labels'); + late final _dart_mv_face_recognition_model_query_labels + _mv_face_recognition_model_query_labels = + _mv_face_recognition_model_query_labels_ptr + .asFunction<_dart_mv_face_recognition_model_query_labels>(); + + /// @brief Calls this function to create a face tracking model handle. + /// @details Use this function to create default face tracking model handle. + /// After creation this handle has to be initialized with + /// @ref mv_face_tracking_model_prepare() function to provide + /// appropriate results of face tracking functionality. When handle is + /// prepared, it is possible to use it for tracking on continuous + /// sequence of the sources. Call @ref mv_face_tracking_model_prepare() + /// function each time before starting tracking on the new sequence. + /// The exception is situation when the new sequence is continuation + /// of the previous sequence for which model has been tracked. + /// + /// @since_tizen 3.0 + /// @param [out] tracking_model The pointer to the handle to the tracking + /// model that will be created + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @post Model can be loaded from the file after creation. Use + /// @ref mv_face_tracking_model_load() function to load it from file + /// @post Use @ref mv_face_tracking_model_prepare() function before tracking on + /// the new video or continuous images sequence + /// @post Release @a tracking_model by using + /// @ref mv_face_tracking_model_destroy() function when it is not needed + /// anymore + /// + /// @see mv_face_tracking_model_destroy() + /// @see mv_face_tracking_model_prepare() + /// @see mv_face_tracking_model_load() + int mv_face_tracking_model_create( + ffi.Pointer> tracking_model, + ) { + return _mv_face_tracking_model_create( + tracking_model, + ); + } + + late final _mv_face_tracking_model_create_ptr = + _lookup>( + 'mv_face_tracking_model_create'); + late final _dart_mv_face_tracking_model_create + _mv_face_tracking_model_create = _mv_face_tracking_model_create_ptr + .asFunction<_dart_mv_face_tracking_model_create>(); + + /// @brief Calls this function to destroy the face tracking model handle and + /// release all its resources. + /// + /// @since_tizen 3.0 + /// @param [in] tracking_model The handle to the face tracking model that + /// will be destroyed + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create tracking model by using @ref mv_face_tracking_model_create() + /// + /// @see mv_face_tracking_model_create() + int mv_face_tracking_model_destroy( + ffi.Pointer tracking_model, + ) { + return _mv_face_tracking_model_destroy( + tracking_model, + ); + } + + late final _mv_face_tracking_model_destroy_ptr = + _lookup>( + 'mv_face_tracking_model_destroy'); + late final _dart_mv_face_tracking_model_destroy + _mv_face_tracking_model_destroy = _mv_face_tracking_model_destroy_ptr + .asFunction<_dart_mv_face_tracking_model_destroy>(); + + /// @brief Calls this function to initialize tracking model by the location of the + /// face to be tracked. + /// @details This function is usually called once after tracking model is created + /// and each time before tracking is started for the new sequence of + /// sources which is not the direct continuation of the sequence for + /// which tracking has been performed before. But it is allowed to call + /// it between tracking sessions to allow Media Vision start to track + /// more accurately. + /// + /// @since_tizen 3.0 + /// @param [in] tracking_model The handle to the tracking model that will be + /// prepared for tracking on new video or image + /// sequence + /// @param [in] engine_cfg The handle to the configuration of engine + /// will be used for model preparing. If NULL, then + /// default settings will be used. + /// @param [in] source The handle to the source where face @a location + /// is specified. Usually it is the first frame of + /// the video or the first image in the continuous + /// image sequence planned to be used for tracking + /// @param [in] location The quadrangle-shaped location (actually, + /// rectangle can be used) determining position + /// of the face to be tracked on the @a source. If + /// @c NULL, then tracking model will try to find + /// previously tracked face by itself. Don't set + /// NULL when called first time for the tracking + /// model. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create a face tracking model handle by calling + /// @ref mv_face_tracking_model_create() function + /// @pre Create a source handle by calling @ref mv_create_source() function + /// @post When model is prepared, @ref mv_face_track() function can be used to + /// track on the video or continuous image sequence + /// + /// @see mv_face_tracking_model_create() + /// @see mv_face_track() + int mv_face_tracking_model_prepare( + ffi.Pointer tracking_model, + ffi.Pointer engine_cfg, + ffi.Pointer source, + ffi.Pointer location, + ) { + return _mv_face_tracking_model_prepare( + tracking_model, + engine_cfg, + source, + location, + ); + } + + late final _mv_face_tracking_model_prepare_ptr = + _lookup>( + 'mv_face_tracking_model_prepare'); + late final _dart_mv_face_tracking_model_prepare + _mv_face_tracking_model_prepare = _mv_face_tracking_model_prepare_ptr + .asFunction<_dart_mv_face_tracking_model_prepare>(); + + /// @brief Calls this function to make a copy of existed tracking model handle and + /// clone all its resources to the copy. + /// + /// @since_tizen 3.0 + /// @remarks Cloning performs not only handle copy, but also copies all internal + /// resources of the model. @a dst must be released using + /// mv_face_tracking_model_destroy(). + /// @param [in] src The handle to the tracking model to be copied + /// @param [out] dst The handle to the copy of existed tracking model + /// specified as @a src + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create face tracking @a src handle by calling + /// @ref mv_face_tracking_model_create() + /// + /// @see mv_face_tracking_model_create() + int mv_face_tracking_model_clone( + ffi.Pointer src, + ffi.Pointer> dst, + ) { + return _mv_face_tracking_model_clone( + src, + dst, + ); + } + + late final _mv_face_tracking_model_clone_ptr = + _lookup>( + 'mv_face_tracking_model_clone'); + late final _dart_mv_face_tracking_model_clone _mv_face_tracking_model_clone = + _mv_face_tracking_model_clone_ptr + .asFunction<_dart_mv_face_tracking_model_clone>(); + + /// @brief Calls this method to save tracking model to the file. + /// + /// @since_tizen 3.0 + /// @remarks @a tracking_model is saved to the absolute path directory. + /// Use @ref app_get_data_path for the private app storage path. + /// After model is saved to the file, it can be loaded from this file + /// with @ref mv_face_tracking_model_load() function. + /// @param [in] file_name Name of the path/file to save the model + /// @param [in] tracking_model The handle to the tracking model to be + /// saved to the file + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_VISION_ERROR_INVALID_PATH Invalid path + /// @retval #MEDIA_VISION_ERROR_PERMISSION_DENIED Not permitted + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Not supported model format + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create a face tracking handle by calling + /// @ref mv_face_tracking_model_create() + /// @post Saved model can be loaded from file using + /// @ref mv_face_tracking_model_load() function + /// + /// @see mv_face_tracking_model_load() + /// @see mv_face_tracking_model_create() + /// @see app_get_data_path() + int mv_face_tracking_model_save( + ffi.Pointer file_name, + ffi.Pointer tracking_model, + ) { + return _mv_face_tracking_model_save( + file_name, + tracking_model, + ); + } + + late final _mv_face_tracking_model_save_ptr = + _lookup>( + 'mv_face_tracking_model_save'); + late final _dart_mv_face_tracking_model_save _mv_face_tracking_model_save = + _mv_face_tracking_model_save_ptr + .asFunction<_dart_mv_face_tracking_model_save>(); + + /// @brief Calls this method to load a tracking model from file. + /// + /// @since_tizen 3.0 + /// @remarks @a tracking_model is loaded from the absolute path directory. + /// Use @ref app_get_data_path for the private app storage path. + /// @a tracking_model must be destroyed using + /// @ref mv_face_tracking_model_destroy. + /// @param [in] file_name Name of path/file to load the model + /// @param [out] tracking_model The handle to the tracking model to be + /// loaded from file + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_INVALID_OPERATION Invalid operation + /// @retval #MEDIA_VISION_ERROR_INVALID_PATH Invalid path + /// @retval #MEDIA_VISION_ERROR_PERMISSION_DENIED Not permitted + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Not supported model format + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Models has been saved by @ref mv_face_tracking_model_save() function + /// can be loaded with this function + /// @post After model has been loaded and if further tracking will be performed + /// on the video which is not continuation of the last tracking performed + /// for the model, it is recommended to call + /// @ref mv_face_tracking_model_prepare() function + /// + /// @see mv_face_tracking_model_save() + /// @see mv_face_tracking_model_destroy() + /// @see app_get_data_path() + int mv_face_tracking_model_load( + ffi.Pointer file_name, + ffi.Pointer> tracking_model, + ) { + return _mv_face_tracking_model_load( + file_name, + tracking_model, + ); + } + + late final _mv_face_tracking_model_load_ptr = + _lookup>( + 'mv_face_tracking_model_load'); + late final _dart_mv_face_tracking_model_load _mv_face_tracking_model_load = + _mv_face_tracking_model_load_ptr + .asFunction<_dart_mv_face_tracking_model_load>(); + + /// @brief Recognizes the given image objects on the source image. + /// @details Use this function to launch image recognition algorithm configured + /// by @a engine_conf configuration. + /// + /// @since_tizen 3.0 + /// @param [in] source The handle to the source image on which image + /// objects will be recognized + /// @param [in] image_objects The set of handles to the image objects which + /// will be processed as targets of recognition + /// @param [in] number_of_objects The number of image objects + /// @param [in] engine_cfg The handle to the configuration of engine + /// which will be used for recognition. If NULL, + /// then default settings will be used. + /// @param [in] recognized_cb The callback which will be called in order to + /// process recognition result + /// @param [in] user_data The user data to be passed to the + /// @a recognized_cb + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Source colorspace + /// isn't supported + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create a set of image objects using @ref mv_image_object_create() for + /// each of them and construct (fill / load / clone) them on images that + /// will be recognized + /// @pre Create a source handle by calling @ref mv_create_source() and fill + /// by the image for which recognition will be performed + /// @post @a mv_image_recognized_cb will be called to process recognition result + /// @post Release source image by using @ref mv_destroy_source() + /// @post Release image objects by using @ref mv_image_object_destroy() for each + /// handle from @a image_objects set + /// + /// @see mv_image_recognized_cb + /// @see mv_source_h + /// @see mv_create_source() + /// @see mv_destroy_source() + /// @see mv_image_object_h + /// @see mv_image_object_create() + /// @see mv_image_object_destroy() + /// @see mv_engine_config_h + int mv_image_recognize( + ffi.Pointer source, + ffi.Pointer> image_objects, + int number_of_objects, + ffi.Pointer engine_cfg, + ffi.Pointer> recognized_cb, + ffi.Pointer user_data, + ) { + return _mv_image_recognize( + source, + image_objects, + number_of_objects, + engine_cfg, + recognized_cb, + user_data, + ); + } + + late final _mv_image_recognize_ptr = + _lookup>('mv_image_recognize'); + late final _dart_mv_image_recognize _mv_image_recognize = + _mv_image_recognize_ptr.asFunction<_dart_mv_image_recognize>(); + + /// @brief Tracks the given image tracking model on the current frame + /// @details Image tracking on a sequence of frames assumes calling this + /// function for each frame in the correct order. + /// @a tracked_cb will be called for result processing. + /// + /// @since_tizen 3.0 + /// @remarks Tracking algorithm is usually using for recognition of image object + /// on the sequence of images that are organized by time. For example, + /// it may be the sequence of frames from a video stream. + /// @remarks If object is lost during the tracking, system tries to find it + /// further for the following frames. Therefore, tracking will be + /// recovered when object appears again. + /// @remarks Previous calls of @ref mv_image_track() for this + /// @a image_tracking_model will affect on current call + /// @param [in] source The handle to the current image of + /// sequence where image tracking model + /// will be tracked + /// @param [in,out] image_tracking_model The handle to the image tracking model + /// which processed as target of tracking + /// @param [in] engine_cfg The handle to the configuration of + /// engine which will be used for tracking. + /// If NULL, then default settings will be + /// used. + /// @param [in] tracked_cb The callback which will receive + /// tracking results + /// @param [in] user_data The user data to be passed to the + /// @a tracked_cb + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Source colorspace + /// isn't supported + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create image tracking model by calling + /// @ref mv_image_tracking_model_create() and set target by calling + /// @ref mv_image_tracking_model_set_target() + /// @pre Create a source images by calling @ref mv_create_source() for each of + /// them and construct them based on sequence of images for which will be + /// held image tracking + /// @post @a tracked_cb will be called to process tracking result + /// @post Release image tracking model by using + /// @ref mv_image_tracking_model_destroy() + /// + /// @see mv_image_tracked_cb + /// @see mv_source_h + /// @see image_tracking_model_h + /// @see mv_image_tracking_model_create() + /// @see mv_image_tracking_model_set_target() + /// @see mv_image_tracking_model_destroy() + int mv_image_track( + ffi.Pointer source, + ffi.Pointer image_tracking_model, + ffi.Pointer engine_cfg, + ffi.Pointer> tracked_cb, + ffi.Pointer user_data, + ) { + return _mv_image_track( + source, + image_tracking_model, + engine_cfg, + tracked_cb, + user_data, + ); + } + + late final _mv_image_track_ptr = + _lookup>('mv_image_track'); + late final _dart_mv_image_track _mv_image_track = + _mv_image_track_ptr.asFunction<_dart_mv_image_track>(); + + /// @brief Creates an image object. + /// + /// @since_tizen 3.0 + /// @param [out] image_object A new handle to the image object + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @post Release image object by using @ref mv_image_object_destroy() + /// + /// @see mv_image_object_destroy() + /// @see mv_image_object_h + int mv_image_object_create( + ffi.Pointer> image_object, + ) { + return _mv_image_object_create( + image_object, + ); + } + + late final _mv_image_object_create_ptr = + _lookup>( + 'mv_image_object_create'); + late final _dart_mv_image_object_create _mv_image_object_create = + _mv_image_object_create_ptr.asFunction<_dart_mv_image_object_create>(); + + /// @brief Destroys the image object. + /// + /// @since_tizen 3.0 + /// @param [in] image_object The handle to the image object to be destroyed + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create image object by using @ref mv_image_object_create() + /// + /// @see mv_image_object_create() + /// @see mv_image_object_h + int mv_image_object_destroy( + ffi.Pointer image_object, + ) { + return _mv_image_object_destroy( + image_object, + ); + } + + late final _mv_image_object_destroy_ptr = + _lookup>( + 'mv_image_object_destroy'); + late final _dart_mv_image_object_destroy _mv_image_object_destroy = + _mv_image_object_destroy_ptr.asFunction<_dart_mv_image_object_destroy>(); + + /// @brief Fills the image object. + /// @details Extracts data from @a source image which will be needed for + /// recognition of depicted object in @a location. + /// + /// @since_tizen 3.0 + /// @remarks After filling the image object it can be evaluated by + /// @ref mv_image_object_get_recognition_rate(). If recognition rate + /// is too low, try to use another image of object or change + /// configuration parameters (see @ref mv_engine_config_h) and construct + /// the image object again. + /// @param [in,out] image_object The handle to the image object which will be + /// filled and can be recognized in future + /// @param [in] engine_cfg The handle to the configuration of engine + /// which will be used for extract recognition + /// data from @a source. If NULL, then default + /// settings will be used. + /// @param [in] source The source image where image object is depicted + /// @param [in] location The pointer to location of the image object + /// on the source image, or NULL if the object is + /// shown in full + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT Source colorspace + /// isn't supported + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create image object by using @ref mv_image_object_create() + /// @post Release image object by using @ref mv_image_object_destroy() + /// + /// @see mv_image_object_h + /// @see mv_image_object_create() + /// @see mv_image_object_get_recognition_rate() + /// @see mv_image_recognize() + /// @see mv_image_object_destroy() + /// @see mv_engine_config_h + int mv_image_object_fill( + ffi.Pointer image_object, + ffi.Pointer engine_cfg, + ffi.Pointer source, + ffi.Pointer location, + ) { + return _mv_image_object_fill( + image_object, + engine_cfg, + source, + location, + ); + } + + late final _mv_image_object_fill_ptr = + _lookup>( + 'mv_image_object_fill'); + late final _dart_mv_image_object_fill _mv_image_object_fill = + _mv_image_object_fill_ptr.asFunction<_dart_mv_image_object_fill>(); + + /// @brief Gets a value that determines how well an image object can be recognized. + /// @details Recognition rate determines how well an image object can be + /// recognized. This value can be from 0 to 1. If the recognition rate + /// is 0 object can not be recognized and the bigger it is the more + /// likely to recognize the object. + /// + /// @since_tizen 3.0 + /// @remarks If recognition rate is too low, try to use another image of object + /// or change some configuration parameters (see @ref mv_engine_config_h) + /// and fill the image object again (see @ref mv_image_object_fill()). + /// @param [in] image_object The handle to the image object which will be + /// evaluated by this function + /// @param [out] recognition_rate A value that determines how well an image + /// object can be recognized, if 0 then object + /// can not be recognized + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create image object by using @ref mv_image_object_create() + /// @post Release image object by using @ref mv_image_object_destroy() + /// + /// @see mv_image_object_h + /// @see mv_image_object_create() + /// @see mv_image_object_fill() + /// @see mv_image_object_destroy() + /// @see mv_engine_config_h + int mv_image_object_get_recognition_rate( + ffi.Pointer image_object, + ffi.Pointer recognition_rate, + ) { + return _mv_image_object_get_recognition_rate( + image_object, + recognition_rate, + ); + } + + late final _mv_image_object_get_recognition_rate_ptr = + _lookup>( + 'mv_image_object_get_recognition_rate'); + late final _dart_mv_image_object_get_recognition_rate + _mv_image_object_get_recognition_rate = + _mv_image_object_get_recognition_rate_ptr + .asFunction<_dart_mv_image_object_get_recognition_rate>(); + + /// @brief Sets a label for the image object. + /// + /// @since_tizen 3.0 + /// @param [in] image_object The handle to the image object for which the label + /// will be assigned + /// @param [in] label The label which will be assigned to the image + /// object + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create image object by using @ref mv_image_object_create() + /// @post Label could be received by using @ref mv_image_object_get_label() + /// @post Release image object by using @ref mv_image_object_destroy() + /// + /// @see mv_image_object_get_label() + /// @see mv_image_object_h + /// @see mv_image_object_create() + /// @see mv_image_object_destroy() + int mv_image_object_set_label( + ffi.Pointer image_object, + int label, + ) { + return _mv_image_object_set_label( + image_object, + label, + ); + } + + late final _mv_image_object_set_label_ptr = + _lookup>( + 'mv_image_object_set_label'); + late final _dart_mv_image_object_set_label _mv_image_object_set_label = + _mv_image_object_set_label_ptr + .asFunction<_dart_mv_image_object_set_label>(); + + /// @brief Gets a label of image object. + /// + /// @since_tizen 3.0 + /// @remarks If @a image_object have not a label, this function return + /// MEDIA_VISION_ERROR_NO_DATA value. + /// @param [in] image_object The handle to the image object from which a + /// label will be received + /// @param [out] label The label of image object + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NO_DATA Image object hasn't label + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create image object by using @ref mv_image_object_create() + /// @pre Set label for the image object by using @ref mv_image_object_set_label() + /// @post Release image object by using @ref mv_image_object_destroy() + /// + /// @see mv_image_object_set_label() + /// @see mv_image_object_h + /// @see mv_image_object_create() + /// @see mv_image_object_destroy() + int mv_image_object_get_label( + ffi.Pointer image_object, + ffi.Pointer label, + ) { + return _mv_image_object_get_label( + image_object, + label, + ); + } + + late final _mv_image_object_get_label_ptr = + _lookup>( + 'mv_image_object_get_label'); + late final _dart_mv_image_object_get_label _mv_image_object_get_label = + _mv_image_object_get_label_ptr + .asFunction<_dart_mv_image_object_get_label>(); + + /// @brief Clones the image object. + /// + /// @since_tizen 3.0 + /// @remarks @a dst must be released using mv_image_object_destroy(). + /// @param [in] src The handle to the source image object + /// @param [out] dst The handle to the destination image object + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @pre Create image object handles by calling mv_image_object_create() + /// + /// @see mv_image_object_create() + /// @see mv_image_object_destroy() + int mv_image_object_clone( + ffi.Pointer src, + ffi.Pointer> dst, + ) { + return _mv_image_object_clone( + src, + dst, + ); + } + + late final _mv_image_object_clone_ptr = + _lookup>( + 'mv_image_object_clone'); + late final _dart_mv_image_object_clone _mv_image_object_clone = + _mv_image_object_clone_ptr.asFunction<_dart_mv_image_object_clone>(); + + /// @brief Saves the image object. + /// + /// @since_tizen 3.0 + /// @remarks @a image_object is saved to the absolute path directory. + /// Use @ref app_get_data_path for the private app storage path. + /// @param [in] file_name Name of the file to path/save the image object + /// @param [in] image_object The handle to the image object which will be saved + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_INVALID_PATH Invalid path + /// @retval #MEDIA_VISION_ERROR_PERMISSION_DENIED Not permitted + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create image object handle by calling mv_image_object_create() + /// @post Saved model can be loaded later by calling + /// mv_image_object_load() function + /// + /// @see mv_image_object_create() + /// @see mv_image_object_load() + /// @see mv_image_object_destroy() + int mv_image_object_save( + ffi.Pointer file_name, + ffi.Pointer image_object, + ) { + return _mv_image_object_save( + file_name, + image_object, + ); + } + + late final _mv_image_object_save_ptr = + _lookup>( + 'mv_image_object_save'); + late final _dart_mv_image_object_save _mv_image_object_save = + _mv_image_object_save_ptr.asFunction<_dart_mv_image_object_save>(); + + /// @brief Loads an image object from the file. + /// + /// @since_tizen 3.0 + /// @remarks @a image_object is loaded from the absolute path directory. + /// Use @ref app_get_data_path for the private app storage path. + /// @a image_object must be destroyed using + /// @ref mv_image_object_destroy(). + /// @param [in] file_name Name of path/file to load the image object + /// @param [out] image_object The handle to the image object which will be + /// filled + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_INVALID_PATH Invalid path + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_VISION_ERROR_PERMISSION_DENIED Not permitted + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Image object can be preliminary saved with mv_image_object_save() + /// function + /// + /// @see mv_image_object_save() + /// @see mv_image_object_destroy() + int mv_image_object_load( + ffi.Pointer file_name, + ffi.Pointer> image_object, + ) { + return _mv_image_object_load( + file_name, + image_object, + ); + } + + late final _mv_image_object_load_ptr = + _lookup>( + 'mv_image_object_load'); + late final _dart_mv_image_object_load _mv_image_object_load = + _mv_image_object_load_ptr.asFunction<_dart_mv_image_object_load>(); + + /// @brief Creates an image tracking model. + /// + /// @since_tizen 3.0 + /// @param [out] image_tracking_model A new handle to the image tracking model + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @post Release image tracking model by using mv_image_tracking_model_destroy() + /// + /// @see mv_image_tracking_model_destroy() + int mv_image_tracking_model_create( + ffi.Pointer> image_tracking_model, + ) { + return _mv_image_tracking_model_create( + image_tracking_model, + ); + } + + late final _mv_image_tracking_model_create_ptr = + _lookup>( + 'mv_image_tracking_model_create'); + late final _dart_mv_image_tracking_model_create + _mv_image_tracking_model_create = _mv_image_tracking_model_create_ptr + .asFunction<_dart_mv_image_tracking_model_create>(); + + /// @brief Sets target of image tracking model. + /// @details Sets image object which will be tracked by using tracking + /// functionality with @a image_tracking_model. + /// + /// @since_tizen 3.0 + /// @param [in] image_object Image object which will be set + /// as target for tracking + /// @param [in] image_tracking_model Handle to the image tracking model + /// for which will be set a new target + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create image tracking model by calling + /// @ref mv_image_tracking_model_create() + /// @pre Create an image object using @ref mv_image_object_create() and construct + /// (fill / load / clone) it on image that will be tracking + /// @post Release image object by using @ref mv_image_object_destroy() + /// @post Release image tracking model by using + /// @ref mv_image_tracking_model_destroy() + /// + /// @see mv_image_object_h + /// @see mv_image_tracking_model_h + /// @see mv_image_object_create() + /// @see mv_image_object_destroy() + /// @see mv_image_tracking_model_create() + /// @see mv_image_track() + /// @see mv_image_tracking_model_destroy() + int mv_image_tracking_model_set_target( + ffi.Pointer image_object, + ffi.Pointer image_tracking_model, + ) { + return _mv_image_tracking_model_set_target( + image_object, + image_tracking_model, + ); + } + + late final _mv_image_tracking_model_set_target_ptr = + _lookup>( + 'mv_image_tracking_model_set_target'); + late final _dart_mv_image_tracking_model_set_target + _mv_image_tracking_model_set_target = + _mv_image_tracking_model_set_target_ptr + .asFunction<_dart_mv_image_tracking_model_set_target>(); + + /// @brief Destroys the image tracking model. + /// + /// @since_tizen 3.0 + /// @param [in] image_tracking_model The handle to the image tracking model + /// to be destroyed + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create image tracking model by using mv_image_tracking_model_create() + /// + /// @see mv_image_tracking_model_create() + int mv_image_tracking_model_destroy( + ffi.Pointer image_tracking_model, + ) { + return _mv_image_tracking_model_destroy( + image_tracking_model, + ); + } + + late final _mv_image_tracking_model_destroy_ptr = + _lookup>( + 'mv_image_tracking_model_destroy'); + late final _dart_mv_image_tracking_model_destroy + _mv_image_tracking_model_destroy = _mv_image_tracking_model_destroy_ptr + .asFunction<_dart_mv_image_tracking_model_destroy>(); + + /// @brief Refreshes the state of image tracking model. + /// @details Clears moving history and change state to undetected. This function + /// is usually called each time before tracking is started for the new + /// sequence of sources which is not the direct continuation of the + /// sequence for which tracking has been performed before. Tracking + /// algorithm will try to find image by itself. + /// + /// @since_tizen 3.0 + /// @param [in] image_tracking_model The handle to the image tracking model + /// which will be refreshed + /// @param [in] engine_cfg The handle to the configuration of + /// engine which will be used. If NULL, + /// then default settings will be used. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create image tracking model by calling + /// @ref mv_image_tracking_model_create() + /// @post Release image tracking model by using + /// @ref mv_image_tracking_model_destroy() + /// + /// @see mv_image_tracking_model_h + /// @see mv_image_tracking_model_create() + /// @see mv_image_track() + /// @see mv_image_tracking_model_destroy() + int mv_image_tracking_model_refresh( + ffi.Pointer image_tracking_model, + ffi.Pointer engine_cfg, + ) { + return _mv_image_tracking_model_refresh( + image_tracking_model, + engine_cfg, + ); + } + + late final _mv_image_tracking_model_refresh_ptr = + _lookup>( + 'mv_image_tracking_model_refresh'); + late final _dart_mv_image_tracking_model_refresh + _mv_image_tracking_model_refresh = _mv_image_tracking_model_refresh_ptr + .asFunction<_dart_mv_image_tracking_model_refresh>(); + + /// @brief Clones the image tracking model. + /// + /// @since_tizen 3.0 + /// @remarks @a dst must be released using mv_image_tracking_model_destroy(). + /// @param [in] src The handle to the source image tracking model + /// @param [out] dst The handle to the destination image tracking model + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @pre Create image tracking model handles by calling + /// mv_image_tracking_model_create() + /// + /// @see mv_image_tracking_model_create() + /// @see mv_image_tracking_model_destroy() + int mv_image_tracking_model_clone( + ffi.Pointer src, + ffi.Pointer> dst, + ) { + return _mv_image_tracking_model_clone( + src, + dst, + ); + } + + late final _mv_image_tracking_model_clone_ptr = + _lookup>( + 'mv_image_tracking_model_clone'); + late final _dart_mv_image_tracking_model_clone + _mv_image_tracking_model_clone = _mv_image_tracking_model_clone_ptr + .asFunction<_dart_mv_image_tracking_model_clone>(); + + /// @brief Saves the image tracking model. + /// + /// @since_tizen 3.0 + /// @remarks @a image_tracking_model is saved to the absolute path directory. + /// Use @ref app_get_data_path for the private app storage path. + /// @param [in] file_name Name of path/file to save the model + /// @param [in] image_tracking_model The handle to the image tracking model + /// to be saved + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_INVALID_PATH Invalid path + /// @retval #MEDIA_VISION_ERROR_PERMISSION_DENIED Not permitted + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Create image tracking model handle by calling + /// mv_image_tracking_model_create() + /// @post Saved model can be loaded later by calling + /// mv_image_tracking_model_load() function + /// + /// @see mv_image_tracking_model_create() + /// @see mv_image_tracking_model_load() + /// @see mv_image_tracking_model_destroy() + int mv_image_tracking_model_save( + ffi.Pointer file_name, + ffi.Pointer image_tracking_model, + ) { + return _mv_image_tracking_model_save( + file_name, + image_tracking_model, + ); + } + + late final _mv_image_tracking_model_save_ptr = + _lookup>( + 'mv_image_tracking_model_save'); + late final _dart_mv_image_tracking_model_save _mv_image_tracking_model_save = + _mv_image_tracking_model_save_ptr + .asFunction<_dart_mv_image_tracking_model_save>(); + + /// @brief Loads an image tracking model from the file. + /// + /// @since_tizen 3.0 + /// @remarks @a image_tracking_model is loaded from the absolute path directory. + /// Use @ref app_get_data_path for the private app storage path. + /// @a image_tracking_model must be destroyed using + /// @ref mv_image_tracking_model_destroy. + /// @param [in] file_name Name of path/file to load model + /// @param [out] image_tracking_model The handle to the image tracking + /// model to be filled + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_INVALID_PATH Invalid path + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_VISION_ERROR_PERMISSION_DENIED Not permitted + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Image tracking model handle can be preliminary saved with + /// mv_image_tracking_model_save() function + /// + /// @see mv_image_tracking_model_save() + /// @see mv_image_tracking_model_destroy() + int mv_image_tracking_model_load( + ffi.Pointer file_name, + ffi.Pointer> image_tracking_model, + ) { + return _mv_image_tracking_model_load( + file_name, + image_tracking_model, + ); + } + + late final _mv_image_tracking_model_load_ptr = + _lookup>( + 'mv_image_tracking_model_load'); + late final _dart_mv_image_tracking_model_load _mv_image_tracking_model_load = + _mv_image_tracking_model_load_ptr + .asFunction<_dart_mv_image_tracking_model_load>(); + + /// @brief Creates surveillance event trigger handle. + /// + /// @since_tizen 3.0 + /// @remarks List of supported event types can be obtained by + /// @ref mv_surveillance_foreach_supported_event_type function + /// @remarks You must release @a trigger by using + /// @ref mv_surveillance_event_trigger_destroy() + /// @param [in] event_type Name of the event type to be supported by the + /// @a trigger + /// @param [out] trigger A new handle to the event trigger + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_surveillance_event_trigger_destroy() + /// @see mv_surveillance_foreach_supported_event_type() + int mv_surveillance_event_trigger_create( + ffi.Pointer event_type, + ffi.Pointer> trigger, + ) { + return _mv_surveillance_event_trigger_create( + event_type, + trigger, + ); + } + + late final _mv_surveillance_event_trigger_create_ptr = + _lookup>( + 'mv_surveillance_event_trigger_create'); + late final _dart_mv_surveillance_event_trigger_create + _mv_surveillance_event_trigger_create = + _mv_surveillance_event_trigger_create_ptr + .asFunction<_dart_mv_surveillance_event_trigger_create>(); + + /// @brief Destroys the surveillance event trigger handle and releases all its + /// resources. + /// + /// @since_tizen 3.0 + /// @param [in] trigger The handle to the event trigger to be destroyed + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_surveillance_event_trigger_create + int mv_surveillance_event_trigger_destroy( + ffi.Pointer trigger, + ) { + return _mv_surveillance_event_trigger_destroy( + trigger, + ); + } + + late final _mv_surveillance_event_trigger_destroy_ptr = + _lookup>( + 'mv_surveillance_event_trigger_destroy'); + late final _dart_mv_surveillance_event_trigger_destroy + _mv_surveillance_event_trigger_destroy = + _mv_surveillance_event_trigger_destroy_ptr + .asFunction<_dart_mv_surveillance_event_trigger_destroy>(); + + /// @brief Gets the surveillance event trigger type as character string. + /// + /// @since_tizen 3.0 + /// @remarks The @a event_type should be freed using free() + /// @param [in] trigger The handle to the event trigger + /// @param [out] event_type The pointer to the character string which will be + /// filled by textual name of the event type + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Event trigger has to be created by + /// @ref mv_surveillance_event_trigger_create() function + int mv_surveillance_get_event_trigger_type( + ffi.Pointer trigger, + ffi.Pointer> event_type, + ) { + return _mv_surveillance_get_event_trigger_type( + trigger, + event_type, + ); + } + + late final _mv_surveillance_get_event_trigger_type_ptr = + _lookup>( + 'mv_surveillance_get_event_trigger_type'); + late final _dart_mv_surveillance_get_event_trigger_type + _mv_surveillance_get_event_trigger_type = + _mv_surveillance_get_event_trigger_type_ptr + .asFunction<_dart_mv_surveillance_get_event_trigger_type>(); + + /// @brief Sets ROI (Region Of Interest) to the event trigger. + /// @details When ROI is set for the event trigger, then event check for this + /// @a triger will be performed only inside the polygonal region + /// determined by @a roi parameter. + /// If this method has been never called for the @a trigger, then event + /// will be checked for the whole input frame (event check is performed + /// for each @ref mv_surveillance_push_source() function call). + /// It is possible to change the ROI between + /// @ref mv_surveillance_push_source() calls. + /// + /// @since_tizen 3.0 + /// @param [in] trigger The handle to the event trigger + /// @param [in] number_of_points The number of ROI points + /// @param [in] roi The input array with ROI points + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Event trigger has to be created by + /// @ref mv_surveillance_event_trigger_create() function + /// + /// @see mv_surveillance_event_trigger_h + /// @see mv_surveillance_get_event_trigger_roi() + int mv_surveillance_set_event_trigger_roi( + ffi.Pointer trigger, + int number_of_points, + ffi.Pointer roi, + ) { + return _mv_surveillance_set_event_trigger_roi( + trigger, + number_of_points, + roi, + ); + } + + late final _mv_surveillance_set_event_trigger_roi_ptr = + _lookup>( + 'mv_surveillance_set_event_trigger_roi'); + late final _dart_mv_surveillance_set_event_trigger_roi + _mv_surveillance_set_event_trigger_roi = + _mv_surveillance_set_event_trigger_roi_ptr + .asFunction<_dart_mv_surveillance_set_event_trigger_roi>(); + + /// @brief Gets ROI (Region Of Interest) from the event trigger. + /// + /// @since_tizen 3.0 + /// @remark If @ref mv_surveillance_set_event_trigger_roi() has been never + /// called for @a trigger, then @a number_of_points output value will be + /// zero and @a roi pointer will be not changed. + /// @param [in] trigger The handle to the event trigger + /// @param [out] number_of_points The number of ROI points + /// @param [out] roi The output array with ROI points + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Event trigger has to be created by + /// @ref mv_surveillance_event_trigger_create() function + /// + /// @post Memory for @a roi array must be released + /// + /// @see mv_surveillance_event_trigger_h + /// @see mv_surveillance_set_event_trigger_roi() + int mv_surveillance_get_event_trigger_roi( + ffi.Pointer trigger, + ffi.Pointer number_of_points, + ffi.Pointer> roi, + ) { + return _mv_surveillance_get_event_trigger_roi( + trigger, + number_of_points, + roi, + ); + } + + late final _mv_surveillance_get_event_trigger_roi_ptr = + _lookup>( + 'mv_surveillance_get_event_trigger_roi'); + late final _dart_mv_surveillance_get_event_trigger_roi + _mv_surveillance_get_event_trigger_roi = + _mv_surveillance_get_event_trigger_roi_ptr + .asFunction<_dart_mv_surveillance_get_event_trigger_roi>(); + + /// @brief Subscribes @a trigger to process sources pushed from video identified + /// by @a video_stream_id. + /// @details When @a trigger is subscribed, then each time when function + /// @ref mv_surveillance_push_source() is called for @a video_stream_id, + /// event occurrence is checked. If this check is successful, + /// @a callback is invoked. Details on occurred event can be obtained + /// using @ref mv_surveillance_result_h handle from @a callback. + /// + /// @since_tizen 3.0 + /// @remarks Use @ref mv_surveillance_unsubscribe_event_trigger() function for + /// the same @a trigger and @a video_stream_id parameters to stop + /// subscription. + /// @param [in] trigger The handle to the event trigger activating + /// calls of the @a callback function + /// @param [in] video_stream_id The identifier of the video stream for which + /// event trigger activation will be checked + /// @param [in] engine_cfg The engine configuration of the event + /// @param [in] callback Callback to be called each time when event + /// occurrence is detected + /// @param [in] user_data The user data to be passed to the @a callback + /// function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @post @ref mv_surveillance_event_occurred_cb will be called each time + /// @a trigger is activated after @ref mv_surveillance_push_source() call + /// + /// @see mv_surveillance_event_trigger_h + /// @see mv_surveillance_unsubscribe_event_trigger() + /// @see mv_surveillance_push_source() + int mv_surveillance_subscribe_event_trigger( + ffi.Pointer trigger, + int video_stream_id, + ffi.Pointer engine_cfg, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mv_surveillance_subscribe_event_trigger( + trigger, + video_stream_id, + engine_cfg, + callback, + user_data, + ); + } + + late final _mv_surveillance_subscribe_event_trigger_ptr = + _lookup>( + 'mv_surveillance_subscribe_event_trigger'); + late final _dart_mv_surveillance_subscribe_event_trigger + _mv_surveillance_subscribe_event_trigger = + _mv_surveillance_subscribe_event_trigger_ptr + .asFunction<_dart_mv_surveillance_subscribe_event_trigger>(); + + /// @brief Unsubscribes @a trigger from the event and stop calling @a callback. + /// + /// @since_tizen 3.0 + /// @remarks To start handling trigger activation use + /// @ref mv_surveillance_subscribe_event_trigger(). + /// @param [in] trigger The handle to the event trigger for which + /// subscription will be stopped + /// @param [in] video_stream_id The identifier of the video source for which + /// subscription will be stopped + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre To stop subscription it has to be created earlier with + /// @ref mv_surveillance_subscribe_event_trigger() function + /// + /// @see mv_surveillance_event_trigger_h + /// @see mv_surveillance_subscribe_event_trigger() + int mv_surveillance_unsubscribe_event_trigger( + ffi.Pointer trigger, + int video_stream_id, + ) { + return _mv_surveillance_unsubscribe_event_trigger( + trigger, + video_stream_id, + ); + } + + late final _mv_surveillance_unsubscribe_event_trigger_ptr = + _lookup>( + 'mv_surveillance_unsubscribe_event_trigger'); + late final _dart_mv_surveillance_unsubscribe_event_trigger + _mv_surveillance_unsubscribe_event_trigger = + _mv_surveillance_unsubscribe_event_trigger_ptr + .asFunction<_dart_mv_surveillance_unsubscribe_event_trigger>(); + + /// @brief Pushes source to the surveillance system to detect events. + /// @details mv_surveillance_event_occurred_cb() will be called when any + /// subscribing event detected. + /// + /// @since_tizen 3.0 + /// @remarks @ref mv_surveillance_set_event_trigger_roi() function can be used + /// to specify the polygon region where event can be detected only + /// @param [in] source The handle to the media source + /// @param [in] video_stream_id The identifier of video stream from which + /// @a source is coming + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre To receive surveillance results, some event triggers has to be + /// subscribed by @ref mv_surveillance_subscribe_event_trigger() function + /// before @ref mv_surveillance_push_source() calls + /// @pre Before calling of this method @a source has to be correctly filled. + /// @ref mv_source_fill_by_media_packet(), @ref mv_source_fill_by_buffer() + /// functions can be used to fill @a source + /// + /// @see mv_surveillance_event_trigger_h + /// @see mv_surveillance_event_occurred_cb + /// @see mv_surveillance_subscribe_event_trigger() + /// @see mv_surveillance_unsubscribe_event_trigger() + int mv_surveillance_push_source( + ffi.Pointer source, + int video_stream_id, + ) { + return _mv_surveillance_push_source( + source, + video_stream_id, + ); + } + + late final _mv_surveillance_push_source_ptr = + _lookup>( + 'mv_surveillance_push_source'); + late final _dart_mv_surveillance_push_source _mv_surveillance_push_source = + _mv_surveillance_push_source_ptr + .asFunction<_dart_mv_surveillance_push_source>(); + + /// @brief Starts traversing through list of supported event types. + /// + /// @since_tizen 3.0 + /// @remarks Supported event types and their descriptions can be found in + /// @ref CAPI_MEDIA_VISION_SURVEILLANCE_EVENT_TYPES documentation + /// section + /// @param [in] callback The callback function to be called for each + /// supported event type + /// @param [in] user_data The user data to be passed to the @a callback + /// function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_surveillance_event_type_cb + /// @see mv_surveillance_foreach_event_result_name() + int mv_surveillance_foreach_supported_event_type( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _mv_surveillance_foreach_supported_event_type( + callback, + user_data, + ); + } + + late final _mv_surveillance_foreach_supported_event_type_ptr = _lookup< + ffi.NativeFunction<_c_mv_surveillance_foreach_supported_event_type>>( + 'mv_surveillance_foreach_supported_event_type'); + late final _dart_mv_surveillance_foreach_supported_event_type + _mv_surveillance_foreach_supported_event_type = + _mv_surveillance_foreach_supported_event_type_ptr + .asFunction<_dart_mv_surveillance_foreach_supported_event_type>(); + + /// @brief Starts traversing through list of supported event result value names. + /// + /// @since_tizen 3.0 + /// @remarks Supported event types, event result value names and their + /// descriptions can be found in + /// @ref CAPI_MEDIA_VISION_SURVEILLANCE_EVENT_TYPES documentation + /// section + /// @param [in] event_type The name of the event type for which result value + /// names will be passed to the @a callback. Can be + /// set @c NULL. If set @c NULL then all supported + /// event result value names will be traversed + /// @param [in] callback The callback function to be called for each + /// supported event result value name + /// @param [in] user_data The user data to be passed to the @a callback + /// function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @see mv_surveillance_event_result_name_cb + /// @see mv_surveillance_foreach_supported_event_type() + /// @see mv_surveillance_get_result_value() + int mv_surveillance_foreach_event_result_name( + ffi.Pointer event_type, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _mv_surveillance_foreach_event_result_name( + event_type, + callback, + user_data, + ); + } + + late final _mv_surveillance_foreach_event_result_name_ptr = + _lookup>( + 'mv_surveillance_foreach_event_result_name'); + late final _dart_mv_surveillance_foreach_event_result_name + _mv_surveillance_foreach_event_result_name = + _mv_surveillance_foreach_event_result_name_ptr + .asFunction<_dart_mv_surveillance_foreach_event_result_name>(); + + /// @brief Gets result value. + /// @details See the output values names in the event types descriptions located + /// in @ref CAPI_MEDIA_VISION_SURVEILLANCE_EVENT_TYPES documentation + /// section. + /// + /// @since_tizen 3.0 + /// @remarks The name can be obtained by + /// @ref mv_surveillance_foreach_event_result_name function + /// @param [in] result The handle to the event result + /// @param [in] name The name of the value to be gotten + /// @param [in, out] value The pointer to variable which will be filled + /// by result value. To find the type of @a value + /// please refer to the + /// @ref CAPI_MEDIA_VISION_SURVEILLANCE_EVENT_TYPES + /// documentation section + /// @return @c 0 on success, otherwise a negative error value + /// @retval #MEDIA_VISION_ERROR_NONE Successful + /// @retval #MEDIA_VISION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_VISION_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Memory for value has to be allocated + /// + /// @see mv_surveillance_event_trigger_h + /// @see mv_surveillance_event_occurred_cb + /// @see mv_surveillance_subscribe_event_trigger() + /// @see mv_surveillance_unsubscribe_event_trigger() + /// @see mv_surveillance_foreach_supported_event_type() + /// @see mv_surveillance_foreach_event_result_name() + int mv_surveillance_get_result_value( + ffi.Pointer result, + ffi.Pointer name, + ffi.Pointer value, + ) { + return _mv_surveillance_get_result_value( + result, + name, + value, + ); + } + + late final _mv_surveillance_get_result_value_ptr = + _lookup>( + 'mv_surveillance_get_result_value'); + late final _dart_mv_surveillance_get_result_value + _mv_surveillance_get_result_value = _mv_surveillance_get_result_value_ptr + .asFunction<_dart_mv_surveillance_get_result_value>(); + + /// @brief Creates metadata. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a metadata should be released using metadata_editor_destroy(). + /// + /// @param[in] metadata The handle to metadata + /// @return 0 on success, otherwise a negative error value + /// @retval #METADATA_EDITOR_ERROR_NONE Successful + /// @retval #METADATA_EDITOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EDITOR_ERROR_OUT_OF_MEMORY Not enough memory is available + /// @see metadata_editor_destroy() + int metadata_editor_create( + ffi.Pointer> metadata, + ) { + return _metadata_editor_create( + metadata, + ); + } + + late final _metadata_editor_create_ptr = + _lookup>( + 'metadata_editor_create'); + late final _dart_metadata_editor_create _metadata_editor_create = + _metadata_editor_create_ptr.asFunction<_dart_metadata_editor_create>(); + + /// @brief Sets file path to read or write metadata. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks In case of accessing specific path in internal storage or external storage, you may add the privilege for accessing the path. \n + /// For example, if you get the specific path by using storage_get_directory(). you should add privilege http://tizen.org/privilege/mediastorage or http://tizen.org/privilege/externalstorage. + /// + /// @param[in] metadata The handle to metadata + /// @param[in] path path to read or write metadata + /// @return 0 on success, otherwise a negative error value + /// @retval #METADATA_EDITOR_ERROR_NONE Successful + /// @retval #METADATA_EDITOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EDITOR_ERROR_FILE_EXISTS File not exist + /// @retval #METADATA_EDITOR_ERROR_NOT_SUPPORTED unsupported file type + /// @retval #METADATA_EDITOR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #METADATA_EDITOR_ERROR_OPERATION_FAILED Internal Operation Fail + /// @pre Create metadata handle by calling metadata_editor_create() + /// @see metadata_editor_create(), metadata_editor_destroy() + int metadata_editor_set_path( + ffi.Pointer metadata, + ffi.Pointer path, + ) { + return _metadata_editor_set_path( + metadata, + path, + ); + } + + late final _metadata_editor_set_path_ptr = + _lookup>( + 'metadata_editor_set_path'); + late final _dart_metadata_editor_set_path _metadata_editor_set_path = + _metadata_editor_set_path_ptr + .asFunction<_dart_metadata_editor_set_path>(); + + /// @brief Gets the metadata corresponding to the attribute. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a value should be released using free(). \n + /// If the attribute value of the metadata is empty, return value is NULL. \n + /// In case of accessing specific path in internal storage or external storage, you may add the privilege for accessing the path. \n + /// For example, if you get the specific path by using storage_get_directory(). you should add privilege http://tizen.org/privilege/mediastorage or http://tizen.org/privilege/externalstorage. + /// + /// @param[in] metadata The handle to metadata + /// @param[in] attribute key attribute name to get + /// @param[out] value The value of the attribute + /// @return 0 on success, otherwise a negative error value + /// @retval #METADATA_EDITOR_ERROR_NONE Successful + /// @retval #METADATA_EDITOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EDITOR_ERROR_OUT_OF_MEMORY Not enough memory is available + /// @retval #METADATA_EDITOR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #METADATA_EDITOR_ERROR_OPERATION_FAILED Internal Operation Fail + /// @pre Set path to read or write metadata by calling metadata_editor_set_path() + /// @see metadata_editor_create(), metadata_editor_destroy() + int metadata_editor_get_metadata( + ffi.Pointer metadata, + int attribute, + ffi.Pointer> value, + ) { + return _metadata_editor_get_metadata( + metadata, + attribute, + value, + ); + } + + late final _metadata_editor_get_metadata_ptr = + _lookup>( + 'metadata_editor_get_metadata'); + late final _dart_metadata_editor_get_metadata _metadata_editor_get_metadata = + _metadata_editor_get_metadata_ptr + .asFunction<_dart_metadata_editor_get_metadata>(); + + /// @brief Sets the attribute of the metadata. + /// @details This function set the attribute of the metadata for updating the metadata. \n + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a value should be released using free(). \n + /// You must call metadata_editor_update_metadata() for applying to the metadata of the media file. if not, you will see the existing metadata when you call metadata_editor_get_metadata(). + /// + /// @param[in] metadata The handle to metadata + /// @param[in] attribute key attribute name to get + /// @param[in] value The value of the attribute + /// @return 0 on success, otherwise a negative error value + /// @retval #METADATA_EDITOR_ERROR_NONE Successful + /// @retval #METADATA_EDITOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EDITOR_ERROR_OUT_OF_MEMORY Not enough memory is available + /// @retval #METADATA_EDITOR_ERROR_OPERATION_FAILED Internal Operation Fail + /// @pre Set path to read or write metadata by calling metadata_editor_set_path() + /// @see metadata_editor_create(), metadata_editor_update_metadata(), metadata_editor_destroy() + int metadata_editor_set_metadata( + ffi.Pointer metadata, + int attribute, + ffi.Pointer value, + ) { + return _metadata_editor_set_metadata( + metadata, + attribute, + value, + ); + } + + late final _metadata_editor_set_metadata_ptr = + _lookup>( + 'metadata_editor_set_metadata'); + late final _dart_metadata_editor_set_metadata _metadata_editor_set_metadata = + _metadata_editor_set_metadata_ptr + .asFunction<_dart_metadata_editor_set_metadata>(); + + /// @brief Updates the modified metadata. + /// @details This function update the metadata in the media file that is modified by metadata_editor_set_metadata(). + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks In case of accessing specific path in internal storage or external storage, you may add the privilege for accessing the path. \n + /// For example, if you get the specific path by using storage_get_directory(). you should add privilege http://tizen.org/privilege/mediastorage or http://tizen.org/privilege/externalstorage. + /// + /// @param[in] metadata The handle to metadata + /// @return 0 on success, otherwise a negative error value + /// @retval #METADATA_EDITOR_ERROR_NONE Successful + /// @retval #METADATA_EDITOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EDITOR_ERROR_OUT_OF_MEMORY Not enough memory is available + /// @retval #METADATA_EDITOR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #METADATA_EDITOR_ERROR_OPERATION_FAILED Internal Operation Fail + /// @pre Set path to read or write metadata by calling metadata_editor_set_path() + /// @see metadata_editor_create(), metadata_editor_destroy() + int metadata_editor_update_metadata( + ffi.Pointer metadata, + ) { + return _metadata_editor_update_metadata( + metadata, + ); + } + + late final _metadata_editor_update_metadata_ptr = + _lookup>( + 'metadata_editor_update_metadata'); + late final _dart_metadata_editor_update_metadata + _metadata_editor_update_metadata = _metadata_editor_update_metadata_ptr + .asFunction<_dart_metadata_editor_update_metadata>(); + + /// @brief Gets the picture in the media file. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a picture and @a mime_type should be released using free(). \n + /// In case of accessing specific path in internal storage or external storage, you may add the privilege for accessing the path. \n + /// For example, if you get the specific path by using storage_get_directory(). you should add privilege http://tizen.org/privilege/mediastorage or http://tizen.org/privilege/externalstorage. + /// + /// @param[in] metadata The handle to metadata + /// @param[in] index picture order + /// @param[out] picture encoded picture + /// @param[out] size encoded picture size + /// @param[out] mime_type the MIME of the picture + /// @return 0 on success, otherwise a negative error value + /// @retval #METADATA_EDITOR_ERROR_NONE Successful + /// @retval #METADATA_EDITOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EDITOR_ERROR_OUT_OF_MEMORY Not enough memory is available + /// @retval #METADATA_EDITOR_ERROR_OPERATION_FAILED Internal Operation Fail + /// @retval #METADATA_EDITOR_ERROR_PERMISSION_DENIED Permission denied + /// @pre Set path to read or write metadata by calling metadata_editor_set_path() + /// @see metadata_editor_create(), metadata_editor_destroy() + int metadata_editor_get_picture( + ffi.Pointer metadata, + int index, + ffi.Pointer> picture, + ffi.Pointer size, + ffi.Pointer> mime_type, + ) { + return _metadata_editor_get_picture( + metadata, + index, + picture, + size, + mime_type, + ); + } + + late final _metadata_editor_get_picture_ptr = + _lookup>( + 'metadata_editor_get_picture'); + late final _dart_metadata_editor_get_picture _metadata_editor_get_picture = + _metadata_editor_get_picture_ptr + .asFunction<_dart_metadata_editor_get_picture>(); + + /// @brief Appends the picture to the media file. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must call metadata_editor_update_metadata() for applying to the metadata of the media file. if not, you will see the existing metadata when you call metadata_editor_get_metadata(). \n + /// Image type of the metadata supports jpeg and png. \n + /// In case of accessing specific path in internal storage or external storage, you may add the privilege for accessing the path. \n + /// For example, if you get the specific path by using storage_get_directory(). you should add privilege http://tizen.org/privilege/mediastorage or http://tizen.org/privilege/externalstorage. + /// + /// @param[in] metadata The handle to metadata + /// @param[in] picture_path The path of picture for adding to the metadata + /// @return 0 on success, otherwise a negative error value + /// @retval #METADATA_EDITOR_ERROR_NONE Successful + /// @retval #METADATA_EDITOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EDITOR_ERROR_OUT_OF_MEMORY Not enough memory is available + /// @retval #METADATA_EDITOR_ERROR_NOT_SUPPORTED unsupported file type + /// @retval #METADATA_EDITOR_ERROR_OPERATION_FAILED Internal Operation Fail + /// @retval #METADATA_EDITOR_ERROR_PERMISSION_DENIED Permission denied + /// @pre Set path to read or write metadata by calling metadata_editor_set_path() + /// @see metadata_editor_create(), metadata_editor_destroy() + int metadata_editor_append_picture( + ffi.Pointer metadata, + ffi.Pointer picture_path, + ) { + return _metadata_editor_append_picture( + metadata, + picture_path, + ); + } + + late final _metadata_editor_append_picture_ptr = + _lookup>( + 'metadata_editor_append_picture'); + late final _dart_metadata_editor_append_picture + _metadata_editor_append_picture = _metadata_editor_append_picture_ptr + .asFunction<_dart_metadata_editor_append_picture>(); + + /// @brief Removes artwork image from media file. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must call metadata_editor_update_metadata() for applying to the metadata of the media file. if not, you will see the existing metadata when you call metadata_editor_get_metadata(). \n + /// In case of accessing specific path in internal storage or external storage, you may add the privilege for accessing the path. \n + /// For example, if you get the specific path by using storage_get_directory(). you should add privilege http://tizen.org/privilege/mediastorage or http://tizen.org/privilege/externalstorage. + /// + /// @param[in] metadata The handle to metadata + /// @param[in] index artwork image order + /// @return 0 on success, otherwise a negative error value + /// @retval #METADATA_EDITOR_ERROR_NONE Successful + /// @retval #METADATA_EDITOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EDITOR_ERROR_OUT_OF_MEMORY Not enough memory is available + /// @retval #METADATA_EDITOR_ERROR_OPERATION_FAILED Internal Operation Fail + /// @retval #METADATA_EDITOR_ERROR_PERMISSION_DENIED Permission denied + /// @pre Set path to read or write metadata by calling metadata_editor_set_path() + /// @see metadata_editor_create(), metadata_editor_destroy() + int metadata_editor_remove_picture( + ffi.Pointer metadata, + int index, + ) { + return _metadata_editor_remove_picture( + metadata, + index, + ); + } + + late final _metadata_editor_remove_picture_ptr = + _lookup>( + 'metadata_editor_remove_picture'); + late final _dart_metadata_editor_remove_picture + _metadata_editor_remove_picture = _metadata_editor_remove_picture_ptr + .asFunction<_dart_metadata_editor_remove_picture>(); + + /// @brief Destroys metadata. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] metadata The handle to metadata + /// @return 0 on success, otherwise a negative error value + /// @retval #METADATA_EDITOR_ERROR_NONE Successful + /// @retval #METADATA_EDITOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EDITOR_ERROR_OPERATION_FAILED Internal Operation Fail + /// @pre Create metadata handle by calling metadata_editor_create() + /// @see metadata_editor_create() + int metadata_editor_destroy( + ffi.Pointer metadata, + ) { + return _metadata_editor_destroy( + metadata, + ); + } + + late final _metadata_editor_destroy_ptr = + _lookup>( + 'metadata_editor_destroy'); + late final _dart_metadata_editor_destroy _metadata_editor_destroy = + _metadata_editor_destroy_ptr.asFunction<_dart_metadata_editor_destroy>(); + + /// @brief Creates metadata. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The @a metadata should be released using metadata_extractor_destroy(). + /// + /// @param[in] metadata The handle to metadata + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #METADATA_EXTRACTOR_ERROR_NONE Successful + /// @retval #METADATA_EXTRACTOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EXTRACTOR_ERROR_OUT_OF_MEMORY Not enough memory is available + /// + /// @see metadata_extractor_destroy() + int metadata_extractor_create( + ffi.Pointer> metadata, + ) { + return _metadata_extractor_create( + metadata, + ); + } + + late final _metadata_extractor_create_ptr = + _lookup>( + 'metadata_extractor_create'); + late final _dart_metadata_extractor_create _metadata_extractor_create = + _metadata_extractor_create_ptr + .asFunction<_dart_metadata_extractor_create>(); + + /// @brief Sets the file path to extract. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] metadata The handle to metadata + /// @param[in] path The path to extract metadata + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #METADATA_EXTRACTOR_ERROR_NONE Successful + /// @retval #METADATA_EXTRACTOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EXTRACTOR_ERROR_FILE_EXISTS File does not exist + /// @retval #METADATA_EXTRACTOR_ERROR_OPERATION_FAILED Internal operation failed + /// + /// @pre Create a metadata handle by calling metadata_extractor_create(). + /// @see metadata_extractor_create() + /// @see metadata_extractor_destroy() + int metadata_extractor_set_path( + ffi.Pointer metadata, + ffi.Pointer path, + ) { + return _metadata_extractor_set_path( + metadata, + path, + ); + } + + late final _metadata_extractor_set_path_ptr = + _lookup>( + 'metadata_extractor_set_path'); + late final _dart_metadata_extractor_set_path _metadata_extractor_set_path = + _metadata_extractor_set_path_ptr + .asFunction<_dart_metadata_extractor_set_path>(); + + /// @brief Sets the buffer to extract. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] metadata The handle to metadata + /// @param[in] buffer The buffer to extract metadata + /// @param[in] size The buffer size + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #METADATA_EXTRACTOR_ERROR_NONE Successful + /// @retval #METADATA_EXTRACTOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EXTRACTOR_ERROR_OPERATION_FAILED Internal operation failed + /// + /// @pre Create a metadata handle by calling metadata_extractor_create(). + /// @see metadata_extractor_create() + /// @see metadata_extractor_destroy() + int metadata_extractor_set_buffer( + ffi.Pointer metadata, + ffi.Pointer buffer, + int size, + ) { + return _metadata_extractor_set_buffer( + metadata, + buffer, + size, + ); + } + + late final _metadata_extractor_set_buffer_ptr = + _lookup>( + 'metadata_extractor_set_buffer'); + late final _dart_metadata_extractor_set_buffer + _metadata_extractor_set_buffer = _metadata_extractor_set_buffer_ptr + .asFunction<_dart_metadata_extractor_set_buffer>(); + + /// @brief Destroys metadata. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] metadata The handle to metadata + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #METADATA_EXTRACTOR_ERROR_NONE Successful + /// @retval #METADATA_EXTRACTOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EXTRACTOR_ERROR_OPERATION_FAILED Internal operation failed + /// + /// @pre Create a metadata handle by calling metadata_extractor_create(). + /// @see metadata_extractor_create() + int metadata_extractor_destroy( + ffi.Pointer metadata, + ) { + return _metadata_extractor_destroy( + metadata, + ); + } + + late final _metadata_extractor_destroy_ptr = + _lookup>( + 'metadata_extractor_destroy'); + late final _dart_metadata_extractor_destroy _metadata_extractor_destroy = + _metadata_extractor_destroy_ptr + .asFunction<_dart_metadata_extractor_destroy>(); + + /// @brief Gets metadata. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a value should be released using free(). \n + /// In case of accessing specific path in internal storage or external storage, you may add the privilege for accessing the path. \n + /// For example, if you get the specific path by using storage_get_directory(). you should add privilege http://tizen.org/privilege/mediastorage or http://tizen.org/privilege/externalstorage. + /// + /// @param[in] metadata The handle to metadata + /// @param[in] attribute The key attribute name to get + /// @param[out] value The value of the attribute + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #METADATA_EXTRACTOR_ERROR_NONE Successful + /// @retval #METADATA_EXTRACTOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EXTRACTOR_ERROR_OUT_OF_MEMORY Not enough memory is available + /// @retval #METADATA_EXTRACTOR_ERROR_OPERATION_FAILED Internal operation failed + /// @retval #METADATA_EXTRACTOR_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Set the path to extract by calling metadata_extractor_set_path(). + /// @see metadata_extractor_create() + /// @see metadata_extractor_destroy() + int metadata_extractor_get_metadata( + ffi.Pointer metadata, + int attribute, + ffi.Pointer> value, + ) { + return _metadata_extractor_get_metadata( + metadata, + attribute, + value, + ); + } + + late final _metadata_extractor_get_metadata_ptr = + _lookup>( + 'metadata_extractor_get_metadata'); + late final _dart_metadata_extractor_get_metadata + _metadata_extractor_get_metadata = _metadata_extractor_get_metadata_ptr + .asFunction<_dart_metadata_extractor_get_metadata>(); + + /// @brief Gets the artwork image in a media file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a artwork and @a mime_type should be released using free(). \n + /// In case of accessing specific path in internal storage or external storage, you may add the privilege for accessing the path. \n + /// For example, if you get the specific path by using storage_get_directory(). you should add privilege http://tizen.org/privilege/mediastorage or http://tizen.org/privilege/externalstorage. + /// + /// @param[in] metadata The handle to metadata + /// @param[out] artwork The encoded artwork image + /// @param[out] size The encoded artwork size + /// @param[out] mime_type The MIME of the artwork + /// @return @c 0 on success, otherwise a negative error value + /// + /// @retval #METADATA_EXTRACTOR_ERROR_NONE Successful + /// @retval #METADATA_EXTRACTOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EXTRACTOR_ERROR_OUT_OF_MEMORY Not enough memory is available + /// @retval #METADATA_EXTRACTOR_ERROR_OPERATION_FAILED Internal operation failed + /// @retval #METADATA_EXTRACTOR_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Set the path to extract by calling metadata_extractor_set_path(). + /// @see metadata_extractor_create() + /// @see metadata_extractor_destroy() + int metadata_extractor_get_artwork( + ffi.Pointer metadata, + ffi.Pointer> artwork, + ffi.Pointer size, + ffi.Pointer> mime_type, + ) { + return _metadata_extractor_get_artwork( + metadata, + artwork, + size, + mime_type, + ); + } + + late final _metadata_extractor_get_artwork_ptr = + _lookup>( + 'metadata_extractor_get_artwork'); + late final _dart_metadata_extractor_get_artwork + _metadata_extractor_get_artwork = _metadata_extractor_get_artwork_ptr + .asFunction<_dart_metadata_extractor_get_artwork>(); + + /// @brief Gets the frame of a video media file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a frame should be released using free(). + /// In case of accessing specific path in internal storage or external storage, you may add the privilege for accessing the path. \n + /// For example, if you get the specific path by using storage_get_directory(). you should add privilege http://tizen.org/privilege/mediastorage or http://tizen.org/privilege/externalstorage. + /// + /// @param[in] metadata The handle to metadata + /// @param[out] frame The raw frame data in RGB888 + /// @param[out] size The frame data size + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #METADATA_EXTRACTOR_ERROR_NONE Successful + /// @retval #METADATA_EXTRACTOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EXTRACTOR_ERROR_OUT_OF_MEMORY Not enough memory is available + /// @retval #METADATA_EXTRACTOR_ERROR_OPERATION_FAILED Internal operation failed + /// @retval #METADATA_EXTRACTOR_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Set the path to extract by calling metadata_extractor_set_path(). + /// @see metadata_extractor_create() + /// @see metadata_extractor_destroy() + int metadata_extractor_get_frame( + ffi.Pointer metadata, + ffi.Pointer> frame, + ffi.Pointer size, + ) { + return _metadata_extractor_get_frame( + metadata, + frame, + size, + ); + } + + late final _metadata_extractor_get_frame_ptr = + _lookup>( + 'metadata_extractor_get_frame'); + late final _dart_metadata_extractor_get_frame _metadata_extractor_get_frame = + _metadata_extractor_get_frame_ptr + .asFunction<_dart_metadata_extractor_get_frame>(); + + /// @brief Gets the synclyrics of a media file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a lyrics should be released using free(). + /// In case of accessing specific path in internal storage or external storage, you may add the privilege for accessing the path. \n + /// For example, if you get the specific path by using storage_get_directory(). you should add privilege http://tizen.org/privilege/mediastorage or http://tizen.org/privilege/externalstorage. + /// + /// @param[in] metadata The handle to metadata + /// @param[in] index The index of time/lyrics to set + /// @param[out] time_stamp The time information of the index + /// @param[out] lyrics The lyrics of the index + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #METADATA_EXTRACTOR_ERROR_NONE Successful + /// @retval #METADATA_EXTRACTOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EXTRACTOR_ERROR_OPERATION_FAILED Internal operation failed + /// @retval #METADATA_EXTRACTOR_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Set the path to extract by calling metadata_extractor_set_path(). + /// @pre Get the time/lyrics set number by calling metadata_extractor_get_metadata(METADATA_SYNCLYRICS_NUM). + /// @see metadata_extractor_create() + /// @see metadata_extractor_destroy() + int metadata_extractor_get_synclyrics( + ffi.Pointer metadata, + int index, + ffi.Pointer time_stamp, + ffi.Pointer> lyrics, + ) { + return _metadata_extractor_get_synclyrics( + metadata, + index, + time_stamp, + lyrics, + ); + } + + late final _metadata_extractor_get_synclyrics_ptr = + _lookup>( + 'metadata_extractor_get_synclyrics'); + late final _dart_metadata_extractor_get_synclyrics + _metadata_extractor_get_synclyrics = + _metadata_extractor_get_synclyrics_ptr + .asFunction<_dart_metadata_extractor_get_synclyrics>(); + + /// @brief Gets the frame of a video media. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a frame should be released using free(). + /// In case of accessing specific path in internal storage or external storage, you may add the privilege for accessing the path. \n + /// For example, if you get the specific path by using storage_get_directory(). you should add privilege http://tizen.org/privilege/mediastorage or http://tizen.org/privilege/externalstorage. + /// + /// @param[in] metadata The handle to metadata + /// @param[in] timestamp The timestamp in milliseconds + /// @param[in] is_accurate If @c true the user can get an accurate frame for the given timestamp,\n + /// otherwise @c false if the user can only get the nearest i-frame of the video rapidly + /// @param[out] frame The raw frame data in RGB888 + /// @param[out] size The frame data size + /// + /// @return @c 0 on success, otherwise a negative error value + /// @retval #METADATA_EXTRACTOR_ERROR_NONE Successful + /// @retval #METADATA_EXTRACTOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #METADATA_EXTRACTOR_ERROR_OUT_OF_MEMORY Not enough memory is available + /// @retval #METADATA_EXTRACTOR_ERROR_OPERATION_FAILED Internal operation failed + /// @retval #METADATA_EXTRACTOR_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Set the path to extract by calling metadata_extractor_set_path(). + /// @see metadata_extractor_create() + /// @see metadata_extractor_destroy() + int metadata_extractor_get_frame_at_time( + ffi.Pointer metadata, + int timestamp, + bool is_accurate, + ffi.Pointer> frame, + ffi.Pointer size, + ) { + return _metadata_extractor_get_frame_at_time( + metadata, + timestamp, + is_accurate ? 1 : 0, + frame, + size, + ); + } + + late final _metadata_extractor_get_frame_at_time_ptr = + _lookup>( + 'metadata_extractor_get_frame_at_time'); + late final _dart_metadata_extractor_get_frame_at_time + _metadata_extractor_get_frame_at_time = + _metadata_extractor_get_frame_at_time_ptr + .asFunction<_dart_metadata_extractor_get_frame_at_time>(); + + /// @brief Creates a player handle for playing multimedia content. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks You must release @a player by using player_destroy().\n + /// Although you can create multiple player handles at the same time, + /// the player cannot guarantee proper operation because of limited resources, such as + /// audio or display device. + /// + /// @param[out] player A new handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_RESOURCE_LIMIT Cannot create more instance due to resource(socket, thread, etc) limitation on system. + /// @post The player state will be #PLAYER_STATE_IDLE. + /// @see player_destroy() + int player_create( + ffi.Pointer> player, + ) { + return _player_create( + player, + ); + } + + late final _player_create_ptr = + _lookup>('player_create'); + late final _dart_player_create _player_create = + _player_create_ptr.asFunction<_dart_player_create>(); + + /// @brief Destroys the media player handle and releases all its resources. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks To completely shutdown player operation, call this function with a valid player handle from any player state. + /// @param[in] player The handle to the media player to be destroyed + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @post The player state will be #PLAYER_STATE_NONE. + /// @see player_create() + int player_destroy( + ffi.Pointer player, + ) { + return _player_destroy( + player, + ); + } + + late final _player_destroy_ptr = + _lookup>('player_destroy'); + late final _dart_player_destroy _player_destroy = + _player_destroy_ptr.asFunction<_dart_player_destroy>(); + + /// @brief Prepares the media player for playback. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks The mediastorage privilege(http://tizen.org/privilege/mediastorage) must be added if any video/audio files are used to play located in the internal storage. + /// @remarks The externalstorage privilege(http://tizen.org/privilege/externalstorage) must be added if any video/audio files are used to play located in the external storage. + /// @remarks The internet privilege(http://tizen.org/privilege/internet) must be added if any URLs are used to play from network. + /// @param[in] player The handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_URI Invalid URI + /// @retval #PLAYER_ERROR_NO_SUCH_FILE File not found + /// @retval #PLAYER_ERROR_NOT_SUPPORTED_FILE File not supported + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #PLAYER_ERROR_NOT_SUPPORTED_AUDIO_CODEC Not support audio codec format (Since 4.0) + /// @retval #PLAYER_ERROR_NOT_SUPPORTED_VIDEO_CODEC Not support video codec format (Since 4.0) + /// @pre The player state must be set to #PLAYER_STATE_IDLE by calling player_create() or player_unprepare(). After that, call player_set_uri() to load the media content you want to play. + /// @post The player state will be #PLAYER_STATE_READY. + /// @see player_prepare_async() + /// @see player_unprepare() + /// @see player_set_uri() + int player_prepare( + ffi.Pointer player, + ) { + return _player_prepare( + player, + ); + } + + late final _player_prepare_ptr = + _lookup>('player_prepare'); + late final _dart_player_prepare _player_prepare = + _player_prepare_ptr.asFunction<_dart_player_prepare>(); + + /// @brief Prepares the media player for playback, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks The mediastorage privilege(http://tizen.org/privilege/mediastorage) must be added if any video/audio files are used to play located in the internal storage. + /// @remarks The externalstorage privilege(http://tizen.org/privilege/externalstorage) must be added if any video/audio files are used to play located in the external storage. + /// @remarks The internet privilege(http://tizen.org/privilege/internet) must be added if any URLs are used to play from network. + /// @param[in] player The handle to the media player + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_URI Invalid URI + /// @retval #PLAYER_ERROR_NO_SUCH_FILE File not found + /// @retval #PLAYER_ERROR_NOT_SUPPORTED_FILE File not supported + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_PERMISSION_DENIED Permission denied + /// @pre The player state must be set to #PLAYER_STATE_IDLE by calling player_create() or player_unprepare(). After that, call player_set_uri() to load the media content you want to play. + /// @post It invokes player_prepared_cb() when playback is prepared. + /// @see player_prepare() + /// @see player_prepared_cb() + /// @see player_unprepare() + /// @see player_set_uri() + int player_prepare_async( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _player_prepare_async( + player, + callback, + user_data, + ); + } + + late final _player_prepare_async_ptr = + _lookup>( + 'player_prepare_async'); + late final _dart_player_prepare_async _player_prepare_async = + _player_prepare_async_ptr.asFunction<_dart_player_prepare_async>(); + + /// @brief Resets the media player. + /// @details The most recently used media is reset and no longer associated with the player. + /// Playback is no longer possible. If you want to use the player again, you must set the data URI and call + /// player_prepare() again. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be higher than #PLAYER_STATE_IDLE. + /// @post The player state will be #PLAYER_STATE_IDLE. + /// @see player_prepare() + int player_unprepare( + ffi.Pointer player, + ) { + return _player_unprepare( + player, + ); + } + + late final _player_unprepare_ptr = + _lookup>('player_unprepare'); + late final _dart_player_unprepare _player_unprepare = + _player_unprepare_ptr.asFunction<_dart_player_unprepare>(); + + /// @brief Sets the data source (file-path, HTTP or RTSP URI) to use. + /// + /// @details Associates media contents, referred to by the URI, with the player. + /// If the function call is successful, subsequent calls to player_prepare() and player_start() will start playing the media. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks If you use HTTP or RTSP, URI must start with "http://" or "rtsp://". The default protocol is "file://". + /// If you provide an invalid URI, you won't receive an error message until you call player_start(). + /// @remarks This function must be called before calling the player_prepare() or player_prepare_async() to build the player based on the URI information. + /// @remarks The mediastorage privilege(http://tizen.org/privilege/mediastorage) must be added if any video/audio files are used to play located in the internal storage. + /// @remarks The externalstorage privilege(http://tizen.org/privilege/externalstorage) must be added if any video/audio files are used to play located in the external storage. + /// @remarks The internet privilege(http://tizen.org/privilege/internet) must be added if any URLs are used to play from network. + /// + /// @param[in] player The handle to the media player + /// @param[in] uri The content location, such as the file path, the URI of the HTTP or RTSP stream you want to play + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_PERMISSION_DENIED Permission denied + /// @if WEARABLE @retval #PLAYER_ERROR_FEATURE_NOT_SUPPORTED_ON_DEVICE Unsupported feature @endif + /// @pre The player state must be set to #PLAYER_STATE_IDLE by calling player_create() or player_unprepare(). + /// @see player_set_memory_buffer() + int player_set_uri( + ffi.Pointer player, + ffi.Pointer uri, + ) { + return _player_set_uri( + player, + uri, + ); + } + + late final _player_set_uri_ptr = + _lookup>('player_set_uri'); + late final _dart_player_set_uri _player_set_uri = + _player_set_uri_ptr.asFunction<_dart_player_set_uri>(); + + /// @brief Sets memory as the data source. + /// + /// @details Associates media content, cached in memory, with the player. Unlike the case of player_set_uri(), the media resides in memory. + /// If the function call is successful, subsequent calls to player_prepare() and player_start() will start playing the media. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks If you provide an invalid data, you won't receive an error message until you call player_start(). + /// @remarks This function must be called before calling the player_prepare() or player_prepare_async() + /// to build the player based on the data. + /// + /// @param[in] player The handle to the media player + /// @param[in] data The memory pointer of media data + /// @param[in] size The size of media data + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be set to #PLAYER_STATE_IDLE by calling player_create() or player_unprepare(). + /// @see player_set_uri() + int player_set_memory_buffer( + ffi.Pointer player, + ffi.Pointer data, + int size, + ) { + return _player_set_memory_buffer( + player, + data, + size, + ); + } + + late final _player_set_memory_buffer_ptr = + _lookup>( + 'player_set_memory_buffer'); + late final _dart_player_set_memory_buffer _player_set_memory_buffer = + _player_set_memory_buffer_ptr + .asFunction<_dart_player_set_memory_buffer>(); + + /// @brief Gets the player's current state. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[out] state The current state of the player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see #player_state_e + int player_get_state( + ffi.Pointer player, + ffi.Pointer state, + ) { + return _player_get_state( + player, + state, + ); + } + + late final _player_get_state_ptr = + _lookup>('player_get_state'); + late final _dart_player_get_state _player_get_state = + _player_get_state_ptr.asFunction<_dart_player_get_state>(); + + /// @brief Sets the player's volume. + /// @details Setting this volume adjusts the player's instance volume, not the system volume. + /// The valid range is from 0 to 1.0, inclusive (1.0 = 100%). Default value is 1.0. + /// To change system volume, use the @ref CAPI_MEDIA_SOUND_MANAGER_MODULE API. + /// Finally, it does not support to set other value into each channel currently. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[in] left The left volume scalar + /// @param[in] right The right volume scalar + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @see player_get_volume() + int player_set_volume( + ffi.Pointer player, + double left, + double right, + ) { + return _player_set_volume( + player, + left, + right, + ); + } + + late final _player_set_volume_ptr = + _lookup>('player_set_volume'); + late final _dart_player_set_volume _player_set_volume = + _player_set_volume_ptr.asFunction<_dart_player_set_volume>(); + + /// @brief Gets the player's current volume factor. + /// @details The range of @a left and @a right is from @c 0 to @c 1.0, inclusive (1.0 = 100%). + /// This function gets the player volume, not the system volume. + /// To get the system volume, use the @ref CAPI_MEDIA_SOUND_MANAGER_MODULE API. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[out] left The current left volume scalar + /// @param[out] right The current right volume scalar + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @see player_set_volume() + int player_get_volume( + ffi.Pointer player, + ffi.Pointer left, + ffi.Pointer right, + ) { + return _player_get_volume( + player, + left, + right, + ); + } + + late final _player_get_volume_ptr = + _lookup>('player_get_volume'); + late final _dart_player_get_volume _player_get_volume = + _player_get_volume_ptr.asFunction<_dart_player_get_volume>(); + + /// @deprecated Deprecated since 3.0. Use player_set_sound_stream_info() instead. + /// @brief Sets the player's volume type. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks The default sound type of the player is #SOUND_TYPE_MEDIA. + /// To get the current sound type, use sound_manager_get_current_sound_type(). + /// @remarks If stream_info already exists by calling sound_manager_create_stream_info(), + /// It will return error since 3.0. + /// + /// @param[in] player The handle to the media player + /// @param[in] type The sound type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_SOUND_POLICY Sound policy error + /// @pre The player state must be set to #PLAYER_STATE_IDLE by calling player_create(). + /// @see sound_manager_get_current_sound_type() + int player_set_sound_type( + ffi.Pointer player, + int type, + ) { + return _player_set_sound_type( + player, + type, + ); + } + + late final _player_set_sound_type_ptr = + _lookup>( + 'player_set_sound_type'); + late final _dart_player_set_sound_type _player_set_sound_type = + _player_set_sound_type_ptr.asFunction<_dart_player_set_sound_type>(); + + /// @brief Sets the player's sound manager stream information. + /// @since_tizen 3.0 + /// @remarks You can set sound stream information including audio routing and volume type. + /// For more details, please refer to sound_manager.h + /// @remarks This function must be called before calling the player_prepare() or player_prepare_async() + /// to reflect the sound stream information when the player is building. + /// @remarks This function is related to the following feature:\n + /// %http://tizen.org/feature/multimedia.player.stream_info\n + /// If this feature is not supported, the stream_type of the player is fixed to the #SOUND_STREAM_TYPE_MEDIA. + /// @param[in] player The handle to the media player + /// @param[in] stream_info The sound manager info type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_FEATURE_NOT_SUPPORTED_ON_DEVICE Unsupported feature + /// @pre The player state must be set to #PLAYER_STATE_IDLE by calling player_create(). + /// @see #sound_stream_info_h + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + /// @par Example + /// @code + /// #include + /// #include + /// ... + /// player_h player = NULL; + /// sound_stream_info_h stream_info = NULL; + /// sound_stream_type_e stream_type = SOUND_STREAM_TYPE_MEDIA; + /// ... + /// sound_manager_create_stream_information (stream_type, _focus_callback, use_data, &stream_info); + /// player_create (&player); + /// player_set_sound_stream_info (player, stream_info); + /// ... + /// player_prepare_async (player, _prepared_cb, udata); + /// ... + /// @endcode + int player_set_sound_stream_info( + ffi.Pointer player, + ffi.Pointer stream_info, + ) { + return _player_set_sound_stream_info( + player, + stream_info, + ); + } + + late final _player_set_sound_stream_info_ptr = + _lookup>( + 'player_set_sound_stream_info'); + late final _dart_player_set_sound_stream_info _player_set_sound_stream_info = + _player_set_sound_stream_info_ptr + .asFunction<_dart_player_set_sound_stream_info>(); + + /// @brief Sets the audio latency mode. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks The default audio latency mode of the player is #AUDIO_LATENCY_MODE_MID. + /// To get the current audio latency mode, use player_get_audio_latency_mode(). + /// If it's high mode, audio output interval can be increased so, it can keep more audio data to play. + /// But, state transition like pause or resume can be more slower than default(mid) mode. + /// + /// @param[in] player The handle to the media player + /// @param[in] latency_mode The latency mode to be applied to the audio + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @see #audio_latency_mode_e + /// @see player_get_audio_latency_mode() + int player_set_audio_latency_mode( + ffi.Pointer player, + int latency_mode, + ) { + return _player_set_audio_latency_mode( + player, + latency_mode, + ); + } + + late final _player_set_audio_latency_mode_ptr = + _lookup>( + 'player_set_audio_latency_mode'); + late final _dart_player_set_audio_latency_mode + _player_set_audio_latency_mode = _player_set_audio_latency_mode_ptr + .asFunction<_dart_player_set_audio_latency_mode>(); + + /// @brief Gets the current audio latency mode. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[out] latency_mode The latency mode to get from the audio + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @see #audio_latency_mode_e + /// @see player_set_audio_latency_mode() + int player_get_audio_latency_mode( + ffi.Pointer player, + ffi.Pointer latency_mode, + ) { + return _player_get_audio_latency_mode( + player, + latency_mode, + ); + } + + late final _player_get_audio_latency_mode_ptr = + _lookup>( + 'player_get_audio_latency_mode'); + late final _dart_player_get_audio_latency_mode + _player_get_audio_latency_mode = _player_get_audio_latency_mode_ptr + .asFunction<_dart_player_get_audio_latency_mode>(); + + /// @brief Starts or resumes playback. + /// @details Plays current media content, or resumes play if paused. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks Sound can be mixed with other sounds if you don't control the stream focus in sound-manager module since 3.0.\n + /// You can refer to @ref CAPI_MEDIA_SOUND_MANAGER_MODULE. + /// @remarks Even if you don't set visible to true by calling player_set_display_visible, the video will be shown on #PLAYER_STATE_PLAYING state. + /// + /// @param[in] player The handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_CONNECTION_FAILED Network connection failed + /// @retval #PLAYER_ERROR_SOUND_POLICY Sound policy error + /// @pre player_prepare() must be called before calling this function. + /// @pre The player state must be set to #PLAYER_STATE_READY by calling player_prepare() or set to #PLAYER_STATE_PAUSED by calling player_pause(). + /// @post The player state will be #PLAYER_STATE_PLAYING. + /// @post It invokes player_completed_cb() when playback completes, if you set a callback with player_set_completed_cb(). + /// @post It invokes player_pd_message_cb() when progressive download starts or completes, if you set a download path with player_set_progressive_download_path() and a callback with player_set_progressive_download_message_cb(). + /// @see player_prepare() + /// @see player_prepare_async() + /// @see player_stop() + /// @see player_pause() + /// @see player_set_completed_cb() + /// @see player_completed_cb() + /// @see player_set_progressive_download_path() + /// @see player_set_progressive_download_message_cb() + /// @see player_pd_message_cb() + /// @see player_set_display_visible() + int player_start( + ffi.Pointer player, + ) { + return _player_start( + player, + ); + } + + late final _player_start_ptr = + _lookup>('player_start'); + late final _dart_player_start _player_start = + _player_start_ptr.asFunction<_dart_player_start>(); + + /// @brief Stops playing media content. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid state + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_SOUND_POLICY Sound policy error + /// @pre The player state must be set to #PLAYER_STATE_PLAYING by calling player_start() or set to #PLAYER_STATE_PAUSED by calling player_pause(). + /// @post The player state will be #PLAYER_STATE_READY. + /// @post The downloading will be aborted if you use progressive download. + /// @see player_start() + /// @see player_pause() + int player_stop( + ffi.Pointer player, + ) { + return _player_stop( + player, + ); + } + + late final _player_stop_ptr = + _lookup>('player_stop'); + late final _dart_player_stop _player_stop = + _player_stop_ptr.asFunction<_dart_player_stop>(); + + /// @brief Pauses the player. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks You can resume playback using player_start(). + /// + /// @param[in] player The handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid state + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_SOUND_POLICY Sound policy error + /// @pre The player state must be set to #PLAYER_STATE_PLAYING. + /// @post The player state will be #PLAYER_STATE_PAUSED. + /// @see player_start() + int player_pause( + ffi.Pointer player, + ) { + return _player_pause( + player, + ); + } + + late final _player_pause_ptr = + _lookup>('player_pause'); + late final _dart_player_pause _player_pause = + _player_pause_ptr.asFunction<_dart_player_pause>(); + + /// @brief Sets the seek position for playback, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks This function will trigger the seeking operation on player instance. + /// Normally application need to wait for player_seek_completed_cb() before calling it again. + /// Otherwise it will return PLAYER_ERROR_SEEK_FAILED. + /// Please note that if application is playing external media data via player_set_media_stream_info(), + /// then consecutive calling of this function will always success and no need to wait for player_seek_completed_cb() + /// before next calling of this function.(Since 3.0) + /// @remarks Even if you don't set visible to true by calling player_set_display_visible, + /// the video will be shown when the _seek_completed cb is invoked. + /// @remarks In case of non-seekable content, it will return PLAYER_ERROR_INVALID_OPERATION. + /// If application ignore this error, player will keep playing without changing play position. + /// @param[in] player The handle to the media player + /// @param[in] millisecond The position in milliseconds from the start to the seek point + /// @param[in] accurate If @c true the selected position is returned, but this might be considerably slow, + /// if @c false the nearest key frame position is returned, but this might be faster but less accurate. + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_SEEK_FAILED Seek operation failure + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @post It invokes player_seek_completed_cb() when seek operation completes, if you set a callback. + /// @see player_get_play_position() + int player_set_play_position( + ffi.Pointer player, + int millisecond, + bool accurate, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _player_set_play_position( + player, + millisecond, + accurate ? 1 : 0, + callback, + user_data, + ); + } + + late final _player_set_play_position_ptr = + _lookup>( + 'player_set_play_position'); + late final _dart_player_set_play_position _player_set_play_position = + _player_set_play_position_ptr + .asFunction<_dart_player_set_play_position>(); + + /// @brief Gets the current position in milliseconds. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[out] millisecond The current position in milliseconds + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_SEEK_FAILED Seek operation failure + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_set_play_position() + int player_get_play_position( + ffi.Pointer player, + ffi.Pointer millisecond, + ) { + return _player_get_play_position( + player, + millisecond, + ); + } + + late final _player_get_play_position_ptr = + _lookup>( + 'player_get_play_position'); + late final _dart_player_get_play_position _player_get_play_position = + _player_get_play_position_ptr + .asFunction<_dart_player_get_play_position>(); + + /// @brief Sets the player's mute status. + /// @details If the mute status is @c true, no sounds are played. + /// If it is @c false, sounds are played at the previously set volume level. + /// Until this function is called, by default the player is not muted. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[in] muted The new mute status: (@c true = mute, @c false = not muted) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_is_muted() + int player_set_mute( + ffi.Pointer player, + bool muted, + ) { + return _player_set_mute( + player, + muted ? 1 : 0, + ); + } + + late final _player_set_mute_ptr = + _lookup>('player_set_mute'); + late final _dart_player_set_mute _player_set_mute = + _player_set_mute_ptr.asFunction<_dart_player_set_mute>(); + + /// @brief Gets the player's mute status. + /// @details If the mute status is @c true, no sounds are played. + /// If it is @c false, sounds are played at the previously set volume level. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[out] muted The current mute status: (@c true = mute, @c false = not muted) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_set_mute() + int player_is_muted( + ffi.Pointer player, + ffi.Pointer muted, + ) { + return _player_is_muted( + player, + muted, + ); + } + + late final _player_is_muted_ptr = + _lookup>('player_is_muted'); + late final _dart_player_is_muted _player_is_muted = + _player_is_muted_ptr.asFunction<_dart_player_is_muted>(); + + /// @brief Sets the player's looping status. + /// @details If the looping status is @c true, playback automatically restarts upon finishing. + /// If it is @c false, it won't. The default value is @c false. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[in] looping The new looping status: (@c true = looping, @c false = non-looping ) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_is_looping() + int player_set_looping( + ffi.Pointer player, + bool looping, + ) { + return _player_set_looping( + player, + looping ? 1 : 0, + ); + } + + late final _player_set_looping_ptr = + _lookup>('player_set_looping'); + late final _dart_player_set_looping _player_set_looping = + _player_set_looping_ptr.asFunction<_dart_player_set_looping>(); + + /// @brief Gets the player's looping status. + /// @details If the looping status is @c true, playback automatically restarts upon finishing. + /// If it is @c false, it won't. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[out] looping The looping status: (@c true = looping, @c false = non-looping ) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_set_looping() + int player_is_looping( + ffi.Pointer player, + ffi.Pointer looping, + ) { + return _player_is_looping( + player, + looping, + ); + } + + late final _player_is_looping_ptr = + _lookup>('player_is_looping'); + late final _dart_player_is_looping _player_is_looping = + _player_is_looping_ptr.asFunction<_dart_player_is_looping>(); + + /// @brief Sets the video display. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks To get @a display to set, use #GET_DISPLAY(). + /// @remarks We are not supporting changing display. + /// @remarks This function have be called before calling the player_prepare() or player_prepare_async() \n + /// to reflect the display type. + /// @param[in] player The handle to the media player + /// @param[in] type The display type + /// @param[in] display The handle to display + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be set to #PLAYER_STATE_IDLE by calling player_create() or player_unprepare(). + /// @see #player_display_type_e + /// @see player_set_display_mode + /// @see player_set_display_roi_area + /// @see player_set_display_visible + /// @see player_set_display_rotation + int player_set_display( + ffi.Pointer player, + int type, + ffi.Pointer display, + ) { + return _player_set_display( + player, + type, + display, + ); + } + + late final _player_set_display_ptr = + _lookup>('player_set_display'); + late final _dart_player_set_display _player_set_display = + _player_set_display_ptr.asFunction<_dart_player_set_display>(); + + /// @brief Sets a media packet video callback function to be called once per frame. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks This function must be called before calling player_prepare() or player_prepare_async().\n + /// A registered callback is called in a separate thread (not in the main loop).\n + /// A video frame can be retrieved using a registered callback as a media packet.\n + /// The callback function holds the same buffer that will be drawn on the display device.\n + /// So if you change the media packet in a registered callback, it will be displayed on the device\n + /// and the media packet is available until it's destroyed by media_packet_destroy().\n + /// The packet have to be destroyed as quickly as possible after rendering the packet\n + /// and all the packets have to be destroyed before player_unprepare() is called.\n + /// @param[in] player The handle to the media player + /// @param[in] callback The callback function to be registered + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid state + /// @pre The player's state must be #PLAYER_STATE_IDLE. And, #PLAYER_DISPLAY_TYPE_NONE must be set by calling player_set_display(). + /// @see player_unset_media_packet_video_frame_decoded_cb + int player_set_media_packet_video_frame_decoded_cb( + ffi.Pointer player, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _player_set_media_packet_video_frame_decoded_cb( + player, + callback, + user_data, + ); + } + + late final _player_set_media_packet_video_frame_decoded_cb_ptr = _lookup< + ffi.NativeFunction< + _c_player_set_media_packet_video_frame_decoded_cb>>( + 'player_set_media_packet_video_frame_decoded_cb'); + late final _dart_player_set_media_packet_video_frame_decoded_cb + _player_set_media_packet_video_frame_decoded_cb = + _player_set_media_packet_video_frame_decoded_cb_ptr + .asFunction<_dart_player_set_media_packet_video_frame_decoded_cb>(); + + /// @brief Unsets the media packet video frame callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The player's state must be #PLAYER_STATE_READY or #PLAYER_STATE_IDLE + /// @see player_set_media_packet_video_frame_decoded_cb() + int player_unset_media_packet_video_frame_decoded_cb( + ffi.Pointer player, + ) { + return _player_unset_media_packet_video_frame_decoded_cb( + player, + ); + } + + late final _player_unset_media_packet_video_frame_decoded_cb_ptr = _lookup< + ffi.NativeFunction< + _c_player_unset_media_packet_video_frame_decoded_cb>>( + 'player_unset_media_packet_video_frame_decoded_cb'); + late final _dart_player_unset_media_packet_video_frame_decoded_cb + _player_unset_media_packet_video_frame_decoded_cb = + _player_unset_media_packet_video_frame_decoded_cb_ptr + .asFunction<_dart_player_unset_media_packet_video_frame_decoded_cb>(); + + /// @brief Pushes elementary stream to decode audio or video. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @remarks player_set_media_stream_info() must be called before using this function. + /// @remarks The available buffer size can be set by calling player_set_media_stream_buffer_max_size(). + /// If there is no available buffer space, this function will return error since 3.0. + /// @param[in] player The handle to media player + /// @param[in] packet The media packet to decode + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid state + /// @retval #PLAYER_ERROR_NOT_SUPPORTED_FILE File not supported + /// @retval #PLAYER_ERROR_BUFFER_SPACE No buffer space available (since 3.0) + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation (since 3.0) + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING or #PLAYER_STATE_PAUSED. + /// @see player_set_media_stream_info() + /// @see player_set_media_stream_buffer_max_size() + int player_push_media_stream( + ffi.Pointer player, + ffi.Pointer packet, + ) { + return _player_push_media_stream( + player, + packet, + ); + } + + late final _player_push_media_stream_ptr = + _lookup>( + 'player_push_media_stream'); + late final _dart_player_push_media_stream _player_push_media_stream = + _player_push_media_stream_ptr + .asFunction<_dart_player_push_media_stream>(); + + /// @brief Sets contents information for media stream. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @remarks AV format must be set before pushing elementary stream with player_push_media_stream(). + /// @remarks This function must be called before calling the player_prepare() or player_prepare_async() + /// to reflect the media information. + /// @remarks AAC can be supported. + /// @remarks H.264 can be supported. + /// @param[in] player The handle to media player + /// @param[in] type The type of target stream + /// @param[in] format The media format to set audio information + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid state + /// @pre The player state must be set to #PLAYER_STATE_IDLE by calling player_create() or player_unprepare(). + /// @see player_push_media_stream() + int player_set_media_stream_info( + ffi.Pointer player, + int type, + ffi.Pointer format, + ) { + return _player_set_media_stream_info( + player, + type, + format, + ); + } + + late final _player_set_media_stream_info_ptr = + _lookup>( + 'player_set_media_stream_info'); + late final _dart_player_set_media_stream_info _player_set_media_stream_info = + _player_set_media_stream_info_ptr + .asFunction<_dart_player_set_media_stream_info>(); + + /// @brief Sets a callback function to be invoked when buffer underrun or overflow is occurred. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @remarks This function is used for media stream playback only. + /// @remarks The callback is called in a separate thread (not in the main loop). + /// @param[in] player The handle to the media player + /// @param[in] type The type of target stream + /// @param[in] callback The buffer status callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The player state must be set to #PLAYER_STATE_IDLE by calling player_create() or player_unprepare(). + /// @post player_media_stream_buffer_status_cb() will be invoked. + /// @see player_unset_media_stream_buffer_status_cb() + /// @see player_media_stream_buffer_status_cb() + int player_set_media_stream_buffer_status_cb( + ffi.Pointer player, + int type, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _player_set_media_stream_buffer_status_cb( + player, + type, + callback, + user_data, + ); + } + + late final _player_set_media_stream_buffer_status_cb_ptr = + _lookup>( + 'player_set_media_stream_buffer_status_cb'); + late final _dart_player_set_media_stream_buffer_status_cb + _player_set_media_stream_buffer_status_cb = + _player_set_media_stream_buffer_status_cb_ptr + .asFunction<_dart_player_set_media_stream_buffer_status_cb>(); + + /// @brief Unsets the buffer status callback function. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @remarks This function is used for media stream playback only. + /// @param[in] player The handle to the media player + /// @param[in] type The type of target stream + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see player_set_media_stream_buffer_status_cb() + int player_unset_media_stream_buffer_status_cb( + ffi.Pointer player, + int type, + ) { + return _player_unset_media_stream_buffer_status_cb( + player, + type, + ); + } + + late final _player_unset_media_stream_buffer_status_cb_ptr = _lookup< + ffi.NativeFunction<_c_player_unset_media_stream_buffer_status_cb>>( + 'player_unset_media_stream_buffer_status_cb'); + late final _dart_player_unset_media_stream_buffer_status_cb + _player_unset_media_stream_buffer_status_cb = + _player_unset_media_stream_buffer_status_cb_ptr + .asFunction<_dart_player_unset_media_stream_buffer_status_cb>(); + + /// @brief Sets a callback function to be invoked when seeking is occurred. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @remarks This function is used for media stream playback only. + /// @remarks The callback is called in a separate thread (not in the main loop). + /// @param[in] player The handle to the media player + /// @param[in] type The type of target stream + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The player state must be set to #PLAYER_STATE_IDLE by calling player_create() or player_unprepare(). + /// @post player_media_stream_seek_cb() will be invoked. + /// @see player_unset_media_stream_seek_cb() + /// @see player_media_stream_seek_cb() + int player_set_media_stream_seek_cb( + ffi.Pointer player, + int type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _player_set_media_stream_seek_cb( + player, + type, + callback, + user_data, + ); + } + + late final _player_set_media_stream_seek_cb_ptr = + _lookup>( + 'player_set_media_stream_seek_cb'); + late final _dart_player_set_media_stream_seek_cb + _player_set_media_stream_seek_cb = _player_set_media_stream_seek_cb_ptr + .asFunction<_dart_player_set_media_stream_seek_cb>(); + + /// @brief Unsets the seek callback function. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @param[in] player The handle to the media player + /// @param[in] type The type of target stream + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see player_set_media_stream_seek_cb() + int player_unset_media_stream_seek_cb( + ffi.Pointer player, + int type, + ) { + return _player_unset_media_stream_seek_cb( + player, + type, + ); + } + + late final _player_unset_media_stream_seek_cb_ptr = + _lookup>( + 'player_unset_media_stream_seek_cb'); + late final _dart_player_unset_media_stream_seek_cb + _player_unset_media_stream_seek_cb = + _player_unset_media_stream_seek_cb_ptr + .asFunction<_dart_player_unset_media_stream_seek_cb>(); + + /// @brief Sets the max size bytes of buffer. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @remarks This function is used for media stream playback only. + /// @remarks If the buffer level over the max size, player_media_stream_buffer_status_cb() will be invoked with overflow status. + /// @param[in] player The handle to the media player + /// @param[in] type The type of target stream + /// @param[in] max_size The max bytes of buffer, it has to be bigger than zero. (default: 200000) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. (since 3.0) + /// @see player_get_media_stream_buffer_max_size() + /// @see player_media_stream_buffer_status_cb() + int player_set_media_stream_buffer_max_size( + ffi.Pointer player, + int type, + int max_size, + ) { + return _player_set_media_stream_buffer_max_size( + player, + type, + max_size, + ); + } + + late final _player_set_media_stream_buffer_max_size_ptr = + _lookup>( + 'player_set_media_stream_buffer_max_size'); + late final _dart_player_set_media_stream_buffer_max_size + _player_set_media_stream_buffer_max_size = + _player_set_media_stream_buffer_max_size_ptr + .asFunction<_dart_player_set_media_stream_buffer_max_size>(); + + /// @brief Gets the max size bytes of buffer. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @remarks This function is used for media stream playback only. + /// @remarks If the buffer level over the max size, player_media_stream_buffer_status_cb() will be invoked with overflow status. + /// @param[in] player The handle to the media player + /// @param[in] type The type of target stream + /// @param[out] max_size The max bytes of buffer + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_set_media_stream_buffer_max_size() + /// @see player_media_stream_buffer_status_cb() + int player_get_media_stream_buffer_max_size( + ffi.Pointer player, + int type, + ffi.Pointer max_size, + ) { + return _player_get_media_stream_buffer_max_size( + player, + type, + max_size, + ); + } + + late final _player_get_media_stream_buffer_max_size_ptr = + _lookup>( + 'player_get_media_stream_buffer_max_size'); + late final _dart_player_get_media_stream_buffer_max_size + _player_get_media_stream_buffer_max_size = + _player_get_media_stream_buffer_max_size_ptr + .asFunction<_dart_player_get_media_stream_buffer_max_size>(); + + /// @brief Sets the buffer threshold percent of buffer. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @remarks This function is used for media stream playback only. + /// @remarks If the buffer level drops below the percent value, player_media_stream_buffer_status_cb() will be invoked with underrun status. + /// @param[in] player The handle to the media player + /// @param[in] type The type of target stream + /// @param[in] percent The minimum threshold(0~100) of buffer (default: 0) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. (since 3.0) + /// @see player_get_media_stream_buffer_min_threshold() + /// @see player_media_stream_buffer_status_cb() + int player_set_media_stream_buffer_min_threshold( + ffi.Pointer player, + int type, + int percent, + ) { + return _player_set_media_stream_buffer_min_threshold( + player, + type, + percent, + ); + } + + late final _player_set_media_stream_buffer_min_threshold_ptr = _lookup< + ffi.NativeFunction<_c_player_set_media_stream_buffer_min_threshold>>( + 'player_set_media_stream_buffer_min_threshold'); + late final _dart_player_set_media_stream_buffer_min_threshold + _player_set_media_stream_buffer_min_threshold = + _player_set_media_stream_buffer_min_threshold_ptr + .asFunction<_dart_player_set_media_stream_buffer_min_threshold>(); + + /// @brief Gets the buffer threshold percent of buffer. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @remarks This function is used for media stream playback only. + /// @remarks If the buffer level drops below the percent value, player_media_stream_buffer_status_cb() will be invoked with underrun status. + /// @param[in] player The handle to the media player + /// @param[in] type The type of target stream + /// @param[out] percent The minimum threshold(0~100) of buffer + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_set_media_stream_buffer_min_threshold() + /// @see player_media_stream_buffer_status_cb() + int player_get_media_stream_buffer_min_threshold( + ffi.Pointer player, + int type, + ffi.Pointer percent, + ) { + return _player_get_media_stream_buffer_min_threshold( + player, + type, + percent, + ); + } + + late final _player_get_media_stream_buffer_min_threshold_ptr = _lookup< + ffi.NativeFunction<_c_player_get_media_stream_buffer_min_threshold>>( + 'player_get_media_stream_buffer_min_threshold'); + late final _dart_player_get_media_stream_buffer_min_threshold + _player_get_media_stream_buffer_min_threshold = + _player_get_media_stream_buffer_min_threshold_ptr + .asFunction<_dart_player_get_media_stream_buffer_min_threshold>(); + + /// @brief Sets the video display mode. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks If no display is set, no operation is performed. + /// @param[in] player The handle to the media player + /// @param[in] mode The display mode + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see #player_display_mode_e + /// @see player_set_display() + /// @see player_get_display_mode() + int player_set_display_mode( + ffi.Pointer player, + int mode, + ) { + return _player_set_display_mode( + player, + mode, + ); + } + + late final _player_set_display_mode_ptr = + _lookup>( + 'player_set_display_mode'); + late final _dart_player_set_display_mode _player_set_display_mode = + _player_set_display_mode_ptr.asFunction<_dart_player_set_display_mode>(); + + /// @brief Gets the video display mode. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks If no display is set, no operation is performed. + /// @param[in] player The handle to the media player + /// @param[out] mode The current display mode + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see #player_display_mode_e + /// @see player_set_display_mode() + int player_get_display_mode( + ffi.Pointer player, + ffi.Pointer mode, + ) { + return _player_get_display_mode( + player, + mode, + ); + } + + late final _player_get_display_mode_ptr = + _lookup>( + 'player_get_display_mode'); + late final _dart_player_get_display_mode _player_get_display_mode = + _player_get_display_mode_ptr.asFunction<_dart_player_get_display_mode>(); + + /// @brief Sets the ROI(Region Of Interest) area of display. + /// @since_tizen 3.0 + /// @remarks If no display is set, no operation is performed and + /// the ROI area is valid only in #PLAYER_DISPLAY_MODE_DST_ROI display mode. + /// @remarks The minimum value of width and height are 1. + /// @remarks ROI area can be set before setting ROI display mode. (since 4.0) + /// @param[in] player The handle to the media player + /// @param[in] x X coordinate of area + /// @param[in] y Y coordinate of area + /// @param[in] width Width of area + /// @param[in] height Height of area + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_set_display() + /// @see player_set_display_mode() + int player_set_display_roi_area( + ffi.Pointer player, + int x, + int y, + int width, + int height, + ) { + return _player_set_display_roi_area( + player, + x, + y, + width, + height, + ); + } + + late final _player_set_display_roi_area_ptr = + _lookup>( + 'player_set_display_roi_area'); + late final _dart_player_set_display_roi_area _player_set_display_roi_area = + _player_set_display_roi_area_ptr + .asFunction<_dart_player_set_display_roi_area>(); + + /// @brief Sets the visibility of the video display. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks If no display is set, no operation is performed. + /// @remarks If you set visible before calling player_set_display, it will be applied on #PLAYER_STATE_READY state. + /// @param[in] player The handle to the media player + /// @param[in] visible The visibility of the display (@c true = visible, @c false = non-visible ) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_set_display() + /// @see player_is_display_visible() + int player_set_display_visible( + ffi.Pointer player, + bool visible, + ) { + return _player_set_display_visible( + player, + visible ? 1 : 0, + ); + } + + late final _player_set_display_visible_ptr = + _lookup>( + 'player_set_display_visible'); + late final _dart_player_set_display_visible _player_set_display_visible = + _player_set_display_visible_ptr + .asFunction<_dart_player_set_display_visible>(); + + /// @brief Gets the visibility of the video display. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[out] visible The current visibility of the display (@c true = visible, @c false = non-visible ) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_set_display_visible() + int player_is_display_visible( + ffi.Pointer player, + ffi.Pointer visible, + ) { + return _player_is_display_visible( + player, + visible, + ); + } + + late final _player_is_display_visible_ptr = + _lookup>( + 'player_is_display_visible'); + late final _dart_player_is_display_visible _player_is_display_visible = + _player_is_display_visible_ptr + .asFunction<_dart_player_is_display_visible>(); + + /// @brief Sets the rotation settings of the video surface display. + /// @details Use this function to change the video orientation to portrait mode. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks If no display is set, no operation is performed. + /// @param[in] player The handle to the media player + /// @param[in] rotation The rotation of the display + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see #player_display_rotation_e + /// @see player_set_display + /// @see player_get_display_rotation() + int player_set_display_rotation( + ffi.Pointer player, + int rotation, + ) { + return _player_set_display_rotation( + player, + rotation, + ); + } + + late final _player_set_display_rotation_ptr = + _lookup>( + 'player_set_display_rotation'); + late final _dart_player_set_display_rotation _player_set_display_rotation = + _player_set_display_rotation_ptr + .asFunction<_dart_player_set_display_rotation>(); + + /// @brief Gets the rotation of the video surface display. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[out] rotation The current rotation of the display + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see #player_display_rotation_e + /// @see player_set_display_rotation() + int player_get_display_rotation( + ffi.Pointer player, + ffi.Pointer rotation, + ) { + return _player_get_display_rotation( + player, + rotation, + ); + } + + late final _player_get_display_rotation_ptr = + _lookup>( + 'player_get_display_rotation'); + late final _dart_player_get_display_rotation _player_get_display_rotation = + _player_get_display_rotation_ptr + .asFunction<_dart_player_get_display_rotation>(); + + /// @brief Gets the media content information. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks You must release @a value using @c free(). + /// @remarks The playback type should be local playback or HTTP streaming playback. + /// @param[in] player The handle to the media player + /// @param[in] key The key attribute name to get + /// @param[out] value The value of the key attribute \n + /// It can be an empty string if there is no content information. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_OUT_OF_MEMORY Not enough memory is available + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING or #PLAYER_STATE_PAUSED. + int player_get_content_info( + ffi.Pointer player, + int key, + ffi.Pointer> value, + ) { + return _player_get_content_info( + player, + key, + value, + ); + } + + late final _player_get_content_info_ptr = + _lookup>( + 'player_get_content_info'); + late final _dart_player_get_content_info _player_get_content_info = + _player_get_content_info_ptr.asFunction<_dart_player_get_content_info>(); + + /// @brief Gets the audio and video codec information. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks You must release @a audio_codec and @a video_codec using free(). + /// @remarks The playback type should be local playback or HTTP streaming playback. + /// @param[in] player The handle to the media player + /// @param[out] audio_codec The name of the audio codec \n + /// It can be @c NULL if there is no audio codec. + /// @param[out] video_codec The name of the video codec \n + /// It can be @c NULL if there is no video codec. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING or #PLAYER_STATE_PAUSED. + int player_get_codec_info( + ffi.Pointer player, + ffi.Pointer> audio_codec, + ffi.Pointer> video_codec, + ) { + return _player_get_codec_info( + player, + audio_codec, + video_codec, + ); + } + + late final _player_get_codec_info_ptr = + _lookup>( + 'player_get_codec_info'); + late final _dart_player_get_codec_info _player_get_codec_info = + _player_get_codec_info_ptr.asFunction<_dart_player_get_codec_info>(); + + /// @brief Gets the audio stream information. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks The playback type should be local playback or HTTP streaming playback. + /// @param[in] player The handle to the media player + /// @param[out] sample_rate The audio sample rate [Hz] \n + /// Value can be invalid if there is no audio stream information. + /// @param[out] channel The audio channel (1: mono, 2: stereo) \n + /// Value can be invalid if there is no audio stream information. + /// @param[out] bit_rate The audio bit rate [Hz] \n + /// Value can be invalid if there is no audio stream information. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING or #PLAYER_STATE_PAUSED. + int player_get_audio_stream_info( + ffi.Pointer player, + ffi.Pointer sample_rate, + ffi.Pointer channel, + ffi.Pointer bit_rate, + ) { + return _player_get_audio_stream_info( + player, + sample_rate, + channel, + bit_rate, + ); + } + + late final _player_get_audio_stream_info_ptr = + _lookup>( + 'player_get_audio_stream_info'); + late final _dart_player_get_audio_stream_info _player_get_audio_stream_info = + _player_get_audio_stream_info_ptr + .asFunction<_dart_player_get_audio_stream_info>(); + + /// @brief Gets the video stream information. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks The playback type should be local playback or HTTP streaming playback. + /// @param[in] player The handle to the media player + /// @param[out] fps The frame per second of the video \n + /// It can be @c 0 if there is no video stream information. + /// @param[out] bit_rate The video bit rate [Hz] \n + /// It can be an invalid value if there is no video stream information. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING or #PLAYER_STATE_PAUSED. + int player_get_video_stream_info( + ffi.Pointer player, + ffi.Pointer fps, + ffi.Pointer bit_rate, + ) { + return _player_get_video_stream_info( + player, + fps, + bit_rate, + ); + } + + late final _player_get_video_stream_info_ptr = + _lookup>( + 'player_get_video_stream_info'); + late final _dart_player_get_video_stream_info _player_get_video_stream_info = + _player_get_video_stream_info_ptr + .asFunction<_dart_player_get_video_stream_info>(); + + /// @brief Gets the video display's height and width. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks The playback type should be local playback or HTTP streaming playback. + /// @param[in] player The handle to the media player + /// @param[out] width The width of the video \n + /// Value can be invalid if there is no video or no display is set. + /// @param[out] height The height of the video \n + /// Value can be invalid value if there is no video or no display is set. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING or #PLAYER_STATE_PAUSED. + int player_get_video_size( + ffi.Pointer player, + ffi.Pointer width, + ffi.Pointer height, + ) { + return _player_get_video_size( + player, + width, + height, + ); + } + + late final _player_get_video_size_ptr = + _lookup>( + 'player_get_video_size'); + late final _dart_player_get_video_size _player_get_video_size = + _player_get_video_size_ptr.asFunction<_dart_player_get_video_size>(); + + /// @brief Gets the album art in the media resource. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks You must not release @a album_art. + /// The @a album_art is managed by the platform and will be released + /// when the player is unprepared or destroyed by calling player_unprepare() or player_destroy(). + /// @param[in] player The handle to the media player + /// @param[out] album_art The encoded artwork image + /// @param[out] size The encoded artwork size + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING or #PLAYER_STATE_PAUSED. + int player_get_album_art( + ffi.Pointer player, + ffi.Pointer> album_art, + ffi.Pointer size, + ) { + return _player_get_album_art( + player, + album_art, + size, + ); + } + + late final _player_get_album_art_ptr = + _lookup>( + 'player_get_album_art'); + late final _dart_player_get_album_art _player_get_album_art = + _player_get_album_art_ptr.asFunction<_dart_player_get_album_art>(); + + /// @brief Gets the total running time of the associated media. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks The media source is associated with the player, using either player_set_uri() or player_set_memory_buffer(). + /// @remarks The playback type should be local playback or HTTP streaming playback. + /// @param[in] player The handle to the media player + /// @param[out] duration The duration in milliseconds + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING or #PLAYER_STATE_PAUSED. + /// @see player_set_uri() + /// @see player_set_memory_buffer() + int player_get_duration( + ffi.Pointer player, + ffi.Pointer duration, + ) { + return _player_get_duration( + player, + duration, + ); + } + + late final _player_get_duration_ptr = + _lookup>( + 'player_get_duration'); + late final _dart_player_get_duration _player_get_duration = + _player_get_duration_ptr.asFunction<_dart_player_get_duration>(); + + /// @brief Gets the number of equalizer bands. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[out] count The number of equalizer bands + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_audio_effect_equalizer_is_available() + /// @see player_audio_effect_set_equalizer_band_level() + /// @see player_audio_effect_set_equalizer_all_bands() + int player_audio_effect_get_equalizer_bands_count( + ffi.Pointer player, + ffi.Pointer count, + ) { + return _player_audio_effect_get_equalizer_bands_count( + player, + count, + ); + } + + late final _player_audio_effect_get_equalizer_bands_count_ptr = _lookup< + ffi.NativeFunction<_c_player_audio_effect_get_equalizer_bands_count>>( + 'player_audio_effect_get_equalizer_bands_count'); + late final _dart_player_audio_effect_get_equalizer_bands_count + _player_audio_effect_get_equalizer_bands_count = + _player_audio_effect_get_equalizer_bands_count_ptr + .asFunction<_dart_player_audio_effect_get_equalizer_bands_count>(); + + /// @brief Sets the gain set for the given equalizer band. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[in] index The index of the equalizer band to be set + /// @param[in] level The new gain in decibel that is set to the given band [dB] + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_audio_effect_equalizer_is_available() + /// @see player_audio_effect_get_equalizer_bands_count() + /// @see player_audio_effect_get_equalizer_level_range() + /// @see player_audio_effect_get_equalizer_band_level() + /// @see player_audio_effect_set_equalizer_all_bands() + int player_audio_effect_set_equalizer_band_level( + ffi.Pointer player, + int index, + int level, + ) { + return _player_audio_effect_set_equalizer_band_level( + player, + index, + level, + ); + } + + late final _player_audio_effect_set_equalizer_band_level_ptr = _lookup< + ffi.NativeFunction<_c_player_audio_effect_set_equalizer_band_level>>( + 'player_audio_effect_set_equalizer_band_level'); + late final _dart_player_audio_effect_set_equalizer_band_level + _player_audio_effect_set_equalizer_band_level = + _player_audio_effect_set_equalizer_band_level_ptr + .asFunction<_dart_player_audio_effect_set_equalizer_band_level>(); + + /// @brief Gets the gain set for the given equalizer band. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[in] index The index of the requested equalizer band + /// @param[out] level The gain in decibel of the given band [dB] + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_audio_effect_equalizer_is_available() + /// @see player_audio_effect_set_equalizer_band_level() + int player_audio_effect_get_equalizer_band_level( + ffi.Pointer player, + int index, + ffi.Pointer level, + ) { + return _player_audio_effect_get_equalizer_band_level( + player, + index, + level, + ); + } + + late final _player_audio_effect_get_equalizer_band_level_ptr = _lookup< + ffi.NativeFunction<_c_player_audio_effect_get_equalizer_band_level>>( + 'player_audio_effect_get_equalizer_band_level'); + late final _dart_player_audio_effect_get_equalizer_band_level + _player_audio_effect_get_equalizer_band_level = + _player_audio_effect_get_equalizer_band_level_ptr + .asFunction<_dart_player_audio_effect_get_equalizer_band_level>(); + + /// @brief Sets all bands of the equalizer. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[in] band_levels The list of band levels to be set + /// @param[in] length The length of the band level + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_audio_effect_equalizer_is_available() + /// @see player_audio_effect_get_equalizer_bands_count() + /// @see player_audio_effect_get_equalizer_level_range() + /// @see player_audio_effect_set_equalizer_band_level() + int player_audio_effect_set_equalizer_all_bands( + ffi.Pointer player, + ffi.Pointer band_levels, + int length, + ) { + return _player_audio_effect_set_equalizer_all_bands( + player, + band_levels, + length, + ); + } + + late final _player_audio_effect_set_equalizer_all_bands_ptr = _lookup< + ffi.NativeFunction<_c_player_audio_effect_set_equalizer_all_bands>>( + 'player_audio_effect_set_equalizer_all_bands'); + late final _dart_player_audio_effect_set_equalizer_all_bands + _player_audio_effect_set_equalizer_all_bands = + _player_audio_effect_set_equalizer_all_bands_ptr + .asFunction<_dart_player_audio_effect_set_equalizer_all_bands>(); + + /// @brief Gets the valid band level range of the equalizer. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[out] min The minimum value to be set [dB] + /// @param[out] max The maximum value to be set [dB] + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_audio_effect_equalizer_is_available() + /// @see player_audio_effect_set_equalizer_band_level() + /// @see player_audio_effect_set_equalizer_all_bands() + int player_audio_effect_get_equalizer_level_range( + ffi.Pointer player, + ffi.Pointer min, + ffi.Pointer max, + ) { + return _player_audio_effect_get_equalizer_level_range( + player, + min, + max, + ); + } + + late final _player_audio_effect_get_equalizer_level_range_ptr = _lookup< + ffi.NativeFunction<_c_player_audio_effect_get_equalizer_level_range>>( + 'player_audio_effect_get_equalizer_level_range'); + late final _dart_player_audio_effect_get_equalizer_level_range + _player_audio_effect_get_equalizer_level_range = + _player_audio_effect_get_equalizer_level_range_ptr + .asFunction<_dart_player_audio_effect_get_equalizer_level_range>(); + + /// @brief Gets the band frequency of the equalizer. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[in] index The index of the requested equalizer band + /// @param[out] frequency The frequency of the given band [dB] + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_audio_effect_equalizer_is_available() + int player_audio_effect_get_equalizer_band_frequency( + ffi.Pointer player, + int index, + ffi.Pointer frequency, + ) { + return _player_audio_effect_get_equalizer_band_frequency( + player, + index, + frequency, + ); + } + + late final _player_audio_effect_get_equalizer_band_frequency_ptr = _lookup< + ffi.NativeFunction< + _c_player_audio_effect_get_equalizer_band_frequency>>( + 'player_audio_effect_get_equalizer_band_frequency'); + late final _dart_player_audio_effect_get_equalizer_band_frequency + _player_audio_effect_get_equalizer_band_frequency = + _player_audio_effect_get_equalizer_band_frequency_ptr + .asFunction<_dart_player_audio_effect_get_equalizer_band_frequency>(); + + /// @brief Gets the band frequency range of the equalizer. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[in] index The index of the requested equalizer band + /// @param[out] range The frequency range of the given band [dB] + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_audio_effect_equalizer_is_available() + int player_audio_effect_get_equalizer_band_frequency_range( + ffi.Pointer player, + int index, + ffi.Pointer range, + ) { + return _player_audio_effect_get_equalizer_band_frequency_range( + player, + index, + range, + ); + } + + late final _player_audio_effect_get_equalizer_band_frequency_range_ptr = + _lookup< + ffi.NativeFunction< + _c_player_audio_effect_get_equalizer_band_frequency_range>>( + 'player_audio_effect_get_equalizer_band_frequency_range'); + late final _dart_player_audio_effect_get_equalizer_band_frequency_range + _player_audio_effect_get_equalizer_band_frequency_range = + _player_audio_effect_get_equalizer_band_frequency_range_ptr.asFunction< + _dart_player_audio_effect_get_equalizer_band_frequency_range>(); + + /// @brief Clears the equalizer effect. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_audio_effect_equalizer_is_available() + /// @see player_audio_effect_set_equalizer_band_level() + /// @see player_audio_effect_set_equalizer_all_bands() + int player_audio_effect_equalizer_clear( + ffi.Pointer player, + ) { + return _player_audio_effect_equalizer_clear( + player, + ); + } + + late final _player_audio_effect_equalizer_clear_ptr = + _lookup>( + 'player_audio_effect_equalizer_clear'); + late final _dart_player_audio_effect_equalizer_clear + _player_audio_effect_equalizer_clear = + _player_audio_effect_equalizer_clear_ptr + .asFunction<_dart_player_audio_effect_equalizer_clear>(); + + /// @brief Checks whether the custom equalizer effect is available. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[out] available If @c true the specified audio effect is available, + /// otherwise @c false + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_audio_effect_set_equalizer_band_level() + /// @see player_audio_effect_set_equalizer_all_bands() + int player_audio_effect_equalizer_is_available( + ffi.Pointer player, + ffi.Pointer available, + ) { + return _player_audio_effect_equalizer_is_available( + player, + available, + ); + } + + late final _player_audio_effect_equalizer_is_available_ptr = _lookup< + ffi.NativeFunction<_c_player_audio_effect_equalizer_is_available>>( + 'player_audio_effect_equalizer_is_available'); + late final _dart_player_audio_effect_equalizer_is_available + _player_audio_effect_equalizer_is_available = + _player_audio_effect_equalizer_is_available_ptr + .asFunction<_dart_player_audio_effect_equalizer_is_available>(); + + /// @brief Captures the video frame, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be set to #PLAYER_STATE_PLAYING by calling player_start() or set to #PLAYER_STATE_PAUSED by calling player_pause(). + /// @pre Video display type should be set by calling player_set_display() otherwise, audio stream is only processed even though video file is set. + /// @post It invokes player_video_captured_cb() when capture completes, if you set a callback. + /// @see player_video_captured_cb() + int player_capture_video( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _player_capture_video( + player, + callback, + user_data, + ); + } + + late final _player_capture_video_ptr = + _lookup>( + 'player_capture_video'); + late final _dart_player_capture_video _player_capture_video = + _player_capture_video_ptr.asFunction<_dart_player_capture_video>(); + + /// @brief Sets the cookie for streaming playback. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks This function must be called before calling the player_prepare() or player_prepare_async() + /// to reflect the cookie information when the streaming connection is set up. + /// @param[in] player The handle to the media player + /// @param[in] cookie The cookie to set + /// @param[in] size The size of the cookie + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be set to #PLAYER_STATE_IDLE by calling player_create() or player_unprepare(). + /// @see player_set_uri() + /// @see player_set_streaming_user_agent() + int player_set_streaming_cookie( + ffi.Pointer player, + ffi.Pointer cookie, + int size, + ) { + return _player_set_streaming_cookie( + player, + cookie, + size, + ); + } + + late final _player_set_streaming_cookie_ptr = + _lookup>( + 'player_set_streaming_cookie'); + late final _dart_player_set_streaming_cookie _player_set_streaming_cookie = + _player_set_streaming_cookie_ptr + .asFunction<_dart_player_set_streaming_cookie>(); + + /// @brief Sets the streaming user agent for playback. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks This function must be called before calling the player_prepare() or player_prepare_async() + /// to reflect the user agent information when the streaming connection is set up. + /// @param[in] player The handle to the media player + /// @param[in] user_agent The user agent to set + /// @param[in] size The size of the user agent + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be set to #PLAYER_STATE_IDLE by calling player_create() or player_unprepare(). + /// @see player_set_uri() + /// @see player_set_streaming_cookie() + int player_set_streaming_user_agent( + ffi.Pointer player, + ffi.Pointer user_agent, + int size, + ) { + return _player_set_streaming_user_agent( + player, + user_agent, + size, + ); + } + + late final _player_set_streaming_user_agent_ptr = + _lookup>( + 'player_set_streaming_user_agent'); + late final _dart_player_set_streaming_user_agent + _player_set_streaming_user_agent = _player_set_streaming_user_agent_ptr + .asFunction<_dart_player_set_streaming_user_agent>(); + + /// @brief Gets the download progress for streaming playback. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[out] start The starting position in percentage [0, 100] + /// @param[out] current The current position in percentage [0, 100] + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be set to #PLAYER_STATE_PLAYING by calling player_start() or set to #PLAYER_STATE_PAUSED by calling player_pause(). + int player_get_streaming_download_progress( + ffi.Pointer player, + ffi.Pointer start, + ffi.Pointer current, + ) { + return _player_get_streaming_download_progress( + player, + start, + current, + ); + } + + late final _player_get_streaming_download_progress_ptr = + _lookup>( + 'player_get_streaming_download_progress'); + late final _dart_player_get_streaming_download_progress + _player_get_streaming_download_progress = + _player_get_streaming_download_progress_ptr + .asFunction<_dart_player_get_streaming_download_progress>(); + + /// @brief Sets a callback function to be invoked when the playback is finished. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @post player_completed_cb() will be invoked. + /// @see player_unset_completed_cb() + /// @see player_completed_cb() + /// @see player_start() + int player_set_completed_cb( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _player_set_completed_cb( + player, + callback, + user_data, + ); + } + + late final _player_set_completed_cb_ptr = + _lookup>( + 'player_set_completed_cb'); + late final _dart_player_set_completed_cb _player_set_completed_cb = + _player_set_completed_cb_ptr.asFunction<_dart_player_set_completed_cb>(); + + /// @brief Unsets the playback completed callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @see player_set_completed_cb() + int player_unset_completed_cb( + ffi.Pointer player, + ) { + return _player_unset_completed_cb( + player, + ); + } + + late final _player_unset_completed_cb_ptr = + _lookup>( + 'player_unset_completed_cb'); + late final _dart_player_unset_completed_cb _player_unset_completed_cb = + _player_unset_completed_cb_ptr + .asFunction<_dart_player_unset_completed_cb>(); + + /// @brief Sets a callback function to be invoked when the playback is interrupted or the interrupt is completed. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @post player_interrupted_cb() will be invoked. + /// @see player_unset_interrupted_cb() + /// @see #player_interrupted_code_e + /// @see player_interrupted_cb() + int player_set_interrupted_cb( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _player_set_interrupted_cb( + player, + callback, + user_data, + ); + } + + late final _player_set_interrupted_cb_ptr = + _lookup>( + 'player_set_interrupted_cb'); + late final _dart_player_set_interrupted_cb _player_set_interrupted_cb = + _player_set_interrupted_cb_ptr + .asFunction<_dart_player_set_interrupted_cb>(); + + /// @brief Unsets the interrupted callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @see player_set_interrupted_cb() + int player_unset_interrupted_cb( + ffi.Pointer player, + ) { + return _player_unset_interrupted_cb( + player, + ); + } + + late final _player_unset_interrupted_cb_ptr = + _lookup>( + 'player_unset_interrupted_cb'); + late final _dart_player_unset_interrupted_cb _player_unset_interrupted_cb = + _player_unset_interrupted_cb_ptr + .asFunction<_dart_player_unset_interrupted_cb>(); + + /// @brief Sets a callback function to be invoked when an error occurs. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @post player_error_cb() will be invoked. + /// @see player_unset_error_cb() + /// @see player_error_cb() + int player_set_error_cb( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _player_set_error_cb( + player, + callback, + user_data, + ); + } + + late final _player_set_error_cb_ptr = + _lookup>( + 'player_set_error_cb'); + late final _dart_player_set_error_cb _player_set_error_cb = + _player_set_error_cb_ptr.asFunction<_dart_player_set_error_cb>(); + + /// @brief Unsets the error callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @see player_set_error_cb() + int player_unset_error_cb( + ffi.Pointer player, + ) { + return _player_unset_error_cb( + player, + ); + } + + late final _player_unset_error_cb_ptr = + _lookup>( + 'player_unset_error_cb'); + late final _dart_player_unset_error_cb _player_unset_error_cb = + _player_unset_error_cb_ptr.asFunction<_dart_player_unset_error_cb>(); + + /// @brief Sets a callback function to be invoked when there is a change in the buffering status of a media stream. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks The media resource should be streamed over the network. + /// @param[in] player The handle to the media player + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @if WEARABLE @retval #PLAYER_ERROR_FEATURE_NOT_SUPPORTED_ON_DEVICE Unsupported feature @endif + /// @post player_buffering_cb() will be invoked. + /// @see player_unset_buffering_cb() + /// @see player_set_uri() + /// @see player_buffering_cb() + int player_set_buffering_cb( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _player_set_buffering_cb( + player, + callback, + user_data, + ); + } + + late final _player_set_buffering_cb_ptr = + _lookup>( + 'player_set_buffering_cb'); + late final _dart_player_set_buffering_cb _player_set_buffering_cb = + _player_set_buffering_cb_ptr.asFunction<_dart_player_set_buffering_cb>(); + + /// @brief Unsets the buffering callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @see player_set_buffering_cb() + int player_unset_buffering_cb( + ffi.Pointer player, + ) { + return _player_unset_buffering_cb( + player, + ); + } + + late final _player_unset_buffering_cb_ptr = + _lookup>( + 'player_unset_buffering_cb'); + late final _dart_player_unset_buffering_cb _player_unset_buffering_cb = + _player_unset_buffering_cb_ptr + .asFunction<_dart_player_unset_buffering_cb>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Sets a path to download, progressively. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks Progressive download will be started when you invoke player_start(). + /// @remarks This function must be called before calling the player_prepare() or player_prepare_async() to reflect the download path when the player is building. + /// @remarks The mediastorage privilege(http://tizen.org/privilege/mediastorage) must be added if any files are used to download and play located in the internal storage. + /// @remarks The externalstorage privilege(http://tizen.org/privilege/externalstorage) must be added if any files are used to download and play located in the external storage. + /// + /// @param[in] player The handle to the media player + /// @param[in] path The absolute path to download + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @if WEARABLE @retval #PLAYER_ERROR_FEATURE_NOT_SUPPORTED_ON_DEVICE Unsupported feature @endif + /// @retval #PLAYER_ERROR_PERMISSION_DENIED Permission denied + /// @pre The player state must be set to #PLAYER_STATE_IDLE by calling player_create() or player_unprepare(). + /// @see player_set_progressive_download_message_cb() + /// @see player_unset_progressive_download_message_cb() + int player_set_progressive_download_path( + ffi.Pointer player, + ffi.Pointer path, + ) { + return _player_set_progressive_download_path( + player, + path, + ); + } + + late final _player_set_progressive_download_path_ptr = + _lookup>( + 'player_set_progressive_download_path'); + late final _dart_player_set_progressive_download_path + _player_set_progressive_download_path = + _player_set_progressive_download_path_ptr + .asFunction<_dart_player_set_progressive_download_path>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Gets the status of progressive download. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[out] current The current download position (bytes) + /// @param[out] total_size The total size of the file (bytes) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The progressive download path must be set by calling player_set_progressive_download_path(). + /// @pre The player state must be set to #PLAYER_STATE_PLAYING by calling player_start() or set to #PLAYER_STATE_PAUSED by calling player_pause(). + int player_get_progressive_download_status( + ffi.Pointer player, + ffi.Pointer current, + ffi.Pointer total_size, + ) { + return _player_get_progressive_download_status( + player, + current, + total_size, + ); + } + + late final _player_get_progressive_download_status_ptr = + _lookup>( + 'player_get_progressive_download_status'); + late final _dart_player_get_progressive_download_status + _player_get_progressive_download_status = + _player_get_progressive_download_status_ptr + .asFunction<_dart_player_get_progressive_download_status>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Sets a callback function to be invoked when progressive download is started or completed. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @if WEARABLE @retval #PLAYER_ERROR_FEATURE_NOT_SUPPORTED_ON_DEVICE Unsupported feature @endif + /// @pre The path to download must be set by calling player_set_progressive_download_path(). + /// @post player_pd_message_cb() will be invoked. + /// @see player_unset_progressive_download_message_cb() + /// @see player_set_progressive_download_path() + int player_set_progressive_download_message_cb( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _player_set_progressive_download_message_cb( + player, + callback, + user_data, + ); + } + + late final _player_set_progressive_download_message_cb_ptr = _lookup< + ffi.NativeFunction<_c_player_set_progressive_download_message_cb>>( + 'player_set_progressive_download_message_cb'); + late final _dart_player_set_progressive_download_message_cb + _player_set_progressive_download_message_cb = + _player_set_progressive_download_message_cb_ptr + .asFunction<_dart_player_set_progressive_download_message_cb>(); + + /// @deprecated Deprecated since 4.0. + /// @brief Unsets the progressive download message callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @see player_set_progressive_download_message_cb() + int player_unset_progressive_download_message_cb( + ffi.Pointer player, + ) { + return _player_unset_progressive_download_message_cb( + player, + ); + } + + late final _player_unset_progressive_download_message_cb_ptr = _lookup< + ffi.NativeFunction<_c_player_unset_progressive_download_message_cb>>( + 'player_unset_progressive_download_message_cb'); + late final _dart_player_unset_progressive_download_message_cb + _player_unset_progressive_download_message_cb = + _player_unset_progressive_download_message_cb_ptr + .asFunction<_dart_player_unset_progressive_download_message_cb>(); + + /// @brief Sets the playback rate. + /// @details The default value is @c 1.0. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks #PLAYER_ERROR_INVALID_OPERATION occurs when streaming playback. + /// @remarks No operation is performed, if @a rate is @c 0. + /// @remarks The sound is muted, when playback rate is under @c 0.0 and over @c 2.0. + /// @param[in] player The handle to the media player + /// @param[in] rate The playback rate (-5.0x ~ 5.0x) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + int player_set_playback_rate( + ffi.Pointer player, + double rate, + ) { + return _player_set_playback_rate( + player, + rate, + ); + } + + late final _player_set_playback_rate_ptr = + _lookup>( + 'player_set_playback_rate'); + late final _dart_player_set_playback_rate _player_set_playback_rate = + _player_set_playback_rate_ptr + .asFunction<_dart_player_set_playback_rate>(); + + /// @brief Sets a subtitle path. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks Only MicroDVD/SubViewer(*.sub), SAMI(*.smi), and SubRip(*.srt) subtitle formats are supported. + /// @remarks The mediastorage privilege(http://tizen.org/privilege/mediastorage) must be added if any files are used to play located in the internal storage. + /// @remarks The externalstorage privilege(http://tizen.org/privilege/externalstorage) must be added if any files are used to play located in the external storage. + /// @remarks The path value can be @c NULL for reset before calling player_prepare() or player_prepare_async(). + /// + /// @param[in] player The handle to the media player + /// @param[in] path The absolute path of the subtitle file, it can be @c NULL in the #PLAYER_STATE_IDLE state. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #PLAYER_ERROR_NO_SUCH_FILE File not found (Since 4.0) + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + int player_set_subtitle_path( + ffi.Pointer player, + ffi.Pointer path, + ) { + return _player_set_subtitle_path( + player, + path, + ); + } + + late final _player_set_subtitle_path_ptr = + _lookup>( + 'player_set_subtitle_path'); + late final _dart_player_set_subtitle_path _player_set_subtitle_path = + _player_set_subtitle_path_ptr + .asFunction<_dart_player_set_subtitle_path>(); + + /// @brief Sets a callback function to be invoked when a subtitle updates. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks The callback is called in a separate thread (not in the main loop). + /// @param[in] player The handle to the media player + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The subtitle must be set by calling player_set_subtitle_path(). + /// @post player_subtitle_updated_cb() will be invoked. + /// @see player_unset_subtitle_updated_cb() + /// @see player_subtitle_updated_cb() + /// @see player_set_subtitle_path() + int player_set_subtitle_updated_cb( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _player_set_subtitle_updated_cb( + player, + callback, + user_data, + ); + } + + late final _player_set_subtitle_updated_cb_ptr = + _lookup>( + 'player_set_subtitle_updated_cb'); + late final _dart_player_set_subtitle_updated_cb + _player_set_subtitle_updated_cb = _player_set_subtitle_updated_cb_ptr + .asFunction<_dart_player_set_subtitle_updated_cb>(); + + /// @brief Unsets the subtitle updated callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] player The handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @see player_set_subtitle_updated_cb() + int player_unset_subtitle_updated_cb( + ffi.Pointer player, + ) { + return _player_unset_subtitle_updated_cb( + player, + ); + } + + late final _player_unset_subtitle_updated_cb_ptr = + _lookup>( + 'player_unset_subtitle_updated_cb'); + late final _dart_player_unset_subtitle_updated_cb + _player_unset_subtitle_updated_cb = _player_unset_subtitle_updated_cb_ptr + .asFunction<_dart_player_unset_subtitle_updated_cb>(); + + /// @brief Sets the seek position for the subtitle. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif.1 + /// @remarks Only MicroDVD/SubViewer(*.sub), SAMI(*.smi), and SubRip(*.srt) subtitle formats are supported. + /// @param[in] player The handle to the media player + /// @param[in] millisecond The position in milliseconds from the start to the seek point + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The subtitle must be set by calling player_set_subtitle_path(). + /// @pre The player state must be one of #PLAYER_STATE_PLAYING or #PLAYER_STATE_PAUSED. + int player_set_subtitle_position_offset( + ffi.Pointer player, + int millisecond, + ) { + return _player_set_subtitle_position_offset( + player, + millisecond, + ); + } + + late final _player_set_subtitle_position_offset_ptr = + _lookup>( + 'player_set_subtitle_position_offset'); + late final _dart_player_set_subtitle_position_offset + _player_set_subtitle_position_offset = + _player_set_subtitle_position_offset_ptr + .asFunction<_dart_player_set_subtitle_position_offset>(); + + /// @brief Sets a callback function to be invoked when video stream is changed. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @remarks The stream changing is detected just before rendering operation. + /// @remarks The callback is called in a separate thread (not in the main loop). + /// @remarks This function must be called before calling the player_prepare() or player_prepare_async() + /// to reflect the requirement when the player is building. + /// @param[in] player The handle to the media player + /// @param[in] callback The stream changed callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The player state must be set to #PLAYER_STATE_IDLE by calling player_create() or player_unprepare(). + /// @post player_video_stream_changed_cb() will be invoked. + /// @see player_unset_video_stream_changed_cb() + /// @see player_video_stream_changed_cb() + int player_set_video_stream_changed_cb( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _player_set_video_stream_changed_cb( + player, + callback, + user_data, + ); + } + + late final _player_set_video_stream_changed_cb_ptr = + _lookup>( + 'player_set_video_stream_changed_cb'); + late final _dart_player_set_video_stream_changed_cb + _player_set_video_stream_changed_cb = + _player_set_video_stream_changed_cb_ptr + .asFunction<_dart_player_set_video_stream_changed_cb>(); + + /// @brief Unsets the video stream changed callback function. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @param[in] player The handle to the media player + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see player_set_video_stream_changed_cb() + int player_unset_video_stream_changed_cb( + ffi.Pointer player, + ) { + return _player_unset_video_stream_changed_cb( + player, + ); + } + + late final _player_unset_video_stream_changed_cb_ptr = + _lookup>( + 'player_unset_video_stream_changed_cb'); + late final _dart_player_unset_video_stream_changed_cb + _player_unset_video_stream_changed_cb = + _player_unset_video_stream_changed_cb_ptr + .asFunction<_dart_player_unset_video_stream_changed_cb>(); + + /// @brief Gets current track index. + /// @details Index starts from 0. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @param[in] player The handle to the media player + /// @param[in] type The type of target stream which is PLAYER_STREAM_TYPE_AUDIO or PLAYER_STREAM_TYPE_TEXT + /// @param[out] index The index of track + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED + int player_get_current_track( + ffi.Pointer player, + int type, + ffi.Pointer index, + ) { + return _player_get_current_track( + player, + type, + index, + ); + } + + late final _player_get_current_track_ptr = + _lookup>( + 'player_get_current_track'); + late final _dart_player_get_current_track _player_get_current_track = + _player_get_current_track_ptr + .asFunction<_dart_player_get_current_track>(); + + /// @brief Gets language code of a track. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @remarks @a code must be released with @c free() by caller + /// @param[in] player The handle to the media player + /// @param[in] type The type of target stream which is PLAYER_STREAM_TYPE_AUDIO or PLAYER_STREAM_TYPE_TEXT + /// @param[in] index The index of track + /// @param[out] code A language code in ISO 639-1. "und" will be returned if the language is undefined. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED + int player_get_track_language_code( + ffi.Pointer player, + int type, + int index, + ffi.Pointer> code, + ) { + return _player_get_track_language_code( + player, + type, + index, + code, + ); + } + + late final _player_get_track_language_code_ptr = + _lookup>( + 'player_get_track_language_code'); + late final _dart_player_get_track_language_code + _player_get_track_language_code = _player_get_track_language_code_ptr + .asFunction<_dart_player_get_track_language_code>(); + + /// @brief Gets the track count. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @param[in] player The handle to the media player + /// @param[in] type The type of target stream which is PLAYER_STREAM_TYPE_AUDIO or PLAYER_STREAM_TYPE_TEXT + /// @param[out] count The number of track + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED + int player_get_track_count( + ffi.Pointer player, + int type, + ffi.Pointer count, + ) { + return _player_get_track_count( + player, + type, + count, + ); + } + + late final _player_get_track_count_ptr = + _lookup>( + 'player_get_track_count'); + late final _dart_player_get_track_count _player_get_track_count = + _player_get_track_count_ptr.asFunction<_dart_player_get_track_count>(); + + /// @brief Selects a track to play. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @param[in] player The handle to the media player + /// @param[in] type The type of target stream which is PLAYER_STREAM_TYPE_AUDIO or PLAYER_STREAM_TYPE_TEXT + /// @param[in] index The index of track + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED + /// @see player_get_current_track() + int player_select_track( + ffi.Pointer player, + int type, + int index, + ) { + return _player_select_track( + player, + type, + index, + ); + } + + late final _player_select_track_ptr = + _lookup>( + 'player_select_track'); + late final _dart_player_select_track _player_select_track = + _player_select_track_ptr.asFunction<_dart_player_select_track>(); + + /// @brief Retrieves all the streaming variant information. + /// @since_tizen 4.0 + /// @remarks This function is used for adaptive streaming(hls/mpeg dash) only. + /// @param[in] player The handle to the media player + /// @param[in] callback The iteration callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED + /// @see player_adaptive_variant_cb + int player_foreach_adaptive_variant( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _player_foreach_adaptive_variant( + player, + callback, + user_data, + ); + } + + late final _player_foreach_adaptive_variant_ptr = + _lookup>( + 'player_foreach_adaptive_variant'); + late final _dart_player_foreach_adaptive_variant + _player_foreach_adaptive_variant = _player_foreach_adaptive_variant_ptr + .asFunction<_dart_player_foreach_adaptive_variant>(); + + /// @brief Sets the maximum limit of the streaming variant. + /// @since_tizen 4.0 + /// @remarks This function is used for adaptive streaming(hls/mpeg dash) only. + /// @remarks The bandwidth setting can only be applied if there is no width, height information at streaming variant header. + /// Application can get all the variant information by calling player_foreach_adaptive_variant() function. + /// @remarks If there is no affordable stream for the condition, the minimum bandwidth stream will be selected. + /// @param[in] player The handle to the media player + /// @param[in] bandwidth The max bandwidth limit of the stream variant (default: -1) + /// @param[in] width The max width limit of the stream variant (deafult: -1) + /// @param[in] height The max height limit of the stream variant (deafult: -1) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_foreach_adaptive_variant() + /// @see player_get_max_adaptive_variant_limit() + int player_set_max_adaptive_variant_limit( + ffi.Pointer player, + int bandwidth, + int width, + int height, + ) { + return _player_set_max_adaptive_variant_limit( + player, + bandwidth, + width, + height, + ); + } + + late final _player_set_max_adaptive_variant_limit_ptr = + _lookup>( + 'player_set_max_adaptive_variant_limit'); + late final _dart_player_set_max_adaptive_variant_limit + _player_set_max_adaptive_variant_limit = + _player_set_max_adaptive_variant_limit_ptr + .asFunction<_dart_player_set_max_adaptive_variant_limit>(); + + /// @brief Gets the maximum limit of the streaming variant. + /// @since_tizen 4.0 + /// @remarks This function is used for adaptive streaming(hls/mpeg dash) only. + /// @param[in] player The handle to the media player + /// @param[out] bandwidth The max bandwidth limit of the stream variant (default: -1) + /// @param[out] width The max width limit of the stream variant (deafult: -1) + /// @param[out] height The max height limit of the stream variant (deafult: -1) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_foreach_adaptive_variant() + /// @see player_set_max_adaptive_variant_limit() + int player_get_max_adaptive_variant_limit( + ffi.Pointer player, + ffi.Pointer bandwidth, + ffi.Pointer width, + ffi.Pointer height, + ) { + return _player_get_max_adaptive_variant_limit( + player, + bandwidth, + width, + height, + ); + } + + late final _player_get_max_adaptive_variant_limit_ptr = + _lookup>( + 'player_get_max_adaptive_variant_limit'); + late final _dart_player_get_max_adaptive_variant_limit + _player_get_max_adaptive_variant_limit = + _player_get_max_adaptive_variant_limit_ptr + .asFunction<_dart_player_get_max_adaptive_variant_limit>(); + + /// @brief Sets the audio only mode. + /// @details This function is used to disable or enable video rendering during playback. + /// @since_tizen 4.0 + /// @param[in] player The handle to the media player + /// @param[in] audio_only The new audio only status: (@c true = enable audio only, @c false = disable audio only) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid player state + /// @pre The player state must be one of: #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_is_audio_only() + int player_set_audio_only( + ffi.Pointer player, + bool audio_only, + ) { + return _player_set_audio_only( + player, + audio_only ? 1 : 0, + ); + } + + late final _player_set_audio_only_ptr = + _lookup>( + 'player_set_audio_only'); + late final _dart_player_set_audio_only _player_set_audio_only = + _player_set_audio_only_ptr.asFunction<_dart_player_set_audio_only>(); + + /// @brief Gets the audio only mode status. + /// @since_tizen 4.0 + /// @param[in] player The handle to the media player + /// @param[out] audio_only The current audio only status: (@c true = audio only enabled, @c false = audio only disabled) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The player state must be one of: #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_set_audio_only() + int player_is_audio_only( + ffi.Pointer player, + ffi.Pointer audio_only, + ) { + return _player_is_audio_only( + player, + audio_only, + ); + } + + late final _player_is_audio_only_ptr = + _lookup>( + 'player_is_audio_only'); + late final _dart_player_is_audio_only _player_is_audio_only = + _player_is_audio_only_ptr.asFunction<_dart_player_is_audio_only>(); + + /// @brief Sets the streaming buffering time. + /// @since_tizen 4.0 + /// @param[in] player The handle to the media player + /// @param[in] prebuffer_ms The buffer time to start playback + /// @param[in] rebuffer_ms The buffer time during playback if player enter pause state for buffering. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid state + /// @if WEARABLE @retval #PLAYER_ERROR_FEATURE_NOT_SUPPORTED_ON_DEVICE Unsupported feature @endif + /// @pre The player state must be #PLAYER_STATE_IDLE. + /// @see player_get_streaming_buffering_time() + int player_set_streaming_buffering_time( + ffi.Pointer player, + int prebuffer_ms, + int rebuffer_ms, + ) { + return _player_set_streaming_buffering_time( + player, + prebuffer_ms, + rebuffer_ms, + ); + } + + late final _player_set_streaming_buffering_time_ptr = + _lookup>( + 'player_set_streaming_buffering_time'); + late final _dart_player_set_streaming_buffering_time + _player_set_streaming_buffering_time = + _player_set_streaming_buffering_time_ptr + .asFunction<_dart_player_set_streaming_buffering_time>(); + + /// @brief Gets the streaming buffering time. + /// @since_tizen 4.0 + /// @param[in] player The handle to the media player + /// @param[in] prebuffer_ms The buffer time to start playback + /// @param[in] rebuffer_ms The buffer time during playback if player enter pause state for buffering. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PLAYER_ERROR_NONE Successful + /// @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PLAYER_ERROR_INVALID_STATE Invalid state + /// @if WEARABLE @retval #PLAYER_ERROR_FEATURE_NOT_SUPPORTED_ON_DEVICE Unsupported feature @endif + /// @pre The player state must be one of #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED. + /// @see player_set_streaming_buffering_time() + int player_get_streaming_buffering_time( + ffi.Pointer player, + ffi.Pointer prebuffer_ms, + ffi.Pointer rebuffer_ms, + ) { + return _player_get_streaming_buffering_time( + player, + prebuffer_ms, + rebuffer_ms, + ); + } + + late final _player_get_streaming_buffering_time_ptr = + _lookup>( + 'player_get_streaming_buffering_time'); + late final _dart_player_get_streaming_buffering_time + _player_get_streaming_buffering_time = + _player_get_streaming_buffering_time_ptr + .asFunction<_dart_player_get_streaming_buffering_time>(); + + /// @brief Creates a radio handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a radio using radio_destroy(). + /// @param[out] radio A new handle to radio + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @see radio_destroy() + int radio_create( + ffi.Pointer> radio, + ) { + return _radio_create( + radio, + ); + } + + late final _radio_create_ptr = + _lookup>('radio_create'); + late final _dart_radio_create _radio_create = + _radio_create_ptr.asFunction<_dart_radio_create>(); + + /// @brief Destroys the radio handle and releases all its resources. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks To completely shutdown the radio operation, call this function with a valid radio handle. + /// + /// @param[in] radio The handle to radio to be destroyed + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @see radio_create() + int radio_destroy( + ffi.Pointer radio, + ) { + return _radio_destroy( + radio, + ); + } + + late final _radio_destroy_ptr = + _lookup>('radio_destroy'); + late final _dart_radio_destroy _radio_destroy = + _radio_destroy_ptr.asFunction<_dart_radio_destroy>(); + + /// @brief Gets the radio's current state. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @param[out] state The current state of the radio + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + int radio_get_state( + ffi.Pointer radio, + ffi.Pointer state, + ) { + return _radio_get_state( + radio, + state, + ); + } + + late final _radio_get_state_ptr = + _lookup>('radio_get_state'); + late final _dart_radio_get_state _radio_get_state = + _radio_get_state_ptr.asFunction<_dart_radio_get_state>(); + + /// @brief Starts playing the radio. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_STATE Invalid radio state + /// @retval #RADIO_ERROR_SOUND_POLICY Sound policy error + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @retval #RADIO_ERROR_NO_ANTENNA No Antenna error + /// @pre The radio state must be set to #RADIO_STATE_READY by calling radio_create(). + /// @post The radio state will be #RADIO_STATE_PLAYING. + /// @see radio_stop() + int radio_start( + ffi.Pointer radio, + ) { + return _radio_start( + radio, + ); + } + + late final _radio_start_ptr = + _lookup>('radio_start'); + late final _dart_radio_start _radio_start = + _radio_start_ptr.asFunction<_dart_radio_start>(); + + /// @brief Stops playing the radio. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid state + /// @retval #RADIO_ERROR_INVALID_STATE Invalid radio state + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @pre The radio state must be set to #RADIO_STATE_PLAYING by calling radio_start(). + /// @post The radio state will be #RADIO_STATE_READY. + /// @see radio_start() + /// @see radio_scan_start() + int radio_stop( + ffi.Pointer radio, + ) { + return _radio_stop( + radio, + ); + } + + late final _radio_stop_ptr = + _lookup>('radio_stop'); + late final _dart_radio_stop _radio_stop = + _radio_stop_ptr.asFunction<_dart_radio_stop>(); + + /// @brief Seeks up the effective frequency of the radio, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_INVALID_STATE Invalid radio state + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @pre The radio state must be set to #RADIO_STATE_PLAYING by calling radio_start(). + /// @post It invokes radio_seek_completed_cb() when the seek completes. + /// @see radio_seek_down() + int radio_seek_up( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _radio_seek_up( + radio, + callback, + user_data, + ); + } + + late final _radio_seek_up_ptr = + _lookup>('radio_seek_up'); + late final _dart_radio_seek_up _radio_seek_up = + _radio_seek_up_ptr.asFunction<_dart_radio_seek_up>(); + + /// @brief Seeks down the effective frequency of the radio, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_INVALID_STATE Invalid radio state + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @pre The radio state must be set to #RADIO_STATE_PLAYING by calling radio_start(). + /// @post It invokes radio_seek_completed_cb() when the seek completes. + /// @see radio_seek_up() + int radio_seek_down( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _radio_seek_down( + radio, + callback, + user_data, + ); + } + + late final _radio_seek_down_ptr = + _lookup>('radio_seek_down'); + late final _dart_radio_seek_down _radio_seek_down = + _radio_seek_down_ptr.asFunction<_dart_radio_seek_down>(); + + /// @brief Sets the radio frequency. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @param[in] frequency The frequency to set [87500 ~ 108000] (kHz) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @see radio_get_frequency() + int radio_set_frequency( + ffi.Pointer radio, + int frequency, + ) { + return _radio_set_frequency( + radio, + frequency, + ); + } + + late final _radio_set_frequency_ptr = + _lookup>( + 'radio_set_frequency'); + late final _dart_radio_set_frequency _radio_set_frequency = + _radio_set_frequency_ptr.asFunction<_dart_radio_set_frequency>(); + + /// @brief Gets the current frequency of the radio. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @param[out] frequency The current frequency [87500 ~ 108000] (kHz) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @see radio_set_frequency() + int radio_get_frequency( + ffi.Pointer radio, + ffi.Pointer frequency, + ) { + return _radio_get_frequency( + radio, + frequency, + ); + } + + late final _radio_get_frequency_ptr = + _lookup>( + 'radio_get_frequency'); + late final _dart_radio_get_frequency _radio_get_frequency = + _radio_get_frequency_ptr.asFunction<_dart_radio_get_frequency>(); + + /// @brief Gets the current signal strength of the radio. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @param[out] strength The current signal strength [-128 ~ 128] (dBm) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + int radio_get_signal_strength( + ffi.Pointer radio, + ffi.Pointer strength, + ) { + return _radio_get_signal_strength( + radio, + strength, + ); + } + + late final _radio_get_signal_strength_ptr = + _lookup>( + 'radio_get_signal_strength'); + late final _dart_radio_get_signal_strength _radio_get_signal_strength = + _radio_get_signal_strength_ptr + .asFunction<_dart_radio_get_signal_strength>(); + + /// @brief Starts scanning radio signals, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_INVALID_STATE Invalid radio state + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @pre The radio state must be set to #RADIO_STATE_READY or #RADIO_STATE_PLAYING. + /// @post The radio state will be #RADIO_STATE_SCANNING during a search. After the scan is completed, the radio state will be set back to the state from before the function call(#RADIO_STATE_READY or #RADIO_STATE_PLAYING). + /// @post It invokes radio_scan_updated_cb() when the scan information updates. + /// @post It invokes radio_scan_completed_cb() when the scan completes, if you set a callback with radio_set_scan_completed_cb(). + /// @see radio_scan_stop() + /// @see radio_set_scan_completed_cb() + /// @see radio_scan_completed_cb() + int radio_scan_start( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _radio_scan_start( + radio, + callback, + user_data, + ); + } + + late final _radio_scan_start_ptr = + _lookup>('radio_scan_start'); + late final _dart_radio_scan_start _radio_scan_start = + _radio_scan_start_ptr.asFunction<_dart_radio_scan_start>(); + + /// @brief Stops scanning radio signals, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid state + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_INVALID_STATE Invalid radio state + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @pre The radio state must be set to #RADIO_STATE_SCANNING by calling radio_scan_start(). + /// @post It invokes radio_scan_stopped_cb() when the scan stops. + /// @post After the scan stopped, the radio state will be set back to the state from before the radio_scan_start() function call(#RADIO_STATE_READY or #RADIO_STATE_PLAYING). + /// @see radio_scan_start() + int radio_scan_stop( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _radio_scan_stop( + radio, + callback, + user_data, + ); + } + + late final _radio_scan_stop_ptr = + _lookup>('radio_scan_stop'); + late final _dart_radio_scan_stop _radio_scan_stop = + _radio_scan_stop_ptr.asFunction<_dart_radio_scan_stop>(); + + /// @brief Sets the radio's mute status. + /// @details If the mute status is @c true, no sounds will be played. If @c false, sounds will be played. Until this function is called, by default the radio is not muted. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @param[in] muted The new mute status: (@c true = mute, @c false = not muted) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @see radio_is_muted() + int radio_set_mute( + ffi.Pointer radio, + bool muted, + ) { + return _radio_set_mute( + radio, + muted ? 1 : 0, + ); + } + + late final _radio_set_mute_ptr = + _lookup>('radio_set_mute'); + late final _dart_radio_set_mute _radio_set_mute = + _radio_set_mute_ptr.asFunction<_dart_radio_set_mute>(); + + /// @brief Gets the radio's mute status. + /// @details If the mute status is @c true, no sounds are played. If @c false, sounds are played. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @param[out] muted The current mute status: (@c true = mute, @c false = not muted) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @see radio_set_mute() + int radio_is_muted( + ffi.Pointer radio, + ffi.Pointer muted, + ) { + return _radio_is_muted( + radio, + muted, + ); + } + + late final _radio_is_muted_ptr = + _lookup>('radio_is_muted'); + late final _dart_radio_is_muted _radio_is_muted = + _radio_is_muted_ptr.asFunction<_dart_radio_is_muted>(); + + /// @brief Sets a callback function to be invoked when the scan finishes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @post radio_scan_completed_cb() will be invoked. + /// @see radio_unset_scan_completed_cb() + /// @see radio_scan_completed_cb() + int radio_set_scan_completed_cb( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _radio_set_scan_completed_cb( + radio, + callback, + user_data, + ); + } + + late final _radio_set_scan_completed_cb_ptr = + _lookup>( + 'radio_set_scan_completed_cb'); + late final _dart_radio_set_scan_completed_cb _radio_set_scan_completed_cb = + _radio_set_scan_completed_cb_ptr + .asFunction<_dart_radio_set_scan_completed_cb>(); + + /// @brief Unsets the scan completed callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @see radio_set_scan_completed_cb() + int radio_unset_scan_completed_cb( + ffi.Pointer radio, + ) { + return _radio_unset_scan_completed_cb( + radio, + ); + } + + late final _radio_unset_scan_completed_cb_ptr = + _lookup>( + 'radio_unset_scan_completed_cb'); + late final _dart_radio_unset_scan_completed_cb + _radio_unset_scan_completed_cb = _radio_unset_scan_completed_cb_ptr + .asFunction<_dart_radio_unset_scan_completed_cb>(); + + /// @brief Sets a callback function to be invoked when the radio is interrupted. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @post radio_interrupted_cb() will be invoked. + /// @see radio_unset_interrupted_cb() + /// @see #radio_interrupted_code_e + /// @see radio_interrupted_cb() + int radio_set_interrupted_cb( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _radio_set_interrupted_cb( + radio, + callback, + user_data, + ); + } + + late final _radio_set_interrupted_cb_ptr = + _lookup>( + 'radio_set_interrupted_cb'); + late final _dart_radio_set_interrupted_cb _radio_set_interrupted_cb = + _radio_set_interrupted_cb_ptr + .asFunction<_dart_radio_set_interrupted_cb>(); + + /// @brief Unsets the interrupted callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] radio The handle to radio + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @see radio_set_interrupted_cb() + int radio_unset_interrupted_cb( + ffi.Pointer radio, + ) { + return _radio_unset_interrupted_cb( + radio, + ); + } + + late final _radio_unset_interrupted_cb_ptr = + _lookup>( + 'radio_unset_interrupted_cb'); + late final _dart_radio_unset_interrupted_cb _radio_unset_interrupted_cb = + _radio_unset_interrupted_cb_ptr + .asFunction<_dart_radio_unset_interrupted_cb>(); + + /// @brief Gets the min, max frequency of the region. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] radio The handle to radio + /// @param[out] min_freq The min frequency [87500 ~ 108000] (kHz) + /// @param[out] max_freq The max frequency [87500 ~ 108000] (kHz) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + int radio_get_frequency_range( + ffi.Pointer radio, + ffi.Pointer min_freq, + ffi.Pointer max_freq, + ) { + return _radio_get_frequency_range( + radio, + min_freq, + max_freq, + ); + } + + late final _radio_get_frequency_range_ptr = + _lookup>( + 'radio_get_frequency_range'); + late final _dart_radio_get_frequency_range _radio_get_frequency_range = + _radio_get_frequency_range_ptr + .asFunction<_dart_radio_get_frequency_range>(); + + /// @brief Gets channel spacing. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] radio The handle to radio + /// @param[out] channel_spacing The channel spacing value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + int radio_get_channel_spacing( + ffi.Pointer radio, + ffi.Pointer channel_spacing, + ) { + return _radio_get_channel_spacing( + radio, + channel_spacing, + ); + } + + late final _radio_get_channel_spacing_ptr = + _lookup>( + 'radio_get_channel_spacing'); + late final _dart_radio_get_channel_spacing _radio_get_channel_spacing = + _radio_get_channel_spacing_ptr + .asFunction<_dart_radio_get_channel_spacing>(); + + /// @brief Sets the radio's volume. + /// @details Setting this volume adjusts the radio's instance volume, not the system volume. + /// The valid range is from 0 to 1.0, inclusive (1.0 = 100%). Default value is 1.0. + /// To change system volume, use the @ref CAPI_MEDIA_SOUND_MANAGER_MODULE API. + /// Finally, it does not support to set other value into each channel currently. + /// @since_tizen 3.0 + /// @param[in] radio The handle to radio + /// @param[in] volume The volume to set [0.0 ~ 1.0](1.0 = 100%) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @see radio_get_volume() + int radio_set_volume( + ffi.Pointer radio, + double volume, + ) { + return _radio_set_volume( + radio, + volume, + ); + } + + late final _radio_set_volume_ptr = + _lookup>('radio_set_volume'); + late final _dart_radio_set_volume _radio_set_volume = + _radio_set_volume_ptr.asFunction<_dart_radio_set_volume>(); + + /// @brief Gets the radio's current volume. + /// @details The range of @a volume is from @c 0 to @c 1.0, inclusive (1.0 = 100%). + /// This function gets the radio volume, not the system volume. + /// To get the system volume, use the @ref CAPI_MEDIA_SOUND_MANAGER_MODULE API. + /// @since_tizen 3.0 + /// @param[in] radio The handle to radio + /// @param[out] volume The current volume [0.0 ~ 1.0](1.0 = 100%) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RADIO_ERROR_NONE Successful + /// @retval #RADIO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RADIO_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RADIO_ERROR_NOT_SUPPORTED Not supported + /// @see radio_set_volume() + int radio_get_volume( + ffi.Pointer radio, + ffi.Pointer volume, + ) { + return _radio_get_volume( + radio, + volume, + ); + } + + late final _radio_get_volume_ptr = + _lookup>('radio_get_volume'); + late final _dart_radio_get_volume _radio_get_volume = + _radio_get_volume_ptr.asFunction<_dart_radio_get_volume>(); + + /// @brief Creates a recorder handle to record a video. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a recorder using recorder_destroy(). \n + /// The @a camera handle also could be used for capturing images. \n + /// If the camera state was #CAMERA_STATE_CREATED, the preview format will be changed to the recommended preview format for recording. + /// @remarks The created recorder state will be different according to camera state : \n + /// #CAMERA_STATE_CREATED -> #RECORDER_STATE_CREATED\n + /// #CAMERA_STATE_PREVIEW -> #RECORDER_STATE_READY\n + /// #CAMERA_STATE_CAPTURED -> #RECORDER_STATE_READY + /// @remarks The privilege %http://tizen.org/privilege/recorder is not required since 4.0,\n + /// but it is required in all earlier versions. + /// @remarks Since 4.0, It's related to the following feature: %http://tizen.org/feature/media.video_recording \n + /// instead of using %http://tizen.org/feature/microphone + /// @param[in] camera The handle to the camera + /// @param[out] recorder A handle to the recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #RECORDER_ERROR_SOUND_POLICY Sound policy error + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @see camera_create() + /// @see camera_stop_preview() + /// @see recorder_destroy() + int recorder_create_videorecorder( + ffi.Pointer camera, + ffi.Pointer> recorder, + ) { + return _recorder_create_videorecorder( + camera, + recorder, + ); + } + + late final _recorder_create_videorecorder_ptr = + _lookup>( + 'recorder_create_videorecorder'); + late final _dart_recorder_create_videorecorder + _recorder_create_videorecorder = _recorder_create_videorecorder_ptr + .asFunction<_dart_recorder_create_videorecorder>(); + + /// @brief Creates a recorder handle to record an audio. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a recorder using recorder_destroy(). + /// @remarks The privilege %http://tizen.org/privilege/recorder is not required since 4.0,\n + /// but it is required in all earlier versions. + /// @remarks Since 4.0, It's related to the following feature: %http://tizen.org/feature/media.audio_recording \n + /// instead of using %http://tizen.org/feature/microphone + /// @param[out] recorder A handle to the recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #RECORDER_ERROR_SOUND_POLICY Sound policy error + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @post The recorder state will be #RECORDER_STATE_CREATED. + /// @see recorder_destroy() + int recorder_create_audiorecorder( + ffi.Pointer> recorder, + ) { + return _recorder_create_audiorecorder( + recorder, + ); + } + + late final _recorder_create_audiorecorder_ptr = + _lookup>( + 'recorder_create_audiorecorder'); + late final _dart_recorder_create_audiorecorder + _recorder_create_audiorecorder = _recorder_create_audiorecorder_ptr + .asFunction<_dart_recorder_create_audiorecorder>(); + + /// @brief Destroys the recorder handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The video recorder's camera handle is not released by this function. + /// @param[in] recorder The handle to the media recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @pre The recorder state should be #RECORDER_STATE_CREATED. + /// @post The recorder state will be #RECORDER_STATE_NONE. + /// @see camera_destroy() + /// @see recorder_create_videorecorder() + /// @see recorder_create_audiorecorder() + int recorder_destroy( + ffi.Pointer recorder, + ) { + return _recorder_destroy( + recorder, + ); + } + + late final _recorder_destroy_ptr = + _lookup>('recorder_destroy'); + late final _dart_recorder_destroy _recorder_destroy = + _recorder_destroy_ptr.asFunction<_dart_recorder_destroy>(); + + /// @brief Prepares the media recorder for recording. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks Before calling the function, it is required to properly set audio encoder (recorder_set_audio_encoder()), + /// video encoder(recorder_set_video_encoder()) and file format (recorder_set_file_format()). + /// @param[in] recorder The handle to the media recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_SOUND_POLICY Sound policy error + /// @retval #RECORDER_ERROR_RESOURCE_CONFLICT Resource conflict error + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state should be #RECORDER_STATE_CREATED by recorder_create_videorecorder(), recorder_create_audiorecorder() or recorder_unprepare(). + /// @post The recorder state will be #RECORDER_STATE_READY. + /// @post If recorder handle is created by recorder_create_videorecorder(), the camera state will be changed to #CAMERA_STATE_PREVIEW. + /// @see recorder_create_videorecorder() + /// @see recorder_create_audiorecorder() + /// @see recorder_unprepare() + /// @see recorder_set_audio_encoder() + /// @see recorder_set_video_encoder() + /// @see recorder_set_file_format() + int recorder_prepare( + ffi.Pointer recorder, + ) { + return _recorder_prepare( + recorder, + ); + } + + late final _recorder_prepare_ptr = + _lookup>('recorder_prepare'); + late final _dart_recorder_prepare _recorder_prepare = + _recorder_prepare_ptr.asFunction<_dart_recorder_prepare>(); + + /// @brief Resets the media recorder. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state should be #RECORDER_STATE_READY set by recorder_prepare(), recorder_cancel() or recorder_commit(). + /// @post The recorder state will be #RECORDER_STATE_CREATED. + /// @post If the recorder handle is created by recorder_create_videorecorder(), camera state will be changed to #CAMERA_STATE_CREATED. + /// @see recorder_prepare() + /// @see recorder_cancel() + /// @see recorder_commit() + int recorder_unprepare( + ffi.Pointer recorder, + ) { + return _recorder_unprepare( + recorder, + ); + } + + late final _recorder_unprepare_ptr = + _lookup>('recorder_unprepare'); + late final _dart_recorder_unprepare _recorder_unprepare = + _recorder_unprepare_ptr.asFunction<_dart_recorder_unprepare>(); + + /// @brief Starts the recording. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks If file path has been set to an existing file, this file is removed automatically and updated by new one. \n + /// In the video recorder, some preview format does not support record mode. It will return #RECORDER_ERROR_INVALID_OPERATION error. \n + /// You should use default preview format or #CAMERA_PIXEL_FORMAT_NV12 in the record mode. \n + /// When you want to record audio or video file, you need to add privilege according to rules below additionally. \n + /// If you want to save contents to internal storage, you should add mediastorage privilege. \n + /// If you want to save contents to external storage, you should add externalstorage privilege. \n + /// The filename should be set before this function is invoked. + /// @param[in] recorder The handle to the media recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_READY by recorder_prepare() or #RECORDER_STATE_PAUSED by recorder_pause(). \n + /// The filename should be set by recorder_set_filename(). + /// @post The recorder state will be #RECORDER_STATE_RECORDING. + /// @see recorder_pause() + /// @see recorder_commit() + /// @see recorder_cancel() + /// @see recorder_set_audio_encoder() + /// @see recorder_set_filename() + /// @see recorder_set_file_format() + /// @see recorder_recording_status_cb() + /// @see recorder_set_filename() + int recorder_start( + ffi.Pointer recorder, + ) { + return _recorder_start( + recorder, + ); + } + + late final _recorder_start_ptr = + _lookup>('recorder_start'); + late final _dart_recorder_start _recorder_start = + _recorder_start_ptr.asFunction<_dart_recorder_start>(); + + /// @brief Pauses the recording. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks Recording can be resumed with recorder_start(). + /// @param[in] recorder The handle to the media recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_RECORDING. + /// @post The recorder state will be #RECORDER_STATE_PAUSED. + /// @see recorder_pause() + /// @see recorder_commit() + /// @see recorder_cancel() + int recorder_pause( + ffi.Pointer recorder, + ) { + return _recorder_pause( + recorder, + ); + } + + late final _recorder_pause_ptr = + _lookup>('recorder_pause'); + late final _dart_recorder_pause _recorder_pause = + _recorder_pause_ptr.asFunction<_dart_recorder_pause>(); + + /// @brief Stops recording and saves the result. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks When you want to record audio or video file, you need to add privilege according to rules below additionally. \n + /// If you want to save contents to internal storage, you should add mediastorage privilege. \n + /// If you want to save contents to external storage, you should add externalstorage privilege. + /// @param[in] recorder The handle to the media recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_RECORDING set by recorder_start() or #RECORDER_STATE_PAUSED by recorder_pause(). + /// @post The recorder state will be #RECORDER_STATE_READY. + /// @see recorder_pause() + /// @see recorder_cancel() + /// @see recorder_set_filename() + /// @see recorder_start() + int recorder_commit( + ffi.Pointer recorder, + ) { + return _recorder_commit( + recorder, + ); + } + + late final _recorder_commit_ptr = + _lookup>('recorder_commit'); + late final _dart_recorder_commit _recorder_commit = + _recorder_commit_ptr.asFunction<_dart_recorder_commit>(); + + /// @brief Cancels the recording. + /// @details The recording data is discarded and not written in the recording file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks When you want to record audio or video file, you need to add privilege according to rules below additionally. \n + /// If you want to save contents to internal storage, you should add mediastorage privilege. \n + /// If you want to save contents to external storage, you should add externalstorage privilege. + /// @param[in] recorder The handle to the media recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_RECORDING set by recorder_start() or #RECORDER_STATE_PAUSED by recorder_pause(). + /// @post The recorder state will be #RECORDER_STATE_READY. + /// @see recorder_pause() + /// @see recorder_commit() + /// @see recorder_cancel() + /// @see recorder_start() + int recorder_cancel( + ffi.Pointer recorder, + ) { + return _recorder_cancel( + recorder, + ); + } + + late final _recorder_cancel_ptr = + _lookup>('recorder_cancel'); + late final _dart_recorder_cancel _recorder_cancel = + _recorder_cancel_ptr.asFunction<_dart_recorder_cancel>(); + + /// @brief Gets the recorder's current state. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[out] state The current state of the recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + int recorder_get_state( + ffi.Pointer recorder, + ffi.Pointer state, + ) { + return _recorder_get_state( + recorder, + state, + ); + } + + late final _recorder_get_state_ptr = + _lookup>('recorder_get_state'); + late final _dart_recorder_get_state _recorder_get_state = + _recorder_get_state_ptr.asFunction<_dart_recorder_get_state>(); + + /// @brief Gets the peak audio input level that was sampled since the last call to this function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks @c 0 dB indicates maximum input level, @c -300 dB indicates minimum input level. + /// @param[in] recorder The handle to the media recorder + /// @param[out] dB The audio input level in dB + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_RECORDING or #RECORDER_STATE_PAUSED. + int recorder_get_audio_level( + ffi.Pointer recorder, + ffi.Pointer dB, + ) { + return _recorder_get_audio_level( + recorder, + dB, + ); + } + + late final _recorder_get_audio_level_ptr = + _lookup>( + 'recorder_get_audio_level'); + late final _dart_recorder_get_audio_level _recorder_get_audio_level = + _recorder_get_audio_level_ptr + .asFunction<_dart_recorder_get_audio_level>(); + + /// @brief Sets the file path to record. + /// @details This function sets file path which defines where newly recorded data should be stored. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If the same file already exists in the file system, then old file will be overwritten. + /// @param[in] recorder The handle to the media recorder + /// @param[in] path The recording file path + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_CREATED or #RECORDER_STATE_READY. + /// @see recorder_get_filename() + int recorder_set_filename( + ffi.Pointer recorder, + ffi.Pointer path, + ) { + return _recorder_set_filename( + recorder, + path, + ); + } + + late final _recorder_set_filename_ptr = + _lookup>( + 'recorder_set_filename'); + late final _dart_recorder_set_filename _recorder_set_filename = + _recorder_set_filename_ptr.asFunction<_dart_recorder_set_filename>(); + + /// @brief Gets the file path to record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a path using free(). + /// @param[in] recorder The handle to the media recorder + /// @param[out] path The recording file path + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_set_filename() + int recorder_get_filename( + ffi.Pointer recorder, + ffi.Pointer> path, + ) { + return _recorder_get_filename( + recorder, + path, + ); + } + + late final _recorder_get_filename_ptr = + _lookup>( + 'recorder_get_filename'); + late final _dart_recorder_get_filename _recorder_get_filename = + _recorder_get_filename_ptr.asFunction<_dart_recorder_get_filename>(); + + /// @brief Sets the file format for recording media stream. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks Since 2.3.1, it could be returned #RECORDER_ERROR_INVALID_OPERATION \n + /// when it's audio recorder and its state is #RECORDER_STATE_READY \n + /// because of checking codec compatibility with current encoder. + /// @param[in] recorder The handle to the media recorder + /// @param[in] format The media file format + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation (Since 2.3.1) + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_CREATED or #RECORDER_STATE_READY (for video recorder only).\n + /// Since 2.3.1, this API also works for audio recorder when its state is #RECORDER_STATE_READY. + /// @see recorder_get_file_format() + /// @see recorder_foreach_supported_file_format() + int recorder_set_file_format( + ffi.Pointer recorder, + int format, + ) { + return _recorder_set_file_format( + recorder, + format, + ); + } + + late final _recorder_set_file_format_ptr = + _lookup>( + 'recorder_set_file_format'); + late final _dart_recorder_set_file_format _recorder_set_file_format = + _recorder_set_file_format_ptr + .asFunction<_dart_recorder_set_file_format>(); + + /// @brief Gets the file format for recording media stream. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[out] format The media file format + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_set_file_format() + /// @see recorder_foreach_supported_file_format() + int recorder_get_file_format( + ffi.Pointer recorder, + ffi.Pointer format, + ) { + return _recorder_get_file_format( + recorder, + format, + ); + } + + late final _recorder_get_file_format_ptr = + _lookup>( + 'recorder_get_file_format'); + late final _dart_recorder_get_file_format _recorder_get_file_format = + _recorder_get_file_format_ptr + .asFunction<_dart_recorder_get_file_format>(); + + /// @brief Sets the recorder's sound manager stream information. + /// @since_tizen 3.0 + /// @remarks You can set sound stream information including audio routing. + /// For more details, please refer to @ref CAPI_MEDIA_SOUND_MANAGER_MODULE + /// @param[in] recorder The handle to the media recorder + /// @param[in] stream_info The sound manager info + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The recorder state must be #RECORDER_STATE_CREATED or #RECORDER_STATE_READY + /// @see #sound_stream_info_h + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + int recorder_set_sound_stream_info( + ffi.Pointer recorder, + ffi.Pointer stream_info, + ) { + return _recorder_set_sound_stream_info( + recorder, + stream_info, + ); + } + + late final _recorder_set_sound_stream_info_ptr = + _lookup>( + 'recorder_set_sound_stream_info'); + late final _dart_recorder_set_sound_stream_info + _recorder_set_sound_stream_info = _recorder_set_sound_stream_info_ptr + .asFunction<_dart_recorder_set_sound_stream_info>(); + + /// @brief Retrieves all supported file formats by invoking a specific callback for each supported file format. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[in] callback The iteration callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post recorder_supported_file_format_cb() will be invoked. + /// @see recorder_get_file_format() + /// @see recorder_set_file_format() + /// @see recorder_supported_file_format_cb() + int recorder_foreach_supported_file_format( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _recorder_foreach_supported_file_format( + recorder, + callback, + user_data, + ); + } + + late final _recorder_foreach_supported_file_format_ptr = + _lookup>( + 'recorder_foreach_supported_file_format'); + late final _dart_recorder_foreach_supported_file_format + _recorder_foreach_supported_file_format = + _recorder_foreach_supported_file_format_ptr + .asFunction<_dart_recorder_foreach_supported_file_format>(); + + /// @brief Sets the audio codec for encoding an audio stream. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You can get available audio encoders by using recorder_foreach_supported_audio_encoder(). \n + /// If set to #RECORDER_AUDIO_CODEC_DISABLE, the audio track is not created in recording files.\n + /// Since 2.3.1, it could be returned #RECORDER_ERROR_INVALID_OPERATION \n + /// when it's audio recorder and its state is #RECORDER_STATE_READY \n + /// because of checking codec compatibility with current file format. + /// @param[in] recorder The handle to the media recorder + /// @param[in] codec The audio codec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation (Since 2.3.1) + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_CREATED or #RECORDER_STATE_READY. + /// @see recorder_get_audio_encoder() + /// @see recorder_foreach_supported_audio_encoder() + int recorder_set_audio_encoder( + ffi.Pointer recorder, + int codec, + ) { + return _recorder_set_audio_encoder( + recorder, + codec, + ); + } + + late final _recorder_set_audio_encoder_ptr = + _lookup>( + 'recorder_set_audio_encoder'); + late final _dart_recorder_set_audio_encoder _recorder_set_audio_encoder = + _recorder_set_audio_encoder_ptr + .asFunction<_dart_recorder_set_audio_encoder>(); + + /// @brief Gets the audio codec for encoding an audio stream. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[out] codec The audio codec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_set_audio_encoder() + /// @see recorder_foreach_supported_audio_encoder() + int recorder_get_audio_encoder( + ffi.Pointer recorder, + ffi.Pointer codec, + ) { + return _recorder_get_audio_encoder( + recorder, + codec, + ); + } + + late final _recorder_get_audio_encoder_ptr = + _lookup>( + 'recorder_get_audio_encoder'); + late final _dart_recorder_get_audio_encoder _recorder_get_audio_encoder = + _recorder_get_audio_encoder_ptr + .asFunction<_dart_recorder_get_audio_encoder>(); + + /// @brief Retrieves all supported audio encoders by invoking a specific callback for each supported audio encoder. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[in] callback The iteration callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post recorder_supported_audio_encoder_cb() will be invoked. + /// @see recorder_set_audio_encoder() + /// @see recorder_get_audio_encoder() + /// @see recorder_supported_audio_encoder_cb() + int recorder_foreach_supported_audio_encoder( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _recorder_foreach_supported_audio_encoder( + recorder, + callback, + user_data, + ); + } + + late final _recorder_foreach_supported_audio_encoder_ptr = + _lookup>( + 'recorder_foreach_supported_audio_encoder'); + late final _dart_recorder_foreach_supported_audio_encoder + _recorder_foreach_supported_audio_encoder = + _recorder_foreach_supported_audio_encoder_ptr + .asFunction<_dart_recorder_foreach_supported_audio_encoder>(); + + /// @brief Sets the resolution of the video recording. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This function should be called before recording (recorder_start()). + /// @param[in] recorder The handle to the media recorder + /// @param[in] width The video width + /// @param[in] height The video height + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_CREATED or #RECORDER_STATE_READY. + /// @see recorder_start() + /// @see recorder_get_video_resolution() + /// @see recorder_foreach_supported_video_resolution() + int recorder_set_video_resolution( + ffi.Pointer recorder, + int width, + int height, + ) { + return _recorder_set_video_resolution( + recorder, + width, + height, + ); + } + + late final _recorder_set_video_resolution_ptr = + _lookup>( + 'recorder_set_video_resolution'); + late final _dart_recorder_set_video_resolution + _recorder_set_video_resolution = _recorder_set_video_resolution_ptr + .asFunction<_dart_recorder_set_video_resolution>(); + + /// @brief Gets the resolution of the video recording. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[out] width The video width + /// @param[out] height The video height + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_set_video_resolution() + /// @see recorder_foreach_supported_video_resolution() + int recorder_get_video_resolution( + ffi.Pointer recorder, + ffi.Pointer width, + ffi.Pointer height, + ) { + return _recorder_get_video_resolution( + recorder, + width, + height, + ); + } + + late final _recorder_get_video_resolution_ptr = + _lookup>( + 'recorder_get_video_resolution'); + late final _dart_recorder_get_video_resolution + _recorder_get_video_resolution = _recorder_get_video_resolution_ptr + .asFunction<_dart_recorder_get_video_resolution>(); + + /// @brief Retrieves all supported video resolutions by invoking callback function once for each supported video resolution. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[in] foreach_cb The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function invokes recorder_supported_video_resolution_cb() repeatedly to retrieve each supported video resolution. + /// @see recorder_set_video_resolution() + /// @see recorder_get_video_resolution() + /// @see recorder_supported_video_resolution_cb() + int recorder_foreach_supported_video_resolution( + ffi.Pointer recorder, + ffi.Pointer> + foreach_cb, + ffi.Pointer user_data, + ) { + return _recorder_foreach_supported_video_resolution( + recorder, + foreach_cb, + user_data, + ); + } + + late final _recorder_foreach_supported_video_resolution_ptr = _lookup< + ffi.NativeFunction<_c_recorder_foreach_supported_video_resolution>>( + 'recorder_foreach_supported_video_resolution'); + late final _dart_recorder_foreach_supported_video_resolution + _recorder_foreach_supported_video_resolution = + _recorder_foreach_supported_video_resolution_ptr + .asFunction<_dart_recorder_foreach_supported_video_resolution>(); + + /// @brief Sets the video codec for encoding video stream. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You can get available video encoders by using recorder_foreach_supported_video_encoder(). + /// @param[in] recorder The handle to the media recorder + /// @param[in] codec The video codec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_CREATED or #RECORDER_STATE_READY. + /// @see recorder_get_video_encoder() + /// @see recorder_foreach_supported_video_encoder() + int recorder_set_video_encoder( + ffi.Pointer recorder, + int codec, + ) { + return _recorder_set_video_encoder( + recorder, + codec, + ); + } + + late final _recorder_set_video_encoder_ptr = + _lookup>( + 'recorder_set_video_encoder'); + late final _dart_recorder_set_video_encoder _recorder_set_video_encoder = + _recorder_set_video_encoder_ptr + .asFunction<_dart_recorder_set_video_encoder>(); + + /// @brief Gets the video codec for encoding video stream. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[out] codec The video codec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_set_video_encoder() + /// @see recorder_foreach_supported_video_encoder() + int recorder_get_video_encoder( + ffi.Pointer recorder, + ffi.Pointer codec, + ) { + return _recorder_get_video_encoder( + recorder, + codec, + ); + } + + late final _recorder_get_video_encoder_ptr = + _lookup>( + 'recorder_get_video_encoder'); + late final _dart_recorder_get_video_encoder _recorder_get_video_encoder = + _recorder_get_video_encoder_ptr + .asFunction<_dart_recorder_get_video_encoder>(); + + /// @brief Retrieves all supported video encoders by invoking a specific callback for each supported video encoder. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[in] callback The iteration callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post recorder_supported_video_encoder_cb() will be invoked. + /// @see recorder_set_video_encoder() + /// @see recorder_get_video_encoder() + /// @see recorder_supported_video_encoder_cb() + int recorder_foreach_supported_video_encoder( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _recorder_foreach_supported_video_encoder( + recorder, + callback, + user_data, + ); + } + + late final _recorder_foreach_supported_video_encoder_ptr = + _lookup>( + 'recorder_foreach_supported_video_encoder'); + late final _dart_recorder_foreach_supported_video_encoder + _recorder_foreach_supported_video_encoder = + _recorder_foreach_supported_video_encoder_ptr + .asFunction<_dart_recorder_foreach_supported_video_encoder>(); + + /// @brief Registers the callback function that will be invoked when the recorder state changes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[in] callback The function pointer of user callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post recorder_state_changed_cb() will be invoked. + /// @see recorder_unset_state_changed_cb() + /// @see recorder_state_changed_cb() + int recorder_set_state_changed_cb( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _recorder_set_state_changed_cb( + recorder, + callback, + user_data, + ); + } + + late final _recorder_set_state_changed_cb_ptr = + _lookup>( + 'recorder_set_state_changed_cb'); + late final _dart_recorder_set_state_changed_cb + _recorder_set_state_changed_cb = _recorder_set_state_changed_cb_ptr + .asFunction<_dart_recorder_set_state_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_set_state_changed_cb() + int recorder_unset_state_changed_cb( + ffi.Pointer recorder, + ) { + return _recorder_unset_state_changed_cb( + recorder, + ); + } + + late final _recorder_unset_state_changed_cb_ptr = + _lookup>( + 'recorder_unset_state_changed_cb'); + late final _dart_recorder_unset_state_changed_cb + _recorder_unset_state_changed_cb = _recorder_unset_state_changed_cb_ptr + .asFunction<_dart_recorder_unset_state_changed_cb>(); + + /// @brief Registers a callback function to be called when the media recorder is interrupted according to a policy. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_unset_interrupted_cb() + /// @see recorder_interrupted_cb() + int recorder_set_interrupted_cb( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _recorder_set_interrupted_cb( + recorder, + callback, + user_data, + ); + } + + late final _recorder_set_interrupted_cb_ptr = + _lookup>( + 'recorder_set_interrupted_cb'); + late final _dart_recorder_set_interrupted_cb _recorder_set_interrupted_cb = + _recorder_set_interrupted_cb_ptr + .asFunction<_dart_recorder_set_interrupted_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_set_interrupted_cb() + int recorder_unset_interrupted_cb( + ffi.Pointer recorder, + ) { + return _recorder_unset_interrupted_cb( + recorder, + ); + } + + late final _recorder_unset_interrupted_cb_ptr = + _lookup>( + 'recorder_unset_interrupted_cb'); + late final _dart_recorder_unset_interrupted_cb + _recorder_unset_interrupted_cb = _recorder_unset_interrupted_cb_ptr + .asFunction<_dart_recorder_unset_interrupted_cb>(); + + /// @brief Registers a callback function to be called when the media recorder interrupt is started according to a policy. + /// @since_tizen 4.0 + /// @param[in] recorder The handle to the media recorder + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see recorder_unset_interrupt_started_cb() + /// @see recorder_interrupt_started_cb() + int recorder_set_interrupt_started_cb( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _recorder_set_interrupt_started_cb( + recorder, + callback, + user_data, + ); + } + + late final _recorder_set_interrupt_started_cb_ptr = + _lookup>( + 'recorder_set_interrupt_started_cb'); + late final _dart_recorder_set_interrupt_started_cb + _recorder_set_interrupt_started_cb = + _recorder_set_interrupt_started_cb_ptr + .asFunction<_dart_recorder_set_interrupt_started_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen 4.0 + /// @param[in] recorder The handle to the media recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see recorder_set_interrupt_started_cb() + int recorder_unset_interrupt_started_cb( + ffi.Pointer recorder, + ) { + return _recorder_unset_interrupt_started_cb( + recorder, + ); + } + + late final _recorder_unset_interrupt_started_cb_ptr = + _lookup>( + 'recorder_unset_interrupt_started_cb'); + late final _dart_recorder_unset_interrupt_started_cb + _recorder_unset_interrupt_started_cb = + _recorder_unset_interrupt_started_cb_ptr + .asFunction<_dart_recorder_unset_interrupt_started_cb>(); + + /// @brief Registers a callback function to be called when audio stream data is being delivered. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This callback function holds the same buffer that will be recorded. \n + /// Therefore if an user changes the buffer, the result file will have the buffer. \n + /// @remarks The callback is called via internal thread of Frameworks. Therefore do not invoke UI API, recorder_unprepare(), recorder_commit() and recorder_cancel() in callback.\n + /// This callback function to be called in #RECORDER_STATE_RECORDING and #RECORDER_STATE_PAUSED state. + /// + /// @param[in] recorder The handle to the recorder + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state should be #RECORDER_STATE_READY or #RECORDER_STATE_CREATED. + /// @see recorder_unset_audio_stream_cb() + /// @see recorder_audio_stream_cb() + int recorder_set_audio_stream_cb( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _recorder_set_audio_stream_cb( + recorder, + callback, + user_data, + ); + } + + late final _recorder_set_audio_stream_cb_ptr = + _lookup>( + 'recorder_set_audio_stream_cb'); + late final _dart_recorder_set_audio_stream_cb _recorder_set_audio_stream_cb = + _recorder_set_audio_stream_cb_ptr + .asFunction<_dart_recorder_set_audio_stream_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_set_audio_stream_cb() + int recorder_unset_audio_stream_cb( + ffi.Pointer recorder, + ) { + return _recorder_unset_audio_stream_cb( + recorder, + ); + } + + late final _recorder_unset_audio_stream_cb_ptr = + _lookup>( + 'recorder_unset_audio_stream_cb'); + late final _dart_recorder_unset_audio_stream_cb + _recorder_unset_audio_stream_cb = _recorder_unset_audio_stream_cb_ptr + .asFunction<_dart_recorder_unset_audio_stream_cb>(); + + /// @brief Registers a callback function to be called when muxed stream data is delivered. + /// @since_tizen 4.0 + /// @remarks This callback receives the data that will be recorded, \n + /// but any changes to this data will not affect the recorded file. + /// @param[in] recorder The handle to the recorder + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @pre The recorder state should be #RECORDER_STATE_READY or #RECORDER_STATE_CREATED. + /// @see recorder_unset_muxed_stream_cb() + /// @see recorder_muxed_stream_cb() + int recorder_set_muxed_stream_cb( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _recorder_set_muxed_stream_cb( + recorder, + callback, + user_data, + ); + } + + late final _recorder_set_muxed_stream_cb_ptr = + _lookup>( + 'recorder_set_muxed_stream_cb'); + late final _dart_recorder_set_muxed_stream_cb _recorder_set_muxed_stream_cb = + _recorder_set_muxed_stream_cb_ptr + .asFunction<_dart_recorder_set_muxed_stream_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen 4.0 + /// @param[in] recorder The handle to the media recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @pre The recorder state should be #RECORDER_STATE_READY or #RECORDER_STATE_CREATED. + /// @see recorder_set_muxed_stream_cb() + int recorder_unset_muxed_stream_cb( + ffi.Pointer recorder, + ) { + return _recorder_unset_muxed_stream_cb( + recorder, + ); + } + + late final _recorder_unset_muxed_stream_cb_ptr = + _lookup>( + 'recorder_unset_muxed_stream_cb'); + late final _dart_recorder_unset_muxed_stream_cb + _recorder_unset_muxed_stream_cb = _recorder_unset_muxed_stream_cb_ptr + .asFunction<_dart_recorder_unset_muxed_stream_cb>(); + + /// @brief Registers a callback function to be invoked when the recording information changes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[in] callback The function pointer of user callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post recorder_recording_status_cb() will be invoked. + /// @see recorder_unset_recording_status_cb() + /// @see recorder_recording_status_cb() + int recorder_set_recording_status_cb( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _recorder_set_recording_status_cb( + recorder, + callback, + user_data, + ); + } + + late final _recorder_set_recording_status_cb_ptr = + _lookup>( + 'recorder_set_recording_status_cb'); + late final _dart_recorder_set_recording_status_cb + _recorder_set_recording_status_cb = _recorder_set_recording_status_cb_ptr + .asFunction<_dart_recorder_set_recording_status_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_set_recording_status_cb() + int recorder_unset_recording_status_cb( + ffi.Pointer recorder, + ) { + return _recorder_unset_recording_status_cb( + recorder, + ); + } + + late final _recorder_unset_recording_status_cb_ptr = + _lookup>( + 'recorder_unset_recording_status_cb'); + late final _dart_recorder_unset_recording_status_cb + _recorder_unset_recording_status_cb = + _recorder_unset_recording_status_cb_ptr + .asFunction<_dart_recorder_unset_recording_status_cb>(); + + /// @brief Registers the callback function to be run when reached the recording limit. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to media recorder + /// @param[in] callback The function pointer of user callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post recorder_recording_limit_reached_cb() will be invoked. + /// @see recorder_unset_recording_limit_reached_cb() + /// @see recorder_attr_set_size_limit() + /// @see recorder_attr_set_time_limit() + /// @see recorder_recording_limit_reached_cb() + int recorder_set_recording_limit_reached_cb( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _recorder_set_recording_limit_reached_cb( + recorder, + callback, + user_data, + ); + } + + late final _recorder_set_recording_limit_reached_cb_ptr = + _lookup>( + 'recorder_set_recording_limit_reached_cb'); + late final _dart_recorder_set_recording_limit_reached_cb + _recorder_set_recording_limit_reached_cb = + _recorder_set_recording_limit_reached_cb_ptr + .asFunction<_dart_recorder_set_recording_limit_reached_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_set_recording_limit_reached_cb() + int recorder_unset_recording_limit_reached_cb( + ffi.Pointer recorder, + ) { + return _recorder_unset_recording_limit_reached_cb( + recorder, + ); + } + + late final _recorder_unset_recording_limit_reached_cb_ptr = + _lookup>( + 'recorder_unset_recording_limit_reached_cb'); + late final _dart_recorder_unset_recording_limit_reached_cb + _recorder_unset_recording_limit_reached_cb = + _recorder_unset_recording_limit_reached_cb_ptr + .asFunction<_dart_recorder_unset_recording_limit_reached_cb>(); + + /// @brief Registers a callback function to be called when an asynchronous operation error occurred. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This callback informs critical error situation.\n + /// When this callback is invoked, user should release the resource and terminate the application. \n + /// These error codes will occur. \n + /// #RECORDER_ERROR_DEVICE \n + /// #RECORDER_ERROR_INVALID_OPERATION \n + /// #RECORDER_ERROR_OUT_OF_MEMORY + /// @param[in] recorder The handle to the recorder + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @post This function will invoke recorder_error_cb() when an asynchronous operation error occur. + /// @see recorder_unset_error_cb() + /// @see recorder_error_cb() + int recorder_set_error_cb( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _recorder_set_error_cb( + recorder, + callback, + user_data, + ); + } + + late final _recorder_set_error_cb_ptr = + _lookup>( + 'recorder_set_error_cb'); + late final _dart_recorder_set_error_cb _recorder_set_error_cb = + _recorder_set_error_cb_ptr.asFunction<_dart_recorder_set_error_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the recorder + /// @return @c on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_set_error_cb() + int recorder_unset_error_cb( + ffi.Pointer recorder, + ) { + return _recorder_unset_error_cb( + recorder, + ); + } + + late final _recorder_unset_error_cb_ptr = + _lookup>( + 'recorder_unset_error_cb'); + late final _dart_recorder_unset_error_cb _recorder_unset_error_cb = + _recorder_unset_error_cb_ptr.asFunction<_dart_recorder_unset_error_cb>(); + + /// @brief Gets the state of recorder device. + /// @since_tizen 3.0 + /// @param[in] type The recorder type + /// @param[out] state The current state of the device + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + int recorder_get_device_state( + int type, + ffi.Pointer state, + ) { + return _recorder_get_device_state( + type, + state, + ); + } + + late final _recorder_get_device_state_ptr = + _lookup>( + 'recorder_get_device_state'); + late final _dart_recorder_get_device_state _recorder_get_device_state = + _recorder_get_device_state_ptr + .asFunction<_dart_recorder_get_device_state>(); + + /// @brief Registers a callback function to be called when the recorder device state changes. + /// @since_tizen 3.0 + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] cb_id The id of the registered callback + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RECORDER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @post This function will invoke recorder_device_state_changed_cb() when the recorder device's state changes. + /// @see recorder_remove_device_state_changed_cb() + /// @see recorder_device_state_changed_cb() + int recorder_add_device_state_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer cb_id, + ) { + return _recorder_add_device_state_changed_cb( + callback, + user_data, + cb_id, + ); + } + + late final _recorder_add_device_state_changed_cb_ptr = + _lookup>( + 'recorder_add_device_state_changed_cb'); + late final _dart_recorder_add_device_state_changed_cb + _recorder_add_device_state_changed_cb = + _recorder_add_device_state_changed_cb_ptr + .asFunction<_dart_recorder_add_device_state_changed_cb>(); + + /// @brief Unregisters a callback function. + /// @since_tizen 3.0 + /// @param[in] cb_id The id of the registered callback + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @see recorder_add_device_state_changed_cb() + int recorder_remove_device_state_changed_cb( + int cb_id, + ) { + return _recorder_remove_device_state_changed_cb( + cb_id, + ); + } + + late final _recorder_remove_device_state_changed_cb_ptr = + _lookup>( + 'recorder_remove_device_state_changed_cb'); + late final _dart_recorder_remove_device_state_changed_cb + _recorder_remove_device_state_changed_cb = + _recorder_remove_device_state_changed_cb_ptr + .asFunction<_dart_recorder_remove_device_state_changed_cb>(); + + /// @brief Sets the maximum size of a recording file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks After reaching the limitation, the recording data is discarded and not written in the recording file. + /// @param[in] recorder The handle to the media recorder + /// @param[in] kbyte The maximum size of the recording file(KB) \n + /// @c 0 means unlimited recording size. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_CREATED or #RECORDER_STATE_READY. + /// @see recorder_attr_get_size_limit() + /// @see recorder_attr_set_time_limit() + int recorder_attr_set_size_limit( + ffi.Pointer recorder, + int kbyte, + ) { + return _recorder_attr_set_size_limit( + recorder, + kbyte, + ); + } + + late final _recorder_attr_set_size_limit_ptr = + _lookup>( + 'recorder_attr_set_size_limit'); + late final _dart_recorder_attr_set_size_limit _recorder_attr_set_size_limit = + _recorder_attr_set_size_limit_ptr + .asFunction<_dart_recorder_attr_set_size_limit>(); + + /// @brief Gets the maximum size of a recording file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[out] kbyte The maximum size of recording file (KB) \n + /// @c 0 means unlimited recording size. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_attr_set_size_limit() + /// @see recorder_attr_get_time_limit() + int recorder_attr_get_size_limit( + ffi.Pointer recorder, + ffi.Pointer kbyte, + ) { + return _recorder_attr_get_size_limit( + recorder, + kbyte, + ); + } + + late final _recorder_attr_get_size_limit_ptr = + _lookup>( + 'recorder_attr_get_size_limit'); + late final _dart_recorder_attr_get_size_limit _recorder_attr_get_size_limit = + _recorder_attr_get_size_limit_ptr + .asFunction<_dart_recorder_attr_get_size_limit>(); + + /// @brief Sets the time limit of a recording file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks After reaching the limitation, the recording data is discarded and not written in the recording file. + /// @param[in] recorder The handle to the media recorder + /// @param[in] second The time limit of the recording file (in seconds) \n + /// @c 0 means unlimited recording size. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_CREATED or #RECORDER_STATE_READY. + /// @see recorder_attr_get_time_limit() + /// @see recorder_attr_set_size_limit() + int recorder_attr_set_time_limit( + ffi.Pointer recorder, + int second, + ) { + return _recorder_attr_set_time_limit( + recorder, + second, + ); + } + + late final _recorder_attr_set_time_limit_ptr = + _lookup>( + 'recorder_attr_set_time_limit'); + late final _dart_recorder_attr_set_time_limit _recorder_attr_set_time_limit = + _recorder_attr_set_time_limit_ptr + .asFunction<_dart_recorder_attr_set_time_limit>(); + + /// @brief Gets the time limit of a recording file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[out] second The time limit of the recording file (in seconds) \n + /// @c 0 means unlimited recording time. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_attr_set_time_limit() + /// @see recorder_attr_get_size_limit() + int recorder_attr_get_time_limit( + ffi.Pointer recorder, + ffi.Pointer second, + ) { + return _recorder_attr_get_time_limit( + recorder, + second, + ); + } + + late final _recorder_attr_get_time_limit_ptr = + _lookup>( + 'recorder_attr_get_time_limit'); + late final _dart_recorder_attr_get_time_limit _recorder_attr_get_time_limit = + _recorder_attr_get_time_limit_ptr + .asFunction<_dart_recorder_attr_get_time_limit>(); + + /// @brief Sets the audio device for recording. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[in] device The type of an audio device + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_CREATED or #RECORDER_STATE_READY (for video recorder only).\n + /// Since 2.3.1, this API also works for audio recorder when its state is #RECORDER_STATE_READY. + /// @see recorder_attr_get_audio_device() + int recorder_attr_set_audio_device( + ffi.Pointer recorder, + int device, + ) { + return _recorder_attr_set_audio_device( + recorder, + device, + ); + } + + late final _recorder_attr_set_audio_device_ptr = + _lookup>( + 'recorder_attr_set_audio_device'); + late final _dart_recorder_attr_set_audio_device + _recorder_attr_set_audio_device = _recorder_attr_set_audio_device_ptr + .asFunction<_dart_recorder_attr_set_audio_device>(); + + /// @brief Gets the audio device for recording. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[out] device The type of an audio device + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_attr_set_audio_device() + int recorder_attr_get_audio_device( + ffi.Pointer recorder, + ffi.Pointer device, + ) { + return _recorder_attr_get_audio_device( + recorder, + device, + ); + } + + late final _recorder_attr_get_audio_device_ptr = + _lookup>( + 'recorder_attr_get_audio_device'); + late final _dart_recorder_attr_get_audio_device + _recorder_attr_get_audio_device = _recorder_attr_get_audio_device_ptr + .asFunction<_dart_recorder_attr_get_audio_device>(); + + /// @brief Sets the sampling rate of an audio stream. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[in] samplerate The sample rate in Hertz + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_CREATED or #RECORDER_STATE_READY (for video recorder only).\n + /// Since 2.3.1, this API also works for audio recorder when its state is #RECORDER_STATE_READY. + /// @see recorder_attr_get_audio_samplerate() + int recorder_attr_set_audio_samplerate( + ffi.Pointer recorder, + int samplerate, + ) { + return _recorder_attr_set_audio_samplerate( + recorder, + samplerate, + ); + } + + late final _recorder_attr_set_audio_samplerate_ptr = + _lookup>( + 'recorder_attr_set_audio_samplerate'); + late final _dart_recorder_attr_set_audio_samplerate + _recorder_attr_set_audio_samplerate = + _recorder_attr_set_audio_samplerate_ptr + .asFunction<_dart_recorder_attr_set_audio_samplerate>(); + + /// @brief Gets the sampling rate of an audio stream. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[out] samplerate The sample rate in Hertz + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_attr_set_audio_samplerate() + int recorder_attr_get_audio_samplerate( + ffi.Pointer recorder, + ffi.Pointer samplerate, + ) { + return _recorder_attr_get_audio_samplerate( + recorder, + samplerate, + ); + } + + late final _recorder_attr_get_audio_samplerate_ptr = + _lookup>( + 'recorder_attr_get_audio_samplerate'); + late final _dart_recorder_attr_get_audio_samplerate + _recorder_attr_get_audio_samplerate = + _recorder_attr_get_audio_samplerate_ptr + .asFunction<_dart_recorder_attr_get_audio_samplerate>(); + + /// @brief Sets the bitrate of an audio encoder. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[in] bitrate The bitrate (for mms : 12200[bps], normal : 288000[bps]) + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_CREATED or #RECORDER_STATE_READY. + /// @see recorder_attr_get_audio_encoder_bitrate() + int recorder_attr_set_audio_encoder_bitrate( + ffi.Pointer recorder, + int bitrate, + ) { + return _recorder_attr_set_audio_encoder_bitrate( + recorder, + bitrate, + ); + } + + late final _recorder_attr_set_audio_encoder_bitrate_ptr = + _lookup>( + 'recorder_attr_set_audio_encoder_bitrate'); + late final _dart_recorder_attr_set_audio_encoder_bitrate + _recorder_attr_set_audio_encoder_bitrate = + _recorder_attr_set_audio_encoder_bitrate_ptr + .asFunction<_dart_recorder_attr_set_audio_encoder_bitrate>(); + + /// @brief Sets the bitrate of a video encoder. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[in] bitrate The bitrate in bits per second + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_CREATED or #RECORDER_STATE_READY. + /// @see recorder_attr_get_video_encoder_bitrate() + int recorder_attr_set_video_encoder_bitrate( + ffi.Pointer recorder, + int bitrate, + ) { + return _recorder_attr_set_video_encoder_bitrate( + recorder, + bitrate, + ); + } + + late final _recorder_attr_set_video_encoder_bitrate_ptr = + _lookup>( + 'recorder_attr_set_video_encoder_bitrate'); + late final _dart_recorder_attr_set_video_encoder_bitrate + _recorder_attr_set_video_encoder_bitrate = + _recorder_attr_set_video_encoder_bitrate_ptr + .asFunction<_dart_recorder_attr_set_video_encoder_bitrate>(); + + /// @brief Gets the bitrate of an audio encoder. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[out] bitrate The bitrate in bits per second + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_attr_set_audio_encoder_bitrate() + int recorder_attr_get_audio_encoder_bitrate( + ffi.Pointer recorder, + ffi.Pointer bitrate, + ) { + return _recorder_attr_get_audio_encoder_bitrate( + recorder, + bitrate, + ); + } + + late final _recorder_attr_get_audio_encoder_bitrate_ptr = + _lookup>( + 'recorder_attr_get_audio_encoder_bitrate'); + late final _dart_recorder_attr_get_audio_encoder_bitrate + _recorder_attr_get_audio_encoder_bitrate = + _recorder_attr_get_audio_encoder_bitrate_ptr + .asFunction<_dart_recorder_attr_get_audio_encoder_bitrate>(); + + /// @brief Gets the bitrate of a video encoder. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[out] bitrate The bitrate in bits per second + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_attr_set_audio_encoder_bitrate() + int recorder_attr_get_video_encoder_bitrate( + ffi.Pointer recorder, + ffi.Pointer bitrate, + ) { + return _recorder_attr_get_video_encoder_bitrate( + recorder, + bitrate, + ); + } + + late final _recorder_attr_get_video_encoder_bitrate_ptr = + _lookup>( + 'recorder_attr_get_video_encoder_bitrate'); + late final _dart_recorder_attr_get_video_encoder_bitrate + _recorder_attr_get_video_encoder_bitrate = + _recorder_attr_get_video_encoder_bitrate_ptr + .asFunction<_dart_recorder_attr_get_video_encoder_bitrate>(); + + /// @brief Sets the mute state of a recorder. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[in] enable The mute state + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_attr_is_muted() + int recorder_attr_set_mute( + ffi.Pointer recorder, + bool enable, + ) { + return _recorder_attr_set_mute( + recorder, + enable ? 1 : 0, + ); + } + + late final _recorder_attr_set_mute_ptr = + _lookup>( + 'recorder_attr_set_mute'); + late final _dart_recorder_attr_set_mute _recorder_attr_set_mute = + _recorder_attr_set_mute_ptr.asFunction<_dart_recorder_attr_set_mute>(); + + /// @brief Gets the mute state of a recorder. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @return @c true if the recorder is not recording any sound, + /// otherwise @c false if the recorder is recording + /// @exception #RECORDER_ERROR_NONE Successful + /// @exception #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @exception #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @see recorder_attr_set_mute() + bool recorder_attr_is_muted( + ffi.Pointer recorder, + ) { + return _recorder_attr_is_muted( + recorder, + ) != + 0; + } + + late final _recorder_attr_is_muted_ptr = + _lookup>( + 'recorder_attr_is_muted'); + late final _dart_recorder_attr_is_muted _recorder_attr_is_muted = + _recorder_attr_is_muted_ptr.asFunction<_dart_recorder_attr_is_muted>(); + + /// @brief Sets the recording motion rate. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This attribute is valid only in a video recorder. \n + /// If the rate bigger than @c 0 and smaller than @c 1, video is recorded in a slow motion mode. \n + /// If the rate bigger than @c 1, video is recorded in a fast motion mode (time lapse recording). + /// @remarks Audio data is not recorded. \n + /// To reset slow motion recording, set the rate to @c 1. + /// @param[in] recorder The handle to the media recorder + /// @param[in] rate The recording motion rate \n + /// It is computed with fps. (@c 0 recorder, + double rate, + ) { + return _recorder_attr_set_recording_motion_rate( + recorder, + rate, + ); + } + + late final _recorder_attr_set_recording_motion_rate_ptr = + _lookup>( + 'recorder_attr_set_recording_motion_rate'); + late final _dart_recorder_attr_set_recording_motion_rate + _recorder_attr_set_recording_motion_rate = + _recorder_attr_set_recording_motion_rate_ptr + .asFunction<_dart_recorder_attr_set_recording_motion_rate>(); + + /// @brief Gets the recording motion rate. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This attribute is valid only in a video recorder. \n + /// If the rate bigger than @c 0 and smaller than @c 1, video is recorded in a slow motion mode. \n + /// If the rate bigger than @c 1, video is recorded in a fast motion mode (time lapse recording). + /// @remarks Audio data is not recorded. \n + /// To reset slow motion recording, set the rate to @c 1. + /// @param[in] recorder The handle to the media recorder + /// @param[out] rate The recording motion rate \n + /// It is computed with fps. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_attr_set_recording_motion_rate() + int recorder_attr_get_recording_motion_rate( + ffi.Pointer recorder, + ffi.Pointer rate, + ) { + return _recorder_attr_get_recording_motion_rate( + recorder, + rate, + ); + } + + late final _recorder_attr_get_recording_motion_rate_ptr = + _lookup>( + 'recorder_attr_get_recording_motion_rate'); + late final _dart_recorder_attr_get_recording_motion_rate + _recorder_attr_get_recording_motion_rate = + _recorder_attr_get_recording_motion_rate_ptr + .asFunction<_dart_recorder_attr_get_recording_motion_rate>(); + + /// @brief Sets the number of the audio channel. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This attribute is applied only in RECORDER_STATE_CREATED state. \n + /// For mono recording, setting channel to @c 1. \n + /// For stereo recording, setting channel to @c 2. + /// @param[in] recorder The handle to the media recorder + /// @param[in] channel_count The number of the audio channel + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @pre The recorder state must be #RECORDER_STATE_CREATED or #RECORDER_STATE_READY (for video recorder only).\n + /// Since 2.3.1, this API also works for audio recorder when its state is #RECORDER_STATE_READY. + /// @see recorder_attr_get_audio_channel() + int recorder_attr_set_audio_channel( + ffi.Pointer recorder, + int channel_count, + ) { + return _recorder_attr_set_audio_channel( + recorder, + channel_count, + ); + } + + late final _recorder_attr_set_audio_channel_ptr = + _lookup>( + 'recorder_attr_set_audio_channel'); + late final _dart_recorder_attr_set_audio_channel + _recorder_attr_set_audio_channel = _recorder_attr_set_audio_channel_ptr + .asFunction<_dart_recorder_attr_set_audio_channel>(); + + /// @brief Gets the number of the audio channel. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to the media recorder + /// @param[out] channel_count The number of the audio channel + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_attr_set_audio_channel() + int recorder_attr_get_audio_channel( + ffi.Pointer recorder, + ffi.Pointer channel_count, + ) { + return _recorder_attr_get_audio_channel( + recorder, + channel_count, + ); + } + + late final _recorder_attr_get_audio_channel_ptr = + _lookup>( + 'recorder_attr_get_audio_channel'); + late final _dart_recorder_attr_get_audio_channel + _recorder_attr_get_audio_channel = _recorder_attr_get_audio_channel_ptr + .asFunction<_dart_recorder_attr_get_audio_channel>(); + + /// @brief Sets the video orientation in a video metadata tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to a media recorder + /// @param[in] orientation The information of the video orientation + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_attr_get_orientation_tag() + int recorder_attr_set_orientation_tag( + ffi.Pointer recorder, + int orientation, + ) { + return _recorder_attr_set_orientation_tag( + recorder, + orientation, + ); + } + + late final _recorder_attr_set_orientation_tag_ptr = + _lookup>( + 'recorder_attr_set_orientation_tag'); + late final _dart_recorder_attr_set_orientation_tag + _recorder_attr_set_orientation_tag = + _recorder_attr_set_orientation_tag_ptr + .asFunction<_dart_recorder_attr_set_orientation_tag>(); + + /// @brief Gets the video orientation in a video metadata tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] recorder The handle to a media recorder + /// @param[out] orientation The information of the video orientation + /// @return @c 0 on success, otherwise a negative error value + /// @retval #RECORDER_ERROR_NONE Successful + /// @retval #RECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @retval #RECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #RECORDER_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected + /// @see recorder_attr_set_orientation_tag() + int recorder_attr_get_orientation_tag( + ffi.Pointer recorder, + ffi.Pointer orientation, + ) { + return _recorder_attr_get_orientation_tag( + recorder, + orientation, + ); + } + + late final _recorder_attr_get_orientation_tag_ptr = + _lookup>( + 'recorder_attr_get_orientation_tag'); + late final _dart_recorder_attr_get_orientation_tag + _recorder_attr_get_orientation_tag = + _recorder_attr_get_orientation_tag_ptr + .asFunction<_dart_recorder_attr_get_orientation_tag>(); + + /// @brief Creates a sound pool instance that can be used for sound sources + /// loading/unloading. + /// @details Up to 8 sound pools can be created. Several pools can be active + /// at the same time. Streams can be in playing state only when pool is + /// active. Memory is allocated for sound pool. User should aware that + /// creation of more number of pools means more memory is allocated. + /// @since_tizen 4.0 + /// @remarks When pool has been created, pool state is + /// #SOUND_POOL_STATE_INACTIVE. To activate the pool use + /// sound_pool_activate() function. + /// When no longer needed, @a pool should be destroyed with sound_pool_destroy(). + /// + /// @param[out] pool The created sound pool handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER + /// Invalid parameter (@a pool is NULL) + /// @retval #SOUND_POOL_ERROR_OUT_OF_MEMORY + /// Not enough memory to create sound pool + /// @retval #SOUND_POOL_ERROR_INVALID_OPERATION + /// Maximal amount of sound pools is exceeded (maximum 8 pools allowed) + /// + /// @see sound_pool_destroy() + int sound_pool_create( + ffi.Pointer> pool, + ) { + return _sound_pool_create( + pool, + ); + } + + late final _sound_pool_create_ptr = + _lookup>('sound_pool_create'); + late final _dart_sound_pool_create _sound_pool_create = + _sound_pool_create_ptr.asFunction<_dart_sound_pool_create>(); + + /// @brief Destroys a sound pool and cleans allocated memory. + /// @details Stops all streams and unloads all sources associated with pool. + /// + /// @since_tizen 4.0 + /// @remarks @a pool should be destroyed with sound_pool_destroy(). + /// @param[in] pool The sound pool handle will be destroyed + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER + /// Invalid parameter (@a pool is NULL or corrupted) + /// @retval #SOUND_POOL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre Create sound pool handle by calling sound_pool_create() + /// + /// @see sound_pool_create() + int sound_pool_destroy( + ffi.Pointer pool, + ) { + return _sound_pool_destroy( + pool, + ); + } + + late final _sound_pool_destroy_ptr = + _lookup>('sound_pool_destroy'); + late final _dart_sound_pool_destroy _sound_pool_destroy = + _sound_pool_destroy_ptr.asFunction<_dart_sound_pool_destroy>(); + + /// @brief Loads sound source data from a file to the pool. + /// @details After calling this routine the source can be accessed by its @a tag. + /// @since_tizen 4.0 + /// @remarks Input data can be either raw or encoded. + /// Each of loaded sources must have unique @a tag + /// It is synchronous operation. + /// + /// @param[in] pool The sound pool handle + /// @param[in] file_name The name of the file that contains sound data + /// @param[in] tag Unique string that will be used to identify source + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER + /// Invalid parameter (@a pool is NULL or corrupted, @a file_name is + /// NULL, @a tag is NULL or @a tag/@a file_name length is too long) + /// @retval #SOUND_POOL_ERROR_OUT_OF_MEMORY Not enough memory to allocate source + /// @retval #SOUND_POOL_ERROR_NO_SUCH_FILE No file determined by @a file_name + /// @retval #SOUND_POOL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// @post Unload source from the pool by calling sound_pool_unload_source() + /// + /// @see sound_pool_create() + /// @see sound_pool_destroy() + /// @see sound_pool_unload_source() + int sound_pool_load_source_from_file( + ffi.Pointer pool, + ffi.Pointer file_name, + ffi.Pointer tag, + ) { + return _sound_pool_load_source_from_file( + pool, + file_name, + tag, + ); + } + + late final _sound_pool_load_source_from_file_ptr = + _lookup>( + 'sound_pool_load_source_from_file'); + late final _dart_sound_pool_load_source_from_file + _sound_pool_load_source_from_file = _sound_pool_load_source_from_file_ptr + .asFunction<_dart_sound_pool_load_source_from_file>(); + + /// @brief Unloads source from the @a pool. + /// @details Cleans memory. This operation is synchronous. + /// @since_tizen 4.0 + /// @remarks The usage of @a tag name that was associated with unloaded source + /// has no effect. It can be reused as well. + /// + /// @param[in] pool The sound pool handle + /// @param[in] tag Unique string that identifies the source + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER + /// Invalid parameter (@a pool is NULL or corrupted, @a tag is NULL) + /// @retval #SOUND_POOL_ERROR_KEY_NOT_AVAILABLE No sources tagged by @a tag exist + /// in the pool + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// @pre Load source to the pool by calling sound_pool_load_source_from_file() + /// + /// @see sound_pool_create() + /// @see sound_pool_load_source_from_file() + int sound_pool_unload_source( + ffi.Pointer pool, + ffi.Pointer tag, + ) { + return _sound_pool_unload_source( + pool, + tag, + ); + } + + late final _sound_pool_unload_source_ptr = + _lookup>( + 'sound_pool_unload_source'); + late final _dart_sound_pool_unload_source _sound_pool_unload_source = + _sound_pool_unload_source_ptr + .asFunction<_dart_sound_pool_unload_source>(); + + /// @brief Changes the current @a state of a @a pool to #SOUND_POOL_STATE_ACTIVE. + /// @since_tizen 4.0 + /// @remarks When activation is performed, all suspended streams with highest + /// priority in the pool will resume their playback. Paused streams will + /// remain their state. + /// + /// @param[in] pool The sound pool handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted) + /// @retval #SOUND_POOL_ERROR_INVALID_OPERATION Invalid operation or sound pool + /// is already in #SOUND_POOL_STATE_ACTIVE state + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// + /// @see sound_pool_create() + /// @see sound_pool_get_state() + /// @see sound_pool_deactivate() + /// @see sound_pool_state_e + int sound_pool_activate( + ffi.Pointer pool, + ) { + return _sound_pool_activate( + pool, + ); + } + + late final _sound_pool_activate_ptr = + _lookup>( + 'sound_pool_activate'); + late final _dart_sound_pool_activate _sound_pool_activate = + _sound_pool_activate_ptr.asFunction<_dart_sound_pool_activate>(); + + /// @brief Changes the current @a state of a @a pool to #SOUND_POOL_STATE_INACTIVE. + /// @since_tizen 4.0 + /// @remarks When deactivation is performed, all playing streams in the pool will + /// be suspended (change state to #SOUND_POOL_STREAM_STATE_SUSPENDED). + /// Paused streams will remain in their state. + /// + /// @param[in] pool The sound pool handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted) + /// @retval #SOUND_POOL_ERROR_INVALID_OPERATION Invalid operation or sound pool + /// is already in @c #SOUND_POOL_STATE_INACTIVE state + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// @pre @a pool has to be in #SOUND_POOL_STATE_ACTIVE state + /// + /// @see sound_pool_create() + /// @see sound_pool_get_state() + /// @see sound_pool_activate() + /// @see sound_pool_state_e + int sound_pool_deactivate( + ffi.Pointer pool, + ) { + return _sound_pool_deactivate( + pool, + ); + } + + late final _sound_pool_deactivate_ptr = + _lookup>( + 'sound_pool_deactivate'); + late final _dart_sound_pool_deactivate _sound_pool_deactivate = + _sound_pool_deactivate_ptr.asFunction<_dart_sound_pool_deactivate>(); + + /// @brief Sets the pool's global volume parameter. + /// @details Volume of all streams related to the @a pool will be scaled + /// in accordance to global pool volume parameter + /// (i.e. [stream real volume] = [global volume] * [stream volume], + /// where [stream volume] is the volume parameter of arbitrary stream). + /// + /// @since_tizen 4.0 + /// @param[in] pool The sound pool handle + /// @param[in] volume Pool global volume in 0.0~1.0 range + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted, or @a volume isn't in 0.0~1.0 range) + /// @retval #SOUND_POOL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// + /// @see sound_pool_create() + int sound_pool_set_volume( + ffi.Pointer pool, + double volume, + ) { + return _sound_pool_set_volume( + pool, + volume, + ); + } + + late final _sound_pool_set_volume_ptr = + _lookup>( + 'sound_pool_set_volume'); + late final _dart_sound_pool_set_volume _sound_pool_set_volume = + _sound_pool_set_volume_ptr.asFunction<_dart_sound_pool_set_volume>(); + + /// @brief Gets the pool's global volume parameter. + /// + /// @since_tizen 4.0 + /// @param[in] pool The sound pool handle + /// @param[out] volume Pool global volume in 0.0~1.0 range + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted, or @a volume is NULL) + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// + /// @see sound_pool_create() + int sound_pool_get_volume( + ffi.Pointer pool, + ffi.Pointer volume, + ) { + return _sound_pool_get_volume( + pool, + volume, + ); + } + + late final _sound_pool_get_volume_ptr = + _lookup>( + 'sound_pool_get_volume'); + late final _dart_sound_pool_get_volume _sound_pool_get_volume = + _sound_pool_get_volume_ptr.asFunction<_dart_sound_pool_get_volume>(); + + /// @brief Gets the current @a state of @a pool. + /// + /// @since_tizen 4.0 + /// @param[in] pool The sound pool handle + /// @param[out] state Current state of @a pool + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER + /// Invalid parameter (@a pool is NULL or corrupted, @a tag is NULL) + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// + /// @see sound_pool_create() + /// @see sound_pool_state_e + int sound_pool_get_state( + ffi.Pointer pool, + ffi.Pointer state, + ) { + return _sound_pool_get_state( + pool, + state, + ); + } + + late final _sound_pool_get_state_ptr = + _lookup>( + 'sound_pool_get_state'); + late final _dart_sound_pool_get_state _sound_pool_get_state = + _sound_pool_get_state_ptr.asFunction<_dart_sound_pool_get_state>(); + + /// @brief Sets the callback for handling sound @a pool state change. + /// + /// @since_tizen 4.0 + /// @param[in] pool The sound pool handle + /// @param[in] callback The callback that will be called after pool state + /// will be changed. @a callback will be called + /// synchronously + /// @param[in] user_data The user data to be passed to the @a callback + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted, or @a callback is NULL) + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// @post Use sound_pool_unset_state_changed_cb() function to unset the + /// @a callback + /// + /// @see sound_pool_create() + /// @see sound_pool_state_changed_cb() + int sound_pool_set_state_changed_cb( + ffi.Pointer pool, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _sound_pool_set_state_changed_cb( + pool, + callback, + user_data, + ); + } + + late final _sound_pool_set_state_changed_cb_ptr = + _lookup>( + 'sound_pool_set_state_changed_cb'); + late final _dart_sound_pool_set_state_changed_cb + _sound_pool_set_state_changed_cb = _sound_pool_set_state_changed_cb_ptr + .asFunction<_dart_sound_pool_set_state_changed_cb>(); + + /// @brief Unsets the callback for handling sound @a pool state change. + /// + /// @since_tizen 4.0 + /// @param[in] pool The sound pool handle + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted) + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// @pre Set state change callback by calling + /// sound_pool_set_state_changed_cb() + /// + /// @see sound_pool_create() + /// @see sound_pool_set_state_changed_cb() + int sound_pool_unset_state_changed_cb( + ffi.Pointer pool, + ) { + return _sound_pool_unset_state_changed_cb( + pool, + ); + } + + late final _sound_pool_unset_state_changed_cb_ptr = + _lookup>( + 'sound_pool_unset_state_changed_cb'); + late final _dart_sound_pool_unset_state_changed_cb + _sound_pool_unset_state_changed_cb = + _sound_pool_unset_state_changed_cb_ptr + .asFunction<_dart_sound_pool_unset_state_changed_cb>(); + + /// @brief Plays a source by @a tag. + /// @details Creates stream with @a id that can be used to change parameters and + /// get additional information. + /// Sets stream state to #SOUND_POOL_STREAM_STATE_PLAYING. + /// If a callback is set with sound_pool_stream_play(), and another + /// callback is set with sound_pool_stream_set_state_changed_cb(), + /// the second callback will overwrite the first one. + /// @since_tizen 4.0 + /// @remarks Resultant stream volume will depend on global pool volume. + /// + /// @param[in] pool The sound pool handle + /// @param[in] tag Unique string that identifies source + /// @param[in] loop Number of times stream will be repeated + /// (pass 0 if stream should be repeated continuously) + /// @param[in] volume Stream volume in 0.0~1.0 range + /// @param[in] priority Stream priority (0 = lowest priority). Check + /// sound_pool_stream_set_priority() documentation + /// for details on prioritization rules. + /// @param[in] priority_policy Stream priority policy.\n + /// (#SOUND_POOL_STREAM_PRIORITY_POLICY_MUTE - Mute)\n + /// (#SOUND_POOL_STREAM_PRIORITY_POLICY_SUSPENDED - Suspended)\n + /// If priority_policy is set to Mute, the stream will be + /// playing with mute even in the presence of high priority + /// stream and it will not be Suspended. + /// @param[in] callback The callback that will be called after stream state + /// will be changed, or NULL if this callback call + /// isn't needed. If @a callback is set, then it will + /// be called asynchronously. + /// @param[in] user_data The user data to be passed to the @a callback + /// @param[out] id Unique stream identifier that can be used to + /// change parameters and get additional information + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted, @a tag is NULL, @a volume is out of + /// 0.0~1.0 range, or @a id is NULL) + /// @retval #SOUND_POOL_ERROR_KEY_NOT_AVAILABLE No sources tagged by @a tag exist + /// in the pool + /// @retval #SOUND_POOL_ERROR_OUT_OF_MEMORY Not enough memory to allocate new + /// sound stream + /// @retval #SOUND_POOL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre Create sound pool handle by calling sound_pool_create() + /// @pre Load source to @a pool by calling sound_pool_load_source_from_file() + /// @post When playback is finished normally (i.e. sound_pool_stream_stop() + /// will be not used for stream termination) state will be changed to + /// #SOUND_POOL_STREAM_STATE_FINISHED and memory will be cleared from the + /// stream allocated resources automatically + /// + /// @see sound_pool_create() + /// @see sound_pool_load_source_from_file() + /// @see sound_pool_set_volume() + /// @see sound_pool_get_volume() + int sound_pool_stream_play( + ffi.Pointer pool, + ffi.Pointer tag, + int loop, + double volume, + int priority, + int priority_policy, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ffi.Pointer id, + ) { + return _sound_pool_stream_play( + pool, + tag, + loop, + volume, + priority, + priority_policy, + callback, + user_data, + id, + ); + } + + late final _sound_pool_stream_play_ptr = + _lookup>( + 'sound_pool_stream_play'); + late final _dart_sound_pool_stream_play _sound_pool_stream_play = + _sound_pool_stream_play_ptr.asFunction<_dart_sound_pool_stream_play>(); + + /// @brief Pauses a stream by @a id. + /// @details Sets stream state to #SOUND_POOL_STREAM_STATE_PAUSED. + /// @since_tizen 4.0 + /// @remarks Stream state has to be #SOUND_POOL_STREAM_STATE_PLAYING. + /// + /// @param[in] pool The sound pool handle + /// @param[in] id Unique stream identifier + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted) + /// @retval #SOUND_POOL_ERROR_KEY_NOT_AVAILABLE No streams identified by @a id + /// exist in the pool + /// @retval #SOUND_POOL_ERROR_INVALID_OPERATION Invalid operation or stream is in + /// the state which is not allowed for pause operation + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// @pre Load source to @a pool by calling sound_pool_load_source_from_file() + /// @pre Start stream playback by calling sound_pool_stream_play() + /// + /// @see sound_pool_create() + /// @see sound_pool_load_source_from_file() + /// @see sound_pool_stream_play() + int sound_pool_stream_pause( + ffi.Pointer pool, + int id, + ) { + return _sound_pool_stream_pause( + pool, + id, + ); + } + + late final _sound_pool_stream_pause_ptr = + _lookup>( + 'sound_pool_stream_pause'); + late final _dart_sound_pool_stream_pause _sound_pool_stream_pause = + _sound_pool_stream_pause_ptr.asFunction<_dart_sound_pool_stream_pause>(); + + /// @brief Resumes a stream by @a id. + /// @details Sets stream state to #SOUND_POOL_STREAM_STATE_PLAYING. + /// @since_tizen 4.0 + /// @remarks Stream state has to be #SOUND_POOL_STREAM_STATE_PAUSED. + /// + /// @param[in] pool The sound pool handle + /// @param[in] id Unique stream identifier + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted) + /// @retval #SOUND_POOL_ERROR_KEY_NOT_AVAILABLE No streams identified by @a id + /// exist in the pool + /// @retval #SOUND_POOL_ERROR_INVALID_OPERATION Invalid operation or stream is in + /// the state which is not allowed for resume operation + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// @pre Load source to @a pool by calling sound_pool_load_source_from_file() + /// @pre Start stream playback by calling sound_pool_stream_play() + /// @pre Pause stream playback by calling sound_pool_stream_pause() + /// + /// @see sound_pool_create() + /// @see sound_pool_load_source_from_file() + /// @see sound_pool_stream_play() + /// @see sound_pool_stream_pause() + int sound_pool_stream_resume( + ffi.Pointer pool, + int id, + ) { + return _sound_pool_stream_resume( + pool, + id, + ); + } + + late final _sound_pool_stream_resume_ptr = + _lookup>( + 'sound_pool_stream_resume'); + late final _dart_sound_pool_stream_resume _sound_pool_stream_resume = + _sound_pool_stream_resume_ptr + .asFunction<_dart_sound_pool_stream_resume>(); + + /// @brief Stops a stream by @a id. + /// @details Sets stream state to #SOUND_POOL_STREAM_STATE_STOPPED. + /// After stream was stopped it can not be resumed and @a id value + /// becomes invalid. Moreover, stream will never gets + /// #SOUND_POOL_STREAM_STATE_FINISHED state as it will be terminated + /// after this function call. + /// + /// @since_tizen 4.0 + /// @param[in] pool The sound pool handle + /// @param[in] id Unique stream identifier + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted) + /// @retval #SOUND_POOL_ERROR_KEY_NOT_AVAILABLE No streams identified by @a id + /// exist in the pool + /// @retval #SOUND_POOL_ERROR_INVALID_OPERATION Invalid operation or stream is in + /// the state which is not allowed for stop operation + /// + /// @pre Create sound pool handle by calling sound_pool_create() + /// @pre Load source to @a pool by calling sound_pool_load_source_from_file() + /// @pre Start stream playback by calling sound_pool_stream_play() + /// + /// @see sound_pool_create() + /// @see sound_pool_load_source_from_file() + /// @see sound_pool_stream_play() + int sound_pool_stream_stop( + ffi.Pointer pool, + int id, + ) { + return _sound_pool_stream_stop( + pool, + id, + ); + } + + late final _sound_pool_stream_stop_ptr = + _lookup>( + 'sound_pool_stream_stop'); + late final _dart_sound_pool_stream_stop _sound_pool_stream_stop = + _sound_pool_stream_stop_ptr.asFunction<_dart_sound_pool_stream_stop>(); + + /// @brief Sets the stream's volume parameters by stream @a id. + /// @since_tizen 4.0 + /// @remarks Resultant stream volume will depend on global pool volume. + /// + /// @param[in] pool The sound pool handle + /// @param[in] id Unique stream identifier + /// @param[in] volume Stream volume in 0.0~1.0 range + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted, or @a volume isn't in 0.0~1.0 range) + /// @retval #SOUND_POOL_ERROR_KEY_NOT_AVAILABLE No streams identified by @a id + /// exist in the pool + /// @retval #SOUND_POOL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// @pre Load source to @a pool by calling sound_pool_load_source_from_file() + /// @pre Start stream playback by calling sound_pool_stream_play() + /// + /// @see sound_pool_create() + /// @see sound_pool_load_source_from_file() + /// @see sound_pool_stream_play() + /// @see sound_pool_set_volume + /// @see sound_pool_get_volume + int sound_pool_stream_set_volume( + ffi.Pointer pool, + int id, + double volume, + ) { + return _sound_pool_stream_set_volume( + pool, + id, + volume, + ); + } + + late final _sound_pool_stream_set_volume_ptr = + _lookup>( + 'sound_pool_stream_set_volume'); + late final _dart_sound_pool_stream_set_volume _sound_pool_stream_set_volume = + _sound_pool_stream_set_volume_ptr + .asFunction<_dart_sound_pool_stream_set_volume>(); + + /// @brief Gets the stream's volume parameters by stream @a id. + /// + /// @since_tizen 4.0 + /// @param[in] pool The sound pool handle + /// @param[in] id Unique stream identifier + /// @param[out] volume Stream volume in 0.0~1.0 range + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted, or @a volume is NULL) + /// @retval #SOUND_POOL_ERROR_KEY_NOT_AVAILABLE No streams identified by @a id + /// exist in the pool + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// @pre Load source to @a pool by calling sound_pool_load_source_from_file() + /// @pre Start stream playback by calling sound_pool_stream_play() + /// + /// @see sound_pool_create() + /// @see sound_pool_load_source_from_file() + /// @see sound_pool_stream_play() + int sound_pool_stream_get_volume( + ffi.Pointer pool, + int id, + ffi.Pointer volume, + ) { + return _sound_pool_stream_get_volume( + pool, + id, + volume, + ); + } + + late final _sound_pool_stream_get_volume_ptr = + _lookup>( + 'sound_pool_stream_get_volume'); + late final _dart_sound_pool_stream_get_volume _sound_pool_stream_get_volume = + _sound_pool_stream_get_volume_ptr + .asFunction<_dart_sound_pool_stream_get_volume>(); + + /// @brief Sets the stream's priority parameter by stream @a id. + /// @since_tizen 4.0 + /// @details The below rules are applicable for streams with priority policy + /// #SOUND_POOL_STREAM_PRIORITY_POLICY_SUSPENDED. + /// Only streams with highest priority in the active Sound Pool can be + /// played. If at least one stream with highest priority enters + /// #SOUND_POOL_STREAM_STATE_PLAYING state, then all streams currently + /// being played with lower priorities will be transferred to the + /// #SOUND_POOL_STREAM_STATE_SUSPENDED state. If there are no more + /// playing streams in a given priority group (group of streams with the + /// same priority), then all previously suspended streams in the group + /// with one level lower priority will be resumed. + /// + /// For example, if we have N suspended streams in 'LOW' group, M + /// suspended streams in 'MEDIUM' group and K playing streams in 'HIGH' + /// group. Then the following rules are valid: When all K streams in HIGH + /// priority group will be finished, paused, or stopped and Sound Pool is + /// in active state, only then M streams from MEDIUM priority group will + /// be resumed. When all M+K streams from HIGH and MEDIUM priority groups + /// are finished, paused or stopped and Sound Pool is in active state, + /// only then N streams from LOW priority group will be resumed. + /// Transferring at least one stream from higher priority group will lead + /// to suspending of all the streams from lower priorities group(s). + /// + /// Priorities don't take any effect in inactive Sound Pools. But after + /// pool activation, all mentioned rules will be applied. + /// + /// If stream priority policy is set to mute + /// #SOUND_POOL_STREAM_PRIORITY_POLICY_MUTE, all above rules are not valid + /// for the stream and it will be played with mute even in the presence + /// of high priority steams. + /// streams. + /// @param[in] pool The sound pool handle + /// @param[in] id Unique stream identifier + /// @param[in] priority Stream priority (0 = lowest priority) + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted) + /// @retval #SOUND_POOL_ERROR_KEY_NOT_AVAILABLE No streams identified by @a id + /// exist in the pool + /// @retval #SOUND_POOL_ERROR_INVALID_OPERATION Invalid operation + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// @pre Load source to @a pool by calling sound_pool_load_source_from_file() + /// @pre Start stream playback by calling sound_pool_stream_play() + /// + /// @see sound_pool_create() + /// @see sound_pool_load_source_from_file() + /// @see sound_pool_stream_play() + int sound_pool_stream_set_priority( + ffi.Pointer pool, + int id, + int priority, + ) { + return _sound_pool_stream_set_priority( + pool, + id, + priority, + ); + } + + late final _sound_pool_stream_set_priority_ptr = + _lookup>( + 'sound_pool_stream_set_priority'); + late final _dart_sound_pool_stream_set_priority + _sound_pool_stream_set_priority = _sound_pool_stream_set_priority_ptr + .asFunction<_dart_sound_pool_stream_set_priority>(); + + /// @brief Gets the stream's priority parameter by stream @a id. + /// + /// @since_tizen 4.0 + /// @param[in] pool The sound pool handle + /// @param[in] id Unique stream identifier + /// @param[out] priority Stream priority (0 = lowest priority). Check + /// sound_pool_stream_set_priority() documentation + /// for details on prioritization rules. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted, or @a priority is NULL) + /// @retval #SOUND_POOL_ERROR_KEY_NOT_AVAILABLE No streams identified by @a id + /// exist in the pool + /// + /// @pre Create a sound @a pool handle by calling sound_pool_create() + /// @pre Load source to @a pool by calling sound_pool_load_source_from_file() + /// @pre Start stream playback by calling sound_pool_stream_play() + /// + /// @see sound_pool_create() + /// @see sound_pool_load_source_from_file() + /// @see sound_pool_stream_play() + int sound_pool_stream_get_priority( + ffi.Pointer pool, + int id, + ffi.Pointer priority, + ) { + return _sound_pool_stream_get_priority( + pool, + id, + priority, + ); + } + + late final _sound_pool_stream_get_priority_ptr = + _lookup>( + 'sound_pool_stream_get_priority'); + late final _dart_sound_pool_stream_get_priority + _sound_pool_stream_get_priority = _sound_pool_stream_get_priority_ptr + .asFunction<_dart_sound_pool_stream_get_priority>(); + + /// @brief Gets the current @a state of stream by @a id. + /// + /// @since_tizen 4.0 + /// @param[in] pool The sound pool handle + /// @param[in] id Unique stream identifier + /// @param[out] state Current state of stream + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SOUND_POOL_ERROR_NONE Successful + /// @retval #SOUND_POOL_ERROR_INVALID_PARAMETER Invalid parameter + /// (@a pool is NULL or corrupted, or @a state is NULL) + /// @retval #SOUND_POOL_ERROR_KEY_NOT_AVAILABLE No streams identified by @a id + /// exist in the pool + /// + /// @pre Create sound pool handle by calling sound_pool_create() + /// @pre Load source to @a pool by calling sound_pool_load_source_from_file() + /// @pre Start stream playback by calling sound_pool_stream_play() + /// + /// @see sound_pool_create() + /// @see sound_pool_load_source_from_file() + /// @see sound_pool_stream_play() + /// @see sound_pool_stream_state_e + int sound_pool_stream_get_state( + ffi.Pointer pool, + int id, + ffi.Pointer state, + ) { + return _sound_pool_stream_get_state( + pool, + id, + state, + ); + } + + late final _sound_pool_stream_get_state_ptr = + _lookup>( + 'sound_pool_stream_get_state'); + late final _dart_sound_pool_stream_get_state _sound_pool_stream_get_state = + _sound_pool_stream_get_state_ptr + .asFunction<_dart_sound_pool_stream_get_state>(); + + /// @brief Creates a streamrecorder handle to record a video or audio + /// @since_tizen 3.0 + /// @remarks You must release @a recorder using streamrecorder_destroy(). + /// @param[out] recorder A handle to the streamrecorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STREAMRECORDER_ERROR_INVALID_OPERATION Invalid operation + int streamrecorder_create( + ffi.Pointer> recorder, + ) { + return _streamrecorder_create( + recorder, + ); + } + + late final _streamrecorder_create_ptr = + _lookup>( + 'streamrecorder_create'); + late final _dart_streamrecorder_create _streamrecorder_create = + _streamrecorder_create_ptr.asFunction<_dart_streamrecorder_create>(); + + /// @brief Destroys the streamrecorder handle + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @pre The recorder state should be #STREAMRECORDER_STATE_CREATED. + /// @post The recorder state will be #STREAMRECORDER_STATE_NONE. + int streamrecorder_destroy( + ffi.Pointer recorder, + ) { + return _streamrecorder_destroy( + recorder, + ); + } + + late final _streamrecorder_destroy_ptr = + _lookup>( + 'streamrecorder_destroy'); + late final _dart_streamrecorder_destroy _streamrecorder_destroy = + _streamrecorder_destroy_ptr.asFunction<_dart_streamrecorder_destroy>(); + + /// @brief Prepares the streamrecorder for recording. + /// @since_tizen 3.0 + /// @remarks Before calling the function, it is required to properly set streamrecorder_enable_source_buffer(), + /// audio encoder (streamrecorder_set_audio_encoder()), + /// video encoder(streamrecorder_set_video_encoder()) and file format (streamrecorder_set_file_format()). + /// @param[in] recorder The handle to the streamrecorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @pre The recorder state should be #STREAMRECORDER_STATE_CREATED. \n + /// The streamrecorder_enable_source_buffer() should be invoked before this function. + /// @post The streamrecorder state will be #STREAMRECORDER_STATE_PREPARED + /// @see streamrecorder_unprepare() + /// @see streamrecorder_set_audio_encoder() + /// @see streamrecorder_set_video_encoder() + /// @see streamrecorder_set_file_format() + int streamrecorder_prepare( + ffi.Pointer recorder, + ) { + return _streamrecorder_prepare( + recorder, + ); + } + + late final _streamrecorder_prepare_ptr = + _lookup>( + 'streamrecorder_prepare'); + late final _dart_streamrecorder_prepare _streamrecorder_prepare = + _streamrecorder_prepare_ptr.asFunction<_dart_streamrecorder_prepare>(); + + /// @brief Resets the streamrecorder. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @pre The streamrecorder state should be #STREAMRECORDER_STATE_PREPARED set by streamrecorder_prepare(), streamrecorder_cancel() or streamrecorder_commit(). + /// @post The streamrecorder state will be #STREAMRECORDER_STATE_CREATED. + /// @see streamrecorder_prepare() + /// @see streamrecorder_cancel() + /// @see streamrecorder_commit() + int streamrecorder_unprepare( + ffi.Pointer recorder, + ) { + return _streamrecorder_unprepare( + recorder, + ); + } + + late final _streamrecorder_unprepare_ptr = + _lookup>( + 'streamrecorder_unprepare'); + late final _dart_streamrecorder_unprepare _streamrecorder_unprepare = + _streamrecorder_unprepare_ptr + .asFunction<_dart_streamrecorder_unprepare>(); + + /// @brief Starts the recording. + /// @since_tizen 3.0 + /// @remarks If file path has been set to an existing file, this file is removed automatically and updated by new one. \n + /// When you want to record audio or video file, you need to add privilege according to rules below additionally. \n + /// http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage.\n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. + /// The filename should be set before this function is invoked. + /// @param[in] recorder The handle to the streamrecorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #STREAMRECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @pre The streamrecorder state must be #STREAMRECORDER_STATE_PREPARED by streamrecorder_prepare() or #STREAMRECORDER_STATE_PAUSED by streamrecorder_pause(). \n + /// The filename should be set by streamrecorder_set_filename(). + /// @post The recorder state will be #STREAMRECORDER_STATE_RECORDING. + /// @see streamrecorder_pause() + /// @see streamrecorder_commit() + /// @see streamrecorder_cancel() + /// @see streamrecorder_set_audio_encoder() + /// @see streamrecorder_set_filename() + /// @see streamrecorder_set_file_format() + /// @see streamrecorder_recording_status_cb() + /// @see streamrecorder_set_filename() + int streamrecorder_start( + ffi.Pointer recorder, + ) { + return _streamrecorder_start( + recorder, + ); + } + + late final _streamrecorder_start_ptr = + _lookup>( + 'streamrecorder_start'); + late final _dart_streamrecorder_start _streamrecorder_start = + _streamrecorder_start_ptr.asFunction<_dart_streamrecorder_start>(); + + /// @brief Pauses the recording. + /// @since_tizen 3.0 + /// @remarks Recording can be resumed with streamrecorder_start(). + /// @param[in] recorder The handle to the streamrecorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @pre The streamrecorder state must be #STREAMRECORDER_STATE_RECORDING. + /// @post The streamrecorder state will be #STREAMRECORDER_STATE_PAUSED. + /// @see streamrecorder_pause() + /// @see streamrecorder_commit() + /// @see streamrecorder_cancel() + int streamrecorder_pause( + ffi.Pointer recorder, + ) { + return _streamrecorder_pause( + recorder, + ); + } + + late final _streamrecorder_pause_ptr = + _lookup>( + 'streamrecorder_pause'); + late final _dart_streamrecorder_pause _streamrecorder_pause = + _streamrecorder_pause_ptr.asFunction<_dart_streamrecorder_pause>(); + + /// @brief Stops recording and saves the result. + /// @since_tizen 3.0 + /// @remarks When you want to record audio or video file, you need to add privilege according to rules below additionally. \n + /// http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage.\n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. + /// @param[in] recorder The handle to the streamrecorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #STREAMRECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @pre The streamrecorder state must be #STREAMRECORDER_STATE_RECORDING set by streamrecorder_start() or #STREAMRECORDER_STATE_PAUSED by streamrecorder_pause(). + /// @post The streamrecorder state will be #STREAMRECORDER_STATE_PREPARED. + /// @see streamrecorder_pause() + /// @see streamrecorder_cancel() + /// @see streamrecorder_set_filename() + /// @see streamrecorder_start() + int streamrecorder_commit( + ffi.Pointer recorder, + ) { + return _streamrecorder_commit( + recorder, + ); + } + + late final _streamrecorder_commit_ptr = + _lookup>( + 'streamrecorder_commit'); + late final _dart_streamrecorder_commit _streamrecorder_commit = + _streamrecorder_commit_ptr.asFunction<_dart_streamrecorder_commit>(); + + /// @brief Cancels the recording. + /// @details The recording data is discarded and not written in the recording file. + /// @since_tizen 3.0 + /// @remarks When you want to record audio or video file, you need to add privilege according to rules below additionally. \n + /// http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage.\n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. + /// @param[in] recorder The handle to the streamrecorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #STREAMRECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + /// @pre The streamrecorder state must be #STREAMRECORDER_STATE_RECORDING set by streamrecorder_start() or #STREAMRECORDER_STATE_PAUSED by streamrecorder_pause(). + /// @post The streamrecorder state will be #STREAMRECORDER_STATE_PREPARED. + /// @see streamrecorder_pause() + /// @see streamrecorder_commit() + /// @see streamrecorder_cancel() + /// @see streamrecorder_start() + int streamrecorder_cancel( + ffi.Pointer recorder, + ) { + return _streamrecorder_cancel( + recorder, + ); + } + + late final _streamrecorder_cancel_ptr = + _lookup>( + 'streamrecorder_cancel'); + late final _dart_streamrecorder_cancel _streamrecorder_cancel = + _streamrecorder_cancel_ptr.asFunction<_dart_streamrecorder_cancel>(); + + /// @brief Pushes buffer to StreamRecorder to record audio/video + /// @since_tizen 3.0 + /// @remarks When you want to record audio or video file, you need to add privilege according to rules below additionally. \n + /// http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage.\n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] inbuf The media packet containing buffer and other associated values + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_PERMISSION_DENIED The access to the resources can not be granted + int streamrecorder_push_stream_buffer( + ffi.Pointer recorder, + ffi.Pointer inbuf, + ) { + return _streamrecorder_push_stream_buffer( + recorder, + inbuf, + ); + } + + late final _streamrecorder_push_stream_buffer_ptr = + _lookup>( + 'streamrecorder_push_stream_buffer'); + late final _dart_streamrecorder_push_stream_buffer + _streamrecorder_push_stream_buffer = + _streamrecorder_push_stream_buffer_ptr + .asFunction<_dart_streamrecorder_push_stream_buffer>(); + + /// @brief Sets the video source as live buffer to be used for recording + /// @since_tizen 3.0 + /// @remarks if you want to enable video or audio or both recording, call before streamrecorder_prepare() + /// @param[in] recorder A handle to the streamrecorder + /// @param[in] type The type of source input + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @pre The streamrecorder state must be only #STREAMRECORDER_STATE_CREATED + int streamrecorder_enable_source_buffer( + ffi.Pointer recorder, + int type, + ) { + return _streamrecorder_enable_source_buffer( + recorder, + type, + ); + } + + late final _streamrecorder_enable_source_buffer_ptr = + _lookup>( + 'streamrecorder_enable_source_buffer'); + late final _dart_streamrecorder_enable_source_buffer + _streamrecorder_enable_source_buffer = + _streamrecorder_enable_source_buffer_ptr + .asFunction<_dart_streamrecorder_enable_source_buffer>(); + + /// @brief Gets the streamrecorder's current state. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[out] state The current state of the streamrecorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + int streamrecorder_get_state( + ffi.Pointer recorder, + ffi.Pointer state, + ) { + return _streamrecorder_get_state( + recorder, + state, + ); + } + + late final _streamrecorder_get_state_ptr = + _lookup>( + 'streamrecorder_get_state'); + late final _dart_streamrecorder_get_state _streamrecorder_get_state = + _streamrecorder_get_state_ptr + .asFunction<_dart_streamrecorder_get_state>(); + + /// @brief Sets the file path to record. + /// @details This function sets file path which defines where newly recorded data should be stored. + /// @since_tizen 3.0 + /// @remarks If the same file already exists in the file system, then old file will be overwritten. + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] path The recording file path + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @pre The streamrecorder state must be #STREAMRECORDER_STATE_CREATED. \n + /// streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_get_filename() + int streamrecorder_set_filename( + ffi.Pointer recorder, + ffi.Pointer path, + ) { + return _streamrecorder_set_filename( + recorder, + path, + ); + } + + late final _streamrecorder_set_filename_ptr = + _lookup>( + 'streamrecorder_set_filename'); + late final _dart_streamrecorder_set_filename _streamrecorder_set_filename = + _streamrecorder_set_filename_ptr + .asFunction<_dart_streamrecorder_set_filename>(); + + /// @brief Gets the file path to record. + /// @since_tizen 3.0 + /// @remarks You must release @a path using free(). + /// @param[in] recorder The handle to the streamrecorder + /// @param[out] path The recording file path + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_set_filename() + int streamrecorder_get_filename( + ffi.Pointer recorder, + ffi.Pointer> path, + ) { + return _streamrecorder_get_filename( + recorder, + path, + ); + } + + late final _streamrecorder_get_filename_ptr = + _lookup>( + 'streamrecorder_get_filename'); + late final _dart_streamrecorder_get_filename _streamrecorder_get_filename = + _streamrecorder_get_filename_ptr + .asFunction<_dart_streamrecorder_get_filename>(); + + /// @brief Sets the file format for recording media stream. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] format The media file format + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #STREAMRECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The streamrecorder state must be #STREAMRECORDER_STATE_CREATED. \n + /// streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_get_file_format() + /// @see streamrecorder_foreach_supported_file_format() + int streamrecorder_set_file_format( + ffi.Pointer recorder, + int format, + ) { + return _streamrecorder_set_file_format( + recorder, + format, + ); + } + + late final _streamrecorder_set_file_format_ptr = + _lookup>( + 'streamrecorder_set_file_format'); + late final _dart_streamrecorder_set_file_format + _streamrecorder_set_file_format = _streamrecorder_set_file_format_ptr + .asFunction<_dart_streamrecorder_set_file_format>(); + + /// @brief Gets the file format for recording media stream. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[out] format The media file format + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_set_file_format() + /// @see streamrecorder_foreach_supported_file_format() + int streamrecorder_get_file_format( + ffi.Pointer recorder, + ffi.Pointer format, + ) { + return _streamrecorder_get_file_format( + recorder, + format, + ); + } + + late final _streamrecorder_get_file_format_ptr = + _lookup>( + 'streamrecorder_get_file_format'); + late final _dart_streamrecorder_get_file_format + _streamrecorder_get_file_format = _streamrecorder_get_file_format_ptr + .asFunction<_dart_streamrecorder_get_file_format>(); + + /// @brief Sets the audio codec for encoding an audio stream. + /// @since_tizen 3.0 + /// @remarks You can get available audio encoders by using streamrecorder_foreach_supported_audio_encoder(). \n + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] codec The audio codec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #STREAMRECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @retval #STREAMRECORDER_ERROR_INVALID_OPERATION Invalid operation + /// @pre The streamrecorder state must be #STREAMRECORDER_STATE_CREATED. \n + /// streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_get_audio_encoder() + /// @see streamrecorder_foreach_supported_audio_encoder() + int streamrecorder_set_audio_encoder( + ffi.Pointer recorder, + int codec, + ) { + return _streamrecorder_set_audio_encoder( + recorder, + codec, + ); + } + + late final _streamrecorder_set_audio_encoder_ptr = + _lookup>( + 'streamrecorder_set_audio_encoder'); + late final _dart_streamrecorder_set_audio_encoder + _streamrecorder_set_audio_encoder = _streamrecorder_set_audio_encoder_ptr + .asFunction<_dart_streamrecorder_set_audio_encoder>(); + + /// @brief Gets the audio codec for encoding an audio stream. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[out] codec The audio codec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @pre The streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_set_audio_encoder() + /// @see streamrecorder_foreach_supported_audio_encoder() + int streamrecorder_get_audio_encoder( + ffi.Pointer recorder, + ffi.Pointer codec, + ) { + return _streamrecorder_get_audio_encoder( + recorder, + codec, + ); + } + + late final _streamrecorder_get_audio_encoder_ptr = + _lookup>( + 'streamrecorder_get_audio_encoder'); + late final _dart_streamrecorder_get_audio_encoder + _streamrecorder_get_audio_encoder = _streamrecorder_get_audio_encoder_ptr + .asFunction<_dart_streamrecorder_get_audio_encoder>(); + + /// @brief Sets the resolution of the video recording. + /// @since_tizen 3.0 + /// @remarks This function should be called before recording (streamrecorder_start()). + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] width The input width + /// @param[in] height The input height + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #STREAMRECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @pre The streamrecorder state must be #STREAMRECORDER_STATE_CREATED. \n + /// streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_start() + /// @see streamrecorder_get_video_resolution() + /// @see streamrecorder_foreach_supported_video_resolution() + int streamrecorder_set_video_resolution( + ffi.Pointer recorder, + int width, + int height, + ) { + return _streamrecorder_set_video_resolution( + recorder, + width, + height, + ); + } + + late final _streamrecorder_set_video_resolution_ptr = + _lookup>( + 'streamrecorder_set_video_resolution'); + late final _dart_streamrecorder_set_video_resolution + _streamrecorder_set_video_resolution = + _streamrecorder_set_video_resolution_ptr + .asFunction<_dart_streamrecorder_set_video_resolution>(); + + /// @brief Gets the resolution of the video recording. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[out] width The video width + /// @param[out] height The video height + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @pre The streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_set_video_resolution() + /// @see streamrecorder_foreach_supported_video_resolution() + int streamrecorder_get_video_resolution( + ffi.Pointer recorder, + ffi.Pointer width, + ffi.Pointer height, + ) { + return _streamrecorder_get_video_resolution( + recorder, + width, + height, + ); + } + + late final _streamrecorder_get_video_resolution_ptr = + _lookup>( + 'streamrecorder_get_video_resolution'); + late final _dart_streamrecorder_get_video_resolution + _streamrecorder_get_video_resolution = + _streamrecorder_get_video_resolution_ptr + .asFunction<_dart_streamrecorder_get_video_resolution>(); + + /// @brief Sets the video codec for encoding video stream. + /// @since_tizen 3.0 + /// @remarks You can get available video encoders by using recorder_foreach_supported_video_encoder(). + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] codec The video codec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @retval #STREAMRECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @pre The streamrecorder state must be #STREAMRECORDER_STATE_CREATED. \n + /// streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_get_video_encoder() + /// @see streamrecorder_foreach_supported_video_encoder() + int streamrecorder_set_video_encoder( + ffi.Pointer recorder, + int codec, + ) { + return _streamrecorder_set_video_encoder( + recorder, + codec, + ); + } + + late final _streamrecorder_set_video_encoder_ptr = + _lookup>( + 'streamrecorder_set_video_encoder'); + late final _dart_streamrecorder_set_video_encoder + _streamrecorder_set_video_encoder = _streamrecorder_set_video_encoder_ptr + .asFunction<_dart_streamrecorder_set_video_encoder>(); + + /// @brief Gets the video codec for encoding video stream. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[out] codec The video codec + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_NOT_SUPPORTED The feature is not supported + /// @pre The streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_set_video_encoder() + /// @see streamrecorder_foreach_supported_video_encoder() + int streamrecorder_get_video_encoder( + ffi.Pointer recorder, + ffi.Pointer codec, + ) { + return _streamrecorder_get_video_encoder( + recorder, + codec, + ); + } + + late final _streamrecorder_get_video_encoder_ptr = + _lookup>( + 'streamrecorder_get_video_encoder'); + late final _dart_streamrecorder_get_video_encoder + _streamrecorder_get_video_encoder = _streamrecorder_get_video_encoder_ptr + .asFunction<_dart_streamrecorder_get_video_encoder>(); + + /// @brief Sets the recording frame rate. + /// @since_tizen 3.0 + /// @remarks This function should be called before prepared state. + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] framerate The frame rate for recording + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @see streamrecorder_get_video_framerate() + int streamrecorder_set_video_framerate( + ffi.Pointer recorder, + int framerate, + ) { + return _streamrecorder_set_video_framerate( + recorder, + framerate, + ); + } + + late final _streamrecorder_set_video_framerate_ptr = + _lookup>( + 'streamrecorder_set_video_framerate'); + late final _dart_streamrecorder_set_video_framerate + _streamrecorder_set_video_framerate = + _streamrecorder_set_video_framerate_ptr + .asFunction<_dart_streamrecorder_set_video_framerate>(); + + /// @brief Gets the recording frame rate. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the camera + /// @param[out] framerate The frame rate for recording that already is set + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see streamrecorder_set_video_framerate() + int streamrecorder_get_video_framerate( + ffi.Pointer recorder, + ffi.Pointer framerate, + ) { + return _streamrecorder_get_video_framerate( + recorder, + framerate, + ); + } + + late final _streamrecorder_get_video_framerate_ptr = + _lookup>( + 'streamrecorder_get_video_framerate'); + late final _dart_streamrecorder_get_video_framerate + _streamrecorder_get_video_framerate = + _streamrecorder_get_video_framerate_ptr + .asFunction<_dart_streamrecorder_get_video_framerate>(); + + /// @brief Sets the video source format. + /// @since_tizen 3.0 + /// @remarks This function should be called before prepared state. + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] format The color type of video source + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @see streamrecorder_get_video_source_format() + int streamrecorder_set_video_source_format( + ffi.Pointer recorder, + int format, + ) { + return _streamrecorder_set_video_source_format( + recorder, + format, + ); + } + + late final _streamrecorder_set_video_source_format_ptr = + _lookup>( + 'streamrecorder_set_video_source_format'); + late final _dart_streamrecorder_set_video_source_format + _streamrecorder_set_video_source_format = + _streamrecorder_set_video_source_format_ptr + .asFunction<_dart_streamrecorder_set_video_source_format>(); + + /// @brief Gets the video source format. + /// @since_tizen 3.0 + /// @remarks This function should be called before prepared state. + /// @param[in] recorder The handle to the streamrecorder + /// @param[out] format The color type of video source that already is set + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see streamrecorder_set_video_source_format() + int streamrecorder_get_video_source_format( + ffi.Pointer recorder, + ffi.Pointer format, + ) { + return _streamrecorder_get_video_source_format( + recorder, + format, + ); + } + + late final _streamrecorder_get_video_source_format_ptr = + _lookup>( + 'streamrecorder_get_video_source_format'); + late final _dart_streamrecorder_get_video_source_format + _streamrecorder_get_video_source_format = + _streamrecorder_get_video_source_format_ptr + .asFunction<_dart_streamrecorder_get_video_source_format>(); + + /// @brief Sets the maximum size of a recording file. + /// @since_tizen 3.0 + /// @remarks After reaching the limitation, the recording data is discarded and not written in the recording file. + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] type The recording limit type + /// @param[in] limit If limit type is STREAMRECORDER_RECORDING_LIMIT_TYPE_SIZE, the limit value is the maximum size of the recording file(KB), \n + /// otherwise limit value is the maximum time of the recording file (in seconds) \n + /// @c 0 means unlimited recording size or time. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @pre The streamrecorder state must be #STREAMRECORDER_STATE_CREATED. \n + /// streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_get_recording_limit() + int streamrecorder_set_recording_limit( + ffi.Pointer recorder, + int type, + int limit, + ) { + return _streamrecorder_set_recording_limit( + recorder, + type, + limit, + ); + } + + late final _streamrecorder_set_recording_limit_ptr = + _lookup>( + 'streamrecorder_set_recording_limit'); + late final _dart_streamrecorder_set_recording_limit + _streamrecorder_set_recording_limit = + _streamrecorder_set_recording_limit_ptr + .asFunction<_dart_streamrecorder_set_recording_limit>(); + + /// @brief Gets the maximum size of a recording file. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] type The recording limit type + /// @param[out] limit If limit type is STREAMRECORDER_RECORDING_LIMIT_TYPE_SIZE, the limit value is the maximum size of the recording file(KB), \n + /// otherwise limit value is the maximum time of the recording file (in seconds) \n + /// @c 0 means unlimited recording size or time. + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_set_recording_limit() + int streamrecorder_get_recording_limit( + ffi.Pointer recorder, + int type, + ffi.Pointer limit, + ) { + return _streamrecorder_get_recording_limit( + recorder, + type, + limit, + ); + } + + late final _streamrecorder_get_recording_limit_ptr = + _lookup>( + 'streamrecorder_get_recording_limit'); + late final _dart_streamrecorder_get_recording_limit + _streamrecorder_get_recording_limit = + _streamrecorder_get_recording_limit_ptr + .asFunction<_dart_streamrecorder_get_recording_limit>(); + + /// @brief Sets the sampling rate of an audio stream. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] samplerate The sample rate in Hertz + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @pre The streamrecorder state must be #STREAMRECORDER_STATE_CREATED. \n + /// streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_get_audio_samplerate() + int streamrecorder_set_audio_samplerate( + ffi.Pointer recorder, + int samplerate, + ) { + return _streamrecorder_set_audio_samplerate( + recorder, + samplerate, + ); + } + + late final _streamrecorder_set_audio_samplerate_ptr = + _lookup>( + 'streamrecorder_set_audio_samplerate'); + late final _dart_streamrecorder_set_audio_samplerate + _streamrecorder_set_audio_samplerate = + _streamrecorder_set_audio_samplerate_ptr + .asFunction<_dart_streamrecorder_set_audio_samplerate>(); + + /// @brief Gets the sampling rate of an audio stream. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[out] samplerate The sample rate in Hertz + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_set_audio_samplerate() + int streamrecorder_get_audio_samplerate( + ffi.Pointer recorder, + ffi.Pointer samplerate, + ) { + return _streamrecorder_get_audio_samplerate( + recorder, + samplerate, + ); + } + + late final _streamrecorder_get_audio_samplerate_ptr = + _lookup>( + 'streamrecorder_get_audio_samplerate'); + late final _dart_streamrecorder_get_audio_samplerate + _streamrecorder_get_audio_samplerate = + _streamrecorder_get_audio_samplerate_ptr + .asFunction<_dart_streamrecorder_get_audio_samplerate>(); + + /// @brief Sets the bitrate of an audio encoder. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] bitrate The bitrate (for mms : 12200[bps], normal : 288000[bps]) + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @pre The streamrecorder state must be #STREAMRECORDER_STATE_CREATED. \n + /// streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_get_audio_encoder_bitrate() + int streamrecorder_set_audio_encoder_bitrate( + ffi.Pointer recorder, + int bitrate, + ) { + return _streamrecorder_set_audio_encoder_bitrate( + recorder, + bitrate, + ); + } + + late final _streamrecorder_set_audio_encoder_bitrate_ptr = + _lookup>( + 'streamrecorder_set_audio_encoder_bitrate'); + late final _dart_streamrecorder_set_audio_encoder_bitrate + _streamrecorder_set_audio_encoder_bitrate = + _streamrecorder_set_audio_encoder_bitrate_ptr + .asFunction<_dart_streamrecorder_set_audio_encoder_bitrate>(); + + /// @brief Sets the bitrate of a video encoder. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] bitrate The bitrate in bits per second + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @pre The streamrecorder state must be #STREAMRECORDER_STATE_CREATED. \n + /// streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_get_video_encoder_bitrate() + int streamrecorder_set_video_encoder_bitrate( + ffi.Pointer recorder, + int bitrate, + ) { + return _streamrecorder_set_video_encoder_bitrate( + recorder, + bitrate, + ); + } + + late final _streamrecorder_set_video_encoder_bitrate_ptr = + _lookup>( + 'streamrecorder_set_video_encoder_bitrate'); + late final _dart_streamrecorder_set_video_encoder_bitrate + _streamrecorder_set_video_encoder_bitrate = + _streamrecorder_set_video_encoder_bitrate_ptr + .asFunction<_dart_streamrecorder_set_video_encoder_bitrate>(); + + /// @brief Gets the bitrate of an audio encoder. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[out] bitrate The bitrate in bits per second + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_set_audio_encoder_bitrate() + int streamrecorder_get_audio_encoder_bitrate( + ffi.Pointer recorder, + ffi.Pointer bitrate, + ) { + return _streamrecorder_get_audio_encoder_bitrate( + recorder, + bitrate, + ); + } + + late final _streamrecorder_get_audio_encoder_bitrate_ptr = + _lookup>( + 'streamrecorder_get_audio_encoder_bitrate'); + late final _dart_streamrecorder_get_audio_encoder_bitrate + _streamrecorder_get_audio_encoder_bitrate = + _streamrecorder_get_audio_encoder_bitrate_ptr + .asFunction<_dart_streamrecorder_get_audio_encoder_bitrate>(); + + /// @brief Gets the bitrate of a video encoder. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[out] bitrate The bitrate in bits per second + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_set_audio_encoder_bitrate() + int streamrecorder_get_video_encoder_bitrate( + ffi.Pointer recorder, + ffi.Pointer bitrate, + ) { + return _streamrecorder_get_video_encoder_bitrate( + recorder, + bitrate, + ); + } + + late final _streamrecorder_get_video_encoder_bitrate_ptr = + _lookup>( + 'streamrecorder_get_video_encoder_bitrate'); + late final _dart_streamrecorder_get_video_encoder_bitrate + _streamrecorder_get_video_encoder_bitrate = + _streamrecorder_get_video_encoder_bitrate_ptr + .asFunction<_dart_streamrecorder_get_video_encoder_bitrate>(); + + /// @brief Sets the number of the audio channel. + /// @since_tizen 3.0 + /// @remarks This attribute is applied only in STREAMRECORDER_STATE_CREATED state. \n + /// For mono recording, setting channel to @c 1. \n + /// For stereo recording, setting channel to @c 2. + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] channel_count The number of the audio channel + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STREAMRECORDER_ERROR_INVALID_STATE Invalid state + /// @pre The streamrecorder state must be #STREAMRECORDER_STATE_CREATED.\n + /// streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_get_audio_channel() + int streamrecorder_set_audio_channel( + ffi.Pointer recorder, + int channel_count, + ) { + return _streamrecorder_set_audio_channel( + recorder, + channel_count, + ); + } + + late final _streamrecorder_set_audio_channel_ptr = + _lookup>( + 'streamrecorder_set_audio_channel'); + late final _dart_streamrecorder_set_audio_channel + _streamrecorder_set_audio_channel = _streamrecorder_set_audio_channel_ptr + .asFunction<_dart_streamrecorder_set_audio_channel>(); + + /// @brief Gets the number of the audio channel. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[out] channel_count The number of the audio channel + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The streamrecorder_enable_source_buffer() should be invoked before this function. + /// @see streamrecorder_set_audio_channel() + int streamrecorder_get_audio_channel( + ffi.Pointer recorder, + ffi.Pointer channel_count, + ) { + return _streamrecorder_get_audio_channel( + recorder, + channel_count, + ); + } + + late final _streamrecorder_get_audio_channel_ptr = + _lookup>( + 'streamrecorder_get_audio_channel'); + late final _dart_streamrecorder_get_audio_channel + _streamrecorder_get_audio_channel = _streamrecorder_get_audio_channel_ptr + .asFunction<_dart_streamrecorder_get_audio_channel>(); + + /// @brief Retrieves all supported file formats by invoking a specific callback for each supported file format. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] callback The iteration callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @post streamrecorder_supported_file_format_cb() will be invoked. + /// @see streamrecorder_get_file_format() + /// @see streamrecorder_set_file_format() + /// @see streamrecorder_supported_file_format_cb() + int streamrecorder_foreach_supported_file_format( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _streamrecorder_foreach_supported_file_format( + recorder, + callback, + user_data, + ); + } + + late final _streamrecorder_foreach_supported_file_format_ptr = _lookup< + ffi.NativeFunction<_c_streamrecorder_foreach_supported_file_format>>( + 'streamrecorder_foreach_supported_file_format'); + late final _dart_streamrecorder_foreach_supported_file_format + _streamrecorder_foreach_supported_file_format = + _streamrecorder_foreach_supported_file_format_ptr + .asFunction<_dart_streamrecorder_foreach_supported_file_format>(); + + /// @brief Retrieves all supported audio encoders by invoking a specific callback for each supported audio encoder. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] callback The iteration callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @post streamrecorder_supported_audio_encoder_cb() will be invoked. + /// @see streamrecorder_set_audio_encoder() + /// @see streamrecorder_get_audio_encoder() + /// @see streamrecorder_supported_audio_encoder_cb() + int streamrecorder_foreach_supported_audio_encoder( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _streamrecorder_foreach_supported_audio_encoder( + recorder, + callback, + user_data, + ); + } + + late final _streamrecorder_foreach_supported_audio_encoder_ptr = _lookup< + ffi.NativeFunction< + _c_streamrecorder_foreach_supported_audio_encoder>>( + 'streamrecorder_foreach_supported_audio_encoder'); + late final _dart_streamrecorder_foreach_supported_audio_encoder + _streamrecorder_foreach_supported_audio_encoder = + _streamrecorder_foreach_supported_audio_encoder_ptr + .asFunction<_dart_streamrecorder_foreach_supported_audio_encoder>(); + + /// @brief Retrieves all supported video encoders by invoking a specific callback for each supported video encoder. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] callback The iteration callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @post streamrecorder_supported_video_encoder_cb() will be invoked. + /// @see streamrecorder_set_video_encoder() + /// @see streamrecorder_get_video_encoder() + /// @see streamrecorder_supported_video_encoder_cb() + int streamrecorder_foreach_supported_video_encoder( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _streamrecorder_foreach_supported_video_encoder( + recorder, + callback, + user_data, + ); + } + + late final _streamrecorder_foreach_supported_video_encoder_ptr = _lookup< + ffi.NativeFunction< + _c_streamrecorder_foreach_supported_video_encoder>>( + 'streamrecorder_foreach_supported_video_encoder'); + late final _dart_streamrecorder_foreach_supported_video_encoder + _streamrecorder_foreach_supported_video_encoder = + _streamrecorder_foreach_supported_video_encoder_ptr + .asFunction<_dart_streamrecorder_foreach_supported_video_encoder>(); + + /// @brief Retrieves all supported video resolutions by invoking callback function once for each supported video resolution. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] foreach_cb The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @post This function invokes streamrecorder_supported_video_resolution_cb() repeatedly to retrieve each supported video resolution. + /// @see streamrecorder_set_video_resolution() + /// @see streamrecorder_get_video_resolution() + /// @see streamrecorder_supported_video_resolution_cb() + int streamrecorder_foreach_supported_video_resolution( + ffi.Pointer recorder, + ffi.Pointer< + ffi.NativeFunction> + foreach_cb, + ffi.Pointer user_data, + ) { + return _streamrecorder_foreach_supported_video_resolution( + recorder, + foreach_cb, + user_data, + ); + } + + late final _streamrecorder_foreach_supported_video_resolution_ptr = _lookup< + ffi.NativeFunction< + _c_streamrecorder_foreach_supported_video_resolution>>( + 'streamrecorder_foreach_supported_video_resolution'); + late final _dart_streamrecorder_foreach_supported_video_resolution + _streamrecorder_foreach_supported_video_resolution = + _streamrecorder_foreach_supported_video_resolution_ptr.asFunction< + _dart_streamrecorder_foreach_supported_video_resolution>(); + + /// @brief Registers the callback function that will be invoked when the streamrecorder get some notification. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] callback The function pointer of user callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @post streamrecorder_notify_cb() will be invoked. + /// @see streamrecorder_unset_notify_cb() + /// @see streamrecorder_notify_cb() + int streamrecorder_set_notify_cb( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _streamrecorder_set_notify_cb( + recorder, + callback, + user_data, + ); + } + + late final _streamrecorder_set_notify_cb_ptr = + _lookup>( + 'streamrecorder_set_notify_cb'); + late final _dart_streamrecorder_set_notify_cb _streamrecorder_set_notify_cb = + _streamrecorder_set_notify_cb_ptr + .asFunction<_dart_streamrecorder_set_notify_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see streamrecorder_set_notify_cb() + int streamrecorder_unset_notify_cb( + ffi.Pointer recorder, + ) { + return _streamrecorder_unset_notify_cb( + recorder, + ); + } + + late final _streamrecorder_unset_notify_cb_ptr = + _lookup>( + 'streamrecorder_unset_notify_cb'); + late final _dart_streamrecorder_unset_notify_cb + _streamrecorder_unset_notify_cb = _streamrecorder_unset_notify_cb_ptr + .asFunction<_dart_streamrecorder_unset_notify_cb>(); + + /// @brief Registers a callback function to be invoked when the recording information changes. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] callback The function pointer of user callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @post streamrecorder_recording_status_cb() will be invoked. + /// @see streamrecorder_unset_recording_status_cb() + /// @see streamrecorder_recording_status_cb() + int streamrecorder_set_recording_status_cb( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _streamrecorder_set_recording_status_cb( + recorder, + callback, + user_data, + ); + } + + late final _streamrecorder_set_recording_status_cb_ptr = + _lookup>( + 'streamrecorder_set_recording_status_cb'); + late final _dart_streamrecorder_set_recording_status_cb + _streamrecorder_set_recording_status_cb = + _streamrecorder_set_recording_status_cb_ptr + .asFunction<_dart_streamrecorder_set_recording_status_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see streamrecorder_set_recording_status_cb() + int streamrecorder_unset_recording_status_cb( + ffi.Pointer recorder, + ) { + return _streamrecorder_unset_recording_status_cb( + recorder, + ); + } + + late final _streamrecorder_unset_recording_status_cb_ptr = + _lookup>( + 'streamrecorder_unset_recording_status_cb'); + late final _dart_streamrecorder_unset_recording_status_cb + _streamrecorder_unset_recording_status_cb = + _streamrecorder_unset_recording_status_cb_ptr + .asFunction<_dart_streamrecorder_unset_recording_status_cb>(); + + /// @brief Registers the callback function to be run when reached the recording limit. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to streamrecorder + /// @param[in] callback The function pointer of user callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @post streamrecorder_recording_limit_reached_cb() will be invoked. + /// @see streamrecorder_unset_recording_limit_reached_cb() + /// @see streamrecorder_set_size_limit() + /// @see streamrecorder_set_time_limit() + /// @see streamrecorder_recording_limit_reached_cb() + int streamrecorder_set_recording_limit_reached_cb( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _streamrecorder_set_recording_limit_reached_cb( + recorder, + callback, + user_data, + ); + } + + late final _streamrecorder_set_recording_limit_reached_cb_ptr = _lookup< + ffi.NativeFunction<_c_streamrecorder_set_recording_limit_reached_cb>>( + 'streamrecorder_set_recording_limit_reached_cb'); + late final _dart_streamrecorder_set_recording_limit_reached_cb + _streamrecorder_set_recording_limit_reached_cb = + _streamrecorder_set_recording_limit_reached_cb_ptr + .asFunction<_dart_streamrecorder_set_recording_limit_reached_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see streamrecorder_set_recording_limit_reached_cb() + int streamrecorder_unset_recording_limit_reached_cb( + ffi.Pointer recorder, + ) { + return _streamrecorder_unset_recording_limit_reached_cb( + recorder, + ); + } + + late final _streamrecorder_unset_recording_limit_reached_cb_ptr = _lookup< + ffi.NativeFunction< + _c_streamrecorder_unset_recording_limit_reached_cb>>( + 'streamrecorder_unset_recording_limit_reached_cb'); + late final _dart_streamrecorder_unset_recording_limit_reached_cb + _streamrecorder_unset_recording_limit_reached_cb = + _streamrecorder_unset_recording_limit_reached_cb_ptr + .asFunction<_dart_streamrecorder_unset_recording_limit_reached_cb>(); + + /// @brief Registers a callback function to be called when an asynchronous operation error occurred. + /// @since_tizen 3.0 + /// @remarks This callback informs critical error situation.\n + /// When this callback is invoked, user should release the resource and terminate the application. \n + /// These error codes will occur. \n + /// #STREAMRECORDER_ERROR_INVALID_OPERATION \n + /// #STREAMRECORDER_ERROR_OUT_OF_MEMORY + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @post This function will invoke streamrecorder_error_cb() when an asynchronous operation error occur. + /// @see streamrecorder_unset_error_cb() + /// @see streamrecorder_error_cb() + int streamrecorder_set_error_cb( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _streamrecorder_set_error_cb( + recorder, + callback, + user_data, + ); + } + + late final _streamrecorder_set_error_cb_ptr = + _lookup>( + 'streamrecorder_set_error_cb'); + late final _dart_streamrecorder_set_error_cb _streamrecorder_set_error_cb = + _streamrecorder_set_error_cb_ptr + .asFunction<_dart_streamrecorder_set_error_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @return @c on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see streamrecorder_set_error_cb() + int streamrecorder_unset_error_cb( + ffi.Pointer recorder, + ) { + return _streamrecorder_unset_error_cb( + recorder, + ); + } + + late final _streamrecorder_unset_error_cb_ptr = + _lookup>( + 'streamrecorder_unset_error_cb'); + late final _dart_streamrecorder_unset_error_cb + _streamrecorder_unset_error_cb = _streamrecorder_unset_error_cb_ptr + .asFunction<_dart_streamrecorder_unset_error_cb>(); + + /// @brief Registers a callback function to be called when asynchronous buffers are consumed. + /// @since_tizen 3.0 + /// @remarks This callback informs to user dealloc buffer.\n + /// When this callback is invoked, user should release the buffer or media packet. \n + /// @param[in] recorder The handle to the streamrecorder + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see streamrecorder_unset_buffer_consume_completed_cb() + /// @see streamrecorder_push_stream_buffer() + int streamrecorder_set_buffer_consume_completed_cb( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _streamrecorder_set_buffer_consume_completed_cb( + recorder, + callback, + user_data, + ); + } + + late final _streamrecorder_set_buffer_consume_completed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_streamrecorder_set_buffer_consume_completed_cb>>( + 'streamrecorder_set_buffer_consume_completed_cb'); + late final _dart_streamrecorder_set_buffer_consume_completed_cb + _streamrecorder_set_buffer_consume_completed_cb = + _streamrecorder_set_buffer_consume_completed_cb_ptr + .asFunction<_dart_streamrecorder_set_buffer_consume_completed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen 3.0 + /// @param[in] recorder The handle to the streamrecorder + /// @return @c on success, otherwise a negative error value + /// @retval #STREAMRECORDER_ERROR_NONE Successful + /// @retval #STREAMRECORDER_ERROR_INVALID_PARAMETER Invalid parameter + /// @see streamrecorder_set_buffer_consume_completed_cb() + int streamrecorder_unset_buffer_consume_completed_cb( + ffi.Pointer recorder, + ) { + return _streamrecorder_unset_buffer_consume_completed_cb( + recorder, + ); + } + + late final _streamrecorder_unset_buffer_consume_completed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_streamrecorder_unset_buffer_consume_completed_cb>>( + 'streamrecorder_unset_buffer_consume_completed_cb'); + late final _dart_streamrecorder_unset_buffer_consume_completed_cb + _streamrecorder_unset_buffer_consume_completed_cb = + _streamrecorder_unset_buffer_consume_completed_cb_ptr + .asFunction<_dart_streamrecorder_unset_buffer_consume_completed_cb>(); + + /// @brief Creates thumbnail info handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks The @a thumb info should be released using thumbnail_util_destroy(). + /// + /// @param[in] thumb The handle to thumbnail info + /// + /// @return @c 0 on success, otherwise a negative error value + /// + /// @retval #THUMBNAIL_UTIL_ERROR_NONE Successful + /// @retval #THUMBNAIL_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #THUMBNAIL_UTIL_ERROR_OUT_OF_MEMORY Not enough memory is available + /// + /// @see thumbnail_util_destroy() + int thumbnail_util_create( + ffi.Pointer> thumb, + ) { + return _thumbnail_util_create( + thumb, + ); + } + + late final _thumbnail_util_create_ptr = + _lookup>( + 'thumbnail_util_create'); + late final _dart_thumbnail_util_create _thumbnail_util_create = + _thumbnail_util_create_ptr.asFunction<_dart_thumbnail_util_create>(); + + /// @brief Extracts the thumbnail for the given media, asynchronously. + /// @details This function extracts the thumbnail for given media item and calls registered + /// callback function for completion of extracting the thumbnail.\n + /// You can distinguish generated thumbnails by @a request_id. Therefore, the @a request_id must be maintained until the request is completed. \n + /// And the @a request_id is also used to cancel the request. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks The @a request_id should be released using free(). \n + /// http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage. \n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. \n + /// If you don't set the size, the thumbnail size will be set default size. Default size is 320x240. \n + /// Color space of the generated thumbnail is BGRA. \n + /// Since 3.0, http://tizen.org/privilege/content.write privilege is not required. \n + /// + /// @param[in] thumb The thumbnail info handle + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] request_id The request id for the thumbnail extraction request + /// + /// @return @c 0 on success, otherwise a negative error value + /// + /// @retval #THUMBNAIL_UTIL_ERROR_NONE Successful + /// @retval #THUMBNAIL_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #THUMBNAIL_UTIL_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre Create a thumbnail info handle by calling thumbnail_util_create(). \n + /// The content path that you want to generate thumbnail must be set by calling thumbnail_util_set_path(). + /// @post Thumbnail extraction result except canceled is provided by thumbnail_extracted_cb(). + /// @see thumbnail_util_create() + /// @see thumbnail_util_set_path() + /// @see thumbnail_util_set_size() + /// @see thumbnail_extracted_cb() + /// @see thumbnail_util_cancel() + /// @see thumbnail_util_destroy() + int thumbnail_util_extract( + ffi.Pointer thumb, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer> request_id, + ) { + return _thumbnail_util_extract( + thumb, + callback, + user_data, + request_id, + ); + } + + late final _thumbnail_util_extract_ptr = + _lookup>( + 'thumbnail_util_extract'); + late final _dart_thumbnail_util_extract _thumbnail_util_extract = + _thumbnail_util_extract_ptr.asFunction<_dart_thumbnail_util_extract>(); + + /// @brief Sets the path of original media file. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] thumb The thumbnail info handle + /// @param[in] path The path of the original media file + /// + /// @return @c 0 on success, otherwise a negative error value + /// + /// @retval #THUMBNAIL_UTIL_ERROR_NONE Successful + /// @retval #THUMBNAIL_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre Create a thumbnail info handle by calling thumbnail_util_create(). + /// @see thumbnail_util_create() + /// @see thumbnail_util_set_size() + /// @see thumbnail_util_destroy() + int thumbnail_util_set_path( + ffi.Pointer thumb, + ffi.Pointer path, + ) { + return _thumbnail_util_set_path( + thumb, + path, + ); + } + + late final _thumbnail_util_set_path_ptr = + _lookup>( + 'thumbnail_util_set_path'); + late final _dart_thumbnail_util_set_path _thumbnail_util_set_path = + _thumbnail_util_set_path_ptr.asFunction<_dart_thumbnail_util_set_path>(); + + /// @brief Sets the size of thumbnail to be extracted. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks If you don't set the size, the thumbnail size will be set default size. Default size is 320x240. \n + /// If the set width is not a multiple of 8, it can be changed by inner process. the width will be a multiple of 8 greater than the set value. + /// + /// @param[in] thumb The thumbnail info handle + /// @param[in] width The width of the thumbnail + /// @param[in] height The height of the thumbnail + /// + /// @return @c 0 on success, otherwise a negative error value + /// + /// @retval #THUMBNAIL_UTIL_ERROR_NONE Successful + /// @retval #THUMBNAIL_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre Create a thumbnail info handle by calling thumbnail_util_create(). + /// @see thumbnail_util_create() + /// @see thumbnail_util_set_path() + /// @see thumbnail_util_destroy() + int thumbnail_util_set_size( + ffi.Pointer thumb, + int width, + int height, + ) { + return _thumbnail_util_set_size( + thumb, + width, + height, + ); + } + + late final _thumbnail_util_set_size_ptr = + _lookup>( + 'thumbnail_util_set_size'); + late final _dart_thumbnail_util_set_size _thumbnail_util_set_size = + _thumbnail_util_set_size_ptr.asFunction<_dart_thumbnail_util_set_size>(); + + /// @brief Cancels the thumbnail extraction request for the given media. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks If there is no request to be canceled, this function returns #THUMBNAIL_UTIL_ERROR_INVALID_OPERATION + /// + /// @param[in] thumb The media thumbnail info handle + /// @param[in] request_id The generated request id by thumbnail extraction request + /// + /// @return @c 0 on success, otherwise a negative error value + /// + /// @retval #THUMBNAIL_UTIL_ERROR_NONE Successful + /// @retval #THUMBNAIL_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre It is available before thumbnail_extracted_cb() is called. + /// @see thumbnail_util_extract() + int thumbnail_util_cancel( + ffi.Pointer thumb, + ffi.Pointer request_id, + ) { + return _thumbnail_util_cancel( + thumb, + request_id, + ); + } + + late final _thumbnail_util_cancel_ptr = + _lookup>( + 'thumbnail_util_cancel'); + late final _dart_thumbnail_util_cancel _thumbnail_util_cancel = + _thumbnail_util_cancel_ptr.asFunction<_dart_thumbnail_util_cancel>(); + + /// @deprecated Deprecated since 4.0. Use thumbnail_util_cancel() instead. + /// @brief Cancels all thumbnail extraction requests associated with the given thumbnail info handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks If there is no item you want to cancel, this function return MEDIA_CONTENT_ERROR_INVALID_OPERATION + /// + /// @param[in] thumb The media thumbnail info handle + /// + /// @return @c 0 on success, otherwise a negative error value + /// + /// @retval #THUMBNAIL_UTIL_ERROR_NONE Successful + /// @retval #THUMBNAIL_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre It is available before thumbnail_extracted_cb() is called. + /// @see thumbnail_util_extract() + int thumbnail_util_cancel_all( + ffi.Pointer thumb, + ) { + return _thumbnail_util_cancel_all( + thumb, + ); + } + + late final _thumbnail_util_cancel_all_ptr = + _lookup>( + 'thumbnail_util_cancel_all'); + late final _dart_thumbnail_util_cancel_all _thumbnail_util_cancel_all = + _thumbnail_util_cancel_all_ptr + .asFunction<_dart_thumbnail_util_cancel_all>(); + + /// @brief Destroys thumbnail info handle. + /// @details The function frees all resources related to the thumbnail info handle. This handle + /// can no longer be used to perform any operation. New thumbnail info handle has to + /// be created before the next usage. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] thumb The thumbnail info handle + /// + /// @return @c 0 on success, otherwise a negative error value + /// + /// @retval #THUMBNAIL_UTIL_ERROR_NONE Successful + /// @retval #THUMBNAIL_UTIL_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre Create a thumbnail info handle by calling thumbnail_util_create(). + /// @see thumbnail_util_create() + int thumbnail_util_destroy( + ffi.Pointer thumb, + ) { + return _thumbnail_util_destroy( + thumb, + ); + } + + late final _thumbnail_util_destroy_ptr = + _lookup>( + 'thumbnail_util_destroy'); + late final _dart_thumbnail_util_destroy _thumbnail_util_destroy = + _thumbnail_util_destroy_ptr.asFunction<_dart_thumbnail_util_destroy>(); + + /// @deprecated Deprecated since 3.0. Use tone_player_start_new() instead. + /// @brief Plays a tone. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks Sound can be mixed with other sounds if you don't control the sound session in sound-manager module since 3.0.\n + /// You can refer to @ref CAPI_MEDIA_SOUND_MANAGER_MODULE. + /// + /// @param[in] tone The tone type to play + /// @param[in] type The sound type + /// @param[in] duration_ms The tone duration in milliseconds \n + /// @c -1 indicates an infinite duration. + /// @param[out] id The tone player ID ( can be set to @c NULL ) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TONE_PLAYER_ERROR_NONE Successful + /// @retval #TONE_PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TONE_PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see tone_player_stop() + int tone_player_start( + int tone, + int type, + int duration_ms, + ffi.Pointer id, + ) { + return _tone_player_start( + tone, + type, + duration_ms, + id, + ); + } + + late final _tone_player_start_ptr = + _lookup>('tone_player_start'); + late final _dart_tone_player_start _tone_player_start = + _tone_player_start_ptr.asFunction<_dart_tone_player_start>(); + + /// @brief Plays a tone with stream information of sound-manager. + /// + /// @since_tizen 3.0 + /// + /// @remarks Voice Recognition stream type is not supported in this API. + /// + /// @param[in] tone The tone type to play + /// @param[in] stream_info The sound stream information handle + /// @param[in] duration_ms The tone duration in milliseconds \n + /// @c -1 indicates an infinite duration. + /// @param[out] id The tone player ID ( can be set to @c NULL ) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TONE_PLAYER_ERROR_NONE Successful + /// @retval #TONE_PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TONE_PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #TONE_PLAYER_ERROR_NOT_SUPPORTED_TYPE Not supported stream type + /// + /// @see tone_player_stop() + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + int tone_player_start_new( + int tone, + ffi.Pointer stream_info, + int duration_ms, + ffi.Pointer id, + ) { + return _tone_player_start_new( + tone, + stream_info, + duration_ms, + id, + ); + } + + late final _tone_player_start_new_ptr = + _lookup>( + 'tone_player_start_new'); + late final _dart_tone_player_start_new _tone_player_start_new = + _tone_player_start_new_ptr.asFunction<_dart_tone_player_start_new>(); + + /// @brief Stops playing the tone. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] id The tone player ID to stop + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #TONE_PLAYER_ERROR_NONE Successful + /// @retval #TONE_PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TONE_PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see tone_player_start() + int tone_player_stop( + int id, + ) { + return _tone_player_stop( + id, + ); + } + + late final _tone_player_stop_ptr = + _lookup>('tone_player_stop'); + late final _dart_tone_player_stop _tone_player_stop = + _tone_player_stop_ptr.asFunction<_dart_tone_player_stop>(); + + /// @deprecated Deprecated since 3.0. Use wav_player_start_new() instead. + /// @brief Plays a WAV file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks Sound can be mixed with other sounds if you don't control the sound session in sound-manager module since 3.0.\n + /// You can refer to @ref CAPI_MEDIA_SOUND_MANAGER_MODULE. + /// + /// @param[in] path The file path to play + /// @param[in] type The sound type + /// @param[in] callback The callback function to invoke when a WAV file is finished playing + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] id The WAV player ID ( can be set to NULL ) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #WAV_PLAYER_ERROR_NONE Successful + /// @retval #WAV_PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WAV_PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WAV_PLAYER_ERROR_FORMAT_NOT_SUPPORTED Not supported format + /// + /// @post It invokes wav_player_playback_completed_cb() when a WAV file has finished playing. + /// @see wav_player_stop() + /// @see wav_player_playback_completed_cb() + int wav_player_start( + ffi.Pointer path, + int type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, + ) { + return _wav_player_start( + path, + type, + callback, + user_data, + id, + ); + } + + late final _wav_player_start_ptr = + _lookup>('wav_player_start'); + late final _dart_wav_player_start _wav_player_start = + _wav_player_start_ptr.asFunction<_dart_wav_player_start>(); + + /// @brief Plays a WAV file with stream information of sound-manager. + /// @since_tizen 3.0 + /// + /// @remarks Voice Recognition and VOIP stream types are not supported in this API. + /// + /// @param[in] path The file path to play + /// @param[in] stream_info The sound stream information handle + /// @param[in] callback The callback function to be invoked when a WAV file is no longer being played + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] id The WAV player ID (can be set to @c NULL) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #WAV_PLAYER_ERROR_NONE Successful + /// @retval #WAV_PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WAV_PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WAV_PLAYER_ERROR_FORMAT_NOT_SUPPORTED Not supported format + /// @retval #WAV_PLAYER_ERROR_NOT_SUPPORTED_TYPE Not supported stream type + /// + /// @post It invokes wav_player_playback_completed_cb() when a WAV file is no longer being played. + /// @see wav_player_stop() + /// @see wav_player_playback_completed_cb() + /// @see sound_manager_create_stream_information() + /// @see sound_manager_destroy_stream_information() + int wav_player_start_new( + ffi.Pointer path, + ffi.Pointer stream_info, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, + ) { + return _wav_player_start_new( + path, + stream_info, + callback, + user_data, + id, + ); + } + + late final _wav_player_start_new_ptr = + _lookup>( + 'wav_player_start_new'); + late final _dart_wav_player_start_new _wav_player_start_new = + _wav_player_start_new_ptr.asFunction<_dart_wav_player_start_new>(); + + /// @brief Stops playing the WAV file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] id The WAV player ID to stop + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #WAV_PLAYER_ERROR_NONE Successful + /// @retval #WAV_PLAYER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WAV_PLAYER_ERROR_INVALID_OPERATION Invalid operation + /// + /// @see wav_player_start() + int wav_player_stop( + int id, + ) { + return _wav_player_stop( + id, + ); + } + + late final _wav_player_stop_ptr = + _lookup>('wav_player_stop'); + late final _dart_wav_player_stop _wav_player_stop = + _wav_player_stop_ptr.asFunction<_dart_wav_player_stop>(); + + /// @brief Initializes Application Service Platform (ASP). + /// @since_tizen 4.0 + /// @return 0 on success, otherwise a negative error value. + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_RESOURCE_BUSY Device or resource busy + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_COMMUNICATION_FAILED Communication failed + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @see asp_deinitialize() + int asp_initialize() { + return _asp_initialize(); + } + + late final _asp_initialize_ptr = + _lookup>('asp_initialize'); + late final _dart_asp_initialize _asp_initialize = + _asp_initialize_ptr.asFunction<_dart_asp_initialize>(); + + /// @brief Deinitializes Application Service Platform (ASP). + /// @since_tizen 4.0 + /// @privilege http://tizen.org/privilege/wifidirect + /// @return 0 on success, otherwise a negative error value. + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_COMMUNICATION_FAILED Communication failed + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_initialize() + int asp_deinitialize() { + return _asp_deinitialize(); + } + + late final _asp_deinitialize_ptr = + _lookup>('asp_deinitialize'); + late final _dart_asp_deinitialize _asp_deinitialize = + _asp_deinitialize_ptr.asFunction<_dart_asp_deinitialize>(); + + /// @brief Registers the callback function that will be invoked when a service found. + /// @since_tizen 4.0 + /// @param[in] cb The callback function to invoke + /// @param[in] user_data The user data passed from the callback registration function + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @post asp_search_result_cb will be called under certain conditions, + /// after calling asp_seek_start() + /// @see asp_initialize() + /// @see asp_seek_unset_search_result_cb() + /// @see asp_seek_start() + int asp_seek_set_search_result_cb( + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _asp_seek_set_search_result_cb( + cb, + user_data, + ); + } + + late final _asp_seek_set_search_result_cb_ptr = + _lookup>( + 'asp_seek_set_search_result_cb'); + late final _dart_asp_seek_set_search_result_cb + _asp_seek_set_search_result_cb = _asp_seek_set_search_result_cb_ptr + .asFunction<_dart_asp_seek_set_search_result_cb>(); + + /// @brief Unregisters the callback function that will invoked when a service found. + /// @since_tizen 4.0 + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_initialize() + /// @see asp_seek_set_search_result_cb() + int asp_seek_unset_search_result_cb() { + return _asp_seek_unset_search_result_cb(); + } + + late final _asp_seek_unset_search_result_cb_ptr = + _lookup>( + 'asp_seek_unset_search_result_cb'); + late final _dart_asp_seek_unset_search_result_cb + _asp_seek_unset_search_result_cb = _asp_seek_unset_search_result_cb_ptr + .asFunction<_dart_asp_seek_unset_search_result_cb>(); + + /// @brief Registers the callback function that will invoked when the status of an advertisement to a service is changed. + /// @since_tizen 4.0 + /// @param[in] cb The callback function to invoke + /// @param[in] user_data The user data passed from the callback registration function + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @post asp_seek_search_result_cb() will be called under certain conditions, + /// after calling asp_seek_start() + /// @see asp_initialize() + /// @see asp_advert_unset_status_changed_cb() + /// @see asp_advert_start_advertising() + int asp_advert_set_status_changed_cb( + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _asp_advert_set_status_changed_cb( + cb, + user_data, + ); + } + + late final _asp_advert_set_status_changed_cb_ptr = + _lookup>( + 'asp_advert_set_status_changed_cb'); + late final _dart_asp_advert_set_status_changed_cb + _asp_advert_set_status_changed_cb = _asp_advert_set_status_changed_cb_ptr + .asFunction<_dart_asp_advert_set_status_changed_cb>(); + + /// @brief Unregisters the callback function that will invoked when the status of an advertisement to a service is changed. + /// @since_tizen 4.0 + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_initialize() + /// @see asp_advert_set_status_changed_cb() + int asp_advert_unset_status_changed_cb() { + return _asp_advert_unset_status_changed_cb(); + } + + late final _asp_advert_unset_status_changed_cb_ptr = + _lookup>( + 'asp_advert_unset_status_changed_cb'); + late final _dart_asp_advert_unset_status_changed_cb + _asp_advert_unset_status_changed_cb = + _asp_advert_unset_status_changed_cb_ptr + .asFunction<_dart_asp_advert_unset_status_changed_cb>(); + + /// @brief Registers the callback called when ASP session connection is requested. + /// @since_tizen 4.0 + /// @param[in] cb The callback function to invoke + /// @param[in] user_data The user data passed from the callback registration function + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_initialize() + /// @see asp_session_unset_request_cb() + int asp_session_set_request_cb( + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _asp_session_set_request_cb( + cb, + user_data, + ); + } + + late final _asp_session_set_request_cb_ptr = + _lookup>( + 'asp_session_set_request_cb'); + late final _dart_asp_session_set_request_cb _asp_session_set_request_cb = + _asp_session_set_request_cb_ptr + .asFunction<_dart_asp_session_set_request_cb>(); + + /// @brief Unregisters the callback called ASP when session connection is requested. + /// @since_tizen 4.0 + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_initialize() + /// @see asp_session_set_request_cb() + int asp_session_unset_request_cb() { + return _asp_session_unset_request_cb(); + } + + late final _asp_session_unset_request_cb_ptr = + _lookup>( + 'asp_session_unset_request_cb'); + late final _dart_asp_session_unset_request_cb _asp_session_unset_request_cb = + _asp_session_unset_request_cb_ptr + .asFunction<_dart_asp_session_unset_request_cb>(); + + /// @brief Registers the callback called when the session configuration is requested. + /// @since_tizen 4.0 + /// @param[in] cb The callback function to invoke + /// @param[in] user_data The user data passed from the callback registration function + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_initialize() + /// @see asp_session_unset_config_request_cb() + /// @see asp_session_config_request_cb() + int asp_session_set_config_request_cb( + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _asp_session_set_config_request_cb( + cb, + user_data, + ); + } + + late final _asp_session_set_config_request_cb_ptr = + _lookup>( + 'asp_session_set_config_request_cb'); + late final _dart_asp_session_set_config_request_cb + _asp_session_set_config_request_cb = + _asp_session_set_config_request_cb_ptr + .asFunction<_dart_asp_session_set_config_request_cb>(); + + /// @brief Unregisters the callback called when the session configuration is requested. + /// @since_tizen 4.0 + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_initialize() + /// @see asp_session_config_request_cb() + int asp_session_unset_config_request_cb() { + return _asp_session_unset_config_request_cb(); + } + + late final _asp_session_unset_config_request_cb_ptr = + _lookup>( + 'asp_session_unset_config_request_cb'); + late final _dart_asp_session_unset_config_request_cb + _asp_session_unset_config_request_cb = + _asp_session_unset_config_request_cb_ptr + .asFunction<_dart_asp_session_unset_config_request_cb>(); + + /// @brief Registers the callback called when the state of the session connection is changed. + /// @since_tizen 4.0 + /// @param[in] cb The callback function to invoke + /// @param[in] user_data The user data passed from the callback registration function + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_initialize() + /// @see asp_session_unset_connection_status_changed_cb() + /// @see asp_session_connect_status_cb() + int asp_session_set_connect_status_cb( + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _asp_session_set_connect_status_cb( + cb, + user_data, + ); + } + + late final _asp_session_set_connect_status_cb_ptr = + _lookup>( + 'asp_session_set_connect_status_cb'); + late final _dart_asp_session_set_connect_status_cb + _asp_session_set_connect_status_cb = + _asp_session_set_connect_status_cb_ptr + .asFunction<_dart_asp_session_set_connect_status_cb>(); + + /// @brief Unregisters the callback called when the state of the session connection is changed. + /// @since_tizen 4.0 + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_initialize() + /// @see asp_session_set_connection_status_changed_cb() + int asp_session_unset_connect_status_cb() { + return _asp_session_unset_connect_status_cb(); + } + + late final _asp_session_unset_connect_status_cb_ptr = + _lookup>( + 'asp_session_unset_connect_status_cb'); + late final _dart_asp_session_unset_connect_status_cb + _asp_session_unset_connect_status_cb = + _asp_session_unset_connect_status_cb_ptr + .asFunction<_dart_asp_session_unset_connect_status_cb>(); + + /// @brief Registers the callback called when the state of the session is changed. + /// @since_tizen 4.0 + /// @param[in] cb The callback function to invoke + /// @param[in] user_data The user data passed from the callback registration function + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_initialize() + /// @see asp_session_unset_status_cb() + /// @see asp_session_status_cb() + int asp_session_set_status_cb( + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _asp_session_set_status_cb( + cb, + user_data, + ); + } + + late final _asp_session_set_status_cb_ptr = + _lookup>( + 'asp_session_set_status_cb'); + late final _dart_asp_session_set_status_cb _asp_session_set_status_cb = + _asp_session_set_status_cb_ptr + .asFunction<_dart_asp_session_set_status_cb>(); + + /// @brief Unregisters the callback called when the state of the session is changed. + /// @since_tizen 4.0 + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_initialize() + /// @see asp_session_set_status_cb() + int asp_session_unset_status_cb() { + return _asp_session_unset_status_cb(); + } + + late final _asp_session_unset_status_cb_ptr = + _lookup>( + 'asp_session_unset_status_cb'); + late final _dart_asp_session_unset_status_cb _asp_session_unset_status_cb = + _asp_session_unset_status_cb_ptr + .asFunction<_dart_asp_session_unset_status_cb>(); + + /// @brief Registers the callback called when the state of the port is changed. + /// @since_tizen 4.0 + /// @param[in] cb The callback function to invoke + /// @param[in] user_data The user data passed from the callback registration function + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_initialize() + /// @see asp_session_unset_status_cb() + int asp_session_set_port_status_cb( + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _asp_session_set_port_status_cb( + cb, + user_data, + ); + } + + late final _asp_session_set_port_status_cb_ptr = + _lookup>( + 'asp_session_set_port_status_cb'); + late final _dart_asp_session_set_port_status_cb + _asp_session_set_port_status_cb = _asp_session_set_port_status_cb_ptr + .asFunction<_dart_asp_session_set_port_status_cb>(); + + /// @brief Unregisters the callback called when the state of the port is changed. + /// @since_tizen 4.0 + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_initialize() + /// @see asp_session_set_port_status_cb() + int asp_session_unset_port_status_cb() { + return _asp_session_unset_port_status_cb(); + } + + late final _asp_session_unset_port_status_cb_ptr = + _lookup>( + 'asp_session_unset_port_status_cb'); + late final _dart_asp_session_unset_port_status_cb + _asp_session_unset_port_status_cb = _asp_session_unset_port_status_cb_ptr + .asFunction<_dart_asp_session_unset_port_status_cb>(); + + /// @brief Creates the description of a service to be advertised. + /// @since_tizen 4.0 + /// @remarks The @a adv_service should be released using asp_advert_destroy(). + /// @param[in] instance_name Service instance name of a service type to be advertised. + /// The length of this parameter be 63 byte or less and + /// encoding shall be single-byte or multi-byte UTF-8 characters. + /// If you want to advertise one of the original P2PS defined services, + /// this shall be NULL. + /// @param[out] adv_service service descriptor handle + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_advert_destroy() + int asp_advert_create( + ffi.Pointer instance_name, + ffi.Pointer> adv_service, + ) { + return _asp_advert_create( + instance_name, + adv_service, + ); + } + + late final _asp_advert_create_ptr = + _lookup>('asp_advert_create'); + late final _dart_asp_advert_create _asp_advert_create = + _asp_advert_create_ptr.asFunction<_dart_asp_advert_create>(); + + /// @brief Destroys the description of a service to be advertised. + /// @details If asp_advert_start_advertising() was called for a service, + /// asp_advert_stop_advertising() should be called for it before destroying it. + /// @since_tizen 4.0 + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_create_service() before use + /// @see asp_advert_create() + int asp_advert_destroy( + ffi.Pointer adv_service, + ) { + return _asp_advert_destroy( + adv_service, + ); + } + + late final _asp_advert_destroy_ptr = + _lookup>('asp_advert_destroy'); + late final _dart_asp_advert_destroy _asp_advert_destroy = + _asp_advert_destroy_ptr.asFunction<_dart_asp_advert_destroy>(); + + /// @brief Sets the service type for a service to be advertised. + /// @details Application should set service type after creating service using + /// asp_advert_create() and before advertising service using + /// asp_advert_start_advertising(). + /// @since_tizen 4.0 + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @param[in] service_type The unique type of a particular service. + /// this shall be at least 1 character and no more than 15 characters long + /// contain only US-ASCII [ANSI.X3.4-1986] letters 'A' - 'Z' and + /// 'a' - 'z', digits '0' - '9', and hyphens ('-', ASCII 0x2D or decimal 45) + /// contain at least one letter ('A' - 'Z' or 'a' - ‘z') + /// not begin or end with a hyphen. If you want to advertise one of the + /// original P2PS defined services, this means service name. + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_create() before use + /// @see asp_advert_create() + int asp_advert_set_service_type( + ffi.Pointer adv_service, + ffi.Pointer service_type, + ) { + return _asp_advert_set_service_type( + adv_service, + service_type, + ); + } + + late final _asp_advert_set_service_type_ptr = + _lookup>( + 'asp_advert_set_service_type'); + late final _dart_asp_advert_set_service_type _asp_advert_set_service_type = + _asp_advert_set_service_type_ptr + .asFunction<_dart_asp_advert_set_service_type>(); + + /// @brief Sets auto accept for a service to be advertised. + /// @details Application should set service auto accept after creating service using + /// asp_advert_create() and before advertising service using + /// asp_advert_start_advertising(). + /// @since_tizen 4.0 + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @param[in] auto_accept Enables/Disables auto accept based on the value TRUE/FALSE + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_create() before use + /// @see asp_advert_create() + int asp_advert_set_auto_accept( + ffi.Pointer adv_service, + bool auto_accept, + ) { + return _asp_advert_set_auto_accept( + adv_service, + auto_accept ? 1 : 0, + ); + } + + late final _asp_advert_set_auto_accept_ptr = + _lookup>( + 'asp_advert_set_auto_accept'); + late final _dart_asp_advert_set_auto_accept _asp_advert_set_auto_accept = + _asp_advert_set_auto_accept_ptr + .asFunction<_dart_asp_advert_set_auto_accept>(); + + /// @brief Adds the information for a service to be advertised. + /// @details Application should set service information after creating service using + /// asp_advert_create() and before advertising service using + /// asp_advert_start_advertising(). + /// @since_tizen 4.0 + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @param[in] key Service-defined key data specified in Section 6 of RFC6763 + /// @param[in] value Service-defined value data specified in Section 6 of RFC6763 + /// Only one value can be added for a given key. If a value is set for a key, + /// and another value was set for the key before, the old value will be + /// overwritten with the new one. + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_create() before use + /// @see asp_advert_create() + int asp_advert_add_info( + ffi.Pointer adv_service, + ffi.Pointer key, + ffi.Pointer value, + ) { + return _asp_advert_add_info( + adv_service, + key, + value, + ); + } + + late final _asp_advert_add_info_ptr = + _lookup>( + 'asp_advert_add_info'); + late final _dart_asp_advert_add_info _asp_advert_add_info = + _asp_advert_add_info_ptr.asFunction<_dart_asp_advert_add_info>(); + + /// @brief Sets the information for a service to be advertised. + /// @details Application should set service information after creating service using + /// asp_advert_create() and before advertising service using + /// asp_advert_start_advertising(). + /// @since_tizen 4.0 + /// @remarks @a value should not be freed. + /// It is recommended to make a copy of it to use. + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @param[in] key Service-defined key data specified in Section 6 of RFC6763 + /// @param[in] length Length of service-defined value data specified in Section 6 of RFC6763 + /// @param[in] value Service-defined value data specified in Section 6 of RFC6763 + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_create() before use + /// @see asp_advert_create() + int asp_advert_get_info( + ffi.Pointer adv_service, + ffi.Pointer key, + ffi.Pointer length, + ffi.Pointer> value, + ) { + return _asp_advert_get_info( + adv_service, + key, + length, + value, + ); + } + + late final _asp_advert_get_info_ptr = + _lookup>( + 'asp_advert_get_info'); + late final _dart_asp_advert_get_info _asp_advert_get_info = + _asp_advert_get_info_ptr.asFunction<_dart_asp_advert_get_info>(); + + /// @brief Sets the information for a service to be advertised. + /// @details Application should set service information after creating service using + /// asp_advert_create() and before advertising service using + /// asp_advert_start_advertising(). + /// @since_tizen 4.0 + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @param[in] key Service-defined key data specified to be removed + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_create() before use + /// @see asp_advert_create() + int asp_advert_remove_info( + ffi.Pointer adv_service, + ffi.Pointer key, + ) { + return _asp_advert_remove_info( + adv_service, + key, + ); + } + + late final _asp_advert_remove_info_ptr = + _lookup>( + 'asp_advert_remove_info'); + late final _dart_asp_advert_remove_info _asp_advert_remove_info = + _asp_advert_remove_info_ptr.asFunction<_dart_asp_advert_remove_info>(); + + /// @brief Sets the status for a service to be advertised. + /// @details Application should set service status after creating service using + /// asp_advert_create() and before advertising service using + /// asp_advert_start_advertising(). + /// @since_tizen 4.0 + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @param[in] status Status of the service: + /// (@c 1 = available to use, @c 0 = not available to use, + /// @c 2-255 = service specific information) + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_create() before use + /// @see asp_advert_create() + int asp_advert_set_status( + ffi.Pointer adv_service, + int status, + ) { + return _asp_advert_set_status( + adv_service, + status, + ); + } + + late final _asp_advert_set_status_ptr = + _lookup>( + 'asp_advert_set_status'); + late final _dart_asp_advert_set_status _asp_advert_set_status = + _asp_advert_set_status_ptr.asFunction<_dart_asp_advert_set_status>(); + + /// @brief Sets the discovery mechanism for a service to be advertised. + /// @details Application should set discovery mechanism after creating service using + /// asp_advert_create() and before advertising service using + /// asp_advert_start_advertising(). + /// @since_tizen 4.0 + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @param[in] discovery_tech The discovery mechanism; values of + /// #asp_discovery_tech_e combined with bitwise 'or' + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_create() before use + /// @see asp_advert_create() + int asp_advert_set_discovery_tech( + ffi.Pointer adv_service, + int discovery_tech, + ) { + return _asp_advert_set_discovery_tech( + adv_service, + discovery_tech, + ); + } + + late final _asp_advert_set_discovery_tech_ptr = + _lookup>( + 'asp_advert_set_discovery_tech'); + late final _dart_asp_advert_set_discovery_tech + _asp_advert_set_discovery_tech = _asp_advert_set_discovery_tech_ptr + .asFunction<_dart_asp_advert_set_discovery_tech>(); + + /// @brief Sets the preferred connection for a service to be advertised. + /// @details Application should set preferred connection after creating service using + /// asp_advert_create() and before advertising service using + /// asp_advert_start_advertising(). + /// @since_tizen 4.0 + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @param[in] preferred_connection The preferred connection + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_create() before use + /// @see asp_advert_create() + int asp_advert_set_preferred_connection( + ffi.Pointer adv_service, + int preferred_connection, + ) { + return _asp_advert_set_preferred_connection( + adv_service, + preferred_connection, + ); + } + + late final _asp_advert_set_preferred_connection_ptr = + _lookup>( + 'asp_advert_set_preferred_connection'); + late final _dart_asp_advert_set_preferred_connection + _asp_advert_set_preferred_connection = + _asp_advert_set_preferred_connection_ptr + .asFunction<_dart_asp_advert_set_preferred_connection>(); + + /// @brief Sets the Wi-Fi P2P role for a service to be advertised. + /// @details Application should set role after creating service using + /// asp_advert_create() and before advertising service using + /// asp_advert_start_advertising(). + /// @since_tizen 4.0 + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @param[in] role The role of the service: \n + /// #ASP_ADVERT_P2P_ROLE_SCHEME_ANY - All roles are acceptable \n + /// #ASP_ADVERT_P2P_ROLE_SCHEME_GO - The receiving interface should assume \n + /// the GO role, if it's not possible, #ASP_ERROR_NETWORK_ROLE_REJECTED \n + /// is returned \n + /// #ASP_ADVERT_P2P_ROLE_SCHEME_GC - + /// The receiving interface should assume the GC role + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @retval #ASP_ERROR_NETWORK_ROLE_REJECTED Network role rejected + /// @pre This API needs asp_advert_create() before use + /// @see asp_advert_create() + int asp_advert_set_p2p_role_scheme( + ffi.Pointer adv_service, + int role, + ) { + return _asp_advert_set_p2p_role_scheme( + adv_service, + role, + ); + } + + late final _asp_advert_set_p2p_role_scheme_ptr = + _lookup>( + 'asp_advert_set_p2p_role_scheme'); + late final _dart_asp_advert_set_p2p_role_scheme + _asp_advert_set_p2p_role_scheme = _asp_advert_set_p2p_role_scheme_ptr + .asFunction<_dart_asp_advert_set_p2p_role_scheme>(); + + /// @brief Gets the Wi-Fi P2P role for a service to be advertised. + /// @details Application should Get role after creating service using + /// asp_advert_create() and before advertising service using + /// asp_advert_start_advertising(). + /// @since_tizen 4.0 + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @param[in] role The role of the service: \n + /// #ASP_ADVERT_P2P_ROLE_SCHEME_ANY - All roles are acceptable \n + /// #ASP_ADVERT_P2P_ROLE_SCHEME_GO - The receiving interface should assume \n + /// the GO role \n + /// #ASP_ADVERT_P2P_ROLE_SCHEME_GC - + /// The receiving interface should assume the GC role + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_create() before use + /// @see asp_advert_create() + int asp_advert_get_p2p_role_scheme( + ffi.Pointer adv_service, + ffi.Pointer role, + ) { + return _asp_advert_get_p2p_role_scheme( + adv_service, + role, + ); + } + + late final _asp_advert_get_p2p_role_scheme_ptr = + _lookup>( + 'asp_advert_get_p2p_role_scheme'); + late final _dart_asp_advert_get_p2p_role_scheme + _asp_advert_get_p2p_role_scheme = _asp_advert_get_p2p_role_scheme_ptr + .asFunction<_dart_asp_advert_get_p2p_role_scheme>(); + + /// @brief Sets the P2P configuration method for a service to be advertised. + /// @details Application should set configuration method after creating service using + /// asp_advert_create() and before advertising service using + /// asp_advert_start_advertising(). + /// @since_tizen 4.0 + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @param[in] config_method preferred Wi-Fi Simple Config (WSC) configuration method. + /// Default value is ASP_WPS_TYPE_DEFAULT. + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_create() before use + /// @see asp_advert_create() + int asp_advert_set_p2p_config_method( + ffi.Pointer adv_service, + int config_method, + ) { + return _asp_advert_set_p2p_config_method( + adv_service, + config_method, + ); + } + + late final _asp_advert_set_p2p_config_method_ptr = + _lookup>( + 'asp_advert_set_p2p_config_method'); + late final _dart_asp_advert_set_p2p_config_method + _asp_advert_set_p2p_config_method = _asp_advert_set_p2p_config_method_ptr + .asFunction<_dart_asp_advert_set_p2p_config_method>(); + + /// @brief Gets the P2P configuration method for a service to be advertised. + /// @details Application should Get configuration method after creating service using + /// asp_advert_create() and before advertising service using + /// asp_advert_start_advertising(). + /// @since_tizen 4.0 + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @param[in] config_method preferred Wi-Fi Simple Config (WSC)configuration method. + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_create() before use + /// @see asp_advert_create() + int asp_advert_get_p2p_config_method( + ffi.Pointer adv_service, + ffi.Pointer config_method, + ) { + return _asp_advert_get_p2p_config_method( + adv_service, + config_method, + ); + } + + late final _asp_advert_get_p2p_config_method_ptr = + _lookup>( + 'asp_advert_get_p2p_config_method'); + late final _dart_asp_advert_get_p2p_config_method + _asp_advert_get_p2p_config_method = _asp_advert_get_p2p_config_method_ptr + .asFunction<_dart_asp_advert_get_p2p_config_method>(); + + /// @brief Sets the service response for an advertised service. + /// @details Application should set service response after creating service using + /// asp_advert_create() and before advertising service using + /// asp_advert_create(). + /// @since_tizen 4.0 + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @param[in] rsp_info Specified for a particular service up to 144 bytes. + /// You can refer to Wi-Fi Peer-to-Peer Services Technical Specification, + /// Wi-Fi Alliance. Available at:http://www.wi-fi.org + /// @param[in] length The length of @a rsp_info in bytes, maximum length is 144 + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_create() before use + /// @see asp_advert_create() + int asp_advert_set_p2p_response( + ffi.Pointer adv_service, + ffi.Pointer rsp_info, + int length, + ) { + return _asp_advert_set_p2p_response( + adv_service, + rsp_info, + length, + ); + } + + late final _asp_advert_set_p2p_response_ptr = + _lookup>( + 'asp_advert_set_p2p_response'); + late final _dart_asp_advert_set_p2p_response _asp_advert_set_p2p_response = + _asp_advert_set_p2p_response_ptr + .asFunction<_dart_asp_advert_set_p2p_response>(); + + /// @brief Starts to advertise a service. + /// @details Application should start to advertise after creating service using + /// asp_advert_create(). If the service is being advertised, no changes can be made to it. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/wifidirect + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_create() before use + /// @see asp_advert_create() + /// @see asp_advert_stop_advertising() + int asp_advert_start_advertising( + ffi.Pointer adv_service, + ) { + return _asp_advert_start_advertising( + adv_service, + ); + } + + late final _asp_advert_start_advertising_ptr = + _lookup>( + 'asp_advert_start_advertising'); + late final _dart_asp_advert_start_advertising _asp_advert_start_advertising = + _asp_advert_start_advertising_ptr + .asFunction<_dart_asp_advert_start_advertising>(); + + /// @brief Stops a service advertisement. + /// @details Application should cancel to advertise after advertising service using + /// asp_advert_start_advertising(). + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/wifidirect + /// @param[in] adv_service Service descriptor handle provided by the asp_advert_create() + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_start_advertising() before use + /// @see asp_advert_start_advertising() + int asp_advert_stop_advertising( + ffi.Pointer adv_service, + ) { + return _asp_advert_stop_advertising( + adv_service, + ); + } + + late final _asp_advert_stop_advertising_ptr = + _lookup>( + 'asp_advert_stop_advertising'); + late final _dart_asp_advert_stop_advertising _asp_advert_stop_advertising = + _asp_advert_stop_advertising_ptr + .asFunction<_dart_asp_advert_stop_advertising>(); + + /// @brief Changes the advertising service status. + /// @details Application should change the advertising service + /// status after advertising service using asp_advert_start_advertising(). + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/wifidirect + /// @param[in] adv_service Service descriptor handle provided by the asp_create_service() + /// @param[in] status Status of the service: + /// (@c 1 = available to use, @c 0 = not available to use, + /// @c 2-255 = service specific information) + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_advert_start_advertising() before use + /// @see asp_advert_start_advertising() + int asp_advert_change_service_status( + ffi.Pointer adv_service, + int status, + ) { + return _asp_advert_change_service_status( + adv_service, + status, + ); + } + + late final _asp_advert_change_service_status_ptr = + _lookup>( + 'asp_advert_change_service_status'); + late final _dart_asp_advert_change_service_status + _asp_advert_change_service_status = _asp_advert_change_service_status_ptr + .asFunction<_dart_asp_advert_change_service_status>(); + + /// @brief Creates the description of a seek operation. + /// @remarks The @a seek_service should be released using asp_seek_destroy(). + /// @since_tizen 4.0 + /// @param[in] service_type Service Type of a service being searched. + /// this shall be at least 1 character and no more than 15 characters long + /// contain only US-ASCII [ANSI.X3.4-1986] letters 'A' - 'Z' and + /// 'a' - 'z', digits '0' - '9', and hyphens ('-', ASCII 0x2D or decimal 45) + /// contain at least one letter ('A' - 'Z' or 'a' - ‘z') + /// not begin or end with a hyphen. If you want to seek one of the + /// original P2PS defined services, this means service name. + /// @param[out] seek_service Service seek handle + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @pre Application Service Platform (ASP) must be initialized by asp_initialize(). + /// @see asp_seek_destroy() + int asp_seek_create( + ffi.Pointer service_type, + ffi.Pointer> seek_service, + ) { + return _asp_seek_create( + service_type, + seek_service, + ); + } + + late final _asp_seek_create_ptr = + _lookup>('asp_seek_create'); + late final _dart_asp_seek_create _asp_seek_create = + _asp_seek_create_ptr.asFunction<_dart_asp_seek_create>(); + + /// @brief Destroys the description of a seek operation. + /// @details If asp_seek_start() was called for a service, + /// asp_seek_stop() should be called for it before destroying it. + /// asp_seek_stop(). + /// @since_tizen 4.0 + /// @param[in] seek_service Service seek handle provided by the asp_seek_create() + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre A seek service handle must be created with asp_seek_create(). + /// @see asp_seek_create + int asp_seek_destroy( + ffi.Pointer seek_service, + ) { + return _asp_seek_destroy( + seek_service, + ); + } + + late final _asp_seek_destroy_ptr = + _lookup>('asp_seek_destroy'); + late final _dart_asp_seek_destroy _asp_seek_destroy = + _asp_seek_destroy_ptr.asFunction<_dart_asp_seek_destroy>(); + + /// @brief Adds the information for a service to be sought. + /// @details Application should set service information after creating service using + /// asp_seek_create() and before seeking service using asp_seek_start(). + /// @since_tizen 4.0 + /// @privlevel public + /// @param[in] seek_service Service descriptor handle provided by the asp_seek_create() + /// @param[in] key Service-defined key data to be searched, + /// specified in Section 6 of RFC6763 + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_seek_create() before use + /// @see asp_seek_create() + int asp_seek_add_info( + ffi.Pointer seek_service, + ffi.Pointer key, + ) { + return _asp_seek_add_info( + seek_service, + key, + ); + } + + late final _asp_seek_add_info_ptr = + _lookup>('asp_seek_add_info'); + late final _dart_asp_seek_add_info _asp_seek_add_info = + _asp_seek_add_info_ptr.asFunction<_dart_asp_seek_add_info>(); + + /// @brief Removes the information for a service to be sought. + /// @details Application should set service information after creating service using + /// asp_seek_create() and before seeking service using asp_seek_start(). + /// @since_tizen 4.0 + /// @param[in] seek_service Service descriptor handle provided by the asp_seek_create() + /// @param[in] key Service-defined key data to be searched, + /// specified in Section 6 of RFC6763 + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_seek_create() before use + /// @see asp_seek_create() + int asp_seek_remove_info( + ffi.Pointer seek_service, + ffi.Pointer key, + ) { + return _asp_seek_remove_info( + seek_service, + key, + ); + } + + late final _asp_seek_remove_info_ptr = + _lookup>( + 'asp_seek_remove_info'); + late final _dart_asp_seek_remove_info _asp_seek_remove_info = + _asp_seek_remove_info_ptr.asFunction<_dart_asp_seek_remove_info>(); + + /// @brief Sets the discovery mechanism for a service to be sought. + /// @details Application should set service information after creating service using + /// asp_seek_create() and before seeking service using asp_seek_start(). + /// @since_tizen 4.0 + /// @param[in] seek_service Service descriptor handle provided by the asp_seek_create() + /// @param[in] discovery_tech The discovery mechanism, values of + /// #asp_discovery_tech_e combined with bitwise 'or' + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_seek_create() before use + /// @see asp_seek_create() + int asp_seek_set_discovery_tech( + ffi.Pointer seek_service, + int discovery_tech, + ) { + return _asp_seek_set_discovery_tech( + seek_service, + discovery_tech, + ); + } + + late final _asp_seek_set_discovery_tech_ptr = + _lookup>( + 'asp_seek_set_discovery_tech'); + late final _dart_asp_seek_set_discovery_tech _asp_seek_set_discovery_tech = + _asp_seek_set_discovery_tech_ptr + .asFunction<_dart_asp_seek_set_discovery_tech>(); + + /// @brief Sets the preferred connection for a service to be sought. + /// @details Application should set service information after creating service using + /// asp_seek_create() and before seeking service using asp_seek_start(). + /// @since_tizen 4.0 + /// @param[in] seek_service Service descriptor handle provided by the asp_seek_create() + /// @param[in] preferred_connection The preferred connection + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre This API needs asp_seek_create() before use + /// @see asp_seek_create() + int asp_seek_set_preferred_connection( + ffi.Pointer seek_service, + int preferred_connection, + ) { + return _asp_seek_set_preferred_connection( + seek_service, + preferred_connection, + ); + } + + late final _asp_seek_set_preferred_connection_ptr = + _lookup>( + 'asp_seek_set_preferred_connection'); + late final _dart_asp_seek_set_preferred_connection + _asp_seek_set_preferred_connection = + _asp_seek_set_preferred_connection_ptr + .asFunction<_dart_asp_seek_set_preferred_connection>(); + + /// @brief Starts to seek services on peer devices. + /// @details If the service is currently seeking, no changes can be made to it. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/wifidirect + /// @param[in] seek_service Service seek handle provided by the asp_seek_create() + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre A seek service handle must be created with asp_seek_create(). + /// @see asp_seek_create() + /// @see asp_seek_stop() + int asp_seek_start( + ffi.Pointer seek_service, + ) { + return _asp_seek_start( + seek_service, + ); + } + + late final _asp_seek_start_ptr = + _lookup>('asp_seek_start'); + late final _dart_asp_seek_start _asp_seek_start = + _asp_seek_start_ptr.asFunction<_dart_asp_seek_start>(); + + /// @brief Stops seeking services. + /// @details Application should cancel to seek service after searching service using + /// asp_seek_start(). + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/wifidirect + /// @param[in] seek_service Service seek handle provided by the asp_seek_create() + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SERVICE_NOT_FOUND Service not found + /// @pre A seek service handle must be created with asp_seek_create(). + /// @see asp_seek_start() + int asp_seek_stop( + ffi.Pointer seek_service, + ) { + return _asp_seek_stop( + seek_service, + ); + } + + late final _asp_seek_stop_ptr = + _lookup>('asp_seek_stop'); + late final _dart_asp_seek_stop _asp_seek_stop = + _asp_seek_stop_ptr.asFunction<_dart_asp_seek_stop>(); + + /// @brief Creates a local Application Service Platform (ASP) session. + /// @since_tizen 4.0 + /// @remarks The @a session should be released using asp_session_destroy(). + /// @param[in] service_mac P2P device address of remote P2P device provided by + /// asp_seek_search_result_cb() + /// @param[in] adv_id The advertisement ID provided by + /// asp_seek_search_result_cb() + /// @param[in] session ASP session descriptor handle + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @see asp_session_destroy() + int asp_session_create( + ffi.Pointer service_mac, + int adv_id, + ffi.Pointer> session, + ) { + return _asp_session_create( + service_mac, + adv_id, + session, + ); + } + + late final _asp_session_create_ptr = + _lookup>('asp_session_create'); + late final _dart_asp_session_create _asp_session_create = + _asp_session_create_ptr.asFunction<_dart_asp_session_create>(); + + /// @brief Destroys a local Application Service Platform (ASP) session. + /// @details Application should create session by asp_session_create(). + /// @since_tizen 4.0 + /// @param[in] session Application Service Platform session descriptor handle + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @pre This API needs asp_session_create() before use. + /// @see asp_session_create() + int asp_session_destroy( + ffi.Pointer session, + ) { + return _asp_session_destroy( + session, + ); + } + + late final _asp_session_destroy_ptr = + _lookup>( + 'asp_session_destroy'); + late final _dart_asp_session_destroy _asp_session_destroy = + _asp_session_destroy_ptr.asFunction<_dart_asp_session_destroy>(); + + /// @brief Gets the session MAC for an Application Service Platform session. + /// @details Application should request to connect session by + /// asp_session_connect() or receive request by asp_session_request_cb(). + /// @since_tizen 4.0 + /// @remarks @a session_mac should not be freed. + /// It is recommended to make a copy of it to use. + /// @param[in] session Application Service Platform session descriptor handle + /// @param[out] session_mac The session MAC is the MAC address of + /// P2P device which assigned the session ID + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @pre This API needs asp_session_connect() before use. + /// @see asp_session_connect() + /// @see asp_session_request_cb() + int asp_session_get_mac( + ffi.Pointer session, + ffi.Pointer> session_mac, + ) { + return _asp_session_get_mac( + session, + session_mac, + ); + } + + late final _asp_session_get_mac_ptr = + _lookup>( + 'asp_session_get_mac'); + late final _dart_asp_session_get_mac _asp_session_get_mac = + _asp_session_get_mac_ptr.asFunction<_dart_asp_session_get_mac>(); + + /// @brief Gets the ID of an Application Service Platform session. + /// @details Application should create local session by + /// asp_session_create() or receive request by asp_session_request_cb(). + /// @since_tizen 4.0 + /// @param[in] session Application Service Platform session descriptor handle + /// @param[out] session_id The session ID + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @pre This API needs asp_session_create() before use. + /// @see asp_session_create() + /// @see asp_session_request_cb() + int asp_session_get_id( + ffi.Pointer session, + ffi.Pointer session_id, + ) { + return _asp_session_get_id( + session, + session_id, + ); + } + + late final _asp_session_get_id_ptr = + _lookup>('asp_session_get_id'); + late final _dart_asp_session_get_id _asp_session_get_id = + _asp_session_get_id_ptr.asFunction<_dart_asp_session_get_id>(); + + /// @brief Sets the information for an Application Service Platform session. + /// @details Application should set session_info after creating session by + /// asp_session_create() and before requesting to connect + /// session by asp_session_connect(). + /// @since_tizen 4.0 + /// @param[in] session Application Service Platform session descriptor handle + /// provided by the asp_session_create() + /// @param[in] session_info Detailed information about the session. + /// The session_info parameter is defined for each service section + /// and up to 144 bytes. You can refer to Wi-Fi Peer-to-Peer Services + /// Technical Specification, Wi-Fi Alliance. + /// Available at:http://www.wi-fi.org + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @pre This API needs asp_session_create() before use. + /// @see asp_session_create() + int asp_session_set_info( + ffi.Pointer session, + ffi.Pointer session_info, + ) { + return _asp_session_set_info( + session, + session_info, + ); + } + + late final _asp_session_set_info_ptr = + _lookup>( + 'asp_session_set_info'); + late final _dart_asp_session_set_info _asp_session_set_info = + _asp_session_set_info_ptr.asFunction<_dart_asp_session_set_info>(); + + /// @brief Gets the information for an Application Service Platform session. + /// @details Application should get session_info after creating session by + /// asp_session_create() and before requesting to connect + /// session by asp_session_connect(). + /// @since_tizen 4.0 + /// @remarks @a session_info should not be freed. + /// It is recommended to make a copy of it to use. + /// @param[in] session Application Service Platform session descriptor handle + /// provided by the asp_session_create() + /// @param[out] session_info detailed information about session + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @pre This API needs asp_session_create() before use. + /// @see asp_session_create() + int asp_session_get_info( + ffi.Pointer session, + ffi.Pointer> session_info, + ) { + return _asp_session_get_info( + session, + session_info, + ); + } + + late final _asp_session_get_info_ptr = + _lookup>( + 'asp_session_get_info'); + late final _dart_asp_session_get_info _asp_session_get_info = + _asp_session_get_info_ptr.asFunction<_dart_asp_session_get_info>(); + + /// @brief Sets the Wi-Fi Direct group role in session. + /// @details Application should set role after creating session by + /// asp_session_create() and before requesting to connect + /// session by asp_session_connect(). + /// @since_tizen 4.0 + /// @param[in] session Application Service Platform session descriptor handle + /// provided by the asp_session_create() + /// @param[in] role The role of the service: \n + /// #ASP_ADVERT_P2P_ROLE_SCHEME_ANY - All roles are acceptable \n + /// #ASP_ADVERT_P2P_ROLE_SCHEME_GO - The receiving interface should assume \n + /// the GO role, if it's not possible, #ASP_ERROR_NETWORK_ROLE_REJECTED \n + /// is returned \n + /// #ASP_ADVERT_P2P_ROLE_SCHEME_GC - + /// The receiving interface should assume the GC role + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @retval #ASP_ERROR_NETWORK_ROLE_REJECTED Network role rejected + /// @pre This API needs asp_create_service() before use. + /// @see asp_create_session() + int asp_session_set_p2p_role_scheme( + ffi.Pointer session, + int role, + ) { + return _asp_session_set_p2p_role_scheme( + session, + role, + ); + } + + late final _asp_session_set_p2p_role_scheme_ptr = + _lookup>( + 'asp_session_set_p2p_role_scheme'); + late final _dart_asp_session_set_p2p_role_scheme + _asp_session_set_p2p_role_scheme = _asp_session_set_p2p_role_scheme_ptr + .asFunction<_dart_asp_session_set_p2p_role_scheme>(); + + /// @brief Gets the Wi-Fi Direct group role in session. + /// @since_tizen 4.0 + /// @param[in] session Application Service Platform session descriptor handle + /// provided by the asp_session_create() + /// @param[in] role The role of the service: \n + /// #ASP_ADVERT_P2P_ROLE_SCHEME_ANY - All roles are acceptable \n + /// #ASP_ADVERT_P2P_ROLE_SCHEME_GO - The receiving interface should assume \n + /// the GO role\n + /// #ASP_ADVERT_P2P_ROLE_SCHEME_GC - + /// The receiving interface should assume the GC role + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @pre This API needs asp_session_create() before use. + /// @see asp_session_create() + int asp_session_get_p2p_role_scheme( + ffi.Pointer session, + ffi.Pointer role, + ) { + return _asp_session_get_p2p_role_scheme( + session, + role, + ); + } + + late final _asp_session_get_p2p_role_scheme_ptr = + _lookup>( + 'asp_session_get_p2p_role_scheme'); + late final _dart_asp_session_get_p2p_role_scheme + _asp_session_get_p2p_role_scheme = _asp_session_get_p2p_role_scheme_ptr + .asFunction<_dart_asp_session_get_p2p_role_scheme>(); + + /// @brief Sets the Preferred WSC Configuration method. + /// @details Application should set the config method after creating session by + /// asp_session_create() and before requesting to connect + /// session by asp_session_connect(). + /// @since_tizen 4.0 + /// @param[in] session Application Service Platform session descriptor handle + /// provided by the asp_session_create() + /// @param[in] config_method Preferred WSC Configuration method. + /// Default value is #ASP_WPS_TYPE_DEFAULT. + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @pre This API needs asp_session_create() before use. + /// @see asp_session_create() + int asp_session_set_p2p_config_method( + ffi.Pointer session, + int config_method, + ) { + return _asp_session_set_p2p_config_method( + session, + config_method, + ); + } + + late final _asp_session_set_p2p_config_method_ptr = + _lookup>( + 'asp_session_set_p2p_config_method'); + late final _dart_asp_session_set_p2p_config_method + _asp_session_set_p2p_config_method = + _asp_session_set_p2p_config_method_ptr + .asFunction<_dart_asp_session_set_p2p_config_method>(); + + /// @brief Gets the Preferred WSC Configuration method. + /// @since_tizen 4.0 + /// @param[in] session Application Service Platform session descriptor handle + /// provided by the asp_session_create() + /// @param[out] config_method Preferred WSC Configuration method + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @pre This API needs asp_session_create() before use. + /// @see asp_session_create() + int asp_session_get_p2p_config_method( + ffi.Pointer session, + ffi.Pointer config_method, + ) { + return _asp_session_get_p2p_config_method( + session, + config_method, + ); + } + + late final _asp_session_get_p2p_config_method_ptr = + _lookup>( + 'asp_session_get_p2p_config_method'); + late final _dart_asp_session_get_p2p_config_method + _asp_session_get_p2p_config_method = + _asp_session_get_p2p_config_method_ptr + .asFunction<_dart_asp_session_get_p2p_config_method>(); + + /// @brief Gets the session close status. + /// @details This call is valid only for closed sessions (sessions in the #ASP_SESSION_STATE_CLOSED + /// state). If the @a session does not identify a closed session, + /// #ASP_ERROR_NOT_PERMITTED is returned. + /// @since_tizen 4.0 + /// @param[in] session ASP session descriptor handle provided by + /// the asp_session_request_cb() callback, + /// asp_session_create(), or asp_session_get_handle() + /// @param[out] status The session close status + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + int asp_session_get_close_status( + ffi.Pointer session, + ffi.Pointer status, + ) { + return _asp_session_get_close_status( + session, + status, + ); + } + + late final _asp_session_get_close_status_ptr = + _lookup>( + 'asp_session_get_close_status'); + late final _dart_asp_session_get_close_status _asp_session_get_close_status = + _asp_session_get_close_status_ptr + .asFunction<_dart_asp_session_get_close_status>(); + + /// @brief Starts to connect the Application Service Platform session. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/wifidirect + /// @param[in] session Application Service Platform session descriptor handle + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @pre This API needs asp_session_create() before use. + /// @see asp_session_create() + int asp_session_connect( + ffi.Pointer session, + ) { + return _asp_session_connect( + session, + ); + } + + late final _asp_session_connect_ptr = + _lookup>( + 'asp_session_connect'); + late final _dart_asp_session_connect _asp_session_connect = + _asp_session_connect_ptr.asFunction<_dart_asp_session_connect>(); + + /// @brief Confirms the Application Service Platform(ASP) session request. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/wifidirect + /// @param[in] session ASP session descriptor handle provided by + /// the asp_session_request_cb() callback or + /// asp_session_create() if pin is requested. + /// @param[in] confirmed (@c true = confirm session, @c false = reject session) + /// @param[in] pin If session requests the WSC PIN + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @see asp_advert_start_advertising() + /// @see asp_session_create() + int asp_session_confirm( + ffi.Pointer session, + bool confirmed, + ffi.Pointer pin, + ) { + return _asp_session_confirm( + session, + confirmed ? 1 : 0, + pin, + ); + } + + late final _asp_session_confirm_ptr = + _lookup>( + 'asp_session_confirm'); + late final _dart_asp_session_confirm _asp_session_confirm = + _asp_session_confirm_ptr.asFunction<_dart_asp_session_confirm>(); + + /// @brief Gets the Description of Application Service Platform (ASP) session to be connected. + /// @since_tizen 4.0 + /// @param[in] session_mac The MAC address of the P2P device that assigned + /// the value of session_id, as provided by + /// the asp_session_request_cb() callback or + /// asp_session_create() if pin is requested. + /// @param[in] session_id The session ID + /// @param[out] session Peer-to-Peer service session descriptor handle + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @see asp_session_create() + int asp_session_get_handle( + ffi.Pointer session_mac, + int session_id, + ffi.Pointer> session, + ) { + return _asp_session_get_handle( + session_mac, + session_id, + session, + ); + } + + late final _asp_session_get_handle_ptr = + _lookup>( + 'asp_session_get_handle'); + late final _dart_asp_session_get_handle _asp_session_get_handle = + _asp_session_get_handle_ptr.asFunction<_dart_asp_session_get_handle>(); + + /// @brief Moves an Application Service Platform (ASP) session from Requested state to the Open state. + /// @since_tizen 4.0 + /// @param[in] session ASP session descriptor handle provided by + /// the asp_session_request_cb() callback + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @pre Peer-to-Peer service must be advertised by asp_advert_start_advertising().\n + /// Local device should be listening or finding remote P2P device by + /// asp_advert_start_advertising() + /// @see asp_advert_start_advertising() + int asp_session_set_state_ready( + ffi.Pointer session, + ) { + return _asp_session_set_state_ready( + session, + ); + } + + late final _asp_session_set_state_ready_ptr = + _lookup>( + 'asp_session_set_state_ready'); + late final _dart_asp_session_set_state_ready _asp_session_set_state_ready = + _asp_session_set_state_ready_ptr + .asFunction<_dart_asp_session_set_state_ready>(); + + /// @brief Ends an Application Service Platform (ASP) session and releases associated resources. + /// @details The ASP may tear down the underlying ASP P2P group + /// if not other ASP sessions are using it. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/wifidirect + /// @param[in] session ASP session descriptor handle provided by + /// the asp_session_request_cb() callback or + /// asp_session_create() + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_PERMISSION_DENIED Permission denied + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @see asp_session_create() + /// @see asp_session_request_cb() + int asp_session_close( + ffi.Pointer session, + ) { + return _asp_session_close( + session, + ); + } + + late final _asp_session_close_ptr = + _lookup>('asp_session_close'); + late final _dart_asp_session_close _asp_session_close = + _asp_session_close_ptr.asFunction<_dart_asp_session_close>(); + + /// @brief Requests that incoming connections be allowed on a given port. + /// @since_tizen 4.0 + /// @param[in] session ASP session descriptor handle provided by + /// the asp_session_request_cb() callback or + /// asp_session_create() + /// @param[in] ip_address The IP address on which the port is being used + /// @param[in] port The port number + /// @param[in] proto The IANA protocol number + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @see asp_session_create() + /// @see asp_session_request_cb() + int asp_session_bind_port( + ffi.Pointer session, + ffi.Pointer ip_address, + int port, + int proto, + ) { + return _asp_session_bind_port( + session, + ip_address, + port, + proto, + ); + } + + late final _asp_session_bind_port_ptr = + _lookup>( + 'asp_session_bind_port'); + late final _dart_asp_session_bind_port _asp_session_bind_port = + _asp_session_bind_port_ptr.asFunction<_dart_asp_session_bind_port>(); + + /// @brief Indicates that the service is no longer utilizing the port in the ASP session. + /// @since_tizen 4.0 + /// @param[in] session ASP session descriptor handle provided by + /// the asp_session_request_cb() callback or + /// asp_session_create() + /// @param[in] ip_address The IP address on which the port is being used + /// @param[in] port The port number + /// @param[in] proto The IANA protocol number + /// @return 0 on success, otherwise a negative error value + /// @retval #ASP_ERROR_NONE Successful + /// @retval #ASP_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #ASP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #ASP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #ASP_ERROR_NOT_SUPPORTED Not supported + /// @retval #ASP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #ASP_ERROR_OPERATION_FAILED Operation failed + /// @retval #ASP_ERROR_SESSION_NOT_FOUND Session not found + /// @see asp_session_create() + /// @see asp_session_request_cb() + int asp_session_release_port( + ffi.Pointer session, + ffi.Pointer ip_address, + int port, + int proto, + ) { + return _asp_session_release_port( + session, + ip_address, + port, + proto, + ); + } + + late final _asp_session_release_port_ptr = + _lookup>( + 'asp_session_release_port'); + late final _dart_asp_session_release_port _asp_session_release_port = + _asp_session_release_port_ptr + .asFunction<_dart_asp_session_release_port>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_MODULE + /// @brief Initializes the Bluetooth API. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @remarks This function must be called before Bluetooth API starts. \n + /// You must free all resources of the Bluetooth service by calling bt_deinitialize() if Bluetooth service is no longer needed. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_deinitialize() + int bt_initialize() { + return _bt_initialize(); + } + + late final _bt_initialize_ptr = + _lookup>('bt_initialize'); + late final _dart_bt_initialize _bt_initialize = + _bt_initialize_ptr.asFunction<_dart_bt_initialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_MODULE + /// @brief Releases all resources of the Bluetooth API. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @remarks This function must be called if Bluetooth API is no longer needed. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Bluetooth API must be initialized with bt_initialize(). + /// + /// @see bt_initialize() + int bt_deinitialize() { + return _bt_deinitialize(); + } + + late final _bt_deinitialize_ptr = + _lookup>('bt_deinitialize'); + late final _dart_bt_deinitialize _bt_deinitialize = + _bt_deinitialize_ptr.asFunction<_dart_bt_deinitialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_MODULE + /// @brief Gets the specification name for the given UUID. + /// @since_tizen 3.0 + /// + /// @remarks The @a name must be released using free(). + /// + /// @param[in] uuid The UUID + /// @param[out] name The specification name defined at www.bluetooth.com + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_get_uuid() + int bt_get_uuid_name( + ffi.Pointer uuid, + ffi.Pointer> name, + ) { + return _bt_get_uuid_name( + uuid, + name, + ); + } + + late final _bt_get_uuid_name_ptr = + _lookup>('bt_get_uuid_name'); + late final _dart_bt_get_uuid_name _bt_get_uuid_name = + _bt_get_uuid_name_ptr.asFunction<_dart_bt_get_uuid_name>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Gets the current state of local Bluetooth adapter. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[out] adapter_state The current adapter state + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_initialize() + int bt_adapter_get_state( + ffi.Pointer adapter_state, + ) { + return _bt_adapter_get_state( + adapter_state, + ); + } + + late final _bt_adapter_get_state_ptr = + _lookup>( + 'bt_adapter_get_state'); + late final _dart_bt_adapter_get_state _bt_adapter_get_state = + _bt_adapter_get_state_ptr.asFunction<_dart_bt_adapter_get_state>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Gets the address of local Bluetooth adapter. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @remarks The @a local_address must be released with free() by you. + /// + /// @param[out] local_address The device address of local Bluetooth adapter + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @see bt_adapter_get_name() + int bt_adapter_get_address( + ffi.Pointer> local_address, + ) { + return _bt_adapter_get_address( + local_address, + ); + } + + late final _bt_adapter_get_address_ptr = + _lookup>( + 'bt_adapter_get_address'); + late final _dart_bt_adapter_get_address _bt_adapter_get_address = + _bt_adapter_get_address_ptr.asFunction<_dart_bt_adapter_get_address>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Gets the name of local Bluetooth adapter. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @details Use this function to get the friendly name associated with Bluetooth + /// device, retrieved by the remote Bluetooth devices. + /// + /// @remarks The @a local_name must be released with free() by you. + /// + /// @param[out] local_name The local device name + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// + /// @see bt_adapter_set_name() + int bt_adapter_get_name( + ffi.Pointer> local_name, + ) { + return _bt_adapter_get_name( + local_name, + ); + } + + late final _bt_adapter_get_name_ptr = + _lookup>( + 'bt_adapter_get_name'); + late final _dart_bt_adapter_get_name _bt_adapter_get_name = + _bt_adapter_get_name_ptr.asFunction<_dart_bt_adapter_get_name>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Sets the name of local Bluetooth adapter. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] local_name The name of the Bluetooth device. \n + /// The maximum length is 248 characters. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @post bt_adapter_name_changed_cb() will be invoked if this function returns #BT_ERROR_NONE. + /// + /// @see bt_adapter_get_name() + /// @see bt_adapter_name_changed_cb() + /// @see bt_adapter_set_name_changed_cb() + /// @see bt_adapter_unset_name_changed_cb() + int bt_adapter_set_name( + ffi.Pointer local_name, + ) { + return _bt_adapter_set_name( + local_name, + ); + } + + late final _bt_adapter_set_name_ptr = + _lookup>( + 'bt_adapter_set_name'); + late final _dart_bt_adapter_set_name _bt_adapter_set_name = + _bt_adapter_set_name_ptr.asFunction<_dart_bt_adapter_set_name>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Gets the visibility mode of local Bluetooth adapter. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[out] mode The visibility mode of the Bluetooth device + /// @param[out] duration The duration until the visibility mode is changed to #BT_ADAPTER_VISIBILITY_MODE_NON_DISCOVERABLE (in seconds). + /// @a duration is valid only if @a mode is #BT_ADAPTER_VISIBILITY_MODE_LIMITED_DISCOVERABLE. This value can be NULL. + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + int bt_adapter_get_visibility( + ffi.Pointer mode, + ffi.Pointer duration, + ) { + return _bt_adapter_get_visibility( + mode, + duration, + ); + } + + late final _bt_adapter_get_visibility_ptr = + _lookup>( + 'bt_adapter_get_visibility'); + late final _dart_bt_adapter_get_visibility _bt_adapter_get_visibility = + _bt_adapter_get_visibility_ptr + .asFunction<_dart_bt_adapter_get_visibility>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Starts the device discovery, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @details If a device is discovered, bt_adapter_device_discovery_state_changed_cb() will be invoked + /// with #BT_ADAPTER_DEVICE_DISCOVERY_FOUND, and then bt_adapter_device_discovery_state_changed_cb() + /// will be called with #BT_ADAPTER_DEVICE_DISCOVERY_FINISHED in case of the completion or cancellation of the discovery. + /// + /// @remarks To connect to peer Bluetooth device, you need to know its Bluetooth address. \n + /// The device discovery can be stopped by bt_adapter_stop_device_discovery(). + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOW_IN_PROGRESS Operation is now in progress + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @post This function invokes bt_adapter_device_discovery_state_changed_cb(). + /// + /// @see bt_adapter_is_discovering() + /// @see bt_adapter_stop_device_discovery() + /// @see bt_adapter_device_discovery_state_changed_cb() + /// @see bt_adapter_set_device_discovery_state_changed_cb() + /// @see bt_adapter_unset_device_discovery_state_changed_cb() + int bt_adapter_start_device_discovery() { + return _bt_adapter_start_device_discovery(); + } + + late final _bt_adapter_start_device_discovery_ptr = + _lookup>( + 'bt_adapter_start_device_discovery'); + late final _dart_bt_adapter_start_device_discovery + _bt_adapter_start_device_discovery = + _bt_adapter_start_device_discovery_ptr + .asFunction<_dart_bt_adapter_start_device_discovery>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Stops the device discovery, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @remarks The device discovery process will take 10 ~ 20 seconds to get all the devices in vicinity. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOT_IN_PROGRESS Operation is not in progress + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The device discovery must be in progress with bt_adapter_start_device_discovery(). + /// @post This function invokes bt_adapter_device_discovery_state_changed_cb(). + /// + /// @see bt_adapter_is_discovering() + /// @see bt_adapter_start_device_discovery() + /// @see bt_adapter_set_device_discovery_state_changed_cb() + /// @see bt_adapter_unset_device_discovery_state_changed_cb() + /// @see bt_adapter_device_discovery_state_changed_cb() + int bt_adapter_stop_device_discovery() { + return _bt_adapter_stop_device_discovery(); + } + + late final _bt_adapter_stop_device_discovery_ptr = + _lookup>( + 'bt_adapter_stop_device_discovery'); + late final _dart_bt_adapter_stop_device_discovery + _bt_adapter_stop_device_discovery = _bt_adapter_stop_device_discovery_ptr + .asFunction<_dart_bt_adapter_stop_device_discovery>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Checks for the device discovery is in progress or not. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @remarks If Bluetooth discovery is in progress, other operations are not allowed and + /// you have to either stop the discovery operation, or wait for it to be finished, + /// before performing other operations. + /// + /// @param[out] is_discovering The discovering status: (@c true = in progress , @c false = not in progress ) + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// + /// @see bt_adapter_start_device_discovery() + /// @see bt_adapter_stop_device_discovery() + int bt_adapter_is_discovering( + ffi.Pointer is_discovering, + ) { + return _bt_adapter_is_discovering( + is_discovering, + ); + } + + late final _bt_adapter_is_discovering_ptr = + _lookup>( + 'bt_adapter_is_discovering'); + late final _dart_bt_adapter_is_discovering _bt_adapter_is_discovering = + _bt_adapter_is_discovering_ptr + .asFunction<_dart_bt_adapter_is_discovering>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Get the service mask from the uuid list. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[in] uuids The UUID list of the device. + /// @param[in] no_of_service The number of the UUID list count. + /// @param[out] service_mask_list Service mask list converted from the given UUID list. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_service_class_t + int bt_device_get_service_mask_from_uuid_list( + ffi.Pointer> uuids, + int no_of_service, + ffi.Pointer service_mask_list, + ) { + return _bt_device_get_service_mask_from_uuid_list( + uuids, + no_of_service, + service_mask_list, + ); + } + + late final _bt_device_get_service_mask_from_uuid_list_ptr = + _lookup>( + 'bt_device_get_service_mask_from_uuid_list'); + late final _dart_bt_device_get_service_mask_from_uuid_list + _bt_device_get_service_mask_from_uuid_list = + _bt_device_get_service_mask_from_uuid_list_ptr + .asFunction<_dart_bt_device_get_service_mask_from_uuid_list>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Retrieves the device information of all bonded devices. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param [in] callback The callback function to invoke + /// @param [in] user_data The user data passed from the foreach function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @post This function invokes bt_adapter_bonded_device_cb(). + /// + /// @see bt_adapter_bonded_device_cb() + int bt_adapter_foreach_bonded_device( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_adapter_foreach_bonded_device( + callback, + user_data, + ); + } + + late final _bt_adapter_foreach_bonded_device_ptr = + _lookup>( + 'bt_adapter_foreach_bonded_device'); + late final _dart_bt_adapter_foreach_bonded_device + _bt_adapter_foreach_bonded_device = _bt_adapter_foreach_bonded_device_ptr + .asFunction<_dart_bt_adapter_foreach_bonded_device>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Gets the device information of a bonded device. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks The @a device_info must be released with bt_adapter_free_device_info() by you . + /// + /// @param [in] remote_address The address of remote device + /// @param [out] device_info The bonded device information + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_BONDED Remote device not bonded + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @post This function invokes bt_adapter_bonded_device_cb(). + /// + /// @see bt_adapter_bonded_device_cb() + int bt_adapter_get_bonded_device_info( + ffi.Pointer remote_address, + ffi.Pointer> device_info, + ) { + return _bt_adapter_get_bonded_device_info( + remote_address, + device_info, + ); + } + + late final _bt_adapter_get_bonded_device_info_ptr = + _lookup>( + 'bt_adapter_get_bonded_device_info'); + late final _dart_bt_adapter_get_bonded_device_info + _bt_adapter_get_bonded_device_info = + _bt_adapter_get_bonded_device_info_ptr + .asFunction<_dart_bt_adapter_get_bonded_device_info>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Frees device info. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param [in] device_info The bonded device information + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_adapter_get_bonded_device_info() + int bt_adapter_free_device_info( + ffi.Pointer device_info, + ) { + return _bt_adapter_free_device_info( + device_info, + ); + } + + late final _bt_adapter_free_device_info_ptr = + _lookup>( + 'bt_adapter_free_device_info'); + late final _dart_bt_adapter_free_device_info _bt_adapter_free_device_info = + _bt_adapter_free_device_info_ptr + .asFunction<_dart_bt_adapter_free_device_info>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Checks whether the UUID of service is used or not + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] service_uuid The UUID of service + /// @param[out] used Indicates whether the service is used or not + /// @return true on success, otherwise false. + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_adapter_is_service_used( + ffi.Pointer service_uuid, + ffi.Pointer used, + ) { + return _bt_adapter_is_service_used( + service_uuid, + used, + ); + } + + late final _bt_adapter_is_service_used_ptr = + _lookup>( + 'bt_adapter_is_service_used'); + late final _dart_bt_adapter_is_service_used _bt_adapter_is_service_used = + _bt_adapter_is_service_used_ptr + .asFunction<_dart_bt_adapter_is_service_used>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Registers a callback function to be invoked when the Bluetooth adapter state changes. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post bt_adapter_state_changed_cb() will be invoked. + /// + /// @see bt_initialize() + /// @see bt_adapter_state_changed_cb() + /// @see bt_adapter_set_state_changed_cb() + /// @see bt_adapter_unset_state_changed_cb() + int bt_adapter_set_state_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_adapter_set_state_changed_cb( + callback, + user_data, + ); + } + + late final _bt_adapter_set_state_changed_cb_ptr = + _lookup>( + 'bt_adapter_set_state_changed_cb'); + late final _dart_bt_adapter_set_state_changed_cb + _bt_adapter_set_state_changed_cb = _bt_adapter_set_state_changed_cb_ptr + .asFunction<_dart_bt_adapter_set_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Unregisters the callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_initialize() + /// @see bt_adapter_set_state_changed_cb() + int bt_adapter_unset_state_changed_cb() { + return _bt_adapter_unset_state_changed_cb(); + } + + late final _bt_adapter_unset_state_changed_cb_ptr = + _lookup>( + 'bt_adapter_unset_state_changed_cb'); + late final _dart_bt_adapter_unset_state_changed_cb + _bt_adapter_unset_state_changed_cb = + _bt_adapter_unset_state_changed_cb_ptr + .asFunction<_dart_bt_adapter_unset_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Registers a callback function to be invoked when the name of Bluetooth adapter changes. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post bt_adapter_name_changed_cb() will be invoked. + /// + /// @see bt_initialize() + /// @see bt_adapter_name_changed_cb() + /// @see bt_adapter_unset_name_changed_cb() + int bt_adapter_set_name_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_adapter_set_name_changed_cb( + callback, + user_data, + ); + } + + late final _bt_adapter_set_name_changed_cb_ptr = + _lookup>( + 'bt_adapter_set_name_changed_cb'); + late final _dart_bt_adapter_set_name_changed_cb + _bt_adapter_set_name_changed_cb = _bt_adapter_set_name_changed_cb_ptr + .asFunction<_dart_bt_adapter_set_name_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Unregisters the callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_initialize() + /// @see bt_adapter_set_name_changed_cb() + int bt_adapter_unset_name_changed_cb() { + return _bt_adapter_unset_name_changed_cb(); + } + + late final _bt_adapter_unset_name_changed_cb_ptr = + _lookup>( + 'bt_adapter_unset_name_changed_cb'); + late final _dart_bt_adapter_unset_name_changed_cb + _bt_adapter_unset_name_changed_cb = _bt_adapter_unset_name_changed_cb_ptr + .asFunction<_dart_bt_adapter_unset_name_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Registers a callback function to be invoked when the visibility mode changes. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post bt_adapter_visibility_mode_changed_cb() will be invoked. + /// + /// @see bt_initialize() + /// @see bt_adapter_visibility_mode_changed_cb() + /// @see bt_adapter_unset_visibility_mode_changed_cb() + int bt_adapter_set_visibility_mode_changed_cb( + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_adapter_set_visibility_mode_changed_cb( + callback, + user_data, + ); + } + + late final _bt_adapter_set_visibility_mode_changed_cb_ptr = + _lookup>( + 'bt_adapter_set_visibility_mode_changed_cb'); + late final _dart_bt_adapter_set_visibility_mode_changed_cb + _bt_adapter_set_visibility_mode_changed_cb = + _bt_adapter_set_visibility_mode_changed_cb_ptr + .asFunction<_dart_bt_adapter_set_visibility_mode_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Unregisters the callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_initialize() + /// @see bt_adapter_set_visibility_mode_changed_cb() + int bt_adapter_unset_visibility_mode_changed_cb() { + return _bt_adapter_unset_visibility_mode_changed_cb(); + } + + late final _bt_adapter_unset_visibility_mode_changed_cb_ptr = _lookup< + ffi.NativeFunction<_c_bt_adapter_unset_visibility_mode_changed_cb>>( + 'bt_adapter_unset_visibility_mode_changed_cb'); + late final _dart_bt_adapter_unset_visibility_mode_changed_cb + _bt_adapter_unset_visibility_mode_changed_cb = + _bt_adapter_unset_visibility_mode_changed_cb_ptr + .asFunction<_dart_bt_adapter_unset_visibility_mode_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Registers a callback function to be invoked every second + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// until the visibility mode is changed from #BT_ADAPTER_VISIBILITY_MODE_LIMITED_DISCOVERABLE + /// to #BT_ADAPTER_VISIBILITY_MODE_NON_DISCOVERABLE. + /// @details When you set visibility mode as #BT_ADAPTER_VISIBILITY_MODE_LIMITED_DISCOVERABLE, + /// @a callback will be called every second until visibility mode is changed to #BT_ADAPTER_VISIBILITY_MODE_NON_DISCOVERABLE. + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized by bt_initialize(). + /// @post bt_adapter_visibility_duration_changed_cb() will be invoked. + /// @see bt_initialize() + /// @see bt_adapter_visibility_duration_changed_cb() + /// @see bt_adapter_unset_visibility_duration_changed_cb() + int bt_adapter_set_visibility_duration_changed_cb( + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_adapter_set_visibility_duration_changed_cb( + callback, + user_data, + ); + } + + late final _bt_adapter_set_visibility_duration_changed_cb_ptr = _lookup< + ffi.NativeFunction<_c_bt_adapter_set_visibility_duration_changed_cb>>( + 'bt_adapter_set_visibility_duration_changed_cb'); + late final _dart_bt_adapter_set_visibility_duration_changed_cb + _bt_adapter_set_visibility_duration_changed_cb = + _bt_adapter_set_visibility_duration_changed_cb_ptr + .asFunction<_dart_bt_adapter_set_visibility_duration_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Unregisters the callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_adapter_set_visibility_duration_changed_cb() + int bt_adapter_unset_visibility_duration_changed_cb() { + return _bt_adapter_unset_visibility_duration_changed_cb(); + } + + late final _bt_adapter_unset_visibility_duration_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_bt_adapter_unset_visibility_duration_changed_cb>>( + 'bt_adapter_unset_visibility_duration_changed_cb'); + late final _dart_bt_adapter_unset_visibility_duration_changed_cb + _bt_adapter_unset_visibility_duration_changed_cb = + _bt_adapter_unset_visibility_duration_changed_cb_ptr + .asFunction<_dart_bt_adapter_unset_visibility_duration_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Registers a callback function to be invoked when the device discovery state changes. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post bt_adapter_device_discovery_state_changed_cb() will be invoked. + /// + /// @see bt_initialize() + /// @see bt_adapter_device_discovery_state_changed_cb() + /// @see bt_adapter_set_device_discovery_state_changed_cb() + /// @see bt_adapter_unset_device_discovery_state_changed_cb() + int bt_adapter_set_device_discovery_state_changed_cb( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, + ) { + return _bt_adapter_set_device_discovery_state_changed_cb( + callback, + user_data, + ); + } + + late final _bt_adapter_set_device_discovery_state_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_bt_adapter_set_device_discovery_state_changed_cb>>( + 'bt_adapter_set_device_discovery_state_changed_cb'); + late final _dart_bt_adapter_set_device_discovery_state_changed_cb + _bt_adapter_set_device_discovery_state_changed_cb = + _bt_adapter_set_device_discovery_state_changed_cb_ptr + .asFunction<_dart_bt_adapter_set_device_discovery_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE + /// @brief Unregisters the callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_initialize() + /// @see bt_adapter_set_device_discovery_state_changed_cb() + int bt_adapter_unset_device_discovery_state_changed_cb() { + return _bt_adapter_unset_device_discovery_state_changed_cb(); + } + + late final _bt_adapter_unset_device_discovery_state_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_bt_adapter_unset_device_discovery_state_changed_cb>>( + 'bt_adapter_unset_device_discovery_state_changed_cb'); + late final _dart_bt_adapter_unset_device_discovery_state_changed_cb + _bt_adapter_unset_device_discovery_state_changed_cb = + _bt_adapter_unset_device_discovery_state_changed_cb_ptr.asFunction< + _dart_bt_adapter_unset_device_discovery_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OOB_MODULE + /// @brief Get the Hash and Randomizer value, synchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[out] hash The hash value received from the controller + /// @param[out] randomizer The hash value received from the controller + /// @param[out] hash_len The length of the hash value + /// @param[out] randomizer_len The length of the randomizer value + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + int bt_adapter_get_local_oob_data( + ffi.Pointer> hash, + ffi.Pointer> randomizer, + ffi.Pointer hash_len, + ffi.Pointer randomizer_len, + ) { + return _bt_adapter_get_local_oob_data( + hash, + randomizer, + hash_len, + randomizer_len, + ); + } + + late final _bt_adapter_get_local_oob_data_ptr = + _lookup>( + 'bt_adapter_get_local_oob_data'); + late final _dart_bt_adapter_get_local_oob_data + _bt_adapter_get_local_oob_data = _bt_adapter_get_local_oob_data_ptr + .asFunction<_dart_bt_adapter_get_local_oob_data>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OOB_MODULE + /// @brief Sets the Hash and Randomizer value, synchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] remote_address Remote device address + /// @param[in] hash The hash value received from the controller + /// @param[in] randomizer The hash value received from the controller + /// @param[in] hash_len The length of the hash value. Allowed value is 16 + /// @param[in] randomizer_len The length of the randomizer value. Allowed value is 16 + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + int bt_adapter_set_remote_oob_data( + ffi.Pointer remote_address, + ffi.Pointer hash, + ffi.Pointer randomizer, + int hash_len, + int randomizer_len, + ) { + return _bt_adapter_set_remote_oob_data( + remote_address, + hash, + randomizer, + hash_len, + randomizer_len, + ); + } + + late final _bt_adapter_set_remote_oob_data_ptr = + _lookup>( + 'bt_adapter_set_remote_oob_data'); + late final _dart_bt_adapter_set_remote_oob_data + _bt_adapter_set_remote_oob_data = _bt_adapter_set_remote_oob_data_ptr + .asFunction<_dart_bt_adapter_set_remote_oob_data>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OOB_MODULE + /// @brief Gets the Hash and Randomizer value, synchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @remarks The @a hash192, randomizer192, hash256 and randomizer256 must be released using free() + /// + /// @param[out] hash192 The hash value derived from the P-192 public key + /// @param[out] randomizer192 The randomizer value associated with the P-192 public key + /// @param[out] hash192_len The length of @a hash192 + /// @param[out] randomizer192_len The length of @a randomizer192 + /// @param[out] hash256 The hash value derived from the P-256 public key + /// @param[out] randomizer256 The randomizer value associated with the P-256 public key + /// @param[out] hash256_len The length of @a hash256 + /// @param[out] randomizer256_len The length of @a randomizer256 + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + int bt_adapter_get_local_oob_ext_data( + ffi.Pointer> hash192, + ffi.Pointer> randomizer192, + ffi.Pointer hash192_len, + ffi.Pointer randomizer192_len, + ffi.Pointer> hash256, + ffi.Pointer> randomizer256, + ffi.Pointer hash256_len, + ffi.Pointer randomizer256_len, + ) { + return _bt_adapter_get_local_oob_ext_data( + hash192, + randomizer192, + hash192_len, + randomizer192_len, + hash256, + randomizer256, + hash256_len, + randomizer256_len, + ); + } + + late final _bt_adapter_get_local_oob_ext_data_ptr = + _lookup>( + 'bt_adapter_get_local_oob_ext_data'); + late final _dart_bt_adapter_get_local_oob_ext_data + _bt_adapter_get_local_oob_ext_data = + _bt_adapter_get_local_oob_ext_data_ptr + .asFunction<_dart_bt_adapter_get_local_oob_ext_data>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OOB_MODULE + /// @brief Sets the Hash and Randomizer value, synchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] remote_address Remote device address + /// @param[in] hash192 The P-192 hash value received via OOB from remote device + /// @param[in] randomizer192 The P-192 randomizer value received via OOB from remote device + /// @param[in] hash192_len The length of @a hash192 + /// @param[in] randomizer192_len The length of @a randomizer192 + /// @param[in] hash256 The P-256 hash value received via OOB from remote device + /// @param[in] randomizer256 The P-256 randomizer value received via OOB from remote device + /// @param[in] hash256_len The length of @a hash256 + /// @param[in] randomizer256_len The length of @a randomizer256 + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + int bt_adapter_set_remote_oob_ext_data( + ffi.Pointer remote_address, + ffi.Pointer hash192, + ffi.Pointer randomizer192, + int hash192_len, + int randomizer192_len, + ffi.Pointer hash256, + ffi.Pointer randomizer256, + int hash256_len, + int randomizer256_len, + ) { + return _bt_adapter_set_remote_oob_ext_data( + remote_address, + hash192, + randomizer192, + hash192_len, + randomizer192_len, + hash256, + randomizer256, + hash256_len, + randomizer256_len, + ); + } + + late final _bt_adapter_set_remote_oob_ext_data_ptr = + _lookup>( + 'bt_adapter_set_remote_oob_ext_data'); + late final _dart_bt_adapter_set_remote_oob_ext_data + _bt_adapter_set_remote_oob_ext_data = + _bt_adapter_set_remote_oob_ext_data_ptr + .asFunction<_dart_bt_adapter_set_remote_oob_ext_data>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OOB_MODULE + /// @brief Deletes the Hash and Randomizer value, synchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] remote_address Remote device address + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + int bt_adapter_remove_remote_oob_data( + ffi.Pointer remote_address, + ) { + return _bt_adapter_remove_remote_oob_data( + remote_address, + ); + } + + late final _bt_adapter_remove_remote_oob_data_ptr = + _lookup>( + 'bt_adapter_remove_remote_oob_data'); + late final _dart_bt_adapter_remove_remote_oob_data + _bt_adapter_remove_remote_oob_data = + _bt_adapter_remove_remote_oob_data_ptr + .asFunction<_dart_bt_adapter_remove_remote_oob_data>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1 + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Starts the LE device discovery. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @details If a LE device is discovered, bt_adapter_le_device_discovery_state_changed_cb() + /// will be invoked with #BT_ADAPTER_LE_DEVICE_DISCOVERY_FOUND, and then bt_adapter_le_device_discovery_state_changed_cb() + /// will be called with #BT_ADAPTER_LE_DEVICE_DISCOVERY_FINISHED in case of the completion or cancellation of the discovery. + /// + /// @remarks To connect to peer Bluetooth device, you need to know its Bluetooth address. \n + /// The device discovery can be stopped by bt_adapter_le_stop_device_discovery(). + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOW_IN_PROGRESS Operation is now in progress + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @post This function invokes bt_adapter_le_device_discovery_state_changed_cb(). + /// + /// @see bt_adapter_le_is_discovering() + /// @see bt_adapter_le_device_discovery_state_changed_cb() + /// @see bt_adapter_le_set_device_discovery_state_changed_cb() + /// @see bt_adapter_le_unset_device_discovery_state_changed_cb() + int bt_adapter_le_start_device_discovery() { + return _bt_adapter_le_start_device_discovery(); + } + + late final _bt_adapter_le_start_device_discovery_ptr = + _lookup>( + 'bt_adapter_le_start_device_discovery'); + late final _dart_bt_adapter_le_start_device_discovery + _bt_adapter_le_start_device_discovery = + _bt_adapter_le_start_device_discovery_ptr + .asFunction<_dart_bt_adapter_le_start_device_discovery>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1 + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Stops the LE device discovery, asynchronously. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOT_IN_PROGRESS Operation is not in progress + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The device discovery must be in progress with bt_adapter_le_start_device_discovery(). + /// @post This function invokes bt_adapter_le_device_discovery_state_changed_cb(). + /// + /// @see bt_adapter_le_is_discovering() + /// @see bt_adapter_le_start_device_discovery() + /// @see bt_adapter_le_set_device_discovery_state_changed_cb() + /// @see bt_adapter_le_unset_device_discovery_state_changed_cb() + /// @see bt_adapter_le_device_discovery_state_changed_cb() + int bt_adapter_le_stop_device_discovery() { + return _bt_adapter_le_stop_device_discovery(); + } + + late final _bt_adapter_le_stop_device_discovery_ptr = + _lookup>( + 'bt_adapter_le_stop_device_discovery'); + late final _dart_bt_adapter_le_stop_device_discovery + _bt_adapter_le_stop_device_discovery = + _bt_adapter_le_stop_device_discovery_ptr + .asFunction<_dart_bt_adapter_le_stop_device_discovery>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1 + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Checks for the LE device discovery is in progress or not. + /// @since_tizen 2.3 + /// + /// @remarks If Bluetooth LE discovery is in progress, other operations are not allowed and + /// you have to either stop the LE discovery operation, or wait for it to be finished, + /// before performing other operations. + /// + /// @param[out] is_discovering The discovering status: (@c true = in progress , @c false = not in progress ) + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// + /// @see bt_adapter_le_start_device_discovery() + /// @see bt_adapter_le_stop_device_discovery() + int bt_adapter_le_is_discovering( + ffi.Pointer is_discovering, + ) { + return _bt_adapter_le_is_discovering( + is_discovering, + ); + } + + late final _bt_adapter_le_is_discovering_ptr = + _lookup>( + 'bt_adapter_le_is_discovering'); + late final _dart_bt_adapter_le_is_discovering _bt_adapter_le_is_discovering = + _bt_adapter_le_is_discovering_ptr + .asFunction<_dart_bt_adapter_le_is_discovering>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1 + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Registers a callback function to be invoked when the LE device discovery state changes. + /// @since_tizen 2.3 + /// + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post bt_adapter_le_device_discovery_state_changed_cb() will be invoked. + /// + /// @see bt_initialize() + /// @see bt_adapter_le_device_discovery_state_changed_cb() + /// @see bt_adapter_le_unset_device_discovery_state_changed_cb() + int bt_adapter_le_set_device_discovery_state_changed_cb( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, + ) { + return _bt_adapter_le_set_device_discovery_state_changed_cb( + callback, + user_data, + ); + } + + late final _bt_adapter_le_set_device_discovery_state_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_bt_adapter_le_set_device_discovery_state_changed_cb>>( + 'bt_adapter_le_set_device_discovery_state_changed_cb'); + late final _dart_bt_adapter_le_set_device_discovery_state_changed_cb + _bt_adapter_le_set_device_discovery_state_changed_cb = + _bt_adapter_le_set_device_discovery_state_changed_cb_ptr.asFunction< + _dart_bt_adapter_le_set_device_discovery_state_changed_cb>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1 + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Unregisters the callback function. + /// @since_tizen 2.3 + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_initialize() + /// @see bt_adapter_le_set_device_discovery_state_changed_cb() + int bt_adapter_le_unset_device_discovery_state_changed_cb() { + return _bt_adapter_le_unset_device_discovery_state_changed_cb(); + } + + late final _bt_adapter_le_unset_device_discovery_state_changed_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_bt_adapter_le_unset_device_discovery_state_changed_cb>>( + 'bt_adapter_le_unset_device_discovery_state_changed_cb'); + late final _dart_bt_adapter_le_unset_device_discovery_state_changed_cb + _bt_adapter_le_unset_device_discovery_state_changed_cb = + _bt_adapter_le_unset_device_discovery_state_changed_cb_ptr.asFunction< + _dart_bt_adapter_le_unset_device_discovery_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Starts the LE scan to find LE advertisement. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @details If a LE advertisement is found, bt_adapter_le_scan_result_cb() will be invoked. + /// + /// @param[in] cb The callback to report the result of this function + /// @param[in] user_data The user data to be passed when callback is called + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOW_IN_PROGRESS Operation is now in progress + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @post This function invokes bt_adapter_le_scan_result_cb(). + /// + /// @see bt_adapter_le_scan_result_cb() + int bt_adapter_le_start_scan( + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _bt_adapter_le_start_scan( + cb, + user_data, + ); + } + + late final _bt_adapter_le_start_scan_ptr = + _lookup>( + 'bt_adapter_le_start_scan'); + late final _dart_bt_adapter_le_start_scan _bt_adapter_le_start_scan = + _bt_adapter_le_start_scan_ptr + .asFunction<_dart_bt_adapter_le_start_scan>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Stops the LE scan. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOT_IN_PROGRESS Operation is not in progress + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The LE scan must be in progress with bt_adapter_le_start_scan(). + /// + /// @see bt_adapter_le_start_scan() + int bt_adapter_le_stop_scan() { + return _bt_adapter_le_stop_scan(); + } + + late final _bt_adapter_le_stop_scan_ptr = + _lookup>( + 'bt_adapter_le_stop_scan'); + late final _dart_bt_adapter_le_stop_scan _bt_adapter_le_stop_scan = + _bt_adapter_le_stop_scan_ptr.asFunction<_dart_bt_adapter_le_stop_scan>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Gets the service UUID list from the scan result information + /// @since_tizen 2.3.1 + /// + /// @remarks The @a uuids must be iterated as count and each pointed data must be released with free(). + /// Then uuids must be released with free(). \n + /// 16-bit service UUID or 128-bit service UUID is supported. (e.g. 180F, 0000180F-0000-1000-8000-00805F9B34FB) + /// + /// @param[in] info The scan result information + /// @param[in] pkt_type The packet type + /// @param[out] uuids The list of string of the service uuid + /// @param[out] count The count of the service UUIDs + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NO_DATA No data available + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_scan_result_cb() + int bt_adapter_le_get_scan_result_service_uuids( + ffi.Pointer info, + int pkt_type, + ffi.Pointer>> uuids, + ffi.Pointer count, + ) { + return _bt_adapter_le_get_scan_result_service_uuids( + info, + pkt_type, + uuids, + count, + ); + } + + late final _bt_adapter_le_get_scan_result_service_uuids_ptr = _lookup< + ffi.NativeFunction<_c_bt_adapter_le_get_scan_result_service_uuids>>( + 'bt_adapter_le_get_scan_result_service_uuids'); + late final _dart_bt_adapter_le_get_scan_result_service_uuids + _bt_adapter_le_get_scan_result_service_uuids = + _bt_adapter_le_get_scan_result_service_uuids_ptr + .asFunction<_dart_bt_adapter_le_get_scan_result_service_uuids>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Gets the device name from the scan result information + /// @since_tizen 2.3.1 + /// + /// @remarks The @a name must be released with free() by you. + /// + /// @param[in] info The scan result information + /// @param[in] pkt_type The packet type + /// @param[out] name The device name + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NO_DATA No data available + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_scan_result_cb() + int bt_adapter_le_get_scan_result_device_name( + ffi.Pointer info, + int pkt_type, + ffi.Pointer> name, + ) { + return _bt_adapter_le_get_scan_result_device_name( + info, + pkt_type, + name, + ); + } + + late final _bt_adapter_le_get_scan_result_device_name_ptr = + _lookup>( + 'bt_adapter_le_get_scan_result_device_name'); + late final _dart_bt_adapter_le_get_scan_result_device_name + _bt_adapter_le_get_scan_result_device_name = + _bt_adapter_le_get_scan_result_device_name_ptr + .asFunction<_dart_bt_adapter_le_get_scan_result_device_name>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Gets the transmission power level from the scan result information + /// @since_tizen 2.3.1 + /// + /// @param[in] info The scan result information + /// @param[in] pkt_type The packet type + /// @param[out] power_level The transmission power level in dBm + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NO_DATA No data available + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_scan_result_cb() + int bt_adapter_le_get_scan_result_tx_power_level( + ffi.Pointer info, + int pkt_type, + ffi.Pointer power_level, + ) { + return _bt_adapter_le_get_scan_result_tx_power_level( + info, + pkt_type, + power_level, + ); + } + + late final _bt_adapter_le_get_scan_result_tx_power_level_ptr = _lookup< + ffi.NativeFunction<_c_bt_adapter_le_get_scan_result_tx_power_level>>( + 'bt_adapter_le_get_scan_result_tx_power_level'); + late final _dart_bt_adapter_le_get_scan_result_tx_power_level + _bt_adapter_le_get_scan_result_tx_power_level = + _bt_adapter_le_get_scan_result_tx_power_level_ptr + .asFunction<_dart_bt_adapter_le_get_scan_result_tx_power_level>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Gets the service solicitation UUID list from the scan result information + /// @since_tizen 2.3.1 + /// + /// @remarks The @a uuids must be iterated as count and each pointed data must be released with free(). + /// Then uuids must be released with free(). \n + /// 16-bit service solicitation UUID or 128-bit service solicitation UUID is supported. + /// (e.g. 180F, 0000180F-0000-1000-8000-00805F9B34FB) + /// + /// @param[in] info The scan result information + /// @param[in] pkt_type The packet type + /// @param[out] uuids The list of string of the service solicitation uuid + /// @param[out] count The count of the service UUIDs + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NO_DATA No data available + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_scan_result_cb() + int bt_adapter_le_get_scan_result_service_solicitation_uuids( + ffi.Pointer info, + int pkt_type, + ffi.Pointer>> uuids, + ffi.Pointer count, + ) { + return _bt_adapter_le_get_scan_result_service_solicitation_uuids( + info, + pkt_type, + uuids, + count, + ); + } + + late final _bt_adapter_le_get_scan_result_service_solicitation_uuids_ptr = + _lookup< + ffi.NativeFunction< + _c_bt_adapter_le_get_scan_result_service_solicitation_uuids>>( + 'bt_adapter_le_get_scan_result_service_solicitation_uuids'); + late final _dart_bt_adapter_le_get_scan_result_service_solicitation_uuids + _bt_adapter_le_get_scan_result_service_solicitation_uuids = + _bt_adapter_le_get_scan_result_service_solicitation_uuids_ptr.asFunction< + _dart_bt_adapter_le_get_scan_result_service_solicitation_uuids>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Gets the service data list from the scan result information + /// @since_tizen 2.3.1 + /// + /// @remarks The @a data_list must be released with bt_adapter_le_free_service_data_list() by you . + /// + /// @param[in] info The scan result information + /// @param[in] pkt_type The packet type + /// @param[out] data_list The list of the service data + /// @param[out] count The count of the service data list + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NO_DATA No data available + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_scan_result_cb() + int bt_adapter_le_get_scan_result_service_data_list( + ffi.Pointer info, + int pkt_type, + ffi.Pointer> data_list, + ffi.Pointer count, + ) { + return _bt_adapter_le_get_scan_result_service_data_list( + info, + pkt_type, + data_list, + count, + ); + } + + late final _bt_adapter_le_get_scan_result_service_data_list_ptr = _lookup< + ffi.NativeFunction< + _c_bt_adapter_le_get_scan_result_service_data_list>>( + 'bt_adapter_le_get_scan_result_service_data_list'); + late final _dart_bt_adapter_le_get_scan_result_service_data_list + _bt_adapter_le_get_scan_result_service_data_list = + _bt_adapter_le_get_scan_result_service_data_list_ptr + .asFunction<_dart_bt_adapter_le_get_scan_result_service_data_list>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Frees service data list. + /// @since_tizen 2.3.1 + /// + /// @param[in] data_list The list of the service data + /// @param[in] count The count of the service data list + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_adapter_le_get_scan_result_service_data_list() + int bt_adapter_le_free_service_data_list( + ffi.Pointer data_list, + int count, + ) { + return _bt_adapter_le_free_service_data_list( + data_list, + count, + ); + } + + late final _bt_adapter_le_free_service_data_list_ptr = + _lookup>( + 'bt_adapter_le_free_service_data_list'); + late final _dart_bt_adapter_le_free_service_data_list + _bt_adapter_le_free_service_data_list = + _bt_adapter_le_free_service_data_list_ptr + .asFunction<_dart_bt_adapter_le_free_service_data_list>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Gets the appearance from the scan result information + /// @since_tizen 2.3.1 + /// + /// @param[in] info The scan result information + /// @param[in] pkt_type The packet type + /// @param[out] appearance The appearance + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NO_DATA No data available + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_scan_result_cb() + int bt_adapter_le_get_scan_result_appearance( + ffi.Pointer info, + int pkt_type, + ffi.Pointer appearance, + ) { + return _bt_adapter_le_get_scan_result_appearance( + info, + pkt_type, + appearance, + ); + } + + late final _bt_adapter_le_get_scan_result_appearance_ptr = + _lookup>( + 'bt_adapter_le_get_scan_result_appearance'); + late final _dart_bt_adapter_le_get_scan_result_appearance + _bt_adapter_le_get_scan_result_appearance = + _bt_adapter_le_get_scan_result_appearance_ptr + .asFunction<_dart_bt_adapter_le_get_scan_result_appearance>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Gets the manufacturer data from the scan result information + /// @since_tizen 2.3.1 + /// + /// @remarks The @a manufacturer_data must be released with free() by you. + /// + /// @param[in] info The scan result information + /// @param[in] pkt_type The packet type + /// @param[out] manufacturer_id The manufacturer ID + /// @param[out] manufacturer_data The manufacturer data (byte array) + /// @param[out] manufacturer_data_len The length of manufacturer data + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NO_DATA No data available + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_scan_result_cb() + int bt_adapter_le_get_scan_result_manufacturer_data( + ffi.Pointer info, + int pkt_type, + ffi.Pointer manufacturer_id, + ffi.Pointer> manufacturer_data, + ffi.Pointer manufacturer_data_len, + ) { + return _bt_adapter_le_get_scan_result_manufacturer_data( + info, + pkt_type, + manufacturer_id, + manufacturer_data, + manufacturer_data_len, + ); + } + + late final _bt_adapter_le_get_scan_result_manufacturer_data_ptr = _lookup< + ffi.NativeFunction< + _c_bt_adapter_le_get_scan_result_manufacturer_data>>( + 'bt_adapter_le_get_scan_result_manufacturer_data'); + late final _dart_bt_adapter_le_get_scan_result_manufacturer_data + _bt_adapter_le_get_scan_result_manufacturer_data = + _bt_adapter_le_get_scan_result_manufacturer_data_ptr + .asFunction<_dart_bt_adapter_le_get_scan_result_manufacturer_data>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Gets iBeacon format's data from the scan result information. + /// @since_tizen 4.0 + /// + /// @remarks The @a ibeacon_info must be released with bt_adapter_le_free_ibeacon_report(). + /// + /// @param[in] info The scan result information + /// @param[in] pkt_type The packet type + /// @param[out] ibeacon_info The iBeacon format's scan result data + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NO_DATA No data available + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_scan_result_cb() + int bt_adapter_le_get_scan_result_ibeacon_report( + ffi.Pointer info, + int pkt_type, + ffi.Pointer> + ibeacon_info, + ) { + return _bt_adapter_le_get_scan_result_ibeacon_report( + info, + pkt_type, + ibeacon_info, + ); + } + + late final _bt_adapter_le_get_scan_result_ibeacon_report_ptr = _lookup< + ffi.NativeFunction<_c_bt_adapter_le_get_scan_result_ibeacon_report>>( + 'bt_adapter_le_get_scan_result_ibeacon_report'); + late final _dart_bt_adapter_le_get_scan_result_ibeacon_report + _bt_adapter_le_get_scan_result_ibeacon_report = + _bt_adapter_le_get_scan_result_ibeacon_report_ptr + .asFunction<_dart_bt_adapter_le_get_scan_result_ibeacon_report>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Frees iBeacon information. + /// @since_tizen 4.0 + /// + /// @param[in] ibeacon_info The iBeacon format's scan result data + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_adapter_le_get_scan_result_service_data_list() + int bt_adapter_le_free_ibeacon_report( + ffi.Pointer ibeacon_info, + ) { + return _bt_adapter_le_free_ibeacon_report( + ibeacon_info, + ); + } + + late final _bt_adapter_le_free_ibeacon_report_ptr = + _lookup>( + 'bt_adapter_le_free_ibeacon_report'); + late final _dart_bt_adapter_le_free_ibeacon_report + _bt_adapter_le_free_ibeacon_report = + _bt_adapter_le_free_ibeacon_report_ptr + .asFunction<_dart_bt_adapter_le_free_ibeacon_report>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Create advertiser to advertise device's existence or respond to LE scanning request. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[out] advertiser The handle of advertiser + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_destroy_advertiser() + int bt_adapter_le_create_advertiser( + ffi.Pointer> advertiser, + ) { + return _bt_adapter_le_create_advertiser( + advertiser, + ); + } + + late final _bt_adapter_le_create_advertiser_ptr = + _lookup>( + 'bt_adapter_le_create_advertiser'); + late final _dart_bt_adapter_le_create_advertiser + _bt_adapter_le_create_advertiser = _bt_adapter_le_create_advertiser_ptr + .asFunction<_dart_bt_adapter_le_create_advertiser>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Destroy advertiser. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[out] advertiser The handle of advertiser + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_create_advertiser() + int bt_adapter_le_destroy_advertiser( + ffi.Pointer advertiser, + ) { + return _bt_adapter_le_destroy_advertiser( + advertiser, + ); + } + + late final _bt_adapter_le_destroy_advertiser_ptr = + _lookup>( + 'bt_adapter_le_destroy_advertiser'); + late final _dart_bt_adapter_le_destroy_advertiser + _bt_adapter_le_destroy_advertiser = _bt_adapter_le_destroy_advertiser_ptr + .asFunction<_dart_bt_adapter_le_destroy_advertiser>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_IPSP_MODULE + /// @brief Initializes the Bluetooth IPSP (Internet Protocol Support Profile) service. + /// @since_tizen 4.0 + /// @param[in] callback The callback called when the initialization is finished + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + int bt_ipsp_initialize( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_ipsp_initialize( + callback, + user_data, + ); + } + + late final _bt_ipsp_initialize_ptr = + _lookup>('bt_ipsp_initialize'); + late final _dart_bt_ipsp_initialize _bt_ipsp_initialize = + _bt_ipsp_initialize_ptr.asFunction<_dart_bt_ipsp_initialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_IPSP_MODULE + /// @brief Deinitializes the Bluetooth IPSP (Internet Protocol Support Profile) service. + /// @since_tizen 4.0 + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + int bt_ipsp_deinitialize() { + return _bt_ipsp_deinitialize(); + } + + late final _bt_ipsp_deinitialize_ptr = + _lookup>( + 'bt_ipsp_deinitialize'); + late final _dart_bt_ipsp_deinitialize _bt_ipsp_deinitialize = + _bt_ipsp_deinitialize_ptr.asFunction<_dart_bt_ipsp_deinitialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_IPSP_MODULE + /// @brief Connects to a remote device's IPSP service over LE, asynchronously. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] remote_address The remote address + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @post bt_ipsp_set_connection_state_changed_cb() will be invoked. + /// @see bt_ipsp_set_connection_state_changed_cb() + int bt_ipsp_connect( + ffi.Pointer remote_address, + ) { + return _bt_ipsp_connect( + remote_address, + ); + } + + late final _bt_ipsp_connect_ptr = + _lookup>('bt_ipsp_connect'); + late final _dart_bt_ipsp_connect _bt_ipsp_connect = + _bt_ipsp_connect_ptr.asFunction<_dart_bt_ipsp_connect>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_IPSP_MODULE + /// @brief Disconnects from a remote device's IPSP service, asynchronously. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] remote_address The remote address + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected by bt_ipsp_connect(). + /// @post bt_ipsp_set_connection_state_changed_cb() will be invoked. + /// @see bt_ipsp_connect() + /// @see bt_ipsp_set_connection_state_changed_cb() + int bt_ipsp_disconnect( + ffi.Pointer remote_address, + ) { + return _bt_ipsp_disconnect( + remote_address, + ); + } + + late final _bt_ipsp_disconnect_ptr = + _lookup>('bt_ipsp_disconnect'); + late final _dart_bt_ipsp_disconnect _bt_ipsp_disconnect = + _bt_ipsp_disconnect_ptr.asFunction<_dart_bt_ipsp_disconnect>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_IPSP_MODULE + /// @brief Registers a callback function that will be invoked when the connection state changes. + /// @since_tizen 4.0 + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + int bt_ipsp_set_connection_state_changed_cb( + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_ipsp_set_connection_state_changed_cb( + callback, + user_data, + ); + } + + late final _bt_ipsp_set_connection_state_changed_cb_ptr = + _lookup>( + 'bt_ipsp_set_connection_state_changed_cb'); + late final _dart_bt_ipsp_set_connection_state_changed_cb + _bt_ipsp_set_connection_state_changed_cb = + _bt_ipsp_set_connection_state_changed_cb_ptr + .asFunction<_dart_bt_ipsp_set_connection_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_IPSP_MODULE + /// @brief Unregisters the callback function called when the connection state changes. + /// @since_tizen 4.0 + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + int bt_ipsp_unset_connection_state_changed_cb() { + return _bt_ipsp_unset_connection_state_changed_cb(); + } + + late final _bt_ipsp_unset_connection_state_changed_cb_ptr = + _lookup>( + 'bt_ipsp_unset_connection_state_changed_cb'); + late final _dart_bt_ipsp_unset_connection_state_changed_cb + _bt_ipsp_unset_connection_state_changed_cb = + _bt_ipsp_unset_connection_state_changed_cb_ptr + .asFunction<_dart_bt_ipsp_unset_connection_state_changed_cb>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1 + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Set the data to be advertised or responded to scan request from LE scanning device. + /// The maximum advertised or responded data size is 31 bytes + /// including data type and system wide data. + /// @since_tizen 2.3 + /// + /// @remarks In case the data_type is local name or tx power level, you don't need to input data + /// because the data value is written automatically by system. + /// + /// @param[in] advertiser The handle of advertiser + /// @param[in] pkt_type The packet type + /// @param[in] data_type The data type that is included in packet + /// @param[in] data The data to be advertised or be responded to scan request from LE scanning device, no need in case of LOCAL_NAME or TX_POWER_LEVEL + /// @param[in] data_size The size of data to be set. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_QUOTA_EXCEEDED Quota exceeded + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_clear_advertising_data() + int bt_adapter_le_add_advertising_data( + ffi.Pointer advertiser, + int pkt_type, + int data_type, + ffi.Pointer data, + int data_size, + ) { + return _bt_adapter_le_add_advertising_data( + advertiser, + pkt_type, + data_type, + data, + data_size, + ); + } + + late final _bt_adapter_le_add_advertising_data_ptr = + _lookup>( + 'bt_adapter_le_add_advertising_data'); + late final _dart_bt_adapter_le_add_advertising_data + _bt_adapter_le_add_advertising_data = + _bt_adapter_le_add_advertising_data_ptr + .asFunction<_dart_bt_adapter_le_add_advertising_data>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Add a service UUID to advertise or scan response data. + /// The maximum advertised or responded data size is 31 bytes + /// including data type and system wide data. + /// @since_tizen 2.3.1 + /// + /// @remarks 16-bit UUID or 128-bit UUID is supported. (e.g. 180F, 0000180F-0000-1000-8000-00805F9B34FB) + /// + /// @param[in] advertiser The handle of advertiser + /// @param[in] pkt_type The packet type + /// @param[in] uuid The string of the service UUID. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_QUOTA_EXCEEDED Quota exceeded + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_clear_advertising_data() + int bt_adapter_le_add_advertising_service_uuid( + ffi.Pointer advertiser, + int pkt_type, + ffi.Pointer uuid, + ) { + return _bt_adapter_le_add_advertising_service_uuid( + advertiser, + pkt_type, + uuid, + ); + } + + late final _bt_adapter_le_add_advertising_service_uuid_ptr = _lookup< + ffi.NativeFunction<_c_bt_adapter_le_add_advertising_service_uuid>>( + 'bt_adapter_le_add_advertising_service_uuid'); + late final _dart_bt_adapter_le_add_advertising_service_uuid + _bt_adapter_le_add_advertising_service_uuid = + _bt_adapter_le_add_advertising_service_uuid_ptr + .asFunction<_dart_bt_adapter_le_add_advertising_service_uuid>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Add a service solicitation UUID to advertise or scan response data. + /// The maximum advertised or responded data size is 31 bytes + /// including data type and system wide data. + /// @since_tizen 2.3.1 + /// + /// @remarks 16-bit service solicitation UUID or 128-bit service solicitation UUID is supported. + /// (e.g. 180F, 0000180F-0000-1000-8000-00805F9B34FB) + /// + /// @param[in] advertiser The handle of advertiser + /// @param[in] pkt_type The packet type + /// @param[in] uuid The string of the service solicitation UUID. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_QUOTA_EXCEEDED Quota exceeded + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_clear_advertising_data() + int bt_adapter_le_add_advertising_service_solicitation_uuid( + ffi.Pointer advertiser, + int pkt_type, + ffi.Pointer uuid, + ) { + return _bt_adapter_le_add_advertising_service_solicitation_uuid( + advertiser, + pkt_type, + uuid, + ); + } + + late final _bt_adapter_le_add_advertising_service_solicitation_uuid_ptr = + _lookup< + ffi.NativeFunction< + _c_bt_adapter_le_add_advertising_service_solicitation_uuid>>( + 'bt_adapter_le_add_advertising_service_solicitation_uuid'); + late final _dart_bt_adapter_le_add_advertising_service_solicitation_uuid + _bt_adapter_le_add_advertising_service_solicitation_uuid = + _bt_adapter_le_add_advertising_service_solicitation_uuid_ptr.asFunction< + _dart_bt_adapter_le_add_advertising_service_solicitation_uuid>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Add service data to advertise or scan response data. + /// The maximum advertised or responded data size is 31 bytes + /// including data type and system wide data. + /// @since_tizen 2.3.1 + /// + /// @remarks 16-bit UUID is supported. (e.g. 180F) + /// + /// @param[in] advertiser The handle of advertiser + /// @param[in] pkt_type The packet type + /// @param[in] uuid 16-bit UUID of the service + /// @param[in] service_data The service data + /// @param[in] service_data_len The data length of service data + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_QUOTA_EXCEEDED Quota exceeded + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_clear_advertising_data() + int bt_adapter_le_add_advertising_service_data( + ffi.Pointer advertiser, + int pkt_type, + ffi.Pointer uuid, + ffi.Pointer service_data, + int service_data_len, + ) { + return _bt_adapter_le_add_advertising_service_data( + advertiser, + pkt_type, + uuid, + service_data, + service_data_len, + ); + } + + late final _bt_adapter_le_add_advertising_service_data_ptr = _lookup< + ffi.NativeFunction<_c_bt_adapter_le_add_advertising_service_data>>( + 'bt_adapter_le_add_advertising_service_data'); + late final _dart_bt_adapter_le_add_advertising_service_data + _bt_adapter_le_add_advertising_service_data = + _bt_adapter_le_add_advertising_service_data_ptr + .asFunction<_dart_bt_adapter_le_add_advertising_service_data>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Sets the external appearance of this device to advertise or scan response data. + /// Please refer to the adopted Bluetooth specification for the the appearance. + /// @since_tizen 2.3.1 + /// + /// @param[in] advertiser The handle of advertiser + /// @param[in] pkt_type The packet type + /// @param[in] appearance The external appearance of device + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_QUOTA_EXCEEDED Quota exceeded + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_clear_advertising_data() + int bt_adapter_le_set_advertising_appearance( + ffi.Pointer advertiser, + int pkt_type, + int appearance, + ) { + return _bt_adapter_le_set_advertising_appearance( + advertiser, + pkt_type, + appearance, + ); + } + + late final _bt_adapter_le_set_advertising_appearance_ptr = + _lookup>( + 'bt_adapter_le_set_advertising_appearance'); + late final _dart_bt_adapter_le_set_advertising_appearance + _bt_adapter_le_set_advertising_appearance = + _bt_adapter_le_set_advertising_appearance_ptr + .asFunction<_dart_bt_adapter_le_set_advertising_appearance>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Add manufacturer specific data to advertise or scan response data. + /// Please refer to the Bluetooth Assigned Numbers provided by the Bluetooth SIG for a list of existing company identifiers. + /// The maximum advertised or responded data size is 31 bytes + /// including data type and system wide data. + /// @since_tizen 2.3.1 + /// + /// + /// @param[in] advertiser The handle of advertiser + /// @param[in] pkt_type The packet type + /// @param[in] manufacturer_id Manufacturer identifier + /// @param[in] manufacturer_data The manufacturer specific data + /// @param[in] manufacturer_data_len The data length of manufacturer data + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_QUOTA_EXCEEDED Quota exceeded + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_clear_advertising_data() + int bt_adapter_le_add_advertising_manufacturer_data( + ffi.Pointer advertiser, + int pkt_type, + int manufacturer_id, + ffi.Pointer manufacturer_data, + int manufacturer_data_len, + ) { + return _bt_adapter_le_add_advertising_manufacturer_data( + advertiser, + pkt_type, + manufacturer_id, + manufacturer_data, + manufacturer_data_len, + ); + } + + late final _bt_adapter_le_add_advertising_manufacturer_data_ptr = _lookup< + ffi.NativeFunction< + _c_bt_adapter_le_add_advertising_manufacturer_data>>( + 'bt_adapter_le_add_advertising_manufacturer_data'); + late final _dart_bt_adapter_le_add_advertising_manufacturer_data + _bt_adapter_le_add_advertising_manufacturer_data = + _bt_adapter_le_add_advertising_manufacturer_data_ptr + .asFunction<_dart_bt_adapter_le_add_advertising_manufacturer_data>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Set whether the device name should be included in advertise or scan response data. + /// The maximum advertised or responded data size is 31 bytes + /// including data type and system wide data. + /// @since_tizen 2.3.1 + /// + /// @param[in] advertiser The handle of advertiser + /// @param[in] pkt_type The packet type + /// @param[in] include_name Whether the device name should be included + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_QUOTA_EXCEEDED Quota exceeded + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_clear_advertising_data() + int bt_adapter_le_set_advertising_device_name( + ffi.Pointer advertiser, + int pkt_type, + bool include_name, + ) { + return _bt_adapter_le_set_advertising_device_name( + advertiser, + pkt_type, + include_name ? 1 : 0, + ); + } + + late final _bt_adapter_le_set_advertising_device_name_ptr = + _lookup>( + 'bt_adapter_le_set_advertising_device_name'); + late final _dart_bt_adapter_le_set_advertising_device_name + _bt_adapter_le_set_advertising_device_name = + _bt_adapter_le_set_advertising_device_name_ptr + .asFunction<_dart_bt_adapter_le_set_advertising_device_name>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Set whether the transmission power level should be included in advertise or scan response data. + /// The maximum advertised or responded data size is 31 bytes + /// including data type and system wide data. + /// @since_tizen 2.3.1 + /// + /// @param[in] advertiser The handle of advertiser + /// @param[in] pkt_type The packet type + /// @param[in] include_tx_power Whether the transmission power level should be included + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_QUOTA_EXCEEDED Quota exceeded + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_clear_advertising_data() + int bt_adapter_le_set_advertising_tx_power_level( + ffi.Pointer advertiser, + int pkt_type, + bool include_tx_power, + ) { + return _bt_adapter_le_set_advertising_tx_power_level( + advertiser, + pkt_type, + include_tx_power ? 1 : 0, + ); + } + + late final _bt_adapter_le_set_advertising_tx_power_level_ptr = _lookup< + ffi.NativeFunction<_c_bt_adapter_le_set_advertising_tx_power_level>>( + 'bt_adapter_le_set_advertising_tx_power_level'); + late final _dart_bt_adapter_le_set_advertising_tx_power_level + _bt_adapter_le_set_advertising_tx_power_level = + _bt_adapter_le_set_advertising_tx_power_level_ptr + .asFunction<_dart_bt_adapter_le_set_advertising_tx_power_level>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1 + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Unset the data to be advertised or responded to scan request from LE scanning device. + /// @since_tizen 2.3 + /// + /// @param[in] advertiser The handle of advertiser + /// @param[in] pkt_type The packet type + /// @param[in] data_type The data type to be removed from selected packet + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_add_advertising_data() + /// @see bt_adapter_le_clear_advertising_data() + int bt_adapter_le_remove_advertising_data( + ffi.Pointer advertiser, + int pkt_type, + int data_type, + ) { + return _bt_adapter_le_remove_advertising_data( + advertiser, + pkt_type, + data_type, + ); + } + + late final _bt_adapter_le_remove_advertising_data_ptr = + _lookup>( + 'bt_adapter_le_remove_advertising_data'); + late final _dart_bt_adapter_le_remove_advertising_data + _bt_adapter_le_remove_advertising_data = + _bt_adapter_le_remove_advertising_data_ptr + .asFunction<_dart_bt_adapter_le_remove_advertising_data>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Clear all data to be advertised or responded to scan request from LE scanning device. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[in] advertiser The handle of advertiser + /// @param[in] pkt_type The packet type to be cleared + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_add_advertising_data() + int bt_adapter_le_clear_advertising_data( + ffi.Pointer advertiser, + int pkt_type, + ) { + return _bt_adapter_le_clear_advertising_data( + advertiser, + pkt_type, + ); + } + + late final _bt_adapter_le_clear_advertising_data_ptr = + _lookup>( + 'bt_adapter_le_clear_advertising_data'); + late final _dart_bt_adapter_le_clear_advertising_data + _bt_adapter_le_clear_advertising_data = + _bt_adapter_le_clear_advertising_data_ptr + .asFunction<_dart_bt_adapter_le_clear_advertising_data>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1 + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Start advertising with passed advertiser and advertising parameters. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @details Once Bluetooth advertising is started, nearby Bluetooth LE(Low Energy) supported + /// devices can know this device's existence. And one of them can make a connection request, + /// if it is allowed. + /// + /// @param[in] advertiser The handle of advertiser + /// @param[in] adv_params The parameters of advertising \n + /// If NULL is passed, default values which are defined in driver / controller are used. + /// @param[in] cb The callback to report the result of this function + /// @param[in] user_data The user data to be passed when callback is called + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOW_IN_PROGRESS Operation is now in progress + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post This function invokes bt_adapter_le_advertising_state_changed_cb(). + /// + /// @see bt_adapter_le_stop_advertising() + /// @see bt_adapter_le_advertising_state_changed_cb() + int bt_adapter_le_start_advertising( + ffi.Pointer advertiser, + ffi.Pointer adv_params, + ffi.Pointer> + cb, + ffi.Pointer user_data, + ) { + return _bt_adapter_le_start_advertising( + advertiser, + adv_params, + cb, + user_data, + ); + } + + late final _bt_adapter_le_start_advertising_ptr = + _lookup>( + 'bt_adapter_le_start_advertising'); + late final _dart_bt_adapter_le_start_advertising + _bt_adapter_le_start_advertising = _bt_adapter_le_start_advertising_ptr + .asFunction<_dart_bt_adapter_le_start_advertising>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Stops the advertising. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] advertiser The handle of advertiser + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOT_IN_PROGRESS Operation is not in progress + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The advertising must be going on with bt_adapter_le_start_advertising_new(). + /// @post This function invokes bt_adapter_le_advertising_state_changed_cb(). + /// + /// @see bt_adapter_le_start_advertising_new() + /// @see bt_adapter_le_advertising_state_changed_cb() + int bt_adapter_le_stop_advertising( + ffi.Pointer advertiser, + ) { + return _bt_adapter_le_stop_advertising( + advertiser, + ); + } + + late final _bt_adapter_le_stop_advertising_ptr = + _lookup>( + 'bt_adapter_le_stop_advertising'); + late final _dart_bt_adapter_le_stop_advertising + _bt_adapter_le_stop_advertising = _bt_adapter_le_stop_advertising_ptr + .asFunction<_dart_bt_adapter_le_stop_advertising>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Start advertising with passed advertiser and advertising parameters. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @details Once Bluetooth advertising is started, nearby Bluetooth LE(Low Energy) supported + /// devices can know this device's existence. And one of them can make a connection request, + /// if it is allowed. + /// + /// @param[in] advertiser The handle of advertiser + /// @param[in] cb The callback to report the result of this function + /// @param[in] user_data The user data to be passed when callback is called + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOW_IN_PROGRESS Operation is now in progress + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post This function invokes bt_adapter_le_advertising_state_changed_cb(). + /// + /// @see bt_adapter_le_stop_advertising() + /// @see bt_adapter_le_advertising_state_changed_cb() + int bt_adapter_le_start_advertising_new( + ffi.Pointer advertiser, + ffi.Pointer> + cb, + ffi.Pointer user_data, + ) { + return _bt_adapter_le_start_advertising_new( + advertiser, + cb, + user_data, + ); + } + + late final _bt_adapter_le_start_advertising_new_ptr = + _lookup>( + 'bt_adapter_le_start_advertising_new'); + late final _dart_bt_adapter_le_start_advertising_new + _bt_adapter_le_start_advertising_new = + _bt_adapter_le_start_advertising_new_ptr + .asFunction<_dart_bt_adapter_le_start_advertising_new>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Set advertising mode to control the advertising power and latency. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] advertiser The handle of advertiser + /// @param[in] mode The mode of advertising + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOW_IN_PROGRESS Operation is now in progress + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_start_advertising_new() + int bt_adapter_le_set_advertising_mode( + ffi.Pointer advertiser, + int mode, + ) { + return _bt_adapter_le_set_advertising_mode( + advertiser, + mode, + ); + } + + late final _bt_adapter_le_set_advertising_mode_ptr = + _lookup>( + 'bt_adapter_le_set_advertising_mode'); + late final _dart_bt_adapter_le_set_advertising_mode + _bt_adapter_le_set_advertising_mode = + _bt_adapter_le_set_advertising_mode_ptr + .asFunction<_dart_bt_adapter_le_set_advertising_mode>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Set whether the advertising type should be connectable or non-connectable + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] advertiser The handle of advertiser + /// @param[in] connectable The type of advertising + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOW_IN_PROGRESS Operation is now in progress + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_start_advertising_new() + int bt_adapter_le_set_advertising_connectable( + ffi.Pointer advertiser, + bool connectable, + ) { + return _bt_adapter_le_set_advertising_connectable( + advertiser, + connectable ? 1 : 0, + ); + } + + late final _bt_adapter_le_set_advertising_connectable_ptr = + _lookup>( + 'bt_adapter_le_set_advertising_connectable'); + late final _dart_bt_adapter_le_set_advertising_connectable + _bt_adapter_le_set_advertising_connectable = + _bt_adapter_le_set_advertising_connectable_ptr + .asFunction<_dart_bt_adapter_le_set_advertising_connectable>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Sets Bluetooth LE scan mode + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] scan_mode The scan mode + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_ENABLED Adapter is not enabled + /// @retval #BT_ERROR_INVALID_PARAMETER Parameter is invalid + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// @pre The state of local bluetooth must be #BT_ADAPTER_ENABLED. + /// @pre The bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + int bt_adapter_le_set_scan_mode( + int scan_mode, + ) { + return _bt_adapter_le_set_scan_mode( + scan_mode, + ); + } + + late final _bt_adapter_le_set_scan_mode_ptr = + _lookup>( + 'bt_adapter_le_set_scan_mode'); + late final _dart_bt_adapter_le_set_scan_mode _bt_adapter_le_set_scan_mode = + _bt_adapter_le_set_scan_mode_ptr + .asFunction<_dart_bt_adapter_le_set_scan_mode>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Creates a bond with a remote Bluetooth device, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @remarks A bond can be destroyed by bt_device_destroy_bond().\n + /// The bonding request can be cancelled by bt_device_cancel_bonding(). + /// + /// @param[in] remote_address The address of the remote Bluetooth device with which the bond should be created + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_RESOURCE_BUSY Device or resource busy + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @pre The remote device must be discoverable with bt_adapter_start_device_discovery(). + /// @post This function invokes bt_device_bond_created_cb(). + /// + /// @see bt_adapter_start_device_discovery() + /// @see bt_device_bond_created_cb() + /// @see bt_device_cancel_bonding() + /// @see bt_device_destroy_bond() + /// @see bt_device_set_bond_created_cb() + /// @see bt_device_unset_bond_created_cb() + int bt_device_create_bond( + ffi.Pointer remote_address, + ) { + return _bt_device_create_bond( + remote_address, + ); + } + + late final _bt_device_create_bond_ptr = + _lookup>( + 'bt_device_create_bond'); + late final _dart_bt_device_create_bond _bt_device_create_bond = + _bt_device_create_bond_ptr.asFunction<_dart_bt_device_create_bond>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Cancels the bonding process. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @remarks Use this function when the remote Bluetooth device is not responding to the + /// bond request or you wish to cancel the bonding request. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOT_IN_PROGRESS Operation not in progress + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The creating a bond must be in progress by bt_device_create_bond(). + /// + /// @see bt_device_create_bond() + /// @see bt_device_bond_created_cb() + /// @see bt_device_set_bond_created_cb() + /// @see bt_device_unset_bond_created_cb() + int bt_device_cancel_bonding() { + return _bt_device_cancel_bonding(); + } + + late final _bt_device_cancel_bonding_ptr = + _lookup>( + 'bt_device_cancel_bonding'); + late final _dart_bt_device_cancel_bonding _bt_device_cancel_bonding = + _bt_device_cancel_bonding_ptr + .asFunction<_dart_bt_device_cancel_bonding>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Destroys the bond, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] remote_address The address of the remote Bluetooth device to remove bonding + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_RESOURCE_BUSY Device or resource busy + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_BONDED Remote device not bonded + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @pre The bond with the remote device must be created with bt_device_create_bond(). + /// @post This function invokes bt_device_bond_destroyed_cb(). + /// + /// @see bt_device_create_bond() + /// @see bt_device_bond_destroyed_cb() + /// @see bt_device_set_bond_destroyed_cb() + /// @see bt_device_unset_bond_destroyed_cb() + int bt_device_destroy_bond( + ffi.Pointer remote_address, + ) { + return _bt_device_destroy_bond( + remote_address, + ); + } + + late final _bt_device_destroy_bond_ptr = + _lookup>( + 'bt_device_destroy_bond'); + late final _dart_bt_device_destroy_bond _bt_device_destroy_bond = + _bt_device_destroy_bond_ptr.asFunction<_dart_bt_device_destroy_bond>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Sets an alias for the bonded device. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] remote_address The address of the remote Bluetooth device + /// @param[in] alias The alias of the remote Bluetooth device + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_BONDED Remote device not bonded + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @pre The bond with the remote device must be created with bt_device_create_bond(). + /// + /// @see bt_device_create_bond() + int bt_device_set_alias( + ffi.Pointer remote_address, + ffi.Pointer alias, + ) { + return _bt_device_set_alias( + remote_address, + alias, + ); + } + + late final _bt_device_set_alias_ptr = + _lookup>( + 'bt_device_set_alias'); + late final _dart_bt_device_set_alias _bt_device_set_alias = + _bt_device_set_alias_ptr.asFunction<_dart_bt_device_set_alias>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Sets the authorization of a bonded device, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @remarks Once a device is authorized, you don't need to receive a confirmation. + /// + /// @param[in] remote_address The address of the remote Bluetooth device to authorize + /// @param[in] authorization_state The Bluetooth authorization state + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_BONDED Remote device not bonded + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @pre The bond with the remote device must be created with bt_device_create_bond(). + /// @post bt_device_authorization_changed_cb() will be invoked. + /// + /// @see bt_device_create_bond() + /// @see bt_device_authorization_changed_cb() + /// @see bt_device_set_authorization_changed_cb() + /// @see bt_device_unset_authorization_changed_cb() + int bt_device_set_authorization( + ffi.Pointer remote_address, + int authorization_state, + ) { + return _bt_device_set_authorization( + remote_address, + authorization_state, + ); + } + + late final _bt_device_set_authorization_ptr = + _lookup>( + 'bt_device_set_authorization'); + late final _dart_bt_device_set_authorization _bt_device_set_authorization = + _bt_device_set_authorization_ptr + .asFunction<_dart_bt_device_set_authorization>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Starts the search for services supported by the specified device, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @remarks If creating a bond succeeds, which means bt_device_bond_created_cb() is called with result #BT_ERROR_NONE, + /// then you don't need to run this function.\n + /// The service search takes a couple of seconds to complete normally. \n + /// + /// @param[in] remote_address The address of the remote Bluetooth device whose services need to be checked + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_BONDED Remote device not bonded + /// @retval #BT_ERROR_SERVICE_SEARCH_FAILED Service search failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @pre The remote device must be discoverable with bt_adapter_start_device_discovery(). + /// @pre The bond with the remote device must be created with bt_device_create_bond(). + /// @post This function invokes bt_device_service_searched_cb(). + /// + /// @see bt_adapter_start_device_discovery() + /// @see bt_device_create_bond() + /// @see bt_device_bond_created_cb() + /// @see bt_device_service_searched_cb() + /// @see bt_device_set_service_searched_cb() + /// @see bt_device_unset_service_searched_cb() + int bt_device_start_service_search( + ffi.Pointer remote_address, + ) { + return _bt_device_start_service_search( + remote_address, + ); + } + + late final _bt_device_start_service_search_ptr = + _lookup>( + 'bt_device_start_service_search'); + late final _dart_bt_device_start_service_search + _bt_device_start_service_search = _bt_device_start_service_search_ptr + .asFunction<_dart_bt_device_start_service_search>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Gets the connected profiles. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] remote_address The address of the remote device + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @post bt_device_connected_profile() will be invoked. + /// @see bt_device_connected_profile() + int bt_device_foreach_connected_profiles( + ffi.Pointer remote_address, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_device_foreach_connected_profiles( + remote_address, + callback, + user_data, + ); + } + + late final _bt_device_foreach_connected_profiles_ptr = + _lookup>( + 'bt_device_foreach_connected_profiles'); + late final _dart_bt_device_foreach_connected_profiles + _bt_device_foreach_connected_profiles = + _bt_device_foreach_connected_profiles_ptr + .asFunction<_dart_bt_device_foreach_connected_profiles>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Gets the profile connected status. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] remote_address The address of the remote device + /// @param[in] bt_profile wish to know bt_profile + /// @param[out] connected_status the connected status + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_BONDED Remote device not bonded + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + int bt_device_is_profile_connected( + ffi.Pointer remote_address, + int bt_profile, + ffi.Pointer connected_status, + ) { + return _bt_device_is_profile_connected( + remote_address, + bt_profile, + connected_status, + ); + } + + late final _bt_device_is_profile_connected_ptr = + _lookup>( + 'bt_device_is_profile_connected'); + late final _dart_bt_device_is_profile_connected + _bt_device_is_profile_connected = _bt_device_is_profile_connected_ptr + .asFunction<_dart_bt_device_is_profile_connected>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Updates a LE connection mode + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] remote_address The address of the remote Bluetooth device + /// @param[in] mode The LE connection mode + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_device_update_le_connection_mode( + ffi.Pointer remote_address, + int mode, + ) { + return _bt_device_update_le_connection_mode( + remote_address, + mode, + ); + } + + late final _bt_device_update_le_connection_mode_ptr = + _lookup>( + 'bt_device_update_le_connection_mode'); + late final _dart_bt_device_update_le_connection_mode + _bt_device_update_le_connection_mode = + _bt_device_update_le_connection_mode_ptr + .asFunction<_dart_bt_device_update_le_connection_mode>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Registers a callback function to be invoked when the bond creates. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post bt_device_bond_created_cb() will be invoked. + /// @see bt_initialize() + /// @see bt_device_bond_created_cb() + /// @see bt_device_unset_bond_created_cb() + int bt_device_set_bond_created_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_device_set_bond_created_cb( + callback, + user_data, + ); + } + + late final _bt_device_set_bond_created_cb_ptr = + _lookup>( + 'bt_device_set_bond_created_cb'); + late final _dart_bt_device_set_bond_created_cb + _bt_device_set_bond_created_cb = _bt_device_set_bond_created_cb_ptr + .asFunction<_dart_bt_device_set_bond_created_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Unregisters the callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_device_set_bond_created_cb() + int bt_device_unset_bond_created_cb() { + return _bt_device_unset_bond_created_cb(); + } + + late final _bt_device_unset_bond_created_cb_ptr = + _lookup>( + 'bt_device_unset_bond_created_cb'); + late final _dart_bt_device_unset_bond_created_cb + _bt_device_unset_bond_created_cb = _bt_device_unset_bond_created_cb_ptr + .asFunction<_dart_bt_device_unset_bond_created_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Registers a callback function to be invoked when the bond destroys. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post bt_device_bond_destroyed_cb() will be invoked. + /// @see bt_initialize() + /// @see bt_device_bond_destroyed_cb() + /// @see bt_device_unset_bond_destroyed_cb() + int bt_device_set_bond_destroyed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_device_set_bond_destroyed_cb( + callback, + user_data, + ); + } + + late final _bt_device_set_bond_destroyed_cb_ptr = + _lookup>( + 'bt_device_set_bond_destroyed_cb'); + late final _dart_bt_device_set_bond_destroyed_cb + _bt_device_set_bond_destroyed_cb = _bt_device_set_bond_destroyed_cb_ptr + .asFunction<_dart_bt_device_set_bond_destroyed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Unregisters the callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_device_set_bond_destroyed_cb() + int bt_device_unset_bond_destroyed_cb() { + return _bt_device_unset_bond_destroyed_cb(); + } + + late final _bt_device_unset_bond_destroyed_cb_ptr = + _lookup>( + 'bt_device_unset_bond_destroyed_cb'); + late final _dart_bt_device_unset_bond_destroyed_cb + _bt_device_unset_bond_destroyed_cb = + _bt_device_unset_bond_destroyed_cb_ptr + .asFunction<_dart_bt_device_unset_bond_destroyed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Registers a callback function to be invoked when the authorization of device changes. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post bt_device_authorization_changed_cb() will be invoked. + /// @see bt_initialize() + /// @see bt_device_authorization_changed_cb() + /// @see bt_device_set_authorization_changed_cb() + /// @see bt_device_unset_authorization_changed_cb() + int bt_device_set_authorization_changed_cb( + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_device_set_authorization_changed_cb( + callback, + user_data, + ); + } + + late final _bt_device_set_authorization_changed_cb_ptr = + _lookup>( + 'bt_device_set_authorization_changed_cb'); + late final _dart_bt_device_set_authorization_changed_cb + _bt_device_set_authorization_changed_cb = + _bt_device_set_authorization_changed_cb_ptr + .asFunction<_dart_bt_device_set_authorization_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Unregisters the callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_device_set_authorization_changed_cb() + int bt_device_unset_authorization_changed_cb() { + return _bt_device_unset_authorization_changed_cb(); + } + + late final _bt_device_unset_authorization_changed_cb_ptr = + _lookup>( + 'bt_device_unset_authorization_changed_cb'); + late final _dart_bt_device_unset_authorization_changed_cb + _bt_device_unset_authorization_changed_cb = + _bt_device_unset_authorization_changed_cb_ptr + .asFunction<_dart_bt_device_unset_authorization_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Registers a callback function to be invoked when the process of service search finishes. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post bt_device_service_searched_cb() will be invoked. + /// @see bt_initialize() + /// @see bt_device_service_searched_cb() + /// @see bt_device_unset_service_searched_cb() + int bt_device_set_service_searched_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_device_set_service_searched_cb( + callback, + user_data, + ); + } + + late final _bt_device_set_service_searched_cb_ptr = + _lookup>( + 'bt_device_set_service_searched_cb'); + late final _dart_bt_device_set_service_searched_cb + _bt_device_set_service_searched_cb = + _bt_device_set_service_searched_cb_ptr + .asFunction<_dart_bt_device_set_service_searched_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Unregisters the callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_device_set_service_searched_cb() + int bt_device_unset_service_searched_cb() { + return _bt_device_unset_service_searched_cb(); + } + + late final _bt_device_unset_service_searched_cb_ptr = + _lookup>( + 'bt_device_unset_service_searched_cb'); + late final _dart_bt_device_unset_service_searched_cb + _bt_device_unset_service_searched_cb = + _bt_device_unset_service_searched_cb_ptr + .asFunction<_dart_bt_device_unset_service_searched_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Registers a callback function to be invoked when the connection state is changed. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post bt_device_connection_state_changed_cb() will be invoked. + /// @see bt_initialize() + /// @see bt_device_connection_state_changed_cb() + /// @see bt_device_unset_connection_state_changed_cb() + int bt_device_set_connection_state_changed_cb( + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_device_set_connection_state_changed_cb( + callback, + user_data, + ); + } + + late final _bt_device_set_connection_state_changed_cb_ptr = + _lookup>( + 'bt_device_set_connection_state_changed_cb'); + late final _dart_bt_device_set_connection_state_changed_cb + _bt_device_set_connection_state_changed_cb = + _bt_device_set_connection_state_changed_cb_ptr + .asFunction<_dart_bt_device_set_connection_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE + /// @brief Unregisters the callback function to be invoked when the connection state is changed. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_device_set_connection_state_changed_cb() + int bt_device_unset_connection_state_changed_cb() { + return _bt_device_unset_connection_state_changed_cb(); + } + + late final _bt_device_unset_connection_state_changed_cb_ptr = _lookup< + ffi.NativeFunction<_c_bt_device_unset_connection_state_changed_cb>>( + 'bt_device_unset_connection_state_changed_cb'); + late final _dart_bt_device_unset_connection_state_changed_cb + _bt_device_unset_connection_state_changed_cb = + _bt_device_unset_connection_state_changed_cb_ptr + .asFunction<_dart_bt_device_unset_connection_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE + /// @brief Registers a rfcomm server socket with a specific UUID. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @remarks A socket can be destroyed by bt_socket_destroy_rfcomm(). + /// + /// @param[in] service_uuid The UUID of service to provide + /// @param[out] socket_fd The file descriptor of socket to listen + /// @return 0 on success, otherwise a negative error value. + /// + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// + /// @see bt_socket_listen_and_accept_rfcomm() + /// @see bt_socket_destroy_rfcomm() + int bt_socket_create_rfcomm( + ffi.Pointer service_uuid, + ffi.Pointer socket_fd, + ) { + return _bt_socket_create_rfcomm( + service_uuid, + socket_fd, + ); + } + + late final _bt_socket_create_rfcomm_ptr = + _lookup>( + 'bt_socket_create_rfcomm'); + late final _dart_bt_socket_create_rfcomm _bt_socket_create_rfcomm = + _bt_socket_create_rfcomm_ptr.asFunction<_dart_bt_socket_create_rfcomm>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE + /// @brief Removes the rfcomm server socket which was created using bt_socket_create_rfcomm(). + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @remarks If callback function bt_socket_connection_state_changed_cb() is set and the remote Bluetooth device is connected, + /// then bt_socket_connection_state_changed_cb() will be called when this function is finished successfully. + /// + /// @param[in] socket_fd The file descriptor of socket (which was created using bt_socket_create_rfcomm()) to destroy + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The socket must be created with bt_socket_create_rfcomm(). + /// @post If callback function bt_socket_connection_state_changed_cb() is set and the remote Bluetooth device is connected, + /// then bt_socket_connection_state_changed_cb() will be called. + /// @see bt_socket_create_rfcomm() + /// @see bt_socket_connection_state_changed_cb() + /// @see bt_socket_set_connection_state_changed_cb() + /// @see bt_socket_unset_connection_state_changed_cb() + int bt_socket_destroy_rfcomm( + int socket_fd, + ) { + return _bt_socket_destroy_rfcomm( + socket_fd, + ); + } + + late final _bt_socket_destroy_rfcomm_ptr = + _lookup>( + 'bt_socket_destroy_rfcomm'); + late final _dart_bt_socket_destroy_rfcomm _bt_socket_destroy_rfcomm = + _bt_socket_destroy_rfcomm_ptr + .asFunction<_dart_bt_socket_destroy_rfcomm>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE + /// @brief Starts listening on passed rfcomm socket and accepts connection requests. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @details Pop-up is shown automatically when a RFCOMM connection is requested. + /// bt_socket_connection_state_changed_cb() will be called with + /// #BT_SOCKET_CONNECTED if you click "yes" and connection is finished successfully. + /// @param[in] socket_fd The file descriptor of socket on which start to listen + /// @param[in] max_pending_connections The maximum number of pending connections + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The socket must be created with bt_socket_create_rfcomm(). + /// @post If callback function bt_socket_connection_state_changed_cb() is set, + /// then bt_socket_connection_state_changed_cb() will be called when the remote Bluetooth device is connected. + /// @see bt_socket_create_rfcomm() + /// @see bt_socket_connection_state_changed_cb() + /// @see bt_socket_set_connection_state_changed_cb() + /// @see bt_socket_unset_connection_state_changed_cb() + int bt_socket_listen_and_accept_rfcomm( + int socket_fd, + int max_pending_connections, + ) { + return _bt_socket_listen_and_accept_rfcomm( + socket_fd, + max_pending_connections, + ); + } + + late final _bt_socket_listen_and_accept_rfcomm_ptr = + _lookup>( + 'bt_socket_listen_and_accept_rfcomm'); + late final _dart_bt_socket_listen_and_accept_rfcomm + _bt_socket_listen_and_accept_rfcomm = + _bt_socket_listen_and_accept_rfcomm_ptr + .asFunction<_dart_bt_socket_listen_and_accept_rfcomm>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE + /// @brief Connects to a specific RFCOMM based service on a remote Bluetooth device UUID, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @remarks A connection can be disconnected by bt_socket_disconnect_rfcomm(). + /// + /// @param[in] remote_address The address of the remote Bluetooth device + /// @param[in] service_uuid The UUID of service provided by the remote Bluetooth device + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @pre The remote device must be discoverable with bt_adapter_start_device_discovery(). + /// @pre The bond with the remote device must be created with bt_device_create_bond(). + /// @post This function invokes bt_socket_connection_state_changed_cb(). + /// + /// @see bt_device_create_bond() + /// @see bt_adapter_start_device_discovery() + /// @see bt_device_start_service_search() + /// @see bt_socket_disconnect_rfcomm() + /// @see bt_socket_connection_state_changed_cb() + /// @see bt_socket_set_connection_state_changed_cb() + /// @see bt_socket_unset_connection_state_changed_cb() + int bt_socket_connect_rfcomm( + ffi.Pointer remote_address, + ffi.Pointer service_uuid, + ) { + return _bt_socket_connect_rfcomm( + remote_address, + service_uuid, + ); + } + + late final _bt_socket_connect_rfcomm_ptr = + _lookup>( + 'bt_socket_connect_rfcomm'); + late final _dart_bt_socket_connect_rfcomm _bt_socket_connect_rfcomm = + _bt_socket_connect_rfcomm_ptr + .asFunction<_dart_bt_socket_connect_rfcomm>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE + /// @brief Disconnects the RFCOMM connection with the given file descriptor of connected socket. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] socket_fd The file descriptor of socket to close which was received using bt_socket_connection_state_changed_cb(). + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The connection must be established. + /// + /// @see bt_socket_connection_state_changed_cb() + /// @see bt_socket_set_connection_state_changed_cb() + /// @see bt_socket_unset_connection_state_changed_cb() + int bt_socket_disconnect_rfcomm( + int socket_fd, + ) { + return _bt_socket_disconnect_rfcomm( + socket_fd, + ); + } + + late final _bt_socket_disconnect_rfcomm_ptr = + _lookup>( + 'bt_socket_disconnect_rfcomm'); + late final _dart_bt_socket_disconnect_rfcomm _bt_socket_disconnect_rfcomm = + _bt_socket_disconnect_rfcomm_ptr + .asFunction<_dart_bt_socket_disconnect_rfcomm>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE + /// @brief Sends data to the connected device. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @remark The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// + /// @param[in] socket_fd The file descriptor of connected socket which was received using bt_socket_connection_state_changed_cb() + /// @param[in] data The data to be sent + /// @param[in] length The length of data to be sent + /// + /// @return the number of bytes written (zero indicates nothing was written). + /// @retval On error, -1 is returned, and errno is set appropriately. See write 2 man page. + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// @exception BT_ERROR_PERMISSION_DENIED Permission denied + /// @exception BT_ERROR_AGAIN Resource temporarily unavailable + /// + /// @pre The connection must be established. + /// + /// @see bt_socket_connection_state_changed_cb() + /// @see bt_socket_set_connection_state_changed_cb() + /// @see bt_socket_unset_connection_state_changed_cb() + int bt_socket_send_data( + int socket_fd, + ffi.Pointer data, + int length, + ) { + return _bt_socket_send_data( + socket_fd, + data, + length, + ); + } + + late final _bt_socket_send_data_ptr = + _lookup>( + 'bt_socket_send_data'); + late final _dart_bt_socket_send_data _bt_socket_send_data = + _bt_socket_send_data_ptr.asFunction<_dart_bt_socket_send_data>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE + /// @brief Register a callback function that will be invoked when you receive data. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post bt_socket_data_received_cb() will be invoked. + /// @see bt_initialize() + /// @see bt_socket_data_received_cb() + /// @see bt_socket_set_data_received_cb() + /// @see bt_socket_unset_data_received_cb() + int bt_socket_set_data_received_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_socket_set_data_received_cb( + callback, + user_data, + ); + } + + late final _bt_socket_set_data_received_cb_ptr = + _lookup>( + 'bt_socket_set_data_received_cb'); + late final _dart_bt_socket_set_data_received_cb + _bt_socket_set_data_received_cb = _bt_socket_set_data_received_cb_ptr + .asFunction<_dart_bt_socket_set_data_received_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE + /// @brief Unregisters the callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_socket_data_received_cb() + /// @see bt_socket_set_data_received_cb() + int bt_socket_unset_data_received_cb() { + return _bt_socket_unset_data_received_cb(); + } + + late final _bt_socket_unset_data_received_cb_ptr = + _lookup>( + 'bt_socket_unset_data_received_cb'); + late final _dart_bt_socket_unset_data_received_cb + _bt_socket_unset_data_received_cb = _bt_socket_unset_data_received_cb_ptr + .asFunction<_dart_bt_socket_unset_data_received_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE + /// @brief Register a callback function that will be invoked when a RFCOMM connection is requested. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post bt_socket_connection_requested_cb() will be invoked. + /// @see bt_initialize() + /// @see bt_socket_unset_connection_requested_cb() + int bt_socket_set_connection_requested_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_socket_set_connection_requested_cb( + callback, + user_data, + ); + } + + late final _bt_socket_set_connection_requested_cb_ptr = + _lookup>( + 'bt_socket_set_connection_requested_cb'); + late final _dart_bt_socket_set_connection_requested_cb + _bt_socket_set_connection_requested_cb = + _bt_socket_set_connection_requested_cb_ptr + .asFunction<_dart_bt_socket_set_connection_requested_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE + /// @brief Unregisters the callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_socket_set_connection_requested_cb() + /// @see bt_socket_connection_requested_cb() + int bt_socket_unset_connection_requested_cb() { + return _bt_socket_unset_connection_requested_cb(); + } + + late final _bt_socket_unset_connection_requested_cb_ptr = + _lookup>( + 'bt_socket_unset_connection_requested_cb'); + late final _dart_bt_socket_unset_connection_requested_cb + _bt_socket_unset_connection_requested_cb = + _bt_socket_unset_connection_requested_cb_ptr + .asFunction<_dart_bt_socket_unset_connection_requested_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE + /// @brief Register a callback function that will be invoked when the connection state changes. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post bt_socket_connection_state_changed_cb() will be invoked. + /// @see bt_initialize() + /// @see bt_socket_connection_state_changed_cb() + /// @see bt_socket_unset_connection_state_changed_cb() + int bt_socket_set_connection_state_changed_cb( + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_socket_set_connection_state_changed_cb( + callback, + user_data, + ); + } + + late final _bt_socket_set_connection_state_changed_cb_ptr = + _lookup>( + 'bt_socket_set_connection_state_changed_cb'); + late final _dart_bt_socket_set_connection_state_changed_cb + _bt_socket_set_connection_state_changed_cb = + _bt_socket_set_connection_state_changed_cb_ptr + .asFunction<_dart_bt_socket_set_connection_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE + /// @brief Unregisters the callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_socket_connection_state_changed_cb() + /// @see bt_socket_set_connection_state_changed_cb() + int bt_socket_unset_connection_state_changed_cb() { + return _bt_socket_unset_connection_state_changed_cb(); + } + + late final _bt_socket_unset_connection_state_changed_cb_ptr = _lookup< + ffi.NativeFunction<_c_bt_socket_unset_connection_state_changed_cb>>( + 'bt_socket_unset_connection_state_changed_cb'); + late final _dart_bt_socket_unset_connection_state_changed_cb + _bt_socket_unset_connection_state_changed_cb = + _bt_socket_unset_connection_state_changed_cb_ptr + .asFunction<_dart_bt_socket_unset_connection_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OPP_SERVER_MODULE + /// @brief Initializes the Bluetooth OPP server requested by bt_opp_server_connection_requested_cb(). + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @details No popup appears when an OPP connection is requested from a remote device. + /// Instead, @a connection_requested_cb() will be called. + /// At that time, you can call either bt_opp_server_accept() or bt_opp_server_reject(). + /// @remarks This function must be called to start Bluetooth OPP server. \n + /// You must free all resources of the Bluetooth service by calling bt_opp_server_deinitialize() if Bluetooth OPP service is no longer needed. + /// @param[in] destination The destination path + /// @param[in] connection_requested_cb The callback called when an OPP connection is requested + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_RESOURCE_BUSY Device or resource busy + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_opp_server_connection_requested_cb() + /// @see bt_opp_server_deinitialize() + /// @see bt_opp_server_accept() + /// @see bt_opp_server_reject() + int bt_opp_server_initialize_by_connection_request( + ffi.Pointer destination, + ffi.Pointer> + connection_requested_cb, + ffi.Pointer user_data, + ) { + return _bt_opp_server_initialize_by_connection_request( + destination, + connection_requested_cb, + user_data, + ); + } + + late final _bt_opp_server_initialize_by_connection_request_ptr = _lookup< + ffi.NativeFunction< + _c_bt_opp_server_initialize_by_connection_request>>( + 'bt_opp_server_initialize_by_connection_request'); + late final _dart_bt_opp_server_initialize_by_connection_request + _bt_opp_server_initialize_by_connection_request = + _bt_opp_server_initialize_by_connection_request_ptr + .asFunction<_dart_bt_opp_server_initialize_by_connection_request>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OPP_SERVER_MODULE + /// @brief Deinitializes the Bluetooth OPP server. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_opp_server_deinitialize() + int bt_opp_server_deinitialize() { + return _bt_opp_server_deinitialize(); + } + + late final _bt_opp_server_deinitialize_ptr = + _lookup>( + 'bt_opp_server_deinitialize'); + late final _dart_bt_opp_server_deinitialize _bt_opp_server_deinitialize = + _bt_opp_server_deinitialize_ptr + .asFunction<_dart_bt_opp_server_deinitialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OPP_SERVER_MODULE + /// @brief Accepts the push request from the remote device. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @remarks If you initialize OPP server by bt_opp_server_initialize_by_connection_request(), then name is ignored. + /// You can cancel the pushes by bt_opp_server_cancel_transfer() with transfer_id. + /// @param[in] progress_cb The callback called when a file is being transferred + /// @param[in] finished_cb The callback called when a transfer is finished + /// @param[in] name The name to store. This can be NULL if you initialize OPP server by bt_opp_server_initialize_by_connection_request(). + /// @param[in] user_data The user data to be passed to the callback function + /// @param[out] transfer_id The ID of transfer + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOW_IN_PROGRESS Operation now in progress + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_opp_server_reject() + int bt_opp_server_accept( + ffi.Pointer> + progress_cb, + ffi.Pointer> + finished_cb, + ffi.Pointer name, + ffi.Pointer user_data, + ffi.Pointer transfer_id, + ) { + return _bt_opp_server_accept( + progress_cb, + finished_cb, + name, + user_data, + transfer_id, + ); + } + + late final _bt_opp_server_accept_ptr = + _lookup>( + 'bt_opp_server_accept'); + late final _dart_bt_opp_server_accept _bt_opp_server_accept = + _bt_opp_server_accept_ptr.asFunction<_dart_bt_opp_server_accept>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OPP_SERVER_MODULE + /// @brief Rejects the push request from the remote device. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_opp_server_accept() + int bt_opp_server_reject() { + return _bt_opp_server_reject(); + } + + late final _bt_opp_server_reject_ptr = + _lookup>( + 'bt_opp_server_reject'); + late final _dart_bt_opp_server_reject _bt_opp_server_reject = + _bt_opp_server_reject_ptr.asFunction<_dart_bt_opp_server_reject>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OPP_SERVER_MODULE + /// @brief Cancels the transfer. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] transfer_id The ID of transfer + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_opp_server_accept() + int bt_opp_server_cancel_transfer( + int transfer_id, + ) { + return _bt_opp_server_cancel_transfer( + transfer_id, + ); + } + + late final _bt_opp_server_cancel_transfer_ptr = + _lookup>( + 'bt_opp_server_cancel_transfer'); + late final _dart_bt_opp_server_cancel_transfer + _bt_opp_server_cancel_transfer = _bt_opp_server_cancel_transfer_ptr + .asFunction<_dart_bt_opp_server_cancel_transfer>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OPP_SERVER_MODULE + /// @brief Sets the destination path of file to be pushed. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] destination The destination path of file to be pushed + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_opp_server_set_destination( + ffi.Pointer destination, + ) { + return _bt_opp_server_set_destination( + destination, + ); + } + + late final _bt_opp_server_set_destination_ptr = + _lookup>( + 'bt_opp_server_set_destination'); + late final _dart_bt_opp_server_set_destination + _bt_opp_server_set_destination = _bt_opp_server_set_destination_ptr + .asFunction<_dart_bt_opp_server_set_destination>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OPP_CLIENT_MODULE + /// @brief Initializes the Bluetooth OPP client. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks This function must be called before Bluetooth OPP client starts. \n + /// You must free all resources of the Bluetooth service by calling bt_opp_client_deinitialize() + /// if Bluetooth OPP service is no longer needed. + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_RESOURCE_BUSY Device or resource busy + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_opp_client_deinitialize() + int bt_opp_client_initialize() { + return _bt_opp_client_initialize(); + } + + late final _bt_opp_client_initialize_ptr = + _lookup>( + 'bt_opp_client_initialize'); + late final _dart_bt_opp_client_initialize _bt_opp_client_initialize = + _bt_opp_client_initialize_ptr + .asFunction<_dart_bt_opp_client_initialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OPP_CLIENT_MODULE + /// @brief Deinitializes the Bluetooth OPP client. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_opp_client_initialize() + int bt_opp_client_deinitialize() { + return _bt_opp_client_deinitialize(); + } + + late final _bt_opp_client_deinitialize_ptr = + _lookup>( + 'bt_opp_client_deinitialize'); + late final _dart_bt_opp_client_deinitialize _bt_opp_client_deinitialize = + _bt_opp_client_deinitialize_ptr + .asFunction<_dart_bt_opp_client_deinitialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OPP_CLIENT_MODULE + /// @brief Adds file to be pushed. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] file The path of file to be pushed + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_opp_client_clear_files() + /// @see bt_opp_client_push_files() + int bt_opp_client_add_file( + ffi.Pointer file, + ) { + return _bt_opp_client_add_file( + file, + ); + } + + late final _bt_opp_client_add_file_ptr = + _lookup>( + 'bt_opp_client_add_file'); + late final _dart_bt_opp_client_add_file _bt_opp_client_add_file = + _bt_opp_client_add_file_ptr.asFunction<_dart_bt_opp_client_add_file>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OPP_CLIENT_MODULE + /// @brief Adds file to be pushed. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_opp_client_add_file() + /// @see bt_opp_client_push_files() + int bt_opp_client_clear_files() { + return _bt_opp_client_clear_files(); + } + + late final _bt_opp_client_clear_files_ptr = + _lookup>( + 'bt_opp_client_clear_files'); + late final _dart_bt_opp_client_clear_files _bt_opp_client_clear_files = + _bt_opp_client_clear_files_ptr + .asFunction<_dart_bt_opp_client_clear_files>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OPP_CLIENT_MODULE + /// @brief Pushes the file to the remote device, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @details At first, bt_opp_client_push_responded_cb() will be called when OPP server responds to the push request. + /// After connection is established, bt_opp_client_push_progress_cb() will be called repeatedly until a file is transferred completely. + /// If you send several files, then bt_opp_client_push_progress_cb() with another file will be called repeatedly until the file is transferred completely. + /// bt_opp_client_push_finished_cb() will be called when the push request is finished. + /// @param[in] remote_address The remote address + /// @param[in] responded_cb The callback called when OPP server responds to the push request + /// @param[in] progress_cb The callback called when each file is being transferred + /// @param[in] finished_cb The callback called when the push request is finished + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOW_IN_PROGRESS Operation now in progress + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_opp_client_initialize() + /// @see bt_opp_client_cancel_push + int bt_opp_client_push_files( + ffi.Pointer remote_address, + ffi.Pointer> + responded_cb, + ffi.Pointer> progress_cb, + ffi.Pointer> finished_cb, + ffi.Pointer user_data, + ) { + return _bt_opp_client_push_files( + remote_address, + responded_cb, + progress_cb, + finished_cb, + user_data, + ); + } + + late final _bt_opp_client_push_files_ptr = + _lookup>( + 'bt_opp_client_push_files'); + late final _dart_bt_opp_client_push_files _bt_opp_client_push_files = + _bt_opp_client_push_files_ptr + .asFunction<_dart_bt_opp_client_push_files>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_OPP_CLIENT_MODULE + /// @brief Cancels the push request in progress, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre bt_opp_client_push_files() must be called. + /// @post bt_opp_client_push_finished_cb() will be invoked with result #BT_ERROR_CANCELLED, + /// which is a parameter of bt_opp_client_push_files(). + /// @see bt_opp_client_initialize() + /// @see bt_opp_client_push_files() + int bt_opp_client_cancel_push() { + return _bt_opp_client_cancel_push(); + } + + late final _bt_opp_client_cancel_push_ptr = + _lookup>( + 'bt_opp_client_cancel_push'); + late final _dart_bt_opp_client_cancel_push _bt_opp_client_cancel_push = + _bt_opp_client_cancel_push_ptr + .asFunction<_dart_bt_opp_client_cancel_push>(); + + /// @ingroup @if WEARABLE CAPI_NETWORK_BLUETOOTH_HID_HOST_MODULE CAPI @else_NETWORK_BLUETOOTH_HID_MODULE @endif + /// @brief Initializes the Bluetooth HID(Human Interface Device) Host. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks This function must be called before Bluetooth HID Host starts. \n + /// You must free all resources of the Bluetooth service by calling bt_hid_host_deinitialize() + /// if Bluetooth HID Host service is no longer needed. + /// @param[in] connection_cb The callback called when the connection state is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_hid_host_deinitialize() + int bt_hid_host_initialize( + ffi.Pointer> + connection_cb, + ffi.Pointer user_data, + ) { + return _bt_hid_host_initialize( + connection_cb, + user_data, + ); + } + + late final _bt_hid_host_initialize_ptr = + _lookup>( + 'bt_hid_host_initialize'); + late final _dart_bt_hid_host_initialize _bt_hid_host_initialize = + _bt_hid_host_initialize_ptr.asFunction<_dart_bt_hid_host_initialize>(); + + /// @ingroup @if WEARABLE CAPI_NETWORK_BLUETOOTH_HID_HOST_MODULE CAPI @else_NETWORK_BLUETOOTH_HID_MODULE @endif + /// @brief Deinitializes the Bluetooth HID(Human Interface Device) Host. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth HID service must be initialized with bt_hid_host_initialize(). + /// @see bt_hid_host_initialize() + int bt_hid_host_deinitialize() { + return _bt_hid_host_deinitialize(); + } + + late final _bt_hid_host_deinitialize_ptr = + _lookup>( + 'bt_hid_host_deinitialize'); + late final _dart_bt_hid_host_deinitialize _bt_hid_host_deinitialize = + _bt_hid_host_deinitialize_ptr + .asFunction<_dart_bt_hid_host_deinitialize>(); + + /// @ingroup @if WEARABLE CAPI_NETWORK_BLUETOOTH_HID_HOST_MODULE CAPI @else_NETWORK_BLUETOOTH_HID_MODULE @endif + /// @brief Connects the remote device with the HID(Human Interface Device) service, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] remote_address The remote address + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The local device must be bonded with the remote device by bt_device_create_bond(). + /// @pre The Bluetooth HID service must be initialized with bt_hid_host_initialize(). + /// @post bt_hid_host_connection_state_changed_cb() will be invoked. + /// @see bt_hid_host_disconnect() + /// @see bt_hid_host_connection_state_changed_cb() + int bt_hid_host_connect( + ffi.Pointer remote_address, + ) { + return _bt_hid_host_connect( + remote_address, + ); + } + + late final _bt_hid_host_connect_ptr = + _lookup>( + 'bt_hid_host_connect'); + late final _dart_bt_hid_host_connect _bt_hid_host_connect = + _bt_hid_host_connect_ptr.asFunction<_dart_bt_hid_host_connect>(); + + /// @ingroup @if WEARABLE CAPI_NETWORK_BLUETOOTH_HID_HOST_MODULE CAPI @else_NETWORK_BLUETOOTH_HID_MODULE @endif + /// @brief Disconnects the remote device with the HID(Human Interface Device) service, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] remote_address The remote address + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected by bt_hid_host_connect(). + /// @post bt_hid_host_connection_state_changed_cb() will be invoked. + /// @see bt_hid_host_connect() + /// @see bt_hid_host_connection_state_changed_cb() + int bt_hid_host_disconnect( + ffi.Pointer remote_address, + ) { + return _bt_hid_host_disconnect( + remote_address, + ); + } + + late final _bt_hid_host_disconnect_ptr = + _lookup>( + 'bt_hid_host_disconnect'); + late final _dart_bt_hid_host_disconnect _bt_hid_host_disconnect = + _bt_hid_host_disconnect_ptr.asFunction<_dart_bt_hid_host_disconnect>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HID_DEVICE_MODULE + /// @brief Activates the Bluetooth HID Device role. + /// @since_tizen @if WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @remarks This function must be called to register HID UUID. + /// Only then a remote device is able to identify this one as a HID device. + /// + /// @param[in] callback The callback called when the connection state is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOW_IN_PROGRESS Already activated + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_hid_device_deactivate() + int bt_hid_device_activate( + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_hid_device_activate( + callback, + user_data, + ); + } + + late final _bt_hid_device_activate_ptr = + _lookup>( + 'bt_hid_device_activate'); + late final _dart_bt_hid_device_activate _bt_hid_device_activate = + _bt_hid_device_activate_ptr.asFunction<_dart_bt_hid_device_activate>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HID_DEVICE_MODULE + /// @brief Deactivates the Bluetooth HID Device role. + /// @since_tizen @if WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @remarks This function must be called to deregister the HID UUID. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOT_IN_PROGRESS Not activated + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_hid_device_activate() + int bt_hid_device_deactivate() { + return _bt_hid_device_deactivate(); + } + + late final _bt_hid_device_deactivate_ptr = + _lookup>( + 'bt_hid_device_deactivate'); + late final _dart_bt_hid_device_deactivate _bt_hid_device_deactivate = + _bt_hid_device_deactivate_ptr + .asFunction<_dart_bt_hid_device_deactivate>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HID_DEVICE_MODULE + /// @brief Initiates the HID device connection with the Device role, asynchronously. + /// @since_tizen @if WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @remarks This function must be called to Initiate the HID device role connection. + /// + /// @param[in] remote_address The remote device's address. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_NOT_IN_PROGRESS Not activated + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_ALREADY_DONE Already connected + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @pre The local device must be bonded with the remote device by bt_device_create_bond(). + /// @see bt_initialize() + /// @see bt_hid_device_activate() + int bt_hid_device_connect( + ffi.Pointer remote_address, + ) { + return _bt_hid_device_connect( + remote_address, + ); + } + + late final _bt_hid_device_connect_ptr = + _lookup>( + 'bt_hid_device_connect'); + late final _dart_bt_hid_device_connect _bt_hid_device_connect = + _bt_hid_device_connect_ptr.asFunction<_dart_bt_hid_device_connect>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HID_DEVICE_MODULE + /// @brief Disconnects from the HID Host device, asynchronously. + /// @since_tizen @if WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] remote_address The remote device's address. + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_hid_device_connection_state_changed_cb() + int bt_hid_device_disconnect( + ffi.Pointer remote_address, + ) { + return _bt_hid_device_disconnect( + remote_address, + ); + } + + late final _bt_hid_device_disconnect_ptr = + _lookup>( + 'bt_hid_device_disconnect'); + late final _dart_bt_hid_device_disconnect _bt_hid_device_disconnect = + _bt_hid_device_disconnect_ptr + .asFunction<_dart_bt_hid_device_disconnect>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HID_DEVICE_MODULE + /// @brief Sends the mouse event data to the remote device. + /// @since_tizen @if WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] remote_address The remote device's address. + /// @param[in] mouse_data The mouse data to be passed to the remote device. + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The HID connection must be established. + /// @see bt_hid_device_connection_state_changed_cb() + int bt_hid_device_send_mouse_event( + ffi.Pointer remote_address, + ffi.Pointer mouse_data, + ) { + return _bt_hid_device_send_mouse_event( + remote_address, + mouse_data, + ); + } + + late final _bt_hid_device_send_mouse_event_ptr = + _lookup>( + 'bt_hid_device_send_mouse_event'); + late final _dart_bt_hid_device_send_mouse_event + _bt_hid_device_send_mouse_event = _bt_hid_device_send_mouse_event_ptr + .asFunction<_dart_bt_hid_device_send_mouse_event>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HID_DEVICE_MODULE + /// @brief Sends the keyboard event data to the remote device. + /// @since_tizen @if WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] remote_address The remote device's address. + /// @param[in] key_data The key data to be passed to the remote device + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The HID connection must be established. + /// @see bt_hid_device_connection_state_changed_cb() + int bt_hid_device_send_key_event( + ffi.Pointer remote_address, + ffi.Pointer key_data, + ) { + return _bt_hid_device_send_key_event( + remote_address, + key_data, + ); + } + + late final _bt_hid_device_send_key_event_ptr = + _lookup>( + 'bt_hid_device_send_key_event'); + late final _dart_bt_hid_device_send_key_event _bt_hid_device_send_key_event = + _bt_hid_device_send_key_event_ptr + .asFunction<_dart_bt_hid_device_send_key_event>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HID_DEVICE_MODULE + /// @brief Sets the callback called when the device receives data from the HID Host. + /// @since_tizen @if WEARABLE 3.0 @endif + /// + /// @param[in] callback The callback function to be set when data is received. + /// @param[in] user_data The user data to be passed to the callback. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_hid_device_connection_state_changed_cb() + int bt_hid_device_set_data_received_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_hid_device_set_data_received_cb( + callback, + user_data, + ); + } + + late final _bt_hid_device_set_data_received_cb_ptr = + _lookup>( + 'bt_hid_device_set_data_received_cb'); + late final _dart_bt_hid_device_set_data_received_cb + _bt_hid_device_set_data_received_cb = + _bt_hid_device_set_data_received_cb_ptr + .asFunction<_dart_bt_hid_device_set_data_received_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HID_DEVICE_MODULE + /// @brief Unsets the data received callback. + /// @since_tizen @if WEARABLE 3.0 @endif + /// + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_hid_device_connection_state_changed_cb() + int bt_hid_device_unset_data_received_cb() { + return _bt_hid_device_unset_data_received_cb(); + } + + late final _bt_hid_device_unset_data_received_cb_ptr = + _lookup>( + 'bt_hid_device_unset_data_received_cb'); + late final _dart_bt_hid_device_unset_data_received_cb + _bt_hid_device_unset_data_received_cb = + _bt_hid_device_unset_data_received_cb_ptr + .asFunction<_dart_bt_hid_device_unset_data_received_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HID_DEVICE_MODULE + /// @brief Responds to reports from the HID Host. + /// @since_tizen @if WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] remote_address The remote device's address. + /// @param[in] header_type The response header type + /// @param[in] param_type The response parameter type + /// @param[in] data The response data + /// @param[in] data_len The length of the response data + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The HID connection must be established. + /// @see bt_hid_device_connection_state_changed_cb() + int bt_hid_device_reply_to_report( + ffi.Pointer remote_address, + int header_type, + int param_type, + ffi.Pointer data, + int data_len, + ) { + return _bt_hid_device_reply_to_report( + remote_address, + header_type, + param_type, + data, + data_len, + ); + } + + late final _bt_hid_device_reply_to_report_ptr = + _lookup>( + 'bt_hid_device_reply_to_report'); + late final _dart_bt_hid_device_reply_to_report + _bt_hid_device_reply_to_report = _bt_hid_device_reply_to_report_ptr + .asFunction<_dart_bt_hid_device_reply_to_report>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_MODULE + /// @brief Initializes the Bluetooth profiles related with audio. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @remarks This function must be called before Bluetooth profiles related with audio starts. \n + /// You must free all resources of the this service by calling bt_audio_deinitialize() + /// if Bluetooth profiles related with audio service is no longer needed. + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_audio_deinitialize() + int bt_audio_initialize() { + return _bt_audio_initialize(); + } + + late final _bt_audio_initialize_ptr = + _lookup>( + 'bt_audio_initialize'); + late final _dart_bt_audio_initialize _bt_audio_initialize = + _bt_audio_initialize_ptr.asFunction<_dart_bt_audio_initialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_MODULE + /// @brief Deinitializes the Bluetooth profiles related with audio. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth audio service must be initialized with bt_audio_initialize(). + /// @see bt_audio_initialize() + int bt_audio_deinitialize() { + return _bt_audio_deinitialize(); + } + + late final _bt_audio_deinitialize_ptr = + _lookup>( + 'bt_audio_deinitialize'); + late final _dart_bt_audio_deinitialize _bt_audio_deinitialize = + _bt_audio_deinitialize_ptr.asFunction<_dart_bt_audio_deinitialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_MODULE + /// @brief Connects the remote device with the given audio profile, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @details If you input type as #BT_AUDIO_PROFILE_TYPE_ALL and connection request succeeds, then bt_audio_connection_state_changed_cb() will be called twice + /// when #BT_AUDIO_PROFILE_TYPE_HSP_HFP is connected and #BT_AUDIO_PROFILE_TYPE_A2DP is connected. + /// @param[in] remote_address The remote address + /// @param[in] type The type of audio profile + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth audio service must be initialized with bt_audio_initialize(). + /// @pre The local device must be bonded with the remote device by bt_device_create_bond(). + /// @post bt_audio_connection_state_changed_cb() will be invoked. + /// @see bt_audio_disconnect() + /// @see bt_audio_connection_state_changed_cb() + int bt_audio_connect( + ffi.Pointer remote_address, + int type, + ) { + return _bt_audio_connect( + remote_address, + type, + ); + } + + late final _bt_audio_connect_ptr = + _lookup>('bt_audio_connect'); + late final _dart_bt_audio_connect _bt_audio_connect = + _bt_audio_connect_ptr.asFunction<_dart_bt_audio_connect>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_MODULE + /// @brief Disconnects the remote device with the given audio profile, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @details If you input type as #BT_AUDIO_PROFILE_TYPE_ALL and disconnection request succeeds, then bt_audio_connection_state_changed_cb() will be called twice + /// when #BT_AUDIO_PROFILE_TYPE_HSP_HFP is disconnected and #BT_AUDIO_PROFILE_TYPE_A2DP is disconnected. + /// @param[in] remote_address The remote address + /// @param[in] type The type of audio profile + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected by bt_audio_connect(). + /// @post bt_audio_connection_state_changed_cb() will be invoked. + /// @see bt_audio_connect() + /// @see bt_audio_connection_state_changed_cb() + int bt_audio_disconnect( + ffi.Pointer remote_address, + int type, + ) { + return _bt_audio_disconnect( + remote_address, + type, + ); + } + + late final _bt_audio_disconnect_ptr = + _lookup>( + 'bt_audio_disconnect'); + late final _dart_bt_audio_disconnect _bt_audio_disconnect = + _bt_audio_disconnect_ptr.asFunction<_dart_bt_audio_disconnect>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_MODULE + /// @brief Registers a callback function that will be invoked when the connection state is changed. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth audio service must be initialized with bt_audio_initialize(). + /// @see bt_audio_initialize() + /// @see bt_audio_connection_state_changed_cb() + int bt_audio_set_connection_state_changed_cb( + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_audio_set_connection_state_changed_cb( + callback, + user_data, + ); + } + + late final _bt_audio_set_connection_state_changed_cb_ptr = + _lookup>( + 'bt_audio_set_connection_state_changed_cb'); + late final _dart_bt_audio_set_connection_state_changed_cb + _bt_audio_set_connection_state_changed_cb = + _bt_audio_set_connection_state_changed_cb_ptr + .asFunction<_dart_bt_audio_set_connection_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AUDIO_MODULE + /// @brief Unregisters a callback function that will be invoked when the connection state is changed. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth audio service must be initialized with bt_audio_initialize(). + /// @see bt_audio_initialize() + /// @see bt_audio_connection_state_changed_cb() + /// @see bt_audio_set_connection_state_changed_cb() + int bt_audio_unset_connection_state_changed_cb() { + return _bt_audio_unset_connection_state_changed_cb(); + } + + late final _bt_audio_unset_connection_state_changed_cb_ptr = _lookup< + ffi.NativeFunction<_c_bt_audio_unset_connection_state_changed_cb>>( + 'bt_audio_unset_connection_state_changed_cb'); + late final _dart_bt_audio_unset_connection_state_changed_cb + _bt_audio_unset_connection_state_changed_cb = + _bt_audio_unset_connection_state_changed_cb_ptr + .asFunction<_dart_bt_audio_unset_connection_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_TARGET_MODULE + /// @brief Initializes the Bluetooth AVRCP (Audio/Video Remote Control Profile) target service. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @remarks This function must be called before any other AVRCP target functions are called. \n + /// You must free all resources of the this service by calling bt_avrcp_target_deinitialize() + /// if Bluetooth AVRCP service is no longer needed. + /// @param[in] callback The callback function called when the connection state is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_avrcp_target_deinitialize() + int bt_avrcp_target_initialize( + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_avrcp_target_initialize( + callback, + user_data, + ); + } + + late final _bt_avrcp_target_initialize_ptr = + _lookup>( + 'bt_avrcp_target_initialize'); + late final _dart_bt_avrcp_target_initialize _bt_avrcp_target_initialize = + _bt_avrcp_target_initialize_ptr + .asFunction<_dart_bt_avrcp_target_initialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_TARGET_MODULE + /// @brief Deinitializes the Bluetooth AVRCP (Audio/Video Remote Control Profile) target service. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth audio service must be initialized with bt_avrcp_target_initialize(). + /// @see bt_avrcp_target_initialize() + int bt_avrcp_target_deinitialize() { + return _bt_avrcp_target_deinitialize(); + } + + late final _bt_avrcp_target_deinitialize_ptr = + _lookup>( + 'bt_avrcp_target_deinitialize'); + late final _dart_bt_avrcp_target_deinitialize _bt_avrcp_target_deinitialize = + _bt_avrcp_target_deinitialize_ptr + .asFunction<_dart_bt_avrcp_target_deinitialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_TARGET_MODULE + /// @brief Notifies the equalizer state to the remote device. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] state The state of equalizer + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_target_notify_equalizer_state( + int state, + ) { + return _bt_avrcp_target_notify_equalizer_state( + state, + ); + } + + late final _bt_avrcp_target_notify_equalizer_state_ptr = + _lookup>( + 'bt_avrcp_target_notify_equalizer_state'); + late final _dart_bt_avrcp_target_notify_equalizer_state + _bt_avrcp_target_notify_equalizer_state = + _bt_avrcp_target_notify_equalizer_state_ptr + .asFunction<_dart_bt_avrcp_target_notify_equalizer_state>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_TARGET_MODULE + /// @brief Notifies the repeat mode to the remote device. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] mode The repeat mode + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_target_notify_repeat_mode( + int mode, + ) { + return _bt_avrcp_target_notify_repeat_mode( + mode, + ); + } + + late final _bt_avrcp_target_notify_repeat_mode_ptr = + _lookup>( + 'bt_avrcp_target_notify_repeat_mode'); + late final _dart_bt_avrcp_target_notify_repeat_mode + _bt_avrcp_target_notify_repeat_mode = + _bt_avrcp_target_notify_repeat_mode_ptr + .asFunction<_dart_bt_avrcp_target_notify_repeat_mode>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_TARGET_MODULE + /// @brief Notifies the shuffle mode to the remote device. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] mode The repeat mode + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_target_notify_shuffle_mode( + int mode, + ) { + return _bt_avrcp_target_notify_shuffle_mode( + mode, + ); + } + + late final _bt_avrcp_target_notify_shuffle_mode_ptr = + _lookup>( + 'bt_avrcp_target_notify_shuffle_mode'); + late final _dart_bt_avrcp_target_notify_shuffle_mode + _bt_avrcp_target_notify_shuffle_mode = + _bt_avrcp_target_notify_shuffle_mode_ptr + .asFunction<_dart_bt_avrcp_target_notify_shuffle_mode>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_TARGET_MODULE + /// @brief Notifies the scan mode to the remote device. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] mode The scan mode + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_target_notify_scan_mode( + int mode, + ) { + return _bt_avrcp_target_notify_scan_mode( + mode, + ); + } + + late final _bt_avrcp_target_notify_scan_mode_ptr = + _lookup>( + 'bt_avrcp_target_notify_scan_mode'); + late final _dart_bt_avrcp_target_notify_scan_mode + _bt_avrcp_target_notify_scan_mode = _bt_avrcp_target_notify_scan_mode_ptr + .asFunction<_dart_bt_avrcp_target_notify_scan_mode>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_TARGET_MODULE + /// @brief Notifies the player state to the remote device. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] state The player state + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_target_notify_player_state( + int state, + ) { + return _bt_avrcp_target_notify_player_state( + state, + ); + } + + late final _bt_avrcp_target_notify_player_state_ptr = + _lookup>( + 'bt_avrcp_target_notify_player_state'); + late final _dart_bt_avrcp_target_notify_player_state + _bt_avrcp_target_notify_player_state = + _bt_avrcp_target_notify_player_state_ptr + .asFunction<_dart_bt_avrcp_target_notify_player_state>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_TARGET_MODULE + /// @brief Notifies the current position of song to the remote device. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] position The current position in milliseconds + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_target_notify_position( + int position, + ) { + return _bt_avrcp_target_notify_position( + position, + ); + } + + late final _bt_avrcp_target_notify_position_ptr = + _lookup>( + 'bt_avrcp_target_notify_position'); + late final _dart_bt_avrcp_target_notify_position + _bt_avrcp_target_notify_position = _bt_avrcp_target_notify_position_ptr + .asFunction<_dart_bt_avrcp_target_notify_position>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_TARGET_MODULE + /// @brief Notifies the track to the remote device. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] title The title of track + /// @param[in] artist The artist of track + /// @param[in] album The album of track + /// @param[in] genre The genre of track + /// @param[in] track_num The track number + /// @param[in] total_tracks The number of all tracks + /// @param[in] duration The duration of track in milliseconds + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_target_notify_track( + ffi.Pointer title, + ffi.Pointer artist, + ffi.Pointer album, + ffi.Pointer genre, + int track_num, + int total_tracks, + int duration, + ) { + return _bt_avrcp_target_notify_track( + title, + artist, + album, + genre, + track_num, + total_tracks, + duration, + ); + } + + late final _bt_avrcp_target_notify_track_ptr = + _lookup>( + 'bt_avrcp_target_notify_track'); + late final _dart_bt_avrcp_target_notify_track _bt_avrcp_target_notify_track = + _bt_avrcp_target_notify_track_ptr + .asFunction<_dart_bt_avrcp_target_notify_track>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE + /// @brief Registers a callback function that will be invoked when the equalizer state is changed. (e.g., by a TV remote control or other input devices) + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize(). + /// @see bt_avrcp_target_initialize() + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_unset_equalizer_state_changed_cb() + int bt_avrcp_set_equalizer_state_changed_cb( + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_avrcp_set_equalizer_state_changed_cb( + callback, + user_data, + ); + } + + late final _bt_avrcp_set_equalizer_state_changed_cb_ptr = + _lookup>( + 'bt_avrcp_set_equalizer_state_changed_cb'); + late final _dart_bt_avrcp_set_equalizer_state_changed_cb + _bt_avrcp_set_equalizer_state_changed_cb = + _bt_avrcp_set_equalizer_state_changed_cb_ptr + .asFunction<_dart_bt_avrcp_set_equalizer_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE + /// @brief Unregisters a callback function that will be invoked when the equalizer state is changed. (e.g., by a TV remote control or other input devices) + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize(). + /// @see bt_avrcp_target_initialize() + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_set_equalizer_state_changed_cb() + int bt_avrcp_unset_equalizer_state_changed_cb() { + return _bt_avrcp_unset_equalizer_state_changed_cb(); + } + + late final _bt_avrcp_unset_equalizer_state_changed_cb_ptr = + _lookup>( + 'bt_avrcp_unset_equalizer_state_changed_cb'); + late final _dart_bt_avrcp_unset_equalizer_state_changed_cb + _bt_avrcp_unset_equalizer_state_changed_cb = + _bt_avrcp_unset_equalizer_state_changed_cb_ptr + .asFunction<_dart_bt_avrcp_unset_equalizer_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE + /// @brief Registers a callback function that will be invoked when the repeat mode is changed. (e.g., by a TV remote control or other input devices) + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize(). + /// @see bt_avrcp_target_initialize() + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_unset_repeat_mode_changed_cb() + int bt_avrcp_set_repeat_mode_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_avrcp_set_repeat_mode_changed_cb( + callback, + user_data, + ); + } + + late final _bt_avrcp_set_repeat_mode_changed_cb_ptr = + _lookup>( + 'bt_avrcp_set_repeat_mode_changed_cb'); + late final _dart_bt_avrcp_set_repeat_mode_changed_cb + _bt_avrcp_set_repeat_mode_changed_cb = + _bt_avrcp_set_repeat_mode_changed_cb_ptr + .asFunction<_dart_bt_avrcp_set_repeat_mode_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE + /// @brief Unregisters a callback function that will be invoked when the repeat mode is changed. (e.g., by a TV remote control or other input devices) + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize(). + /// @see bt_avrcp_target_initialize() + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_set_repeat_mode_changed_cb() + int bt_avrcp_unset_repeat_mode_changed_cb() { + return _bt_avrcp_unset_repeat_mode_changed_cb(); + } + + late final _bt_avrcp_unset_repeat_mode_changed_cb_ptr = + _lookup>( + 'bt_avrcp_unset_repeat_mode_changed_cb'); + late final _dart_bt_avrcp_unset_repeat_mode_changed_cb + _bt_avrcp_unset_repeat_mode_changed_cb = + _bt_avrcp_unset_repeat_mode_changed_cb_ptr + .asFunction<_dart_bt_avrcp_unset_repeat_mode_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE + /// @brief Registers a callback function that will be invoked when the shuffle mode is changed. (e.g., by a TV remote control or other input devices) + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize(). + /// @see bt_avrcp_target_initialize() + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_unset_shuffle_mode_changed_cb() + int bt_avrcp_set_shuffle_mode_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_avrcp_set_shuffle_mode_changed_cb( + callback, + user_data, + ); + } + + late final _bt_avrcp_set_shuffle_mode_changed_cb_ptr = + _lookup>( + 'bt_avrcp_set_shuffle_mode_changed_cb'); + late final _dart_bt_avrcp_set_shuffle_mode_changed_cb + _bt_avrcp_set_shuffle_mode_changed_cb = + _bt_avrcp_set_shuffle_mode_changed_cb_ptr + .asFunction<_dart_bt_avrcp_set_shuffle_mode_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE + /// @brief Unregisters a callback function that will be invoked when the shuffle mode is changed. (e.g., by a TV remote control or other input devices) + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize(). + /// @see bt_avrcp_target_initialize() + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_set_shuffle_mode_changed_cb() + int bt_avrcp_unset_shuffle_mode_changed_cb() { + return _bt_avrcp_unset_shuffle_mode_changed_cb(); + } + + late final _bt_avrcp_unset_shuffle_mode_changed_cb_ptr = + _lookup>( + 'bt_avrcp_unset_shuffle_mode_changed_cb'); + late final _dart_bt_avrcp_unset_shuffle_mode_changed_cb + _bt_avrcp_unset_shuffle_mode_changed_cb = + _bt_avrcp_unset_shuffle_mode_changed_cb_ptr + .asFunction<_dart_bt_avrcp_unset_shuffle_mode_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE + /// @brief Registers a callback function that will be invoked when the scan mode is changed. (e.g., by a TV remote control or other input devices) + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize(). + /// @see bt_avrcp_target_initialize() + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_unset_scan_mode_changed_cb() + int bt_avrcp_set_scan_mode_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_avrcp_set_scan_mode_changed_cb( + callback, + user_data, + ); + } + + late final _bt_avrcp_set_scan_mode_changed_cb_ptr = + _lookup>( + 'bt_avrcp_set_scan_mode_changed_cb'); + late final _dart_bt_avrcp_set_scan_mode_changed_cb + _bt_avrcp_set_scan_mode_changed_cb = + _bt_avrcp_set_scan_mode_changed_cb_ptr + .asFunction<_dart_bt_avrcp_set_scan_mode_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE + /// @brief Unregisters a callback function that will be invoked when the scan mode is changed. (e.g., by a TV remote control or other input devices) + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize(). + /// @see bt_avrcp_target_initialize() + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_set_scan_mode_changed_cb() + int bt_avrcp_unset_scan_mode_changed_cb() { + return _bt_avrcp_unset_scan_mode_changed_cb(); + } + + late final _bt_avrcp_unset_scan_mode_changed_cb_ptr = + _lookup>( + 'bt_avrcp_unset_scan_mode_changed_cb'); + late final _dart_bt_avrcp_unset_scan_mode_changed_cb + _bt_avrcp_unset_scan_mode_changed_cb = + _bt_avrcp_unset_scan_mode_changed_cb_ptr + .asFunction<_dart_bt_avrcp_unset_scan_mode_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE + /// @brief Registers a callback function that will be invoked when the song position is changed. (e.g., by a TV remote control or other input devices) + /// @since_tizen 3.0 + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize(). + /// @see bt_avrcp_target_initialize() + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_set_position_changed_cb() + int bt_avrcp_set_position_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_avrcp_set_position_changed_cb( + callback, + user_data, + ); + } + + late final _bt_avrcp_set_position_changed_cb_ptr = + _lookup>( + 'bt_avrcp_set_position_changed_cb'); + late final _dart_bt_avrcp_set_position_changed_cb + _bt_avrcp_set_position_changed_cb = _bt_avrcp_set_position_changed_cb_ptr + .asFunction<_dart_bt_avrcp_set_position_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE + /// @brief Unregisters a callback function that will be invoked when the song position is changed. (e.g., by a TV remote control or other input devices) + /// @since_tizen 3.0 + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize(). + /// @see bt_avrcp_target_initialize() + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_set_position_changed_cb() + int bt_avrcp_unset_position_changed_cb() { + return _bt_avrcp_unset_position_changed_cb(); + } + + late final _bt_avrcp_unset_position_changed_cb_ptr = + _lookup>( + 'bt_avrcp_unset_position_changed_cb'); + late final _dart_bt_avrcp_unset_position_changed_cb + _bt_avrcp_unset_position_changed_cb = + _bt_avrcp_unset_position_changed_cb_ptr + .asFunction<_dart_bt_avrcp_unset_position_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE + /// @brief Registers a callback function that will be invoked when the Play status is changed. (e.g., by a TV remote control or other input devices) + /// @since_tizen 3.0 + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize(). + /// @see bt_avrcp_target_initialize() + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_unset_play_status_changed_cb() + int bt_avrcp_set_play_status_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_avrcp_set_play_status_changed_cb( + callback, + user_data, + ); + } + + late final _bt_avrcp_set_play_status_changed_cb_ptr = + _lookup>( + 'bt_avrcp_set_play_status_changed_cb'); + late final _dart_bt_avrcp_set_play_status_changed_cb + _bt_avrcp_set_play_status_changed_cb = + _bt_avrcp_set_play_status_changed_cb_ptr + .asFunction<_dart_bt_avrcp_set_play_status_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE + /// @brief Unregisters a callback function that will be invoked when the Play status is changed. (e.g., by a TV remote control or other input devices) + /// @since_tizen 3.0 + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize(). + /// @see bt_avrcp_target_initialize() + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_unset_play_status_changed_cb() + int bt_avrcp_unset_play_status_changed_cb() { + return _bt_avrcp_unset_play_status_changed_cb(); + } + + late final _bt_avrcp_unset_play_status_changed_cb_ptr = + _lookup>( + 'bt_avrcp_unset_play_status_changed_cb'); + late final _dart_bt_avrcp_unset_play_status_changed_cb + _bt_avrcp_unset_play_status_changed_cb = + _bt_avrcp_unset_play_status_changed_cb_ptr + .asFunction<_dart_bt_avrcp_unset_play_status_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE + /// @brief Registers a callback function that will be invoked when the track metadata is changed. (e.g., by a TV remote control or other input devices) + /// @since_tizen 3.0 + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize(). + /// @see bt_avrcp_target_initialize() + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_unset_track_info_changed_cb() + int bt_avrcp_set_track_info_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_avrcp_set_track_info_changed_cb( + callback, + user_data, + ); + } + + late final _bt_avrcp_set_track_info_changed_cb_ptr = + _lookup>( + 'bt_avrcp_set_track_info_changed_cb'); + late final _dart_bt_avrcp_set_track_info_changed_cb + _bt_avrcp_set_track_info_changed_cb = + _bt_avrcp_set_track_info_changed_cb_ptr + .asFunction<_dart_bt_avrcp_set_track_info_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_MODULE + /// @brief Unregisters a callback function that will be invoked when the track metadata is changed. (e.g., by a TV remote control or other input devices) + /// @since_tizen 3.0 + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The AVRCP service must be initialized with bt_avrcp_target_initialize() or bt_avrcp_control_initialize(). + /// @see bt_avrcp_target_initialize() + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_set_track_info_changed_cb() + int bt_avrcp_unset_track_info_changed_cb() { + return _bt_avrcp_unset_track_info_changed_cb(); + } + + late final _bt_avrcp_unset_track_info_changed_cb_ptr = + _lookup>( + 'bt_avrcp_unset_track_info_changed_cb'); + late final _dart_bt_avrcp_unset_track_info_changed_cb + _bt_avrcp_unset_track_info_changed_cb = + _bt_avrcp_unset_track_info_changed_cb_ptr + .asFunction<_dart_bt_avrcp_unset_track_info_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Initializes the Bluetooth AVRCP (Audio/Video Remote Control Profile) controller service. + /// @since_tizen 3.0 + /// @remarks This function must be called before any other AVRCP controller functions are called. \n + /// You must free all resources of the this service by calling bt_avrcp_control_deinitialize() + /// if Bluetooth AVRCP service is no longer needed. + /// @param[in] callback The callback function called when the connection state is changed + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_avrcp_control_deinitialize() + int bt_avrcp_control_initialize( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, + ) { + return _bt_avrcp_control_initialize( + callback, + user_data, + ); + } + + late final _bt_avrcp_control_initialize_ptr = + _lookup>( + 'bt_avrcp_control_initialize'); + late final _dart_bt_avrcp_control_initialize _bt_avrcp_control_initialize = + _bt_avrcp_control_initialize_ptr + .asFunction<_dart_bt_avrcp_control_initialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Deinitializes the Bluetooth AVRCP (Audio/Video Remote Control Profile) controller service. + /// @since_tizen 3.0 + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// @pre The Bluetooth audio service must be initialized with bt_avrcp_control_initialize(). + /// @see bt_avrcp_control_initialize() + int bt_avrcp_control_deinitialize() { + return _bt_avrcp_control_deinitialize(); + } + + late final _bt_avrcp_control_deinitialize_ptr = + _lookup>( + 'bt_avrcp_control_deinitialize'); + late final _dart_bt_avrcp_control_deinitialize + _bt_avrcp_control_deinitialize = _bt_avrcp_control_deinitialize_ptr + .asFunction<_dart_bt_avrcp_control_deinitialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Connects the AVRCP (Audio/Video Remote Control Profile) target device. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] remote_address The remote address + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// @pre The Bluetooth audio service must be initialized with bt_avrcp_control_initialize(). + /// @see bt_avrcp_control_initialize() + int bt_avrcp_control_connect( + ffi.Pointer remote_address, + ) { + return _bt_avrcp_control_connect( + remote_address, + ); + } + + late final _bt_avrcp_control_connect_ptr = + _lookup>( + 'bt_avrcp_control_connect'); + late final _dart_bt_avrcp_control_connect _bt_avrcp_control_connect = + _bt_avrcp_control_connect_ptr + .asFunction<_dart_bt_avrcp_control_connect>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Disconnects from the AVRCP (Audio/Video Remote Control Profile) target device. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] remote_address The remote address + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// @pre The Bluetooth audio service must be initialized with bt_avrcp_control_initialize(). + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_control_connect() + int bt_avrcp_control_disconnect( + ffi.Pointer remote_address, + ) { + return _bt_avrcp_control_disconnect( + remote_address, + ); + } + + late final _bt_avrcp_control_disconnect_ptr = + _lookup>( + 'bt_avrcp_control_disconnect'); + late final _dart_bt_avrcp_control_disconnect _bt_avrcp_control_disconnect = + _bt_avrcp_control_disconnect_ptr + .asFunction<_dart_bt_avrcp_control_disconnect>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Sends a command to the target device. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] cmd The commands, one of: Play, Pause, Next, Rewind. + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// @pre The Bluetooth audio service must be initialized with bt_avrcp_control_initialize(). + /// @see bt_avrcp_control_initialize() + /// @see bt_avrcp_control_connect() + int bt_avrcp_control_send_player_command( + int cmd, + ) { + return _bt_avrcp_control_send_player_command( + cmd, + ); + } + + late final _bt_avrcp_control_send_player_command_ptr = + _lookup>( + 'bt_avrcp_control_send_player_command'); + late final _dart_bt_avrcp_control_send_player_command + _bt_avrcp_control_send_player_command = + _bt_avrcp_control_send_player_command_ptr + .asFunction<_dart_bt_avrcp_control_send_player_command>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Sends the equalizer state change request to the remote device. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] state The new equalizer state, one of: ON, OFF + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_control_set_equalizer_state( + int state, + ) { + return _bt_avrcp_control_set_equalizer_state( + state, + ); + } + + late final _bt_avrcp_control_set_equalizer_state_ptr = + _lookup>( + 'bt_avrcp_control_set_equalizer_state'); + late final _dart_bt_avrcp_control_set_equalizer_state + _bt_avrcp_control_set_equalizer_state = + _bt_avrcp_control_set_equalizer_state_ptr + .asFunction<_dart_bt_avrcp_control_set_equalizer_state>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Gets the the equalizer state of the remote device. + /// @since_tizen 3.0 + /// @param[out] state The equalizer state, one of: ON, OFF + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_control_get_equalizer_state( + ffi.Pointer state, + ) { + return _bt_avrcp_control_get_equalizer_state( + state, + ); + } + + late final _bt_avrcp_control_get_equalizer_state_ptr = + _lookup>( + 'bt_avrcp_control_get_equalizer_state'); + late final _dart_bt_avrcp_control_get_equalizer_state + _bt_avrcp_control_get_equalizer_state = + _bt_avrcp_control_get_equalizer_state_ptr + .asFunction<_dart_bt_avrcp_control_get_equalizer_state>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Sends the repeat change request to the remote device. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] mode The new repeat mode, one of: OFF, SINGLE, ALL + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_control_set_repeat_mode( + int mode, + ) { + return _bt_avrcp_control_set_repeat_mode( + mode, + ); + } + + late final _bt_avrcp_control_set_repeat_mode_ptr = + _lookup>( + 'bt_avrcp_control_set_repeat_mode'); + late final _dart_bt_avrcp_control_set_repeat_mode + _bt_avrcp_control_set_repeat_mode = _bt_avrcp_control_set_repeat_mode_ptr + .asFunction<_dart_bt_avrcp_control_set_repeat_mode>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Gets the repeat state of the remote device. + /// @since_tizen 3.0 + /// @param[out] mode The repeat mode, one of: OFF, SINGLE, ALL + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_control_get_repeat_mode( + ffi.Pointer mode, + ) { + return _bt_avrcp_control_get_repeat_mode( + mode, + ); + } + + late final _bt_avrcp_control_get_repeat_mode_ptr = + _lookup>( + 'bt_avrcp_control_get_repeat_mode'); + late final _dart_bt_avrcp_control_get_repeat_mode + _bt_avrcp_control_get_repeat_mode = _bt_avrcp_control_get_repeat_mode_ptr + .asFunction<_dart_bt_avrcp_control_get_repeat_mode>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Sends the shuffle mode change request to the remote device. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] mode The new shuffle mode, one of: OFF, GROUP, ALL + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_control_set_shuffle_mode( + int mode, + ) { + return _bt_avrcp_control_set_shuffle_mode( + mode, + ); + } + + late final _bt_avrcp_control_set_shuffle_mode_ptr = + _lookup>( + 'bt_avrcp_control_set_shuffle_mode'); + late final _dart_bt_avrcp_control_set_shuffle_mode + _bt_avrcp_control_set_shuffle_mode = + _bt_avrcp_control_set_shuffle_mode_ptr + .asFunction<_dart_bt_avrcp_control_set_shuffle_mode>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Gets the shuffle mode of the remote device. + /// @since_tizen 3.0 + /// @param[out] mode The shuffle mode, one of: OFF, GROUP, ALL + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_control_get_shuffle_mode( + ffi.Pointer mode, + ) { + return _bt_avrcp_control_get_shuffle_mode( + mode, + ); + } + + late final _bt_avrcp_control_get_shuffle_mode_ptr = + _lookup>( + 'bt_avrcp_control_get_shuffle_mode'); + late final _dart_bt_avrcp_control_get_shuffle_mode + _bt_avrcp_control_get_shuffle_mode = + _bt_avrcp_control_get_shuffle_mode_ptr + .asFunction<_dart_bt_avrcp_control_get_shuffle_mode>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Sends the scan mode change request to the remote device. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] mode The new scan mode, one of: OFF, GROUP, ALL + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_control_set_scan_mode( + int mode, + ) { + return _bt_avrcp_control_set_scan_mode( + mode, + ); + } + + late final _bt_avrcp_control_set_scan_mode_ptr = + _lookup>( + 'bt_avrcp_control_set_scan_mode'); + late final _dart_bt_avrcp_control_set_scan_mode + _bt_avrcp_control_set_scan_mode = _bt_avrcp_control_set_scan_mode_ptr + .asFunction<_dart_bt_avrcp_control_set_scan_mode>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Gets the scan mode of the remote device. + /// @since_tizen 3.0 + /// @param[out] mode The scan mode, one of: OFF, GROUP, ALL + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_control_get_scan_mode( + ffi.Pointer mode, + ) { + return _bt_avrcp_control_get_scan_mode( + mode, + ); + } + + late final _bt_avrcp_control_get_scan_mode_ptr = + _lookup>( + 'bt_avrcp_control_get_scan_mode'); + late final _dart_bt_avrcp_control_get_scan_mode + _bt_avrcp_control_get_scan_mode = _bt_avrcp_control_get_scan_mode_ptr + .asFunction<_dart_bt_avrcp_control_get_scan_mode>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Gets the position of the song played by the remote device. + /// @since_tizen 3.0 + /// @param[out] position The position, in milliseconds + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_control_get_position( + ffi.Pointer position, + ) { + return _bt_avrcp_control_get_position( + position, + ); + } + + late final _bt_avrcp_control_get_position_ptr = + _lookup>( + 'bt_avrcp_control_get_position'); + late final _dart_bt_avrcp_control_get_position + _bt_avrcp_control_get_position = _bt_avrcp_control_get_position_ptr + .asFunction<_dart_bt_avrcp_control_get_position>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Gets the play status of the remote device. + /// @since_tizen 3.0 + /// @param[out] status The play status, one of: PLAYING, STOPPED... + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_control_get_play_status( + ffi.Pointer status, + ) { + return _bt_avrcp_control_get_play_status( + status, + ); + } + + late final _bt_avrcp_control_get_play_status_ptr = + _lookup>( + 'bt_avrcp_control_get_play_status'); + late final _dart_bt_avrcp_control_get_play_status + _bt_avrcp_control_get_play_status = _bt_avrcp_control_get_play_status_ptr + .asFunction<_dart_bt_avrcp_control_get_play_status>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Gets the metadata of the track played by the remote device. + /// @since_tizen 3.0 + /// @remarks The @a track must be released using bt_avrcp_control_free_track_info() + /// @param[out] track The track metadata. + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_avrcp_target_connection_state_changed_cb() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_control_get_track_info( + ffi.Pointer> track, + ) { + return _bt_avrcp_control_get_track_info( + track, + ); + } + + late final _bt_avrcp_control_get_track_info_ptr = + _lookup>( + 'bt_avrcp_control_get_track_info'); + late final _dart_bt_avrcp_control_get_track_info + _bt_avrcp_control_get_track_info = _bt_avrcp_control_get_track_info_ptr + .asFunction<_dart_bt_avrcp_control_get_track_info>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_AVRCP_CONTROL_MODULE + /// @brief Frees the track metadata. + /// @since_tizen 3.0 + /// @param[in] track The track metadata. + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// @pre track should point to valid metadata address. + /// @see bt_avrcp_control_get_track_info() + /// @see bt_avrcp_target_initialize() + int bt_avrcp_control_free_track_info( + ffi.Pointer track, + ) { + return _bt_avrcp_control_free_track_info( + track, + ); + } + + late final _bt_avrcp_control_free_track_info_ptr = + _lookup>( + 'bt_avrcp_control_free_track_info'); + late final _dart_bt_avrcp_control_free_track_info + _bt_avrcp_control_free_track_info = _bt_avrcp_control_free_track_info_ptr + .asFunction<_dart_bt_avrcp_control_free_track_info>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HDP_MODULE + /// @brief Registers an application that acts as the @a Sink role of HDP(Health Device Profile). + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @remarks The @a app_id must be released with free() by you. + /// @param[in] data_type The data type of MDEP. This value is defined in ISO/IEEE 11073-20601 spec. + /// For example, pulse oximeter is 0x1004 and blood pressure monitor is 0x1007. + /// @param[out] app_id The ID of application + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @see bt_hdp_unregister_sink_app() + int bt_hdp_register_sink_app( + int data_type, + ffi.Pointer> app_id, + ) { + return _bt_hdp_register_sink_app( + data_type, + app_id, + ); + } + + late final _bt_hdp_register_sink_app_ptr = + _lookup>( + 'bt_hdp_register_sink_app'); + late final _dart_bt_hdp_register_sink_app _bt_hdp_register_sink_app = + _bt_hdp_register_sink_app_ptr + .asFunction<_dart_bt_hdp_register_sink_app>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HDP_MODULE + /// @brief Unregisters the given application that acts as the @a Sink role of HDP(Health Device Profile). + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] app_id The ID of application + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_hdp_register_sink_app() + int bt_hdp_unregister_sink_app( + ffi.Pointer app_id, + ) { + return _bt_hdp_unregister_sink_app( + app_id, + ); + } + + late final _bt_hdp_unregister_sink_app_ptr = + _lookup>( + 'bt_hdp_unregister_sink_app'); + late final _dart_bt_hdp_unregister_sink_app _bt_hdp_unregister_sink_app = + _bt_hdp_unregister_sink_app_ptr + .asFunction<_dart_bt_hdp_unregister_sink_app>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HDP_MODULE + /// @brief Connects the remote device which acts as @a Source role, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] remote_address The remote address + /// @param[in] app_id The ID of application + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Sink role of HDP must be registered with bt_hdp_register_sink_app(). + /// @pre The local device must be bonded with the remote device by bt_device_create_bond(). + /// @post bt_hdp_connected_cb() will be invoked. + /// @see bt_hdp_disconnect() + /// @see bt_hdp_set_connection_state_changed_cb() + /// @see bt_hdp_unset_connection_state_changed_cb() + int bt_hdp_connect_to_source( + ffi.Pointer remote_address, + ffi.Pointer app_id, + ) { + return _bt_hdp_connect_to_source( + remote_address, + app_id, + ); + } + + late final _bt_hdp_connect_to_source_ptr = + _lookup>( + 'bt_hdp_connect_to_source'); + late final _dart_bt_hdp_connect_to_source _bt_hdp_connect_to_source = + _bt_hdp_connect_to_source_ptr + .asFunction<_dart_bt_hdp_connect_to_source>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HDP_MODULE + /// @brief Disconnects the remote device, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] remote_address The remote address + /// @param[in] channel The connected data channel + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED Remote device is not connected + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @post bt_hdp_disconnected_cb() will be invoked. + /// @see bt_hdp_set_connection_state_changed_cb() + /// @see bt_hdp_unset_connection_state_changed_cb() + int bt_hdp_disconnect( + ffi.Pointer remote_address, + int channel, + ) { + return _bt_hdp_disconnect( + remote_address, + channel, + ); + } + + late final _bt_hdp_disconnect_ptr = + _lookup>('bt_hdp_disconnect'); + late final _dart_bt_hdp_disconnect _bt_hdp_disconnect = + _bt_hdp_disconnect_ptr.asFunction<_dart_bt_hdp_disconnect>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HDP_MODULE + /// @brief Sends the data to the remote device. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] channel The connected data channel + /// @param[in] data The data to send + /// @param[in] size The size of data to send (byte) + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The remote device must be connected. + /// @see bt_hdp_data_received_cb() + /// @see bt_hdp_set_data_received_cb() + /// @see bt_hdp_unset_data_received_cb() + int bt_hdp_send_data( + int channel, + ffi.Pointer data, + int size, + ) { + return _bt_hdp_send_data( + channel, + data, + size, + ); + } + + late final _bt_hdp_send_data_ptr = + _lookup>('bt_hdp_send_data'); + late final _dart_bt_hdp_send_data _bt_hdp_send_data = + _bt_hdp_send_data_ptr.asFunction<_dart_bt_hdp_send_data>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HDP_MODULE + /// @brief Registers a callback function that will be invoked when the connection state is changed. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] connected_cb The callback function called when a connection is established + /// @param[in] disconnected_cb The callback function called when a connection is disconnected + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_hdp_unset_connection_state_changed_cb() + int bt_hdp_set_connection_state_changed_cb( + ffi.Pointer> connected_cb, + ffi.Pointer> disconnected_cb, + ffi.Pointer user_data, + ) { + return _bt_hdp_set_connection_state_changed_cb( + connected_cb, + disconnected_cb, + user_data, + ); + } + + late final _bt_hdp_set_connection_state_changed_cb_ptr = + _lookup>( + 'bt_hdp_set_connection_state_changed_cb'); + late final _dart_bt_hdp_set_connection_state_changed_cb + _bt_hdp_set_connection_state_changed_cb = + _bt_hdp_set_connection_state_changed_cb_ptr + .asFunction<_dart_bt_hdp_set_connection_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HDP_MODULE + /// @brief Unregisters a callback function that will be invoked when the connection state is changed. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_hdp_set_connection_state_changed_cb() + int bt_hdp_unset_connection_state_changed_cb() { + return _bt_hdp_unset_connection_state_changed_cb(); + } + + late final _bt_hdp_unset_connection_state_changed_cb_ptr = + _lookup>( + 'bt_hdp_unset_connection_state_changed_cb'); + late final _dart_bt_hdp_unset_connection_state_changed_cb + _bt_hdp_unset_connection_state_changed_cb = + _bt_hdp_unset_connection_state_changed_cb_ptr + .asFunction<_dart_bt_hdp_unset_connection_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HDP_MODULE + /// @brief Registers a callback function that will be invoked when you receive the data. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_hdp_unset_data_received_cb() + int bt_hdp_set_data_received_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_hdp_set_data_received_cb( + callback, + user_data, + ); + } + + late final _bt_hdp_set_data_received_cb_ptr = + _lookup>( + 'bt_hdp_set_data_received_cb'); + late final _dart_bt_hdp_set_data_received_cb _bt_hdp_set_data_received_cb = + _bt_hdp_set_data_received_cb_ptr + .asFunction<_dart_bt_hdp_set_data_received_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_HDP_MODULE + /// @brief Unregisters a callback function that will be invoked when you receive the data. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_hdp_set_data_received_cb() + int bt_hdp_unset_data_received_cb() { + return _bt_hdp_unset_data_received_cb(); + } + + late final _bt_hdp_unset_data_received_cb_ptr = + _lookup>( + 'bt_hdp_unset_data_received_cb'); + late final _dart_bt_hdp_unset_data_received_cb + _bt_hdp_unset_data_received_cb = _bt_hdp_unset_data_received_cb_ptr + .asFunction<_dart_bt_hdp_unset_data_received_cb>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. Use bt_gatt_client_foreach_services or bt_gatt_client_get_service instead. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the primary services of GATT(Generic Attribute Profile). + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] remote_address The address of the remote device + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @post @a callback will be called if there are primary services. + /// @see bt_gatt_primary_service_cb() + int bt_gatt_foreach_primary_services( + ffi.Pointer remote_address, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_foreach_primary_services( + remote_address, + callback, + user_data, + ); + } + + late final _bt_gatt_foreach_primary_services_ptr = + _lookup>( + 'bt_gatt_foreach_primary_services'); + late final _dart_bt_gatt_foreach_primary_services + _bt_gatt_foreach_primary_services = _bt_gatt_foreach_primary_services_ptr + .asFunction<_dart_bt_gatt_foreach_primary_services>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. This function call is not required because characteristic discovery is happened automatically. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Discovers the characteristics in service, asynchronously. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] service The attribute handle of service + /// @param[in] callback The result callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @post @a callback will be called. + /// @see bt_gatt_characteristics_discovered_cb() + int bt_gatt_discover_characteristics( + ffi.Pointer service, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_discover_characteristics( + service, + callback, + user_data, + ); + } + + late final _bt_gatt_discover_characteristics_ptr = + _lookup>( + 'bt_gatt_discover_characteristics'); + late final _dart_bt_gatt_discover_characteristics + _bt_gatt_discover_characteristics = _bt_gatt_discover_characteristics_ptr + .asFunction<_dart_bt_gatt_discover_characteristics>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. Use bt_gatt_get_uuid instead. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the UUID of service. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @remarks @a uuid must be released with free() by you. + /// @param[in] service The attribute handle of service + /// @param[out] uuid The UUID of service + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + int bt_gatt_get_service_uuid( + ffi.Pointer service, + ffi.Pointer> uuid, + ) { + return _bt_gatt_get_service_uuid( + service, + uuid, + ); + } + + late final _bt_gatt_get_service_uuid_ptr = + _lookup>( + 'bt_gatt_get_service_uuid'); + late final _dart_bt_gatt_get_service_uuid _bt_gatt_get_service_uuid = + _bt_gatt_get_service_uuid_ptr + .asFunction<_dart_bt_gatt_get_service_uuid>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. Use bt_gatt_service_foreach_included_services or bt_gatt_service_get_included_service instead. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the included services in service. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] service The attribute handle of service + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @post @a callback will be called if there are included services. + /// @see bt_gatt_included_service_cb() + int bt_gatt_foreach_included_services( + ffi.Pointer service, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_foreach_included_services( + service, + callback, + user_data, + ); + } + + late final _bt_gatt_foreach_included_services_ptr = + _lookup>( + 'bt_gatt_foreach_included_services'); + late final _dart_bt_gatt_foreach_included_services + _bt_gatt_foreach_included_services = + _bt_gatt_foreach_included_services_ptr + .asFunction<_dart_bt_gatt_foreach_included_services>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. Use bt_gatt_client_set_characteristic_value_changed_cb instead. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Registers a callback function that will be invoked when a characteristic value is changed. + /// @since_tizen 2.3 + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_gatt_unset_characteristic_changed_cb() + int bt_gatt_set_characteristic_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_set_characteristic_changed_cb( + callback, + user_data, + ); + } + + late final _bt_gatt_set_characteristic_changed_cb_ptr = + _lookup>( + 'bt_gatt_set_characteristic_changed_cb'); + late final _dart_bt_gatt_set_characteristic_changed_cb + _bt_gatt_set_characteristic_changed_cb = + _bt_gatt_set_characteristic_changed_cb_ptr + .asFunction<_dart_bt_gatt_set_characteristic_changed_cb>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. Use bt_gatt_client_unset_characteristic_value_changed_cb instead. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Unregisters a callback function that will be invoked when a characteristic is changed. + /// @since_tizen 2.3 + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_gatt_set_characteristic_changed_cb() + int bt_gatt_unset_characteristic_changed_cb() { + return _bt_gatt_unset_characteristic_changed_cb(); + } + + late final _bt_gatt_unset_characteristic_changed_cb_ptr = + _lookup>( + 'bt_gatt_unset_characteristic_changed_cb'); + late final _dart_bt_gatt_unset_characteristic_changed_cb + _bt_gatt_unset_characteristic_changed_cb = + _bt_gatt_unset_characteristic_changed_cb_ptr + .asFunction<_dart_bt_gatt_unset_characteristic_changed_cb>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. Use bt_gatt_client_set_characteristic_value_changed_cb instead. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Watches all the characteristic value changes of the service. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] service The attribute handle of service + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_gatt_unset_characteristic_changed_cb() + int bt_gatt_watch_characteristic_changes( + ffi.Pointer service, + ) { + return _bt_gatt_watch_characteristic_changes( + service, + ); + } + + late final _bt_gatt_watch_characteristic_changes_ptr = + _lookup>( + 'bt_gatt_watch_characteristic_changes'); + late final _dart_bt_gatt_watch_characteristic_changes + _bt_gatt_watch_characteristic_changes = + _bt_gatt_watch_characteristic_changes_ptr + .asFunction<_dart_bt_gatt_watch_characteristic_changes>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. Use bt_gatt_client_unset_characteristic_value_changed_cb instead. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Remove watching of all the characteristic value changes of the service. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] service The attribute handle of service + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_gatt_set_characteristic_changed_cb() + int bt_gatt_unwatch_characteristic_changes( + ffi.Pointer service, + ) { + return _bt_gatt_unwatch_characteristic_changes( + service, + ); + } + + late final _bt_gatt_unwatch_characteristic_changes_ptr = + _lookup>( + 'bt_gatt_unwatch_characteristic_changes'); + late final _dart_bt_gatt_unwatch_characteristic_changes + _bt_gatt_unwatch_characteristic_changes = + _bt_gatt_unwatch_characteristic_changes_ptr + .asFunction<_dart_bt_gatt_unwatch_characteristic_changes>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. Use bt_gatt_get_value or bt_gatt_get_uuid after bt_gatt_client_read_value instead. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the characteristic declaration. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @remarks @a uuid and @a value must be released with free() by you. + /// @param[in] characteristic The attribute handle of characteristic + /// @param[out] uuid The UUID of service + /// @param[out] value The value of characteristic (byte array) + /// @param[out] value_length The length of value + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @see bt_gatt_set_characteristic_value() + int bt_gatt_get_characteristic_declaration( + ffi.Pointer characteristic, + ffi.Pointer> uuid, + ffi.Pointer> value, + ffi.Pointer value_length, + ) { + return _bt_gatt_get_characteristic_declaration( + characteristic, + uuid, + value, + value_length, + ); + } + + late final _bt_gatt_get_characteristic_declaration_ptr = + _lookup>( + 'bt_gatt_get_characteristic_declaration'); + late final _dart_bt_gatt_get_characteristic_declaration + _bt_gatt_get_characteristic_declaration = + _bt_gatt_get_characteristic_declaration_ptr + .asFunction<_dart_bt_gatt_get_characteristic_declaration>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. Use bt_gatt_set_value and bt_gatt_client_write_value instead. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Sets the value of characteristic. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] characteristic The attribute handle of characteristic + /// @param[in] value The value of characteristic (byte array) + /// @param[in] value_length The length of value + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @see bt_gatt_get_characteristic_declaration() + int bt_gatt_set_characteristic_value( + ffi.Pointer characteristic, + ffi.Pointer value, + int value_length, + ) { + return _bt_gatt_set_characteristic_value( + characteristic, + value, + value_length, + ); + } + + late final _bt_gatt_set_characteristic_value_ptr = + _lookup>( + 'bt_gatt_set_characteristic_value'); + late final _dart_bt_gatt_set_characteristic_value + _bt_gatt_set_characteristic_value = _bt_gatt_set_characteristic_value_ptr + .asFunction<_dart_bt_gatt_set_characteristic_value>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. Use bt_gatt_set_value and bt_gatt_client_write_value instead. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Sets the value of characteristic request. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] characteristic The attribute handle of characteristic + /// @param[in] value The value of characteristic (byte array) + /// @param[in] value_length The length of value + /// @param[in] callback The result callback + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @see bt_gatt_get_characteristic_declaration() + int bt_gatt_set_characteristic_value_request( + ffi.Pointer characteristic, + ffi.Pointer value, + int value_length, + ffi.Pointer> callback, + ) { + return _bt_gatt_set_characteristic_value_request( + characteristic, + value, + value_length, + callback, + ); + } + + late final _bt_gatt_set_characteristic_value_request_ptr = + _lookup>( + 'bt_gatt_set_characteristic_value_request'); + late final _dart_bt_gatt_set_characteristic_value_request + _bt_gatt_set_characteristic_value_request = + _bt_gatt_set_characteristic_value_request_ptr + .asFunction<_dart_bt_gatt_set_characteristic_value_request>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. GATT handle clone is not allowed. Instead, all handles for client role must be got from GATT client handle. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Clones the attribute handle. + /// @since_tizen 2.3 + /// @remarks @a clone must be released with bt_gatt_destroy_attribute_handle(). + /// @param[out] clone The cloned attribute handle + /// @param[in] origin The origin attribute handle + /// @return 0 on success, otherwise negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_destroy_attribute_handle() + int bt_gatt_clone_attribute_handle( + ffi.Pointer> clone, + ffi.Pointer origin, + ) { + return _bt_gatt_clone_attribute_handle( + clone, + origin, + ); + } + + late final _bt_gatt_clone_attribute_handle_ptr = + _lookup>( + 'bt_gatt_clone_attribute_handle'); + late final _dart_bt_gatt_clone_attribute_handle + _bt_gatt_clone_attribute_handle = _bt_gatt_clone_attribute_handle_ptr + .asFunction<_dart_bt_gatt_clone_attribute_handle>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. GATT handle clone and destroy are not allowed. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Destroys the attribute handle. + /// @since_tizen 2.3 + /// @param[in] handle The attribute handle + /// @return 0 on success, otherwise negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_clone_attribute_handle() + int bt_gatt_destroy_attribute_handle( + ffi.Pointer handle, + ) { + return _bt_gatt_destroy_attribute_handle( + handle, + ); + } + + late final _bt_gatt_destroy_attribute_handle_ptr = + _lookup>( + 'bt_gatt_destroy_attribute_handle'); + late final _dart_bt_gatt_destroy_attribute_handle + _bt_gatt_destroy_attribute_handle = _bt_gatt_destroy_attribute_handle_ptr + .asFunction<_dart_bt_gatt_destroy_attribute_handle>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. Use gatt_client_read_value instead. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Reads the value of characteristic from remote device. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] char_handle The attribute handle of characteristic + /// @param[in] callback The result callback + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @see bt_gatt_get_characteristic_declaration() + int bt_gatt_read_characteristic_value( + ffi.Pointer char_handle, + ffi.Pointer> callback, + ) { + return _bt_gatt_read_characteristic_value( + char_handle, + callback, + ); + } + + late final _bt_gatt_read_characteristic_value_ptr = + _lookup>( + 'bt_gatt_read_characteristic_value'); + late final _dart_bt_gatt_read_characteristic_value + _bt_gatt_read_characteristic_value = + _bt_gatt_read_characteristic_value_ptr + .asFunction<_dart_bt_gatt_read_characteristic_value>(); + + /// @MOBILE_ONLY + /// @deprecated Deprecated since 2.3.1. This function call is not required because descriptor discovery is happened automatically. + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Discovers the characteristic descriptors of a characteristic within its definition, asynchronously. + /// @since_tizen 2.3 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// @param[in] characteristic_handle The attribute handle of characteristic + /// @param[in] callback The result callback + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @post @a callback will be called. + /// @see bt_gatt_characteristic_descriptor_discovered_cb() + int bt_gatt_discover_characteristic_descriptor( + ffi.Pointer characteristic_handle, + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_discover_characteristic_descriptor( + characteristic_handle, + callback, + user_data, + ); + } + + late final _bt_gatt_discover_characteristic_descriptor_ptr = _lookup< + ffi.NativeFunction<_c_bt_gatt_discover_characteristic_descriptor>>( + 'bt_gatt_discover_characteristic_descriptor'); + late final _dart_bt_gatt_discover_characteristic_descriptor + _bt_gatt_discover_characteristic_descriptor = + _bt_gatt_discover_characteristic_descriptor_ptr + .asFunction<_dart_bt_gatt_discover_characteristic_descriptor>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the value of a characteristic or descriptor's GATT handle. + /// @since_tizen 2.3.1 + /// + /// @remarks @a value must be released using free(). \n + /// When @a gatt_handle is associated with bt_gatt_client_h, bt_gatt_client_read_value() must be used prior to this function \n + /// in order to get the remote device's current value. + /// + /// @param[in] gatt_handle The handle of a characteristic or descriptor + /// @param[out] value The value of @a gatt_handle. It is a byte stream type. + /// @param[out] value_length The length of @a value + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_get_value( + ffi.Pointer gatt_handle, + ffi.Pointer> value, + ffi.Pointer value_length, + ) { + return _bt_gatt_get_value( + gatt_handle, + value, + value_length, + ); + } + + late final _bt_gatt_get_value_ptr = + _lookup>('bt_gatt_get_value'); + late final _dart_bt_gatt_get_value _bt_gatt_get_value = + _bt_gatt_get_value_ptr.asFunction<_dart_bt_gatt_get_value>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the value of a characteristic or descriptor's GATT handle as an integer type. + /// @since_tizen 2.3.1 + /// + /// @remarks This function returns a locally saved value in @a gatt_handle. \n + /// When @a gatt_handle is associated with bt_gatt_client_h, bt_gatt_client_read_value() must be used prior to this function \n + /// in order to get the remote device's current value. + /// + /// @param[in] gatt_handle The handle of a characteristic or descriptor + /// @param[in] type The type of a saved value in @a gatt_handle + /// @param[in] offset The offset from where a value will be read from @a gatt_handle as an integer type + /// @param[out] value The integer type's value of @a gatt_handle + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_get_int_value( + ffi.Pointer gatt_handle, + int type, + int offset, + ffi.Pointer value, + ) { + return _bt_gatt_get_int_value( + gatt_handle, + type, + offset, + value, + ); + } + + late final _bt_gatt_get_int_value_ptr = + _lookup>( + 'bt_gatt_get_int_value'); + late final _dart_bt_gatt_get_int_value _bt_gatt_get_int_value = + _bt_gatt_get_int_value_ptr.asFunction<_dart_bt_gatt_get_int_value>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the value of a characteristic or descriptor's GATT handle as a float type. + /// @since_tizen 2.3.1 + /// + /// @remarks This function returns a locally saved value in @a gatt_handle. \n + /// When @a gatt_handle is associated with bt_gatt_client_h, bt_gatt_client_read_value() must be used prior to this function \n + /// in order to get the remote device's current value. + /// + /// @param[in] gatt_handle The handle of a characteristic or descriptor + /// @param[in] type The type of a saved value in @a gatt_handle + /// @param[in] offset The offset from where a value will be read from @a gatt_handle as an integer type + /// @param[out] value The float type's value of @a gatt_handle + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_get_float_value( + ffi.Pointer gatt_handle, + int type, + int offset, + ffi.Pointer value, + ) { + return _bt_gatt_get_float_value( + gatt_handle, + type, + offset, + value, + ); + } + + late final _bt_gatt_get_float_value_ptr = + _lookup>( + 'bt_gatt_get_float_value'); + late final _dart_bt_gatt_get_float_value _bt_gatt_get_float_value = + _bt_gatt_get_float_value_ptr.asFunction<_dart_bt_gatt_get_float_value>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Updates the value of a characteristic or descriptor's GATT handle. + /// @since_tizen 2.3.1 + /// + /// @remarks This function updates a value of @a gatt_handle locally. \n + /// When @a gatt_handle is associated with bt_gatt_client_h, bt_gatt_client_write_value() can be used after this function \n + /// in order to update the remote device's value. \n + /// + /// @param[in] gatt_handle The handle of a characteristic or descriptor + /// @param[in] value The value to be updated + /// @param[in] value_length The length of @a value + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_set_value( + ffi.Pointer gatt_handle, + ffi.Pointer value, + int value_length, + ) { + return _bt_gatt_set_value( + gatt_handle, + value, + value_length, + ); + } + + late final _bt_gatt_set_value_ptr = + _lookup>('bt_gatt_set_value'); + late final _dart_bt_gatt_set_value _bt_gatt_set_value = + _bt_gatt_set_value_ptr.asFunction<_dart_bt_gatt_set_value>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Updates the value of a characteristic or descriptor's GATT handle using a integer type's value. + /// @since_tizen 2.3.1 + /// + /// @remarks This function updates a value of @a gatt_handle locally. \n + /// When @a gatt_handle is associated with bt_gatt_client_h, bt_gatt_client_write_value() can be used after this function \n + /// in order to update the remote device's value. \n + /// + /// @param[in] gatt_handle The handle of a characteristic or descriptor + /// @param[in] type @a value will be saved in @a gatt_handle as this type + /// @param[in] value The integer type's value to be updated + /// @param[in] offset The offset from where @a value will be saved in @a gatt_handle + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_set_int_value( + ffi.Pointer gatt_handle, + int type, + int value, + int offset, + ) { + return _bt_gatt_set_int_value( + gatt_handle, + type, + value, + offset, + ); + } + + late final _bt_gatt_set_int_value_ptr = + _lookup>( + 'bt_gatt_set_int_value'); + late final _dart_bt_gatt_set_int_value _bt_gatt_set_int_value = + _bt_gatt_set_int_value_ptr.asFunction<_dart_bt_gatt_set_int_value>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Updates the value of a characteristic or descriptor's GATT handle using a float type's value. + /// @since_tizen 2.3.1 + /// + /// @remarks This function updates a value of @a gatt_handle locally. \n + /// When @a gatt_handle is associated with bt_gatt_client_h, bt_gatt_client_write_value() can be used after this function \n + /// in order to update the remote device's value. \n + /// + /// @param[in] gatt_handle The handle of a characteristic or descriptor + /// @param[in] type @a mantissa and @a exponent will be saved in @a gatt_handle as this type + /// @param[in] mantissa The mantissa of float type's value to be updated + /// @param[in] exponent The exponent of float type's value to be updated + /// @param[in] offset The offset from where @a mantissa and @a exponent will be saved in @a gatt_handle + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_set_float_value( + ffi.Pointer gatt_handle, + int type, + int mantissa, + int exponent, + int offset, + ) { + return _bt_gatt_set_float_value( + gatt_handle, + type, + mantissa, + exponent, + offset, + ); + } + + late final _bt_gatt_set_float_value_ptr = + _lookup>( + 'bt_gatt_set_float_value'); + late final _dart_bt_gatt_set_float_value _bt_gatt_set_float_value = + _bt_gatt_set_float_value_ptr.asFunction<_dart_bt_gatt_set_float_value>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the UUID of a service, characteristic or descriptor's GATT handle. + /// @since_tizen 2.3.1 + /// + /// @remarks @a uuid must be released using free(). \n + /// 16-bit UUID or 128-bit UUID is supported. (e.g. 2A19, 00002A19-0000-1000-8000-00805F9B34FB) + /// + /// @param[in] gatt_handle The handle of a service, characteristic or descriptor + /// @param[out] uuid The string of the UUID of @a gatt_handle + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_get_uuid( + ffi.Pointer gatt_handle, + ffi.Pointer> uuid, + ) { + return _bt_gatt_get_uuid( + gatt_handle, + uuid, + ); + } + + late final _bt_gatt_get_uuid_ptr = + _lookup>('bt_gatt_get_uuid'); + late final _dart_bt_gatt_get_uuid _bt_gatt_get_uuid = + _bt_gatt_get_uuid_ptr.asFunction<_dart_bt_gatt_get_uuid>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the type of GATT handle. + /// @since_tizen 2.3.1 + /// + /// @param[in] gatt_handle The GATT handle + /// @param[out] gatt_type The type of @a gatt_handle + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_get_type( + ffi.Pointer gatt_handle, + ffi.Pointer gatt_type, + ) { + return _bt_gatt_get_type( + gatt_handle, + gatt_type, + ); + } + + late final _bt_gatt_get_type_ptr = + _lookup>('bt_gatt_get_type'); + late final _dart_bt_gatt_get_type _bt_gatt_get_type = + _bt_gatt_get_type_ptr.asFunction<_dart_bt_gatt_get_type>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Gets the GATT client handle which the specified service belongs to. + /// @since_tizen 2.3.1 + /// + /// @remark This function doesn't allocate new memory for GATT client handle. + /// The returned GATT client handle is the same one which was got from bt_gatt_client_create(). + /// So if it is destroyed by bt_gatt_client_destroy(), all related GATT handles are freed also. + /// + /// @param[in] service The service's GATT handle + /// @param[out] client The GATT client handle which @a service belongs to + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_client_create() + int bt_gatt_service_get_client( + ffi.Pointer service, + ffi.Pointer> client, + ) { + return _bt_gatt_service_get_client( + service, + client, + ); + } + + late final _bt_gatt_service_get_client_ptr = + _lookup>( + 'bt_gatt_service_get_client'); + late final _dart_bt_gatt_service_get_client _bt_gatt_service_get_client = + _bt_gatt_service_get_client_ptr + .asFunction<_dart_bt_gatt_service_get_client>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets a characteristic's GATT handle which has specific UUID. + /// @since_tizen 2.3.1 + /// + /// @remark The returned GATT handle must not be freed by application. + /// It will be freed when an associated client is destroyed by bt_gatt_client_destroy(). + /// If there are multiple characteristics which have same UUID, only the first matched one will be returned. + /// + /// @param[in] service The service's GATT handle + /// @param[in] uuid The characteristic's GATT handle which has this UUID will be returned if it exists + /// @param[out] characteristic The characteristic's GATT handle which has @a uuid if it exists + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NO_DATA No data available + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_service_get_characteristic( + ffi.Pointer service, + ffi.Pointer uuid, + ffi.Pointer> characteristic, + ) { + return _bt_gatt_service_get_characteristic( + service, + uuid, + characteristic, + ); + } + + late final _bt_gatt_service_get_characteristic_ptr = + _lookup>( + 'bt_gatt_service_get_characteristic'); + late final _dart_bt_gatt_service_get_characteristic + _bt_gatt_service_get_characteristic = + _bt_gatt_service_get_characteristic_ptr + .asFunction<_dart_bt_gatt_service_get_characteristic>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Invokes @a callback function on each characteristic that belongs to the specified service. + /// @since_tizen 2.3.1 + /// + /// @param[in] service The service's GATT handle + /// @param[in] callback The function to be invoked on each characteristic + /// @param[in] user_data The user data to be passed to @a callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_foreach_cb() + int bt_gatt_service_foreach_characteristics( + ffi.Pointer service, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_service_foreach_characteristics( + service, + callback, + user_data, + ); + } + + late final _bt_gatt_service_foreach_characteristics_ptr = + _lookup>( + 'bt_gatt_service_foreach_characteristics'); + late final _dart_bt_gatt_service_foreach_characteristics + _bt_gatt_service_foreach_characteristics = + _bt_gatt_service_foreach_characteristics_ptr + .asFunction<_dart_bt_gatt_service_foreach_characteristics>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets an included service's GATT handle which has specific UUID. + /// @since_tizen 2.3.1 + /// + /// @remark The returned GATT handle must not be freed by application. + /// It will be freed when an associated client is destroyed by bt_gatt_client_destroy(). + /// If there are multiple included services which have same UUID, only the first matched one will be returned. + /// + /// @param[in] service The service's GATT handle + /// @param[in] uuid The included service's GATT handle which has this UUID will be returned if it exists + /// @param[out] included_service The included service's GATT handle which has @a uuid if it exists + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NO_DATA No data available + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_service_get_included_service( + ffi.Pointer service, + ffi.Pointer uuid, + ffi.Pointer> included_service, + ) { + return _bt_gatt_service_get_included_service( + service, + uuid, + included_service, + ); + } + + late final _bt_gatt_service_get_included_service_ptr = + _lookup>( + 'bt_gatt_service_get_included_service'); + late final _dart_bt_gatt_service_get_included_service + _bt_gatt_service_get_included_service = + _bt_gatt_service_get_included_service_ptr + .asFunction<_dart_bt_gatt_service_get_included_service>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Invokes @a callback function on each included service that belongs to the specified service. + /// @since_tizen 2.3.1 + /// + /// @param[in] service The service's GATT handle + /// @param[in] callback The function to be invoked on each included service + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_foreach_cb() + int bt_gatt_service_foreach_included_services( + ffi.Pointer service, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_service_foreach_included_services( + service, + callback, + user_data, + ); + } + + late final _bt_gatt_service_foreach_included_services_ptr = + _lookup>( + 'bt_gatt_service_foreach_included_services'); + late final _dart_bt_gatt_service_foreach_included_services + _bt_gatt_service_foreach_included_services = + _bt_gatt_service_foreach_included_services_ptr + .asFunction<_dart_bt_gatt_service_foreach_included_services>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the service's GATT handle which the specified characteristic belongs to. + /// @since_tizen 2.3.1 + /// + /// @remark The returned GATT handle must not be freed by application. + /// It will be freed when an associated client is destroyed by bt_gatt_client_destroy(). + /// + /// @param[in] characteristic The characteristic's GATT handle + /// @param[out] service The service's GATT handle which @a characteristic belongs to + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_characteristic_get_service( + ffi.Pointer characteristic, + ffi.Pointer> service, + ) { + return _bt_gatt_characteristic_get_service( + characteristic, + service, + ); + } + + late final _bt_gatt_characteristic_get_service_ptr = + _lookup>( + 'bt_gatt_characteristic_get_service'); + late final _dart_bt_gatt_characteristic_get_service + _bt_gatt_characteristic_get_service = + _bt_gatt_characteristic_get_service_ptr + .asFunction<_dart_bt_gatt_characteristic_get_service>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the properties which a characteristic's GATT handle has. + /// @since_tizen 2.3.1 + /// + /// @param[in] characteristic The characteristic's GATT handle + /// @param[out] properties The properties which a characteristic's GATT handle has + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_property_e + int bt_gatt_characteristic_get_properties( + ffi.Pointer characteristic, + ffi.Pointer properties, + ) { + return _bt_gatt_characteristic_get_properties( + characteristic, + properties, + ); + } + + late final _bt_gatt_characteristic_get_properties_ptr = + _lookup>( + 'bt_gatt_characteristic_get_properties'); + late final _dart_bt_gatt_characteristic_get_properties + _bt_gatt_characteristic_get_properties = + _bt_gatt_characteristic_get_properties_ptr + .asFunction<_dart_bt_gatt_characteristic_get_properties>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the write type of the specified characteristic. + /// @since_tizen 2.3.1 + /// + /// @param[in] characteristic The characteristic's GATT handle + /// @param[out] write_type The write type of the specified characteristic + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_write_type_e + int bt_gatt_characteristic_get_write_type( + ffi.Pointer characteristic, + ffi.Pointer write_type, + ) { + return _bt_gatt_characteristic_get_write_type( + characteristic, + write_type, + ); + } + + late final _bt_gatt_characteristic_get_write_type_ptr = + _lookup>( + 'bt_gatt_characteristic_get_write_type'); + late final _dart_bt_gatt_characteristic_get_write_type + _bt_gatt_characteristic_get_write_type = + _bt_gatt_characteristic_get_write_type_ptr + .asFunction<_dart_bt_gatt_characteristic_get_write_type>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Updates the write type of the specified characteristic. + /// @since_tizen 2.3.1 + /// + /// @param[in] characteristic The characteristic's GATT handle + /// @param[in] write_type The write type to be updated + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_client_write_value() + /// @see bt_gatt_write_type_e + int bt_gatt_characteristic_set_write_type( + ffi.Pointer characteristic, + int write_type, + ) { + return _bt_gatt_characteristic_set_write_type( + characteristic, + write_type, + ); + } + + late final _bt_gatt_characteristic_set_write_type_ptr = + _lookup>( + 'bt_gatt_characteristic_set_write_type'); + late final _dart_bt_gatt_characteristic_set_write_type + _bt_gatt_characteristic_set_write_type = + _bt_gatt_characteristic_set_write_type_ptr + .asFunction<_dart_bt_gatt_characteristic_set_write_type>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets a descriptor's GATT handle which has specific UUID. + /// @since_tizen 2.3.1 + /// + /// @remark The returned GATT handle must not be freed by application. + /// It will be freed when an associated client is destroyed by bt_gatt_client_destroy(). + /// If there are multiple descriptors which have same UUID, only the first matched one will be returned. + /// + /// @param[in] characteristic The characteristic's GATT handle + /// @param[in] uuid The descriptor's GATT handle which has this UUID will be returned if it exists + /// @param[out] descriptor The descriptor's GATT handle which has @a uuid if it exists + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NO_DATA No data available + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_characteristic_get_descriptor( + ffi.Pointer characteristic, + ffi.Pointer uuid, + ffi.Pointer> descriptor, + ) { + return _bt_gatt_characteristic_get_descriptor( + characteristic, + uuid, + descriptor, + ); + } + + late final _bt_gatt_characteristic_get_descriptor_ptr = + _lookup>( + 'bt_gatt_characteristic_get_descriptor'); + late final _dart_bt_gatt_characteristic_get_descriptor + _bt_gatt_characteristic_get_descriptor = + _bt_gatt_characteristic_get_descriptor_ptr + .asFunction<_dart_bt_gatt_characteristic_get_descriptor>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Invokes @a callback function on each descriptor that belongs to the specified characteristic. + /// @since_tizen 2.3.1 + /// + /// @param[in] characteristic The characteristic's GATT handle + /// @param[in] callback The function to be invoked on each descriptor + /// @param[in] user_data The user data to be passed to @a callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_foreach_cb() + int bt_gatt_characteristic_foreach_descriptors( + ffi.Pointer characteristic, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_characteristic_foreach_descriptors( + characteristic, + callback, + user_data, + ); + } + + late final _bt_gatt_characteristic_foreach_descriptors_ptr = _lookup< + ffi.NativeFunction<_c_bt_gatt_characteristic_foreach_descriptors>>( + 'bt_gatt_characteristic_foreach_descriptors'); + late final _dart_bt_gatt_characteristic_foreach_descriptors + _bt_gatt_characteristic_foreach_descriptors = + _bt_gatt_characteristic_foreach_descriptors_ptr + .asFunction<_dart_bt_gatt_characteristic_foreach_descriptors>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the characteristic's GATT handle which the specified descriptor belongs to. + /// @since_tizen 2.3.1 + /// + /// @remark The returned GATT handle must not be freed by application. + /// It will be freed when an associated client is destroyed by bt_gatt_client_destroy(). + /// + /// @param[in] descriptor The descriptor's GATT handle + /// @param[out] characteristic The characteristic's GATT handle which @a descriptor belongs to + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_descriptor_get_characteristic( + ffi.Pointer descriptor, + ffi.Pointer> characteristic, + ) { + return _bt_gatt_descriptor_get_characteristic( + descriptor, + characteristic, + ); + } + + late final _bt_gatt_descriptor_get_characteristic_ptr = + _lookup>( + 'bt_gatt_descriptor_get_characteristic'); + late final _dart_bt_gatt_descriptor_get_characteristic + _bt_gatt_descriptor_get_characteristic = + _bt_gatt_descriptor_get_characteristic_ptr + .asFunction<_dart_bt_gatt_descriptor_get_characteristic>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Creates the GATT client handle. + /// @since_tizen 2.3.1 + /// + /// @remark The GATT client handle must be freed by bt_gatt_client_destroy() after use + /// + /// @param[in] remote_address The address of the remote device + /// @param[out] client The created GATT client's handle + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_ALREADY_DONE Operation is already done + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_client_destroy() + int bt_gatt_client_create( + ffi.Pointer remote_address, + ffi.Pointer> client, + ) { + return _bt_gatt_client_create( + remote_address, + client, + ); + } + + late final _bt_gatt_client_create_ptr = + _lookup>( + 'bt_gatt_client_create'); + late final _dart_bt_gatt_client_create _bt_gatt_client_create = + _bt_gatt_client_create_ptr.asFunction<_dart_bt_gatt_client_create>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Destroys the GATT client's handle. + /// @since_tizen 2.3.1 + /// + /// @remark All related service, characteristic and descriptor's GATT handles are freed also + /// + /// @param[in] client The GATT client's handle + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_client_create() + int bt_gatt_client_destroy( + ffi.Pointer client, + ) { + return _bt_gatt_client_destroy( + client, + ); + } + + late final _bt_gatt_client_destroy_ptr = + _lookup>( + 'bt_gatt_client_destroy'); + late final _dart_bt_gatt_client_destroy _bt_gatt_client_destroy = + _bt_gatt_client_destroy_ptr.asFunction<_dart_bt_gatt_client_destroy>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Gets the address of remote device. + /// @since_tizen 2.3.1 + /// + /// @param[in] client The created GATT client's handle + /// @param[out] remote_address The address of the remote device which is associated with @a client + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_client_create() + int bt_gatt_client_get_remote_address( + ffi.Pointer client, + ffi.Pointer> remote_address, + ) { + return _bt_gatt_client_get_remote_address( + client, + remote_address, + ); + } + + late final _bt_gatt_client_get_remote_address_ptr = + _lookup>( + 'bt_gatt_client_get_remote_address'); + late final _dart_bt_gatt_client_get_remote_address + _bt_gatt_client_get_remote_address = + _bt_gatt_client_get_remote_address_ptr + .asFunction<_dart_bt_gatt_client_get_remote_address>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Reads the value of a characteristic or descriptor from the remote device asynchronously. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] gatt_handle The GATT handle of a characteristic or descriptor + /// @param[in] callback When a read request is completed, this callback function will be called + /// @param[in] user_data The user data to be passed to @a callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOW_IN_PROGRESS Operation now in progress + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_client_create() + /// @see bt_gatt_client_request_completed_cb() + int bt_gatt_client_read_value( + ffi.Pointer gatt_handle, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_client_read_value( + gatt_handle, + callback, + user_data, + ); + } + + late final _bt_gatt_client_read_value_ptr = + _lookup>( + 'bt_gatt_client_read_value'); + late final _dart_bt_gatt_client_read_value _bt_gatt_client_read_value = + _bt_gatt_client_read_value_ptr + .asFunction<_dart_bt_gatt_client_read_value>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Writes the value of a characteristic or descriptor to the remote device asynchronously. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] gatt_handle The GATT handle of a characteristic or descriptor + /// @param[in] callback When a write request is completed, this callback function will be called + /// @param[in] user_data The user data to be passed to @a callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOW_IN_PROGRESS Operation now in progress + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_client_create() + /// @see bt_gatt_characteristic_set_write_type() + /// @see bt_gatt_set_value() + /// @see bt_gatt_set_int_value() + /// @see bt_gatt_set_float_value() + /// @see bt_gatt_client_request_completed_cb() + int bt_gatt_client_write_value( + ffi.Pointer gatt_handle, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_client_write_value( + gatt_handle, + callback, + user_data, + ); + } + + late final _bt_gatt_client_write_value_ptr = + _lookup>( + 'bt_gatt_client_write_value'); + late final _dart_bt_gatt_client_write_value _bt_gatt_client_write_value = + _bt_gatt_client_write_value_ptr + .asFunction<_dart_bt_gatt_client_write_value>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Requests a change of the ATT MTU value. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] client The created GATT client's handle + /// @param[in] mtu The new MTU value + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// @see bt_gatt_client_set_att_mtu_changed_cb() + int bt_gatt_client_request_att_mtu_change( + ffi.Pointer client, + int mtu, + ) { + return _bt_gatt_client_request_att_mtu_change( + client, + mtu, + ); + } + + late final _bt_gatt_client_request_att_mtu_change_ptr = + _lookup>( + 'bt_gatt_client_request_att_mtu_change'); + late final _dart_bt_gatt_client_request_att_mtu_change + _bt_gatt_client_request_att_mtu_change = + _bt_gatt_client_request_att_mtu_change_ptr + .asFunction<_dart_bt_gatt_client_request_att_mtu_change>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Gets the ATT MTU value set for a connection. + /// @since_tizen 4.0 + /// + /// @param[in] client The created GATT client's handle + /// @param[out] mtu The MTU value set for a connection + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_client_get_att_mtu( + ffi.Pointer client, + ffi.Pointer mtu, + ) { + return _bt_gatt_client_get_att_mtu( + client, + mtu, + ); + } + + late final _bt_gatt_client_get_att_mtu_ptr = + _lookup>( + 'bt_gatt_client_get_att_mtu'); + late final _dart_bt_gatt_client_get_att_mtu _bt_gatt_client_get_att_mtu = + _bt_gatt_client_get_att_mtu_ptr + .asFunction<_dart_bt_gatt_client_get_att_mtu>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Registers a callback function to be invoked when the ATT MTU is changed. + /// @since_tizen 4.0 + /// @param[in] client The created GATT client's handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @post bt_device_connection_state_changed_cb() will be invoked. + /// @see bt_initialize() + /// @see bt_gatt_client_request_att_mtu_change() + /// @see bt_gatt_client_unset_att_mtu_changed_cb() + int bt_gatt_client_set_att_mtu_changed_cb( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_client_set_att_mtu_changed_cb( + client, + callback, + user_data, + ); + } + + late final _bt_gatt_client_set_att_mtu_changed_cb_ptr = + _lookup>( + 'bt_gatt_client_set_att_mtu_changed_cb'); + late final _dart_bt_gatt_client_set_att_mtu_changed_cb + _bt_gatt_client_set_att_mtu_changed_cb = + _bt_gatt_client_set_att_mtu_changed_cb_ptr + .asFunction<_dart_bt_gatt_client_set_att_mtu_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Unregisters the callback function to be invoked when the ATT MTU is changed. + /// @since_tizen 4.0 + /// @param[in] client The created GATT client's handle + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @see bt_initialize() + /// @see bt_gatt_client_request_att_mtu_change() + /// @see bt_gatt_client_set_att_mtu_changed_cb() + int bt_gatt_client_unset_att_mtu_changed_cb( + ffi.Pointer client, + ) { + return _bt_gatt_client_unset_att_mtu_changed_cb( + client, + ); + } + + late final _bt_gatt_client_unset_att_mtu_changed_cb_ptr = + _lookup>( + 'bt_gatt_client_unset_att_mtu_changed_cb'); + late final _dart_bt_gatt_client_unset_att_mtu_changed_cb + _bt_gatt_client_unset_att_mtu_changed_cb = + _bt_gatt_client_unset_att_mtu_changed_cb_ptr + .asFunction<_dart_bt_gatt_client_unset_att_mtu_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Registers a callback function to be invoked when the characteristic value is changed on the remote device. + /// @since_tizen 2.3.1 + /// + /// @param[in] characteristic The characteristic's GATT handle + /// @param[in] callback The callback to be invoked when the value is changed and it is informed + /// @param[in] user_data The user data to be passed to @a callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_client_characteristic_value_changed_cb() + /// @see bt_gatt_client_unset_characteristic_value_change() + int bt_gatt_client_set_characteristic_value_changed_cb( + ffi.Pointer characteristic, + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_client_set_characteristic_value_changed_cb( + characteristic, + callback, + user_data, + ); + } + + late final _bt_gatt_client_set_characteristic_value_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_bt_gatt_client_set_characteristic_value_changed_cb>>( + 'bt_gatt_client_set_characteristic_value_changed_cb'); + late final _dart_bt_gatt_client_set_characteristic_value_changed_cb + _bt_gatt_client_set_characteristic_value_changed_cb = + _bt_gatt_client_set_characteristic_value_changed_cb_ptr.asFunction< + _dart_bt_gatt_client_set_characteristic_value_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Unregisters a callback function to be invoked when the characteristic value is changed on the remote device. + /// @since_tizen 2.3.1 + /// + /// @param[in] characteristic The characteristic's GATT handle, whose value change will not be informed + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_client_set_characteristic_value_changed_cb() + int bt_gatt_client_unset_characteristic_value_changed_cb( + ffi.Pointer characteristic, + ) { + return _bt_gatt_client_unset_characteristic_value_changed_cb( + characteristic, + ); + } + + late final _bt_gatt_client_unset_characteristic_value_changed_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_bt_gatt_client_unset_characteristic_value_changed_cb>>( + 'bt_gatt_client_unset_characteristic_value_changed_cb'); + late final _dart_bt_gatt_client_unset_characteristic_value_changed_cb + _bt_gatt_client_unset_characteristic_value_changed_cb = + _bt_gatt_client_unset_characteristic_value_changed_cb_ptr.asFunction< + _dart_bt_gatt_client_unset_characteristic_value_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Gets a service's GATT handle which has specific UUID. + /// @since_tizen 2.3.1 + /// + /// @remark The returned GATT handle must not be freed by application. + /// It will be freed when an associated client is destroyed by bt_gatt_client_destroy(). + /// If there are multiple services which have same UUID, only the first matched one will be returned. + /// + /// @param[in] client The GATT client's handle + /// @param[in] uuid The service's GATT handle which has this UUID will be returned if it exists + /// @param[out] service The service's GATT handle which has @a uuid if it exists + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NO_DATA No data available + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_client_get_service( + ffi.Pointer client, + ffi.Pointer uuid, + ffi.Pointer> service, + ) { + return _bt_gatt_client_get_service( + client, + uuid, + service, + ); + } + + late final _bt_gatt_client_get_service_ptr = + _lookup>( + 'bt_gatt_client_get_service'); + late final _dart_bt_gatt_client_get_service _bt_gatt_client_get_service = + _bt_gatt_client_get_service_ptr + .asFunction<_dart_bt_gatt_client_get_service>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Invokes @a callback function on each service that belongs to the specified GATT client. + /// @since_tizen 2.3.1 + /// + /// @param[in] client The GATT client's handle + /// @param[in] callback The function to be invoked on each service + /// @param[in] user_data The user data to be passed to @a callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_foreach_cb() + int bt_gatt_client_foreach_services( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_client_foreach_services( + client, + callback, + user_data, + ); + } + + late final _bt_gatt_client_foreach_services_ptr = + _lookup>( + 'bt_gatt_client_foreach_services'); + late final _dart_bt_gatt_client_foreach_services + _bt_gatt_client_foreach_services = _bt_gatt_client_foreach_services_ptr + .asFunction<_dart_bt_gatt_client_foreach_services>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Registers a callback function to be invoked when service is changed from a remote device(GATT server). + /// @since_tizen 3.0 + /// + /// @param[in] client The GATT client's handle + /// @param[in] callback The callback to be invoked + /// @param[in] user_data The user data to be passed to @a callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_client_unset_service_changed_cb() + int bt_gatt_client_set_service_changed_cb( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_client_set_service_changed_cb( + client, + callback, + user_data, + ); + } + + late final _bt_gatt_client_set_service_changed_cb_ptr = + _lookup>( + 'bt_gatt_client_set_service_changed_cb'); + late final _dart_bt_gatt_client_set_service_changed_cb + _bt_gatt_client_set_service_changed_cb = + _bt_gatt_client_set_service_changed_cb_ptr + .asFunction<_dart_bt_gatt_client_set_service_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Unregisters a callback function + /// @since_tizen 3.0 + /// + /// @param[in] client The GATT client's handle + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_client_set_service_changed_cb() + int bt_gatt_client_unset_service_changed_cb( + ffi.Pointer client, + ) { + return _bt_gatt_client_unset_service_changed_cb( + client, + ); + } + + late final _bt_gatt_client_unset_service_changed_cb_ptr = + _lookup>( + 'bt_gatt_client_unset_service_changed_cb'); + late final _dart_bt_gatt_client_unset_service_changed_cb + _bt_gatt_client_unset_service_changed_cb = + _bt_gatt_client_unset_service_changed_cb_ptr + .asFunction<_dart_bt_gatt_client_unset_service_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Connect to a specific LE based service on a remote bluetooth device address, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @remarks A connection can be disconnected by bt_gatt_disconnect(). + /// + /// @param[in] address The address of the remote Bluetooth device. + /// @param[in] auto_connect The flag of the auto connection. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// @pre The remote device must support le connection. + /// @post This function invokes bt_gatt_connection_state_changed_cb(). + /// + /// @see bt_initialize() + /// @see bt_gatt_disconnect() + /// @see bt_gatt_set_connection_state_changed_cb() + /// @see bt_gatt_unset_connection_state_changed_cb() + /// @see bt_gatt_connection_state_changed_cb() + int bt_gatt_connect( + ffi.Pointer address, + bool auto_connect, + ) { + return _bt_gatt_connect( + address, + auto_connect ? 1 : 0, + ); + } + + late final _bt_gatt_connect_ptr = + _lookup>('bt_gatt_connect'); + late final _dart_bt_gatt_connect _bt_gatt_connect = + _bt_gatt_connect_ptr.asFunction<_dart_bt_gatt_connect>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Disconnect to LE connection with the given remote Bluetooth device address, asynchronously. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] address The address of the remote Bluetooth device + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The connection must be established. + /// @post This function invokes bt_gatt_connection_state_changed_cb(). + /// + /// @see bt_initialize() + /// @see bt_gatt_connect() + /// @see bt_gatt_set_connection_state_changed_cb() + /// @see bt_gatt_unset_connection_state_changed_cb() + /// @see bt_gatt_connection_state_changed_cb() + int bt_gatt_disconnect( + ffi.Pointer address, + ) { + return _bt_gatt_disconnect( + address, + ); + } + + late final _bt_gatt_disconnect_ptr = + _lookup>('bt_gatt_disconnect'); + late final _dart_bt_gatt_disconnect _bt_gatt_disconnect = + _bt_gatt_disconnect_ptr.asFunction<_dart_bt_gatt_disconnect>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Registers a callback function that will be invoked when the connection state is changed. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[in] callback The callback function to register. + /// @param[in] user_data The user data to be passed to the callback function. + /// + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_connect() + /// @see bt_gatt_disconnect() + /// @see bt_gatt_unset_connection_state_changed_cb() + int bt_gatt_set_connection_state_changed_cb( + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_set_connection_state_changed_cb( + callback, + user_data, + ); + } + + late final _bt_gatt_set_connection_state_changed_cb_ptr = + _lookup>( + 'bt_gatt_set_connection_state_changed_cb'); + late final _dart_bt_gatt_set_connection_state_changed_cb + _bt_gatt_set_connection_state_changed_cb = + _bt_gatt_set_connection_state_changed_cb_ptr + .asFunction<_dart_bt_gatt_set_connection_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE + /// @brief Unregisters a callback function that will be invoked when the connection state is changed. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_connect() + /// @see bt_gatt_disconnect() + /// @see bt_gatt_connection_state_changed_cb() + int bt_gatt_unset_connection_state_changed_cb() { + return _bt_gatt_unset_connection_state_changed_cb(); + } + + late final _bt_gatt_unset_connection_state_changed_cb_ptr = + _lookup>( + 'bt_gatt_unset_connection_state_changed_cb'); + late final _dart_bt_gatt_unset_connection_state_changed_cb + _bt_gatt_unset_connection_state_changed_cb = + _bt_gatt_unset_connection_state_changed_cb_ptr + .asFunction<_dart_bt_gatt_unset_connection_state_changed_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Destroys the GATT handle of service. + /// @since_tizen 3.0 + /// + /// @param[in] gatt_handle The handle of service + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_service_create() + int bt_gatt_service_destroy( + ffi.Pointer gatt_handle, + ) { + return _bt_gatt_service_destroy( + gatt_handle, + ); + } + + late final _bt_gatt_service_destroy_ptr = + _lookup>( + 'bt_gatt_service_destroy'); + late final _dart_bt_gatt_service_destroy _bt_gatt_service_destroy = + _bt_gatt_service_destroy_ptr.asFunction<_dart_bt_gatt_service_destroy>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Destroys the GATT handle of characteristic. + /// @since_tizen 3.0 + /// + /// @param[in] gatt_handle The handle of characteristic + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_characteristic_create() + int bt_gatt_characteristic_destroy( + ffi.Pointer gatt_handle, + ) { + return _bt_gatt_characteristic_destroy( + gatt_handle, + ); + } + + late final _bt_gatt_characteristic_destroy_ptr = + _lookup>( + 'bt_gatt_characteristic_destroy'); + late final _dart_bt_gatt_characteristic_destroy + _bt_gatt_characteristic_destroy = _bt_gatt_characteristic_destroy_ptr + .asFunction<_dart_bt_gatt_characteristic_destroy>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Destroys the GATT handle of descriptor. + /// @since_tizen 3.0 + /// + /// @param[in] gatt_handle The handle of descriptor + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_descriptor_create() + int bt_gatt_descriptor_destroy( + ffi.Pointer gatt_handle, + ) { + return _bt_gatt_descriptor_destroy( + gatt_handle, + ); + } + + late final _bt_gatt_descriptor_destroy_ptr = + _lookup>( + 'bt_gatt_descriptor_destroy'); + late final _dart_bt_gatt_descriptor_destroy _bt_gatt_descriptor_destroy = + _bt_gatt_descriptor_destroy_ptr + .asFunction<_dart_bt_gatt_descriptor_destroy>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the permissions which a characteristic's GATT handle has. + /// @since_tizen 3.0 + /// + /// @remarks The @a permissions can be one or more values of #bt_gatt_permission_e, combined with bitwise 'or'. + /// + /// @param[in] gatt_handle The handle of a characteristic + /// @param[out] permissions The permissions which a characteristic's GATT handle has + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_characteristic_create() + /// @see bt_gatt_permission_e + int bt_gatt_characteristic_get_permissions( + ffi.Pointer gatt_handle, + ffi.Pointer permissions, + ) { + return _bt_gatt_characteristic_get_permissions( + gatt_handle, + permissions, + ); + } + + late final _bt_gatt_characteristic_get_permissions_ptr = + _lookup>( + 'bt_gatt_characteristic_get_permissions'); + late final _dart_bt_gatt_characteristic_get_permissions + _bt_gatt_characteristic_get_permissions = + _bt_gatt_characteristic_get_permissions_ptr + .asFunction<_dart_bt_gatt_characteristic_get_permissions>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Gets the permissions which a descriptor's GATT handle has. + /// @since_tizen 3.0 + /// + /// @remarks The @a permissions can be one or more values of #bt_gatt_permission_e, combined with bitwise 'or'. + /// + /// @param[in] gatt_handle The handle of a descriptor + /// @param[out] permissions The permissions which a descriptor's GATT handle has + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_descriptor_create() + /// @see bt_gatt_permission_e + int bt_gatt_descriptor_get_permissions( + ffi.Pointer gatt_handle, + ffi.Pointer permissions, + ) { + return _bt_gatt_descriptor_get_permissions( + gatt_handle, + permissions, + ); + } + + late final _bt_gatt_descriptor_get_permissions_ptr = + _lookup>( + 'bt_gatt_descriptor_get_permissions'); + late final _dart_bt_gatt_descriptor_get_permissions + _bt_gatt_descriptor_get_permissions = + _bt_gatt_descriptor_get_permissions_ptr + .asFunction<_dart_bt_gatt_descriptor_get_permissions>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Creates the GATT service. + /// @since_tizen 3.0 + /// + /// @remarks The @a service should be destroyed by using bt_gatt_service_destroy() + /// + /// @param[in] uuid The UUID of the service + /// @param[in] type The type of the service + /// @param[out] service The GATT handle of the created service + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_service_destroy() + int bt_gatt_service_create( + ffi.Pointer uuid, + int type, + ffi.Pointer> service, + ) { + return _bt_gatt_service_create( + uuid, + type, + service, + ); + } + + late final _bt_gatt_service_create_ptr = + _lookup>( + 'bt_gatt_service_create'); + late final _dart_bt_gatt_service_create _bt_gatt_service_create = + _bt_gatt_service_create_ptr.asFunction<_dart_bt_gatt_service_create>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Adds a characteristic to a specified service. + /// @since_tizen 3.0 + /// + /// @param[in] service The service's GATT handle + /// @param[in] characteristic The characteristic's GATT handle to be added + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_service_create() + /// @see bt_gatt_characteristic_create() + int bt_gatt_service_add_characteristic( + ffi.Pointer service, + ffi.Pointer characteristic, + ) { + return _bt_gatt_service_add_characteristic( + service, + characteristic, + ); + } + + late final _bt_gatt_service_add_characteristic_ptr = + _lookup>( + 'bt_gatt_service_add_characteristic'); + late final _dart_bt_gatt_service_add_characteristic + _bt_gatt_service_add_characteristic = + _bt_gatt_service_add_characteristic_ptr + .asFunction<_dart_bt_gatt_service_add_characteristic>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Adds a service to a specified service as included service. + /// @since_tizen 3.0 + /// + /// @param[in] service The service's GATT handle + /// @param[in] included_service The service's GATT handle to be added as included service + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_service_create() + int bt_gatt_service_add_included_service( + ffi.Pointer service, + ffi.Pointer included_service, + ) { + return _bt_gatt_service_add_included_service( + service, + included_service, + ); + } + + late final _bt_gatt_service_add_included_service_ptr = + _lookup>( + 'bt_gatt_service_add_included_service'); + late final _dart_bt_gatt_service_add_included_service + _bt_gatt_service_add_included_service = + _bt_gatt_service_add_included_service_ptr + .asFunction<_dart_bt_gatt_service_add_included_service>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Gets the GATT server handle to which the specified service belongs. + /// @since_tizen 3.0 + /// + /// @remarks The returned Server handle must not be freed by application. + /// + /// @param[in] service The service's GATT handle + /// @param[out] server The GATT server handle to which @a service belongs + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_server_create() + /// @see bt_gatt_service_create() + /// @see bt_gatt_server_register_service() + int bt_gatt_service_get_server( + ffi.Pointer service, + ffi.Pointer> server, + ) { + return _bt_gatt_service_get_server( + service, + server, + ); + } + + late final _bt_gatt_service_get_server_ptr = + _lookup>( + 'bt_gatt_service_get_server'); + late final _dart_bt_gatt_service_get_server _bt_gatt_service_get_server = + _bt_gatt_service_get_server_ptr + .asFunction<_dart_bt_gatt_service_get_server>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Creates the GATT characteristic. + /// @since_tizen 3.0 + /// + /// @remarks The @a permissions can be one or more values of #bt_gatt_permission_e, combined with bitwise 'or'. + /// @remarks The @a properties can be one or more values of #bt_gatt_property_e, combined with bitwise 'or'. + /// @remarks The @a characteristic should be destroyed by using bt_gatt_characteristic_destroy(). + /// + /// @param[in] uuid The UUID of the characteristic + /// @param[in] permissions the permissions of the characteristic + /// @param[in] properties The properties of the characteristic + /// @param[in] value The value(byte stream) of the characteristic + /// @param[in] value_length The length of @a value + /// @param[out] characteristic The GATT handle of the created characteristic + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_characteristic_destroy() + int bt_gatt_characteristic_create( + ffi.Pointer uuid, + int permissions, + int properties, + ffi.Pointer value, + int value_length, + ffi.Pointer> characteristic, + ) { + return _bt_gatt_characteristic_create( + uuid, + permissions, + properties, + value, + value_length, + characteristic, + ); + } + + late final _bt_gatt_characteristic_create_ptr = + _lookup>( + 'bt_gatt_characteristic_create'); + late final _dart_bt_gatt_characteristic_create + _bt_gatt_characteristic_create = _bt_gatt_characteristic_create_ptr + .asFunction<_dart_bt_gatt_characteristic_create>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Adds a descriptor to a specified characteristic. + /// @since_tizen 3.0 + /// + /// @param[in] characteristic The GATT handle of the characteristic + /// @param[in] descriptor The descriptor's GATT handle to be added + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_characteristic_create() + /// @see bt_gatt_descriptor_create() + int bt_gatt_characteristic_add_descriptor( + ffi.Pointer characteristic, + ffi.Pointer descriptor, + ) { + return _bt_gatt_characteristic_add_descriptor( + characteristic, + descriptor, + ); + } + + late final _bt_gatt_characteristic_add_descriptor_ptr = + _lookup>( + 'bt_gatt_characteristic_add_descriptor'); + late final _dart_bt_gatt_characteristic_add_descriptor + _bt_gatt_characteristic_add_descriptor = + _bt_gatt_characteristic_add_descriptor_ptr + .asFunction<_dart_bt_gatt_characteristic_add_descriptor>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE + /// @brief Creates the GATT characteristic descriptor. + /// @since_tizen 3.0 + /// + /// @remarks The @a permissions can be one or more values of #bt_gatt_permission_e, combined with bitwise 'or'. + /// @remarks The @a descriptor should be destroyed by using bt_gatt_descriptor_destroy(). + /// + /// @param[in] uuid The UUID of the descriptor + /// @param[in] permissions The permissions of the descriptor + /// @param[in] value The value(byte stream) associated with the descriptor + /// @param[in] value_length The length of @a value + /// @param[out] descriptor The GATT handle of the created characteristic descriptor + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_descriptor_destroy() + int bt_gatt_descriptor_create( + ffi.Pointer uuid, + int permissions, + ffi.Pointer value, + int value_length, + ffi.Pointer> descriptor, + ) { + return _bt_gatt_descriptor_create( + uuid, + permissions, + value, + value_length, + descriptor, + ); + } + + late final _bt_gatt_descriptor_create_ptr = + _lookup>( + 'bt_gatt_descriptor_create'); + late final _dart_bt_gatt_descriptor_create _bt_gatt_descriptor_create = + _bt_gatt_descriptor_create_ptr + .asFunction<_dart_bt_gatt_descriptor_create>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Initializes the GATT Server. + /// @since_tizen 3.0 + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @see bt_gatt_server_deinitialize() + int bt_gatt_server_initialize() { + return _bt_gatt_server_initialize(); + } + + late final _bt_gatt_server_initialize_ptr = + _lookup>( + 'bt_gatt_server_initialize'); + late final _dart_bt_gatt_server_initialize _bt_gatt_server_initialize = + _bt_gatt_server_initialize_ptr + .asFunction<_dart_bt_gatt_server_initialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief DeInitializes the GATT server. + /// @since_tizen 3.0 + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of local Bluetooth must be #BT_ADAPTER_ENABLED. + /// @see bt_gatt_server_initialize() + int bt_gatt_server_deinitialize() { + return _bt_gatt_server_deinitialize(); + } + + late final _bt_gatt_server_deinitialize_ptr = + _lookup>( + 'bt_gatt_server_deinitialize'); + late final _dart_bt_gatt_server_deinitialize _bt_gatt_server_deinitialize = + _bt_gatt_server_deinitialize_ptr + .asFunction<_dart_bt_gatt_server_deinitialize>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Creates the GATT server's handle. + /// @since_tizen 3.0 + /// + /// @remarks The @a server handle should be destroyed by using bt_gatt_server_destroy() + /// + /// @param[out] server The GATT server's handle + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_server_destroy() + int bt_gatt_server_create( + ffi.Pointer> server, + ) { + return _bt_gatt_server_create( + server, + ); + } + + late final _bt_gatt_server_create_ptr = + _lookup>( + 'bt_gatt_server_create'); + late final _dart_bt_gatt_server_create _bt_gatt_server_create = + _bt_gatt_server_create_ptr.asFunction<_dart_bt_gatt_server_create>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Destroys the GATT server's handle. + /// @since_tizen 3.0 + /// + /// @remarks All registered services to GATT server are unregistered + /// + /// @param[in] server The GATT server's handle + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_server_create() + int bt_gatt_server_destroy( + ffi.Pointer server, + ) { + return _bt_gatt_server_destroy( + server, + ); + } + + late final _bt_gatt_server_destroy_ptr = + _lookup>( + 'bt_gatt_server_destroy'); + late final _dart_bt_gatt_server_destroy _bt_gatt_server_destroy = + _bt_gatt_server_destroy_ptr.asFunction<_dart_bt_gatt_server_destroy>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Registers a callback function to be invoked when a read request for a specified characteristic or descriptor is issued from a remote device(GATT client). + /// @since_tizen 3.0 + /// + /// @param[in] gatt_handle The GATT handle of a characteristic or descriptor + /// @param[in] callback The callback to be invoked + /// @param[in] user_data The user data to be passed to @a callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_server_read_value_requested_cb() + /// @see bt_gatt_server_send_response() + int bt_gatt_server_set_read_value_requested_cb( + ffi.Pointer gatt_handle, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_server_set_read_value_requested_cb( + gatt_handle, + callback, + user_data, + ); + } + + late final _bt_gatt_server_set_read_value_requested_cb_ptr = _lookup< + ffi.NativeFunction<_c_bt_gatt_server_set_read_value_requested_cb>>( + 'bt_gatt_server_set_read_value_requested_cb'); + late final _dart_bt_gatt_server_set_read_value_requested_cb + _bt_gatt_server_set_read_value_requested_cb = + _bt_gatt_server_set_read_value_requested_cb_ptr + .asFunction<_dart_bt_gatt_server_set_read_value_requested_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Registers a callback function to be invoked when the remote device enables or disables the Notification/Indication for particular characteristics. + /// @since_tizen 3.0 + /// + /// @param[in] gatt_handle The GATT handle of a characteristic + /// @param[in] callback The callback to be invoked + /// @param[in] user_data The user data to be passed to @a callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_server_characteristic_notification_state_changed_cb() + int bt_gatt_server_set_characteristic_notification_state_change_cb( + ffi.Pointer gatt_handle, + ffi.Pointer< + ffi.NativeFunction< + bt_gatt_server_characteristic_notification_state_changed_cb>> + callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_server_set_characteristic_notification_state_change_cb( + gatt_handle, + callback, + user_data, + ); + } + + late final _bt_gatt_server_set_characteristic_notification_state_change_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_bt_gatt_server_set_characteristic_notification_state_change_cb>>( + 'bt_gatt_server_set_characteristic_notification_state_change_cb'); + late final _dart_bt_gatt_server_set_characteristic_notification_state_change_cb + _bt_gatt_server_set_characteristic_notification_state_change_cb = + _bt_gatt_server_set_characteristic_notification_state_change_cb_ptr + .asFunction< + _dart_bt_gatt_server_set_characteristic_notification_state_change_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Registers a callback function to be invoked when a value of a characteristic or descriptor has been changed by a remote device(GATT client)'s request. + /// @since_tizen 3.0 + /// + /// @param[in] gatt_handle The GATT handle of a characteristic or descriptor + /// @param[in] callback The callback to be invoked + /// @param[in] user_data The user data to be passed to @a callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_server_write_value_requested_cb() + int bt_gatt_server_set_write_value_requested_cb( + ffi.Pointer gatt_handle, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_server_set_write_value_requested_cb( + gatt_handle, + callback, + user_data, + ); + } + + late final _bt_gatt_server_set_write_value_requested_cb_ptr = _lookup< + ffi.NativeFunction<_c_bt_gatt_server_set_write_value_requested_cb>>( + 'bt_gatt_server_set_write_value_requested_cb'); + late final _dart_bt_gatt_server_set_write_value_requested_cb + _bt_gatt_server_set_write_value_requested_cb = + _bt_gatt_server_set_write_value_requested_cb_ptr + .asFunction<_dart_bt_gatt_server_set_write_value_requested_cb>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Registers a specified service to the specified GATT server that the local device is hosting. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] server The GATT server that local device is hosting + /// @param[in] service The service, which needs to be registered in @a server + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_ALREADY_DONE Operation is already done + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_server_create() + /// @see bt_gatt_service_create() + /// @see bt_gatt_server_start() + /// @see bt_gatt_server_unregister_service() + int bt_gatt_server_register_service( + ffi.Pointer server, + ffi.Pointer service, + ) { + return _bt_gatt_server_register_service( + server, + service, + ); + } + + late final _bt_gatt_server_register_service_ptr = + _lookup>( + 'bt_gatt_server_register_service'); + late final _dart_bt_gatt_server_register_service + _bt_gatt_server_register_service = _bt_gatt_server_register_service_ptr + .asFunction<_dart_bt_gatt_server_register_service>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Unregisters a specified service from the specified GATT server that the local device is hosting. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] server The GATT server that local device is hosting + /// @param[in] service The service, which needs to be unregistered from @a server + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_SERVICE_NOT_FOUND Service not found + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_server_register_service() + int bt_gatt_server_unregister_service( + ffi.Pointer server, + ffi.Pointer service, + ) { + return _bt_gatt_server_unregister_service( + server, + service, + ); + } + + late final _bt_gatt_server_unregister_service_ptr = + _lookup>( + 'bt_gatt_server_unregister_service'); + late final _dart_bt_gatt_server_unregister_service + _bt_gatt_server_unregister_service = + _bt_gatt_server_unregister_service_ptr + .asFunction<_dart_bt_gatt_server_unregister_service>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Unregisters all services from the specified GATT server that the local device is hosting. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] server The GATT server that local device is hosting + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_server_register_service() + int bt_gatt_server_unregister_all_services( + ffi.Pointer server, + ) { + return _bt_gatt_server_unregister_all_services( + server, + ); + } + + late final _bt_gatt_server_unregister_all_services_ptr = + _lookup>( + 'bt_gatt_server_unregister_all_services'); + late final _dart_bt_gatt_server_unregister_all_services + _bt_gatt_server_unregister_all_services = + _bt_gatt_server_unregister_all_services_ptr + .asFunction<_dart_bt_gatt_server_unregister_all_services>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Registers the application along with the GATT services of the application it is hosting. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_ALREADY_DONE Operation is already done + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_server_initialize() + /// @see bt_gatt_server_create() + /// @see bt_gatt_service_create() + /// @see bt_gatt_server_unregister_service() + int bt_gatt_server_start() { + return _bt_gatt_server_start(); + } + + late final _bt_gatt_server_start_ptr = + _lookup>( + 'bt_gatt_server_start'); + late final _dart_bt_gatt_server_start _bt_gatt_server_start = + _bt_gatt_server_start_ptr.asFunction<_dart_bt_gatt_server_start>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Sends a response to the remote device as a result of a read/write request. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @remarks Until this function is called, a read/write request is not finished. + /// + /// @param[in] request_id The identification of a read/write request + /// @param[in] request_type The request type for read/write + /// @param[in] offset The offset from where a value is read + /// @param[in] resp_status The application error if any occurred or BT_ERROR_NONE for successful. + /// @param[in] value The value to be sent. It will be sent from @a offset. If it is NULL, a requested GATT handle's value will be sent from @a offset. + /// @param[in] value_length Value Length + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_server_read_value_requested_cb() + int bt_gatt_server_send_response( + int request_id, + int request_type, + int offset, + int resp_status, + ffi.Pointer value, + int value_length, + ) { + return _bt_gatt_server_send_response( + request_id, + request_type, + offset, + resp_status, + value, + value_length, + ); + } + + late final _bt_gatt_server_send_response_ptr = + _lookup>( + 'bt_gatt_server_send_response'); + late final _dart_bt_gatt_server_send_response _bt_gatt_server_send_response = + _bt_gatt_server_send_response_ptr + .asFunction<_dart_bt_gatt_server_send_response>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Notifies value change of the characteristic to the remote devices which enable a Client Characteristic Configuration Descriptor. + /// @since_tizen 3.0 + /// + /// @param[in] characteristic The characteristic which has a changed value + /// @param[in] callback The function to be invoked on each remote device when a sending operation is done + /// @param[in] device_address Remote device address to send notify or indicate and if set to NULL then notify/indicate all is enabled. + /// @param[in] user_data The user data to be passed to @a callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_server_notification_sent_cb() + int bt_gatt_server_notify_characteristic_changed_value( + ffi.Pointer characteristic, + ffi.Pointer> + callback, + ffi.Pointer device_address, + ffi.Pointer user_data, + ) { + return _bt_gatt_server_notify_characteristic_changed_value( + characteristic, + callback, + device_address, + user_data, + ); + } + + late final _bt_gatt_server_notify_characteristic_changed_value_ptr = _lookup< + ffi.NativeFunction< + _c_bt_gatt_server_notify_characteristic_changed_value>>( + 'bt_gatt_server_notify_characteristic_changed_value'); + late final _dart_bt_gatt_server_notify_characteristic_changed_value + _bt_gatt_server_notify_characteristic_changed_value = + _bt_gatt_server_notify_characteristic_changed_value_ptr.asFunction< + _dart_bt_gatt_server_notify_characteristic_changed_value>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Gets a service's GATT handle which has specific UUID. + /// @since_tizen 3.0 + /// + /// @remark The returned GATT handle must not be freed by application. + /// It will be freed when an associated server is destroyed by bt_gatt_server_destroy(). + /// If there are multiple services which have same UUID, only the first matched one will be returned. + /// + /// @param[in] server The GATT server's handle + /// @param[in] uuid The service's GATT handle which has this UUID will be returned if it exists + /// @param[out] service The service's GATT handle which has @a uuid if it exists + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NO_DATA No data available + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + int bt_gatt_server_get_service( + ffi.Pointer server, + ffi.Pointer uuid, + ffi.Pointer> service, + ) { + return _bt_gatt_server_get_service( + server, + uuid, + service, + ); + } + + late final _bt_gatt_server_get_service_ptr = + _lookup>( + 'bt_gatt_server_get_service'); + late final _dart_bt_gatt_server_get_service _bt_gatt_server_get_service = + _bt_gatt_server_get_service_ptr + .asFunction<_dart_bt_gatt_server_get_service>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE + /// @brief Invokes @a callback function on each service that belongs to the specified GATT server. + /// @since_tizen 3.0 + /// + /// @param[in] server The GATT server's handle + /// @param[in] callback The function to be invoked on each service + /// @param[in] user_data The user data to be passed to @a callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @see bt_gatt_foreach_cb() + int bt_gatt_server_foreach_services( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_gatt_server_foreach_services( + server, + callback, + user_data, + ); + } + + late final _bt_gatt_server_foreach_services_ptr = + _lookup>( + 'bt_gatt_server_foreach_services'); + late final _dart_bt_gatt_server_foreach_services + _bt_gatt_server_foreach_services = _bt_gatt_server_foreach_services_ptr + .asFunction<_dart_bt_gatt_server_foreach_services>(); + + /// @WEARABLE_ONLY + /// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE + /// @brief Initializes the Bluetooth PBAP Client. + /// @details This initialization is necessary to call other PBAP client APIs. + /// @since_tizen 3.0 + /// + /// @remarks This function must be called to initialize Bluetooth PBAP client. You must free all resources of the Bluetooth service + /// by calling bt_pbap_client_deinitialize() if Bluetooth PBAP Client is no longer needed. + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of the local Bluetooth adapter must be #BT_ADAPTER_ENABLED. + /// + /// @see bt_pbap_client_deinitialize() + /// @see bt_pbap_client_connect() + /// @see bt_pbap_client_disconnect() + /// @see bt_pbap_client_get_phone_book_size() + /// @see bt_pbap_client_get_phone_book() + /// @see bt_pbap_client_get_list() + /// @see bt_pbap_client_pull_vcard() + /// @see bt_pbap_client_search_phone_book() + int bt_pbap_client_initialize() { + return _bt_pbap_client_initialize(); + } + + late final _bt_pbap_client_initialize_ptr = + _lookup>( + 'bt_pbap_client_initialize'); + late final _dart_bt_pbap_client_initialize _bt_pbap_client_initialize = + _bt_pbap_client_initialize_ptr + .asFunction<_dart_bt_pbap_client_initialize>(); + + /// @WEARABLE_ONLY + /// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE + /// @brief Deinitializes the Bluetooth PBAP Client. + /// @details This deinitialization must be done to free resources when the PBAP client is not longer needed. + /// @since_tizen 3.0 + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOT_ENABLED Not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of the local Bluetooth adapter must be #BT_ADAPTER_ENABLED. + /// The PBAP client must be initialized with bt_pbap_client_initialize(). + /// @see bt_pbap_client_deinitialize() + /// @see bt_pbap_client_connect() + /// @see bt_pbap_client_disconnect() + /// @see bt_pbap_client_get_phone_book_size() + /// @see bt_pbap_client_get_phone_book() + /// @see bt_pbap_client_get_list() + /// @see bt_pbap_client_pull_vcard() + /// @see bt_pbap_client_search_phone_book() + int bt_pbap_client_deinitialize() { + return _bt_pbap_client_deinitialize(); + } + + late final _bt_pbap_client_deinitialize_ptr = + _lookup>( + 'bt_pbap_client_deinitialize'); + late final _dart_bt_pbap_client_deinitialize _bt_pbap_client_deinitialize = + _bt_pbap_client_deinitialize_ptr + .asFunction<_dart_bt_pbap_client_deinitialize>(); + + /// @WEARABLE_ONLY + /// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE + /// @brief Registers a callback function that will be invoked when the connection state is changed. + /// @since_tizen 3.0 + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The PBAP client must be initialized with bt_pbap_client_initialize(). + /// @see bt_pbap_client_initialize() + int bt_pbap_client_set_connection_state_changed_cb( + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _bt_pbap_client_set_connection_state_changed_cb( + callback, + user_data, + ); + } + + late final _bt_pbap_client_set_connection_state_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_bt_pbap_client_set_connection_state_changed_cb>>( + 'bt_pbap_client_set_connection_state_changed_cb'); + late final _dart_bt_pbap_client_set_connection_state_changed_cb + _bt_pbap_client_set_connection_state_changed_cb = + _bt_pbap_client_set_connection_state_changed_cb_ptr + .asFunction<_dart_bt_pbap_client_set_connection_state_changed_cb>(); + + /// @WEARABLE_ONLY + /// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE + /// @brief Unregisters a callback function that will be invoked when the connection state is changed. + /// @since_tizen 3.0 + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The PBAP client must be initialized with bt_pbap_client_initialize(). + /// @see bt_pbap_client_initialize() + int bt_pbap_client_unset_connection_state_changed_cb() { + return _bt_pbap_client_unset_connection_state_changed_cb(); + } + + late final _bt_pbap_client_unset_connection_state_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_bt_pbap_client_unset_connection_state_changed_cb>>( + 'bt_pbap_client_unset_connection_state_changed_cb'); + late final _dart_bt_pbap_client_unset_connection_state_changed_cb + _bt_pbap_client_unset_connection_state_changed_cb = + _bt_pbap_client_unset_connection_state_changed_cb_ptr + .asFunction<_dart_bt_pbap_client_unset_connection_state_changed_cb>(); + + /// @WEARABLE_ONLY + /// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE + /// @brief Connects to PBAP server, asynchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/bluetooth + /// + /// @param[in] address The other device's address + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Adapter is not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of the local Bluetooth adapter must be #BT_ADAPTER_ENABLED. + /// @pre The PBAP client must be initialized with bt_pbap_client_initialize(). + /// @pre The local device must be bonded with the remote device by bt_device_create_bond(). + /// @post bt_pbap_connection_state_changed_cb() will be invoked. + /// @see bt_pbap_client_disconnect() + /// @see bt_pbap_client_set_connection_state_changed_cb() + int bt_pbap_client_connect( + ffi.Pointer address, + ) { + return _bt_pbap_client_connect( + address, + ); + } + + late final _bt_pbap_client_connect_ptr = + _lookup>( + 'bt_pbap_client_connect'); + late final _dart_bt_pbap_client_connect _bt_pbap_client_connect = + _bt_pbap_client_connect_ptr.asFunction<_dart_bt_pbap_client_connect>(); + + /// @WEARABLE_ONLY + /// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE + /// @brief Disconnects from PBAP server, asynchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/bluetooth + /// + /// @param[in] address The other device's address + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Adapter is not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of the local Bluetooth adapter must be #BT_ADAPTER_ENABLED. + /// @pre The PBAP client must be initialized with bt_pbap_client_initialize(). + /// @pre PBAP connection must be created with bt_pbap_client_connect(). + /// @post bt_pbap_connection_state_changed_cb() will be invoked. + /// @see bt_pbap_client_connect() + /// @see bt_pbap_client_set_connection_state_changed_cb() + int bt_pbap_client_disconnect( + ffi.Pointer address, + ) { + return _bt_pbap_client_disconnect( + address, + ); + } + + late final _bt_pbap_client_disconnect_ptr = + _lookup>( + 'bt_pbap_client_disconnect'); + late final _dart_bt_pbap_client_disconnect _bt_pbap_client_disconnect = + _bt_pbap_client_disconnect_ptr + .asFunction<_dart_bt_pbap_client_disconnect>(); + + /// @WEARABLE_ONLY + /// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE + /// @brief Gets size of phone book from PBAP server, asynchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/bluetooth + /// + /// @param[in] address The other device's address + /// @param[in] source Source of the phone book (Phone/SIM) + /// @param[in] folder_type Type of folder + /// @param[in] callback The callback function called when PBAP phone book size is returned. + /// @param[in] user_data Data to be passed to the PBAP phone book size callback. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Adapter is not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of the local Bluetooth adapter must be #BT_ADAPTER_ENABLED. + /// @pre The PBAP client must be initialized with bt_pbap_client_initialize(). + /// @pre PBAP connection must be created with bt_pbap_client_connect(). + /// + /// @see bt_pbap_client_connect() + int bt_pbap_client_get_phone_book_size( + ffi.Pointer address, + int source, + int folder_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_pbap_client_get_phone_book_size( + address, + source, + folder_type, + callback, + user_data, + ); + } + + late final _bt_pbap_client_get_phone_book_size_ptr = + _lookup>( + 'bt_pbap_client_get_phone_book_size'); + late final _dart_bt_pbap_client_get_phone_book_size + _bt_pbap_client_get_phone_book_size = + _bt_pbap_client_get_phone_book_size_ptr + .asFunction<_dart_bt_pbap_client_get_phone_book_size>(); + + /// @WEARABLE_ONLY + /// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE + /// @brief Gets all contacts and call logs as vCard from PBAP server, asynchronously. + /// @details The received phone book file will be saved in the platform downloads folder. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/bluetooth + /// http://tizen.org/privilege/mediastorage + /// + /// @param[in] address The other device's address + /// @param[in] source Source of phone book (Phone/SIM) + /// @param[in] folder_type Type of folder + /// @param[in] format The vCard format + /// @param[in] order Specifies which field shall be used to sort vCards. + /// @param[in] offset The number of vCards to be excluded, counting from the beginning + /// @param[in] max_list_count The maximum number of vCards to be fetched + /// @param[in] fields vCard fields to be fetched; one or more #bt_pbap_field_e values combined with bitwise 'or' + /// @param[in] callback The callback function called when PBAP phone book is Pulled. + /// @param[in] user_data Data to be passed to the PBAP phone book pulling callback. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Adapter is not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of the local Bluetooth adapter must be #BT_ADAPTER_ENABLED. + /// @pre The PBAP client must be initialized with bt_pbap_client_initialize(). + /// @pre PBAP connection must be created with bt_pbap_client_connect(). + /// + /// @see bt_pbap_client_connect() + int bt_pbap_client_get_phone_book( + ffi.Pointer address, + int source, + int folder_type, + int format, + int order, + int offset, + int max_list_count, + int fields, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_pbap_client_get_phone_book( + address, + source, + folder_type, + format, + order, + offset, + max_list_count, + fields, + callback, + user_data, + ); + } + + late final _bt_pbap_client_get_phone_book_ptr = + _lookup>( + 'bt_pbap_client_get_phone_book'); + late final _dart_bt_pbap_client_get_phone_book + _bt_pbap_client_get_phone_book = _bt_pbap_client_get_phone_book_ptr + .asFunction<_dart_bt_pbap_client_get_phone_book>(); + + /// @WEARABLE_ONLY + /// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE + /// @brief Gets contact and call log information from the PBAP server, asynchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/bluetooth + /// + /// @param[in] address The other device's address + /// @param[in] source Source of phone book (Phone/SIM) + /// @param[in] folder_type Type of folder + /// @param[in] order Specifies which field shall be used to sort vCards. + /// @param[in] offset vCards to be excluded from beginning. + /// @param[in] max_list_count Maximum number of vCards to be fetched + /// @param[in] callback The callback function called when PBAP List is returned. + /// @param[in] user_data Data to be passed to the PBAP phone book pulling callback. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Adapter is not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of the local Bluetooth adapter must be #BT_ADAPTER_ENABLED. + /// @pre The PBAP client must be initialized with bt_pbap_client_initialize(). + /// @pre PBAP connection must be created with bt_pbap_client_connect(). + /// + /// @see bt_pbap_client_connect() + int bt_pbap_client_get_list( + ffi.Pointer address, + int source, + int folder_type, + int order, + int offset, + int max_list_count, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_pbap_client_get_list( + address, + source, + folder_type, + order, + offset, + max_list_count, + callback, + user_data, + ); + } + + late final _bt_pbap_client_get_list_ptr = + _lookup>( + 'bt_pbap_client_get_list'); + late final _dart_bt_pbap_client_get_list _bt_pbap_client_get_list = + _bt_pbap_client_get_list_ptr.asFunction<_dart_bt_pbap_client_get_list>(); + + /// @WEARABLE_ONLY + /// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE + /// @brief Gets the selected contact using the index parameter as vCard from PBAP server, asynchronously. + /// @details The received phone book file will be saved in the platform downloads folder. + /// The @a index value should be equal to the value of the @a index field in the #bt_pbap_vcard_info_s structure, + /// which can be obtained with bt_pbap_client_get_list() or bt_pbap_client_search_phone_book(). + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/bluetooth + /// http://tizen.org/privilege/mediastorage + /// + /// @param[in] address The other device's address + /// @param[in] source Source of phone book (Phone/SIM) + /// @param[in] folder_type Type of folder + /// @param[in] index The handle index of vCard to be fetched + /// @param[in] format Format of vCard + /// @param[in] fields vCard fields to be fetched; one or more #bt_pbap_field_e values combined with bitwise 'or' + /// @param[in] callback The callback function called when PBAP phone book is Pulled. + /// @param[in] user_data Data to be passed to the PBAP phone book Pulling callback. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Adapter is not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of the local Bluetooth adapter must be #BT_ADAPTER_ENABLED. + /// @pre The PBAP client must be initialized with bt_pbap_client_initialize(). + /// @pre PBAP connection must be created with bt_pbap_client_connect(). + /// @pre The vCard information (#bt_pbap_vcard_info_s) must be obtained with bt_pbap_client_get_list() or bt_pbap_client_search_phone_book(). + /// @see bt_pbap_client_connect() + /// @see bt_pbap_client_get_list() + /// @see bt_pbap_client_search_phone_book() + int bt_pbap_client_pull_vcard( + ffi.Pointer address, + int source, + int folder_type, + int index, + int format, + int fields, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_pbap_client_pull_vcard( + address, + source, + folder_type, + index, + format, + fields, + callback, + user_data, + ); + } + + late final _bt_pbap_client_pull_vcard_ptr = + _lookup>( + 'bt_pbap_client_pull_vcard'); + late final _dart_bt_pbap_client_pull_vcard _bt_pbap_client_pull_vcard = + _bt_pbap_client_pull_vcard_ptr + .asFunction<_dart_bt_pbap_client_pull_vcard>(); + + /// @WEARABLE_ONLY + /// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE + /// @brief Finds and fetches the contact and call log information from the PBAP server, asynchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/bluetooth + /// + /// @param[in] address The other device's address + /// @param[in] source Source of phone book (Phone/SIM) + /// @param[in] folder_type Type of folder + /// @param[in] search_attribute field to be search + /// @param[in] search_value pattern to be searched for + /// @param[in] order Specifies which field shall be used to sort vCards. + /// @param[in] offset vCards to be excluded from beginning. + /// @param[in] max_list_count Maximum number of vCards to be fetched + /// @param[in] callback The callback function called when PBAP List is returned. + /// @param[in] user_data Data to be passed to the PBAP phone book pulling callback. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_ENABLED Adapter is not enabled + /// @retval #BT_ERROR_OPERATION_FAILED Operation failed + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The state of the local Bluetooth adapter must be #BT_ADAPTER_ENABLED. + /// @pre The PBAP client must be initialized with bt_pbap_client_initialize(). + /// @pre PBAP connection must be created with bt_pbap_client_connect(). + /// + /// @see bt_pbap_client_connect() + int bt_pbap_client_search_phone_book( + ffi.Pointer address, + int source, + int folder_type, + int search_attribute, + ffi.Pointer search_value, + int order, + int offset, + int max_list_count, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _bt_pbap_client_search_phone_book( + address, + source, + folder_type, + search_attribute, + search_value, + order, + offset, + max_list_count, + callback, + user_data, + ); + } + + late final _bt_pbap_client_search_phone_book_ptr = + _lookup>( + 'bt_pbap_client_search_phone_book'); + late final _dart_bt_pbap_client_search_phone_book + _bt_pbap_client_search_phone_book = _bt_pbap_client_search_phone_book_ptr + .asFunction<_dart_bt_pbap_client_search_phone_book>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Creates a scan filter to find only LE advertisements which match specific requirements. + /// @details If the filter's attribute is not set, then the filter will accept + /// all values of that attribute. If an attribute is set, the filter + /// will accept only advertisements which match the set attribute. + /// + /// For example, if device name is set with + /// bt_adapter_le_scan_filter_set_device_name(), the filter will accept + /// only advertisements from devices with the given name. If device name + /// is not set, advertisements will be filtered without regard to device + /// names. + /// @since_tizen 4.0 + /// + /// @remarks The @a scan_filter should be destroyed with bt_adapter_le_scan_filter_destroy(). + /// + /// @param[out] scan_filter The scan filter handle + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_scan_filter_destroy() + int bt_adapter_le_scan_filter_create( + ffi.Pointer> scan_filter, + ) { + return _bt_adapter_le_scan_filter_create( + scan_filter, + ); + } + + late final _bt_adapter_le_scan_filter_create_ptr = + _lookup>( + 'bt_adapter_le_scan_filter_create'); + late final _dart_bt_adapter_le_scan_filter_create + _bt_adapter_le_scan_filter_create = _bt_adapter_le_scan_filter_create_ptr + .asFunction<_dart_bt_adapter_le_scan_filter_create>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Destroys a scan filter. + /// @since_tizen 4.0 + /// + /// @param[in] scan_filter The scan filter handle + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + /// + /// @see bt_adapter_le_scan_filter_create() + int bt_adapter_le_scan_filter_destroy( + ffi.Pointer scan_filter, + ) { + return _bt_adapter_le_scan_filter_destroy( + scan_filter, + ); + } + + late final _bt_adapter_le_scan_filter_destroy_ptr = + _lookup>( + 'bt_adapter_le_scan_filter_destroy'); + late final _dart_bt_adapter_le_scan_filter_destroy + _bt_adapter_le_scan_filter_destroy = + _bt_adapter_le_scan_filter_destroy_ptr + .asFunction<_dart_bt_adapter_le_scan_filter_destroy>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Sets the device address for the advertisements filter. + /// @since_tizen 4.0 + /// + /// @param[in] scan_filter The scan filter handle + /// @param[in] address The device address by which advertisements will be filtered + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + int bt_adapter_le_scan_filter_set_device_address( + ffi.Pointer scan_filter, + ffi.Pointer address, + ) { + return _bt_adapter_le_scan_filter_set_device_address( + scan_filter, + address, + ); + } + + late final _bt_adapter_le_scan_filter_set_device_address_ptr = _lookup< + ffi.NativeFunction<_c_bt_adapter_le_scan_filter_set_device_address>>( + 'bt_adapter_le_scan_filter_set_device_address'); + late final _dart_bt_adapter_le_scan_filter_set_device_address + _bt_adapter_le_scan_filter_set_device_address = + _bt_adapter_le_scan_filter_set_device_address_ptr + .asFunction<_dart_bt_adapter_le_scan_filter_set_device_address>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Sets the device name for the advertisements filter. + /// @details Any previously set value will be overwritten. + /// @since_tizen 4.0 + /// + /// @param[in] scan_filter The scan filter handle + /// @param[in] name The device name by which advertisements will be filtered + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + int bt_adapter_le_scan_filter_set_device_name( + ffi.Pointer scan_filter, + ffi.Pointer name, + ) { + return _bt_adapter_le_scan_filter_set_device_name( + scan_filter, + name, + ); + } + + late final _bt_adapter_le_scan_filter_set_device_name_ptr = + _lookup>( + 'bt_adapter_le_scan_filter_set_device_name'); + late final _dart_bt_adapter_le_scan_filter_set_device_name + _bt_adapter_le_scan_filter_set_device_name = + _bt_adapter_le_scan_filter_set_device_name_ptr + .asFunction<_dart_bt_adapter_le_scan_filter_set_device_name>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Sets the service UUID for the advertisements filter. + /// @details Any previously set value will be overwritten. + /// @since_tizen 4.0 + /// + /// @param[in] scan_filter The scan filter handle + /// @param[in] uuid The service UUID by which advertisements will be filtered + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + int bt_adapter_le_scan_filter_set_service_uuid( + ffi.Pointer scan_filter, + ffi.Pointer uuid, + ) { + return _bt_adapter_le_scan_filter_set_service_uuid( + scan_filter, + uuid, + ); + } + + late final _bt_adapter_le_scan_filter_set_service_uuid_ptr = _lookup< + ffi.NativeFunction<_c_bt_adapter_le_scan_filter_set_service_uuid>>( + 'bt_adapter_le_scan_filter_set_service_uuid'); + late final _dart_bt_adapter_le_scan_filter_set_service_uuid + _bt_adapter_le_scan_filter_set_service_uuid = + _bt_adapter_le_scan_filter_set_service_uuid_ptr + .asFunction<_dart_bt_adapter_le_scan_filter_set_service_uuid>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Sets the service UUID and the mask for the advertisements filter, + /// to use for filtering by partial data. + /// @details Any previously set value will be overwritten. The mask works as follows: + /// For each bit set to 1 in the mask, the corresponding bits in @a uuid + /// and in the filtered data will have to be equal. If the mask bit is set to 0, + /// the corresponding bits will be ignored. + /// @since_tizen 4.0 + /// + /// @remarks The @a mask and the service @a uuid must have equal lengths. + /// + /// @param[in] scan_filter The scan filter handle + /// @param[in] uuid The service UUID by which advertisements will be filtered + /// @param[in] mask The mask to filter advertisements + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + int bt_adapter_le_scan_filter_set_service_uuid_with_mask( + ffi.Pointer scan_filter, + ffi.Pointer uuid, + ffi.Pointer mask, + ) { + return _bt_adapter_le_scan_filter_set_service_uuid_with_mask( + scan_filter, + uuid, + mask, + ); + } + + late final _bt_adapter_le_scan_filter_set_service_uuid_with_mask_ptr = + _lookup< + ffi.NativeFunction< + _c_bt_adapter_le_scan_filter_set_service_uuid_with_mask>>( + 'bt_adapter_le_scan_filter_set_service_uuid_with_mask'); + late final _dart_bt_adapter_le_scan_filter_set_service_uuid_with_mask + _bt_adapter_le_scan_filter_set_service_uuid_with_mask = + _bt_adapter_le_scan_filter_set_service_uuid_with_mask_ptr.asFunction< + _dart_bt_adapter_le_scan_filter_set_service_uuid_with_mask>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Sets the service solicitation UUID for the advertisements filter. + /// @details Any previously set value will be overwritten. + /// @since_tizen 4.0 + /// + /// @param[in] scan_filter The scan filter handle + /// @param[in] uuid The service solicitation UUID by which advertisements will be filtered + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + int bt_adapter_le_scan_filter_set_service_solicitation_uuid( + ffi.Pointer scan_filter, + ffi.Pointer uuid, + ) { + return _bt_adapter_le_scan_filter_set_service_solicitation_uuid( + scan_filter, + uuid, + ); + } + + late final _bt_adapter_le_scan_filter_set_service_solicitation_uuid_ptr = + _lookup< + ffi.NativeFunction< + _c_bt_adapter_le_scan_filter_set_service_solicitation_uuid>>( + 'bt_adapter_le_scan_filter_set_service_solicitation_uuid'); + late final _dart_bt_adapter_le_scan_filter_set_service_solicitation_uuid + _bt_adapter_le_scan_filter_set_service_solicitation_uuid = + _bt_adapter_le_scan_filter_set_service_solicitation_uuid_ptr.asFunction< + _dart_bt_adapter_le_scan_filter_set_service_solicitation_uuid>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Sets the service solicitation UUID and the mask for the advertisements filter, + /// to use for filtering by partial data. + /// @details Any previously set value will be overwritten. The mask works as follows: + /// For each bit set to 1 in the mask, the corresponding bits in @a uuid + /// and in the filtered data will have to be equal. If the mask bit is set to 0, + /// the corresponding bits will be ignored. + /// @since_tizen 4.0 + /// + /// @remarks The @a mask and the service solicitation @a uuid must have equal lengths. + /// + /// @param[in] scan_filter The scan filter handle + /// @param[in] uuid The service solicitation UUID by which advertisements will be filtered + /// @param[in] mask The mask by which advertisements will be filtered + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + int bt_adapter_le_scan_filter_set_service_solicitation_uuid_with_mask( + ffi.Pointer scan_filter, + ffi.Pointer uuid, + ffi.Pointer mask, + ) { + return _bt_adapter_le_scan_filter_set_service_solicitation_uuid_with_mask( + scan_filter, + uuid, + mask, + ); + } + + late final _bt_adapter_le_scan_filter_set_service_solicitation_uuid_with_mask_ptr = + _lookup< + ffi.NativeFunction< + _c_bt_adapter_le_scan_filter_set_service_solicitation_uuid_with_mask>>( + 'bt_adapter_le_scan_filter_set_service_solicitation_uuid_with_mask'); + late final _dart_bt_adapter_le_scan_filter_set_service_solicitation_uuid_with_mask + _bt_adapter_le_scan_filter_set_service_solicitation_uuid_with_mask = + _bt_adapter_le_scan_filter_set_service_solicitation_uuid_with_mask_ptr + .asFunction< + _dart_bt_adapter_le_scan_filter_set_service_solicitation_uuid_with_mask>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Sets the service data for the advertisements filter. + /// @details Any previously set value will be overwritten. + /// @since_tizen 4.0 + /// + /// @param[in] scan_filter The scan filter handle + /// @param[in] uuid The service UUID by which advertisements will be filtered + /// @param[in] data The service data by which advertisements will be filtered + /// @param[in] data_len The length of the service data + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + int bt_adapter_le_scan_filter_set_service_data( + ffi.Pointer scan_filter, + ffi.Pointer uuid, + ffi.Pointer data, + int data_len, + ) { + return _bt_adapter_le_scan_filter_set_service_data( + scan_filter, + uuid, + data, + data_len, + ); + } + + late final _bt_adapter_le_scan_filter_set_service_data_ptr = _lookup< + ffi.NativeFunction<_c_bt_adapter_le_scan_filter_set_service_data>>( + 'bt_adapter_le_scan_filter_set_service_data'); + late final _dart_bt_adapter_le_scan_filter_set_service_data + _bt_adapter_le_scan_filter_set_service_data = + _bt_adapter_le_scan_filter_set_service_data_ptr + .asFunction<_dart_bt_adapter_le_scan_filter_set_service_data>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Sets the service data and the mask for the advertisements filter, + /// to use for filtering by partial data. + /// @details Any previously set value will be overwritten. The mask works as follows: + /// For each bit set to 1 in the mask, the corresponding bits in @a data + /// and in the filtered data will have to be equal. If the mask bit is set to 0, + /// the corresponding bits will be ignored. + /// @since_tizen 4.0 + /// + /// @remarks The @a mask and the service @a data must have equal lengths. + /// + /// @param[in] scan_filter The scan filter handle + /// @param[in] uuid The service UUID by which advertisements will be filtered + /// @param[in] data The service data by which advertisements will be filtered + /// @param[in] data_len The length of the service data + /// @param[in] mask The mask by which advertisements will be filtered + /// @param[in] mask_len The length of the mask + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + int bt_adapter_le_scan_filter_set_service_data_with_mask( + ffi.Pointer scan_filter, + ffi.Pointer uuid, + ffi.Pointer data, + int data_len, + ffi.Pointer mask, + int mask_len, + ) { + return _bt_adapter_le_scan_filter_set_service_data_with_mask( + scan_filter, + uuid, + data, + data_len, + mask, + mask_len, + ); + } + + late final _bt_adapter_le_scan_filter_set_service_data_with_mask_ptr = + _lookup< + ffi.NativeFunction< + _c_bt_adapter_le_scan_filter_set_service_data_with_mask>>( + 'bt_adapter_le_scan_filter_set_service_data_with_mask'); + late final _dart_bt_adapter_le_scan_filter_set_service_data_with_mask + _bt_adapter_le_scan_filter_set_service_data_with_mask = + _bt_adapter_le_scan_filter_set_service_data_with_mask_ptr.asFunction< + _dart_bt_adapter_le_scan_filter_set_service_data_with_mask>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Sets the manufacturer data for the advertisements filter. + /// @details Any previously set value will be overwritten. + /// @since_tizen 4.0 + /// + /// @param[in] scan_filter The scan filter handle + /// @param[in] manufacturer_id The manufacturer ID (0x0000 ~ 0xFFFF) + /// @param[in] data The manufacturer data (byte array) + /// @param[in] data_len The length of the manufacturer data + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + int bt_adapter_le_scan_filter_set_manufacturer_data( + ffi.Pointer scan_filter, + int manufacturer_id, + ffi.Pointer data, + int data_len, + ) { + return _bt_adapter_le_scan_filter_set_manufacturer_data( + scan_filter, + manufacturer_id, + data, + data_len, + ); + } + + late final _bt_adapter_le_scan_filter_set_manufacturer_data_ptr = _lookup< + ffi.NativeFunction< + _c_bt_adapter_le_scan_filter_set_manufacturer_data>>( + 'bt_adapter_le_scan_filter_set_manufacturer_data'); + late final _dart_bt_adapter_le_scan_filter_set_manufacturer_data + _bt_adapter_le_scan_filter_set_manufacturer_data = + _bt_adapter_le_scan_filter_set_manufacturer_data_ptr + .asFunction<_dart_bt_adapter_le_scan_filter_set_manufacturer_data>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Sets the manufacturer data and the mask for the advertisements filter, + /// to use for filtering by partial data. + /// @details Any previously set value will be overwritten. The mask works as follows: + /// For each bit set to 1 in the mask, the corresponding bits in @a data + /// and in the filtered data will have to be equal. If the mask bit is set to 0, + /// the corresponding bits will be ignored. + /// @since_tizen 4.0 + /// + /// @remarks The @a mask and the manufacturer @a data must have equal lengths. + /// + /// @param[in] scan_filter The scan filter handle + /// @param[in] manufacturer_id The manufacturer ID (0x0000 ~ 0xFFFF) + /// @param[in] data The manufacturer data (byte array) + /// @param[in] data_len The length of the manufacturer data + /// @param[in] mask The mask by which advertisements will be filtered + /// @param[in] mask_len The length of the mask + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + int bt_adapter_le_scan_filter_set_manufacturer_data_with_mask( + ffi.Pointer scan_filter, + int manufacturer_id, + ffi.Pointer data, + int data_len, + ffi.Pointer mask, + int mask_len, + ) { + return _bt_adapter_le_scan_filter_set_manufacturer_data_with_mask( + scan_filter, + manufacturer_id, + data, + data_len, + mask, + mask_len, + ); + } + + late final _bt_adapter_le_scan_filter_set_manufacturer_data_with_mask_ptr = + _lookup< + ffi.NativeFunction< + _c_bt_adapter_le_scan_filter_set_manufacturer_data_with_mask>>( + 'bt_adapter_le_scan_filter_set_manufacturer_data_with_mask'); + late final _dart_bt_adapter_le_scan_filter_set_manufacturer_data_with_mask + _bt_adapter_le_scan_filter_set_manufacturer_data_with_mask = + _bt_adapter_le_scan_filter_set_manufacturer_data_with_mask_ptr.asFunction< + _dart_bt_adapter_le_scan_filter_set_manufacturer_data_with_mask>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Sets the scan filter type for the advertisements filter. + /// @details The filter type is used when searching only for iBeacon or proximity + /// type's advertising data. If the type is not set, LE scanner will + /// search devices as with regard to other filtered attributes. + /// If the type is set, all other attributes set for the filter are ignored. + /// @since_tizen 4.0 + /// + /// @param[in] scan_filter The scan filter handle + /// @param[in] mode The scan filter type + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + int bt_adapter_le_scan_filter_set_type( + ffi.Pointer scan_filter, + int mode, + ) { + return _bt_adapter_le_scan_filter_set_type( + scan_filter, + mode, + ); + } + + late final _bt_adapter_le_scan_filter_set_type_ptr = + _lookup>( + 'bt_adapter_le_scan_filter_set_type'); + late final _dart_bt_adapter_le_scan_filter_set_type + _bt_adapter_le_scan_filter_set_type = + _bt_adapter_le_scan_filter_set_type_ptr + .asFunction<_dart_bt_adapter_le_scan_filter_set_type>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Registers a scan filter to use for scanning. + /// @details If the filter is registered, it cannot be changed. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @remarks Several scan filters can be registered. If an advertisement passes + /// any of the registered scan filters, it will be included in the results. + /// + /// @param[in] scan_filter The scan filter handle + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOW_IN_PROGRESS Scan is in progress + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + int bt_adapter_le_scan_filter_register( + ffi.Pointer scan_filter, + ) { + return _bt_adapter_le_scan_filter_register( + scan_filter, + ); + } + + late final _bt_adapter_le_scan_filter_register_ptr = + _lookup>( + 'bt_adapter_le_scan_filter_register'); + late final _dart_bt_adapter_le_scan_filter_register + _bt_adapter_le_scan_filter_register = + _bt_adapter_le_scan_filter_register_ptr + .asFunction<_dart_bt_adapter_le_scan_filter_register>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Unregisters all registered scan filters. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @param[in] scan_filter The scan filter handle + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #BT_ERROR_NOW_IN_PROGRESS Scan is in progress + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + int bt_adapter_le_scan_filter_unregister( + ffi.Pointer scan_filter, + ) { + return _bt_adapter_le_scan_filter_unregister( + scan_filter, + ); + } + + late final _bt_adapter_le_scan_filter_unregister_ptr = + _lookup>( + 'bt_adapter_le_scan_filter_unregister'); + late final _dart_bt_adapter_le_scan_filter_unregister + _bt_adapter_le_scan_filter_unregister = + _bt_adapter_le_scan_filter_unregister_ptr + .asFunction<_dart_bt_adapter_le_scan_filter_unregister>(); + + /// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE + /// @brief Unregisters all registered scan filters. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/bluetooth + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #BT_ERROR_NONE Successful + /// @retval #BT_ERROR_NOT_INITIALIZED Not initialized + /// @retval #BT_ERROR_NOW_IN_PROGRESS Scan is in progress + /// @retval #BT_ERROR_NOT_SUPPORTED Not supported + /// @retval #BT_ERROR_PERMISSION_DENIED Permission denied + /// + /// @pre The Bluetooth service must be initialized with bt_initialize(). + int bt_adapter_le_scan_filter_unregister_all() { + return _bt_adapter_le_scan_filter_unregister_all(); + } + + late final _bt_adapter_le_scan_filter_unregister_all_ptr = + _lookup>( + 'bt_adapter_le_scan_filter_unregister_all'); + late final _dart_bt_adapter_le_scan_filter_unregister_all + _bt_adapter_le_scan_filter_unregister_all = + _bt_adapter_le_scan_filter_unregister_all_ptr + .asFunction<_dart_bt_adapter_le_scan_filter_unregister_all>(); + + /// @brief Creates a profile handle. + /// @details The profile name, which you get from connection_profile_get_name() + /// will include the keyword you set. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @remarks You must release @a profile using connection_profile_destroy(). + /// @param[in] type The type of profile \n + /// #CONNECTION_PROFILE_TYPE_CELLULAR and #CONNECTION_PROFILE_TYPE_WIFI are supported + /// @param[in] keyword The keyword included in profile name + /// @param[out] profile The handle of the profile + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + /// @see connection_profile_destroy() + /// @see connection_profile_get_name() + int connection_profile_create( + int type, + ffi.Pointer keyword, + ffi.Pointer> profile, + ) { + return _connection_profile_create( + type, + keyword, + profile, + ); + } + + late final _connection_profile_create_ptr = + _lookup>( + 'connection_profile_create'); + late final _dart_connection_profile_create _connection_profile_create = + _connection_profile_create_ptr + .asFunction<_dart_connection_profile_create>(); + + /// @brief Destroys a profile handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] profile The handle to the profile + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @see connection_profile_create() + int connection_profile_destroy( + ffi.Pointer profile, + ) { + return _connection_profile_destroy( + profile, + ); + } + + late final _connection_profile_destroy_ptr = + _lookup>( + 'connection_profile_destroy'); + late final _dart_connection_profile_destroy _connection_profile_destroy = + _connection_profile_destroy_ptr + .asFunction<_dart_connection_profile_destroy>(); + + /// @brief Clones a profile handle. + /// @since_tizen 2.3 + /// @remarks You must release @a cloned_profile using connection_profile_destroy(). + /// @param[out] cloned_profile The handle of the cloned profile + /// @param[in] origin_profile The handle of the origin profile + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @see connection_profile_destroy() + int connection_profile_clone( + ffi.Pointer> cloned_profile, + ffi.Pointer origin_profile, + ) { + return _connection_profile_clone( + cloned_profile, + origin_profile, + ); + } + + late final _connection_profile_clone_ptr = + _lookup>( + 'connection_profile_clone'); + late final _dart_connection_profile_clone _connection_profile_clone = + _connection_profile_clone_ptr + .asFunction<_dart_connection_profile_clone>(); + + /// @brief Gets the profile ID. + /// @details The separate profiles can have the same name. + /// So, you must use this API instead of connection_profile_get_name() + /// if you want to get the unique identification. + /// In case you create a profile, this value will be determined when you add the profile. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a profile_id using free(). + /// @param[in] profile The profile handle + /// @param[out] profile_id The ID of the profile + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @see connection_profile_get_name() + /// @see connection_add_profile() + int connection_profile_get_id( + ffi.Pointer profile, + ffi.Pointer> profile_id, + ) { + return _connection_profile_get_id( + profile, + profile_id, + ); + } + + late final _connection_profile_get_id_ptr = + _lookup>( + 'connection_profile_get_id'); + late final _dart_connection_profile_get_id _connection_profile_get_id = + _connection_profile_get_id_ptr + .asFunction<_dart_connection_profile_get_id>(); + + /// @brief Gets the profile name. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a profile_name using free(). + /// @param[in] profile The profile handle + /// @param[out] profile_name The name of the profile + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @see connection_profile_get_id() + int connection_profile_get_name( + ffi.Pointer profile, + ffi.Pointer> profile_name, + ) { + return _connection_profile_get_name( + profile, + profile_name, + ); + } + + late final _connection_profile_get_name_ptr = + _lookup>( + 'connection_profile_get_name'); + late final _dart_connection_profile_get_name _connection_profile_get_name = + _connection_profile_get_name_ptr + .asFunction<_dart_connection_profile_get_name>(); + + /// @brief Gets the network type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[out] type The type of the profile + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_profile_get_type( + ffi.Pointer profile, + ffi.Pointer type, + ) { + return _connection_profile_get_type( + profile, + type, + ); + } + + late final _connection_profile_get_type_ptr = + _lookup>( + 'connection_profile_get_type'); + late final _dart_connection_profile_get_type _connection_profile_get_type = + _connection_profile_get_type_ptr + .asFunction<_dart_connection_profile_get_type>(); + + /// @brief Gets the name of the network interface, e.g. eth0 and pdp0. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a interface_name using free(). + /// @param[in] profile The profile handle + /// @param[out] interface_name The name of the network interface + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + int connection_profile_get_network_interface_name( + ffi.Pointer profile, + ffi.Pointer> interface_name, + ) { + return _connection_profile_get_network_interface_name( + profile, + interface_name, + ); + } + + late final _connection_profile_get_network_interface_name_ptr = _lookup< + ffi.NativeFunction<_c_connection_profile_get_network_interface_name>>( + 'connection_profile_get_network_interface_name'); + late final _dart_connection_profile_get_network_interface_name + _connection_profile_get_network_interface_name = + _connection_profile_get_network_interface_name_ptr + .asFunction<_dart_connection_profile_get_network_interface_name>(); + + /// @brief Refreshes the profile information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @remarks You should call this function in order to get the current information + /// because the profile information can be changed. + /// @param[in] profile The profile handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + int connection_profile_refresh( + ffi.Pointer profile, + ) { + return _connection_profile_refresh( + profile, + ); + } + + late final _connection_profile_refresh_ptr = + _lookup>( + 'connection_profile_refresh'); + late final _dart_connection_profile_refresh _connection_profile_refresh = + _connection_profile_refresh_ptr + .asFunction<_dart_connection_profile_refresh>(); + + /// @brief Gets the network type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[out] state The state of the profile + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_profile_get_state( + ffi.Pointer profile, + ffi.Pointer state, + ) { + return _connection_profile_get_state( + profile, + state, + ); + } + + late final _connection_profile_get_state_ptr = + _lookup>( + 'connection_profile_get_state'); + late final _dart_connection_profile_get_state _connection_profile_get_state = + _connection_profile_get_state_ptr + .asFunction<_dart_connection_profile_get_state>(); + + /// @brief Gets the IP config type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[out] type The type of the IP config + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_profile_get_ip_config_type( + ffi.Pointer profile, + int address_family, + ffi.Pointer type, + ) { + return _connection_profile_get_ip_config_type( + profile, + address_family, + type, + ); + } + + late final _connection_profile_get_ip_config_type_ptr = + _lookup>( + 'connection_profile_get_ip_config_type'); + late final _dart_connection_profile_get_ip_config_type + _connection_profile_get_ip_config_type = + _connection_profile_get_ip_config_type_ptr + .asFunction<_dart_connection_profile_get_ip_config_type>(); + + /// @brief Gets the IP address. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a ip_address using free(). + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[out] ip_address The IP address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_profile_get_ip_address( + ffi.Pointer profile, + int address_family, + ffi.Pointer> ip_address, + ) { + return _connection_profile_get_ip_address( + profile, + address_family, + ip_address, + ); + } + + late final _connection_profile_get_ip_address_ptr = + _lookup>( + 'connection_profile_get_ip_address'); + late final _dart_connection_profile_get_ip_address + _connection_profile_get_ip_address = + _connection_profile_get_ip_address_ptr + .asFunction<_dart_connection_profile_get_ip_address>(); + + /// @brief Gets the Subnet Mask. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a subnet_mask using free(). + /// This function is supported only for IPv4 address family. + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[out] subnet_mask The subnet mask + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_profile_get_subnet_mask( + ffi.Pointer profile, + int address_family, + ffi.Pointer> subnet_mask, + ) { + return _connection_profile_get_subnet_mask( + profile, + address_family, + subnet_mask, + ); + } + + late final _connection_profile_get_subnet_mask_ptr = + _lookup>( + 'connection_profile_get_subnet_mask'); + late final _dart_connection_profile_get_subnet_mask + _connection_profile_get_subnet_mask = + _connection_profile_get_subnet_mask_ptr + .asFunction<_dart_connection_profile_get_subnet_mask>(); + + /// @brief Gets the Gateway address. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a gateway_address using free(). + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[out] gateway_address The gateway address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_profile_get_gateway_address( + ffi.Pointer profile, + int address_family, + ffi.Pointer> gateway_address, + ) { + return _connection_profile_get_gateway_address( + profile, + address_family, + gateway_address, + ); + } + + late final _connection_profile_get_gateway_address_ptr = + _lookup>( + 'connection_profile_get_gateway_address'); + late final _dart_connection_profile_get_gateway_address + _connection_profile_get_gateway_address = + _connection_profile_get_gateway_address_ptr + .asFunction<_dart_connection_profile_get_gateway_address>(); + + /// @brief Gets the DHCP Server address. + /// @since_tizen 4.0 + /// @remarks You must release @a dhcp_server using free(). + /// This function is supported only for IPv4 address family. + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[out] dhcp_server The DHCP Server address + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_profile_get_dhcp_server_address( + ffi.Pointer profile, + int address_family, + ffi.Pointer> dhcp_server, + ) { + return _connection_profile_get_dhcp_server_address( + profile, + address_family, + dhcp_server, + ); + } + + late final _connection_profile_get_dhcp_server_address_ptr = _lookup< + ffi.NativeFunction<_c_connection_profile_get_dhcp_server_address>>( + 'connection_profile_get_dhcp_server_address'); + late final _dart_connection_profile_get_dhcp_server_address + _connection_profile_get_dhcp_server_address = + _connection_profile_get_dhcp_server_address_ptr + .asFunction<_dart_connection_profile_get_dhcp_server_address>(); + + /// @brief Gets the DHCP lease duration. + /// @since_tizen 4.0 + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[out] dhcp_lease_duration The DHCP lease duration in seconds + /// @return @c 0 on success, otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_dhcp_lease_duration( + ffi.Pointer profile, + int address_family, + ffi.Pointer dhcp_lease_duration, + ) { + return _connection_profile_get_dhcp_lease_duration( + profile, + address_family, + dhcp_lease_duration, + ); + } + + late final _connection_profile_get_dhcp_lease_duration_ptr = _lookup< + ffi.NativeFunction<_c_connection_profile_get_dhcp_lease_duration>>( + 'connection_profile_get_dhcp_lease_duration'); + late final _dart_connection_profile_get_dhcp_lease_duration + _connection_profile_get_dhcp_lease_duration = + _connection_profile_get_dhcp_lease_duration_ptr + .asFunction<_dart_connection_profile_get_dhcp_lease_duration>(); + + /// @brief Gets the DNS address. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The allowance of the DNS address is @c 2. You must release @a dns_address using free(). + /// @param[in] profile The profile handle + /// @param[in] order The order of DNS address \n + /// It starts from 1, which means first DNS address + /// @param[in] address_family The address family + /// @param[out] dns_address The DNS address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_profile_get_dns_address( + ffi.Pointer profile, + int order, + int address_family, + ffi.Pointer> dns_address, + ) { + return _connection_profile_get_dns_address( + profile, + order, + address_family, + dns_address, + ); + } + + late final _connection_profile_get_dns_address_ptr = + _lookup>( + 'connection_profile_get_dns_address'); + late final _dart_connection_profile_get_dns_address + _connection_profile_get_dns_address = + _connection_profile_get_dns_address_ptr + .asFunction<_dart_connection_profile_get_dns_address>(); + + /// @brief Gets the Proxy type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[out] type The type of the proxy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_profile_get_proxy_type( + ffi.Pointer profile, + ffi.Pointer type, + ) { + return _connection_profile_get_proxy_type( + profile, + type, + ); + } + + late final _connection_profile_get_proxy_type_ptr = + _lookup>( + 'connection_profile_get_proxy_type'); + late final _dart_connection_profile_get_proxy_type + _connection_profile_get_proxy_type = + _connection_profile_get_proxy_type_ptr + .asFunction<_dart_connection_profile_get_proxy_type>(); + + /// @brief Gets the Proxy address. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a proxy_address using free(). + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[out] proxy_address The proxy address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_profile_get_proxy_address( + ffi.Pointer profile, + int address_family, + ffi.Pointer> proxy_address, + ) { + return _connection_profile_get_proxy_address( + profile, + address_family, + proxy_address, + ); + } + + late final _connection_profile_get_proxy_address_ptr = + _lookup>( + 'connection_profile_get_proxy_address'); + late final _dart_connection_profile_get_proxy_address + _connection_profile_get_proxy_address = + _connection_profile_get_proxy_address_ptr + .asFunction<_dart_connection_profile_get_proxy_address>(); + + /// @brief Sets the IP config type. + /// @details If you set IP config type to #CONNECTION_IP_CONFIG_TYPE_STATIC, + /// then IP address, Gateway and Subnet mask will be set to the initial value "0.0.0.0". + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[in] type The type of the IP config + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_profile_set_ip_config_type( + ffi.Pointer profile, + int address_family, + int type, + ) { + return _connection_profile_set_ip_config_type( + profile, + address_family, + type, + ); + } + + late final _connection_profile_set_ip_config_type_ptr = + _lookup>( + 'connection_profile_set_ip_config_type'); + late final _dart_connection_profile_set_ip_config_type + _connection_profile_set_ip_config_type = + _connection_profile_set_ip_config_type_ptr + .asFunction<_dart_connection_profile_set_ip_config_type>(); + + /// @brief Sets the IP address. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a ip_address using free(). + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[in] ip_address The IP address \n + /// If you set this value to @c NULL, then the existing value will be deleted + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @see connection_update_profile() + int connection_profile_set_ip_address( + ffi.Pointer profile, + int address_family, + ffi.Pointer ip_address, + ) { + return _connection_profile_set_ip_address( + profile, + address_family, + ip_address, + ); + } + + late final _connection_profile_set_ip_address_ptr = + _lookup>( + 'connection_profile_set_ip_address'); + late final _dart_connection_profile_set_ip_address + _connection_profile_set_ip_address = + _connection_profile_set_ip_address_ptr + .asFunction<_dart_connection_profile_set_ip_address>(); + + /// @brief Sets the Subnet Mask. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a subnet_mask using free(). + /// This function is supported only for IPv4 address family. + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[in] subnet_mask The subnet mask \n + /// If you set this value to @c NULL, then the existing value will be deleted + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @see connection_update_profile() + int connection_profile_set_subnet_mask( + ffi.Pointer profile, + int address_family, + ffi.Pointer subnet_mask, + ) { + return _connection_profile_set_subnet_mask( + profile, + address_family, + subnet_mask, + ); + } + + late final _connection_profile_set_subnet_mask_ptr = + _lookup>( + 'connection_profile_set_subnet_mask'); + late final _dart_connection_profile_set_subnet_mask + _connection_profile_set_subnet_mask = + _connection_profile_set_subnet_mask_ptr + .asFunction<_dart_connection_profile_set_subnet_mask>(); + + /// @brief Sets the Gateway address. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a gateway_address using free(). + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[in] gateway_address The gateway address \n + /// If you set this value to @c NULL, then the existing value will be deleted + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @see connection_update_profile() + int connection_profile_set_gateway_address( + ffi.Pointer profile, + int address_family, + ffi.Pointer gateway_address, + ) { + return _connection_profile_set_gateway_address( + profile, + address_family, + gateway_address, + ); + } + + late final _connection_profile_set_gateway_address_ptr = + _lookup>( + 'connection_profile_set_gateway_address'); + late final _dart_connection_profile_set_gateway_address + _connection_profile_set_gateway_address = + _connection_profile_set_gateway_address_ptr + .asFunction<_dart_connection_profile_set_gateway_address>(); + + /// @brief Sets the DNS address. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The allowance of the DNS address is @c 2. + /// @remarks You must release @a dns_address using free(). + /// @param[in] profile The profile handle + /// @param[in] order The order of the DNS address \n + /// It starts from @c 1, which means first DNS address + /// @param[in] address_family The address family + /// @param[in] dns_address The DNS address \n + /// If you set this value to NULL then the existing value will be deleted + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @see connection_update_profile() + int connection_profile_set_dns_address( + ffi.Pointer profile, + int order, + int address_family, + ffi.Pointer dns_address, + ) { + return _connection_profile_set_dns_address( + profile, + order, + address_family, + dns_address, + ); + } + + late final _connection_profile_set_dns_address_ptr = + _lookup>( + 'connection_profile_set_dns_address'); + late final _dart_connection_profile_set_dns_address + _connection_profile_set_dns_address = + _connection_profile_set_dns_address_ptr + .asFunction<_dart_connection_profile_set_dns_address>(); + + /// @brief Sets the Proxy type. + /// @details If you set the Proxy type to #CONNECTION_PROXY_TYPE_AUTO or + /// #CONNECTION_PROXY_TYPE_MANUAL, then Proxy will be restored. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[in] type The type of the proxy + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @see connection_update_profile() + int connection_profile_set_proxy_type( + ffi.Pointer profile, + int type, + ) { + return _connection_profile_set_proxy_type( + profile, + type, + ); + } + + late final _connection_profile_set_proxy_type_ptr = + _lookup>( + 'connection_profile_set_proxy_type'); + late final _dart_connection_profile_set_proxy_type + _connection_profile_set_proxy_type = + _connection_profile_set_proxy_type_ptr + .asFunction<_dart_connection_profile_set_proxy_type>(); + + /// @brief Sets the Proxy address. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a proxy_address using free(). + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[in] proxy_address The proxy address \n + /// If you set this value to @c NULL, then the existing value will be deleted + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @see connection_update_profile() + int connection_profile_set_proxy_address( + ffi.Pointer profile, + int address_family, + ffi.Pointer proxy_address, + ) { + return _connection_profile_set_proxy_address( + profile, + address_family, + proxy_address, + ); + } + + late final _connection_profile_set_proxy_address_ptr = + _lookup>( + 'connection_profile_set_proxy_address'); + late final _dart_connection_profile_set_proxy_address + _connection_profile_set_proxy_address = + _connection_profile_set_proxy_address_ptr + .asFunction<_dart_connection_profile_set_proxy_address>(); + + /// @brief Registers the callback that is called when the state of profile is changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @post connection_opened_cb() is invoked when the state of profile is changed. + /// @see connection_profile_state_changed_cb() + /// @see connection_profile_unset_state_changed_cb() + int connection_profile_set_state_changed_cb( + ffi.Pointer profile, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _connection_profile_set_state_changed_cb( + profile, + callback, + user_data, + ); + } + + late final _connection_profile_set_state_changed_cb_ptr = + _lookup>( + 'connection_profile_set_state_changed_cb'); + late final _dart_connection_profile_set_state_changed_cb + _connection_profile_set_state_changed_cb = + _connection_profile_set_state_changed_cb_ptr + .asFunction<_dart_connection_profile_set_state_changed_cb>(); + + /// @brief Unregisters the callback that is called when the state of profile is changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @see connection_profile_state_changed_cb() + /// @see connection_profile_set_state_changed_cb() + int connection_profile_unset_state_changed_cb( + ffi.Pointer profile, + ) { + return _connection_profile_unset_state_changed_cb( + profile, + ); + } + + late final _connection_profile_unset_state_changed_cb_ptr = + _lookup>( + 'connection_profile_unset_state_changed_cb'); + late final _dart_connection_profile_unset_state_changed_cb + _connection_profile_unset_state_changed_cb = + _connection_profile_unset_state_changed_cb_ptr + .asFunction<_dart_connection_profile_unset_state_changed_cb>(); + + /// @brief Gets the IPv6 network state. + /// @since_tizen 4.0 + /// @param[in] profile The profile handle + /// @param[out] state The profile state + /// @return 0 on success, otherwise negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_ipv6_state( + ffi.Pointer profile, + ffi.Pointer state, + ) { + return _connection_profile_get_ipv6_state( + profile, + state, + ); + } + + late final _connection_profile_get_ipv6_state_ptr = + _lookup>( + 'connection_profile_get_ipv6_state'); + late final _dart_connection_profile_get_ipv6_state + _connection_profile_get_ipv6_state = + _connection_profile_get_ipv6_state_ptr + .asFunction<_dart_connection_profile_get_ipv6_state>(); + + /// @brief Sets the DNS config type. + /// @since_tizen 4.0 + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[in] type The DNS config type + /// @return 0 on success, otherwise negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_set_dns_config_type( + ffi.Pointer profile, + int address_family, + int type, + ) { + return _connection_profile_set_dns_config_type( + profile, + address_family, + type, + ); + } + + late final _connection_profile_set_dns_config_type_ptr = + _lookup>( + 'connection_profile_set_dns_config_type'); + late final _dart_connection_profile_set_dns_config_type + _connection_profile_set_dns_config_type = + _connection_profile_set_dns_config_type_ptr + .asFunction<_dart_connection_profile_set_dns_config_type>(); + + /// @brief Gets the DNS config type. + /// @since_tizen 4.0 + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[out] type The DNS config type + /// @return 0 on success, otherwise negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_dns_config_type( + ffi.Pointer profile, + int address_family, + ffi.Pointer type, + ) { + return _connection_profile_get_dns_config_type( + profile, + address_family, + type, + ); + } + + late final _connection_profile_get_dns_config_type_ptr = + _lookup>( + 'connection_profile_get_dns_config_type'); + late final _dart_connection_profile_get_dns_config_type + _connection_profile_get_dns_config_type = + _connection_profile_get_dns_config_type_ptr + .asFunction<_dart_connection_profile_get_dns_config_type>(); + + /// @brief Gets the network prefix length. + /// @since_tizen 4.0 + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[out] prefix_len The network prefix length \n + /// In case of IPv4, it means netmask length + /// (also called a prefix, e.g. 8, 16, 24, 32) + /// @return 0 on success, otherwise negative error value. + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_prefix_length( + ffi.Pointer profile, + int address_family, + ffi.Pointer prefix_len, + ) { + return _connection_profile_get_prefix_length( + profile, + address_family, + prefix_len, + ); + } + + late final _connection_profile_get_prefix_length_ptr = + _lookup>( + 'connection_profile_get_prefix_length'); + late final _dart_connection_profile_get_prefix_length + _connection_profile_get_prefix_length = + _connection_profile_get_prefix_length_ptr + .asFunction<_dart_connection_profile_get_prefix_length>(); + + /// @brief Sets the network prefix length. + /// @since_tizen 4.0 + /// @param[in] profile The profile handle + /// @param[in] address_family The address family + /// @param[in] prefix_len The network prefix length + /// In case of IPv4, it means netmask length + /// (also called a prefix, e.g. 8, 16, 24, 32) + /// @return 0 on success, otherwise negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + /// @see connection_update_profile() + int connection_profile_set_prefix_length( + ffi.Pointer profile, + int address_family, + int prefix_len, + ) { + return _connection_profile_set_prefix_length( + profile, + address_family, + prefix_len, + ); + } + + late final _connection_profile_set_prefix_length_ptr = + _lookup>( + 'connection_profile_set_prefix_length'); + late final _dart_connection_profile_set_prefix_length + _connection_profile_set_prefix_length = + _connection_profile_set_prefix_length_ptr + .asFunction<_dart_connection_profile_set_prefix_length>(); + + /// @brief Gets the ESSID (Extended Service Set Identifier). + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a essid using free(). + /// @param[in] profile The profile handle + /// @param[out] essid The ESSID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_wifi_essid( + ffi.Pointer profile, + ffi.Pointer> essid, + ) { + return _connection_profile_get_wifi_essid( + profile, + essid, + ); + } + + late final _connection_profile_get_wifi_essid_ptr = + _lookup>( + 'connection_profile_get_wifi_essid'); + late final _dart_connection_profile_get_wifi_essid + _connection_profile_get_wifi_essid = + _connection_profile_get_wifi_essid_ptr + .asFunction<_dart_connection_profile_get_wifi_essid>(); + + /// @brief Gets the BSSID (Basic Service Set Identifier). + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a bssid using free(). + /// @param[in] profile The profile handle + /// @param[out] bssid The BSSID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_wifi_bssid( + ffi.Pointer profile, + ffi.Pointer> bssid, + ) { + return _connection_profile_get_wifi_bssid( + profile, + bssid, + ); + } + + late final _connection_profile_get_wifi_bssid_ptr = + _lookup>( + 'connection_profile_get_wifi_bssid'); + late final _dart_connection_profile_get_wifi_bssid + _connection_profile_get_wifi_bssid = + _connection_profile_get_wifi_bssid_ptr + .asFunction<_dart_connection_profile_get_wifi_bssid>(); + + /// @brief Gets the RSSI. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[out] rssi The RSSI + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_wifi_rssi( + ffi.Pointer profile, + ffi.Pointer rssi, + ) { + return _connection_profile_get_wifi_rssi( + profile, + rssi, + ); + } + + late final _connection_profile_get_wifi_rssi_ptr = + _lookup>( + 'connection_profile_get_wifi_rssi'); + late final _dart_connection_profile_get_wifi_rssi + _connection_profile_get_wifi_rssi = _connection_profile_get_wifi_rssi_ptr + .asFunction<_dart_connection_profile_get_wifi_rssi>(); + + /// @brief Gets the frequency (MHz). + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[out] frequency The frequency + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_wifi_frequency( + ffi.Pointer profile, + ffi.Pointer frequency, + ) { + return _connection_profile_get_wifi_frequency( + profile, + frequency, + ); + } + + late final _connection_profile_get_wifi_frequency_ptr = + _lookup>( + 'connection_profile_get_wifi_frequency'); + late final _dart_connection_profile_get_wifi_frequency + _connection_profile_get_wifi_frequency = + _connection_profile_get_wifi_frequency_ptr + .asFunction<_dart_connection_profile_get_wifi_frequency>(); + + /// @brief Gets the max speed (Mbps). + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[out] max_speed The max speed + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_wifi_max_speed( + ffi.Pointer profile, + ffi.Pointer max_speed, + ) { + return _connection_profile_get_wifi_max_speed( + profile, + max_speed, + ); + } + + late final _connection_profile_get_wifi_max_speed_ptr = + _lookup>( + 'connection_profile_get_wifi_max_speed'); + late final _dart_connection_profile_get_wifi_max_speed + _connection_profile_get_wifi_max_speed = + _connection_profile_get_wifi_max_speed_ptr + .asFunction<_dart_connection_profile_get_wifi_max_speed>(); + + /// @brief Gets the security mode of Wi-Fi. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[out] type The type of Wi-Fi security + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_wifi_security_type( + ffi.Pointer profile, + ffi.Pointer type, + ) { + return _connection_profile_get_wifi_security_type( + profile, + type, + ); + } + + late final _connection_profile_get_wifi_security_type_ptr = + _lookup>( + 'connection_profile_get_wifi_security_type'); + late final _dart_connection_profile_get_wifi_security_type + _connection_profile_get_wifi_security_type = + _connection_profile_get_wifi_security_type_ptr + .asFunction<_dart_connection_profile_get_wifi_security_type>(); + + /// @brief Gets the security mode of Wi-Fi. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[out] type The type of Wi-Fi security + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_wifi_encryption_type( + ffi.Pointer profile, + ffi.Pointer type, + ) { + return _connection_profile_get_wifi_encryption_type( + profile, + type, + ); + } + + late final _connection_profile_get_wifi_encryption_type_ptr = _lookup< + ffi.NativeFunction<_c_connection_profile_get_wifi_encryption_type>>( + 'connection_profile_get_wifi_encryption_type'); + late final _dart_connection_profile_get_wifi_encryption_type + _connection_profile_get_wifi_encryption_type = + _connection_profile_get_wifi_encryption_type_ptr + .asFunction<_dart_connection_profile_get_wifi_encryption_type>(); + + /// @brief Checks whether passphrase is required. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks This function is not valid if security type is #CONNECTION_WIFI_SECURITY_TYPE_EAP. + /// @param[in] profile The profile handle + /// @param[out] required @c true if a passphrase is required, + /// otherwise @c false if a passphrase is not required + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_is_wifi_passphrase_required( + ffi.Pointer profile, + ffi.Pointer required, + ) { + return _connection_profile_is_wifi_passphrase_required( + profile, + required, + ); + } + + late final _connection_profile_is_wifi_passphrase_required_ptr = _lookup< + ffi.NativeFunction< + _c_connection_profile_is_wifi_passphrase_required>>( + 'connection_profile_is_wifi_passphrase_required'); + late final _dart_connection_profile_is_wifi_passphrase_required + _connection_profile_is_wifi_passphrase_required = + _connection_profile_is_wifi_passphrase_required_ptr + .asFunction<_dart_connection_profile_is_wifi_passphrase_required>(); + + /// @brief Sets the passphrase of the Wi-Fi WPA. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a passphrase using free(). + /// @param[in] profile The profile handle + /// @param[in] passphrase The passphrase of Wi-Fi security + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + /// @see connection_update_profile() + int connection_profile_set_wifi_passphrase( + ffi.Pointer profile, + ffi.Pointer passphrase, + ) { + return _connection_profile_set_wifi_passphrase( + profile, + passphrase, + ); + } + + late final _connection_profile_set_wifi_passphrase_ptr = + _lookup>( + 'connection_profile_set_wifi_passphrase'); + late final _dart_connection_profile_set_wifi_passphrase + _connection_profile_set_wifi_passphrase = + _connection_profile_set_wifi_passphrase_ptr + .asFunction<_dart_connection_profile_set_wifi_passphrase>(); + + /// @brief Checks whether the WPS (Wi-Fi Protected Setup) is supported. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If WPS is supported, you can connect the access point with WPS by wifi_connect_with_wps(). + /// @param[in] profile The profile handle + /// @param[out] supported @c true if WPS is supported, + /// otherwise @c false if WPS is not supported + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_is_wifi_wps_supported( + ffi.Pointer profile, + ffi.Pointer supported, + ) { + return _connection_profile_is_wifi_wps_supported( + profile, + supported, + ); + } + + late final _connection_profile_is_wifi_wps_supported_ptr = + _lookup>( + 'connection_profile_is_wifi_wps_supported'); + late final _dart_connection_profile_is_wifi_wps_supported + _connection_profile_is_wifi_wps_supported = + _connection_profile_is_wifi_wps_supported_ptr + .asFunction<_dart_connection_profile_is_wifi_wps_supported>(); + + /// @brief Gets the service type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[out] type The type of the cellular service + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_cellular_service_type( + ffi.Pointer profile, + ffi.Pointer type, + ) { + return _connection_profile_get_cellular_service_type( + profile, + type, + ); + } + + late final _connection_profile_get_cellular_service_type_ptr = _lookup< + ffi.NativeFunction<_c_connection_profile_get_cellular_service_type>>( + 'connection_profile_get_cellular_service_type'); + late final _dart_connection_profile_get_cellular_service_type + _connection_profile_get_cellular_service_type = + _connection_profile_get_cellular_service_type_ptr + .asFunction<_dart_connection_profile_get_cellular_service_type>(); + + /// @brief Gets the APN (access point name). + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a apn using free(). + /// @param[in] profile The profile handle + /// @param[out] apn The name of the APN + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_cellular_apn( + ffi.Pointer profile, + ffi.Pointer> apn, + ) { + return _connection_profile_get_cellular_apn( + profile, + apn, + ); + } + + late final _connection_profile_get_cellular_apn_ptr = + _lookup>( + 'connection_profile_get_cellular_apn'); + late final _dart_connection_profile_get_cellular_apn + _connection_profile_get_cellular_apn = + _connection_profile_get_cellular_apn_ptr + .asFunction<_dart_connection_profile_get_cellular_apn>(); + + /// @brief Gets the authentication information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a user_name and @a password using free(). + /// @param[in] profile The profile handle + /// @param[out] type The type of the authentication + /// @param[out] user_name The user name + /// @param[out] password The password + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_cellular_auth_info( + ffi.Pointer profile, + ffi.Pointer type, + ffi.Pointer> user_name, + ffi.Pointer> password, + ) { + return _connection_profile_get_cellular_auth_info( + profile, + type, + user_name, + password, + ); + } + + late final _connection_profile_get_cellular_auth_info_ptr = + _lookup>( + 'connection_profile_get_cellular_auth_info'); + late final _dart_connection_profile_get_cellular_auth_info + _connection_profile_get_cellular_auth_info = + _connection_profile_get_cellular_auth_info_ptr + .asFunction<_dart_connection_profile_get_cellular_auth_info>(); + + /// @brief Gets the home URL. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a home_url using free(). + /// @param[in] profile The profile handle + /// @param[out] home_url The home URL + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_cellular_home_url( + ffi.Pointer profile, + ffi.Pointer> home_url, + ) { + return _connection_profile_get_cellular_home_url( + profile, + home_url, + ); + } + + late final _connection_profile_get_cellular_home_url_ptr = + _lookup>( + 'connection_profile_get_cellular_home_url'); + late final _dart_connection_profile_get_cellular_home_url + _connection_profile_get_cellular_home_url = + _connection_profile_get_cellular_home_url_ptr + .asFunction<_dart_connection_profile_get_cellular_home_url>(); + + /// @brief Gets the cellular pdn type. + /// @since_tizen 3.0 + /// @param[in] profile The profile handle + /// @param[out] type The cellular pdn type + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_cellular_pdn_type( + ffi.Pointer profile, + ffi.Pointer type, + ) { + return _connection_profile_get_cellular_pdn_type( + profile, + type, + ); + } + + late final _connection_profile_get_cellular_pdn_type_ptr = + _lookup>( + 'connection_profile_get_cellular_pdn_type'); + late final _dart_connection_profile_get_cellular_pdn_type + _connection_profile_get_cellular_pdn_type = + _connection_profile_get_cellular_pdn_type_ptr + .asFunction<_dart_connection_profile_get_cellular_pdn_type>(); + + /// @brief Gets the cellular roam pdn type. + /// @since_tizen 3.0 + /// @param[in] profile The profile handle + /// @param[out] type The cellular pdn type + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_get_cellular_roam_pdn_type( + ffi.Pointer profile, + ffi.Pointer type, + ) { + return _connection_profile_get_cellular_roam_pdn_type( + profile, + type, + ); + } + + late final _connection_profile_get_cellular_roam_pdn_type_ptr = _lookup< + ffi.NativeFunction<_c_connection_profile_get_cellular_roam_pdn_type>>( + 'connection_profile_get_cellular_roam_pdn_type'); + late final _dart_connection_profile_get_cellular_roam_pdn_type + _connection_profile_get_cellular_roam_pdn_type = + _connection_profile_get_cellular_roam_pdn_type_ptr + .asFunction<_dart_connection_profile_get_cellular_roam_pdn_type>(); + + /// @brief Checks whether the connection is in roaming state. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[out] is_roaming @c true if the cellular is roaming, + /// otherwise @c false if it is not roaming + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_is_cellular_roaming( + ffi.Pointer profile, + ffi.Pointer is_roaming, + ) { + return _connection_profile_is_cellular_roaming( + profile, + is_roaming, + ); + } + + late final _connection_profile_is_cellular_roaming_ptr = + _lookup>( + 'connection_profile_is_cellular_roaming'); + late final _dart_connection_profile_is_cellular_roaming + _connection_profile_is_cellular_roaming = + _connection_profile_is_cellular_roaming_ptr + .asFunction<_dart_connection_profile_is_cellular_roaming>(); + + /// @brief Checks whether the profile is hidden. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[out] is_hidden @c true if the profile is in hidden, + /// otherwise @c false if the profile is not hidden + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_is_cellular_hidden( + ffi.Pointer profile, + ffi.Pointer is_hidden, + ) { + return _connection_profile_is_cellular_hidden( + profile, + is_hidden, + ); + } + + late final _connection_profile_is_cellular_hidden_ptr = + _lookup>( + 'connection_profile_is_cellular_hidden'); + late final _dart_connection_profile_is_cellular_hidden + _connection_profile_is_cellular_hidden = + _connection_profile_is_cellular_hidden_ptr + .asFunction<_dart_connection_profile_is_cellular_hidden>(); + + /// @brief Checks whether the profile is editable. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[out] is_editable @c true if the profile is editable, + /// otherwise @c false if the profile is not editable + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_is_cellular_editable( + ffi.Pointer profile, + ffi.Pointer is_editable, + ) { + return _connection_profile_is_cellular_editable( + profile, + is_editable, + ); + } + + late final _connection_profile_is_cellular_editable_ptr = + _lookup>( + 'connection_profile_is_cellular_editable'); + late final _dart_connection_profile_is_cellular_editable + _connection_profile_is_cellular_editable = + _connection_profile_is_cellular_editable_ptr + .asFunction<_dart_connection_profile_is_cellular_editable>(); + + /// @brief Checks whether the profile is default. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[out] is_default @c true if the profile is default, + /// otherwise @c false if the profile is not default + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_is_cellular_default( + ffi.Pointer profile, + ffi.Pointer is_default, + ) { + return _connection_profile_is_cellular_default( + profile, + is_default, + ); + } + + late final _connection_profile_is_cellular_default_ptr = + _lookup>( + 'connection_profile_is_cellular_default'); + late final _dart_connection_profile_is_cellular_default + _connection_profile_is_cellular_default = + _connection_profile_is_cellular_default_ptr + .asFunction<_dart_connection_profile_is_cellular_default>(); + + /// @brief Sets the service type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile The profile handle + /// @param[in] service_type The type of cellular service + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + /// @see connection_update_profile() + int connection_profile_set_cellular_service_type( + ffi.Pointer profile, + int service_type, + ) { + return _connection_profile_set_cellular_service_type( + profile, + service_type, + ); + } + + late final _connection_profile_set_cellular_service_type_ptr = _lookup< + ffi.NativeFunction<_c_connection_profile_set_cellular_service_type>>( + 'connection_profile_set_cellular_service_type'); + late final _dart_connection_profile_set_cellular_service_type + _connection_profile_set_cellular_service_type = + _connection_profile_set_cellular_service_type_ptr + .asFunction<_dart_connection_profile_set_cellular_service_type>(); + + /// @brief Sets the APN (Access Point Name). + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a apn using free(). + /// @param[in] profile The profile handle + /// @param[in] apn The name of APN + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + /// @see connection_update_profile() + int connection_profile_set_cellular_apn( + ffi.Pointer profile, + ffi.Pointer apn, + ) { + return _connection_profile_set_cellular_apn( + profile, + apn, + ); + } + + late final _connection_profile_set_cellular_apn_ptr = + _lookup>( + 'connection_profile_set_cellular_apn'); + late final _dart_connection_profile_set_cellular_apn + _connection_profile_set_cellular_apn = + _connection_profile_set_cellular_apn_ptr + .asFunction<_dart_connection_profile_set_cellular_apn>(); + + /// @brief Sets the Authentication information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a user_name using free(). + /// @param[in] profile The profile handle + /// @param[in] type The type of the authentication + /// @param[in] user_name The user name + /// @param[in] password The password + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + /// @see connection_update_profile() + int connection_profile_set_cellular_auth_info( + ffi.Pointer profile, + int type, + ffi.Pointer user_name, + ffi.Pointer password, + ) { + return _connection_profile_set_cellular_auth_info( + profile, + type, + user_name, + password, + ); + } + + late final _connection_profile_set_cellular_auth_info_ptr = + _lookup>( + 'connection_profile_set_cellular_auth_info'); + late final _dart_connection_profile_set_cellular_auth_info + _connection_profile_set_cellular_auth_info = + _connection_profile_set_cellular_auth_info_ptr + .asFunction<_dart_connection_profile_set_cellular_auth_info>(); + + /// @brief Sets the home URL. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a home_url using free(). + /// @param[in] profile The profile handle + /// @param[in] home_url The home URL + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + /// @see connection_update_profile() + int connection_profile_set_cellular_home_url( + ffi.Pointer profile, + ffi.Pointer home_url, + ) { + return _connection_profile_set_cellular_home_url( + profile, + home_url, + ); + } + + late final _connection_profile_set_cellular_home_url_ptr = + _lookup>( + 'connection_profile_set_cellular_home_url'); + late final _dart_connection_profile_set_cellular_home_url + _connection_profile_set_cellular_home_url = + _connection_profile_set_cellular_home_url_ptr + .asFunction<_dart_connection_profile_set_cellular_home_url>(); + + /// @brief Sets the cellular pdn type. + /// @since_tizen 3.0 + /// @param[in] profile The profile handle + /// @param[in] type The cellular pdn type + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_set_cellular_pdn_type( + ffi.Pointer profile, + int type, + ) { + return _connection_profile_set_cellular_pdn_type( + profile, + type, + ); + } + + late final _connection_profile_set_cellular_pdn_type_ptr = + _lookup>( + 'connection_profile_set_cellular_pdn_type'); + late final _dart_connection_profile_set_cellular_pdn_type + _connection_profile_set_cellular_pdn_type = + _connection_profile_set_cellular_pdn_type_ptr + .asFunction<_dart_connection_profile_set_cellular_pdn_type>(); + + /// @brief Sets the cellular roam pdn type. + /// @since_tizen 3.0 + /// @param[in] profile The profile handle + /// @param[in] type The cellular pdn type + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_profile_set_cellular_roam_pdn_type( + ffi.Pointer profile, + int type, + ) { + return _connection_profile_set_cellular_roam_pdn_type( + profile, + type, + ); + } + + late final _connection_profile_set_cellular_roam_pdn_type_ptr = _lookup< + ffi.NativeFunction<_c_connection_profile_set_cellular_roam_pdn_type>>( + 'connection_profile_set_cellular_roam_pdn_type'); + late final _dart_connection_profile_set_cellular_roam_pdn_type + _connection_profile_set_cellular_roam_pdn_type = + _connection_profile_set_cellular_roam_pdn_type_ptr + .asFunction<_dart_connection_profile_set_cellular_roam_pdn_type>(); + + /// @brief Creates a handle for managing data connections. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @remarks You must release @a handle using connection_destroy(). + /// @param[out] connection The connection handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @see connection_destroy() + int connection_create( + ffi.Pointer> connection, + ) { + return _connection_create( + connection, + ); + } + + late final _connection_create_ptr = + _lookup>('connection_create'); + late final _dart_connection_create _connection_create = + _connection_create_ptr.asFunction<_dart_connection_create>(); + + /// @brief Destroys the connection handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] connection The connection handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @see connection_create() + int connection_destroy( + ffi.Pointer connection, + ) { + return _connection_destroy( + connection, + ); + } + + late final _connection_destroy_ptr = + _lookup>('connection_destroy'); + late final _dart_connection_destroy _connection_destroy = + _connection_destroy_ptr.asFunction<_dart_connection_destroy>(); + + /// @brief Gets the type of the current profile for data connection. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] connection The connection handle + /// @param[out] type The type of the network + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_get_type( + ffi.Pointer connection, + ffi.Pointer type, + ) { + return _connection_get_type( + connection, + type, + ); + } + + late final _connection_get_type_ptr = + _lookup>( + 'connection_get_type'); + late final _dart_connection_get_type _connection_get_type = + _connection_get_type_ptr.asFunction<_dart_connection_get_type>(); + + /// @brief Gets the IP address of the current connection. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a ip_address using free(). + /// @param[in] connection The connection handle + /// @param[in] address_family The address family + /// @param[out] ip_address The pointer to the IP address string + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + int connection_get_ip_address( + ffi.Pointer connection, + int address_family, + ffi.Pointer> ip_address, + ) { + return _connection_get_ip_address( + connection, + address_family, + ip_address, + ); + } + + late final _connection_get_ip_address_ptr = + _lookup>( + 'connection_get_ip_address'); + late final _dart_connection_get_ip_address _connection_get_ip_address = + _connection_get_ip_address_ptr + .asFunction<_dart_connection_get_ip_address>(); + + /// @brief Gets the proxy address of the current connection. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks You must release @a proxy using free(). + /// @param[in] connection The connection handle + /// @param[in] address_family The address family + /// @param[out] proxy The proxy address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + int connection_get_proxy( + ffi.Pointer connection, + int address_family, + ffi.Pointer> proxy, + ) { + return _connection_get_proxy( + connection, + address_family, + proxy, + ); + } + + late final _connection_get_proxy_ptr = + _lookup>( + 'connection_get_proxy'); + late final _dart_connection_get_proxy _connection_get_proxy = + _connection_get_proxy_ptr.asFunction<_dart_connection_get_proxy>(); + + /// @brief Gets the MAC address of the Wi-Fi or ethernet. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks @a mac_addr must be released with free() by you. + /// @param[in] connection The handle of the connection + /// @param[in] type The type of current network connection + /// @param[out] mac_addr The MAC address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_INVALID_OPERATION Invalid operation + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + int connection_get_mac_address( + ffi.Pointer connection, + int type, + ffi.Pointer> mac_addr, + ) { + return _connection_get_mac_address( + connection, + type, + mac_addr, + ); + } + + late final _connection_get_mac_address_ptr = + _lookup>( + 'connection_get_mac_address'); + late final _dart_connection_get_mac_address _connection_get_mac_address = + _connection_get_mac_address_ptr + .asFunction<_dart_connection_get_mac_address>(); + + /// @brief Gets if the current connection is metered. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @param[in] connection The connection handle + /// @param[out] is_metered The value indicating whether it is metered + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_is_metered_network( + ffi.Pointer connection, + ffi.Pointer is_metered, + ) { + return _connection_is_metered_network( + connection, + is_metered, + ); + } + + late final _connection_is_metered_network_ptr = + _lookup>( + 'connection_is_metered_network'); + late final _dart_connection_is_metered_network + _connection_is_metered_network = _connection_is_metered_network_ptr + .asFunction<_dart_connection_is_metered_network>(); + + /// @brief Gets the state of cellular connection. + /// @details The returned state is for the cellular connection state. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] connection The connection handle + /// @param[out] state The state of the cellular connection + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_get_cellular_state( + ffi.Pointer connection, + ffi.Pointer state, + ) { + return _connection_get_cellular_state( + connection, + state, + ); + } + + late final _connection_get_cellular_state_ptr = + _lookup>( + 'connection_get_cellular_state'); + late final _dart_connection_get_cellular_state + _connection_get_cellular_state = _connection_get_cellular_state_ptr + .asFunction<_dart_connection_get_cellular_state>(); + + /// @brief Gets the state of the Wi-Fi. + /// @details The returned state is for the Wi-Fi connection state. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @param[in] connection The connection handle + /// @param[out] state The state of Wi-Fi connection + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_get_wifi_state( + ffi.Pointer connection, + ffi.Pointer state, + ) { + return _connection_get_wifi_state( + connection, + state, + ); + } + + late final _connection_get_wifi_state_ptr = + _lookup>( + 'connection_get_wifi_state'); + late final _dart_connection_get_wifi_state _connection_get_wifi_state = + _connection_get_wifi_state_ptr + .asFunction<_dart_connection_get_wifi_state>(); + + /// @brief Gets the state of the Ethernet. + /// @details The returned state is for the Ethernet connection state. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @param[in] connection The connection handle + /// @param[out] state The state of Ethernet connection + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_get_ethernet_state( + ffi.Pointer connection, + ffi.Pointer state, + ) { + return _connection_get_ethernet_state( + connection, + state, + ); + } + + late final _connection_get_ethernet_state_ptr = + _lookup>( + 'connection_get_ethernet_state'); + late final _dart_connection_get_ethernet_state + _connection_get_ethernet_state = _connection_get_ethernet_state_ptr + .asFunction<_dart_connection_get_ethernet_state>(); + + /// @brief Checks for ethernet cable is attached or not. + /// @details The returned state is for the ethernet cable state. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @param[in] connection The handle of the connection + /// @param[in] state The state of ethernet cable + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + int connection_get_ethernet_cable_state( + ffi.Pointer connection, + ffi.Pointer state, + ) { + return _connection_get_ethernet_cable_state( + connection, + state, + ); + } + + late final _connection_get_ethernet_cable_state_ptr = + _lookup>( + 'connection_get_ethernet_cable_state'); + late final _dart_connection_get_ethernet_cable_state + _connection_get_ethernet_cable_state = + _connection_get_ethernet_cable_state_ptr + .asFunction<_dart_connection_get_ethernet_cable_state>(); + + /// @deprecated Deprecated since 4.0. Use connection_set_ethernet_cable_state_changed_cb() instead. + /// @brief Registers callback for ethernet cable is plugged [in/out] event. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] connection The handle of connection + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_set_ethernet_cable_state_chaged_cb( + ffi.Pointer connection, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _connection_set_ethernet_cable_state_chaged_cb( + connection, + callback, + user_data, + ); + } + + late final _connection_set_ethernet_cable_state_chaged_cb_ptr = _lookup< + ffi.NativeFunction<_c_connection_set_ethernet_cable_state_chaged_cb>>( + 'connection_set_ethernet_cable_state_chaged_cb'); + late final _dart_connection_set_ethernet_cable_state_chaged_cb + _connection_set_ethernet_cable_state_chaged_cb = + _connection_set_ethernet_cable_state_chaged_cb_ptr + .asFunction<_dart_connection_set_ethernet_cable_state_chaged_cb>(); + + /// @deprecated Deprecated since 4.0. Use connection_unset_ethernet_cable_state_changed_cb() instead. + /// @brief Unregisters callback for ethernet cable is plugged [in/out] event. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] connection The handle of connection + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_unset_ethernet_cable_state_chaged_cb( + ffi.Pointer connection, + ) { + return _connection_unset_ethernet_cable_state_chaged_cb( + connection, + ); + } + + late final _connection_unset_ethernet_cable_state_chaged_cb_ptr = _lookup< + ffi.NativeFunction< + _c_connection_unset_ethernet_cable_state_chaged_cb>>( + 'connection_unset_ethernet_cable_state_chaged_cb'); + late final _dart_connection_unset_ethernet_cable_state_chaged_cb + _connection_unset_ethernet_cable_state_chaged_cb = + _connection_unset_ethernet_cable_state_chaged_cb_ptr + .asFunction<_dart_connection_unset_ethernet_cable_state_chaged_cb>(); + + /// @brief Registers callback for ethernet cable is plugged [in/out] event. + /// @since_tizen 4.0 + /// @param[in] connection The handle of connection + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_set_ethernet_cable_state_changed_cb( + ffi.Pointer connection, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _connection_set_ethernet_cable_state_changed_cb( + connection, + callback, + user_data, + ); + } + + late final _connection_set_ethernet_cable_state_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_connection_set_ethernet_cable_state_changed_cb>>( + 'connection_set_ethernet_cable_state_changed_cb'); + late final _dart_connection_set_ethernet_cable_state_changed_cb + _connection_set_ethernet_cable_state_changed_cb = + _connection_set_ethernet_cable_state_changed_cb_ptr + .asFunction<_dart_connection_set_ethernet_cable_state_changed_cb>(); + + /// @brief Unregisters callback for ethernet cable is plugged [in/out] event. + /// @since_tizen 4.0 + /// @param[in] connection The handle of connection + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_unset_ethernet_cable_state_changed_cb( + ffi.Pointer connection, + ) { + return _connection_unset_ethernet_cable_state_changed_cb( + connection, + ); + } + + late final _connection_unset_ethernet_cable_state_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_connection_unset_ethernet_cable_state_changed_cb>>( + 'connection_unset_ethernet_cable_state_changed_cb'); + late final _dart_connection_unset_ethernet_cable_state_changed_cb + _connection_unset_ethernet_cable_state_changed_cb = + _connection_unset_ethernet_cable_state_changed_cb_ptr + .asFunction<_dart_connection_unset_ethernet_cable_state_changed_cb>(); + + /// @brief Gets the state of the Bluetooth. + /// @details The returned state is for the Bluetooth connection state. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @param[in] connection The connection handle + /// @param[out] state The state of the Bluetooth connection + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_get_bt_state( + ffi.Pointer connection, + ffi.Pointer state, + ) { + return _connection_get_bt_state( + connection, + state, + ); + } + + late final _connection_get_bt_state_ptr = + _lookup>( + 'connection_get_bt_state'); + late final _dart_connection_get_bt_state _connection_get_bt_state = + _connection_get_bt_state_ptr.asFunction<_dart_connection_get_bt_state>(); + + /// @brief Registers the callback that is called when the type of the current connection is changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] connection The connection handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_set_type_changed_cb( + ffi.Pointer connection, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _connection_set_type_changed_cb( + connection, + callback, + user_data, + ); + } + + late final _connection_set_type_changed_cb_ptr = + _lookup>( + 'connection_set_type_changed_cb'); + late final _dart_connection_set_type_changed_cb + _connection_set_type_changed_cb = _connection_set_type_changed_cb_ptr + .asFunction<_dart_connection_set_type_changed_cb>(); + + /// @brief Unregisters the callback that is called when the type of current connection is changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] connection The connection handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_unset_type_changed_cb( + ffi.Pointer connection, + ) { + return _connection_unset_type_changed_cb( + connection, + ); + } + + late final _connection_unset_type_changed_cb_ptr = + _lookup>( + 'connection_unset_type_changed_cb'); + late final _dart_connection_unset_type_changed_cb + _connection_unset_type_changed_cb = _connection_unset_type_changed_cb_ptr + .asFunction<_dart_connection_unset_type_changed_cb>(); + + /// @brief Registers the callback that is called when the IP address is changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] connection The connection handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_set_ip_address_changed_cb( + ffi.Pointer connection, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _connection_set_ip_address_changed_cb( + connection, + callback, + user_data, + ); + } + + late final _connection_set_ip_address_changed_cb_ptr = + _lookup>( + 'connection_set_ip_address_changed_cb'); + late final _dart_connection_set_ip_address_changed_cb + _connection_set_ip_address_changed_cb = + _connection_set_ip_address_changed_cb_ptr + .asFunction<_dart_connection_set_ip_address_changed_cb>(); + + /// @brief Unregisters the callback that is called when the IP address is changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] connection The connection handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_unset_ip_address_changed_cb( + ffi.Pointer connection, + ) { + return _connection_unset_ip_address_changed_cb( + connection, + ); + } + + late final _connection_unset_ip_address_changed_cb_ptr = + _lookup>( + 'connection_unset_ip_address_changed_cb'); + late final _dart_connection_unset_ip_address_changed_cb + _connection_unset_ip_address_changed_cb = + _connection_unset_ip_address_changed_cb_ptr + .asFunction<_dart_connection_unset_ip_address_changed_cb>(); + + /// @brief Registers the callback that is called when the proxy address is changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] connection The connection handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_set_proxy_address_changed_cb( + ffi.Pointer connection, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _connection_set_proxy_address_changed_cb( + connection, + callback, + user_data, + ); + } + + late final _connection_set_proxy_address_changed_cb_ptr = + _lookup>( + 'connection_set_proxy_address_changed_cb'); + late final _dart_connection_set_proxy_address_changed_cb + _connection_set_proxy_address_changed_cb = + _connection_set_proxy_address_changed_cb_ptr + .asFunction<_dart_connection_set_proxy_address_changed_cb>(); + + /// @brief Unregisters the callback that is called when the proxy address is changed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] connection The connection handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + int connection_unset_proxy_address_changed_cb( + ffi.Pointer connection, + ) { + return _connection_unset_proxy_address_changed_cb( + connection, + ); + } + + late final _connection_unset_proxy_address_changed_cb_ptr = + _lookup>( + 'connection_unset_proxy_address_changed_cb'); + late final _dart_connection_unset_proxy_address_changed_cb + _connection_unset_proxy_address_changed_cb = + _connection_unset_proxy_address_changed_cb_ptr + .asFunction<_dart_connection_unset_proxy_address_changed_cb>(); + + /// @brief Adds a new profile which is created by connection_profile_create(). + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.profile + /// @remarks You can only add a profile of the cellular type. + /// @param[in] connection The connection handle + /// @param[in] profile The profile handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_add_profile( + ffi.Pointer connection, + ffi.Pointer profile, + ) { + return _connection_add_profile( + connection, + profile, + ); + } + + late final _connection_add_profile_ptr = + _lookup>( + 'connection_add_profile'); + late final _dart_connection_add_profile _connection_add_profile = + _connection_add_profile_ptr.asFunction<_dart_connection_add_profile>(); + + /// @brief Removes an existing profile. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.profile \n + /// %http://tizen.org/privilege/network.get + /// @remarks This API needs both privileges. + /// @param[in] connection The connection handle + /// @param[in] profile The profile handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_remove_profile( + ffi.Pointer connection, + ffi.Pointer profile, + ) { + return _connection_remove_profile( + connection, + profile, + ); + } + + late final _connection_remove_profile_ptr = + _lookup>( + 'connection_remove_profile'); + late final _dart_connection_remove_profile _connection_remove_profile = + _connection_remove_profile_ptr + .asFunction<_dart_connection_remove_profile>(); + + /// @brief Updates an existing profile. + /// @details When a profile is changed, these changes will be not applied to the + /// Connection Manager immediately. + /// When you call this function, your changes affect the Connection Manager + /// and the existing profile is updated. + /// In addition, the existing profile will be updated if you call connection_open_profile(). + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.profile \n + /// %http://tizen.org/privilege/network.get + /// @remarks This API needs both privileges. + /// @param[in] connection The connection handle + /// @param[in] profile The profile handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + /// @see connection_open_profile() + int connection_update_profile( + ffi.Pointer connection, + ffi.Pointer profile, + ) { + return _connection_update_profile( + connection, + profile, + ); + } + + late final _connection_update_profile_ptr = + _lookup>( + 'connection_update_profile'); + late final _dart_connection_update_profile _connection_update_profile = + _connection_update_profile_ptr + .asFunction<_dart_connection_update_profile>(); + + /// @brief Gets a profiles iterator. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @remarks You must release @a profile_iterator using connection_destroy(). + /// @param[in] connection The connection handle + /// @param[in] type The type of the connection iterator + /// @param[out] profile_iterator The iterator of profile + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + int connection_get_profile_iterator( + ffi.Pointer connection, + int type, + ffi.Pointer> profile_iterator, + ) { + return _connection_get_profile_iterator( + connection, + type, + profile_iterator, + ); + } + + late final _connection_get_profile_iterator_ptr = + _lookup>( + 'connection_get_profile_iterator'); + late final _dart_connection_get_profile_iterator + _connection_get_profile_iterator = _connection_get_profile_iterator_ptr + .asFunction<_dart_connection_get_profile_iterator>(); + + /// @brief Moves the profile iterator to the next position and gets a profile handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile_iterator The iterator of profile + /// @param[out] profile The profile handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_ITERATOR_END End of iteration + int connection_profile_iterator_next( + ffi.Pointer profile_iterator, + ffi.Pointer> profile, + ) { + return _connection_profile_iterator_next( + profile_iterator, + profile, + ); + } + + late final _connection_profile_iterator_next_ptr = + _lookup>( + 'connection_profile_iterator_next'); + late final _dart_connection_profile_iterator_next + _connection_profile_iterator_next = _connection_profile_iterator_next_ptr + .asFunction<_dart_connection_profile_iterator_next>(); + + /// @brief Checks whether the next element of a profile iterator exists or not. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks The specific error code can be obtained using the get_last_result() method. + /// Error codes are described in Exception section. + /// @param[in] profile_iterator The iterator of profile + /// @return @c true if next element exists, + /// otherwise @c false if next element doesn't exist + /// @exception #CONNECTION_ERROR_NONE Successful + /// @exception #CONNECTION_ERROR_NOT_SUPPORTED Not supported + /// @see get_last_result() + bool connection_profile_iterator_has_next( + ffi.Pointer profile_iterator, + ) { + return _connection_profile_iterator_has_next( + profile_iterator, + ) != + 0; + } + + late final _connection_profile_iterator_has_next_ptr = + _lookup>( + 'connection_profile_iterator_has_next'); + late final _dart_connection_profile_iterator_has_next + _connection_profile_iterator_has_next = + _connection_profile_iterator_has_next_ptr + .asFunction<_dart_connection_profile_iterator_has_next>(); + + /// @brief Destroys a profiles iterator. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] profile_iterator The iterator of the profile + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + int connection_destroy_profile_iterator( + ffi.Pointer profile_iterator, + ) { + return _connection_destroy_profile_iterator( + profile_iterator, + ); + } + + late final _connection_destroy_profile_iterator_ptr = + _lookup>( + 'connection_destroy_profile_iterator'); + late final _dart_connection_destroy_profile_iterator + _connection_destroy_profile_iterator = + _connection_destroy_profile_iterator_ptr + .asFunction<_dart_connection_destroy_profile_iterator>(); + + /// @brief Gets the name of the default profile. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @remarks You must release @a profile using connection_profile_destroy(). + /// @param[in] connection The connection handle + /// @param[out] profile The profile handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NO_CONNECTION There is no connection + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + int connection_get_current_profile( + ffi.Pointer connection, + ffi.Pointer> profile, + ) { + return _connection_get_current_profile( + connection, + profile, + ); + } + + late final _connection_get_current_profile_ptr = + _lookup>( + 'connection_get_current_profile'); + late final _dart_connection_get_current_profile + _connection_get_current_profile = _connection_get_current_profile_ptr + .asFunction<_dart_connection_get_current_profile>(); + + /// @brief Gets the default profile which provides the given cellular service. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @remarks You must release @a profile using connection_profile_destroy(). + /// @param[in] connection The connection handle + /// @param[in] type The type of cellular service \n + /// #CONNECTION_CELLULAR_SERVICE_TYPE_APPLICATION is not permitted + /// @param[out] profile The profile handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_get_default_cellular_service_profile( + ffi.Pointer connection, + int type, + ffi.Pointer> profile, + ) { + return _connection_get_default_cellular_service_profile( + connection, + type, + profile, + ); + } + + late final _connection_get_default_cellular_service_profile_ptr = _lookup< + ffi.NativeFunction< + _c_connection_get_default_cellular_service_profile>>( + 'connection_get_default_cellular_service_profile'); + late final _dart_connection_get_default_cellular_service_profile + _connection_get_default_cellular_service_profile = + _connection_get_default_cellular_service_profile_ptr + .asFunction<_dart_connection_get_default_cellular_service_profile>(); + + /// @brief Sets the default profile which provides the given cellular service. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.profile \n + /// %http://tizen.org/privilege/network.get + /// @remarks This API needs both privileges. + /// @param[in] connection The connection handle + /// @param[in] type The type of cellular service \n + /// Only #CONNECTION_CELLULAR_SERVICE_TYPE_INTERNET and + /// #CONNECTION_CELLULAR_SERVICE_TYPE_PREPAID_INTERNET are permitted + /// @param[in] profile The profile handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_set_default_cellular_service_profile( + ffi.Pointer connection, + int type, + ffi.Pointer profile, + ) { + return _connection_set_default_cellular_service_profile( + connection, + type, + profile, + ); + } + + late final _connection_set_default_cellular_service_profile_ptr = _lookup< + ffi.NativeFunction< + _c_connection_set_default_cellular_service_profile>>( + 'connection_set_default_cellular_service_profile'); + late final _dart_connection_set_default_cellular_service_profile + _connection_set_default_cellular_service_profile = + _connection_set_default_cellular_service_profile_ptr + .asFunction<_dart_connection_set_default_cellular_service_profile>(); + + /// @brief Sets the default profile which provides the given cellular service, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.profile \n + /// %http://tizen.org/privilege/network.get + /// @remarks This API needs both privileges. + /// @param[in] connection The connection handle + /// @param[in] type The type of cellular service \n + /// Only #CONNECTION_CELLULAR_SERVICE_TYPE_INTERNET and + /// #CONNECTION_CELLULAR_SERVICE_TYPE_PREPAID_INTERNET are permitted + /// @param[in] profile The profile handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_set_default_cellular_service_profile_async( + ffi.Pointer connection, + int type, + ffi.Pointer profile, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _connection_set_default_cellular_service_profile_async( + connection, + type, + profile, + callback, + user_data, + ); + } + + late final _connection_set_default_cellular_service_profile_async_ptr = + _lookup< + ffi.NativeFunction< + _c_connection_set_default_cellular_service_profile_async>>( + 'connection_set_default_cellular_service_profile_async'); + late final _dart_connection_set_default_cellular_service_profile_async + _connection_set_default_cellular_service_profile_async = + _connection_set_default_cellular_service_profile_async_ptr.asFunction< + _dart_connection_set_default_cellular_service_profile_async>(); + + /// @brief Opens a connection of profile, asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set \n + /// %http://tizen.org/privilege/network.get + /// @remarks This API needs both privileges. + /// @param[in] connection The connection handle + /// @param[in] profile The profile handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @post connection_opened_cb() will be invoked. + /// @see connection_opened_cb() + /// @see connection_close_profile() + /// @see connection_profile_set_state_changed_cb() + /// @see connection_profile_unset_state_changed_cb() + /// @see connection_profile_state_changed_cb() + int connection_open_profile( + ffi.Pointer connection, + ffi.Pointer profile, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _connection_open_profile( + connection, + profile, + callback, + user_data, + ); + } + + late final _connection_open_profile_ptr = + _lookup>( + 'connection_open_profile'); + late final _dart_connection_open_profile _connection_open_profile = + _connection_open_profile_ptr.asFunction<_dart_connection_open_profile>(); + + /// @brief Closes a connection of profile. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set + /// @param[in] connection The connection handle + /// @param[in] profile The profile handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @post connection_closed_cb() will be invoked. + /// @see connection_closed_cb() + /// @see connection_open_profile() + /// @see connection_profile_set_state_changed_cb() + /// @see connection_profile_unset_state_changed_cb() + /// @see connection_profile_state_changed_cb() + int connection_close_profile( + ffi.Pointer connection, + ffi.Pointer profile, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _connection_close_profile( + connection, + profile, + callback, + user_data, + ); + } + + late final _connection_close_profile_ptr = + _lookup>( + 'connection_close_profile'); + late final _dart_connection_close_profile _connection_close_profile = + _connection_close_profile_ptr + .asFunction<_dart_connection_close_profile>(); + + /// @brief Resets the cellular profile. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.profile \n + /// %http://tizen.org/privilege/network.get + /// @remarks This API needs both privileges. + /// @param[in] connection The connection handle + /// @param[in] type The type of reset + /// @param[in] id The subscriber identity module ID to reset + /// (The sim index starts from 0.) + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + /// @post connection_reset_cb() will be invoked. + int connection_reset_profile( + ffi.Pointer connection, + int type, + int id, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _connection_reset_profile( + connection, + type, + id, + callback, + user_data, + ); + } + + late final _connection_reset_profile_ptr = + _lookup>( + 'connection_reset_profile'); + late final _dart_connection_reset_profile _connection_reset_profile = + _connection_reset_profile_ptr + .asFunction<_dart_connection_reset_profile>(); + + /// @brief Adds a IPv4 route to the routing table. + /// @details You can get the @a interface_name from + /// connection_profile_get_network_interface_name() of opened profile. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set + /// @param[in] connection The connection handle + /// @param[in] interface_name The name of network interface + /// @param[in] host_address The IP address of the host + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_ALREADY_EXISTS Already exists + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @see connection_profile_get_network_interface_name() + int connection_add_route( + ffi.Pointer connection, + ffi.Pointer interface_name, + ffi.Pointer host_address, + ) { + return _connection_add_route( + connection, + interface_name, + host_address, + ); + } + + late final _connection_add_route_ptr = + _lookup>( + 'connection_add_route'); + late final _dart_connection_add_route _connection_add_route = + _connection_add_route_ptr.asFunction<_dart_connection_add_route>(); + + /// @deprecated Deprecated since 4.0. Use connection_remove_route_entry() instead. + /// @brief Removes a IPv4 route from the routing table. + /// @details You can get the @a interface_name from + /// connection_profile_get_network_interface_name() of opened profile. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set + /// @param[in] connection The connection handle + /// @param[in] interface_name The name of network interface + /// @param[in] host_address The IP address of the host + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @see connection_profile_get_network_interface_name() + int connection_remove_route( + ffi.Pointer connection, + ffi.Pointer interface_name, + ffi.Pointer host_address, + ) { + return _connection_remove_route( + connection, + interface_name, + host_address, + ); + } + + late final _connection_remove_route_ptr = + _lookup>( + 'connection_remove_route'); + late final _dart_connection_remove_route _connection_remove_route = + _connection_remove_route_ptr.asFunction<_dart_connection_remove_route>(); + + /// @deprecated Deprecated since 4.0. Use connection_add_route_entry() instead. + /// @brief Adds a IPv6 route to the routing table. + /// @details You can get the @a interface_name from + /// connection_profile_get_network_interface_name() of opened profile. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set + /// @param[in] connection The connection handle + /// @param[in] interface_name The name of network interface + /// @param[in] host_address The IP address of the host + /// @param[in] gateway The gateway address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_ALREADY_EXISTS Already exists + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @see connection_profile_get_network_interface_name() + int connection_add_route_ipv6( + ffi.Pointer connection, + ffi.Pointer interface_name, + ffi.Pointer host_address, + ffi.Pointer gateway, + ) { + return _connection_add_route_ipv6( + connection, + interface_name, + host_address, + gateway, + ); + } + + late final _connection_add_route_ipv6_ptr = + _lookup>( + 'connection_add_route_ipv6'); + late final _dart_connection_add_route_ipv6 _connection_add_route_ipv6 = + _connection_add_route_ipv6_ptr + .asFunction<_dart_connection_add_route_ipv6>(); + + /// @deprecated Deprecated since 4.0. Use connection_remove_route_entry() instead. + /// @brief Removes a IPV6 route from the routing table. + /// @details You can get the @a interface_name from + /// connection_profile_get_network_interface_name() of opened profile. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set + /// @param[in] connection The connection handle + /// @param[in] interface_name The name of network interface + /// @param[in] host_address The IP address of the host + /// @param[in] gateway The gateway address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @see connection_profile_get_network_interface_name() + int connection_remove_route_ipv6( + ffi.Pointer connection, + ffi.Pointer interface_name, + ffi.Pointer host_address, + ffi.Pointer gateway, + ) { + return _connection_remove_route_ipv6( + connection, + interface_name, + host_address, + gateway, + ); + } + + late final _connection_remove_route_ipv6_ptr = + _lookup>( + 'connection_remove_route_ipv6'); + late final _dart_connection_remove_route_ipv6 _connection_remove_route_ipv6 = + _connection_remove_route_ipv6_ptr + .asFunction<_dart_connection_remove_route_ipv6>(); + + /// @brief Adds a route to the routing table. + /// @details You can get the @a interface_name from \n + /// connection_profile_get_network_interface_name() of opened profile. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set + /// @param[in] connection The connection handle + /// @param[in] address_family The address family + /// @param[in] interface_name The name of network interface + /// @param[in] host_address The IP address of the host (e.g., single IP address such as + /// 163.152.10.2,192.168.1.2), group's IP address (e.g., 163.152.10.0, 192.168.0.0) + /// is not allowed + /// @param[in] gateway The gateway address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_ALREADY_EXISTS Already exists + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @see connection_profile_get_network_interface_name() + int connection_add_route_entry( + ffi.Pointer connection, + int address_family, + ffi.Pointer interface_name, + ffi.Pointer host_address, + ffi.Pointer gateway, + ) { + return _connection_add_route_entry( + connection, + address_family, + interface_name, + host_address, + gateway, + ); + } + + late final _connection_add_route_entry_ptr = + _lookup>( + 'connection_add_route_entry'); + late final _dart_connection_add_route_entry _connection_add_route_entry = + _connection_add_route_entry_ptr + .asFunction<_dart_connection_add_route_entry>(); + + /// @brief Removes a route from the routing table. + /// @details You can get the @a interface_name from \n + /// connection_profile_get_network_interface_name() of opened profile. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set + /// @param[in] connection The connection handle + /// @param[in] address_family The address family + /// @param[in] interface_name The name of network interface + /// @param[in] host_address The IP address of the host (e.g., single IP address such as + /// 163.152.10.2,192.168.1.2), group's IP address (e.g., 163.152.10.0, 192.168.0.0) + /// is not allowed + /// @param[in] gateway The gateway address + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @see connection_profile_get_network_interface_name() + int connection_remove_route_entry( + ffi.Pointer connection, + int address_family, + ffi.Pointer interface_name, + ffi.Pointer host_address, + ffi.Pointer gateway, + ) { + return _connection_remove_route_entry( + connection, + address_family, + interface_name, + host_address, + gateway, + ); + } + + late final _connection_remove_route_entry_ptr = + _lookup>( + 'connection_remove_route_entry'); + late final _dart_connection_remove_route_entry + _connection_remove_route_entry = _connection_remove_route_entry_ptr + .asFunction<_dart_connection_remove_route_entry>(); + + /// @brief Gets all IPv6 addresses assigned to the network interface. + /// @since_tizen 4.0 + /// @param[in] connection The connection handle + /// @param[in] connection_type The connection type + /// @param[in] callback The callback to be called for each IPv6 address + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value. + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_foreach_ipv6_address( + ffi.Pointer connection, + int connection_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _connection_foreach_ipv6_address( + connection, + connection_type, + callback, + user_data, + ); + } + + late final _connection_foreach_ipv6_address_ptr = + _lookup>( + 'connection_foreach_ipv6_address'); + late final _dart_connection_foreach_ipv6_address + _connection_foreach_ipv6_address = _connection_foreach_ipv6_address_ptr + .asFunction<_dart_connection_foreach_ipv6_address>(); + + /// @brief Gets the statistics information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @param[in] connection The connection handle + /// @param[in] connection_type The type of connection \n + /// Only CONNECTION_TYPE_WIFI and CONNECTION_TYPE_CELLULAR are supported + /// @param[in] statistics_type The type of statistics + /// @param[out] size The received data size of the last cellular packet data connection (bytes) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_get_statistics( + ffi.Pointer connection, + int connection_type, + int statistics_type, + ffi.Pointer size, + ) { + return _connection_get_statistics( + connection, + connection_type, + statistics_type, + size, + ); + } + + late final _connection_get_statistics_ptr = + _lookup>( + 'connection_get_statistics'); + late final _dart_connection_get_statistics _connection_get_statistics = + _connection_get_statistics_ptr + .asFunction<_dart_connection_get_statistics>(); + + /// @brief Resets the statistics information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set + /// @param[in] connection The connection handle + /// @param[in] connection_type The type of connection \n + /// Only CONNECTION_TYPE_WIFI and CONNECTION_TYPE_CELLULAR are supported + /// @param[in] statistics_type The type of statistics + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONNECTION_ERROR_NONE Successful + /// @retval #CONNECTION_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONNECTION_ERROR_OPERATION_FAILED Operation failed + /// @retval #CONNECTION_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CONNECTION_ERROR_NOT_SUPPORTED Not supported + int connection_reset_statistics( + ffi.Pointer connection, + int connection_type, + int statistics_type, + ) { + return _connection_reset_statistics( + connection, + connection_type, + statistics_type, + ); + } + + late final _connection_reset_statistics_ptr = + _lookup>( + 'connection_reset_statistics'); + late final _dart_connection_reset_statistics _connection_reset_statistics = + _connection_reset_statistics_ptr + .asFunction<_dart_connection_reset_statistics>(); + + /// @brief Initializes DNSSD. + /// @since_tizen 3.0 + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + int dnssd_initialize() { + return _dnssd_initialize(); + } + + late final _dnssd_initialize_ptr = + _lookup>('dnssd_initialize'); + late final _dart_dnssd_initialize _dnssd_initialize = + _dnssd_initialize_ptr.asFunction<_dart_dnssd_initialize>(); + + /// @brief Deinitializes DNSSD. + /// @since_tizen 3.0 + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_INVALID_OPERATION Invalid Operation + /// @pre DNS-SD service must be initialized by dnssd_initialize(). + int dnssd_deinitialize() { + return _dnssd_deinitialize(); + } + + late final _dnssd_deinitialize_ptr = + _lookup>('dnssd_deinitialize'); + late final _dart_dnssd_deinitialize _dnssd_deinitialize = + _dnssd_deinitialize_ptr.asFunction<_dart_dnssd_deinitialize>(); + + /// @brief Creates a DNSSD local service handle. + /// @since_tizen 3.0 + /// @remarks You must release @a dnssd_service using dnssd_destroy_local_service(). + /// @param[in] service_type The DNSSD service type. It is expressed as type + /// followed by protocol, separated by a dot(e.g. "_ftp._tcp"). It + /// must begin with an underscore, followed by 1-15 characters which + /// may be letters, digits, or hyphens. The transport protocol must be + /// "_tcp" or "_udp". New service types should be registered at + /// http://www.dns-sd.org/ServiceTypes.html. + /// @param[out] dnssd_service The DNSSD local handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + /// @see dnssd_destroy_local_service() + /// @pre This API needs dnssd_initialize() before use + int dnssd_create_local_service( + ffi.Pointer service_type, + ffi.Pointer dnssd_service, + ) { + return _dnssd_create_local_service( + service_type, + dnssd_service, + ); + } + + late final _dnssd_create_local_service_ptr = + _lookup>( + 'dnssd_create_local_service'); + late final _dart_dnssd_create_local_service _dnssd_create_local_service = + _dnssd_create_local_service_ptr + .asFunction<_dart_dnssd_create_local_service>(); + + /// @brief Destroys the DNSSD local service handle. + /// @details Destroying a local service doesn't deregister local service. If + /// local service was registered using dnssd_register_local_service(), + /// then it must be deregistered using dnssd_deregister_local_service() + /// before destroying the local service. + /// @since_tizen 3.0 + /// @remarks You must destroy only local services created using dnssd_create_local_service(). + /// @param[in] dnssd_service The DNSSD local service handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + /// @see dnssd_create_local_service() + /// @pre This API needs dnssd_create_local_service() before use. + int dnssd_destroy_local_service( + int dnssd_service, + ) { + return _dnssd_destroy_local_service( + dnssd_service, + ); + } + + late final _dnssd_destroy_local_service_ptr = + _lookup>( + 'dnssd_destroy_local_service'); + late final _dart_dnssd_destroy_local_service _dnssd_destroy_local_service = + _dnssd_destroy_local_service_ptr + .asFunction<_dart_dnssd_destroy_local_service>(); + + /// @brief Sets the name of DNSSD local service. + /// @details Application should set name after creating local service using + /// dnssd_create_local_service() and before registering the local + /// service using dnssd_register_local_service(). + /// @since_tizen 3.0 + /// @remarks You must pass only local services created using dnssd_create_local_service(). + /// @param[in] local_service The DNSSD local service handle + /// @param[in] service_name The name of DNSSD local service + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + /// @see dnssd_create_local_service() + /// @pre This API needs dnssd_create_local_service() before use. + int dnssd_service_set_name( + int local_service, + ffi.Pointer service_name, + ) { + return _dnssd_service_set_name( + local_service, + service_name, + ); + } + + late final _dnssd_service_set_name_ptr = + _lookup>( + 'dnssd_service_set_name'); + late final _dart_dnssd_service_set_name _dnssd_service_set_name = + _dnssd_service_set_name_ptr.asFunction<_dart_dnssd_service_set_name>(); + + /// @brief Sets the port number of DNSSD local service. + /// @details Application should set port after creating local service using + /// dnssd_create_local_service() and before registering the local + /// service using dnssd_register_local_service(). + /// @since_tizen 3.0 + /// @remarks You must pass only local services created using dnssd_create_local_service(). + /// @param[in] local_service The DNSSD local service handle + /// @param[in] port The port number of DNSSD local service + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + /// @see dnssd_create_local_service() + /// @pre This API needs dnssd_create_local_service() before use. + int dnssd_service_set_port( + int local_service, + int port, + ) { + return _dnssd_service_set_port( + local_service, + port, + ); + } + + late final _dnssd_service_set_port_ptr = + _lookup>( + 'dnssd_service_set_port'); + late final _dart_dnssd_service_set_port _dnssd_service_set_port = + _dnssd_service_set_port_ptr.asFunction<_dart_dnssd_service_set_port>(); + + /// @brief Adds the TXT record. + /// @details TXT record gives additional information about the service. + /// Some services discovered via dnssd_start_browsing_service() may + /// need more than just IP address and port number to completely + /// identify the service instance. For example, A web server typically + /// has multiple pages, each identified by its own URL. + /// So additional data is stored in a TXT record. Check Section 6 of + /// http://files.dns-sd.org/draft-cheshire-dnsext-dns-sd.txt + /// for details. TXT record of known service types can be found at + /// http://www.dns-sd.org/ServiceTypes.html. TXT record is stored in a + /// structured form using key/value pairs. + /// @since_tizen 3.0 + /// @remarks You must pass only local services created using dnssd_create_local_service(). + /// @param[in] local_service The DNSSD local service handle + /// @param[in] key The key of the TXT record. A null-terminated string which only + /// contains printable ASCII values (0x20-0x7E), excluding '=' (0x3D). + /// Keys should be 9 characters or fewer excluding NULL. Keys are case + /// insensitivie. Keys for known service types can be found at + /// http://www.dns-sd.org/ServiceTypes.html. For details, see section + /// 6.4 of http://files.dns-sd.org/draft-cheshire-dnsext-dns-sd.txt. + /// @param[in] length The length of the value of the TXT record in bytes. The + /// total size of a typical DNS-SD TXT record is intended to be small + /// (upto 200 bytes). For details, see section 6.2 of + /// http://files.dns-sd.org/draft-cheshire-dnsext-dns-sd.txt + /// @param[in] value The value of the TXT record. It can be any binary value. For + /// value that represents textual data, UTF-8 is STRONGLY recommended. + /// For value that represents textual data, value_length should NOT + /// include the terminating null (if any) at the end of the string. If + /// NULL, then "key" will be added with no value. If non-NULL but + /// value_length is zero, then "key=" will be added with empty value. + /// For details see section 6.5 of + /// http://files.dns-sd.org/draft-cheshire-dnsext-dns-sd.txt + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_SERVICE_NOT_RUNNING Service Not Running + /// @retval #DNSSD_ERROR_ALREADY_REGISTERED Already Registered + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + /// @retval #DNSSD_ERROR_OUT_OF_MEMORY Out of Memory + /// @see dnssd_create_local_service() + /// @pre This API needs dnssd_create_local_service() before use. + int dnssd_service_add_txt_record( + int local_service, + ffi.Pointer key, + int length, + ffi.Pointer value, + ) { + return _dnssd_service_add_txt_record( + local_service, + key, + length, + value, + ); + } + + late final _dnssd_service_add_txt_record_ptr = + _lookup>( + 'dnssd_service_add_txt_record'); + late final _dart_dnssd_service_add_txt_record _dnssd_service_add_txt_record = + _dnssd_service_add_txt_record_ptr + .asFunction<_dart_dnssd_service_add_txt_record>(); + + /// @brief Removes the TXT record. + /// @since_tizen 3.0 + /// @remarks You must pass only local services created using dnssd_create_local_service(). + /// @param[in] local_service The DNSSD local service handle + /// @param[in] key The key of the TXT record to be removed + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_SERVICE_NOT_RUNNING Service Not Running + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + /// @see dnssd_create_local_service() + /// @see dnssd_service_add_txt_record() + /// @pre This API needs dnssd_create_local_service() before use. + int dnssd_service_remove_txt_record( + int local_service, + ffi.Pointer key, + ) { + return _dnssd_service_remove_txt_record( + local_service, + key, + ); + } + + late final _dnssd_service_remove_txt_record_ptr = + _lookup>( + 'dnssd_service_remove_txt_record'); + late final _dart_dnssd_service_remove_txt_record + _dnssd_service_remove_txt_record = _dnssd_service_remove_txt_record_ptr + .asFunction<_dart_dnssd_service_remove_txt_record>(); + + /// @brief Sets/updates the DNS resource record. + /// @details If the resource record for the type has been previously added using + /// dnssd_service_set_record(), then the record will be updated. DNS + /// resource record can be set only after local_service is registered + /// using dnssd_register_local_service(). Data is added using + /// dnssd_service_add_txt_record() and then obtained using + /// dnssd_service_get_all_txt_record() to pass here. + /// @since_tizen 3.0 + /// @remarks You must pass only local services created using dnssd_create_local_service(). + /// @param[in] local_service The DNSSD local service handle + /// @param[in] type The resource record type. For details see, RFC 1035 and RFC 2782 + /// @param[in] length The length of the resource record in bytes + /// @param[in] data The data contained in resource record to be added + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_OPERATION_FAILED Operation failed + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_SERVICE_NOT_RUNNING Service Not Running + /// @retval #DNSSD_ERROR_ALREADY_REGISTERED Already Registered + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + /// @retval #DNSSD_ERROR_OUT_OF_MEMORY Out of Memory + /// @see dnssd_create_local_service() + /// @pre This API needs dnssd_create_local_service() before use. + int dnssd_service_set_record( + int local_service, + int type, + int length, + ffi.Pointer data, + ) { + return _dnssd_service_set_record( + local_service, + type, + length, + data, + ); + } + + late final _dnssd_service_set_record_ptr = + _lookup>( + 'dnssd_service_set_record'); + late final _dart_dnssd_service_set_record _dnssd_service_set_record = + _dnssd_service_set_record_ptr + .asFunction<_dart_dnssd_service_set_record>(); + + /// @brief Unsets the DNS resource record. DNS resource record for the given type + /// must be set using dnssd_service_set_record(). + /// @since_tizen 3.0 + /// @remarks You must pass only local services created using dnssd_create_local_service(). + /// @param[in] local_service The DNSSD local service handle + /// @param[in] type The resource record type. For details, see RFC 1035 and RFC 2782 + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_OPERATION_FAILED Operation failed + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_SERVICE_NOT_RUNNING Service Not Running + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + /// @see dnssd_create_local_service() + /// @pre This API needs dnssd_create_local_service() before use. + int dnssd_service_unset_record( + int local_service, + int type, + ) { + return _dnssd_service_unset_record( + local_service, + type, + ); + } + + late final _dnssd_service_unset_record_ptr = + _lookup>( + 'dnssd_service_unset_record'); + late final _dart_dnssd_service_unset_record _dnssd_service_unset_record = + _dnssd_service_unset_record_ptr + .asFunction<_dart_dnssd_service_unset_record>(); + + /// @brief Registers the DNSSD local service for publishing. + /// @since_tizen 3.0 + /// @remarks You must pass only local services created using dnssd_create_local_service(). + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] local_service The DNSSD local service handle + /// @param[in] register_cb The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_OPERATION_FAILED Operation failed + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_SERVICE_NOT_RUNNING Service Not Running + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + /// @retval #DNSSD_ERROR_PERMISSION_DENIED Permission Denied + /// @see dnssd_create_local_service() + /// @pre This API needs dnssd_create_local_service() before use. + int dnssd_register_local_service( + int local_service, + ffi.Pointer> register_cb, + ffi.Pointer user_data, + ) { + return _dnssd_register_local_service( + local_service, + register_cb, + user_data, + ); + } + + late final _dnssd_register_local_service_ptr = + _lookup>( + 'dnssd_register_local_service'); + late final _dart_dnssd_register_local_service _dnssd_register_local_service = + _dnssd_register_local_service_ptr + .asFunction<_dart_dnssd_register_local_service>(); + + /// @brief Deregisters the DNSSD local service. + /// @since_tizen 3.0 + /// @remarks You must pass only local services registered using dnssd_register_local_service(). + /// @param[in] local_service The DNSSD local service handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_SERVICE_NOT_RUNNING Service Not Running + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + /// @see dnssd_create_local_service() + /// @see dnssd_register_local_service() + /// @pre This API needs dnssd_register_local_service() before use. + int dnssd_deregister_local_service( + int local_service, + ) { + return _dnssd_deregister_local_service( + local_service, + ); + } + + late final _dnssd_deregister_local_service_ptr = + _lookup>( + 'dnssd_deregister_local_service'); + late final _dart_dnssd_deregister_local_service + _dnssd_deregister_local_service = _dnssd_deregister_local_service_ptr + .asFunction<_dart_dnssd_deregister_local_service>(); + + /// @brief Starts browsing the DNSSD remote service. + /// @details found_cb would be called only if there are any services available of + /// service_type provided in the argument. Application will keep + /// browsing for available/unavailable services until it calls + /// dnssd_stop_browsing_service(). + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] service_type The DNSSD service type to browse. It is expressed + /// as type followed by protocol, separated by a dot(e.g. "_ftp._tcp"). + /// It must begin with an underscore, followed by 1-15 characters + /// which may be letters, digits, or hyphens. The transport protocol + /// must be "_tcp" or "_udp". New service types should be registered + /// at http://www.dns-sd.org/ServiceTypes.html + /// @param[out] dnssd_service The DNSSD browse service handle + /// @param[in] found_cb The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_SERVICE_NOT_RUNNING Service Not Running + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + /// @retval #DNSSD_ERROR_PERMISSION_DENIED Permission Denied + /// @pre This API needs dnssd_initialize() before use. + int dnssd_start_browsing_service( + ffi.Pointer service_type, + ffi.Pointer dnssd_service, + ffi.Pointer> found_cb, + ffi.Pointer user_data, + ) { + return _dnssd_start_browsing_service( + service_type, + dnssd_service, + found_cb, + user_data, + ); + } + + late final _dnssd_start_browsing_service_ptr = + _lookup>( + 'dnssd_start_browsing_service'); + late final _dart_dnssd_start_browsing_service _dnssd_start_browsing_service = + _dnssd_start_browsing_service_ptr + .asFunction<_dart_dnssd_start_browsing_service>(); + + /// @brief Stops browsing the DNSSD remote service. + /// @since_tizen 3.0 + /// @param[in] dnssd_service The DNSSD browse service handle returned by + /// dnssd_start_browsing_service() + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_SERVICE_NOT_RUNNING Service Not Running + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + /// @pre This API needs dnssd_start_browsing_service() before use. + int dnssd_stop_browsing_service( + int dnssd_service, + ) { + return _dnssd_stop_browsing_service( + dnssd_service, + ); + } + + late final _dnssd_stop_browsing_service_ptr = + _lookup>( + 'dnssd_stop_browsing_service'); + late final _dart_dnssd_stop_browsing_service _dnssd_stop_browsing_service = + _dnssd_stop_browsing_service_ptr + .asFunction<_dart_dnssd_stop_browsing_service>(); + + /// @brief Gets the type of DNSSD local/remote service. + /// @since_tizen 3.0 + /// @remarks You must release @a service_type using free(). + /// @param[in] dnssd_service The DNSSD local/remote service handle + /// @param[out] service_type The type of DNSSD service. It is expressed as type + /// followed by protocol, separated by a dot(e.g. "_ftp._tcp"). It + /// must begin with an underscore, followed by 1-15 characters which + /// may be letters, digits, or hyphens. The transport protocol must be + /// "_tcp" or "_udp". New service types should be registered at + /// http://www.dns-sd.org/ServiceTypes.html + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + int dnssd_service_get_type( + int dnssd_service, + ffi.Pointer> service_type, + ) { + return _dnssd_service_get_type( + dnssd_service, + service_type, + ); + } + + late final _dnssd_service_get_type_ptr = + _lookup>( + 'dnssd_service_get_type'); + late final _dart_dnssd_service_get_type _dnssd_service_get_type = + _dnssd_service_get_type_ptr.asFunction<_dart_dnssd_service_get_type>(); + + /// @brief Gets the name of DNSSD local/remote service. + /// @since_tizen 3.0 + /// @remarks You must release @a service_name using free(). + /// @param[in] dnssd_service The DNSSD local/remote service handle + /// @param[out] service_name The name of DNSSD service + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + int dnssd_service_get_name( + int dnssd_service, + ffi.Pointer> service_name, + ) { + return _dnssd_service_get_name( + dnssd_service, + service_name, + ); + } + + late final _dnssd_service_get_name_ptr = + _lookup>( + 'dnssd_service_get_name'); + late final _dart_dnssd_service_get_name _dnssd_service_get_name = + _dnssd_service_get_name_ptr.asFunction<_dart_dnssd_service_get_name>(); + + /// @brief Gets the IP of DNSSD remote service. + /// @since_tizen 3.0 + /// @remarks You must release @a ip_v4_address, @a ip_v6_address using free(). + /// @param[in] dnssd_service The DNSSD remote service handle + /// @param[out] ip_v4_address The IP version 4 address of DNSSD service. If there + /// is no IPv4 Address, then it would contain NULL and should not be freed + /// @param[out] ip_v6_address The IP version 6 address of DNSSD service. If there + /// is no IPv6 Address, then it would contain NULL and should not be freed + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + int dnssd_service_get_ip( + int dnssd_service, + ffi.Pointer> ip_v4_address, + ffi.Pointer> ip_v6_address, + ) { + return _dnssd_service_get_ip( + dnssd_service, + ip_v4_address, + ip_v6_address, + ); + } + + late final _dnssd_service_get_ip_ptr = + _lookup>( + 'dnssd_service_get_ip'); + late final _dart_dnssd_service_get_ip _dnssd_service_get_ip = + _dnssd_service_get_ip_ptr.asFunction<_dart_dnssd_service_get_ip>(); + + /// @brief Gets the port number of DNSSD local/remote service. + /// @since_tizen 3.0 + /// @param[in] dnssd_service The DNSSD service local/remote handle + /// @param[out] port The port number of DNSSD service + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + int dnssd_service_get_port( + int dnssd_service, + ffi.Pointer port, + ) { + return _dnssd_service_get_port( + dnssd_service, + port, + ); + } + + late final _dnssd_service_get_port_ptr = + _lookup>( + 'dnssd_service_get_port'); + late final _dart_dnssd_service_get_port _dnssd_service_get_port = + _dnssd_service_get_port_ptr.asFunction<_dart_dnssd_service_get_port>(); + + /// @brief Gets the TXT record. + /// @details TXT record gives additional information about the service. Some + /// services discovered via dnssd_start_browsing_service() may need + /// more than just IP address and port number to completely identify + /// the service instance. For example, a web server typically has + /// multiple pages, each identified by its own URL. So additional data + /// is stored in a TXT record. Check Section 6 of + /// http://files.dns-sd.org/draft-cheshire-dnsext-dns-sd.txt for + /// details. TXT record of known service types can be found at + /// http://www.dns-sd.org/ServiceTypes.html. TXT record is stored in a + /// structured form using key/value pairs. + /// @since_tizen 3.0 + /// @remarks You must release @a value using free(). + /// @param[in] dnssd_service The DNSSD local/remote service handle + /// @param[out] length The length of the value of the TXT record in bytes + /// @param[out] value The value of the TXT record + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #DNSSD_ERROR_NONE Successful + /// @retval #DNSSD_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DNSSD_ERROR_NOT_SUPPORTED Not Supported + /// @retval #DNSSD_ERROR_OUT_OF_MEMORY Out of Memory + /// @retval #DNSSD_ERROR_SERVICE_NOT_RUNNING Service Not Running + /// @retval #DNSSD_ERROR_NOT_INITIALIZED Not Initialized + int dnssd_service_get_all_txt_record( + int dnssd_service, + ffi.Pointer length, + ffi.Pointer> value, + ) { + return _dnssd_service_get_all_txt_record( + dnssd_service, + length, + value, + ); + } + + late final _dnssd_service_get_all_txt_record_ptr = + _lookup>( + 'dnssd_service_get_all_txt_record'); + late final _dart_dnssd_service_get_all_txt_record + _dnssd_service_get_all_txt_record = _dnssd_service_get_all_txt_record_ptr + .asFunction<_dart_dnssd_service_get_all_txt_record>(); + + /// @brief Initializes the HTTP module. + /// @since_tizen 3.0 + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_OPERATION_FAILED Operation failed + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + /// @see http_deinit() + int http_init() { + return _http_init(); + } + + late final _http_init_ptr = + _lookup>('http_init'); + late final _dart_http_init _http_init = + _http_init_ptr.asFunction<_dart_http_init>(); + + /// @brief Deinitializes the HTTP module. + /// @since_tizen 3.0 + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_OPERATION_FAILED Operation failed + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + /// @see http_init() + int http_deinit() { + return _http_deinit(); + } + + late final _http_deinit_ptr = + _lookup>('http_deinit'); + late final _dart_http_deinit _http_deinit = + _http_deinit_ptr.asFunction<_dart_http_deinit>(); + + /// @brief Creates the HTTP session handle. + /// @since_tizen 3.0 + /// @remarks The @a http_session should be released using http_session_destroy(). + /// Opened transactions can't be submitted after destroying session handle. + /// @param[in] mode The HTTP session mode + /// @param[out] http_session The HTTP session handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + /// @see http_session_destroy() + int http_session_create( + int mode, + ffi.Pointer> http_session, + ) { + return _http_session_create( + mode, + http_session, + ); + } + + late final _http_session_create_ptr = + _lookup>( + 'http_session_create'); + late final _dart_http_session_create _http_session_create = + _http_session_create_ptr.asFunction<_dart_http_session_create>(); + + /// @brief Destroys the HTTP session handle. + /// @since_tizen 3.0 + /// @remarks http_session should be set to NULL after using it + /// @param[in] http_session The HTTP session handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + /// @see http_session_create() + int http_session_destroy( + ffi.Pointer http_session, + ) { + return _http_session_destroy( + http_session, + ); + } + + late final _http_session_destroy_ptr = + _lookup>( + 'http_session_destroy'); + late final _dart_http_session_destroy _http_session_destroy = + _http_session_destroy_ptr.asFunction<_dart_http_session_destroy>(); + + /// @brief Opens HTTP transaction from the HTTP Session. + /// @since_tizen 3.0 + /// @remarks The @a http_transaction should be released using http_transaction_destroy(). + /// @param[in] http_session The HTTP session handle + /// @param[in] method The HTTP request method + /// @param[out] http_transaction The HTTP transaction handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_session_open_transaction( + ffi.Pointer http_session, + int method, + ffi.Pointer> http_transaction, + ) { + return _http_session_open_transaction( + http_session, + method, + http_transaction, + ); + } + + late final _http_session_open_transaction_ptr = + _lookup>( + 'http_session_open_transaction'); + late final _dart_http_session_open_transaction + _http_session_open_transaction = _http_session_open_transaction_ptr + .asFunction<_dart_http_session_open_transaction>(); + + /// @brief Sets the value to redirect the HTTP request automatically. + /// @since_tizen 3.0 + /// @param[in] http_session The HTTP session handle + /// @param[in] auto_redirection The value which determines whether allow redirection or not + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + /// @see http_session_get_auto_redirection() + int http_session_set_auto_redirection( + ffi.Pointer http_session, + bool auto_redirection, + ) { + return _http_session_set_auto_redirection( + http_session, + auto_redirection ? 1 : 0, + ); + } + + late final _http_session_set_auto_redirection_ptr = + _lookup>( + 'http_session_set_auto_redirection'); + late final _dart_http_session_set_auto_redirection + _http_session_set_auto_redirection = + _http_session_set_auto_redirection_ptr + .asFunction<_dart_http_session_set_auto_redirection>(); + + /// @brief Gets the auto redirection for the HTTP request. + /// @since_tizen 3.0 + /// @param[in] http_session The HTTP session handle + /// @param[out] auto_redirect The value of auto redirect + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + /// @see http_session_set_auto_redirection() + int http_session_get_auto_redirection( + ffi.Pointer http_session, + ffi.Pointer auto_redirect, + ) { + return _http_session_get_auto_redirection( + http_session, + auto_redirect, + ); + } + + late final _http_session_get_auto_redirection_ptr = + _lookup>( + 'http_session_get_auto_redirection'); + late final _dart_http_session_get_auto_redirection + _http_session_get_auto_redirection = + _http_session_get_auto_redirection_ptr + .asFunction<_dart_http_session_get_auto_redirection>(); + + /// @brief Gets the number of active transactions in the current session. + /// @since_tizen 3.0 + /// @param[in] http_session The HTTP session handle + /// @param[out] active_transaction_count The number of activated transactions + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_session_get_active_transaction_count( + ffi.Pointer http_session, + ffi.Pointer active_transaction_count, + ) { + return _http_session_get_active_transaction_count( + http_session, + active_transaction_count, + ); + } + + late final _http_session_get_active_transaction_count_ptr = + _lookup>( + 'http_session_get_active_transaction_count'); + late final _dart_http_session_get_active_transaction_count + _http_session_get_active_transaction_count = + _http_session_get_active_transaction_count_ptr + .asFunction<_dart_http_session_get_active_transaction_count>(); + + /// @brief Gets the maximum number of transactions for the current session. + /// @since_tizen 3.0 + /// @param[in] http_session The HTTP session handle + /// @param[out] transaction_count The maximum transaction count + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_session_get_max_transaction_count( + ffi.Pointer http_session, + ffi.Pointer transaction_count, + ) { + return _http_session_get_max_transaction_count( + http_session, + transaction_count, + ); + } + + late final _http_session_get_max_transaction_count_ptr = + _lookup>( + 'http_session_get_max_transaction_count'); + late final _dart_http_session_get_max_transaction_count + _http_session_get_max_transaction_count = + _http_session_get_max_transaction_count_ptr + .asFunction<_dart_http_session_get_max_transaction_count>(); + + /// @brief Destroys all transactions. + /// @since_tizen 3.0 + /// @remarks All http_transactions should be set to NULL after using it + /// @param[in] http_session The HTTP session handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_OPERATION_FAILED Operation failed + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_session_destroy_all_transactions( + ffi.Pointer http_session, + ) { + return _http_session_destroy_all_transactions( + http_session, + ); + } + + late final _http_session_destroy_all_transactions_ptr = + _lookup>( + 'http_session_destroy_all_transactions'); + late final _dart_http_session_destroy_all_transactions + _http_session_destroy_all_transactions = + _http_session_destroy_all_transactions_ptr + .asFunction<_dart_http_session_destroy_all_transactions>(); + + /// @brief Submits the HTTP request. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet \n + /// %http://tizen.org/privilege/network.get + /// @param[in] http_transaction The HTTP transaction handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + /// @retval #HTTP_ERROR_PERMISSION_DENIED Permission denied + int http_transaction_submit( + ffi.Pointer http_transaction, + ) { + return _http_transaction_submit( + http_transaction, + ); + } + + late final _http_transaction_submit_ptr = + _lookup>( + 'http_transaction_submit'); + late final _dart_http_transaction_submit _http_transaction_submit = + _http_transaction_submit_ptr.asFunction<_dart_http_transaction_submit>(); + + /// @brief Closes the HTTP transaction handle. + /// @since_tizen 3.0 + /// @remarks The @a transaction is released by http_transaction_destroy(). + /// http_transaction should be set to NULL after using it. + /// @param[in] http_transaction The HTTP transaction handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + /// @see http_transaction_create() + int http_transaction_destroy( + ffi.Pointer http_transaction, + ) { + return _http_transaction_destroy( + http_transaction, + ); + } + + late final _http_transaction_destroy_ptr = + _lookup>( + 'http_transaction_destroy'); + late final _dart_http_transaction_destroy _http_transaction_destroy = + _http_transaction_destroy_ptr + .asFunction<_dart_http_transaction_destroy>(); + + /// @brief Registers callback called when receives header. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] header_cb The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_set_received_header_cb( + ffi.Pointer http_transaction, + ffi.Pointer> header_cb, + ffi.Pointer user_data, + ) { + return _http_transaction_set_received_header_cb( + http_transaction, + header_cb, + user_data, + ); + } + + late final _http_transaction_set_received_header_cb_ptr = + _lookup>( + 'http_transaction_set_received_header_cb'); + late final _dart_http_transaction_set_received_header_cb + _http_transaction_set_received_header_cb = + _http_transaction_set_received_header_cb_ptr + .asFunction<_dart_http_transaction_set_received_header_cb>(); + + /// @brief Registers callback called when receives body. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] body_cb The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_set_received_body_cb( + ffi.Pointer http_transaction, + ffi.Pointer> body_cb, + ffi.Pointer user_data, + ) { + return _http_transaction_set_received_body_cb( + http_transaction, + body_cb, + user_data, + ); + } + + late final _http_transaction_set_received_body_cb_ptr = + _lookup>( + 'http_transaction_set_received_body_cb'); + late final _dart_http_transaction_set_received_body_cb + _http_transaction_set_received_body_cb = + _http_transaction_set_received_body_cb_ptr + .asFunction<_dart_http_transaction_set_received_body_cb>(); + + /// @brief Registers callback called when writes data. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] write_cb The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_set_uploaded_cb( + ffi.Pointer http_transaction, + ffi.Pointer> write_cb, + ffi.Pointer user_data, + ) { + return _http_transaction_set_uploaded_cb( + http_transaction, + write_cb, + user_data, + ); + } + + late final _http_transaction_set_uploaded_cb_ptr = + _lookup>( + 'http_transaction_set_uploaded_cb'); + late final _dart_http_transaction_set_uploaded_cb + _http_transaction_set_uploaded_cb = _http_transaction_set_uploaded_cb_ptr + .asFunction<_dart_http_transaction_set_uploaded_cb>(); + + /// @brief Registers callback called when transaction is completed. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] completed_cb The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_set_completed_cb( + ffi.Pointer http_transaction, + ffi.Pointer> completed_cb, + ffi.Pointer user_data, + ) { + return _http_transaction_set_completed_cb( + http_transaction, + completed_cb, + user_data, + ); + } + + late final _http_transaction_set_completed_cb_ptr = + _lookup>( + 'http_transaction_set_completed_cb'); + late final _dart_http_transaction_set_completed_cb + _http_transaction_set_completed_cb = + _http_transaction_set_completed_cb_ptr + .asFunction<_dart_http_transaction_set_completed_cb>(); + + /// @brief Registers callback called when transaction is aborted. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] aborted_cb The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_set_aborted_cb( + ffi.Pointer http_transaction, + ffi.Pointer> aborted_cb, + ffi.Pointer user_data, + ) { + return _http_transaction_set_aborted_cb( + http_transaction, + aborted_cb, + user_data, + ); + } + + late final _http_transaction_set_aborted_cb_ptr = + _lookup>( + 'http_transaction_set_aborted_cb'); + late final _dart_http_transaction_set_aborted_cb + _http_transaction_set_aborted_cb = _http_transaction_set_aborted_cb_ptr + .asFunction<_dart_http_transaction_set_aborted_cb>(); + + /// @brief Registers the progress callbacks. + /// @details Registers callback that is called when data is uploaded/downloaded. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] progress_cb The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_set_progress_cb( + ffi.Pointer http_transaction, + ffi.Pointer> progress_cb, + ffi.Pointer user_data, + ) { + return _http_transaction_set_progress_cb( + http_transaction, + progress_cb, + user_data, + ); + } + + late final _http_transaction_set_progress_cb_ptr = + _lookup>( + 'http_transaction_set_progress_cb'); + late final _dart_http_transaction_set_progress_cb + _http_transaction_set_progress_cb = _http_transaction_set_progress_cb_ptr + .asFunction<_dart_http_transaction_set_progress_cb>(); + + /// @brief Sets the timeout in seconds that is the timeout for waiting the transaction. + /// @details Sets the timeout in seconds that is the timeout for waiting the transaction. \n + /// A timeout value of zero means an infinite timeout. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] timeout The timeout in seconds + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_set_timeout( + ffi.Pointer http_transaction, + int timeout, + ) { + return _http_transaction_set_timeout( + http_transaction, + timeout, + ); + } + + late final _http_transaction_set_timeout_ptr = + _lookup>( + 'http_transaction_set_timeout'); + late final _dart_http_transaction_set_timeout _http_transaction_set_timeout = + _http_transaction_set_timeout_ptr + .asFunction<_dart_http_transaction_set_timeout>(); + + /// @brief Gets the timeout in seconds for the transaction. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] timeout The timeout in seconds + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_get_timeout( + ffi.Pointer http_transaction, + ffi.Pointer timeout, + ) { + return _http_transaction_get_timeout( + http_transaction, + timeout, + ); + } + + late final _http_transaction_get_timeout_ptr = + _lookup>( + 'http_transaction_get_timeout'); + late final _dart_http_transaction_get_timeout _http_transaction_get_timeout = + _http_transaction_get_timeout_ptr + .asFunction<_dart_http_transaction_get_timeout>(); + + /// @brief Resumes the transaction. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_OPERATION_FAILED Operation failed + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_resume( + ffi.Pointer http_transaction, + ) { + return _http_transaction_resume( + http_transaction, + ); + } + + late final _http_transaction_resume_ptr = + _lookup>( + 'http_transaction_resume'); + late final _dart_http_transaction_resume _http_transaction_resume = + _http_transaction_resume_ptr.asFunction<_dart_http_transaction_resume>(); + + /// @brief Pauses the transaction. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] pause_type The pause type of the connection + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_OPERATION_FAILED Operation failed + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_pause( + ffi.Pointer http_transaction, + int pause_type, + ) { + return _http_transaction_pause( + http_transaction, + pause_type, + ); + } + + late final _http_transaction_pause_ptr = + _lookup>( + 'http_transaction_pause'); + late final _dart_http_transaction_pause _http_transaction_pause = + _http_transaction_pause_ptr.asFunction<_dart_http_transaction_pause>(); + + /// @brief Cancels the transaction. + /// @details This function cancels the transaction.\n + /// The aborted callback is invoked after using it. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_OPERATION_FAILED Operation failed + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_cancel( + ffi.Pointer http_transaction, + ) { + return _http_transaction_cancel( + http_transaction, + ); + } + + late final _http_transaction_cancel_ptr = + _lookup>( + 'http_transaction_cancel'); + late final _dart_http_transaction_cancel _http_transaction_cancel = + _http_transaction_cancel_ptr.asFunction<_dart_http_transaction_cancel>(); + + /// @brief Sets ready to write event for a transaction. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] read_to_write Enable/disable ready to write + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_set_ready_to_write( + ffi.Pointer http_transaction, + bool read_to_write, + ) { + return _http_transaction_set_ready_to_write( + http_transaction, + read_to_write ? 1 : 0, + ); + } + + late final _http_transaction_set_ready_to_write_ptr = + _lookup>( + 'http_transaction_set_ready_to_write'); + late final _dart_http_transaction_set_ready_to_write + _http_transaction_set_ready_to_write = + _http_transaction_set_ready_to_write_ptr + .asFunction<_dart_http_transaction_set_ready_to_write>(); + + /// @brief Sets the interface name. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] interface_name The interface name to use as outgoing network interface + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_set_interface_name( + ffi.Pointer http_transaction, + ffi.Pointer interface_name, + ) { + return _http_transaction_set_interface_name( + http_transaction, + interface_name, + ); + } + + late final _http_transaction_set_interface_name_ptr = + _lookup>( + 'http_transaction_set_interface_name'); + late final _dart_http_transaction_set_interface_name + _http_transaction_set_interface_name = + _http_transaction_set_interface_name_ptr + .asFunction<_dart_http_transaction_set_interface_name>(); + + /// @brief Gets the interface name. + /// @since_tizen 3.0 + /// @remarks The @a interface_name should be freed using free(). + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] interface_name The interface name + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_get_interface_name( + ffi.Pointer http_transaction, + ffi.Pointer> interface_name, + ) { + return _http_transaction_get_interface_name( + http_transaction, + interface_name, + ); + } + + late final _http_transaction_get_interface_name_ptr = + _lookup>( + 'http_transaction_get_interface_name'); + late final _dart_http_transaction_get_interface_name + _http_transaction_get_interface_name = + _http_transaction_get_interface_name_ptr + .asFunction<_dart_http_transaction_get_interface_name>(); + + /// @brief Sets the flag to verify a server certificate. + /// @details The verify determines whether verifies the peer's certificate. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] verify The flag to verify a server certificate; true means verifies; false means it doesn't. + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_set_server_certificate_verification( + ffi.Pointer http_transaction, + bool verify, + ) { + return _http_transaction_set_server_certificate_verification( + http_transaction, + verify ? 1 : 0, + ); + } + + late final _http_transaction_set_server_certificate_verification_ptr = + _lookup< + ffi.NativeFunction< + _c_http_transaction_set_server_certificate_verification>>( + 'http_transaction_set_server_certificate_verification'); + late final _dart_http_transaction_set_server_certificate_verification + _http_transaction_set_server_certificate_verification = + _http_transaction_set_server_certificate_verification_ptr.asFunction< + _dart_http_transaction_set_server_certificate_verification>(); + + /// @brief Gets the flag to verify a server certificate. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] verify The flag to verify a server certificate; true means verifies; false means it doesn't. + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_get_server_certificate_verification( + ffi.Pointer http_transaction, + ffi.Pointer verify, + ) { + return _http_transaction_get_server_certificate_verification( + http_transaction, + verify, + ); + } + + late final _http_transaction_get_server_certificate_verification_ptr = + _lookup< + ffi.NativeFunction< + _c_http_transaction_get_server_certificate_verification>>( + 'http_transaction_get_server_certificate_verification'); + late final _dart_http_transaction_get_server_certificate_verification + _http_transaction_get_server_certificate_verification = + _http_transaction_get_server_certificate_verification_ptr.asFunction< + _dart_http_transaction_get_server_certificate_verification>(); + + /// @brief Adds a named field to header. + /// @details Adds a named field, which is a <@c fieldName, @c fieldValue> pair, to the current instance of HTTP Transaction. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] field_name The HTTP Header Field name + /// @param[in] field_value The HTTP Header Field value + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_header_add_field( + ffi.Pointer http_transaction, + ffi.Pointer field_name, + ffi.Pointer field_value, + ) { + return _http_transaction_header_add_field( + http_transaction, + field_name, + field_value, + ); + } + + late final _http_transaction_header_add_field_ptr = + _lookup>( + 'http_transaction_header_add_field'); + late final _dart_http_transaction_header_add_field + _http_transaction_header_add_field = + _http_transaction_header_add_field_ptr + .asFunction<_dart_http_transaction_header_add_field>(); + + /// @brief Removes the named field from header. + /// @details Remove the named field, which is a <@c fieldName, @c fieldValue> pair, from the current instance of HTTP Transaction. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] field_name The HTTP Header Field name + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_header_remove_field( + ffi.Pointer http_transaction, + ffi.Pointer field_name, + ) { + return _http_transaction_header_remove_field( + http_transaction, + field_name, + ); + } + + late final _http_transaction_header_remove_field_ptr = + _lookup>( + 'http_transaction_header_remove_field'); + late final _dart_http_transaction_header_remove_field + _http_transaction_header_remove_field = + _http_transaction_header_remove_field_ptr + .asFunction<_dart_http_transaction_header_remove_field>(); + + /// @brief Gets the HTTP Header Field value from custom header. + /// @since_tizen 3.0 + /// @remarks The @a field_value should be freed using free(). + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] field_name The HTTP Header Field name + /// @param[out] field_value The HTTP Header Field value + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_header_get_field_value( + ffi.Pointer http_transaction, + ffi.Pointer field_name, + ffi.Pointer> field_value, + ) { + return _http_transaction_header_get_field_value( + http_transaction, + field_name, + field_value, + ); + } + + late final _http_transaction_header_get_field_value_ptr = + _lookup>( + 'http_transaction_header_get_field_value'); + late final _dart_http_transaction_header_get_field_value + _http_transaction_header_get_field_value = + _http_transaction_header_get_field_value_ptr + .asFunction<_dart_http_transaction_header_get_field_value>(); + + /// @brief Sets an HTTP method of the request header. + /// @details Sets an HTTP method such as GET, POST, PUT and etc. + /// @since_tizen 3.0 + /// @remarks The default method is GET. + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] method The HTTP method + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_request_set_method( + ffi.Pointer http_transaction, + int method, + ) { + return _http_transaction_request_set_method( + http_transaction, + method, + ); + } + + late final _http_transaction_request_set_method_ptr = + _lookup>( + 'http_transaction_request_set_method'); + late final _dart_http_transaction_request_set_method + _http_transaction_request_set_method = + _http_transaction_request_set_method_ptr + .asFunction<_dart_http_transaction_request_set_method>(); + + /// @brief Gets the HTTP method from request header. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] method The HTTP method + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_request_get_method( + ffi.Pointer http_transaction, + ffi.Pointer method, + ) { + return _http_transaction_request_get_method( + http_transaction, + method, + ); + } + + late final _http_transaction_request_get_method_ptr = + _lookup>( + 'http_transaction_request_get_method'); + late final _dart_http_transaction_request_get_method + _http_transaction_request_get_method = + _http_transaction_request_get_method_ptr + .asFunction<_dart_http_transaction_request_get_method>(); + + /// @brief Sets an HTTP version of the request header. + /// @since_tizen 3.0 + /// @remarks The default version is HTTP 1.1. + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] version The HTTP version + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_request_set_version( + ffi.Pointer http_transaction, + int version, + ) { + return _http_transaction_request_set_version( + http_transaction, + version, + ); + } + + late final _http_transaction_request_set_version_ptr = + _lookup>( + 'http_transaction_request_set_version'); + late final _dart_http_transaction_request_set_version + _http_transaction_request_set_version = + _http_transaction_request_set_version_ptr + .asFunction<_dart_http_transaction_request_set_version>(); + + /// @brief Gets the HTTP version from request header. + /// @details Gets the HTTP version. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] version The HTTP version + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_request_get_version( + ffi.Pointer http_transaction, + ffi.Pointer version, + ) { + return _http_transaction_request_get_version( + http_transaction, + version, + ); + } + + late final _http_transaction_request_get_version_ptr = + _lookup>( + 'http_transaction_request_get_version'); + late final _dart_http_transaction_request_get_version + _http_transaction_request_get_version = + _http_transaction_request_get_version_ptr + .asFunction<_dart_http_transaction_request_get_version>(); + + /// @brief Sets a URI of the request header. + /// @details Sets a URI of the request header. + /// @since_tizen 3.0 + /// @remarks It should be used before http_transaction_submit(). + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] host_uri The URI to use in the request + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_request_set_uri( + ffi.Pointer http_transaction, + ffi.Pointer host_uri, + ) { + return _http_transaction_request_set_uri( + http_transaction, + host_uri, + ); + } + + late final _http_transaction_request_set_uri_ptr = + _lookup>( + 'http_transaction_request_set_uri'); + late final _dart_http_transaction_request_set_uri + _http_transaction_request_set_uri = _http_transaction_request_set_uri_ptr + .asFunction<_dart_http_transaction_request_set_uri>(); + + /// @brief Gets the URI. + /// @since_tizen 3.0 + /// @remarks The @a host_uri should be freed using free(). + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] host_uri The host URI + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_request_get_uri( + ffi.Pointer http_transaction, + ffi.Pointer> host_uri, + ) { + return _http_transaction_request_get_uri( + http_transaction, + host_uri, + ); + } + + late final _http_transaction_request_get_uri_ptr = + _lookup>( + 'http_transaction_request_get_uri'); + late final _dart_http_transaction_request_get_uri + _http_transaction_request_get_uri = _http_transaction_request_get_uri_ptr + .asFunction<_dart_http_transaction_request_get_uri>(); + + /// @brief Sets the Accept-Encoding header field of HTTP Request. + /// @details The Accept-Encoding header enables automatic decompression of HTTP downloads. + /// @since_tizen 3.0 + /// @remarks If empty string is set, an Accept-Encoding header contains all supported built-in compressions. + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] encoding The encoding algorithms (e.g. gzip, deflate) + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_request_set_accept_encoding( + ffi.Pointer http_transaction, + ffi.Pointer encoding, + ) { + return _http_transaction_request_set_accept_encoding( + http_transaction, + encoding, + ); + } + + late final _http_transaction_request_set_accept_encoding_ptr = _lookup< + ffi.NativeFunction<_c_http_transaction_request_set_accept_encoding>>( + 'http_transaction_request_set_accept_encoding'); + late final _dart_http_transaction_request_set_accept_encoding + _http_transaction_request_set_accept_encoding = + _http_transaction_request_set_accept_encoding_ptr + .asFunction<_dart_http_transaction_request_set_accept_encoding>(); + + /// @brief Gets the Accept-Encoding header field of HTTP Request. + /// @since_tizen 3.0 + /// @remarks The @a encoding should be freed using free(). + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] encoding The encoding algorithms + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_request_get_accept_encoding( + ffi.Pointer http_transaction, + ffi.Pointer> encoding, + ) { + return _http_transaction_request_get_accept_encoding( + http_transaction, + encoding, + ); + } + + late final _http_transaction_request_get_accept_encoding_ptr = _lookup< + ffi.NativeFunction<_c_http_transaction_request_get_accept_encoding>>( + 'http_transaction_request_get_accept_encoding'); + late final _dart_http_transaction_request_get_accept_encoding + _http_transaction_request_get_accept_encoding = + _http_transaction_request_get_accept_encoding_ptr + .asFunction<_dart_http_transaction_request_get_accept_encoding>(); + + /// @brief Sets a cookie in the HTTP request. + /// @since_tizen 3.0 + /// @remarks The format of string should be NME=CONTENTS (e.g. "name1=hello; name2=tizen;") + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] cookie The cookie + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_request_set_cookie( + ffi.Pointer http_transaction, + ffi.Pointer cookie, + ) { + return _http_transaction_request_set_cookie( + http_transaction, + cookie, + ); + } + + late final _http_transaction_request_set_cookie_ptr = + _lookup>( + 'http_transaction_request_set_cookie'); + late final _dart_http_transaction_request_set_cookie + _http_transaction_request_set_cookie = + _http_transaction_request_set_cookie_ptr + .asFunction<_dart_http_transaction_request_set_cookie>(); + + /// @brief Gets a cookie in the HTTP request. + /// @since_tizen 3.0 + /// @remarks The @a cookie should be freed using free(). + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] cookie The cookie + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_request_get_cookie( + ffi.Pointer http_transaction, + ffi.Pointer> cookie, + ) { + return _http_transaction_request_get_cookie( + http_transaction, + cookie, + ); + } + + late final _http_transaction_request_get_cookie_ptr = + _lookup>( + 'http_transaction_request_get_cookie'); + late final _dart_http_transaction_request_get_cookie + _http_transaction_request_get_cookie = + _http_transaction_request_get_cookie_ptr + .asFunction<_dart_http_transaction_request_get_cookie>(); + + /// @brief Writes the request message body. + /// @details This function writes the request message body in the internal queue. \n + /// The written queue for request body is uploaded after invoking http_transaction_submit(). + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] body The message body data + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_request_write_body( + ffi.Pointer http_transaction, + ffi.Pointer body, + ) { + return _http_transaction_request_write_body( + http_transaction, + body, + ); + } + + late final _http_transaction_request_write_body_ptr = + _lookup>( + 'http_transaction_request_write_body'); + late final _dart_http_transaction_request_write_body + _http_transaction_request_write_body = + _http_transaction_request_write_body_ptr + .asFunction<_dart_http_transaction_request_write_body>(); + + /// @brief Sets the file path for uploading a file. + /// @since_tizen 3.0 + /// @remarks It is used with #HTTP_METHOD_PUT. \n + /// http://tizen.org/privilege/mediastorage is needed if input or output path are relevant to media storage. \n + /// http://tizen.org/privilege/externalstorage is needed if input or output path are relevant to external storage. + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] file_path The path for file + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_request_set_upload_file( + ffi.Pointer http_transaction, + ffi.Pointer file_path, + ) { + return _http_transaction_request_set_upload_file( + http_transaction, + file_path, + ); + } + + late final _http_transaction_request_set_upload_file_ptr = + _lookup>( + 'http_transaction_request_set_upload_file'); + late final _dart_http_transaction_request_set_upload_file + _http_transaction_request_set_upload_file = + _http_transaction_request_set_upload_file_ptr + .asFunction<_dart_http_transaction_request_set_upload_file>(); + + /// @brief Gets the HTTP status code from HTTP Response. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] status_code The HTTP status code + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_response_get_status_code( + ffi.Pointer http_transaction, + ffi.Pointer status_code, + ) { + return _http_transaction_response_get_status_code( + http_transaction, + status_code, + ); + } + + late final _http_transaction_response_get_status_code_ptr = + _lookup>( + 'http_transaction_response_get_status_code'); + late final _dart_http_transaction_response_get_status_code + _http_transaction_response_get_status_code = + _http_transaction_response_get_status_code_ptr + .asFunction<_dart_http_transaction_response_get_status_code>(); + + /// @brief Gets the HTTP status text from HTTP Response. + /// @since_tizen 3.0 + /// @remarks The @a status_text should be freed using free(). + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] status_text The HTTP status text + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_response_get_status_text( + ffi.Pointer http_transaction, + ffi.Pointer> status_text, + ) { + return _http_transaction_response_get_status_text( + http_transaction, + status_text, + ); + } + + late final _http_transaction_response_get_status_text_ptr = + _lookup>( + 'http_transaction_response_get_status_text'); + late final _dart_http_transaction_response_get_status_text + _http_transaction_response_get_status_text = + _http_transaction_response_get_status_text_ptr + .asFunction<_dart_http_transaction_response_get_status_text>(); + + /// @brief Gets the HTTP version from HTTP Response. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] version The HTTP version + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_response_get_version( + ffi.Pointer http_transaction, + ffi.Pointer version, + ) { + return _http_transaction_response_get_version( + http_transaction, + version, + ); + } + + late final _http_transaction_response_get_version_ptr = + _lookup>( + 'http_transaction_response_get_version'); + late final _dart_http_transaction_response_get_version + _http_transaction_response_get_version = + _http_transaction_response_get_version_ptr + .asFunction<_dart_http_transaction_response_get_version>(); + + /// @brief Opens HTTP transaction with authentication information. + /// @since_tizen 3.0 + /// @remarks The @a http_auth_transaction should be released using http_transaction_destroy(). + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] http_auth_transaction The HTTP transaction handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_open_authentication( + ffi.Pointer http_transaction, + ffi.Pointer> http_auth_transaction, + ) { + return _http_transaction_open_authentication( + http_transaction, + http_auth_transaction, + ); + } + + late final _http_transaction_open_authentication_ptr = + _lookup>( + 'http_transaction_open_authentication'); + late final _dart_http_transaction_open_authentication + _http_transaction_open_authentication = + _http_transaction_open_authentication_ptr + .asFunction<_dart_http_transaction_open_authentication>(); + + /// @brief Sets an HTTP credentials. + /// @details Sets an HTTP authentication scheme such as username and password. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] user_name The HTTP user name + /// @param[in] password The HTTP password + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_set_credentials( + ffi.Pointer http_transaction, + ffi.Pointer user_name, + ffi.Pointer password, + ) { + return _http_transaction_set_credentials( + http_transaction, + user_name, + password, + ); + } + + late final _http_transaction_set_credentials_ptr = + _lookup>( + 'http_transaction_set_credentials'); + late final _dart_http_transaction_set_credentials + _http_transaction_set_credentials = _http_transaction_set_credentials_ptr + .asFunction<_dart_http_transaction_set_credentials>(); + + /// @brief Gets the username & password for the HTTP credential. + /// @since_tizen 3.0 + /// @remarks The @a user_name & @a password should be freed using free(). + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] user_name The HTTP credential user name + /// @param[out] password The HTTP credential password + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_get_credentials( + ffi.Pointer http_transaction, + ffi.Pointer> user_name, + ffi.Pointer> password, + ) { + return _http_transaction_get_credentials( + http_transaction, + user_name, + password, + ); + } + + late final _http_transaction_get_credentials_ptr = + _lookup>( + 'http_transaction_get_credentials'); + late final _dart_http_transaction_get_credentials + _http_transaction_get_credentials = _http_transaction_get_credentials_ptr + .asFunction<_dart_http_transaction_get_credentials>(); + + /// @brief Sets an HTTP authentication scheme. + /// @details Set an HTTP authentication scheme such as BASIC, MD5, NTLM and etc. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[in] auth_scheme The HTTP authentication scheme + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_set_http_auth_scheme( + ffi.Pointer http_transaction, + int auth_scheme, + ) { + return _http_transaction_set_http_auth_scheme( + http_transaction, + auth_scheme, + ); + } + + late final _http_transaction_set_http_auth_scheme_ptr = + _lookup>( + 'http_transaction_set_http_auth_scheme'); + late final _dart_http_transaction_set_http_auth_scheme + _http_transaction_set_http_auth_scheme = + _http_transaction_set_http_auth_scheme_ptr + .asFunction<_dart_http_transaction_set_http_auth_scheme>(); + + /// @brief Gets the HTTP authentication scheme. + /// @since_tizen 3.0 + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] auth_scheme The HTTP auth scheme value + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_get_http_auth_scheme( + ffi.Pointer http_transaction, + ffi.Pointer auth_scheme, + ) { + return _http_transaction_get_http_auth_scheme( + http_transaction, + auth_scheme, + ); + } + + late final _http_transaction_get_http_auth_scheme_ptr = + _lookup>( + 'http_transaction_get_http_auth_scheme'); + late final _dart_http_transaction_get_http_auth_scheme + _http_transaction_get_http_auth_scheme = + _http_transaction_get_http_auth_scheme_ptr + .asFunction<_dart_http_transaction_get_http_auth_scheme>(); + + /// @brief Gets the HTTP authentication realm. + /// @since_tizen 3.0 + /// @remarks The @a realm should be freed using free(). + /// @param[in] http_transaction The HTTP transaction handle + /// @param[out] realm The HTTP authentication realm value + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #HTTP_ERROR_NONE Successful + /// @retval #HTTP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #HTTP_ERROR_INVALID_OPERATION Invalid operation + /// @retval #HTTP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #HTTP_ERROR_NOT_SUPPORTED Not Supported + int http_transaction_get_realm( + ffi.Pointer http_transaction, + ffi.Pointer> realm, + ) { + return _http_transaction_get_realm( + http_transaction, + realm, + ); + } + + late final _http_transaction_get_realm_ptr = + _lookup>( + 'http_transaction_get_realm'); + late final _dart_http_transaction_get_realm _http_transaction_get_realm = + _http_transaction_get_realm_ptr + .asFunction<_dart_http_transaction_get_realm>(); + + /// @brief Creates a new list handle. + /// @since_tizen 3.0 + /// @remarks You must destroy @a list by calling iotcon_list_destroy() if @a list is no longer needed. + /// @param[in] type The type of list + /// @param[out] list A newly allocated list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_list_create( + int type, + ffi.Pointer> list, + ) { + return _iotcon_list_create( + type, + list, + ); + } + + late final _iotcon_list_create_ptr = + _lookup>('iotcon_list_create'); + late final _dart_iotcon_list_create _iotcon_list_create = + _iotcon_list_create_ptr.asFunction<_dart_iotcon_list_create>(); + + /// @brief Destroys a list handle. + /// @details Releases a @a list and its internal data. + /// @since_tizen 3.0 + /// @param[in] list The handle to the list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_list_destroy( + ffi.Pointer list, + ) { + return _iotcon_list_destroy( + list, + ); + } + + late final _iotcon_list_destroy_ptr = + _lookup>( + 'iotcon_list_destroy'); + late final _dart_iotcon_list_destroy _iotcon_list_destroy = + _iotcon_list_destroy_ptr.asFunction<_dart_iotcon_list_destroy>(); + + /// @brief Adds a new element integer value into the list at the given position. + /// @details If @a pos is negative, or is larger than the number of elements in the list, the new value is added on to the end of the list. + /// @since_tizen 3.0 + /// @param[in] list The list handle + /// @param[in] val The new integer value + /// @param[in] pos The position to insert value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_list_add_int( + ffi.Pointer list, + int val, + int pos, + ) { + return _iotcon_list_add_int( + list, + val, + pos, + ); + } + + late final _iotcon_list_add_int_ptr = + _lookup>( + 'iotcon_list_add_int'); + late final _dart_iotcon_list_add_int _iotcon_list_add_int = + _iotcon_list_add_int_ptr.asFunction<_dart_iotcon_list_add_int>(); + + /// @brief Adds a new element boolean value into the list at the given position. + /// @details If @a pos is negative, or is larger than the number of elements in the list, the new value is added on to the end of the list. + /// @since_tizen 3.0 + /// @param[in] list The list handle + /// @param[in] val The new boolean value + /// @param[in] pos The position to insert value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_list_add_bool( + ffi.Pointer list, + bool val, + int pos, + ) { + return _iotcon_list_add_bool( + list, + val ? 1 : 0, + pos, + ); + } + + late final _iotcon_list_add_bool_ptr = + _lookup>( + 'iotcon_list_add_bool'); + late final _dart_iotcon_list_add_bool _iotcon_list_add_bool = + _iotcon_list_add_bool_ptr.asFunction<_dart_iotcon_list_add_bool>(); + + /// @brief Adds a new element double value into the list at the given position. + /// @details If @a pos is negative, or is larger than the number of elements in the list, the new value is added on to the end of the list. + /// @since_tizen 3.0 + /// @param[in] list The list handle + /// @param[in] val The new double value + /// @param[in] pos The position to insert value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_list_add_double( + ffi.Pointer list, + double val, + int pos, + ) { + return _iotcon_list_add_double( + list, + val, + pos, + ); + } + + late final _iotcon_list_add_double_ptr = + _lookup>( + 'iotcon_list_add_double'); + late final _dart_iotcon_list_add_double _iotcon_list_add_double = + _iotcon_list_add_double_ptr.asFunction<_dart_iotcon_list_add_double>(); + + /// @brief Adds a new element string value into the list at the given position. + /// @details If @a pos is negative, or is larger than the number of elements in the list, the new value is added on to the end of the list. + /// @since_tizen 3.0 + /// @param[in] list The list handle + /// @param[in] val The new char value + /// @param[in] pos The position to insert value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_list_add_str( + ffi.Pointer list, + ffi.Pointer val, + int pos, + ) { + return _iotcon_list_add_str( + list, + val, + pos, + ); + } + + late final _iotcon_list_add_str_ptr = + _lookup>( + 'iotcon_list_add_str'); + late final _dart_iotcon_list_add_str _iotcon_list_add_str = + _iotcon_list_add_str_ptr.asFunction<_dart_iotcon_list_add_str>(); + + /// @brief Adds a new element byte string value into the list at the given position. + /// @details If @a pos is negative, or is larger than the number of elements in the list, the new value is added on to the end of the list. + /// @since_tizen 3.0 + /// @param[in] list The list handle + /// @param[in] val The new byte string value + /// @param[in] len The length of @a val + /// @param[in] pos The position to insert value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_list_add_byte_str( + ffi.Pointer list, + ffi.Pointer val, + int len, + int pos, + ) { + return _iotcon_list_add_byte_str( + list, + val, + len, + pos, + ); + } + + late final _iotcon_list_add_byte_str_ptr = + _lookup>( + 'iotcon_list_add_byte_str'); + late final _dart_iotcon_list_add_byte_str _iotcon_list_add_byte_str = + _iotcon_list_add_byte_str_ptr + .asFunction<_dart_iotcon_list_add_byte_str>(); + + /// @brief Adds a new element list into the list at the given position. + /// @details If @a pos is negative, or is larger than the number of elements in the list, the new value is added on to the end of the list. + /// @since_tizen 3.0 + /// @param[in] list The list handle + /// @param[in] val The new list value + /// @param[in] pos The position to insert value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_list_add_list( + ffi.Pointer list, + ffi.Pointer val, + int pos, + ) { + return _iotcon_list_add_list( + list, + val, + pos, + ); + } + + late final _iotcon_list_add_list_ptr = + _lookup>( + 'iotcon_list_add_list'); + late final _dart_iotcon_list_add_list _iotcon_list_add_list = + _iotcon_list_add_list_ptr.asFunction<_dart_iotcon_list_add_list>(); + + /// @brief Adds a new element attributes value into the list at the given position. + /// @details If @a pos is negative, or is larger than the number of elements in the list, the new value is added on to the end of the list. + /// @since_tizen 3.0 + /// @param[in] list The list handle + /// @param[in] val The new attributes value + /// @param[in] pos The position to insert value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_list_add_attributes( + ffi.Pointer list, + ffi.Pointer val, + int pos, + ) { + return _iotcon_list_add_attributes( + list, + val, + pos, + ); + } + + late final _iotcon_list_add_attributes_ptr = + _lookup>( + 'iotcon_list_add_attributes'); + late final _dart_iotcon_list_add_attributes _iotcon_list_add_attributes = + _iotcon_list_add_attributes_ptr + .asFunction<_dart_iotcon_list_add_attributes>(); + + /// @brief Gets the integer value at the given position. + /// @details Iterates over the list until it reaches the @a pos-1 position. + /// @since_tizen 3.0 + /// @param[in] list The list handle + /// @param[in] pos The position + /// @param[out] val The integer value to get + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_REPRESENTATION Representation errors + int iotcon_list_get_nth_int( + ffi.Pointer list, + int pos, + ffi.Pointer val, + ) { + return _iotcon_list_get_nth_int( + list, + pos, + val, + ); + } + + late final _iotcon_list_get_nth_int_ptr = + _lookup>( + 'iotcon_list_get_nth_int'); + late final _dart_iotcon_list_get_nth_int _iotcon_list_get_nth_int = + _iotcon_list_get_nth_int_ptr.asFunction<_dart_iotcon_list_get_nth_int>(); + + /// @brief Gets the boolean value at the given position. + /// @details Iterates over the list until it reaches the @a pos-1 position. + /// @since_tizen 3.0 + /// @param[in] list The list handle + /// @param[in] pos The position + /// @param[out] val The boolean value to get + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_REPRESENTATION Representation errors + int iotcon_list_get_nth_bool( + ffi.Pointer list, + int pos, + ffi.Pointer val, + ) { + return _iotcon_list_get_nth_bool( + list, + pos, + val, + ); + } + + late final _iotcon_list_get_nth_bool_ptr = + _lookup>( + 'iotcon_list_get_nth_bool'); + late final _dart_iotcon_list_get_nth_bool _iotcon_list_get_nth_bool = + _iotcon_list_get_nth_bool_ptr + .asFunction<_dart_iotcon_list_get_nth_bool>(); + + /// @brief Gets the double value at the given position. + /// @details Iterates over the list until it reaches the @a pos-1 position. + /// @since_tizen 3.0 + /// @param[in] list The list handle + /// @param[in] pos The position + /// @param[out] val The double value to get + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_REPRESENTATION Representation errors + int iotcon_list_get_nth_double( + ffi.Pointer list, + int pos, + ffi.Pointer val, + ) { + return _iotcon_list_get_nth_double( + list, + pos, + val, + ); + } + + late final _iotcon_list_get_nth_double_ptr = + _lookup>( + 'iotcon_list_get_nth_double'); + late final _dart_iotcon_list_get_nth_double _iotcon_list_get_nth_double = + _iotcon_list_get_nth_double_ptr + .asFunction<_dart_iotcon_list_get_nth_double>(); + + /// @brief Gets the string value at the given position. + /// @details Iterates over the list until it reaches the @a pos-1 position. + /// @since_tizen 3.0 + /// @remarks @a val must not be released using free(). + /// @param[in] list The list handle + /// @param[in] pos The position + /// @param[out] val The string value to get + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_REPRESENTATION Representation errors + int iotcon_list_get_nth_str( + ffi.Pointer list, + int pos, + ffi.Pointer> val, + ) { + return _iotcon_list_get_nth_str( + list, + pos, + val, + ); + } + + late final _iotcon_list_get_nth_str_ptr = + _lookup>( + 'iotcon_list_get_nth_str'); + late final _dart_iotcon_list_get_nth_str _iotcon_list_get_nth_str = + _iotcon_list_get_nth_str_ptr.asFunction<_dart_iotcon_list_get_nth_str>(); + + /// @brief Gets the string value at the given position. + /// @details Iterates over the list until it reaches the @a pos-1 position. + /// @since_tizen 3.0 + /// @remarks @a val must not be released using free(). + /// @param[in] list The list handle + /// @param[in] pos The position + /// @param[out] val The byte string value to get + /// @param[out] len The length of the @a val + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_REPRESENTATION Representation errors + int iotcon_list_get_nth_byte_str( + ffi.Pointer list, + int pos, + ffi.Pointer> val, + ffi.Pointer len, + ) { + return _iotcon_list_get_nth_byte_str( + list, + pos, + val, + len, + ); + } + + late final _iotcon_list_get_nth_byte_str_ptr = + _lookup>( + 'iotcon_list_get_nth_byte_str'); + late final _dart_iotcon_list_get_nth_byte_str _iotcon_list_get_nth_byte_str = + _iotcon_list_get_nth_byte_str_ptr + .asFunction<_dart_iotcon_list_get_nth_byte_str>(); + + /// @brief Gets the list value at the given position. + /// @details Iterates over the list until it reaches the @a pos-1 position. + /// @since_tizen 3.0 + /// @remarks @a dest must not be released using iotcon_list_destroy(). + /// @param[in] src The list handle + /// @param[in] pos The position + /// @param[out] dest The list value to get + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_REPRESENTATION Representation errors + int iotcon_list_get_nth_list( + ffi.Pointer src, + int pos, + ffi.Pointer> dest, + ) { + return _iotcon_list_get_nth_list( + src, + pos, + dest, + ); + } + + late final _iotcon_list_get_nth_list_ptr = + _lookup>( + 'iotcon_list_get_nth_list'); + late final _dart_iotcon_list_get_nth_list _iotcon_list_get_nth_list = + _iotcon_list_get_nth_list_ptr + .asFunction<_dart_iotcon_list_get_nth_list>(); + + /// @brief Gets the attributes value at the given position. + /// @details Iterates over the list until it reaches the @a pos-1 position. + /// @since_tizen 3.0 + /// @remarks @a attributes must not be released using iotcon_attributes_destroy(). + /// @param[in] list The list handle + /// @param[in] pos The position + /// @param[out] attributes The attributes value to get + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_REPRESENTATION Representation errors + int iotcon_list_get_nth_attributes( + ffi.Pointer list, + int pos, + ffi.Pointer> attributes, + ) { + return _iotcon_list_get_nth_attributes( + list, + pos, + attributes, + ); + } + + late final _iotcon_list_get_nth_attributes_ptr = + _lookup>( + 'iotcon_list_get_nth_attributes'); + late final _dart_iotcon_list_get_nth_attributes + _iotcon_list_get_nth_attributes = _iotcon_list_get_nth_attributes_ptr + .asFunction<_dart_iotcon_list_get_nth_attributes>(); + + /// @brief Removes the value at the given position. + /// @details Iterates over the list until it reaches the @a pos-1 position. + /// @since_tizen 3.0 + /// @param[in] list The list handle + /// @param[in] pos The position to delete + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + int iotcon_list_remove_nth( + ffi.Pointer list, + int pos, + ) { + return _iotcon_list_remove_nth( + list, + pos, + ); + } + + late final _iotcon_list_remove_nth_ptr = + _lookup>( + 'iotcon_list_remove_nth'); + late final _dart_iotcon_list_remove_nth _iotcon_list_remove_nth = + _iotcon_list_remove_nth_ptr.asFunction<_dart_iotcon_list_remove_nth>(); + + /// @brief Gets the type of the list. + /// @details It gets the data type of value related to the @a key in @a attributes. + /// The data type could be one of #iotcon_type_e. + /// @since_tizen 3.0 + /// @param[in] list The list handle + /// @param[out] type The data type of list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_list_get_type( + ffi.Pointer list, + ffi.Pointer type, + ) { + return _iotcon_list_get_type( + list, + type, + ); + } + + late final _iotcon_list_get_type_ptr = + _lookup>( + 'iotcon_list_get_type'); + late final _dart_iotcon_list_get_type _iotcon_list_get_type = + _iotcon_list_get_type_ptr.asFunction<_dart_iotcon_list_get_type>(); + + /// @brief Gets the number of elements in a list. + /// @since_tizen 3.0 + /// @param[in] list The handle to the list + /// @param[out] length The length of list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_list_get_length( + ffi.Pointer list, + ffi.Pointer length, + ) { + return _iotcon_list_get_length( + list, + length, + ); + } + + late final _iotcon_list_get_length_ptr = + _lookup>( + 'iotcon_list_get_length'); + late final _dart_iotcon_list_get_length _iotcon_list_get_length = + _iotcon_list_get_length_ptr.asFunction<_dart_iotcon_list_get_length>(); + + /// @brief Gets all integer values of the given list by invoking the callback function. + /// @details iotcon_list_int_cb() will be called for each child. + /// @since_tizen 3.0 + /// @param[in] list The handle to the list + /// @param[in] cb The callback function to get each integer value + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @post iotcon_list_int_cb() will be called for each item. + /// @see iotcon_list_int_cb() + int iotcon_list_foreach_int( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_list_foreach_int( + list, + cb, + user_data, + ); + } + + late final _iotcon_list_foreach_int_ptr = + _lookup>( + 'iotcon_list_foreach_int'); + late final _dart_iotcon_list_foreach_int _iotcon_list_foreach_int = + _iotcon_list_foreach_int_ptr.asFunction<_dart_iotcon_list_foreach_int>(); + + /// @brief Gets all boolean values of the given list by invoking the callback function. + /// @details iotcon_list_bool_cb() will be called for each child. + /// @since_tizen 3.0 + /// @param[in] list The handle to the list + /// @param[in] cb The callback function to get each boolean value + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @post iotcon_list_bool_cb() will be called for each item. + /// @see iotcon_list_bool_cb() + int iotcon_list_foreach_bool( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_list_foreach_bool( + list, + cb, + user_data, + ); + } + + late final _iotcon_list_foreach_bool_ptr = + _lookup>( + 'iotcon_list_foreach_bool'); + late final _dart_iotcon_list_foreach_bool _iotcon_list_foreach_bool = + _iotcon_list_foreach_bool_ptr + .asFunction<_dart_iotcon_list_foreach_bool>(); + + /// @brief Gets all double values of the given list by invoking the callback function. + /// @details iotcon_list_double_cb() will be called for each child. + /// @since_tizen 3.0 + /// @param[in] list The handle to the list + /// @param[in] cb The callback function to get each double value + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @post iotcon_list_double_cb() will be called for each item. + /// @see iotcon_list_double_cb() + int iotcon_list_foreach_double( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_list_foreach_double( + list, + cb, + user_data, + ); + } + + late final _iotcon_list_foreach_double_ptr = + _lookup>( + 'iotcon_list_foreach_double'); + late final _dart_iotcon_list_foreach_double _iotcon_list_foreach_double = + _iotcon_list_foreach_double_ptr + .asFunction<_dart_iotcon_list_foreach_double>(); + + /// @brief Gets all string values of the given list by invoking the callback function. + /// @details iotcon_list_byte_str_cb() will be called for each child. + /// @since_tizen 3.0 + /// @param[in] list The handle to the list + /// @param[in] cb The callback function to get each string value + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @post iotcon_list_byte_str_cb() will be called for each item. + /// @see iotcon_list_byte_str_cb() + int iotcon_list_foreach_byte_str( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_list_foreach_byte_str( + list, + cb, + user_data, + ); + } + + late final _iotcon_list_foreach_byte_str_ptr = + _lookup>( + 'iotcon_list_foreach_byte_str'); + late final _dart_iotcon_list_foreach_byte_str _iotcon_list_foreach_byte_str = + _iotcon_list_foreach_byte_str_ptr + .asFunction<_dart_iotcon_list_foreach_byte_str>(); + + /// @brief Gets all string values of the given list by invoking the callback function. + /// @details iotcon_list_str_cb() will be called for each child. + /// @since_tizen 3.0 + /// @param[in] list The handle to the list + /// @param[in] cb The callback function to get each string value + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @post iotcon_list_str_cb() will be called for each item. + /// @see iotcon_list_str_cb() + int iotcon_list_foreach_str( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_list_foreach_str( + list, + cb, + user_data, + ); + } + + late final _iotcon_list_foreach_str_ptr = + _lookup>( + 'iotcon_list_foreach_str'); + late final _dart_iotcon_list_foreach_str _iotcon_list_foreach_str = + _iotcon_list_foreach_str_ptr.asFunction<_dart_iotcon_list_foreach_str>(); + + /// @brief Gets all sub lists of the given list by invoking the callback function. + /// @details iotcon_list_list_cb() will be called for each child. + /// @since_tizen 3.0 + /// @param[in] list The handle to the origin list + /// @param[in] cb The callback function to get each sub list + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @post iotcon_list_list_cb() will be called for each item. + /// @see iotcon_list_list_cb() + int iotcon_list_foreach_list( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_list_foreach_list( + list, + cb, + user_data, + ); + } + + late final _iotcon_list_foreach_list_ptr = + _lookup>( + 'iotcon_list_foreach_list'); + late final _dart_iotcon_list_foreach_list _iotcon_list_foreach_list = + _iotcon_list_foreach_list_ptr + .asFunction<_dart_iotcon_list_foreach_list>(); + + /// @brief Gets all attributes of the given list by invoking the callback function. + /// @details iotcon_list_attributes_cb() will be called for each child. + /// @since_tizen 3.0 + /// @param[in] list The handle to the list + /// @param[in] cb The callback function to get each attributes + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @post iotcon_list_attributes_cb() will be called for each item. + /// @see iotcon_list_attributes_cb() + int iotcon_list_foreach_attributes( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_list_foreach_attributes( + list, + cb, + user_data, + ); + } + + late final _iotcon_list_foreach_attributes_ptr = + _lookup>( + 'iotcon_list_foreach_attributes'); + late final _dart_iotcon_list_foreach_attributes + _iotcon_list_foreach_attributes = _iotcon_list_foreach_attributes_ptr + .asFunction<_dart_iotcon_list_foreach_attributes>(); + + /// @brief Creates a new query handle. + /// @since_tizen 3.0 + /// @remarks You must destroy @a query by calling iotcon_query_destroy() if @a query is no longer needed. + /// @param[out] query A newly allocated query handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_query_destroy() + /// @see iotcon_query_add() + /// @see iotcon_query_remove() + /// @see iotcon_query_lookup() + int iotcon_query_create( + ffi.Pointer> query, + ) { + return _iotcon_query_create( + query, + ); + } + + late final _iotcon_query_create_ptr = + _lookup>( + 'iotcon_query_create'); + late final _dart_iotcon_query_create _iotcon_query_create = + _iotcon_query_create_ptr.asFunction<_dart_iotcon_query_create>(); + + /// @brief Destroys a query handle. + /// @since_tizen 3.0 + /// @param[in] query The handle of the query + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_query_create() + /// @see iotcon_query_add() + /// @see iotcon_query_remove() + /// @see iotcon_query_lookup() + int iotcon_query_destroy( + ffi.Pointer query, + ) { + return _iotcon_query_destroy( + query, + ); + } + + late final _iotcon_query_destroy_ptr = + _lookup>( + 'iotcon_query_destroy'); + late final _dart_iotcon_query_destroy _iotcon_query_destroy = + _iotcon_query_destroy_ptr.asFunction<_dart_iotcon_query_destroy>(); + + /// @brief Gets resource type from the query. + /// @since_tizen 3.0 + /// @remarks @a resource_type must not be released using free(). + /// @a resource_type must start with a lowercase alphabetic character, followed by a sequence + /// of lowercase alphabetic, numeric, ".", or "-" characters, and contains no white space. + /// @param[in] query The handle of the query + /// @param[out] resource_type Found resource type from query + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @see iotcon_query_create() + /// @see iotcon_query_destroy() + /// @see iotcon_query_add() + /// @see iotcon_query_remove() + /// @see iotcon_query_set_resource_type() + int iotcon_query_get_resource_type( + ffi.Pointer query, + ffi.Pointer> resource_type, + ) { + return _iotcon_query_get_resource_type( + query, + resource_type, + ); + } + + late final _iotcon_query_get_resource_type_ptr = + _lookup>( + 'iotcon_query_get_resource_type'); + late final _dart_iotcon_query_get_resource_type + _iotcon_query_get_resource_type = _iotcon_query_get_resource_type_ptr + .asFunction<_dart_iotcon_query_get_resource_type>(); + + /// @brief Gets resource interface from the query. + /// @since_tizen 3.0 + /// @remarks @a resource_iface could be a value such as #IOTCON_INTERFACE_DEFAULT. + /// @remarks @a resource_iface must not be released using free(). + /// @param[in] query The handle of the query + /// @param[out] resource_iface Found resource interface from query + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @see iotcon_query_create() + /// @see iotcon_query_destroy() + /// @see iotcon_query_add() + /// @see iotcon_query_remove() + /// @see iotcon_query_set_interface() + int iotcon_query_get_interface( + ffi.Pointer query, + ffi.Pointer> resource_iface, + ) { + return _iotcon_query_get_interface( + query, + resource_iface, + ); + } + + late final _iotcon_query_get_interface_ptr = + _lookup>( + 'iotcon_query_get_interface'); + late final _dart_iotcon_query_get_interface _iotcon_query_get_interface = + _iotcon_query_get_interface_ptr + .asFunction<_dart_iotcon_query_get_interface>(); + + /// @brief Sets the resource type into the query. + /// @since_tizen 3.0 + /// @param[in] query The handle of the query + /// @param[in] resource_type The resource type to set into the query + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_query_create() + /// @see iotcon_query_destroy() + /// @see iotcon_query_add() + /// @see iotcon_query_remove() + /// @see iotcon_query_lookup() + /// @see iotcon_query_get_resource_type() + int iotcon_query_set_resource_type( + ffi.Pointer query, + ffi.Pointer resource_type, + ) { + return _iotcon_query_set_resource_type( + query, + resource_type, + ); + } + + late final _iotcon_query_set_resource_type_ptr = + _lookup>( + 'iotcon_query_set_resource_type'); + late final _dart_iotcon_query_set_resource_type + _iotcon_query_set_resource_type = _iotcon_query_set_resource_type_ptr + .asFunction<_dart_iotcon_query_set_resource_type>(); + + /// @brief Sets the resource interface into the query. + /// @since_tizen 3.0 + /// @remarks @a resource_iface could be a value such as #IOTCON_INTERFACE_DEFAULT. + /// @param[in] query The handle of the query + /// @param[in] resource_iface The resource interface to add into the query + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_query_create() + /// @see iotcon_query_destroy() + /// @see iotcon_query_add() + /// @see iotcon_query_remove() + /// @see iotcon_query_lookup() + /// @see iotcon_query_get_interface() + int iotcon_query_set_interface( + ffi.Pointer query, + ffi.Pointer resource_iface, + ) { + return _iotcon_query_set_interface( + query, + resource_iface, + ); + } + + late final _iotcon_query_set_interface_ptr = + _lookup>( + 'iotcon_query_set_interface'); + late final _dart_iotcon_query_set_interface _iotcon_query_set_interface = + _iotcon_query_set_interface_ptr + .asFunction<_dart_iotcon_query_set_interface>(); + + /// @brief Adds a new key and corresponding value into the query. + /// @since_tizen 3.0 + /// @remarks The full length of query should be less than or equal to 64. + /// @param[in] query The handle of the query + /// @param[in] key The key of the query to insert + /// @param[in] value The string data to insert into the query + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_query_create() + /// @see iotcon_query_destroy() + /// @see iotcon_query_remove() + /// @see iotcon_query_lookup() + int iotcon_query_add( + ffi.Pointer query, + ffi.Pointer key, + ffi.Pointer value, + ) { + return _iotcon_query_add( + query, + key, + value, + ); + } + + late final _iotcon_query_add_ptr = + _lookup>('iotcon_query_add'); + late final _dart_iotcon_query_add _iotcon_query_add = + _iotcon_query_add_ptr.asFunction<_dart_iotcon_query_add>(); + + /// @brief Removes the key and its associated value from the query. + /// @since_tizen 3.0 + /// @param[in] query The handle of the query + /// @param[in] key The key of the option to delete + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_query_create() + /// @see iotcon_query_destroy() + /// @see iotcon_query_add() + /// @see iotcon_query_lookup() + int iotcon_query_remove( + ffi.Pointer query, + ffi.Pointer key, + ) { + return _iotcon_query_remove( + query, + key, + ); + } + + late final _iotcon_query_remove_ptr = + _lookup>( + 'iotcon_query_remove'); + late final _dart_iotcon_query_remove _iotcon_query_remove = + _iotcon_query_remove_ptr.asFunction<_dart_iotcon_query_remove>(); + + /// @brief Looks up data at the given key from the query. + /// @since_tizen 3.0 + /// @remarks @a data must not be released using free(). + /// @param[in] query The handle of the query + /// @param[in] key The key of the query to lookup + /// @param[out] data Found data from query + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_query_create() + /// @see iotcon_query_destroy() + /// @see iotcon_query_add() + /// @see iotcon_query_remove() + int iotcon_query_lookup( + ffi.Pointer query, + ffi.Pointer key, + ffi.Pointer> data, + ) { + return _iotcon_query_lookup( + query, + key, + data, + ); + } + + late final _iotcon_query_lookup_ptr = + _lookup>( + 'iotcon_query_lookup'); + late final _dart_iotcon_query_lookup _iotcon_query_lookup = + _iotcon_query_lookup_ptr.asFunction<_dart_iotcon_query_lookup>(); + + /// @brief Gets all data of the query by invoking the callback function. + /// @details iotcon_query_foreach_cb() will be called for each query. \n + /// If iotcon_query_foreach_cb() returns false, iteration will be stopped. + /// @since_tizen 3.0 + /// @param[in] query The handle of the query + /// @param[in] cb The callback function to get data + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @post iotcon_query_foreach_cb() will be called for each query. + /// @see iotcon_query_foreach_cb() + int iotcon_query_foreach( + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_query_foreach( + query, + cb, + user_data, + ); + } + + late final _iotcon_query_foreach_ptr = + _lookup>( + 'iotcon_query_foreach'); + late final _dart_iotcon_query_foreach _iotcon_query_foreach = + _iotcon_query_foreach_ptr.asFunction<_dart_iotcon_query_foreach>(); + + /// @brief Creates a new attributes handle. + /// @since_tizen 3.0 + /// @remarks You must destroy @a attributes by calling iotcon_attributes_destroy() if @a attributes is no longer needed. + /// @param[out] attributes A newly allocated attributes handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_attributes_destroy() + int iotcon_attributes_create( + ffi.Pointer> attributes, + ) { + return _iotcon_attributes_create( + attributes, + ); + } + + late final _iotcon_attributes_create_ptr = + _lookup>( + 'iotcon_attributes_create'); + late final _dart_iotcon_attributes_create _iotcon_attributes_create = + _iotcon_attributes_create_ptr + .asFunction<_dart_iotcon_attributes_create>(); + + /// @brief Destroys the attributes. + /// @details Releases @a attributes and its internal data. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle to free + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_attributes_create() + int iotcon_attributes_destroy( + ffi.Pointer attributes, + ) { + return _iotcon_attributes_destroy( + attributes, + ); + } + + late final _iotcon_attributes_destroy_ptr = + _lookup>( + 'iotcon_attributes_destroy'); + late final _dart_iotcon_attributes_destroy _iotcon_attributes_destroy = + _iotcon_attributes_destroy_ptr + .asFunction<_dart_iotcon_attributes_destroy>(); + + /// @brief Clones the attributes handle. + /// @since_tizen 3.0 + /// @remarks You must destroy @a attributes_clone by calling iotcon_attributes_destroy() if @a attributes_clone is no longer needed. + /// @param[in] attributes The attributes handle + /// @param[out] attributes_clone The cloned attributes handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_attributes_create() + /// @see iotcon_attributes_destroy() + int iotcon_attributes_clone( + ffi.Pointer attributes, + ffi.Pointer> attributes_clone, + ) { + return _iotcon_attributes_clone( + attributes, + attributes_clone, + ); + } + + late final _iotcon_attributes_clone_ptr = + _lookup>( + 'iotcon_attributes_clone'); + late final _dart_iotcon_attributes_clone _iotcon_attributes_clone = + _iotcon_attributes_clone_ptr.asFunction<_dart_iotcon_attributes_clone>(); + + /// @brief Adds a new key and integer value into the attributes. + /// @details If @a key is already exists, current value will be replaced with new @a val. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @param[in] val The value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_attributes_add_int( + ffi.Pointer attributes, + ffi.Pointer key, + int val, + ) { + return _iotcon_attributes_add_int( + attributes, + key, + val, + ); + } + + late final _iotcon_attributes_add_int_ptr = + _lookup>( + 'iotcon_attributes_add_int'); + late final _dart_iotcon_attributes_add_int _iotcon_attributes_add_int = + _iotcon_attributes_add_int_ptr + .asFunction<_dart_iotcon_attributes_add_int>(); + + /// @brief Adds a new key and boolean value into the attributes. + /// @details If @a key is already exists, current value will be replaced with new @a val. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @param[in] val The value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_attributes_add_bool( + ffi.Pointer attributes, + ffi.Pointer key, + bool val, + ) { + return _iotcon_attributes_add_bool( + attributes, + key, + val ? 1 : 0, + ); + } + + late final _iotcon_attributes_add_bool_ptr = + _lookup>( + 'iotcon_attributes_add_bool'); + late final _dart_iotcon_attributes_add_bool _iotcon_attributes_add_bool = + _iotcon_attributes_add_bool_ptr + .asFunction<_dart_iotcon_attributes_add_bool>(); + + /// @brief Adds a new key and double value into the attributes. + /// @details If @a key is already exists, current value will be replaced with new @a val. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @param[in] val The value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_attributes_add_double( + ffi.Pointer attributes, + ffi.Pointer key, + double val, + ) { + return _iotcon_attributes_add_double( + attributes, + key, + val, + ); + } + + late final _iotcon_attributes_add_double_ptr = + _lookup>( + 'iotcon_attributes_add_double'); + late final _dart_iotcon_attributes_add_double _iotcon_attributes_add_double = + _iotcon_attributes_add_double_ptr + .asFunction<_dart_iotcon_attributes_add_double>(); + + /// @brief Adds a new key and string value into the attributes. + /// @details If @a key is already exists, current value will be replaced with new @a val. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @param[in] val The value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_attributes_add_str( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, + ) { + return _iotcon_attributes_add_str( + attributes, + key, + val, + ); + } + + late final _iotcon_attributes_add_str_ptr = + _lookup>( + 'iotcon_attributes_add_str'); + late final _dart_iotcon_attributes_add_str _iotcon_attributes_add_str = + _iotcon_attributes_add_str_ptr + .asFunction<_dart_iotcon_attributes_add_str>(); + + /// @brief Adds a new key and byte string value into the attributes. + /// @details If @a key is already exists, current value will be replaced with new @a val. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @param[in] val The value + /// @param[in] len The length of @a val + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_attributes_add_byte_str( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, + int len, + ) { + return _iotcon_attributes_add_byte_str( + attributes, + key, + val, + len, + ); + } + + late final _iotcon_attributes_add_byte_str_ptr = + _lookup>( + 'iotcon_attributes_add_byte_str'); + late final _dart_iotcon_attributes_add_byte_str + _iotcon_attributes_add_byte_str = _iotcon_attributes_add_byte_str_ptr + .asFunction<_dart_iotcon_attributes_add_byte_str>(); + + /// @brief Adds a new key and list value into the attributes. + /// @details If @a key already exists, current list will be replaced with new @a list. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @param[in] list The value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_attributes_add_list( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer list, + ) { + return _iotcon_attributes_add_list( + attributes, + key, + list, + ); + } + + late final _iotcon_attributes_add_list_ptr = + _lookup>( + 'iotcon_attributes_add_list'); + late final _dart_iotcon_attributes_add_list _iotcon_attributes_add_list = + _iotcon_attributes_add_list_ptr + .asFunction<_dart_iotcon_attributes_add_list>(); + + /// @brief Adds a new key and attributes value into the attributes. + /// @details If @a key already exists, current attributes will be replaced with new @a src. + /// @since_tizen 3.0 + /// @param[in] dest The attributes handle + /// @param[in] key The key + /// @param[in] src The attributes handle to set newly + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_attributes_add_attributes( + ffi.Pointer dest, + ffi.Pointer key, + ffi.Pointer src, + ) { + return _iotcon_attributes_add_attributes( + dest, + key, + src, + ); + } + + late final _iotcon_attributes_add_attributes_ptr = + _lookup>( + 'iotcon_attributes_add_attributes'); + late final _dart_iotcon_attributes_add_attributes + _iotcon_attributes_add_attributes = _iotcon_attributes_add_attributes_ptr + .asFunction<_dart_iotcon_attributes_add_attributes>(); + + /// @brief Adds a new key with NULL value into the attributes. + /// @details If @a key already exists, current value will be replaced with NULL. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[in] key The key to be set NULL + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_attributes_add_null( + ffi.Pointer attributes, + ffi.Pointer key, + ) { + return _iotcon_attributes_add_null( + attributes, + key, + ); + } + + late final _iotcon_attributes_add_null_ptr = + _lookup>( + 'iotcon_attributes_add_null'); + late final _dart_iotcon_attributes_add_null _iotcon_attributes_add_null = + _iotcon_attributes_add_null_ptr + .asFunction<_dart_iotcon_attributes_add_null>(); + + /// @brief Gets the integer value from the given key. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @param[out] val The integer value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_attributes_get_int( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, + ) { + return _iotcon_attributes_get_int( + attributes, + key, + val, + ); + } + + late final _iotcon_attributes_get_int_ptr = + _lookup>( + 'iotcon_attributes_get_int'); + late final _dart_iotcon_attributes_get_int _iotcon_attributes_get_int = + _iotcon_attributes_get_int_ptr + .asFunction<_dart_iotcon_attributes_get_int>(); + + /// @brief Gets the boolean value from the given key. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @param[out] val The boolean value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_attributes_get_bool( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, + ) { + return _iotcon_attributes_get_bool( + attributes, + key, + val, + ); + } + + late final _iotcon_attributes_get_bool_ptr = + _lookup>( + 'iotcon_attributes_get_bool'); + late final _dart_iotcon_attributes_get_bool _iotcon_attributes_get_bool = + _iotcon_attributes_get_bool_ptr + .asFunction<_dart_iotcon_attributes_get_bool>(); + + /// @brief Gets the double value from the given key. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @param[out] val The double value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_attributes_get_double( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, + ) { + return _iotcon_attributes_get_double( + attributes, + key, + val, + ); + } + + late final _iotcon_attributes_get_double_ptr = + _lookup>( + 'iotcon_attributes_get_double'); + late final _dart_iotcon_attributes_get_double _iotcon_attributes_get_double = + _iotcon_attributes_get_double_ptr + .asFunction<_dart_iotcon_attributes_get_double>(); + + /// @brief Gets the string value from the given key. + /// @since_tizen 3.0 + /// @remarks @a val must not be released using free(). + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @param[out] val The string value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_attributes_get_str( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer> val, + ) { + return _iotcon_attributes_get_str( + attributes, + key, + val, + ); + } + + late final _iotcon_attributes_get_str_ptr = + _lookup>( + 'iotcon_attributes_get_str'); + late final _dart_iotcon_attributes_get_str _iotcon_attributes_get_str = + _iotcon_attributes_get_str_ptr + .asFunction<_dart_iotcon_attributes_get_str>(); + + /// @brief Gets the byte string value from the given key. + /// @since_tizen 3.0 + /// @remarks @a val must not be released using free(). + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @param[out] val The byte string value + /// @param[out] len The length of @a val + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_attributes_get_byte_str( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer> val, + ffi.Pointer len, + ) { + return _iotcon_attributes_get_byte_str( + attributes, + key, + val, + len, + ); + } + + late final _iotcon_attributes_get_byte_str_ptr = + _lookup>( + 'iotcon_attributes_get_byte_str'); + late final _dart_iotcon_attributes_get_byte_str + _iotcon_attributes_get_byte_str = _iotcon_attributes_get_byte_str_ptr + .asFunction<_dart_iotcon_attributes_get_byte_str>(); + + /// @brief Gets the list value from the given key. + /// @since_tizen 3.0 + /// @remarks @a list must not be released using iotcon_list_destroy(). + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @param[out] list The list value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_attributes_get_list( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer> list, + ) { + return _iotcon_attributes_get_list( + attributes, + key, + list, + ); + } + + late final _iotcon_attributes_get_list_ptr = + _lookup>( + 'iotcon_attributes_get_list'); + late final _dart_iotcon_attributes_get_list _iotcon_attributes_get_list = + _iotcon_attributes_get_list_ptr + .asFunction<_dart_iotcon_attributes_get_list>(); + + /// @brief Gets the attributes value from the given key. + /// @since_tizen 3.0 + /// @remarks @a attributes must not be released using iotcon_attributes_destroy(). + /// @param[in] src The attributes handle + /// @param[in] key The key + /// @param[out] dest The attributes value at the key + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @retval #IOTCON_ERROR_INVALID_TYPE Invalid type + int iotcon_attributes_get_attributes( + ffi.Pointer src, + ffi.Pointer key, + ffi.Pointer> dest, + ) { + return _iotcon_attributes_get_attributes( + src, + key, + dest, + ); + } + + late final _iotcon_attributes_get_attributes_ptr = + _lookup>( + 'iotcon_attributes_get_attributes'); + late final _dart_iotcon_attributes_get_attributes + _iotcon_attributes_get_attributes = _iotcon_attributes_get_attributes_ptr + .asFunction<_dart_iotcon_attributes_get_attributes>(); + + /// @brief Checks whether the value of given key is NULL or not. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @param[out] is_null true if the type of the given key is null, + /// otherwise false + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_attributes_is_null( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer is_null, + ) { + return _iotcon_attributes_is_null( + attributes, + key, + is_null, + ); + } + + late final _iotcon_attributes_is_null_ptr = + _lookup>( + 'iotcon_attributes_is_null'); + late final _dart_iotcon_attributes_is_null _iotcon_attributes_is_null = + _iotcon_attributes_is_null_ptr + .asFunction<_dart_iotcon_attributes_is_null>(); + + /// @brief Removes the key and its associated value from the attributes. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + int iotcon_attributes_remove( + ffi.Pointer attributes, + ffi.Pointer key, + ) { + return _iotcon_attributes_remove( + attributes, + key, + ); + } + + late final _iotcon_attributes_remove_ptr = + _lookup>( + 'iotcon_attributes_remove'); + late final _dart_iotcon_attributes_remove _iotcon_attributes_remove = + _iotcon_attributes_remove_ptr + .asFunction<_dart_iotcon_attributes_remove>(); + + /// @brief Gets the type of a value at the given key. + /// @details It gets the data type of value related to the @a key in @a attributes. + /// The data type could be one of #iotcon_type_e. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[in] key The key + /// @param[out] type The data type of value related to the key in attributes handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + int iotcon_attributes_get_type( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer type, + ) { + return _iotcon_attributes_get_type( + attributes, + key, + type, + ); + } + + late final _iotcon_attributes_get_type_ptr = + _lookup>( + 'iotcon_attributes_get_type'); + late final _dart_iotcon_attributes_get_type _iotcon_attributes_get_type = + _iotcon_attributes_get_type_ptr + .asFunction<_dart_iotcon_attributes_get_type>(); + + /// @brief Calls a function for each element of attributes. + /// @details iotcon_attributes_cb() will be called for each child. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[in] cb The callback function to invoke + /// @param[in] user_data The user data to pass to the function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @post iotcon_attributes_cb() will be called for each child. + /// @see iotcon_attributes_cb() + int iotcon_attributes_foreach( + ffi.Pointer attributes, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_attributes_foreach( + attributes, + cb, + user_data, + ); + } + + late final _iotcon_attributes_foreach_ptr = + _lookup>( + 'iotcon_attributes_foreach'); + late final _dart_iotcon_attributes_foreach _iotcon_attributes_foreach = + _iotcon_attributes_foreach_ptr + .asFunction<_dart_iotcon_attributes_foreach>(); + + /// @brief Gets the number of keys in the attributes. + /// @since_tizen 3.0 + /// @param[in] attributes The attributes handle + /// @param[out] count The number of keys + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_attributes_get_keys_count( + ffi.Pointer attributes, + ffi.Pointer count, + ) { + return _iotcon_attributes_get_keys_count( + attributes, + count, + ); + } + + late final _iotcon_attributes_get_keys_count_ptr = + _lookup>( + 'iotcon_attributes_get_keys_count'); + late final _dart_iotcon_attributes_get_keys_count + _iotcon_attributes_get_keys_count = _iotcon_attributes_get_keys_count_ptr + .asFunction<_dart_iotcon_attributes_get_keys_count>(); + + /// @brief Creates a new option handle. + /// @since_tizen 3.0 + /// @remarks You must destroy @a options by calling iotcon_options_destroy() if @a options is no longer needed. + /// @param[out] options A newly allocated option handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_options_destroy() + /// @see iotcon_options_add() + /// @see iotcon_options_remove() + /// @see iotcon_options_lookup() + int iotcon_options_create( + ffi.Pointer> options, + ) { + return _iotcon_options_create( + options, + ); + } + + late final _iotcon_options_create_ptr = + _lookup>( + 'iotcon_options_create'); + late final _dart_iotcon_options_create _iotcon_options_create = + _iotcon_options_create_ptr.asFunction<_dart_iotcon_options_create>(); + + /// @brief Destroys an option handle. + /// @since_tizen 3.0 + /// @param[in] options The handle of the options + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_options_create() + /// @see iotcon_options_add() + /// @see iotcon_options_remove() + /// @see iotcon_options_lookup() + int iotcon_options_destroy( + ffi.Pointer options, + ) { + return _iotcon_options_destroy( + options, + ); + } + + late final _iotcon_options_destroy_ptr = + _lookup>( + 'iotcon_options_destroy'); + late final _dart_iotcon_options_destroy _iotcon_options_destroy = + _iotcon_options_destroy_ptr.asFunction<_dart_iotcon_options_destroy>(); + + /// @brief Adds a new ID and a corresponding data into the options. + /// @since_tizen 3.0 + /// @remarks iotcon_options_h can have up to 2 options. \n + /// Option ID is always situated between 2048 and 3000. \n + /// Length of option data is less than or equal to 15. + /// @param[in] options The handle of the options + /// @param[in] id The ID of the option to insert + /// @param[in] data The string data to insert into the options + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_options_create() + /// @see iotcon_options_destroy() + /// @see iotcon_options_remove() + /// @see iotcon_options_lookup() + int iotcon_options_add( + ffi.Pointer options, + int id, + ffi.Pointer data, + ) { + return _iotcon_options_add( + options, + id, + data, + ); + } + + late final _iotcon_options_add_ptr = + _lookup>('iotcon_options_add'); + late final _dart_iotcon_options_add _iotcon_options_add = + _iotcon_options_add_ptr.asFunction<_dart_iotcon_options_add>(); + + /// @brief Removes the ID and its associated data from the options. + /// @since_tizen 3.0 + /// @param[in] options The handle of the options + /// @param[in] id The ID of the option to delete + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_options_create() + /// @see iotcon_options_destroy() + /// @see iotcon_options_add() + /// @see iotcon_options_lookup() + int iotcon_options_remove( + ffi.Pointer options, + int id, + ) { + return _iotcon_options_remove( + options, + id, + ); + } + + late final _iotcon_options_remove_ptr = + _lookup>( + 'iotcon_options_remove'); + late final _dart_iotcon_options_remove _iotcon_options_remove = + _iotcon_options_remove_ptr.asFunction<_dart_iotcon_options_remove>(); + + /// @brief Looks up data at the given ID from the options. + /// @since_tizen 3.0 + /// @remarks @a data must not be released using free(). + /// @param[in] options The handle of the options + /// @param[in] id The ID of the option to lookup + /// @param[out] data Found data from options + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_options_create() + /// @see iotcon_options_destroy() + /// @see iotcon_options_add() + /// @see iotcon_options_remove() + int iotcon_options_lookup( + ffi.Pointer options, + int id, + ffi.Pointer> data, + ) { + return _iotcon_options_lookup( + options, + id, + data, + ); + } + + late final _iotcon_options_lookup_ptr = + _lookup>( + 'iotcon_options_lookup'); + late final _dart_iotcon_options_lookup _iotcon_options_lookup = + _iotcon_options_lookup_ptr.asFunction<_dart_iotcon_options_lookup>(); + + /// @brief Gets all data of the options by invoking the callback function. + /// @details iotcon_options_foreach_cb() will be called for each option. \n + /// If iotcon_options_foreach_cb() returns false, iteration will be stopped. + /// @since_tizen 3.0 + /// @param[in] options The handle of the options + /// @param[in] cb The callback function to get data + /// @param[in] user_data The user data to pass to the function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @post iotcon_options_foreach_cb() will be called for each option. + /// @see iotcon_options_foreach_cb() + int iotcon_options_foreach( + ffi.Pointer options, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_options_foreach( + options, + cb, + user_data, + ); + } + + late final _iotcon_options_foreach_ptr = + _lookup>( + 'iotcon_options_foreach'); + late final _dart_iotcon_options_foreach _iotcon_options_foreach = + _iotcon_options_foreach_ptr.asFunction<_dart_iotcon_options_foreach>(); + + /// @brief Creates a new Representation handle. + /// @since_tizen 3.0 + /// @remarks You must destroy @a repr by calling iotcon_representation_destroy() if @a repr is no longer needed. + /// @param[out] repr A newly allocated Representation handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_representation_destroy() + int iotcon_representation_create( + ffi.Pointer> repr, + ) { + return _iotcon_representation_create( + repr, + ); + } + + late final _iotcon_representation_create_ptr = + _lookup>( + 'iotcon_representation_create'); + late final _dart_iotcon_representation_create _iotcon_representation_create = + _iotcon_representation_create_ptr + .asFunction<_dart_iotcon_representation_create>(); + + /// @brief Destroys a Representation. + /// @details Releases @a Representation and its internal data. + /// @since_tizen 3.0 + /// @param[in] repr The representation handle to free + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_representation_create() + int iotcon_representation_destroy( + ffi.Pointer repr, + ) { + return _iotcon_representation_destroy( + repr, + ); + } + + late final _iotcon_representation_destroy_ptr = + _lookup>( + 'iotcon_representation_destroy'); + late final _dart_iotcon_representation_destroy + _iotcon_representation_destroy = _iotcon_representation_destroy_ptr + .asFunction<_dart_iotcon_representation_destroy>(); + + /// @brief Clones from the source Representation. + /// @details Makes a deep copy of a source Representation. + /// @since_tizen 3.0 + /// @remarks You must destroy @a dest by calling iotcon_representation_destroy() if @a dest is no longer needed. + /// @param[in] src Source of Representation to be copied + /// @param[out] dest Clone of a source Representation + /// @return Clone of a source Representation, + /// otherwise NULL on failure + /// @retval iotcon_representation_h Success + /// @retval NULL Failure + int iotcon_representation_clone( + ffi.Pointer src, + ffi.Pointer> dest, + ) { + return _iotcon_representation_clone( + src, + dest, + ); + } + + late final _iotcon_representation_clone_ptr = + _lookup>( + 'iotcon_representation_clone'); + late final _dart_iotcon_representation_clone _iotcon_representation_clone = + _iotcon_representation_clone_ptr + .asFunction<_dart_iotcon_representation_clone>(); + + /// @brief Appends resource type name. + /// @since_tizen 3.0 + /// @remarks Stored string is replaced with @a uri_path. If @a uri_path is NULL, stored string is set to NULL. + /// @param[in] repr The handle to the Representation + /// @param[in] uri_path The URI of resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_representation_set_uri_path( + ffi.Pointer repr, + ffi.Pointer uri_path, + ) { + return _iotcon_representation_set_uri_path( + repr, + uri_path, + ); + } + + late final _iotcon_representation_set_uri_path_ptr = + _lookup>( + 'iotcon_representation_set_uri_path'); + late final _dart_iotcon_representation_set_uri_path + _iotcon_representation_set_uri_path = + _iotcon_representation_set_uri_path_ptr + .asFunction<_dart_iotcon_representation_set_uri_path>(); + + /// @brief Gets a URI path from the Representation. + /// @since_tizen 3.0 + /// @remarks @a uri_path must not be released using free(). + /// @param[in] repr The Representation handle + /// @param[out] uri_path The URI path to get + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + int iotcon_representation_get_uri_path( + ffi.Pointer repr, + ffi.Pointer> uri_path, + ) { + return _iotcon_representation_get_uri_path( + repr, + uri_path, + ); + } + + late final _iotcon_representation_get_uri_path_ptr = + _lookup>( + 'iotcon_representation_get_uri_path'); + late final _dart_iotcon_representation_get_uri_path + _iotcon_representation_get_uri_path = + _iotcon_representation_get_uri_path_ptr + .asFunction<_dart_iotcon_representation_get_uri_path>(); + + /// @brief Sets resource type list to the Representation. + /// @since_tizen 3.0 + /// @remarks Stored list is replaced with @a types. If @a types is NULL, stored list is set to NULL. + /// @param[in] repr The handle to the Representation + /// @param[in] types The resource type list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_representation_set_resource_types( + ffi.Pointer repr, + ffi.Pointer types, + ) { + return _iotcon_representation_set_resource_types( + repr, + types, + ); + } + + late final _iotcon_representation_set_resource_types_ptr = + _lookup>( + 'iotcon_representation_set_resource_types'); + late final _dart_iotcon_representation_set_resource_types + _iotcon_representation_set_resource_types = + _iotcon_representation_set_resource_types_ptr + .asFunction<_dart_iotcon_representation_set_resource_types>(); + + /// @brief Gets list of resource type from the Representation. + /// @since_tizen 3.0 + /// @remarks @a types must not be released using iotcon_resource_types_destroy(). + /// @param[in] repr The Representation handle + /// @param[out] types The list of resource types to get + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_representation_get_resource_types( + ffi.Pointer repr, + ffi.Pointer> types, + ) { + return _iotcon_representation_get_resource_types( + repr, + types, + ); + } + + late final _iotcon_representation_get_resource_types_ptr = + _lookup>( + 'iotcon_representation_get_resource_types'); + late final _dart_iotcon_representation_get_resource_types + _iotcon_representation_get_resource_types = + _iotcon_representation_get_resource_types_ptr + .asFunction<_dart_iotcon_representation_get_resource_types>(); + + /// @brief Sets list of resource interfaces to the Representation. + /// @since_tizen 3.0 + /// @remarks Stored list is replaced with @a ifaces. If @a ifaces is NULL, stored list is set to NULL. + /// @param[in] repr The Representation handle + /// @param[in] ifaces The list of resource interfaces + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_representation_set_resource_interfaces( + ffi.Pointer repr, + ffi.Pointer ifaces, + ) { + return _iotcon_representation_set_resource_interfaces( + repr, + ifaces, + ); + } + + late final _iotcon_representation_set_resource_interfaces_ptr = _lookup< + ffi.NativeFunction<_c_iotcon_representation_set_resource_interfaces>>( + 'iotcon_representation_set_resource_interfaces'); + late final _dart_iotcon_representation_set_resource_interfaces + _iotcon_representation_set_resource_interfaces = + _iotcon_representation_set_resource_interfaces_ptr + .asFunction<_dart_iotcon_representation_set_resource_interfaces>(); + + /// @brief Gets list of resource interfaces from the Representation. + /// @since_tizen 3.0 + /// @remarks @a ifaces must not be released using iotcon_resource_interfaces_destroy(). + /// @param[in] repr The Representation handle + /// @param[out] ifaces The list of resource interfaces to get + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_representation_get_resource_interfaces( + ffi.Pointer repr, + ffi.Pointer> ifaces, + ) { + return _iotcon_representation_get_resource_interfaces( + repr, + ifaces, + ); + } + + late final _iotcon_representation_get_resource_interfaces_ptr = _lookup< + ffi.NativeFunction<_c_iotcon_representation_get_resource_interfaces>>( + 'iotcon_representation_get_resource_interfaces'); + late final _dart_iotcon_representation_get_resource_interfaces + _iotcon_representation_get_resource_interfaces = + _iotcon_representation_get_resource_interfaces_ptr + .asFunction<_dart_iotcon_representation_get_resource_interfaces>(); + + /// @brief Sets a new attributes handle into the Representation. + /// @since_tizen 3.0 + /// @param[in] repr The Representation handle + /// @param[in] attributes The attributes handle to be set newly + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_representation_set_attributes( + ffi.Pointer repr, + ffi.Pointer attributes, + ) { + return _iotcon_representation_set_attributes( + repr, + attributes, + ); + } + + late final _iotcon_representation_set_attributes_ptr = + _lookup>( + 'iotcon_representation_set_attributes'); + late final _dart_iotcon_representation_set_attributes + _iotcon_representation_set_attributes = + _iotcon_representation_set_attributes_ptr + .asFunction<_dart_iotcon_representation_set_attributes>(); + + /// @brief Gets the attributes handle in the Representation. + /// @since_tizen 3.0 + /// @remarks @a attributes must not be released using iotcon_attributes_destroy(). + /// @param[in] repr The Representation handle + /// @param[in] attributes The attributes handle to get + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_representation_get_attributes( + ffi.Pointer repr, + ffi.Pointer> attributes, + ) { + return _iotcon_representation_get_attributes( + repr, + attributes, + ); + } + + late final _iotcon_representation_get_attributes_ptr = + _lookup>( + 'iotcon_representation_get_attributes'); + late final _dart_iotcon_representation_get_attributes + _iotcon_representation_get_attributes = + _iotcon_representation_get_attributes_ptr + .asFunction<_dart_iotcon_representation_get_attributes>(); + + /// @brief Adds a new child Representation on to the end of the parent Representation. + /// @details Duplicated child Representation is allowed to append. + /// @since_tizen 3.0 + /// @param[in] parent The parent Representation handle + /// @param[in] child The child Representation handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_representation_add_child( + ffi.Pointer parent, + ffi.Pointer child, + ) { + return _iotcon_representation_add_child( + parent, + child, + ); + } + + late final _iotcon_representation_add_child_ptr = + _lookup>( + 'iotcon_representation_add_child'); + late final _dart_iotcon_representation_add_child + _iotcon_representation_add_child = _iotcon_representation_add_child_ptr + .asFunction<_dart_iotcon_representation_add_child>(); + + /// @brief Removes a child Representation from parent Representation without freeing. + /// @since_tizen 3.0 + /// @param[in] parent The parent Representation handle + /// @param[in] child The child Representation handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_representation_remove_child( + ffi.Pointer parent, + ffi.Pointer child, + ) { + return _iotcon_representation_remove_child( + parent, + child, + ); + } + + late final _iotcon_representation_remove_child_ptr = + _lookup>( + 'iotcon_representation_remove_child'); + late final _dart_iotcon_representation_remove_child + _iotcon_representation_remove_child = + _iotcon_representation_remove_child_ptr + .asFunction<_dart_iotcon_representation_remove_child>(); + + /// @brief Calls a function for each child Representation of parent. + /// @details iotcon_children_cb() will be called for each child. + /// @since_tizen 3.0 + /// @param[in] parent The parent Representation handle + /// @param[in] cb The callback function to invoke + /// @param[in] user_data The user data to pass to the function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @post iotcon_children_cb() will be called for each child. + /// @see iotcon_children_cb() + int iotcon_representation_foreach_children( + ffi.Pointer parent, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_representation_foreach_children( + parent, + cb, + user_data, + ); + } + + late final _iotcon_representation_foreach_children_ptr = + _lookup>( + 'iotcon_representation_foreach_children'); + late final _dart_iotcon_representation_foreach_children + _iotcon_representation_foreach_children = + _iotcon_representation_foreach_children_ptr + .asFunction<_dart_iotcon_representation_foreach_children>(); + + /// @brief Gets the number of child Representations in the parent Representation. + /// @since_tizen 3.0 + /// @param[in] parent The parent Representation handle + /// @param[out] count The number of child Representations + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_representation_get_child_count( + ffi.Pointer parent, + ffi.Pointer count, + ) { + return _iotcon_representation_get_child_count( + parent, + count, + ); + } + + late final _iotcon_representation_get_child_count_ptr = + _lookup>( + 'iotcon_representation_get_child_count'); + late final _dart_iotcon_representation_get_child_count + _iotcon_representation_get_child_count = + _iotcon_representation_get_child_count_ptr + .asFunction<_dart_iotcon_representation_get_child_count>(); + + /// @brief Gets the child Representation at the given position. + /// @details Iterates over the parent until it reaches the @a pos-1 position. + /// @since_tizen 3.0 + /// @remarks @a child must not be released using iotcon_representation_destroy(). + /// @param[in] parent The parent Representation handle + /// @param[in] pos The position of the child Representation + /// @param[out] child The handle to the child Representation + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + int iotcon_representation_get_nth_child( + ffi.Pointer parent, + int pos, + ffi.Pointer> child, + ) { + return _iotcon_representation_get_nth_child( + parent, + pos, + child, + ); + } + + late final _iotcon_representation_get_nth_child_ptr = + _lookup>( + 'iotcon_representation_get_nth_child'); + late final _dart_iotcon_representation_get_nth_child + _iotcon_representation_get_nth_child = + _iotcon_representation_get_nth_child_ptr + .asFunction<_dart_iotcon_representation_get_nth_child>(); + + /// @brief Creates a new resource types handle. + /// @since_tizen 3.0 + /// @remarks You must destroy @a types by calling iotcon_resource_types_destroy() if @a types is no longer needed. + /// @param[out] types A newly allocated list of resource types handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_resource_types_destroy() + /// @see iotcon_resource_types_add() + /// @see iotcon_resource_types_remove() + /// @see iotcon_resource_types_clone() + int iotcon_resource_types_create( + ffi.Pointer> types, + ) { + return _iotcon_resource_types_create( + types, + ); + } + + late final _iotcon_resource_types_create_ptr = + _lookup>( + 'iotcon_resource_types_create'); + late final _dart_iotcon_resource_types_create _iotcon_resource_types_create = + _iotcon_resource_types_create_ptr + .asFunction<_dart_iotcon_resource_types_create>(); + + /// @brief Destroys a resource types handle. + /// @since_tizen 3.0 + /// @param[in] types The handle of the resource types + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_resource_types_create() + /// @see iotcon_resource_types_add() + /// @see iotcon_resource_types_remove() + /// @see iotcon_resource_types_clone() + int iotcon_resource_types_destroy( + ffi.Pointer types, + ) { + return _iotcon_resource_types_destroy( + types, + ); + } + + late final _iotcon_resource_types_destroy_ptr = + _lookup>( + 'iotcon_resource_types_destroy'); + late final _dart_iotcon_resource_types_destroy + _iotcon_resource_types_destroy = _iotcon_resource_types_destroy_ptr + .asFunction<_dart_iotcon_resource_types_destroy>(); + + /// @brief Inserts a resource types into the list. + /// @since_tizen 3.0 + /// @remarks The length of @a type should be less than or equal to 61.\n + /// The @a type must start with a lowercase alphabetic character, followed by a sequence + /// of lowercase alphabetic, numeric, ".", or "-" characters, and contains no white space.\n + /// Duplicate strings are not allowed. + /// @param[in] types The handle of the resource types + /// @param[in] type The string data to insert into the resource types (e.g. "org.tizen.light") + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_ALREADY Already done + /// @see iotcon_resource_types_create() + /// @see iotcon_resource_types_destroy() + /// @see iotcon_resource_types_remove() + /// @see iotcon_resource_types_clone() + int iotcon_resource_types_add( + ffi.Pointer types, + ffi.Pointer type, + ) { + return _iotcon_resource_types_add( + types, + type, + ); + } + + late final _iotcon_resource_types_add_ptr = + _lookup>( + 'iotcon_resource_types_add'); + late final _dart_iotcon_resource_types_add _iotcon_resource_types_add = + _iotcon_resource_types_add_ptr + .asFunction<_dart_iotcon_resource_types_add>(); + + /// @brief Deletes a resource types from the list. + /// @since_tizen 3.0 + /// @param[in] types The handle of the resource types + /// @param[in] type The string data to delete from the resource types + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @see iotcon_resource_types_create() + /// @see iotcon_resource_types_destroy() + /// @see iotcon_resource_types_add() + /// @see iotcon_resource_types_clone() + int iotcon_resource_types_remove( + ffi.Pointer types, + ffi.Pointer type, + ) { + return _iotcon_resource_types_remove( + types, + type, + ); + } + + late final _iotcon_resource_types_remove_ptr = + _lookup>( + 'iotcon_resource_types_remove'); + late final _dart_iotcon_resource_types_remove _iotcon_resource_types_remove = + _iotcon_resource_types_remove_ptr + .asFunction<_dart_iotcon_resource_types_remove>(); + + /// @brief Gets all of the resource types of the list by invoking the callback function. + /// @details iotcon_resource_types_foreach_cb() will be called for each type. \n + /// If iotcon_resource_types_foreach_cb() returns false, iteration will be stopped. + /// @since_tizen 3.0 + /// @param[in] types The handle of resource types + /// @param[in] cb The callback function to get data + /// @param[in] user_data The user data to pass to the function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @post iotcon_resource_types_foreach() will be called for each type. + /// @see iotcon_resource_types_foreach_cb() + int iotcon_resource_types_foreach( + ffi.Pointer types, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_resource_types_foreach( + types, + cb, + user_data, + ); + } + + late final _iotcon_resource_types_foreach_ptr = + _lookup>( + 'iotcon_resource_types_foreach'); + late final _dart_iotcon_resource_types_foreach + _iotcon_resource_types_foreach = _iotcon_resource_types_foreach_ptr + .asFunction<_dart_iotcon_resource_types_foreach>(); + + /// @brief Clones the resource types handle. + /// @details Makes a deep copy of a source list of resource types. + /// @since_tizen 3.0 + /// @remarks You must @a destroy dest by calling iotcon_resource_types_destroy() if @a dest is no longer needed. + /// @param[in] src The origin handle of the resource types + /// @param[out] dest Clone of a source list of resource types + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_resource_types_create() + /// @see iotcon_resource_types_destroy() + /// @see iotcon_resource_types_add() + /// @see iotcon_resource_types_remove() + int iotcon_resource_types_clone( + ffi.Pointer src, + ffi.Pointer> dest, + ) { + return _iotcon_resource_types_clone( + src, + dest, + ); + } + + late final _iotcon_resource_types_clone_ptr = + _lookup>( + 'iotcon_resource_types_clone'); + late final _dart_iotcon_resource_types_clone _iotcon_resource_types_clone = + _iotcon_resource_types_clone_ptr + .asFunction<_dart_iotcon_resource_types_clone>(); + + /// @brief Creates a new resource interfaces handle. + /// @since_tizen 3.0 + /// @remarks You must destroy @a ifaces by calling iotcon_resource_interfaces_destroy() if @a ifaces is no longer needed. + /// @param[out] ifaces A newly allocated list of resource ifaces handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_resource_interfaces_destroy() + /// @see iotcon_resource_interfaces_add() + /// @see iotcon_resource_interfaces_remove() + /// @see iotcon_resource_interfaces_clone() + int iotcon_resource_interfaces_create( + ffi.Pointer> ifaces, + ) { + return _iotcon_resource_interfaces_create( + ifaces, + ); + } + + late final _iotcon_resource_interfaces_create_ptr = + _lookup>( + 'iotcon_resource_interfaces_create'); + late final _dart_iotcon_resource_interfaces_create + _iotcon_resource_interfaces_create = + _iotcon_resource_interfaces_create_ptr + .asFunction<_dart_iotcon_resource_interfaces_create>(); + + /// @brief Destroys a resource ifaces handle. + /// @since_tizen 3.0 + /// @param[in] ifaces The handle of the resource ifaces + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_resource_interfaces_create() + /// @see iotcon_resource_interfaces_add() + /// @see iotcon_resource_interfaces_remove() + /// @see iotcon_resource_interfaces_clone() + int iotcon_resource_interfaces_destroy( + ffi.Pointer ifaces, + ) { + return _iotcon_resource_interfaces_destroy( + ifaces, + ); + } + + late final _iotcon_resource_interfaces_destroy_ptr = + _lookup>( + 'iotcon_resource_interfaces_destroy'); + late final _dart_iotcon_resource_interfaces_destroy + _iotcon_resource_interfaces_destroy = + _iotcon_resource_interfaces_destroy_ptr + .asFunction<_dart_iotcon_resource_interfaces_destroy>(); + + /// @brief Inserts a resource iface into the list. + /// @since_tizen 3.0 + /// @remarks @a iface could be a value such as #IOTCON_INTERFACE_DEFAULT. + /// @param[in] ifaces The handle of the resource ifaces + /// @param[in] iface The string data to insert into the resource ifaces + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_ALREADY Already done + /// @see iotcon_resource_interfaces_create() + /// @see iotcon_resource_interfaces_destroy() + /// @see iotcon_resource_interfaces_remove() + /// @see iotcon_resource_interfaces_clone() + int iotcon_resource_interfaces_add( + ffi.Pointer ifaces, + ffi.Pointer iface, + ) { + return _iotcon_resource_interfaces_add( + ifaces, + iface, + ); + } + + late final _iotcon_resource_interfaces_add_ptr = + _lookup>( + 'iotcon_resource_interfaces_add'); + late final _dart_iotcon_resource_interfaces_add + _iotcon_resource_interfaces_add = _iotcon_resource_interfaces_add_ptr + .asFunction<_dart_iotcon_resource_interfaces_add>(); + + /// @brief Deletes a resource iface from the list. + /// @since_tizen 3.0 + /// @remarks @a iface could be a value such as #IOTCON_INTERFACE_DEFAULT. + /// @param[in] ifaces The handle of the resource ifaces + /// @param[in] iface The string data to delete from the resource ifaces + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @see iotcon_resource_interfaces_create() + /// @see iotcon_resource_interfaces_destroy() + /// @see iotcon_resource_interfaces_add() + /// @see iotcon_resource_interfaces_clone() + int iotcon_resource_interfaces_remove( + ffi.Pointer ifaces, + ffi.Pointer iface, + ) { + return _iotcon_resource_interfaces_remove( + ifaces, + iface, + ); + } + + late final _iotcon_resource_interfaces_remove_ptr = + _lookup>( + 'iotcon_resource_interfaces_remove'); + late final _dart_iotcon_resource_interfaces_remove + _iotcon_resource_interfaces_remove = + _iotcon_resource_interfaces_remove_ptr + .asFunction<_dart_iotcon_resource_interfaces_remove>(); + + /// @brief Gets all of the resource ifaces of the list by invoking the callback function. + /// @details iotcon_resource_interfaces_foreach_cb() will be called for each iface. \n + /// If iotcon_resource_interfaces_foreach_cb() returns false, iteration will be stopped. + /// @since_tizen 3.0 + /// @param[in] ifaces The handle of resource ifaces + /// @param[in] cb The callback function to get data + /// @param[in] user_data The user data to pass to the function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @post iotcon_resource_interfaces_foreach() will be called for each iface. + /// @see iotcon_resource_interfaces_foreach_cb() + int iotcon_resource_interfaces_foreach( + ffi.Pointer ifaces, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_resource_interfaces_foreach( + ifaces, + cb, + user_data, + ); + } + + late final _iotcon_resource_interfaces_foreach_ptr = + _lookup>( + 'iotcon_resource_interfaces_foreach'); + late final _dart_iotcon_resource_interfaces_foreach + _iotcon_resource_interfaces_foreach = + _iotcon_resource_interfaces_foreach_ptr + .asFunction<_dart_iotcon_resource_interfaces_foreach>(); + + /// @brief Clones the resource ifaces handle. + /// @details Makes a deep copy of a source list of resource ifaces. + /// @since_tizen 3.0 + /// @remarks You must @a destroy dest by calling iotcon_resource_interfaces_destroy() if @a dest is no longer needed. + /// @param[in] src The origin handle of the resource ifaces + /// @param[out] dest Clone of a source list of resource ifaces + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_resource_interfaces_create() + /// @see iotcon_resource_interfaces_destroy() + /// @see iotcon_resource_interfaces_add() + /// @see iotcon_resource_interfaces_remove() + int iotcon_resource_interfaces_clone( + ffi.Pointer src, + ffi.Pointer> dest, + ) { + return _iotcon_resource_interfaces_clone( + src, + dest, + ); + } + + late final _iotcon_resource_interfaces_clone_ptr = + _lookup>( + 'iotcon_resource_interfaces_clone'); + late final _dart_iotcon_resource_interfaces_clone + _iotcon_resource_interfaces_clone = _iotcon_resource_interfaces_clone_ptr + .asFunction<_dart_iotcon_resource_interfaces_clone>(); + + /// @brief Creates a resource handle and registers the resource in server. + /// @details Registers a resource specified by @a uri_path, @a res_types, @a ifaces which has @a properties in IoTCon server. \n + /// When client finds the registered resource, iotcon_request_handler_cb() will be called automatically. \n + /// @a uri_path format would be relative URI path like '/a/light' \n + /// @a res_types is a list of resource types. Create a iotcon_resource_types_h handle and add types string to it. \n + /// @a ifaces is a list of resource interfaces. Create a iotcon_resource_interfaces_h handle and add interfaces string to it. \n + /// @a policies also can contain multiple policies like IOTCON_RESOURCE_DISCOVERABLE | IOTCON_RESOURCE_OBSERVABLE. \n + /// iotcon_request_handler_cb() will be called when receive CRUD request to the registered resource. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks @a uri_path length must be less than 128. \n + /// You must destroy @a resource by calling iotcon_resource_destroy() if @a resource is no longer needed. + /// @param[in] uri_path The URI path of the resource + /// @param[in] res_types The list of type of the resource + /// @param[in] ifaces The list of interface of the resource + /// @param[in] policies The policies of the resource \n + /// Set of #iotcon_resource_policy_e + /// @param[in] cb The request handler callback function + /// @param[in] user_data The user data to pass to the callback function + /// @param[out] resource_handle The handle of the resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_IOTIVITY IoTivity errors + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @post When the resource receive CRUD request, iotcon_request_handler_cb() will be called. + /// @see iotcon_resource_destroy() + /// @see iotcon_resource_bind_interface() + /// @see iotcon_resource_bind_type() + /// @see iotcon_resource_set_request_handler() + /// @see iotcon_resource_bind_child_resource() + /// @see iotcon_resource_unbind_child_resource() + /// @see iotcon_request_handler_cb() + int iotcon_resource_create( + ffi.Pointer uri_path, + ffi.Pointer res_types, + ffi.Pointer ifaces, + int policies, + ffi.Pointer> cb, + ffi.Pointer user_data, + ffi.Pointer> resource_handle, + ) { + return _iotcon_resource_create( + uri_path, + res_types, + ifaces, + policies, + cb, + user_data, + resource_handle, + ); + } + + late final _iotcon_resource_create_ptr = + _lookup>( + 'iotcon_resource_create'); + late final _dart_iotcon_resource_create _iotcon_resource_create = + _iotcon_resource_create_ptr.asFunction<_dart_iotcon_resource_create>(); + + /// @brief Destroys the resource and releases its data. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks When a normal variable is used, there is only permission denied error. + /// If the errors of this API are not handled, then you must check an application has the privileges for the API. + /// @param[in] resource_handle The handle of the resource to be unregistered + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_resource_create() + /// @see iotcon_resource_bind_interface() + /// @see iotcon_resource_bind_type() + /// @see iotcon_resource_set_request_handler() + /// @see iotcon_resource_bind_child_resource() + /// @see iotcon_resource_unbind_child_resource() + /// @see iotcon_request_handler_cb() + int iotcon_resource_destroy( + ffi.Pointer resource_handle, + ) { + return _iotcon_resource_destroy( + resource_handle, + ); + } + + late final _iotcon_resource_destroy_ptr = + _lookup>( + 'iotcon_resource_destroy'); + late final _dart_iotcon_resource_destroy _iotcon_resource_destroy = + _iotcon_resource_destroy_ptr.asFunction<_dart_iotcon_resource_destroy>(); + + /// @brief Binds an interface to the resource. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks @a iface could be a value such as #IOTCON_INTERFACE_DEFAULT. + /// @param[in] resource The handle of the resource + /// @param[in] iface The interface to be bound to the resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @retval #IOTCON_ERROR_ALREADY Already done + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_resource_create() + /// @see iotcon_resource_destroy() + /// @see iotcon_resource_bind_type() + /// @see iotcon_resource_set_request_handler() + /// @see iotcon_resource_bind_child_resource() + /// @see iotcon_resource_unbind_child_resource() + /// @see iotcon_request_handler_cb() + int iotcon_resource_bind_interface( + ffi.Pointer resource, + ffi.Pointer iface, + ) { + return _iotcon_resource_bind_interface( + resource, + iface, + ); + } + + late final _iotcon_resource_bind_interface_ptr = + _lookup>( + 'iotcon_resource_bind_interface'); + late final _dart_iotcon_resource_bind_interface + _iotcon_resource_bind_interface = _iotcon_resource_bind_interface_ptr + .asFunction<_dart_iotcon_resource_bind_interface>(); + + /// @brief Binds a type to the resource. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks The length of @a resource_type should be less than or equal to 61.\n + /// The @a resource_type must start with a lowercase alphabetic character, followed by a sequence + /// of lowercase alphabetic, numeric, ".", or "-" characters, and contains no white space. + /// @param[in] resource_handle The handle of the resource + /// @param[in] resource_type The type to be bound to the resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @retval #IOTCON_ERROR_ALREADY Already done + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_resource_create() + /// @see iotcon_resource_destroy() + /// @see iotcon_resource_bind_interface() + /// @see iotcon_resource_set_request_handler() + /// @see iotcon_resource_bind_child_resource() + /// @see iotcon_resource_unbind_child_resource() + /// @see iotcon_request_handler_cb() + int iotcon_resource_bind_type( + ffi.Pointer resource_handle, + ffi.Pointer resource_type, + ) { + return _iotcon_resource_bind_type( + resource_handle, + resource_type, + ); + } + + late final _iotcon_resource_bind_type_ptr = + _lookup>( + 'iotcon_resource_bind_type'); + late final _dart_iotcon_resource_bind_type _iotcon_resource_bind_type = + _iotcon_resource_bind_type_ptr + .asFunction<_dart_iotcon_resource_bind_type>(); + + /// @brief Sets a request handler to the resource. + /// @details When the resource receive CRUD request, iotcon_request_handler_cb() will be called. + /// @since_tizen 3.0 + /// @remarks Registered callback function will be replaced with the new @a cb. + /// @param[in] resource The handle of the resource + /// @param[in] cb The request handler to be bound to the resource + /// @param[in] user_data The user data to pass to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_resource_create() + /// @see iotcon_resource_destroy() + /// @see iotcon_resource_bind_interface() + /// @see iotcon_resource_bind_type() + /// @see iotcon_resource_bind_child_resource() + /// @see iotcon_resource_unbind_child_resource() + /// @see iotcon_request_handler_cb() + int iotcon_resource_set_request_handler( + ffi.Pointer resource, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_resource_set_request_handler( + resource, + cb, + user_data, + ); + } + + late final _iotcon_resource_set_request_handler_ptr = + _lookup>( + 'iotcon_resource_set_request_handler'); + late final _dart_iotcon_resource_set_request_handler + _iotcon_resource_set_request_handler = + _iotcon_resource_set_request_handler_ptr + .asFunction<_dart_iotcon_resource_set_request_handler>(); + + /// @brief Binds a child resource into the parent resource. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] parent The handle of the parent resource + /// @param[in] child The handle of the child resource to be added to the parent resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_ALREADY Already done + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_resource_create() + /// @see iotcon_resource_destroy() + /// @see iotcon_resource_bind_interface() + /// @see iotcon_resource_bind_type() + /// @see iotcon_resource_set_request_handler() + /// @see iotcon_resource_unbind_child_resource() + /// @see iotcon_request_handler_cb() + int iotcon_resource_bind_child_resource( + ffi.Pointer parent, + ffi.Pointer child, + ) { + return _iotcon_resource_bind_child_resource( + parent, + child, + ); + } + + late final _iotcon_resource_bind_child_resource_ptr = + _lookup>( + 'iotcon_resource_bind_child_resource'); + late final _dart_iotcon_resource_bind_child_resource + _iotcon_resource_bind_child_resource = + _iotcon_resource_bind_child_resource_ptr + .asFunction<_dart_iotcon_resource_bind_child_resource>(); + + /// @brief Unbinds a child resource from the parent resource. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] parent The handle of the parent resource + /// @param[in] child The handle of the child resource to be unbound from the parent resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_resource_create() + /// @see iotcon_resource_destroy() + /// @see iotcon_resource_bind_interface() + /// @see iotcon_resource_bind_type() + /// @see iotcon_resource_set_request_handler() + /// @see iotcon_resource_bind_child_resource() + /// @see iotcon_request_handler_cb() + int iotcon_resource_unbind_child_resource( + ffi.Pointer parent, + ffi.Pointer child, + ) { + return _iotcon_resource_unbind_child_resource( + parent, + child, + ); + } + + late final _iotcon_resource_unbind_child_resource_ptr = + _lookup>( + 'iotcon_resource_unbind_child_resource'); + late final _dart_iotcon_resource_unbind_child_resource + _iotcon_resource_unbind_child_resource = + _iotcon_resource_unbind_child_resource_ptr + .asFunction<_dart_iotcon_resource_unbind_child_resource>(); + + /// @brief Notifies specific clients that resource's attributes have changed. + /// @details If @a observers is @c NULL, the @a msg will notify to all observers. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] resource The handle of the resource + /// @param[in] repr The handle of the representation + /// @param[in] observers The handle of the observers + /// @param[in] qos The quality of service for message transfer + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_REPRESENTATION Representation error + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_remote_resource_observe_cb() + /// @see iotcon_remote_resource_observe_register() + /// @see iotcon_remote_resource_observe_deregister() + /// @see iotcon_observers_create() + /// @see iotcon_observers_destroy() + /// @see iotcon_observers_add() + /// @see iotcon_observers_remove() + int iotcon_resource_notify( + ffi.Pointer resource, + ffi.Pointer repr, + ffi.Pointer observers, + int qos, + ) { + return _iotcon_resource_notify( + resource, + repr, + observers, + qos, + ); + } + + late final _iotcon_resource_notify_ptr = + _lookup>( + 'iotcon_resource_notify'); + late final _dart_iotcon_resource_notify _iotcon_resource_notify = + _iotcon_resource_notify_ptr.asFunction<_dart_iotcon_resource_notify>(); + + /// @brief Gets the number of child resources of the resource. + /// @since_tizen 3.0 + /// @param[in] resource The handle of the resource + /// @param[out] count The number of child resources + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_resource_get_nth_child() + /// @see iotcon_resource_get_uri_path() + /// @see iotcon_resource_get_types() + /// @see iotcon_resource_get_interfaces() + /// @see iotcon_resource_get_policies() + int iotcon_resource_get_child_count( + ffi.Pointer resource, + ffi.Pointer count, + ) { + return _iotcon_resource_get_child_count( + resource, + count, + ); + } + + late final _iotcon_resource_get_child_count_ptr = + _lookup>( + 'iotcon_resource_get_child_count'); + late final _dart_iotcon_resource_get_child_count + _iotcon_resource_get_child_count = _iotcon_resource_get_child_count_ptr + .asFunction<_dart_iotcon_resource_get_child_count>(); + + /// @brief Gets the child resource at the given index in the parent resource. + /// @since_tizen 3.0 + /// @remarks @a child must not be released using iotcon_resource_destroy(). + /// @param[in] parent The handle of the parent resource + /// @param[in] index The index of the child resource + /// @param[out] child The child resource at the index + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @see iotcon_resource_get_child_count() + /// @see iotcon_resource_get_uri_path() + /// @see iotcon_resource_get_types() + /// @see iotcon_resource_get_interfaces() + /// @see iotcon_resource_get_policies() + int iotcon_resource_get_nth_child( + ffi.Pointer parent, + int index, + ffi.Pointer> child, + ) { + return _iotcon_resource_get_nth_child( + parent, + index, + child, + ); + } + + late final _iotcon_resource_get_nth_child_ptr = + _lookup>( + 'iotcon_resource_get_nth_child'); + late final _dart_iotcon_resource_get_nth_child + _iotcon_resource_get_nth_child = _iotcon_resource_get_nth_child_ptr + .asFunction<_dart_iotcon_resource_get_nth_child>(); + + /// @brief Gets an URI path of the resource. + /// @since_tizen 3.0 + /// @remarks @a uri_path must not be released using free(). + /// @param[in] resource The handle of the resource + /// @param[out] uri_path The URI path of the resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_resource_get_child_count() + /// @see iotcon_resource_get_nth_child() + /// @see iotcon_resource_get_types() + /// @see iotcon_resource_get_interfaces() + /// @see iotcon_resource_get_policies() + int iotcon_resource_get_uri_path( + ffi.Pointer resource, + ffi.Pointer> uri_path, + ) { + return _iotcon_resource_get_uri_path( + resource, + uri_path, + ); + } + + late final _iotcon_resource_get_uri_path_ptr = + _lookup>( + 'iotcon_resource_get_uri_path'); + late final _dart_iotcon_resource_get_uri_path _iotcon_resource_get_uri_path = + _iotcon_resource_get_uri_path_ptr + .asFunction<_dart_iotcon_resource_get_uri_path>(); + + /// @brief Gets the list of types in the resource. + /// @since_tizen 3.0 + /// @remarks @a types must not be released using iotcon_resource_types_destroy(). + /// @param[in] resource The handle of the resource + /// @param[out] types The types of the resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_resource_get_child_count() + /// @see iotcon_resource_get_nth_child() + /// @see iotcon_resource_get_uri_path() + /// @see iotcon_resource_get_interfaces() + /// @see iotcon_resource_get_policies() + int iotcon_resource_get_types( + ffi.Pointer resource, + ffi.Pointer> types, + ) { + return _iotcon_resource_get_types( + resource, + types, + ); + } + + late final _iotcon_resource_get_types_ptr = + _lookup>( + 'iotcon_resource_get_types'); + late final _dart_iotcon_resource_get_types _iotcon_resource_get_types = + _iotcon_resource_get_types_ptr + .asFunction<_dart_iotcon_resource_get_types>(); + + /// @brief Gets the interfaces of the resource. + /// @since_tizen 3.0 + /// @remarks @a ifaces must not be released using iotcon_resource_interfaces_destroy(). + /// @param[in] resource The handle of the resource + /// @param[out] ifaces The interfaces of the resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_resource_get_child_count() + /// @see iotcon_resource_get_nth_child() + /// @see iotcon_resource_get_uri_path() + /// @see iotcon_resource_get_types() + /// @see iotcon_resource_get_policies() + int iotcon_resource_get_interfaces( + ffi.Pointer resource, + ffi.Pointer> ifaces, + ) { + return _iotcon_resource_get_interfaces( + resource, + ifaces, + ); + } + + late final _iotcon_resource_get_interfaces_ptr = + _lookup>( + 'iotcon_resource_get_interfaces'); + late final _dart_iotcon_resource_get_interfaces + _iotcon_resource_get_interfaces = _iotcon_resource_get_interfaces_ptr + .asFunction<_dart_iotcon_resource_get_interfaces>(); + + /// @brief Gets the policies in the resource. + /// @details @a policies can contain multiple policies like IOTCON_RESOURCE_DISCOVERABLE | IOTCON_RESOURCE_OBSERVABLE. + /// @since_tizen 3.0 + /// @param[in] resource The handle of the resource + /// @param[out] policies The policies of resource \n + /// Set of #iotcon_resource_policy_e + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_resource_get_child_count() + /// @see iotcon_resource_get_nth_child() + /// @see iotcon_resource_get_uri_path() + /// @see iotcon_resource_get_types() + /// @see iotcon_resource_get_interfaces() + int iotcon_resource_get_policies( + ffi.Pointer resource, + ffi.Pointer policies, + ) { + return _iotcon_resource_get_policies( + resource, + policies, + ); + } + + late final _iotcon_resource_get_policies_ptr = + _lookup>( + 'iotcon_resource_get_policies'); + late final _dart_iotcon_resource_get_policies _iotcon_resource_get_policies = + _iotcon_resource_get_policies_ptr + .asFunction<_dart_iotcon_resource_get_policies>(); + + /// @brief Creates a lite resource handle and registers the resource in server. + /// @details Registers a resource specified by @a uri_path, @a res_types, @a attributes which have @a properties in IoTCon server. \n + /// When client requests some operations, it send a response to client, automatically.\n + /// The @a policies can contain multiple policies like IOTCON_RESOURCE_DISCOVERABLE | IOTCON_RESOURCE_OBSERVABLE. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks @a uri_path length must be less than 128. \n + /// You must destroy @a resource_handle by calling iotcon_lite_resource_destroy() if @a remote_handle is no longer needed. + /// @param[in] uri_path The URI path of the resource + /// @param[in] res_types The list of type of the resource + /// @param[in] policies The policies of the resource \n + /// Set of #iotcon_resource_policy_e + /// @param[in] attributes The attributes handle to set + /// @param[in] cb The callback function to add into callback list + /// @param[in] user_data The user data to pass to the callback function + /// @param[out] resource_handle The handle of the resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_IOTIVITY IoTivity errors + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_lite_resource_destroy() + int iotcon_lite_resource_create( + ffi.Pointer uri_path, + ffi.Pointer res_types, + int policies, + ffi.Pointer attributes, + ffi.Pointer> cb, + ffi.Pointer user_data, + ffi.Pointer> resource_handle, + ) { + return _iotcon_lite_resource_create( + uri_path, + res_types, + policies, + attributes, + cb, + user_data, + resource_handle, + ); + } + + late final _iotcon_lite_resource_create_ptr = + _lookup>( + 'iotcon_lite_resource_create'); + late final _dart_iotcon_lite_resource_create _iotcon_lite_resource_create = + _iotcon_lite_resource_create_ptr + .asFunction<_dart_iotcon_lite_resource_create>(); + + /// @brief Destroys the resource and releases its data. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks When a normal variable is used, there is only permission denied error. + /// If the errors of this API are not handled, then you must check an application having the privileges for the API. + /// @param[in] resource The handle of the lite resource to be unregistered + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_lite_resource_create() + int iotcon_lite_resource_destroy( + ffi.Pointer resource, + ) { + return _iotcon_lite_resource_destroy( + resource, + ); + } + + late final _iotcon_lite_resource_destroy_ptr = + _lookup>( + 'iotcon_lite_resource_destroy'); + late final _dart_iotcon_lite_resource_destroy _iotcon_lite_resource_destroy = + _iotcon_lite_resource_destroy_ptr + .asFunction<_dart_iotcon_lite_resource_destroy>(); + + /// @brief Updates attributes into the lite resource handle. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] resource The handle of the lite resource + /// @param[in] attributes The attributes handle to update + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_lite_resource_get_attributes() + int iotcon_lite_resource_update_attributes( + ffi.Pointer resource, + ffi.Pointer attributes, + ) { + return _iotcon_lite_resource_update_attributes( + resource, + attributes, + ); + } + + late final _iotcon_lite_resource_update_attributes_ptr = + _lookup>( + 'iotcon_lite_resource_update_attributes'); + late final _dart_iotcon_lite_resource_update_attributes + _iotcon_lite_resource_update_attributes = + _iotcon_lite_resource_update_attributes_ptr + .asFunction<_dart_iotcon_lite_resource_update_attributes>(); + + /// @brief Gets attributes from the lite resource handle. + /// @since_tizen 3.0 + /// @remarks @a attributes must not be released using iotcon_attributes_destroy(). + /// @param[in] resource The handle of the lite resource + /// @param[out] attributes The attributes handle of the lite resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_lite_resource_update_attributes() + int iotcon_lite_resource_get_attributes( + ffi.Pointer resource, + ffi.Pointer> attributes, + ) { + return _iotcon_lite_resource_get_attributes( + resource, + attributes, + ); + } + + late final _iotcon_lite_resource_get_attributes_ptr = + _lookup>( + 'iotcon_lite_resource_get_attributes'); + late final _dart_iotcon_lite_resource_get_attributes + _iotcon_lite_resource_get_attributes = + _iotcon_lite_resource_get_attributes_ptr + .asFunction<_dart_iotcon_lite_resource_get_attributes>(); + + /// @brief Creates a response handle. + /// @since_tizen 3.0 + /// @remarks You must destroy @a response by calling iotcon_response_destroy() if @a response is no longer needed. + /// @param[in] request The handle of received request handle + /// @param[out] response Generated response handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @see iotcon_response_destroy() + int iotcon_response_create( + ffi.Pointer request, + ffi.Pointer> response, + ) { + return _iotcon_response_create( + request, + response, + ); + } + + late final _iotcon_response_create_ptr = + _lookup>( + 'iotcon_response_create'); + late final _dart_iotcon_response_create _iotcon_response_create = + _iotcon_response_create_ptr.asFunction<_dart_iotcon_response_create>(); + + /// @brief Destroys a response handle. + /// @since_tizen 3.0 + /// @param[in] resp The handle of the response + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_response_create() + int iotcon_response_destroy( + ffi.Pointer resp, + ) { + return _iotcon_response_destroy( + resp, + ); + } + + late final _iotcon_response_destroy_ptr = + _lookup>( + 'iotcon_response_destroy'); + late final _dart_iotcon_response_destroy _iotcon_response_destroy = + _iotcon_response_destroy_ptr.asFunction<_dart_iotcon_response_destroy>(); + + /// @brief Gets header options of the response. + /// @since_tizen 3.0 + /// @remarks @a options must not be released using iotcon_options_destroy(). + /// @param[in] resp The handle of the response + /// @param[out] options The handle of the header options + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_response_get_representation() + /// @see iotcon_response_get_result() + int iotcon_response_get_options( + ffi.Pointer resp, + ffi.Pointer> options, + ) { + return _iotcon_response_get_options( + resp, + options, + ); + } + + late final _iotcon_response_get_options_ptr = + _lookup>( + 'iotcon_response_get_options'); + late final _dart_iotcon_response_get_options _iotcon_response_get_options = + _iotcon_response_get_options_ptr + .asFunction<_dart_iotcon_response_get_options>(); + + /// @brief Gets representation of the response. + /// @since_tizen 3.0 + /// @remarks @a repr must not be released using iotcon_representation_destroy(). + /// @param[in] resp The handle of the response + /// @param[out] repr The handle of the representation + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data + /// @see iotcon_response_get_options() + /// @see iotcon_response_get_result() + int iotcon_response_get_representation( + ffi.Pointer resp, + ffi.Pointer> repr, + ) { + return _iotcon_response_get_representation( + resp, + repr, + ); + } + + late final _iotcon_response_get_representation_ptr = + _lookup>( + 'iotcon_response_get_representation'); + late final _dart_iotcon_response_get_representation + _iotcon_response_get_representation = + _iotcon_response_get_representation_ptr + .asFunction<_dart_iotcon_response_get_representation>(); + + /// @brief Gets result of the response. + /// @since_tizen 3.0 + /// @param[in] resp The handle of the response + /// @param[out] result The result of the response + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_response_get_options() + /// @see iotcon_response_get_representation() + int iotcon_response_get_result( + ffi.Pointer resp, + ffi.Pointer result, + ) { + return _iotcon_response_get_result( + resp, + result, + ); + } + + late final _iotcon_response_get_result_ptr = + _lookup>( + 'iotcon_response_get_result'); + late final _dart_iotcon_response_get_result _iotcon_response_get_result = + _iotcon_response_get_result_ptr + .asFunction<_dart_iotcon_response_get_result>(); + + /// @brief Sets result into the response. + /// @details The @a result could be one of #iotcon_response_result_e. + /// @since_tizen 3.0 + /// @param[in] resp The handle of the response + /// @param[in] result The result to set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @see iotcon_response_create() + /// @see iotcon_response_destroy() + int iotcon_response_set_result( + ffi.Pointer resp, + int result, + ) { + return _iotcon_response_set_result( + resp, + result, + ); + } + + late final _iotcon_response_set_result_ptr = + _lookup>( + 'iotcon_response_set_result'); + late final _dart_iotcon_response_set_result _iotcon_response_set_result = + _iotcon_response_set_result_ptr + .asFunction<_dart_iotcon_response_set_result>(); + + /// @brief Sets representation into the response. + /// @since_tizen 3.0 + /// @param[in] resp The handle of the response + /// @param[in] repr The representation of the response + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @see iotcon_response_create() + /// @see iotcon_response_destroy() + int iotcon_response_set_representation( + ffi.Pointer resp, + ffi.Pointer repr, + ) { + return _iotcon_response_set_representation( + resp, + repr, + ); + } + + late final _iotcon_response_set_representation_ptr = + _lookup>( + 'iotcon_response_set_representation'); + late final _dart_iotcon_response_set_representation + _iotcon_response_set_representation = + _iotcon_response_set_representation_ptr + .asFunction<_dart_iotcon_response_set_representation>(); + + /// @brief Sets header options into the response. + /// @since_tizen 3.0 + /// @param[in] resp The handle of the response + /// @param[in] options The header options of the response + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @see iotcon_response_create() + /// @see iotcon_response_destroy() + int iotcon_response_set_options( + ffi.Pointer resp, + ffi.Pointer options, + ) { + return _iotcon_response_set_options( + resp, + options, + ); + } + + late final _iotcon_response_set_options_ptr = + _lookup>( + 'iotcon_response_set_options'); + late final _dart_iotcon_response_set_options _iotcon_response_set_options = + _iotcon_response_set_options_ptr + .asFunction<_dart_iotcon_response_set_options>(); + + /// @brief Sends response for incoming request. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] resp The handle of the response to send + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + int iotcon_response_send( + ffi.Pointer resp, + ) { + return _iotcon_response_send( + resp, + ); + } + + late final _iotcon_response_send_ptr = + _lookup>( + 'iotcon_response_send'); + late final _dart_iotcon_response_send _iotcon_response_send = + _iotcon_response_send_ptr.asFunction<_dart_iotcon_response_send>(); + + /// @brief Creates a new observers handle. + /// @since_tizen 3.0 + /// @remarks You must destroy @a observers by calling iotcon_observers_destroy() if @a observers is no longer needed. + /// @param[out] observers A newly allocated list of observers handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @see iotcon_observers_destroy() + /// @see iotcon_observers_add() + /// @see iotcon_observers_remove() + int iotcon_observers_create( + ffi.Pointer> observers, + ) { + return _iotcon_observers_create( + observers, + ); + } + + late final _iotcon_observers_create_ptr = + _lookup>( + 'iotcon_observers_create'); + late final _dart_iotcon_observers_create _iotcon_observers_create = + _iotcon_observers_create_ptr.asFunction<_dart_iotcon_observers_create>(); + + /// @brief Destroys a observers handle. + /// @since_tizen 3.0 + /// @param[in] observers The handle of the observers + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_observers_create() + /// @see iotcon_observers_add() + /// @see iotcon_observers_remove() + int iotcon_observers_destroy( + ffi.Pointer observers, + ) { + return _iotcon_observers_destroy( + observers, + ); + } + + late final _iotcon_observers_destroy_ptr = + _lookup>( + 'iotcon_observers_destroy'); + late final _dart_iotcon_observers_destroy _iotcon_observers_destroy = + _iotcon_observers_destroy_ptr + .asFunction<_dart_iotcon_observers_destroy>(); + + /// @brief Adds an observers ID into the observers handle. + /// @since_tizen 3.0 + /// @param[in] observers The handle of the observers + /// @param[in] obs_id The ID to be appended to observers + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_observers_create() + /// @see iotcon_observers_destroy() + /// @see iotcon_observers_remove() + int iotcon_observers_add( + ffi.Pointer observers, + int obs_id, + ) { + return _iotcon_observers_add( + observers, + obs_id, + ); + } + + late final _iotcon_observers_add_ptr = + _lookup>( + 'iotcon_observers_add'); + late final _dart_iotcon_observers_add _iotcon_observers_add = + _iotcon_observers_add_ptr.asFunction<_dart_iotcon_observers_add>(); + + /// @brief Removes ID from the observers. + /// @since_tizen 3.0 + /// @param[in] observers observers The handle of the observers + /// @param[in] obs_id The ID to be removed from observers + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_observers_create() + /// @see iotcon_observers_destroy() + /// @see iotcon_observers_add() + int iotcon_observers_remove( + ffi.Pointer observers, + int obs_id, + ) { + return _iotcon_observers_remove( + observers, + obs_id, + ); + } + + late final _iotcon_observers_remove_ptr = + _lookup>( + 'iotcon_observers_remove'); + late final _dart_iotcon_observers_remove _iotcon_observers_remove = + _iotcon_observers_remove_ptr.asFunction<_dart_iotcon_observers_remove>(); + + /// @brief Gets host address of the request. + /// @since_tizen 3.0 + /// @remarks @a host_address must not be released using free(). + /// @param[in] request The handle of the request + /// @param[out] host_address The host address of the request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_request_get_connectivity_type() + /// @see iotcon_request_get_representation() + /// @see iotcon_request_get_request_type() + /// @see iotcon_request_get_options() + /// @see iotcon_request_get_query() + /// @see iotcon_request_get_observe_type() + /// @see iotcon_request_get_observe_id() + int iotcon_request_get_host_address( + ffi.Pointer request, + ffi.Pointer> host_address, + ) { + return _iotcon_request_get_host_address( + request, + host_address, + ); + } + + late final _iotcon_request_get_host_address_ptr = + _lookup>( + 'iotcon_request_get_host_address'); + late final _dart_iotcon_request_get_host_address + _iotcon_request_get_host_address = _iotcon_request_get_host_address_ptr + .asFunction<_dart_iotcon_request_get_host_address>(); + + /// @brief Gets connectivity type of the request. + /// @since_tizen 3.0 + /// @param[in] request The handle of the request + /// @param[out] connectivity_type The connectivity type of the request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_request_get_host_address() + /// @see iotcon_request_get_representation() + /// @see iotcon_request_get_request_type() + /// @see iotcon_request_get_options() + /// @see iotcon_request_get_query() + /// @see iotcon_request_get_observe_type() + /// @see iotcon_request_get_observe_id() + int iotcon_request_get_connectivity_type( + ffi.Pointer request, + ffi.Pointer connectivity_type, + ) { + return _iotcon_request_get_connectivity_type( + request, + connectivity_type, + ); + } + + late final _iotcon_request_get_connectivity_type_ptr = + _lookup>( + 'iotcon_request_get_connectivity_type'); + late final _dart_iotcon_request_get_connectivity_type + _iotcon_request_get_connectivity_type = + _iotcon_request_get_connectivity_type_ptr + .asFunction<_dart_iotcon_request_get_connectivity_type>(); + + /// @brief Gets a representation of the request. + /// @since_tizen 3.0 + /// @remarks @a repr must not be released using iotcon_representation_destroy(). + /// @param[in] request The handle of the request + /// @param[out] repr The representation of the request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_request_get_host_address() + /// @see iotcon_request_get_connectivity_type() + /// @see iotcon_request_get_request_type() + /// @see iotcon_request_get_options() + /// @see iotcon_request_get_query() + /// @see iotcon_request_get_observe_type() + /// @see iotcon_request_get_observe_id() + int iotcon_request_get_representation( + ffi.Pointer request, + ffi.Pointer> repr, + ) { + return _iotcon_request_get_representation( + request, + repr, + ); + } + + late final _iotcon_request_get_representation_ptr = + _lookup>( + 'iotcon_request_get_representation'); + late final _dart_iotcon_request_get_representation + _iotcon_request_get_representation = + _iotcon_request_get_representation_ptr + .asFunction<_dart_iotcon_request_get_representation>(); + + /// @brief Gets type of the request. + /// @details @a type could be one of the #iotcon_request_type_e. + /// @since_tizen 3.0 + /// @param[in] request The handle of the request + /// @param[out] type The types of the request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_request_get_host_address() + /// @see iotcon_request_get_connectivity_type() + /// @see iotcon_request_get_representation() + /// @see iotcon_request_get_options() + /// @see iotcon_request_get_query() + /// @see iotcon_request_get_observe_type() + /// @see iotcon_request_get_observe_id() + int iotcon_request_get_request_type( + ffi.Pointer request, + ffi.Pointer type, + ) { + return _iotcon_request_get_request_type( + request, + type, + ); + } + + late final _iotcon_request_get_request_type_ptr = + _lookup>( + 'iotcon_request_get_request_type'); + late final _dart_iotcon_request_get_request_type + _iotcon_request_get_request_type = _iotcon_request_get_request_type_ptr + .asFunction<_dart_iotcon_request_get_request_type>(); + + /// @brief Gets options of the request. + /// @since_tizen 3.0 + /// @remarks @a options must not be released using iotcon_options_destroy(). + /// @param[in] request The handle of the request + /// @param[out] options The options of the request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_request_get_host_address() + /// @see iotcon_request_get_connectivity_type() + /// @see iotcon_request_get_representation() + /// @see iotcon_request_get_request_type() + /// @see iotcon_request_get_query() + /// @see iotcon_request_get_observe_type() + /// @see iotcon_request_get_observe_id() + int iotcon_request_get_options( + ffi.Pointer request, + ffi.Pointer> options, + ) { + return _iotcon_request_get_options( + request, + options, + ); + } + + late final _iotcon_request_get_options_ptr = + _lookup>( + 'iotcon_request_get_options'); + late final _dart_iotcon_request_get_options _iotcon_request_get_options = + _iotcon_request_get_options_ptr + .asFunction<_dart_iotcon_request_get_options>(); + + /// @brief Gets query of the request. + /// @since_tizen 3.0 + /// @remarks @a query must not be released using iotcon_query_destroy(). + /// @param[in] request The handle of the request + /// @param[out] query The query of the request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_request_get_host_address() + /// @see iotcon_request_get_connectivity_type() + /// @see iotcon_request_get_representation() + /// @see iotcon_request_get_request_type() + /// @see iotcon_request_get_options() + /// @see iotcon_request_get_observe_type() + /// @see iotcon_request_get_observe_id() + int iotcon_request_get_query( + ffi.Pointer request, + ffi.Pointer> query, + ) { + return _iotcon_request_get_query( + request, + query, + ); + } + + late final _iotcon_request_get_query_ptr = + _lookup>( + 'iotcon_request_get_query'); + late final _dart_iotcon_request_get_query _iotcon_request_get_query = + _iotcon_request_get_query_ptr + .asFunction<_dart_iotcon_request_get_query>(); + + /// @brief Gets observation action of the request. + /// @details The @a observe_type could be one of #iotcon_observe_type_e. + /// @since_tizen 3.0 + /// @param[in] request The handle of the request + /// @param[out] observe_type The observation type of the request + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_request_get_host_address() + /// @see iotcon_request_get_connectivity_type() + /// @see iotcon_request_get_representation() + /// @see iotcon_request_get_request_type() + /// @see iotcon_request_get_options() + /// @see iotcon_request_get_query() + /// @see iotcon_request_get_observe_id() + int iotcon_request_get_observe_type( + ffi.Pointer request, + ffi.Pointer observe_type, + ) { + return _iotcon_request_get_observe_type( + request, + observe_type, + ); + } + + late final _iotcon_request_get_observe_type_ptr = + _lookup>( + 'iotcon_request_get_observe_type'); + late final _dart_iotcon_request_get_observe_type + _iotcon_request_get_observe_type = _iotcon_request_get_observe_type_ptr + .asFunction<_dart_iotcon_request_get_observe_type>(); + + /// @brief Gets observation ID of the request. + /// @since_tizen 3.0 + /// @param[in] request The handle of the request + /// @param[out] observe_id The ID of the observer + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_request_get_host_address() + /// @see iotcon_request_get_connectivity_type() + /// @see iotcon_request_get_representation() + /// @see iotcon_request_get_request_type() + /// @see iotcon_request_get_options() + /// @see iotcon_request_get_query() + /// @see iotcon_request_get_observe_type() + int iotcon_request_get_observe_id( + ffi.Pointer request, + ffi.Pointer observe_id, + ) { + return _iotcon_request_get_observe_id( + request, + observe_id, + ); + } + + late final _iotcon_request_get_observe_id_ptr = + _lookup>( + 'iotcon_request_get_observe_id'); + late final _dart_iotcon_request_get_observe_id + _iotcon_request_get_observe_id = _iotcon_request_get_observe_id_ptr + .asFunction<_dart_iotcon_request_get_observe_id>(); + + /// @brief Starts presence of a server. + /// @details Use this function to send server's announcements to clients. \n + /// Server can call this function when online for the first time or come back from offline to online. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks If @a time_to_live is 0, server will set default value as 60 seconds. \n + /// If @a time_to_live is very big, server will set maximum value as (60 * 60 * 24) seconds (24 hours). + /// @param[in] time_to_live The interval of announcing presence in seconds + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_stop_presence() + /// @see iotcon_add_presence_cb() + /// @see iotcon_remove_presence_cb() + int iotcon_start_presence( + int time_to_live, + ) { + return _iotcon_start_presence( + time_to_live, + ); + } + + late final _iotcon_start_presence_ptr = + _lookup>( + 'iotcon_start_presence'); + late final _dart_iotcon_start_presence _iotcon_start_presence = + _iotcon_start_presence_ptr.asFunction<_dart_iotcon_start_presence>(); + + /// @brief Stops presence of a server. + /// @details Use this function to stop sending server's announcements to clients. + /// Server can call this function when terminating, entering to offline or out of network. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_start_presence() + /// @see iotcon_add_presence_cb() + /// @see iotcon_remove_presence_cb() + int iotcon_stop_presence() { + return _iotcon_stop_presence(); + } + + late final _iotcon_stop_presence_ptr = + _lookup>( + 'iotcon_stop_presence'); + late final _dart_iotcon_stop_presence _iotcon_stop_presence = + _iotcon_stop_presence_ptr.asFunction<_dart_iotcon_stop_presence>(); + + /// @brief Sets the device name. + /// @details The function sets the name of the local device (the device calling the function). + /// If the device name is set, clients can get the name using iotcon_device_info_get_property() or iotcon_remote_resource_get_device_name(). + /// @since_tizen 3.0 + /// @remarks @a device_name may not be an empty string. + /// @param[in] device_name The device name + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_IOTIVITY Iotivity errors + /// @see iotcon_get_device_info() + /// @see iotcon_device_info_get_property() + /// @see iotcon_remote_resource_get_device_name() + int iotcon_set_device_name( + ffi.Pointer device_name, + ) { + return _iotcon_set_device_name( + device_name, + ); + } + + late final _iotcon_set_device_name_ptr = + _lookup>( + 'iotcon_set_device_name'); + late final _dart_iotcon_set_device_name _iotcon_set_device_name = + _iotcon_set_device_name_ptr.asFunction<_dart_iotcon_set_device_name>(); + + /// @brief Creates a new resource handle. + /// @details Creates a resource proxy object so that iotcon_remote_resource_get(), + /// iotcon_remote_resource_put(), iotcon_remote_resource_post(), + /// iotcon_remote_resource_delete(), iotcon_remote_resource_observe_register(), + /// iotcon_remote_resource_start_caching() and iotcon_remote_resource_start_monitoring() + /// API can be used without discovering the object in advance.\n + /// To use this API, you should provide all of the details required to correctly contact and observe the object.\n + /// If not, you should discover the resource object manually.\n + /// The @a policies can contain multiple policies like IOTCON_RESOURCE_DISCOVERABLE | IOTCON_RESOURCE_OBSERVABLE. + /// @since_tizen 3.0 + /// @remarks You must destroy @a remote_resource by calling iotcon_remote_resource_destroy() if @a remote_resource is no longer needed. + /// @param[in] host_address The host address of the resource + /// @param[in] connectivity_type The connectivity type. Can not use @a IOTCON_CONNECTIVITY_ALL. \n + /// Connectivity type of specific remote resource(It has specific host address, not @a IOTCON_MULTICAST_ADDRESS) is already decided. \n + /// Use specific connectivity type of the remote resource. \n + /// You can refer to the @a iotcon_remote_resource_get_connectivity_type(). + /// @param[in] uri_path The URI path of the resource + /// @param[in] policies The policies of the resource \n + /// Set of #iotcon_resource_policy_e + /// @param[in] resource_types The resource types of the resource. For example, "core.light" + /// @param[in] resource_ifaces The resource interfaces of the resource + /// @param[out] remote_resource Generated resource handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_IOTIVITY IoTivity errors + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @see iotcon_remote_resource_destroy() + /// @see iotcon_remote_resource_clone() + int iotcon_remote_resource_create( + ffi.Pointer host_address, + int connectivity_type, + ffi.Pointer uri_path, + int policies, + ffi.Pointer resource_types, + ffi.Pointer resource_ifaces, + ffi.Pointer> remote_resource, + ) { + return _iotcon_remote_resource_create( + host_address, + connectivity_type, + uri_path, + policies, + resource_types, + resource_ifaces, + remote_resource, + ); + } + + late final _iotcon_remote_resource_create_ptr = + _lookup>( + 'iotcon_remote_resource_create'); + late final _dart_iotcon_remote_resource_create + _iotcon_remote_resource_create = _iotcon_remote_resource_create_ptr + .asFunction<_dart_iotcon_remote_resource_create>(); + + /// @brief Destroys a resource handle. + /// @since_tizen 3.0 + /// @param[in] resource The handle of the resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_remote_resource_create() + /// @see iotcon_remote_resource_clone() + int iotcon_remote_resource_destroy( + ffi.Pointer resource, + ) { + return _iotcon_remote_resource_destroy( + resource, + ); + } + + late final _iotcon_remote_resource_destroy_ptr = + _lookup>( + 'iotcon_remote_resource_destroy'); + late final _dart_iotcon_remote_resource_destroy + _iotcon_remote_resource_destroy = _iotcon_remote_resource_destroy_ptr + .asFunction<_dart_iotcon_remote_resource_destroy>(); + + /// @brief Clones a clone of a remote resource. + /// @since_tizen 3.0 + /// @remarks You must destroy @a dest by calling iotcon_remote_resource_destroy() if @a dest is no longer needed. + /// @param[in] src The Source of resource + /// @param[out] dest The cloned resource handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_remote_resource_create() + /// @see iotcon_remote_resource_destroy() + int iotcon_remote_resource_clone( + ffi.Pointer src, + ffi.Pointer> dest, + ) { + return _iotcon_remote_resource_clone( + src, + dest, + ); + } + + late final _iotcon_remote_resource_clone_ptr = + _lookup>( + 'iotcon_remote_resource_clone'); + late final _dart_iotcon_remote_resource_clone _iotcon_remote_resource_clone = + _iotcon_remote_resource_clone_ptr + .asFunction<_dart_iotcon_remote_resource_clone>(); + + /// @brief Registers observe callback on the resource. + /// @details When server sends notification message, iotcon_remote_resource_observe_cb() will be called. + /// The @a observe_policy could be one of #iotcon_observe_policy_e. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] resource The handle of the resource + /// @param[in] observe_policy The type to specify how client wants to observe + /// @param[in] query The query to send to server + /// @param[in] cb The callback function to get notifications from server + /// @param[in] user_data The user data to pass to the function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_IOTIVITY IoTivity errors + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @post When the @a resource receive notification message, iotcon_remote_resource_observe_cb() will be called. + /// @see iotcon_remote_resource_observe_cb() + /// @see iotcon_remote_resource_observe_deregister() + /// @see iotcon_resource_notify() + int iotcon_remote_resource_observe_register( + ffi.Pointer resource, + int observe_policy, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_remote_resource_observe_register( + resource, + observe_policy, + query, + cb, + user_data, + ); + } + + late final _iotcon_remote_resource_observe_register_ptr = + _lookup>( + 'iotcon_remote_resource_observe_register'); + late final _dart_iotcon_remote_resource_observe_register + _iotcon_remote_resource_observe_register = + _iotcon_remote_resource_observe_register_ptr + .asFunction<_dart_iotcon_remote_resource_observe_register>(); + + /// @brief Deregisters observe callback on the resource. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] resource The handle of the resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_remote_resource_observe_cb() + /// @see iotcon_remote_resource_observe_register() + /// @see iotcon_resource_notify() + int iotcon_remote_resource_observe_deregister( + ffi.Pointer resource, + ) { + return _iotcon_remote_resource_observe_deregister( + resource, + ); + } + + late final _iotcon_remote_resource_observe_deregister_ptr = + _lookup>( + 'iotcon_remote_resource_observe_deregister'); + late final _dart_iotcon_remote_resource_observe_deregister + _iotcon_remote_resource_observe_deregister = + _iotcon_remote_resource_observe_deregister_ptr + .asFunction<_dart_iotcon_remote_resource_observe_deregister>(); + + /// @brief Gets the attributes of a resource asynchronously. + /// @details When server sends response on get request, iotcon_remote_resource_response_cb() will be called. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] resource The handle of the resource + /// @param[in] query The query to send to server + /// @param[in] cb The callback function + /// @param[in] user_data The user data to pass to the function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @post When the client receive get response, iotcon_remote_resource_response_cb() will be called. + /// @see iotcon_remote_resource_response_cb() + /// @see iotcon_set_timeout() + int iotcon_remote_resource_get( + ffi.Pointer resource, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_remote_resource_get( + resource, + query, + cb, + user_data, + ); + } + + late final _iotcon_remote_resource_get_ptr = + _lookup>( + 'iotcon_remote_resource_get'); + late final _dart_iotcon_remote_resource_get _iotcon_remote_resource_get = + _iotcon_remote_resource_get_ptr + .asFunction<_dart_iotcon_remote_resource_get>(); + + /// @brief Puts the representation of a resource asynchronously. + /// @details When server sends response on put request, iotcon_remote_resource_response_cb() will be called. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] resource The handle of the resource + /// @param[in] repr The handle of the representation + /// @param[in] query The query to send to server + /// @param[in] cb The callback function + /// @param[in] user_data The user data to pass to the function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @post When the client receive put response, iotcon_remote_resource_response_cb() will be called. + /// @see iotcon_remote_resource_response_cb() + /// @see iotcon_set_timeout() + int iotcon_remote_resource_put( + ffi.Pointer resource, + ffi.Pointer repr, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_remote_resource_put( + resource, + repr, + query, + cb, + user_data, + ); + } + + late final _iotcon_remote_resource_put_ptr = + _lookup>( + 'iotcon_remote_resource_put'); + late final _dart_iotcon_remote_resource_put _iotcon_remote_resource_put = + _iotcon_remote_resource_put_ptr + .asFunction<_dart_iotcon_remote_resource_put>(); + + /// @brief Posts on a resource asynchronously. + /// @details When server sends response on post request, iotcon_remote_resource_response_cb() will be called. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] resource The handle of the resource + /// @param[in] repr The handle of the representation + /// @param[in] query The query to send to server + /// @param[in] cb The callback function + /// @param[in] user_data The user data to pass to the function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @post When the client receive post response, iotcon_remote_resource_response_cb() will be called. + /// @see iotcon_remote_resource_response_cb() + /// @see iotcon_set_timeout() + int iotcon_remote_resource_post( + ffi.Pointer resource, + ffi.Pointer repr, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_remote_resource_post( + resource, + repr, + query, + cb, + user_data, + ); + } + + late final _iotcon_remote_resource_post_ptr = + _lookup>( + 'iotcon_remote_resource_post'); + late final _dart_iotcon_remote_resource_post _iotcon_remote_resource_post = + _iotcon_remote_resource_post_ptr + .asFunction<_dart_iotcon_remote_resource_post>(); + + /// @brief Deletes a resource asynchronously. + /// @details When server sends response on delete request, iotcon_remote_resource_response_cb() will be called. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] resource The handle of the resource + /// @param[in] cb The callback function + /// @param[in] user_data The user data to pass to the function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @post When the client receive delete response, iotcon_remote_resource_response_cb() will be called. + /// @see iotcon_remote_resource_response_cb() + /// @see iotcon_set_timeout() + int iotcon_remote_resource_delete( + ffi.Pointer resource, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_remote_resource_delete( + resource, + cb, + user_data, + ); + } + + late final _iotcon_remote_resource_delete_ptr = + _lookup>( + 'iotcon_remote_resource_delete'); + late final _dart_iotcon_remote_resource_delete + _iotcon_remote_resource_delete = _iotcon_remote_resource_delete_ptr + .asFunction<_dart_iotcon_remote_resource_delete>(); + + /// @brief Starts caching of a remote resource. + /// @details Use this function to start caching the resource's attribute. \n + /// Although, remote resource is not observable, it keeps the representation up-to-date. + /// Because it checks whether representation is changed periodically. \n + /// Therefore, you can get the cached representation even when the remote resource is off-line. + /// The default checking interval is 10 seconds. + /// It can be changed by iotcon_remote_resource_set_checking_interval(). + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] resource The handle of the remote resource to be cached + /// @param[in] cb The callback function to add into callback list + /// @param[in] user_data The user data to pass to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_ALREADY Already done + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_remote_resource_stop_caching() + /// @see iotcon_remote_resource_cached_representation_changed_cb() + int iotcon_remote_resource_start_caching( + ffi.Pointer resource, + ffi.Pointer< + ffi.NativeFunction< + iotcon_remote_resource_cached_representation_changed_cb>> + cb, + ffi.Pointer user_data, + ) { + return _iotcon_remote_resource_start_caching( + resource, + cb, + user_data, + ); + } + + late final _iotcon_remote_resource_start_caching_ptr = + _lookup>( + 'iotcon_remote_resource_start_caching'); + late final _dart_iotcon_remote_resource_start_caching + _iotcon_remote_resource_start_caching = + _iotcon_remote_resource_start_caching_ptr + .asFunction<_dart_iotcon_remote_resource_start_caching>(); + + /// @brief Stops caching of a remote resource. + /// @details Use this function to stop caching the resource's attribute. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] resource The handle of the remote resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_remote_resource_start_caching() + /// @see iotcon_remote_resource_cached_representation_changed_cb() + int iotcon_remote_resource_stop_caching( + ffi.Pointer resource, + ) { + return _iotcon_remote_resource_stop_caching( + resource, + ); + } + + late final _iotcon_remote_resource_stop_caching_ptr = + _lookup>( + 'iotcon_remote_resource_stop_caching'); + late final _dart_iotcon_remote_resource_stop_caching + _iotcon_remote_resource_stop_caching = + _iotcon_remote_resource_stop_caching_ptr + .asFunction<_dart_iotcon_remote_resource_stop_caching>(); + + /// @brief Starts monitoring of a remote resource. + /// @details When remote resource's state is changed, registered callbacks will be called in turn. + /// Although, remote resource does not call iotcon_start_presence(), it knows the state of resource. + /// Because it checks the state of resource, periodically. \n + /// The default checking interval is 10 seconds. + /// It can be changed by iotcon_remote_resource_set_checking_interval(). + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] resource The handle of the remote resource + /// @param[in] cb The callback function to add into callback list + /// @param[in] user_data The user data to pass to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_ALREADY Already done + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_remote_resource_stop_monitoring() + /// @see iotcon_remote_resource_state_changed_cb() + int iotcon_remote_resource_start_monitoring( + ffi.Pointer resource, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_remote_resource_start_monitoring( + resource, + cb, + user_data, + ); + } + + late final _iotcon_remote_resource_start_monitoring_ptr = + _lookup>( + 'iotcon_remote_resource_start_monitoring'); + late final _dart_iotcon_remote_resource_start_monitoring + _iotcon_remote_resource_start_monitoring = + _iotcon_remote_resource_start_monitoring_ptr + .asFunction<_dart_iotcon_remote_resource_start_monitoring>(); + + /// @brief Stops monitoring of a remote resource. + /// @details Use this function to stop monitoring the remote resource. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] resource The handle of the remote resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_remote_resource_start_monitoring() + /// @see iotcon_remote_resource_state_changed_cb() + int iotcon_remote_resource_stop_monitoring( + ffi.Pointer resource, + ) { + return _iotcon_remote_resource_stop_monitoring( + resource, + ); + } + + late final _iotcon_remote_resource_stop_monitoring_ptr = + _lookup>( + 'iotcon_remote_resource_stop_monitoring'); + late final _dart_iotcon_remote_resource_stop_monitoring + _iotcon_remote_resource_stop_monitoring = + _iotcon_remote_resource_stop_monitoring_ptr + .asFunction<_dart_iotcon_remote_resource_stop_monitoring>(); + + /// @brief Gets an URI path of the remote resource. + /// @since_tizen 3.0 + /// @remarks @a uri_path must not be released using free(). + /// @param[in] resource The handle of the remote resource + /// @param[out] uri_path The URI path of the remote resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_remote_resource_get_host_address() + /// @see iotcon_remote_resource_get_connectivity_type() + /// @see iotcon_remote_resource_get_device_id() + /// @see iotcon_remote_resource_get_device_name() + /// @see iotcon_remote_resource_get_types() + /// @see iotcon_remote_resource_get_interfaces() + /// @see iotcon_remote_resource_get_policies() + /// @see iotcon_remote_resource_set_options() + int iotcon_remote_resource_get_uri_path( + ffi.Pointer resource, + ffi.Pointer> uri_path, + ) { + return _iotcon_remote_resource_get_uri_path( + resource, + uri_path, + ); + } + + late final _iotcon_remote_resource_get_uri_path_ptr = + _lookup>( + 'iotcon_remote_resource_get_uri_path'); + late final _dart_iotcon_remote_resource_get_uri_path + _iotcon_remote_resource_get_uri_path = + _iotcon_remote_resource_get_uri_path_ptr + .asFunction<_dart_iotcon_remote_resource_get_uri_path>(); + + /// @brief Gets a connectivity type of the remote resource. + /// @since_tizen 3.0 + /// @param[in] resource The handle of the remote resource + /// @param[out] connectivity_type The connectivity type of the remote resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_remote_resource_get_uri_path() + /// @see iotcon_remote_resource_get_host_address() + /// @see iotcon_remote_resource_get_connectivity_type() + /// @see iotcon_remote_resource_get_device_id() + /// @see iotcon_remote_resource_get_device_name() + /// @see iotcon_remote_resource_get_types() + /// @see iotcon_remote_resource_get_interfaces() + /// @see iotcon_remote_resource_get_policies() + /// @see iotcon_remote_resource_set_options() + int iotcon_remote_resource_get_connectivity_type( + ffi.Pointer resource, + ffi.Pointer connectivity_type, + ) { + return _iotcon_remote_resource_get_connectivity_type( + resource, + connectivity_type, + ); + } + + late final _iotcon_remote_resource_get_connectivity_type_ptr = _lookup< + ffi.NativeFunction<_c_iotcon_remote_resource_get_connectivity_type>>( + 'iotcon_remote_resource_get_connectivity_type'); + late final _dart_iotcon_remote_resource_get_connectivity_type + _iotcon_remote_resource_get_connectivity_type = + _iotcon_remote_resource_get_connectivity_type_ptr + .asFunction<_dart_iotcon_remote_resource_get_connectivity_type>(); + + /// @brief Gets a host address of the remote resource. + /// @since_tizen 3.0 + /// @remarks @a host_address must not be released using free(). + /// @param[in] resource The handle of the remote resource + /// @param[out] host_address The host address of the remote resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_remote_resource_get_connectivity_type() + /// @see iotcon_remote_resource_get_uri_path() + /// @see iotcon_remote_resource_get_device_id() + /// @see iotcon_remote_resource_get_device_name() + /// @see iotcon_remote_resource_get_types() + /// @see iotcon_remote_resource_get_interfaces() + /// @see iotcon_remote_resource_get_policies() + /// @see iotcon_remote_resource_set_options() + int iotcon_remote_resource_get_host_address( + ffi.Pointer resource, + ffi.Pointer> host_address, + ) { + return _iotcon_remote_resource_get_host_address( + resource, + host_address, + ); + } + + late final _iotcon_remote_resource_get_host_address_ptr = + _lookup>( + 'iotcon_remote_resource_get_host_address'); + late final _dart_iotcon_remote_resource_get_host_address + _iotcon_remote_resource_get_host_address = + _iotcon_remote_resource_get_host_address_ptr + .asFunction<_dart_iotcon_remote_resource_get_host_address>(); + + /// @brief Gets a device ID of the remote resource. + /// @since_tizen 3.0 + /// @remarks @a device_id must not be released using free().\n + /// If @a resource is created by calling iotcon_remote_resource_create(), you cannot get @a device_id. + /// In this case, the return value of this function is #IOTCON_ERROR_NO_DATA. + /// @param[in] resource The handle of the remote resource + /// @param[out] device_id The device ID of the remote resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @see iotcon_remote_resource_get_uri_path() + /// @see iotcon_remote_resource_get_device_name() + /// @see iotcon_remote_resource_get_host_address() + /// @see iotcon_remote_resource_get_connectivity_type() + /// @see iotcon_remote_resource_get_types() + /// @see iotcon_remote_resource_get_interfaces() + /// @see iotcon_remote_resource_get_policies() + /// @see iotcon_remote_resource_set_options() + int iotcon_remote_resource_get_device_id( + ffi.Pointer resource, + ffi.Pointer> device_id, + ) { + return _iotcon_remote_resource_get_device_id( + resource, + device_id, + ); + } + + late final _iotcon_remote_resource_get_device_id_ptr = + _lookup>( + 'iotcon_remote_resource_get_device_id'); + late final _dart_iotcon_remote_resource_get_device_id + _iotcon_remote_resource_get_device_id = + _iotcon_remote_resource_get_device_id_ptr + .asFunction<_dart_iotcon_remote_resource_get_device_id>(); + + /// @brief Gets the device name of the remote resource. + /// @since_tizen 3.0 + /// @remarks @a device_name must not be released using free().\n + /// If @a resource is created by calling iotcon_remote_resource_create(), you cannot get @a device_name. + /// In this case, the return value of this function is #IOTCON_ERROR_NO_DATA. + /// @param[in] resource The handle of the remote resource + /// @param[out] device_name The device name of the remote resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @see iotcon_set_device_name() + /// @see iotcon_remote_resource_get_uri_path() + /// @see iotcon_remote_resource_get_device_id() + /// @see iotcon_remote_resource_get_device_name() + /// @see iotcon_remote_resource_get_host_address() + /// @see iotcon_remote_resource_get_connectivity_type() + /// @see iotcon_remote_resource_get_types() + /// @see iotcon_remote_resource_get_interfaces() + /// @see iotcon_remote_resource_get_properties() + /// @see iotcon_remote_resource_set_options() + int iotcon_remote_resource_get_device_name( + ffi.Pointer resource, + ffi.Pointer> device_name, + ) { + return _iotcon_remote_resource_get_device_name( + resource, + device_name, + ); + } + + late final _iotcon_remote_resource_get_device_name_ptr = + _lookup>( + 'iotcon_remote_resource_get_device_name'); + late final _dart_iotcon_remote_resource_get_device_name + _iotcon_remote_resource_get_device_name = + _iotcon_remote_resource_get_device_name_ptr + .asFunction<_dart_iotcon_remote_resource_get_device_name>(); + + /// @brief Gets resource types of the remote resource. + /// @since_tizen 3.0 + /// @remarks @a types must not be released using iotcon_resource_types_destroy(). + /// @param[in] resource The handle of the remote resource + /// @param[out] types The resource types of the remote resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_remote_resource_get_uri_path() + /// @see iotcon_remote_resource_get_host_address() + /// @see iotcon_remote_resource_get_connectivity_type() + /// @see iotcon_remote_resource_get_device_id() + /// @see iotcon_remote_resource_get_device_name() + /// @see iotcon_remote_resource_get_interfaces() + /// @see iotcon_remote_resource_get_policies() + /// @see iotcon_remote_resource_set_options() + int iotcon_remote_resource_get_types( + ffi.Pointer resource, + ffi.Pointer> types, + ) { + return _iotcon_remote_resource_get_types( + resource, + types, + ); + } + + late final _iotcon_remote_resource_get_types_ptr = + _lookup>( + 'iotcon_remote_resource_get_types'); + late final _dart_iotcon_remote_resource_get_types + _iotcon_remote_resource_get_types = _iotcon_remote_resource_get_types_ptr + .asFunction<_dart_iotcon_remote_resource_get_types>(); + + /// @brief Gets resource interfaces of the remote resource. + /// @since_tizen 3.0 + /// @remarks @a ifaces must not be released using iotcon_resource_interfaces_destroy(). + /// @param[in] resource The handle of the remote resource + /// @param[out] ifaces The resource interfaces of the remote resource + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_remote_resource_get_uri_path() + /// @see iotcon_remote_resource_get_host_address() + /// @see iotcon_remote_resource_get_connectivity_type() + /// @see iotcon_remote_resource_get_device_id() + /// @see iotcon_remote_resource_get_device_name() + /// @see iotcon_remote_resource_get_types() + /// @see iotcon_remote_resource_get_policies() + /// @see iotcon_remote_resource_set_options() + int iotcon_remote_resource_get_interfaces( + ffi.Pointer resource, + ffi.Pointer> ifaces, + ) { + return _iotcon_remote_resource_get_interfaces( + resource, + ifaces, + ); + } + + late final _iotcon_remote_resource_get_interfaces_ptr = + _lookup>( + 'iotcon_remote_resource_get_interfaces'); + late final _dart_iotcon_remote_resource_get_interfaces + _iotcon_remote_resource_get_interfaces = + _iotcon_remote_resource_get_interfaces_ptr + .asFunction<_dart_iotcon_remote_resource_get_interfaces>(); + + /// @brief Checks whether the remote resource is observable or not. + /// @details The @a policies can contain multiple policies like IOTCON_RESOURCE_DISCOVERABLE | IOTCON_RESOURCE_OBSERVABLE. + /// @since_tizen 3.0 + /// @param[in] resource The handle of the resource + /// @param[out] policies The policies of the resource \n + /// Set of #iotcon_resource_policy_e + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_remote_resource_get_uri_path() + /// @see iotcon_remote_resource_get_host_address() + /// @see iotcon_remote_resource_get_connectivity_type() + /// @see iotcon_remote_resource_get_device_id() + /// @see iotcon_remote_resource_get_device_name() + /// @see iotcon_remote_resource_get_types() + /// @see iotcon_remote_resource_get_interfaces() + /// @see iotcon_remote_resource_set_options() + int iotcon_remote_resource_get_policies( + ffi.Pointer resource, + ffi.Pointer policies, + ) { + return _iotcon_remote_resource_get_policies( + resource, + policies, + ); + } + + late final _iotcon_remote_resource_get_policies_ptr = + _lookup>( + 'iotcon_remote_resource_get_policies'); + late final _dart_iotcon_remote_resource_get_policies + _iotcon_remote_resource_get_policies = + _iotcon_remote_resource_get_policies_ptr + .asFunction<_dart_iotcon_remote_resource_get_policies>(); + + /// @brief Gets options of the remote resource. + /// @since_tizen 3.0 + /// @remarks @a options must not be released using iotcon_options_destroy(). + /// @param[in] resource The handle of the remote resource + /// @param[out] options The handle of the header options + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_remote_resource_get_uri_path() + /// @see iotcon_remote_resource_get_host_address() + /// @see iotcon_remote_resource_get_connectivity_type() + /// @see iotcon_remote_resource_get_device_id() + /// @see iotcon_remote_resource_get_device_name() + /// @see iotcon_remote_resource_get_types() + /// @see iotcon_remote_resource_get_interfaces() + /// @see iotcon_remote_resource_set_options() + /// @see iotcon_remote_resource_get_policies() + int iotcon_remote_resource_get_options( + ffi.Pointer resource, + ffi.Pointer> options, + ) { + return _iotcon_remote_resource_get_options( + resource, + options, + ); + } + + late final _iotcon_remote_resource_get_options_ptr = + _lookup>( + 'iotcon_remote_resource_get_options'); + late final _dart_iotcon_remote_resource_get_options + _iotcon_remote_resource_get_options = + _iotcon_remote_resource_get_options_ptr + .asFunction<_dart_iotcon_remote_resource_get_options>(); + + /// @brief Sets options into the remote resource. + /// @since_tizen 3.0 + /// @param[in] resource The handle of the remote resource + /// @param[in] options The handle of the header options + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_remote_resource_get_uri_path() + /// @see iotcon_remote_resource_get_host_address() + /// @see iotcon_remote_resource_get_connectivity_type() + /// @see iotcon_remote_resource_get_device_id() + /// @see iotcon_remote_resource_get_device_name() + /// @see iotcon_remote_resource_get_types() + /// @see iotcon_remote_resource_get_interfaces() + /// @see iotcon_remote_resource_get_options() + /// @see iotcon_remote_resource_get_policies() + int iotcon_remote_resource_set_options( + ffi.Pointer resource, + ffi.Pointer options, + ) { + return _iotcon_remote_resource_set_options( + resource, + options, + ); + } + + late final _iotcon_remote_resource_set_options_ptr = + _lookup>( + 'iotcon_remote_resource_set_options'); + late final _dart_iotcon_remote_resource_set_options + _iotcon_remote_resource_set_options = + _iotcon_remote_resource_set_options_ptr + .asFunction<_dart_iotcon_remote_resource_set_options>(); + + /// @brief Gets cached representation from the remote resource. + /// @since_tizen 3.0 + /// @remarks @a representation must not be released using iotcon_representation_destroy(). + /// @param[in] resource The handle of the remote resource + /// @param[out] representation The handle of the representation + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + int iotcon_remote_resource_get_cached_representation( + ffi.Pointer resource, + ffi.Pointer> representation, + ) { + return _iotcon_remote_resource_get_cached_representation( + resource, + representation, + ); + } + + late final _iotcon_remote_resource_get_cached_representation_ptr = _lookup< + ffi.NativeFunction< + _c_iotcon_remote_resource_get_cached_representation>>( + 'iotcon_remote_resource_get_cached_representation'); + late final _dart_iotcon_remote_resource_get_cached_representation + _iotcon_remote_resource_get_cached_representation = + _iotcon_remote_resource_get_cached_representation_ptr + .asFunction<_dart_iotcon_remote_resource_get_cached_representation>(); + + /// @brief Gets the checking interval which is using on the monitoring & caching of remote resource. + /// @details This API get the checking interval which is using in the process of monitoring and caching() of remote resource. \n + /// The monitoring and caching will operate "GET method" with the checking interval. + /// Default checking interval is 10 seconds. + /// @since_tizen 3.0 + /// @param[in] resource The handle of the remote resource + /// @param[out] interval Seconds for time interval + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_remote_resource_set_checking_interval() + /// @see iotcon_remote_resource_start_monitoring() + /// @see iotcon_remote_resource_start_caching() + int iotcon_remote_resource_get_checking_interval( + ffi.Pointer resource, + ffi.Pointer interval, + ) { + return _iotcon_remote_resource_get_checking_interval( + resource, + interval, + ); + } + + late final _iotcon_remote_resource_get_checking_interval_ptr = _lookup< + ffi.NativeFunction<_c_iotcon_remote_resource_get_checking_interval>>( + 'iotcon_remote_resource_get_checking_interval'); + late final _dart_iotcon_remote_resource_get_checking_interval + _iotcon_remote_resource_get_checking_interval = + _iotcon_remote_resource_get_checking_interval_ptr + .asFunction<_dart_iotcon_remote_resource_get_checking_interval>(); + + /// @brief Sets the checking interval which is using on the monitoring & caching of remote resource. + /// @details This API set the checking interval which is using in the process of monitoring and caching() of remote resource. \n + /// The monitoring and caching will operate "GET method" with the checking interval changed by this function. + /// Default checking interval is 10 seconds. + /// @since_tizen 3.0 + /// @param[in] resource The handle of the remote resource + /// @param[in] interval Seconds for time interval (must be in range from 1 to 3600) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_remote_resource_get_checking_interval() + /// @see iotcon_remote_resource_start_monitoring() + /// @see iotcon_remote_resource_start_caching() + int iotcon_remote_resource_set_checking_interval( + ffi.Pointer resource, + int interval, + ) { + return _iotcon_remote_resource_set_checking_interval( + resource, + interval, + ); + } + + late final _iotcon_remote_resource_set_checking_interval_ptr = _lookup< + ffi.NativeFunction<_c_iotcon_remote_resource_set_checking_interval>>( + 'iotcon_remote_resource_set_checking_interval'); + late final _dart_iotcon_remote_resource_set_checking_interval + _iotcon_remote_resource_set_checking_interval = + _iotcon_remote_resource_set_checking_interval_ptr + .asFunction<_dart_iotcon_remote_resource_set_checking_interval>(); + + /// @brief Adds callback to a server to receive presence events. + /// @details Request to receive presence to an interested server's resource with @a resource_type. \n + /// If succeeded to subscribe, iotcon_presence_cb() will be invoked when the server sends presence. \n + /// A server sends presence events when adds/removes/alters a resource or start/stop presence. \n + /// @a host_address could be #IOTCON_MULTICAST_ADDRESS for IPv4 multicast. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks The length of @a resource_type should be less than or equal to 61.\n + /// The @a resource_type must start with a lowercase alphabetic character, followed by a sequence + /// of lowercase alphabetic, numeric, ".", or "-" characters, and contains no white space.\n + /// You must destroy @a presence by calling iotcon_unsubscribe_presence() + /// if @a presence is no longer needed. + /// @param[in] host_address The address or addressable name of the server + /// @param[in] connectivity_type The connectivity type + /// @param[in] resource_type A resource type that a client is interested in + /// @param[in] cb The callback function to invoke + /// @param[in] user_data The user data to pass to the function + /// @param[out] presence_handle The generated presence handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_IOTIVITY IoTivity errors + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @post When the resource receive presence, iotcon_presence_cb() will be called. + /// @see iotcon_start_presence() + /// @see iotcon_stop_presence() + /// @see iotcon_remove_presence_cb() + /// @see iotcon_presence_cb() + int iotcon_add_presence_cb( + ffi.Pointer host_address, + int connectivity_type, + ffi.Pointer resource_type, + ffi.Pointer> cb, + ffi.Pointer user_data, + ffi.Pointer> presence_handle, + ) { + return _iotcon_add_presence_cb( + host_address, + connectivity_type, + resource_type, + cb, + user_data, + presence_handle, + ); + } + + late final _iotcon_add_presence_cb_ptr = + _lookup>( + 'iotcon_add_presence_cb'); + late final _dart_iotcon_add_presence_cb _iotcon_add_presence_cb = + _iotcon_add_presence_cb_ptr.asFunction<_dart_iotcon_add_presence_cb>(); + + /// @brief Removes callback to a server's presence events. + /// @details Request not to receive server's presence any more. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] presence_handle The presence handle to be unsubscribed + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_start_presence() + /// @see iotcon_stop_presence() + /// @see iotcon_add_presence_cb() + /// @see iotcon_presence_cb() + int iotcon_remove_presence_cb( + ffi.Pointer presence_handle, + ) { + return _iotcon_remove_presence_cb( + presence_handle, + ); + } + + late final _iotcon_remove_presence_cb_ptr = + _lookup>( + 'iotcon_remove_presence_cb'); + late final _dart_iotcon_remove_presence_cb _iotcon_remove_presence_cb = + _iotcon_remove_presence_cb_ptr + .asFunction<_dart_iotcon_remove_presence_cb>(); + + /// @brief Gets host address from the presence handle. + /// @since_tizen 3.0 + /// @remarks @a host_address must not be released using free(). + /// @param[in] presence The handle of the presence + /// @param[out] host_address The host address of the presence + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_presence_get_connectivity_type() + /// @see iotcon_presence_get_resource_type() + int iotcon_presence_get_host_address( + ffi.Pointer presence, + ffi.Pointer> host_address, + ) { + return _iotcon_presence_get_host_address( + presence, + host_address, + ); + } + + late final _iotcon_presence_get_host_address_ptr = + _lookup>( + 'iotcon_presence_get_host_address'); + late final _dart_iotcon_presence_get_host_address + _iotcon_presence_get_host_address = _iotcon_presence_get_host_address_ptr + .asFunction<_dart_iotcon_presence_get_host_address>(); + + /// @brief Gets connectivity type from the presence handle. + /// @details The @a connectivity_type could be one of #iotcon_connectivity_type_e. + /// @since_tizen 3.0 + /// @param[in] presence The handle of the presence + /// @param[out] connectivity_type The connectivity type of the presence + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_presence_get_host_address() + /// @see iotcon_presence_get_resource_type() + int iotcon_presence_get_connectivity_type( + ffi.Pointer presence, + ffi.Pointer connectivity_type, + ) { + return _iotcon_presence_get_connectivity_type( + presence, + connectivity_type, + ); + } + + late final _iotcon_presence_get_connectivity_type_ptr = + _lookup>( + 'iotcon_presence_get_connectivity_type'); + late final _dart_iotcon_presence_get_connectivity_type + _iotcon_presence_get_connectivity_type = + _iotcon_presence_get_connectivity_type_ptr + .asFunction<_dart_iotcon_presence_get_connectivity_type>(); + + /// @brief Gets resource type from the presence handle. + /// @since_tizen 3.0 + /// @remarks @a resource_type must not be released using free(). + /// @param[in] presence The handle of the presence + /// @param[out] resource_type The resource type of the presence + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_presence_get_host_address() + /// @see iotcon_presence_get_connectivity_type() + int iotcon_presence_get_resource_type( + ffi.Pointer presence, + ffi.Pointer> resource_type, + ) { + return _iotcon_presence_get_resource_type( + presence, + resource_type, + ); + } + + late final _iotcon_presence_get_resource_type_ptr = + _lookup>( + 'iotcon_presence_get_resource_type'); + late final _dart_iotcon_presence_get_resource_type + _iotcon_presence_get_resource_type = + _iotcon_presence_get_resource_type_ptr + .asFunction<_dart_iotcon_presence_get_resource_type>(); + + /// @brief Gets result from the presence response handle. + /// @details The @a result could be one of #iotcon_presence_result_e. + /// @since_tizen 3.0 + /// @param[in] response The handle of the presence response + /// @param[out] result The result code + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_presence_response_get_trigger() + /// @see iotcon_presence_response_get_host_address() + /// @see iotcon_presence_response_get_connectivity_type() + /// @see iotcon_presence_response_get_resource_type() + int iotcon_presence_response_get_result( + ffi.Pointer response, + ffi.Pointer result, + ) { + return _iotcon_presence_response_get_result( + response, + result, + ); + } + + late final _iotcon_presence_response_get_result_ptr = + _lookup>( + 'iotcon_presence_response_get_result'); + late final _dart_iotcon_presence_response_get_result + _iotcon_presence_response_get_result = + _iotcon_presence_response_get_result_ptr + .asFunction<_dart_iotcon_presence_response_get_result>(); + + /// @brief Gets trigger from the presence response handle. + /// @details The @a trigger could be one of #iotcon_presence_trigger_e. + /// It is set only if a response result is IOTCON_PRESENCE_OK. + /// @since_tizen 3.0 + /// @param[in] response The handle of the presence response + /// @param[out] trigger The presence trigger value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_presence_response_get_result() + /// @see iotcon_presence_response_get_host_address() + /// @see iotcon_presence_response_get_connectivity_type() + /// @see iotcon_presence_response_get_resource_type() + int iotcon_presence_response_get_trigger( + ffi.Pointer response, + ffi.Pointer trigger, + ) { + return _iotcon_presence_response_get_trigger( + response, + trigger, + ); + } + + late final _iotcon_presence_response_get_trigger_ptr = + _lookup>( + 'iotcon_presence_response_get_trigger'); + late final _dart_iotcon_presence_response_get_trigger + _iotcon_presence_response_get_trigger = + _iotcon_presence_response_get_trigger_ptr + .asFunction<_dart_iotcon_presence_response_get_trigger>(); + + /// @brief Gets host address from the presence response handle. + /// @since_tizen 3.0 + /// @remarks @a host_address must not be released using free(). + /// @param[in] response The handle of the presence response + /// @param[out] host_address The host address of the presence response + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see iotcon_presence_response_get_result() + /// @see iotcon_presence_response_get_trigger() + /// @see iotcon_presence_response_get_connectivity_type() + /// @see iotcon_presence_response_get_resource_type() + int iotcon_presence_response_get_host_address( + ffi.Pointer response, + ffi.Pointer> host_address, + ) { + return _iotcon_presence_response_get_host_address( + response, + host_address, + ); + } + + late final _iotcon_presence_response_get_host_address_ptr = + _lookup>( + 'iotcon_presence_response_get_host_address'); + late final _dart_iotcon_presence_response_get_host_address + _iotcon_presence_response_get_host_address = + _iotcon_presence_response_get_host_address_ptr + .asFunction<_dart_iotcon_presence_response_get_host_address>(); + + /// @brief Gets connectivity type from the presence response handle. + /// @details The @a connectivity_type could be one of #iotcon_connectivity_type_e. + /// @since_tizen 3.0 + /// @param[in] response The handle of the presence response + /// @param[out] connectivity_type The connectivity type of the presence response + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_presence_response_get_result() + /// @see iotcon_presence_response_get_trigger() + /// @see iotcon_presence_response_get_host_address() + /// @see iotcon_presence_response_get_resource_type() + int iotcon_presence_response_get_connectivity_type( + ffi.Pointer response, + ffi.Pointer connectivity_type, + ) { + return _iotcon_presence_response_get_connectivity_type( + response, + connectivity_type, + ); + } + + late final _iotcon_presence_response_get_connectivity_type_ptr = _lookup< + ffi.NativeFunction< + _c_iotcon_presence_response_get_connectivity_type>>( + 'iotcon_presence_response_get_connectivity_type'); + late final _dart_iotcon_presence_response_get_connectivity_type + _iotcon_presence_response_get_connectivity_type = + _iotcon_presence_response_get_connectivity_type_ptr + .asFunction<_dart_iotcon_presence_response_get_connectivity_type>(); + + /// @brief Gets resource type from the presence response handle. + /// @since_tizen 3.0 + /// @remarks @a resource_type must not be released using free(). + /// @param[in] response The handle of the presence response + /// @param[out] resource_type The resource type of the presence response + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_presence_response_get_result() + /// @see iotcon_presence_response_get_trigger() + /// @see iotcon_presence_response_get_host_address() + /// @see iotcon_presence_response_get_connectivity_type() + int iotcon_presence_response_get_resource_type( + ffi.Pointer response, + ffi.Pointer> resource_type, + ) { + return _iotcon_presence_response_get_resource_type( + response, + resource_type, + ); + } + + late final _iotcon_presence_response_get_resource_type_ptr = _lookup< + ffi.NativeFunction<_c_iotcon_presence_response_get_resource_type>>( + 'iotcon_presence_response_get_resource_type'); + late final _dart_iotcon_presence_response_get_resource_type + _iotcon_presence_response_get_resource_type = + _iotcon_presence_response_get_resource_type_ptr + .asFunction<_dart_iotcon_presence_response_get_resource_type>(); + + /// @brief Finds resources asynchronously. + /// @details Request to find a resource of @a host_address server with @a query.\n + /// @a host_address could be #IOTCON_MULTICAST_ADDRESS for multicast.\n + /// If succeeded to find the resource, iotcon_found_resource_cb() will be invoked with information of the resource. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks @a host_address should be in the format coap://address:port. \n + /// (ex. coaps://[fe80::ae5a:14ff:fe24:b8fe]:12345, or coaps://192.168.1.10:12345)\n + /// @a connectivity_type can be set with extra options. + /// If @a connectivity_type is set without IOTCON_CONNECTIVITY_IPV4_ONLY + /// and IOTCON_CONNECTIVITY_IPV6_ONLY, the resources are discovered by default setting + /// of IoTivity(IPv6 is preferred over IPv4). \n + /// If there are no preference options(PREFER_XXX), resources will reply using each of + /// opened protocol(TCP/UDP). + /// Therefore, you can get remote resource handles which include different host address, + /// but indicates same resource. \n + /// (coaps://192.168.0.2:1234/res/light, coaps+tcp://192.168.0.2/1235/res/light) + /// @a query can be set using specific resource types, or resource interfaces. + /// If @a query is NULL, every resource discovered is listed. + /// @param[in] host_address The address or addressable name of server + /// @param[in] connectivity_type The connectivity type + /// @param[in] query The query specified as a filter for the resource + /// @param[in] cb The callback function to invoke + /// @param[in] user_data The user data to pass to the function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @post iotcon_found_resource_cb() will be invoked. + /// @see iotcon_found_resource_cb() + /// @see iotcon_set_timeout() + int iotcon_find_resource( + ffi.Pointer host_address, + int connectivity_type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_find_resource( + host_address, + connectivity_type, + query, + cb, + user_data, + ); + } + + late final _iotcon_find_resource_ptr = + _lookup>( + 'iotcon_find_resource'); + late final _dart_iotcon_find_resource _iotcon_find_resource = + _iotcon_find_resource_ptr.asFunction<_dart_iotcon_find_resource>(); + + /// @brief Finds the device information of remote server asynchronously. + /// @details Request device information to server and pass the information by calling iotcon_device_info_cb(). \n + /// @a host_address could be #IOTCON_MULTICAST_ADDRESS for multicast. \n + /// If succeeded in getting device information, iotcon_device_info_cb() will be invoked with information. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks @a host_address should be in the format coap://address:port. \n + /// (ex. coap://[fe80::ae5a:14ff:fe24:b8fe]:12345, or coap://192.168.1.10:12345) \n + /// @a connectivity_type can be set with extra options. + /// If @a connectivity_type is set without IOTCON_CONNECTIVITY_IPV4_ONLY + /// and IOTCON_CONNECTIVITY_IPV6_ONLY, device informations are discovered by default setting + /// of IoTivity(IPv6 is preferred over IPv4). \n + /// If there are no preference options(PREFER_XXX), it will reply using UDP. + /// @param[in] host_address The host address of remote server + /// @param[in] connectivity_type The connectivity type + /// @param[in] query The query specified as a filter for the device information + /// @param[in] cb The callback function to invoke + /// @param[in] user_data The user data to pass to the function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @post iotcon_device_info_cb() will be invoked. + /// @see iotcon_set_device_name() + /// @see iotcon_device_info_cb() + /// @see iotcon_device_info_get_property() + /// @see iotcon_set_timeout() + int iotcon_find_device_info( + ffi.Pointer host_address, + int connectivity_type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_find_device_info( + host_address, + connectivity_type, + query, + cb, + user_data, + ); + } + + late final _iotcon_find_device_info_ptr = + _lookup>( + 'iotcon_find_device_info'); + late final _dart_iotcon_find_device_info _iotcon_find_device_info = + _iotcon_find_device_info_ptr.asFunction<_dart_iotcon_find_device_info>(); + + /// @brief Gets device properties from the device information handle. + /// @since_tizen 3.0 + /// @remarks @a value must not be released using free(). + /// @param[in] device_info The handle of the device information + /// @param[in] property The properties of the device information + /// @param[out] value The value of the property + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_set_device_name() + /// @see iotcon_device_info_cb() + /// @see iotcon_find_device_info() + int iotcon_device_info_get_property( + ffi.Pointer device_info, + int property, + ffi.Pointer> value, + ) { + return _iotcon_device_info_get_property( + device_info, + property, + value, + ); + } + + late final _iotcon_device_info_get_property_ptr = + _lookup>( + 'iotcon_device_info_get_property'); + late final _dart_iotcon_device_info_get_property + _iotcon_device_info_get_property = _iotcon_device_info_get_property_ptr + .asFunction<_dart_iotcon_device_info_get_property>(); + + /// @brief Finds the platform information of remote server asynchronously. + /// @details Request platform information to server and pass the information by calling iotcon_platform_info_cb(). \n + /// @a host_address could be #IOTCON_MULTICAST_ADDRESS for multicast. \n + /// If succeeded in getting platform information, iotcon_platform_info_cb() will be invoked with information. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks @a host_address should be in the format coap://address:port. \n + /// (ex. coap://[fe80::ae5a:14ff:fe24:b8fe]:12345, or coap://192.168.1.10:12345) \n + /// @a connectivity_type can be set with extra options. + /// If @a connectivity_type is set without IOTCON_CONNECTIVITY_IPV4_ONLY + /// and IOTCON_CONNECTIVITY_IPV6_ONLY, platform informations are discovered by default setting + /// of IoTivity(IPv6 is preferred over IPv4). \n + /// If there are no preference options(PREFER_XXX), it will reply using UDP. + /// @param[in] host_address The host address of remote server + /// @param[in] connectivity_type The connectivity type + /// @param[in] query The query specified as a filter for the platform information + /// @param[in] cb The callback function to invoke + /// @param[in] user_data The user data to pass to the function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_SYSTEM System error + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @pre iotcon_initialize() should be called to initialize. + /// @post iotcon_platform_info_cb() will be invoked. + /// @see iotcon_platform_info_cb() + /// @see iotcon_platform_info_get_property() + /// @see iotcon_set_timeout() + int iotcon_find_platform_info( + ffi.Pointer host_address, + int connectivity_type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_find_platform_info( + host_address, + connectivity_type, + query, + cb, + user_data, + ); + } + + late final _iotcon_find_platform_info_ptr = + _lookup>( + 'iotcon_find_platform_info'); + late final _dart_iotcon_find_platform_info _iotcon_find_platform_info = + _iotcon_find_platform_info_ptr + .asFunction<_dart_iotcon_find_platform_info>(); + + /// @brief Gets platform properties from the platform information handle. + /// @since_tizen 3.0 + /// @remarks @a value must not be released using free(). + /// @param[in] platform_info The handle of the platform information + /// @param[in] property The properties of the platform information + /// @param[out] value The value of the property + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @see iotcon_platform_info_cb() + /// @see iotcon_find_platform_info() + int iotcon_platform_info_get_property( + ffi.Pointer platform_info, + int property, + ffi.Pointer> value, + ) { + return _iotcon_platform_info_get_property( + platform_info, + property, + value, + ); + } + + late final _iotcon_platform_info_get_property_ptr = + _lookup>( + 'iotcon_platform_info_get_property'); + late final _dart_iotcon_platform_info_get_property + _iotcon_platform_info_get_property = + _iotcon_platform_info_get_property_ptr + .asFunction<_dart_iotcon_platform_info_get_property>(); + + /// @brief Initializes IoTCon. + /// @details Calls this function to start IoTCon. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @privilege %http://tizen.org/privilege/internet + /// @remarks The @a file_path point to a file for handling secure virtual resources. + /// The file that is CBOR(Concise Binary Object Representation)-format must already exist in @a file_path. + /// We recommend to use application-local file for @a file_path. \n + /// You must call iotcon_deinitialize() if IoTCon API is no longer needed. + /// @param[in] file_path The path of SVR(Secure Virtual Resources) DB + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_PERMISSION_DENIED Permission denied + /// @see iotcon_deinitialize() + int iotcon_initialize( + ffi.Pointer file_path, + ) { + return _iotcon_initialize( + file_path, + ); + } + + late final _iotcon_initialize_ptr = + _lookup>('iotcon_initialize'); + late final _dart_iotcon_initialize _iotcon_initialize = + _iotcon_initialize_ptr.asFunction<_dart_iotcon_initialize>(); + + /// @brief Deinitializes IoTCon. + /// @details Frees the resources allocated to IoTCon. + /// @since_tizen 3.0 + /// @remarks This function must be called if IoTCon API is no longer needed. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_initialize() + int iotcon_deinitialize() { + return _iotcon_deinitialize(); + } + + late final _iotcon_deinitialize_ptr = + _lookup>( + 'iotcon_deinitialize'); + late final _dart_iotcon_deinitialize _iotcon_deinitialize = + _iotcon_deinitialize_ptr.asFunction<_dart_iotcon_deinitialize>(); + + /// @brief Gets the timeout seconds of asynchronous API. + /// @details This API get the timeout of iotcon_find_device_info(), + /// iotcon_find_platform_info(), iotcon_find_resource(), + /// iotcon_remote_resource_get(), iotcon_remote_resource_put(), + /// iotcon_remote_resource_post() and iotcon_remote_resource_delete(). + /// @since_tizen 3.0 + /// @param[out] timeout_seconds Seconds for timeout + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_set_timeout() + int iotcon_get_timeout( + ffi.Pointer timeout_seconds, + ) { + return _iotcon_get_timeout( + timeout_seconds, + ); + } + + late final _iotcon_get_timeout_ptr = + _lookup>('iotcon_get_timeout'); + late final _dart_iotcon_get_timeout _iotcon_get_timeout = + _iotcon_get_timeout_ptr.asFunction<_dart_iotcon_get_timeout>(); + + /// @brief Sets the timeout seconds of asynchronous APIs. + /// @details This API set the timeout of iotcon_find_device_info(), + /// iotcon_find_platform_info(), iotcon_find_resource(), + /// iotcon_remote_resource_get(), iotcon_remote_resource_put(), + /// iotcon_remote_resource_post() and iotcon_remote_resource_delete().\n + /// Default timeout interval value is 30. + /// @since_tizen 3.0 + /// @param[in] timeout_seconds Seconds for timeout (must be in range from 1 to 3600) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_get_timeout() + int iotcon_set_timeout( + int timeout_seconds, + ) { + return _iotcon_set_timeout( + timeout_seconds, + ); + } + + late final _iotcon_set_timeout_ptr = + _lookup>('iotcon_set_timeout'); + late final _dart_iotcon_set_timeout _iotcon_set_timeout = + _iotcon_set_timeout_ptr.asFunction<_dart_iotcon_set_timeout>(); + + /// @brief Gets the polling interval(milliseconds) of IoTCon. + /// @details This API gets the polling interval of IoTCon. + /// Default polling interval is 100 milliseconds. + /// @since_tizen 3.0 + /// @param[out] interval Milliseconds for polling interval + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_set_timeout() + int iotcon_polling_get_interval( + ffi.Pointer interval, + ) { + return _iotcon_polling_get_interval( + interval, + ); + } + + late final _iotcon_polling_get_interval_ptr = + _lookup>( + 'iotcon_polling_get_interval'); + late final _dart_iotcon_polling_get_interval _iotcon_polling_get_interval = + _iotcon_polling_get_interval_ptr + .asFunction<_dart_iotcon_polling_get_interval>(); + + /// @brief Sets the polling interval(milliseconds) of IoTCon. + /// @details This API sets the polling interval of IoTCon. + /// The closer to 0, the faster it operates. It is invoked immediately for changing the interval. + /// Default polling interval is 100 milliseconds. If you want the faster operation, + /// we recommend you set 10 milliseconds for polling interval. + /// @since_tizen 3.0 + /// @param[in] interval Milliseconds for polling interval (must be in range from 1 to 999) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_polling_get_interval() + int iotcon_polling_set_interval( + int interval, + ) { + return _iotcon_polling_set_interval( + interval, + ); + } + + late final _iotcon_polling_set_interval_ptr = + _lookup>( + 'iotcon_polling_set_interval'); + late final _dart_iotcon_polling_set_interval _iotcon_polling_set_interval = + _iotcon_polling_set_interval_ptr + .asFunction<_dart_iotcon_polling_set_interval>(); + + /// @brief Invokes a next message from a queue for receiving messages from others immediately. + /// @details This API invokes a next message from a queue for receiving messages from others immediately. \n + /// After calling the API, it continues the polling with existing interval. + /// @since_tizen 3.0 + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @pre iotcon_initialize() should be called to initialize. + int iotcon_polling_invoke() { + return _iotcon_polling_invoke(); + } + + late final _iotcon_polling_invoke_ptr = + _lookup>( + 'iotcon_polling_invoke'); + late final _dart_iotcon_polling_invoke _iotcon_polling_invoke = + _iotcon_polling_invoke_ptr.asFunction<_dart_iotcon_polling_invoke>(); + + /// @brief Adds callback to show pin number which is generated automatically. + /// @details When a provisioning tool tries to register this device using random pin based \n + /// ownership transfer method, it makes pin number which is generated automatically be shown. + /// @since_tizen 3.0 + /// @param[in] cb The callback function to invoke + /// @param[in] user_data The user data to pass to the function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_ALREADY Already done + /// @retval #IOTCON_ERROR_OUT_OF_MEMORY Out of memory + /// @pre iotcon_initialize() should be called to initialize. + /// @post When the device is registered by provisioning tool, iotcon_generated_pin_cb() will be called. + /// @see iotcon_remove_generated_pin_cb() + int iotcon_add_generated_pin_cb( + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _iotcon_add_generated_pin_cb( + cb, + user_data, + ); + } + + late final _iotcon_add_generated_pin_cb_ptr = + _lookup>( + 'iotcon_add_generated_pin_cb'); + late final _dart_iotcon_add_generated_pin_cb _iotcon_add_generated_pin_cb = + _iotcon_add_generated_pin_cb_ptr + .asFunction<_dart_iotcon_add_generated_pin_cb>(); + + /// @brief Removes callback to show pin number which is generated automatically. + /// @details If this function is called, @a cb will be not called anymore. \n + /// For removing @a cb that is used at iotcon_add_generated_pin_cb() should be used. + /// @since_tizen 3.0 + /// @param[in] cb The callback function to invoke + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IOTCON_ERROR_NONE Successful + /// @retval #IOTCON_ERROR_NOT_SUPPORTED Not supported + /// @retval #IOTCON_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IOTCON_ERROR_NO_DATA No data available + /// @pre iotcon_initialize() should be called to initialize. + /// @see iotcon_add_generated_pin_cb() + int iotcon_remove_generated_pin_cb( + ffi.Pointer> cb, + ) { + return _iotcon_remove_generated_pin_cb( + cb, + ); + } + + late final _iotcon_remove_generated_pin_cb_ptr = + _lookup>( + 'iotcon_remove_generated_pin_cb'); + late final _dart_iotcon_remove_generated_pin_cb + _iotcon_remove_generated_pin_cb = _iotcon_remove_generated_pin_cb_ptr + .asFunction<_dart_iotcon_remove_generated_pin_cb>(); + + /// @brief The default factory key. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @details The key is 0xff, 0xff, 0xff, 0xff, 0xff, 0xff + /// @ingroup CAPI_NETWORK_NFC_TAG_MIFARE_MODULE + late final ffi.Pointer> _NFC_TAG_MIFARE_KEY_DEFAULT = + _lookup>('NFC_TAG_MIFARE_KEY_DEFAULT'); + + ffi.Pointer get NFC_TAG_MIFARE_KEY_DEFAULT => + _NFC_TAG_MIFARE_KEY_DEFAULT.value; + + set NFC_TAG_MIFARE_KEY_DEFAULT(ffi.Pointer value) => + _NFC_TAG_MIFARE_KEY_DEFAULT.value = value; + + /// @brief The well-known key for tags formatted according to the MIFARE Application Directory (MAD) specification. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @details The key is 0xA0, 0xA1, 0xA2, 0xA3, 0xA4, 0xA5 + /// @ingroup CAPI_NETWORK_NFC_TAG_MIFARE_MODULE + late final ffi.Pointer> + _NFC_TAG_MIFARE_KEY_APPLICATION_DIRECTORY = + _lookup>( + 'NFC_TAG_MIFARE_KEY_APPLICATION_DIRECTORY'); + + ffi.Pointer get NFC_TAG_MIFARE_KEY_APPLICATION_DIRECTORY => + _NFC_TAG_MIFARE_KEY_APPLICATION_DIRECTORY.value; + + set NFC_TAG_MIFARE_KEY_APPLICATION_DIRECTORY(ffi.Pointer value) => + _NFC_TAG_MIFARE_KEY_APPLICATION_DIRECTORY.value = value; + + /// @brief The well-known key for tags formatted according to the NDEF on Mifare Classic specification. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @details The key is 0xD3, 0xF7, 0xD3, 0xF7, 0xD3, 0xF7 + /// @ingroup CAPI_NETWORK_NFC_TAG_MIFARE_MODULE + late final ffi.Pointer> _NFC_TAG_MIFARE_KEY_NFC_FORUM = + _lookup>('NFC_TAG_MIFARE_KEY_NFC_FORUM'); + + ffi.Pointer get NFC_TAG_MIFARE_KEY_NFC_FORUM => + _NFC_TAG_MIFARE_KEY_NFC_FORUM.value; + + set NFC_TAG_MIFARE_KEY_NFC_FORUM(ffi.Pointer value) => + _NFC_TAG_MIFARE_KEY_NFC_FORUM.value = value; + + /// @brief RTD(Record type definition) Type - Smart Poster type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + late final ffi.Pointer> _NFC_RECORD_SMART_POSTER_TYPE = + _lookup>('NFC_RECORD_SMART_POSTER_TYPE'); + + ffi.Pointer get NFC_RECORD_SMART_POSTER_TYPE => + _NFC_RECORD_SMART_POSTER_TYPE.value; + + set NFC_RECORD_SMART_POSTER_TYPE(ffi.Pointer value) => + _NFC_RECORD_SMART_POSTER_TYPE.value = value; + + /// @brief RTD(Record type definition) Type - Text type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + late final ffi.Pointer> _NFC_RECORD_TEXT_TYPE = + _lookup>('NFC_RECORD_TEXT_TYPE'); + + ffi.Pointer get NFC_RECORD_TEXT_TYPE => + _NFC_RECORD_TEXT_TYPE.value; + + set NFC_RECORD_TEXT_TYPE(ffi.Pointer value) => + _NFC_RECORD_TEXT_TYPE.value = value; + + /// @brief RTD(Record type definition) Type - URI type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + late final ffi.Pointer> _NFC_RECORD_URI_TYPE = + _lookup>('NFC_RECORD_URI_TYPE'); + + ffi.Pointer get NFC_RECORD_URI_TYPE => _NFC_RECORD_URI_TYPE.value; + + set NFC_RECORD_URI_TYPE(ffi.Pointer value) => + _NFC_RECORD_URI_TYPE.value = value; + + /// @brief RTD(Record type definition) Type - Alternative Carrier type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + late final ffi.Pointer> + _NFC_RECORD_ALTERNATIVE_CARRIER_TYPE = + _lookup>('NFC_RECORD_ALTERNATIVE_CARRIER_TYPE'); + + ffi.Pointer get NFC_RECORD_ALTERNATIVE_CARRIER_TYPE => + _NFC_RECORD_ALTERNATIVE_CARRIER_TYPE.value; + + set NFC_RECORD_ALTERNATIVE_CARRIER_TYPE(ffi.Pointer value) => + _NFC_RECORD_ALTERNATIVE_CARRIER_TYPE.value = value; + + /// @brief RTD(Record type definition) Type - Handover Carrier type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + late final ffi.Pointer> + _NFC_RECORD_HANDOVER_CARRIER_TYPE = + _lookup>('NFC_RECORD_HANDOVER_CARRIER_TYPE'); + + ffi.Pointer get NFC_RECORD_HANDOVER_CARRIER_TYPE => + _NFC_RECORD_HANDOVER_CARRIER_TYPE.value; + + set NFC_RECORD_HANDOVER_CARRIER_TYPE(ffi.Pointer value) => + _NFC_RECORD_HANDOVER_CARRIER_TYPE.value = value; + + /// @brief RTD(Record type definition) Type - Handover Request type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + late final ffi.Pointer> + _NFC_RECORD_HANDOVER_REQUEST_TYPE = + _lookup>('NFC_RECORD_HANDOVER_REQUEST_TYPE'); + + ffi.Pointer get NFC_RECORD_HANDOVER_REQUEST_TYPE => + _NFC_RECORD_HANDOVER_REQUEST_TYPE.value; + + set NFC_RECORD_HANDOVER_REQUEST_TYPE(ffi.Pointer value) => + _NFC_RECORD_HANDOVER_REQUEST_TYPE.value = value; + + /// @brief RTD(Record type definition) Type - Handover Select type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + late final ffi.Pointer> + _NFC_RECORD_HANDOVER_SELECT_TYPE = + _lookup>('NFC_RECORD_HANDOVER_SELECT_TYPE'); + + ffi.Pointer get NFC_RECORD_HANDOVER_SELECT_TYPE => + _NFC_RECORD_HANDOVER_SELECT_TYPE.value; + + set NFC_RECORD_HANDOVER_SELECT_TYPE(ffi.Pointer value) => + _NFC_RECORD_HANDOVER_SELECT_TYPE.value = value; + + /// @brief Gets the value that indicates whether NFC is supported. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @remarks This function can executed Regardless of nfc_manager_initialize state. + /// + /// @return true on NFC supported, otherwise false + /// @exception #NFC_ERROR_NONE Success + /// @exception #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @exception #NFC_ERROR_ILLEGAL_STATE Illegal state + /// @exception #NFC_ERROR_OPERATION_FAILED Operation fail + bool nfc_manager_is_supported() { + return _nfc_manager_is_supported() != 0; + } + + late final _nfc_manager_is_supported_ptr = + _lookup>( + 'nfc_manager_is_supported'); + late final _dart_nfc_manager_is_supported _nfc_manager_is_supported = + _nfc_manager_is_supported_ptr + .asFunction<_dart_nfc_manager_is_supported>(); + + /// @brief Set NFC Activation state changed callback + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @param [in] callback The callback function to invoke when activation state is changed. + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_activation_changed_cb() + /// @see nfc_manager_unset_activation_changed_cb() + /// @see nfc_manager_initialize() + int nfc_manager_set_activation_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_manager_set_activation_changed_cb( + callback, + user_data, + ); + } + + late final _nfc_manager_set_activation_changed_cb_ptr = + _lookup>( + 'nfc_manager_set_activation_changed_cb'); + late final _dart_nfc_manager_set_activation_changed_cb + _nfc_manager_set_activation_changed_cb = + _nfc_manager_set_activation_changed_cb_ptr + .asFunction<_dart_nfc_manager_set_activation_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// + /// @exception #NFC_ERROR_NONE Success + /// @exception #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @exception #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// + /// @see nfc_manager_set_activation_changed_cb() + /// @see nfc_activation_changed_cb() + /// @see nfc_manager_initialize() + void nfc_manager_unset_activation_changed_cb() { + return _nfc_manager_unset_activation_changed_cb(); + } + + late final _nfc_manager_unset_activation_changed_cb_ptr = + _lookup>( + 'nfc_manager_unset_activation_changed_cb'); + late final _dart_nfc_manager_unset_activation_changed_cb + _nfc_manager_unset_activation_changed_cb = + _nfc_manager_unset_activation_changed_cb_ptr + .asFunction<_dart_nfc_manager_unset_activation_changed_cb>(); + + /// @brief Sets NFC Activation + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/nfc.admin + /// @platform + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @param [in] activation The NFC state for setting + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @post It invokes nfc_activation_completed_cb() when it has completed to set activation.\n + /// The Callback can receive error code when process is done. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_ALREADY_ACTIVATED Already activated + /// @retval #NFC_ERROR_ALREADY_DEACTIVATED Already deactivated + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_OPERATION_FAILED Operation fail + /// + /// @see nfc_manager_is_activated() + /// @see nfc_activation_completed_cb() + /// @see nfc_manager_initialize() + int nfc_manager_set_activation( + bool activation, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_manager_set_activation( + activation ? 1 : 0, + callback, + user_data, + ); + } + + late final _nfc_manager_set_activation_ptr = + _lookup>( + 'nfc_manager_set_activation'); + late final _dart_nfc_manager_set_activation _nfc_manager_set_activation = + _nfc_manager_set_activation_ptr + .asFunction<_dart_nfc_manager_set_activation>(); + + /// @brief Gets NFC Activation state + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @remarks This function can executed Regardless of nfc_manager_initialize state. + /// + /// @return true on NFC activated, otherwise false + /// @exception #NFC_ERROR_NONE Success + /// @exception #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @exception #NFC_ERROR_ILLEGAL_STATE Illegal state + /// @exception #NFC_ERROR_OPERATION_FAILED Operation fail + bool nfc_manager_is_activated() { + return _nfc_manager_is_activated() != 0; + } + + late final _nfc_manager_is_activated_ptr = + _lookup>( + 'nfc_manager_is_activated'); + late final _dart_nfc_manager_is_activated _nfc_manager_is_activated = + _nfc_manager_is_activated_ptr + .asFunction<_dart_nfc_manager_is_activated>(); + + /// @brief Initializes NFC Manager. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// @remarks This function must be called before proceeding any other nfc functions\n + /// When an application crashes or exits without the deinitialization. NFC manager automatically deinitializes the process itself.\n + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_OPERATION_FAILED Operation fail + /// + /// @see nfc_manager_deinitialize() + int nfc_manager_initialize() { + return _nfc_manager_initialize(); + } + + late final _nfc_manager_initialize_ptr = + _lookup>( + 'nfc_manager_initialize'); + late final _dart_nfc_manager_initialize _nfc_manager_initialize = + _nfc_manager_initialize_ptr.asFunction<_dart_nfc_manager_initialize>(); + + /// @brief Releases all the resource of the NFC Manager and disconnect the session between an application and NFC Manager. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_OPERATION_FAILED Operation fail + /// + /// @see nfc_manager_initialize() + int nfc_manager_deinitialize() { + return _nfc_manager_deinitialize(); + } + + late final _nfc_manager_deinitialize_ptr = + _lookup>( + 'nfc_manager_deinitialize'); + late final _dart_nfc_manager_deinitialize _nfc_manager_deinitialize = + _nfc_manager_deinitialize_ptr + .asFunction<_dart_nfc_manager_deinitialize>(); + + /// @brief Registers a callback function for receiving tag discovered notification. + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @param [in] callback The callback function called when a tag is appeared or disappeared + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_manager_unset_tag_discovered_cb() + /// @see nfc_tag_discovered_cb() + /// @see nfc_manager_initialize() + int nfc_manager_set_tag_discovered_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_manager_set_tag_discovered_cb( + callback, + user_data, + ); + } + + late final _nfc_manager_set_tag_discovered_cb_ptr = + _lookup>( + 'nfc_manager_set_tag_discovered_cb'); + late final _dart_nfc_manager_set_tag_discovered_cb + _nfc_manager_set_tag_discovered_cb = + _nfc_manager_set_tag_discovered_cb_ptr + .asFunction<_dart_nfc_manager_set_tag_discovered_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// + /// @exception #NFC_ERROR_NONE Success + /// @exception #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @exception #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// + /// @see nfc_manager_set_tag_discovered_cb() + /// @see nfc_tag_discovered_cb() + /// @see nfc_manager_initialize() + void nfc_manager_unset_tag_discovered_cb() { + return _nfc_manager_unset_tag_discovered_cb(); + } + + late final _nfc_manager_unset_tag_discovered_cb_ptr = + _lookup>( + 'nfc_manager_unset_tag_discovered_cb'); + late final _dart_nfc_manager_unset_tag_discovered_cb + _nfc_manager_unset_tag_discovered_cb = + _nfc_manager_unset_tag_discovered_cb_ptr + .asFunction<_dart_nfc_manager_unset_tag_discovered_cb>(); + + /// @brief Registers a callback function for receiving NDEF Message discovered notification + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @param [in] callback The callback function called when NDEF Message is discovered + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_manager_unset_ndef_discovered_cb() + /// @see nfc_ndef_discovered_cb() + /// @see nfc_manager_initialize() + int nfc_manager_set_ndef_discovered_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_manager_set_ndef_discovered_cb( + callback, + user_data, + ); + } + + late final _nfc_manager_set_ndef_discovered_cb_ptr = + _lookup>( + 'nfc_manager_set_ndef_discovered_cb'); + late final _dart_nfc_manager_set_ndef_discovered_cb + _nfc_manager_set_ndef_discovered_cb = + _nfc_manager_set_ndef_discovered_cb_ptr + .asFunction<_dart_nfc_manager_set_ndef_discovered_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// + /// @exception #NFC_ERROR_NONE Success + /// @exception #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @exception #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// + /// @see nfc_manager_set_ndef_discovered_cb() + /// @see nfc_ndef_discovered_cb() + /// @see nfc_manager_initialize() + void nfc_manager_unset_ndef_discovered_cb() { + return _nfc_manager_unset_ndef_discovered_cb(); + } + + late final _nfc_manager_unset_ndef_discovered_cb_ptr = + _lookup>( + 'nfc_manager_unset_ndef_discovered_cb'); + late final _dart_nfc_manager_unset_ndef_discovered_cb + _nfc_manager_unset_ndef_discovered_cb = + _nfc_manager_unset_ndef_discovered_cb_ptr + .asFunction<_dart_nfc_manager_unset_ndef_discovered_cb>(); + + /// @brief Registers a callback function for receiving NFC peer-to-peer target discovered notification. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @param [in] callback The callback function called when NFC peer-to-peer target is discovered + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_manager_unset_ndef_discovered_cb() + /// @see nfc_p2p_target_discovered_cb() + /// @see nfc_manager_initialize() + int nfc_manager_set_p2p_target_discovered_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_manager_set_p2p_target_discovered_cb( + callback, + user_data, + ); + } + + late final _nfc_manager_set_p2p_target_discovered_cb_ptr = + _lookup>( + 'nfc_manager_set_p2p_target_discovered_cb'); + late final _dart_nfc_manager_set_p2p_target_discovered_cb + _nfc_manager_set_p2p_target_discovered_cb = + _nfc_manager_set_p2p_target_discovered_cb_ptr + .asFunction<_dart_nfc_manager_set_p2p_target_discovered_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// + /// @exception #NFC_ERROR_NONE Success + /// @exception #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @exception #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// + /// @see nfc_manager_set_p2p_target_discovered_cb() + /// @see nfc_p2p_target_discovered_cb() + /// @see nfc_manager_initialize() + void nfc_manager_unset_p2p_target_discovered_cb() { + return _nfc_manager_unset_p2p_target_discovered_cb(); + } + + late final _nfc_manager_unset_p2p_target_discovered_cb_ptr = _lookup< + ffi.NativeFunction<_c_nfc_manager_unset_p2p_target_discovered_cb>>( + 'nfc_manager_unset_p2p_target_discovered_cb'); + late final _dart_nfc_manager_unset_p2p_target_discovered_cb + _nfc_manager_unset_p2p_target_discovered_cb = + _nfc_manager_unset_p2p_target_discovered_cb_ptr + .asFunction<_dart_nfc_manager_unset_p2p_target_discovered_cb>(); + + /// @brief Registers a callback function for receiving Secure Element (SIM/UICC(Universal Integrated Circuit Card)) event. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @param [in] callback The callback function called when occurred Secure Element (SIM/UICC(Universal Integrated Circuit Card)) event. + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_se_event_cb() + /// @see nfc_manager_unset_se_event_cb() + /// @see nfc_manager_initialize() + int nfc_manager_set_se_event_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_manager_set_se_event_cb( + callback, + user_data, + ); + } + + late final _nfc_manager_set_se_event_cb_ptr = + _lookup>( + 'nfc_manager_set_se_event_cb'); + late final _dart_nfc_manager_set_se_event_cb _nfc_manager_set_se_event_cb = + _nfc_manager_set_se_event_cb_ptr + .asFunction<_dart_nfc_manager_set_se_event_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// + /// @exception #NFC_ERROR_NONE Success + /// @exception #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @exception #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// + /// @see nfc_se_event_cb() + /// @see nfc_manager_set_se_event_cb() + /// @see nfc_manager_initialize() + void nfc_manager_unset_se_event_cb() { + return _nfc_manager_unset_se_event_cb(); + } + + late final _nfc_manager_unset_se_event_cb_ptr = + _lookup>( + 'nfc_manager_unset_se_event_cb'); + late final _dart_nfc_manager_unset_se_event_cb + _nfc_manager_unset_se_event_cb = _nfc_manager_unset_se_event_cb_ptr + .asFunction<_dart_nfc_manager_unset_se_event_cb>(); + + /// @brief Registers a callback function for receiving Secure Element (SIM/UICC(Universal Integrated Circuit Card)) transaction event(#NFC_SE_EVENT_TRANSACTION) data. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @param [in] se_type The type of secure element. + /// @param [in] callback The callback function called when occurred SE transaction event. + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_se_transaction_event_cb() + /// @see nfc_manager_unset_se_transaction_event_cb() + /// @see nfc_manager_initialize() + int nfc_manager_set_se_transaction_event_cb( + int se_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_manager_set_se_transaction_event_cb( + se_type, + callback, + user_data, + ); + } + + late final _nfc_manager_set_se_transaction_event_cb_ptr = + _lookup>( + 'nfc_manager_set_se_transaction_event_cb'); + late final _dart_nfc_manager_set_se_transaction_event_cb + _nfc_manager_set_se_transaction_event_cb = + _nfc_manager_set_se_transaction_event_cb_ptr + .asFunction<_dart_nfc_manager_set_se_transaction_event_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @param [in] se_type The type of secure element. + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// + /// @exception #NFC_ERROR_NONE Success + /// @exception #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @exception #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// + /// @see nfc_se_transaction_event_cb() + /// @see nfc_manager_set_se_transaction_event_cb() + /// @see nfc_manager_initialize() + void nfc_manager_unset_se_transaction_event_cb( + int se_type, + ) { + return _nfc_manager_unset_se_transaction_event_cb( + se_type, + ); + } + + late final _nfc_manager_unset_se_transaction_event_cb_ptr = + _lookup>( + 'nfc_manager_unset_se_transaction_event_cb'); + late final _dart_nfc_manager_unset_se_transaction_event_cb + _nfc_manager_unset_se_transaction_event_cb = + _nfc_manager_unset_se_transaction_event_cb_ptr + .asFunction<_dart_nfc_manager_unset_se_transaction_event_cb>(); + + /// @brief Registers a callback function for receiving HCE(Host Card Emulation) event. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @param [in] callback The callback function called when HCE(Host Card Emulation) event occurred. + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see nfc_hce_event_cb() + /// @see nfc_manager_unset_hce_event_cb() + /// @see nfc_manager_initialize() + int nfc_manager_set_hce_event_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_manager_set_hce_event_cb( + callback, + user_data, + ); + } + + late final _nfc_manager_set_hce_event_cb_ptr = + _lookup>( + 'nfc_manager_set_hce_event_cb'); + late final _dart_nfc_manager_set_hce_event_cb _nfc_manager_set_hce_event_cb = + _nfc_manager_set_hce_event_cb_ptr + .asFunction<_dart_nfc_manager_set_hce_event_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// + /// @exception #NFC_ERROR_NONE Success + /// @exception #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @exception #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @exception #NFC_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see nfc_hce_event_cb() + /// @see nfc_manager_set_hce_event_cb() + /// @see nfc_manager_initialize() + void nfc_manager_unset_hce_event_cb() { + return _nfc_manager_unset_hce_event_cb(); + } + + late final _nfc_manager_unset_hce_event_cb_ptr = + _lookup>( + 'nfc_manager_unset_hce_event_cb'); + late final _dart_nfc_manager_unset_hce_event_cb + _nfc_manager_unset_hce_event_cb = _nfc_manager_unset_hce_event_cb_ptr + .asFunction<_dart_nfc_manager_unset_hce_event_cb>(); + + /// @brief give the priority to the foreground application when dispatching transaction event. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// @remarks This function must be called only when the application is in the foreground. \n + /// If the application go out from foreground, application must call "nfc_manager_disable_transaction_fg_dispatch" to disable foreground dispatch \n\n + /// @remarks Security level can be determined by the manufacturer usage.\n + /// If a security issue is occurred, contact with the manufacturer of the product.\n + /// If you want to know about security level in detail, See the GSMA specification.\n + /// (http://www.gsma.com/digitalcommerce/wp-content/uploads/2013/12/GSMA-NFC05-NFC-Handset-APIs-Requirement-Specification-version-4-1.pdf) + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_PERMISSION_DENIED Security restricted by SMACK + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_SECURITY_RESTRICTED Security restricted by Access Control + /// @retval #NFC_ERROR_ILLEGAL_STATE Illegal state + /// @retval #NFC_ERROR_OPERATION_FAILED IPC fail + /// + /// @see nfc_manager_disable_transaction_fg_dispatch() + /// @see nfc_manager_initialize() + int nfc_manager_enable_transaction_fg_dispatch() { + return _nfc_manager_enable_transaction_fg_dispatch(); + } + + late final _nfc_manager_enable_transaction_fg_dispatch_ptr = _lookup< + ffi.NativeFunction<_c_nfc_manager_enable_transaction_fg_dispatch>>( + 'nfc_manager_enable_transaction_fg_dispatch'); + late final _dart_nfc_manager_enable_transaction_fg_dispatch + _nfc_manager_enable_transaction_fg_dispatch = + _nfc_manager_enable_transaction_fg_dispatch_ptr + .asFunction<_dart_nfc_manager_enable_transaction_fg_dispatch>(); + + /// @brief disable foreground dispatch for "EVT_TRANSACTION" to the given application. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// @remarks After calling "nfc_manager_enable_transaction_fg_dispatch", an application must call this api when it goes out from foreground. \n\n + /// @remarks Security level can be determined by the manufacturer usage.\n + /// If a security issue is occurred, contact with the manufacturer of the product.\n + /// If you want to know about security level in detail, See the GSMA specification.\n + /// (http://www.gsma.com/digitalcommerce/wp-content/uploads/2013/12/GSMA-NFC05-NFC-Handset-APIs-Requirement-Specification-version-4-1.pdf) + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_PERMISSION_DENIED Security restricted by SMACK + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_SECURITY_RESTRICTED Security restricted by Access Control + /// @retval #NFC_ERROR_ILLEGAL_STATE Illegal state + /// @retval #NFC_ERROR_OPERATION_FAILED IPC fail + /// + /// @see nfc_manager_enable_transaction_fg_dispatch() + /// @see nfc_manager_initialize() + int nfc_manager_disable_transaction_fg_dispatch() { + return _nfc_manager_disable_transaction_fg_dispatch(); + } + + late final _nfc_manager_disable_transaction_fg_dispatch_ptr = _lookup< + ffi.NativeFunction<_c_nfc_manager_disable_transaction_fg_dispatch>>( + 'nfc_manager_disable_transaction_fg_dispatch'); + late final _dart_nfc_manager_disable_transaction_fg_dispatch + _nfc_manager_disable_transaction_fg_dispatch = + _nfc_manager_disable_transaction_fg_dispatch_ptr + .asFunction<_dart_nfc_manager_disable_transaction_fg_dispatch>(); + + /// @brief Gets NDEF message cached when the tag is detected or when data received from NFC peer-to-peer target. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @remarks This function is used to get the ndef message that was read before launched your application. + /// @param [out] ndef_message The cached NDEF message + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_NO_NDEF_MESSAGE The cached message does not exist + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @see nfc_manager_initialize() + int nfc_manager_get_cached_message( + ffi.Pointer> ndef_message, + ) { + return _nfc_manager_get_cached_message( + ndef_message, + ); + } + + late final _nfc_manager_get_cached_message_ptr = + _lookup>( + 'nfc_manager_get_cached_message'); + late final _dart_nfc_manager_get_cached_message + _nfc_manager_get_cached_message = _nfc_manager_get_cached_message_ptr + .asFunction<_dart_nfc_manager_get_cached_message>(); + + /// @brief Sets filter of target types. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// @remarks Bit operator OR(|) can be used in the configure parameter (like NFC_TAG_FILTER_ISO14443A_ENABLE | NFC_TAG_FILTER_ISO14443B_ENABLE) + /// or you may choose "NFC_TAG_ALL_ENABLE" enum value to get all result. + /// It prevent getting tag types from RF level. + /// If the client api does call this function, default is always NFC_TAG_ALL_ENABLE. + /// + /// @param [in] filter The filter value with bits operation #nfc_tag_filter_e + /// + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// + /// @exception #NFC_ERROR_NONE Success + /// @exception #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @exception #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @exception #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_manager_get_tag_filter() + /// @see nfc_tag_discovered_cb() + /// @see nfc_manager_initialize() + void nfc_manager_set_tag_filter( + int filter, + ) { + return _nfc_manager_set_tag_filter( + filter, + ); + } + + late final _nfc_manager_set_tag_filter_ptr = + _lookup>( + 'nfc_manager_set_tag_filter'); + late final _dart_nfc_manager_set_tag_filter _nfc_manager_set_tag_filter = + _nfc_manager_set_tag_filter_ptr + .asFunction<_dart_nfc_manager_set_tag_filter>(); + + /// @brief Gets the current filter status. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @remarks Bit operation OR(|) is used in return data\n + /// The default value is NFC_TAG_FILTER_ALL_ENABLE + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// + /// @return The filter which is set #nfc_tag_filter_e + /// + /// @exception #NFC_ERROR_NONE Success + /// @exception #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @exception #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// + /// @see nfc_manager_set_tag_filter() + /// @see nfc_manager_initialize() + int nfc_manager_get_tag_filter() { + return _nfc_manager_get_tag_filter(); + } + + late final _nfc_manager_get_tag_filter_ptr = + _lookup>( + 'nfc_manager_get_tag_filter'); + late final _dart_nfc_manager_get_tag_filter _nfc_manager_get_tag_filter = + _nfc_manager_get_tag_filter_ptr + .asFunction<_dart_nfc_manager_get_tag_filter>(); + + /// @brief Gets current connected tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @param [out] tag The connected tag + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_NO_DEVICE There is no connected target + /// @retval #NFC_ERROR_PERMISSION_DENIED Security restricted by SMACK + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_NO_DEVICE There is no connected tag + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @see nfc_manager_initialize() + int nfc_manager_get_connected_tag( + ffi.Pointer> tag, + ) { + return _nfc_manager_get_connected_tag( + tag, + ); + } + + late final _nfc_manager_get_connected_tag_ptr = + _lookup>( + 'nfc_manager_get_connected_tag'); + late final _dart_nfc_manager_get_connected_tag + _nfc_manager_get_connected_tag = _nfc_manager_get_connected_tag_ptr + .asFunction<_dart_nfc_manager_get_connected_tag>(); + + /// @brief Gets current connected p2p target + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @param [out] target The connected target + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_NO_DEVICE There is no connected target + /// @retval #NFC_ERROR_PERMISSION_DENIED Security restricted by SMACK + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_NO_DEVICE There is no connected tag + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @see nfc_manager_initialize() + int nfc_manager_get_connected_target( + ffi.Pointer> target, + ) { + return _nfc_manager_get_connected_target( + target, + ); + } + + late final _nfc_manager_get_connected_target_ptr = + _lookup>( + 'nfc_manager_get_connected_target'); + late final _dart_nfc_manager_get_connected_target + _nfc_manager_get_connected_target = _nfc_manager_get_connected_target_ptr + .asFunction<_dart_nfc_manager_get_connected_target>(); + + /// @brief Enable or disable the system handling for tag and target discovered event + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// @remarks In default, The system handling is enabled. + /// + /// @param [in] enable The state of enable + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_PERMISSION_DENIED Security restricted by SMACK + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @see nfc_manager_is_system_handler_enabled() + /// @see nfc_manager_initialize() + int nfc_manager_set_system_handler_enable( + bool enable, + ) { + return _nfc_manager_set_system_handler_enable( + enable ? 1 : 0, + ); + } + + late final _nfc_manager_set_system_handler_enable_ptr = + _lookup>( + 'nfc_manager_set_system_handler_enable'); + late final _dart_nfc_manager_set_system_handler_enable + _nfc_manager_set_system_handler_enable = + _nfc_manager_set_system_handler_enable_ptr + .asFunction<_dart_nfc_manager_set_system_handler_enable>(); + + /// @brief Gets the state of the system handler + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// @remarks In default, The system handling is enabled. + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// + /// @return true on enabled, otherwise false. + /// + /// @exception #NFC_ERROR_NONE Success + /// @exception #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @exception #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @exception #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @exception #NFC_ERROR_PERMISSION_DENIED Security restricted by SMACK + /// @exception #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @see nfc_manager_set_system_handler_enable() + /// @see nfc_manager_initialize() + bool nfc_manager_is_system_handler_enabled() { + return _nfc_manager_is_system_handler_enabled() != 0; + } + + late final _nfc_manager_is_system_handler_enabled_ptr = + _lookup>( + 'nfc_manager_is_system_handler_enabled'); + late final _dart_nfc_manager_is_system_handler_enabled + _nfc_manager_is_system_handler_enabled = + _nfc_manager_is_system_handler_enabled_ptr + .asFunction<_dart_nfc_manager_is_system_handler_enabled>(); + + /// @brief Sets the card emulation Secure Element type + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// @remarks Security level can be determined by the manufacturer usage.\n + /// If a security issue is occurred, contact with the manufacturer of the product.\n + /// If you want to know about security level in detail, See the GSMA specification.\n + /// (http://www.gsma.com/digitalcommerce/wp-content/uploads/2013/12/GSMA-NFC05-NFC-Handset-APIs-Requirement-Specification-version-4-1.pdf) + /// + /// @param [in] type The type of Secure Element + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_PERMISSION_DENIED Security restricted by SMACK + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_SECURITY_RESTRICTED Security restricted by Access Control + /// @retval #NFC_ERROR_ILLEGAL_STATE Illegal state + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @see nfc_manager_initialize() + int nfc_manager_set_se_type( + int type, + ) { + return _nfc_manager_set_se_type( + type, + ); + } + + late final _nfc_manager_set_se_type_ptr = + _lookup>( + 'nfc_manager_set_se_type'); + late final _dart_nfc_manager_set_se_type _nfc_manager_set_se_type = + _nfc_manager_set_se_type_ptr.asFunction<_dart_nfc_manager_set_se_type>(); + + /// @brief Gets the card emulation Secure Element type + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_MANAGER_MODULE + /// + /// @param [out] type The type of Secure Element + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_PERMISSION_DENIED Security restricted by SMACK + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @see nfc_manager_initialize() + int nfc_manager_get_se_type( + ffi.Pointer type, + ) { + return _nfc_manager_get_se_type( + type, + ); + } + + late final _nfc_manager_get_se_type_ptr = + _lookup>( + 'nfc_manager_get_se_type'); + late final _dart_nfc_manager_get_se_type _nfc_manager_get_se_type = + _nfc_manager_get_se_type_ptr.asFunction<_dart_nfc_manager_get_se_type>(); + + /// @brief Creates a record with given parameter value. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// + /// @remarks Every data buffer is deeply copied.\n + /// Every data is a byte array(binary data). + /// + /// @param [out] record A handle to record + /// @param [in] tnf The type name format + /// @param [in] type The specified type name + /// @param [in] type_size The byte size of type + /// @param [in] id The record ID + /// @param [in] id_size The byte size of ID + /// @param [in] payload The payload of this record + /// @param [in] payload_size The byte size of payload + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see nfc_ndef_record_create_text() + /// @see nfc_ndef_record_create_uri() + /// @see nfc_ndef_record_create_mime() + /// @see nfc_ndef_record_destroy() + /// @see nfc_manager_initialize() + int nfc_ndef_record_create( + ffi.Pointer> record, + int tnf, + ffi.Pointer type, + int type_size, + ffi.Pointer id, + int id_size, + ffi.Pointer payload, + int payload_size, + ) { + return _nfc_ndef_record_create( + record, + tnf, + type, + type_size, + id, + id_size, + payload, + payload_size, + ); + } + + late final _nfc_ndef_record_create_ptr = + _lookup>( + 'nfc_ndef_record_create'); + late final _dart_nfc_ndef_record_create _nfc_ndef_record_create = + _nfc_ndef_record_create_ptr.asFunction<_dart_nfc_ndef_record_create>(); + + /// @brief Creates a record with text type payload + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// + /// @remarks This function does not encode the text. @a text will be assumed as that it is already encoded with encode type.\n + /// The text buffer will be deeply copied.\n + /// The record is created in this format\n + /// - TNF : NFC_RECORD_TNF_WELL_KNOWN\n + /// - type : "T"\n + /// - payload : encode and header information + language code + text \n + /// Defined in Record Type Definition Technical Specifications. + /// + /// @param [out] record A handle to record + /// @param [in] text The encoded text + /// @param [in] lang_code The language code string value followed by IANA[RFC 3066] (ex: en-US, ko-KR) + /// @param [in] encode The encoding type + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see nfc_ndef_record_create() + /// @see nfc_ndef_record_create_uri() + /// @see nfc_ndef_record_create_mime() + /// @see nfc_ndef_record_destroy() + /// @see nfc_ndef_record_get_text() + /// @see nfc_ndef_record_get_langcode() + /// @see nfc_ndef_record_get_encode_type() + /// @see nfc_manager_initialize() + int nfc_ndef_record_create_text( + ffi.Pointer> record, + ffi.Pointer text, + ffi.Pointer lang_code, + int encode, + ) { + return _nfc_ndef_record_create_text( + record, + text, + lang_code, + encode, + ); + } + + late final _nfc_ndef_record_create_text_ptr = + _lookup>( + 'nfc_ndef_record_create_text'); + late final _dart_nfc_ndef_record_create_text _nfc_ndef_record_create_text = + _nfc_ndef_record_create_text_ptr + .asFunction<_dart_nfc_ndef_record_create_text>(); + + /// @brief Creates a record with URI type payload + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// + /// @remarks The uri string will be deep copied.\n + /// The record is created in this format\n + /// - TNF : NFC_RECORD_TNF_WELL_KNOWN\n + /// - type : "U"\n + /// - payload : protocol scheme + uri\n + /// Defined in Record Type Definition Technical Specifications. + /// + /// @param [out] record A handle to record + /// @param [in] uri The URI string that will be stored in the payload + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see nfc_ndef_record_create() + /// @see nfc_ndef_record_create_text() + /// @see nfc_ndef_record_create_mime() + /// @see nfc_ndef_record_destroy() + /// @see nfc_ndef_record_get_uri() + /// @see nfc_manager_initialize() + int nfc_ndef_record_create_uri( + ffi.Pointer> record, + ffi.Pointer uri, + ) { + return _nfc_ndef_record_create_uri( + record, + uri, + ); + } + + late final _nfc_ndef_record_create_uri_ptr = + _lookup>( + 'nfc_ndef_record_create_uri'); + late final _dart_nfc_ndef_record_create_uri _nfc_ndef_record_create_uri = + _nfc_ndef_record_create_uri_ptr + .asFunction<_dart_nfc_ndef_record_create_uri>(); + + /// @brief Creates a record with MIME type payload + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// + /// @remarks The data buffer will be deep copied.\n + /// The data are bytes array(binary data).\n + /// The mime_type string will deep copied.\n + /// The record is created in this format\n + /// - TNF : NFC_RECORD_TNF_MIME_MEDIA\n + /// - type : mime type\n + /// - payload : data\n + /// Defined in Record Type Definition Technical Specifications. + /// + /// @param [out] record A handle to record + /// @param [in] mime_type The mime type [RFC 2046] (ex. text/plain, image/jpeg ) This value is stored in type field + /// @param [in] data The pointer of data + /// @param [in] data_size The size of data + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see nfc_ndef_record_create() + /// @see nfc_ndef_record_create_uri() + /// @see nfc_ndef_record_create_text() + /// @see nfc_ndef_record_destroy() + /// @see nfc_ndef_record_get_mime_type() + /// @see nfc_manager_initialize() + int nfc_ndef_record_create_mime( + ffi.Pointer> record, + ffi.Pointer mime_type, + ffi.Pointer data, + int data_size, + ) { + return _nfc_ndef_record_create_mime( + record, + mime_type, + data, + data_size, + ); + } + + late final _nfc_ndef_record_create_mime_ptr = + _lookup>( + 'nfc_ndef_record_create_mime'); + late final _dart_nfc_ndef_record_create_mime _nfc_ndef_record_create_mime = + _nfc_ndef_record_create_mime_ptr + .asFunction<_dart_nfc_ndef_record_create_mime>(); + + /// @brief Destroys the record handle + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// + /// @param [in] record The handle to record + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_ndef_record_create() + /// @see nfc_ndef_record_create_text() + /// @see nfc_ndef_record_create_uri() + /// @see nfc_ndef_record_create_mime() + /// @see nfc_manager_initialize() + int nfc_ndef_record_destroy( + ffi.Pointer<_ndef_record_s> record, + ) { + return _nfc_ndef_record_destroy( + record, + ); + } + + late final _nfc_ndef_record_destroy_ptr = + _lookup>( + 'nfc_ndef_record_destroy'); + late final _dart_nfc_ndef_record_destroy _nfc_ndef_record_destroy = + _nfc_ndef_record_destroy_ptr.asFunction<_dart_nfc_ndef_record_destroy>(); + + /// @brief Sets record ID + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// + /// @remarks The ID buffer are deep copied. + /// + /// @param [in] record The handle to record + /// @param [in] id The record ID + /// @param [in] id_size The size of ID in bytes + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_ndef_record_get_id() + /// @see nfc_manager_initialize() + int nfc_ndef_record_set_id( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer id, + int id_size, + ) { + return _nfc_ndef_record_set_id( + record, + id, + id_size, + ); + } + + late final _nfc_ndef_record_set_id_ptr = + _lookup>( + 'nfc_ndef_record_set_id'); + late final _dart_nfc_ndef_record_set_id _nfc_ndef_record_set_id = + _nfc_ndef_record_set_id_ptr.asFunction<_dart_nfc_ndef_record_set_id>(); + + /// @brief Gets record ID + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// + /// @remarks It may return NULL pointer if the ID is not exist\n + /// This function gives you the pointer of ID that is contained by record\n + /// Do not free the ID. It will be released when @a record is destroyed by nfc_ndef_record_destroy(). + /// + /// @param [in] record The handle to record + /// @param [out] id The record ID ( do not free ) + /// @param [out] size The size of ID in bytes + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_ndef_record_set_id() + /// @see nfc_manager_initialize() + int nfc_ndef_record_get_id( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> id, + ffi.Pointer size, + ) { + return _nfc_ndef_record_get_id( + record, + id, + size, + ); + } + + late final _nfc_ndef_record_get_id_ptr = + _lookup>( + 'nfc_ndef_record_get_id'); + late final _dart_nfc_ndef_record_get_id _nfc_ndef_record_get_id = + _nfc_ndef_record_get_id_ptr.asFunction<_dart_nfc_ndef_record_get_id>(); + + /// @brief Gets record payload. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// + /// @remarks This function gives you the pointer of payload that is contained by record\n + /// Do not free the payload. it will be freed when @a record is destroyed by nfc_ndef_record_destroy(). + /// + /// @param [in] record The handle to record + /// @param [out] payload The payload ( do not free this pointer ) + /// @param [out] size the size of payload in byte + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_manager_initialize() + int nfc_ndef_record_get_payload( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> payload, + ffi.Pointer size, + ) { + return _nfc_ndef_record_get_payload( + record, + payload, + size, + ); + } + + late final _nfc_ndef_record_get_payload_ptr = + _lookup>( + 'nfc_ndef_record_get_payload'); + late final _dart_nfc_ndef_record_get_payload _nfc_ndef_record_get_payload = + _nfc_ndef_record_get_payload_ptr + .asFunction<_dart_nfc_ndef_record_get_payload>(); + + /// @brief Gets record type. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// + /// @remarks This function gives you the pointer of type that is contained by record.\n + /// Do not free the type. it will be freed when the record is freed. + /// + /// @param [in] record The handle to record + /// @param [out] type The record type ( do not free this pointer ) + /// @param [out] size The size of type in byte + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_manager_initialize() + int nfc_ndef_record_get_type( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> type, + ffi.Pointer size, + ) { + return _nfc_ndef_record_get_type( + record, + type, + size, + ); + } + + late final _nfc_ndef_record_get_type_ptr = + _lookup>( + 'nfc_ndef_record_get_type'); + late final _dart_nfc_ndef_record_get_type _nfc_ndef_record_get_type = + _nfc_ndef_record_get_type_ptr + .asFunction<_dart_nfc_ndef_record_get_type>(); + + /// @brief Gets record TNF(Type Name Format) value. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// + /// @param [in] record The handle to record + /// @param [out] tnf The TNF(Type Name Format) value + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_manager_initialize() + int nfc_ndef_record_get_tnf( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer tnf, + ) { + return _nfc_ndef_record_get_tnf( + record, + tnf, + ); + } + + late final _nfc_ndef_record_get_tnf_ptr = + _lookup>( + 'nfc_ndef_record_get_tnf'); + late final _dart_nfc_ndef_record_get_tnf _nfc_ndef_record_get_tnf = + _nfc_ndef_record_get_tnf_ptr.asFunction<_dart_nfc_ndef_record_get_tnf>(); + + /// @brief Gets text from text record + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// + /// @remarks This function returns newly allocated string, this value must be deallocated by caller.\n + /// This function is valid only for text type record.\n + /// The text type record 's tnf is NFC_RECORD_TNF_WELL_KNOWN and it's type is "T" + /// + /// @param [in] record The handle to record + /// @param [out] text The text in record payload ( should be freed by caller ) + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_INVALID_RECORD_TYPE Invalid record type + /// + /// @see nfc_ndef_record_create_text() + /// @see nfc_manager_initialize() + int nfc_ndef_record_get_text( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> text, + ) { + return _nfc_ndef_record_get_text( + record, + text, + ); + } + + late final _nfc_ndef_record_get_text_ptr = + _lookup>( + 'nfc_ndef_record_get_text'); + late final _dart_nfc_ndef_record_get_text _nfc_ndef_record_get_text = + _nfc_ndef_record_get_text_ptr + .asFunction<_dart_nfc_ndef_record_get_text>(); + + /// @brief Gets language code from text record + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// @remarks This function returns newly allocated string, this value must be deallocated by caller.\n + /// This function is valid only for text type record.\n + /// The text type record 's tnf is NFC_RECORD_TNF_WELL_KNOWN and it's type is "T" + /// + /// @param [in] record The handle to record + /// @param [out] lang_code lang code ( should be freed by caller ) + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_INVALID_RECORD_TYPE Invalid record type + /// + /// @see nfc_ndef_record_create_text() + /// @see nfc_manager_initialize() + int nfc_ndef_record_get_langcode( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> lang_code, + ) { + return _nfc_ndef_record_get_langcode( + record, + lang_code, + ); + } + + late final _nfc_ndef_record_get_langcode_ptr = + _lookup>( + 'nfc_ndef_record_get_langcode'); + late final _dart_nfc_ndef_record_get_langcode _nfc_ndef_record_get_langcode = + _nfc_ndef_record_get_langcode_ptr + .asFunction<_dart_nfc_ndef_record_get_langcode>(); + + /// @brief Gets encoding type from text record + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// + /// @remarks This function is valid only for text type record.\n + /// The text type record 's tnf is NFC_RECORD_TNF_WELL_KNOWN and it's type is "T" + /// + /// @param [in] record The handle to record + /// @param [out] encode encode type #nfc_encode_type_e + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_INVALID_RECORD_TYPE Invalid record type + /// + /// @see nfc_ndef_record_create_text() + /// @see nfc_manager_initialize() + int nfc_ndef_record_get_encode_type( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer encode, + ) { + return _nfc_ndef_record_get_encode_type( + record, + encode, + ); + } + + late final _nfc_ndef_record_get_encode_type_ptr = + _lookup>( + 'nfc_ndef_record_get_encode_type'); + late final _dart_nfc_ndef_record_get_encode_type + _nfc_ndef_record_get_encode_type = _nfc_ndef_record_get_encode_type_ptr + .asFunction<_dart_nfc_ndef_record_get_encode_type>(); + + /// @brief Gets URI from uri record + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// + /// @remarks The function returns newly allocated string, this value must be deallocated by caller.\n + /// This function is valid only for uri type record. + /// The uri type record 's tnf is NFC_RECORD_TNF_WELL_KNOWN and it's type is "U" + /// + /// @param [in] record The handle to record + /// @param [out] uri The uri in record payload ( should be freed by caller ) + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_INVALID_RECORD_TYPE Invalid record type + /// + /// @see nfc_ndef_record_create_uri() + /// @see nfc_manager_initialize() + int nfc_ndef_record_get_uri( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> uri, + ) { + return _nfc_ndef_record_get_uri( + record, + uri, + ); + } + + late final _nfc_ndef_record_get_uri_ptr = + _lookup>( + 'nfc_ndef_record_get_uri'); + late final _dart_nfc_ndef_record_get_uri _nfc_ndef_record_get_uri = + _nfc_ndef_record_get_uri_ptr.asFunction<_dart_nfc_ndef_record_get_uri>(); + + /// @brief Gets mime type from mime type record + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_RECORD_MODULE + /// + /// @remarks The function returns newly allocated string, this value must be deallocated by caller.\n + /// This function is valid only for mime type record.\n + /// The uri type record 's tnf is NFC_RECORD_TNF_MIME_MEDIA. + /// + /// @param [in] record The handle to record + /// @param [out] mime_type The mime type in record payload ( should be freed by caller ) + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_INVALID_RECORD_TYPE Invalid record type + /// + /// @see nfc_ndef_record_create_mime() + /// @see nfc_manager_initialize() + int nfc_ndef_record_get_mime_type( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> mime_type, + ) { + return _nfc_ndef_record_get_mime_type( + record, + mime_type, + ); + } + + late final _nfc_ndef_record_get_mime_type_ptr = + _lookup>( + 'nfc_ndef_record_get_mime_type'); + late final _dart_nfc_ndef_record_get_mime_type + _nfc_ndef_record_get_mime_type = _nfc_ndef_record_get_mime_type_ptr + .asFunction<_dart_nfc_ndef_record_get_mime_type>(); + + /// @brief Creates NDEF message handle + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_MESSAGE_MODULE + /// + /// @param [out] ndef_message A handle to NDEF message + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see nfc_ndef_message_create_from_rawdata() + /// @see nfc_ndef_message_destroy() + /// @see nfc_manager_initialize() + int nfc_ndef_message_create( + ffi.Pointer> ndef_message, + ) { + return _nfc_ndef_message_create( + ndef_message, + ); + } + + late final _nfc_ndef_message_create_ptr = + _lookup>( + 'nfc_ndef_message_create'); + late final _dart_nfc_ndef_message_create _nfc_ndef_message_create = + _nfc_ndef_message_create_ptr.asFunction<_dart_nfc_ndef_message_create>(); + + /// @brief Creates NDEF message handle from raw serial bytes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_MESSAGE_MODULE + /// + /// @remarks It consumes the bytes array until get the ME(Message End) flag*. It returns error if the bytes array does not have ME flag.\n + /// *The ME flag is a 1-bit field that when set indicates the end of an NDEF message. + /// + /// @param [out] ndef_message The handle to NDEF message + /// @param [in] rawdata The NDEF message in form of bytes array + /// @param [in] rawdata_size The size of bytes array + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see nfc_ndef_message_create() + /// @see nfc_ndef_message_destroy() + /// @see nfc_ndef_message_get_rawdata() + /// @see nfc_manager_initialize() + int nfc_ndef_message_create_from_rawdata( + ffi.Pointer> ndef_message, + ffi.Pointer rawdata, + int rawdata_size, + ) { + return _nfc_ndef_message_create_from_rawdata( + ndef_message, + rawdata, + rawdata_size, + ); + } + + late final _nfc_ndef_message_create_from_rawdata_ptr = + _lookup>( + 'nfc_ndef_message_create_from_rawdata'); + late final _dart_nfc_ndef_message_create_from_rawdata + _nfc_ndef_message_create_from_rawdata = + _nfc_ndef_message_create_from_rawdata_ptr + .asFunction<_dart_nfc_ndef_message_create_from_rawdata>(); + + /// @brief Destroys NDEF message handle + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_MESSAGE_MODULE + /// + /// @remarks This function will free all these memory including record handles. + /// + /// @param [in] ndef_message The handle to NDEF message to destroy + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_ndef_message_create() + /// @see nfc_ndef_message_create_from_rawdata() + /// @see nfc_manager_initialize() + int nfc_ndef_message_destroy( + ffi.Pointer<_ndef_message_s> ndef_message, + ) { + return _nfc_ndef_message_destroy( + ndef_message, + ); + } + + late final _nfc_ndef_message_destroy_ptr = + _lookup>( + 'nfc_ndef_message_destroy'); + late final _dart_nfc_ndef_message_destroy _nfc_ndef_message_destroy = + _nfc_ndef_message_destroy_ptr + .asFunction<_dart_nfc_ndef_message_destroy>(); + + /// @brief Gets the number of record in NDEF message + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_MESSAGE_MODULE + /// + /// @param [in] ndef_message The handle to NDEF message + /// @param [out] count The number of record + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_manager_initialize() + int nfc_ndef_message_get_record_count( + ffi.Pointer<_ndef_message_s> ndef_message, + ffi.Pointer count, + ) { + return _nfc_ndef_message_get_record_count( + ndef_message, + count, + ); + } + + late final _nfc_ndef_message_get_record_count_ptr = + _lookup>( + 'nfc_ndef_message_get_record_count'); + late final _dart_nfc_ndef_message_get_record_count + _nfc_ndef_message_get_record_count = + _nfc_ndef_message_get_record_count_ptr + .asFunction<_dart_nfc_ndef_message_get_record_count>(); + + /// @brief Gets serial bytes array of NDEF message. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_MESSAGE_MODULE + /// + /// @remarks It gets copy of the bytes array from NDEF message. @a rawdata must be released with free() by you. + /// + /// @param [in] ndef_message The handle to NDEF message + /// @param [out] rawdata The bytes array of bytes array + /// @param [out] rawdata_size The size of bytes array in byte + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_NDEF_MESSAGE Invalid NDEF message + /// + /// @see nfc_ndef_message_create_from_rawdata() + /// @see nfc_manager_initialize() + int nfc_ndef_message_get_rawdata( + ffi.Pointer<_ndef_message_s> ndef_message, + ffi.Pointer> rawdata, + ffi.Pointer rawdata_size, + ) { + return _nfc_ndef_message_get_rawdata( + ndef_message, + rawdata, + rawdata_size, + ); + } + + late final _nfc_ndef_message_get_rawdata_ptr = + _lookup>( + 'nfc_ndef_message_get_rawdata'); + late final _dart_nfc_ndef_message_get_rawdata _nfc_ndef_message_get_rawdata = + _nfc_ndef_message_get_rawdata_ptr + .asFunction<_dart_nfc_ndef_message_get_rawdata>(); + + /// @brief Appends a record into NDEF message + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_MESSAGE_MODULE + /// + /// @remarks Appended record is handled by frameworks. The record is released by frameworks when message is released. + /// + /// @param [in] ndef_message The handle to NDEF message + /// @param [in] record The record that will be appended into NDEF message + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_ndef_message_insert_record() + /// @see nfc_ndef_message_remove_record() + /// @see nfc_manager_initialize() + int nfc_ndef_message_append_record( + ffi.Pointer<_ndef_message_s> ndef_message, + ffi.Pointer<_ndef_record_s> record, + ) { + return _nfc_ndef_message_append_record( + ndef_message, + record, + ); + } + + late final _nfc_ndef_message_append_record_ptr = + _lookup>( + 'nfc_ndef_message_append_record'); + late final _dart_nfc_ndef_message_append_record + _nfc_ndef_message_append_record = _nfc_ndef_message_append_record_ptr + .asFunction<_dart_nfc_ndef_message_append_record>(); + + /// @brief Inserts a record at index into NDEF message + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_MESSAGE_MODULE + /// + /// @remarks Appended record is handled by frameworks. The record is released by frameworks when message is released.\n + /// The index value should not bigger than nfc_ndef_message_get_record_count() + /// + /// @param [in] ndef_message The handle to NDEF message + /// @param [in] index The index of record ( starts from 0 ) + /// @param [in] record The record that will be appended into NDEF message + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_INVALID_NDEF_MESSAGE Invalid NDEF message + /// + /// @see nfc_ndef_message_append_record() + /// @see nfc_ndef_message_remove_record() + /// @see nfc_manager_initialize() + int nfc_ndef_message_insert_record( + ffi.Pointer<_ndef_message_s> ndef_message, + int index, + ffi.Pointer<_ndef_record_s> record, + ) { + return _nfc_ndef_message_insert_record( + ndef_message, + index, + record, + ); + } + + late final _nfc_ndef_message_insert_record_ptr = + _lookup>( + 'nfc_ndef_message_insert_record'); + late final _dart_nfc_ndef_message_insert_record + _nfc_ndef_message_insert_record = _nfc_ndef_message_insert_record_ptr + .asFunction<_dart_nfc_ndef_message_insert_record>(); + + /// @brief Removes the record that indicated by index number and this deleted record will be freed. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_MESSAGE_MODULE + /// + /// @param [in] ndef_message The handle to NDEF message + /// @param [in] index The index of record ( starts from 0 ) + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_INVALID_NDEF_MESSAGE Invalid NDEF message + /// + /// @see nfc_ndef_message_append_record() + /// @see nfc_ndef_message_insert_record() + /// @see nfc_manager_initialize() + int nfc_ndef_message_remove_record( + ffi.Pointer<_ndef_message_s> ndef_message, + int index, + ) { + return _nfc_ndef_message_remove_record( + ndef_message, + index, + ); + } + + late final _nfc_ndef_message_remove_record_ptr = + _lookup>( + 'nfc_ndef_message_remove_record'); + late final _dart_nfc_ndef_message_remove_record + _nfc_ndef_message_remove_record = _nfc_ndef_message_remove_record_ptr + .asFunction<_dart_nfc_ndef_message_remove_record>(); + + /// @brief Gets record by index. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_NDEF_MESSAGE_MODULE + /// + /// @remarks This function just return the pointer of record. if you change the record value it directly affects the NDEF message + /// + /// @param [in] ndef_message The handle to NDEF message + /// @param [in] index The index of record ( starts from 0 ) + /// @param [out] record The handle to record + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_manager_initialize() + int nfc_ndef_message_get_record( + ffi.Pointer<_ndef_message_s> ndef_message, + int index, + ffi.Pointer> record, + ) { + return _nfc_ndef_message_get_record( + ndef_message, + index, + record, + ); + } + + late final _nfc_ndef_message_get_record_ptr = + _lookup>( + 'nfc_ndef_message_get_record'); + late final _dart_nfc_ndef_message_get_record _nfc_ndef_message_get_record = + _nfc_ndef_message_get_record_ptr + .asFunction<_dart_nfc_ndef_message_get_record>(); + + /// @brief Gets the type of NFC tag + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_TAG_MODULE + /// + /// @param [in] tag The handle to NFC tag + /// @param [out] type The type of NFC tag + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @see nfc_manager_initialize() + int nfc_tag_get_type( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer type, + ) { + return _nfc_tag_get_type( + tag, + type, + ); + } + + late final _nfc_tag_get_type_ptr = + _lookup>('nfc_tag_get_type'); + late final _dart_nfc_tag_get_type _nfc_tag_get_type = + _nfc_tag_get_type_ptr.asFunction<_dart_nfc_tag_get_type>(); + + /// @brief Checks whether the given NFC tag supports NDEF messages. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_TAG_MODULE + /// + /// @param [in] tag The handle to NFC tag + /// @param [out] is_supported @c true when NFC tag supports NDEF messages, otherwise @c false + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_tag_read_ndef() + /// @see nfc_manager_initialize() + int nfc_tag_is_support_ndef( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer is_supported, + ) { + return _nfc_tag_is_support_ndef( + tag, + is_supported, + ); + } + + late final _nfc_tag_is_support_ndef_ptr = + _lookup>( + 'nfc_tag_is_support_ndef'); + late final _dart_nfc_tag_is_support_ndef _nfc_tag_is_support_ndef = + _nfc_tag_is_support_ndef_ptr.asFunction<_dart_nfc_tag_is_support_ndef>(); + + /// @brief Gets the maximum NDEF message size that can be stored in NFC tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_TAG_MODULE + /// + /// @remarks This max size indicates the maximum size of NDEF message that can be stored in this detected tag. + /// + /// @param [in] tag The handle to NFC tag + /// @param [out] maximum_ndef_bytes_size The maximum bytes size of NDEF message that can be stored in this detected tag. + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_manager_initialize() + int nfc_tag_get_maximum_ndef_size( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer maximum_ndef_bytes_size, + ) { + return _nfc_tag_get_maximum_ndef_size( + tag, + maximum_ndef_bytes_size, + ); + } + + late final _nfc_tag_get_maximum_ndef_size_ptr = + _lookup>( + 'nfc_tag_get_maximum_ndef_size'); + late final _dart_nfc_tag_get_maximum_ndef_size + _nfc_tag_get_maximum_ndef_size = _nfc_tag_get_maximum_ndef_size_ptr + .asFunction<_dart_nfc_tag_get_maximum_ndef_size>(); + + /// @brief Gets size of NDEF message that stored in the tag + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_TAG_MODULE + /// + /// @param [in] tag The handle to NFC tag + /// @param [out] ndef_bytes_size The NDEF message bytes size that stored in the tag + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_manager_initialize() + int nfc_tag_get_ndef_size( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer ndef_bytes_size, + ) { + return _nfc_tag_get_ndef_size( + tag, + ndef_bytes_size, + ); + } + + late final _nfc_tag_get_ndef_size_ptr = + _lookup>( + 'nfc_tag_get_ndef_size'); + late final _dart_nfc_tag_get_ndef_size _nfc_tag_get_ndef_size = + _nfc_tag_get_ndef_size_ptr.asFunction<_dart_nfc_tag_get_ndef_size>(); + + /// @brief Retrieves all tag information + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_TAG_MODULE + /// + /// @param[in] tag The handle to NFC tag + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see nfc_manager_initialize() + int nfc_tag_foreach_information( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_tag_foreach_information( + tag, + callback, + user_data, + ); + } + + late final _nfc_tag_foreach_information_ptr = + _lookup>( + 'nfc_tag_foreach_information'); + late final _dart_nfc_tag_foreach_information _nfc_tag_foreach_information = + _nfc_tag_foreach_information_ptr + .asFunction<_dart_nfc_tag_foreach_information>(); + + /// @brief Transceives the data of the raw format card. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @details This function is the only way to access the raw format card (not formated), + /// each tag type requires own command to access tags. \n + /// This function provides the low level access of tag operation and you require the knowledge of each tag technology. + /// @ingroup CAPI_NETWORK_NFC_TAG_MODULE + /// + /// @param [in] tag The handle to NFC tag + /// @param [in] buffer The binary data for parameter or additional commands + /// @param [in] buffer_size The size of buffer in bytes + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if a notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_TIMED_OUT Timeout is reached while communicating with tag + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @post It invokes nfc_tag_transceive_completed_cb() when it has completed to transceive data.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_tag_read_ndef() + /// @see nfc_tag_is_support_ndef() + /// @see nfc_manager_initialize() + int nfc_tag_transceive( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer buffer, + int buffer_size, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_tag_transceive( + tag, + buffer, + buffer_size, + callback, + user_data, + ); + } + + late final _nfc_tag_transceive_ptr = + _lookup>('nfc_tag_transceive'); + late final _dart_nfc_tag_transceive _nfc_tag_transceive = + _nfc_tag_transceive_ptr.asFunction<_dart_nfc_tag_transceive>(); + + /// @brief Reads NDEF formatted data from NFC tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @ingroup CAPI_NETWORK_NFC_TAG_MODULE + /// + /// @param [in] tag The handle to NFC tag + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_TIMED_OUT Timeout is reached while communicating with tag + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_NOT_NDEF_FORMAT Not ndef format tag + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @post It invokes nfc_tag_read_completed_cb() when it has completed to read NDEF formatted data.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_tag_transceive() + /// @see nfc_tag_is_support_ndef() + /// @see nfc_tag_write_ndef() + /// @see nfc_manager_initialize() + int nfc_tag_read_ndef( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_tag_read_ndef( + tag, + callback, + user_data, + ); + } + + late final _nfc_tag_read_ndef_ptr = + _lookup>('nfc_tag_read_ndef'); + late final _dart_nfc_tag_read_ndef _nfc_tag_read_ndef = + _nfc_tag_read_ndef_ptr.asFunction<_dart_nfc_tag_read_ndef>(); + + /// @brief Writes NDEF formatted data. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @ingroup CAPI_NETWORK_NFC_TAG_MODULE + /// + /// @param [in] tag The handle to NFC tag + /// @param [in] msg The message will be write to the tag + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_TIMED_OUT Timeout is reached while communicating with tag + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_NOT_NDEF_FORMAT Not ndef format tag + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @post It invokes nfc_tag_write_completed_cb() when it has completed to write NDEF data.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_tag_is_support_ndef() + /// @see nfc_tag_read_ndef() + /// @see nfc_manager_initialize() + int nfc_tag_write_ndef( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer<_ndef_message_s> msg, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_tag_write_ndef( + tag, + msg, + callback, + user_data, + ); + } + + late final _nfc_tag_write_ndef_ptr = + _lookup>('nfc_tag_write_ndef'); + late final _dart_nfc_tag_write_ndef _nfc_tag_write_ndef = + _nfc_tag_write_ndef_ptr.asFunction<_dart_nfc_tag_write_ndef>(); + + /// @brief Formats the detected tag that can store NDEF message. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @details Some tags are required authentication. If the detected target doesn't need authentication, @a key can be NULL. + /// @ingroup CAPI_NETWORK_NFC_TAG_MODULE + /// + /// @param [in] tag The handle to NFC tag + /// @param [in] key The key value that may need to format the tag + /// @param [in] key_size The size of key in byte + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_TIMED_OUT Timeout is reached while communicating with tag + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_NOT_NDEF_FORMAT Not ndef format tag + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @post It invokes nfc_tag_format_completed_cb() when it has completed to format the NFC tag.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_tag_is_support_ndef() + /// @see nfc_manager_initialize() + int nfc_tag_format_ndef( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer key, + int key_size, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_tag_format_ndef( + tag, + key, + key_size, + callback, + user_data, + ); + } + + late final _nfc_tag_format_ndef_ptr = + _lookup>( + 'nfc_tag_format_ndef'); + late final _dart_nfc_tag_format_ndef _nfc_tag_format_ndef = + _nfc_tag_format_ndef_ptr.asFunction<_dart_nfc_tag_format_ndef>(); + + /// @ingroup CAPI_NETWORK_NFC_TAG_MIFARE_MODULE + /// @brief Authenticates a sector with key A. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @remarks I/O operations(read / write / increment / decrement / transfer / restore) will be available after successful authentication.\n + /// This function is only available for MIFARE classic.\n + /// \n + /// MIFARE CLASSIC MINI \n + /// => 0 ~ 4 : 5 sectors having 4 block each with block size of 16 bytes \n + /// \n + /// MIFARE CLASSIC 1K \n + /// => 0 ~ 15 : 16 sectors having 4 block each with block size of 16 bytes \n + /// \n + /// MIFARE CLASSIC 4K \n + /// => 0 ~ 31 : 32 sectors having 4 block each with block size of 16 bytes \n + /// => 32 ~ 39 : 8 sectors having 16 block each with block size of 16 bytes + /// + /// @param[in] tag The handle to NFC tag + /// @param[in] sector_index The index of sector to authenticate with key A, starting from 0 + /// @param[in] auth_key 6-byte authentication key + /// @param[in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_TIMED_OUT Timeout is reached while communicating with tag + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @post It invokes nfc_mifare_authenticate_with_keyA_completed_cb() when it has completed to authenticate the given sector with key A.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_mifare_authenticate_with_keyB() + /// @see nfc_mifare_read_block() + /// @see nfc_mifare_read_page() + /// @see nfc_mifare_write_block() + /// @see nfc_mifare_write_page() + /// @see nfc_mifare_increment() + /// @see nfc_mifare_decrement() + /// @see nfc_manager_initialize() + int nfc_mifare_authenticate_with_keyA( + ffi.Pointer<_net_nfc_target_info_s> tag, + int sector_index, + ffi.Pointer auth_key, + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, + ) { + return _nfc_mifare_authenticate_with_keyA( + tag, + sector_index, + auth_key, + callback, + user_data, + ); + } + + late final _nfc_mifare_authenticate_with_keyA_ptr = + _lookup>( + 'nfc_mifare_authenticate_with_keyA'); + late final _dart_nfc_mifare_authenticate_with_keyA + _nfc_mifare_authenticate_with_keyA = + _nfc_mifare_authenticate_with_keyA_ptr + .asFunction<_dart_nfc_mifare_authenticate_with_keyA>(); + + /// @ingroup CAPI_NETWORK_NFC_TAG_MIFARE_MODULE + /// @brief Authenticates a sector with key B. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @remarks I/O operations(read / write / increment / decrement / transfer / restore) will be available after successful authentication.\n + /// This function is only available for MIFARE classic.\n + /// \n + /// MIFARE CLASSIC MINI\n + /// => 0 ~ 4 : 5 sector and 4 block with 16 bytes\n + /// \n + /// MIFARE CLASSIC 1K \n + /// => 0 ~ 15 : 16 sector and 4 block with 16 bytes\n + /// \n + /// MIFARE CLASSIC 4K\n + /// => 0 ~ 31 : 32 sector and 4 block with 16 bytes \n + /// => 32 ~ 39 : 8 sector and 16 block with 16 bytes + /// + /// @param [in] tag The handle to NFC tag + /// @param [in] sector_index The index of sector to authenticate with key B, starting from 0 + /// @param [in] auth_key 6-byte authentication key + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_TIMED_OUT Timeout is reached while communicating with tag + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @post It invokes nfc_mifare_authenticate_with_keyB_completed_cb() when it has completed to authenticate the given sector with key B.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_mifare_authenticate_with_keyA() + /// @see nfc_mifare_read_block() + /// @see nfc_mifare_read_page() + /// @see nfc_mifare_write_block() + /// @see nfc_mifare_write_page() + /// @see nfc_mifare_increment() + /// @see nfc_mifare_decrement() + /// @see nfc_manager_initialize() + int nfc_mifare_authenticate_with_keyB( + ffi.Pointer<_net_nfc_target_info_s> tag, + int sector_index, + ffi.Pointer auth_key, + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, + ) { + return _nfc_mifare_authenticate_with_keyB( + tag, + sector_index, + auth_key, + callback, + user_data, + ); + } + + late final _nfc_mifare_authenticate_with_keyB_ptr = + _lookup>( + 'nfc_mifare_authenticate_with_keyB'); + late final _dart_nfc_mifare_authenticate_with_keyB + _nfc_mifare_authenticate_with_keyB = + _nfc_mifare_authenticate_with_keyB_ptr + .asFunction<_dart_nfc_mifare_authenticate_with_keyB>(); + + /// @ingroup CAPI_NETWORK_NFC_TAG_MIFARE_MODULE + /// @brief Reads a 16-byte block. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @remarks This function is only available for MIFARE classic. + /// + /// @param [in] tag The handle to NFC tag + /// @param [in] block_index The block or starting page number + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_TIMED_OUT Timeout is reached while communicating with tag + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @post It invokes nfc_mifare_read_block_completed_cb() when it has completed to read a block.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_mifare_read_page() + /// @see nfc_mifare_write_block() + /// @see nfc_manager_initialize() + int nfc_mifare_read_block( + ffi.Pointer<_net_nfc_target_info_s> tag, + int block_index, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _nfc_mifare_read_block( + tag, + block_index, + callback, + user_data, + ); + } + + late final _nfc_mifare_read_block_ptr = + _lookup>( + 'nfc_mifare_read_block'); + late final _dart_nfc_mifare_read_block _nfc_mifare_read_block = + _nfc_mifare_read_block_ptr.asFunction<_dart_nfc_mifare_read_block>(); + + /// @ingroup CAPI_NETWORK_NFC_TAG_MIFARE_MODULE + /// @brief Reads 4 pages(16 bytes). + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @remarks This function is only available for MIFARE Ultra light.\n + /// The MIFARE Ultralight protocol always reads 4 pages at a time, to reduce the number of commands required to read an entire tag. + /// + /// @param [in] tag The handle to NFC tag + /// @param [in] page_index The index of page to read, starting from 0 + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_TIMED_OUT Timeout is reached while communicating with tag + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @post It invokes nfc_mifare_read_page_completed_cb() when it has completed to read a page.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_mifare_read_block() + /// @see nfc_mifare_write_page() + /// @see nfc_manager_initialize() + int nfc_mifare_read_page( + ffi.Pointer<_net_nfc_target_info_s> tag, + int page_index, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_mifare_read_page( + tag, + page_index, + callback, + user_data, + ); + } + + late final _nfc_mifare_read_page_ptr = + _lookup>( + 'nfc_mifare_read_page'); + late final _dart_nfc_mifare_read_page _nfc_mifare_read_page = + _nfc_mifare_read_page_ptr.asFunction<_dart_nfc_mifare_read_page>(); + + /// @ingroup CAPI_NETWORK_NFC_TAG_MIFARE_MODULE + /// @brief Writes block (16 byte) of data to the tag at a given block index. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @remarks This function is only available for MIFARE classic. + /// + /// @param [in] tag The handle to NFC tag + /// @param [in] block_index The index of block to read, starting from 0 + /// @param [in] buffer 16 bytes of data to write + /// @param [in] buffer_size The size of buffer in bytes + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_TIMED_OUT Timeout is reached while communicating with tag + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @post It invokes nfc_mifare_write_block_completed_cb() when it has completed to write a block.\n The Callback can receive error code when process is done. + /// + /// @see nfc_mifare_write_page() + /// @see nfc_mifare_read_block() + /// @see nfc_manager_initialize() + int nfc_mifare_write_block( + ffi.Pointer<_net_nfc_target_info_s> tag, + int block_index, + ffi.Pointer buffer, + int buffer_size, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _nfc_mifare_write_block( + tag, + block_index, + buffer, + buffer_size, + callback, + user_data, + ); + } + + late final _nfc_mifare_write_block_ptr = + _lookup>( + 'nfc_mifare_write_block'); + late final _dart_nfc_mifare_write_block _nfc_mifare_write_block = + _nfc_mifare_write_block_ptr.asFunction<_dart_nfc_mifare_write_block>(); + + /// @ingroup CAPI_NETWORK_NFC_TAG_MIFARE_MODULE + /// @brief Writes a page (4 bytes) of data to the tag at a given page index + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @remarks This function is only available for MIFARE Ultra light + /// + /// @param [in] tag The handle to NFC tag + /// @param [in] page_index The index of page to write, starting from 0 + /// @param [in] buffer 4 bytes of data to write + /// @param [in] buffer_size The size of buffer in bytes + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_TIMED_OUT Timeout is reached while communicating with tag + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @post It invokes nfc_mifare_write_page_completed_cb() when it has completed to write a page.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_mifare_write_block() + /// @see nfc_mifare_read_page() + /// @see nfc_manager_initialize() + int nfc_mifare_write_page( + ffi.Pointer<_net_nfc_target_info_s> tag, + int page_index, + ffi.Pointer buffer, + int buffer_size, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _nfc_mifare_write_page( + tag, + page_index, + buffer, + buffer_size, + callback, + user_data, + ); + } + + late final _nfc_mifare_write_page_ptr = + _lookup>( + 'nfc_mifare_write_page'); + late final _dart_nfc_mifare_write_page _nfc_mifare_write_page = + _nfc_mifare_write_page_ptr.asFunction<_dart_nfc_mifare_write_page>(); + + /// @ingroup CAPI_NETWORK_NFC_TAG_MIFARE_MODULE + /// @brief Increases a value block, storing the result in the temporary block on the tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @remarks This function is only available for MIFARE classic + /// + /// @param [in] tag The handle to NFC tag + /// @param [in] block_index The index of block to increase, starting from 0 + /// @param [in] value Non-negative to increment by + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_TIMED_OUT Timeout is reached while communicating with tag + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @post It invokes nfc_mifare_increment_completed_cb() when it has completed to increment.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_mifare_decrement() + /// @see nfc_mifare_write_block() + /// @see nfc_manager_initialize() + int nfc_mifare_increment( + ffi.Pointer<_net_nfc_target_info_s> tag, + int block_index, + int value, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_mifare_increment( + tag, + block_index, + value, + callback, + user_data, + ); + } + + late final _nfc_mifare_increment_ptr = + _lookup>( + 'nfc_mifare_increment'); + late final _dart_nfc_mifare_increment _nfc_mifare_increment = + _nfc_mifare_increment_ptr.asFunction<_dart_nfc_mifare_increment>(); + + /// @ingroup CAPI_NETWORK_NFC_TAG_MIFARE_MODULE + /// @brief Decreases a value block, storing the result in the temporary block on the tag. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @remarks This function is only available for MIFARE classic + /// + /// @param [in] tag The handle to NFC tag + /// @param [in] block_index The index of block to decrease, starting from 0 + /// @param [in] value non-negative to decrement by + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_TIMED_OUT Timeout is reached while communicating with tag + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @post It invokes nfc_mifare_decrement_completed_cb() when it has completed to decrement.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_mifare_increment() + /// @see nfc_mifare_write_block() + /// @see nfc_manager_initialize() + int nfc_mifare_decrement( + ffi.Pointer<_net_nfc_target_info_s> tag, + int block_index, + int value, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_mifare_decrement( + tag, + block_index, + value, + callback, + user_data, + ); + } + + late final _nfc_mifare_decrement_ptr = + _lookup>( + 'nfc_mifare_decrement'); + late final _dart_nfc_mifare_decrement _nfc_mifare_decrement = + _nfc_mifare_decrement_ptr.asFunction<_dart_nfc_mifare_decrement>(); + + /// @ingroup CAPI_NETWORK_NFC_TAG_MIFARE_MODULE + /// @brief Copy from the temporary block to the specified block. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @remarks This function is only available for MIFARE classic + /// + /// @param [in] tag The handle to NFC tag + /// @param [in] block_index The index of block to copy to, starting from 0 + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_TIMED_OUT Timeout is reached while communicating with tag + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @post It invokes nfc_mifare_transfer_completed_cb() when it has completed to transfer.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_mifare_restore() + /// @see nfc_manager_initialize() + int nfc_mifare_transfer( + ffi.Pointer<_net_nfc_target_info_s> tag, + int block_index, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_mifare_transfer( + tag, + block_index, + callback, + user_data, + ); + } + + late final _nfc_mifare_transfer_ptr = + _lookup>( + 'nfc_mifare_transfer'); + late final _dart_nfc_mifare_transfer _nfc_mifare_transfer = + _nfc_mifare_transfer_ptr.asFunction<_dart_nfc_mifare_transfer>(); + + /// @ingroup CAPI_NETWORK_NFC_TAG_MIFARE_MODULE + /// @brief Copy from a value block to the temporary block. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @remarks This function is only available for MIFARE classic + /// + /// @param [in] tag The handle to NFC tag + /// @param [in] block_index The index of block to copy from, starting from 0 + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_TIMED_OUT Timeout is reached while communicating with tag + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// + /// @post It invokes nfc_mifare_restore_completed_cb() when it has completed to restore.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_mifare_transfer() + /// @see nfc_manager_initialize() + int nfc_mifare_restore( + ffi.Pointer<_net_nfc_target_info_s> tag, + int block_index, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_mifare_restore( + tag, + block_index, + callback, + user_data, + ); + } + + late final _nfc_mifare_restore_ptr = + _lookup>('nfc_mifare_restore'); + late final _dart_nfc_mifare_restore _nfc_mifare_restore = + _nfc_mifare_restore_ptr.asFunction<_dart_nfc_mifare_restore>(); + + /// @brief Registers a callback function for receiving data from NFC peer-to-peer target. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_P2P_MODULE + /// + /// @param [in] target The handle to peer target + /// @param [in] callback The callback function to invoke when an NDEF Message is discovered + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_p2p_set_data_received_cb() + /// @see nfc_p2p_unset_data_received_cb() + /// @see nfc_p2p_target_discovered_cb() + /// @see nfc_manager_initialize() + int nfc_p2p_set_data_received_cb( + ffi.Pointer target, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_p2p_set_data_received_cb( + target, + callback, + user_data, + ); + } + + late final _nfc_p2p_set_data_received_cb_ptr = + _lookup>( + 'nfc_p2p_set_data_received_cb'); + late final _dart_nfc_p2p_set_data_received_cb _nfc_p2p_set_data_received_cb = + _nfc_p2p_set_data_received_cb_ptr + .asFunction<_dart_nfc_p2p_set_data_received_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @ingroup CAPI_NETWORK_NFC_P2P_MODULE + /// + /// @param [in] target The handle to peer target + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see nfc_p2p_set_data_received_cb() + /// @see nfc_p2p_unset_data_received_cb() + /// @see nfc_p2p_target_discovered_cb() + /// @see nfc_manager_initialize() + int nfc_p2p_unset_data_received_cb( + ffi.Pointer target, + ) { + return _nfc_p2p_unset_data_received_cb( + target, + ); + } + + late final _nfc_p2p_unset_data_received_cb_ptr = + _lookup>( + 'nfc_p2p_unset_data_received_cb'); + late final _dart_nfc_p2p_unset_data_received_cb + _nfc_p2p_unset_data_received_cb = _nfc_p2p_unset_data_received_cb_ptr + .asFunction<_dart_nfc_p2p_unset_data_received_cb>(); + + /// @brief Sends data to NFC peer-to-peer target + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @ingroup CAPI_NETWORK_NFC_P2P_MODULE + /// + /// @param [in] target The handle to peer target + /// @param [in] message The message to send + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// + /// @post It invokes nfc_p2p_send_completed_cb() when it has completed to p2p send.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_p2p_send_completed_cb() + /// @see nfc_p2p_target_discovered_cb() + /// @see nfc_manager_initialize() + int nfc_p2p_send( + ffi.Pointer target, + ffi.Pointer<_ndef_message_s> message, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_p2p_send( + target, + message, + callback, + user_data, + ); + } + + late final _nfc_p2p_send_ptr = + _lookup>('nfc_p2p_send'); + late final _dart_nfc_p2p_send _nfc_p2p_send = + _nfc_p2p_send_ptr.asFunction<_dart_nfc_p2p_send>(); + + /// @brief Start peer-to-peer server using SNEP protocol + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @ingroup CAPI_NETWORK_NFC_P2P_MODULE + /// + /// @param [in] target The handle to peer target + /// @param [in] san The name of service (service access name) + /// @param [in] sap The number of service (service access point) + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// + /// @post It invokes nfc_snep_event_cb() when snep event is occured.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_snep_event_cb() + /// @see nfc_manager_initialize() + int nfc_snep_start_server( + ffi.Pointer target, + ffi.Pointer san, + int sap, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_snep_start_server( + target, + san, + sap, + callback, + user_data, + ); + } + + late final _nfc_snep_start_server_ptr = + _lookup>( + 'nfc_snep_start_server'); + late final _dart_nfc_snep_start_server _nfc_snep_start_server = + _nfc_snep_start_server_ptr.asFunction<_dart_nfc_snep_start_server>(); + + /// @brief Start peer-to-peer client using SNEP protocol + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @ingroup CAPI_NETWORK_NFC_P2P_MODULE + /// + /// @param [in] target The handle to peer target + /// @param [in] san The name of service (service access name) + /// @param [in] sap The number of service (service access point) + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// + /// @post It invokes nfc_snep_event_cb() when snep event is occured.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_snep_event_cb() + /// @see nfc_snep_send_client_request() + /// @see nfc_snep_stop_service() + /// @see nfc_manager_initialize() + int nfc_snep_start_client( + ffi.Pointer target, + ffi.Pointer san, + int sap, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_snep_start_client( + target, + san, + sap, + callback, + user_data, + ); + } + + late final _nfc_snep_start_client_ptr = + _lookup>( + 'nfc_snep_start_client'); + late final _dart_nfc_snep_start_client _nfc_snep_start_client = + _nfc_snep_start_client_ptr.asFunction<_dart_nfc_snep_start_client>(); + + /// @brief Send request message to peer-to-peer client using SNEP protocol + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @ingroup CAPI_NETWORK_NFC_P2P_MODULE + /// + /// @param [in] handle The handle to connected snep instance + /// @param [in] type The request type of snep protocol + /// @param [in] msg The ndef message which will be sent + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// + /// @post It invokes nfc_snep_event_cb() when snep event is occured.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_snep_event_cb() + /// @see nfc_manager_initialize() + int nfc_snep_send_client_request( + ffi.Pointer<_nfc_p2p_snep_s> handle, + int type, + ffi.Pointer<_ndef_message_s> msg, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_snep_send_client_request( + handle, + type, + msg, + callback, + user_data, + ); + } + + late final _nfc_snep_send_client_request_ptr = + _lookup>( + 'nfc_snep_send_client_request'); + late final _dart_nfc_snep_send_client_request _nfc_snep_send_client_request = + _nfc_snep_send_client_request_ptr + .asFunction<_dart_nfc_snep_send_client_request>(); + + /// @brief Stop snep server or client + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @ingroup CAPI_NETWORK_NFC_P2P_MODULE + /// + /// @param [in] target The handle to peer target + /// @param [in] service The handle which will be stopped + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// + /// @see nfc_snep_event_cb() + /// @see nfc_manager_initialize() + int nfc_snep_stop_service( + ffi.Pointer target, + ffi.Pointer<_nfc_p2p_snep_s> service, + ) { + return _nfc_snep_stop_service( + target, + service, + ); + } + + late final _nfc_snep_stop_service_ptr = + _lookup>( + 'nfc_snep_stop_service'); + late final _dart_nfc_snep_stop_service _nfc_snep_stop_service = + _nfc_snep_stop_service_ptr.asFunction<_dart_nfc_snep_stop_service>(); + + /// @brief Register peer-to-peer server using SNEP protocol + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @ingroup CAPI_NETWORK_NFC_P2P_MODULE + /// + /// @param [in] san The name of service (service access name) + /// @param [in] sap The number of service (service access point) + /// @param [in] callback The callback function to invoke after this function has completed\n It can be null if notification is not required + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// + /// @post It invokes nfc_snep_event_cb() when snep event is occured.\n + /// The Callback can receive error code when process is done. + /// + /// @see nfc_snep_event_cb() + /// @see nfc_manager_initialize() + int nfc_snep_register_server( + ffi.Pointer san, + int sap, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_snep_register_server( + san, + sap, + callback, + user_data, + ); + } + + late final _nfc_snep_register_server_ptr = + _lookup>( + 'nfc_snep_register_server'); + late final _dart_nfc_snep_register_server _nfc_snep_register_server = + _nfc_snep_register_server_ptr + .asFunction<_dart_nfc_snep_register_server>(); + + /// @brief Unregister snep server or client + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc + /// @ingroup CAPI_NETWORK_NFC_P2P_MODULE + /// + /// @param [in] san The name of service (service access name) + /// @param [in] sap The number of service (service access point) + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// + /// @see nfc_snep_event_cb() + /// @see nfc_manager_initialize() + int nfc_snep_unregister_server( + ffi.Pointer san, + int sap, + ) { + return _nfc_snep_unregister_server( + san, + sap, + ); + } + + late final _nfc_snep_unregister_server_ptr = + _lookup>( + 'nfc_snep_unregister_server'); + late final _dart_nfc_snep_unregister_server _nfc_snep_unregister_server = + _nfc_snep_unregister_server_ptr + .asFunction<_dart_nfc_snep_unregister_server>(); + + /// @brief Enable card emulation mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_SE_MODULE + /// @remarks Security level can be determined by the manufacturer usage.\n + /// If a security issue is occurred, contact with the manufacturer of the product.\n + /// If you want to know about security level in detail, See the GSMA specification.\n + /// (http://www.gsma.com/digitalcommerce/wp-content/uploads/2013/12/GSMA-NFC05-NFC-Handset-APIs-Requirement-Specification-version-4-1.pdf) + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// @retval #NFC_ERROR_PERMISSION_DENIED Security Restricted by SMACK + /// @retval #NFC_ERROR_SECURITY_RESTRICTED Security Restricted + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see nfc_se_disable_card_emulation() + /// @see nfc_manager_initialize() + int nfc_se_enable_card_emulation() { + return _nfc_se_enable_card_emulation(); + } + + late final _nfc_se_enable_card_emulation_ptr = + _lookup>( + 'nfc_se_enable_card_emulation'); + late final _dart_nfc_se_enable_card_emulation _nfc_se_enable_card_emulation = + _nfc_se_enable_card_emulation_ptr + .asFunction<_dart_nfc_se_enable_card_emulation>(); + + /// @brief Disable card emulation mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_SE_MODULE + /// @remarks Security level can be determined by the manufacturer usage.\n + /// If a security issue is occurred, contact with the manufacturer of the product.\n + /// If you want to know about security level in detail, See the GSMA specification.\n + /// (http://www.gsma.com/digitalcommerce/wp-content/uploads/2013/12/GSMA-NFC05-NFC-Handset-APIs-Requirement-Specification-version-4-1.pdf) + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// @retval #NFC_ERROR_PERMISSION_DENIED Security Restricted by SMACK + /// @retval #NFC_ERROR_SECURITY_RESTRICTED Security Restricted + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see nfc_se_enable_card_emulation() + /// @see nfc_manager_initialize() + int nfc_se_disable_card_emulation() { + return _nfc_se_disable_card_emulation(); + } + + late final _nfc_se_disable_card_emulation_ptr = + _lookup>( + 'nfc_se_disable_card_emulation'); + late final _dart_nfc_se_disable_card_emulation + _nfc_se_disable_card_emulation = _nfc_se_disable_card_emulation_ptr + .asFunction<_dart_nfc_se_disable_card_emulation>(); + + /// @brief Get the current card emulation mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_SE_MODULE + /// + /// @param [out] type The current card emulation mode type + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// @retval #NFC_ERROR_PERMISSION_DENIED Security Restricted by SMACK + /// @retval #NFC_ERROR_DEVICE_BUSY Device is too busy to handle your request + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see nfc_se_enable_card_emulation() + /// @see nfc_se_disable_card_emulation() + /// @see nfc_manager_initialize() + int nfc_se_get_card_emulation_mode( + ffi.Pointer type, + ) { + return _nfc_se_get_card_emulation_mode( + type, + ); + } + + late final _nfc_se_get_card_emulation_mode_ptr = + _lookup>( + 'nfc_se_get_card_emulation_mode'); + late final _dart_nfc_se_get_card_emulation_mode + _nfc_se_get_card_emulation_mode = _nfc_se_get_card_emulation_mode_ptr + .asFunction<_dart_nfc_se_get_card_emulation_mode>(); + + /// @brief Send APDU(Application Protocol Data Unit) response to CLF(Contactless Front-end). + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_SE_MODULE + /// + /// @param [in] handle The handle of connected secure element + /// @param [in] resp The bytes array of response data + /// @param [in] resp_len The size of response bytes array + /// + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_ILLEGAL_STATE Illegal state + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see nfc_manager_set_hce_event_cb() + /// @see nfc_manager_unset_hce_event_cb() + /// @see nfc_manager_initialize() + int nfc_hce_send_apdu_response( + ffi.Pointer handle, + ffi.Pointer resp, + int resp_len, + ) { + return _nfc_hce_send_apdu_response( + handle, + resp, + resp_len, + ); + } + + late final _nfc_hce_send_apdu_response_ptr = + _lookup>( + 'nfc_hce_send_apdu_response'); + late final _dart_nfc_hce_send_apdu_response _nfc_hce_send_apdu_response = + _nfc_hce_send_apdu_response_ptr + .asFunction<_dart_nfc_hce_send_apdu_response>(); + + /// @brief Set the default route for each device status. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_SE_MODULE + /// + /// @param [in] powered_on_status The type of default Secure Element when device is powered on + /// @param [in] powered_off_status The type of default Secure Element when device is powered off + /// @param [in] low_battery_status The type of default Secure Element when battery is low + /// + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_ILLEGAL_STATE Illegal state + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see nfc_manager_initialize() + int nfc_se_set_default_route( + int powered_on_status, + int powered_off_status, + int low_battery_status, + ) { + return _nfc_se_set_default_route( + powered_on_status, + powered_off_status, + low_battery_status, + ); + } + + late final _nfc_se_set_default_route_ptr = + _lookup>( + 'nfc_se_set_default_route'); + late final _dart_nfc_se_set_default_route _nfc_se_set_default_route = + _nfc_se_set_default_route_ptr + .asFunction<_dart_nfc_se_set_default_route>(); + + /// @brief Gets the state whether an application to call this api is currently the activated handler for specific AID. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_SE_MODULE + /// + /// @param [in] se_type The type of Secure Element + /// @param [in] aid Application Id, specified in ISO/IEC 7816-4 + /// @param [out] is_activated_handler @c true when application is currently the activated handler, otherwise @c false + /// + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_ILLEGAL_STATE Illegal state + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see nfc_manager_initialize() + int nfc_se_is_activated_handler_for_aid( + int se_type, + ffi.Pointer aid, + ffi.Pointer is_activated_handler, + ) { + return _nfc_se_is_activated_handler_for_aid( + se_type, + aid, + is_activated_handler, + ); + } + + late final _nfc_se_is_activated_handler_for_aid_ptr = + _lookup>( + 'nfc_se_is_activated_handler_for_aid'); + late final _dart_nfc_se_is_activated_handler_for_aid + _nfc_se_is_activated_handler_for_aid = + _nfc_se_is_activated_handler_for_aid_ptr + .asFunction<_dart_nfc_se_is_activated_handler_for_aid>(); + + /// @brief Gets the state whether an application to call this api is currently the activated handler for category. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_SE_MODULE + /// + /// @param [in] se_type The type of Secure Element + /// @param [in] category The category + /// @param [out] is_activated_handler @c true when application is currently the activated handler, otherwise @c false + /// + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_ILLEGAL_STATE Illegal state + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see nfc_manager_initialize() + int nfc_se_is_activated_handler_for_category( + int se_type, + int category, + ffi.Pointer is_activated_handler, + ) { + return _nfc_se_is_activated_handler_for_category( + se_type, + category, + is_activated_handler, + ); + } + + late final _nfc_se_is_activated_handler_for_category_ptr = + _lookup>( + 'nfc_se_is_activated_handler_for_category'); + late final _dart_nfc_se_is_activated_handler_for_category + _nfc_se_is_activated_handler_for_category = + _nfc_se_is_activated_handler_for_category_ptr + .asFunction<_dart_nfc_se_is_activated_handler_for_category>(); + + /// @brief Registers a AID for a specific category. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_SE_MODULE + /// + /// @param [in] se_type The type of Secure Element + /// @param [in] category The category + /// @param [in] aid Application Id, specified in ISO/IEC 7816-4 + /// + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_ILLEGAL_STATE Illegal state + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_AID_ALREADY_REGISTERED AID is already registered + /// @retval #NFC_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see nfc_se_unregister_aid() + /// @see nfc_manager_initialize() + int nfc_se_register_aid( + int se_type, + int category, + ffi.Pointer aid, + ) { + return _nfc_se_register_aid( + se_type, + category, + aid, + ); + } + + late final _nfc_se_register_aid_ptr = + _lookup>( + 'nfc_se_register_aid'); + late final _dart_nfc_se_register_aid _nfc_se_register_aid = + _nfc_se_register_aid_ptr.asFunction<_dart_nfc_se_register_aid>(); + + /// @brief Unregisters a previously registered AID for the specified category. + /// @details You can unregister aid only you registered. If you try to release the aid what you are not registered, then the api return error. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_SE_MODULE + /// + /// @param [in] se_type The type of Secure Element + /// @param [in] category The category + /// @param [in] aid Application Id, specified in ISO/IEC 7816-4 + /// + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_ILLEGAL_STATE Illegal state + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #NFC_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see nfc_se_register_aid() + /// @see nfc_manager_initialize() + int nfc_se_unregister_aid( + int se_type, + int category, + ffi.Pointer aid, + ) { + return _nfc_se_unregister_aid( + se_type, + category, + aid, + ); + } + + late final _nfc_se_unregister_aid_ptr = + _lookup>( + 'nfc_se_unregister_aid'); + late final _dart_nfc_se_unregister_aid _nfc_se_unregister_aid = + _nfc_se_unregister_aid_ptr.asFunction<_dart_nfc_se_unregister_aid>(); + + /// @brief Retrieves all registered AID. + /// @details You can retrieve aid only you registered. If you try to retrieves the aid what you are not registered, then the api return error. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_SE_MODULE + /// + /// @param [in] se_type The type of Secure Element + /// @param [in] category The category + /// @param [in] callback The callback function to invoke + /// @param [in] user_data The user data to be passed to the callback function + /// + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_ILLEGAL_STATE Illegal state + /// @retval #NFC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #NFC_ERROR_OUT_OF_MEMORY Out of memory + /// + /// @see nfc_manager_initialize() + int nfc_se_foreach_registered_aids( + int se_type, + int category, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _nfc_se_foreach_registered_aids( + se_type, + category, + callback, + user_data, + ); + } + + late final _nfc_se_foreach_registered_aids_ptr = + _lookup>( + 'nfc_se_foreach_registered_aids'); + late final _dart_nfc_se_foreach_registered_aids + _nfc_se_foreach_registered_aids = _nfc_se_foreach_registered_aids_ptr + .asFunction<_dart_nfc_se_foreach_registered_aids>(); + + /// @brief Sets the application as a preferred handler. + /// @since_tizen 3.0 + /// @details This api is possible to call when your application is in the foreground.\n + /// We recommend that you call api when the app state is resume. + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_SE_MODULE + /// + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// @retval #NFC_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see nfc_manager_initialize() + /// @see nfc_se_unset_preferred_handler() + int nfc_se_set_preferred_handler() { + return _nfc_se_set_preferred_handler(); + } + + late final _nfc_se_set_preferred_handler_ptr = + _lookup>( + 'nfc_se_set_preferred_handler'); + late final _dart_nfc_se_set_preferred_handler _nfc_se_set_preferred_handler = + _nfc_se_set_preferred_handler_ptr + .asFunction<_dart_nfc_se_set_preferred_handler>(); + + /// @brief Unsets the application as a preferred handler. + /// @since_tizen 3.0 + /// @details We recommend that you call api when the app state is pause.\n + /// If you do not call the api, Tizen will initialize the preferred app properly.\n + /// But there may be a problem with the performance, we recommend your explicit call. + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/nfc.cardemulation + /// @ingroup CAPI_NETWORK_NFC_SE_MODULE + /// + /// @retval #NFC_ERROR_NONE Successful + /// @retval #NFC_ERROR_NOT_SUPPORTED Not supported NFC + /// @retval #NFC_ERROR_NOT_INITIALIZED Not initialized NFC + /// @retval #NFC_ERROR_NOT_ACTIVATED NFC is not activated + /// @retval #NFC_ERROR_OPERATION_FAILED Operation failed + /// @retval #NFC_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see nfc_manager_initialize() + /// @see nfc_se_set_preferred_handler() + int nfc_se_unset_preferred_handler() { + return _nfc_se_unset_preferred_handler(); + } + + late final _nfc_se_unset_preferred_handler_ptr = + _lookup>( + 'nfc_se_unset_preferred_handler'); + late final _dart_nfc_se_unset_preferred_handler + _nfc_se_unset_preferred_handler = _nfc_se_unset_preferred_handler_ptr + .asFunction<_dart_nfc_se_unset_preferred_handler>(); + + /// @brief Initializes SSDP. + /// @since_tizen 3.0 + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #SSDP_ERROR_NONE Successful + /// @retval #SSDP_ERROR_OPERATION_FAILED Operation failed + /// @retval #SSDP_ERROR_NOT_SUPPORTED Not supported + int ssdp_initialize() { + return _ssdp_initialize(); + } + + late final _ssdp_initialize_ptr = + _lookup>('ssdp_initialize'); + late final _dart_ssdp_initialize _ssdp_initialize = + _ssdp_initialize_ptr.asFunction<_dart_ssdp_initialize>(); + + /// @brief Deinitializes SSDP. + /// @since_tizen 3.0 + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #SSDP_ERROR_NONE Successful + /// @retval #SSDP_ERROR_NOT_SUPPORTED Not supported + int ssdp_deinitialize() { + return _ssdp_deinitialize(); + } + + late final _ssdp_deinitialize_ptr = + _lookup>('ssdp_deinitialize'); + late final _dart_ssdp_deinitialize _ssdp_deinitialize = + _ssdp_deinitialize_ptr.asFunction<_dart_ssdp_deinitialize>(); + + /// @brief Creates a SSDP local service handle. + /// @since_tizen 3.0 + /// @remarks You must release @a local_service using ssdp_destroy_local_service(). + /// @param[in] target The SSDP local service's target. It may be a device type or a service type specified in UPnP forum (http://upnp.org) + /// @param[out] local_service The SSDP local service handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #SSDP_ERROR_NONE Successful + /// @retval #SSDP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #SSDP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SSDP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #SSDP_ERROR_NOT_SUPPORTED Not supported + /// @see ssdp_destroy_local_service() + /// @pre This API needs ssdp_initialize() before use. + int ssdp_create_local_service( + ffi.Pointer target, + ffi.Pointer local_service, + ) { + return _ssdp_create_local_service( + target, + local_service, + ); + } + + late final _ssdp_create_local_service_ptr = + _lookup>( + 'ssdp_create_local_service'); + late final _dart_ssdp_create_local_service _ssdp_create_local_service = + _ssdp_create_local_service_ptr + .asFunction<_dart_ssdp_create_local_service>(); + + /// @brief Destroys the SSDP local service handle. + /// @details You must call ssdp_deregister_local_service() before destroying the local service. + /// @since_tizen 3.0 + /// @param[in] local_service The SSDP local service handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #SSDP_ERROR_NONE Successful + /// @retval #SSDP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #SSDP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SSDP_ERROR_SERVICE_NOT_FOUND Service not found + /// @retval #SSDP_ERROR_NOT_SUPPORTED Not supported + /// @see ssdp_create_local_service() + int ssdp_destroy_local_service( + int local_service, + ) { + return _ssdp_destroy_local_service( + local_service, + ); + } + + late final _ssdp_destroy_local_service_ptr = + _lookup>( + 'ssdp_destroy_local_service'); + late final _dart_ssdp_destroy_local_service _ssdp_destroy_local_service = + _ssdp_destroy_local_service_ptr + .asFunction<_dart_ssdp_destroy_local_service>(); + + /// @brief Sets the USN (Unique Service Name) of SSDP local service. The USN format is specified in UPnP forum (http://upnp.org). + /// @since_tizen 3.0 + /// @remarks You must pass only @a unregistered local_service created using ssdp_create_local_service(). + /// If @a local_service is already registered, you cannot set @a usn. + /// @param[in] local_service The SSDP local service handle + /// @param[in] usn The USN of SSDP local service + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #SSDP_ERROR_NONE Successful + /// @retval #SSDP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #SSDP_ERROR_SERVICE_NOT_FOUND Service not found + /// @retval #SSDP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SSDP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #SSDP_ERROR_NOT_SUPPORTED Not supported + int ssdp_service_set_usn( + int local_service, + ffi.Pointer usn, + ) { + return _ssdp_service_set_usn( + local_service, + usn, + ); + } + + late final _ssdp_service_set_usn_ptr = + _lookup>( + 'ssdp_service_set_usn'); + late final _dart_ssdp_service_set_usn _ssdp_service_set_usn = + _ssdp_service_set_usn_ptr.asFunction<_dart_ssdp_service_set_usn>(); + + /// @brief Sets the URL (Uniform Resource Locator) for description of SSDP local service. See RFC 3986. + /// @since_tizen 3.0 + /// @remarks You must pass only unregistered @a local_service created using ssdp_create_local_service(). + /// If @a local_service is already registered, you cannot set @a url. + /// @param[in] local_service The SSDP local service handle + /// @param[in] url The URL of SSDP local service + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #SSDP_ERROR_NONE Successful + /// @retval #SSDP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #SSDP_ERROR_SERVICE_NOT_FOUND Service not found + /// @retval #SSDP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SSDP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #SSDP_ERROR_NOT_SUPPORTED Not supported + int ssdp_service_set_url( + int local_service, + ffi.Pointer url, + ) { + return _ssdp_service_set_url( + local_service, + url, + ); + } + + late final _ssdp_service_set_url_ptr = + _lookup>( + 'ssdp_service_set_url'); + late final _dart_ssdp_service_set_url _ssdp_service_set_url = + _ssdp_service_set_url_ptr.asFunction<_dart_ssdp_service_set_url>(); + + /// @brief Gets the target of SSDP service. + /// @since_tizen 3.0 + /// @remarks You must release @a target using free(). + /// @param[in] service The SSDP service handle + /// @param[out] target The target of SSDP service + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #SSDP_ERROR_NONE Successful + /// @retval #SSDP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #SSDP_ERROR_SERVICE_NOT_FOUND Service not found + /// @retval #SSDP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SSDP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #SSDP_ERROR_NOT_SUPPORTED Not supported + int ssdp_service_get_target( + int service, + ffi.Pointer> target, + ) { + return _ssdp_service_get_target( + service, + target, + ); + } + + late final _ssdp_service_get_target_ptr = + _lookup>( + 'ssdp_service_get_target'); + late final _dart_ssdp_service_get_target _ssdp_service_get_target = + _ssdp_service_get_target_ptr.asFunction<_dart_ssdp_service_get_target>(); + + /// @brief Gets the USN of SSDP service. + /// @since_tizen 3.0 + /// @remarks You must release @a usn using free(). + /// @param[in] service The SSDP service handle + /// @param[out] usn The USN of SSDP service + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #SSDP_ERROR_NONE Successful + /// @retval #SSDP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #SSDP_ERROR_SERVICE_NOT_FOUND Service not found + /// @retval #SSDP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SSDP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #SSDP_ERROR_NOT_SUPPORTED Not supported + int ssdp_service_get_usn( + int service, + ffi.Pointer> usn, + ) { + return _ssdp_service_get_usn( + service, + usn, + ); + } + + late final _ssdp_service_get_usn_ptr = + _lookup>( + 'ssdp_service_get_usn'); + late final _dart_ssdp_service_get_usn _ssdp_service_get_usn = + _ssdp_service_get_usn_ptr.asFunction<_dart_ssdp_service_get_usn>(); + + /// @brief Gets the URL of SSDP service. + /// @since_tizen 3.0 + /// @remarks You must release @a url using free(). + /// @param[in] service The SSDP service handle + /// @param[out] url The URL of SSDP service + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #SSDP_ERROR_NONE Successful + /// @retval #SSDP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #SSDP_ERROR_SERVICE_NOT_FOUND Service not found + /// @retval #SSDP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SSDP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #SSDP_ERROR_NOT_SUPPORTED Not supported + int ssdp_service_get_url( + int service, + ffi.Pointer> url, + ) { + return _ssdp_service_get_url( + service, + url, + ); + } + + late final _ssdp_service_get_url_ptr = + _lookup>( + 'ssdp_service_get_url'); + late final _dart_ssdp_service_get_url _ssdp_service_get_url = + _ssdp_service_get_url_ptr.asFunction<_dart_ssdp_service_get_url>(); + + /// @brief Registers the SSDP local service for publishing. + /// @details You must set a USN and a URL of the local service before ssdp_register_local_service() is called. + /// @since_tizen 3.0 + /// @remarks You must pass only local_service created using ssdp_create_local_service(). + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] local_service The SSDP local service handle + /// @param[in] registered_cb The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #SSDP_ERROR_NONE Successful + /// @retval #SSDP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #SSDP_ERROR_SERVICE_NOT_FOUND Service not found + /// @retval #SSDP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SSDP_ERROR_OPERATION_FAILED Operation failed + /// @retval #SSDP_ERROR_NOT_SUPPORTED Not supported + /// @retval #SSDP_ERROR_SERVICE_ALREADY_REGISTERED Service already registered + /// @retval #SSDP_ERROR_PERMISSION_DENIED Permission Denied + /// @pre This API needs ssdp_service_set_usn() and ssdp_service_set_url() before use. + int ssdp_register_local_service( + int local_service, + ffi.Pointer> registered_cb, + ffi.Pointer user_data, + ) { + return _ssdp_register_local_service( + local_service, + registered_cb, + user_data, + ); + } + + late final _ssdp_register_local_service_ptr = + _lookup>( + 'ssdp_register_local_service'); + late final _dart_ssdp_register_local_service _ssdp_register_local_service = + _ssdp_register_local_service_ptr + .asFunction<_dart_ssdp_register_local_service>(); + + /// @brief Deregisters the SSDP local service. + /// @since_tizen 3.0 + /// @remarks You must pass only local_service created using ssdp_create_local_service(). + /// @param[in] local_service The SSDP local service handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #SSDP_ERROR_NONE Successful + /// @retval #SSDP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #SSDP_ERROR_SERVICE_NOT_FOUND Service not found + /// @retval #SSDP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SSDP_ERROR_NOT_SUPPORTED Not supported + int ssdp_deregister_local_service( + int local_service, + ) { + return _ssdp_deregister_local_service( + local_service, + ); + } + + late final _ssdp_deregister_local_service_ptr = + _lookup>( + 'ssdp_deregister_local_service'); + late final _dart_ssdp_deregister_local_service + _ssdp_deregister_local_service = _ssdp_deregister_local_service_ptr + .asFunction<_dart_ssdp_deregister_local_service>(); + + /// @brief Starts browsing the SSDP remote service. + /// @details ssdp_start_browsing_service() keeps browsing services until calling ssdp_stop_browsing_service(). + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @param[in] target The target to browse + /// @param[out] ssdp_browser The SSDP browser handle + /// @param[in] found_cb The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #SSDP_ERROR_NONE Successful + /// @retval #SSDP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #SSDP_ERROR_SERVICE_NOT_FOUND Service not found + /// @retval #SSDP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SSDP_ERROR_OPERATION_FAILED Operation failed + /// @retval #SSDP_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #SSDP_ERROR_NOT_SUPPORTED Not supported + /// @retval #SSDP_ERROR_PERMISSION_DENIED Permission Denied + int ssdp_start_browsing_service( + ffi.Pointer target, + ffi.Pointer ssdp_browser, + ffi.Pointer> found_cb, + ffi.Pointer user_data, + ) { + return _ssdp_start_browsing_service( + target, + ssdp_browser, + found_cb, + user_data, + ); + } + + late final _ssdp_start_browsing_service_ptr = + _lookup>( + 'ssdp_start_browsing_service'); + late final _dart_ssdp_start_browsing_service _ssdp_start_browsing_service = + _ssdp_start_browsing_service_ptr + .asFunction<_dart_ssdp_start_browsing_service>(); + + /// @brief Stops browsing the SSDP remote service. + /// @since_tizen 3.0 + /// @param[in] ssdp_browser The SSDP browser handle + /// @return @c 0 on success, + /// otherwise negative error value + /// @retval #SSDP_ERROR_NONE Successful + /// @retval #SSDP_ERROR_NOT_INITIALIZED Not initialized + /// @retval #SSDP_ERROR_SERVICE_NOT_FOUND Service not found + /// @retval #SSDP_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SSDP_ERROR_NOT_SUPPORTED Not supported + int ssdp_stop_browsing_service( + int ssdp_browser, + ) { + return _ssdp_stop_browsing_service( + ssdp_browser, + ); + } + + late final _ssdp_stop_browsing_service_ptr = + _lookup>( + 'ssdp_stop_browsing_service'); + late final _dart_ssdp_stop_browsing_service _ssdp_stop_browsing_service = + _ssdp_stop_browsing_service_ptr + .asFunction<_dart_ssdp_stop_browsing_service>(); + + /// @brief Initializes STC (Smart Traffic Control). + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @remarks You must release @a handle using stc_deinitialize(). + /// + /// @param[out] stc The STC handle + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// @retval #STC_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see stc_h + /// @see stc_deinitialize() + int stc_initialize( + ffi.Pointer> stc, + ) { + return _stc_initialize( + stc, + ); + } + + late final _stc_initialize_ptr = + _lookup>('stc_initialize'); + late final _dart_stc_initialize _stc_initialize = + _stc_initialize_ptr.asFunction<_dart_stc_initialize>(); + + /// @brief Deinitializes STC. + /// @since_tizen 4.0 + /// + /// @param[in] stc The STC handle + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_h + /// @see stc_initialize() + int stc_deinitialize( + ffi.Pointer stc, + ) { + return _stc_deinitialize( + stc, + ); + } + + late final _stc_deinitialize_ptr = + _lookup>('stc_deinitialize'); + late final _dart_stc_deinitialize _stc_deinitialize = + _stc_deinitialize_ptr.asFunction<_dart_stc_deinitialize>(); + + /// @brief Gets the statistics information an application matched rule asynchronously. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// + /// @param[in] stc The STC handle + /// @param[in] rule The statistics rule handle + /// @param[in] info_cb The callback is called for each application + /// that used network in between timestamps specified + /// @param[in] user_data The user data passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// @retval #STC_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see stc_h + /// @see stc_stats_rule_h + /// @see stc_initialize() + /// @see stc_stats_rule_create() + /// @see stc_stats_rule_destroy() + /// @see stc_stats_rule_set_app_id() + /// @see stc_stats_rule_set_time_interval() + /// @see stc_stats_rule_set_iface_type() + /// @see stc_stats_rule_set_time_period() + /// @see stc_stats_rule_get_app_id() + /// @see stc_stats_rule_get_time_interval() + /// @see stc_stats_rule_get_iface_type() + /// @see stc_stats_rule_get_time_period() + /// @see stc_stats_info_cb() + /// @see stc_foreach_stats() + /// @see stc_get_total_stats() + int stc_get_stats( + ffi.Pointer stc, + ffi.Pointer rule, + ffi.Pointer> info_cb, + ffi.Pointer user_data, + ) { + return _stc_get_stats( + stc, + rule, + info_cb, + user_data, + ); + } + + late final _stc_get_stats_ptr = + _lookup>('stc_get_stats'); + late final _dart_stc_get_stats _stc_get_stats = + _stc_get_stats_ptr.asFunction<_dart_stc_get_stats>(); + + /// @brief Gets the statistics information of each application asynchronously. + /// @details The callback is called for each application that used network + /// in between timestamps specified. + /// If interface name is not specified, each application will only appear + /// once with the total traffic used over all interfaces. + /// + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// + /// @param[in] stc The STC handle + /// @param[in] rule The statistics rule handle + /// @param[in] info_cb The callback is called for each application + /// that used network in between timestamps specified + /// @param[in] user_data The user data passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// @retval #STC_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see stc_h + /// @see stc_stats_rule_h + /// @see stc_initialize() + /// @see stc_stats_rule_create() + /// @see stc_stats_rule_destroy() + /// @see stc_stats_rule_set_app_id() + /// @see stc_stats_rule_set_time_interval() + /// @see stc_stats_rule_set_iface_type() + /// @see stc_stats_rule_set_time_period() + /// @see stc_stats_rule_get_app_id() + /// @see stc_stats_rule_get_time_interval() + /// @see stc_stats_rule_get_iface_type() + /// @see stc_stats_rule_get_time_period() + /// @see stc_stats_info_cb() + /// @see stc_get_stats() + /// @see stc_get_total_stats() + int stc_foreach_stats( + ffi.Pointer stc, + ffi.Pointer rule, + ffi.Pointer> info_cb, + ffi.Pointer user_data, + ) { + return _stc_foreach_stats( + stc, + rule, + info_cb, + user_data, + ); + } + + late final _stc_foreach_stats_ptr = + _lookup>('stc_foreach_stats'); + late final _dart_stc_foreach_stats _stc_foreach_stats = + _stc_foreach_stats_ptr.asFunction<_dart_stc_foreach_stats>(); + + /// @brief Gets the total statistics information by interface type asynchronously. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// + /// @param[in] stc The STC handle + /// @param[in] rule The statistics rule handle + /// @param[in] info_cb The callback is called for each application + /// that used network in between timestamps specified + /// @param[in] user_data The user data passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// @retval #STC_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see stc_h + /// @see stc_stats_rule_h + /// @see stc_initialize() + /// @see stc_stats_rule_create() + /// @see stc_stats_rule_destroy() + /// @see stc_stats_rule_set_app_id() + /// @see stc_stats_rule_set_time_interval() + /// @see stc_stats_rule_set_iface_type() + /// @see stc_stats_rule_set_time_period() + /// @see stc_stats_rule_get_app_id() + /// @see stc_stats_rule_get_time_interval() + /// @see stc_stats_rule_get_iface_type() + /// @see stc_stats_rule_get_time_period() + /// @see stc_stats_info_cb() + /// @see stc_get_stats() + /// @see stc_foreach_stats() + int stc_get_total_stats( + ffi.Pointer stc, + ffi.Pointer rule, + ffi.Pointer> info_cb, + ffi.Pointer user_data, + ) { + return _stc_get_total_stats( + stc, + rule, + info_cb, + user_data, + ); + } + + late final _stc_get_total_stats_ptr = + _lookup>( + 'stc_get_total_stats'); + late final _dart_stc_get_total_stats _stc_get_total_stats = + _stc_get_total_stats_ptr.asFunction<_dart_stc_get_total_stats>(); + + /// @brief Creates the statistics rule handle. + /// @since_tizen 4.0 + /// @remarks You must release @a handle using stc_stats_rule_destroy(). + /// + /// @param[in] stc The STC handle + /// @param[out] rule The statistics rule handle + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_h + /// @see stc_stats_rule_h + /// @see stc_initialize() + /// @see stc_stats_rule_destroy() + int stc_stats_rule_create( + ffi.Pointer stc, + ffi.Pointer> rule, + ) { + return _stc_stats_rule_create( + stc, + rule, + ); + } + + late final _stc_stats_rule_create_ptr = + _lookup>( + 'stc_stats_rule_create'); + late final _dart_stc_stats_rule_create _stc_stats_rule_create = + _stc_stats_rule_create_ptr.asFunction<_dart_stc_stats_rule_create>(); + + /// @brief Destroys the statistics rule handle. + /// @since_tizen 4.0 + /// + /// @param[in] rule The statistics rule handle + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_rule_h + /// @see stc_stats_rule_create() + int stc_stats_rule_destroy( + ffi.Pointer rule, + ) { + return _stc_stats_rule_destroy( + rule, + ); + } + + late final _stc_stats_rule_destroy_ptr = + _lookup>( + 'stc_stats_rule_destroy'); + late final _dart_stc_stats_rule_destroy _stc_stats_rule_destroy = + _stc_stats_rule_destroy_ptr.asFunction<_dart_stc_stats_rule_destroy>(); + + /// @brief Sets the application ID for statistics rule. + /// @since_tizen 4.0 + /// + /// @param[in] rule The statistics rule handle + /// @param[in] app_id The application ID + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_rule_h + /// @see stc_stats_rule_create() + /// @see stc_stats_rule_destroy() + /// @see stc_stats_rule_get_app_id() + int stc_stats_rule_set_app_id( + ffi.Pointer rule, + ffi.Pointer app_id, + ) { + return _stc_stats_rule_set_app_id( + rule, + app_id, + ); + } + + late final _stc_stats_rule_set_app_id_ptr = + _lookup>( + 'stc_stats_rule_set_app_id'); + late final _dart_stc_stats_rule_set_app_id _stc_stats_rule_set_app_id = + _stc_stats_rule_set_app_id_ptr + .asFunction<_dart_stc_stats_rule_set_app_id>(); + + /// @brief Sets the time interval for statistics rule. + /// @since_tizen 4.0 + /// + /// @param[in] rule The statistics rule handle + /// @param[in] from The beginning of the time interval + /// @param[in] to The end of the time interval + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_rule_h + /// @see stc_stats_rule_create() + /// @see stc_stats_rule_destroy() + /// @see stc_stats_rule_get_time_interval() + int stc_stats_rule_set_time_interval( + ffi.Pointer rule, + int from, + int to, + ) { + return _stc_stats_rule_set_time_interval( + rule, + from, + to, + ); + } + + late final _stc_stats_rule_set_time_interval_ptr = + _lookup>( + 'stc_stats_rule_set_time_interval'); + late final _dart_stc_stats_rule_set_time_interval + _stc_stats_rule_set_time_interval = _stc_stats_rule_set_time_interval_ptr + .asFunction<_dart_stc_stats_rule_set_time_interval>(); + + /// @brief Sets the interface type for statistics rule. + /// @since_tizen 4.0 + /// + /// @param[in] rule The stats rule handle + /// @param[in] iface_type The interface type + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_rule_h + /// @see stc_iface_type_e + /// @see stc_stats_rule_create() + /// @see stc_stats_rule_destroy() + /// @see stc_stats_rule_get_iface_type() + int stc_stats_rule_set_iface_type( + ffi.Pointer rule, + int iface_type, + ) { + return _stc_stats_rule_set_iface_type( + rule, + iface_type, + ); + } + + late final _stc_stats_rule_set_iface_type_ptr = + _lookup>( + 'stc_stats_rule_set_iface_type'); + late final _dart_stc_stats_rule_set_iface_type + _stc_stats_rule_set_iface_type = _stc_stats_rule_set_iface_type_ptr + .asFunction<_dart_stc_stats_rule_set_iface_type>(); + + /// @brief Sets the time period for statistics rule. + /// @since_tizen 4.0 + /// + /// @param[in] rule The statistics rule handle + /// @param[in] time_period The time period + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_rule_h + /// @see stc_time_period_e + /// @see stc_stats_rule_create() + /// @see stc_stats_rule_destroy() + /// @see stc_stats_rule_get_time_period() + int stc_stats_rule_set_time_period( + ffi.Pointer rule, + int time_period, + ) { + return _stc_stats_rule_set_time_period( + rule, + time_period, + ); + } + + late final _stc_stats_rule_set_time_period_ptr = + _lookup>( + 'stc_stats_rule_set_time_period'); + late final _dart_stc_stats_rule_set_time_period + _stc_stats_rule_set_time_period = _stc_stats_rule_set_time_period_ptr + .asFunction<_dart_stc_stats_rule_set_time_period>(); + + /// @brief Gets the application ID for statistics rule. + /// @since_tizen 4.0 + /// @remarks You must release @a app_id using free(). + /// + /// @param[in] rule The statistics rule handle + /// @param[out] app_id The application ID + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_rule_h + /// @see stc_stats_rule_create() + /// @see stc_stats_rule_destroy() + /// @see stc_stats_rule_set_app_id() + int stc_stats_rule_get_app_id( + ffi.Pointer rule, + ffi.Pointer> app_id, + ) { + return _stc_stats_rule_get_app_id( + rule, + app_id, + ); + } + + late final _stc_stats_rule_get_app_id_ptr = + _lookup>( + 'stc_stats_rule_get_app_id'); + late final _dart_stc_stats_rule_get_app_id _stc_stats_rule_get_app_id = + _stc_stats_rule_get_app_id_ptr + .asFunction<_dart_stc_stats_rule_get_app_id>(); + + /// @brief Gets the time interval for statistics rule. + /// @since_tizen 4.0 + /// + /// @param[in] rule The statistics rule handle + /// @param[out] from The beginning of the time interval + /// @param[out] to The end of the time interval + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_rule_h + /// @see stc_stats_rule_create() + /// @see stc_stats_rule_destroy() + /// @see stc_stats_rule_set_time_interval() + int stc_stats_rule_get_time_interval( + ffi.Pointer rule, + ffi.Pointer from, + ffi.Pointer to, + ) { + return _stc_stats_rule_get_time_interval( + rule, + from, + to, + ); + } + + late final _stc_stats_rule_get_time_interval_ptr = + _lookup>( + 'stc_stats_rule_get_time_interval'); + late final _dart_stc_stats_rule_get_time_interval + _stc_stats_rule_get_time_interval = _stc_stats_rule_get_time_interval_ptr + .asFunction<_dart_stc_stats_rule_get_time_interval>(); + + /// @brief Gets the interface type for statistics rule. + /// @since_tizen 4.0 + /// + /// @param[in] rule The statistics rule handle + /// @param[out] iface_type The interface type + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_rule_h + /// @see stc_iface_type_e + /// @see stc_stats_rule_create() + /// @see stc_stats_rule_destroy() + /// @see stc_stats_rule_set_iface_type() + int stc_stats_rule_get_iface_type( + ffi.Pointer rule, + ffi.Pointer iface_type, + ) { + return _stc_stats_rule_get_iface_type( + rule, + iface_type, + ); + } + + late final _stc_stats_rule_get_iface_type_ptr = + _lookup>( + 'stc_stats_rule_get_iface_type'); + late final _dart_stc_stats_rule_get_iface_type + _stc_stats_rule_get_iface_type = _stc_stats_rule_get_iface_type_ptr + .asFunction<_dart_stc_stats_rule_get_iface_type>(); + + /// @brief Gets the time period for statistics rule. + /// @since_tizen 4.0 + /// + /// @param[in] rule The statistics rule handle + /// @param[out] time_period The time period + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_rule_h + /// @see stc_time_period_e + /// @see stc_stats_rule_create() + /// @see stc_stats_rule_destroy() + /// @see stc_stats_rule_set_time_period() + int stc_stats_rule_get_time_period( + ffi.Pointer rule, + ffi.Pointer time_period, + ) { + return _stc_stats_rule_get_time_period( + rule, + time_period, + ); + } + + late final _stc_stats_rule_get_time_period_ptr = + _lookup>( + 'stc_stats_rule_get_time_period'); + late final _dart_stc_stats_rule_get_time_period + _stc_stats_rule_get_time_period = _stc_stats_rule_get_time_period_ptr + .asFunction<_dart_stc_stats_rule_get_time_period>(); + + /// @brief Gets the application ID from statistics information. + /// @since_tizen 4.0 + /// @remarks You must release @a app_id using free(). + /// + /// @param[in] info The statistics information handle + /// @param[out] app_id The application ID + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_info_h + /// @see stc_stats_info_cb() + int stc_stats_info_get_app_id( + ffi.Pointer info, + ffi.Pointer> app_id, + ) { + return _stc_stats_info_get_app_id( + info, + app_id, + ); + } + + late final _stc_stats_info_get_app_id_ptr = + _lookup>( + 'stc_stats_info_get_app_id'); + late final _dart_stc_stats_info_get_app_id _stc_stats_info_get_app_id = + _stc_stats_info_get_app_id_ptr + .asFunction<_dart_stc_stats_info_get_app_id>(); + + /// @brief Gets the interface name from statistics information. + /// @since_tizen 4.0 + /// @remarks You must release @a iface_name using free(). + /// + /// @param[in] info The statistics information handle + /// @param[out] iface_name The interface name + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_info_h + /// @see stc_stats_info_cb() + int stc_stats_info_get_iface_name( + ffi.Pointer info, + ffi.Pointer> iface_name, + ) { + return _stc_stats_info_get_iface_name( + info, + iface_name, + ); + } + + late final _stc_stats_info_get_iface_name_ptr = + _lookup>( + 'stc_stats_info_get_iface_name'); + late final _dart_stc_stats_info_get_iface_name + _stc_stats_info_get_iface_name = _stc_stats_info_get_iface_name_ptr + .asFunction<_dart_stc_stats_info_get_iface_name>(); + + /// @brief Gets the time interval from statistics information. + /// @since_tizen 4.0 + /// + /// @param[in] info The statistics information handle + /// @param[out] from The beginning of the time interval + /// @param[out] to The end of the time interval + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_info_h + /// @see stc_stats_info_cb() + int stc_stats_info_get_time_interval( + ffi.Pointer info, + ffi.Pointer from, + ffi.Pointer to, + ) { + return _stc_stats_info_get_time_interval( + info, + from, + to, + ); + } + + late final _stc_stats_info_get_time_interval_ptr = + _lookup>( + 'stc_stats_info_get_time_interval'); + late final _dart_stc_stats_info_get_time_interval + _stc_stats_info_get_time_interval = _stc_stats_info_get_time_interval_ptr + .asFunction<_dart_stc_stats_info_get_time_interval>(); + + /// @brief Gets the interface type from statistics information. + /// @since_tizen 4.0 + /// + /// @param[in] info The statistics information handle + /// @param[out] iface_type The interface type + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_info_h + /// @see stc_iface_type_e + /// @see stc_stats_info_cb() + int stc_stats_info_get_iface_type( + ffi.Pointer info, + ffi.Pointer iface_type, + ) { + return _stc_stats_info_get_iface_type( + info, + iface_type, + ); + } + + late final _stc_stats_info_get_iface_type_ptr = + _lookup>( + 'stc_stats_info_get_iface_type'); + late final _dart_stc_stats_info_get_iface_type + _stc_stats_info_get_iface_type = _stc_stats_info_get_iface_type_ptr + .asFunction<_dart_stc_stats_info_get_iface_type>(); + + /// @brief Gets the counters from statistics information. + /// @since_tizen 4.0 + /// + /// @param[in] info The statistics information handle + /// @param[out] incoming The incoming counter + /// @param[out] outgoing The outgoing counter + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_info_h + /// @see stc_stats_info_cb() + int stc_stats_info_get_counter( + ffi.Pointer info, + ffi.Pointer incoming, + ffi.Pointer outgoing, + ) { + return _stc_stats_info_get_counter( + info, + incoming, + outgoing, + ); + } + + late final _stc_stats_info_get_counter_ptr = + _lookup>( + 'stc_stats_info_get_counter'); + late final _dart_stc_stats_info_get_counter _stc_stats_info_get_counter = + _stc_stats_info_get_counter_ptr + .asFunction<_dart_stc_stats_info_get_counter>(); + + /// @brief Gets the roaming type from statistics information. + /// @since_tizen 4.0 + /// + /// @param[in] info The statistics information handle + /// @param[out] roaming_type The roaming type + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_info_h + /// @see stc_roaming_type_e + /// @see stc_stats_info_cb() + int stc_stats_info_get_roaming_type( + ffi.Pointer info, + ffi.Pointer roaming_type, + ) { + return _stc_stats_info_get_roaming_type( + info, + roaming_type, + ); + } + + late final _stc_stats_info_get_roaming_type_ptr = + _lookup>( + 'stc_stats_info_get_roaming_type'); + late final _dart_stc_stats_info_get_roaming_type + _stc_stats_info_get_roaming_type = _stc_stats_info_get_roaming_type_ptr + .asFunction<_dart_stc_stats_info_get_roaming_type>(); + + /// @brief Gets the protocol type from statistics information. + /// @since_tizen 4.0 + /// + /// @param[in] info The statistics information handle + /// @param[out] protocol The protocol type + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_info_h + /// @see stc_protocol_type_e + /// @see stc_stats_info_cb() + int stc_stats_info_get_protocol_type( + ffi.Pointer info, + ffi.Pointer protocol, + ) { + return _stc_stats_info_get_protocol_type( + info, + protocol, + ); + } + + late final _stc_stats_info_get_protocol_type_ptr = + _lookup>( + 'stc_stats_info_get_protocol_type'); + late final _dart_stc_stats_info_get_protocol_type + _stc_stats_info_get_protocol_type = _stc_stats_info_get_protocol_type_ptr + .asFunction<_dart_stc_stats_info_get_protocol_type>(); + + /// @brief Gets the process state from statistics information. + /// @since_tizen 4.0 + /// + /// @param[in] info The statistics information handle + /// @param[out] state The process state + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #STC_ERROR_NONE Successful + /// @retval #STC_ERROR_OPERATION_FAILED General error + /// @retval #STC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STC_ERROR_INVALID_OPERATION Invalid operation + /// @retval #STC_ERROR_NOT_INITIALIZED Not initialized + /// @retval #STC_ERROR_NOT_SUPPORTED Not supported + /// + /// @see stc_stats_info_h + /// @see stc_process_state_e + /// @see stc_stats_info_cb() + int stc_stats_info_get_process_state( + ffi.Pointer info, + ffi.Pointer state, + ) { + return _stc_stats_info_get_process_state( + info, + state, + ); + } + + late final _stc_stats_info_get_process_state_ptr = + _lookup>( + 'stc_stats_info_get_process_state'); + late final _dart_stc_stats_info_get_process_state + _stc_stats_info_get_process_state = _stc_stats_info_get_process_state_ptr + .asFunction<_dart_stc_stats_info_get_process_state>(); + + /// @brief Initializes smartcard service + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/secureelement + /// @ingroup CAPI_NETWORK_SMARTCARD_SE_SERVICE_MODULE + /// + /// @remarks This function must be called before proceeding any other smartcard function + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// @retval #SMARTCARD_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see smartcard_deinitialize() + int smartcard_initialize() { + return _smartcard_initialize(); + } + + late final _smartcard_initialize_ptr = + _lookup>( + 'smartcard_initialize'); + late final _dart_smartcard_initialize _smartcard_initialize = + _smartcard_initialize_ptr.asFunction<_dart_smartcard_initialize>(); + + /// @brief Deinitializes smartcard service + /// @details Releases all the resource of the smartcard service + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/secureelement + /// @ingroup CAPI_NETWORK_SMARTCARD_SE_SERVICE_MODULE + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// @retval #SMARTCARD_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see smartcard_initialize() + int smartcard_deinitialize() { + return _smartcard_deinitialize(); + } + + late final _smartcard_deinitialize_ptr = + _lookup>( + 'smartcard_deinitialize'); + late final _dart_smartcard_deinitialize _smartcard_deinitialize = + _smartcard_deinitialize_ptr.asFunction<_dart_smartcard_deinitialize>(); + + /// @brief Gets the version of SIMAlliance OpenMobileAPI specification + /// @since_tizen 3.0 + /// @ingroup CAPI_NETWORK_SMARTCARD_SE_SERVICE_MODULE + /// + /// @remarks The @a version must be released using free(). + /// + /// @param [out] version The version of SIMAlliance OpenMobileAPI specification + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// @retval #SMARTCARD_ERROR_OUT_OF_MEMORY Out of memory + int smartcard_get_version( + ffi.Pointer> version, + ) { + return _smartcard_get_version( + version, + ); + } + + late final _smartcard_get_version_ptr = + _lookup>( + 'smartcard_get_version'); + late final _dart_smartcard_get_version _smartcard_get_version = + _smartcard_get_version_ptr.asFunction<_dart_smartcard_get_version>(); + + /// @brief Gets the list of available Secure Element readers. + /// @since_tizen 2.3.1 + /// @ingroup CAPI_NETWORK_SMARTCARD_SE_SERVICE_MODULE + /// + /// @remarks readers must be released using free(). + /// + /// @param [out] readers List of readers + /// @param [out] length The number of readers + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + int smartcard_get_readers( + ffi.Pointer> readers, + ffi.Pointer length, + ) { + return _smartcard_get_readers( + readers, + length, + ); + } + + late final _smartcard_get_readers_ptr = + _lookup>( + 'smartcard_get_readers'); + late final _dart_smartcard_get_readers _smartcard_get_readers = + _smartcard_get_readers_ptr.asFunction<_dart_smartcard_get_readers>(); + + /// @brief Returns the name of the given reader. + /// @since_tizen 2.3.1 + /// @ingroup CAPI_NETWORK_SMARTCARD_READER_MODULE + /// + /// @remarks reader_name must be released using free(). + /// @remarks If the reader is a SIM reader, then its name must be "SIM[Slot]" + /// @remarks If the reader is a SD or micro SD reader, then its name must be "SD[slot]" + /// @remarks If the reader is a embedded SE reader, then its name must be "eSE[slot]" + /// + /// @param [in] reader Handle to the reader + /// @param [out] reader_name The name of reader + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// + /// @see smartcard_get_readers() + int smartcard_reader_get_name( + int reader, + ffi.Pointer> reader_name, + ) { + return _smartcard_reader_get_name( + reader, + reader_name, + ); + } + + late final _smartcard_reader_get_name_ptr = + _lookup>( + 'smartcard_reader_get_name'); + late final _dart_smartcard_reader_get_name _smartcard_reader_get_name = + _smartcard_reader_get_name_ptr + .asFunction<_dart_smartcard_reader_get_name>(); + + /// @brief Checks if a Secure Element is present in the given reader. + /// @since_tizen 2.3.1 + /// @ingroup CAPI_NETWORK_SMARTCARD_READER_MODULE + /// + /// @param [in] reader Handle to the reader + /// @param [out] is_present True or false depending whether a secure element is present in the + /// reader - undefined when an error is returned + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// + /// @see smartcard_get_readers() + int smartcard_reader_is_secure_element_present( + int reader, + ffi.Pointer is_present, + ) { + return _smartcard_reader_is_secure_element_present( + reader, + is_present, + ); + } + + late final _smartcard_reader_is_secure_element_present_ptr = _lookup< + ffi.NativeFunction<_c_smartcard_reader_is_secure_element_present>>( + 'smartcard_reader_is_secure_element_present'); + late final _dart_smartcard_reader_is_secure_element_present + _smartcard_reader_is_secure_element_present = + _smartcard_reader_is_secure_element_present_ptr + .asFunction<_dart_smartcard_reader_is_secure_element_present>(); + + /// @brief Connects to a Secure Element in the given reader. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/secureelement + /// @ingroup CAPI_NETWORK_SMARTCARD_READER_MODULE + /// + /// @param [in] reader Handle to the reader + /// @param [out] session Handle to the session created for the given reader + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_IO_ERROR I/O error + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// @retval #SMARTCARD_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see smartcard_get_readers() + int smartcard_reader_open_session( + int reader, + ffi.Pointer session, + ) { + return _smartcard_reader_open_session( + reader, + session, + ); + } + + late final _smartcard_reader_open_session_ptr = + _lookup>( + 'smartcard_reader_open_session'); + late final _dart_smartcard_reader_open_session + _smartcard_reader_open_session = _smartcard_reader_open_session_ptr + .asFunction<_dart_smartcard_reader_open_session>(); + + /// @brief Closes all the sessions opened on the given reader. + /// @details All the channels opened by all these sessions will be closed. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/secureelement + /// @ingroup CAPI_NETWORK_SMARTCARD_READER_MODULE + /// + /// @param [in] reader Handle to the reader + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_IO_ERROR I/O error + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// @retval #SMARTCARD_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see smartcard_get_readers() + int smartcard_reader_close_sessions( + int reader, + ) { + return _smartcard_reader_close_sessions( + reader, + ); + } + + late final _smartcard_reader_close_sessions_ptr = + _lookup>( + 'smartcard_reader_close_sessions'); + late final _dart_smartcard_reader_close_sessions + _smartcard_reader_close_sessions = _smartcard_reader_close_sessions_ptr + .asFunction<_dart_smartcard_reader_close_sessions>(); + + /// @brief Sets a callback function for receiving reader event. + /// @since_tizen 3.0 + /// @ingroup CAPI_NETWORK_SMARTCARD_READER_MODULE + /// + /// @param [in] cb The reader event callback + /// @param [in] user_data The user data + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// + /// @see smartcard_reader_unset_event_cb() + int smartcard_reader_set_event_cb( + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _smartcard_reader_set_event_cb( + cb, + user_data, + ); + } + + late final _smartcard_reader_set_event_cb_ptr = + _lookup>( + 'smartcard_reader_set_event_cb'); + late final _dart_smartcard_reader_set_event_cb + _smartcard_reader_set_event_cb = _smartcard_reader_set_event_cb_ptr + .asFunction<_dart_smartcard_reader_set_event_cb>(); + + /// @brief Unsets the reader event callback function. + /// @since_tizen 3.0 + /// @ingroup CAPI_NETWORK_SMARTCARD_READER_MODULE + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// + /// @see smartcard_reader_set_event_cb() + int smartcard_reader_unset_event_cb() { + return _smartcard_reader_unset_event_cb(); + } + + late final _smartcard_reader_unset_event_cb_ptr = + _lookup>( + 'smartcard_reader_unset_event_cb'); + late final _dart_smartcard_reader_unset_event_cb + _smartcard_reader_unset_event_cb = _smartcard_reader_unset_event_cb_ptr + .asFunction<_dart_smartcard_reader_unset_event_cb>(); + + /// @brief Gets the reader that provides the given session. + /// @since_tizen 2.3.1 + /// @ingroup CAPI_NETWORK_SMARTCARD_SESSION_MODULE + /// + /// @param [in] session Handle to the session + /// @param [out] reader Reader handle that provides the given session + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// + /// @see smartcard_reader_open_session() + int smartcard_session_get_reader( + int session, + ffi.Pointer reader, + ) { + return _smartcard_session_get_reader( + session, + reader, + ); + } + + late final _smartcard_session_get_reader_ptr = + _lookup>( + 'smartcard_session_get_reader'); + late final _dart_smartcard_session_get_reader _smartcard_session_get_reader = + _smartcard_session_get_reader_ptr + .asFunction<_dart_smartcard_session_get_reader>(); + + /// @brief Gets the Answer to Reset(ATR) of this Secure Element. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/secureelement + /// @ingroup CAPI_NETWORK_SMARTCARD_SESSION_MODULE + /// + /// @remarks atr must be released using free(). + /// @remarks If the Answer to Reset(ATR) for this Secure Element is not available the returned length is set to zero and return value is Success. + /// + /// @param [in] session Handle to the session + /// @param [out] atr Byte array to retrieve the Answer to Reset(ATR) + /// @param [out] length The length of atr + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// @retval #SMARTCARD_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see smartcard_reader_open_session() + int smartcard_session_get_atr( + int session, + ffi.Pointer> atr, + ffi.Pointer length, + ) { + return _smartcard_session_get_atr( + session, + atr, + length, + ); + } + + late final _smartcard_session_get_atr_ptr = + _lookup>( + 'smartcard_session_get_atr'); + late final _dart_smartcard_session_get_atr _smartcard_session_get_atr = + _smartcard_session_get_atr_ptr + .asFunction<_dart_smartcard_session_get_atr>(); + + /// @brief Closes the connection with the Secure Element. + /// @details This will close any channels opened by this application with this Secure Element. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/secureelement + /// @ingroup CAPI_NETWORK_SMARTCARD_SESSION_MODULE + /// + /// @param [in] session handle to the session + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_IO_ERROR I/O error + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// @retval #SMARTCARD_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see smartcard_reader_open_session() + int smartcard_session_close( + int session, + ) { + return _smartcard_session_close( + session, + ); + } + + late final _smartcard_session_close_ptr = + _lookup>( + 'smartcard_session_close'); + late final _dart_smartcard_session_close _smartcard_session_close = + _smartcard_session_close_ptr.asFunction<_dart_smartcard_session_close>(); + + /// @brief Checks if the given session is closed. + /// @since_tizen 2.3.1 + /// @ingroup CAPI_NETWORK_SMARTCARD_SESSION_MODULE + /// + /// @param [in] session Handle to the session + /// @param [out] is_closed True or false depending on the session state + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// + /// @see smartcard_reader_open_session() + int smartcard_session_is_closed( + int session, + ffi.Pointer is_closed, + ) { + return _smartcard_session_is_closed( + session, + is_closed, + ); + } + + late final _smartcard_session_is_closed_ptr = + _lookup>( + 'smartcard_session_is_closed'); + late final _dart_smartcard_session_is_closed _smartcard_session_is_closed = + _smartcard_session_is_closed_ptr + .asFunction<_dart_smartcard_session_is_closed>(); + + /// @brief Closes any channel opened on the given session. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/secureelement + /// @ingroup CAPI_NETWORK_SMARTCARD_SESSION_MODULE + /// + /// @param [in] session Handle to the session + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_IO_ERROR I/O error + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// @retval #SMARTCARD_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see smartcard_reader_open_session() + int smartcard_session_close_channels( + int session, + ) { + return _smartcard_session_close_channels( + session, + ); + } + + late final _smartcard_session_close_channels_ptr = + _lookup>( + 'smartcard_session_close_channels'); + late final _dart_smartcard_session_close_channels + _smartcard_session_close_channels = _smartcard_session_close_channels_ptr + .asFunction<_dart_smartcard_session_close_channels>(); + + /// @brief Gets an access to the basic channel, as defined in the ISO/IEC 7816-4 specification (the one that has number 0). + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/secureelement + /// @ingroup CAPI_NETWORK_SMARTCARD_SESSION_MODULE + /// + /// @remarks ex) unsigned char aid[] = {0xA0, 0x00, 0x00, 0x00, 0x63, 0x50, 0x4B, 0x43, 0x53, 0x2D, 0x31, 0x35}; + /// @remarks If the Application ID(AID) is null, it means no Applet is to be selected on this channel and the default Applet is used. + /// @remarks Opening of the basic channel to a specific applet is NOT allowed for UICC. + /// + /// @param [in] session Handle to the session + /// @param [in] aid Byte array containing the Application ID(AID) to be selected on the given channel + /// @param [in] aid_len Size of byte array or 0 when no SELECT should be executed + /// @param [in] P2 P2 byte of the SELECT command if executed + /// @param [out] channel Handle of the basic channel + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_CHANNEL_NOT_AVAILABLE No channel available + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_NO_SUCH_ELEMENT No such element error + /// @retval #SMARTCARD_ERROR_IO_ERROR I/O error + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// @retval #SMARTCARD_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see smartcard_reader_open_session() + int smartcard_session_open_basic_channel( + int session, + ffi.Pointer aid, + int aid_len, + int P2, + ffi.Pointer channel, + ) { + return _smartcard_session_open_basic_channel( + session, + aid, + aid_len, + P2, + channel, + ); + } + + late final _smartcard_session_open_basic_channel_ptr = + _lookup>( + 'smartcard_session_open_basic_channel'); + late final _dart_smartcard_session_open_basic_channel + _smartcard_session_open_basic_channel = + _smartcard_session_open_basic_channel_ptr + .asFunction<_dart_smartcard_session_open_basic_channel>(); + + /// @brief Open a logical channel with the Secure Element, selecting the Applet represented by the given Application ID(AID). + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/secureelement + /// @ingroup CAPI_NETWORK_SMARTCARD_SESSION_MODULE + /// + /// @remarks ex) unsigned char aid[] = {0xA0, 0x00, 0x00, 0x00, 0x63, 0x50, 0x4B, 0x43, 0x53, 0x2D, 0x31, 0x35}; + /// @remarks If the Application ID(AID) is null, it means no Applet is to be selected on this channel and the default Applet is used. + /// + /// @param [in] session Handle to the session + /// @param [in] aid Byte array containing the Application ID(AID) to be selected on the given channel + /// @param [in] aid_len Size of byte array or 0 when no SELECT should be executed + /// @param [in] P2 P2 byte of the SELECT command if executed + /// @param [out] channel Handle of the new logical channel + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_CHANNEL_NOT_AVAILABLE No channel available + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_NO_SUCH_ELEMENT No such element error + /// @retval #SMARTCARD_ERROR_IO_ERROR I/O error + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// @retval #SMARTCARD_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see smartcard_reader_open_session() + int smartcard_session_open_logical_channel( + int session, + ffi.Pointer aid, + int aid_len, + int P2, + ffi.Pointer channel, + ) { + return _smartcard_session_open_logical_channel( + session, + aid, + aid_len, + P2, + channel, + ); + } + + late final _smartcard_session_open_logical_channel_ptr = + _lookup>( + 'smartcard_session_open_logical_channel'); + late final _dart_smartcard_session_open_logical_channel + _smartcard_session_open_logical_channel = + _smartcard_session_open_logical_channel_ptr + .asFunction<_dart_smartcard_session_open_logical_channel>(); + + /// @brief Closes the given channel to the Secure Element. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/secureelement + /// @ingroup CAPI_NETWORK_SMARTCARD_CHANNEL_MODULE + /// + /// @param [in] channel Handle to the channel + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_IO_ERROR I/O error + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// @retval #SMARTCARD_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see smartcard_session_open_basic_channel() + /// @see smartcard_session_open_logical_channel() + int smartcard_channel_close( + int channel, + ) { + return _smartcard_channel_close( + channel, + ); + } + + late final _smartcard_channel_close_ptr = + _lookup>( + 'smartcard_channel_close'); + late final _dart_smartcard_channel_close _smartcard_channel_close = + _smartcard_channel_close_ptr.asFunction<_dart_smartcard_channel_close>(); + + /// @brief Checks if the given channel is the basic channel. + /// @since_tizen 2.3.1 + /// @ingroup CAPI_NETWORK_SMARTCARD_CHANNEL_MODULE + /// + /// @param [in] channel Handle to the channel + /// @param [out] is_basic_channel True or false depending on the channel type + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// + /// @see smartcard_session_open_basic_channel() + /// @see smartcard_session_open_logical_channel() + int smartcard_channel_is_basic_channel( + int channel, + ffi.Pointer is_basic_channel, + ) { + return _smartcard_channel_is_basic_channel( + channel, + is_basic_channel, + ); + } + + late final _smartcard_channel_is_basic_channel_ptr = + _lookup>( + 'smartcard_channel_is_basic_channel'); + late final _dart_smartcard_channel_is_basic_channel + _smartcard_channel_is_basic_channel = + _smartcard_channel_is_basic_channel_ptr + .asFunction<_dart_smartcard_channel_is_basic_channel>(); + + /// @brief Checks if the given channel is closed. + /// @since_tizen 2.3.1 + /// @ingroup CAPI_NETWORK_SMARTCARD_CHANNEL_MODULE + /// + /// @param [in] channel Handle to the channel + /// @param [out] is_closed True or false depending on the channel state + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// + /// @see smartcard_session_open_basic_channel() + /// @see smartcard_session_open_logical_channel() + int smartcard_channel_is_closed( + int channel, + ffi.Pointer is_closed, + ) { + return _smartcard_channel_is_closed( + channel, + is_closed, + ); + } + + late final _smartcard_channel_is_closed_ptr = + _lookup>( + 'smartcard_channel_is_closed'); + late final _dart_smartcard_channel_is_closed _smartcard_channel_is_closed = + _smartcard_channel_is_closed_ptr + .asFunction<_dart_smartcard_channel_is_closed>(); + + /// @brief Gets the response to the select command. + /// @since_tizen 2.3.1 + /// @ingroup CAPI_NETWORK_SMARTCARD_CHANNEL_MODULE + /// + /// @remarks select_resp must be released using free(). + /// + /// @param [in] channel Handle to the channel + /// @param [out] select_resp Byte array to retrieve the SELECT response + /// @param [out] length The length of select_resp + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// + /// @see smartcard_session_open_basic_channel() + /// @see smartcard_session_open_logical_channel() + int smartcard_channel_get_select_response( + int channel, + ffi.Pointer> select_resp, + ffi.Pointer length, + ) { + return _smartcard_channel_get_select_response( + channel, + select_resp, + length, + ); + } + + late final _smartcard_channel_get_select_response_ptr = + _lookup>( + 'smartcard_channel_get_select_response'); + late final _dart_smartcard_channel_get_select_response + _smartcard_channel_get_select_response = + _smartcard_channel_get_select_response_ptr + .asFunction<_dart_smartcard_channel_get_select_response>(); + + /// @brief Gets the session that has opened the given channel. + /// @since_tizen 2.3.1 + /// @ingroup CAPI_NETWORK_SMARTCARD_CHANNEL_MODULE + /// + /// @param [in] channel Handle to the channel + /// @param [out] session Session handle of the given channel + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// + /// @see smartcard_session_open_basic_channel() + /// @see smartcard_session_open_logical_channel() + int smartcard_channel_get_session( + int channel, + ffi.Pointer session, + ) { + return _smartcard_channel_get_session( + channel, + session, + ); + } + + late final _smartcard_channel_get_session_ptr = + _lookup>( + 'smartcard_channel_get_session'); + late final _dart_smartcard_channel_get_session + _smartcard_channel_get_session = _smartcard_channel_get_session_ptr + .asFunction<_dart_smartcard_channel_get_session>(); + + /// @brief Transmits an APDU command (as per ISO/IEC 7816-4) to the Secure Element. + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/secureelement + /// @ingroup CAPI_NETWORK_SMARTCARD_CHANNEL_MODULE + /// + /// @remarks resp must be released using free(). + /// @remarks MANAGE_CHANNEL commands are not allowed. + /// @remarks SELECT by DF Name (P1=04) are not allowed. + /// @remarks bytes with channel numbers are de-masked. + /// + /// @param [in] channel Handle to the channel + /// @param [in] cmd Command APDU to be send to the secure element + /// @param [in] cmd_len Size of command APDU + /// @param [out] resp Byte array for the response APDU plus status words + /// @param [out] length The length of resp + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_ILLEGAL_STATE Illegal state of execution error + /// @retval #SMARTCARD_ERROR_IO_ERROR I/O error + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// @retval #SMARTCARD_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see smartcard_session_open_basic_channel() + /// @see smartcard_session_open_logical_channel() + int smartcard_channel_transmit( + int channel, + ffi.Pointer cmd, + int cmd_len, + ffi.Pointer> resp, + ffi.Pointer length, + ) { + return _smartcard_channel_transmit( + channel, + cmd, + cmd_len, + resp, + length, + ); + } + + late final _smartcard_channel_transmit_ptr = + _lookup>( + 'smartcard_channel_transmit'); + late final _dart_smartcard_channel_transmit _smartcard_channel_transmit = + _smartcard_channel_transmit_ptr + .asFunction<_dart_smartcard_channel_transmit>(); + + /// @brief Helper function to retrieves the response APDU of the previous transmit() call + /// @since_tizen 2.3.1 + /// @ingroup CAPI_NETWORK_SMARTCARD_CHANNEL_MODULE + /// + /// @remarks resp must be released using free(). + /// + /// @param [in] channel Handle to the channel + /// @param [out] resp Byte array for the response APDU plus status words + /// @param [out] length The length of resp + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_ILLEGAL_STATE Illegal state of execution error + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// + /// @see smartcard_session_open_basic_channel() + /// @see smartcard_session_open_logical_channel() + int smartcard_channel_transmit_retrieve_response( + int channel, + ffi.Pointer> resp, + ffi.Pointer length, + ) { + return _smartcard_channel_transmit_retrieve_response( + channel, + resp, + length, + ); + } + + late final _smartcard_channel_transmit_retrieve_response_ptr = _lookup< + ffi.NativeFunction<_c_smartcard_channel_transmit_retrieve_response>>( + 'smartcard_channel_transmit_retrieve_response'); + late final _dart_smartcard_channel_transmit_retrieve_response + _smartcard_channel_transmit_retrieve_response = + _smartcard_channel_transmit_retrieve_response_ptr + .asFunction<_dart_smartcard_channel_transmit_retrieve_response>(); + + /// @brief Performs a selection of the next Applet on the given channel that matches to the partial Application ID(AID) + /// @since_tizen 2.3.1 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/secureelement + /// @ingroup CAPI_NETWORK_SMARTCARD_CHANNEL_MODULE + /// + /// @param [in] channel Handle to the channel + /// @param [out] is_success True or false depending whether another applet with the partial Application ID(AID) + /// could be selected on the given channel + /// + /// @return 0 on success, otherwise a negative error value. + /// @retval #SMARTCARD_ERROR_NONE Successful + /// @retval #SMARTCARD_ERROR_GENERAL A general error occurred + /// @retval #SMARTCARD_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #SMARTCARD_ERROR_ILLEGAL_STATE Illegal state of execution error + /// @retval #SMARTCARD_ERROR_OPERATION_NOT_SUPPORTED Operation not supported from SE + /// @retval #SMARTCARD_ERROR_IO_ERROR I/O error + /// @retval #SMARTCARD_ERROR_NOT_INITIALIZED Smartcard service not initialized + /// @retval #SMARTCARD_ERROR_NOT_SUPPORTED Not supported + /// @retval #SMARTCARD_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see smartcard_session_open_basic_channel() + /// @see smartcard_session_open_logical_channel() + int smartcard_channel_select_next( + int channel, + ffi.Pointer is_success, + ) { + return _smartcard_channel_select_next( + channel, + is_success, + ); + } + + late final _smartcard_channel_select_next_ptr = + _lookup>( + 'smartcard_channel_select_next'); + late final _dart_smartcard_channel_select_next + _smartcard_channel_select_next = _smartcard_channel_select_next_ptr + .asFunction<_dart_smartcard_channel_select_next>(); + + /// @brief Initializes Wi-Fi. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @remarks You must release @a wifi using wifi_manager_deinitialize(). + /// @param[out] wifi The Wi-Fi handle + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_ALREADY_INITIALIZED Already initialized + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_initialize( + ffi.Pointer> wifi, + ) { + return _wifi_manager_initialize( + wifi, + ); + } + + late final _wifi_manager_initialize_ptr = + _lookup>( + 'wifi_manager_initialize'); + late final _dart_wifi_manager_initialize _wifi_manager_initialize = + _wifi_manager_initialize_ptr.asFunction<_dart_wifi_manager_initialize>(); + + /// @brief Deinitializes Wi-Fi. + /// @since_tizen 3.0 + /// @param[in] wifi The Wi-Fi handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_deinitialize( + ffi.Pointer wifi, + ) { + return _wifi_manager_deinitialize( + wifi, + ); + } + + late final _wifi_manager_deinitialize_ptr = + _lookup>( + 'wifi_manager_deinitialize'); + late final _dart_wifi_manager_deinitialize _wifi_manager_deinitialize = + _wifi_manager_deinitialize_ptr + .asFunction<_dart_wifi_manager_deinitialize>(); + + /// @brief Activates Wi-Fi asynchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set \n + /// %http://tizen.org/privilege/network.get + /// @remarks This function needs both privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called \n + /// This can be @c NULL if you don't want to get the notification. + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_SECURITY_RESTRICTED Restricted by security system policy + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post wifi_manager_activated_cb() will be invoked. + /// @see wifi_manager_activated_cb() + /// @see wifi_manager_deactivate() + int wifi_manager_activate( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_activate( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_activate_ptr = + _lookup>( + 'wifi_manager_activate'); + late final _dart_wifi_manager_activate _wifi_manager_activate = + _wifi_manager_activate_ptr.asFunction<_dart_wifi_manager_activate>(); + + /// @brief Activates Wi-Fi asynchronously and displays Wi-Fi picker (popup) when Wi-Fi is not automatically connected. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set \n + /// %http://tizen.org/privilege/network.get + /// @remarks This function needs both privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called \n + /// This can be @c NULL if you don't want to get the notification. + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_SECURITY_RESTRICTED Restricted by security system policy + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post wifi_manager_activated_cb() will be invoked. + /// @see wifi_manager_activated_cb() + /// @see wifi_manager_deactivate() + int wifi_manager_activate_with_wifi_picker_tested( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_activate_with_wifi_picker_tested( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_activate_with_wifi_picker_tested_ptr = _lookup< + ffi.NativeFunction<_c_wifi_manager_activate_with_wifi_picker_tested>>( + 'wifi_manager_activate_with_wifi_picker_tested'); + late final _dart_wifi_manager_activate_with_wifi_picker_tested + _wifi_manager_activate_with_wifi_picker_tested = + _wifi_manager_activate_with_wifi_picker_tested_ptr + .asFunction<_dart_wifi_manager_activate_with_wifi_picker_tested>(); + + /// @brief Deactivates Wi-Fi asynchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set \n + /// %http://tizen.org/privilege/network.get + /// @remarks This function needs both privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called \n + /// This can be @c NULL if you don't want to get the notification. + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post wifi_manager_deactivated_cb() will be invoked. + /// @see wifi_manager_deactivated_cb() + /// @see wifi_manager_activate() + int wifi_manager_deactivate( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_deactivate( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_deactivate_ptr = + _lookup>( + 'wifi_manager_deactivate'); + late final _dart_wifi_manager_deactivate _wifi_manager_deactivate = + _wifi_manager_deactivate_ptr.asFunction<_dart_wifi_manager_deactivate>(); + + /// @brief Checks whether Wi-Fi is activated. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @param[in] wifi The Wi-Fi handle + /// @param[out] activated @c true if Wi-Fi is activated, + /// otherwise @c false if Wi-Fi is not activated. + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_is_activated( + ffi.Pointer wifi, + ffi.Pointer activated, + ) { + return _wifi_manager_is_activated( + wifi, + activated, + ); + } + + late final _wifi_manager_is_activated_ptr = + _lookup>( + 'wifi_manager_is_activated'); + late final _dart_wifi_manager_is_activated _wifi_manager_is_activated = + _wifi_manager_is_activated_ptr + .asFunction<_dart_wifi_manager_is_activated>(); + + /// @brief Gets the local MAC address. + /// @since_tizen 3.0 + /// @remarks You must release @a mac_address using free(). + /// @param[in] wifi The Wi-Fi handle + /// @param[out] mac_address The MAC address + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_get_mac_address( + ffi.Pointer wifi, + ffi.Pointer> mac_address, + ) { + return _wifi_manager_get_mac_address( + wifi, + mac_address, + ); + } + + late final _wifi_manager_get_mac_address_ptr = + _lookup>( + 'wifi_manager_get_mac_address'); + late final _dart_wifi_manager_get_mac_address _wifi_manager_get_mac_address = + _wifi_manager_get_mac_address_ptr + .asFunction<_dart_wifi_manager_get_mac_address>(); + + /// @brief Gets the name of the network interface. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @remarks You must release @a name using free(). + /// @param[in] wifi The Wi-Fi handle + /// @param[out] name The name of network interface + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_get_network_interface_name( + ffi.Pointer wifi, + ffi.Pointer> name, + ) { + return _wifi_manager_get_network_interface_name( + wifi, + name, + ); + } + + late final _wifi_manager_get_network_interface_name_ptr = + _lookup>( + 'wifi_manager_get_network_interface_name'); + late final _dart_wifi_manager_get_network_interface_name + _wifi_manager_get_network_interface_name = + _wifi_manager_get_network_interface_name_ptr + .asFunction<_dart_wifi_manager_get_network_interface_name>(); + + /// @brief Starts scan asynchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set \n + /// %http://tizen.org/privilege/network.get + /// @remarks This function needs both privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes wifi_manager_scan_finished_cb(). + int wifi_manager_scan( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_scan( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_scan_ptr = + _lookup>('wifi_manager_scan'); + late final _dart_wifi_manager_scan _wifi_manager_scan = + _wifi_manager_scan_ptr.asFunction<_dart_wifi_manager_scan>(); + + /// @brief Gets the Wi-Fi scan state. + /// @since_tizen 4.0 + /// @param[in] wifi The Wi-Fi handle + /// @param[in] scan_state The Wi-Fi scan state + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_get_scan_state( + ffi.Pointer wifi, + ffi.Pointer scan_state, + ) { + return _wifi_manager_get_scan_state( + wifi, + scan_state, + ); + } + + late final _wifi_manager_get_scan_state_ptr = + _lookup>( + 'wifi_manager_get_scan_state'); + late final _dart_wifi_manager_get_scan_state _wifi_manager_get_scan_state = + _wifi_manager_get_scan_state_ptr + .asFunction<_dart_wifi_manager_get_scan_state>(); + + /// @brief Starts specific AP scan, asynchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set \n + /// %http://tizen.org/privilege/network.get + /// @remarks This function needs both privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] essid The essid of specific AP + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value. + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes wifi_manager_scan_finished_cb(). + int wifi_manager_scan_specific_ap( + ffi.Pointer wifi, + ffi.Pointer essid, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_scan_specific_ap( + wifi, + essid, + callback, + user_data, + ); + } + + late final _wifi_manager_scan_specific_ap_ptr = + _lookup>( + 'wifi_manager_scan_specific_ap'); + late final _dart_wifi_manager_scan_specific_ap + _wifi_manager_scan_specific_ap = _wifi_manager_scan_specific_ap_ptr + .asFunction<_dart_wifi_manager_scan_specific_ap>(); + + /// @brief Creates a Wi-Fi specific AP scan handle. + /// @since_tizen 4.0 + /// @remarks You must release @a specific_scan using wifi_manager_specific_scan_destroy(). + /// @param[in] wifi The Wi-Fi handle + /// @param[out] specific_scan The Wi-Fi specific AP scan handle + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @pre This function needs a wifi_manager_initialize() call before use. + /// @see wifi_manager_specific_scan_create() + int wifi_manager_specific_scan_create( + ffi.Pointer wifi, + ffi.Pointer> specific_scan, + ) { + return _wifi_manager_specific_scan_create( + wifi, + specific_scan, + ); + } + + late final _wifi_manager_specific_scan_create_ptr = + _lookup>( + 'wifi_manager_specific_scan_create'); + late final _dart_wifi_manager_specific_scan_create + _wifi_manager_specific_scan_create = + _wifi_manager_specific_scan_create_ptr + .asFunction<_dart_wifi_manager_specific_scan_create>(); + + /// @brief Destroys a Wi-Fi specific AP scan handle. + /// @since_tizen 4.0 + /// @param[in] wifi The Wi-Fi handle + /// @param[in] specific_scan The Wi-Fi specific AP scan handle + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @pre This function needs a wifi_manager_initialize() call before use. + /// @see wifi_manager_specific_scan_destroy() + int wifi_manager_specific_scan_destroy( + ffi.Pointer wifi, + ffi.Pointer specific_scan, + ) { + return _wifi_manager_specific_scan_destroy( + wifi, + specific_scan, + ); + } + + late final _wifi_manager_specific_scan_destroy_ptr = + _lookup>( + 'wifi_manager_specific_scan_destroy'); + late final _dart_wifi_manager_specific_scan_destroy + _wifi_manager_specific_scan_destroy = + _wifi_manager_specific_scan_destroy_ptr + .asFunction<_dart_wifi_manager_specific_scan_destroy>(); + + /// @brief Sets the SSID of a specific AP scan. + /// @since_tizen 4.0 + /// @param[in] specific_scan The Wi-Fi specific AP scan handle + /// @param[in] essid The SSID of specific AP scan + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_specific_scan_set_ssid() + int wifi_manager_specific_scan_set_ssid( + ffi.Pointer specific_scan, + ffi.Pointer essid, + ) { + return _wifi_manager_specific_scan_set_ssid( + specific_scan, + essid, + ); + } + + late final _wifi_manager_specific_scan_set_ssid_ptr = + _lookup>( + 'wifi_manager_specific_scan_set_ssid'); + late final _dart_wifi_manager_specific_scan_set_ssid + _wifi_manager_specific_scan_set_ssid = + _wifi_manager_specific_scan_set_ssid_ptr + .asFunction<_dart_wifi_manager_specific_scan_set_ssid>(); + + /// @brief Sets the channel frequency of a specific AP scan. + /// @since_tizen 4.0 + /// @param[in] specific_scan The Wi-Fi specific AP scan handle + /// @param[in] freq The channel frequency of specific AP scan + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_specific_scan_set_freq() + int wifi_manager_specific_scan_set_freq( + ffi.Pointer specific_scan, + int freq, + ) { + return _wifi_manager_specific_scan_set_freq( + specific_scan, + freq, + ); + } + + late final _wifi_manager_specific_scan_set_freq_ptr = + _lookup>( + 'wifi_manager_specific_scan_set_freq'); + late final _dart_wifi_manager_specific_scan_set_freq + _wifi_manager_specific_scan_set_freq = + _wifi_manager_specific_scan_set_freq_ptr + .asFunction<_dart_wifi_manager_specific_scan_set_freq>(); + + /// @brief Starts multi SSID and multi channel specific scan, asynchronously. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set \n + /// %http://tizen.org/privilege/network.get + /// @remarks This function needs both privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] specific_scan The Wi-Fi specific AP scan handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value. + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes wifi_manager_scan_finished_cb(). + int wifi_manager_specific_ap_start_multi_scan( + ffi.Pointer wifi, + ffi.Pointer specific_scan, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_specific_ap_start_multi_scan( + wifi, + specific_scan, + callback, + user_data, + ); + } + + late final _wifi_manager_specific_ap_start_multi_scan_ptr = + _lookup>( + 'wifi_manager_specific_ap_start_multi_scan'); + late final _dart_wifi_manager_specific_ap_start_multi_scan + _wifi_manager_specific_ap_start_multi_scan = + _wifi_manager_specific_ap_start_multi_scan_ptr + .asFunction<_dart_wifi_manager_specific_ap_start_multi_scan>(); + + /// @brief Connects to the hidden AP, asynchronously. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set \n + /// %http://tizen.org/privilege/network.get \n + /// %http://tizen.org/privilege/network.profile + /// @remarks This function needs all listed privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] essid The ESSID of the hidden AP + /// @param[in] sec_type The security type of the hidden AP + /// @param[in] passphrase The passphrase of the hidden AP + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value. + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @pre This function needs wifi_manager_scan() before use. + /// @post This function invokes wifi_manager_connected_cb(). + int wifi_manager_connect_hidden_ap( + ffi.Pointer wifi, + ffi.Pointer essid, + int sec_type, + ffi.Pointer passphrase, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_connect_hidden_ap( + wifi, + essid, + sec_type, + passphrase, + callback, + user_data, + ); + } + + late final _wifi_manager_connect_hidden_ap_ptr = + _lookup>( + 'wifi_manager_connect_hidden_ap'); + late final _dart_wifi_manager_connect_hidden_ap + _wifi_manager_connect_hidden_ap = _wifi_manager_connect_hidden_ap_ptr + .asFunction<_dart_wifi_manager_connect_hidden_ap>(); + + /// @brief Gets the handle of the connected access point. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @remarks You must release @a ap using wifi_manager_ap_destroy(). + /// @param[in] wifi The Wi-Fi handle + /// @param[out] ap The access point handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NO_CONNECTION There is no connected AP + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_get_connected_ap( + ffi.Pointer wifi, + ffi.Pointer> ap, + ) { + return _wifi_manager_get_connected_ap( + wifi, + ap, + ); + } + + late final _wifi_manager_get_connected_ap_ptr = + _lookup>( + 'wifi_manager_get_connected_ap'); + late final _dart_wifi_manager_get_connected_ap + _wifi_manager_get_connected_ap = _wifi_manager_get_connected_ap_ptr + .asFunction<_dart_wifi_manager_get_connected_ap>(); + + /// @brief Gets the result of the scan. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback to be called + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes wifi_manager_found_ap_cb(). + int wifi_manager_foreach_found_ap( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_foreach_found_ap( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_foreach_found_ap_ptr = + _lookup>( + 'wifi_manager_foreach_found_ap'); + late final _dart_wifi_manager_foreach_found_ap + _wifi_manager_foreach_found_ap = _wifi_manager_foreach_found_ap_ptr + .asFunction<_dart_wifi_manager_foreach_found_ap>(); + + /// @brief Gets the result of specific AP scan. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback to be called + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value. + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes wifi_manager_found_ap_cb(). + /// @see wifi_manager_scan_specific_ap() + int wifi_manager_foreach_found_specific_ap( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_foreach_found_specific_ap( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_foreach_found_specific_ap_ptr = + _lookup>( + 'wifi_manager_foreach_found_specific_ap'); + late final _dart_wifi_manager_foreach_found_specific_ap + _wifi_manager_foreach_found_specific_ap = + _wifi_manager_foreach_found_specific_ap_ptr + .asFunction<_dart_wifi_manager_foreach_found_specific_ap>(); + + /// @brief Gets the result of the BSSID scan (i.e. BSSID, ESSID & RSSI). + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback to be called + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes wifi_manager_found_ap_cb(). + /// @see wifi_manager_scan_ap() + /// @see wifi_manager_scan_specific_ap() + int wifi_manager_foreach_found_bssid_ap( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_foreach_found_bssid_ap( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_foreach_found_bssid_ap_ptr = + _lookup>( + 'wifi_manager_foreach_found_bssid_ap'); + late final _dart_wifi_manager_foreach_found_bssid_ap + _wifi_manager_foreach_found_bssid_ap = + _wifi_manager_foreach_found_bssid_ap_ptr + .asFunction<_dart_wifi_manager_foreach_found_bssid_ap>(); + + /// @brief Connects to the access point asynchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set \n + /// %http://tizen.org/privilege/network.get + /// @remarks This function needs both privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] ap The access point handle + /// @param[in] callback The callback function to be called \n + /// This can be @c NULL if you don't want to get the notification. + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes wifi_manager_connected_cb(). + /// @see wifi_manager_connected_cb() + /// @see wifi_manager_connect_by_wps_pbc() + /// @see wifi_manager_connect_by_wps_pin() + /// @see wifi_manager_disconnect() + int wifi_manager_connect( + ffi.Pointer wifi, + ffi.Pointer ap, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_connect( + wifi, + ap, + callback, + user_data, + ); + } + + late final _wifi_manager_connect_ptr = + _lookup>( + 'wifi_manager_connect'); + late final _dart_wifi_manager_connect _wifi_manager_connect = + _wifi_manager_connect_ptr.asFunction<_dart_wifi_manager_connect>(); + + /// @brief Disconnects to the access point asynchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set \n + /// %http://tizen.org/privilege/network.get + /// @remarks This function needs both privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] ap The access point handle + /// @param[in] callback The callback function to be called \n + /// This can be @c NULL if you don't want to get the notification. + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes wifi_manager_disconnected_cb(). + /// @see wifi_manager_disconnected_cb() + /// @see wifi_manager_connect_by_wps_pbc() + /// @see wifi_manager_connect_by_wps_pin() + /// @see wifi_manager_connect() + int wifi_manager_disconnect( + ffi.Pointer wifi, + ffi.Pointer ap, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_disconnect( + wifi, + ap, + callback, + user_data, + ); + } + + late final _wifi_manager_disconnect_ptr = + _lookup>( + 'wifi_manager_disconnect'); + late final _dart_wifi_manager_disconnect _wifi_manager_disconnect = + _wifi_manager_disconnect_ptr.asFunction<_dart_wifi_manager_disconnect>(); + + /// @brief Connects to the access point with WPS PBC asynchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.profile \n + /// %http://tizen.org/privilege/network.get + /// @remarks This function needs both privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] ap The access point handle + /// @param[in] callback The callback function to be called \n + /// This can be NULL if you don't want to get the notification. + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes wifi_manager_connected_cb(). + /// @see wifi_manager_connected_cb() + /// @see wifi_manager_connect() + /// @see wifi_manager_disconnect() + /// @see wifi_manager_ap_is_wps_supported() + int wifi_manager_connect_by_wps_pbc( + ffi.Pointer wifi, + ffi.Pointer ap, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_connect_by_wps_pbc( + wifi, + ap, + callback, + user_data, + ); + } + + late final _wifi_manager_connect_by_wps_pbc_ptr = + _lookup>( + 'wifi_manager_connect_by_wps_pbc'); + late final _dart_wifi_manager_connect_by_wps_pbc + _wifi_manager_connect_by_wps_pbc = _wifi_manager_connect_by_wps_pbc_ptr + .asFunction<_dart_wifi_manager_connect_by_wps_pbc>(); + + /// @brief Connects to the access point with WPS PIN asynchronously. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.profile \n + /// %http://tizen.org/privilege/network.get + /// @remarks This function needs both privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] ap The access point handle + /// @param[in] pin The WPS PIN is a non-NULL string with length greater than 0 and less than or equal to 8 + /// @param[in] callback The callback function to be called (this can be NULL if you don't want to get the notification) + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes wifi_manager_connected_cb(). + /// @see wifi_manager_connected_cb() + /// @see wifi_manager_connect() + /// @see wifi_manager_disconnect() + /// @see wifi_manager_ap_is_wps_supported() + int wifi_manager_connect_by_wps_pin( + ffi.Pointer wifi, + ffi.Pointer ap, + ffi.Pointer pin, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_connect_by_wps_pin( + wifi, + ap, + pin, + callback, + user_data, + ); + } + + late final _wifi_manager_connect_by_wps_pin_ptr = + _lookup>( + 'wifi_manager_connect_by_wps_pin'); + late final _dart_wifi_manager_connect_by_wps_pin + _wifi_manager_connect_by_wps_pin = _wifi_manager_connect_by_wps_pin_ptr + .asFunction<_dart_wifi_manager_connect_by_wps_pin>(); + + /// @brief Connects to the access point with WPS PBC without entering SSID. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set \n + /// %http://tizen.org/privilege/network.get \n + /// %http://tizen.org/privilege/network.profile + /// @remarks This function needs all listed privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called \n + /// This can be NULL if you don't want to get the notification. + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes wifi_connected_cb(). + /// @see wifi_manager_connected_cb() + /// @see wifi_manager_connect() + /// @see wifi_manager_disconnect() + /// @see wifi_manager_ap_is_wps_supported() + int wifi_manager_connect_by_wps_pbc_without_ssid( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_connect_by_wps_pbc_without_ssid( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_connect_by_wps_pbc_without_ssid_ptr = _lookup< + ffi.NativeFunction<_c_wifi_manager_connect_by_wps_pbc_without_ssid>>( + 'wifi_manager_connect_by_wps_pbc_without_ssid'); + late final _dart_wifi_manager_connect_by_wps_pbc_without_ssid + _wifi_manager_connect_by_wps_pbc_without_ssid = + _wifi_manager_connect_by_wps_pbc_without_ssid_ptr + .asFunction<_dart_wifi_manager_connect_by_wps_pbc_without_ssid>(); + + /// @brief Connects to the access point with WPS PIN without entering SSID. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set \n + /// %http://tizen.org/privilege/network.get \n + /// %http://tizen.org/privilege/network.profile + /// @remarks This function needs all listed privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] pin The WPS PIN, a non-NULL string with length greater \n + /// than 0 and less than or equal to 8 + /// @param[in] callback The callback function to be called \n + /// This can be NULL if you don't want to get the notification. + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes wifi_connected_cb(). + /// @see wifi_manager_connected_cb() + /// @see wifi_manager_connect() + /// @see wifi_manager_disconnect() + /// @see wifi_manager_ap_is_wps_supported() + int wifi_manager_connect_by_wps_pin_without_ssid( + ffi.Pointer wifi, + ffi.Pointer pin, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_connect_by_wps_pin_without_ssid( + wifi, + pin, + callback, + user_data, + ); + } + + late final _wifi_manager_connect_by_wps_pin_without_ssid_ptr = _lookup< + ffi.NativeFunction<_c_wifi_manager_connect_by_wps_pin_without_ssid>>( + 'wifi_manager_connect_by_wps_pin_without_ssid'); + late final _dart_wifi_manager_connect_by_wps_pin_without_ssid + _wifi_manager_connect_by_wps_pin_without_ssid = + _wifi_manager_connect_by_wps_pin_without_ssid_ptr + .asFunction<_dart_wifi_manager_connect_by_wps_pin_without_ssid>(); + + /// @brief Stops ongoing WPS provisioning / disconnects from the connected access point. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set \n + /// %http://tizen.org/privilege/network.get + /// @remarks This function needs both privileges. + /// @param[in] wifi The Wi-Fi handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_cancel_wps( + ffi.Pointer wifi, + ) { + return _wifi_manager_cancel_wps( + wifi, + ); + } + + late final _wifi_manager_cancel_wps_ptr = + _lookup>( + 'wifi_manager_cancel_wps'); + late final _dart_wifi_manager_cancel_wps _wifi_manager_cancel_wps = + _wifi_manager_cancel_wps_ptr.asFunction<_dart_wifi_manager_cancel_wps>(); + + /// @brief Deletes the information of a stored access point and disconnects from it if it was connected to. + /// @details If an AP is connected to, then connection information will be stored. + /// This information is used when a connection to that AP is established automatically. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.profile \n + /// %http://tizen.org/privilege/network.get + /// @remarks This function needs both privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] ap The access point handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_forget_ap( + ffi.Pointer wifi, + ffi.Pointer ap, + ) { + return _wifi_manager_forget_ap( + wifi, + ap, + ); + } + + late final _wifi_manager_forget_ap_ptr = + _lookup>( + 'wifi_manager_forget_ap'); + late final _dart_wifi_manager_forget_ap _wifi_manager_forget_ap = + _wifi_manager_forget_ap_ptr.asFunction<_dart_wifi_manager_forget_ap>(); + + /// @brief Updates an existing AP. + /// @details When a AP is changed, these changes will be not applied to the Connection Manager immediately. + /// When you call this function, your changes affect the Connection Manager and the existing AP is updated. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.profile \n + /// %http://tizen.org/privilege/network.get + /// @remarks This function needs both privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] ap The access point handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_update_ap( + ffi.Pointer wifi, + ffi.Pointer ap, + ) { + return _wifi_manager_update_ap( + wifi, + ap, + ); + } + + late final _wifi_manager_update_ap_ptr = + _lookup>( + 'wifi_manager_update_ap'); + late final _dart_wifi_manager_update_ap _wifi_manager_update_ap = + _wifi_manager_update_ap_ptr.asFunction<_dart_wifi_manager_update_ap>(); + + /// @brief Adds the Wi-Fi Vendor Specific Information Element (VSIE) to a specific frame type. + /// @since_tizen 5.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/network.set + /// @remarks @a vsie_str for @a frame_id will be in effect until Wi-Fi is deactivated. + /// + /// @param[in] wifi The Wi-Fi handle + /// @param[in] frame_id The frame ID for setting VSIE + /// @param[in] vsie_str The VSIE data + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @pre Wi-Fi service must be activated by wifi_manager_activate(). + /// @see wifi_manager_activate() + /// @see wifi_manager_remove_vsie() + /// @see wifi_manager_get_vsie() + int wifi_manager_add_vsie( + ffi.Pointer wifi, + int frame_id, + ffi.Pointer vsie_str, + ) { + return _wifi_manager_add_vsie( + wifi, + frame_id, + vsie_str, + ); + } + + late final _wifi_manager_add_vsie_ptr = + _lookup>( + 'wifi_manager_add_vsie'); + late final _dart_wifi_manager_add_vsie _wifi_manager_add_vsie = + _wifi_manager_add_vsie_ptr.asFunction<_dart_wifi_manager_add_vsie>(); + + /// @brief Gets the Wi-Fi Vendor Specific Information Elements (VSIE) from a specific frame. + /// @since_tizen 5.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/network.get + /// @remarks @a vsie_str must be released with free(). + /// + /// @param[in] wifi The Wi-Fi handle + /// @param[in] frame_id The frame ID for getting VSIE + /// @param[out] vsie_str The VSIE data + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @pre Wi-Fi service must be activated by wifi_manager_activate() + /// and VSIE for a specific frame must be set with wifi_manager_add_vsie(). + /// @see wifi_manager_activate() + /// @see wifi_manager_remove_vsie() + /// @see wifi_manager_add_vsie() + int wifi_manager_get_vsie( + ffi.Pointer wifi, + int frame_id, + ffi.Pointer> vsie_str, + ) { + return _wifi_manager_get_vsie( + wifi, + frame_id, + vsie_str, + ); + } + + late final _wifi_manager_get_vsie_ptr = + _lookup>( + 'wifi_manager_get_vsie'); + late final _dart_wifi_manager_get_vsie _wifi_manager_get_vsie = + _wifi_manager_get_vsie_ptr.asFunction<_dart_wifi_manager_get_vsie>(); + + /// @brief Removes the Wi-Fi Vendor Specific Information Element (VSIE) from specific frame. + /// @since_tizen 5.0 + /// @privlevel public + /// @privilege http://tizen.org/privilege/network.set + /// @remarks @a vsie_str for @a frame_id will be in effect until Wi-Fi is deactivated. + /// + /// @param[in] wifi The wifi handle + /// @param[in] frame_id The frame ID for removing VSIE + /// @param[in] vsie_str The VSIE data + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @pre Wi-Fi service must be activated by wifi_manager_activate() + /// and VSIE for a specific frame must be set with wifi_manager_add_vsie(). + /// @see wifi_manager_activate() + /// @see wifi_manager_get_vsie() + /// @see wifi_manager_add_vsie() + int wifi_manager_remove_vsie( + ffi.Pointer wifi, + int frame_id, + ffi.Pointer vsie_str, + ) { + return _wifi_manager_remove_vsie( + wifi, + frame_id, + vsie_str, + ); + } + + late final _wifi_manager_remove_vsie_ptr = + _lookup>( + 'wifi_manager_remove_vsie'); + late final _dart_wifi_manager_remove_vsie _wifi_manager_remove_vsie = + _wifi_manager_remove_vsie_ptr + .asFunction<_dart_wifi_manager_remove_vsie>(); + + /// @brief Gets the connection state. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @param[in] wifi The Wi-Fi handle + /// @param[out] connection_state The connection state + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_get_connection_state( + ffi.Pointer wifi, + ffi.Pointer connection_state, + ) { + return _wifi_manager_get_connection_state( + wifi, + connection_state, + ); + } + + late final _wifi_manager_get_connection_state_ptr = + _lookup>( + 'wifi_manager_get_connection_state'); + late final _dart_wifi_manager_get_connection_state + _wifi_manager_get_connection_state = + _wifi_manager_get_connection_state_ptr + .asFunction<_dart_wifi_manager_get_connection_state>(); + + /// @brief Registers the callback called when the device state is changed. + /// @since_tizen 3.0 + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_set_device_state_changed_cb( + ffi.Pointer wifi, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_set_device_state_changed_cb( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_set_device_state_changed_cb_ptr = + _lookup>( + 'wifi_manager_set_device_state_changed_cb'); + late final _dart_wifi_manager_set_device_state_changed_cb + _wifi_manager_set_device_state_changed_cb = + _wifi_manager_set_device_state_changed_cb_ptr + .asFunction<_dart_wifi_manager_set_device_state_changed_cb>(); + + /// @brief Unregisters the callback called when the device state is changed. + /// @since_tizen 3.0 + /// @param[in] wifi The Wi-Fi handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_unset_device_state_changed_cb( + ffi.Pointer wifi, + ) { + return _wifi_manager_unset_device_state_changed_cb( + wifi, + ); + } + + late final _wifi_manager_unset_device_state_changed_cb_ptr = _lookup< + ffi.NativeFunction<_c_wifi_manager_unset_device_state_changed_cb>>( + 'wifi_manager_unset_device_state_changed_cb'); + late final _dart_wifi_manager_unset_device_state_changed_cb + _wifi_manager_unset_device_state_changed_cb = + _wifi_manager_unset_device_state_changed_cb_ptr + .asFunction<_dart_wifi_manager_unset_device_state_changed_cb>(); + + /// @brief Registers the callback called when the background scan is finished. + /// @since_tizen 3.0 + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_set_background_scan_cb( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_set_background_scan_cb( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_set_background_scan_cb_ptr = + _lookup>( + 'wifi_manager_set_background_scan_cb'); + late final _dart_wifi_manager_set_background_scan_cb + _wifi_manager_set_background_scan_cb = + _wifi_manager_set_background_scan_cb_ptr + .asFunction<_dart_wifi_manager_set_background_scan_cb>(); + + /// @brief Unregisters the callback called when the scan is finished. + /// @since_tizen 3.0 + /// @param[in] wifi The Wi-Fi handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_unset_background_scan_cb( + ffi.Pointer wifi, + ) { + return _wifi_manager_unset_background_scan_cb( + wifi, + ); + } + + late final _wifi_manager_unset_background_scan_cb_ptr = + _lookup>( + 'wifi_manager_unset_background_scan_cb'); + late final _dart_wifi_manager_unset_background_scan_cb + _wifi_manager_unset_background_scan_cb = + _wifi_manager_unset_background_scan_cb_ptr + .asFunction<_dart_wifi_manager_unset_background_scan_cb>(); + + /// @brief Registers the callback called when the scanning state is changed. + /// @since_tizen 4.0 + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_set_scan_state_changed_cb( + ffi.Pointer wifi, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_set_scan_state_changed_cb( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_set_scan_state_changed_cb_ptr = + _lookup>( + 'wifi_manager_set_scan_state_changed_cb'); + late final _dart_wifi_manager_set_scan_state_changed_cb + _wifi_manager_set_scan_state_changed_cb = + _wifi_manager_set_scan_state_changed_cb_ptr + .asFunction<_dart_wifi_manager_set_scan_state_changed_cb>(); + + /// @brief Unregisters the callback called when the scanning state is changed. + /// @since_tizen 4.0 + /// @param[in] wifi The Wi-Fi handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_unset_scan_state_changed_cb( + ffi.Pointer wifi, + ) { + return _wifi_manager_unset_scan_state_changed_cb( + wifi, + ); + } + + late final _wifi_manager_unset_scan_state_changed_cb_ptr = + _lookup>( + 'wifi_manager_unset_scan_state_changed_cb'); + late final _dart_wifi_manager_unset_scan_state_changed_cb + _wifi_manager_unset_scan_state_changed_cb = + _wifi_manager_unset_scan_state_changed_cb_ptr + .asFunction<_dart_wifi_manager_unset_scan_state_changed_cb>(); + + /// @brief Registers the callback called when the connection state is changed. + /// @since_tizen 3.0 + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_set_connection_state_changed_cb( + ffi.Pointer wifi, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_set_connection_state_changed_cb( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_set_connection_state_changed_cb_ptr = _lookup< + ffi.NativeFunction<_c_wifi_manager_set_connection_state_changed_cb>>( + 'wifi_manager_set_connection_state_changed_cb'); + late final _dart_wifi_manager_set_connection_state_changed_cb + _wifi_manager_set_connection_state_changed_cb = + _wifi_manager_set_connection_state_changed_cb_ptr + .asFunction<_dart_wifi_manager_set_connection_state_changed_cb>(); + + /// @brief Unregisters the callback called when the connection state is changed. + /// @since_tizen 3.0 + /// @param[in] wifi The Wi-Fi handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_unset_connection_state_changed_cb( + ffi.Pointer wifi, + ) { + return _wifi_manager_unset_connection_state_changed_cb( + wifi, + ); + } + + late final _wifi_manager_unset_connection_state_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_wifi_manager_unset_connection_state_changed_cb>>( + 'wifi_manager_unset_connection_state_changed_cb'); + late final _dart_wifi_manager_unset_connection_state_changed_cb + _wifi_manager_unset_connection_state_changed_cb = + _wifi_manager_unset_connection_state_changed_cb_ptr + .asFunction<_dart_wifi_manager_unset_connection_state_changed_cb>(); + + /// @brief Registers callback called when the RSSI of connected Wi-Fi is changed. + /// @since_tizen 3.0 + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_set_rssi_level_changed_cb( + ffi.Pointer wifi, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_set_rssi_level_changed_cb( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_set_rssi_level_changed_cb_ptr = + _lookup>( + 'wifi_manager_set_rssi_level_changed_cb'); + late final _dart_wifi_manager_set_rssi_level_changed_cb + _wifi_manager_set_rssi_level_changed_cb = + _wifi_manager_set_rssi_level_changed_cb_ptr + .asFunction<_dart_wifi_manager_set_rssi_level_changed_cb>(); + + /// @brief Unregisters callback called when the RSSI of connected Wi-Fi is changed. + /// @since_tizen 3.0 + /// @param[in] wifi The Wi-Fi handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_unset_rssi_level_changed_cb( + ffi.Pointer wifi, + ) { + return _wifi_manager_unset_rssi_level_changed_cb( + wifi, + ); + } + + late final _wifi_manager_unset_rssi_level_changed_cb_ptr = + _lookup>( + 'wifi_manager_unset_rssi_level_changed_cb'); + late final _dart_wifi_manager_unset_rssi_level_changed_cb + _wifi_manager_unset_rssi_level_changed_cb = + _wifi_manager_unset_rssi_level_changed_cb_ptr + .asFunction<_dart_wifi_manager_unset_rssi_level_changed_cb>(); + + /// @brief Registers a callback called when the Wi-Fi Module state is changed. + /// @since_tizen 4.0 + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_module_state_changed_cb() + /// @see wifi_manager_unset_module_state_changed_cb() + int wifi_manager_set_module_state_changed_cb( + ffi.Pointer wifi, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_set_module_state_changed_cb( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_set_module_state_changed_cb_ptr = + _lookup>( + 'wifi_manager_set_module_state_changed_cb'); + late final _dart_wifi_manager_set_module_state_changed_cb + _wifi_manager_set_module_state_changed_cb = + _wifi_manager_set_module_state_changed_cb_ptr + .asFunction<_dart_wifi_manager_set_module_state_changed_cb>(); + + /// @brief Unregisters the callback called when the Wi-Fi Module state is changed. + /// @since_tizen 4.0 + /// @param[in] wifi The Wi-Fi handle + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_module_state_changed_cb() + /// @see wifi_manager_set_module_state_changed_cb() + int wifi_manager_unset_module_state_changed_cb( + ffi.Pointer wifi, + ) { + return _wifi_manager_unset_module_state_changed_cb( + wifi, + ); + } + + late final _wifi_manager_unset_module_state_changed_cb_ptr = _lookup< + ffi.NativeFunction<_c_wifi_manager_unset_module_state_changed_cb>>( + 'wifi_manager_unset_module_state_changed_cb'); + late final _dart_wifi_manager_unset_module_state_changed_cb + _wifi_manager_unset_module_state_changed_cb = + _wifi_manager_unset_module_state_changed_cb_ptr + .asFunction<_dart_wifi_manager_unset_module_state_changed_cb>(); + + /// @brief Gets the Wi-Fi Module state. + /// @since_tizen 4.0 + /// @param[in] wifi The Wi-Fi handle + /// @param[out] state The Wi-Fi Module state + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_get_module_state( + ffi.Pointer wifi, + ffi.Pointer state, + ) { + return _wifi_manager_get_module_state( + wifi, + state, + ); + } + + late final _wifi_manager_get_module_state_ptr = + _lookup>( + 'wifi_manager_get_module_state'); + late final _dart_wifi_manager_get_module_state + _wifi_manager_get_module_state = _wifi_manager_get_module_state_ptr + .asFunction<_dart_wifi_manager_get_module_state>(); + + /// @brief Starts BSSID scan asynchronously. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set \n + /// %http://tizen.org/privilege/network.get + /// @remarks This function needs both privileges. + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes wifi_manager_bssid_scan_finished_cb(). + int wifi_manager_bssid_scan( + ffi.Pointer wifi, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_bssid_scan( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_bssid_scan_ptr = + _lookup>( + 'wifi_manager_bssid_scan'); + late final _dart_wifi_manager_bssid_scan _wifi_manager_bssid_scan = + _wifi_manager_bssid_scan_ptr.asFunction<_dart_wifi_manager_bssid_scan>(); + + /// @brief Creates the access point handle. + /// @since_tizen 3.0 + /// @remarks You must release @a ap using wifi_manager_ap_destroy(). + /// @param[in] wifi The Wi-Fi handle + /// @param[in] essid The ESSID (Extended Service Set Identifier) should be null-terminated and can be UTF-8 encoded + /// @param[out] ap The access point handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_ap_destroy() + int wifi_manager_ap_create( + ffi.Pointer wifi, + ffi.Pointer essid, + ffi.Pointer> ap, + ) { + return _wifi_manager_ap_create( + wifi, + essid, + ap, + ); + } + + late final _wifi_manager_ap_create_ptr = + _lookup>( + 'wifi_manager_ap_create'); + late final _dart_wifi_manager_ap_create _wifi_manager_ap_create = + _wifi_manager_ap_create_ptr.asFunction<_dart_wifi_manager_ap_create>(); + + /// @brief Creates the hidden access point handle. + /// @since_tizen 3.0 + /// @remarks You must release @a ap using wifi_manager_ap_destroy(). + /// @param[in] wifi The Wi-Fi handle + /// @param[in] essid The ESSID (Extended Service Set Identifier) should be null-terminated and can be UTF-8 encoded + /// @param[out] ap The access point handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_ap_destroy() + int wifi_manager_ap_hidden_create( + ffi.Pointer wifi, + ffi.Pointer essid, + ffi.Pointer> ap, + ) { + return _wifi_manager_ap_hidden_create( + wifi, + essid, + ap, + ); + } + + late final _wifi_manager_ap_hidden_create_ptr = + _lookup>( + 'wifi_manager_ap_hidden_create'); + late final _dart_wifi_manager_ap_hidden_create + _wifi_manager_ap_hidden_create = _wifi_manager_ap_hidden_create_ptr + .asFunction<_dart_wifi_manager_ap_hidden_create>(); + + /// @brief Destroys the access point handle. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_ap_create() + int wifi_manager_ap_destroy( + ffi.Pointer ap, + ) { + return _wifi_manager_ap_destroy( + ap, + ); + } + + late final _wifi_manager_ap_destroy_ptr = + _lookup>( + 'wifi_manager_ap_destroy'); + late final _dart_wifi_manager_ap_destroy _wifi_manager_ap_destroy = + _wifi_manager_ap_destroy_ptr.asFunction<_dart_wifi_manager_ap_destroy>(); + + /// @brief Clones the access point handle. + /// @since_tizen 3.0 + /// @remarks You must release @a cloned_ap using wifi_manager_ap_destroy(). + /// @param[out] cloned_ap The cloned access point handle + /// @param[in] origin The origin access point handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_ap_destroy() + int wifi_manager_ap_clone( + ffi.Pointer> cloned_ap, + ffi.Pointer origin, + ) { + return _wifi_manager_ap_clone( + cloned_ap, + origin, + ); + } + + late final _wifi_manager_ap_clone_ptr = + _lookup>( + 'wifi_manager_ap_clone'); + late final _dart_wifi_manager_ap_clone _wifi_manager_ap_clone = + _wifi_manager_ap_clone_ptr.asFunction<_dart_wifi_manager_ap_clone>(); + + /// @brief Refreshes the access point information. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @remarks You should call this function in order to get the current access point information, because the information can be changed. + /// @param[in] ap The access point handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_refresh( + ffi.Pointer ap, + ) { + return _wifi_manager_ap_refresh( + ap, + ); + } + + late final _wifi_manager_ap_refresh_ptr = + _lookup>( + 'wifi_manager_ap_refresh'); + late final _dart_wifi_manager_ap_refresh _wifi_manager_ap_refresh = + _wifi_manager_ap_refresh_ptr.asFunction<_dart_wifi_manager_ap_refresh>(); + + /// @brief Gets ESSID (Extended Service Set Identifier). + /// @since_tizen 3.0 + /// @remarks You must release @a essid using free(). + /// @param[in] ap The access point handle + /// @param[out] essid The ESSID + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_essid( + ffi.Pointer ap, + ffi.Pointer> essid, + ) { + return _wifi_manager_ap_get_essid( + ap, + essid, + ); + } + + late final _wifi_manager_ap_get_essid_ptr = + _lookup>( + 'wifi_manager_ap_get_essid'); + late final _dart_wifi_manager_ap_get_essid _wifi_manager_ap_get_essid = + _wifi_manager_ap_get_essid_ptr + .asFunction<_dart_wifi_manager_ap_get_essid>(); + + /// @brief Gets raw SSID (Service Set Identifier). + /// @since_tizen 4.0 + /// @remarks You must release @a ssid using free(). + /// @param[in] ap The access point handle + /// @param[out] ssid The raw SSID bytes + /// @param[out] ssid_len The raw SSID length + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_raw_ssid( + ffi.Pointer ap, + ffi.Pointer> ssid, + ffi.Pointer ssid_len, + ) { + return _wifi_manager_ap_get_raw_ssid( + ap, + ssid, + ssid_len, + ); + } + + late final _wifi_manager_ap_get_raw_ssid_ptr = + _lookup>( + 'wifi_manager_ap_get_raw_ssid'); + late final _dart_wifi_manager_ap_get_raw_ssid _wifi_manager_ap_get_raw_ssid = + _wifi_manager_ap_get_raw_ssid_ptr + .asFunction<_dart_wifi_manager_ap_get_raw_ssid>(); + + /// @brief Gets BSSID (Basic Service Set Identifier). + /// @since_tizen 3.0 + /// @remarks You must release @a bssid using free(). + /// @param[in] ap The access point handle + /// @param[out] bssid The BSSID + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_bssid( + ffi.Pointer ap, + ffi.Pointer> bssid, + ) { + return _wifi_manager_ap_get_bssid( + ap, + bssid, + ); + } + + late final _wifi_manager_ap_get_bssid_ptr = + _lookup>( + 'wifi_manager_ap_get_bssid'); + late final _dart_wifi_manager_ap_get_bssid _wifi_manager_ap_get_bssid = + _wifi_manager_ap_get_bssid_ptr + .asFunction<_dart_wifi_manager_ap_get_bssid>(); + + /// @brief Gets the RSSI. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[out] rssi The RSSI value (in dBm) + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_rssi( + ffi.Pointer ap, + ffi.Pointer rssi, + ) { + return _wifi_manager_ap_get_rssi( + ap, + rssi, + ); + } + + late final _wifi_manager_ap_get_rssi_ptr = + _lookup>( + 'wifi_manager_ap_get_rssi'); + late final _dart_wifi_manager_ap_get_rssi _wifi_manager_ap_get_rssi = + _wifi_manager_ap_get_rssi_ptr + .asFunction<_dart_wifi_manager_ap_get_rssi>(); + + /// @brief Gets the RSSI level. + /// @since_tizen 4.0 + /// @param[in] ap The access point handle + /// @param[out] rssi_level The RSSI level + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_rssi_level( + ffi.Pointer ap, + ffi.Pointer rssi_level, + ) { + return _wifi_manager_ap_get_rssi_level( + ap, + rssi_level, + ); + } + + late final _wifi_manager_ap_get_rssi_level_ptr = + _lookup>( + 'wifi_manager_ap_get_rssi_level'); + late final _dart_wifi_manager_ap_get_rssi_level + _wifi_manager_ap_get_rssi_level = _wifi_manager_ap_get_rssi_level_ptr + .asFunction<_dart_wifi_manager_ap_get_rssi_level>(); + + /// @brief Gets the frequency band (MHz). + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[out] frequency The frequency + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_frequency( + ffi.Pointer ap, + ffi.Pointer frequency, + ) { + return _wifi_manager_ap_get_frequency( + ap, + frequency, + ); + } + + late final _wifi_manager_ap_get_frequency_ptr = + _lookup>( + 'wifi_manager_ap_get_frequency'); + late final _dart_wifi_manager_ap_get_frequency + _wifi_manager_ap_get_frequency = _wifi_manager_ap_get_frequency_ptr + .asFunction<_dart_wifi_manager_ap_get_frequency>(); + + /// @brief Gets the max speed (Mbps). + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[out] max_speed The max speed + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_max_speed( + ffi.Pointer ap, + ffi.Pointer max_speed, + ) { + return _wifi_manager_ap_get_max_speed( + ap, + max_speed, + ); + } + + late final _wifi_manager_ap_get_max_speed_ptr = + _lookup>( + 'wifi_manager_ap_get_max_speed'); + late final _dart_wifi_manager_ap_get_max_speed + _wifi_manager_ap_get_max_speed = _wifi_manager_ap_get_max_speed_ptr + .asFunction<_dart_wifi_manager_ap_get_max_speed>(); + + /// @brief Checks whether the access point is favorite or not. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[out] favorite @c true if access point is favorite, + /// otherwise @c false if access point is not favorite + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_is_favorite( + ffi.Pointer ap, + ffi.Pointer favorite, + ) { + return _wifi_manager_ap_is_favorite( + ap, + favorite, + ); + } + + late final _wifi_manager_ap_is_favorite_ptr = + _lookup>( + 'wifi_manager_ap_is_favorite'); + late final _dart_wifi_manager_ap_is_favorite _wifi_manager_ap_is_favorite = + _wifi_manager_ap_is_favorite_ptr + .asFunction<_dart_wifi_manager_ap_is_favorite>(); + + /// @brief Checks whether the access point is passpoint or not. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[out] passpoint @c true if access point is passpoint, + /// otherwise @c false if access point is not passpoint. + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_is_passpoint( + ffi.Pointer ap, + ffi.Pointer passpoint, + ) { + return _wifi_manager_ap_is_passpoint( + ap, + passpoint, + ); + } + + late final _wifi_manager_ap_is_passpoint_ptr = + _lookup>( + 'wifi_manager_ap_is_passpoint'); + late final _dart_wifi_manager_ap_is_passpoint _wifi_manager_ap_is_passpoint = + _wifi_manager_ap_is_passpoint_ptr + .asFunction<_dart_wifi_manager_ap_is_passpoint>(); + + /// @brief Gets the connection state. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[out] state The connection state + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_connection_state( + ffi.Pointer ap, + ffi.Pointer state, + ) { + return _wifi_manager_ap_get_connection_state( + ap, + state, + ); + } + + late final _wifi_manager_ap_get_connection_state_ptr = + _lookup>( + 'wifi_manager_ap_get_connection_state'); + late final _dart_wifi_manager_ap_get_connection_state + _wifi_manager_ap_get_connection_state = + _wifi_manager_ap_get_connection_state_ptr + .asFunction<_dart_wifi_manager_ap_get_connection_state>(); + + /// @brief Gets the config type of IP. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[out] type The type of IP config + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Address family not supported + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_ip_config_type( + ffi.Pointer ap, + int address_family, + ffi.Pointer type, + ) { + return _wifi_manager_ap_get_ip_config_type( + ap, + address_family, + type, + ); + } + + late final _wifi_manager_ap_get_ip_config_type_ptr = + _lookup>( + 'wifi_manager_ap_get_ip_config_type'); + late final _dart_wifi_manager_ap_get_ip_config_type + _wifi_manager_ap_get_ip_config_type = + _wifi_manager_ap_get_ip_config_type_ptr + .asFunction<_dart_wifi_manager_ap_get_ip_config_type>(); + + /// @brief Sets the config type of IP. + /// @details If you set IP config type to #WIFI_MANAGER_IP_CONFIG_TYPE_STATIC, + /// then IP address, Gateway and Subnet mask will be set to the initial value "0.0.0.0". + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[in] type The type of IP config + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Address family not supported + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_update_ap() + int wifi_manager_ap_set_ip_config_type( + ffi.Pointer ap, + int address_family, + int type, + ) { + return _wifi_manager_ap_set_ip_config_type( + ap, + address_family, + type, + ); + } + + late final _wifi_manager_ap_set_ip_config_type_ptr = + _lookup>( + 'wifi_manager_ap_set_ip_config_type'); + late final _dart_wifi_manager_ap_set_ip_config_type + _wifi_manager_ap_set_ip_config_type = + _wifi_manager_ap_set_ip_config_type_ptr + .asFunction<_dart_wifi_manager_ap_set_ip_config_type>(); + + /// @brief Gets the IP address. + /// @since_tizen 3.0 + /// @remarks You must release @a ip_address using free(). + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[out] ip_address The IP address; this value is for default address \n + /// e.g, IPv6 can have multiple addresses. but you can only obtain a representative address \n + /// if you want to get all IPv6 address, you can use the wifi_manager_ap_foreach_ipv6_address(). + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Address family not supported + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_ap_foreach_ipv6_address() + int wifi_manager_ap_get_ip_address( + ffi.Pointer ap, + int address_family, + ffi.Pointer> ip_address, + ) { + return _wifi_manager_ap_get_ip_address( + ap, + address_family, + ip_address, + ); + } + + late final _wifi_manager_ap_get_ip_address_ptr = + _lookup>( + 'wifi_manager_ap_get_ip_address'); + late final _dart_wifi_manager_ap_get_ip_address + _wifi_manager_ap_get_ip_address = _wifi_manager_ap_get_ip_address_ptr + .asFunction<_dart_wifi_manager_ap_get_ip_address>(); + + /// @brief Sets the IP address. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[in] ip_address The IP address; if you set this value to NULL, then the existing value will be deleted + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Address family not supported + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_update_ap() + int wifi_manager_ap_set_ip_address( + ffi.Pointer ap, + int address_family, + ffi.Pointer ip_address, + ) { + return _wifi_manager_ap_set_ip_address( + ap, + address_family, + ip_address, + ); + } + + late final _wifi_manager_ap_set_ip_address_ptr = + _lookup>( + 'wifi_manager_ap_set_ip_address'); + late final _dart_wifi_manager_ap_set_ip_address + _wifi_manager_ap_set_ip_address = _wifi_manager_ap_set_ip_address_ptr + .asFunction<_dart_wifi_manager_ap_set_ip_address>(); + + /// @brief Gets all IPv6 addresses assigned to the Wi-Fi interface. + /// @since_tizen 4.0 + /// @param[in] ap The access point handle + /// @param[in] callback The callback to be called for each IPv6 address + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value. + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_foreach_ipv6_address( + ffi.Pointer ap, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_ap_foreach_ipv6_address( + ap, + callback, + user_data, + ); + } + + late final _wifi_manager_ap_foreach_ipv6_address_ptr = + _lookup>( + 'wifi_manager_ap_foreach_ipv6_address'); + late final _dart_wifi_manager_ap_foreach_ipv6_address + _wifi_manager_ap_foreach_ipv6_address = + _wifi_manager_ap_foreach_ipv6_address_ptr + .asFunction<_dart_wifi_manager_ap_foreach_ipv6_address>(); + + /// @brief Gets the subnet mask. + /// @since_tizen 3.0 + /// @remarks You must release @a subnet_mask using free(). + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[out] subnet_mask The subnet mask + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Address family not supported + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_subnet_mask( + ffi.Pointer ap, + int address_family, + ffi.Pointer> subnet_mask, + ) { + return _wifi_manager_ap_get_subnet_mask( + ap, + address_family, + subnet_mask, + ); + } + + late final _wifi_manager_ap_get_subnet_mask_ptr = + _lookup>( + 'wifi_manager_ap_get_subnet_mask'); + late final _dart_wifi_manager_ap_get_subnet_mask + _wifi_manager_ap_get_subnet_mask = _wifi_manager_ap_get_subnet_mask_ptr + .asFunction<_dart_wifi_manager_ap_get_subnet_mask>(); + + /// @brief Sets the subnet mask. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[in] subnet_mask The subnet mask; if you set this value to NULL, then the existing value will be deleted + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Address family not supported + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_update_ap() + int wifi_manager_ap_set_subnet_mask( + ffi.Pointer ap, + int address_family, + ffi.Pointer subnet_mask, + ) { + return _wifi_manager_ap_set_subnet_mask( + ap, + address_family, + subnet_mask, + ); + } + + late final _wifi_manager_ap_set_subnet_mask_ptr = + _lookup>( + 'wifi_manager_ap_set_subnet_mask'); + late final _dart_wifi_manager_ap_set_subnet_mask + _wifi_manager_ap_set_subnet_mask = _wifi_manager_ap_set_subnet_mask_ptr + .asFunction<_dart_wifi_manager_ap_set_subnet_mask>(); + + /// @brief Gets the gateway address. + /// @since_tizen 3.0 + /// @remarks You must release @a gateway_address using free(). + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[out] gateway_address The gateway address + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Address family not supported + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_gateway_address( + ffi.Pointer ap, + int address_family, + ffi.Pointer> gateway_address, + ) { + return _wifi_manager_ap_get_gateway_address( + ap, + address_family, + gateway_address, + ); + } + + late final _wifi_manager_ap_get_gateway_address_ptr = + _lookup>( + 'wifi_manager_ap_get_gateway_address'); + late final _dart_wifi_manager_ap_get_gateway_address + _wifi_manager_ap_get_gateway_address = + _wifi_manager_ap_get_gateway_address_ptr + .asFunction<_dart_wifi_manager_ap_get_gateway_address>(); + + /// @brief Sets the gateway address. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[in] gateway_address The gateway address \n + /// If you set this value to @c NULL, then the existing value will be deleted. + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Address family not supported + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_update_ap() + int wifi_manager_ap_set_gateway_address( + ffi.Pointer ap, + int address_family, + ffi.Pointer gateway_address, + ) { + return _wifi_manager_ap_set_gateway_address( + ap, + address_family, + gateway_address, + ); + } + + late final _wifi_manager_ap_set_gateway_address_ptr = + _lookup>( + 'wifi_manager_ap_set_gateway_address'); + late final _dart_wifi_manager_ap_set_gateway_address + _wifi_manager_ap_set_gateway_address = + _wifi_manager_ap_set_gateway_address_ptr + .asFunction<_dart_wifi_manager_ap_set_gateway_address>(); + + /// @brief Gets the DHCP Server address. + /// @since_tizen 4.0 + /// @remarks You must release @a dhcp_server using g_free(). + /// This function is supported only for IPv4 address family. + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[out] dhcp_server The DHCP server address + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_dhcp_server_address( + ffi.Pointer ap, + int address_family, + ffi.Pointer> dhcp_server, + ) { + return _wifi_manager_ap_get_dhcp_server_address( + ap, + address_family, + dhcp_server, + ); + } + + late final _wifi_manager_ap_get_dhcp_server_address_ptr = + _lookup>( + 'wifi_manager_ap_get_dhcp_server_address'); + late final _dart_wifi_manager_ap_get_dhcp_server_address + _wifi_manager_ap_get_dhcp_server_address = + _wifi_manager_ap_get_dhcp_server_address_ptr + .asFunction<_dart_wifi_manager_ap_get_dhcp_server_address>(); + + /// @brief Gets the DHCP lease duration. + /// @since_tizen 4.0 + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[out] dhcp_lease_duration The DHCP lease duration in seconds + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_dhcp_lease_duration( + ffi.Pointer ap, + int address_family, + ffi.Pointer dhcp_lease_duration, + ) { + return _wifi_manager_ap_get_dhcp_lease_duration( + ap, + address_family, + dhcp_lease_duration, + ); + } + + late final _wifi_manager_ap_get_dhcp_lease_duration_ptr = + _lookup>( + 'wifi_manager_ap_get_dhcp_lease_duration'); + late final _dart_wifi_manager_ap_get_dhcp_lease_duration + _wifi_manager_ap_get_dhcp_lease_duration = + _wifi_manager_ap_get_dhcp_lease_duration_ptr + .asFunction<_dart_wifi_manager_ap_get_dhcp_lease_duration>(); + + /// @brief Gets the proxy address. + /// @since_tizen 3.0 + /// @remarks You must release @a proxy_address using free(). + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[out] proxy_address The proxy address + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Address family not supported + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_proxy_address( + ffi.Pointer ap, + int address_family, + ffi.Pointer> proxy_address, + ) { + return _wifi_manager_ap_get_proxy_address( + ap, + address_family, + proxy_address, + ); + } + + late final _wifi_manager_ap_get_proxy_address_ptr = + _lookup>( + 'wifi_manager_ap_get_proxy_address'); + late final _dart_wifi_manager_ap_get_proxy_address + _wifi_manager_ap_get_proxy_address = + _wifi_manager_ap_get_proxy_address_ptr + .asFunction<_dart_wifi_manager_ap_get_proxy_address>(); + + /// @brief Sets the proxy address. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[in] proxy_address The proxy address \n + /// If you set this value to @c NULL, then the existing value will be deleted. + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Address family not supported + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_update_ap() + int wifi_manager_ap_set_proxy_address( + ffi.Pointer ap, + int address_family, + ffi.Pointer proxy_address, + ) { + return _wifi_manager_ap_set_proxy_address( + ap, + address_family, + proxy_address, + ); + } + + late final _wifi_manager_ap_set_proxy_address_ptr = + _lookup>( + 'wifi_manager_ap_set_proxy_address'); + late final _dart_wifi_manager_ap_set_proxy_address + _wifi_manager_ap_set_proxy_address = + _wifi_manager_ap_set_proxy_address_ptr + .asFunction<_dart_wifi_manager_ap_set_proxy_address>(); + + /// @brief Gets the Proxy type. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[out] proxy_type The type of proxy + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_proxy_type( + ffi.Pointer ap, + ffi.Pointer proxy_type, + ) { + return _wifi_manager_ap_get_proxy_type( + ap, + proxy_type, + ); + } + + late final _wifi_manager_ap_get_proxy_type_ptr = + _lookup>( + 'wifi_manager_ap_get_proxy_type'); + late final _dart_wifi_manager_ap_get_proxy_type + _wifi_manager_ap_get_proxy_type = _wifi_manager_ap_get_proxy_type_ptr + .asFunction<_dart_wifi_manager_ap_get_proxy_type>(); + + /// @brief Sets the Proxy address. + /// @details If you set Proxy type to #WIFI_MANAGER_PROXY_TYPE_AUTO or #WIFI_MANAGER_PROXY_TYPE_MANUAL, then Proxy will be restored. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[in] proxy_type The type of proxy + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_update_ap() + int wifi_manager_ap_set_proxy_type( + ffi.Pointer ap, + int proxy_type, + ) { + return _wifi_manager_ap_set_proxy_type( + ap, + proxy_type, + ); + } + + late final _wifi_manager_ap_set_proxy_type_ptr = + _lookup>( + 'wifi_manager_ap_set_proxy_type'); + late final _dart_wifi_manager_ap_set_proxy_type + _wifi_manager_ap_set_proxy_type = _wifi_manager_ap_set_proxy_type_ptr + .asFunction<_dart_wifi_manager_ap_set_proxy_type>(); + + /// @brief Gets the DNS address. + /// @since_tizen 3.0 + /// @remarks The allowance of DNS address is @c 2.You must release @a dns_address using free(). + /// @param[in] ap The access point handle + /// @param[in] order The order of DNS address; it starts from 1, which means first DNS address + /// @param[in] address_family The address family + /// @param[out] dns_address The DNS address + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Address family not supported + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_dns_address( + ffi.Pointer ap, + int order, + int address_family, + ffi.Pointer> dns_address, + ) { + return _wifi_manager_ap_get_dns_address( + ap, + order, + address_family, + dns_address, + ); + } + + late final _wifi_manager_ap_get_dns_address_ptr = + _lookup>( + 'wifi_manager_ap_get_dns_address'); + late final _dart_wifi_manager_ap_get_dns_address + _wifi_manager_ap_get_dns_address = _wifi_manager_ap_get_dns_address_ptr + .asFunction<_dart_wifi_manager_ap_get_dns_address>(); + + /// @brief Sets the DNS address. + /// @since_tizen 3.0 + /// @remarks The allowance of DNS address is @c 2 \n + /// @param[in] ap The access point handle + /// @param[in] order The order of DNS address \n + /// It starts from @c 1, which means first DNS address. + /// @param[in] address_family The address family + /// @param[in] dns_address The DNS address \n + /// If you set this value to @c NULL, then the existing value will be deleted. + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Address family not supported + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_update_ap() + int wifi_manager_ap_set_dns_address( + ffi.Pointer ap, + int order, + int address_family, + ffi.Pointer dns_address, + ) { + return _wifi_manager_ap_set_dns_address( + ap, + order, + address_family, + dns_address, + ); + } + + late final _wifi_manager_ap_set_dns_address_ptr = + _lookup>( + 'wifi_manager_ap_set_dns_address'); + late final _dart_wifi_manager_ap_set_dns_address + _wifi_manager_ap_set_dns_address = _wifi_manager_ap_set_dns_address_ptr + .asFunction<_dart_wifi_manager_ap_set_dns_address>(); + + /// @brief Gets the DNS config type. + /// @since_tizen 4.0 + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[out] type The DNS config type + /// @return 0 on success, otherwise negative error value. + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_dns_config_type( + ffi.Pointer ap, + int address_family, + ffi.Pointer type, + ) { + return _wifi_manager_ap_get_dns_config_type( + ap, + address_family, + type, + ); + } + + late final _wifi_manager_ap_get_dns_config_type_ptr = + _lookup>( + 'wifi_manager_ap_get_dns_config_type'); + late final _dart_wifi_manager_ap_get_dns_config_type + _wifi_manager_ap_get_dns_config_type = + _wifi_manager_ap_get_dns_config_type_ptr + .asFunction<_dart_wifi_manager_ap_get_dns_config_type>(); + + /// @brief Sets the DNS config type. + /// @since_tizen 4.0 + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[in] type The DNS config type + /// @return 0 on success, otherwise negative error value. + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_update_ap() + int wifi_manager_ap_set_dns_config_type( + ffi.Pointer ap, + int address_family, + int type, + ) { + return _wifi_manager_ap_set_dns_config_type( + ap, + address_family, + type, + ); + } + + late final _wifi_manager_ap_set_dns_config_type_ptr = + _lookup>( + 'wifi_manager_ap_set_dns_config_type'); + late final _dart_wifi_manager_ap_set_dns_config_type + _wifi_manager_ap_set_dns_config_type = + _wifi_manager_ap_set_dns_config_type_ptr + .asFunction<_dart_wifi_manager_ap_set_dns_config_type>(); + + /// @brief Gets the network prefix length. + /// @since_tizen 4.0 + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[out] prefix_len The network prefix length. \n + /// In case of IPv4, it means netmask length \n + /// (also called a prefix, e.g. 8, 16, 24, 32) + /// @return 0 on success, otherwise negative error value. + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_prefix_length( + ffi.Pointer ap, + int address_family, + ffi.Pointer prefix_len, + ) { + return _wifi_manager_ap_get_prefix_length( + ap, + address_family, + prefix_len, + ); + } + + late final _wifi_manager_ap_get_prefix_length_ptr = + _lookup>( + 'wifi_manager_ap_get_prefix_length'); + late final _dart_wifi_manager_ap_get_prefix_length + _wifi_manager_ap_get_prefix_length = + _wifi_manager_ap_get_prefix_length_ptr + .asFunction<_dart_wifi_manager_ap_get_prefix_length>(); + + /// @brief Sets the network prefix length. + /// @since_tizen 4.0 + /// @param[in] ap The access point handle + /// @param[in] address_family The address family + /// @param[in] prefix_len The network prefix length. \n + /// In case of IPv4, it means netmask length \n + /// (also called a prefix, e.g. 8, 16, 24, 32) + /// @return 0 on success, otherwise negative error value. + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_update_ap() + int wifi_manager_ap_set_prefix_length( + ffi.Pointer ap, + int address_family, + int prefix_len, + ) { + return _wifi_manager_ap_set_prefix_length( + ap, + address_family, + prefix_len, + ); + } + + late final _wifi_manager_ap_set_prefix_length_ptr = + _lookup>( + 'wifi_manager_ap_set_prefix_length'); + late final _dart_wifi_manager_ap_set_prefix_length + _wifi_manager_ap_set_prefix_length = + _wifi_manager_ap_set_prefix_length_ptr + .asFunction<_dart_wifi_manager_ap_set_prefix_length>(); + + /// @brief Gets the Wi-Fi disconnect reason from the supplicant. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[out] disconnect_reason The supplicant disconnect reason + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_disconnect_reason( + ffi.Pointer ap, + ffi.Pointer disconnect_reason, + ) { + return _wifi_manager_ap_get_disconnect_reason( + ap, + disconnect_reason, + ); + } + + late final _wifi_manager_ap_get_disconnect_reason_ptr = + _lookup>( + 'wifi_manager_ap_get_disconnect_reason'); + late final _dart_wifi_manager_ap_get_disconnect_reason + _wifi_manager_ap_get_disconnect_reason = + _wifi_manager_ap_get_disconnect_reason_ptr + .asFunction<_dart_wifi_manager_ap_get_disconnect_reason>(); + + /// @brief Gets the error state. + /// @since_tizen 4.0 + /// @param[in] ap The access point handle + /// @param[out] error_state The Wi-Fi connection error state + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_error_state( + ffi.Pointer ap, + ffi.Pointer error_state, + ) { + return _wifi_manager_ap_get_error_state( + ap, + error_state, + ); + } + + late final _wifi_manager_ap_get_error_state_ptr = + _lookup>( + 'wifi_manager_ap_get_error_state'); + late final _dart_wifi_manager_ap_get_error_state + _wifi_manager_ap_get_error_state = _wifi_manager_ap_get_error_state_ptr + .asFunction<_dart_wifi_manager_ap_get_error_state>(); + + /// @brief Gets the Wi-Fi Association Status Code from the supplicant. + /// @since_tizen 5.0 + /// @param[in] ap The access point handle + /// @param[out] status_code The supplicant Wi-Fi association status code + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_assoc_status_code( + ffi.Pointer ap, + ffi.Pointer status_code, + ) { + return _wifi_manager_ap_get_assoc_status_code( + ap, + status_code, + ); + } + + late final _wifi_manager_ap_get_assoc_status_code_ptr = + _lookup>( + 'wifi_manager_ap_get_assoc_status_code'); + late final _dart_wifi_manager_ap_get_assoc_status_code + _wifi_manager_ap_get_assoc_status_code = + _wifi_manager_ap_get_assoc_status_code_ptr + .asFunction<_dart_wifi_manager_ap_get_assoc_status_code>(); + + /// @brief Gets the VSIE result of the AP. + /// @since_tizen 5.0 + /// @remarks You must release @a vsie using free(). + /// + /// @param[in] ap The access point handle + /// @param[out] vsie The vendor specific information element + /// @param[out] length The VSIE length + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_vsie( + ffi.Pointer ap, + ffi.Pointer> vsie, + ffi.Pointer length, + ) { + return _wifi_manager_ap_get_vsie( + ap, + vsie, + length, + ); + } + + late final _wifi_manager_ap_get_vsie_ptr = + _lookup>( + 'wifi_manager_ap_get_vsie'); + late final _dart_wifi_manager_ap_get_vsie _wifi_manager_ap_get_vsie = + _wifi_manager_ap_get_vsie_ptr + .asFunction<_dart_wifi_manager_ap_get_vsie>(); + + /// @brief Gets the Wi-Fi security mode. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[out] type The type of Wi-Fi security + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_security_type( + ffi.Pointer ap, + ffi.Pointer type, + ) { + return _wifi_manager_ap_get_security_type( + ap, + type, + ); + } + + late final _wifi_manager_ap_get_security_type_ptr = + _lookup>( + 'wifi_manager_ap_get_security_type'); + late final _dart_wifi_manager_ap_get_security_type + _wifi_manager_ap_get_security_type = + _wifi_manager_ap_get_security_type_ptr + .asFunction<_dart_wifi_manager_ap_get_security_type>(); + + /// @brief Sets the Wi-Fi security mode. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[in] type The type of Wi-Fi security + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_set_security_type( + ffi.Pointer ap, + int type, + ) { + return _wifi_manager_ap_set_security_type( + ap, + type, + ); + } + + late final _wifi_manager_ap_set_security_type_ptr = + _lookup>( + 'wifi_manager_ap_set_security_type'); + late final _dart_wifi_manager_ap_set_security_type + _wifi_manager_ap_set_security_type = + _wifi_manager_ap_set_security_type_ptr + .asFunction<_dart_wifi_manager_ap_set_security_type>(); + + /// @brief Gets the Wi-Fi encryption type. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[out] type The type of Wi-Fi encryption + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_encryption_type( + ffi.Pointer ap, + ffi.Pointer type, + ) { + return _wifi_manager_ap_get_encryption_type( + ap, + type, + ); + } + + late final _wifi_manager_ap_get_encryption_type_ptr = + _lookup>( + 'wifi_manager_ap_get_encryption_type'); + late final _dart_wifi_manager_ap_get_encryption_type + _wifi_manager_ap_get_encryption_type = + _wifi_manager_ap_get_encryption_type_ptr + .asFunction<_dart_wifi_manager_ap_get_encryption_type>(); + + /// @brief Sets the Wi-Fi encryption type. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[in] type The type of Wi-Fi encryption + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_set_encryption_type( + ffi.Pointer ap, + int type, + ) { + return _wifi_manager_ap_set_encryption_type( + ap, + type, + ); + } + + late final _wifi_manager_ap_set_encryption_type_ptr = + _lookup>( + 'wifi_manager_ap_set_encryption_type'); + late final _dart_wifi_manager_ap_set_encryption_type + _wifi_manager_ap_set_encryption_type = + _wifi_manager_ap_set_encryption_type_ptr + .asFunction<_dart_wifi_manager_ap_set_encryption_type>(); + + /// @brief Checks whether the passphrase is required or not. + /// @since_tizen 3.0 + /// @remarks This function is not valid if security type is #WIFI_MANAGER_SECURITY_TYPE_EAP. + /// @param[in] ap The access point handle + /// @param[out] required @c true if passphrase is required, + /// @c false if passphrase is not required. + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_is_passphrase_required( + ffi.Pointer ap, + ffi.Pointer required, + ) { + return _wifi_manager_ap_is_passphrase_required( + ap, + required, + ); + } + + late final _wifi_manager_ap_is_passphrase_required_ptr = + _lookup>( + 'wifi_manager_ap_is_passphrase_required'); + late final _dart_wifi_manager_ap_is_passphrase_required + _wifi_manager_ap_is_passphrase_required = + _wifi_manager_ap_is_passphrase_required_ptr + .asFunction<_dart_wifi_manager_ap_is_passphrase_required>(); + + /// @brief Sets the passphrase. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[in] passphrase The passphrase of access point + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_set_passphrase( + ffi.Pointer ap, + ffi.Pointer passphrase, + ) { + return _wifi_manager_ap_set_passphrase( + ap, + passphrase, + ); + } + + late final _wifi_manager_ap_set_passphrase_ptr = + _lookup>( + 'wifi_manager_ap_set_passphrase'); + late final _dart_wifi_manager_ap_set_passphrase + _wifi_manager_ap_set_passphrase = _wifi_manager_ap_set_passphrase_ptr + .asFunction<_dart_wifi_manager_ap_set_passphrase>(); + + /// @brief Checks whether the WPS(Wi-Fi Protected Setup) is supported or not. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[out] supported @c true if WPS is supported, + /// otherwise @c false is WPS is not supported. + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_connect_by_wps_pbc() + /// @see wifi_manager_connect_by_wps_pin() + int wifi_manager_ap_is_wps_supported( + ffi.Pointer ap, + ffi.Pointer supported, + ) { + return _wifi_manager_ap_is_wps_supported( + ap, + supported, + ); + } + + late final _wifi_manager_ap_is_wps_supported_ptr = + _lookup>( + 'wifi_manager_ap_is_wps_supported'); + late final _dart_wifi_manager_ap_is_wps_supported + _wifi_manager_ap_is_wps_supported = _wifi_manager_ap_is_wps_supported_ptr + .asFunction<_dart_wifi_manager_ap_is_wps_supported>(); + + /// @brief Sets the passphrase of EAP. + /// @details You can set one of @a user_name and @a password as @c NULL. + /// In this case, the value of a parameter which is set as @c NULL will be the previous value. + /// But it is not allowed that both @a user_name and @a password are set as @c NULL. + /// @since_tizen 3.0 + /// @remarks This function is valid only if the EAP type is #WIFI_MANAGER_EAP_TYPE_PEAP or #WIFI_MANAGER_EAP_TYPE_TTLS. + /// @param[in] ap The access point handle + /// @param[in] user_name The user name \n + /// This value can be @c NULL. + /// @param[in] password The password \n + /// This value can be @c NULL. + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_set_eap_passphrase( + ffi.Pointer ap, + ffi.Pointer user_name, + ffi.Pointer password, + ) { + return _wifi_manager_ap_set_eap_passphrase( + ap, + user_name, + password, + ); + } + + late final _wifi_manager_ap_set_eap_passphrase_ptr = + _lookup>( + 'wifi_manager_ap_set_eap_passphrase'); + late final _dart_wifi_manager_ap_set_eap_passphrase + _wifi_manager_ap_set_eap_passphrase = + _wifi_manager_ap_set_eap_passphrase_ptr + .asFunction<_dart_wifi_manager_ap_set_eap_passphrase>(); + + /// @brief Gets the passphrase of EAP. + /// @since_tizen 3.0 + /// @remarks This function is valid only if the EAP type is #WIFI_MANAGER_EAP_TYPE_PEAP or #WIFI_MANAGER_EAP_TYPE_TTLS. + /// You must release @a user_name using free(). + /// @param[in] ap The access point handle + /// @param[out] user_name The user name + /// @param[out] is_password_set @c true if password is set, + /// otherwise @c false if password is not set. + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_eap_passphrase( + ffi.Pointer ap, + ffi.Pointer> user_name, + ffi.Pointer is_password_set, + ) { + return _wifi_manager_ap_get_eap_passphrase( + ap, + user_name, + is_password_set, + ); + } + + late final _wifi_manager_ap_get_eap_passphrase_ptr = + _lookup>( + 'wifi_manager_ap_get_eap_passphrase'); + late final _dart_wifi_manager_ap_get_eap_passphrase + _wifi_manager_ap_get_eap_passphrase = + _wifi_manager_ap_get_eap_passphrase_ptr + .asFunction<_dart_wifi_manager_ap_get_eap_passphrase>(); + + /// @brief Gets the CA Certificate of EAP. + /// @since_tizen 3.0 + /// @remarks This function is valid only if the EAP type is #WIFI_MANAGER_EAP_TYPE_TLS. + /// You must release @a file using free(). + /// @param[in] ap The access point handle + /// @param[out] file The file path of CA Certificate + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_eap_ca_cert_file( + ffi.Pointer ap, + ffi.Pointer> file, + ) { + return _wifi_manager_ap_get_eap_ca_cert_file( + ap, + file, + ); + } + + late final _wifi_manager_ap_get_eap_ca_cert_file_ptr = + _lookup>( + 'wifi_manager_ap_get_eap_ca_cert_file'); + late final _dart_wifi_manager_ap_get_eap_ca_cert_file + _wifi_manager_ap_get_eap_ca_cert_file = + _wifi_manager_ap_get_eap_ca_cert_file_ptr + .asFunction<_dart_wifi_manager_ap_get_eap_ca_cert_file>(); + + /// @brief Sets the CA Certificate of EAP. + /// @since_tizen 3.0 + /// @remarks This function is valid only if the EAP type is #WIFI_MANAGER_EAP_TYPE_TLS. + /// @param[in] ap The access point handle + /// @param[in] file The file path of CA Certificate + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_set_eap_ca_cert_file( + ffi.Pointer ap, + ffi.Pointer file, + ) { + return _wifi_manager_ap_set_eap_ca_cert_file( + ap, + file, + ); + } + + late final _wifi_manager_ap_set_eap_ca_cert_file_ptr = + _lookup>( + 'wifi_manager_ap_set_eap_ca_cert_file'); + late final _dart_wifi_manager_ap_set_eap_ca_cert_file + _wifi_manager_ap_set_eap_ca_cert_file = + _wifi_manager_ap_set_eap_ca_cert_file_ptr + .asFunction<_dart_wifi_manager_ap_set_eap_ca_cert_file>(); + + /// @brief Gets the Client Certificate of EAP. + /// @since_tizen 3.0 + /// @remarks This function is valid only if the EAP type is #WIFI_MANAGER_EAP_TYPE_TLS. + /// You must release @a file using free(). + /// @param[in] ap The access point handle + /// @param[out] file The file path of Client Certificate + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_eap_client_cert_file( + ffi.Pointer ap, + ffi.Pointer> file, + ) { + return _wifi_manager_ap_get_eap_client_cert_file( + ap, + file, + ); + } + + late final _wifi_manager_ap_get_eap_client_cert_file_ptr = + _lookup>( + 'wifi_manager_ap_get_eap_client_cert_file'); + late final _dart_wifi_manager_ap_get_eap_client_cert_file + _wifi_manager_ap_get_eap_client_cert_file = + _wifi_manager_ap_get_eap_client_cert_file_ptr + .asFunction<_dart_wifi_manager_ap_get_eap_client_cert_file>(); + + /// @brief Sets the CA Certificate of EAP. + /// @since_tizen 3.0 + /// @remarks This function is valid only if the EAP type is #WIFI_MANAGER_EAP_TYPE_TLS. + /// @param[in] ap The access point handle + /// @param[in] file The file path of Client Certificate + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_set_eap_client_cert_file( + ffi.Pointer ap, + ffi.Pointer file, + ) { + return _wifi_manager_ap_set_eap_client_cert_file( + ap, + file, + ); + } + + late final _wifi_manager_ap_set_eap_client_cert_file_ptr = + _lookup>( + 'wifi_manager_ap_set_eap_client_cert_file'); + late final _dart_wifi_manager_ap_set_eap_client_cert_file + _wifi_manager_ap_set_eap_client_cert_file = + _wifi_manager_ap_set_eap_client_cert_file_ptr + .asFunction<_dart_wifi_manager_ap_set_eap_client_cert_file>(); + + /// @brief Gets the private key file of EAP. + /// @since_tizen 3.0 + /// @remarks This function is valid only if the EAP type is #WIFI_MANAGER_EAP_TYPE_TLS. + /// You must release @a file using free(). + /// @param[in] ap The access point handle + /// @param[out] file The file path of private key + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_eap_private_key_file( + ffi.Pointer ap, + ffi.Pointer> file, + ) { + return _wifi_manager_ap_get_eap_private_key_file( + ap, + file, + ); + } + + late final _wifi_manager_ap_get_eap_private_key_file_ptr = + _lookup>( + 'wifi_manager_ap_get_eap_private_key_file'); + late final _dart_wifi_manager_ap_get_eap_private_key_file + _wifi_manager_ap_get_eap_private_key_file = + _wifi_manager_ap_get_eap_private_key_file_ptr + .asFunction<_dart_wifi_manager_ap_get_eap_private_key_file>(); + + /// @brief Sets the private key information of EAP. + /// @since_tizen 3.0 + /// @remarks This function is valid only if the EAP type is #WIFI_MANAGER_EAP_TYPE_TLS. + /// @param[in] ap The access point handle + /// @param[in] file The file path of private key + /// @param[in] password The password + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_set_eap_private_key_info( + ffi.Pointer ap, + ffi.Pointer file, + ffi.Pointer password, + ) { + return _wifi_manager_ap_set_eap_private_key_info( + ap, + file, + password, + ); + } + + late final _wifi_manager_ap_set_eap_private_key_info_ptr = + _lookup>( + 'wifi_manager_ap_set_eap_private_key_info'); + late final _dart_wifi_manager_ap_set_eap_private_key_info + _wifi_manager_ap_set_eap_private_key_info = + _wifi_manager_ap_set_eap_private_key_info_ptr + .asFunction<_dart_wifi_manager_ap_set_eap_private_key_info>(); + + /// @brief Gets the EAP type of Wi-Fi. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[out] type The type of EAP + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_eap_type( + ffi.Pointer ap, + ffi.Pointer type, + ) { + return _wifi_manager_ap_get_eap_type( + ap, + type, + ); + } + + late final _wifi_manager_ap_get_eap_type_ptr = + _lookup>( + 'wifi_manager_ap_get_eap_type'); + late final _dart_wifi_manager_ap_get_eap_type _wifi_manager_ap_get_eap_type = + _wifi_manager_ap_get_eap_type_ptr + .asFunction<_dart_wifi_manager_ap_get_eap_type>(); + + /// @brief Sets the EAP type of Wi-Fi. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[in] type The type of EAP + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_set_eap_type( + ffi.Pointer ap, + int type, + ) { + return _wifi_manager_ap_set_eap_type( + ap, + type, + ); + } + + late final _wifi_manager_ap_set_eap_type_ptr = + _lookup>( + 'wifi_manager_ap_set_eap_type'); + late final _dart_wifi_manager_ap_set_eap_type _wifi_manager_ap_set_eap_type = + _wifi_manager_ap_set_eap_type_ptr + .asFunction<_dart_wifi_manager_ap_set_eap_type>(); + + /// @brief Gets the type of EAP phase2 authentication of Wi-Fi. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[out] type The type of EAP phase2 authentication + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_get_eap_auth_type( + ffi.Pointer ap, + ffi.Pointer type, + ) { + return _wifi_manager_ap_get_eap_auth_type( + ap, + type, + ); + } + + late final _wifi_manager_ap_get_eap_auth_type_ptr = + _lookup>( + 'wifi_manager_ap_get_eap_auth_type'); + late final _dart_wifi_manager_ap_get_eap_auth_type + _wifi_manager_ap_get_eap_auth_type = + _wifi_manager_ap_get_eap_auth_type_ptr + .asFunction<_dart_wifi_manager_ap_get_eap_auth_type>(); + + /// @brief Sets the type of EAP phase2 authentication of Wi-Fi. + /// @since_tizen 3.0 + /// @param[in] ap The access point handle + /// @param[in] type The type of EAP phase2 authentication + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ap_set_eap_auth_type( + ffi.Pointer ap, + int type, + ) { + return _wifi_manager_ap_set_eap_auth_type( + ap, + type, + ); + } + + late final _wifi_manager_ap_set_eap_auth_type_ptr = + _lookup>( + 'wifi_manager_ap_set_eap_auth_type'); + late final _dart_wifi_manager_ap_set_eap_auth_type + _wifi_manager_ap_set_eap_auth_type = + _wifi_manager_ap_set_eap_auth_type_ptr + .asFunction<_dart_wifi_manager_ap_set_eap_auth_type>(); + + /// @brief Gets access point configuration handle. + /// @since_tizen 3.0 + /// @remarks You must release @a config using wifi_manager_config_destroy(). + /// + /// @param[in] wifi The Wi-Fi handle + /// @param[in] name The access point name + /// @param[in] passphrase The access point passphrase + /// @param[in] security_type The access point security type + /// @param[out] config The access point configuration handle + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @pre This function needs a wifi_manager_initialize() call before use + /// @see wifi_manager_config_destroy() + int wifi_manager_config_create( + ffi.Pointer wifi, + ffi.Pointer name, + ffi.Pointer passphrase, + int security_type, + ffi.Pointer> config, + ) { + return _wifi_manager_config_create( + wifi, + name, + passphrase, + security_type, + config, + ); + } + + late final _wifi_manager_config_create_ptr = + _lookup>( + 'wifi_manager_config_create'); + late final _dart_wifi_manager_config_create _wifi_manager_config_create = + _wifi_manager_config_create_ptr + .asFunction<_dart_wifi_manager_config_create>(); + + /// @brief Clones the access point configuration handle. + /// @since_tizen 3.0 + /// @remarks You must release @a cloned_config using wifi_manager_config_destroy(). + /// + /// @param[in] origin The origin access point configuration handle + /// @param[out] cloned_config The cloned access point configuration handle + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_config_destroy() + int wifi_manager_config_clone( + ffi.Pointer origin, + ffi.Pointer> cloned_config, + ) { + return _wifi_manager_config_clone( + origin, + cloned_config, + ); + } + + late final _wifi_manager_config_clone_ptr = + _lookup>( + 'wifi_manager_config_clone'); + late final _dart_wifi_manager_config_clone _wifi_manager_config_clone = + _wifi_manager_config_clone_ptr + .asFunction<_dart_wifi_manager_config_clone>(); + + /// @brief Destroys the access point configuration handle. + /// @since_tizen 3.0 + /// + /// @param[in] config The access point configuration handle + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_config_create() + /// @see wifi_manager_config_clone() + int wifi_manager_config_destroy( + ffi.Pointer config, + ) { + return _wifi_manager_config_destroy( + config, + ); + } + + late final _wifi_manager_config_destroy_ptr = + _lookup>( + 'wifi_manager_config_destroy'); + late final _dart_wifi_manager_config_destroy _wifi_manager_config_destroy = + _wifi_manager_config_destroy_ptr + .asFunction<_dart_wifi_manager_config_destroy>(); + + /// @brief Saves Wi-Fi configuration of access point. + /// @details When a configuration is changed, these changes will be not applied to the Connection Manager immediately.\n + /// When you call this function, your changes affect the Connection Manager and the existing configuration is updated. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.profile + /// + /// @param[in] wifi The Wi-Fi handle + /// @param[in] config The access point configuration handle + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_config_create() + int wifi_manager_config_save( + ffi.Pointer wifi, + ffi.Pointer config, + ) { + return _wifi_manager_config_save( + wifi, + config, + ); + } + + late final _wifi_manager_config_save_ptr = + _lookup>( + 'wifi_manager_config_save'); + late final _dart_wifi_manager_config_save _wifi_manager_config_save = + _wifi_manager_config_save_ptr + .asFunction<_dart_wifi_manager_config_save>(); + + /// @brief Removes Wi-Fi configuration of access point. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.profile + /// + /// @param[in] wifi The Wi-Fi handle + /// @param[in] config The access point configuration handle + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_config_create() + /// @see wifi_manager_config_foreach_configuration() + int wifi_manager_config_remove( + ffi.Pointer wifi, + ffi.Pointer config, + ) { + return _wifi_manager_config_remove( + wifi, + config, + ); + } + + late final _wifi_manager_config_remove_ptr = + _lookup>( + 'wifi_manager_config_remove'); + late final _dart_wifi_manager_config_remove _wifi_manager_config_remove = + _wifi_manager_config_remove_ptr + .asFunction<_dart_wifi_manager_config_remove>(); + + /// @brief Gets configurations of an access point. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.profile + /// + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback to be called + /// @param[in] user_data The user data passed to the callback function + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @pre This function needs wifi_manager_initialize() before use. + /// @post This function invokes wifi_manager_config_list_cb(). + int wifi_manager_config_foreach_configuration( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_config_foreach_configuration( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_config_foreach_configuration_ptr = + _lookup>( + 'wifi_manager_config_foreach_configuration'); + late final _dart_wifi_manager_config_foreach_configuration + _wifi_manager_config_foreach_configuration = + _wifi_manager_config_foreach_configuration_ptr + .asFunction<_dart_wifi_manager_config_foreach_configuration>(); + + /// @brief Gets the name of access point from configuration. + /// @since_tizen 3.0 + /// @remarks You must release @a name using free(). + /// + /// @param[in] config The access point configuration handle + /// @param[out] name The name of access point + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_config_get_name( + ffi.Pointer config, + ffi.Pointer> name, + ) { + return _wifi_manager_config_get_name( + config, + name, + ); + } + + late final _wifi_manager_config_get_name_ptr = + _lookup>( + 'wifi_manager_config_get_name'); + late final _dart_wifi_manager_config_get_name _wifi_manager_config_get_name = + _wifi_manager_config_get_name_ptr + .asFunction<_dart_wifi_manager_config_get_name>(); + + /// @brief Gets the security type of access point from configuration. + /// @since_tizen 3.0 + /// + /// @param[in] config The access point configuration handle + /// @param[out] security_type The security type of access point + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_config_get_security_type( + ffi.Pointer config, + ffi.Pointer security_type, + ) { + return _wifi_manager_config_get_security_type( + config, + security_type, + ); + } + + late final _wifi_manager_config_get_security_type_ptr = + _lookup>( + 'wifi_manager_config_get_security_type'); + late final _dart_wifi_manager_config_get_security_type + _wifi_manager_config_get_security_type = + _wifi_manager_config_get_security_type_ptr + .asFunction<_dart_wifi_manager_config_get_security_type>(); + + /// @brief Sets access point proxy address configuration. + /// @since_tizen 3.0 + /// + /// @param[in] config The access point configuration handle + /// @param[in] address_family The address family + /// @param[in] proxy_address The proxy address + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIFI_MANAGER_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED Not supported address family + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_config_save() + int wifi_manager_config_set_proxy_address( + ffi.Pointer config, + int address_family, + ffi.Pointer proxy_address, + ) { + return _wifi_manager_config_set_proxy_address( + config, + address_family, + proxy_address, + ); + } + + late final _wifi_manager_config_set_proxy_address_ptr = + _lookup>( + 'wifi_manager_config_set_proxy_address'); + late final _dart_wifi_manager_config_set_proxy_address + _wifi_manager_config_set_proxy_address = + _wifi_manager_config_set_proxy_address_ptr + .asFunction<_dart_wifi_manager_config_set_proxy_address>(); + + /// @brief Gets the proxy address of access point from configuration. + /// @since_tizen 3.0 + /// @remarks You must release @a proxy_address using free(). + /// + /// @param[in] config The access point configuration handle + /// @param[out] address_family The address family + /// @param[out] proxy_address The proxy address + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_config_get_proxy_address( + ffi.Pointer config, + ffi.Pointer address_family, + ffi.Pointer> proxy_address, + ) { + return _wifi_manager_config_get_proxy_address( + config, + address_family, + proxy_address, + ); + } + + late final _wifi_manager_config_get_proxy_address_ptr = + _lookup>( + 'wifi_manager_config_get_proxy_address'); + late final _dart_wifi_manager_config_get_proxy_address + _wifi_manager_config_get_proxy_address = + _wifi_manager_config_get_proxy_address_ptr + .asFunction<_dart_wifi_manager_config_get_proxy_address>(); + + /// @brief Sets the hidden property of access point from the configuration. + /// @since_tizen 3.0 + /// + /// @param[in] config The access point configuration handle + /// @param[in] is_hidden The new value of the hidden property + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + /// @see wifi_manager_config_save() + int wifi_manager_config_set_hidden_ap_property( + ffi.Pointer config, + bool is_hidden, + ) { + return _wifi_manager_config_set_hidden_ap_property( + config, + is_hidden ? 1 : 0, + ); + } + + late final _wifi_manager_config_set_hidden_ap_property_ptr = _lookup< + ffi.NativeFunction<_c_wifi_manager_config_set_hidden_ap_property>>( + 'wifi_manager_config_set_hidden_ap_property'); + late final _dart_wifi_manager_config_set_hidden_ap_property + _wifi_manager_config_set_hidden_ap_property = + _wifi_manager_config_set_hidden_ap_property_ptr + .asFunction<_dart_wifi_manager_config_set_hidden_ap_property>(); + + /// @brief Gets the hidden property of access point from the configuration. + /// @since_tizen 3.0 + /// + /// @param[in] config The access point configuration handle + /// @param[out] is_hidden The hidden property of access point + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_config_get_hidden_ap_property( + ffi.Pointer config, + ffi.Pointer is_hidden, + ) { + return _wifi_manager_config_get_hidden_ap_property( + config, + is_hidden, + ); + } + + late final _wifi_manager_config_get_hidden_ap_property_ptr = _lookup< + ffi.NativeFunction<_c_wifi_manager_config_get_hidden_ap_property>>( + 'wifi_manager_config_get_hidden_ap_property'); + late final _dart_wifi_manager_config_get_hidden_ap_property + _wifi_manager_config_get_hidden_ap_property = + _wifi_manager_config_get_hidden_ap_property_ptr + .asFunction<_dart_wifi_manager_config_get_hidden_ap_property>(); + + /// @brief Gets access point anonymous identity from configuration. + /// @since_tizen 3.0 + /// @remarks You must release @a anonymous_identity using free(). + /// + /// @param[in] config The access point configuration handle + /// @param[out] anonymous_identity The anonymous identity of access point + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int wifi_manager_config_get_eap_anonymous_identity( + ffi.Pointer config, + ffi.Pointer> anonymous_identity, + ) { + return _wifi_manager_config_get_eap_anonymous_identity( + config, + anonymous_identity, + ); + } + + late final _wifi_manager_config_get_eap_anonymous_identity_ptr = _lookup< + ffi.NativeFunction< + _c_wifi_manager_config_get_eap_anonymous_identity>>( + 'wifi_manager_config_get_eap_anonymous_identity'); + late final _dart_wifi_manager_config_get_eap_anonymous_identity + _wifi_manager_config_get_eap_anonymous_identity = + _wifi_manager_config_get_eap_anonymous_identity_ptr + .asFunction<_dart_wifi_manager_config_get_eap_anonymous_identity>(); + + /// @brief Sets access point anonymous identity to configuration. + /// @since_tizen 3.0 + /// + /// @param[in] config The access point configuration handle + /// @param[in] anonymous_identity The anonymous identity + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @see wifi_manager_config_save() + int wifi_manager_config_set_eap_anonymous_identity( + ffi.Pointer config, + ffi.Pointer anonymous_identity, + ) { + return _wifi_manager_config_set_eap_anonymous_identity( + config, + anonymous_identity, + ); + } + + late final _wifi_manager_config_set_eap_anonymous_identity_ptr = _lookup< + ffi.NativeFunction< + _c_wifi_manager_config_set_eap_anonymous_identity>>( + 'wifi_manager_config_set_eap_anonymous_identity'); + late final _dart_wifi_manager_config_set_eap_anonymous_identity + _wifi_manager_config_set_eap_anonymous_identity = + _wifi_manager_config_set_eap_anonymous_identity_ptr + .asFunction<_dart_wifi_manager_config_set_eap_anonymous_identity>(); + + /// @brief Gets access point cacert file from configuration. + /// @since_tizen 3.0 + /// @remarks You must release @a ca_cert using free(). + /// @remarks The mediastorage privilege http://tizen.org/privilege/mediastorage is needed \n + /// if @a image_path is relevant to media storage.\n + /// The externalstorage privilege http://tizen.org/privilege/externalstorage is needed \n + /// if @a image_path is relevant to external storage. + /// + /// @param[in] config The access point configuration handle + /// @param[out] ca_cert The certification authority(CA) certificates file of access point + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int wifi_manager_config_get_eap_ca_cert_file( + ffi.Pointer config, + ffi.Pointer> ca_cert, + ) { + return _wifi_manager_config_get_eap_ca_cert_file( + config, + ca_cert, + ); + } + + late final _wifi_manager_config_get_eap_ca_cert_file_ptr = + _lookup>( + 'wifi_manager_config_get_eap_ca_cert_file'); + late final _dart_wifi_manager_config_get_eap_ca_cert_file + _wifi_manager_config_get_eap_ca_cert_file = + _wifi_manager_config_get_eap_ca_cert_file_ptr + .asFunction<_dart_wifi_manager_config_get_eap_ca_cert_file>(); + + /// @brief Sets access point cacert file to configuration. + /// @since_tizen 3.0 + /// @remarks The mediastorage privilege http://tizen.org/privilege/mediastorage is needed \n + /// if @a image_path is relevant to media storage.\n + /// The externalstorage privilege http://tizen.org/privilege/externalstorage is needed \n + /// if @a image_path is relevant to external storage. + /// + /// @param[in] config The access point configuration handle + /// @param[in] ca_cert The certification authority(CA) certificates file of access point + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @see wifi_manager_config_save() + int wifi_manager_config_set_eap_ca_cert_file( + ffi.Pointer config, + ffi.Pointer ca_cert, + ) { + return _wifi_manager_config_set_eap_ca_cert_file( + config, + ca_cert, + ); + } + + late final _wifi_manager_config_set_eap_ca_cert_file_ptr = + _lookup>( + 'wifi_manager_config_set_eap_ca_cert_file'); + late final _dart_wifi_manager_config_set_eap_ca_cert_file + _wifi_manager_config_set_eap_ca_cert_file = + _wifi_manager_config_set_eap_ca_cert_file_ptr + .asFunction<_dart_wifi_manager_config_set_eap_ca_cert_file>(); + + /// @brief Gets access point client cert file from configuration. + /// @since_tizen 3.0 + /// @remarks You must release @a client_cert using free(). + /// + /// @param[in] config The access point configuration handle + /// @param[out] client_cert The certification authority(CA) certificates file of access point + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int wifi_manager_config_get_eap_client_cert_file( + ffi.Pointer config, + ffi.Pointer> client_cert, + ) { + return _wifi_manager_config_get_eap_client_cert_file( + config, + client_cert, + ); + } + + late final _wifi_manager_config_get_eap_client_cert_file_ptr = _lookup< + ffi.NativeFunction<_c_wifi_manager_config_get_eap_client_cert_file>>( + 'wifi_manager_config_get_eap_client_cert_file'); + late final _dart_wifi_manager_config_get_eap_client_cert_file + _wifi_manager_config_get_eap_client_cert_file = + _wifi_manager_config_get_eap_client_cert_file_ptr + .asFunction<_dart_wifi_manager_config_get_eap_client_cert_file>(); + + /// @brief Sets access point client cert file to configuration. + /// @since_tizen 3.0 + /// + /// @param[in] config The access point configuration handle + /// @param[in] private_key The private key file + /// @param[in] client_cert The certification authority(CA) certificates file of access point + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @see wifi_manager_config_save() + int wifi_manager_config_set_eap_client_cert_file( + ffi.Pointer config, + ffi.Pointer private_key, + ffi.Pointer client_cert, + ) { + return _wifi_manager_config_set_eap_client_cert_file( + config, + private_key, + client_cert, + ); + } + + late final _wifi_manager_config_set_eap_client_cert_file_ptr = _lookup< + ffi.NativeFunction<_c_wifi_manager_config_set_eap_client_cert_file>>( + 'wifi_manager_config_set_eap_client_cert_file'); + late final _dart_wifi_manager_config_set_eap_client_cert_file + _wifi_manager_config_set_eap_client_cert_file = + _wifi_manager_config_set_eap_client_cert_file_ptr + .asFunction<_dart_wifi_manager_config_set_eap_client_cert_file>(); + + /// @brief Gets access point identity from configuration. + /// @since_tizen 3.0 + /// @remarks You must release @a identity using free(). + /// + /// @param[in] config The access point configuration handle + /// @param[out] identity The identity of access point + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int wifi_manager_config_get_eap_identity( + ffi.Pointer config, + ffi.Pointer> identity, + ) { + return _wifi_manager_config_get_eap_identity( + config, + identity, + ); + } + + late final _wifi_manager_config_get_eap_identity_ptr = + _lookup>( + 'wifi_manager_config_get_eap_identity'); + late final _dart_wifi_manager_config_get_eap_identity + _wifi_manager_config_get_eap_identity = + _wifi_manager_config_get_eap_identity_ptr + .asFunction<_dart_wifi_manager_config_get_eap_identity>(); + + /// @brief Sets access point identity to configuration. + /// @since_tizen 3.0 + /// + /// @param[in] config The access point configuration handle + /// @param[in] identity The identity + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @see wifi_manager_config_save() + int wifi_manager_config_set_eap_identity( + ffi.Pointer config, + ffi.Pointer identity, + ) { + return _wifi_manager_config_set_eap_identity( + config, + identity, + ); + } + + late final _wifi_manager_config_set_eap_identity_ptr = + _lookup>( + 'wifi_manager_config_set_eap_identity'); + late final _dart_wifi_manager_config_set_eap_identity + _wifi_manager_config_set_eap_identity = + _wifi_manager_config_set_eap_identity_ptr + .asFunction<_dart_wifi_manager_config_set_eap_identity>(); + + /// @brief Gets access point EAP type from configuration. + /// @since_tizen 3.0 + /// + /// @param[in] config The access point configuration handle + /// @param[out] eap_type The EAP type of access point + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int wifi_manager_config_get_eap_type( + ffi.Pointer config, + ffi.Pointer eap_type, + ) { + return _wifi_manager_config_get_eap_type( + config, + eap_type, + ); + } + + late final _wifi_manager_config_get_eap_type_ptr = + _lookup>( + 'wifi_manager_config_get_eap_type'); + late final _dart_wifi_manager_config_get_eap_type + _wifi_manager_config_get_eap_type = _wifi_manager_config_get_eap_type_ptr + .asFunction<_dart_wifi_manager_config_get_eap_type>(); + + /// @brief Sets access point EAP type to configuration. + /// @since_tizen 3.0 + /// + /// @param[in] config The access point configuration handle + /// @param[in] eap_type The EAP type + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @see wifi_manager_config_save() + int wifi_manager_config_set_eap_type( + ffi.Pointer config, + int eap_type, + ) { + return _wifi_manager_config_set_eap_type( + config, + eap_type, + ); + } + + late final _wifi_manager_config_set_eap_type_ptr = + _lookup>( + 'wifi_manager_config_set_eap_type'); + late final _dart_wifi_manager_config_set_eap_type + _wifi_manager_config_set_eap_type = _wifi_manager_config_set_eap_type_ptr + .asFunction<_dart_wifi_manager_config_set_eap_type>(); + + /// @brief Gets access point EAP auth type from configuration. + /// @since_tizen 3.0 + /// + /// @param[in] config The access point configuration handle + /// @param[out] eap_auth_type The EAP auth type of access point + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int wifi_manager_config_get_eap_auth_type( + ffi.Pointer config, + ffi.Pointer eap_auth_type, + ) { + return _wifi_manager_config_get_eap_auth_type( + config, + eap_auth_type, + ); + } + + late final _wifi_manager_config_get_eap_auth_type_ptr = + _lookup>( + 'wifi_manager_config_get_eap_auth_type'); + late final _dart_wifi_manager_config_get_eap_auth_type + _wifi_manager_config_get_eap_auth_type = + _wifi_manager_config_get_eap_auth_type_ptr + .asFunction<_dart_wifi_manager_config_get_eap_auth_type>(); + + /// @brief Sets access point EAP auth type to configuration. + /// @since_tizen 3.0 + /// + /// @param[in] config The access point configuration handle + /// @param[in] eap_auth_type The EAP auth type + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @see wifi_manager_config_save() + int wifi_manager_config_set_eap_auth_type( + ffi.Pointer config, + int eap_auth_type, + ) { + return _wifi_manager_config_set_eap_auth_type( + config, + eap_auth_type, + ); + } + + late final _wifi_manager_config_set_eap_auth_type_ptr = + _lookup>( + 'wifi_manager_config_set_eap_auth_type'); + late final _dart_wifi_manager_config_set_eap_auth_type + _wifi_manager_config_set_eap_auth_type = + _wifi_manager_config_set_eap_auth_type_ptr + .asFunction<_dart_wifi_manager_config_set_eap_auth_type>(); + + /// @brief Gets access point subject match from configuration. + /// @since_tizen 3.0 + /// @remarks You must release @a subject_match using free(). + /// + /// @param[in] config The access point configuration handle + /// @param[out] subject_match The subject match of access point + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + int wifi_manager_config_get_eap_subject_match( + ffi.Pointer config, + ffi.Pointer> subject_match, + ) { + return _wifi_manager_config_get_eap_subject_match( + config, + subject_match, + ); + } + + late final _wifi_manager_config_get_eap_subject_match_ptr = + _lookup>( + 'wifi_manager_config_get_eap_subject_match'); + late final _dart_wifi_manager_config_get_eap_subject_match + _wifi_manager_config_get_eap_subject_match = + _wifi_manager_config_get_eap_subject_match_ptr + .asFunction<_dart_wifi_manager_config_get_eap_subject_match>(); + + /// @brief Sets access point subject match to configuration. + /// @since_tizen 3.0 + /// + /// @param[in] config The access point configuration handle + /// @param[in] subject_match The subject match + /// + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @see wifi_manager_config_save() + int wifi_manager_config_set_eap_subject_match( + ffi.Pointer config, + ffi.Pointer subject_match, + ) { + return _wifi_manager_config_set_eap_subject_match( + config, + subject_match, + ); + } + + late final _wifi_manager_config_set_eap_subject_match_ptr = + _lookup>( + 'wifi_manager_config_set_eap_subject_match'); + late final _dart_wifi_manager_config_set_eap_subject_match + _wifi_manager_config_set_eap_subject_match = + _wifi_manager_config_set_eap_subject_match_ptr + .asFunction<_dart_wifi_manager_config_set_eap_subject_match>(); + + /// @brief Registers the callback called when a TDLS device is found. + /// @since_tizen 4.0 + /// + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_tdls_set_discovered_cb( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_tdls_set_discovered_cb( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_tdls_set_discovered_cb_ptr = + _lookup>( + 'wifi_manager_tdls_set_discovered_cb'); + late final _dart_wifi_manager_tdls_set_discovered_cb + _wifi_manager_tdls_set_discovered_cb = + _wifi_manager_tdls_set_discovered_cb_ptr + .asFunction<_dart_wifi_manager_tdls_set_discovered_cb>(); + + /// @brief Unregisters the callback called when TDLS device is found. + /// @since_tizen 4.0 + /// + /// @param[in] wifi The Wi-Fi handle + /// + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_tdls_unset_discovered_cb( + ffi.Pointer wifi, + ) { + return _wifi_manager_tdls_unset_discovered_cb( + wifi, + ); + } + + late final _wifi_manager_tdls_unset_discovered_cb_ptr = + _lookup>( + 'wifi_manager_tdls_unset_discovered_cb'); + late final _dart_wifi_manager_tdls_unset_discovered_cb + _wifi_manager_tdls_unset_discovered_cb = + _wifi_manager_tdls_unset_discovered_cb_ptr + .asFunction<_dart_wifi_manager_tdls_unset_discovered_cb>(); + + /// @brief Discovers devices that support TDLS. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set + /// + /// @param[in] wifi The Wi-Fi handle + /// @param[in] peer_mac_addr The MAC address (e.g., ff:ff:ff:ff:ff:ff, + /// AA:BB:CC:DD:EE:FF) of the peer to be discovered + /// + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_tdls_start_discovery( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, + ) { + return _wifi_manager_tdls_start_discovery( + wifi, + peer_mac_addr, + ); + } + + late final _wifi_manager_tdls_start_discovery_ptr = + _lookup>( + 'wifi_manager_tdls_start_discovery'); + late final _dart_wifi_manager_tdls_start_discovery + _wifi_manager_tdls_start_discovery = + _wifi_manager_tdls_start_discovery_ptr + .asFunction<_dart_wifi_manager_tdls_start_discovery>(); + + /// @brief Connects to a peer device. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set + /// + /// @param[in] wifi The Wi-Fi handle + /// @param[in] peer_mac_addr The MAC address of the peer device to be connected + /// + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_tdls_connect( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, + ) { + return _wifi_manager_tdls_connect( + wifi, + peer_mac_addr, + ); + } + + late final _wifi_manager_tdls_connect_ptr = + _lookup>( + 'wifi_manager_tdls_connect'); + late final _dart_wifi_manager_tdls_connect _wifi_manager_tdls_connect = + _wifi_manager_tdls_connect_ptr + .asFunction<_dart_wifi_manager_tdls_connect>(); + + /// @brief Disconnects the connected peer. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set + /// + /// @param[in] wifi The Wi-Fi handle + /// @param[in] peer_mac_addr The MAC address of the connected peer + /// + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_tdls_disconnect( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, + ) { + return _wifi_manager_tdls_disconnect( + wifi, + peer_mac_addr, + ); + } + + late final _wifi_manager_tdls_disconnect_ptr = + _lookup>( + 'wifi_manager_tdls_disconnect'); + late final _dart_wifi_manager_tdls_disconnect _wifi_manager_tdls_disconnect = + _wifi_manager_tdls_disconnect_ptr + .asFunction<_dart_wifi_manager_tdls_disconnect>(); + + /// @brief Gets Peer Mac address of Connected peer. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// + /// @remarks The @a peer_mac_addr should be freed using free(). + /// @param[in] wifi The Wi-Fi handle + /// @param[out] peer_mac_addr The MAC address of the connected peer + /// + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_NO_CONNECTION No active TDLS Connection + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_tdls_get_connected_peer( + ffi.Pointer wifi, + ffi.Pointer> peer_mac_addr, + ) { + return _wifi_manager_tdls_get_connected_peer( + wifi, + peer_mac_addr, + ); + } + + late final _wifi_manager_tdls_get_connected_peer_ptr = + _lookup>( + 'wifi_manager_tdls_get_connected_peer'); + late final _dart_wifi_manager_tdls_get_connected_peer + _wifi_manager_tdls_get_connected_peer = + _wifi_manager_tdls_get_connected_peer_ptr + .asFunction<_dart_wifi_manager_tdls_get_connected_peer>(); + + /// @brief Registers the callback called when TDLS state is changed. + /// @since_tizen 3.0 + /// + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_tdls_set_state_changed_cb( + ffi.Pointer wifi, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_tdls_set_state_changed_cb( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_tdls_set_state_changed_cb_ptr = + _lookup>( + 'wifi_manager_tdls_set_state_changed_cb'); + late final _dart_wifi_manager_tdls_set_state_changed_cb + _wifi_manager_tdls_set_state_changed_cb = + _wifi_manager_tdls_set_state_changed_cb_ptr + .asFunction<_dart_wifi_manager_tdls_set_state_changed_cb>(); + + /// @brief Unregisters the callback called when TDLS state is changed. + /// @since_tizen 3.0 + /// + /// @param[in] wifi The Wi-Fi handle + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_tdls_unset_state_changed_cb( + ffi.Pointer wifi, + ) { + return _wifi_manager_tdls_unset_state_changed_cb( + wifi, + ); + } + + late final _wifi_manager_tdls_unset_state_changed_cb_ptr = + _lookup>( + 'wifi_manager_tdls_unset_state_changed_cb'); + late final _dart_wifi_manager_tdls_unset_state_changed_cb + _wifi_manager_tdls_unset_state_changed_cb = + _wifi_manager_tdls_unset_state_changed_cb_ptr + .asFunction<_dart_wifi_manager_tdls_unset_state_changed_cb>(); + + /// @brief Enables a TDLS channel switching request. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set + /// + /// @param[in] wifi The Wi-Fi handle + /// @param[in] peer_mac_addr The MAC address of the connected TDLS peer + /// @param[in] freq The new frequency [MHz] + /// + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_tdls_enable_channel_switching( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, + int freq, + ) { + return _wifi_manager_tdls_enable_channel_switching( + wifi, + peer_mac_addr, + freq, + ); + } + + late final _wifi_manager_tdls_enable_channel_switching_ptr = _lookup< + ffi.NativeFunction<_c_wifi_manager_tdls_enable_channel_switching>>( + 'wifi_manager_tdls_enable_channel_switching'); + late final _dart_wifi_manager_tdls_enable_channel_switching + _wifi_manager_tdls_enable_channel_switching = + _wifi_manager_tdls_enable_channel_switching_ptr + .asFunction<_dart_wifi_manager_tdls_enable_channel_switching>(); + + /// @brief Disables a TDLS channel switching request. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set + /// + /// @param[in] wifi The Wi-Fi handle + /// @param[in] peer_mac_addr The MAC address of the connected TDLS peer + /// + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_tdls_disable_channel_switching( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, + ) { + return _wifi_manager_tdls_disable_channel_switching( + wifi, + peer_mac_addr, + ); + } + + late final _wifi_manager_tdls_disable_channel_switching_ptr = _lookup< + ffi.NativeFunction<_c_wifi_manager_tdls_disable_channel_switching>>( + 'wifi_manager_tdls_disable_channel_switching'); + late final _dart_wifi_manager_tdls_disable_channel_switching + _wifi_manager_tdls_disable_channel_switching = + _wifi_manager_tdls_disable_channel_switching_ptr + .asFunction<_dart_wifi_manager_tdls_disable_channel_switching>(); + + /// @brief Registers the callback called when IP conflict state is changed. + /// @since_tizen 5.0 + /// @param[in] wifi The Wi-Fi handle + /// @param[in] callback The callback function to be called + /// @param[in] user_data The user data passed to the callback function + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_set_ip_conflict_cb( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _wifi_manager_set_ip_conflict_cb( + wifi, + callback, + user_data, + ); + } + + late final _wifi_manager_set_ip_conflict_cb_ptr = + _lookup>( + 'wifi_manager_set_ip_conflict_cb'); + late final _dart_wifi_manager_set_ip_conflict_cb + _wifi_manager_set_ip_conflict_cb = _wifi_manager_set_ip_conflict_cb_ptr + .asFunction<_dart_wifi_manager_set_ip_conflict_cb>(); + + /// @brief Unregisters the callback called when IP conflict state is changed. + /// @since_tizen 5.0 + /// @param[in] wifi The Wi-Fi handle + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_unset_ip_conflict_cb( + ffi.Pointer wifi, + ) { + return _wifi_manager_unset_ip_conflict_cb( + wifi, + ); + } + + late final _wifi_manager_unset_ip_conflict_cb_ptr = + _lookup>( + 'wifi_manager_unset_ip_conflict_cb'); + late final _dart_wifi_manager_unset_ip_conflict_cb + _wifi_manager_unset_ip_conflict_cb = + _wifi_manager_unset_ip_conflict_cb_ptr + .asFunction<_dart_wifi_manager_unset_ip_conflict_cb>(); + + /// @brief Enables or disables IP conflict detection. + /// @since_tizen 5.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.set + /// + /// @param[in] wifi The Wi-Fi handle + /// @param[in] detect True or false boolean to enable or disable + /// + /// @return @c 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_INVALID_OPERATION Invalid operation + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_set_ip_conflict_detect_enable( + ffi.Pointer wifi, + bool detect, + ) { + return _wifi_manager_set_ip_conflict_detect_enable( + wifi, + detect ? 1 : 0, + ); + } + + late final _wifi_manager_set_ip_conflict_detect_enable_ptr = _lookup< + ffi.NativeFunction<_c_wifi_manager_set_ip_conflict_detect_enable>>( + 'wifi_manager_set_ip_conflict_detect_enable'); + late final _dart_wifi_manager_set_ip_conflict_detect_enable + _wifi_manager_set_ip_conflict_detect_enable = + _wifi_manager_set_ip_conflict_detect_enable_ptr + .asFunction<_dart_wifi_manager_set_ip_conflict_detect_enable>(); + + /// @brief Checks whether IP conflict detection is enabled. + /// @since_tizen 5.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @param[in] wifi The Wi-Fi handle + /// @param[out] state @c true if IP conflict detection is enabled, + /// otherwise @c false if IP conflict detection is disabled. + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_ip_conflict_detect_is_enabled( + ffi.Pointer wifi, + ffi.Pointer state, + ) { + return _wifi_manager_ip_conflict_detect_is_enabled( + wifi, + state, + ); + } + + late final _wifi_manager_ip_conflict_detect_is_enabled_ptr = _lookup< + ffi.NativeFunction<_c_wifi_manager_ip_conflict_detect_is_enabled>>( + 'wifi_manager_ip_conflict_detect_is_enabled'); + late final _dart_wifi_manager_ip_conflict_detect_is_enabled + _wifi_manager_ip_conflict_detect_is_enabled = + _wifi_manager_ip_conflict_detect_is_enabled_ptr + .asFunction<_dart_wifi_manager_ip_conflict_detect_is_enabled>(); + + /// @brief Gets the state of the IP conflict. + /// @since_tizen 5.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/network.get + /// @param[in] wifi The Wi-Fi handle + /// @param[out] state The current state of IP conflict + /// @return 0 on success, otherwise negative error value + /// @retval #WIFI_MANAGER_ERROR_NONE Successful + /// @retval #WIFI_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #WIFI_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @retval #WIFI_MANAGER_ERROR_PERMISSION_DENIED Permission Denied + /// @retval #WIFI_MANAGER_ERROR_NOT_SUPPORTED Not supported + int wifi_manager_get_ip_conflict_state( + ffi.Pointer wifi, + ffi.Pointer state, + ) { + return _wifi_manager_get_ip_conflict_state( + wifi, + state, + ); + } + + late final _wifi_manager_get_ip_conflict_state_ptr = + _lookup>( + 'wifi_manager_get_ip_conflict_state'); + late final _dart_wifi_manager_get_ip_conflict_state + _wifi_manager_get_ip_conflict_state = + _wifi_manager_get_ip_conflict_state_ptr + .asFunction<_dart_wifi_manager_get_ip_conflict_state>(); + + /// @platform + /// @brief Gets the handle of a current engine information. + /// @since_tizen 3.0 + /// @remarks @a engine should be released using csr_engine_destroy(). + /// @param[in] id Engine identifier to get handle + /// @param[out] engine A pointer of the engine information handle + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_PARAMETER @a engine is invalid + /// @retval #CSR_ERROR_ENGINE_NOT_EXIST No engine exists + /// @retval #CSR_ERROR_ENGINE_NOT_ACTIVATED Engine is not activated + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_engine_destroy() + int csr_get_current_engine( + int id, + ffi.Pointer> engine, + ) { + return _csr_get_current_engine( + id, + engine, + ); + } + + late final _csr_get_current_engine_ptr = + _lookup>( + 'csr_get_current_engine'); + late final _dart_csr_get_current_engine _csr_get_current_engine = + _csr_get_current_engine_ptr.asFunction<_dart_csr_get_current_engine>(); + + /// @platform + /// @brief Extracts a vendor name from the engine information handle. + /// @since_tizen 3.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/antivirus.admin + /// @remarks @a vendor must be released using free(). + /// @param[in] engine The engine information handle + /// @param[out] vendor A pointer of the engine's vendor name + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid engine information handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a vendor is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_get_current_engine() + int csr_engine_get_vendor( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer> vendor, + ) { + return _csr_engine_get_vendor( + engine, + vendor, + ); + } + + late final _csr_engine_get_vendor_ptr = + _lookup>( + 'csr_engine_get_vendor'); + late final _dart_csr_engine_get_vendor _csr_engine_get_vendor = + _csr_engine_get_vendor_ptr.asFunction<_dart_csr_engine_get_vendor>(); + + /// @platform + /// @brief Extracts an engine name from the engine information handle. + /// @since_tizen 3.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/antivirus.admin + /// @remarks @a name must be released using free(). + /// @param[in] engine The engine information handle + /// @param[out] name A pointer of the engine's name + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid engine information handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a name is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_get_current_engine() + int csr_engine_get_name( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer> name, + ) { + return _csr_engine_get_name( + engine, + name, + ); + } + + late final _csr_engine_get_name_ptr = + _lookup>( + 'csr_engine_get_name'); + late final _dart_csr_engine_get_name _csr_engine_get_name = + _csr_engine_get_name_ptr.asFunction<_dart_csr_engine_get_name>(); + + /// @platform + /// @brief Extracts an engine version from the engine information handle. + /// @since_tizen 3.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/antivirus.admin + /// @remarks @a version must be released using free(). + /// @param[in] engine An engine information handle + /// @param[out] version A pointer of the engine's version + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid engine information handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a version is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_get_current_engine() + int csr_engine_get_version( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer> version, + ) { + return _csr_engine_get_version( + engine, + version, + ); + } + + late final _csr_engine_get_version_ptr = + _lookup>( + 'csr_engine_get_version'); + late final _dart_csr_engine_get_version _csr_engine_get_version = + _csr_engine_get_version_ptr.asFunction<_dart_csr_engine_get_version>(); + + /// @platform + /// @brief Extracts an engine's data version from the engine information handle. + /// @since_tizen 3.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/antivirus.admin + /// @remarks @a version must be released using free(). + /// @param[in] engine The engine information handle + /// @param[out] version A pointer of the data version. It can be null + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid engine information handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a version is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_get_current_engine() + int csr_engine_get_data_version( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer> version, + ) { + return _csr_engine_get_data_version( + engine, + version, + ); + } + + late final _csr_engine_get_data_version_ptr = + _lookup>( + 'csr_engine_get_data_version'); + late final _dart_csr_engine_get_data_version _csr_engine_get_data_version = + _csr_engine_get_data_version_ptr + .asFunction<_dart_csr_engine_get_data_version>(); + + /// @platform + /// @brief Extracts the latest update time of an engine from the engine information handle. + /// @since_tizen 3.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/antivirus.admin + /// @param[in] engine The engine information handle + /// @param[out] time A pointer of lasted update time + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid engine information handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a time is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_get_current_engine() + int csr_engine_get_latest_update_time( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer time, + ) { + return _csr_engine_get_latest_update_time( + engine, + time, + ); + } + + late final _csr_engine_get_latest_update_time_ptr = + _lookup>( + 'csr_engine_get_latest_update_time'); + late final _dart_csr_engine_get_latest_update_time + _csr_engine_get_latest_update_time = + _csr_engine_get_latest_update_time_ptr + .asFunction<_dart_csr_engine_get_latest_update_time>(); + + /// @platform + /// @brief Extracts the state of engine activation from the engine information handle. + /// @since_tizen 3.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/antivirus.admin + /// @param[in] engine The engine information handle + /// @param[out] activated A pointer of the engine activation state + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid engine information handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a activated is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_get_current_engine() + int csr_engine_get_activated( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer activated, + ) { + return _csr_engine_get_activated( + engine, + activated, + ); + } + + late final _csr_engine_get_activated_ptr = + _lookup>( + 'csr_engine_get_activated'); + late final _dart_csr_engine_get_activated _csr_engine_get_activated = + _csr_engine_get_activated_ptr + .asFunction<_dart_csr_engine_get_activated>(); + + /// @platform + /// @brief Enable or disable an engine. + /// @since_tizen 3.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/antivirus.admin + /// @remarks If an engine is disabled, all major operations would be failed with #CSR_ERROR_ENGINE_DISABLED error code. + /// @param[in] engine The engine information handle + /// @param[in] state The engine state + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid engine information handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a state is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_get_current_engine() + int csr_engine_set_state( + ffi.Pointer<__csr_engine_h> engine, + int state, + ) { + return _csr_engine_set_state( + engine, + state, + ); + } + + late final _csr_engine_set_state_ptr = + _lookup>( + 'csr_engine_set_state'); + late final _dart_csr_engine_set_state _csr_engine_set_state = + _csr_engine_set_state_ptr.asFunction<_dart_csr_engine_set_state>(); + + /// @platform + /// @brief Gets the engine state. + /// @since_tizen 3.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/antivirus.admin + /// @param[in] engine The engine information handle + /// @param[out] state A pointer of the engine state + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid engine information handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a state is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_get_current_engine() + int csr_engine_get_state( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer state, + ) { + return _csr_engine_get_state( + engine, + state, + ); + } + + late final _csr_engine_get_state_ptr = + _lookup>( + 'csr_engine_get_state'); + late final _dart_csr_engine_get_state _csr_engine_get_state = + _csr_engine_get_state_ptr.asFunction<_dart_csr_engine_get_state>(); + + /// @platform + /// @brief Releases all system resources associated with a engine information handle. + /// @since_tizen 3.0 + /// @param[in] engine The engine information handle + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid engine information handle + int csr_engine_destroy( + ffi.Pointer<__csr_engine_h> engine, + ) { + return _csr_engine_destroy( + engine, + ); + } + + late final _csr_engine_destroy_ptr = + _lookup>('csr_engine_destroy'); + late final _dart_csr_engine_destroy _csr_engine_destroy = + _csr_engine_destroy_ptr.asFunction<_dart_csr_engine_destroy>(); + + /// @partner + /// @brief Initializes and returns a Content Screening API handle. + /// @details A Content Screening API handle (or CSR CS handle) is obtained by this method. + /// The handle is required for subsequent CSR CS API calls. + /// @since_tizen 3.0 + /// @remarks @a handle should be released using csr_cs_context_destroy(). + /// @remarks Multiple handles can be obtained. + /// @param[out] handle A pointer of CSR CS context handle + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE @a handle may be null + /// @retval #CSR_ERROR_OUT_OF_MEMORY Not enough memory + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_context_destroy() + int csr_cs_context_create( + ffi.Pointer> handle, + ) { + return _csr_cs_context_create( + handle, + ); + } + + late final _csr_cs_context_create_ptr = + _lookup>( + 'csr_cs_context_create'); + late final _dart_csr_cs_context_create _csr_cs_context_create = + _csr_cs_context_create_ptr.asFunction<_dart_csr_cs_context_create>(); + + /// @partner + /// @brief Releases all system resources associated with a Content Screening API handle. + /// @since_tizen 3.0 + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_SOCKET Socket error between client and server + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_context_create() + int csr_cs_context_destroy( + ffi.Pointer<__csr_cs_context_s> handle, + ) { + return _csr_cs_context_destroy( + handle, + ); + } + + late final _csr_cs_context_destroy_ptr = + _lookup>( + 'csr_cs_context_destroy'); + late final _dart_csr_cs_context_destroy _csr_cs_context_destroy = + _csr_cs_context_destroy_ptr.asFunction<_dart_csr_cs_context_destroy>(); + + /// @partner + /// @brief Sets a popup option for malware detected. + /// @details If #CSR_CS_ASK_USER_YES is set, a popup will be prompted to a user when a malware is detected. + /// If #CSR_CS_ASK_USER_NO is set which is default value, no popup will be prompted even if a malware is detected. + /// User can allow, disallow, and remove detected malware by popup. + /// Selection can be different between malware's severity. + /// @since_tizen 3.0 + /// @remarks This option is disabled(#CSR_CS_ASK_USER_NO) as a default. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] ask_user Popup option to set or unset + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a ask_user is invalid + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_context_create() + /// @see csr_cs_context_destroy() + int csr_cs_set_ask_user( + ffi.Pointer<__csr_cs_context_s> handle, + int ask_user, + ) { + return _csr_cs_set_ask_user( + handle, + ask_user, + ); + } + + late final _csr_cs_set_ask_user_ptr = + _lookup>( + 'csr_cs_set_ask_user'); + late final _dart_csr_cs_set_ask_user _csr_cs_set_ask_user = + _csr_cs_set_ask_user_ptr.asFunction<_dart_csr_cs_set_ask_user>(); + + /// @partner + /// @brief Sets a popup message of a client in case that a malware is detected. + /// @details Default message is "Malware which may harm your device is detected." + /// @since_tizen 3.0 + /// @remarks Meaningful only when ask user option is set by csr_cs_set_ask_user(). + /// @remarks The message will be printed on popup for user. + /// @remarks Default popup message will be used if it isn't set. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] message A message to print on a popup + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a message is too long or empty. Max size is 64 bytes + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_context_create() + /// @see csr_cs_context_destroy() + int csr_cs_set_popup_message( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer message, + ) { + return _csr_cs_set_popup_message( + handle, + message, + ); + } + + late final _csr_cs_set_popup_message_ptr = + _lookup>( + 'csr_cs_set_popup_message'); + late final _dart_csr_cs_set_popup_message _csr_cs_set_popup_message = + _csr_cs_set_popup_message_ptr + .asFunction<_dart_csr_cs_set_popup_message>(); + + /// @partner + /// @brief Sets a maximum core usage during scanning. + /// @since_tizen 3.0 + /// @remarks If a core usage is not set, #CSR_CS_CORE_USAGE_DEFAULT will be used. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] usage A maximum core usage during scanning + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a usage is invalid + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_context_create() + /// @see csr_cs_context_destroy() + int csr_cs_set_core_usage( + ffi.Pointer<__csr_cs_context_s> handle, + int usage, + ) { + return _csr_cs_set_core_usage( + handle, + usage, + ); + } + + late final _csr_cs_set_core_usage_ptr = + _lookup>( + 'csr_cs_set_core_usage'); + late final _dart_csr_cs_set_core_usage _csr_cs_set_core_usage = + _csr_cs_set_core_usage_ptr.asFunction<_dart_csr_cs_set_core_usage>(); + + /// @partner + /// @brief Sets a scan on cloud option. + /// @since_tizen 3.0 + /// @remarks Scan on cloud option is turned off as a default. + /// @remarks If an engine does not support "scanning on cloud", this option is silently ignored. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] scan_on_cloud Flag of scanning on cloud option + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_context_create() + /// @see csr_cs_context_destroy() + int csr_cs_set_scan_on_cloud( + ffi.Pointer<__csr_cs_context_s> handle, + bool scan_on_cloud, + ) { + return _csr_cs_set_scan_on_cloud( + handle, + scan_on_cloud ? 1 : 0, + ); + } + + late final _csr_cs_set_scan_on_cloud_ptr = + _lookup>( + 'csr_cs_set_scan_on_cloud'); + late final _dart_csr_cs_set_scan_on_cloud _csr_cs_set_scan_on_cloud = + _csr_cs_set_scan_on_cloud_ptr + .asFunction<_dart_csr_cs_set_scan_on_cloud>(); + + /// @partner + /// @brief Scans a data buffer for malware. + /// @details @a malware result of this method is not available for being judged by + /// csr_cs_judge_detected_malware() because it's data and not a file, so it cannot be removed or ignored. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/antivirus.scan + /// @remarks Scan data synchronously. + /// @remarks @a malware will be released when @a handle is released using csr_cs_context_destroy(). + /// @remarks If multiple malwares exists in @a data, the malware with the highest severity will be returned. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] data A scan target data + /// @param[in] length A size of a scan target data + /// @param[out] malware A pointer of the detected malware handle. It can be null when no malware detected + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_OUT_OF_MEMORY Not enough memory + /// @retval #CSR_ERROR_INVALID_PARAMETER @a data or @a malware is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED No privilege to call + /// @retval #CSR_ERROR_NOT_SUPPORTED Device needed to run API is not supported + /// @retval #CSR_ERROR_SOCKET Socket error between client and server + /// @retval #CSR_ERROR_SERVER Server has been failed for some reason + /// @retval #CSR_ERROR_USER_RESPONSE_FAILED Getting user response is failed. + /// @a malware will be allocated on this error + /// @retval #CSR_ERROR_ENGINE_NOT_EXIST No engine exists + /// @retval #CSR_ERROR_ENGINE_DISABLED Engine is in disabled state + /// @retval #CSR_ERROR_ENGINE_NOT_ACTIVATED Engine is not activated + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_context_create() + /// @see csr_cs_context_destroy() + int csr_cs_scan_data( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer data, + int length, + ffi.Pointer> malware, + ) { + return _csr_cs_scan_data( + handle, + data, + length, + malware, + ); + } + + late final _csr_cs_scan_data_ptr = + _lookup>('csr_cs_scan_data'); + late final _dart_csr_cs_scan_data _csr_cs_scan_data = + _csr_cs_scan_data_ptr.asFunction<_dart_csr_cs_scan_data>(); + + /// @partner + /// @brief Scans a file specified by file path for malware. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/antivirus.scan + /// @remarks Scan file synchronously. + /// @remarks @a malware will be released when @a handle is released using csr_cs_context_destroy(). + /// @remarks If multiple malwares exists in a file, the malware with the highest severity will be returned. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] file_path A path of scan target file + /// @param[out] malware A pointer of the detected malware handle. It can be null when no malware detected + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_OUT_OF_MEMORY Not enough memory + /// @retval #CSR_ERROR_INVALID_PARAMETER @a file_path or @a malware is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED Access denied + /// @retval #CSR_ERROR_NOT_SUPPORTED Device needed to run API is not supported + /// @retval #CSR_ERROR_DB DB transaction error + /// @retval #CSR_ERROR_REMOVE_FAILED Removing file or application is failed when malware exist and user select to remove by popup. + /// @a malware will be allocated on this error + /// @retval #CSR_ERROR_USER_RESPONSE_FAILED Getting user response is failed + /// @a malware will be allocated on this error + /// @retval #CSR_ERROR_FILE_DO_NOT_EXIST File not found + /// @retval #CSR_ERROR_SOCKET Socket error between client and server + /// @retval #CSR_ERROR_SERVER Server has been failed for some reason + /// @retval #CSR_ERROR_ENGINE_NOT_EXIST No engine exists + /// @retval #CSR_ERROR_ENGINE_DISABLED Engine is in disabled state + /// @retval #CSR_ERROR_ENGINE_NOT_ACTIVATED Engine is not activated + /// @retval #CSR_ERROR_ENGINE_PERMISSION Insufficient permission of engine + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_context_create() + /// @see csr_cs_context_destroy() + int csr_cs_scan_file( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer file_path, + ffi.Pointer> malware, + ) { + return _csr_cs_scan_file( + handle, + file_path, + malware, + ); + } + + late final _csr_cs_scan_file_ptr = + _lookup>('csr_cs_scan_file'); + late final _dart_csr_cs_scan_file _csr_cs_scan_file = + _csr_cs_scan_file_ptr.asFunction<_dart_csr_cs_scan_file>(); + + /// @partner + /// @brief Sets a callback function for the case that a file scan is completed. + /// @since_tizen 3.0 + /// @remarks Callback for asynchronous scan functions. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] callback A callback function for each file or application scanning done without any malware. + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a callback is invalid + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_scan_files_async() + /// @see csr_cs_scan_dir_async() + /// @see csr_cs_scan_dirs_async() + int csr_cs_set_file_scanned_cb( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, + ) { + return _csr_cs_set_file_scanned_cb( + handle, + callback, + ); + } + + late final _csr_cs_set_file_scanned_cb_ptr = + _lookup>( + 'csr_cs_set_file_scanned_cb'); + late final _dart_csr_cs_set_file_scanned_cb _csr_cs_set_file_scanned_cb = + _csr_cs_set_file_scanned_cb_ptr + .asFunction<_dart_csr_cs_set_file_scanned_cb>(); + + /// @partner + /// @brief Sets a callback function for detection of a malware. + /// @since_tizen 3.0 + /// @remarks Callback for asynchronous scan functions. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] callback A callback function for each file or application scanning done with malware detected + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a callback is invalid + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_scan_files_async() + /// @see csr_cs_scan_dir_async() + /// @see csr_cs_scan_dirs_async() + int csr_cs_set_detected_cb( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, + ) { + return _csr_cs_set_detected_cb( + handle, + callback, + ); + } + + late final _csr_cs_set_detected_cb_ptr = + _lookup>( + 'csr_cs_set_detected_cb'); + late final _dart_csr_cs_set_detected_cb _csr_cs_set_detected_cb = + _csr_cs_set_detected_cb_ptr.asFunction<_dart_csr_cs_set_detected_cb>(); + + /// @partner + /// @brief Sets a callback function for scanning completed without an error. + /// @since_tizen 3.0 + /// @remarks Callback for asynchronous scan functions. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] callback A callback function for scanning completed successfully + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a callback is invalid + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_scan_files_async() + /// @see csr_cs_scan_dir_async() + /// @see csr_cs_scan_dirs_async() + int csr_cs_set_completed_cb( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, + ) { + return _csr_cs_set_completed_cb( + handle, + callback, + ); + } + + late final _csr_cs_set_completed_cb_ptr = + _lookup>( + 'csr_cs_set_completed_cb'); + late final _dart_csr_cs_set_completed_cb _csr_cs_set_completed_cb = + _csr_cs_set_completed_cb_ptr.asFunction<_dart_csr_cs_set_completed_cb>(); + + /// @partner + /// @brief Sets a callback function for scanning cancelled. + /// @since_tizen 3.0 + /// @remarks Callback for asynchronous scan functions. + /// @remarks Client can cancel asynchronous scanning by csr_cs_cancel_scanning(). + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] callback A callback function for scanning cancelled + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a callback is invalid + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_scan_files_async() + /// @see csr_cs_scan_dir_async() + /// @see csr_cs_scan_dirs_async() + /// @see csr_cs_cancel_scanning() + int csr_cs_set_cancelled_cb( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, + ) { + return _csr_cs_set_cancelled_cb( + handle, + callback, + ); + } + + late final _csr_cs_set_cancelled_cb_ptr = + _lookup>( + 'csr_cs_set_cancelled_cb'); + late final _dart_csr_cs_set_cancelled_cb _csr_cs_set_cancelled_cb = + _csr_cs_set_cancelled_cb_ptr.asFunction<_dart_csr_cs_set_cancelled_cb>(); + + /// @partner + /// @brief Sets a callback function for scanning stopped with an error. + /// @since_tizen 3.0 + /// @remarks Callback for asynchronous scan functions. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] callback A callback function for scanning stopped due to an error + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a callback is invalid + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_scan_files_async() + /// @see csr_cs_scan_dir_async() + /// @see csr_cs_scan_dirs_async() + int csr_cs_set_error_cb( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, + ) { + return _csr_cs_set_error_cb( + handle, + callback, + ); + } + + late final _csr_cs_set_error_cb_ptr = + _lookup>( + 'csr_cs_set_error_cb'); + late final _dart_csr_cs_set_error_cb _csr_cs_set_error_cb = + _csr_cs_set_error_cb_ptr.asFunction<_dart_csr_cs_set_error_cb>(); + + /// @partner + /// @brief Scan files specified by an array of file paths for malware. + /// @details If scanning of the single file is done without detected malware, + /// csr_cs_file_scanned_cb() is called and else if malware detected + /// csr_cs_detected_cb() is called. If scanning is cancelled by + /// csr_cs_cancel_scanning(), csr_cs_cancelled_cb() is called. If scanning is failed + /// with error, csr_cs_error_cb() is called. If scanning is completed without + /// error, csr_cs_completed_cb(). Every callbacks are registered by callback + /// setter methods to @a handle and if callback is not registered, it will be just skipped to be called. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/antivirus.scan + /// @remarks Asynchronous function. + /// @remarks The caller should set callback functions before calling this method. + /// @remarks Detected malware which is provided to the callback will be released when + /// @a handle is released using csr_cs_context_destroy(). + /// @remarks If multiple malwares exists in a file, the malware with the highest + /// severity will be returned for the file via csr_cs_set_detected_cb(). + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] file_paths An array of scan target files + /// @param[in] count A number of scan target files + /// @param[in] user_data The pointer of a user data. It can be null. + /// It is delivered back to the client when a callback function is called + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_OUT_OF_MEMORY Not enough memory + /// @retval #CSR_ERROR_INVALID_PARAMETER @a file_paths is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED Access denied + /// @retval #CSR_ERROR_NOT_SUPPORTED Device needed to run API is not supported + /// @retval #CSR_ERROR_BUSY Busy for processing another request + /// @retval #CSR_ERROR_FILE_DO_NOT_EXIST File not found + /// @retval #CSR_ERROR_SOCKET Socket error between client and server + /// @retval #CSR_ERROR_SERVER Server has been failed for some reason + /// @retval #CSR_ERROR_DB DB transaction error + /// @retval #CSR_ERROR_ENGINE_PERMISSION Insufficient permission of engine + /// @retval #CSR_ERROR_ENGINE_NOT_EXIST No engine exists + /// @retval #CSR_ERROR_ENGINE_DISABLED Engine is in disabled state + /// @retval #CSR_ERROR_ENGINE_NOT_ACTIVATED Engine is not activated + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @pre It is required to set callbacks, csr_cs_completed_cb, csr_cs_error_cb(), + /// csr_cs_cancel_scanning(), csr_cs_detected_cb(), and/or csr_cs_file_scanned_cb(). + /// @see csr_cs_set_file_scanned_cb() + /// @see csr_cs_set_detected_cb() + /// @see csr_cs_set_completed_cb() + /// @see csr_cs_set_cancelled_cb() + /// @see csr_cs_set_error_cb() + /// @see csr_cs_cancel_scanning() + int csr_cs_scan_files_async( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> file_paths, + int count, + ffi.Pointer user_data, + ) { + return _csr_cs_scan_files_async( + handle, + file_paths, + count, + user_data, + ); + } + + late final _csr_cs_scan_files_async_ptr = + _lookup>( + 'csr_cs_scan_files_async'); + late final _dart_csr_cs_scan_files_async _csr_cs_scan_files_async = + _csr_cs_scan_files_async_ptr.asFunction<_dart_csr_cs_scan_files_async>(); + + /// @partner + /// @brief Scans a directory specified by directory path for malware. + /// @details If scanning of the single file is done without detected malware, + /// csr_cs_file_scanned_cb() is called and else if malware detected + /// csr_cs_detected_cb() is called. If scanning is cancelled by + /// csr_cs_cancel_scanning(), csr_cs_cancelled_cb() is called. If scanning is failed + /// with error, csr_cs_error_cb() is called. If scanning is completed without + /// error, csr_cs_completed_cb(). Every callbacks are registered by callback + /// setter methods to @a handle and if callback is not registered, it will be just skipped to be called. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/antivirus.scan + /// @remarks Asynchronous function. + /// @remarks The caller should set callback functions before calling this method. + /// @remarks Detected malware which is provided to the callback will be released when + /// @a handle is released using csr_cs_context_destroy(). + /// @remarks If multiple malwares exists in a file, the malware with the highest + /// severity will be returned for the file via csr_cs_set_detected_cb(). + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] dir_path A path of scan target directory + /// @param[in] user_data The pointer of a user data. It can be null. + /// It is used on the callback functions which are registered to @a handle + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_OUT_OF_MEMORY Not enough memory + /// @retval #CSR_ERROR_INVALID_PARAMETER @a dir_path is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED Access denied + /// @retval #CSR_ERROR_NOT_SUPPORTED Device needed to run API is not supported + /// @retval #CSR_ERROR_BUSY Busy for processing another request + /// @retval #CSR_ERROR_FILE_DO_NOT_EXIST File not found + /// @retval #CSR_ERROR_FILE_SYSTEM File type is invalid. It should be directory + /// @retval #CSR_ERROR_SOCKET Socket error between client and server + /// @retval #CSR_ERROR_SERVER Server has been failed for some reason + /// @retval #CSR_ERROR_DB DB transaction error + /// @retval #CSR_ERROR_ENGINE_PERMISSION Insufficient permission of engine + /// @retval #CSR_ERROR_ENGINE_NOT_EXIST No engine exists + /// @retval #CSR_ERROR_ENGINE_DISABLED Engine is in disabled state + /// @retval #CSR_ERROR_ENGINE_NOT_ACTIVATED Engine is not activated + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @pre It is required to set callbacks, csr_cs_completed_cb, csr_cs_error_cb(), + /// csr_cs_cancel_scanning(), csr_cs_detected_cb(), and/or csr_cs_file_scanned_cb(). + /// @see csr_cs_set_file_scanned_cb() + /// @see csr_cs_set_detected_cb() + /// @see csr_cs_set_completed_cb() + /// @see csr_cs_set_cancelled_cb() + /// @see csr_cs_set_error_cb() + /// @see csr_cs_cancel_scanning() + int csr_cs_scan_dir_async( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer dir_path, + ffi.Pointer user_data, + ) { + return _csr_cs_scan_dir_async( + handle, + dir_path, + user_data, + ); + } + + late final _csr_cs_scan_dir_async_ptr = + _lookup>( + 'csr_cs_scan_dir_async'); + late final _dart_csr_cs_scan_dir_async _csr_cs_scan_dir_async = + _csr_cs_scan_dir_async_ptr.asFunction<_dart_csr_cs_scan_dir_async>(); + + /// @partner + /// @brief Scan directories specified by an array of directory paths for malware. + /// @details If scanning of the single file is done without detected malware, + /// csr_cs_file_scanned_cb() is called and else if malware detected + /// csr_cs_detected_cb() is called. If scanning is cancelled by + /// csr_cs_cancel_scanning(), csr_cs_cancelled_cb() is called. If scanning is failed + /// with error, csr_cs_error_cb() is called. If scanning is completed without + /// error, csr_cs_completed_cb(). Every callbacks are registered by callback + /// setter methods to @a handle and if callback is not registered, it will just be skipped to be called. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/antivirus.scan + /// @remarks Asynchronous function. + /// @remarks The caller should set callback functions before calls this method. + /// @remarks Detected malware which is provided to the callback will be released when + /// @a handle is released using csr_cs_context_destroy(). + /// @remarks If multiple malwares exists in a file, the malware with the highest + /// severity will be returned for the file via csr_cs_set_detected_cb(). + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] dir_paths An array of scan target directories + /// @param[in] count A number of scan target directories + /// @param[in] user_data The pointer of a user data. It can be null. It is used on + /// the callback functions which are registered to @a handle + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_OUT_OF_MEMORY Not enough memory + /// @retval #CSR_ERROR_INVALID_PARAMETER @a dir_paths is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED Access denied + /// @retval #CSR_ERROR_NOT_SUPPORTED Device needed to run API is not supported + /// @retval #CSR_ERROR_BUSY Busy for processing another request + /// @retval #CSR_ERROR_FILE_DO_NOT_EXIST File not found + /// @retval #CSR_ERROR_FILE_SYSTEM File type is invalid. It should be directory + /// @retval #CSR_ERROR_SOCKET Socket error between client and server + /// @retval #CSR_ERROR_SERVER Server has been failed for some reason + /// @retval #CSR_ERROR_DB DB transaction error + /// @retval #CSR_ERROR_ENGINE_PERMISSION Insufficient permission of engine + /// @retval #CSR_ERROR_ENGINE_NOT_EXIST No engine exists + /// @retval #CSR_ERROR_ENGINE_DISABLED Engine is in disabled state + /// @retval #CSR_ERROR_ENGINE_NOT_ACTIVATED Engine is not activated + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @pre It is required to set callbacks, csr_cs_completed_cb, csr_cs_error_cb(), + /// csr_cs_cancel_scanning(), csr_cs_detected_cb(), and/or csr_cs_file_scanned_cb(). + /// @see csr_cs_set_file_scanned_cb() + /// @see csr_cs_set_detected_cb() + /// @see csr_cs_set_completed_cb() + /// @see csr_cs_set_cancelled_cb() + /// @see csr_cs_set_error_cb() + /// @see csr_cs_cancel_scanning() + int csr_cs_scan_dirs_async( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> dir_paths, + int count, + ffi.Pointer user_data, + ) { + return _csr_cs_scan_dirs_async( + handle, + dir_paths, + count, + user_data, + ); + } + + late final _csr_cs_scan_dirs_async_ptr = + _lookup>( + 'csr_cs_scan_dirs_async'); + late final _dart_csr_cs_scan_dirs_async _csr_cs_scan_dirs_async = + _csr_cs_scan_dirs_async_ptr.asFunction<_dart_csr_cs_scan_dirs_async>(); + + /// @partner + /// @brief Cancels a running scanning task, asynchronously. + /// @since_tizen 3.0 + /// @remarks Only for asynchronous scan functions. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_NO_TASK No task to cancel + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_scan_files_async() + /// @see csr_cs_scan_dir_async() + /// @see csr_cs_scan_dirs_async() + int csr_cs_cancel_scanning( + ffi.Pointer<__csr_cs_context_s> handle, + ) { + return _csr_cs_cancel_scanning( + handle, + ); + } + + late final _csr_cs_cancel_scanning_ptr = + _lookup>( + 'csr_cs_cancel_scanning'); + late final _dart_csr_cs_cancel_scanning _csr_cs_cancel_scanning = + _csr_cs_cancel_scanning_ptr.asFunction<_dart_csr_cs_cancel_scanning>(); + + /// @partner + /// @brief Extracts the severity of a detected malware from the detected malware handle. + /// @since_tizen 3.0 + /// @param[in] malware A detected malware handle returned by csr_cs_scan_data(), + /// csr_cs_scan_file() or csr_cs_malware_list_get_malware() + /// @param[out] severity A pointer of the severity of a detected malware + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid detected malware handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a severity is invalid + /// @retval #CSR_ERROR_SYSTEM System error + int csr_cs_malware_get_severity( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer severity, + ) { + return _csr_cs_malware_get_severity( + malware, + severity, + ); + } + + late final _csr_cs_malware_get_severity_ptr = + _lookup>( + 'csr_cs_malware_get_severity'); + late final _dart_csr_cs_malware_get_severity _csr_cs_malware_get_severity = + _csr_cs_malware_get_severity_ptr + .asFunction<_dart_csr_cs_malware_get_severity>(); + + /// @partner + /// @brief Extracts the name of a detected malware from the detected malware handle. + /// @since_tizen 3.0 + /// @remarks @a name must be released using free(). + /// @param[in] malware A detected malware handle + /// @param[out] name A pointer of the name of a detected malware + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid detected malware handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a name is invalid + /// @retval #CSR_ERROR_SYSTEM System error + int csr_cs_malware_get_name( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer> name, + ) { + return _csr_cs_malware_get_name( + malware, + name, + ); + } + + late final _csr_cs_malware_get_name_ptr = + _lookup>( + 'csr_cs_malware_get_name'); + late final _dart_csr_cs_malware_get_name _csr_cs_malware_get_name = + _csr_cs_malware_get_name_ptr.asFunction<_dart_csr_cs_malware_get_name>(); + + /// @partner + /// @brief Extracts an url that contains detailed information on vendor's web site from the detected malware handle. + /// @since_tizen 3.0 + /// @remarks @a detailed_url must be released using free(). + /// @param[in] malware A detected malware handle + /// @param[out] detailed_url A pointer of an url that contains detailed information on + /// vendor's web site. It can be null if a vendor doesn't provide this information + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid detected malware handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a detailed_url is invalid. + /// @retval #CSR_ERROR_SYSTEM System error + int csr_cs_malware_get_detailed_url( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer> detailed_url, + ) { + return _csr_cs_malware_get_detailed_url( + malware, + detailed_url, + ); + } + + late final _csr_cs_malware_get_detailed_url_ptr = + _lookup>( + 'csr_cs_malware_get_detailed_url'); + late final _dart_csr_cs_malware_get_detailed_url + _csr_cs_malware_get_detailed_url = _csr_cs_malware_get_detailed_url_ptr + .asFunction<_dart_csr_cs_malware_get_detailed_url>(); + + /// @partner + /// @brief Extracts the time stamp when a malware is detected from the detected malware handle. + /// @since_tizen 3.0 + /// @param[in] malware A detected malware handle + /// @param[out] timestamp A pointer of the time stamp in milli second when a malware is detected + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid detected malware handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a timestamp is invalid + /// @retval #CSR_ERROR_SYSTEM System error + int csr_cs_malware_get_timestamp( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer timestamp, + ) { + return _csr_cs_malware_get_timestamp( + malware, + timestamp, + ); + } + + late final _csr_cs_malware_get_timestamp_ptr = + _lookup>( + 'csr_cs_malware_get_timestamp'); + late final _dart_csr_cs_malware_get_timestamp _csr_cs_malware_get_timestamp = + _csr_cs_malware_get_timestamp_ptr + .asFunction<_dart_csr_cs_malware_get_timestamp>(); + + /// @partner + /// @brief Extracts the file name where a malware is detected from the detected malware handle. + /// @since_tizen 3.0 + /// @remarks @a file_name must be released using free(). + /// @param[in] malware A detected malware handle + /// @param[out] file_name A pointer of the file name where a malware is detected. The file name is null for csr_cs_scan_data() + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid detected malware handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a file_name is invalid + /// @retval #CSR_ERROR_SYSTEM System error + int csr_cs_malware_get_file_name( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer> file_name, + ) { + return _csr_cs_malware_get_file_name( + malware, + file_name, + ); + } + + late final _csr_cs_malware_get_file_name_ptr = + _lookup>( + 'csr_cs_malware_get_file_name'); + late final _dart_csr_cs_malware_get_file_name _csr_cs_malware_get_file_name = + _csr_cs_malware_get_file_name_ptr + .asFunction<_dart_csr_cs_malware_get_file_name>(); + + /// @partner + /// @brief Extracts a user response of a popup from the detected malware handle. + /// @since_tizen 3.0 + /// @param[in] malware A detected malware handle + /// @param[out] response A pointer of the user response + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid result handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a response is invalid + /// @retval #CSR_ERROR_SYSTEM System error + int csr_cs_malware_get_user_response( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer response, + ) { + return _csr_cs_malware_get_user_response( + malware, + response, + ); + } + + late final _csr_cs_malware_get_user_response_ptr = + _lookup>( + 'csr_cs_malware_get_user_response'); + late final _dart_csr_cs_malware_get_user_response + _csr_cs_malware_get_user_response = _csr_cs_malware_get_user_response_ptr + .asFunction<_dart_csr_cs_malware_get_user_response>(); + + /// @partner + /// @brief Checks if a malware was detected in an application or in a file. + /// @since_tizen 3.0 + /// @param[in] malware A detected malware handle + /// @param[out] is_app A pointer of a flag indicating the position where a malware was detected. + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid result handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a is_app is invalid + /// @retval #CSR_ERROR_SYSTEM System error + int csr_cs_malware_is_app( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer is_app, + ) { + return _csr_cs_malware_is_app( + malware, + is_app, + ); + } + + late final _csr_cs_malware_is_app_ptr = + _lookup>( + 'csr_cs_malware_is_app'); + late final _dart_csr_cs_malware_is_app _csr_cs_malware_is_app = + _csr_cs_malware_is_app_ptr.asFunction<_dart_csr_cs_malware_is_app>(); + + /// @partner + /// @brief Extracts the package id of an application where a malware is detected from detected malware handle. + /// @since_tizen 3.0 + /// @remarks @a pkg_id must be released using free(). + /// @param[in] malware A detected malware handle + /// @param[out] pkg_id A pointer of the package id where a malware is detected. + /// It is null when a malware was not detected in an application + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid detected malware handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a pkg_id is invalid + /// @retval #CSR_ERROR_SYSTEM System error + int csr_cs_malware_get_pkg_id( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer> pkg_id, + ) { + return _csr_cs_malware_get_pkg_id( + malware, + pkg_id, + ); + } + + late final _csr_cs_malware_get_pkg_id_ptr = + _lookup>( + 'csr_cs_malware_get_pkg_id'); + late final _dart_csr_cs_malware_get_pkg_id _csr_cs_malware_get_pkg_id = + _csr_cs_malware_get_pkg_id_ptr + .asFunction<_dart_csr_cs_malware_get_pkg_id>(); + + /// @platform + /// @brief Judges how a detected malware file is handled. + /// @details Detected malware will be removed by #CSR_CS_ACTION_REMOVE action. + /// File or application which contains malware will be removed. + /// Detected malware will be ignored by #CSR_CS_ACTION_IGNORE action. + /// File or application which contains malware will be ignored and will not be treated + /// as malware until this API is called with #CSR_CS_ACTION_UNIGNORE action. + /// @since_tizen 3.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/antivirus.admin + /// @remarks Detected malware can be removed or ignored. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] malware A handle of a detected malware + /// @param[in] action An action to be taken + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_OUT_OF_MEMORY Not enough memory + /// @retval #CSR_ERROR_INVALID_PARAMETER @a malware or @a action is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED No permission to remove + /// @retval #CSR_ERROR_FILE_DO_NOT_EXIST File to take action on not found + /// @retval #CSR_ERROR_FILE_CHANGED File to take action on changed after detection + /// @retval #CSR_ERROR_SOCKET Socket error between client and server + /// @retval #CSR_ERROR_SERVER Server has been failed for some reason + /// @retval #CSR_ERROR_DB DB transaction error + /// @retval #CSR_ERROR_REMOVE_FAILED Removing file or application is failed + /// @retval #CSR_ERROR_SYSTEM System error + int csr_cs_judge_detected_malware( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer<__csr_cs_malware_s> malware, + int action, + ) { + return _csr_cs_judge_detected_malware( + handle, + malware, + action, + ); + } + + late final _csr_cs_judge_detected_malware_ptr = + _lookup>( + 'csr_cs_judge_detected_malware'); + late final _dart_csr_cs_judge_detected_malware + _csr_cs_judge_detected_malware = _csr_cs_judge_detected_malware_ptr + .asFunction<_dart_csr_cs_judge_detected_malware>(); + + /// @partner + /// @brief Gets information on a detected malware file specified by file path. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/antivirus.scan + /// @remarks @a malware will be released when @a handle is destroyed. + /// @remarks @a file_path will be null if it's result of csr_cs_scan_data(). + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] file_path A path of a detected malware file + /// @param[out] malware A pointer of the detected malware handle. It can be null when no malware file + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_OUT_OF_MEMORY Not enough memory + /// @retval #CSR_ERROR_INVALID_PARAMETER @a file_path or @a malware is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED No permission to remove + /// @retval #CSR_ERROR_FILE_DO_NOT_EXIST No malware file + /// @retval #CSR_ERROR_SOCKET Socket error between client and server + /// @retval #CSR_ERROR_SERVER Server has been failed for some reason + /// @retval #CSR_ERROR_DB DB transaction error + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_cs_scan_data() + /// @see csr_cs_scan_file() + /// @see csr_cs_detected_cb + int csr_cs_get_detected_malware( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer file_path, + ffi.Pointer> malware, + ) { + return _csr_cs_get_detected_malware( + handle, + file_path, + malware, + ); + } + + late final _csr_cs_get_detected_malware_ptr = + _lookup>( + 'csr_cs_get_detected_malware'); + late final _dart_csr_cs_get_detected_malware _csr_cs_get_detected_malware = + _csr_cs_get_detected_malware_ptr + .asFunction<_dart_csr_cs_get_detected_malware>(); + + /// @partner + /// @brief Gets information on a detected malware files specified by directory path. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/antivirus.scan + /// @remarks @a list will be released when @a handle is destroyed. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] dir_paths A directory path where detected malware files exists + /// @param[in] count Count of array element of @a dir_paths + /// @param[out] list A pointer of the detected malware list handle. It can be null when there is no malware file + /// @param[out] list_count Count of detected malware files which existed in the specified directory + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_OUT_OF_MEMORY Not enough memory + /// @retval #CSR_ERROR_INVALID_PARAMETER @a dir_paths, @a list, or @a count is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED No permission to remove + /// @retval #CSR_ERROR_FILE_DO_NOT_EXIST No malware file + /// @retval #CSR_ERROR_SOCKET Socket error between client and server + /// @retval #CSR_ERROR_SERVER Server has been failed for some reason + /// @retval #CSR_ERROR_DB DB transaction error + /// @retval #CSR_ERROR_SYSTEM System error + int csr_cs_get_detected_malwares( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> dir_paths, + int count, + ffi.Pointer> list, + ffi.Pointer list_count, + ) { + return _csr_cs_get_detected_malwares( + handle, + dir_paths, + count, + list, + list_count, + ); + } + + late final _csr_cs_get_detected_malwares_ptr = + _lookup>( + 'csr_cs_get_detected_malwares'); + late final _dart_csr_cs_get_detected_malwares _csr_cs_get_detected_malwares = + _csr_cs_get_detected_malwares_ptr + .asFunction<_dart_csr_cs_get_detected_malwares>(); + + /// @partner + /// @brief Gets information on a ignored malware file specified by file path. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/antivirus.scan + /// @remarks @a malware will be released when @a handle is destroyed. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] file_path A path of a ignored malware file + /// @param[out] malware A pointer of the detected malware handle. It can be null when no ignored file + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_OUT_OF_MEMORY Not enough memory + /// @retval #CSR_ERROR_INVALID_PARAMETER @a file_path or @a malware is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED No permission to remove + /// @retval #CSR_ERROR_FILE_DO_NOT_EXIST No ignored file + /// @retval #CSR_ERROR_SOCKET Socket error between client and server + /// @retval #CSR_ERROR_SERVER Server has been failed for some reason + /// @retval #CSR_ERROR_DB DB transaction error + /// @retval #CSR_ERROR_SYSTEM System error + int csr_cs_get_ignored_malware( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer file_path, + ffi.Pointer> malware, + ) { + return _csr_cs_get_ignored_malware( + handle, + file_path, + malware, + ); + } + + late final _csr_cs_get_ignored_malware_ptr = + _lookup>( + 'csr_cs_get_ignored_malware'); + late final _dart_csr_cs_get_ignored_malware _csr_cs_get_ignored_malware = + _csr_cs_get_ignored_malware_ptr + .asFunction<_dart_csr_cs_get_ignored_malware>(); + + /// @partner + /// @brief Gets information on ignored malware files specified by directory path. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/antivirus.scan + /// @remarks @a list will be released when @a handle is destroyed. + /// @param[in] handle CSR CS context handle returned by csr_cs_context_create() + /// @param[in] dir_paths A directory path where ignored malware files exists + /// @param[in] count Count of array element of @a dir_paths + /// @param[out] list A pointer of the detected malware list handle. It can be null when no ignored file + /// @param[out] list_count Count of ignored malware files which existed in the specified directory + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_OUT_OF_MEMORY Not enough memory + /// @retval #CSR_ERROR_INVALID_PARAMETER @a dir_paths, @a list, or @a count is invalid + /// @retval #CSR_ERROR_PERMISSION_DENIED No permission to remove + /// @retval #CSR_ERROR_FILE_DO_NOT_EXIST No ignored file + /// @retval #CSR_ERROR_SOCKET Socket error between client and server + /// @retval #CSR_ERROR_SERVER Server has been failed for some reason + /// @retval #CSR_ERROR_DB DB transaction error + /// @retval #CSR_ERROR_SYSTEM System error + int csr_cs_get_ignored_malwares( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> dir_paths, + int count, + ffi.Pointer> list, + ffi.Pointer list_count, + ) { + return _csr_cs_get_ignored_malwares( + handle, + dir_paths, + count, + list, + list_count, + ); + } + + late final _csr_cs_get_ignored_malwares_ptr = + _lookup>( + 'csr_cs_get_ignored_malwares'); + late final _dart_csr_cs_get_ignored_malwares _csr_cs_get_ignored_malwares = + _csr_cs_get_ignored_malwares_ptr + .asFunction<_dart_csr_cs_get_ignored_malwares>(); + + /// @partner + /// @brief Extracts the detected malware handle from the detected malware list handle. + /// @since_tizen 3.0 + /// @remarks @a malware will be released when a context is released using csr_cs_context_destroy(). + /// @param[in] list A detected malware list handle returned by csr_cs_get_detected_malwares() or csr_cs_get_ignored_malwares() + /// @param[in] index An index of a target detected malware handle to get + /// @param[out] malware A pointer of the detected malware handle. It can be null when index is invalid + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid list + /// @retval #CSR_ERROR_INVALID_PARAMETER @a index or @a malware is invalid + /// @retval #CSR_ERROR_SYSTEM System error + int csr_cs_malware_list_get_malware( + ffi.Pointer<__csr_cs_malware_list_s> list, + int index, + ffi.Pointer> malware, + ) { + return _csr_cs_malware_list_get_malware( + list, + index, + malware, + ); + } + + late final _csr_cs_malware_list_get_malware_ptr = + _lookup>( + 'csr_cs_malware_list_get_malware'); + late final _dart_csr_cs_malware_list_get_malware + _csr_cs_malware_list_get_malware = _csr_cs_malware_list_get_malware_ptr + .asFunction<_dart_csr_cs_malware_list_get_malware>(); + + /// @partner + /// @brief Initializes and returns a CSR Web Protection API handle. + /// @details A Web Protection API handle (or CSR WP handle) is obtained by this method. + /// The handle is required for subsequent CSR WP API calls. + /// @since_tizen 3.0 + /// @remarks @a handle should be released using csr_wp_context_destroy(). + /// @remarks Multiple handles can be obtained. + /// @param[out] handle A pointer of CSR WP context handle + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_OUT_OF_MEMORY Not enough memory + /// @retval #CSR_ERROR_INVALID_PARAMETER @a handle is invalid + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_wp_context_destroy() + int csr_wp_context_create( + ffi.Pointer> handle, + ) { + return _csr_wp_context_create( + handle, + ); + } + + late final _csr_wp_context_create_ptr = + _lookup>( + 'csr_wp_context_create'); + late final _dart_csr_wp_context_create _csr_wp_context_create = + _csr_wp_context_create_ptr.asFunction<_dart_csr_wp_context_create>(); + + /// @partner + /// @brief Releases all system resources associated with a Web Protection API handle. + /// @since_tizen 3.0 + /// @param[in] handle CSR WP context handle returned by csr_wp_context_create() + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_SOCKET Socket error between client and server + /// @retval #CSR_ERROR_SERVER Server has been failed for some reason + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_wp_context_create() + int csr_wp_context_destroy( + ffi.Pointer<__csr_wp_context_s> handle, + ) { + return _csr_wp_context_destroy( + handle, + ); + } + + late final _csr_wp_context_destroy_ptr = + _lookup>( + 'csr_wp_context_destroy'); + late final _dart_csr_wp_context_destroy _csr_wp_context_destroy = + _csr_wp_context_destroy_ptr.asFunction<_dart_csr_wp_context_destroy>(); + + /// @partner + /// @brief Sets a popup option for risky URL checked. + /// @details If #CSR_WP_ASK_USER_YES is set, a popup will be prompted to a user when a URL turns out risky. + /// If #CSR_WP_ASK_USER_NO is set, no popup will be prompted even when a URL turns out risky. + /// @since_tizen 3.0 + /// @remarks This option is disabled(#CSR_WP_ASK_USER_NO) as a default. + /// @param[in] handle CSR WP context handle returned by csr_wp_context_create() + /// @param[in] ask_user A popup option in case for a risky URL + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a ask_user is invalid + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_wp_context_create() + int csr_wp_set_ask_user( + ffi.Pointer<__csr_wp_context_s> handle, + int ask_user, + ) { + return _csr_wp_set_ask_user( + handle, + ask_user, + ); + } + + late final _csr_wp_set_ask_user_ptr = + _lookup>( + 'csr_wp_set_ask_user'); + late final _dart_csr_wp_set_ask_user _csr_wp_set_ask_user = + _csr_wp_set_ask_user_ptr.asFunction<_dart_csr_wp_set_ask_user>(); + + /// @partner + /// @brief Sets a popup message of a client in case for a risky URL. + /// @details Default message is "Risky URL which may harm your device is detected". + /// @since_tizen 3.0 + /// @remarks Meaningful only when ask user option is set by csr_wp_set_ask_user(). + /// @remarks The message will be printed on popup for user. + /// @remarks Default popup message will be used if it isn't set. + /// @param[in] handle CSR WP context handle returned by csr_wp_context_create() + /// @param[in] message A message to print on a popup + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a message is too long or empty. Max size is 64 bytes + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_wp_context_create() + int csr_wp_set_popup_message( + ffi.Pointer<__csr_wp_context_s> handle, + ffi.Pointer message, + ) { + return _csr_wp_set_popup_message( + handle, + message, + ); + } + + late final _csr_wp_set_popup_message_ptr = + _lookup>( + 'csr_wp_set_popup_message'); + late final _dart_csr_wp_set_popup_message _csr_wp_set_popup_message = + _csr_wp_set_popup_message_ptr + .asFunction<_dart_csr_wp_set_popup_message>(); + + /// @partner + /// @brief Checks URL reputation against the engine vendor's database. + /// @details Checks whether accessing the URL is risky or not and returns a result handle with the risk level for the URL. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/antivirus.webprotect + /// @remarks @a result will be released when @a handle is released using csr_wp_context_destroy(). + /// @param[in] handle CSR WP context handle returned by csr_wp_context_create() + /// @param[in] url URL to check + /// @param[out] result A pointer of the result handle with the Risk level for the URL + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid handle + /// @retval #CSR_ERROR_OUT_OF_MEMORY Not enough memory + /// @retval #CSR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CSR_ERROR_NOT_SUPPORTED Device needed to run API is not supported + /// @retval #CSR_ERROR_INVALID_PARAMETER @a url or @a result is invalid + /// @retval #CSR_ERROR_SOCKET Socket error between client and server + /// @retval #CSR_ERROR_SERVER Server has been failed for some reason + /// @retval #CSR_ERROR_USER_RESPONSE_FAILED Getting user response is failed. + /// @a result will be allocated on this error + /// @retval #CSR_ERROR_ENGINE_NOT_EXIST No engine exists + /// @retval #CSR_ERROR_ENGINE_DISABLED Engine is in disabled state + /// @retval #CSR_ERROR_ENGINE_NOT_ACTIVATED Engine is not activated + /// @retval #CSR_ERROR_ENGINE_INTERNAL Engine Internal error + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_wp_context_create() + /// @see csr_wp_set_ask_user() + /// @see csr_wp_set_popup_message() + int csr_wp_check_url( + ffi.Pointer<__csr_wp_context_s> handle, + ffi.Pointer url, + ffi.Pointer> result, + ) { + return _csr_wp_check_url( + handle, + url, + result, + ); + } + + late final _csr_wp_check_url_ptr = + _lookup>('csr_wp_check_url'); + late final _dart_csr_wp_check_url _csr_wp_check_url = + _csr_wp_check_url_ptr.asFunction<_dart_csr_wp_check_url>(); + + /// @partner + /// @brief Extracts a risk level of the url from the result handle. + /// @since_tizen 3.0 + /// @param[in] result A result handle returned by csr_wp_check_url() + /// @param[out] level A pointer of the risk level for the given URL + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid result handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a level is invalid + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_wp_check_url() + int csr_wp_result_get_risk_level( + ffi.Pointer<__csr_wp_check_result_h> result, + ffi.Pointer level, + ) { + return _csr_wp_result_get_risk_level( + result, + level, + ); + } + + late final _csr_wp_result_get_risk_level_ptr = + _lookup>( + 'csr_wp_result_get_risk_level'); + late final _dart_csr_wp_result_get_risk_level _csr_wp_result_get_risk_level = + _csr_wp_result_get_risk_level_ptr + .asFunction<_dart_csr_wp_result_get_risk_level>(); + + /// @partner + /// @brief Extracts an url of vendor's web site that contains detailed information about the risk from the result handle. + /// @since_tizen 3.0 + /// @remarks @a detailed_url must be released using free(). + /// @param[in] result A result handle returned by csr_wp_check_url() + /// @param[out] detailed_url A pointer of an url that contains detailed information about the risk + /// If the risk level is #CSR_WP_RISK_MEDIUM or #CSR_WP_RISK_HIGH, + /// this url should be provided by the engine + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid result handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a detailed_url is invalid + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_wp_check_url() + int csr_wp_result_get_detailed_url( + ffi.Pointer<__csr_wp_check_result_h> result, + ffi.Pointer> detailed_url, + ) { + return _csr_wp_result_get_detailed_url( + result, + detailed_url, + ); + } + + late final _csr_wp_result_get_detailed_url_ptr = + _lookup>( + 'csr_wp_result_get_detailed_url'); + late final _dart_csr_wp_result_get_detailed_url + _csr_wp_result_get_detailed_url = _csr_wp_result_get_detailed_url_ptr + .asFunction<_dart_csr_wp_result_get_detailed_url>(); + + /// @partner + /// @brief Extracts a user response of a popup from the result handle. + /// @since_tizen 3.0 + /// @param[in] result A result handle returned by csr_wp_check_url() + /// @param[out] response A pointer of the user response + /// @return #CSR_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CSR_ERROR_NONE Successful + /// @retval #CSR_ERROR_INVALID_HANDLE Invalid result handle + /// @retval #CSR_ERROR_INVALID_PARAMETER @a response is invalid + /// @retval #CSR_ERROR_SYSTEM System error + /// @see csr_wp_check_url() + /// @see #csr_wp_user_response_e + int csr_wp_result_get_user_response( + ffi.Pointer<__csr_wp_check_result_h> result, + ffi.Pointer response, + ) { + return _csr_wp_result_get_user_response( + result, + response, + ); + } + + late final _csr_wp_result_get_user_response_ptr = + _lookup>( + 'csr_wp_result_get_user_response'); + late final _dart_csr_wp_result_get_user_response + _csr_wp_result_get_user_response = _csr_wp_result_get_user_response_ptr + .asFunction<_dart_csr_wp_result_get_user_response>(); + + /// @brief Creates the device policy manager handle. + /// @details This API creates device policy manager handle required to + /// the device policy APIs. + /// This API is also used to verify whether caller is authorized + /// or not. + /// @since_tizen 3.0 + /// @return Device policy manager handle on success, otherwise NULL + /// @remarks The specific error code can be obtained by using the + /// get_last_result() method. Error codes are described in + /// exception section. + /// The returned handle should be released using dpm_manager_destroy(). + /// @exception #DPM_ERROR_NONE No error + /// @exception #DPM_ERROR_CONNECTION_REFUSED Connection refused + /// @exception #DPM_ERROR_OUT_OF_MEMORY Out of memory + /// @see dpm_manager_destroy() + /// @see get_last_result() + ffi.Pointer dpm_manager_create() { + return _dpm_manager_create(); + } + + late final _dpm_manager_create_ptr = + _lookup>('dpm_manager_create'); + late final _dart_dpm_manager_create _dpm_manager_create = + _dpm_manager_create_ptr.asFunction<_dart_dpm_manager_create>(); + + /// @brief Releases the device policy manager handle. + /// @details This API must be called if interaction with the device + /// policy manager is no longer required. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_manager_destroy( + ffi.Pointer handle, + ) { + return _dpm_manager_destroy( + handle, + ); + } + + late final _dpm_manager_destroy_ptr = + _lookup>( + 'dpm_manager_destroy'); + late final _dart_dpm_manager_destroy _dpm_manager_destroy = + _dpm_manager_destroy_ptr.asFunction<_dart_dpm_manager_destroy>(); + + /// @brief Adds policy change callback to the device policy + /// manager. + /// @details This API can be used to subscribe policy change callback. + /// The callback specified to this API is asynchronously called when + /// policy is changed on runtime. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[in] name Policy name to subscribe(see @ref CAPI_SECURITY_DPM_MODULE_POLICY) + /// @param[in] callback The callback when policy is changed + /// @param[in] user_data User specified data passed to the callback + /// @param[out] id Policy change callback identifier + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @remarks See @ref CAPI_SECURITY_DPM_MODULE_POLICY section for available policy name + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_remove_policy_changed_cb() + int dpm_add_policy_changed_cb( + ffi.Pointer handle, + ffi.Pointer name, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, + ) { + return _dpm_add_policy_changed_cb( + handle, + name, + callback, + user_data, + id, + ); + } + + late final _dpm_add_policy_changed_cb_ptr = + _lookup>( + 'dpm_add_policy_changed_cb'); + late final _dart_dpm_add_policy_changed_cb _dpm_add_policy_changed_cb = + _dpm_add_policy_changed_cb_ptr + .asFunction<_dart_dpm_add_policy_changed_cb>(); + + /// @brief Removes policy change callback from the device policy + /// manager. + /// @details This API should be called if policy change subscription is no longer + /// required. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[in] id Policy change callback identifier + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @pre The handle must be created by dpm_manager_create(). + /// @pre The callback identifier must be created by dpm_manager_add_policy_changed_cb(). + /// @see dpm_manager_create() + /// @see dpm_add_policy_changed_cb() + int dpm_remove_policy_changed_cb( + ffi.Pointer handle, + int id, + ) { + return _dpm_remove_policy_changed_cb( + handle, + id, + ); + } + + late final _dpm_remove_policy_changed_cb_ptr = + _lookup>( + 'dpm_remove_policy_changed_cb'); + late final _dart_dpm_remove_policy_changed_cb _dpm_remove_policy_changed_cb = + _dpm_remove_policy_changed_cb_ptr + .asFunction<_dart_dpm_remove_policy_changed_cb>(); + + /// @brief Adds signal callback. + /// @details This API can be used to receive signals raised by the device policy manager. + /// The callback specified to this function is automatically called when + /// the device policy manager raises signal. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[in] signal The signal name to receive(see @ref CAPI_DPM_SECURITY_MODULE_SIGNAL) + /// @param[in] callback The signal callback + /// @param[in] user_data The user data passed to the callback function + /// @param[out] id Signal identifier + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @remarks See @ref CAPI_DPM_SECURITY_MODULE_SIGNAL section for signals + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_manager_destroy() + /// @see dpm_remove_signal_cb() + int dpm_add_signal_cb( + ffi.Pointer handle, + ffi.Pointer signal, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, + ) { + return _dpm_add_signal_cb( + handle, + signal, + callback, + user_data, + id, + ); + } + + late final _dpm_add_signal_cb_ptr = + _lookup>('dpm_add_signal_cb'); + late final _dart_dpm_add_signal_cb _dpm_add_signal_cb = + _dpm_add_signal_cb_ptr.asFunction<_dart_dpm_add_signal_cb>(); + + /// @brief Removes signal callback. + /// @details This API removes signal callback. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[in] id Signal identifier + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @pre The context must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_manager_destroy() + /// @see dpm_add_signal_cb() + int dpm_remove_signal_cb( + ffi.Pointer handle, + int id, + ) { + return _dpm_remove_signal_cb( + handle, + id, + ); + } + + late final _dpm_remove_signal_cb_ptr = + _lookup>( + 'dpm_remove_signal_cb'); + late final _dart_dpm_remove_signal_cb _dpm_remove_signal_cb = + _dpm_remove_signal_cb_ptr.asFunction<_dart_dpm_remove_signal_cb>(); + + /// @partner + /// @brief Sets password quality. + /// @details An administrator can set the password restrictions it is imposing. + /// After setting this, the user will not be able to + /// enter a new password that is not at least as restrictive as what has been set. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[in] quality Password quality type, values of #dpm_password_quality_e combined with bitwise 'or' + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_set_quality( + ffi.Pointer handle, + int quality, + ) { + return _dpm_password_set_quality( + handle, + quality, + ); + } + + late final _dpm_password_set_quality_ptr = + _lookup>( + 'dpm_password_set_quality'); + late final _dart_dpm_password_set_quality _dpm_password_set_quality = + _dpm_password_set_quality_ptr + .asFunction<_dart_dpm_password_set_quality>(); + + /// @partner + /// @brief Gets password quality. + /// @details An administrator can get the password restrictions it is imposing. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[out] quality Password quality type, values of #dpm_password_quality_e combined with bitwise 'or' + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_get_quality( + ffi.Pointer handle, + ffi.Pointer quality, + ) { + return _dpm_password_get_quality( + handle, + quality, + ); + } + + late final _dpm_password_get_quality_ptr = + _lookup>( + 'dpm_password_get_quality'); + late final _dart_dpm_password_get_quality _dpm_password_get_quality = + _dpm_password_get_quality_ptr + .asFunction<_dart_dpm_password_get_quality>(); + + /// @partner + /// @brief Sets password minimum length. + /// @details Sets the minimum allowed password length. After setting this, + /// the user will not be able to enter a new password that is + /// shorter than the setting length. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[in] value Allowed minimum password length + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_set_minimum_length( + ffi.Pointer handle, + int value, + ) { + return _dpm_password_set_minimum_length( + handle, + value, + ); + } + + late final _dpm_password_set_minimum_length_ptr = + _lookup>( + 'dpm_password_set_minimum_length'); + late final _dart_dpm_password_set_minimum_length + _dpm_password_set_minimum_length = _dpm_password_set_minimum_length_ptr + .asFunction<_dart_dpm_password_set_minimum_length>(); + + /// @partner + /// @brief Gets password minimum length. + /// @details Gets the minimum allowed password length. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[out] value Allowed minimum password length + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_get_minimum_length( + ffi.Pointer handle, + ffi.Pointer value, + ) { + return _dpm_password_get_minimum_length( + handle, + value, + ); + } + + late final _dpm_password_get_minimum_length_ptr = + _lookup>( + 'dpm_password_get_minimum_length'); + late final _dart_dpm_password_get_minimum_length + _dpm_password_get_minimum_length = _dpm_password_get_minimum_length_ptr + .asFunction<_dart_dpm_password_get_minimum_length>(); + + /// @partner + /// @brief Sets minimum complex char in password. + /// @details Complex characters are all non-alphabetic characters; + /// that is, numbers and symbols. Admin can configure this + /// setting and make the password more secure. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[in] value Number of minimum complex char in password. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_set_min_complex_chars( + ffi.Pointer handle, + int value, + ) { + return _dpm_password_set_min_complex_chars( + handle, + value, + ); + } + + late final _dpm_password_set_min_complex_chars_ptr = + _lookup>( + 'dpm_password_set_min_complex_chars'); + late final _dart_dpm_password_set_min_complex_chars + _dpm_password_set_min_complex_chars = + _dpm_password_set_min_complex_chars_ptr + .asFunction<_dart_dpm_password_set_min_complex_chars>(); + + /// @partner + /// @brief Gets minimum complex char in password. + /// @details Complex characters are all non-alphabetic characters; + /// that is, numbers and symbols. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[out] value Number of minimum complex char in password. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_get_min_complex_chars( + ffi.Pointer handle, + ffi.Pointer value, + ) { + return _dpm_password_get_min_complex_chars( + handle, + value, + ); + } + + late final _dpm_password_get_min_complex_chars_ptr = + _lookup>( + 'dpm_password_get_min_complex_chars'); + late final _dart_dpm_password_get_min_complex_chars + _dpm_password_get_min_complex_chars = + _dpm_password_get_min_complex_chars_ptr + .asFunction<_dart_dpm_password_get_min_complex_chars>(); + + /// @partner + /// @brief Sets maximum number of failed attempts before device is wiped. + /// @details If user fails the last attempt, device will be wiped. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[in] value Maximum count for failed passwords. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_set_maximum_failed_attempts_for_wipe( + ffi.Pointer handle, + int value, + ) { + return _dpm_password_set_maximum_failed_attempts_for_wipe( + handle, + value, + ); + } + + late final _dpm_password_set_maximum_failed_attempts_for_wipe_ptr = _lookup< + ffi.NativeFunction< + _c_dpm_password_set_maximum_failed_attempts_for_wipe>>( + 'dpm_password_set_maximum_failed_attempts_for_wipe'); + late final _dart_dpm_password_set_maximum_failed_attempts_for_wipe + _dpm_password_set_maximum_failed_attempts_for_wipe = + _dpm_password_set_maximum_failed_attempts_for_wipe_ptr.asFunction< + _dart_dpm_password_set_maximum_failed_attempts_for_wipe>(); + + /// @partner + /// @brief Gets maximum number of failed attempts before device is wiped. + /// @details If user fails the last attempt, device will be wiped. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[out] value Maximum count for failed passwords. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_get_maximum_failed_attempts_for_wipe( + ffi.Pointer handle, + ffi.Pointer value, + ) { + return _dpm_password_get_maximum_failed_attempts_for_wipe( + handle, + value, + ); + } + + late final _dpm_password_get_maximum_failed_attempts_for_wipe_ptr = _lookup< + ffi.NativeFunction< + _c_dpm_password_get_maximum_failed_attempts_for_wipe>>( + 'dpm_password_get_maximum_failed_attempts_for_wipe'); + late final _dart_dpm_password_get_maximum_failed_attempts_for_wipe + _dpm_password_get_maximum_failed_attempts_for_wipe = + _dpm_password_get_maximum_failed_attempts_for_wipe_ptr.asFunction< + _dart_dpm_password_get_maximum_failed_attempts_for_wipe>(); + + /// @partner + /// @brief Sets the number of days password expires. + /// @details An administrator can configure the password age to force + /// the user to enter a new password after every expiration period. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[in] value Number of days after which the password expires. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_set_expires( + ffi.Pointer handle, + int value, + ) { + return _dpm_password_set_expires( + handle, + value, + ); + } + + late final _dpm_password_set_expires_ptr = + _lookup>( + 'dpm_password_set_expires'); + late final _dart_dpm_password_set_expires _dpm_password_set_expires = + _dpm_password_set_expires_ptr + .asFunction<_dart_dpm_password_set_expires>(); + + /// @partner + /// @brief Gets the number of days password expires. + /// @details An administrator can get the password age to force + /// the user to enter a new password after every expiration period. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[out] value Number of days after which the password expires. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_get_expires( + ffi.Pointer handle, + ffi.Pointer value, + ) { + return _dpm_password_get_expires( + handle, + value, + ); + } + + late final _dpm_password_get_expires_ptr = + _lookup>( + 'dpm_password_get_expires'); + late final _dart_dpm_password_get_expires _dpm_password_get_expires = + _dpm_password_get_expires_ptr + .asFunction<_dart_dpm_password_get_expires>(); + + /// @partner + /// @brief Sets the number of min password history to avoid previous password. + /// @details An administrator can configure the number of previous + /// passwords which cannot be used when entering a new password. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[in] value Number of previous passwords which cannot be used when + /// settings a new password. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_set_history( + ffi.Pointer handle, + int value, + ) { + return _dpm_password_set_history( + handle, + value, + ); + } + + late final _dpm_password_set_history_ptr = + _lookup>( + 'dpm_password_set_history'); + late final _dart_dpm_password_set_history _dpm_password_set_history = + _dpm_password_set_history_ptr + .asFunction<_dart_dpm_password_set_history>(); + + /// @partner + /// @brief Gets the number of min password history to avoid previous password. + /// @details An administrator can get the number of previous + /// passwords which cannot be used when entering a new password. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[out] value Number of previous passwords which cannot be used when + /// settings a new password. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_get_history( + ffi.Pointer handle, + ffi.Pointer value, + ) { + return _dpm_password_get_history( + handle, + value, + ); + } + + late final _dpm_password_get_history_ptr = + _lookup>( + 'dpm_password_get_history'); + late final _dart_dpm_password_get_history _dpm_password_get_history = + _dpm_password_get_history_ptr + .asFunction<_dart_dpm_password_get_history>(); + + /// @partner + /// @brief Sets the required password pattern. + /// @details An administrator can force User to enter password based on + /// a regular expression. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[in] pattern Password pattern. If regular expression is + /// [a-zA-Z]{4}[0-9]{4}, we can force user to enter a 8 character + /// password with first 4 alphabetic characters and next 4 + /// numeric characters. An administrator must take care when + /// setting this pattern. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_set_pattern( + ffi.Pointer handle, + ffi.Pointer pattern, + ) { + return _dpm_password_set_pattern( + handle, + pattern, + ); + } + + late final _dpm_password_set_pattern_ptr = + _lookup>( + 'dpm_password_set_pattern'); + late final _dart_dpm_password_set_pattern _dpm_password_set_pattern = + _dpm_password_set_pattern_ptr + .asFunction<_dart_dpm_password_set_pattern>(); + + /// @partner + /// @brief Resets password. + /// @details This takes effect immediately to the device password. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[in] password New password + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_reset( + ffi.Pointer handle, + ffi.Pointer password, + ) { + return _dpm_password_reset( + handle, + password, + ); + } + + late final _dpm_password_reset_ptr = + _lookup>('dpm_password_reset'); + late final _dart_dpm_password_reset _dpm_password_reset = + _dpm_password_reset_ptr.asFunction<_dart_dpm_password_reset>(); + + /// @partner + /// @brief Enforces password change. + /// @details An administrator can enforce password change. PasswordPolicy + /// change setting is launched. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_enforce_change( + ffi.Pointer handle, + ) { + return _dpm_password_enforce_change( + handle, + ); + } + + late final _dpm_password_enforce_change_ptr = + _lookup>( + 'dpm_password_enforce_change'); + late final _dart_dpm_password_enforce_change _dpm_password_enforce_change = + _dpm_password_enforce_change_ptr + .asFunction<_dart_dpm_password_enforce_change>(); + + /// @partner + /// @brief Sets the maximum number of seconds of inactivity time + /// before the screen timeout occurs. + /// @details An administrator sets the maximum number of seconds of inactivity + /// time before the screen timeout occurs and a device user must + /// type the password to unlock the device. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[in] value Maximum inactivity time for device lock. Specifies how soon + /// the device can be unlocked again after use, without reprompting for + /// the passcode. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_set_max_inactivity_time_device_lock( + ffi.Pointer handle, + int value, + ) { + return _dpm_password_set_max_inactivity_time_device_lock( + handle, + value, + ); + } + + late final _dpm_password_set_max_inactivity_time_device_lock_ptr = _lookup< + ffi.NativeFunction< + _c_dpm_password_set_max_inactivity_time_device_lock>>( + 'dpm_password_set_max_inactivity_time_device_lock'); + late final _dart_dpm_password_set_max_inactivity_time_device_lock + _dpm_password_set_max_inactivity_time_device_lock = + _dpm_password_set_max_inactivity_time_device_lock_ptr + .asFunction<_dart_dpm_password_set_max_inactivity_time_device_lock>(); + + /// @partner + /// @brief Gets the maximum number of seconds of inactivity time + /// before the screen timeout occurs. + /// @details Called by an application that is managing the device to get + /// the value of timeout period. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[out] value Pointer of Maximum inactivity time for device lock. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_get_max_inactivity_time_device_lock( + ffi.Pointer handle, + ffi.Pointer value, + ) { + return _dpm_password_get_max_inactivity_time_device_lock( + handle, + value, + ); + } + + late final _dpm_password_get_max_inactivity_time_device_lock_ptr = _lookup< + ffi.NativeFunction< + _c_dpm_password_get_max_inactivity_time_device_lock>>( + 'dpm_password_get_max_inactivity_time_device_lock'); + late final _dart_dpm_password_get_max_inactivity_time_device_lock + _dpm_password_get_max_inactivity_time_device_lock = + _dpm_password_get_max_inactivity_time_device_lock_ptr + .asFunction<_dart_dpm_password_get_max_inactivity_time_device_lock>(); + + /// @partner + /// @brief Sets password status + /// @details An administrator can know password status for this API. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[in] status Password status + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_set_status( + ffi.Pointer handle, + int status, + ) { + return _dpm_password_set_status( + handle, + status, + ); + } + + late final _dpm_password_set_status_ptr = + _lookup>( + 'dpm_password_set_status'); + late final _dart_dpm_password_set_status _dpm_password_set_status = + _dpm_password_set_status_ptr.asFunction<_dart_dpm_password_set_status>(); + + /// @partner + /// @brief Gets password status + /// @details An administrator can know password status for this API. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] status Password status + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_get_status( + ffi.Pointer handle, + ffi.Pointer status, + ) { + return _dpm_password_get_status( + handle, + status, + ); + } + + late final _dpm_password_get_status_ptr = + _lookup>( + 'dpm_password_get_status'); + late final _dart_dpm_password_get_status _dpm_password_get_status = + _dpm_password_get_status_ptr.asFunction<_dart_dpm_password_get_status>(); + + /// @partner + /// @brief Removes all password patterns. + /// @details An administrator can remove all password patterns. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_delete_pattern( + ffi.Pointer handle, + ) { + return _dpm_password_delete_pattern( + handle, + ); + } + + late final _dpm_password_delete_pattern_ptr = + _lookup>( + 'dpm_password_delete_pattern'); + late final _dart_dpm_password_delete_pattern _dpm_password_delete_pattern = + _dpm_password_delete_pattern_ptr + .asFunction<_dart_dpm_password_delete_pattern>(); + + /// @partner + /// @brief Gets password pattern. + /// @details This API can be used for applying complexity on new password value. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @remarks The @a pattern should be freed using free(). + /// @param[in] handle Device policy manager handle + /// @param[out] pattern Password pattern + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_get_pattern( + ffi.Pointer handle, + ffi.Pointer> pattern, + ) { + return _dpm_password_get_pattern( + handle, + pattern, + ); + } + + late final _dpm_password_get_pattern_ptr = + _lookup>( + 'dpm_password_get_pattern'); + late final _dart_dpm_password_get_pattern _dpm_password_get_pattern = + _dpm_password_get_pattern_ptr + .asFunction<_dart_dpm_password_get_pattern>(); + + /// @partner + /// @brief Sets the maximum number of times a character can occur in + /// the device password. + /// @details Called by an admin that is managing the device to specify that + /// any character in the device password cannot occur more than + /// the specified maximum number of times. Characters can be numeric + /// or alphabetic or symbolic. "aaabcde" has 'a' which occurs 3 times, + /// "1b1c1de" has '1' which occurs 3 times and "a@b@c@" has '@' which + /// occurs 3 times. A value of '0' specifies that no restrictions are + /// applied. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[in] value Maximum character occurrences + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_set_maximum_character_occurrences( + ffi.Pointer handle, + int value, + ) { + return _dpm_password_set_maximum_character_occurrences( + handle, + value, + ); + } + + late final _dpm_password_set_maximum_character_occurrences_ptr = _lookup< + ffi.NativeFunction< + _c_dpm_password_set_maximum_character_occurrences>>( + 'dpm_password_set_maximum_character_occurrences'); + late final _dart_dpm_password_set_maximum_character_occurrences + _dpm_password_set_maximum_character_occurrences = + _dpm_password_set_maximum_character_occurrences_ptr + .asFunction<_dart_dpm_password_set_maximum_character_occurrences>(); + + /// @partner + /// @brief Gets the maximum number of times a character can occur in + /// the device password. + /// @details An administrator can retrieve the maximum number of times + /// a character can occur in the device password. If more than + /// one admin has set this value then the least value will take + /// preference. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[out] value Pointer of Maximum Character Occurrences + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_get_maximum_character_occurrences( + ffi.Pointer handle, + ffi.Pointer value, + ) { + return _dpm_password_get_maximum_character_occurrences( + handle, + value, + ); + } + + late final _dpm_password_get_maximum_character_occurrences_ptr = _lookup< + ffi.NativeFunction< + _c_dpm_password_get_maximum_character_occurrences>>( + 'dpm_password_get_maximum_character_occurrences'); + late final _dart_dpm_password_get_maximum_character_occurrences + _dpm_password_get_maximum_character_occurrences = + _dpm_password_get_maximum_character_occurrences_ptr + .asFunction<_dart_dpm_password_get_maximum_character_occurrences>(); + + /// @partner + /// @brief Sets the maximum length of the numeric sequence + /// which is allowed in the device password. + /// @details Called by an administrator that is managing the device to set + /// the maximum numeric sequence length. This specifies that + /// the device password must not contain numeric sequences greater + /// than the given length. + /// Numeric sequences can be increasing successively by one like + /// "12345", or decreasing successively by one like "98765", or + /// repeating like "55555". + /// These are all numeric sequences of length '5'. + /// If maximum value is set to '5' then "123456" or "987654" or + /// "555555" are not allowed. + /// A value of '0' specifies that no such numeric sequence + /// restrictions are applied. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[in] value Maximum numeric sequence length + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_set_maximum_numeric_sequence_length( + ffi.Pointer handle, + int value, + ) { + return _dpm_password_set_maximum_numeric_sequence_length( + handle, + value, + ); + } + + late final _dpm_password_set_maximum_numeric_sequence_length_ptr = _lookup< + ffi.NativeFunction< + _c_dpm_password_set_maximum_numeric_sequence_length>>( + 'dpm_password_set_maximum_numeric_sequence_length'); + late final _dart_dpm_password_set_maximum_numeric_sequence_length + _dpm_password_set_maximum_numeric_sequence_length = + _dpm_password_set_maximum_numeric_sequence_length_ptr + .asFunction<_dart_dpm_password_set_maximum_numeric_sequence_length>(); + + /// @partner + /// @brief Gets the maximum numeric sequence length allowed in + /// the device password. + /// @details An administrator can retrieve the length of numeric sequences + /// which are allowed in the device password. + /// For instance, if the return value is '3' then "123", "987", + /// "555" would all be numeric sequences of length '3' and will be + /// allowed in the device password. + /// If more than one admin has set this value then the least value + /// will take preference. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[out] value Pointer of maximum numeric sequence length + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_get_maximum_numeric_sequence_length( + ffi.Pointer handle, + ffi.Pointer value, + ) { + return _dpm_password_get_maximum_numeric_sequence_length( + handle, + value, + ); + } + + late final _dpm_password_get_maximum_numeric_sequence_length_ptr = _lookup< + ffi.NativeFunction< + _c_dpm_password_get_maximum_numeric_sequence_length>>( + 'dpm_password_get_maximum_numeric_sequence_length'); + late final _dart_dpm_password_get_maximum_numeric_sequence_length + _dpm_password_get_maximum_numeric_sequence_length = + _dpm_password_get_maximum_numeric_sequence_length_ptr + .asFunction<_dart_dpm_password_get_maximum_numeric_sequence_length>(); + + /// @partner + /// @brief Creates a password forbidden string list iterator. + /// @details The password forbidden string list iterator can be used to get all forbidden strings. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @return A password forbidden string list iterator on success, otherwise + /// null value + /// @remarks The specific error code can be obtained by using the + /// get_last_result() method. Error codes are described in + /// exception section. + /// The returned iterator should be released using dpm_password_destroy_iterator(). + /// @exception #DPM_ERROR_NONE No error + /// @exception #DPM_ERROR_OUT_OF_MEMORY Out of memory + /// @exception #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @exception #DPM_ERROR_TIMED_OUT Time out + /// @exception #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_password_iterator_next() + /// @see dpm_password_destroy_iterator() + /// @see get_last_result() + ffi.Pointer dpm_password_create_iterator( + ffi.Pointer handle, + ) { + return _dpm_password_create_iterator( + handle, + ); + } + + late final _dpm_password_create_iterator_ptr = + _lookup>( + 'dpm_password_create_iterator'); + late final _dart_dpm_password_create_iterator _dpm_password_create_iterator = + _dpm_password_create_iterator_ptr + .asFunction<_dart_dpm_password_create_iterator>(); + + /// @partner + /// @brief Fetches a password forbidden string and forwards the iterator. + /// @details This API returns a password forbidden string indicated by the iterator, and then + /// the iterator is moved to the next position. If the iterator reaches + /// the end of the list, null value will be returned. + /// @since_tizen 3.0 + /// @param[in] iter The iterator to be controlled + /// @param[out] forbidden_string The forbidden string got from the iterator + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @remarks The @a forbidden_string should not be freed using free(). + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @pre The iter must be created by dpm_password_create_iterator(). + /// @see dpm_passsword_create_iterator() + /// @see dpm_password_destroy_iterator() + int dpm_password_iterator_next( + ffi.Pointer iter, + ffi.Pointer> forbidden_string, + ) { + return _dpm_password_iterator_next( + iter, + forbidden_string, + ); + } + + late final _dpm_password_iterator_next_ptr = + _lookup>( + 'dpm_password_iterator_next'); + late final _dart_dpm_password_iterator_next _dpm_password_iterator_next = + _dpm_password_iterator_next_ptr + .asFunction<_dart_dpm_password_iterator_next>(); + + /// @partner + /// @brief Frees the password forbidden string iterator. + /// @details This API frees the password forbidden string iterator. This API must be called + /// if the iterator no longer used. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] iter The iterator to be removed + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The iter must be created by dpm_password_create_iterator() + /// @see dpm_password_create_iterator() + /// @see dpm_password_iterator_next() + int dpm_password_destroy_iterator( + ffi.Pointer iter, + ) { + return _dpm_password_destroy_iterator( + iter, + ); + } + + late final _dpm_password_destroy_iterator_ptr = + _lookup>( + 'dpm_password_destroy_iterator'); + late final _dart_dpm_password_destroy_iterator + _dpm_password_destroy_iterator = _dpm_password_destroy_iterator_ptr + .asFunction<_dart_dpm_password_destroy_iterator>(); + + /// @partner + /// @brief Sets strings which are forbidden in the device password. + /// @details Called by an admin that is managing the device to set strings that are forbidden to be used in the device password. + /// This specifies any strings which must not be present in the device password such as personal data (variations on the user's name, email address or X400 address), or any other strings. + /// If the parameter list has only one blank string(""), then the stored strings are cleared. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.password + /// @param[in] handle Device policy manager handle + /// @param[in] strings The forbidden strings + /// @param[in] length The length of the strings + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_password_set_forbidden_strings( + ffi.Pointer handle, + ffi.Pointer> strings, + int length, + ) { + return _dpm_password_set_forbidden_strings( + handle, + strings, + length, + ); + } + + late final _dpm_password_set_forbidden_strings_ptr = + _lookup>( + 'dpm_password_set_forbidden_strings'); + late final _dart_dpm_password_set_forbidden_strings + _dpm_password_set_forbidden_strings = + _dpm_password_set_forbidden_strings_ptr + .asFunction<_dart_dpm_password_set_forbidden_strings>(); + + /// @partner + /// @brief Allows or disallows the use of camera. + /// @details An administrator can use this API to set whether the use of camera + /// is allowed or not. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.camera + /// @param[in] handle Device policy manager handle + /// @param[in] allow If true, allow the use of camera, if false, disallow the use of camera + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_get_camera_state() + int dpm_restriction_set_camera_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_camera_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_camera_state_ptr = + _lookup>( + 'dpm_restriction_set_camera_state'); + late final _dart_dpm_restriction_set_camera_state + _dpm_restriction_set_camera_state = _dpm_restriction_set_camera_state_ptr + .asFunction<_dart_dpm_restriction_set_camera_state>(); + + /// @brief Check whether the use of camera is allowed or not. + /// @details An administrator can use this API to check whether the use of camera + /// is allowed or not. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the use of camera is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_set_camera_state() + int dpm_restriction_get_camera_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_camera_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_camera_state_ptr = + _lookup>( + 'dpm_restriction_get_camera_state'); + late final _dart_dpm_restriction_get_camera_state + _dpm_restriction_get_camera_state = _dpm_restriction_get_camera_state_ptr + .asFunction<_dart_dpm_restriction_get_camera_state>(); + + /// @partner + /// @brief Allows or disallows the use of microphone. + /// @details An administrator can use this API to set whether the use of microphone + /// is allowed or not. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.microphone + /// @param[in] handle Device policy manager handle + /// @param[in] allow If true, allow the use of microphone, + /// if false, disallow the use of microphone + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_get_microphone_state() + int dpm_restriction_set_microphone_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_microphone_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_microphone_state_ptr = + _lookup>( + 'dpm_restriction_set_microphone_state'); + late final _dart_dpm_restriction_set_microphone_state + _dpm_restriction_set_microphone_state = + _dpm_restriction_set_microphone_state_ptr + .asFunction<_dart_dpm_restriction_set_microphone_state>(); + + /// @brief Checks whether the use of microphone is allowed or not. + /// @details An administrator can use this API to check whether the use of microphone + /// is allowed of not. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the use of microphone is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_set_microphone_state() + int dpm_restriction_get_microphone_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_microphone_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_microphone_state_ptr = + _lookup>( + 'dpm_restriction_get_microphone_state'); + late final _dart_dpm_restriction_get_microphone_state + _dpm_restriction_get_microphone_state = + _dpm_restriction_get_microphone_state_ptr + .asFunction<_dart_dpm_restriction_get_microphone_state>(); + + /// @partner + /// @brief Allows or disallows user to change the location state. + /// @details An administrator can use this API to allow or disallow user to change + /// the location state. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.location + /// @param[in] handle Device policy manager handle + /// @param[in] allow If true, allow user to change the location state, if false, disallow + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_get_location_state() + int dpm_restriction_set_location_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_location_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_location_state_ptr = + _lookup>( + 'dpm_restriction_set_location_state'); + late final _dart_dpm_restriction_set_location_state + _dpm_restriction_set_location_state = + _dpm_restriction_set_location_state_ptr + .asFunction<_dart_dpm_restriction_set_location_state>(); + + /// @brief Check whether user is allowed to change location state or not. + /// @details An administrator can use this API to check whether user is allowed to change + /// the location state or not. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the location state change is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_set_location_state() + int dpm_restriction_get_location_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_location_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_location_state_ptr = + _lookup>( + 'dpm_restriction_get_location_state'); + late final _dart_dpm_restriction_get_location_state + _dpm_restriction_get_location_state = + _dpm_restriction_get_location_state_ptr + .asFunction<_dart_dpm_restriction_get_location_state>(); + + /// @partner + /// @brief Allows or disallows user to use usb mass storage. + /// @details An administrator can use this API to set whether the usb mass + /// storage is allowed or not. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.storage + /// @param[in] handle Device policy manager handle + /// @param[in] allow If true, allow user to use the external storages, if false, disallow + /// the external storage + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_storage_get_external_storage_state() + int dpm_restriction_set_external_storage_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_external_storage_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_external_storage_state_ptr = _lookup< + ffi.NativeFunction<_c_dpm_restriction_set_external_storage_state>>( + 'dpm_restriction_set_external_storage_state'); + late final _dart_dpm_restriction_set_external_storage_state + _dpm_restriction_set_external_storage_state = + _dpm_restriction_set_external_storage_state_ptr + .asFunction<_dart_dpm_restriction_set_external_storage_state>(); + + /// @brief Checks whether the use of external storage is allowed or not. + /// @details An administrator can use this API to check whether the use of external storage is + /// allowed or not. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the use of external storage is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_storage_set_external_storage_state() + int dpm_restriction_get_external_storage_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_external_storage_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_external_storage_state_ptr = _lookup< + ffi.NativeFunction<_c_dpm_restriction_get_external_storage_state>>( + 'dpm_restriction_get_external_storage_state'); + late final _dart_dpm_restriction_get_external_storage_state + _dpm_restriction_get_external_storage_state = + _dpm_restriction_get_external_storage_state_ptr + .asFunction<_dart_dpm_restriction_get_external_storage_state>(); + + /// @partner + /// @brief Allows or disallows user to access the clipboard. + /// @details An administrator can use this API to set whether the clipboard access. + /// is allowed or not + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.clipboard + /// @param[in] handle Device policy manager handle + /// @param[in] allow If true, allow the clipboard access, if false, disallow the clipboard access. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_get_clipboard_state() + int dpm_restriction_set_clipboard_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_clipboard_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_clipboard_state_ptr = + _lookup>( + 'dpm_restriction_set_clipboard_state'); + late final _dart_dpm_restriction_set_clipboard_state + _dpm_restriction_set_clipboard_state = + _dpm_restriction_set_clipboard_state_ptr + .asFunction<_dart_dpm_restriction_set_clipboard_state>(); + + /// @brief Checks whether the clipboard access is allowed or not. + /// @details An administrator can use this API to check whether the clipboard access + /// is allowed or not. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the access is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_set_clipboard_state() + int dpm_restriction_get_clipboard_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_clipboard_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_clipboard_state_ptr = + _lookup>( + 'dpm_restriction_get_clipboard_state'); + late final _dart_dpm_restriction_get_clipboard_state + _dpm_restriction_get_clipboard_state = + _dpm_restriction_get_clipboard_state_ptr + .asFunction<_dart_dpm_restriction_get_clipboard_state>(); + + /// @partner + /// @brief Allows or disallows the usb debugging. + /// @details An administrator can use this API to set whether the usb debugging + /// is allowed or not. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.debugging + /// @param[in] handle Device policy manager handle + /// @param[in] allow If true, allow the usb debugging, if false, disallow the usb + /// debugging + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_get_usb_debugging_state() + int dpm_restriction_set_usb_debugging_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_usb_debugging_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_usb_debugging_state_ptr = + _lookup>( + 'dpm_restriction_set_usb_debugging_state'); + late final _dart_dpm_restriction_set_usb_debugging_state + _dpm_restriction_set_usb_debugging_state = + _dpm_restriction_set_usb_debugging_state_ptr + .asFunction<_dart_dpm_restriction_set_usb_debugging_state>(); + + /// @brief Checks whether the usb debugging is allowed or not. + /// @details An administrator can use this API to check whether the usb debugging + /// is allowed or not. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the usb debugging is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_set_usb_debugging_state() + int dpm_restriction_get_usb_debugging_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_usb_debugging_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_usb_debugging_state_ptr = + _lookup>( + 'dpm_restriction_get_usb_debugging_state'); + late final _dart_dpm_restriction_get_usb_debugging_state + _dpm_restriction_get_usb_debugging_state = + _dpm_restriction_get_usb_debugging_state_ptr + .asFunction<_dart_dpm_restriction_get_usb_debugging_state>(); + + /// @partner + /// @brief Allows or disallows user to change the Wi-Fi state. + /// @details An administrator can use this API to allow or disallow user to + /// change the Wi-Fi state. If it is disallowed, user does not have UI + /// access to change the state. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.wifi + /// @param[in] handle Device policy manager handle + /// @param[in] allow If true, allow user to change Wi-Fi state, + /// if false, disallow user to change Wi-Fi state. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_get_wifi_state() + int dpm_restriction_set_wifi_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_wifi_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_wifi_state_ptr = + _lookup>( + 'dpm_restriction_set_wifi_state'); + late final _dart_dpm_restriction_set_wifi_state + _dpm_restriction_set_wifi_state = _dpm_restriction_set_wifi_state_ptr + .asFunction<_dart_dpm_restriction_set_wifi_state>(); + + /// @brief Checks whether the Wi-Fi state change is allowed or not. + /// @details An administrator can use this API to check whether user is + /// allowed to change Wi-Fi state or not. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the change is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_set_wifi_state() + int dpm_restriction_get_wifi_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_wifi_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_wifi_state_ptr = + _lookup>( + 'dpm_restriction_get_wifi_state'); + late final _dart_dpm_restriction_get_wifi_state + _dpm_restriction_get_wifi_state = _dpm_restriction_get_wifi_state_ptr + .asFunction<_dart_dpm_restriction_get_wifi_state>(); + + /// @partner + /// @brief Allows or disallows user to change Wi-Fi hotspot state change. + /// @details An administrator can use this API to allow or disallow user to change Wi-Fi + /// hotspot state. When it is disallowed, the UI is grayed out so user cannot + /// change Wi-Fi hotspot state. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.wifi + /// @param[in] handle Device policy manager handle + /// @param[in] allow If true, allow user to change Wi-Fi hotspot state, + /// if false, disallow user to change Wi-Fi hotspot state. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_get_wifi_hotspot_state() + int dpm_restriction_set_wifi_hotspot_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_wifi_hotspot_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_wifi_hotspot_state_ptr = + _lookup>( + 'dpm_restriction_set_wifi_hotspot_state'); + late final _dart_dpm_restriction_set_wifi_hotspot_state + _dpm_restriction_set_wifi_hotspot_state = + _dpm_restriction_set_wifi_hotspot_state_ptr + .asFunction<_dart_dpm_restriction_set_wifi_hotspot_state>(); + + /// @brief Checks whether the the Wi-Fi hotspot state change is allowed or not. + /// @details An administrator can use this API to check whether user is allowed to change + /// Wi-Fi hotspot state or not. + /// If the Wi-Fi hotspot state change is disallowed, the UI is grayed out so user can not + /// change its state. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the state change is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_set_wifi_hotspot_state() + int dpm_restriction_get_wifi_hotspot_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_wifi_hotspot_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_wifi_hotspot_state_ptr = + _lookup>( + 'dpm_restriction_get_wifi_hotspot_state'); + late final _dart_dpm_restriction_get_wifi_hotspot_state + _dpm_restriction_get_wifi_hotspot_state = + _dpm_restriction_get_wifi_hotspot_state_ptr + .asFunction<_dart_dpm_restriction_get_wifi_hotspot_state>(); + + /// @partner + /// @brief Allows or disallows user to change the bluetooth tethering state. + /// @details An administrator can use this API to allow of disallow user + /// to change the bluetooth tethering state. + /// When disallowed, the UI is grayed out so user cannot change the state. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.bluetooth + /// @param[in] handle Device policy manager handle + /// @param[in] allow If true, allow user to change the bluetooth tethering state, + /// if false, disallow user to change the bluetooth tethering state. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_get_bluetooth_tethering_state() + int dpm_restriction_set_bluetooth_tethering_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_bluetooth_tethering_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_bluetooth_tethering_state_ptr = _lookup< + ffi.NativeFunction<_c_dpm_restriction_set_bluetooth_tethering_state>>( + 'dpm_restriction_set_bluetooth_tethering_state'); + late final _dart_dpm_restriction_set_bluetooth_tethering_state + _dpm_restriction_set_bluetooth_tethering_state = + _dpm_restriction_set_bluetooth_tethering_state_ptr + .asFunction<_dart_dpm_restriction_set_bluetooth_tethering_state>(); + + /// @brief Checks whether the bluetooth tethering state change is allowed. + /// @details An administrator can use this API to check whether user is allowed + /// to change bluetooth tethering state. + /// is allowed or not. + /// If the bluetooth tethering state change is disallowed, the UI is grayed out + /// so user can not change its state. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the change is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_set_bluetooth_tethering_state() + int dpm_restriction_get_bluetooth_tethering_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_bluetooth_tethering_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_bluetooth_tethering_state_ptr = _lookup< + ffi.NativeFunction<_c_dpm_restriction_get_bluetooth_tethering_state>>( + 'dpm_restriction_get_bluetooth_tethering_state'); + late final _dart_dpm_restriction_get_bluetooth_tethering_state + _dpm_restriction_get_bluetooth_tethering_state = + _dpm_restriction_get_bluetooth_tethering_state_ptr + .asFunction<_dart_dpm_restriction_get_bluetooth_tethering_state>(); + + /// @partner + /// @brief Allows or disallows user to change USB tethering settings. + /// @details An administrator can use this API to allow or disallow user + /// to change USB tethering settings. + /// When disallowed, the UI is grayed out so user cannot change the state. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.usb + /// @param[in] handle Device policy manager handle + /// @param[in] allow If true, allow USB tethering state change, + /// if false, disallow USB tethering state change. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_get_usb_tethering_state() + int dpm_restriction_set_usb_tethering_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_usb_tethering_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_usb_tethering_state_ptr = + _lookup>( + 'dpm_restriction_set_usb_tethering_state'); + late final _dart_dpm_restriction_set_usb_tethering_state + _dpm_restriction_set_usb_tethering_state = + _dpm_restriction_set_usb_tethering_state_ptr + .asFunction<_dart_dpm_restriction_set_usb_tethering_state>(); + + /// @brief Checks whether the USB tethering state change is allowed. + /// @details An administrator can use this API to check whether the USB tethering state change + /// is allowed or not. + /// If the USB tethering state change is disallowed, the UI is grayed out + /// so user can not change its state. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the change is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_set_usb_tethering_state() + int dpm_restriction_get_usb_tethering_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_usb_tethering_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_usb_tethering_state_ptr = + _lookup>( + 'dpm_restriction_get_usb_tethering_state'); + late final _dart_dpm_restriction_get_usb_tethering_state + _dpm_restriction_get_usb_tethering_state = + _dpm_restriction_get_usb_tethering_state_ptr + .asFunction<_dart_dpm_restriction_get_usb_tethering_state>(); + + /// @partner + /// @brief Allows or disallows user to change the bluetooth state. + /// @details An administrator can use this API to allow or disallow user + /// to change the bluetooth state. + /// When disallowed, the UI is grayed out so user cannot change the state. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.bluetooth + /// @param[in] handle Device policy manager handle + /// @param[in] allow If true, allow user to change bluetooth state, + /// if false, disallow user to change bluetooth state. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_get_bluetooth_mode_change_state() + int dpm_restriction_set_bluetooth_mode_change_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_bluetooth_mode_change_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_bluetooth_mode_change_state_ptr = _lookup< + ffi.NativeFunction< + _c_dpm_restriction_set_bluetooth_mode_change_state>>( + 'dpm_restriction_set_bluetooth_mode_change_state'); + late final _dart_dpm_restriction_set_bluetooth_mode_change_state + _dpm_restriction_set_bluetooth_mode_change_state = + _dpm_restriction_set_bluetooth_mode_change_state_ptr + .asFunction<_dart_dpm_restriction_set_bluetooth_mode_change_state>(); + + /// @brief Checks whether the the bluetooth state change is allowed of not. + /// @details An administrator can use this API to check whether the bluetooth state change + /// is allowed or not. + /// If the bluetooth state change is disallowed, the UI is grayed out + /// so user can not change its state. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the change is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_set_bluetooth_mode_change_state() + int dpm_restriction_get_bluetooth_mode_change_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_bluetooth_mode_change_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_bluetooth_mode_change_state_ptr = _lookup< + ffi.NativeFunction< + _c_dpm_restriction_get_bluetooth_mode_change_state>>( + 'dpm_restriction_get_bluetooth_mode_change_state'); + late final _dart_dpm_restriction_get_bluetooth_mode_change_state + _dpm_restriction_get_bluetooth_mode_change_state = + _dpm_restriction_get_bluetooth_mode_change_state_ptr + .asFunction<_dart_dpm_restriction_get_bluetooth_mode_change_state>(); + + /// @partner + /// @brief Allows or disallows the bluetooth desktop connectivity. + /// @details An administrator can use this API to allow or disallow the bluetooth + /// desktop connectivity. + /// If the bluetooth desktop connectivity is disallowed, the UI is grayed out + /// so user can not + /// change its state. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.bluetooth + /// @param[in] handle Device policy manager handle + /// @param[out] allow If true, allow the bluetooth desktop connectivity, + /// if false, disallow the bluetooth desktop connectivity + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_get_bluetooth_desktop_connectivity_state() + int dpm_restriction_set_bluetooth_desktop_connectivity_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_bluetooth_desktop_connectivity_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_bluetooth_desktop_connectivity_state_ptr = + _lookup< + ffi.NativeFunction< + _c_dpm_restriction_set_bluetooth_desktop_connectivity_state>>( + 'dpm_restriction_set_bluetooth_desktop_connectivity_state'); + late final _dart_dpm_restriction_set_bluetooth_desktop_connectivity_state + _dpm_restriction_set_bluetooth_desktop_connectivity_state = + _dpm_restriction_set_bluetooth_desktop_connectivity_state_ptr.asFunction< + _dart_dpm_restriction_set_bluetooth_desktop_connectivity_state>(); + + /// @brief Checks whether the the Bluetooth desktop connectivity is allowed or not. + /// @details An administrator can use this API to check whether the Bluetooth desktop + /// connectivity is allowed or not. + /// If the Bluetooth desktop connectivity is disallowed, the UI is grayed out + /// so user can not change its state. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the connectivity is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_set_bluetooth_desktop_connectivity_state() + int dpm_restriction_get_bluetooth_desktop_connectivity_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_bluetooth_desktop_connectivity_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_bluetooth_desktop_connectivity_state_ptr = + _lookup< + ffi.NativeFunction< + _c_dpm_restriction_get_bluetooth_desktop_connectivity_state>>( + 'dpm_restriction_get_bluetooth_desktop_connectivity_state'); + late final _dart_dpm_restriction_get_bluetooth_desktop_connectivity_state + _dpm_restriction_get_bluetooth_desktop_connectivity_state = + _dpm_restriction_get_bluetooth_desktop_connectivity_state_ptr.asFunction< + _dart_dpm_restriction_get_bluetooth_desktop_connectivity_state>(); + + /// @partner + /// @brief Allows or disallows user to change the bluetooth pairing. + /// @details An administrator can use this API to allow or disallow the bluetooth pairing. + /// If the bluetooth pairing is disallowed, the UI is grayed out + /// so user can not change its state. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.bluetooth + /// @param[in] handle Device policy manager handle + /// @param[out] allow If true, allow the bluetooth pairing, if false, disallow the bluetooth pairing. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_get_bluetooth_pairing_state() + int dpm_restriction_set_bluetooth_pairing_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_bluetooth_pairing_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_bluetooth_pairing_state_ptr = _lookup< + ffi.NativeFunction<_c_dpm_restriction_set_bluetooth_pairing_state>>( + 'dpm_restriction_set_bluetooth_pairing_state'); + late final _dart_dpm_restriction_set_bluetooth_pairing_state + _dpm_restriction_set_bluetooth_pairing_state = + _dpm_restriction_set_bluetooth_pairing_state_ptr + .asFunction<_dart_dpm_restriction_set_bluetooth_pairing_state>(); + + /// @brief Checks whether the the bluetooth pairing is allowed or not. + /// @details An administrator can use this API to check whether the bluetooth + /// pairing is allowed or not. + /// If the bluetooth pairing is disallowed, the UI is grayed out + /// so user can not change its state. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the pairing is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_restriction_set_bluetooth_pairing_state() + int dpm_restriction_get_bluetooth_pairing_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_bluetooth_pairing_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_bluetooth_pairing_state_ptr = _lookup< + ffi.NativeFunction<_c_dpm_restriction_get_bluetooth_pairing_state>>( + 'dpm_restriction_get_bluetooth_pairing_state'); + late final _dart_dpm_restriction_get_bluetooth_pairing_state + _dpm_restriction_get_bluetooth_pairing_state = + _dpm_restriction_get_bluetooth_pairing_state_ptr + .asFunction<_dart_dpm_restriction_get_bluetooth_pairing_state>(); + + /// @partner + /// @brief Allows or disallows user to use of SMS or text messaging. + /// @details An administrator can disable the text messaging capability + /// without any user interaction + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.message + /// @param[in] handle Device policy manager handle + /// @param[in] sim_id SIM identifier + /// @param[in] allow If true, allow the use of SMS or text messaging, + /// if false, disallow the use of SMS or text messaging. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_restriction_get_messaging_state() + int dpm_restriction_set_messaging_state( + ffi.Pointer handle, + ffi.Pointer sim_id, + int allow, + ) { + return _dpm_restriction_set_messaging_state( + handle, + sim_id, + allow, + ); + } + + late final _dpm_restriction_set_messaging_state_ptr = + _lookup>( + 'dpm_restriction_set_messaging_state'); + late final _dart_dpm_restriction_set_messaging_state + _dpm_restriction_set_messaging_state = + _dpm_restriction_set_messaging_state_ptr + .asFunction<_dart_dpm_restriction_set_messaging_state>(); + + /// @brief Checks whether the text messaging is allowed or not. + /// @details An administrator can use this API to check whether text messaging capability + /// is enabled or not. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[in] sim_id SIM identifier + /// @param[out] is_allowed true if the messaging is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_restriction_set_messaging_state() + int dpm_restriction_get_messaging_state( + ffi.Pointer handle, + ffi.Pointer sim_id, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_messaging_state( + handle, + sim_id, + is_allowed, + ); + } + + late final _dpm_restriction_get_messaging_state_ptr = + _lookup>( + 'dpm_restriction_get_messaging_state'); + late final _dart_dpm_restriction_get_messaging_state + _dpm_restriction_get_messaging_state = + _dpm_restriction_get_messaging_state_ptr + .asFunction<_dart_dpm_restriction_get_messaging_state>(); + + /// @partner + /// @brief Allows or disallows the access to POP or IMAP email. + /// @details An administrator can disable the email capability without any user interaction + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.email + /// @param[in] handle Device policy manager handle + /// @param[in] allow If true, allow POP or IMAP email, if false, disallow POP or IMAP email. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_restriction_get_popimap_email_state() + int dpm_restriction_set_popimap_email_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_popimap_email_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_popimap_email_state_ptr = + _lookup>( + 'dpm_restriction_set_popimap_email_state'); + late final _dart_dpm_restriction_set_popimap_email_state + _dpm_restriction_set_popimap_email_state = + _dpm_restriction_set_popimap_email_state_ptr + .asFunction<_dart_dpm_restriction_set_popimap_email_state>(); + + /// @brief Checks whether the access to POP or IMAP email is allowed or not. + /// @details An administrator can use this API to check the access to POP or IMAP email + /// is allowed or not. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the POP or IMAP email is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_restriction_set_popimap_email_state() + int dpm_restriction_get_popimap_email_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_popimap_email_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_popimap_email_state_ptr = + _lookup>( + 'dpm_restriction_get_popimap_email_state'); + late final _dart_dpm_restriction_get_popimap_email_state + _dpm_restriction_get_popimap_email_state = + _dpm_restriction_get_popimap_email_state_ptr + .asFunction<_dart_dpm_restriction_get_popimap_email_state>(); + + /// @partner + /// @brief Allows or disallows the use of web browser. + /// @details An administrator can allows or disallow the use of web browser without + /// any user interaction + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.browser + /// @param[in] handle Device policy manager handle + /// @param[in] allow If true, allow the use of web browser, + /// if false, disallow the use of web browser. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_restriction_get_browser_state() + int dpm_restriction_set_browser_state( + ffi.Pointer handle, + int allow, + ) { + return _dpm_restriction_set_browser_state( + handle, + allow, + ); + } + + late final _dpm_restriction_set_browser_state_ptr = + _lookup>( + 'dpm_restriction_set_browser_state'); + late final _dart_dpm_restriction_set_browser_state + _dpm_restriction_set_browser_state = + _dpm_restriction_set_browser_state_ptr + .asFunction<_dart_dpm_restriction_set_browser_state>(); + + /// @brief Checks whether the use of web browser is allowed or not. + /// @details An administrator can use this API to check whether the use of web browser + /// is allowed or not. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_allowed true if the use of web browser is allowed, false otherwise. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_restriction_set_browser_state() + int dpm_restriction_get_browser_state( + ffi.Pointer handle, + ffi.Pointer is_allowed, + ) { + return _dpm_restriction_get_browser_state( + handle, + is_allowed, + ); + } + + late final _dpm_restriction_get_browser_state_ptr = + _lookup>( + 'dpm_restriction_get_browser_state'); + late final _dart_dpm_restriction_get_browser_state + _dpm_restriction_get_browser_state = + _dpm_restriction_get_browser_state_ptr + .asFunction<_dart_dpm_restriction_get_browser_state>(); + + /// @partner + /// @brief Locks device screen immediately. + /// @details An administrator can use this API to lock the device screen + /// immediately + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.lock + /// @param[in] handle Device policy manager handle + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_security_lockout_screen( + ffi.Pointer handle, + ) { + return _dpm_security_lockout_screen( + handle, + ); + } + + late final _dpm_security_lockout_screen_ptr = + _lookup>( + 'dpm_security_lockout_screen'); + late final _dart_dpm_security_lockout_screen _dpm_security_lockout_screen = + _dpm_security_lockout_screen_ptr + .asFunction<_dart_dpm_security_lockout_screen>(); + + /// @partner + /// @brief Encrypts or decrypts internal storage. + /// @details An administrator can use this API to enable full device + /// encryption, which includes device memory and internal SD card. + /// Before calling this API, administrator must ensure that + /// the device password is set to alphanumeric quality. + /// The administrator can set an alphanumeric password by using + /// dpm_set_password_quality() API + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.security + /// @param[in] handle Device policy manager handle + /// @param[in] encrypt true if encryption is required, false if decryption is + /// required + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_security_is_internal_storage_encrypted() + int dpm_security_set_internal_storage_encryption( + ffi.Pointer handle, + int encrypt, + ) { + return _dpm_security_set_internal_storage_encryption( + handle, + encrypt, + ); + } + + late final _dpm_security_set_internal_storage_encryption_ptr = _lookup< + ffi.NativeFunction<_c_dpm_security_set_internal_storage_encryption>>( + 'dpm_security_set_internal_storage_encryption'); + late final _dart_dpm_security_set_internal_storage_encryption + _dpm_security_set_internal_storage_encryption = + _dpm_security_set_internal_storage_encryption_ptr + .asFunction<_dart_dpm_security_set_internal_storage_encryption>(); + + /// @brief Checks the internal storage encryption state. + /// @details An administrator can use this API to check whether internal + /// storage encryption is enabled. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_encrypted true if internal storage is encrypted or being encrypted, + /// else false. + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_security_set_internal_storage_encryption() + int dpm_security_is_internal_storage_encrypted( + ffi.Pointer handle, + ffi.Pointer is_encrypted, + ) { + return _dpm_security_is_internal_storage_encrypted( + handle, + is_encrypted, + ); + } + + late final _dpm_security_is_internal_storage_encrypted_ptr = _lookup< + ffi.NativeFunction<_c_dpm_security_is_internal_storage_encrypted>>( + 'dpm_security_is_internal_storage_encrypted'); + late final _dart_dpm_security_is_internal_storage_encrypted + _dpm_security_is_internal_storage_encrypted = + _dpm_security_is_internal_storage_encrypted_ptr + .asFunction<_dart_dpm_security_is_internal_storage_encrypted>(); + + /// @partner + /// @brief Encrypts or decrypts external storage. + /// @details An administrator can use this API to enable external SD card + /// encryption. Before calling this API, administrator must + /// ensure that the device password is set to alphanumeric quality. + /// The administrator can set an alphanumeric password by using + /// dpm_set_password_quality() API + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.security + /// @param[in] handle Device policy manager handle + /// @param[in] encrypt true if encryption is required, false if decryption is + /// required + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_security_is_external_storage_encrypted() + int dpm_security_set_external_storage_encryption( + ffi.Pointer handle, + int encrypt, + ) { + return _dpm_security_set_external_storage_encryption( + handle, + encrypt, + ); + } + + late final _dpm_security_set_external_storage_encryption_ptr = _lookup< + ffi.NativeFunction<_c_dpm_security_set_external_storage_encryption>>( + 'dpm_security_set_external_storage_encryption'); + late final _dart_dpm_security_set_external_storage_encryption + _dpm_security_set_external_storage_encryption = + _dpm_security_set_external_storage_encryption_ptr + .asFunction<_dart_dpm_security_set_external_storage_encryption>(); + + /// @brief Checks the external storage encryption state. + /// @details An administrator can use this API to check whether external + /// storage encryption is enabled. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[out] is_encrypted true if external storage is encrypted or being encrypted, + /// else false + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_security_set_external_storage_encryption() + int dpm_security_is_external_storage_encrypted( + ffi.Pointer handle, + ffi.Pointer is_encrypted, + ) { + return _dpm_security_is_external_storage_encrypted( + handle, + is_encrypted, + ); + } + + late final _dpm_security_is_external_storage_encrypted_ptr = _lookup< + ffi.NativeFunction<_c_dpm_security_is_external_storage_encrypted>>( + 'dpm_security_is_external_storage_encrypted'); + late final _dart_dpm_security_is_external_storage_encrypted + _dpm_security_is_external_storage_encrypted = + _dpm_security_is_external_storage_encrypted_ptr + .asFunction<_dart_dpm_security_is_external_storage_encrypted>(); + + /// @partner + /// @brief Wipes external memory, internal memory, or both selectively. + /// @details Device Admin can use this API to wipe both SD card data + /// and application data. + /// Calling this API may require rebooting the device. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.wipe + /// @param[in] handle Device policy manager handle + /// @param[in] type The target storage for wipe + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + int dpm_security_wipe_data( + ffi.Pointer handle, + int type, + ) { + return _dpm_security_wipe_data( + handle, + type, + ); + } + + late final _dpm_security_wipe_data_ptr = + _lookup>( + 'dpm_security_wipe_data'); + late final _dart_dpm_security_wipe_data _dpm_security_wipe_data = + _dpm_security_wipe_data_ptr.asFunction<_dart_dpm_security_wipe_data>(); + + /// @partner + /// @brief Creates a new zone. + /// @details An administrator can use this API to create a container. Once the container + /// is created, the admin package given to the parameter will be installed inside + /// the container. Then ownership of the container gets transferred to the admin + /// package from the client which triggered the container creation process. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.zone + /// @param[in] handle Device policy manager handle + /// @param[in] name The zone name to be created + /// @param[in] pkgname Admin package container ownership will be transferred + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_zone_destroy() + /// @see dpm_zone_create_iterator() + int dpm_zone_create( + ffi.Pointer handle, + ffi.Pointer name, + ffi.Pointer pkgname, + ) { + return _dpm_zone_create( + handle, + name, + pkgname, + ); + } + + late final _dpm_zone_create_ptr = + _lookup>('dpm_zone_create'); + late final _dart_dpm_zone_create _dpm_zone_create = + _dpm_zone_create_ptr.asFunction<_dart_dpm_zone_create>(); + + /// @partner + /// @brief Removes existing zone. + /// @details Administrator can use this API to remove zone. All file system objects + /// created for the zone will be also erased. + /// @since_tizen 3.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/dpm.zone + /// @param[in] handle Device policy manager handle + /// @param[in] name The zone name to be removed + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_PERMISSION_DENIED The application does not have + /// the privilege to call this API or the caller is not the owner + /// of the zone + /// @pre The handle must be created by dpm_manager_create(). + /// @pre The zone corresponding to the given name must be + /// created before use of this API. + /// @see dpm_manager_create() + /// @see dpm_zone_create() + /// @see dpm_zone_create_iterator() + int dpm_zone_destroy( + ffi.Pointer handle, + ffi.Pointer name, + ) { + return _dpm_zone_destroy( + handle, + name, + ); + } + + late final _dpm_zone_destroy_ptr = + _lookup>('dpm_zone_destroy'); + late final _dart_dpm_zone_destroy _dpm_zone_destroy = + _dpm_zone_destroy_ptr.asFunction<_dart_dpm_zone_destroy>(); + + /// @brief Gets the zone state. + /// @details This API can be used to get the state of the zone. The zone can + /// have one of the three states(running, locked). + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[in] name The zone name + /// @param[out] state The zone state + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_NO_DATA No such zone to get state + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_zone_create() + /// @see dpm_zone_destroy() + int dpm_zone_get_state( + ffi.Pointer handle, + ffi.Pointer name, + ffi.Pointer state, + ) { + return _dpm_zone_get_state( + handle, + name, + state, + ); + } + + late final _dpm_zone_get_state_ptr = + _lookup>('dpm_zone_get_state'); + late final _dart_dpm_zone_get_state _dpm_zone_get_state = + _dpm_zone_get_state_ptr.asFunction<_dart_dpm_zone_get_state>(); + + /// @brief Retrieves all the name of created zones + /// @details This API calls dpm_zone_foreach_cb() once for each zone name + /// with traversing the created zones list. + /// @since_tizen 3.0 + /// @param[in] handle Device policy manager handle + /// @param[in] state a combination of the zone state to look + /// @param[in] callback The iteration callback function + /// @param[in] user_data The user data passed to the callback function + /// @return #DPM_ERROR_NONE on success, otherwise a negative value + /// @retval #DPM_ERROR_NONE Successful + /// @retval #DPM_ERROR_TIMED_OUT Time out + /// @retval #DPM_ERROR_INVALID_PARAMETER Invalid parameter + /// @pre The handle must be created by dpm_manager_create(). + /// @see dpm_manager_create() + /// @see dpm_zone_create() + /// @see dpm_zone_destroy() + int dpm_zone_foreach_name( + ffi.Pointer handle, + int state, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _dpm_zone_foreach_name( + handle, + state, + callback, + user_data, + ); + } + + late final _dpm_zone_foreach_name_ptr = + _lookup>( + 'dpm_zone_foreach_name'); + late final _dart_dpm_zone_foreach_name _dpm_zone_foreach_name = + _dpm_zone_foreach_name_ptr.asFunction<_dart_dpm_zone_foreach_name>(); + + /// @deprecated Deprecated since 3.0. [Use ckmc_owner_id_separator instead] + /// @brief Separator between alias and label. + /// @since_tizen 2.3 + /// @remarks Alias can be provided as an alias alone, or together with label - in this + /// case, separator " " (space bar) is used to separate label and alias. + /// @see #ckmc_owner_id_separator + late final ffi.Pointer> _ckmc_label_name_separator = + _lookup>('ckmc_label_name_separator'); + + ffi.Pointer get ckmc_label_name_separator => + _ckmc_label_name_separator.value; + + set ckmc_label_name_separator(ffi.Pointer value) => + _ckmc_label_name_separator.value = value; + + /// @brief Separator between alias and owner id. + /// @since_tizen 3.0 + /// @remarks Alias can be provided as an alias alone, or together with owner id. + /// In this case, separator " " (space bar) is used to separate id and alias. + /// @see ckmc_alias_new() + late final ffi.Pointer> _ckmc_owner_id_separator = + _lookup>('ckmc_owner_id_separator'); + + ffi.Pointer get ckmc_owner_id_separator => + _ckmc_owner_id_separator.value; + + set ckmc_owner_id_separator(ffi.Pointer value) => + _ckmc_owner_id_separator.value = value; + + /// @brief The owner of system database. + /// @since_tizen 3.0 + /// @remarks #ckmc_owner_id_system contains id connected with all system applications that run with uid less than 5000. + /// Client should use #ckmc_owner_id_system to access data owned by system application and stored in system database. + /// Client must have permission to access proper row. + /// @see ckmc_alias_new() + late final ffi.Pointer> _ckmc_owner_id_system = + _lookup>('ckmc_owner_id_system'); + + ffi.Pointer get ckmc_owner_id_system => _ckmc_owner_id_system.value; + + set ckmc_owner_id_system(ffi.Pointer value) => + _ckmc_owner_id_system.value = value; + + /// @brief Creates a new full alias which is a concatenation of @a owner_id and @a alias. + /// @since_tizen 3.0 + /// @remarks @a full_alias should be freed with free() after use. + /// @remarks Returns #CKMC_ERROR_INVALID_PARAMETER if any of parameter is NULL. + /// @remarks Returns #CKMC_ERROR_INVALID_PARAMETER if @a owner_id is empty. + /// @param[in] owner_id Data owner's id. This should be package id if data owner is + /// application. If you want to access data stored by system + /// services, it should be #ckmc_owner_id_system + /// @param[in] alias Data alias + /// @param[out] full_alias The newly created alias which is a concatenation of + /// @a owner_id, #ckmc_owner_id_separator and @a alias. + /// Destroy by free() after use + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_OUT_OF_MEMORY Not enough memory + /// @see #ckmc_owner_id_separator + /// @see #ckmc_owner_id_system + int ckmc_alias_new( + ffi.Pointer owner_id, + ffi.Pointer alias, + ffi.Pointer> full_alias, + ) { + return _ckmc_alias_new( + owner_id, + alias, + full_alias, + ); + } + + late final _ckmc_alias_new_ptr = + _lookup>('ckmc_alias_new'); + late final _dart_ckmc_alias_new _ckmc_alias_new = + _ckmc_alias_new_ptr.asFunction<_dart_ckmc_alias_new>(); + + /// @brief Creates a new #ckmc_key_s handle and returns it. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks You must destroy the newly created #ckmc_key_s by calling ckmc_key_free() if it is no longer needed. + /// @param[in] raw_key The byte array of key \n + /// @a raw_key may be encrypted with password + /// @param[in] key_size The byte size of @a raw_key + /// @param[in] key_type The @a raw_key's type + /// @param[in] password The byte array used to decrypt @a raw_key inside key manager \n + /// If @a raw_key is not encrypted, @a password can be null + /// @param[out] ppkey The pointer to a newly created #ckmc_key_s handle + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_OUT_OF_MEMORY Not enough memory + /// @see ckmc_key_free() + /// @see #ckmc_key_s + int ckmc_key_new( + ffi.Pointer raw_key, + int key_size, + int key_type, + ffi.Pointer password, + ffi.Pointer> ppkey, + ) { + return _ckmc_key_new( + raw_key, + key_size, + key_type, + password, + ppkey, + ); + } + + late final _ckmc_key_new_ptr = + _lookup>('ckmc_key_new'); + late final _dart_ckmc_key_new _ckmc_key_new = + _ckmc_key_new_ptr.asFunction<_dart_ckmc_key_new>(); + + /// @brief Destroys the #ckmc_key_s handle and releases all its resources. + /// @since_tizen 2.3 + /// @param[in] key The #ckmc_key_s handle to destroy + void ckmc_key_free( + ffi.Pointer key, + ) { + return _ckmc_key_free( + key, + ); + } + + late final _ckmc_key_free_ptr = + _lookup>('ckmc_key_free'); + late final _dart_ckmc_key_free _ckmc_key_free = + _ckmc_key_free_ptr.asFunction<_dart_ckmc_key_free>(); + + /// @brief Creates a new #ckmc_raw_buffer_s handle and returns it. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks You must destroy the newly created #ckmc_raw_buffer_s by calling ckmc_buffer_free() if it is no longer needed. + /// @param[in] data The byte array of buffer + /// @param[in] size The byte size of buffer + /// @param[out] ppbuffer The pointer to a newly created #ckmc_raw_buffer_s handle + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_OUT_OF_MEMORY Not enough memory + /// @see ckmc_buffer_free() + /// @see #ckmc_raw_buffer_s + int ckmc_buffer_new( + ffi.Pointer data, + int size, + ffi.Pointer> ppbuffer, + ) { + return _ckmc_buffer_new( + data, + size, + ppbuffer, + ); + } + + late final _ckmc_buffer_new_ptr = + _lookup>('ckmc_buffer_new'); + late final _dart_ckmc_buffer_new _ckmc_buffer_new = + _ckmc_buffer_new_ptr.asFunction<_dart_ckmc_buffer_new>(); + + /// @brief Destroys the #ckmc_raw_buffer_s handle and releases all its resources. + /// @since_tizen 2.3 + /// @param[in] buffer The #ckmc_raw_buffer_s structure to destroy + void ckmc_buffer_free( + ffi.Pointer buffer, + ) { + return _ckmc_buffer_free( + buffer, + ); + } + + late final _ckmc_buffer_free_ptr = + _lookup>('ckmc_buffer_free'); + late final _dart_ckmc_buffer_free _ckmc_buffer_free = + _ckmc_buffer_free_ptr.asFunction<_dart_ckmc_buffer_free>(); + + /// @brief Creates a new #ckmc_cert_s handle and returns it. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks You must destroy the newly created #ckmc_cert_s by calling ckmc_cert_free() if it is no longer needed. + /// @param[in] raw_cert The byte array of certificate + /// @param[in] cert_size The byte size of raw_cert + /// @param[in] data_format The encoding format of raw_cert + /// @param[out] ppcert The pointer to a newly created #ckmc_cert_s handle + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_OUT_OF_MEMORY Not enough memory + /// @see ckmc_cert_free() + /// @see ckmc_load_cert_from_file() + /// @see #ckmc_cert_s + int ckmc_cert_new( + ffi.Pointer raw_cert, + int cert_size, + int data_format, + ffi.Pointer> ppcert, + ) { + return _ckmc_cert_new( + raw_cert, + cert_size, + data_format, + ppcert, + ); + } + + late final _ckmc_cert_new_ptr = + _lookup>('ckmc_cert_new'); + late final _dart_ckmc_cert_new _ckmc_cert_new = + _ckmc_cert_new_ptr.asFunction<_dart_ckmc_cert_new>(); + + /// @brief Destroys the #ckmc_cert_s handle and releases all its resources. + /// @since_tizen 2.3 + /// @param[in] cert The #ckmc_cert_s handle to destroy + /// @see ckmc_load_cert_from_file() + void ckmc_cert_free( + ffi.Pointer cert, + ) { + return _ckmc_cert_free( + cert, + ); + } + + late final _ckmc_cert_free_ptr = + _lookup>('ckmc_cert_free'); + late final _dart_ckmc_cert_free _ckmc_cert_free = + _ckmc_cert_free_ptr.asFunction<_dart_ckmc_cert_free>(); + + /// @brief Creates a new #ckmc_cert_s handle from a given file and returns it. + /// @since_tizen 2.3 + /// @remarks You must destroy the newly created #ckmc_cert_s by calling ckmc_cert_free() if it is no longer needed. + /// @param[in] file_path The path of certificate file to be loaded \n + /// The only DER or PEM encoded certificate file is supported + /// @param[out] cert The pointer of newly created #ckmc_cert_s handle + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_OUT_OF_MEMORY Not enough memory space + /// @retval #CKMC_ERROR_INVALID_FORMAT Invalid certificate file format + /// @retval #CKMC_ERROR_FILE_ACCESS_DENIED Provided file does not exist or cannot be accessed + /// @see ckmc_cert_free() + /// @see #ckmc_cert_s + int ckmc_load_cert_from_file( + ffi.Pointer file_path, + ffi.Pointer> cert, + ) { + return _ckmc_load_cert_from_file( + file_path, + cert, + ); + } + + late final _ckmc_load_cert_from_file_ptr = + _lookup>( + 'ckmc_load_cert_from_file'); + late final _dart_ckmc_load_cert_from_file _ckmc_load_cert_from_file = + _ckmc_load_cert_from_file_ptr + .asFunction<_dart_ckmc_load_cert_from_file>(); + + /// @brief Creates a new #ckmc_pkcs12_s handle and returns it. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks You must destroy the newly created #ckmc_pkcs12_s by calling ckmc_pkcs12_free() if it is no longer needed. + /// @remarks On success, private_key, cert && ca_cert_list ownership is transferred into newly returned ckmc_pkcs12_s. + /// @param[in] private_key #ckmc_key_s handle to the private key (optional) + /// @param[in] cert #ckmc_cert_s handle to the certificate (optional) + /// @param[in] ca_cert_list #ckmc_cert_list_s list of chain certificate handles (optional) + /// @param[out] pkcs12_bundle The pointer to a newly created #ckmc_pkcs12_s handle + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid or private_key, cert and ca_cert_list all are null + /// @retval #CKMC_ERROR_OUT_OF_MEMORY Not enough memory + /// @see ckmc_pkcs12_free() + /// @see ckmc_pkcs12_load() + /// @see #ckmc_key_s + /// @see #ckmc_cert_s + /// @see #ckmc_cert_list_s + /// @see #ckmc_pkcs12_s + int ckmc_pkcs12_new( + ffi.Pointer private_key, + ffi.Pointer cert, + ffi.Pointer ca_cert_list, + ffi.Pointer> pkcs12_bundle, + ) { + return _ckmc_pkcs12_new( + private_key, + cert, + ca_cert_list, + pkcs12_bundle, + ); + } + + late final _ckmc_pkcs12_new_ptr = + _lookup>('ckmc_pkcs12_new'); + late final _dart_ckmc_pkcs12_new _ckmc_pkcs12_new = + _ckmc_pkcs12_new_ptr.asFunction<_dart_ckmc_pkcs12_new>(); + + /// @deprecated Deprecated since @if MOBILE 2.4. @elseif WEARABLE 3.0. @endif [Use ckmc_pkcs12_load() instead] + /// @brief Creates a new #ckmc_key_s (@a private_key), #ckmc_cert_s (@a cert), and #ckmc_cert_list_s (@a ca_cert_list) handle from a given PKCS#12 file and returns them. + /// @since_tizen 2.3 + /// @remarks You must destroy the newly created #ckmc_key_s, #ckmc_cert_s, and + /// #ckmc_cert_list_s by calling ckmc_key_free(), ckmc_cert_free(), and + /// ckmc_cert_list_all_free() if they are no longer needed. + /// @param[in] file_path The path of PKCS12 file to be loaded + /// @param[in] passphrase The passphrase used to decrypt the PCKS12 file \n + /// If PKCS12 file is not encrypted, passphrase can be null + /// @param[out] private_key The pointer of newly created #ckmc_key_s handle for a private key + /// @param[out] cert The pointer of newly created #ckmc_cert_s handle for a certificate \n + /// It is null if the PKCS12 file does not contain a certificate + /// @param[out] ca_cert_list The pointer of newly created #ckmc_cert_list_s handle for CA certificates \n + /// It is null if the PKCS12 file does not contain CA certificates + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_OUT_OF_MEMORY Not enough memory space + /// @retval #CKMC_ERROR_INVALID_FORMAT Invalid PKCS12 file format + /// @retval #CKMC_ERROR_FILE_ACCESS_DENIED Provided file does not exist or cannot be accessed + /// @see ckmc_pkcs12_new() + /// @see ckmc_pkcs12_load() + /// @see ckmc_key_free() + /// @see ckmc_cert_free() + /// @see ckmc_cert_list_all_free() + /// @see #ckmc_key_s + /// @see #ckmc_cert_s + /// @see #ckmc_cert_list_s + int ckmc_load_from_pkcs12_file( + ffi.Pointer file_path, + ffi.Pointer passphrase, + ffi.Pointer> private_key, + ffi.Pointer> cert, + ffi.Pointer> ca_cert_list, + ) { + return _ckmc_load_from_pkcs12_file( + file_path, + passphrase, + private_key, + cert, + ca_cert_list, + ); + } + + late final _ckmc_load_from_pkcs12_file_ptr = + _lookup>( + 'ckmc_load_from_pkcs12_file'); + late final _dart_ckmc_load_from_pkcs12_file _ckmc_load_from_pkcs12_file = + _ckmc_load_from_pkcs12_file_ptr + .asFunction<_dart_ckmc_load_from_pkcs12_file>(); + + /// @brief Creates a new #ckmc_pkcs12_s handle from a given PKCS#12 file and returns it. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks You must destroy the newly created #ckmc_pkcs12_s by calling ckmc_pkcs12_free() if they are no longer needed. + /// @param[in] file_path The path of PKCS12 file to be loaded + /// @param[in] passphrase The passphrase used to decrypt the PCKS12 file \n + /// If PKCS12 file is not encrypted, passphrase can be null + /// @param[out] pkcs12_bundle The pointer of newly created #ckmc_cert_list_s handle for CA certificates \n + /// It is null if the PKCS12 file does not contain CA certificates + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_OUT_OF_MEMORY Not enough memory space + /// @retval #CKMC_ERROR_INVALID_FORMAT Invalid PKCS12 file format + /// @retval #CKMC_ERROR_FILE_ACCESS_DENIED Provided file does not exist or cannot be accessed + /// @see ckmc_pkcs12_free() + /// @see #ckmc_pkcs12_s + int ckmc_pkcs12_load( + ffi.Pointer file_path, + ffi.Pointer passphrase, + ffi.Pointer> pkcs12_bundle, + ) { + return _ckmc_pkcs12_load( + file_path, + passphrase, + pkcs12_bundle, + ); + } + + late final _ckmc_pkcs12_load_ptr = + _lookup>('ckmc_pkcs12_load'); + late final _dart_ckmc_pkcs12_load _ckmc_pkcs12_load = + _ckmc_pkcs12_load_ptr.asFunction<_dart_ckmc_pkcs12_load>(); + + /// @brief Destroys the #ckmc_pkcs12_s handle and releases all its resources. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] pkcs12 The #ckmc_pkcs12_s handle to destroy + /// @see ckmc_pkcs12_new() + /// @see ckmc_pkcs12_load() + void ckmc_pkcs12_free( + ffi.Pointer pkcs12, + ) { + return _ckmc_pkcs12_free( + pkcs12, + ); + } + + late final _ckmc_pkcs12_free_ptr = + _lookup>('ckmc_pkcs12_free'); + late final _dart_ckmc_pkcs12_free _ckmc_pkcs12_free = + _ckmc_pkcs12_free_ptr.asFunction<_dart_ckmc_pkcs12_free>(); + + /// @brief Creates a new #ckmc_alias_list_s handle and returns it. + /// The alias pointer in the returned #ckmc_alias_list_s handle points to the provided characters and next is null. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks You must destroy the newly created #ckmc_alias_list_s + /// by calling ckmc_alias_list_free() or ckmc_alias_list_all_free() if it is no longer needed. + /// @param[in] alias The first item to be set in the newly created #ckmc_alias_list_s + /// @param[out] ppalias_list The pointer to a newly created #ckmc_alias_list_s handle + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_OUT_OF_MEMORY Not enough memory + /// @see ckmc_alias_list_all_free() + /// @see #ckmc_alias_list_s + int ckmc_alias_list_new( + ffi.Pointer alias, + ffi.Pointer> ppalias_list, + ) { + return _ckmc_alias_list_new( + alias, + ppalias_list, + ); + } + + late final _ckmc_alias_list_new_ptr = + _lookup>( + 'ckmc_alias_list_new'); + late final _dart_ckmc_alias_list_new _ckmc_alias_list_new = + _ckmc_alias_list_new_ptr.asFunction<_dart_ckmc_alias_list_new>(); + + /// @brief Creates a new #ckmc_alias_list_s handle, adds it to a previous #ckmc_alias_list_s and returns it. + /// The alias pointer in the returned #ckmc_alias_list_s handle points to the provided characters and next is null. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] previous The last #ckmc_alias_list_s handle to which a newly created #ckmc_alias_list_s is added + /// @param[in] alias The item to be set in the newly created #ckmc_alias_list_s + /// @param[out] pplast The pointer to a newly created and added #ckmc_alias_list_s handle + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_OUT_OF_MEMORY Not enough memory + /// @see ckmc_alias_list_all_free() + /// @see #ckmc_alias_list_s + int ckmc_alias_list_add( + ffi.Pointer previous, + ffi.Pointer alias, + ffi.Pointer> pplast, + ) { + return _ckmc_alias_list_add( + previous, + alias, + pplast, + ); + } + + late final _ckmc_alias_list_add_ptr = + _lookup>( + 'ckmc_alias_list_add'); + late final _dart_ckmc_alias_list_add _ckmc_alias_list_add = + _ckmc_alias_list_add_ptr.asFunction<_dart_ckmc_alias_list_add>(); + + /// @brief Destroys the #ckmc_alias_list_s handle and releases resources of #ckmc_alias_list_s from the provided first handle cascadingly. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks It does not destroy an alias itself in #ckmc_alias_list_s. + /// @param[in] first The first #ckmc_alias_list_s handle to destroy + /// @see ckmc_alias_list_all_free() + /// @see #ckmc_alias_list_s + void ckmc_alias_list_free( + ffi.Pointer first, + ) { + return _ckmc_alias_list_free( + first, + ); + } + + late final _ckmc_alias_list_free_ptr = + _lookup>( + 'ckmc_alias_list_free'); + late final _dart_ckmc_alias_list_free _ckmc_alias_list_free = + _ckmc_alias_list_free_ptr.asFunction<_dart_ckmc_alias_list_free>(); + + /// @brief Destroys the #ckmc_alias_list_s handle and releases all its resources from the provided first handle cascadingly. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks It also destroys the alias in #ckmc_alias_list_s. + /// @param[in] first The first #ckmc_alias_list_s handle to destroy + /// @see #ckmc_alias_list_s + void ckmc_alias_list_all_free( + ffi.Pointer first, + ) { + return _ckmc_alias_list_all_free( + first, + ); + } + + late final _ckmc_alias_list_all_free_ptr = + _lookup>( + 'ckmc_alias_list_all_free'); + late final _dart_ckmc_alias_list_all_free _ckmc_alias_list_all_free = + _ckmc_alias_list_all_free_ptr + .asFunction<_dart_ckmc_alias_list_all_free>(); + + /// @brief Creates a new #ckmc_cert_list_s handle and returns it. + /// The cert pointer in the returned #ckmc_cert_list_s handle points to the provided #ckmc_cert_s and next is null. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks You must destroy the newly created #ckmc_cert_list_s by calling ckmc_cert_list_free() or ckmc_cert_list_all_free() if it is no longer needed. + /// @param[in] cert The first item to be set in the newly created #ckmc_cert_list_s + /// @param[out] ppalias_list The pointer to a newly created #ckmc_alias_list_s handle + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_OUT_OF_MEMORY Not enough memory + /// @see ckmc_cert_list_all_free() + /// @see #ckmc_cert_list_s + int ckmc_cert_list_new( + ffi.Pointer cert, + ffi.Pointer> ppalias_list, + ) { + return _ckmc_cert_list_new( + cert, + ppalias_list, + ); + } + + late final _ckmc_cert_list_new_ptr = + _lookup>('ckmc_cert_list_new'); + late final _dart_ckmc_cert_list_new _ckmc_cert_list_new = + _ckmc_cert_list_new_ptr.asFunction<_dart_ckmc_cert_list_new>(); + + /// @brief Creates a new #ckmc_cert_list_s handle, adds it to a previous #ckmc_cert_list_s and returns it. + /// The cert pointer in the returned #ckmc_alias_list_s handle points to the provided #ckmc_cert_s and next is null. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] previous The last #ckmc_cert_list_s handle to which a newly created #ckmc_cert_list_s is added + /// @param[in] cert The item to be set in the newly created #ckmc_cert_list_s + /// @param[out] pplast The pointer to a newly created and added #ckmc_alias_list_s handle + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_OUT_OF_MEMORY Not enough memory + /// @see ckmc_cert_list_all_free() + /// @see #ckmc_cert_list_s + int ckmc_cert_list_add( + ffi.Pointer previous, + ffi.Pointer cert, + ffi.Pointer> pplast, + ) { + return _ckmc_cert_list_add( + previous, + cert, + pplast, + ); + } + + late final _ckmc_cert_list_add_ptr = + _lookup>('ckmc_cert_list_add'); + late final _dart_ckmc_cert_list_add _ckmc_cert_list_add = + _ckmc_cert_list_add_ptr.asFunction<_dart_ckmc_cert_list_add>(); + + /// @brief Destroys the #ckmc_cert_list_s handle and releases resources of #ckmc_cert_list_s from the provided first handle cascadingly. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks It does not destroy #ckmc_cert_s itself in #ckmc_cert_list_s. + /// @param[in] first The first #ckmc_cert_list_s handle to destroy + /// @see ckmc_cert_list_all_free() + /// @see #ckmc_cert_list_s + void ckmc_cert_list_free( + ffi.Pointer first, + ) { + return _ckmc_cert_list_free( + first, + ); + } + + late final _ckmc_cert_list_free_ptr = + _lookup>( + 'ckmc_cert_list_free'); + late final _dart_ckmc_cert_list_free _ckmc_cert_list_free = + _ckmc_cert_list_free_ptr.asFunction<_dart_ckmc_cert_list_free>(); + + /// @brief Destroys the #ckmc_cert_list_s handle and releases all its resources from the provided first handle cascadingly. + /// @since_tizen 2.3 + /// @remarks It also destroys #ckmc_cert_s in #ckmc_cert_list_s. + /// @param[in] first The first #ckmc_cert_list_s handle to destroy + /// @see #ckmc_cert_list_s + void ckmc_cert_list_all_free( + ffi.Pointer first, + ) { + return _ckmc_cert_list_all_free( + first, + ); + } + + late final _ckmc_cert_list_all_free_ptr = + _lookup>( + 'ckmc_cert_list_all_free'); + late final _dart_ckmc_cert_list_all_free _ckmc_cert_list_all_free = + _ckmc_cert_list_all_free_ptr.asFunction<_dart_ckmc_cert_list_all_free>(); + + /// @brief Creates new parameter list. + /// @since_tizen 3.0 + /// @remarks Caller is responsible for freeing it with ckmc_param_list_free(). + /// @param[in] pparams Double pointer to the handle of param list to which the newly created algorithm param list will be assigned + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @see ckmc_param_list_set_integer() + /// @see ckmc_param_list_set_buffer() + /// @see ckmc_param_list_free() + /// @see ckmc_generate_new_params() + /// @see #ckmc_param_list_h + /// @see #ckmc_param_name_e + /// @see #ckmc_algo_type_e + int ckmc_param_list_new( + ffi.Pointer> pparams, + ) { + return _ckmc_param_list_new( + pparams, + ); + } + + late final _ckmc_param_list_new_ptr = + _lookup>( + 'ckmc_param_list_new'); + late final _dart_ckmc_param_list_new _ckmc_param_list_new = + _ckmc_param_list_new_ptr.asFunction<_dart_ckmc_param_list_new>(); + + /// @brief Sets integer parameter to the list. + /// @since_tizen 3.0 + /// @remarks Caller is responsible for #ckmc_param_list_h creation. + /// @param[in] params Algorithm param list handle created with ckmc_param_list_new() or ckmc_generate_new_params() \n + /// New param with @a name and @a value will be set here + /// @param[in] name Name of parameter to set \n + /// Existing parameter will be overwritten \n + /// Passing invalid parameter name will result in an error + /// @param[in] value Value of the parameter in form of a integer + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @see ckmc_param_list_new() + /// @see ckmc_param_list_set_buffer() + /// @see ckmc_param_list_get_integer() + /// @see ckmc_param_list_get_buffer() + /// @see ckmc_param_list_free() + /// @see ckmc_generate_new_params() + /// @see #ckmc_param_list_h + /// @see #ckmc_param_name_e + /// @see #ckmc_algo_type_e + int ckmc_param_list_set_integer( + ffi.Pointer<__ckmc_param_list> params, + int name, + int value, + ) { + return _ckmc_param_list_set_integer( + params, + name, + value, + ); + } + + late final _ckmc_param_list_set_integer_ptr = + _lookup>( + 'ckmc_param_list_set_integer'); + late final _dart_ckmc_param_list_set_integer _ckmc_param_list_set_integer = + _ckmc_param_list_set_integer_ptr + .asFunction<_dart_ckmc_param_list_set_integer>(); + + /// @brief Sets buffer parameter to the list. + /// @since_tizen 3.0 + /// @remarks Caller is responsible for #ckmc_param_list_h creation. + /// @param[in] params Algorithm param list handle created with ckmc_param_list_new() or ckmc_generate_new_params() + /// New param with @a name and @a buffer will be set here + /// @param[in] name Name of parameter to set \n + /// Existing parameter will be overwritten \n + /// Passing invalid parameter name will result in an error + /// @param[in] buffer Value of the parameter in form of a buffer \n + /// Caller is responsible for creating and freeing the buffer + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @see ckmc_param_list_new() + /// @see ckmc_param_list_set_integer() + /// @see ckmc_param_list_get_integer() + /// @see ckmc_param_list_get_buffer() + /// @see ckmc_param_list_free() + /// @see ckmc_generate_new_params() + /// @see #ckmc_param_list_h + /// @see #ckmc_param_name_e + /// @see #ckmc_algo_type_e + int ckmc_param_list_set_buffer( + ffi.Pointer<__ckmc_param_list> params, + int name, + ffi.Pointer buffer, + ) { + return _ckmc_param_list_set_buffer( + params, + name, + buffer, + ); + } + + late final _ckmc_param_list_set_buffer_ptr = + _lookup>( + 'ckmc_param_list_set_buffer'); + late final _dart_ckmc_param_list_set_buffer _ckmc_param_list_set_buffer = + _ckmc_param_list_set_buffer_ptr + .asFunction<_dart_ckmc_param_list_set_buffer>(); + + /// @brief Gets integer parameter from the list. + /// @since_tizen 3.0 + /// @remarks Caller is responsible for #ckmc_param_list_h creation. + /// @param[in] params Algorithm param list handle created with ckmc_param_list_new() or ckmc_generate_new_params() + /// which contains param with @a name + /// @param[in] name Name of parameter to get + /// @param[out] pvalue Value of the parameter in form of a integer + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @see ckmc_param_list_new() + /// @see ckmc_param_list_set_integer() + /// @see ckmc_param_list_set_buffer() + /// @see ckmc_param_list_get_buffer() + /// @see ckmc_param_list_free() + /// @see ckmc_generate_new_params() + /// @see #ckmc_param_list_h + /// @see #ckmc_param_name_e + /// @see #ckmc_algo_type_e + int ckmc_param_list_get_integer( + ffi.Pointer<__ckmc_param_list> params, + int name, + ffi.Pointer pvalue, + ) { + return _ckmc_param_list_get_integer( + params, + name, + pvalue, + ); + } + + late final _ckmc_param_list_get_integer_ptr = + _lookup>( + 'ckmc_param_list_get_integer'); + late final _dart_ckmc_param_list_get_integer _ckmc_param_list_get_integer = + _ckmc_param_list_get_integer_ptr + .asFunction<_dart_ckmc_param_list_get_integer>(); + + /// @brief Gets buffer parameter from the list. + /// @since_tizen 3.0 + /// @remarks Caller is responsible for #ckmc_param_list_h creation. + /// @param[in] params Algorithm param list handle created with ckmc_param_list_new() or ckmc_generate_new_params() + /// which contains param with @a name + /// @param[in] name Name of parameter to get + /// @param[out] ppbuffer Value of the parameter in form of a buffer \n + /// Caller is responsible for creating and freeing the buffer + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @see ckmc_param_list_new() + /// @see ckmc_param_list_set_integer() + /// @see ckmc_param_list_set_buffer() + /// @see ckmc_param_list_get_integer() + /// @see ckmc_param_list_free() + /// @see ckmc_generate_new_params() + /// @see ckmc_buffer_free() + /// @see #ckmc_param_list_h + /// @see #ckmc_param_name_e + /// @see #ckmc_algo_type_e + int ckmc_param_list_get_buffer( + ffi.Pointer<__ckmc_param_list> params, + int name, + ffi.Pointer> ppbuffer, + ) { + return _ckmc_param_list_get_buffer( + params, + name, + ppbuffer, + ); + } + + late final _ckmc_param_list_get_buffer_ptr = + _lookup>( + 'ckmc_param_list_get_buffer'); + late final _dart_ckmc_param_list_get_buffer _ckmc_param_list_get_buffer = + _ckmc_param_list_get_buffer_ptr + .asFunction<_dart_ckmc_param_list_get_buffer>(); + + /// @brief Frees previously allocated list of algorithm params. + /// @since_tizen 3.0 + /// @param[in] params First element of the list to be freed + /// @see ckmc_param_list_new() + /// @see ckmc_param_list_set_integer() + /// @see ckmc_param_list_set_buffer() + /// @see ckmc_param_list_get_integer() + /// @see ckmc_param_list_get_buffer() + /// @see ckmc_generate_new_params() + /// @see #ckmc_param_list_h + /// @see #ckmc_param_name_e + /// @see #ckmc_algo_type_e + void ckmc_param_list_free( + ffi.Pointer<__ckmc_param_list> params, + ) { + return _ckmc_param_list_free( + params, + ); + } + + late final _ckmc_param_list_free_ptr = + _lookup>( + 'ckmc_param_list_free'); + late final _dart_ckmc_param_list_free _ckmc_param_list_free = + _ckmc_param_list_free_ptr.asFunction<_dart_ckmc_param_list_free>(); + + /// @brief Generates algorithm parameters for a given algorithm type and set them to the list. + /// @since_tizen 3.0 + /// @remarks Caller is responsible for #ckmc_param_list_h destruction. + /// @remarks Algorithm parameters are set to default values. Optional fields are left empty. + /// Initialization vectors are left empty (they have to be set manually). + /// Caller is responsible for freeing the list with ckmc_param_list_free(). + /// @remarks If the function returns error, provided param list may contain some of default parameters. + /// @param[in] type Type of the algorithm + /// @param[out] pparams Newly generated handle of param list which should be freed by caller after use + /// @return #CKMC_ERROR_NONE on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @see ckmc_param_list_new() + /// @see ckmc_param_list_set_integer() + /// @see ckmc_param_list_set_buffer() + /// @see ckmc_param_list_get_integer() + /// @see ckmc_param_list_get_buffer() + /// @see ckmc_param_list_free() + /// @see #ckmc_param_list_h + /// @see #ckmc_param_name_e + /// @see #ckmc_algo_type_e + int ckmc_generate_new_params( + int type, + ffi.Pointer> pparams, + ) { + return _ckmc_generate_new_params( + type, + pparams, + ); + } + + late final _ckmc_generate_new_params_ptr = + _lookup>( + 'ckmc_generate_new_params'); + late final _dart_ckmc_generate_new_params _ckmc_generate_new_params = + _ckmc_generate_new_params_ptr + .asFunction<_dart_ckmc_generate_new_params>(); + + /// @brief Stores a key inside key manager based on the provided policy. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks Currently API supports seven types of keys. These are RSA public/private key, DSA public/private key, ECDSA public/private key, and AES symmetric key. + /// @remarks key_type in key may be set to #CKMC_KEY_NONE as an input. key_type is determined inside key manager during storing keys. + /// @remarks Some private key files are protected by a password. If raw_key in key read from those encrypted files is encrypted with a password, the password should be provided in the #ckmc_key_s structure. + /// @remarks If password in policy is provided, the key is additionally encrypted with the password in the policy. + /// @param[in] alias The name of a key to be stored + /// @param[in] key The key's binary value to be stored + /// @param[in] policy The policy about how to store a key securely + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ALIAS_EXISTS Alias already exists + /// @retval #CKMC_ERROR_INVALID_FORMAT The format of raw_key is not valid + /// @retval #CKMC_ERROR_DB_ERROR Failed due to a database error + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_remove_alias() + /// @see ckmc_get_key() + /// @see ckmc_get_key_alias_list() + /// @see #ckmc_key_s + /// @see #ckmc_policy_s + int ckmc_save_key( + ffi.Pointer alias, + ckmc_key_s key, + ckmc_policy_s policy, + ) { + return _ckmc_save_key( + alias, + key, + policy, + ); + } + + late final _ckmc_save_key_ptr = + _lookup>('ckmc_save_key'); + late final _dart_ckmc_save_key _ckmc_save_key = + _ckmc_save_key_ptr.asFunction<_dart_ckmc_save_key>(); + + /// @deprecated Deprecated since @if MOBILE 2.4. @elseif WEARABLE 3.0. @endif [Use ckmc_remove_alias() instead] + /// @brief Removes a key from key manager. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks To remove key, client must have remove permission to the specified key. + /// @remarks The key owner can remove by default. + /// @param[in] alias The name of a key to be removed + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to a database error + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_save_key() + /// @see ckmc_get_key() + /// @see ckmc_get_key_alias_list() + int ckmc_remove_key( + ffi.Pointer alias, + ) { + return _ckmc_remove_key( + alias, + ); + } + + late final _ckmc_remove_key_ptr = + _lookup>('ckmc_remove_key'); + late final _dart_ckmc_remove_key _ckmc_remove_key = + _ckmc_remove_key_ptr.asFunction<_dart_ckmc_remove_key>(); + + /// @brief Gets a key from key manager. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks A client can access only data stored by the client. + /// @remarks You must destroy the newly created @a ppkey by calling ckmc_key_free() if it is no longer needed. + /// @param[in] alias The name of a key to retrieve + /// @param[in] password The password used in decrypting a key value \n + /// If password of policy is provided in ckmc_save_key(), the same password should be provided + /// @param[out] ppkey The pointer to a newly created ckmc_key_s handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to a database error + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @retval #CKMC_ERROR_AUTHENTICATION_FAILED Decryption failed because password is incorrect + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_save_key() + /// @see ckmc_remove_alias() + /// @see ckmc_get_key_alias_list() + int ckmc_get_key( + ffi.Pointer alias, + ffi.Pointer password, + ffi.Pointer> ppkey, + ) { + return _ckmc_get_key( + alias, + password, + ppkey, + ); + } + + late final _ckmc_get_key_ptr = + _lookup>('ckmc_get_key'); + late final _dart_ckmc_get_key _ckmc_get_key = + _ckmc_get_key_ptr.asFunction<_dart_ckmc_get_key>(); + + /// @brief Gets all the alias of keys that the client can access. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks A client can access only data stored by the client. + /// @remarks You must destroy the newly created @a ppalias_list by calling ckmc_alias_list_all_free() + /// if it is no longer needed. + /// @param[out] ppalias_list The pointer to a newly created ckmc_alias_list_s handle containing all + /// available alias of keys \n + /// If there is no available key alias, *ppalias_list will be null + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to a database error + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_save_key() + /// @see ckmc_remove_alias() + /// @see ckmc_get_key() + int ckmc_get_key_alias_list( + ffi.Pointer> ppalias_list, + ) { + return _ckmc_get_key_alias_list( + ppalias_list, + ); + } + + late final _ckmc_get_key_alias_list_ptr = + _lookup>( + 'ckmc_get_key_alias_list'); + late final _dart_ckmc_get_key_alias_list _ckmc_get_key_alias_list = + _ckmc_get_key_alias_list_ptr.asFunction<_dart_ckmc_get_key_alias_list>(); + + /// @brief Stores a certificate inside key manager based on the provided policy. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0 + /// @remarks The certificate's binary value will be converted and saved as binary DER encoded certificates. + /// @param[in] alias The name of a certificate to be stored + /// @param[in] cert The certificate's binary value to be stored + /// @param[in] policy The policy about how to store a certificate securely + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ALIAS_EXISTS Alias already exists + /// @retval #CKMC_ERROR_INVALID_FORMAT The format of raw_cert is not valid + /// @retval #CKMC_ERROR_DB_ERROR Failed due to a database error + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_remove_alias() + /// @see ckmc_get_cert() + /// @see ckmc_get_cert_alias_list() + /// @see #ckmc_cert_s + /// @see #ckmc_policy_s + int ckmc_save_cert( + ffi.Pointer alias, + ckmc_cert_s cert, + ckmc_policy_s policy, + ) { + return _ckmc_save_cert( + alias, + cert, + policy, + ); + } + + late final _ckmc_save_cert_ptr = + _lookup>('ckmc_save_cert'); + late final _dart_ckmc_save_cert _ckmc_save_cert = + _ckmc_save_cert_ptr.asFunction<_dart_ckmc_save_cert>(); + + /// @deprecated Deprecated since @if MOBILE 2.4. @elseif WEARABLE 3.0. @endif [Use ckmc_remove_alias() instead] + /// @brief Removes a certificate from key manager. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks To remove certificate, client must have remove permission to the specified certificate. + /// @remarks The key owner can remove by default. + /// @param[in] alias The name of a certificate to be removed + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to a database error + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_save_cert() + /// @see ckmc_get_cert() + /// @see ckmc_get_cert_alias_list() + int ckmc_remove_cert( + ffi.Pointer alias, + ) { + return _ckmc_remove_cert( + alias, + ); + } + + late final _ckmc_remove_cert_ptr = + _lookup>('ckmc_remove_cert'); + late final _dart_ckmc_remove_cert _ckmc_remove_cert = + _ckmc_remove_cert_ptr.asFunction<_dart_ckmc_remove_cert>(); + + /// @brief Gets a certificate from key manager. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks A client can access only certificate stored by the client. + /// @remarks A DER encoded certificate will be returned as a return value. + /// @remarks You must destroy the newly created @a ppcert by calling ckmc_cert_free() if it is no longer needed. + /// @param[in] alias The name of a certificate to retrieve + /// @param[in] password The password used in decrypting a certificate value \n + /// If password of policy is provided in ckmc_save_cert(), the same password + /// should be provided + /// @param[out] ppcert The pointer to a newly created ckmc_cert_s handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to a database error + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exists + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @retval #CKMC_ERROR_AUTHENTICATION_FAILED Decryption failed because password is incorrect + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_save_cert() + /// @see ckmc_remove_alias() + /// @see ckmc_get_cert_alias_list() + int ckmc_get_cert( + ffi.Pointer alias, + ffi.Pointer password, + ffi.Pointer> ppcert, + ) { + return _ckmc_get_cert( + alias, + password, + ppcert, + ); + } + + late final _ckmc_get_cert_ptr = + _lookup>('ckmc_get_cert'); + late final _dart_ckmc_get_cert _ckmc_get_cert = + _ckmc_get_cert_ptr.asFunction<_dart_ckmc_get_cert>(); + + /// @brief Gets all alias of certificates which the client can access. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks A client can access only data stored by the client. + /// @remarks You must destroy the newly created @a ppalias_list by calling ckmc_alias_list_all_free() if it is no longer needed. + /// @param[out] ppalias_list The pointer to a newly created ckmc_alias_list_s handle containing all available alias of keys \n + /// If there is no available key alias, *ppalias_list will be null + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to a database error + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_save_cert() + /// @see ckmc_remove_alias() + /// @see ckmc_get_cert() + int ckmc_get_cert_alias_list( + ffi.Pointer> ppalias_list, + ) { + return _ckmc_get_cert_alias_list( + ppalias_list, + ); + } + + late final _ckmc_get_cert_alias_list_ptr = + _lookup>( + 'ckmc_get_cert_alias_list'); + late final _dart_ckmc_get_cert_alias_list _ckmc_get_cert_alias_list = + _ckmc_get_cert_alias_list_ptr + .asFunction<_dart_ckmc_get_cert_alias_list>(); + + /// @brief Stores PKCS12's contents inside key manager based on the provided policies. All items from the PKCS12 will use the same alias. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @param[in] alias The name of a data to be stored + /// @param[in] pkcs Pointer to the pkcs12 structure to be saved + /// @param[in] key_policy The policy about how to store pkcs's private key + /// @param[in] cert_policy The policy about how to store pkcs's certificate + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ALIAS_EXISTS Alias already exists + /// @retval #CKMC_ERROR_DB_ERROR Failed due to a database error + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_remove_alias() + /// @see ckmc_get_pkcs12() + /// @see ckmc_get_data_alias_list() + /// @see ckmc_pkcs12_load() + /// @see #ckmc_pkcs12_s + /// @see #ckmc_policy_s + int ckmc_save_pkcs12( + ffi.Pointer alias, + ffi.Pointer pkcs, + ckmc_policy_s key_policy, + ckmc_policy_s cert_policy, + ) { + return _ckmc_save_pkcs12( + alias, + pkcs, + key_policy, + cert_policy, + ); + } + + late final _ckmc_save_pkcs12_ptr = + _lookup>('ckmc_save_pkcs12'); + late final _dart_ckmc_save_pkcs12 _ckmc_save_pkcs12 = + _ckmc_save_pkcs12_ptr.asFunction<_dart_ckmc_save_pkcs12>(); + + /// @brief Gets a pkcs12 from key manager. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks A client can access only data stored by the client. + /// @remarks You must destroy the newly created @a pkcs12 by calling ckmc_pkcs12_free() if it is no longer needed. + /// @param[in] alias The name of a data to retrieve + /// @param[in] key_password Password that was used to encrypt privateKey (may be NULL) + /// @param[in] cert_password Password used to encrypt certificates (may be NULL) + /// @param[out] pkcs12 The pointer to a newly created ckmc_pkcs12_s handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to a database error + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @retval #CKMC_ERROR_AUTHENTICATION_FAILED key_password or cert_password does not match with password used to encrypt data + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_save_pkcs12() + /// @see ckmc_remove_alias() + int ckmc_get_pkcs12( + ffi.Pointer alias, + ffi.Pointer key_password, + ffi.Pointer cert_password, + ffi.Pointer> pkcs12, + ) { + return _ckmc_get_pkcs12( + alias, + key_password, + cert_password, + pkcs12, + ); + } + + late final _ckmc_get_pkcs12_ptr = + _lookup>('ckmc_get_pkcs12'); + late final _dart_ckmc_get_pkcs12 _ckmc_get_pkcs12 = + _ckmc_get_pkcs12_ptr.asFunction<_dart_ckmc_get_pkcs12>(); + + /// @brief Stores a data inside key manager based on the provided policy. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @param[in] alias The name of a data to be stored + /// @param[in] data The binary value to be stored + /// @param[in] policy The policy about how to store a data securely + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ALIAS_EXISTS Alias already exists + /// @retval #CKMC_ERROR_DB_ERROR Failed due to a database error + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_remove_alias() + /// @see ckmc_get_data() + /// @see ckmc_get_data_alias_list() + /// @see #ckmc_raw_buffer_s + /// @see #ckmc_policy_s + int ckmc_save_data( + ffi.Pointer alias, + ckmc_raw_buffer_s data, + ckmc_policy_s policy, + ) { + return _ckmc_save_data( + alias, + data, + policy, + ); + } + + late final _ckmc_save_data_ptr = + _lookup>('ckmc_save_data'); + late final _dart_ckmc_save_data _ckmc_save_data = + _ckmc_save_data_ptr.asFunction<_dart_ckmc_save_data>(); + + /// @deprecated Deprecated since @if MOBILE 2.4. @elseif WEARABLE 3.0. @endif [Use ckmc_remove_alias() instead] + /// @brief Removes a data from key manager. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks To remove data, client must have remove permission to the specified data object. + /// @remarks The data owner can remove by default. + /// @param[in] alias The name of a data to be removed + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to the error with unknown reason + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_save_data() + /// @see ckmc_get_data() + /// @see ckmc_get_data_alias_list() + int ckmc_remove_data( + ffi.Pointer alias, + ) { + return _ckmc_remove_data( + alias, + ); + } + + late final _ckmc_remove_data_ptr = + _lookup>('ckmc_remove_data'); + late final _dart_ckmc_remove_data _ckmc_remove_data = + _ckmc_remove_data_ptr.asFunction<_dart_ckmc_remove_data>(); + + /// @brief Gets a data from key manager. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks A client can access only data stored by the client. + /// @remarks You must destroy the newly created @a ppdata by calling ckmc_buffer_free() if it is no longer needed. + /// @param[in] alias The name of a data to retrieve + /// @param[in] password The password used in decrypting a data value \n + /// If password of policy is provided in ckmc_save_data(), the same password + /// should be provided + /// @param[out] ppdata The pointer to a newly created ckmc_raw_buffer_s handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to the error with unknown reason + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @retval #CKMC_ERROR_AUTHENTICATION_FAILED Decryption failed because password is incorrect + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_save_data() + /// @see ckmc_remove_alias() + /// @see ckmc_get_data_alias_list() + int ckmc_get_data( + ffi.Pointer alias, + ffi.Pointer password, + ffi.Pointer> ppdata, + ) { + return _ckmc_get_data( + alias, + password, + ppdata, + ); + } + + late final _ckmc_get_data_ptr = + _lookup>('ckmc_get_data'); + late final _dart_ckmc_get_data _ckmc_get_data = + _ckmc_get_data_ptr.asFunction<_dart_ckmc_get_data>(); + + /// @brief Gets all alias of data which the client can access. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks A client can access only data stored by the client. + /// @remarks You must destroy the newly created @a ppalias_list by calling ckmc_alias_list_all_free() if it is no longer needed. + /// @param[out] ppalias_list The pointer to a newly created ckmc_alias_list_s handle containing all available alias of keys \n + /// If there is no available key alias, *ppalias_list will be null + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to the error with unknown reason + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_save_data() + /// @see ckmc_remove_alias() + /// @see ckmc_get_data() + int ckmc_get_data_alias_list( + ffi.Pointer> ppalias_list, + ) { + return _ckmc_get_data_alias_list( + ppalias_list, + ); + } + + late final _ckmc_get_data_alias_list_ptr = + _lookup>( + 'ckmc_get_data_alias_list'); + late final _dart_ckmc_get_data_alias_list _ckmc_get_data_alias_list = + _ckmc_get_data_alias_list_ptr + .asFunction<_dart_ckmc_get_data_alias_list>(); + + /// @brief Creates RSA private/public key pair and stores them inside key manager based on each policy. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks If password in the policy is provided, the key is additionally encrypted with the password in the policy. + /// @param[in] size The size of key strength to be created \n + /// @c 1024, @c 2048, and @c 4096 are supported + /// @param[in] private_key_alias The name of private key to be stored + /// @param[in] public_key_alias The name of public key to be stored + /// @param[in] policy_private_key The policy about how to store a private key securely + /// @param[in] policy_public_key The policy about how to store a public key securely + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ALIAS_EXISTS Alias already exists + /// @retval #CKMC_ERROR_DB_ERROR Failed due to other DB transaction unexpectedly + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_create_key_pair_dsa() + /// @see ckmc_create_key_pair_ecdsa() + /// @see ckmc_create_signature() + /// @see ckmc_verify_signature() + int ckmc_create_key_pair_rsa( + int size, + ffi.Pointer private_key_alias, + ffi.Pointer public_key_alias, + ckmc_policy_s policy_private_key, + ckmc_policy_s policy_public_key, + ) { + return _ckmc_create_key_pair_rsa( + size, + private_key_alias, + public_key_alias, + policy_private_key, + policy_public_key, + ); + } + + late final _ckmc_create_key_pair_rsa_ptr = + _lookup>( + 'ckmc_create_key_pair_rsa'); + late final _dart_ckmc_create_key_pair_rsa _ckmc_create_key_pair_rsa = + _ckmc_create_key_pair_rsa_ptr + .asFunction<_dart_ckmc_create_key_pair_rsa>(); + + /// @brief Creates DSA private/public key pair and stores them inside key manager based on each policy. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks If password in the policy is provided, the key is additionally encrypted with the password in the policy. + /// @param[in] size The size of key strength to be created \n + /// @c 1024, @c 2048, @c 3072 and @c 4096 are supported + /// @param[in] private_key_alias The name of private key to be stored + /// @param[in] public_key_alias The name of public key to be stored + /// @param[in] policy_private_key The policy about how to store a private key securely + /// @param[in] policy_public_key The policy about how to store a public key securely + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ALIAS_EXISTS Alias already exists + /// @retval #CKMC_ERROR_DB_ERROR Failed due to other DB transaction unexpectedly + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_create_key_pair_rsa() + /// @see ckmc_create_key_pair_ecdsa() + /// @see ckmc_create_signature() + /// @see ckmc_verify_signature() + int ckmc_create_key_pair_dsa( + int size, + ffi.Pointer private_key_alias, + ffi.Pointer public_key_alias, + ckmc_policy_s policy_private_key, + ckmc_policy_s policy_public_key, + ) { + return _ckmc_create_key_pair_dsa( + size, + private_key_alias, + public_key_alias, + policy_private_key, + policy_public_key, + ); + } + + late final _ckmc_create_key_pair_dsa_ptr = + _lookup>( + 'ckmc_create_key_pair_dsa'); + late final _dart_ckmc_create_key_pair_dsa _ckmc_create_key_pair_dsa = + _ckmc_create_key_pair_dsa_ptr + .asFunction<_dart_ckmc_create_key_pair_dsa>(); + + /// @brief Creates ECDSA private/public key pair and stores them inside key manager based on each policy. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks If password in the policy is provided, the key is additionally encrypted with the password in the policy. + /// @param[in] type The type of elliptic curve of ECDSA + /// @param[in] private_key_alias The name of private key to be stored + /// @param[in] public_key_alias The name of public key to be stored + /// @param[in] policy_private_key The policy about how to store a private key securely + /// @param[in] policy_public_key The policy about how to store a public key securely + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ALIAS_EXISTS Alias already exists + /// @retval #CKMC_ERROR_DB_ERROR Failed due to other DB transaction unexpectedly + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_create_key_pair_rsa() + /// @see ckmc_create_key_pair_dsa() + /// @see ckmc_create_signature() + /// @see ckmc_verify_signature() + /// @see #ckmc_ec_type_e + int ckmc_create_key_pair_ecdsa( + int type, + ffi.Pointer private_key_alias, + ffi.Pointer public_key_alias, + ckmc_policy_s policy_private_key, + ckmc_policy_s policy_public_key, + ) { + return _ckmc_create_key_pair_ecdsa( + type, + private_key_alias, + public_key_alias, + policy_private_key, + policy_public_key, + ); + } + + late final _ckmc_create_key_pair_ecdsa_ptr = + _lookup>( + 'ckmc_create_key_pair_ecdsa'); + late final _dart_ckmc_create_key_pair_ecdsa _ckmc_create_key_pair_ecdsa = + _ckmc_create_key_pair_ecdsa_ptr + .asFunction<_dart_ckmc_create_key_pair_ecdsa>(); + + /// @brief Creates AES key and stores it inside key manager based on the policy. + /// @since_tizen 3.0 + /// @remarks If password in the policy is provided, the key is additionally encrypted with the password in the policy. + /// @param[in] size The size of key strength to be created \n + /// @c 128, @c 192 and @c 256 are supported + /// @param[in] key_alias The name of key to be stored + /// @param[in] key_policy The policy about how to store the key securely + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ALIAS_EXISTS Alias already exists + /// @retval #CKMC_ERROR_DB_ERROR Failed due to other DB transaction unexpectedly + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_create_key_pair_rsa() + /// @see ckmc_create_key_pair_dsa() + /// @see ckmc_create_key_pair_ecdsa() + /// @see #ckmc_policy_s + int ckmc_create_key_aes( + int size, + ffi.Pointer key_alias, + ckmc_policy_s key_policy, + ) { + return _ckmc_create_key_aes( + size, + key_alias, + key_policy, + ); + } + + late final _ckmc_create_key_aes_ptr = + _lookup>( + 'ckmc_create_key_aes'); + late final _dart_ckmc_create_key_aes _ckmc_create_key_aes = + _ckmc_create_key_aes_ptr.asFunction<_dart_ckmc_create_key_aes>(); + + /// @brief Creates a signature on a given message using a private key and returns the signature. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks If password of policy is provided during storing a key, the same password should be provided. + /// @remarks You must destroy the newly created @a ppsignature by calling ckmc_buffer_free() if it is no longer needed. + /// @param[in] private_key_alias The name of private key + /// @param[in] password The password used in decrypting a private key value + /// @param[in] message The message that is signed with a private key + /// @param[in] hash The hash algorithm used in creating signature + /// @param[in] padding The RSA padding algorithm used in creating signature \n + /// It is used only when the signature algorithm is RSA. If + /// @a padding is CKMC_NONE_PADDING you must use CKMC_HASH_NONE + /// and the message must be equal to key length + /// @param[out] ppsignature The pointer to a newly created signature \n + /// If an error occurs, @a *ppsignature will be null + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to the error with unknown reason + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @retval #CKMC_ERROR_AUTHENTICATION_FAILED Decryption failed because password is incorrect + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_create_key_pair_rsa() + /// @see ckmc_create_key_pair_ecdsa() + /// @see ckmc_verify_signature() + /// @see ckmc_buffer_free() + /// @see #ckmc_hash_algo_e + /// @see #ckmc_rsa_padding_algo_e + int ckmc_create_signature( + ffi.Pointer private_key_alias, + ffi.Pointer password, + ckmc_raw_buffer_s message, + int hash, + int padding, + ffi.Pointer> ppsignature, + ) { + return _ckmc_create_signature( + private_key_alias, + password, + message, + hash, + padding, + ppsignature, + ); + } + + late final _ckmc_create_signature_ptr = + _lookup>( + 'ckmc_create_signature'); + late final _dart_ckmc_create_signature _ckmc_create_signature = + _ckmc_create_signature_ptr.asFunction<_dart_ckmc_create_signature>(); + + /// @brief Verifies a given signature on a given message using a public key and returns the signature status. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks If password of policy is provided during storing a key, the same password should be provided. + /// @param[in] public_key_alias The name of public key + /// @param[in] password The password used in decrypting a public key value + /// @param[in] message The input on which the signature is created + /// @param[in] signature The signature that is verified with public key + /// @param[in] hash The hash algorithm used in verifying signature + /// @param[in] padding The RSA padding algorithm used in verifying signature \n + /// It is used only when the signature algorithm is RSA. If + /// @a padding is CKMC_NONE_PADDING you must use CKMC_HASH_NONE + /// and the message must be equal to key length + /// @return @c 0 on success and the signature is valid, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_VERIFICATION_FAILED The signature is invalid + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to the error with unknown reason + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @retval #CKMC_ERROR_AUTHENTICATION_FAILED Decryption failed because password is incorrect + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_create_key_pair_rsa() + /// @see ckmc_create_key_pair_ecdsa() + /// @see ckmc_verify_signature() + /// @see #ckmc_hash_algo_e + /// @see #ckmc_rsa_padding_algo_e + int ckmc_verify_signature( + ffi.Pointer public_key_alias, + ffi.Pointer password, + ckmc_raw_buffer_s message, + ckmc_raw_buffer_s signature, + int hash, + int padding, + ) { + return _ckmc_verify_signature( + public_key_alias, + password, + message, + signature, + hash, + padding, + ); + } + + late final _ckmc_verify_signature_ptr = + _lookup>( + 'ckmc_verify_signature'); + late final _dart_ckmc_verify_signature _ckmc_verify_signature = + _ckmc_verify_signature_ptr.asFunction<_dart_ckmc_verify_signature>(); + + /// @brief Verifies a certificate chain and returns that chain. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks The trusted root certificate of the chain should exist in the system's certificate storage. + /// @remarks You must destroy the newly created @a ppcert_chain_list by calling ckmc_cert_list_all_free() if it is no longer needed. + /// @param[in] cert The certificate to be verified + /// @param[in] untrustedcerts The untrusted CA certificates to be used in verifying a certificate chain + /// @param[out] ppcert_chain_list The pointer to a newly created certificate chain's handle \n + /// If an error occurs, @a *ppcert_chain_list will be null + /// @return @c 0 on success and the signature is valid, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_VERIFICATION_FAILED The certificate chain is not valid + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to the error with unknown reason + /// @retval #CKMC_ERROR_INVALID_FORMAT The format of certificate is not valid + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @retval #CKMC_ERROR_AUTHENTICATION_FAILED Decryption failed because password is incorrect + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_cert_list_all_free() + int ckmc_get_cert_chain( + ffi.Pointer cert, + ffi.Pointer untrustedcerts, + ffi.Pointer> ppcert_chain_list, + ) { + return _ckmc_get_cert_chain( + cert, + untrustedcerts, + ppcert_chain_list, + ); + } + + late final _ckmc_get_cert_chain_ptr = + _lookup>( + 'ckmc_get_cert_chain'); + late final _dart_ckmc_get_cert_chain _ckmc_get_cert_chain = + _ckmc_get_cert_chain_ptr.asFunction<_dart_ckmc_get_cert_chain>(); + + /// @deprecated Deprecated since @if MOBILE 2.4. @elseif WEARABLE 3.0. @endif [Use ckmc_get_cert_chain() instead] + /// @brief Verifies a certificate chain using an alias list of untrusted certificates and return that chain. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks The trusted root certificate of the chain should exist in the system's certificate storage. + /// @remarks You must destroy the newly created @a ppcert_chain_list by calling ckmc_cert_list_all_free() if it is no longer needed. + /// @remarks @a untrustedcerts shouldn't be protected with optional password. + /// @param[in] cert The certificate to be verified + /// @param[in] untrustedcerts The alias list of untrusted CA certificates stored in key manager to be used in verifying a certificate chain + /// @param[out] ppcert_chain_list The pointer to a newly created certificate chain's handle \n + /// If an error occurs, @a *ppcert_chain_list will be null + /// @return @c 0 on success and the signature is valid, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_VERIFICATION_FAILED The certificate chain is not valid + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to the error with unknown reason + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_INVALID_FORMAT The format of certificate is not valid + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @retval #CKMC_ERROR_AUTHENTICATION_FAILED Some certificates were encrypted with password and could not be used + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_get_cert_chain() + /// @see ckmc_cert_list_all_free() + int ckmc_get_cert_chain_with_alias( + ffi.Pointer cert, + ffi.Pointer untrustedcerts, + ffi.Pointer> ppcert_chain_list, + ) { + return _ckmc_get_cert_chain_with_alias( + cert, + untrustedcerts, + ppcert_chain_list, + ); + } + + late final _ckmc_get_cert_chain_with_alias_ptr = + _lookup>( + 'ckmc_get_cert_chain_with_alias'); + late final _dart_ckmc_get_cert_chain_with_alias + _ckmc_get_cert_chain_with_alias = _ckmc_get_cert_chain_with_alias_ptr + .asFunction<_dart_ckmc_get_cert_chain_with_alias>(); + + /// @brief Verifies a certificate chain and returns that chain using user-entered, trusted, and untrusted CA certificates. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks If the trusted root certificates are provided as a user input, these certificates do not need to exist in the system's certificate storage. + /// @remarks You must destroy the newly created @a ppcert_chain_list by calling ckmc_cert_list_all_free() if it is no longer needed. + /// @param[in] cert The certificate to be verified + /// @param[in] untrustedcerts The untrusted CA certificates to be used in verifying a certificate chain + /// @param[in] trustedcerts The trusted CA certificates to be used in verifying a certificate chain + /// @param[in] use_trustedsystemcerts The flag indicating the use of the trusted root certificates in the system's certificate storage + /// @param[out] ppcert_chain_list The pointer to a newly created certificate chain's handle \n + /// If an error occurs, @a *ppcert_chain_list will be null + /// @return @c 0 on success and the signature is valid, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_VERIFICATION_FAILED The certificate chain is not valid + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to the error with unknown reason + /// @retval #CKMC_ERROR_INVALID_FORMAT The format of certificate is not valid + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_cert_list_all_free() + int ckmc_get_cert_chain_with_trustedcert( + ffi.Pointer cert, + ffi.Pointer untrustedcerts, + ffi.Pointer trustedcerts, + bool use_trustedsystemcerts, + ffi.Pointer> ppcert_chain_list, + ) { + return _ckmc_get_cert_chain_with_trustedcert( + cert, + untrustedcerts, + trustedcerts, + use_trustedsystemcerts ? 1 : 0, + ppcert_chain_list, + ); + } + + late final _ckmc_get_cert_chain_with_trustedcert_ptr = + _lookup>( + 'ckmc_get_cert_chain_with_trustedcert'); + late final _dart_ckmc_get_cert_chain_with_trustedcert + _ckmc_get_cert_chain_with_trustedcert = + _ckmc_get_cert_chain_with_trustedcert_ptr + .asFunction<_dart_ckmc_get_cert_chain_with_trustedcert>(); + + /// @brief Perform OCSP that checks certificate is whether revoked or not. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/internet + /// @remarks %http://tizen.org/privilege/internet (public level privilege) is required to use this API instead of %http://tizen.org/privilege/keymanager (public level privilege) since 3.0. + /// @param[in] pcert_chain_list Valid certificate chain to perform OCSP check + /// @param[out] ocsp_status The pointer to status result of OCSP check + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @retval #CKMC_ERROR_NOT_SUPPORTED Device needed to run API is not supported + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @pre @a pcert_chain_list is created with ckmc_get_certificate_chain() or + /// ckmc_get_certificate_chain_with_alias(). + /// @see ckmc_get_cert_chain()) + /// @see ckmc_cert_list_all_free() + int ckmc_ocsp_check( + ffi.Pointer pcert_chain_list, + ffi.Pointer ocsp_status, + ) { + return _ckmc_ocsp_check( + pcert_chain_list, + ocsp_status, + ); + } + + late final _ckmc_ocsp_check_ptr = + _lookup>('ckmc_ocsp_check'); + late final _dart_ckmc_ocsp_check _ckmc_ocsp_check = + _ckmc_ocsp_check_ptr.asFunction<_dart_ckmc_ocsp_check>(); + + /// @deprecated Deprecated since @if MOBILE 2.4. @elseif WEARABLE 3.0. @endif [Use ckmc_set_permission() instead] + /// @brief Allows another application to access client's application data. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks Data identified by @a alias should exist. + /// @param[in] alias Data alias for which access will be granted + /// @param[in] accessor Package id of the application that will gain access rights + /// @param[in] granted Rights granted for @a accessor application + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to the error with unknown reason + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_deny_access() + int ckmc_allow_access( + ffi.Pointer alias, + ffi.Pointer accessor, + int granted, + ) { + return _ckmc_allow_access( + alias, + accessor, + granted, + ); + } + + late final _ckmc_allow_access_ptr = + _lookup>('ckmc_allow_access'); + late final _dart_ckmc_allow_access _ckmc_allow_access = + _ckmc_allow_access_ptr.asFunction<_dart_ckmc_allow_access>(); + + /// @brief Allows another application to access client's application data. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks Data identified by @a alias should exist. + /// @param[in] alias Data alias for which access will be granted + /// @param[in] accessor Package id of the application that will gain access rights + /// @param[in] permissions Mask of permissions granted for @a accessor application + /// (#ckmc_permission_e) + /// (previous permission mask will be replaced with the new mask value) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to the error with unknown reason + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + int ckmc_set_permission( + ffi.Pointer alias, + ffi.Pointer accessor, + int permissions, + ) { + return _ckmc_set_permission( + alias, + accessor, + permissions, + ); + } + + late final _ckmc_set_permission_ptr = + _lookup>( + 'ckmc_set_permission'); + late final _dart_ckmc_set_permission _ckmc_set_permission = + _ckmc_set_permission_ptr.asFunction<_dart_ckmc_set_permission>(); + + /// @deprecated Deprecated since @if MOBILE 2.4. @elseif WEARABLE 3.0. @endif [Use ckmc_set_permission() instead] + /// @brief Revokes another application's access to client's application data. + /// @since_tizen 2.3 + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks Data identified by @a alias should exist. + /// @remarks Only access previously granted with ckmc_allow_access can be revoked. + /// @param[in] alias Data alias for which access will be revoked + /// @param[in] accessor Package id of the application that will lose access rights + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid or the @a accessor doesn't have access to @a alias + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to the error with unknown reason + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_allow_access() + /// @see ckmc_set_permission() + int ckmc_deny_access( + ffi.Pointer alias, + ffi.Pointer accessor, + ) { + return _ckmc_deny_access( + alias, + accessor, + ); + } + + late final _ckmc_deny_access_ptr = + _lookup>('ckmc_deny_access'); + late final _dart_ckmc_deny_access _ckmc_deny_access = + _ckmc_deny_access_ptr.asFunction<_dart_ckmc_deny_access>(); + + /// @brief Removes an entry (no matter of type) from the key manager. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks %http://tizen.org/privilege/keymanager (public level privilege) is no longer required to use this API since 3.0. + /// @remarks To remove item, client must have remove permission to the specified item. + /// @remarks The item owner can remove by default. + /// @param[in] alias Item alias to be removed + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to a database error + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_save_key() + /// @see ckmc_save_cert() + /// @see ckmc_save_data() + /// @see ckmc_save_pkcs12() + /// @see ckmc_create_key_pair_rsa() + /// @see ckmc_create_key_pair_dsa() + /// @see ckmc_create_key_pair_ecdsa() + int ckmc_remove_alias( + ffi.Pointer alias, + ) { + return _ckmc_remove_alias( + alias, + ); + } + + late final _ckmc_remove_alias_ptr = + _lookup>('ckmc_remove_alias'); + late final _dart_ckmc_remove_alias _ckmc_remove_alias = + _ckmc_remove_alias_ptr.asFunction<_dart_ckmc_remove_alias>(); + + /// @brief Encrypts data using selected key and algorithm. + /// @since_tizen 3.0 + /// @remarks Key identified by @a key_alias should exist. + /// @param[in] params Algorithm parameter list handle. See #ckmc_param_list_h and + /// #ckmc_algo_type_e for details + /// @param[in] key_alias Alias of the key to be used for encryption + /// @param[in] password The password used in decrypting a key value \n + /// If password of the policy is provided in ckmc_save_key(), the same + /// password should be provided + /// @param[in] decrypted Data to be encrypted. In case of AES algorithm there are no restrictions on the size of data. + /// For RSA the size must be smaller or equal to key size in bytes - 42. + /// Example: for 1024 RSA key the maximum data size is 1024/8 - 42 = 86 + /// @param[out] ppencrypted Encrypted data (some algorithms may return additional information embedded in encrypted data. + /// AES GCM is an example) \n + /// The caller is responsible for freeing @a encrypted with ckmc_buffer_free() + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid (missing or invalid + /// mandatory algorithm parameter, decrypted = NULL, + /// ppencrypted = NULL) + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to the error with unknown reason + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Key with given alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @retval #CKMC_ERROR_AUTHENTICATION_FAILED Key decryption failed because password is incorrect + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_buffer_free() + /// @see ckmc_param_list_new() + /// @see ckmc_param_list_free() + /// @see ckmc_param_list_set_integer() + /// @see ckmc_param_list_set_buffer() + /// @see ckmc_generate_new_params() + /// @see #ckmc_param_list_h + /// @see #ckmc_param_name_e + /// @see #ckmc_algo_type_e + int ckmc_encrypt_data( + ffi.Pointer<__ckmc_param_list> params, + ffi.Pointer key_alias, + ffi.Pointer password, + ckmc_raw_buffer_s decrypted, + ffi.Pointer> ppencrypted, + ) { + return _ckmc_encrypt_data( + params, + key_alias, + password, + decrypted, + ppencrypted, + ); + } + + late final _ckmc_encrypt_data_ptr = + _lookup>('ckmc_encrypt_data'); + late final _dart_ckmc_encrypt_data _ckmc_encrypt_data = + _ckmc_encrypt_data_ptr.asFunction<_dart_ckmc_encrypt_data>(); + + /// @brief Decrypts data using selected key and algorithm. + /// @since_tizen 3.0 + /// @remarks Key identified by @a key_alias should exist. + /// @param[in] params Algorithm parameter list handle. You should use the same parameters that were used for encryption. + /// See #ckmc_param_list_h and #ckmc_algo_type_e for details + /// @param[in] key_alias Alias of the key to be used for encryption + /// @param[in] password The password used in decrypting a key value \n + /// If password of the policy is provided in ckmc_save_key(), the same password should be provided + /// @param[in] encrypted Data to be decrypted (some algorithms may require additional information embedded in encrypted data. AES GCM is an example) + /// @param[out] ppdecrypted Decrypted data \n + /// The caller is responsible for freeing @a decrypted with ckmc_buffer_free() + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CKMC_ERROR_NONE Successful + /// @retval #CKMC_ERROR_INVALID_PARAMETER Input parameter is invalid (missing or invalid + /// mandatory algorithm parameter, encrypted = NULL, + /// ppdecrypted = NULL) + /// @retval #CKMC_ERROR_DB_LOCKED A user key is not loaded in memory (a user is not logged in) + /// @retval #CKMC_ERROR_DB_ERROR Failed due to the error with unknown reason + /// @retval #CKMC_ERROR_DB_ALIAS_UNKNOWN Key with given alias does not exist + /// @retval #CKMC_ERROR_PERMISSION_DENIED Failed to access key manager + /// @retval #CKMC_ERROR_AUTHENTICATION_FAILED Key decryption failed because password is incorrect + /// @pre User is already logged in and the user key is already loaded into memory in plain text form. + /// @see ckmc_buffer_free() + /// @see ckmc_param_list_new() + /// @see ckmc_param_list_free() + /// @see ckmc_param_list_set_integer() + /// @see ckmc_param_list_set_buffer() + /// @see ckmc_generate_new_params() + /// @see #ckmc_param_list_h + /// @see #ckmc_param_name_e + /// @see #ckmc_algo_type_e + int ckmc_decrypt_data( + ffi.Pointer<__ckmc_param_list> params, + ffi.Pointer key_alias, + ffi.Pointer password, + ckmc_raw_buffer_s encrypted, + ffi.Pointer> ppdecrypted, + ) { + return _ckmc_decrypt_data( + params, + key_alias, + password, + encrypted, + ppdecrypted, + ); + } + + late final _ckmc_decrypt_data_ptr = + _lookup>('ckmc_decrypt_data'); + late final _dart_ckmc_decrypt_data _ckmc_decrypt_data = + _ckmc_decrypt_data_ptr.asFunction<_dart_ckmc_decrypt_data>(); + + /// @brief Checks if an application, which calls this function, has permission to use the + /// given privilege. + /// + /// @since_tizen 4.0 + /// + /// @param[in] privilege The privilege that is to be checked. + /// @param[out] result The result of the privilege check. + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #PRIVACY_PRIVILEGE_MANAGER_ERROR_NONE Successful + /// @retval #PRIVACY_PRIVILEGE_MANAGER_ERROR_IO_ERROR I/O error + /// @retval #PRIVACY_PRIVILEGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PRIVACY_PRIVILEGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PRIVACY_PRIVILEGE_MANAGER_ERROR_UNKNOWN Unknown error + int ppm_check_permission( + ffi.Pointer privilege, + ffi.Pointer result, + ) { + return _ppm_check_permission( + privilege, + result, + ); + } + + late final _ppm_check_permission_ptr = + _lookup>( + 'ppm_check_permission'); + late final _dart_ppm_check_permission _ppm_check_permission = + _ppm_check_permission_ptr.asFunction<_dart_ppm_check_permission>(); + + /// @brief Requests a user's response to obtain permission for using the given privilege. + /// + /// @details When this function is called, an underlying service may show an appropriate + /// UI dialogue box (pop-up) with a question about granting the application access + /// to the given privilege. Once a user makes a decision, the service may modify + /// the privacy policy (when it is a definitive decision). After that, the service + /// sends the response back to the application. The possible response values are as follows: + /// #PRIVACY_PRIVILEGE_MANAGER_REQUEST_RESULT_ALLOW_FOREVER\n + /// #PRIVACY_PRIVILEGE_MANAGER_REQUEST_RESULT_DENY_FOREVER\n + /// #PRIVACY_PRIVILEGE_MANAGER_REQUEST_RESULT_DENY_ONCE\n + /// The application receives #PRIVACY_PRIVILEGE_MANAGER_REQUEST_RESULT_DENY_ONCE value after + /// pressing 'Deny' button while not having selected the 'Don't ask again?' checkbox. If the device + /// has the home and back buttons, pressing either of them gives the + /// #PRIVACY_PRIVILEGE_MANAGER_REQUEST_RESULT_DENY_ONCE response. + /// The application is informed about the user's decision by invoking ppm_request_response_cb(). + /// When a privacy policy for the given privilege has already been resolved, no pop-up will + /// be shown and the service will reply immediately with an appropriate result: + /// #PRIVACY_PRIVILEGE_MANAGER_REQUEST_RESULT_ALLOW_FOREVER\n + /// #PRIVACY_PRIVILEGE_MANAGER_REQUEST_RESULT_DENY_FOREVER\n + /// + /// @since_tizen 4.0 + /// + /// @remarks Before calling this function, call ppm_check_permission() to check if the application has + /// permission to use the given privilege. If the result of calling ppm_check_permission() is + /// #PRIVACY_PRIVILEGE_MANAGER_CHECK_RESULT_ASK, the application should call + /// this function to determine access to the privilege. + /// + /// @param[in] privilege The given privilege for which a pop-up must be shown. + /// @param[in] callback The given callback function which will be invoked + /// when the API receives a response. + /// @param[in] user_data User specific data which will be passed to + /// the given callback. + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #PRIVACY_PRIVILEGE_MANAGER_ERROR_NONE Successful + /// @retval #PRIVACY_PRIVILEGE_MANAGER_ERROR_IO_ERROR I/O error + /// @retval #PRIVACY_PRIVILEGE_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PRIVACY_PRIVILEGE_MANAGER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PRIVACY_PRIVILEGE_MANAGER_ERROR_ALREADY_IN_PROGRESS Operation already in progress + /// @retval #PRIVACY_PRIVILEGE_MANAGER_ERROR_UNKNOWN Unknown error + /// + /// @post ppm_request_response_cb() will be invoked. + /// @see ppm_request_response_cb() + int ppm_request_permission( + ffi.Pointer privilege, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _ppm_request_permission( + privilege, + callback, + user_data, + ); + } + + late final _ppm_request_permission_ptr = + _lookup>( + 'ppm_request_permission'); + late final _dart_ppm_request_permission _ppm_request_permission = + _ppm_request_permission_ptr.asFunction<_dart_ppm_request_permission>(); + + /// @brief Gets the display name of the given privilege. + /// @since_tizen @if WEARABLE 2.3.1 @elseif MOBILE 2.3 @endif + /// @remarks @a display_name must be released using free(). + /// @param[in] api_version The API version of the application to get privilege information + /// @param[in] privilege The privilege + /// @param[out] display_name The display name of the privilege + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PRVINFO_ERROR_NONE Successful + /// @retval #PRVINFO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PRVINFO_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #PRVINFO_ERROR_INTERNAL_ERROR Unknown error + int privilege_info_get_display_name( + ffi.Pointer api_version, + ffi.Pointer privilege, + ffi.Pointer> display_name, + ) { + return _privilege_info_get_display_name( + api_version, + privilege, + display_name, + ); + } + + late final _privilege_info_get_display_name_ptr = + _lookup>( + 'privilege_info_get_display_name'); + late final _dart_privilege_info_get_display_name + _privilege_info_get_display_name = _privilege_info_get_display_name_ptr + .asFunction<_dart_privilege_info_get_display_name>(); + + /// @brief Gets the display name of the given privilege. + /// @since_tizen @if WEARABLE 2.3.1 @elseif MOBILE 2.3 @endif + /// @remarks @a display_name must be released using free(). + /// @remarks package_type must be one of followings: PRVINFO_PACKAGE_TYPE_NATIVE, PRVINFO_PACKAGE_TYPE_WEB + /// @param[in] package_type The type of application package + /// @param[in] api_version The API version of the application to get privilege information + /// @param[in] privilege The privilege + /// @param[out] display_name The display name of the privilege + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PRVINFO_ERROR_NONE Successful + /// @retval #PRVINFO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PRVINFO_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #PRVINFO_ERROR_INTERNAL_ERROR Unknown error + int privilege_info_get_display_name_by_pkgtype( + ffi.Pointer package_type, + ffi.Pointer api_version, + ffi.Pointer privilege, + ffi.Pointer> display_name, + ) { + return _privilege_info_get_display_name_by_pkgtype( + package_type, + api_version, + privilege, + display_name, + ); + } + + late final _privilege_info_get_display_name_by_pkgtype_ptr = _lookup< + ffi.NativeFunction<_c_privilege_info_get_display_name_by_pkgtype>>( + 'privilege_info_get_display_name_by_pkgtype'); + late final _dart_privilege_info_get_display_name_by_pkgtype + _privilege_info_get_display_name_by_pkgtype = + _privilege_info_get_display_name_by_pkgtype_ptr + .asFunction<_dart_privilege_info_get_display_name_by_pkgtype>(); + + /// @brief Gets the description of the given privilege. + /// @since_tizen @if WEARABLE 2.3.1 @elseif MOBILE 2.3 @endif + /// @remarks @a description must be released using free(). + /// @param[in] api_version The API version of the application to get privilege information + /// @param[in] privilege The privilege + /// @param[out] description The description of the privilege + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PRVINFO_ERROR_NONE Successful + /// @retval #PRVINFO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PRVINFO_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #PRVINFO_ERROR_INTERNAL_ERROR Unknown error + int privilege_info_get_description( + ffi.Pointer api_version, + ffi.Pointer privilege, + ffi.Pointer> description, + ) { + return _privilege_info_get_description( + api_version, + privilege, + description, + ); + } + + late final _privilege_info_get_description_ptr = + _lookup>( + 'privilege_info_get_description'); + late final _dart_privilege_info_get_description + _privilege_info_get_description = _privilege_info_get_description_ptr + .asFunction<_dart_privilege_info_get_description>(); + + /// @brief Gets the description of the given privilege. + /// @since_tizen @if WEARABLE 2.3.1 @elseif MOBILE 2.3 @endif + /// @remarks @a description must be released using free(). + /// @remarks package_type must be one of followings: PRVINFO_PACKAGE_TYPE_NATIVE, PRVINFO_PACKAGE_TYPE_WEB + /// @param[in] package_type The type of application package + /// @param[in] api_version The API version of the application to get privilege information + /// @param[in] privilege The privilege + /// @param[out] description The description of the privilege + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PRVINFO_ERROR_NONE Successful + /// @retval #PRVINFO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PRVINFO_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #PRVINFO_ERROR_INTERNAL_ERROR Unknown error + int privilege_info_get_description_by_pkgtype( + ffi.Pointer package_type, + ffi.Pointer api_version, + ffi.Pointer privilege, + ffi.Pointer> description, + ) { + return _privilege_info_get_description_by_pkgtype( + package_type, + api_version, + privilege, + description, + ); + } + + late final _privilege_info_get_description_by_pkgtype_ptr = + _lookup>( + 'privilege_info_get_description_by_pkgtype'); + late final _dart_privilege_info_get_description_by_pkgtype + _privilege_info_get_description_by_pkgtype = + _privilege_info_get_description_by_pkgtype_ptr + .asFunction<_dart_privilege_info_get_description_by_pkgtype>(); + + /// @brief Gets the display name of the privacy group in which the given privilege is included. + /// @since_tizen 3.0 + /// @remarks @a privacy_name must be released using free(). + /// @remarks @a privilege must be privacy related, otherwise #PRVINFO_ERROR_INVALID_PARAMETER is returned. + /// @param[in] privilege The privilege + /// @param[out] privacy_name The privacy group's display name that the given privilege is included in + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PRVINFO_ERROR_NONE Successful + /// @retval #PRVINFO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PRVINFO_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #PRVINFO_ERROR_INTERNAL_ERROR Unknown error + int privilege_info_get_privacy_display_name( + ffi.Pointer privilege, + ffi.Pointer> privacy_name, + ) { + return _privilege_info_get_privacy_display_name( + privilege, + privacy_name, + ); + } + + late final _privilege_info_get_privacy_display_name_ptr = + _lookup>( + 'privilege_info_get_privacy_display_name'); + late final _dart_privilege_info_get_privacy_display_name + _privilege_info_get_privacy_display_name = + _privilege_info_get_privacy_display_name_ptr + .asFunction<_dart_privilege_info_get_privacy_display_name>(); + + /// @brief Gets the status of the given privacy related privilege. + /// @since_tizen 3.0 + /// @remarks @a privilege must be privacy related, otherwise #PRVINFO_ERROR_INVALID_PARAMETER is returned. + /// In case of errors, @a status is set to @c true. + /// @param[in] privilege The privilege + /// @param[out] status @c true if the privilege is on, + /// and @c false if the privilege is off + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PRVINFO_ERROR_NONE Successful + /// @retval #PRVINFO_ERROR_INVALID_PARAMETER Invalid function parameter + /// @retval #PRVINFO_ERROR_INTERNAL_ERROR Unknown error + int privilege_info_get_privacy_privilege_status( + ffi.Pointer privilege, + ffi.Pointer status, + ) { + return _privilege_info_get_privacy_privilege_status( + privilege, + status, + ); + } + + late final _privilege_info_get_privacy_privilege_status_ptr = _lookup< + ffi.NativeFunction<_c_privilege_info_get_privacy_privilege_status>>( + 'privilege_info_get_privacy_privilege_status'); + late final _dart_privilege_info_get_privacy_privilege_status + _privilege_info_get_privacy_privilege_status = + _privilege_info_get_privacy_privilege_status_ptr + .asFunction<_dart_privilege_info_get_privacy_privilege_status>(); + + /// @brief Initializes the library. Must be called before any other crypto + /// function. Should be called once in each thread that uses yaca. + /// + /// @since_tizen 3.0 + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_cleanup() + int yaca_initialize() { + return _yaca_initialize(); + } + + late final _yaca_initialize_ptr = + _lookup>('yaca_initialize'); + late final _dart_yaca_initialize _yaca_initialize = + _yaca_initialize_ptr.asFunction<_dart_yaca_initialize>(); + + /// @brief Cleans up the library. Must be called before exiting the thread that + /// called yaca_initialize(). + /// + /// @since_tizen 3.0 + /// + /// @see yaca_initialize() + void yaca_cleanup() { + return _yaca_cleanup(); + } + + late final _yaca_cleanup_ptr = + _lookup>('yaca_cleanup'); + late final _dart_yaca_cleanup _yaca_cleanup = + _yaca_cleanup_ptr.asFunction<_dart_yaca_cleanup>(); + + /// @brief Allocates the memory. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a memory should be freed using yaca_free(). + /// + /// @param[in] size Size of the allocation (bytes) + /// @param[out] memory Allocated memory + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// + /// @see yaca_zalloc() + /// @see yaca_realloc() + /// @see yaca_free() + int yaca_malloc( + int size, + ffi.Pointer> memory, + ) { + return _yaca_malloc( + size, + memory, + ); + } + + late final _yaca_malloc_ptr = + _lookup>('yaca_malloc'); + late final _dart_yaca_malloc _yaca_malloc = + _yaca_malloc_ptr.asFunction<_dart_yaca_malloc>(); + + /// @brief Allocates the zeroed memory. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a memory should be freed using yaca_free(). + /// + /// @param[in] size Size of the allocation (bytes) + /// @param[out] memory Allocated memory + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// + /// @see yaca_malloc() + /// @see yaca_realloc() + /// @see yaca_free() + int yaca_zalloc( + int size, + ffi.Pointer> memory, + ) { + return _yaca_zalloc( + size, + memory, + ); + } + + late final _yaca_zalloc_ptr = + _lookup>('yaca_zalloc'); + late final _dart_yaca_zalloc _yaca_zalloc = + _yaca_zalloc_ptr.asFunction<_dart_yaca_zalloc>(); + + /// @brief Re-allocates the memory. + /// + /// @since_tizen 3.0 + /// + /// @remarks In case of failure the function doesn't free the memory pointed by @a memory. + /// + /// @remarks If @a memory is NULL then the call is equivalent to yaca_malloc(). + /// + /// @remarks If the function fails the contents of @a memory will be left unchanged. + /// + /// @remarks The @a memory should be freed using yaca_free(). + /// + /// @param[in] size Size of the new allocation (bytes) + /// @param[in,out] memory Memory to be reallocated + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// + /// @see yaca_malloc() + /// @see yaca_zalloc() + /// @see yaca_free() + int yaca_realloc( + int size, + ffi.Pointer> memory, + ) { + return _yaca_realloc( + size, + memory, + ); + } + + late final _yaca_realloc_ptr = + _lookup>('yaca_realloc'); + late final _dart_yaca_realloc _yaca_realloc = + _yaca_realloc_ptr.asFunction<_dart_yaca_realloc>(); + + /// @brief Frees the memory allocated by yaca_malloc(), yaca_zalloc(), + /// yaca_realloc() or one of the cryptographic operations. + /// + /// @since_tizen 3.0 + /// + /// @param[in] memory Pointer to the memory to be freed + /// + /// @see yaca_malloc() + /// @see yaca_zalloc() + /// @see yaca_realloc() + void yaca_free( + ffi.Pointer memory, + ) { + return _yaca_free( + memory, + ); + } + + late final _yaca_free_ptr = + _lookup>('yaca_free'); + late final _dart_yaca_free _yaca_free = + _yaca_free_ptr.asFunction<_dart_yaca_free>(); + + /// @brief Safely compares first @a len bytes of two buffers. + /// + /// @since_tizen 3.0 + /// + /// @param[in] first Pointer to the first buffer + /// @param[in] second Pointer to the second buffer + /// @param[in] len Length to compare + /// + /// @return #YACA_ERROR_NONE when buffers are equal otherwise #YACA_ERROR_DATA_MISMATCH + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0) + /// @retval #YACA_ERROR_DATA_MISMATCH Buffers are different + int yaca_memcmp( + ffi.Pointer first, + ffi.Pointer second, + int len, + ) { + return _yaca_memcmp( + first, + second, + len, + ); + } + + late final _yaca_memcmp_ptr = + _lookup>('yaca_memcmp'); + late final _dart_yaca_memcmp _yaca_memcmp = + _yaca_memcmp_ptr.asFunction<_dart_yaca_memcmp>(); + + /// @brief Generates random data. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] data Pointer to the memory to be randomized + /// @param[in] data_len Length of the memory to be randomized + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0) + /// @retval #YACA_ERROR_INTERNAL Internal error + int yaca_randomize_bytes( + ffi.Pointer data, + int data_len, + ) { + return _yaca_randomize_bytes( + data, + data_len, + ); + } + + late final _yaca_randomize_bytes_ptr = + _lookup>( + 'yaca_randomize_bytes'); + late final _dart_yaca_randomize_bytes _yaca_randomize_bytes = + _yaca_randomize_bytes_ptr.asFunction<_dart_yaca_randomize_bytes>(); + + /// @brief Sets the non-standard context properties. Can only be called on an + /// initialized context. + /// + /// @remarks The @a value has to be of type appropriate for given property. See #yaca_property_e + /// for details on corresponding types. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] ctx Previously initialized crypto context + /// @param[in] property Property to be set + /// @param[in] value Property value + /// @param[in] value_len Length of the property value + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0, + /// invalid @a ctx or @a property) + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_property_e + /// @see yaca_context_get_property() + int yaca_context_set_property( + ffi.Pointer ctx, + int property, + ffi.Pointer value, + int value_len, + ) { + return _yaca_context_set_property( + ctx, + property, + value, + value_len, + ); + } + + late final _yaca_context_set_property_ptr = + _lookup>( + 'yaca_context_set_property'); + late final _dart_yaca_context_set_property _yaca_context_set_property = + _yaca_context_set_property_ptr + .asFunction<_dart_yaca_context_set_property>(); + + /// @brief Returns the non-standard context properties. Can only be called on an + /// initialized context. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a value should be freed using yaca_free(). + /// + /// @remarks The @a value has to be of type appropriate for given property. See #yaca_property_e + /// for details on corresponding types. + /// + /// @remarks The @a value_len can be NULL if returned @a value is a single object + /// (i.e. not an array/buffer). + /// + /// @param[in] ctx Previously initialized crypto context + /// @param[in] property Property to be read + /// @param[out] value Copy of the property value + /// @param[out] value_len Length of the property value will be returned here + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a ctx or @a property) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_property_e + /// @see yaca_context_set_property() + /// @see yaca_free() + int yaca_context_get_property( + ffi.Pointer ctx, + int property, + ffi.Pointer> value, + ffi.Pointer value_len, + ) { + return _yaca_context_get_property( + ctx, + property, + value, + value_len, + ); + } + + late final _yaca_context_get_property_ptr = + _lookup>( + 'yaca_context_get_property'); + late final _dart_yaca_context_get_property _yaca_context_get_property = + _yaca_context_get_property_ptr + .asFunction<_dart_yaca_context_get_property>(); + + /// @brief Returns the minimum required size of the output buffer for a single crypto function call. + /// + /// @since_tizen 3.0 + /// + /// @remarks This function should be used to learn the required size of the output buffer + /// for a single function call (eg. *_update or *_finalize). The actual output length + /// (number of bytes that has been used) will be returned by the function call itself. + /// + /// @remarks In case the function call has no output (e.g. yaca_sign_update(), + /// yaca_digest_update()), there is no need to use this function. + /// + /// @remarks In case the function call has no input (eg. *_finalize), the value of + /// @a input_len has to be set to 0. + /// + /// @param[in] ctx Previously initialized crypto context + /// @param[in] input_len Length of the input data to be processed + /// @param[out] output_len Required length of the output + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a ctx or too big @a input_len) + /// @retval #YACA_ERROR_INTERNAL Internal error + int yaca_context_get_output_length( + ffi.Pointer ctx, + int input_len, + ffi.Pointer output_len, + ) { + return _yaca_context_get_output_length( + ctx, + input_len, + output_len, + ); + } + + late final _yaca_context_get_output_length_ptr = + _lookup>( + 'yaca_context_get_output_length'); + late final _dart_yaca_context_get_output_length + _yaca_context_get_output_length = _yaca_context_get_output_length_ptr + .asFunction<_dart_yaca_context_get_output_length>(); + + /// @brief Destroys the crypto context. Must be called on all contexts that are + /// no longer used. Passing #YACA_CONTEXT_NULL is allowed. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] ctx Crypto context + /// + /// @see #yaca_context_h + void yaca_context_destroy( + ffi.Pointer ctx, + ) { + return _yaca_context_destroy( + ctx, + ); + } + + late final _yaca_context_destroy_ptr = + _lookup>( + 'yaca_context_destroy'); + late final _dart_yaca_context_destroy _yaca_context_destroy = + _yaca_context_destroy_ptr.asFunction<_dart_yaca_context_destroy>(); + + /// @brief Returns the recommended/default length of the Initialization Vector + /// for a given encryption configuration. + /// + /// @since_tizen 3.0 + /// + /// @remarks If returned @a iv_bit_len equals 0 that means that for this + /// specific algorithm and its parameters Initialization Vector is not used. + /// + /// @param[in] algo Encryption algorithm + /// @param[in] bcm Chain mode + /// @param[in] key_bit_len Key length in bits + /// @param[out] iv_bit_len Recommended Initialization Vector length in bits + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a algo, @a bcm or @a key_bit_len) + /// @retval #YACA_ERROR_INTERNAL Internal error + int yaca_encrypt_get_iv_bit_length( + int algo, + int bcm, + int key_bit_len, + ffi.Pointer iv_bit_len, + ) { + return _yaca_encrypt_get_iv_bit_length( + algo, + bcm, + key_bit_len, + iv_bit_len, + ); + } + + late final _yaca_encrypt_get_iv_bit_length_ptr = + _lookup>( + 'yaca_encrypt_get_iv_bit_length'); + late final _dart_yaca_encrypt_get_iv_bit_length + _yaca_encrypt_get_iv_bit_length = _yaca_encrypt_get_iv_bit_length_ptr + .asFunction<_dart_yaca_encrypt_get_iv_bit_length>(); + + /// @brief Initializes an encryption context. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a ctx should be released using yaca_context_destroy(). + /// + /// @param[out] ctx Newly created context + /// @param[in] algo Encryption algorithm that will be used + /// @param[in] bcm Chaining mode that will be used + /// @param[in] sym_key Symmetric key that will be used + /// @param[in] iv Initialization Vector that will be used + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a algo, @a bcm, @a sym_key or @a iv) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_encrypt_algorithm_e + /// @see #yaca_block_cipher_mode_e + /// @see yaca_encrypt_update() + /// @see yaca_encrypt_finalize() + /// @see yaca_context_destroy() + int yaca_encrypt_initialize( + ffi.Pointer> ctx, + int algo, + int bcm, + ffi.Pointer sym_key, + ffi.Pointer iv, + ) { + return _yaca_encrypt_initialize( + ctx, + algo, + bcm, + sym_key, + iv, + ); + } + + late final _yaca_encrypt_initialize_ptr = + _lookup>( + 'yaca_encrypt_initialize'); + late final _dart_yaca_encrypt_initialize _yaca_encrypt_initialize = + _yaca_encrypt_initialize_ptr.asFunction<_dart_yaca_encrypt_initialize>(); + + /// @brief Encrypts chunk of the data. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] ctx Context created by yaca_encrypt_initialize() + /// @param[in] plaintext Plaintext to be encrypted + /// @param[in] plaintext_len Length of the plaintext + /// @param[out] ciphertext Buffer for the encrypted data + /// (must be allocated by client, see yaca_context_get_output_length()) + /// @param[out] ciphertext_len Length of the encrypted data, + /// actual number of bytes written will be returned here + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0, + /// invalid @a ctx) + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_encrypt_initialize() + /// @see yaca_encrypt_finalize() + /// @see yaca_context_get_output_length() + int yaca_encrypt_update( + ffi.Pointer ctx, + ffi.Pointer plaintext, + int plaintext_len, + ffi.Pointer ciphertext, + ffi.Pointer ciphertext_len, + ) { + return _yaca_encrypt_update( + ctx, + plaintext, + plaintext_len, + ciphertext, + ciphertext_len, + ); + } + + late final _yaca_encrypt_update_ptr = + _lookup>( + 'yaca_encrypt_update'); + late final _dart_yaca_encrypt_update _yaca_encrypt_update = + _yaca_encrypt_update_ptr.asFunction<_dart_yaca_encrypt_update>(); + + /// @brief Encrypts the final chunk of the data. + /// + /// @remarks Skipping yaca_encrypt_update() and calling only yaca_encrypt_finalize() will produce an + /// encryption of an empty message. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] ctx A valid encrypt context + /// @param[out] ciphertext Final piece of the encrypted data + /// (must be allocated by client, see yaca_context_get_output_length()) + /// @param[out] ciphertext_len Length of the final piece, + /// actual number of bytes written will be returned here + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a ctx) + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_encrypt_initialize() + /// @see yaca_encrypt_update() + /// @see yaca_context_get_output_length() + int yaca_encrypt_finalize( + ffi.Pointer ctx, + ffi.Pointer ciphertext, + ffi.Pointer ciphertext_len, + ) { + return _yaca_encrypt_finalize( + ctx, + ciphertext, + ciphertext_len, + ); + } + + late final _yaca_encrypt_finalize_ptr = + _lookup>( + 'yaca_encrypt_finalize'); + late final _dart_yaca_encrypt_finalize _yaca_encrypt_finalize = + _yaca_encrypt_finalize_ptr.asFunction<_dart_yaca_encrypt_finalize>(); + + /// @brief Initializes an decryption context. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a ctx should be released using yaca_context_destroy(). + /// + /// @param[out] ctx Newly created context + /// @param[in] algo Encryption algorithm that was used to encrypt the data + /// @param[in] bcm Chaining mode that was used to encrypt the data + /// @param[in] sym_key Symmetric key that was used to encrypt the data + /// @param[in] iv Initialization Vector that was used to encrypt the data + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a algo, @a bcm, @a sym_key or @a iv) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_encrypt_algorithm_e + /// @see #yaca_block_cipher_mode_e + /// @see yaca_decrypt_update() + /// @see yaca_decrypt_finalize() + /// @see yaca_context_destroy() + int yaca_decrypt_initialize( + ffi.Pointer> ctx, + int algo, + int bcm, + ffi.Pointer sym_key, + ffi.Pointer iv, + ) { + return _yaca_decrypt_initialize( + ctx, + algo, + bcm, + sym_key, + iv, + ); + } + + late final _yaca_decrypt_initialize_ptr = + _lookup>( + 'yaca_decrypt_initialize'); + late final _dart_yaca_decrypt_initialize _yaca_decrypt_initialize = + _yaca_decrypt_initialize_ptr.asFunction<_dart_yaca_decrypt_initialize>(); + + /// @brief Decrypts chunk of the data. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] ctx Context created by yaca_decrypt_initialize() + /// @param[in] ciphertext Ciphertext to be decrypted + /// @param[in] ciphertext_len Length of the ciphertext + /// @param[out] plaintext Buffer for the decrypted data + /// (must be allocated by client, see yaca_context_get_output_length()) + /// @param[out] plaintext_len Length of the decrypted data, + /// actual number of bytes written will be returned here + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0, + /// invalid @a ctx), wrong #YACA_PROPERTY_CCM_AAD or + /// wrong #YACA_PROPERTY_CCM_TAG was used + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_decrypt_initialize() + /// @see yaca_decrypt_finalize() + /// @see yaca_context_get_output_length() + int yaca_decrypt_update( + ffi.Pointer ctx, + ffi.Pointer ciphertext, + int ciphertext_len, + ffi.Pointer plaintext, + ffi.Pointer plaintext_len, + ) { + return _yaca_decrypt_update( + ctx, + ciphertext, + ciphertext_len, + plaintext, + plaintext_len, + ); + } + + late final _yaca_decrypt_update_ptr = + _lookup>( + 'yaca_decrypt_update'); + late final _dart_yaca_decrypt_update _yaca_decrypt_update = + _yaca_decrypt_update_ptr.asFunction<_dart_yaca_decrypt_update>(); + + /// @brief Decrypts the final chunk of the data. + /// + /// @remarks Skipping yaca_decrypt_update() and calling only yaca_decrypt_finalize() will produce a + /// decryption of an empty ciphertext. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] ctx A valid decrypt context + /// @param[out] plaintext Final piece of the decrypted data + /// (must be allocated by client, see yaca_context_get_output_length()) + /// @param[out] plaintext_len Length of the final piece, + /// actual number of bytes written will be returned here + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a ctx), wrong #YACA_PROPERTY_GCM_AAD or + /// wrong #YACA_PROPERTY_GCM_TAG was used + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_decrypt_initialize() + /// @see yaca_decrypt_update() + /// @see yaca_context_get_output_length() + int yaca_decrypt_finalize( + ffi.Pointer ctx, + ffi.Pointer plaintext, + ffi.Pointer plaintext_len, + ) { + return _yaca_decrypt_finalize( + ctx, + plaintext, + plaintext_len, + ); + } + + late final _yaca_decrypt_finalize_ptr = + _lookup>( + 'yaca_decrypt_finalize'); + late final _dart_yaca_decrypt_finalize _yaca_decrypt_finalize = + _yaca_decrypt_finalize_ptr.asFunction<_dart_yaca_decrypt_finalize>(); + + /// @brief Initializes an asymmetric encryption context and generates + /// symmetric key and Initialization Vector. + /// + /// @remarks Generated symmetric key is encrypted with public key, + /// so can be only used with yaca_open_initialize(). It can be exported, + /// but after import it can be only used with yaca_open_initialize() as well. + /// + /// @remarks The @a ctx should be released using yaca_context_destroy(). + /// + /// @remarks The @a pub_key must be #YACA_KEY_TYPE_RSA_PUB. + /// + /// @remarks The @a sym_key_bit_len must be at least 88 bits shorter than the @a pub_key bit length. + /// + /// @remarks The @a sym_key should be released using yaca_key_destroy(). + /// + /// @remarks The @a iv should be released using yaca_key_destroy(). + /// + /// @since_tizen 3.0 + /// + /// @param[out] ctx Newly created context + /// @param[in] pub_key Public key of the peer that will receive the encrypted data + /// @param[in] algo Symmetric algorithm that will be used + /// @param[in] bcm Block chaining mode for the symmetric algorithm + /// @param[in] sym_key_bit_len Symmetric key length (in bits) that will be generated + /// @param[out] sym_key Generated symmetric key that will be used, + /// it is encrypted with peer's public key + /// @param[out] iv Generated Initialization Vector that will be used + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a algo, @a bcm, @a sym_key_bit_len or @a pub_key) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_encrypt_algorithm_e + /// @see #yaca_block_cipher_mode_e + /// @see #yaca_key_bit_length_e + /// @see yaca_seal_update() + /// @see yaca_seal_finalize() + /// @see yaca_open_initialize() + /// @see yaca_key_destroy() + /// @see yaca_context_destroy() + int yaca_seal_initialize( + ffi.Pointer> ctx, + ffi.Pointer pub_key, + int algo, + int bcm, + int sym_key_bit_len, + ffi.Pointer> sym_key, + ffi.Pointer> iv, + ) { + return _yaca_seal_initialize( + ctx, + pub_key, + algo, + bcm, + sym_key_bit_len, + sym_key, + iv, + ); + } + + late final _yaca_seal_initialize_ptr = + _lookup>( + 'yaca_seal_initialize'); + late final _dart_yaca_seal_initialize _yaca_seal_initialize = + _yaca_seal_initialize_ptr.asFunction<_dart_yaca_seal_initialize>(); + + /// @brief Encrypts piece of the data. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] ctx Context created by yaca_seal_initialize() + /// @param[in] plaintext Plaintext to be encrypted + /// @param[in] plaintext_len Length of the plaintext + /// @param[out] ciphertext Buffer for the encrypted data + /// (must be allocated by client, see yaca_context_get_output_length()) + /// @param[out] ciphertext_len Length of the encrypted data, + /// actual number of bytes written will be returned here + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0, + /// invalid @a ctx) + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_seal_initialize() + /// @see yaca_seal_finalize() + /// @see yaca_context_get_output_length() + int yaca_seal_update( + ffi.Pointer ctx, + ffi.Pointer plaintext, + int plaintext_len, + ffi.Pointer ciphertext, + ffi.Pointer ciphertext_len, + ) { + return _yaca_seal_update( + ctx, + plaintext, + plaintext_len, + ciphertext, + ciphertext_len, + ); + } + + late final _yaca_seal_update_ptr = + _lookup>('yaca_seal_update'); + late final _dart_yaca_seal_update _yaca_seal_update = + _yaca_seal_update_ptr.asFunction<_dart_yaca_seal_update>(); + + /// @brief Encrypts the final piece of the data. + /// + /// @remarks Skipping yaca_seal_update() and calling only yaca_seal_finalize() will produce an + /// encryption of an empty message. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] ctx A valid seal context + /// @param[out] ciphertext Final piece of the encrypted data + /// (must be allocated by client, see yaca_context_get_output_length()) + /// @param[out] ciphertext_len Length of the final piece, + /// actual number of bytes written will be returned here + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a ctx) + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_seal_initialize() + /// @see yaca_seal_update() + /// @see yaca_context_get_output_length() + int yaca_seal_finalize( + ffi.Pointer ctx, + ffi.Pointer ciphertext, + ffi.Pointer ciphertext_len, + ) { + return _yaca_seal_finalize( + ctx, + ciphertext, + ciphertext_len, + ); + } + + late final _yaca_seal_finalize_ptr = + _lookup>('yaca_seal_finalize'); + late final _dart_yaca_seal_finalize _yaca_seal_finalize = + _yaca_seal_finalize_ptr.asFunction<_dart_yaca_seal_finalize>(); + + /// @brief Initializes an asymmetric decryption context. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a ctx should be released using yaca_context_destroy(). + /// + /// @remarks The @a prv_key must be #YACA_KEY_TYPE_RSA_PRIV. + /// + /// @param[out] ctx Newly created context + /// @param[in] prv_key Private key, part of the pair that was used for the encryption + /// @param[in] algo Symmetric algorithm that was used for the encryption + /// @param[in] bcm Block chaining mode for the symmetric algorithm + /// @param[in] sym_key_bit_len Symmetric key length (in bits) that was used for the encryption + /// @param[in] sym_key Symmetric key, encrypted with the public key, + /// that was used to encrypt the data + /// @param[in] iv Initialization Vector that was used for the encryption + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, invalid + /// @a algo, @a bcm, @a sym_key_bit_len, @a prv_key, + /// @a sym_key or @a iv) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_encrypt_algorithm_e + /// @see #yaca_block_cipher_mode_e + /// @see #yaca_key_bit_length_e + /// @see yaca_open_update() + /// @see yaca_open_finalize() + /// @see yaca_context_destroy() + int yaca_open_initialize( + ffi.Pointer> ctx, + ffi.Pointer prv_key, + int algo, + int bcm, + int sym_key_bit_len, + ffi.Pointer sym_key, + ffi.Pointer iv, + ) { + return _yaca_open_initialize( + ctx, + prv_key, + algo, + bcm, + sym_key_bit_len, + sym_key, + iv, + ); + } + + late final _yaca_open_initialize_ptr = + _lookup>( + 'yaca_open_initialize'); + late final _dart_yaca_open_initialize _yaca_open_initialize = + _yaca_open_initialize_ptr.asFunction<_dart_yaca_open_initialize>(); + + /// @brief Decrypts piece of the data. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] ctx Context created by yaca_open_initialize() + /// @param[in] ciphertext Ciphertext to be decrypted + /// @param[in] ciphertext_len Length of the ciphertext + /// @param[out] plaintext Buffer for the decrypted data + /// (must be allocated by client, see yaca_context_get_output_length()) + /// @param[out] plaintext_len Length of the decrypted data, + /// actual number of bytes written will be returned here + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0, + /// invalid @a ctx), wrong #YACA_PROPERTY_CCM_AAD or + /// wrong #YACA_PROPERTY_CCM_TAG was used + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_open_initialize() + /// @see yaca_open_finalize() + /// @see yaca_context_get_output_length() + int yaca_open_update( + ffi.Pointer ctx, + ffi.Pointer ciphertext, + int ciphertext_len, + ffi.Pointer plaintext, + ffi.Pointer plaintext_len, + ) { + return _yaca_open_update( + ctx, + ciphertext, + ciphertext_len, + plaintext, + plaintext_len, + ); + } + + late final _yaca_open_update_ptr = + _lookup>('yaca_open_update'); + late final _dart_yaca_open_update _yaca_open_update = + _yaca_open_update_ptr.asFunction<_dart_yaca_open_update>(); + + /// @brief Decrypts last chunk of sealed message. + /// + /// @remarks Skipping yaca_open_update() and calling only yaca_open_finalize() will produce a + /// decryption of an empty ciphertext. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] ctx A valid open context + /// @param[out] plaintext Final piece of the decrypted data + /// (must be allocated by client, see yaca_context_get_output_length()) + /// @param[out] plaintext_len Length of the final piece, + /// actual number of bytes written will be returned here + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a ctx), wrong #YACA_PROPERTY_GCM_AAD or + /// wrong #YACA_PROPERTY_GCM_TAG was used + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_open_initialize() + /// @see yaca_open_update() + /// @see yaca_context_get_output_length() + int yaca_open_finalize( + ffi.Pointer ctx, + ffi.Pointer plaintext, + ffi.Pointer plaintext_len, + ) { + return _yaca_open_finalize( + ctx, + plaintext, + plaintext_len, + ); + } + + late final _yaca_open_finalize_ptr = + _lookup>('yaca_open_finalize'); + late final _dart_yaca_open_finalize _yaca_open_finalize = + _yaca_open_finalize_ptr.asFunction<_dart_yaca_open_finalize>(); + + /// @brief Initializes a signature context for asymmetric signatures. + /// + /// @since_tizen 3.0 + /// + /// @remarks For verification use yaca_verify_initialize(), yaca_verify_update() and + /// yaca_verify_finalize() functions with matching public key. + /// + /// @remarks For RSA operations the default padding used is #YACA_PADDING_PKCS1. It can be + /// changed using yaca_context_set_property() with #YACA_PROPERTY_PADDING. + /// + /// @remarks For #YACA_DIGEST_SHA384 and #YACA_DIGEST_SHA512 the RSA key size must be bigger than + /// #YACA_KEY_LENGTH_512BIT. + /// + /// @remarks Using of #YACA_DIGEST_MD5 algorithm for DSA and ECDSA operations is prohibited. + /// + /// @remarks Using of #YACA_DIGEST_MD5 or #YACA_DIGEST_SHA224 with #YACA_PADDING_X931 is prohibited. + /// + /// @remarks The @a ctx should be released using yaca_context_destroy(). + /// + /// @param[out] ctx Newly created context + /// @param[in] algo Digest algorithm that will be used + /// @param[in] prv_key Private key that will be used, algorithm is deduced based + /// on key type, supported key types: + /// - #YACA_KEY_TYPE_RSA_PRIV, + /// - #YACA_KEY_TYPE_DSA_PRIV, + /// - #YACA_KEY_TYPE_EC_PRIV + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a algo or @a prv_key) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_key_type_e + /// @see #yaca_digest_algorithm_e + /// @see #yaca_padding_e + /// @see yaca_context_set_property() + /// @see yaca_sign_update() + /// @see yaca_sign_finalize() + /// @see yaca_verify_initialize() + /// @see yaca_verify_update() + /// @see yaca_verify_finalize() + /// @see yaca_context_destroy() + int yaca_sign_initialize( + ffi.Pointer> ctx, + int algo, + ffi.Pointer prv_key, + ) { + return _yaca_sign_initialize( + ctx, + algo, + prv_key, + ); + } + + late final _yaca_sign_initialize_ptr = + _lookup>( + 'yaca_sign_initialize'); + late final _dart_yaca_sign_initialize _yaca_sign_initialize = + _yaca_sign_initialize_ptr.asFunction<_dart_yaca_sign_initialize>(); + + /// @brief Initializes a signature context for HMAC. + /// + /// @since_tizen 3.0 + /// + /// @remarks For verification, calculate message HMAC and compare with received MAC using + /// yaca_memcmp(). + /// + /// @remarks The @a ctx should be released using yaca_context_destroy(). + /// + /// @param[out] ctx Newly created context + /// @param[in] algo Digest algorithm that will be used + /// @param[in] sym_key Symmetric key that will be used, supported key types: + /// - #YACA_KEY_TYPE_SYMMETRIC, + /// - #YACA_KEY_TYPE_DES + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a algo or @a sym_key) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_key_type_e + /// @see #yaca_digest_algorithm_e + /// @see yaca_sign_update() + /// @see yaca_sign_finalize() + /// @see yaca_memcmp() + /// @see yaca_context_destroy() + int yaca_sign_initialize_hmac( + ffi.Pointer> ctx, + int algo, + ffi.Pointer sym_key, + ) { + return _yaca_sign_initialize_hmac( + ctx, + algo, + sym_key, + ); + } + + late final _yaca_sign_initialize_hmac_ptr = + _lookup>( + 'yaca_sign_initialize_hmac'); + late final _dart_yaca_sign_initialize_hmac _yaca_sign_initialize_hmac = + _yaca_sign_initialize_hmac_ptr + .asFunction<_dart_yaca_sign_initialize_hmac>(); + + /// @brief Initializes a signature context for CMAC. + /// + /// @since_tizen 3.0 + /// + /// @remarks For verification, calculate message CMAC and compare with received MAC using + /// yaca_memcmp(). + /// + /// @remarks The @a ctx should be released using yaca_context_destroy(). + /// + /// @param[out] ctx Newly created context + /// @param[in] algo Encryption algorithm that will be used + /// @param[in] sym_key Symmetric key that will be used, supported key types: + /// - #YACA_KEY_TYPE_SYMMETRIC, + /// - #YACA_KEY_TYPE_DES + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a algo or @a sym_key) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_key_type_e + /// @see #yaca_encrypt_algorithm_e + /// @see yaca_sign_update() + /// @see yaca_sign_finalize() + /// @see yaca_memcmp() + /// @see yaca_context_destroy() + int yaca_sign_initialize_cmac( + ffi.Pointer> ctx, + int algo, + ffi.Pointer sym_key, + ) { + return _yaca_sign_initialize_cmac( + ctx, + algo, + sym_key, + ); + } + + late final _yaca_sign_initialize_cmac_ptr = + _lookup>( + 'yaca_sign_initialize_cmac'); + late final _dart_yaca_sign_initialize_cmac _yaca_sign_initialize_cmac = + _yaca_sign_initialize_cmac_ptr + .asFunction<_dart_yaca_sign_initialize_cmac>(); + + /// @brief Feeds the message into the digital signature or MAC algorithm. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] ctx Context created by yaca_sign_initialize(), + /// yaca_sign_initialize_hmac() or yaca_sign_initialize_cmac() + /// @param[in] message Message to be signed + /// @param[in] message_len Length of the message + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0, + /// invalid @a ctx) + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_sign_initialize() + /// @see yaca_sign_finalize() + /// @see yaca_sign_initialize_hmac() + /// @see yaca_sign_initialize_cmac() + int yaca_sign_update( + ffi.Pointer ctx, + ffi.Pointer message, + int message_len, + ) { + return _yaca_sign_update( + ctx, + message, + message_len, + ); + } + + late final _yaca_sign_update_ptr = + _lookup>('yaca_sign_update'); + late final _dart_yaca_sign_update _yaca_sign_update = + _yaca_sign_update_ptr.asFunction<_dart_yaca_sign_update>(); + + /// @brief Calculates the final signature or MAC. + /// + /// @since_tizen 3.0 + /// + /// @remarks Skipping yaca_sign_update() and calling only yaca_sign_finalize() will produce a + /// signature or MAC of an empty message. + /// + /// @param[in,out] ctx A valid sign context + /// @param[out] signature Buffer for the MAC or the message signature + /// (must be allocated by client, see yaca_context_get_output_length()) + /// @param[out] signature_len Length of the MAC or the signature, + /// actual number of bytes written will be returned here + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a ctx) + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_sign_initialize() + /// @see yaca_sign_update() + /// @see yaca_sign_initialize_hmac() + /// @see yaca_sign_initialize_cmac() + /// @see yaca_context_get_output_length() + int yaca_sign_finalize( + ffi.Pointer ctx, + ffi.Pointer signature, + ffi.Pointer signature_len, + ) { + return _yaca_sign_finalize( + ctx, + signature, + signature_len, + ); + } + + late final _yaca_sign_finalize_ptr = + _lookup>('yaca_sign_finalize'); + late final _dart_yaca_sign_finalize _yaca_sign_finalize = + _yaca_sign_finalize_ptr.asFunction<_dart_yaca_sign_finalize>(); + + /// @brief Initializes a signature verification context for asymmetric signatures. + /// + /// @since_tizen 3.0 + /// + /// @remarks For RSA operations the default padding used is #YACA_PADDING_PKCS1. It can be + /// changed using yaca_context_set_property() with #YACA_PROPERTY_PADDING. + /// For verify to succeed it has to be set to the same value it was signed with. + /// + /// @remarks The @a ctx should be released using yaca_context_destroy(). + /// + /// @param[out] ctx Newly created context + /// @param[in] algo Digest algorithm that will be used + /// @param[in] pub_key Public key that will be used, algorithm is deduced based on + /// key type, supported key types: + /// - #YACA_KEY_TYPE_RSA_PUB, + /// - #YACA_KEY_TYPE_DSA_PUB, + /// - #YACA_KEY_TYPE_EC_PUB + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a algo or @a pub_key) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_key_type_e + /// @see #yaca_digest_algorithm_e + /// @see #yaca_padding_e + /// @see yaca_context_set_property() + /// @see yaca_verify_update() + /// @see yaca_verify_finalize() + /// @see yaca_context_destroy() + int yaca_verify_initialize( + ffi.Pointer> ctx, + int algo, + ffi.Pointer pub_key, + ) { + return _yaca_verify_initialize( + ctx, + algo, + pub_key, + ); + } + + late final _yaca_verify_initialize_ptr = + _lookup>( + 'yaca_verify_initialize'); + late final _dart_yaca_verify_initialize _yaca_verify_initialize = + _yaca_verify_initialize_ptr.asFunction<_dart_yaca_verify_initialize>(); + + /// @brief Feeds the message into the digital signature verification algorithm. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] ctx Context created by yaca_verify_initialize() + /// @param[in] message Message + /// @param[in] message_len Length of the message + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0, + /// invalid @a ctx) + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_verify_initialize() + /// @see yaca_verify_finalize() + int yaca_verify_update( + ffi.Pointer ctx, + ffi.Pointer message, + int message_len, + ) { + return _yaca_verify_update( + ctx, + message, + message_len, + ); + } + + late final _yaca_verify_update_ptr = + _lookup>('yaca_verify_update'); + late final _dart_yaca_verify_update _yaca_verify_update = + _yaca_verify_update_ptr.asFunction<_dart_yaca_verify_update>(); + + /// @brief Performs the verification. + /// + /// @since_tizen 3.0 + /// + /// @remarks Skipping yaca_verify_update() and calling only yaca_verify_finalize() will verify + /// the signature of an empty message. + /// + /// @param[in,out] ctx A valid verify context + /// @param[in] signature Message signature to be verified + /// @param[in] signature_len Length of the signature + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a ctx) + /// @retval #YACA_ERROR_INTERNAL Internal error + /// @retval #YACA_ERROR_DATA_MISMATCH The verification failed + /// + /// @see yaca_verify_initialize() + /// @see yaca_verify_update() + /// @see yaca_sign_finalize() + int yaca_verify_finalize( + ffi.Pointer ctx, + ffi.Pointer signature, + int signature_len, + ) { + return _yaca_verify_finalize( + ctx, + signature, + signature_len, + ); + } + + late final _yaca_verify_finalize_ptr = + _lookup>( + 'yaca_verify_finalize'); + late final _dart_yaca_verify_finalize _yaca_verify_finalize = + _yaca_verify_finalize_ptr.asFunction<_dart_yaca_verify_finalize>(); + + /// @brief Initializes a digest context. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a ctx should be released using yaca_context_destroy(). + /// + /// @param[out] ctx Newly created context + /// @param[in] algo Digest algorithm that will be used + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a algo) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_digest_algorithm_e + /// @see yaca_digest_update() + /// @see yaca_digest_finalize() + /// @see yaca_context_destroy() + int yaca_digest_initialize( + ffi.Pointer> ctx, + int algo, + ) { + return _yaca_digest_initialize( + ctx, + algo, + ); + } + + late final _yaca_digest_initialize_ptr = + _lookup>( + 'yaca_digest_initialize'); + late final _dart_yaca_digest_initialize _yaca_digest_initialize = + _yaca_digest_initialize_ptr.asFunction<_dart_yaca_digest_initialize>(); + + /// @brief Feeds the message into the message digest algorithm. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] ctx Context created by yaca_digest_initialize() + /// @param[in] message Message from which the digest is to be calculated + /// @param[in] message_len Length of the message + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0, + /// invalid @a ctx) + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_digest_initialize() + /// @see yaca_digest_finalize() + int yaca_digest_update( + ffi.Pointer ctx, + ffi.Pointer message, + int message_len, + ) { + return _yaca_digest_update( + ctx, + message, + message_len, + ); + } + + late final _yaca_digest_update_ptr = + _lookup>('yaca_digest_update'); + late final _dart_yaca_digest_update _yaca_digest_update = + _yaca_digest_update_ptr.asFunction<_dart_yaca_digest_update>(); + + /// @brief Calculates the final digest. + /// + /// @since_tizen 3.0 + /// + /// @remarks Skipping yaca_digest_update() and calling only yaca_digest_finalize() will produce an + /// empty message digest. + /// + /// @param[in,out] ctx A valid digest context + /// @param[out] digest Buffer for the message digest + /// (must be allocated by client, see yaca_context_get_output_length()) + /// @param[out] digest_len Length of the digest, + /// actual number of bytes written will be returned here + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a ctx) + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_digest_initialize() + /// @see yaca_digest_update() + /// @see yaca_context_get_output_length() + int yaca_digest_finalize( + ffi.Pointer ctx, + ffi.Pointer digest, + ffi.Pointer digest_len, + ) { + return _yaca_digest_finalize( + ctx, + digest, + digest_len, + ); + } + + late final _yaca_digest_finalize_ptr = + _lookup>( + 'yaca_digest_finalize'); + late final _dart_yaca_digest_finalize _yaca_digest_finalize = + _yaca_digest_finalize_ptr.asFunction<_dart_yaca_digest_finalize>(); + + /// @brief Gets key's type. + /// + /// @since_tizen 3.0 + /// + /// @param[in] key Key which type we return + /// @param[out] key_type Key type + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Either of the params is NULL + /// + /// @see #yaca_key_type_e + int yaca_key_get_type( + ffi.Pointer key, + ffi.Pointer key_type, + ) { + return _yaca_key_get_type( + key, + key_type, + ); + } + + late final _yaca_key_get_type_ptr = + _lookup>('yaca_key_get_type'); + late final _dart_yaca_key_get_type _yaca_key_get_type = + _yaca_key_get_type_ptr.asFunction<_dart_yaca_key_get_type>(); + + /// @brief Gets key's length (in bits). + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a key can be any symmetric (including an Initialization Vector) or + /// asymmetric key (including key generation parameters). + /// + /// @remarks For Diffie-Helmann @a key_bit_len returns prime length in bits. Values + /// used to generate the key/parameters in yaca_key_generate() are not + /// restored. Neither generator number nor values from #yaca_key_bit_length_dh_rfc_e. + /// + /// @remarks For Elliptic Curves @a key_bit_len returns values from #yaca_key_bit_length_ec_e. + /// + /// @param[in] key Key which length we return + /// @param[out] key_bit_len Key length in bits + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Either of the params is NULL + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_key_bit_length_e + /// @see #yaca_key_bit_length_dh_rfc_e + /// @see #yaca_key_bit_length_ec_e + int yaca_key_get_bit_length( + ffi.Pointer key, + ffi.Pointer key_bit_len, + ) { + return _yaca_key_get_bit_length( + key, + key_bit_len, + ); + } + + late final _yaca_key_get_bit_length_ptr = + _lookup>( + 'yaca_key_get_bit_length'); + late final _dart_yaca_key_get_bit_length _yaca_key_get_bit_length = + _yaca_key_get_bit_length_ptr.asFunction<_dart_yaca_key_get_bit_length>(); + + /// @brief Imports a key or key generation parameters. + /// + /// @since_tizen 3.0 + /// + /// @remarks Everywhere where either a key (of any type) or an asymmetric key is referred + /// in the documentation of this function key generator parameters are also included. + /// + /// @remarks This function imports a key trying to match it to the @a key_type specified. + /// It should autodetect both the key format and the file format. + /// + /// @remarks For symmetric, Initialization Vector and DES keys RAW binary format and BASE64 encoded + /// binary format are supported. + /// For asymmetric keys PEM and DER file formats are supported. + /// + /// @remarks Asymmetric keys can be in their default ASN1 structure formats (like + /// PKCS#1, SSleay or PKCS#3). Private asymmetric keys can also be in + /// PKCS#8 format. Additionally it is possible to import public RSA/DSA/EC + /// keys from X509 certificate. + /// + /// @remarks If the key is encrypted the algorithm will be autodetected and password + /// used. If it's not known if the key is encrypted one should pass NULL as + /// password and check for the #YACA_ERROR_INVALID_PASSWORD return code. + /// + /// @remarks If the imported key will be detected as a format that does not support + /// encryption and password was passed #YACA_ERROR_INVALID_PARAMETER will + /// be returned. For a list of keys and formats that do support encryption + /// see yaca_key_export() documentation. + /// + /// @remarks The @a key should be released using yaca_key_destroy(). + /// + /// @param[in] key_type Type of the key + /// @param[in] password Null-terminated password for the key (can be NULL) + /// @param[in] data Blob containing the key + /// @param[in] data_len Size of the blob + /// @param[out] key Returned key + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0, + /// invalid @a key_type or @a data_len too big) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// @retval #YACA_ERROR_INVALID_PASSWORD Invalid @a password given or @a password was required + /// and none was given + /// + /// @see #yaca_key_type_e + /// @see yaca_key_export() + /// @see yaca_key_destroy() + int yaca_key_import( + int key_type, + ffi.Pointer password, + ffi.Pointer data, + int data_len, + ffi.Pointer> key, + ) { + return _yaca_key_import( + key_type, + password, + data, + data_len, + key, + ); + } + + late final _yaca_key_import_ptr = + _lookup>('yaca_key_import'); + late final _dart_yaca_key_import _yaca_key_import = + _yaca_key_import_ptr.asFunction<_dart_yaca_key_import>(); + + /// @brief Exports a key or key generation parameters to arbitrary format. + /// + /// @since_tizen 3.0 + /// + /// @remarks Everywhere where either a key (of any type) or an asymmetric key is referred + /// in the documentation of this function key generator parameters are also included. + /// + /// @remarks This function exports the key to an arbitrary key format and key file format. + /// + /// @remarks For key formats two values are allowed: + /// - #YACA_KEY_FORMAT_DEFAULT: this is the only option possible in case of symmetric keys + /// (or Initialization Vector), for asymmetric keys it will + /// export to their default ASN1 structure format + /// (e.g. PKCS#1, SSLeay, PKCS#3). + /// - #YACA_KEY_FORMAT_PKCS8: this will only work for private asymmetric keys. + /// + /// @remarks The following file formats are supported: + /// - #YACA_KEY_FILE_FORMAT_RAW: used only for symmetric, raw binary format + /// - #YACA_KEY_FILE_FORMAT_BASE64: used only for symmetric, BASE64 encoded binary form + /// - #YACA_KEY_FILE_FORMAT_PEM: used only for asymmetric, PEM file format + /// - #YACA_KEY_FILE_FORMAT_DER: used only for asymmetric, DER file format + /// + /// @remarks Encryption is supported and optional for RSA/DSA private keys in the + /// #YACA_KEY_FORMAT_DEFAULT with #YACA_KEY_FILE_FORMAT_PEM format. If no password is + /// provided the exported key will be unencrypted. The encryption algorithm used + /// in this case is AES-256-CBC. + /// + /// @remarks Encryption is obligatory for #YACA_KEY_FORMAT_PKCS8 format (for both, PEM and DER + /// file formats). If no password is provided the #YACA_ERROR_INVALID_PARAMETER will + /// be returned. The encryption algorithm used in this case is AES-256-CBC. The key is + /// generated from password using PBKDF2 with HMAC-SHA1 function and 2048 iterations. + /// + /// @remarks Encryption is not supported for the symmetric, public keys and key generation + /// parameters in all their supported formats. If a password is provided in such + /// case the #YACA_ERROR_INVALID_PARAMETER will be returned. + /// + /// @param[in] key Key to be exported + /// @param[in] key_fmt Format of the key + /// @param[in] key_file_fmt Format of the key file + /// @param[in] password Password used for the encryption (can be NULL) + /// @param[out] data Data, allocated by the library, containing exported key + /// (must be freed with yaca_free()) + /// @param[out] data_len Size of the output data + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0, + /// invalid @a key_fmt, @a key_file_fmt or @a data_len too big) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_key_format_e + /// @see #yaca_key_file_format_e + /// @see yaca_key_import() + /// @see yaca_key_destroy() + int yaca_key_export( + ffi.Pointer key, + int key_fmt, + int key_file_fmt, + ffi.Pointer password, + ffi.Pointer> data, + ffi.Pointer data_len, + ) { + return _yaca_key_export( + key, + key_fmt, + key_file_fmt, + password, + data, + data_len, + ); + } + + late final _yaca_key_export_ptr = + _lookup>('yaca_key_export'); + late final _dart_yaca_key_export _yaca_key_export = + _yaca_key_export_ptr.asFunction<_dart_yaca_key_export>(); + + /// @brief Generates a secure key or key generation parameters (or an Initialization Vector). + /// + /// @since_tizen 3.0 + /// + /// @remarks This function is used to generate symmetric keys, private asymmetric keys + /// or key generation parameters for key types that support them (DSA, DH and EC). + /// + /// @remarks Supported key lengths: + /// - RSA: length >= 512bits + /// - DSA: length >= 512bits, multiple of 64 + /// - DH: a value taken from #yaca_key_bit_length_dh_rfc_e or + /// (YACA_KEY_LENGTH_DH_GENERATOR_* | prime_length_in_bits), + /// where prime_length_in_bits can be any positive number + /// - EC: a value taken from #yaca_key_bit_length_ec_e + /// + /// @remarks The @a key should be released using yaca_key_destroy(). + /// + /// @param[in] key_type Type of the key to be generated + /// @param[in] key_bit_len Length of the key (in bits) to be generated + /// @param[out] key Newly generated key + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER @a key is NULL, incorrect @a key_type or + /// @a key_bit_len is not dividable by 8 + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_key_type_e + /// @see #yaca_key_bit_length_e + /// @see #yaca_key_bit_length_dh_rfc_e + /// @see #YACA_KEY_LENGTH_DH_GENERATOR_2 + /// @see #YACA_KEY_LENGTH_DH_GENERATOR_5 + /// @see #yaca_key_bit_length_ec_e + /// @see yaca_key_destroy() + int yaca_key_generate( + int key_type, + int key_bit_len, + ffi.Pointer> key, + ) { + return _yaca_key_generate( + key_type, + key_bit_len, + key, + ); + } + + late final _yaca_key_generate_ptr = + _lookup>('yaca_key_generate'); + late final _dart_yaca_key_generate _yaca_key_generate = + _yaca_key_generate_ptr.asFunction<_dart_yaca_key_generate>(); + + /// @brief Generates a secure private asymmetric key from parameters. + /// + /// @since_tizen 3.0 + /// + /// @remarks This function is used to generate private asymmetric keys + /// based on pre-generated parameters. + /// + /// @remarks The @a key should be released using yaca_key_destroy(). + /// + /// @param[in] params Pre-generated parameters + /// @param[out] prv_key Newly generated private key + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER @a prv_key is NULL or incorrect @a params + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_key_destroy() + /// @see yaca_key_generate() + /// @see yaca_key_extract_parameters() + int yaca_key_generate_from_parameters( + ffi.Pointer params, + ffi.Pointer> prv_key, + ) { + return _yaca_key_generate_from_parameters( + params, + prv_key, + ); + } + + late final _yaca_key_generate_from_parameters_ptr = + _lookup>( + 'yaca_key_generate_from_parameters'); + late final _dart_yaca_key_generate_from_parameters + _yaca_key_generate_from_parameters = + _yaca_key_generate_from_parameters_ptr + .asFunction<_dart_yaca_key_generate_from_parameters>(); + + /// @brief Extracts public key from a private one. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a pub_key should be released using yaca_key_destroy(). + /// + /// @param[in] prv_key Private key to extract the public one from + /// @param[out] pub_key Extracted public key + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER @a prv_key is of invalid type or @a pub_key is NULL + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_key_generate() + /// @see yaca_key_import() + /// @see yaca_key_destroy() + int yaca_key_extract_public( + ffi.Pointer prv_key, + ffi.Pointer> pub_key, + ) { + return _yaca_key_extract_public( + prv_key, + pub_key, + ); + } + + late final _yaca_key_extract_public_ptr = + _lookup>( + 'yaca_key_extract_public'); + late final _dart_yaca_key_extract_public _yaca_key_extract_public = + _yaca_key_extract_public_ptr.asFunction<_dart_yaca_key_extract_public>(); + + /// @brief Extracts parameters from a private or a public key. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a params should be released using yaca_key_destroy(). + /// + /// @param[in] key A key to extract the parameters from + /// @param[out] params Extracted parameters + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER @a key is of invalid type or @a params is NULL + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_key_generate() + /// @see yaca_key_generate_from_parameters() + /// @see yaca_key_import() + /// @see yaca_key_destroy() + int yaca_key_extract_parameters( + ffi.Pointer key, + ffi.Pointer> params, + ) { + return _yaca_key_extract_parameters( + key, + params, + ); + } + + late final _yaca_key_extract_parameters_ptr = + _lookup>( + 'yaca_key_extract_parameters'); + late final _dart_yaca_key_extract_parameters _yaca_key_extract_parameters = + _yaca_key_extract_parameters_ptr + .asFunction<_dart_yaca_key_extract_parameters>(); + + /// @brief Derives a shared secret using Diffie-Helmann or EC Diffie-Helmann key exchange protocol. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a secret should not be used as a symmetric key, + /// to produce a symmetric key pass the secret to a key derivation function (KDF) + /// or a message digest function. + /// + /// @remarks The @a secret should be freed with yaca_free(). + /// + /// @param[in] prv_key Our private key + /// @param[in] pub_key Peer public key + /// @param[out] secret Generated shared secret + /// @param[out] secret_len Size of the shared secret + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values + /// (invalid @a prv_key or @a pub_key) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see yaca_key_derive_kdf() + /// @see yaca_simple_calculate_digest() + /// @see yaca_free() + int yaca_key_derive_dh( + ffi.Pointer prv_key, + ffi.Pointer pub_key, + ffi.Pointer> secret, + ffi.Pointer secret_len, + ) { + return _yaca_key_derive_dh( + prv_key, + pub_key, + secret, + secret_len, + ); + } + + late final _yaca_key_derive_dh_ptr = + _lookup>('yaca_key_derive_dh'); + late final _dart_yaca_key_derive_dh _yaca_key_derive_dh = + _yaca_key_derive_dh_ptr.asFunction<_dart_yaca_key_derive_dh>(); + + /// @brief Derives a key material from shared secret. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a info parameter is ANSI X9.42 OtherInfo or ANSI X9.62 SharedInfo structure, + /// more information can be found in ANSI X9.42/62 standard specification. + /// + /// @remarks The @a key_material or separate parts of it can be used to import a symmetric key + /// with yaca_key_import(). + /// + /// @remarks The @a key_material should be freed using yaca_free(). + /// + /// @param[in] kdf Key derivation function + /// @param[in] algo Digest algorithm that should be used in key derivation + /// @param[in] secret Shared secret + /// @param[in] secret_len Size of the shared secret + /// @param[in] info Optional additional info, use NULL if not appending extra info + /// @param[in] info_len Length of additional info, use 0 if not using additional info + /// @param[in] key_material_len Length of a key material to be generated + /// @param[out] key_material Newly generated key material + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0, + /// invalid @a algo or @a kdf) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_kdf_e + /// @see #yaca_digest_algorithm_e + /// @see yaca_key_derive_dh() + /// @see yaca_key_import() + /// @see yaca_free() + int yaca_key_derive_kdf( + int kdf, + int algo, + ffi.Pointer secret, + int secret_len, + ffi.Pointer info, + int info_len, + int key_material_len, + ffi.Pointer> key_material, + ) { + return _yaca_key_derive_kdf( + kdf, + algo, + secret, + secret_len, + info, + info_len, + key_material_len, + key_material, + ); + } + + late final _yaca_key_derive_kdf_ptr = + _lookup>( + 'yaca_key_derive_kdf'); + late final _dart_yaca_key_derive_kdf _yaca_key_derive_kdf = + _yaca_key_derive_kdf_ptr.asFunction<_dart_yaca_key_derive_kdf>(); + + /// @brief Derives a key from user password (PKCS #5 a.k.a. pbkdf2 algorithm). + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a key should be released using yaca_key_destroy(). + /// + /// @param[in] password User password as a null-terminated string + /// @param[in] salt Salt, should be a non-empty string + /// @param[in] salt_len Length of the salt + /// @param[in] iterations Number of iterations + /// @param[in] algo Digest algorithm that should be used in key generation + /// @param[in] key_bit_len Length of a key (in bits) to be generated + /// @param[out] key Newly generated key + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0, + /// invalid @a algo or @a key_bit_len not dividable by 8) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_digest_algorithm_e + /// @see yaca_key_destroy() + int yaca_key_derive_pbkdf2( + ffi.Pointer password, + ffi.Pointer salt, + int salt_len, + int iterations, + int algo, + int key_bit_len, + ffi.Pointer> key, + ) { + return _yaca_key_derive_pbkdf2( + password, + salt, + salt_len, + iterations, + algo, + key_bit_len, + key, + ); + } + + late final _yaca_key_derive_pbkdf2_ptr = + _lookup>( + 'yaca_key_derive_pbkdf2'); + late final _dart_yaca_key_derive_pbkdf2 _yaca_key_derive_pbkdf2 = + _yaca_key_derive_pbkdf2_ptr.asFunction<_dart_yaca_key_derive_pbkdf2>(); + + /// @brief Release the key created by the library. Passing YACA_KEY_NULL is allowed. + /// + /// @since_tizen 3.0 + /// + /// @param[in,out] key Key to be released + /// + /// @see yaca_key_import() + /// @see yaca_key_export() + /// @see yaca_key_generate() + void yaca_key_destroy( + ffi.Pointer key, + ) { + return _yaca_key_destroy( + key, + ); + } + + late final _yaca_key_destroy_ptr = + _lookup>('yaca_key_destroy'); + late final _dart_yaca_key_destroy _yaca_key_destroy = + _yaca_key_destroy_ptr.asFunction<_dart_yaca_key_destroy>(); + + /// @brief Encrypts data using a RSA public key (low-level encrypt equivalent). + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a ciphertext should be freed using yaca_free(). + /// + /// @remarks The @a pub_key used has to be of a #YACA_KEY_TYPE_RSA_PUB type. + /// + /// @remarks The maximum length of plaintext depends on the key length and padding method. + /// See #yaca_padding_e for details. + /// + /// @remarks The @a plaintext can be NULL but then the @a plaintext_len must be 0. + /// + /// @param[in] padding Padding method + /// @param[in] pub_key Public RSA key (see yaca_key.h for key generation functions) + /// @param[in] plaintext Plaintext to be encrypted + /// @param[in] plaintext_len Length of the plaintext + /// @param[out] ciphertext Encrypted data, will be allocated by the library + /// @param[out] ciphertext_len Length of the encrypted data (may be larger than decrypted) + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0 + /// invalid @a padding, @a pub_key or @a plaintext_len) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_key_type_e + /// @see #yaca_padding_e + /// @see yaca_rsa_private_decrypt() + /// @see yaca_free() + int yaca_rsa_public_encrypt( + int padding, + ffi.Pointer pub_key, + ffi.Pointer plaintext, + int plaintext_len, + ffi.Pointer> ciphertext, + ffi.Pointer ciphertext_len, + ) { + return _yaca_rsa_public_encrypt( + padding, + pub_key, + plaintext, + plaintext_len, + ciphertext, + ciphertext_len, + ); + } + + late final _yaca_rsa_public_encrypt_ptr = + _lookup>( + 'yaca_rsa_public_encrypt'); + late final _dart_yaca_rsa_public_encrypt _yaca_rsa_public_encrypt = + _yaca_rsa_public_encrypt_ptr.asFunction<_dart_yaca_rsa_public_encrypt>(); + + /// @brief Decrypts data using a RSA private key (low-level decrypt equivalent). + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a plaintext should be freed using yaca_free(). + /// + /// @remarks The @a prv_key used has to be of a #YACA_KEY_TYPE_RSA_PRIV type. + /// + /// @param[in] padding Padding method + /// @param[in] prv_key Private RSA key matching the public one used to encrypt the data + /// @param[in] ciphertext Ciphertext to be decrypted + /// @param[in] ciphertext_len Length of ciphertext + /// @param[out] plaintext Decrypted data, will be allocated by the library + /// @param[out] plaintext_len Length of the decrypted data + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0 + /// invalid @a padding or @a prv_key), padding check failed + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_key_type_e + /// @see #yaca_padding_e + /// @see yaca_rsa_public_encrypt() + /// @see yaca_free() + int yaca_rsa_private_decrypt( + int padding, + ffi.Pointer prv_key, + ffi.Pointer ciphertext, + int ciphertext_len, + ffi.Pointer> plaintext, + ffi.Pointer plaintext_len, + ) { + return _yaca_rsa_private_decrypt( + padding, + prv_key, + ciphertext, + ciphertext_len, + plaintext, + plaintext_len, + ); + } + + late final _yaca_rsa_private_decrypt_ptr = + _lookup>( + 'yaca_rsa_private_decrypt'); + late final _dart_yaca_rsa_private_decrypt _yaca_rsa_private_decrypt = + _yaca_rsa_private_decrypt_ptr + .asFunction<_dart_yaca_rsa_private_decrypt>(); + + /// @brief Encrypts data using a RSA private key (low-level sign equivalent). + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a ciphertext should be freed using yaca_free(). + /// + /// @remarks The @a prv_key used has to be of a #YACA_KEY_TYPE_RSA_PRIV type. + /// + /// @remarks The maximum length of plaintext depends on the key length and padding method, + /// see #yaca_padding_e for details. + /// + /// @remarks The @a plaintext can be NULL but then the @a plaintext_len must be 0. + /// + /// @param[in] padding Padding method + /// @param[in] prv_key Private RSA key (see yaca_key.h for key generation functions) + /// @param[in] plaintext Plaintext to be encrypted + /// @param[in] plaintext_len Length of the plaintext + /// @param[out] ciphertext Encrypted data, will be allocated by the library + /// @param[out] ciphertext_len Length of the encrypted data (may be larger than decrypted) + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0 + /// invalid @a padding, @a prv_key or @a plaintext_len) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_key_type_e + /// @see #yaca_padding_e + /// @see yaca_rsa_public_decrypt() + /// @see yaca_free() + int yaca_rsa_private_encrypt( + int padding, + ffi.Pointer prv_key, + ffi.Pointer plaintext, + int plaintext_len, + ffi.Pointer> ciphertext, + ffi.Pointer ciphertext_len, + ) { + return _yaca_rsa_private_encrypt( + padding, + prv_key, + plaintext, + plaintext_len, + ciphertext, + ciphertext_len, + ); + } + + late final _yaca_rsa_private_encrypt_ptr = + _lookup>( + 'yaca_rsa_private_encrypt'); + late final _dart_yaca_rsa_private_encrypt _yaca_rsa_private_encrypt = + _yaca_rsa_private_encrypt_ptr + .asFunction<_dart_yaca_rsa_private_encrypt>(); + + /// @brief Decrypts data using a RSA public key (low-level verify equivalent). + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a plaintext should be freed using yaca_free(). + /// + /// @remarks The @a pub_key used has to be of a #YACA_KEY_TYPE_RSA_PUB type. + /// + /// @param[in] padding Padding method + /// @param[in] pub_key Public RSA key matching the private one used to encrypt the data + /// @param[in] ciphertext Ciphertext to be decrypted + /// @param[in] ciphertext_len Length of ciphertext + /// @param[out] plaintext Decrypted data, will be allocated by the library + /// @param[out] plaintext_len Length of the decrypted data + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0 + /// invalid @a padding or @a pub_key), padding check failed + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_key_type_e + /// @see #yaca_padding_e + /// @see yaca_rsa_private_encrypt() + /// @see yaca_free() + int yaca_rsa_public_decrypt( + int padding, + ffi.Pointer pub_key, + ffi.Pointer ciphertext, + int ciphertext_len, + ffi.Pointer> plaintext, + ffi.Pointer plaintext_len, + ) { + return _yaca_rsa_public_decrypt( + padding, + pub_key, + ciphertext, + ciphertext_len, + plaintext, + plaintext_len, + ); + } + + late final _yaca_rsa_public_decrypt_ptr = + _lookup>( + 'yaca_rsa_public_decrypt'); + late final _dart_yaca_rsa_public_decrypt _yaca_rsa_public_decrypt = + _yaca_rsa_public_decrypt_ptr.asFunction<_dart_yaca_rsa_public_decrypt>(); + + /// @brief Encrypts data using a symmetric cipher. + /// + /// @since_tizen 3.0 + /// + /// @remarks yaca_simple_encrypt() doesn't support #YACA_BCM_GCM and #YACA_BCM_CCM. + /// + /// @remarks The @a ciphertext should be freed using yaca_free(). + /// + /// @remarks The @a plaintext can be NULL but then @a plaintext_len must be 0. + /// + /// @param[in] algo Encryption algorithm (select #YACA_ENCRYPT_AES if unsure) + /// @param[in] bcm Chaining mode (select #YACA_BCM_CBC if unsure) + /// @param[in] sym_key Symmetric encryption key (see yaca_key.h for key generation functions) + /// @param[in] iv Initialization Vector + /// @param[in] plaintext Plaintext to be encrypted + /// @param[in] plaintext_len Length of the plaintext + /// @param[out] ciphertext Encrypted data, will be allocated by the library + /// @param[out] ciphertext_len Length of the encrypted data (may be larger than decrypted) + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0 + /// invalid @a algo, @a bcm, @a sym_key or @a iv) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_encrypt_algorithm_e + /// @see #yaca_block_cipher_mode_e + /// @see yaca_simple_decrypt() + /// @see yaca_free() + int yaca_simple_encrypt( + int algo, + int bcm, + ffi.Pointer sym_key, + ffi.Pointer iv, + ffi.Pointer plaintext, + int plaintext_len, + ffi.Pointer> ciphertext, + ffi.Pointer ciphertext_len, + ) { + return _yaca_simple_encrypt( + algo, + bcm, + sym_key, + iv, + plaintext, + plaintext_len, + ciphertext, + ciphertext_len, + ); + } + + late final _yaca_simple_encrypt_ptr = + _lookup>( + 'yaca_simple_encrypt'); + late final _dart_yaca_simple_encrypt _yaca_simple_encrypt = + _yaca_simple_encrypt_ptr.asFunction<_dart_yaca_simple_encrypt>(); + + /// @brief Decrypts data using a symmetric cipher. + /// + /// @since_tizen 3.0 + /// + /// @remarks yaca_simple_decrypt() doesn't support #YACA_BCM_GCM and #YACA_BCM_CCM. + /// + /// @remarks The @a plaintext should be freed using yaca_free(). + /// + /// @remarks The @a ciphertext can be NULL but then @a ciphertext_len must be 0. + /// + /// @param[in] algo Decryption algorithm that was used to encrypt the data + /// @param[in] bcm Chaining mode that was used to encrypt the data + /// @param[in] sym_key Symmetric encryption key that was used to encrypt the data + /// @param[in] iv Initialization Vector that was used to encrypt the data + /// @param[in] ciphertext Ciphertext to be decrypted + /// @param[in] ciphertext_len Length of ciphertext + /// @param[out] plaintext Decrypted data, will be allocated by the library + /// @param[out] plaintext_len Length of the decrypted data + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0 + /// invalid @a algo, @a bcm, @a sym_key or @a iv) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_encrypt_algorithm_e + /// @see #yaca_block_cipher_mode_e + /// @see yaca_simple_encrypt() + /// @see yaca_free() + int yaca_simple_decrypt( + int algo, + int bcm, + ffi.Pointer sym_key, + ffi.Pointer iv, + ffi.Pointer ciphertext, + int ciphertext_len, + ffi.Pointer> plaintext, + ffi.Pointer plaintext_len, + ) { + return _yaca_simple_decrypt( + algo, + bcm, + sym_key, + iv, + ciphertext, + ciphertext_len, + plaintext, + plaintext_len, + ); + } + + late final _yaca_simple_decrypt_ptr = + _lookup>( + 'yaca_simple_decrypt'); + late final _dart_yaca_simple_decrypt _yaca_simple_decrypt = + _yaca_simple_decrypt_ptr.asFunction<_dart_yaca_simple_decrypt>(); + + /// @brief Calculates a digest of a message. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a digest should be freed using yaca_free(). + /// + /// @remarks The @a message can be NULL but then @a message_len must be 0. + /// + /// @param[in] algo Digest algorithm (select #YACA_DIGEST_SHA256 if unsure) + /// @param[in] message Message from which the digest is to be calculated + /// @param[in] message_len Length of the message + /// @param[out] digest Message digest, will be allocated by the library + /// @param[out] digest_len Length of message digest (depends on algorithm) + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, + /// invalid @a algo) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_digest_algorithm_e + /// @see yaca_free() + int yaca_simple_calculate_digest( + int algo, + ffi.Pointer message, + int message_len, + ffi.Pointer> digest, + ffi.Pointer digest_len, + ) { + return _yaca_simple_calculate_digest( + algo, + message, + message_len, + digest, + digest_len, + ); + } + + late final _yaca_simple_calculate_digest_ptr = + _lookup>( + 'yaca_simple_calculate_digest'); + late final _dart_yaca_simple_calculate_digest _yaca_simple_calculate_digest = + _yaca_simple_calculate_digest_ptr + .asFunction<_dart_yaca_simple_calculate_digest>(); + + /// @brief Creates a signature using asymmetric private key. + /// + /// @since_tizen 3.0 + /// + /// @remarks For #YACA_DIGEST_SHA384 and #YACA_DIGEST_SHA512 the RSA key size must be bigger than + /// #YACA_KEY_LENGTH_512BIT. + /// + /// @remarks Using of #YACA_DIGEST_MD5 algorithm for DSA and ECDSA operations is prohibited. + /// + /// @remarks The @a signature should be freed using yaca_free(). + /// + /// @remarks The @a message can be NULL but then @a message_len must be 0. + /// + /// @param[in] algo Digest algorithm that will be used + /// @param[in] prv_key Private key that will be used, algorithm is + /// deduced based on key type, supported key types: + /// - #YACA_KEY_TYPE_RSA_PRIV, + /// - #YACA_KEY_TYPE_DSA_PRIV, + /// - #YACA_KEY_TYPE_EC_PRIV + /// @param[in] message Message to be signed + /// @param[in] message_len Length of the message + /// @param[out] signature Message signature, will be allocated by the library + /// @param[out] signature_len Length of the signature + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0 + /// invalid @a algo or @a prv_key) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_key_type_e + /// @see #yaca_digest_algorithm_e + /// @see yaca_simple_verify_signature() + /// @see yaca_free() + int yaca_simple_calculate_signature( + int algo, + ffi.Pointer prv_key, + ffi.Pointer message, + int message_len, + ffi.Pointer> signature, + ffi.Pointer signature_len, + ) { + return _yaca_simple_calculate_signature( + algo, + prv_key, + message, + message_len, + signature, + signature_len, + ); + } + + late final _yaca_simple_calculate_signature_ptr = + _lookup>( + 'yaca_simple_calculate_signature'); + late final _dart_yaca_simple_calculate_signature + _yaca_simple_calculate_signature = _yaca_simple_calculate_signature_ptr + .asFunction<_dart_yaca_simple_calculate_signature>(); + + /// @brief Verifies a signature using asymmetric public key. + /// + /// @since_tizen 3.0 + /// + /// @remarks The @a message can be NULL but then @a message_len must be 0. + /// + /// @param[in] algo Digest algorithm that will be used + /// @param[in] pub_key Public key that will be used, algorithm is + /// deduced based on key type, supported key types: + /// - #YACA_KEY_TYPE_RSA_PUB, + /// - #YACA_KEY_TYPE_DSA_PUB, + /// - #YACA_KEY_TYPE_EC_PUB + /// @param[in] message Message + /// @param[in] message_len Length of the message + /// @param[in] signature Message signature to be verified + /// @param[in] signature_len Length of the signature + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0 + /// invalid @a algo or @a pub_key) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// @retval #YACA_ERROR_DATA_MISMATCH The verification failed + /// + /// @see #yaca_key_type_e + /// @see #yaca_digest_algorithm_e + /// @see yaca_simple_calculate_signature() + int yaca_simple_verify_signature( + int algo, + ffi.Pointer pub_key, + ffi.Pointer message, + int message_len, + ffi.Pointer signature, + int signature_len, + ) { + return _yaca_simple_verify_signature( + algo, + pub_key, + message, + message_len, + signature, + signature_len, + ); + } + + late final _yaca_simple_verify_signature_ptr = + _lookup>( + 'yaca_simple_verify_signature'); + late final _dart_yaca_simple_verify_signature _yaca_simple_verify_signature = + _yaca_simple_verify_signature_ptr + .asFunction<_dart_yaca_simple_verify_signature>(); + + /// @brief Calculates a HMAC of given message using symmetric key. + /// + /// @since_tizen 3.0 + /// + /// @remarks For verification, calculate message HMAC and compare with received MAC using + /// yaca_memcmp(). + /// + /// @remarks The @a mac should be freed using yaca_free(). + /// + /// @remarks The @a message can be NULL but then @a message_len must be 0. + /// + /// @param[in] algo Digest algorithm that will be used + /// @param[in] sym_key Key that will be used, supported key types: + /// - #YACA_KEY_TYPE_SYMMETRIC, + /// - #YACA_KEY_TYPE_DES + /// @param[in] message Message to calculate HMAC from + /// @param[in] message_len Length of the message + /// @param[out] mac MAC, will be allocated by the library + /// @param[out] mac_len Length of the MAC + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0 + /// invalid @a algo or @a sym_key) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_key_type_e + /// @see #yaca_digest_algorithm_e + /// @see yaca_memcmp() + /// @see yaca_free() + int yaca_simple_calculate_hmac( + int algo, + ffi.Pointer sym_key, + ffi.Pointer message, + int message_len, + ffi.Pointer> mac, + ffi.Pointer mac_len, + ) { + return _yaca_simple_calculate_hmac( + algo, + sym_key, + message, + message_len, + mac, + mac_len, + ); + } + + late final _yaca_simple_calculate_hmac_ptr = + _lookup>( + 'yaca_simple_calculate_hmac'); + late final _dart_yaca_simple_calculate_hmac _yaca_simple_calculate_hmac = + _yaca_simple_calculate_hmac_ptr + .asFunction<_dart_yaca_simple_calculate_hmac>(); + + /// @brief Calculates a CMAC of given message using symmetric key. + /// + /// @since_tizen 3.0 + /// + /// @remarks For verification, calculate message CMAC and compare with received MAC using + /// yaca_memcmp(). + /// + /// @remarks The @a mac should be freed using yaca_free(). + /// + /// @remarks The @a message can be NULL but then @a message_len must be 0. + /// + /// @param[in] algo Encryption algorithm that will be used + /// @param[in] sym_key Key that will be used, supported key types: + /// - #YACA_KEY_TYPE_SYMMETRIC, + /// - #YACA_KEY_TYPE_DES + /// @param[in] message Message to calculate CMAC from + /// @param[in] message_len Length of the message + /// @param[out] mac MAC, will be allocated by the library + /// @param[out] mac_len Length of the MAC + /// + /// @return #YACA_ERROR_NONE on success, negative on error + /// @retval #YACA_ERROR_NONE Successful + /// @retval #YACA_ERROR_INVALID_PARAMETER Required parameters have incorrect values (NULL, 0 + /// invalid @a algo or @a sym_key) + /// @retval #YACA_ERROR_OUT_OF_MEMORY Out of memory error + /// @retval #YACA_ERROR_INTERNAL Internal error + /// + /// @see #yaca_key_type_e + /// @see #yaca_encrypt_algorithm_e + /// @see yaca_memcmp() + /// @see yaca_free() + int yaca_simple_calculate_cmac( + int algo, + ffi.Pointer sym_key, + ffi.Pointer message, + int message_len, + ffi.Pointer> mac, + ffi.Pointer mac_len, + ) { + return _yaca_simple_calculate_cmac( + algo, + sym_key, + message, + message_len, + mac, + mac_len, + ); + } + + late final _yaca_simple_calculate_cmac_ptr = + _lookup>( + 'yaca_simple_calculate_cmac'); + late final _dart_yaca_simple_calculate_cmac _yaca_simple_calculate_cmac = + _yaca_simple_calculate_cmac_ptr + .asFunction<_dart_yaca_simple_calculate_cmac>(); + + late final ffi.Pointer<_calendar_book_property_ids> __calendar_book = + _lookup<_calendar_book_property_ids>('_calendar_book'); + + _calendar_book_property_ids get _calendar_book => __calendar_book.ref; + + late final ffi.Pointer<_calendar_event_property_ids> __calendar_event = + _lookup<_calendar_event_property_ids>('_calendar_event'); + + _calendar_event_property_ids get _calendar_event => __calendar_event.ref; + + late final ffi.Pointer<_calendar_todo_property_ids> __calendar_todo = + _lookup<_calendar_todo_property_ids>('_calendar_todo'); + + _calendar_todo_property_ids get _calendar_todo => __calendar_todo.ref; + + late final ffi.Pointer<_calendar_timezone_property_ids> __calendar_timezone = + _lookup<_calendar_timezone_property_ids>('_calendar_timezone'); + + _calendar_timezone_property_ids get _calendar_timezone => + __calendar_timezone.ref; + + late final ffi.Pointer<_calendar_attendee_property_ids> __calendar_attendee = + _lookup<_calendar_attendee_property_ids>('_calendar_attendee'); + + _calendar_attendee_property_ids get _calendar_attendee => + __calendar_attendee.ref; + + late final ffi.Pointer<_calendar_alarm_property_ids> __calendar_alarm = + _lookup<_calendar_alarm_property_ids>('_calendar_alarm'); + + _calendar_alarm_property_ids get _calendar_alarm => __calendar_alarm.ref; + + late final ffi.Pointer<_calendar_updated_info_property_ids> + __calendar_updated_info = + _lookup<_calendar_updated_info_property_ids>('_calendar_updated_info'); + + _calendar_updated_info_property_ids get _calendar_updated_info => + __calendar_updated_info.ref; + + late final ffi.Pointer<_calendar_event_calendar_book_property_ids> + __calendar_event_calendar_book = + _lookup<_calendar_event_calendar_book_property_ids>( + '_calendar_event_calendar_book'); + + _calendar_event_calendar_book_property_ids + get _calendar_event_calendar_book => __calendar_event_calendar_book.ref; + + late final ffi.Pointer<_calendar_todo_calendar_book_property_ids> + __calendar_todo_calendar_book = + _lookup<_calendar_todo_calendar_book_property_ids>( + '_calendar_todo_calendar_book'); + + _calendar_todo_calendar_book_property_ids get _calendar_todo_calendar_book => + __calendar_todo_calendar_book.ref; + + late final ffi.Pointer<_calendar_event_calendar_book_attendee_property_ids> + __calendar_event_calendar_book_attendee = + _lookup<_calendar_event_calendar_book_attendee_property_ids>( + '_calendar_event_calendar_book_attendee'); + + _calendar_event_calendar_book_attendee_property_ids + get _calendar_event_calendar_book_attendee => + __calendar_event_calendar_book_attendee.ref; + + late final ffi.Pointer<_calendar_instance_utime_calendar_book_property_ids> + __calendar_instance_utime_calendar_book = + _lookup<_calendar_instance_utime_calendar_book_property_ids>( + '_calendar_instance_utime_calendar_book'); + + _calendar_instance_utime_calendar_book_property_ids + get _calendar_instance_utime_calendar_book => + __calendar_instance_utime_calendar_book.ref; + + late final ffi + .Pointer<_calendar_instance_localtime_calendar_book_property_ids> + __calendar_instance_localtime_calendar_book = + _lookup<_calendar_instance_localtime_calendar_book_property_ids>( + '_calendar_instance_localtime_calendar_book'); + + _calendar_instance_localtime_calendar_book_property_ids + get _calendar_instance_localtime_calendar_book => + __calendar_instance_localtime_calendar_book.ref; + + late final ffi + .Pointer<_calendar_instance_utime_calendar_book_extended_property_ids> + __calendar_instance_utime_calendar_book_extended = + _lookup<_calendar_instance_utime_calendar_book_extended_property_ids>( + '_calendar_instance_utime_calendar_book_extended'); + + _calendar_instance_utime_calendar_book_extended_property_ids + get _calendar_instance_utime_calendar_book_extended => + __calendar_instance_utime_calendar_book_extended.ref; + + late final ffi.Pointer< + _calendar_instance_localtime_calendar_book_extended_property_ids> + __calendar_instance_localtime_calendar_book_extended = + _lookup<_calendar_instance_localtime_calendar_book_extended_property_ids>( + '_calendar_instance_localtime_calendar_book_extended'); + + _calendar_instance_localtime_calendar_book_extended_property_ids + get _calendar_instance_localtime_calendar_book_extended => + __calendar_instance_localtime_calendar_book_extended.ref; + + late final ffi.Pointer<_calendar_extended_property_property_ids> + __calendar_extended_property = + _lookup<_calendar_extended_property_property_ids>( + '_calendar_extended_property'); + + _calendar_extended_property_property_ids get _calendar_extended_property => + __calendar_extended_property.ref; + + /// @brief Inserts a record into the calendar database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.write + /// @param[in] record The record handle + /// @param[out] record_id The record ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_FILE_NO_SPACE File system is full + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_NO_DATA Data does not exist + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + /// @see calendar_db_update_record() + /// @see calendar_db_delete_record() + /// @see calendar_db_get_record() + int calendar_db_insert_record( + ffi.Pointer<__calendar_record_h> record, + ffi.Pointer record_id, + ) { + return _calendar_db_insert_record( + record, + record_id, + ); + } + + late final _calendar_db_insert_record_ptr = + _lookup>( + 'calendar_db_insert_record'); + late final _dart_calendar_db_insert_record _calendar_db_insert_record = + _calendar_db_insert_record_ptr + .asFunction<_dart_calendar_db_insert_record>(); + + /// @brief Gets a record from the calendar database. + /// @details This function creates a new record handle from the calendar database by the given @a record_id. \n + /// @a record will be created and filled with record information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.read + /// @remarks You must release @a record using calendar_record_destroy(). + /// @param[in] view_uri The view URI of a record + /// @param[in] record_id The record ID + /// @param[out] record The record handle associated with the record ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_FILE_NO_SPACE File system is full + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_DB_RECORD_NOT_FOUND Database not found + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_NO_DATA Data does not exist + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + /// @see calendar_record_destroy() + int calendar_db_get_record( + ffi.Pointer view_uri, + int record_id, + ffi.Pointer> record, + ) { + return _calendar_db_get_record( + view_uri, + record_id, + record, + ); + } + + late final _calendar_db_get_record_ptr = + _lookup>( + 'calendar_db_get_record'); + late final _dart_calendar_db_get_record _calendar_db_get_record = + _calendar_db_get_record_ptr.asFunction<_dart_calendar_db_get_record>(); + + /// @brief Updates a record in the calendar database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.write + /// @param[in] record The record handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_DB_RECORD_NOT_FOUND Database not found + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_NO_DATA Data does not exist + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + /// @see calendar_db_insert_record() + /// @see calendar_db_delete_record() + /// @see calendar_db_get_record() + int calendar_db_update_record( + ffi.Pointer<__calendar_record_h> record, + ) { + return _calendar_db_update_record( + record, + ); + } + + late final _calendar_db_update_record_ptr = + _lookup>( + 'calendar_db_update_record'); + late final _dart_calendar_db_update_record _calendar_db_update_record = + _calendar_db_update_record_ptr + .asFunction<_dart_calendar_db_update_record>(); + + /// @brief Deletes a record from the calendar database with related child records. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.write + /// @param[in] view_uri The view URI of a record + /// @param[in] record_id The record ID to be deleted + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_DB_RECORD_NOT_FOUND Database not found + /// @retval #CALENDAR_ERROR_FILE_NO_SPACE File system is full + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_NO_DATA Data does not exist + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + /// @see calendar_db_insert_record() + int calendar_db_delete_record( + ffi.Pointer view_uri, + int record_id, + ) { + return _calendar_db_delete_record( + view_uri, + record_id, + ); + } + + late final _calendar_db_delete_record_ptr = + _lookup>( + 'calendar_db_delete_record'); + late final _dart_calendar_db_delete_record _calendar_db_delete_record = + _calendar_db_delete_record_ptr + .asFunction<_dart_calendar_db_delete_record>(); + + /// @brief Retrieves all records as a list. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.read + /// @remarks You must release @a record_list using calendar_list_destroy(). + /// @param[in] view_uri The view URI to get records from + /// @param[in] offset The index from which results are received + /// @param[in] limit The maximum number of results(value 0 is used for all records) + /// @param[out] record_list The record list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_NO_DATA Data does not exist + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + /// @see calendar_list_destroy() + int calendar_db_get_all_records( + ffi.Pointer view_uri, + int offset, + int limit, + ffi.Pointer> record_list, + ) { + return _calendar_db_get_all_records( + view_uri, + offset, + limit, + record_list, + ); + } + + late final _calendar_db_get_all_records_ptr = + _lookup>( + 'calendar_db_get_all_records'); + late final _dart_calendar_db_get_all_records _calendar_db_get_all_records = + _calendar_db_get_all_records_ptr + .asFunction<_dart_calendar_db_get_all_records>(); + + /// @brief Retrieves records using a query handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.read + /// @remarks You must release @a record_list using calendar_list_destroy(). + /// @param[in] query The query handle used to filter results + /// @param[in] offset The index from which results are received + /// @param[in] limit The maximum number of results(value 0 is used for all records) + /// @param[out] record_list The record list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_NO_DATA Data does not exist + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + /// @see calendar_list_destroy() + int calendar_db_get_records_with_query( + ffi.Pointer<__calendar_query_h> query, + int offset, + int limit, + ffi.Pointer> record_list, + ) { + return _calendar_db_get_records_with_query( + query, + offset, + limit, + record_list, + ); + } + + late final _calendar_db_get_records_with_query_ptr = + _lookup>( + 'calendar_db_get_records_with_query'); + late final _dart_calendar_db_get_records_with_query + _calendar_db_get_records_with_query = + _calendar_db_get_records_with_query_ptr + .asFunction<_dart_calendar_db_get_records_with_query>(); + + /// @brief Gets the record count of a specific view. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.read + /// @param[in] view_uri The view URI to get records from + /// @param[out] count The number of records + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_NO_DATA Data does not exist + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre This function requires an open connection to the calendar service using calendar_connect2(). + /// @see calendar_connect() + int calendar_db_get_count( + ffi.Pointer view_uri, + ffi.Pointer count, + ) { + return _calendar_db_get_count( + view_uri, + count, + ); + } + + late final _calendar_db_get_count_ptr = + _lookup>( + 'calendar_db_get_count'); + late final _dart_calendar_db_get_count _calendar_db_get_count = + _calendar_db_get_count_ptr.asFunction<_dart_calendar_db_get_count>(); + + /// @brief Gets the record count with a query handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.read + /// @param[in] query The query handle used for filtering the results + /// @param[out] count The number of records + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_NO_DATA Data does not exist + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre This function requires an open connection to the calendar service using calendar_connect2(). + /// @see calendar_connect2() + int calendar_db_get_count_with_query( + ffi.Pointer<__calendar_query_h> query, + ffi.Pointer count, + ) { + return _calendar_db_get_count_with_query( + query, + count, + ); + } + + late final _calendar_db_get_count_with_query_ptr = + _lookup>( + 'calendar_db_get_count_with_query'); + late final _dart_calendar_db_get_count_with_query + _calendar_db_get_count_with_query = _calendar_db_get_count_with_query_ptr + .asFunction<_dart_calendar_db_get_count_with_query>(); + + /// @brief Inserts multiple records into the calendar database as a batch operation. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.write + /// @param[in] record_list The record list handle + /// @param[out] record_id_array The array of record IDs + /// @param[out] count The number of record IDs + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_FILE_NO_SPACE File system is full + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_NO_DATA Data does not exist + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + /// @see calendar_db_update_records() + /// @see calendar_db_delete_records() + int calendar_db_insert_records( + ffi.Pointer<__calendar_list_h> record_list, + ffi.Pointer> record_id_array, + ffi.Pointer count, + ) { + return _calendar_db_insert_records( + record_list, + record_id_array, + count, + ); + } + + late final _calendar_db_insert_records_ptr = + _lookup>( + 'calendar_db_insert_records'); + late final _dart_calendar_db_insert_records _calendar_db_insert_records = + _calendar_db_insert_records_ptr + .asFunction<_dart_calendar_db_insert_records>(); + + /// @brief Updates multiple records into the calendar database as a batch operation. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.write + /// @param[in] record_list The record list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_NO_DATA Data does not exist + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_DB_RECORD_NOT_FOUND Database not found + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + /// @see calendar_db_insert_records() + /// @see calendar_db_delete_records() + int calendar_db_update_records( + ffi.Pointer<__calendar_list_h> record_list, + ) { + return _calendar_db_update_records( + record_list, + ); + } + + late final _calendar_db_update_records_ptr = + _lookup>( + 'calendar_db_update_records'); + late final _dart_calendar_db_update_records _calendar_db_update_records = + _calendar_db_update_records_ptr + .asFunction<_dart_calendar_db_update_records>(); + + /// @brief Deletes multiple records with related child records from the calendar database as a batch operation. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.write + /// @param[in] view_uri The view URI of the records to delete + /// @param[in] record_id_array The record IDs to delete + /// @param[in] count The number of records + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_DB_RECORD_NOT_FOUND Database not found + /// @retval #CALENDAR_ERROR_FILE_NO_SPACE File system is full + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + /// @see calendar_db_insert_records() + /// @see calendar_db_delete_records() + int calendar_db_delete_records( + ffi.Pointer view_uri, + ffi.Pointer record_id_array, + int count, + ) { + return _calendar_db_delete_records( + view_uri, + record_id_array, + count, + ); + } + + late final _calendar_db_delete_records_ptr = + _lookup>( + 'calendar_db_delete_records'); + late final _dart_calendar_db_delete_records _calendar_db_delete_records = + _calendar_db_delete_records_ptr + .asFunction<_dart_calendar_db_delete_records>(); + + /// @brief Gets the current calendar database version. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.read + /// @param[out] calendar_db_version The calendar database version + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_DB_RECORD_NOT_FOUND Database not found + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre This function requires an open connection to the calendar service using calendar_connect(). + /// @see calendar_connect() + /// @see calendar_db_get_changes_by_version() + int calendar_db_get_current_version( + ffi.Pointer calendar_db_version, + ) { + return _calendar_db_get_current_version( + calendar_db_version, + ); + } + + late final _calendar_db_get_current_version_ptr = + _lookup>( + 'calendar_db_get_current_version'); + late final _dart_calendar_db_get_current_version + _calendar_db_get_current_version = _calendar_db_get_current_version_ptr + .asFunction<_dart_calendar_db_get_current_version>(); + + /// @brief Registers a callback function to be invoked when a record changes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.read + /// @remarks If successive change notification produced on the view_uri are identical, + /// then they are coalesced into a single notification if the older notification has not yet been called + /// because default main loop is doing something. + /// But it means that a callback function is not called to reliably count of change. + /// This API supports only @ref CAPI_SOCIAL_CALENDAR_SVC_VIEW_MODULE_calendar_book view, @ref CAPI_SOCIAL_CALENDAR_SVC_VIEW_MODULE_calendar_event view, + /// @ref CAPI_SOCIAL_CALENDAR_SVC_VIEW_MODULE_calendar_todo view. + /// @param[in] view_uri The view URI of the record to subscribe for change notifications + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre This function requires an open connection to the calendar service using calendar_connect(). + /// @post calendar_db_changed_cb() will be invoked when the designated view changes. + /// @see calendar_connect() + /// @see calendar_db_changed_cb() + /// @see calendar_db_remove_changed_cb() + int calendar_db_add_changed_cb( + ffi.Pointer view_uri, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _calendar_db_add_changed_cb( + view_uri, + callback, + user_data, + ); + } + + late final _calendar_db_add_changed_cb_ptr = + _lookup>( + 'calendar_db_add_changed_cb'); + late final _dart_calendar_db_add_changed_cb _calendar_db_add_changed_cb = + _calendar_db_add_changed_cb_ptr + .asFunction<_dart_calendar_db_add_changed_cb>(); + + /// @brief Unregisters a callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.read + /// @param[in] view_uri The view URI of the record to subscribe for change notifications + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre This function requires an open connection to the calendar service using calendar_connect(). + /// @see calendar_connect() + /// @see calendar_db_changed_cb() + /// @see calendar_db_add_changed_cb() + int calendar_db_remove_changed_cb( + ffi.Pointer view_uri, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _calendar_db_remove_changed_cb( + view_uri, + callback, + user_data, + ); + } + + late final _calendar_db_remove_changed_cb_ptr = + _lookup>( + 'calendar_db_remove_changed_cb'); + late final _dart_calendar_db_remove_changed_cb + _calendar_db_remove_changed_cb = _calendar_db_remove_changed_cb_ptr + .asFunction<_dart_calendar_db_remove_changed_cb>(); + + /// @brief Retrieves records with the given calendar database version. + /// @details This function finds all the changed records since the given @a calendar_db_version. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.read + /// @remarks You must release @a change_record_list using calendar_list_destroy(). + /// @param[in] view_uri The view URI to get records from + /// @param[in] calendar_book_id The calendar book ID to filter + /// @param[in] calendar_db_version The calendar database version + /// @param[out] record_list The record list + /// @param[out] current_calendar_db_version The current calendar database version + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_DB_RECORD_NOT_FOUND Database not found + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + /// @see calendar_list_destroy() + int calendar_db_get_changes_by_version( + ffi.Pointer view_uri, + int calendar_book_id, + int calendar_db_version, + ffi.Pointer> record_list, + ffi.Pointer current_calendar_db_version, + ) { + return _calendar_db_get_changes_by_version( + view_uri, + calendar_book_id, + calendar_db_version, + record_list, + current_calendar_db_version, + ); + } + + late final _calendar_db_get_changes_by_version_ptr = + _lookup>( + 'calendar_db_get_changes_by_version'); + late final _dart_calendar_db_get_changes_by_version + _calendar_db_get_changes_by_version = + _calendar_db_get_changes_by_version_ptr + .asFunction<_dart_calendar_db_get_changes_by_version>(); + + /// @brief Inserts a vcalendar stream into the calendar database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.write + /// @param[in] vcalendar_stream The vcalendar stream + /// @param[out] record_id_array The record IDs to delete + /// @param[out] count The number of record ID arrays + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_NO_DATA Data does not exist + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_FILE_NO_SPACE File system is full + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + /// @see calendar_db_replace_vcalendars() + int calendar_db_insert_vcalendars( + ffi.Pointer vcalendar_stream, + ffi.Pointer> record_id_array, + ffi.Pointer count, + ) { + return _calendar_db_insert_vcalendars( + vcalendar_stream, + record_id_array, + count, + ); + } + + late final _calendar_db_insert_vcalendars_ptr = + _lookup>( + 'calendar_db_insert_vcalendars'); + late final _dart_calendar_db_insert_vcalendars + _calendar_db_insert_vcalendars = _calendar_db_insert_vcalendars_ptr + .asFunction<_dart_calendar_db_insert_vcalendars>(); + + /// @brief Replaces a vcalendar stream in the calendar database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.write + /// @param[in] vcalendar_stream The vcalendar stream + /// @param[in] record_id_array The record IDs to replace + /// @param[in] count The number of record ID arrays + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_NO_DATA Data does not exist + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_DB_RECORD_NOT_FOUND Database not found + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre This function requires an open connection to the calendar service by calendar_connect(). + /// @see calendar_connect() + /// @see calendar_db_replace_vcalendars() + int calendar_db_replace_vcalendars( + ffi.Pointer vcalendar_stream, + ffi.Pointer record_id_array, + int count, + ) { + return _calendar_db_replace_vcalendars( + vcalendar_stream, + record_id_array, + count, + ); + } + + late final _calendar_db_replace_vcalendars_ptr = + _lookup>( + 'calendar_db_replace_vcalendars'); + late final _dart_calendar_db_replace_vcalendars + _calendar_db_replace_vcalendars = _calendar_db_replace_vcalendars_ptr + .asFunction<_dart_calendar_db_replace_vcalendars>(); + + /// @brief Replaces a record in the calendar database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.write + /// @param[in] record The record handle + /// @param[in] record_id The record ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_FILE_NO_SPACE File system is full + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + /// @see calendar_db_update_record() + /// @see calendar_db_delete_record() + /// @see calendar_db_get_record() + int calendar_db_replace_record( + ffi.Pointer<__calendar_record_h> record, + int record_id, + ) { + return _calendar_db_replace_record( + record, + record_id, + ); + } + + late final _calendar_db_replace_record_ptr = + _lookup>( + 'calendar_db_replace_record'); + late final _dart_calendar_db_replace_record _calendar_db_replace_record = + _calendar_db_replace_record_ptr + .asFunction<_dart_calendar_db_replace_record>(); + + /// @brief Replaces multiple records in the calendar database as a batch operation. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.write + /// @param[in] record_list The record list handle + /// @param[in] record_id_array The record IDs + /// @param[in] count The number of record ID arrays + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_FILE_NO_SPACE File system is full + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + /// @see calendar_db_update_records() + /// @see calendar_db_delete_records() + /// @see calendar_db_replace_record() + int calendar_db_replace_records( + ffi.Pointer<__calendar_list_h> record_list, + ffi.Pointer record_id_array, + int count, + ) { + return _calendar_db_replace_records( + record_list, + record_id_array, + count, + ); + } + + late final _calendar_db_replace_records_ptr = + _lookup>( + 'calendar_db_replace_records'); + late final _dart_calendar_db_replace_records _calendar_db_replace_records = + _calendar_db_replace_records_ptr + .asFunction<_dart_calendar_db_replace_records>(); + + /// @brief Gets the last successful change version of the database on the current connection. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.read + /// @param[out] last_change_version The calendar database version on the current connection + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre This function requires an open connection to the calendar service using calendar_connect(). + /// @see calendar_connect() + /// @see calendar_db_get_current_version() + int calendar_db_get_last_change_version( + ffi.Pointer last_change_version, + ) { + return _calendar_db_get_last_change_version( + last_change_version, + ); + } + + late final _calendar_db_get_last_change_version_ptr = + _lookup>( + 'calendar_db_get_last_change_version'); + late final _dart_calendar_db_get_last_change_version + _calendar_db_get_last_change_version = + _calendar_db_get_last_change_version_ptr + .asFunction<_dart_calendar_db_get_last_change_version>(); + + /// @brief Retrieves changed exception records since the given calendar database version. + /// Exceptions are the modified or deleted instances in a recurring event. + /// @details This function finds all the changed records since the given @a calendar_db_version. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.read + /// @remarks You must release @a change_record_list using calendar_list_destroy(). + /// @param[in] view_uri The view URI to get records from + /// @param[in] original_event_id The original event ID + /// @param[in] calendar_db_version The calendar database version starting from which to get records + /// @param[out] list The record list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + /// @see calendar_list_destroy() + int calendar_db_get_changes_exception_by_version( + ffi.Pointer view_uri, + int original_event_id, + int calendar_db_version, + ffi.Pointer> list, + ) { + return _calendar_db_get_changes_exception_by_version( + view_uri, + original_event_id, + calendar_db_version, + list, + ); + } + + late final _calendar_db_get_changes_exception_by_version_ptr = _lookup< + ffi.NativeFunction<_c_calendar_db_get_changes_exception_by_version>>( + 'calendar_db_get_changes_exception_by_version'); + late final _dart_calendar_db_get_changes_exception_by_version + _calendar_db_get_changes_exception_by_version = + _calendar_db_get_changes_exception_by_version_ptr + .asFunction<_dart_calendar_db_get_changes_exception_by_version>(); + + /// @brief Cleans the data after sync. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.write + /// @param[in] calendar_book_id The calendar book ID + /// @param[in] calendar_db_version The calendar database version + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CALENDAR_ERROR_FILE_NO_SPACE File system is full + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_NO_DATA Data does not exist + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + int calendar_db_clean_after_sync( + int calendar_book_id, + int calendar_db_version, + ) { + return _calendar_db_clean_after_sync( + calendar_book_id, + calendar_db_version, + ); + } + + late final _calendar_db_clean_after_sync_ptr = + _lookup>( + 'calendar_db_clean_after_sync'); + late final _dart_calendar_db_clean_after_sync _calendar_db_clean_after_sync = + _calendar_db_clean_after_sync_ptr + .asFunction<_dart_calendar_db_clean_after_sync>(); + + /// @brief Links a record to another record. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.write + /// @param[in] base_id The base record ID + /// @param[in] record_id The record ID to link to + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CALENDAR_ERROR_FILE_NO_SPACE File system is full + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + int calendar_db_link_record( + int base_id, + int record_id, + ) { + return _calendar_db_link_record( + base_id, + record_id, + ); + } + + late final _calendar_db_link_record_ptr = + _lookup>( + 'calendar_db_link_record'); + late final _dart_calendar_db_link_record _calendar_db_link_record = + _calendar_db_link_record_ptr.asFunction<_dart_calendar_db_link_record>(); + + /// @brief Unlinks a record from base record. + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.write + /// @param[in] record_id The record ID to unlink + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #CALENDAR_ERROR_FILE_NO_SPACE File system is full + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to open a connection to the calendar service. + /// @see calendar_connect() + int calendar_db_unlink_record( + int record_id, + ) { + return _calendar_db_unlink_record( + record_id, + ); + } + + late final _calendar_db_unlink_record_ptr = + _lookup>( + 'calendar_db_unlink_record'); + late final _dart_calendar_db_unlink_record _calendar_db_unlink_record = + _calendar_db_unlink_record_ptr + .asFunction<_dart_calendar_db_unlink_record>(); + + /// @brief Creates a filter handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks You must release @a filter using calendar_filter_destroy(). + /// @param[in] view_uri The view URI of a filter + /// @param[out] filter The filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to initialize. + /// @see calendar_filter_destroy() + int calendar_filter_create( + ffi.Pointer view_uri, + ffi.Pointer> filter, + ) { + return _calendar_filter_create( + view_uri, + filter, + ); + } + + late final _calendar_filter_create_ptr = + _lookup>( + 'calendar_filter_create'); + late final _dart_calendar_filter_create _calendar_filter_create = + _calendar_filter_create_ptr.asFunction<_dart_calendar_filter_create>(); + + /// @brief Destroys a filter handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] filter The filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_filter_create() + int calendar_filter_destroy( + ffi.Pointer<__calendar_filter_h> filter, + ) { + return _calendar_filter_destroy( + filter, + ); + } + + late final _calendar_filter_destroy_ptr = + _lookup>( + 'calendar_filter_destroy'); + late final _dart_calendar_filter_destroy _calendar_filter_destroy = + _calendar_filter_destroy_ptr.asFunction<_dart_calendar_filter_destroy>(); + + /// @brief Adds a condition for the string type property. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] filter The filter handle + /// @param[in] property_id The property ID to add a condition + /// @param[in] match The match flag + /// @param[in] match_value The match value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_filter_add_operator() + int calendar_filter_add_str( + ffi.Pointer<__calendar_filter_h> filter, + int property_id, + int match, + ffi.Pointer match_value, + ) { + return _calendar_filter_add_str( + filter, + property_id, + match, + match_value, + ); + } + + late final _calendar_filter_add_str_ptr = + _lookup>( + 'calendar_filter_add_str'); + late final _dart_calendar_filter_add_str _calendar_filter_add_str = + _calendar_filter_add_str_ptr.asFunction<_dart_calendar_filter_add_str>(); + + /// @brief Adds a condition for the integer type property. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] filter The filter handle + /// @param[in] property_id The property ID to add a condition + /// @param[in] match The match flag + /// @param[in] match_value The match value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_filter_add_operator() + int calendar_filter_add_int( + ffi.Pointer<__calendar_filter_h> filter, + int property_id, + int match, + int match_value, + ) { + return _calendar_filter_add_int( + filter, + property_id, + match, + match_value, + ); + } + + late final _calendar_filter_add_int_ptr = + _lookup>( + 'calendar_filter_add_int'); + late final _dart_calendar_filter_add_int _calendar_filter_add_int = + _calendar_filter_add_int_ptr.asFunction<_dart_calendar_filter_add_int>(); + + /// @brief Adds a condition for the double type property. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] filter The filter handle + /// @param[in] property_id The property ID to add a condition + /// @param[in] match The match flag + /// @param[in] match_value The match value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_filter_add_operator() + int calendar_filter_add_double( + ffi.Pointer<__calendar_filter_h> filter, + int property_id, + int match, + double match_value, + ) { + return _calendar_filter_add_double( + filter, + property_id, + match, + match_value, + ); + } + + late final _calendar_filter_add_double_ptr = + _lookup>( + 'calendar_filter_add_double'); + late final _dart_calendar_filter_add_double _calendar_filter_add_double = + _calendar_filter_add_double_ptr + .asFunction<_dart_calendar_filter_add_double>(); + + /// @brief Adds a condition for the long long int type property. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] filter The filter handle + /// @param[in] property_id The property ID to add a condition + /// @param[in] match The match flag + /// @param[in] match_value The match value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_filter_add_operator() + int calendar_filter_add_lli( + ffi.Pointer<__calendar_filter_h> filter, + int property_id, + int match, + int match_value, + ) { + return _calendar_filter_add_lli( + filter, + property_id, + match, + match_value, + ); + } + + late final _calendar_filter_add_lli_ptr = + _lookup>( + 'calendar_filter_add_lli'); + late final _dart_calendar_filter_add_lli _calendar_filter_add_lli = + _calendar_filter_add_lli_ptr.asFunction<_dart_calendar_filter_add_lli>(); + + /// @brief Adds a child filter to a parent filter. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] parent_filter The parent filter handle + /// @param[in] child_filter The child filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_filter_add_operator() + int calendar_filter_add_filter( + ffi.Pointer<__calendar_filter_h> parent_filter, + ffi.Pointer<__calendar_filter_h> child_filter, + ) { + return _calendar_filter_add_filter( + parent_filter, + child_filter, + ); + } + + late final _calendar_filter_add_filter_ptr = + _lookup>( + 'calendar_filter_add_filter'); + late final _dart_calendar_filter_add_filter _calendar_filter_add_filter = + _calendar_filter_add_filter_ptr + .asFunction<_dart_calendar_filter_add_filter>(); + + /// @brief Adds an operator between conditions. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] filter The filter handle + /// @param[in] operator_type The operator type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_filter_add_str() + /// @see calendar_filter_add_int() + /// @see calendar_filter_add_double() + /// @see calendar_filter_add_caltime() + /// @see calendar_filter_add_filter() + int calendar_filter_add_operator( + ffi.Pointer<__calendar_filter_h> filter, + int operator_type, + ) { + return _calendar_filter_add_operator( + filter, + operator_type, + ); + } + + late final _calendar_filter_add_operator_ptr = + _lookup>( + 'calendar_filter_add_operator'); + late final _dart_calendar_filter_add_operator _calendar_filter_add_operator = + _calendar_filter_add_operator_ptr + .asFunction<_dart_calendar_filter_add_operator>(); + + /// @brief Creates a calendar list handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks You must release @a calendar_list using calendar_list_destroy(). + /// @param[out] out_list The calendar list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_list_destroy() + int calendar_list_create( + ffi.Pointer> out_list, + ) { + return _calendar_list_create( + out_list, + ); + } + + late final _calendar_list_create_ptr = + _lookup>( + 'calendar_list_create'); + late final _dart_calendar_list_create _calendar_list_create = + _calendar_list_create_ptr.asFunction<_dart_calendar_list_create>(); + + /// @brief Destroys a calendar list handle and releases all its resources. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] list The calendar list handle + /// @param[in] delete_record If @c true, child records are destroyed automatically, + /// otherwise @c false + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_list_create() + int calendar_list_destroy( + ffi.Pointer<__calendar_list_h> list, + bool delete_record, + ) { + return _calendar_list_destroy( + list, + delete_record ? 1 : 0, + ); + } + + late final _calendar_list_destroy_ptr = + _lookup>( + 'calendar_list_destroy'); + late final _dart_calendar_list_destroy _calendar_list_destroy = + _calendar_list_destroy_ptr.asFunction<_dart_calendar_list_destroy>(); + + /// @brief Retrieves the number of calendar entities in a calendar list. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] list The calendar list handle + /// @param[out] count The count of the calendar entity + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_list_add() + int calendar_list_get_count( + ffi.Pointer<__calendar_list_h> list, + ffi.Pointer count, + ) { + return _calendar_list_get_count( + list, + count, + ); + } + + late final _calendar_list_get_count_ptr = + _lookup>( + 'calendar_list_get_count'); + late final _dart_calendar_list_get_count _calendar_list_get_count = + _calendar_list_get_count_ptr.asFunction<_dart_calendar_list_get_count>(); + + /// @brief Adds a record to the calendar list. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] list The calendar list handle + /// @param[in] record The record handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_list_remove() + int calendar_list_add( + ffi.Pointer<__calendar_list_h> list, + ffi.Pointer<__calendar_record_h> record, + ) { + return _calendar_list_add( + list, + record, + ); + } + + late final _calendar_list_add_ptr = + _lookup>('calendar_list_add'); + late final _dart_calendar_list_add _calendar_list_add = + _calendar_list_add_ptr.asFunction<_dart_calendar_list_add>(); + + /// @brief Removes a record from the calendar list. + /// @details If the record is the current record, then the current record is changed to the next record.\n + /// If the record is the last record then the current record will be @c NULL. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] list The calendar list handle + /// @param[in] record The record handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NO_DATA Requested data does not exist + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_list_add() + int calendar_list_remove( + ffi.Pointer<__calendar_list_h> list, + ffi.Pointer<__calendar_record_h> record, + ) { + return _calendar_list_remove( + list, + record, + ); + } + + late final _calendar_list_remove_ptr = + _lookup>( + 'calendar_list_remove'); + late final _dart_calendar_list_remove _calendar_list_remove = + _calendar_list_remove_ptr.asFunction<_dart_calendar_list_remove>(); + + /// @brief Retrieves a record from the calendar list. + /// @details The default current record is the first record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks You MUST NOT destroy the @a record handle. + /// It is destroyed automatically when the @a list is destroyed. + /// @param[in] list The calendar list handle + /// @param[out] record The record handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NO_DATA Requested data does not exist + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + int calendar_list_get_current_record_p( + ffi.Pointer<__calendar_list_h> list, + ffi.Pointer> record, + ) { + return _calendar_list_get_current_record_p( + list, + record, + ); + } + + late final _calendar_list_get_current_record_p_ptr = + _lookup>( + 'calendar_list_get_current_record_p'); + late final _dart_calendar_list_get_current_record_p + _calendar_list_get_current_record_p = + _calendar_list_get_current_record_p_ptr + .asFunction<_dart_calendar_list_get_current_record_p>(); + + /// @brief Moves a calendar list to the previous position. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] list The calendar list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NO_DATA Requested data does not exist + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_list_next() + int calendar_list_prev( + ffi.Pointer<__calendar_list_h> list, + ) { + return _calendar_list_prev( + list, + ); + } + + late final _calendar_list_prev_ptr = + _lookup>('calendar_list_prev'); + late final _dart_calendar_list_prev _calendar_list_prev = + _calendar_list_prev_ptr.asFunction<_dart_calendar_list_prev>(); + + /// @brief Moves a calendar list to the next position. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] list The calendar list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NO_DATA Requested data does not exist + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_list_prev() + int calendar_list_next( + ffi.Pointer<__calendar_list_h> list, + ) { + return _calendar_list_next( + list, + ); + } + + late final _calendar_list_next_ptr = + _lookup>('calendar_list_next'); + late final _dart_calendar_list_next _calendar_list_next = + _calendar_list_next_ptr.asFunction<_dart_calendar_list_next>(); + + /// @brief Moves a calendar list to the first position. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] list The calendar list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_list_last() + int calendar_list_first( + ffi.Pointer<__calendar_list_h> list, + ) { + return _calendar_list_first( + list, + ); + } + + late final _calendar_list_first_ptr = + _lookup>( + 'calendar_list_first'); + late final _dart_calendar_list_first _calendar_list_first = + _calendar_list_first_ptr.asFunction<_dart_calendar_list_first>(); + + /// @brief Moves a calendar list to the last position. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] list The calendar list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_list_first() + int calendar_list_last( + ffi.Pointer<__calendar_list_h> list, + ) { + return _calendar_list_last( + list, + ); + } + + late final _calendar_list_last_ptr = + _lookup>('calendar_list_last'); + late final _dart_calendar_list_last _calendar_list_last = + _calendar_list_last_ptr.asFunction<_dart_calendar_list_last>(); + + /// @brief Creates a query handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks You must release @a query using calendar_query_destroy(). + /// @param[in] view_uri The view URI of a query + /// @param[out] query The filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to initialize. + /// @see calendar_query_destroy() + int calendar_query_create( + ffi.Pointer view_uri, + ffi.Pointer> query, + ) { + return _calendar_query_create( + view_uri, + query, + ); + } + + late final _calendar_query_create_ptr = + _lookup>( + 'calendar_query_create'); + late final _dart_calendar_query_create _calendar_query_create = + _calendar_query_create_ptr.asFunction<_dart_calendar_query_create>(); + + /// @brief Destroys a query handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] query The query handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_query_create() + int calendar_query_destroy( + ffi.Pointer<__calendar_query_h> query, + ) { + return _calendar_query_destroy( + query, + ); + } + + late final _calendar_query_destroy_ptr = + _lookup>( + 'calendar_query_destroy'); + late final _dart_calendar_query_destroy _calendar_query_destroy = + _calendar_query_destroy_ptr.asFunction<_dart_calendar_query_destroy>(); + + /// @brief Adds property IDs for projection. + /// @details Property IDs can be of one of the properties of view_uri which is used in calendar_query_create(). + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] query The query handle + /// @param[in] property_id_array The property ID array + /// @param[in] count The number of property IDs + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + int calendar_query_set_projection( + ffi.Pointer<__calendar_query_h> query, + ffi.Pointer property_id_array, + int count, + ) { + return _calendar_query_set_projection( + query, + property_id_array, + count, + ); + } + + late final _calendar_query_set_projection_ptr = + _lookup>( + 'calendar_query_set_projection'); + late final _dart_calendar_query_set_projection + _calendar_query_set_projection = _calendar_query_set_projection_ptr + .asFunction<_dart_calendar_query_set_projection>(); + + /// @brief Sets the "distinct" option for projection. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] query The query handle + /// @param[in] set If @c true it is set, + /// otherwise if @c false it is unset + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + int calendar_query_set_distinct( + ffi.Pointer<__calendar_query_h> query, + bool set_1, + ) { + return _calendar_query_set_distinct( + query, + set_1 ? 1 : 0, + ); + } + + late final _calendar_query_set_distinct_ptr = + _lookup>( + 'calendar_query_set_distinct'); + late final _dart_calendar_query_set_distinct _calendar_query_set_distinct = + _calendar_query_set_distinct_ptr + .asFunction<_dart_calendar_query_set_distinct>(); + + /// @brief Sets the filter for a query. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] query The query handle + /// @param[in] filter The filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NO_DATA Requested data does not exist + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_query_add_operator() + int calendar_query_set_filter( + ffi.Pointer<__calendar_query_h> query, + ffi.Pointer<__calendar_filter_h> filter, + ) { + return _calendar_query_set_filter( + query, + filter, + ); + } + + late final _calendar_query_set_filter_ptr = + _lookup>( + 'calendar_query_set_filter'); + late final _dart_calendar_query_set_filter _calendar_query_set_filter = + _calendar_query_set_filter_ptr + .asFunction<_dart_calendar_query_set_filter>(); + + /// @brief Sets the sort mode for a query. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] query The query handle + /// @param[in] property_id The property ID to sort + /// @param[in] is_ascending If @c true it sorts in the ascending order, + /// otherwise if @c false it sorts in the descending order + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + int calendar_query_set_sort( + ffi.Pointer<__calendar_query_h> query, + int property_id, + bool is_ascending, + ) { + return _calendar_query_set_sort( + query, + property_id, + is_ascending ? 1 : 0, + ); + } + + late final _calendar_query_set_sort_ptr = + _lookup>( + 'calendar_query_set_sort'); + late final _dart_calendar_query_set_sort _calendar_query_set_sort = + _calendar_query_set_sort_ptr.asFunction<_dart_calendar_query_set_sort>(); + + /// @brief Creates a record handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks You must release @a record using calendar_record_destroy(). + /// @param[in] view_uri The view URI + /// @param[out] out_record The record handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to initialize. + /// @see calendar_record_destroy() + int calendar_record_create( + ffi.Pointer view_uri, + ffi.Pointer> out_record, + ) { + return _calendar_record_create( + view_uri, + out_record, + ); + } + + late final _calendar_record_create_ptr = + _lookup>( + 'calendar_record_create'); + late final _dart_calendar_record_create _calendar_record_create = + _calendar_record_create_ptr.asFunction<_dart_calendar_record_create>(); + + /// @brief Destroys a record handle and releases all its resources. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] record The record handle + /// @param[in] delete_child If @c true, child records are destroyed automatically, + /// otherwise @c false + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_create() + int calendar_record_destroy( + ffi.Pointer<__calendar_record_h> record, + bool delete_child, + ) { + return _calendar_record_destroy( + record, + delete_child ? 1 : 0, + ); + } + + late final _calendar_record_destroy_ptr = + _lookup>( + 'calendar_record_destroy'); + late final _dart_calendar_record_destroy _calendar_record_destroy = + _calendar_record_destroy_ptr.asFunction<_dart_calendar_record_destroy>(); + + /// @brief Makes a clone of a record handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks You must release @a cloned_record using calendar_record_destroy(). + /// @param[in] record The record handle + /// @param[out] out_record The cloned record handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_destroy() + int calendar_record_clone( + ffi.Pointer<__calendar_record_h> record, + ffi.Pointer> out_record, + ) { + return _calendar_record_clone( + record, + out_record, + ); + } + + late final _calendar_record_clone_ptr = + _lookup>( + 'calendar_record_clone'); + late final _dart_calendar_record_clone _calendar_record_clone = + _calendar_record_clone_ptr.asFunction<_dart_calendar_record_clone>(); + + /// @brief Gets a URI string from a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] record The record handle + /// @param[out] uri The URI of the record + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + int calendar_record_get_uri_p( + ffi.Pointer<__calendar_record_h> record, + ffi.Pointer> uri, + ) { + return _calendar_record_get_uri_p( + record, + uri, + ); + } + + late final _calendar_record_get_uri_p_ptr = + _lookup>( + 'calendar_record_get_uri_p'); + late final _dart_calendar_record_get_uri_p _calendar_record_get_uri_p = + _calendar_record_get_uri_p_ptr + .asFunction<_dart_calendar_record_get_uri_p>(); + + /// @brief Gets a string from a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks You must release @a value using free(). + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[out] out_str The result value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_get_str_p() + /// @see calendar_record_set_str() + int calendar_record_get_str( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer> out_str, + ) { + return _calendar_record_get_str( + record, + property_id, + out_str, + ); + } + + late final _calendar_record_get_str_ptr = + _lookup>( + 'calendar_record_get_str'); + late final _dart_calendar_record_get_str _calendar_record_get_str = + _calendar_record_get_str_ptr.asFunction<_dart_calendar_record_get_str>(); + + /// @brief Gets a string pointer from a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks You MUST NOT release @a value. + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[out] out_str The result value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_get_str() + /// @see calendar_record_set_str() + int calendar_record_get_str_p( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer> out_str, + ) { + return _calendar_record_get_str_p( + record, + property_id, + out_str, + ); + } + + late final _calendar_record_get_str_p_ptr = + _lookup>( + 'calendar_record_get_str_p'); + late final _dart_calendar_record_get_str_p _calendar_record_get_str_p = + _calendar_record_get_str_p_ptr + .asFunction<_dart_calendar_record_get_str_p>(); + + /// @brief Gets an integer value from a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[out] out_value The result value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_set_int() + int calendar_record_get_int( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer out_value, + ) { + return _calendar_record_get_int( + record, + property_id, + out_value, + ); + } + + late final _calendar_record_get_int_ptr = + _lookup>( + 'calendar_record_get_int'); + late final _dart_calendar_record_get_int _calendar_record_get_int = + _calendar_record_get_int_ptr.asFunction<_dart_calendar_record_get_int>(); + + /// @brief Gets a double value from a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[out] out_value The result value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_set_double() + int calendar_record_get_double( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer out_value, + ) { + return _calendar_record_get_double( + record, + property_id, + out_value, + ); + } + + late final _calendar_record_get_double_ptr = + _lookup>( + 'calendar_record_get_double'); + late final _dart_calendar_record_get_double _calendar_record_get_double = + _calendar_record_get_double_ptr + .asFunction<_dart_calendar_record_get_double>(); + + /// @brief Gets a long long integer value from a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[out] out_value The result value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_set_lli() + int calendar_record_get_lli( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer out_value, + ) { + return _calendar_record_get_lli( + record, + property_id, + out_value, + ); + } + + late final _calendar_record_get_lli_ptr = + _lookup>( + 'calendar_record_get_lli'); + late final _dart_calendar_record_get_lli _calendar_record_get_lli = + _calendar_record_get_lli_ptr.asFunction<_dart_calendar_record_get_lli>(); + + /// @brief Gets a calendar_caltime_s value from a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[out] out_value The result value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_set_caltime() + int calendar_record_get_caltime( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer out_value, + ) { + return _calendar_record_get_caltime( + record, + property_id, + out_value, + ); + } + + late final _calendar_record_get_caltime_ptr = + _lookup>( + 'calendar_record_get_caltime'); + late final _dart_calendar_record_get_caltime _calendar_record_get_caltime = + _calendar_record_get_caltime_ptr + .asFunction<_dart_calendar_record_get_caltime>(); + + /// @brief Sets a string to a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[in] value The value to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_get_str() + /// @see calendar_record_get_str_p() + int calendar_record_set_str( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer value, + ) { + return _calendar_record_set_str( + record, + property_id, + value, + ); + } + + late final _calendar_record_set_str_ptr = + _lookup>( + 'calendar_record_set_str'); + late final _dart_calendar_record_set_str _calendar_record_set_str = + _calendar_record_set_str_ptr.asFunction<_dart_calendar_record_set_str>(); + + /// @brief Sets an integer value to a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[in] value The value to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_get_int() + int calendar_record_set_int( + ffi.Pointer<__calendar_record_h> record, + int property_id, + int value, + ) { + return _calendar_record_set_int( + record, + property_id, + value, + ); + } + + late final _calendar_record_set_int_ptr = + _lookup>( + 'calendar_record_set_int'); + late final _dart_calendar_record_set_int _calendar_record_set_int = + _calendar_record_set_int_ptr.asFunction<_dart_calendar_record_set_int>(); + + /// @brief Sets a double value to a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[in] value The value to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_get_double() + int calendar_record_set_double( + ffi.Pointer<__calendar_record_h> record, + int property_id, + double value, + ) { + return _calendar_record_set_double( + record, + property_id, + value, + ); + } + + late final _calendar_record_set_double_ptr = + _lookup>( + 'calendar_record_set_double'); + late final _dart_calendar_record_set_double _calendar_record_set_double = + _calendar_record_set_double_ptr + .asFunction<_dart_calendar_record_set_double>(); + + /// @brief Sets a long long integer value to a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[in] value The value to be set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_get_lli() + int calendar_record_set_lli( + ffi.Pointer<__calendar_record_h> record, + int property_id, + int value, + ) { + return _calendar_record_set_lli( + record, + property_id, + value, + ); + } + + late final _calendar_record_set_lli_ptr = + _lookup>( + 'calendar_record_set_lli'); + late final _dart_calendar_record_set_lli _calendar_record_set_lli = + _calendar_record_set_lli_ptr.asFunction<_dart_calendar_record_set_lli>(); + + /// @brief Adds a child record to the parent record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] record The parent record handle + /// @param[in] property_id The property ID + /// @param[in] child_record The handle of the child record to be added to the parent record + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_remove_child_record() + int calendar_record_add_child_record( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer<__calendar_record_h> child_record, + ) { + return _calendar_record_add_child_record( + record, + property_id, + child_record, + ); + } + + late final _calendar_record_add_child_record_ptr = + _lookup>( + 'calendar_record_add_child_record'); + late final _dart_calendar_record_add_child_record + _calendar_record_add_child_record = _calendar_record_add_child_record_ptr + .asFunction<_dart_calendar_record_add_child_record>(); + + /// @brief Removes a child record from the parent record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] record The parent record handle + /// @param[in] property_id The property ID + /// @param[in] child_record The handle of the child record to be removed from the parent record + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_add_child_record() + int calendar_record_remove_child_record( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer<__calendar_record_h> child_record, + ) { + return _calendar_record_remove_child_record( + record, + property_id, + child_record, + ); + } + + late final _calendar_record_remove_child_record_ptr = + _lookup>( + 'calendar_record_remove_child_record'); + late final _dart_calendar_record_remove_child_record + _calendar_record_remove_child_record = + _calendar_record_remove_child_record_ptr + .asFunction<_dart_calendar_record_remove_child_record>(); + + /// @brief Gets the number of child records in a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] record The parent record handle + /// @param[in] property_id The property ID + /// @param[out] count The child record count + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_add_child_record() + /// @see calendar_record_remove_child_record() + int calendar_record_get_child_record_count( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer count, + ) { + return _calendar_record_get_child_record_count( + record, + property_id, + count, + ); + } + + late final _calendar_record_get_child_record_count_ptr = + _lookup>( + 'calendar_record_get_child_record_count'); + late final _dart_calendar_record_get_child_record_count + _calendar_record_get_child_record_count = + _calendar_record_get_child_record_count_ptr + .asFunction<_dart_calendar_record_get_child_record_count>(); + + /// @brief Gets a child record handle pointer from the parent record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks You MUST NOT release @a child_record. \n + /// It is released when the parent record handle is destroyed. + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[in] index The index of the child record + /// @param[out] child_record The child record handle pointer + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_record_add_child_record() + /// @see calendar_record_remove_child_record() + /// @see calendar_record_get_child_record_count() + int calendar_record_get_child_record_at_p( + ffi.Pointer<__calendar_record_h> record, + int property_id, + int index, + ffi.Pointer> child_record, + ) { + return _calendar_record_get_child_record_at_p( + record, + property_id, + index, + child_record, + ); + } + + late final _calendar_record_get_child_record_at_p_ptr = + _lookup>( + 'calendar_record_get_child_record_at_p'); + late final _dart_calendar_record_get_child_record_at_p + _calendar_record_get_child_record_at_p = + _calendar_record_get_child_record_at_p_ptr + .asFunction<_dart_calendar_record_get_child_record_at_p>(); + + /// @brief Makes a clone of a given record's child record list. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks You must release @a cloned_list using calendar_list_destroy(). + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[out] out_list The cloned list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_list_destroy() + int calendar_record_clone_child_record_list( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer> out_list, + ) { + return _calendar_record_clone_child_record_list( + record, + property_id, + out_list, + ); + } + + late final _calendar_record_clone_child_record_list_ptr = + _lookup>( + 'calendar_record_clone_child_record_list'); + late final _dart_calendar_record_clone_child_record_list + _calendar_record_clone_child_record_list = + _calendar_record_clone_child_record_list_ptr + .asFunction<_dart_calendar_record_clone_child_record_list>(); + + /// @brief Connects to the calendar service. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks Opening the connection is necessary to access the calendar database and perform operations such as fetching, inserting, or updating records.\n + /// The execution of calendar_connect() and calendar_disconnect() could slow down your application, so you are recommended not to call them frequently. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_disconnect() + int calendar_connect() { + return _calendar_connect(); + } + + late final _calendar_connect_ptr = + _lookup>('calendar_connect'); + late final _dart_calendar_connect _calendar_connect = + _calendar_connect_ptr.asFunction<_dart_calendar_connect>(); + + /// @brief Disconnects from the calendar service. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks If there is no open connection, this function returns #CALENDAR_ERROR_DB_FAILED. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_connect() + int calendar_disconnect() { + return _calendar_disconnect(); + } + + late final _calendar_disconnect_ptr = + _lookup>( + 'calendar_disconnect'); + late final _dart_calendar_disconnect _calendar_disconnect = + _calendar_disconnect_ptr.asFunction<_dart_calendar_disconnect>(); + + /// @brief Connects to the calendar service on a thread. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks Opening a connection is necessary to access the calendar database and perform operations such as fetching, inserting, or updating records.\n + /// On a thread environment with calendar_connect(), request in one thread could fail, while another request connection is working in the other thread. + /// To prevent request failure, calendar_connect_on_thread() is recommended. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_disconnect_on_thread() + int calendar_connect_on_thread() { + return _calendar_connect_on_thread(); + } + + late final _calendar_connect_on_thread_ptr = + _lookup>( + 'calendar_connect_on_thread'); + late final _dart_calendar_connect_on_thread _calendar_connect_on_thread = + _calendar_connect_on_thread_ptr + .asFunction<_dart_calendar_connect_on_thread>(); + + /// @brief Disconnects from the calendar service on a thread. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks If there is no open connection, this function returns #CALENDAR_ERROR_DB_FAILED. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_connect_on_thread() + int calendar_disconnect_on_thread() { + return _calendar_disconnect_on_thread(); + } + + late final _calendar_disconnect_on_thread_ptr = + _lookup>( + 'calendar_disconnect_on_thread'); + late final _dart_calendar_disconnect_on_thread + _calendar_disconnect_on_thread = _calendar_disconnect_on_thread_ptr + .asFunction<_dart_calendar_disconnect_on_thread>(); + + /// @brief Connects to the calendar service. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @remarks Opening a connection is necessary to access the calendar database and perform operations such as fetching, inserting, or updating records.\n + /// Before the calendar-service daemon is ready, if you call calendar_connect(), it could fail. + /// It is recommended to call this API with #CALENDAR_CONNECT_FLAG_RETRY flags in such a situation. + /// @param[in] flags calendar_connect_flag + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_disconnect(), CALENDAR_CONNECT_FLAG_RETRY + int calendar_connect_with_flags( + int flags, + ) { + return _calendar_connect_with_flags( + flags, + ); + } + + late final _calendar_connect_with_flags_ptr = + _lookup>( + 'calendar_connect_with_flags'); + late final _dart_calendar_connect_with_flags _calendar_connect_with_flags = + _calendar_connect_with_flags_ptr + .asFunction<_dart_calendar_connect_with_flags>(); + + /// @brief Retrieves a vcalendar stream from a calendar list. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] calendar_list The calendar list handle + /// @param[out] vcalendar_stream The vcalendar stream + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NO_DATA Requested data does not exist + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + int calendar_vcalendar_make_from_records( + ffi.Pointer<__calendar_list_h> calendar_list, + ffi.Pointer> vcalendar_stream, + ) { + return _calendar_vcalendar_make_from_records( + calendar_list, + vcalendar_stream, + ); + } + + late final _calendar_vcalendar_make_from_records_ptr = + _lookup>( + 'calendar_vcalendar_make_from_records'); + late final _dart_calendar_vcalendar_make_from_records + _calendar_vcalendar_make_from_records = + _calendar_vcalendar_make_from_records_ptr + .asFunction<_dart_calendar_vcalendar_make_from_records>(); + + /// @brief Retrieves all calendars from a vcalendar stream. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] vcalendar_stream The vcalendar stream + /// @param[out] calendar_list The calendar list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_NO_DATA Requested data does not exist + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to initialize. + int calendar_vcalendar_parse_to_calendar( + ffi.Pointer vcalendar_stream, + ffi.Pointer> calendar_list, + ) { + return _calendar_vcalendar_parse_to_calendar( + vcalendar_stream, + calendar_list, + ); + } + + late final _calendar_vcalendar_parse_to_calendar_ptr = + _lookup>( + 'calendar_vcalendar_parse_to_calendar'); + late final _dart_calendar_vcalendar_parse_to_calendar + _calendar_vcalendar_parse_to_calendar = + _calendar_vcalendar_parse_to_calendar_ptr + .asFunction<_dart_calendar_vcalendar_parse_to_calendar>(); + + /// @brief Retrieves all events or to-dos + /// (\ref CAPI_SOCIAL_CALENDAR_SVC_VIEW_MODULE_calendar_event or \ref CAPI_SOCIAL_CALENDAR_SVC_VIEW_MODULE_calendar_todo) from a vCalendar file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] vcalendar_file_path The file path of the vCalendar stream file + /// @param[in] callback The callback function to be invoked + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @pre calendar_connect() should be called to initialize. + /// @post This function invokes calendar_vcalendar_parse_cb(). + /// @see calendar_vcalendar_parse_cb() + /// @see calendar_record_get_uri_p() + int calendar_vcalendar_parse_to_calendar_foreach( + ffi.Pointer vcalendar_file_path, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _calendar_vcalendar_parse_to_calendar_foreach( + vcalendar_file_path, + callback, + user_data, + ); + } + + late final _calendar_vcalendar_parse_to_calendar_foreach_ptr = _lookup< + ffi.NativeFunction<_c_calendar_vcalendar_parse_to_calendar_foreach>>( + 'calendar_vcalendar_parse_to_calendar_foreach'); + late final _dart_calendar_vcalendar_parse_to_calendar_foreach + _calendar_vcalendar_parse_to_calendar_foreach = + _calendar_vcalendar_parse_to_calendar_foreach_ptr + .asFunction<_dart_calendar_vcalendar_parse_to_calendar_foreach>(); + + /// @brief Adds a callback to get a notification when an alarm gives an alert. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/calendar.read + /// @param[in] callback The callback to be added + /// @param[in] user_data The user data + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CALENDAR_ERROR_NOT_PERMITTED Operation not permitted + /// @retval #CALENDAR_ERROR_IPC Unknown IPC error + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_reminder_remove_cb() + int calendar_reminder_add_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _calendar_reminder_add_cb( + callback, + user_data, + ); + } + + late final _calendar_reminder_add_cb_ptr = + _lookup>( + 'calendar_reminder_add_cb'); + late final _dart_calendar_reminder_add_cb _calendar_reminder_add_cb = + _calendar_reminder_add_cb_ptr + .asFunction<_dart_calendar_reminder_add_cb>(); + + /// @brief Removes a callback to get a notification when an alarm gives an alert. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif + /// @param[in] callback The callback to be removed + /// @param[in] user_data The user data + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CALENDAR_ERROR_NONE Successful + /// @retval #CALENDAR_ERROR_DB_FAILED Database operation failure + /// @retval #CALENDAR_ERROR_SYSTEM Internal system module error + /// @retval #CALENDAR_ERROR_NOT_SUPPORTED Not supported + /// @see calendar_reminder_add_cb() + int calendar_reminder_remove_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _calendar_reminder_remove_cb( + callback, + user_data, + ); + } + + late final _calendar_reminder_remove_cb_ptr = + _lookup>( + 'calendar_reminder_remove_cb'); + late final _dart_calendar_reminder_remove_cb _calendar_reminder_remove_cb = + _calendar_reminder_remove_cb_ptr + .asFunction<_dart_calendar_reminder_remove_cb>(); + + /// @brief Connects to the contacts service. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks Connection opening is necessary to access the contacts server such as fetching, inserting, or updating records.\n + /// The execution of contacts_connect() and contacts_disconnect() could slow down your application. So it is not recommended to call them frequently. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM System error + /// @retval #CONTACTS_ERROR_INTERNAL Internal error + /// @see contacts_disconnect() + int contacts_connect() { + return _contacts_connect(); + } + + late final _contacts_connect_ptr = + _lookup>('contacts_connect'); + late final _dart_contacts_connect _contacts_connect = + _contacts_connect_ptr.asFunction<_dart_contacts_connect>(); + + /// @brief Disconnects from the contacts service. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks If there is no opened connection, this function returns #CONTACTS_ERROR_DB. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM System error + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @see contacts_connect() + int contacts_disconnect() { + return _contacts_disconnect(); + } + + late final _contacts_disconnect_ptr = + _lookup>( + 'contacts_disconnect'); + late final _dart_contacts_disconnect _contacts_disconnect = + _contacts_disconnect_ptr.asFunction<_dart_contacts_disconnect>(); + + /// @brief Connects to the contacts service with a connection on another thread. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks Opening connection is necessary to access the contact server and to perform operations such as fetching, inserting, or updating records.\n + /// On multiple thread environment with contacts_connect(), request can be failed in one thread, while another request is working by the connection in the other thread. + /// To prevent request fail, contacts_connect_on_thread() is recommended. Then new connection is set for the thread. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM System error + /// @retval #CONTACTS_ERROR_INTERNAL Internal error + /// @see contacts_disconnect_on_thread() + int contacts_connect_on_thread() { + return _contacts_connect_on_thread(); + } + + late final _contacts_connect_on_thread_ptr = + _lookup>( + 'contacts_connect_on_thread'); + late final _dart_contacts_connect_on_thread _contacts_connect_on_thread = + _contacts_connect_on_thread_ptr + .asFunction<_dart_contacts_connect_on_thread>(); + + /// @brief Disconnects from the contacts service. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks If there is no opened connection, this function returns #CONTACTS_ERROR_DB. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM System error + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @see contacts_connect_on_thread() + int contacts_disconnect_on_thread() { + return _contacts_disconnect_on_thread(); + } + + late final _contacts_disconnect_on_thread_ptr = + _lookup>( + 'contacts_disconnect_on_thread'); + late final _dart_contacts_disconnect_on_thread + _contacts_disconnect_on_thread = _contacts_disconnect_on_thread_ptr + .asFunction<_dart_contacts_disconnect_on_thread>(); + + /// @brief Connects to the contacts service. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] flags Connection flag + /// @remarks Connection opening is necessary to access the contacts server such as fetching, inserting, or updating records.\n + /// Before contacts-service daemon is ready, if you call contacts_connect(), it will fail. + /// To prevent it, if you call this API with @ref CONTACTS_CONNECT_FLAG_RETRY flags, it will retry several time.\n + /// To close the connection, contacts_disconnect() should be called. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM System error + /// @retval #CONTACTS_ERROR_INTERNAL Internal error + /// @see contacts_disconnect() + int contacts_connect_with_flags( + int flags, + ) { + return _contacts_connect_with_flags( + flags, + ); + } + + late final _contacts_connect_with_flags_ptr = + _lookup>( + 'contacts_connect_with_flags'); + late final _dart_contacts_connect_with_flags _contacts_connect_with_flags = + _contacts_connect_with_flags_ptr + .asFunction<_dart_contacts_connect_with_flags>(); + + late final ffi.Pointer<_contacts_address_book_property_ids> + __contacts_address_book = + _lookup<_contacts_address_book_property_ids>('_contacts_address_book'); + + _contacts_address_book_property_ids get _contacts_address_book => + __contacts_address_book.ref; + + late final ffi.Pointer<_contacts_group_property_ids> __contacts_group = + _lookup<_contacts_group_property_ids>('_contacts_group'); + + _contacts_group_property_ids get _contacts_group => __contacts_group.ref; + + late final ffi.Pointer<_contacts_person_property_ids> __contacts_person = + _lookup<_contacts_person_property_ids>('_contacts_person'); + + _contacts_person_property_ids get _contacts_person => __contacts_person.ref; + + late final ffi.Pointer<_contacts_simple_contact_property_ids> + __contacts_simple_contact = + _lookup<_contacts_simple_contact_property_ids>( + '_contacts_simple_contact'); + + _contacts_simple_contact_property_ids get _contacts_simple_contact => + __contacts_simple_contact.ref; + + late final ffi.Pointer<_contacts_contact_property_ids> __contacts_contact = + _lookup<_contacts_contact_property_ids>('_contacts_contact'); + + _contacts_contact_property_ids get _contacts_contact => + __contacts_contact.ref; + + late final ffi.Pointer<_contacts_my_profile_property_ids> + __contacts_my_profile = + _lookup<_contacts_my_profile_property_ids>('_contacts_my_profile'); + + _contacts_my_profile_property_ids get _contacts_my_profile => + __contacts_my_profile.ref; + + late final ffi.Pointer<_contacts_name_property_ids> __contacts_name = + _lookup<_contacts_name_property_ids>('_contacts_name'); + + _contacts_name_property_ids get _contacts_name => __contacts_name.ref; + + late final ffi.Pointer<_contacts_number_property_ids> __contacts_number = + _lookup<_contacts_number_property_ids>('_contacts_number'); + + _contacts_number_property_ids get _contacts_number => __contacts_number.ref; + + late final ffi.Pointer<_contacts_email_property_ids> __contacts_email = + _lookup<_contacts_email_property_ids>('_contacts_email'); + + _contacts_email_property_ids get _contacts_email => __contacts_email.ref; + + late final ffi.Pointer<_contacts_address_property_ids> __contacts_address = + _lookup<_contacts_address_property_ids>('_contacts_address'); + + _contacts_address_property_ids get _contacts_address => + __contacts_address.ref; + + late final ffi.Pointer<_contacts_note_property_ids> __contacts_note = + _lookup<_contacts_note_property_ids>('_contacts_note'); + + _contacts_note_property_ids get _contacts_note => __contacts_note.ref; + + late final ffi.Pointer<_contacts_url_property_ids> __contacts_url = + _lookup<_contacts_url_property_ids>('_contacts_url'); + + _contacts_url_property_ids get _contacts_url => __contacts_url.ref; + + late final ffi.Pointer<_contacts_event_property_ids> __contacts_event = + _lookup<_contacts_event_property_ids>('_contacts_event'); + + _contacts_event_property_ids get _contacts_event => __contacts_event.ref; + + late final ffi.Pointer<_contacts_group_relation_property_ids> + __contacts_group_relation = + _lookup<_contacts_group_relation_property_ids>( + '_contacts_group_relation'); + + _contacts_group_relation_property_ids get _contacts_group_relation => + __contacts_group_relation.ref; + + late final ffi.Pointer<_contacts_relationship_property_ids> + __contacts_relationship = + _lookup<_contacts_relationship_property_ids>('_contacts_relationship'); + + _contacts_relationship_property_ids get _contacts_relationship => + __contacts_relationship.ref; + + late final ffi.Pointer<_contacts_image_property_ids> __contacts_image = + _lookup<_contacts_image_property_ids>('_contacts_image'); + + _contacts_image_property_ids get _contacts_image => __contacts_image.ref; + + late final ffi.Pointer<_contacts_company_property_ids> __contacts_company = + _lookup<_contacts_company_property_ids>('_contacts_company'); + + _contacts_company_property_ids get _contacts_company => + __contacts_company.ref; + + late final ffi.Pointer<_contacts_nickname_property_ids> __contacts_nickname = + _lookup<_contacts_nickname_property_ids>('_contacts_nickname'); + + _contacts_nickname_property_ids get _contacts_nickname => + __contacts_nickname.ref; + + late final ffi.Pointer<_contacts_messenger_property_ids> + __contacts_messenger = + _lookup<_contacts_messenger_property_ids>('_contacts_messenger'); + + _contacts_messenger_property_ids get _contacts_messenger => + __contacts_messenger.ref; + + late final ffi.Pointer<_contacts_extension_property_ids> + __contacts_extension = + _lookup<_contacts_extension_property_ids>('_contacts_extension'); + + _contacts_extension_property_ids get _contacts_extension => + __contacts_extension.ref; + + late final ffi.Pointer<_contacts_sdn_property_ids> __contacts_sdn = + _lookup<_contacts_sdn_property_ids>('_contacts_sdn'); + + _contacts_sdn_property_ids get _contacts_sdn => __contacts_sdn.ref; + + late final ffi.Pointer<_contacts_profile_property_ids> __contacts_profile = + _lookup<_contacts_profile_property_ids>('_contacts_profile'); + + _contacts_profile_property_ids get _contacts_profile => + __contacts_profile.ref; + + late final ffi.Pointer<_contacts_activity_photo_property_ids> + __contacts_activity_photo = + _lookup<_contacts_activity_photo_property_ids>( + '_contacts_activity_photo'); + + _contacts_activity_photo_property_ids get _contacts_activity_photo => + __contacts_activity_photo.ref; + + late final ffi.Pointer<_contacts_activity_property_ids> __contacts_activity = + _lookup<_contacts_activity_property_ids>('_contacts_activity'); + + _contacts_activity_property_ids get _contacts_activity => + __contacts_activity.ref; + + late final ffi.Pointer<_contacts_speeddial_property_ids> + __contacts_speeddial = + _lookup<_contacts_speeddial_property_ids>('_contacts_speeddial'); + + _contacts_speeddial_property_ids get _contacts_speeddial => + __contacts_speeddial.ref; + + late final ffi.Pointer<_contacts_phone_log_property_ids> + __contacts_phone_log = + _lookup<_contacts_phone_log_property_ids>('_contacts_phone_log'); + + _contacts_phone_log_property_ids get _contacts_phone_log => + __contacts_phone_log.ref; + + late final ffi.Pointer<_contacts_contact_updated_info_property_ids> + __contacts_contact_updated_info = + _lookup<_contacts_contact_updated_info_property_ids>( + '_contacts_contact_updated_info'); + + _contacts_contact_updated_info_property_ids + get _contacts_contact_updated_info => __contacts_contact_updated_info.ref; + + late final ffi.Pointer<_contacts_my_profile_updated_info_property_ids> + __contacts_my_profile_updated_info = + _lookup<_contacts_my_profile_updated_info_property_ids>( + '_contacts_my_profile_updated_info'); + + _contacts_my_profile_updated_info_property_ids + get _contacts_my_profile_updated_info => + __contacts_my_profile_updated_info.ref; + + late final ffi.Pointer<_contacts_group_updated_info_property_ids> + __contacts_group_updated_info = + _lookup<_contacts_group_updated_info_property_ids>( + '_contacts_group_updated_info'); + + _contacts_group_updated_info_property_ids get _contacts_group_updated_info => + __contacts_group_updated_info.ref; + + late final ffi.Pointer<_contacts_group_member_updated_info_property_ids> + __contacts_group_member_updated_info = + _lookup<_contacts_group_member_updated_info_property_ids>( + '_contacts_group_member_updated_info'); + + _contacts_group_member_updated_info_property_ids + get _contacts_group_member_updated_info => + __contacts_group_member_updated_info.ref; + + late final ffi.Pointer<_contacts_grouprel_updated_info_property_ids> + __contacts_grouprel_updated_info = + _lookup<_contacts_grouprel_updated_info_property_ids>( + '_contacts_grouprel_updated_info'); + + _contacts_grouprel_updated_info_property_ids + get _contacts_grouprel_updated_info => + __contacts_grouprel_updated_info.ref; + + late final ffi.Pointer<_contacts_person_contact_property_ids> + __contacts_person_contact = + _lookup<_contacts_person_contact_property_ids>( + '_contacts_person_contact'); + + _contacts_person_contact_property_ids get _contacts_person_contact => + __contacts_person_contact.ref; + + late final ffi.Pointer<_contacts_person_number_property_ids> + __contacts_person_number = + _lookup<_contacts_person_number_property_ids>('_contacts_person_number'); + + _contacts_person_number_property_ids get _contacts_person_number => + __contacts_person_number.ref; + + late final ffi.Pointer<_contacts_person_email_property_ids> + __contacts_person_email = + _lookup<_contacts_person_email_property_ids>('_contacts_person_email'); + + _contacts_person_email_property_ids get _contacts_person_email => + __contacts_person_email.ref; + + late final ffi.Pointer<_contacts_person_grouprel_property_ids> + __contacts_person_grouprel = + _lookup<_contacts_person_grouprel_property_ids>( + '_contacts_person_grouprel'); + + _contacts_person_grouprel_property_ids get _contacts_person_grouprel => + __contacts_person_grouprel.ref; + + late final ffi.Pointer<_contacts_person_group_assigned_property_ids> + __contacts_person_group_assigned = + _lookup<_contacts_person_group_assigned_property_ids>( + '_contacts_person_group_assigned'); + + _contacts_person_group_assigned_property_ids + get _contacts_person_group_assigned => + __contacts_person_group_assigned.ref; + + late final ffi.Pointer<_contacts_person_group_not_assigned_property_ids> + __contacts_person_group_not_assigned = + _lookup<_contacts_person_group_not_assigned_property_ids>( + '_contacts_person_group_not_assigned'); + + _contacts_person_group_not_assigned_property_ids + get _contacts_person_group_not_assigned => + __contacts_person_group_not_assigned.ref; + + late final ffi.Pointer<_contacts_person_phone_log_property_ids> + __contacts_person_phone_log = + _lookup<_contacts_person_phone_log_property_ids>( + '_contacts_person_phone_log'); + + _contacts_person_phone_log_property_ids get _contacts_person_phone_log => + __contacts_person_phone_log.ref; + + late final ffi.Pointer<_contacts_person_usage_property_ids> + __contacts_person_usage = + _lookup<_contacts_person_usage_property_ids>('_contacts_person_usage'); + + _contacts_person_usage_property_ids get _contacts_person_usage => + __contacts_person_usage.ref; + + late final ffi.Pointer<_contacts_contact_number_property_ids> + __contacts_contact_number = + _lookup<_contacts_contact_number_property_ids>( + '_contacts_contact_number'); + + _contacts_contact_number_property_ids get _contacts_contact_number => + __contacts_contact_number.ref; + + late final ffi.Pointer<_contacts_contact_email_property_ids> + __contacts_contact_email = + _lookup<_contacts_contact_email_property_ids>('_contacts_contact_email'); + + _contacts_contact_email_property_ids get _contacts_contact_email => + __contacts_contact_email.ref; + + late final ffi.Pointer<_contacts_contact_grouprel_property_ids> + __contacts_contact_grouprel = + _lookup<_contacts_contact_grouprel_property_ids>( + '_contacts_contact_grouprel'); + + _contacts_contact_grouprel_property_ids get _contacts_contact_grouprel => + __contacts_contact_grouprel.ref; + + late final ffi.Pointer<_contacts_contact_activity_property_ids> + __contacts_contact_activity = + _lookup<_contacts_contact_activity_property_ids>( + '_contacts_contact_activity'); + + _contacts_contact_activity_property_ids get _contacts_contact_activity => + __contacts_contact_activity.ref; + + late final ffi.Pointer<_contacts_phone_log_stat_property_ids> + __contacts_phone_log_stat = + _lookup<_contacts_phone_log_stat_property_ids>( + '_contacts_phone_log_stat'); + + _contacts_phone_log_stat_property_ids get _contacts_phone_log_stat => + __contacts_phone_log_stat.ref; + + late final ffi.Pointer<_contacts_sip_property_ids> __contacts_sip = + _lookup<_contacts_sip_property_ids>('_contacts_sip'); + + _contacts_sip_property_ids get _contacts_sip => __contacts_sip.ref; + + /// @brief Creates a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a record using contacts_record_destroy(). + /// @param[in] view_uri The view URI + /// @param[out] record The record handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to initialize. + /// @see contacts_record_destroy() + int contacts_record_create( + ffi.Pointer view_uri, + ffi.Pointer> record, + ) { + return _contacts_record_create( + view_uri, + record, + ); + } + + late final _contacts_record_create_ptr = + _lookup>( + 'contacts_record_create'); + late final _dart_contacts_record_create _contacts_record_create = + _contacts_record_create_ptr.asFunction<_dart_contacts_record_create>(); + + /// @brief Destroys a record and releases its all resources. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] record The record handle + /// @param[in] delete_child Set @c true to destroy child records automatically, + /// otherwise set @c false to not destroy child records automatically + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_create() + int contacts_record_destroy( + ffi.Pointer<__contacts_record_h> record, + bool delete_child, + ) { + return _contacts_record_destroy( + record, + delete_child ? 1 : 0, + ); + } + + late final _contacts_record_destroy_ptr = + _lookup>( + 'contacts_record_destroy'); + late final _dart_contacts_record_destroy _contacts_record_destroy = + _contacts_record_destroy_ptr.asFunction<_dart_contacts_record_destroy>(); + + /// @brief Makes a clone of a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a cloned_record using contacts_record_destroy(). + /// @param[in] record The record handle + /// @param[out] cloned_record The cloned record handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_destroy() + int contacts_record_clone( + ffi.Pointer<__contacts_record_h> record, + ffi.Pointer> cloned_record, + ) { + return _contacts_record_clone( + record, + cloned_record, + ); + } + + late final _contacts_record_clone_ptr = + _lookup>( + 'contacts_record_clone'); + late final _dart_contacts_record_clone _contacts_record_clone = + _contacts_record_clone_ptr.asFunction<_dart_contacts_record_clone>(); + + /// @brief Gets a string from the record handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a value using free(). + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[out] value The value to be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_get_str_p() + /// @see contacts_record_set_str() + int contacts_record_get_str( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer> value, + ) { + return _contacts_record_get_str( + record, + property_id, + value, + ); + } + + late final _contacts_record_get_str_ptr = + _lookup>( + 'contacts_record_get_str'); + late final _dart_contacts_record_get_str _contacts_record_get_str = + _contacts_record_get_str_ptr.asFunction<_dart_contacts_record_get_str>(); + + /// @brief Gets a string pointer from the record handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You MUST NOT release @a value. + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[out] value The value to be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_get_str() + /// @see contacts_record_set_str() + int contacts_record_get_str_p( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer> value, + ) { + return _contacts_record_get_str_p( + record, + property_id, + value, + ); + } + + late final _contacts_record_get_str_p_ptr = + _lookup>( + 'contacts_record_get_str_p'); + late final _dart_contacts_record_get_str_p _contacts_record_get_str_p = + _contacts_record_get_str_p_ptr + .asFunction<_dart_contacts_record_get_str_p>(); + + /// @brief Sets a string to a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[in] value The value to set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_get_str() + /// @see contacts_record_get_str_p() + int contacts_record_set_str( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer value, + ) { + return _contacts_record_set_str( + record, + property_id, + value, + ); + } + + late final _contacts_record_set_str_ptr = + _lookup>( + 'contacts_record_set_str'); + late final _dart_contacts_record_set_str _contacts_record_set_str = + _contacts_record_set_str_ptr.asFunction<_dart_contacts_record_set_str>(); + + /// @brief Gets a record's integer value. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[out] value The value to be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_set_int() + int contacts_record_get_int( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer value, + ) { + return _contacts_record_get_int( + record, + property_id, + value, + ); + } + + late final _contacts_record_get_int_ptr = + _lookup>( + 'contacts_record_get_int'); + late final _dart_contacts_record_get_int _contacts_record_get_int = + _contacts_record_get_int_ptr.asFunction<_dart_contacts_record_get_int>(); + + /// @brief Sets an integer value to a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[in] value The value to set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_get_int() + int contacts_record_set_int( + ffi.Pointer<__contacts_record_h> record, + int property_id, + int value, + ) { + return _contacts_record_set_int( + record, + property_id, + value, + ); + } + + late final _contacts_record_set_int_ptr = + _lookup>( + 'contacts_record_set_int'); + late final _dart_contacts_record_set_int _contacts_record_set_int = + _contacts_record_set_int_ptr.asFunction<_dart_contacts_record_set_int>(); + + /// @brief Gets a record's long integer value. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[out] value The value to be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_set_lli() + int contacts_record_get_lli( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer value, + ) { + return _contacts_record_get_lli( + record, + property_id, + value, + ); + } + + late final _contacts_record_get_lli_ptr = + _lookup>( + 'contacts_record_get_lli'); + late final _dart_contacts_record_get_lli _contacts_record_get_lli = + _contacts_record_get_lli_ptr.asFunction<_dart_contacts_record_get_lli>(); + + /// @brief Sets a long long integer value to a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[in] value The value to set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_get_lli() + int contacts_record_set_lli( + ffi.Pointer<__contacts_record_h> record, + int property_id, + int value, + ) { + return _contacts_record_set_lli( + record, + property_id, + value, + ); + } + + late final _contacts_record_set_lli_ptr = + _lookup>( + 'contacts_record_set_lli'); + late final _dart_contacts_record_set_lli _contacts_record_set_lli = + _contacts_record_set_lli_ptr.asFunction<_dart_contacts_record_set_lli>(); + + /// @brief Gets a record's boolean value. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[out] value The value to be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_set_bool() + int contacts_record_get_bool( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer value, + ) { + return _contacts_record_get_bool( + record, + property_id, + value, + ); + } + + late final _contacts_record_get_bool_ptr = + _lookup>( + 'contacts_record_get_bool'); + late final _dart_contacts_record_get_bool _contacts_record_get_bool = + _contacts_record_get_bool_ptr + .asFunction<_dart_contacts_record_get_bool>(); + + /// @brief Sets a boolean value to a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[in] value The value to set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_get_bool() + int contacts_record_set_bool( + ffi.Pointer<__contacts_record_h> record, + int property_id, + bool value, + ) { + return _contacts_record_set_bool( + record, + property_id, + value ? 1 : 0, + ); + } + + late final _contacts_record_set_bool_ptr = + _lookup>( + 'contacts_record_set_bool'); + late final _dart_contacts_record_set_bool _contacts_record_set_bool = + _contacts_record_set_bool_ptr + .asFunction<_dart_contacts_record_set_bool>(); + + /// @brief Gets a record's double value. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[out] value The value to be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_set_double() + int contacts_record_get_double( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer value, + ) { + return _contacts_record_get_double( + record, + property_id, + value, + ); + } + + late final _contacts_record_get_double_ptr = + _lookup>( + 'contacts_record_get_double'); + late final _dart_contacts_record_get_double _contacts_record_get_double = + _contacts_record_get_double_ptr + .asFunction<_dart_contacts_record_get_double>(); + + /// @brief Sets a double value to a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[in] value The value to set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_get_double() + int contacts_record_set_double( + ffi.Pointer<__contacts_record_h> record, + int property_id, + double value, + ) { + return _contacts_record_set_double( + record, + property_id, + value, + ); + } + + late final _contacts_record_set_double_ptr = + _lookup>( + 'contacts_record_set_double'); + late final _dart_contacts_record_set_double _contacts_record_set_double = + _contacts_record_set_double_ptr + .asFunction<_dart_contacts_record_set_double>(); + + /// @brief Adds a child record to the parent record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] record The parent record handle + /// @param[in] property_id The property ID + /// @param[in] child_record The child record handle to be added to parent record handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_remove_child_record() + int contacts_record_add_child_record( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer<__contacts_record_h> child_record, + ) { + return _contacts_record_add_child_record( + record, + property_id, + child_record, + ); + } + + late final _contacts_record_add_child_record_ptr = + _lookup>( + 'contacts_record_add_child_record'); + late final _dart_contacts_record_add_child_record + _contacts_record_add_child_record = _contacts_record_add_child_record_ptr + .asFunction<_dart_contacts_record_add_child_record>(); + + /// @brief Removes a child record from the parent record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] record The parent record handle + /// @param[in] property_id The property ID + /// @param[in] child_record The child record handle to be removed from parent record handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_add_child_record() + int contacts_record_remove_child_record( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer<__contacts_record_h> child_record, + ) { + return _contacts_record_remove_child_record( + record, + property_id, + child_record, + ); + } + + late final _contacts_record_remove_child_record_ptr = + _lookup>( + 'contacts_record_remove_child_record'); + late final _dart_contacts_record_remove_child_record + _contacts_record_remove_child_record = + _contacts_record_remove_child_record_ptr + .asFunction<_dart_contacts_record_remove_child_record>(); + + /// @brief Gets the number of child records of a parent record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] record The parent record handle + /// @param[in] property_id The property ID + /// @param[out] count The child record count + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_add_child_record() + /// @see contacts_record_remove_child_record() + int contacts_record_get_child_record_count( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer count, + ) { + return _contacts_record_get_child_record_count( + record, + property_id, + count, + ); + } + + late final _contacts_record_get_child_record_count_ptr = + _lookup>( + 'contacts_record_get_child_record_count'); + late final _dart_contacts_record_get_child_record_count + _contacts_record_get_child_record_count = + _contacts_record_get_child_record_count_ptr + .asFunction<_dart_contacts_record_get_child_record_count>(); + + /// @brief Gets a child record handle pointer from the parent record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You MUST NOT release @a child_record. It is released when the parent record is destroyed. + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[in] index The index of child record + /// @param[out] child_record The child record handle pointer + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NO_DATA + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_record_add_child_record() + /// @see contacts_record_remove_child_record() + /// @see contacts_record_get_child_record_count() + int contacts_record_get_child_record_at_p( + ffi.Pointer<__contacts_record_h> record, + int property_id, + int index, + ffi.Pointer> child_record, + ) { + return _contacts_record_get_child_record_at_p( + record, + property_id, + index, + child_record, + ); + } + + late final _contacts_record_get_child_record_at_p_ptr = + _lookup>( + 'contacts_record_get_child_record_at_p'); + late final _dart_contacts_record_get_child_record_at_p + _contacts_record_get_child_record_at_p = + _contacts_record_get_child_record_at_p_ptr + .asFunction<_dart_contacts_record_get_child_record_at_p>(); + + /// @brief Clones a child record list of the given parent record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a cloned_list using contacts_list_destroy(). + /// @param[in] record The record handle + /// @param[in] property_id The property ID + /// @param[out] cloned_list The cloned list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_list_destroy() + int contacts_record_clone_child_record_list( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer> cloned_list, + ) { + return _contacts_record_clone_child_record_list( + record, + property_id, + cloned_list, + ); + } + + late final _contacts_record_clone_child_record_list_ptr = + _lookup>( + 'contacts_record_clone_child_record_list'); + late final _dart_contacts_record_clone_child_record_list + _contacts_record_clone_child_record_list = + _contacts_record_clone_child_record_list_ptr + .asFunction<_dart_contacts_record_clone_child_record_list>(); + + /// @brief Gets URI string from a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] record The record handle + /// @param[out] view_uri The URI of record + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + int contacts_record_get_uri_p( + ffi.Pointer<__contacts_record_h> record, + ffi.Pointer> view_uri, + ) { + return _contacts_record_get_uri_p( + record, + view_uri, + ); + } + + late final _contacts_record_get_uri_p_ptr = + _lookup>( + 'contacts_record_get_uri_p'); + late final _dart_contacts_record_get_uri_p _contacts_record_get_uri_p = + _contacts_record_get_uri_p_ptr + .asFunction<_dart_contacts_record_get_uri_p>(); + + /// @brief Creates a contacts list. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a contacts_list using contacts_list_destroy(). + /// @param[out] contacts_list The contacts list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_list_destroy() + int contacts_list_create( + ffi.Pointer> contacts_list, + ) { + return _contacts_list_create( + contacts_list, + ); + } + + late final _contacts_list_create_ptr = + _lookup>( + 'contacts_list_create'); + late final _dart_contacts_list_create _contacts_list_create = + _contacts_list_create_ptr.asFunction<_dart_contacts_list_create>(); + + /// @brief Destroys a contacts list and releases its all resources. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] contacts_list The contacts list handle + /// @param[in] delete_child Set @c true to destroy child records automatically, + /// otherwise set @c false to not destroy child records automatically + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_list_create() + int contacts_list_destroy( + ffi.Pointer<__contacts_list_h> contacts_list, + bool delete_child, + ) { + return _contacts_list_destroy( + contacts_list, + delete_child ? 1 : 0, + ); + } + + late final _contacts_list_destroy_ptr = + _lookup>( + 'contacts_list_destroy'); + late final _dart_contacts_list_destroy _contacts_list_destroy = + _contacts_list_destroy_ptr.asFunction<_dart_contacts_list_destroy>(); + + /// @brief Retrieves the number of contact entities from a contacts list. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] contacts_list The contacts list handle + /// @param[out] count The count of contact entity + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_list_add() + int contacts_list_get_count( + ffi.Pointer<__contacts_list_h> contacts_list, + ffi.Pointer count, + ) { + return _contacts_list_get_count( + contacts_list, + count, + ); + } + + late final _contacts_list_get_count_ptr = + _lookup>( + 'contacts_list_get_count'); + late final _dart_contacts_list_get_count _contacts_list_get_count = + _contacts_list_get_count_ptr.asFunction<_dart_contacts_list_get_count>(); + + /// @brief Adds a record to a contacts list. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks Same kind of record can be added. + /// @param[in] contacts_list The contacts list handle + /// @param[in] record The record handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_list_remove() + int contacts_list_add( + ffi.Pointer<__contacts_list_h> contacts_list, + ffi.Pointer<__contacts_record_h> record, + ) { + return _contacts_list_add( + contacts_list, + record, + ); + } + + late final _contacts_list_add_ptr = + _lookup>('contacts_list_add'); + late final _dart_contacts_list_add _contacts_list_add = + _contacts_list_add_ptr.asFunction<_dart_contacts_list_add>(); + + /// @brief Removes a record from the contacts list. + /// @details If the record is current record, then current record is changed the next record. \n + /// If the record is the last record, then current record will be @c NULL. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] contacts_list The contacts list handle + /// @param[in] record The record handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_list_add() + int contacts_list_remove( + ffi.Pointer<__contacts_list_h> contacts_list, + ffi.Pointer<__contacts_record_h> record, + ) { + return _contacts_list_remove( + contacts_list, + record, + ); + } + + late final _contacts_list_remove_ptr = + _lookup>( + 'contacts_list_remove'); + late final _dart_contacts_list_remove _contacts_list_remove = + _contacts_list_remove_ptr.asFunction<_dart_contacts_list_remove>(); + + /// @brief Retrieves a record from the contacts list. + /// @details The default current record is the first record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You MUST NOT destroy the @a record. + /// It is destroyed automatically when the @a contacts_list is destroyed. + /// @param[in] contacts_list The contacts list handle + /// @param[out] record The record handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + int contacts_list_get_current_record_p( + ffi.Pointer<__contacts_list_h> contacts_list, + ffi.Pointer> record, + ) { + return _contacts_list_get_current_record_p( + contacts_list, + record, + ); + } + + late final _contacts_list_get_current_record_p_ptr = + _lookup>( + 'contacts_list_get_current_record_p'); + late final _dart_contacts_list_get_current_record_p + _contacts_list_get_current_record_p = + _contacts_list_get_current_record_p_ptr + .asFunction<_dart_contacts_list_get_current_record_p>(); + + /// @brief Moves a contacts list to the previous position. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] contacts_list The contacts list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_list_next() + int contacts_list_prev( + ffi.Pointer<__contacts_list_h> contacts_list, + ) { + return _contacts_list_prev( + contacts_list, + ); + } + + late final _contacts_list_prev_ptr = + _lookup>('contacts_list_prev'); + late final _dart_contacts_list_prev _contacts_list_prev = + _contacts_list_prev_ptr.asFunction<_dart_contacts_list_prev>(); + + /// @brief Moves a contacts list to the next position. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] contacts_list The contacts list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_list_prev() + int contacts_list_next( + ffi.Pointer<__contacts_list_h> contacts_list, + ) { + return _contacts_list_next( + contacts_list, + ); + } + + late final _contacts_list_next_ptr = + _lookup>('contacts_list_next'); + late final _dart_contacts_list_next _contacts_list_next = + _contacts_list_next_ptr.asFunction<_dart_contacts_list_next>(); + + /// @brief Moves a contacts list to the first position. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] contacts_list The contacts list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_list_last() + int contacts_list_first( + ffi.Pointer<__contacts_list_h> contacts_list, + ) { + return _contacts_list_first( + contacts_list, + ); + } + + late final _contacts_list_first_ptr = + _lookup>( + 'contacts_list_first'); + late final _dart_contacts_list_first _contacts_list_first = + _contacts_list_first_ptr.asFunction<_dart_contacts_list_first>(); + + /// @brief Moves a contacts list to the last position. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] contacts_list The contacts list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_list_first() + int contacts_list_last( + ffi.Pointer<__contacts_list_h> contacts_list, + ) { + return _contacts_list_last( + contacts_list, + ); + } + + late final _contacts_list_last_ptr = + _lookup>('contacts_list_last'); + late final _dart_contacts_list_last _contacts_list_last = + _contacts_list_last_ptr.asFunction<_dart_contacts_list_last>(); + + /// @brief Creates a filter. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a filter using contacts_filter_destroy(). + /// @param[in] view_uri The view URI of a filter + /// @param[out] filter The filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to initialize + /// @see contacts_filter_destroy() + int contacts_filter_create( + ffi.Pointer view_uri, + ffi.Pointer> filter, + ) { + return _contacts_filter_create( + view_uri, + filter, + ); + } + + late final _contacts_filter_create_ptr = + _lookup>( + 'contacts_filter_create'); + late final _dart_contacts_filter_create _contacts_filter_create = + _contacts_filter_create_ptr.asFunction<_dart_contacts_filter_create>(); + + /// @brief Destroys a filter. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] filter The filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_filter_create() + int contacts_filter_destroy( + ffi.Pointer<__contacts_filter_h> filter, + ) { + return _contacts_filter_destroy( + filter, + ); + } + + late final _contacts_filter_destroy_ptr = + _lookup>( + 'contacts_filter_destroy'); + late final _dart_contacts_filter_destroy _contacts_filter_destroy = + _contacts_filter_destroy_ptr.asFunction<_dart_contacts_filter_destroy>(); + + /// @brief Adds a condition for a string type property. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] filter The filter handle + /// @param[in] property_id The property ID to add a condition + /// @param[in] match The match flag + /// @param[in] match_value The match value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_filter_add_operator() + int contacts_filter_add_str( + ffi.Pointer<__contacts_filter_h> filter, + int property_id, + int match, + ffi.Pointer match_value, + ) { + return _contacts_filter_add_str( + filter, + property_id, + match, + match_value, + ); + } + + late final _contacts_filter_add_str_ptr = + _lookup>( + 'contacts_filter_add_str'); + late final _dart_contacts_filter_add_str _contacts_filter_add_str = + _contacts_filter_add_str_ptr.asFunction<_dart_contacts_filter_add_str>(); + + /// @brief Adds a condition for an integer type property. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] filter The filter handle + /// @param[in] property_id The property ID to add a condition + /// @param[in] match The match flag + /// @param[in] match_value The match value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_filter_add_operator() + int contacts_filter_add_int( + ffi.Pointer<__contacts_filter_h> filter, + int property_id, + int match, + int match_value, + ) { + return _contacts_filter_add_int( + filter, + property_id, + match, + match_value, + ); + } + + late final _contacts_filter_add_int_ptr = + _lookup>( + 'contacts_filter_add_int'); + late final _dart_contacts_filter_add_int _contacts_filter_add_int = + _contacts_filter_add_int_ptr.asFunction<_dart_contacts_filter_add_int>(); + + /// @brief Adds a condition for a long int type property. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] filter The filter handle + /// @param[in] property_id The property ID to add a condition + /// @param[in] match The match flag + /// @param[in] match_value The match value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_filter_add_operator() + int contacts_filter_add_lli( + ffi.Pointer<__contacts_filter_h> filter, + int property_id, + int match, + int match_value, + ) { + return _contacts_filter_add_lli( + filter, + property_id, + match, + match_value, + ); + } + + late final _contacts_filter_add_lli_ptr = + _lookup>( + 'contacts_filter_add_lli'); + late final _dart_contacts_filter_add_lli _contacts_filter_add_lli = + _contacts_filter_add_lli_ptr.asFunction<_dart_contacts_filter_add_lli>(); + + /// @brief Adds a condition for a double type property. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] filter The filter handle + /// @param[in] property_id The property ID to add a condition + /// @param[in] match The match flag + /// @param[in] match_value The match value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_filter_add_operator() + int contacts_filter_add_double( + ffi.Pointer<__contacts_filter_h> filter, + int property_id, + int match, + double match_value, + ) { + return _contacts_filter_add_double( + filter, + property_id, + match, + match_value, + ); + } + + late final _contacts_filter_add_double_ptr = + _lookup>( + 'contacts_filter_add_double'); + late final _dart_contacts_filter_add_double _contacts_filter_add_double = + _contacts_filter_add_double_ptr + .asFunction<_dart_contacts_filter_add_double>(); + + /// @brief Adds a condition for a boolean type property. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] filter The filter handle + /// @param[in] property_id The property ID to add a condition + /// @param[in] match_value The match value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_filter_add_operator() + int contacts_filter_add_bool( + ffi.Pointer<__contacts_filter_h> filter, + int property_id, + bool match_value, + ) { + return _contacts_filter_add_bool( + filter, + property_id, + match_value ? 1 : 0, + ); + } + + late final _contacts_filter_add_bool_ptr = + _lookup>( + 'contacts_filter_add_bool'); + late final _dart_contacts_filter_add_bool _contacts_filter_add_bool = + _contacts_filter_add_bool_ptr + .asFunction<_dart_contacts_filter_add_bool>(); + + /// @brief Adds an operator between conditions. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] filter The filter handle + /// @param[in] operator_type The operator type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_filter_add_str() + /// @see contacts_filter_add_int() + /// @see contacts_filter_add_bool() + int contacts_filter_add_operator( + ffi.Pointer<__contacts_filter_h> filter, + int operator_type, + ) { + return _contacts_filter_add_operator( + filter, + operator_type, + ); + } + + late final _contacts_filter_add_operator_ptr = + _lookup>( + 'contacts_filter_add_operator'); + late final _dart_contacts_filter_add_operator _contacts_filter_add_operator = + _contacts_filter_add_operator_ptr + .asFunction<_dart_contacts_filter_add_operator>(); + + /// @brief Adds a filter to a given filter. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] parent_filter The parent filter handle + /// @param[in] child_filter The child filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_filter_add_operator() + int contacts_filter_add_filter( + ffi.Pointer<__contacts_filter_h> parent_filter, + ffi.Pointer<__contacts_filter_h> child_filter, + ) { + return _contacts_filter_add_filter( + parent_filter, + child_filter, + ); + } + + late final _contacts_filter_add_filter_ptr = + _lookup>( + 'contacts_filter_add_filter'); + late final _dart_contacts_filter_add_filter _contacts_filter_add_filter = + _contacts_filter_add_filter_ptr + .asFunction<_dart_contacts_filter_add_filter>(); + + /// @brief Creates a query. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a query using contacts_query_destroy(). + /// @param[in] view_uri The view URI of a query + /// @param[out] query The filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to initialize + /// @see contacts_query_destroy() + int contacts_query_create( + ffi.Pointer view_uri, + ffi.Pointer> query, + ) { + return _contacts_query_create( + view_uri, + query, + ); + } + + late final _contacts_query_create_ptr = + _lookup>( + 'contacts_query_create'); + late final _dart_contacts_query_create _contacts_query_create = + _contacts_query_create_ptr.asFunction<_dart_contacts_query_create>(); + + /// @brief Destroys a query. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] query The query handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_query_create() + int contacts_query_destroy( + ffi.Pointer<__contacts_query_h> query, + ) { + return _contacts_query_destroy( + query, + ); + } + + late final _contacts_query_destroy_ptr = + _lookup>( + 'contacts_query_destroy'); + late final _dart_contacts_query_destroy _contacts_query_destroy = + _contacts_query_destroy_ptr.asFunction<_dart_contacts_query_destroy>(); + + /// @brief Adds property IDs for projection. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] query The query handle + /// @param[in] property_id_array The property ID array + /// @param[in] count The number of property IDs + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + int contacts_query_set_projection( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer property_id_array, + int count, + ) { + return _contacts_query_set_projection( + query, + property_id_array, + count, + ); + } + + late final _contacts_query_set_projection_ptr = + _lookup>( + 'contacts_query_set_projection'); + late final _dart_contacts_query_set_projection + _contacts_query_set_projection = _contacts_query_set_projection_ptr + .asFunction<_dart_contacts_query_set_projection>(); + + /// @brief Sets the "distinct" option for projection. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] query The query handle + /// @param[in] set Set @c true to set the distinct option for projection, + /// otherwise @c false to unset the distinct option + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + int contacts_query_set_distinct( + ffi.Pointer<__contacts_query_h> query, + bool set_1, + ) { + return _contacts_query_set_distinct( + query, + set_1 ? 1 : 0, + ); + } + + late final _contacts_query_set_distinct_ptr = + _lookup>( + 'contacts_query_set_distinct'); + late final _dart_contacts_query_set_distinct _contacts_query_set_distinct = + _contacts_query_set_distinct_ptr + .asFunction<_dart_contacts_query_set_distinct>(); + + /// @brief Sets a filter for query. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] query The query handle + /// @param[in] filter The filter handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @see contacts_filter_create() + int contacts_query_set_filter( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer<__contacts_filter_h> filter, + ) { + return _contacts_query_set_filter( + query, + filter, + ); + } + + late final _contacts_query_set_filter_ptr = + _lookup>( + 'contacts_query_set_filter'); + late final _dart_contacts_query_set_filter _contacts_query_set_filter = + _contacts_query_set_filter_ptr + .asFunction<_dart_contacts_query_set_filter>(); + + /// @brief Sets a sort mode for query. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] query The query handle + /// @param[in] property_id The property ID to sort + /// @param[in] is_ascending Set @c true for ascending sort mode, + /// otherwise @c false for descending sort mode + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + int contacts_query_set_sort( + ffi.Pointer<__contacts_query_h> query, + int property_id, + bool is_ascending, + ) { + return _contacts_query_set_sort( + query, + property_id, + is_ascending ? 1 : 0, + ); + } + + late final _contacts_query_set_sort_ptr = + _lookup>( + 'contacts_query_set_sort'); + late final _dart_contacts_query_set_sort _contacts_query_set_sort = + _contacts_query_set_sort_ptr.asFunction<_dart_contacts_query_set_sort>(); + + /// @brief Inserts a record to the contacts database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @privilege %http://tizen.org/privilege/callhistory.write + /// @remarks %http://tizen.org/privilege/contact.write is needed for record which is created with @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address_book, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact, \n @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_group, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_my_profile, + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_name, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_number, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_email, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_note, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_url, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_event, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_image, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_company, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_nickname, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_messenger, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_extension, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_profile, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_relationship, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity_photo, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_speeddial. \n + /// %http://tizen.org/privilege/callhistory.write is needed for record which is created with @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log. + /// @param[in] record The record handle + /// @param[out] id The ID of inserted record + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @post contacts_db_changed_cb() callback will be called upon success. + /// @see contacts_connect() + /// @see contacts_db_update_record() + /// @see contacts_db_delete_record() + /// @see contacts_db_get_record() + int contacts_db_insert_record( + ffi.Pointer<__contacts_record_h> record, + ffi.Pointer id, + ) { + return _contacts_db_insert_record( + record, + id, + ); + } + + late final _contacts_db_insert_record_ptr = + _lookup>( + 'contacts_db_insert_record'); + late final _dart_contacts_db_insert_record _contacts_db_insert_record = + _contacts_db_insert_record_ptr + .asFunction<_dart_contacts_db_insert_record>(); + + /// @brief Gets a record from the contacts database. + /// @details This function creates a new contact handle from the contacts database by the given @a record_id. \n + /// @a record will be created, which is filled with contact information. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @privilege %http://tizen.org/privilege/callhistory.read + /// @remarks %http://tizen.org/privilege/contact.read is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address_book, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_simple_contact, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_group, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_my_profile, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_name, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_number, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_email, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_note, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_url, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_event, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_image, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_company, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_nickname, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_messenger, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_extension, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_profile, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_relationship, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity_photo, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_speeddial, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_sdn. \n + /// %http://tizen.org/privilege/callhistory.read is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log. + /// @remarks You must release @a record using contacts_record_destroy(). + /// @param[in] view_uri The view URI of a record + /// @param[in] record_id The record ID to get from database + /// @param[out] record The record handle associated with the record ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_record_destroy() + int contacts_db_get_record( + ffi.Pointer view_uri, + int record_id, + ffi.Pointer> record, + ) { + return _contacts_db_get_record( + view_uri, + record_id, + record, + ); + } + + late final _contacts_db_get_record_ptr = + _lookup>( + 'contacts_db_get_record'); + late final _dart_contacts_db_get_record _contacts_db_get_record = + _contacts_db_get_record_ptr.asFunction<_dart_contacts_db_get_record>(); + + /// @brief Updates a record in the contacts database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @privilege %http://tizen.org/privilege/callhistory.write + /// @remarks %http://tizen.org/privilege/contact.write is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address_book, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact, \n @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_group, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_my_profile, + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_name, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_number, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_email, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_note, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_url, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_event, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_image, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_company, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_nickname, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_messenger, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_extension, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_profile, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_relationship, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity_photo, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_speeddial. \n + /// %http://tizen.org/privilege/callhistory.write is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log. + /// @param[in] record The record handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @post contacts_db_changed_cb() callback will be called upon success. + /// @see contacts_connect() + /// @see contacts_db_insert_record() + /// @see contacts_db_delete_record() + /// @see contacts_db_get_record() + int contacts_db_update_record( + ffi.Pointer<__contacts_record_h> record, + ) { + return _contacts_db_update_record( + record, + ); + } + + late final _contacts_db_update_record_ptr = + _lookup>( + 'contacts_db_update_record'); + late final _dart_contacts_db_update_record _contacts_db_update_record = + _contacts_db_update_record_ptr + .asFunction<_dart_contacts_db_update_record>(); + + /// @brief Deletes a record from the contacts database with related child records. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @privilege %http://tizen.org/privilege/callhistory.write + /// @remarks %http://tizen.org/privilege/contact.write is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address_book, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact, \n @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_group, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_my_profile, + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_name, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_number, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_email, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_note, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_url, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_event, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_image, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_company, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_nickname, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_messenger, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_extension, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_profile, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_relationship, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity_photo, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_speeddial. \n + /// %http://tizen.org/privilege/callhistory.write is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log. + /// @param[in] view_uri The view URI of a record + /// @param[in] record_id The record ID to delete + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @post contacts_db_changed_cb() callback will be called upon success. + /// @see contacts_connect() + /// @see contacts_db_insert_record() + int contacts_db_delete_record( + ffi.Pointer view_uri, + int record_id, + ) { + return _contacts_db_delete_record( + view_uri, + record_id, + ); + } + + late final _contacts_db_delete_record_ptr = + _lookup>( + 'contacts_db_delete_record'); + late final _dart_contacts_db_delete_record _contacts_db_delete_record = + _contacts_db_delete_record_ptr + .asFunction<_dart_contacts_db_delete_record>(); + + /// @brief Replaces an id-identified record with the given record. + /// @details Now, this API supports only _contacts_contact view_uri. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @remarks The write-once value of @a record is not replaced. \n + /// This API works only for @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact. + /// @param[in] record The new record handle to replace + /// @param[in] id The DB record ID to be replaced + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @post contacts_db_changed_cb() callback will be called upon success. + /// @see contacts_connect() + /// @see contacts_db_update_record() + /// @see contacts_db_delete_record() + /// @see contacts_db_get_record() + int contacts_db_replace_record( + ffi.Pointer<__contacts_record_h> record, + int id, + ) { + return _contacts_db_replace_record( + record, + id, + ); + } + + late final _contacts_db_replace_record_ptr = + _lookup>( + 'contacts_db_replace_record'); + late final _dart_contacts_db_replace_record _contacts_db_replace_record = + _contacts_db_replace_record_ptr + .asFunction<_dart_contacts_db_replace_record>(); + + /// @brief Retrieves all records and returns the results list. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @privilege %http://tizen.org/privilege/callhistory.read + /// @remarks You must release @a record_list using contacts_list_destroy(). \n + /// %http://tizen.org/privilege/contact.read is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address_book, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_simple_contact, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_group, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_my_profile, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_name, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_number, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_email, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_note, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_url, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_event, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_image, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_company, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_nickname, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_messenger, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_extension, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_profile, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_relationship, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity_photo, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_speeddial, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_sdn and all read-only views except views which are related to phone log. \n + /// %http://tizen.org/privilege/callhistory.read is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log_stat. \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_phone_log view is needed both privileges. + /// @param[in] view_uri The view URI to get records + /// @param[in] offset The index from which to get results + /// @param[in] limit The number to limit results(value 0 is used for all records) + /// @param[out] record_list The record list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_list_destroy() + int contacts_db_get_all_records( + ffi.Pointer view_uri, + int offset, + int limit, + ffi.Pointer> record_list, + ) { + return _contacts_db_get_all_records( + view_uri, + offset, + limit, + record_list, + ); + } + + late final _contacts_db_get_all_records_ptr = + _lookup>( + 'contacts_db_get_all_records'); + late final _dart_contacts_db_get_all_records _contacts_db_get_all_records = + _contacts_db_get_all_records_ptr + .asFunction<_dart_contacts_db_get_all_records>(); + + /// @brief Uses a query to find records. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @privilege %http://tizen.org/privilege/callhistory.read + /// @remarks You must release @a record_list using contacts_list_destroy(). \n + /// %http://tizen.org/privilege/contact.read is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address_book, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_simple_contact, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_group, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_my_profile, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_name, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_number, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_email, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_note, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_url, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_event, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_image, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_company, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_nickname, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_messenger, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_extension, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_profile, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_relationship, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity_photo, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_speeddial, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_sdn and all read-only views except views which are related to phone log. \n + /// %http://tizen.org/privilege/callhistory.read is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log_stat. \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_phone_log view is needed both privileges. + /// @param[in] query The query to filter the results + /// @param[in] offset The index from which to get results + /// @param[in] limit The number to limit results(value 0 is used for get all records) + /// @param[out] record_list The record list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_list_destroy() + int contacts_db_get_records_with_query( + ffi.Pointer<__contacts_query_h> query, + int offset, + int limit, + ffi.Pointer> record_list, + ) { + return _contacts_db_get_records_with_query( + query, + offset, + limit, + record_list, + ); + } + + late final _contacts_db_get_records_with_query_ptr = + _lookup>( + 'contacts_db_get_records_with_query'); + late final _dart_contacts_db_get_records_with_query + _contacts_db_get_records_with_query = + _contacts_db_get_records_with_query_ptr + .asFunction<_dart_contacts_db_get_records_with_query>(); + + /// @brief Inserts multiple records to the contacts database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @privilege %http://tizen.org/privilege/callhistory.write + /// @remarks %http://tizen.org/privilege/contact.write is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address_book, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact, \n @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_group, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_my_profile, + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_name, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_number, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_email, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_note, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_url, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_event, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_image, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_company, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_nickname, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_messenger, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_extension, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_profile, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_relationship, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity_photo, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_speeddial. \n + /// %http://tizen.org/privilege/callhistory.write is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log. + /// @param[in] record_list The record list handle + /// @param[out] ids The IDs of inserted records + /// @param[out] count The number of IDs + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @post contacts_db_changed_cb() callback will be called upon success. + /// @see contacts_connect() + /// @see contacts_db_update_records() + /// @see contacts_db_delete_records() + int contacts_db_insert_records( + ffi.Pointer<__contacts_list_h> record_list, + ffi.Pointer> ids, + ffi.Pointer count, + ) { + return _contacts_db_insert_records( + record_list, + ids, + count, + ); + } + + late final _contacts_db_insert_records_ptr = + _lookup>( + 'contacts_db_insert_records'); + late final _dart_contacts_db_insert_records _contacts_db_insert_records = + _contacts_db_insert_records_ptr + .asFunction<_dart_contacts_db_insert_records>(); + + /// @brief Updates multiple records in the contacts database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @privilege %http://tizen.org/privilege/callhistory.write + /// @remarks %http://tizen.org/privilege/contact.write is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address_book, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact, \n @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_group, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_my_profile, + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_name, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_number, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_email, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_note, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_url, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_event, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_image, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_company, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_nickname, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_messenger, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_extension, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_profile, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_relationship, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity_photo, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_speeddial. \n + /// %http://tizen.org/privilege/callhistory.write is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log. + /// @param[in] record_list The record list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @post contacts_db_changed_cb() callback will be called upon success. + /// @see contacts_connect() + /// @see contacts_db_insert_records() + /// @see contacts_db_delete_records() + int contacts_db_update_records( + ffi.Pointer<__contacts_list_h> record_list, + ) { + return _contacts_db_update_records( + record_list, + ); + } + + late final _contacts_db_update_records_ptr = + _lookup>( + 'contacts_db_update_records'); + late final _dart_contacts_db_update_records _contacts_db_update_records = + _contacts_db_update_records_ptr + .asFunction<_dart_contacts_db_update_records>(); + + /// @brief Deletes multiple records in the contacts database with related child records. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @privilege %http://tizen.org/privilege/callhistory.write + /// @remarks %http://tizen.org/privilege/contact.write is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address_book, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact, \n @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_group, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_my_profile, + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_name, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_number, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_email, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_note, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_url, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_event, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_image, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_company, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_nickname, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_messenger, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_extension, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_profile, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_relationship, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity_photo, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_speeddial. \n + /// %http://tizen.org/privilege/callhistory.write is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log. + /// @param[in] view_uri The view URI of records + /// @param[in] record_id_array The record IDs to delete + /// @param[in] count The size of record ID array + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @post contacts_db_changed_cb() callback will be called upon success. + /// @see contacts_connect() + /// @see contacts_db_insert_records() + /// @see contacts_db_update_records() + int contacts_db_delete_records( + ffi.Pointer view_uri, + ffi.Pointer record_id_array, + int count, + ) { + return _contacts_db_delete_records( + view_uri, + record_id_array, + count, + ); + } + + late final _contacts_db_delete_records_ptr = + _lookup>( + 'contacts_db_delete_records'); + late final _dart_contacts_db_delete_records _contacts_db_delete_records = + _contacts_db_delete_records_ptr + .asFunction<_dart_contacts_db_delete_records>(); + + /// @brief Replaces database records identified by given ids with a given record list. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @remarks The write-once value of record is not replaced. \n + /// This API works only for @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact. + /// @param[in] list The new record list handle to replace + /// @param[in] record_id_array The record IDs to replace + /// @param[in] count The size of record ID array + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @post contacts_db_changed_cb() callback will be called upon success. + /// @see contacts_connect() + /// @see contacts_db_update_record() + /// @see contacts_db_delete_record() + /// @see contacts_db_get_record() + int contacts_db_replace_records( + ffi.Pointer<__contacts_list_h> list, + ffi.Pointer record_id_array, + int count, + ) { + return _contacts_db_replace_records( + list, + record_id_array, + count, + ); + } + + late final _contacts_db_replace_records_ptr = + _lookup>( + 'contacts_db_replace_records'); + late final _dart_contacts_db_replace_records _contacts_db_replace_records = + _contacts_db_replace_records_ptr + .asFunction<_dart_contacts_db_replace_records>(); + + /// @brief Gets the current contacts database version. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @privilege %http://tizen.org/privilege/callhistory.read + /// @param[out] contacts_db_version The contacts database version + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_db_get_changes_by_version() + int contacts_db_get_current_version( + ffi.Pointer contacts_db_version, + ) { + return _contacts_db_get_current_version( + contacts_db_version, + ); + } + + late final _contacts_db_get_current_version_ptr = + _lookup>( + 'contacts_db_get_current_version'); + late final _dart_contacts_db_get_current_version + _contacts_db_get_current_version = _contacts_db_get_current_version_ptr + .asFunction<_dart_contacts_db_get_current_version>(); + + /// @brief Registers a callback function to be invoked when a record changes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @privilege %http://tizen.org/privilege/callhistory.read + /// @remarks %http://tizen.org/privilege/contact.read is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address_book, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_simple_contact, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_group, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_my_profile, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_name, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_number, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_email, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_note, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_url, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_event, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_image, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_company, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_nickname, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_messenger, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_extension, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_profile, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_relationship, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity_photo, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_speeddial, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_sdn, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_group_relation.\n + /// %http://tizen.org/privilege/callhistory.read is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log. + /// If successive change notification produced on the view_uri are identical, + /// then they are coalesced into a single notification if the older notification has not yet been called + /// because default main loop is doing something. + /// But, it means that a callback function is not called to reliably count of change. + /// @param[in] view_uri The view URI of records whose changes are monitored + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM System error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @post contacts_db_changed_cb() will be invoked when the designated view changes. + /// @see contacts_connect() + /// @see contacts_db_changed_cb() + /// @see contacts_db_remove_changed_cb() + int contacts_db_add_changed_cb( + ffi.Pointer view_uri, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _contacts_db_add_changed_cb( + view_uri, + callback, + user_data, + ); + } + + late final _contacts_db_add_changed_cb_ptr = + _lookup>( + 'contacts_db_add_changed_cb'); + late final _dart_contacts_db_add_changed_cb _contacts_db_add_changed_cb = + _contacts_db_add_changed_cb_ptr + .asFunction<_dart_contacts_db_add_changed_cb>(); + + /// @brief Unregisters a callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] view_uri The view URI of records whose changes are monitored + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM System error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_db_changed_cb() + /// @see contacts_db_add_changed_cb() + int contacts_db_remove_changed_cb( + ffi.Pointer view_uri, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _contacts_db_remove_changed_cb( + view_uri, + callback, + user_data, + ); + } + + late final _contacts_db_remove_changed_cb_ptr = + _lookup>( + 'contacts_db_remove_changed_cb'); + late final _dart_contacts_db_remove_changed_cb + _contacts_db_remove_changed_cb = _contacts_db_remove_changed_cb_ptr + .asFunction<_dart_contacts_db_remove_changed_cb>(); + + /// @brief Retrieves records changes since the given database version. + /// @details This function will find all changed records since the given @a contacts_db_version. \n + /// Now, support @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact_updated_info, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_group_updated_info \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_my_profile_updated_info and @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_grouprel_updated_info. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @remarks You must release @a record_list using contacts_list_destroy(). + /// @param[in] view_uri The view URI to get records + /// @param[in] address_book_id The address book ID to filter + /// @param[in] contacts_db_version The contacts database version + /// @param[out] change_record_list The record list + /// @param[out] current_contacts_db_version The current contacts database version + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_list_destroy() + int contacts_db_get_changes_by_version( + ffi.Pointer view_uri, + int address_book_id, + int contacts_db_version, + ffi.Pointer> change_record_list, + ffi.Pointer current_contacts_db_version, + ) { + return _contacts_db_get_changes_by_version( + view_uri, + address_book_id, + contacts_db_version, + change_record_list, + current_contacts_db_version, + ); + } + + late final _contacts_db_get_changes_by_version_ptr = + _lookup>( + 'contacts_db_get_changes_by_version'); + late final _dart_contacts_db_get_changes_by_version + _contacts_db_get_changes_by_version = + _contacts_db_get_changes_by_version_ptr + .asFunction<_dart_contacts_db_get_changes_by_version>(); + + /// @brief Finds records based on a given keyword. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @remarks You must release @a record_list using contacts_list_destroy(). \n + /// This API works only for @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_contact, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_grouprel, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_group_assigned \n + /// and @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_group_not_assigned. + /// @param[in] view_uri The view URI to get records + /// @param[in] keyword The keyword + /// @param[in] offset The index from which to get results + /// @param[in] limit The number to limit results(value 0 is used for get all records) + /// @param[out] record_list The record list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_list_destroy() + int contacts_db_search_records( + ffi.Pointer view_uri, + ffi.Pointer keyword, + int offset, + int limit, + ffi.Pointer> record_list, + ) { + return _contacts_db_search_records( + view_uri, + keyword, + offset, + limit, + record_list, + ); + } + + late final _contacts_db_search_records_ptr = + _lookup>( + 'contacts_db_search_records'); + late final _dart_contacts_db_search_records _contacts_db_search_records = + _contacts_db_search_records_ptr + .asFunction<_dart_contacts_db_search_records>(); + + /// @brief Finds records based on given query and keyword. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @remarks You must release @a record_list using contacts_list_destroy(). \n + /// This API works only for @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_contact, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_grouprel, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_group_assigned \n + /// and @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_group_not_assigned. + /// @param[in] query The query handle to filter + /// @param[in] keyword The keyword + /// @param[in] offset The index from which to get results + /// @param[in] limit The number to limit results(value 0 used for get all records) + /// @param[out] record_list The record list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_list_destroy() + int contacts_db_search_records_with_query( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer keyword, + int offset, + int limit, + ffi.Pointer> record_list, + ) { + return _contacts_db_search_records_with_query( + query, + keyword, + offset, + limit, + record_list, + ); + } + + late final _contacts_db_search_records_with_query_ptr = + _lookup>( + 'contacts_db_search_records_with_query'); + late final _dart_contacts_db_search_records_with_query + _contacts_db_search_records_with_query = + _contacts_db_search_records_with_query_ptr + .asFunction<_dart_contacts_db_search_records_with_query>(); + + /// @brief Finds records based on a keyword and range. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @remarks You must release @a record_list using contacts_list_destroy(). \n + /// This API works only for @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_contact, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_grouprel, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_group_assigned, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_group_not_assigned. These views can search records with range @ref CONTACTS_SEARCH_RANGE_NAME, @ref CONTACTS_SEARCH_RANGE_NUMBER, @ref CONTACTS_SEARCH_RANGE_DATA. \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_number can search records with @ref CONTACTS_SEARCH_RANGE_NAME and @ref CONTACTS_SEARCH_RANGE_NUMBER.\n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_email can search records with @ref CONTACTS_SEARCH_RANGE_NAME and @ref CONTACTS_SEARCH_RANGE_EMAIL. + /// @param[in] view_uri The view URI + /// @param[in] keyword The keyword + /// @param[in] offset The index from which to get results + /// @param[in] limit The number to limit results(value 0 is used for get all records) + /// @param[in] range The search range + /// @param[out] record_list The record list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_list_destroy() + int contacts_db_search_records_with_range( + ffi.Pointer view_uri, + ffi.Pointer keyword, + int offset, + int limit, + int range, + ffi.Pointer> record_list, + ) { + return _contacts_db_search_records_with_range( + view_uri, + keyword, + offset, + limit, + range, + record_list, + ); + } + + late final _contacts_db_search_records_with_range_ptr = + _lookup>( + 'contacts_db_search_records_with_range'); + late final _dart_contacts_db_search_records_with_range + _contacts_db_search_records_with_range = + _contacts_db_search_records_with_range_ptr + .asFunction<_dart_contacts_db_search_records_with_range>(); + + /// @brief Finds records based on a given keyword for snippet. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @remarks You must release @a record_list using contacts_list_destroy(). \n + /// This API works only for @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_contact, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_grouprel, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_group_assigned \n + /// and @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_group_not_assigned. \n + /// Because start match and end match is needed to be composed with keyword, this API performance is lower than contacts_db_search_records(). + /// @param[in] view_uri The view URI to get records + /// @param[in] keyword The keyword + /// @param[in] offset The index from which to get results + /// @param[in] limit The number to limit results(value 0 used for get all records) + /// @param[in] start_match The text which is inserted into the fragment before the keyword(If NULL, default is "[") + /// @param[in] end_match The text which is inserted into the fragment after the keyword(If NULL, default is "]") + /// @param[in] token_number The one side extra number of tokens near keyword(If negative value, full sentence is printed. e.g. if token number is 3 with 'abc' keyword, "my name is [abc]de and my home") + /// @param[out] record_list The record list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_list_destroy() + int contacts_db_search_records_for_snippet( + ffi.Pointer view_uri, + ffi.Pointer keyword, + int offset, + int limit, + ffi.Pointer start_match, + ffi.Pointer end_match, + int token_number, + ffi.Pointer> record_list, + ) { + return _contacts_db_search_records_for_snippet( + view_uri, + keyword, + offset, + limit, + start_match, + end_match, + token_number, + record_list, + ); + } + + late final _contacts_db_search_records_for_snippet_ptr = + _lookup>( + 'contacts_db_search_records_for_snippet'); + late final _dart_contacts_db_search_records_for_snippet + _contacts_db_search_records_for_snippet = + _contacts_db_search_records_for_snippet_ptr + .asFunction<_dart_contacts_db_search_records_for_snippet>(); + + /// @brief Finds records based on given query and keyword for snippet. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @remarks You must release @a record_list using contacts_list_destroy(). \n + /// This API works only for @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_contact, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_grouprel, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_group_assigned \n + /// and @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_group_not_assigned. \n + /// Because start match and end match is needed to be composed with keyword, this API performance is lower than contacts_db_search_records_with_query(). + /// @param[in] query The query handle to filter + /// @param[in] keyword The keyword + /// @param[in] offset The index from which to get results + /// @param[in] limit The number to limit results(value 0 used for get all records) + /// @param[in] start_match The text which is inserted into the fragment before the keyword(If NULL, default is "[") + /// @param[in] end_match The text which is inserted into the fragment after the keyword(If NULL, default is "]") + /// @param[in] token_number The one side extra number of tokens near keyword(If negative value, full sentence is printed. e.g. if token number is 3 with 'abc' keyword, "my name is [abc]de and my home") + /// @param[out] record_list The record list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_list_destroy() + int contacts_db_search_records_with_query_for_snippet( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer keyword, + int offset, + int limit, + ffi.Pointer start_match, + ffi.Pointer end_match, + int token_number, + ffi.Pointer> record_list, + ) { + return _contacts_db_search_records_with_query_for_snippet( + query, + keyword, + offset, + limit, + start_match, + end_match, + token_number, + record_list, + ); + } + + late final _contacts_db_search_records_with_query_for_snippet_ptr = _lookup< + ffi.NativeFunction< + _c_contacts_db_search_records_with_query_for_snippet>>( + 'contacts_db_search_records_with_query_for_snippet'); + late final _dart_contacts_db_search_records_with_query_for_snippet + _contacts_db_search_records_with_query_for_snippet = + _contacts_db_search_records_with_query_for_snippet_ptr.asFunction< + _dart_contacts_db_search_records_with_query_for_snippet>(); + + /// @brief Finds records based on a keyword and range for snippet. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @remarks You must release @a record_list using contacts_list_destroy(). \n + /// This API works only for @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_contact, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_grouprel, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_group_assigned, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_group_not_assigned. These views can search records with range @ref CONTACTS_SEARCH_RANGE_NAME, @ref CONTACTS_SEARCH_RANGE_NUMBER, @ref CONTACTS_SEARCH_RANGE_DATA. \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_number can search records with @ref CONTACTS_SEARCH_RANGE_NAME and @ref CONTACTS_SEARCH_RANGE_NUMBER.\n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_email can search records with @ref CONTACTS_SEARCH_RANGE_NAME and @ref CONTACTS_SEARCH_RANGE_EMAIL. \n + /// Because start match and end match is needed to be composed with keyword, this API performance is lower than contacts_db_search_records_with_range(). + /// @param[in] view_uri The view URI + /// @param[in] keyword The keyword + /// @param[in] offset The index from which to get results + /// @param[in] limit The number to limit results(value 0 is used for get all records) + /// @param[in] range The search range + /// @param[in] start_match The text which is inserted into the fragment before the keyword(If NULL, default is "[") + /// @param[in] end_match The text which is inserted into the fragment after the keyword(If NULL, default is "]") + /// @param[in] token_number The one side extra number of tokens near keyword(If negative value, full sentence is printed. e.g. if token number is 3 with 'abc' keyword, "my name is [abc]de and my home") + /// @param[out] record_list The record list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_list_destroy() + int contacts_db_search_records_with_range_for_snippet( + ffi.Pointer view_uri, + ffi.Pointer keyword, + int offset, + int limit, + int range, + ffi.Pointer start_match, + ffi.Pointer end_match, + int token_number, + ffi.Pointer> record_list, + ) { + return _contacts_db_search_records_with_range_for_snippet( + view_uri, + keyword, + offset, + limit, + range, + start_match, + end_match, + token_number, + record_list, + ); + } + + late final _contacts_db_search_records_with_range_for_snippet_ptr = _lookup< + ffi.NativeFunction< + _c_contacts_db_search_records_with_range_for_snippet>>( + 'contacts_db_search_records_with_range_for_snippet'); + late final _dart_contacts_db_search_records_with_range_for_snippet + _contacts_db_search_records_with_range_for_snippet = + _contacts_db_search_records_with_range_for_snippet_ptr.asFunction< + _dart_contacts_db_search_records_with_range_for_snippet>(); + + /// @brief Gets the number of records in a specific view. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @privilege %http://tizen.org/privilege/callhistory.read + /// @remarks %http://tizen.org/privilege/contact.read is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address_book, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_simple_contact, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_group, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_my_profile, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_name, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_number, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_email, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_note, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_url, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_event, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_image, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_company, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_nickname, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_messenger, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_extension, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_profile, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_relationship, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity_photo, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_speeddial, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_sdn and all read-only views except views which is related to phone log. \n + /// %http://tizen.org/privilege/callhistory.read is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log_stat. \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_phone_log view is needed both privilege. + /// @param[in] view_uri The view URI + /// @param[out] count The count of records + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_db_get_count( + ffi.Pointer view_uri, + ffi.Pointer count, + ) { + return _contacts_db_get_count( + view_uri, + count, + ); + } + + late final _contacts_db_get_count_ptr = + _lookup>( + 'contacts_db_get_count'); + late final _dart_contacts_db_get_count _contacts_db_get_count = + _contacts_db_get_count_ptr.asFunction<_dart_contacts_db_get_count>(); + + /// @brief Gets the number of records matching a query. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @privilege %http://tizen.org/privilege/callhistory.read + /// @remarks %http://tizen.org/privilege/contact.read is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address_book, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_contact, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_simple_contact, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_group, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_my_profile, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_name, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_number, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_email, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_address, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_note, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_url, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_event, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_image, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_company, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_nickname, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_messenger, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_extension, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_profile, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_relationship, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_activity_photo, \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_speeddial, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_sdn and all read-only views except views which is related to phone log. \n + /// %http://tizen.org/privilege/callhistory.read is needed for record which is related to @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log, @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_phone_log_stat. \n + /// @ref CAPI_SOCIAL_CONTACTS_SVC_VIEW_MODULE_contacts_person_phone_log view is needed both privilege. + /// @param[in] query The query handle + /// @param[out] count The count of records + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_db_get_count_with_query( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer count, + ) { + return _contacts_db_get_count_with_query( + query, + count, + ); + } + + late final _contacts_db_get_count_with_query_ptr = + _lookup>( + 'contacts_db_get_count_with_query'); + late final _dart_contacts_db_get_count_with_query + _contacts_db_get_count_with_query = _contacts_db_get_count_with_query_ptr + .asFunction<_dart_contacts_db_get_count_with_query>(); + + /// @brief Gets the last successful changed contacts database version on the current connection. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @privilege %http://tizen.org/privilege/callhistory.read + /// @param[out] last_change_version The database version + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_db_get_current_version() + int contacts_db_get_last_change_version( + ffi.Pointer last_change_version, + ) { + return _contacts_db_get_last_change_version( + last_change_version, + ); + } + + late final _contacts_db_get_last_change_version_ptr = + _lookup>( + 'contacts_db_get_last_change_version'); + late final _dart_contacts_db_get_last_change_version + _contacts_db_get_last_change_version = + _contacts_db_get_last_change_version_ptr + .asFunction<_dart_contacts_db_get_last_change_version>(); + + /// @brief Gets the contacts name display order. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @param[out] name_display_order The name display order + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_IPC Unknown IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_setting_get_name_display_order( + ffi.Pointer name_display_order, + ) { + return _contacts_setting_get_name_display_order( + name_display_order, + ); + } + + late final _contacts_setting_get_name_display_order_ptr = + _lookup>( + 'contacts_setting_get_name_display_order'); + late final _dart_contacts_setting_get_name_display_order + _contacts_setting_get_name_display_order = + _contacts_setting_get_name_display_order_ptr + .asFunction<_dart_contacts_setting_get_name_display_order>(); + + /// @brief Sets the contacts name display order. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @param[in] name_display_order The name display order + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_IPC Unknown IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @post contacts_setting_name_display_order_changed_cb() callback will be called upon success. + /// @see contacts_connect() + int contacts_setting_set_name_display_order( + int name_display_order, + ) { + return _contacts_setting_set_name_display_order( + name_display_order, + ); + } + + late final _contacts_setting_set_name_display_order_ptr = + _lookup>( + 'contacts_setting_set_name_display_order'); + late final _dart_contacts_setting_set_name_display_order + _contacts_setting_set_name_display_order = + _contacts_setting_set_name_display_order_ptr + .asFunction<_dart_contacts_setting_set_name_display_order>(); + + /// @brief Gets the contacts name sorting order in which contacts are returned. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @param[out] name_sorting_order The name sorting order + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_IPC Unknown IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_setting_get_name_sorting_order( + ffi.Pointer name_sorting_order, + ) { + return _contacts_setting_get_name_sorting_order( + name_sorting_order, + ); + } + + late final _contacts_setting_get_name_sorting_order_ptr = + _lookup>( + 'contacts_setting_get_name_sorting_order'); + late final _dart_contacts_setting_get_name_sorting_order + _contacts_setting_get_name_sorting_order = + _contacts_setting_get_name_sorting_order_ptr + .asFunction<_dart_contacts_setting_get_name_sorting_order>(); + + /// @brief Sets the contacts name sorting order in which contacts are returned. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @param[in] name_sorting_order The name sorting order + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_IPC Unknown IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @post contacts_setting_name_sorting_order_changed_cb() callback will be called upon success. + /// @see contacts_connect() + int contacts_setting_set_name_sorting_order( + int name_sorting_order, + ) { + return _contacts_setting_set_name_sorting_order( + name_sorting_order, + ); + } + + late final _contacts_setting_set_name_sorting_order_ptr = + _lookup>( + 'contacts_setting_set_name_sorting_order'); + late final _dart_contacts_setting_set_name_sorting_order + _contacts_setting_set_name_sorting_order = + _contacts_setting_set_name_sorting_order_ptr + .asFunction<_dart_contacts_setting_set_name_sorting_order>(); + + /// @brief Registers a callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_IPC Unknown IPC error + /// @retval #CONTACTS_ERROR_INTERNAL Implementation Error, Temporary Use + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @post contacts_setting_name_display_order_changed_cb() will be called under certain conditions, after calling contacts_setting_set_name_display_order(). + /// @see contacts_connect() + /// @see contacts_setting_remove_name_display_order_changed_cb() + int contacts_setting_add_name_display_order_changed_cb( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, + ) { + return _contacts_setting_add_name_display_order_changed_cb( + callback, + user_data, + ); + } + + late final _contacts_setting_add_name_display_order_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_contacts_setting_add_name_display_order_changed_cb>>( + 'contacts_setting_add_name_display_order_changed_cb'); + late final _dart_contacts_setting_add_name_display_order_changed_cb + _contacts_setting_add_name_display_order_changed_cb = + _contacts_setting_add_name_display_order_changed_cb_ptr.asFunction< + _dart_contacts_setting_add_name_display_order_changed_cb>(); + + /// @brief Unregisters a callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_INTERNAL Implementation Error, Temporary Use + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_setting_add_name_display_order_changed_cb() + int contacts_setting_remove_name_display_order_changed_cb( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, + ) { + return _contacts_setting_remove_name_display_order_changed_cb( + callback, + user_data, + ); + } + + late final _contacts_setting_remove_name_display_order_changed_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_contacts_setting_remove_name_display_order_changed_cb>>( + 'contacts_setting_remove_name_display_order_changed_cb'); + late final _dart_contacts_setting_remove_name_display_order_changed_cb + _contacts_setting_remove_name_display_order_changed_cb = + _contacts_setting_remove_name_display_order_changed_cb_ptr.asFunction< + _dart_contacts_setting_remove_name_display_order_changed_cb>(); + + /// @brief Registers a callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_IPC Unknown IPC error + /// @retval #CONTACTS_ERROR_INTERNAL Implementation Error, Temporary Use + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @post contacts_setting_name_sorting_order_changed_cb() will be called under certain conditions, after calling contacts_setting_set_name_sorting_order(). + /// @see contacts_connect() + /// @see contacts_setting_remove_name_sorting_order_changed_cb() + int contacts_setting_add_name_sorting_order_changed_cb( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, + ) { + return _contacts_setting_add_name_sorting_order_changed_cb( + callback, + user_data, + ); + } + + late final _contacts_setting_add_name_sorting_order_changed_cb_ptr = _lookup< + ffi.NativeFunction< + _c_contacts_setting_add_name_sorting_order_changed_cb>>( + 'contacts_setting_add_name_sorting_order_changed_cb'); + late final _dart_contacts_setting_add_name_sorting_order_changed_cb + _contacts_setting_add_name_sorting_order_changed_cb = + _contacts_setting_add_name_sorting_order_changed_cb_ptr.asFunction< + _dart_contacts_setting_add_name_sorting_order_changed_cb>(); + + /// @brief Unregisters a callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_INTERNAL Implementation Error, Temporary Use + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_setting_add_name_sorting_order_changed_cb() + int contacts_setting_remove_name_sorting_order_changed_cb( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, + ) { + return _contacts_setting_remove_name_sorting_order_changed_cb( + callback, + user_data, + ); + } + + late final _contacts_setting_remove_name_sorting_order_changed_cb_ptr = + _lookup< + ffi.NativeFunction< + _c_contacts_setting_remove_name_sorting_order_changed_cb>>( + 'contacts_setting_remove_name_sorting_order_changed_cb'); + late final _dart_contacts_setting_remove_name_sorting_order_changed_cb + _contacts_setting_remove_name_sorting_order_changed_cb = + _contacts_setting_remove_name_sorting_order_changed_cb_ptr.asFunction< + _dart_contacts_setting_remove_name_sorting_order_changed_cb>(); + + /// @brief Links a person to another person. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @param[in] base_person_id The base person ID + /// @param[in] person_id The person ID to link to + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_person_link_person( + int base_person_id, + int person_id, + ) { + return _contacts_person_link_person( + base_person_id, + person_id, + ); + } + + late final _contacts_person_link_person_ptr = + _lookup>( + 'contacts_person_link_person'); + late final _dart_contacts_person_link_person _contacts_person_link_person = + _contacts_person_link_person_ptr + .asFunction<_dart_contacts_person_link_person>(); + + /// @brief Unlinks a contact from a person. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @param[in] person_id The person ID + /// @param[in] contact_id The contact ID to unlink + /// @param[out] unlinked_person_id The person ID generated + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_person_unlink_contact( + int person_id, + int contact_id, + ffi.Pointer unlinked_person_id, + ) { + return _contacts_person_unlink_contact( + person_id, + contact_id, + unlinked_person_id, + ); + } + + late final _contacts_person_unlink_contact_ptr = + _lookup>( + 'contacts_person_unlink_contact'); + late final _dart_contacts_person_unlink_contact + _contacts_person_unlink_contact = _contacts_person_unlink_contact_ptr + .asFunction<_dart_contacts_person_unlink_contact>(); + + /// @brief Resets a person's usage count. + /// @details The person is no longer in the most frequently contacted person list. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @param[in] person_id The person ID + /// @param[in] type The type to reset + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_person_reset_usage( + int person_id, + int type, + ) { + return _contacts_person_reset_usage( + person_id, + type, + ); + } + + late final _contacts_person_reset_usage_ptr = + _lookup>( + 'contacts_person_reset_usage'); + late final _dart_contacts_person_reset_usage _contacts_person_reset_usage = + _contacts_person_reset_usage_ptr + .asFunction<_dart_contacts_person_reset_usage>(); + + /// @brief Sets the order of a (favorite) contact. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @param[in] person_id The person ID to move + /// @param[in] previous_person_id The previous person ID + /// @param[in] next_person_id The back person ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_person_set_favorite_order( + int person_id, + int previous_person_id, + int next_person_id, + ) { + return _contacts_person_set_favorite_order( + person_id, + previous_person_id, + next_person_id, + ); + } + + late final _contacts_person_set_favorite_order_ptr = + _lookup>( + 'contacts_person_set_favorite_order'); + late final _dart_contacts_person_set_favorite_order + _contacts_person_set_favorite_order = + _contacts_person_set_favorite_order_ptr + .asFunction<_dart_contacts_person_set_favorite_order>(); + + /// @brief Sets a record's default property. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @remarks @a id can be contact_id, number_id, email_id, image_id. + /// @param[in] property #contacts_person_property_e + /// @param[in] person_id The person ID + /// @param[in] id The record ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_person_set_default_property( + int property, + int person_id, + int id, + ) { + return _contacts_person_set_default_property( + property, + person_id, + id, + ); + } + + late final _contacts_person_set_default_property_ptr = + _lookup>( + 'contacts_person_set_default_property'); + late final _dart_contacts_person_set_default_property + _contacts_person_set_default_property = + _contacts_person_set_default_property_ptr + .asFunction<_dart_contacts_person_set_default_property>(); + + /// @brief Gets a default property for a record. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @remarks @a id can be contact_id, number_id, email_id, image_id. + /// @param[in] property #contacts_person_property_e + /// @param[in] person_id The person ID + /// @param[out] id The record ID of the property to be set as default + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_person_get_default_property( + int property, + int person_id, + ffi.Pointer id, + ) { + return _contacts_person_get_default_property( + property, + person_id, + id, + ); + } + + late final _contacts_person_get_default_property_ptr = + _lookup>( + 'contacts_person_get_default_property'); + late final _dart_contacts_person_get_default_property + _contacts_person_get_default_property = + _contacts_person_get_default_property_ptr + .asFunction<_dart_contacts_person_get_default_property>(); + + /// @brief Gets aggregation suggestions. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @remarks You must release @a record_list using contacts_list_destroy(). + /// @remarks This may take a long time. If you need to use it in bulk, make sure the user experience is acceptable while running it. + /// @param[in] person_id The person ID + /// @param[in] limit The number to limit results(value 0 is used for get all records) + /// @param[out] record_list The list of person records + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_person_get_aggregation_suggestions( + int person_id, + int limit, + ffi.Pointer> record_list, + ) { + return _contacts_person_get_aggregation_suggestions( + person_id, + limit, + record_list, + ); + } + + late final _contacts_person_get_aggregation_suggestions_ptr = _lookup< + ffi.NativeFunction<_c_contacts_person_get_aggregation_suggestions>>( + 'contacts_person_get_aggregation_suggestions'); + late final _dart_contacts_person_get_aggregation_suggestions + _contacts_person_get_aggregation_suggestions = + _contacts_person_get_aggregation_suggestions_ptr + .asFunction<_dart_contacts_person_get_aggregation_suggestions>(); + + /// @brief Adds a contact and a group relationship to the contacts database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @param[in] group_id The group ID + /// @param[in] contact_id The contact ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_group_remove_contact() + int contacts_group_add_contact( + int group_id, + int contact_id, + ) { + return _contacts_group_add_contact( + group_id, + contact_id, + ); + } + + late final _contacts_group_add_contact_ptr = + _lookup>( + 'contacts_group_add_contact'); + late final _dart_contacts_group_add_contact _contacts_group_add_contact = + _contacts_group_add_contact_ptr + .asFunction<_dart_contacts_group_add_contact>(); + + /// @brief Removes a contact and a group relationship from the contacts database. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @param[in] group_id The group ID + /// @param[in] contact_id The contact ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_group_add_contact() + int contacts_group_remove_contact( + int group_id, + int contact_id, + ) { + return _contacts_group_remove_contact( + group_id, + contact_id, + ); + } + + late final _contacts_group_remove_contact_ptr = + _lookup>( + 'contacts_group_remove_contact'); + late final _dart_contacts_group_remove_contact + _contacts_group_remove_contact = _contacts_group_remove_contact_ptr + .asFunction<_dart_contacts_group_remove_contact>(); + + /// @brief Sets a group between the previous group and the next group. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @param[in] group_id The group ID to move + /// @param[in] previous_group_id The previous group ID + /// @param[in] next_group_id The back group ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_group_set_group_order( + int group_id, + int previous_group_id, + int next_group_id, + ) { + return _contacts_group_set_group_order( + group_id, + previous_group_id, + next_group_id, + ); + } + + late final _contacts_group_set_group_order_ptr = + _lookup>( + 'contacts_group_set_group_order'); + late final _dart_contacts_group_set_group_order + _contacts_group_set_group_order = _contacts_group_set_group_order_ptr + .asFunction<_dart_contacts_group_set_group_order>(); + + /// @deprecated Deprecated since 3.0. Use contacts_sim_import_all_contacts_by_sim_slot_no() instead. + /// @brief Imports all contacts from first SIM to Contacts Database. + /// @since_tizen @if MOBILE 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_IPC Unknown IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @retval #CONTACTS_ERROR_INTERNAL Implementation Error, Temporary Use + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_sim_import_all_contacts() { + return _contacts_sim_import_all_contacts(); + } + + late final _contacts_sim_import_all_contacts_ptr = + _lookup>( + 'contacts_sim_import_all_contacts'); + late final _dart_contacts_sim_import_all_contacts + _contacts_sim_import_all_contacts = _contacts_sim_import_all_contacts_ptr + .asFunction<_dart_contacts_sim_import_all_contacts>(); + + /// @deprecated Deprecated since 3.0. Use contacts_sim_get_initialization_status_by_sim_slot_no() instead. + /// @brief Checks whether first SIM initialization is completed. + /// @since_tizen @if MOBILE 2.3 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @param[out] completed @c true if SIM is initialized, + /// otherwise @c false if SIM is not initialized + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_IPC Unknown IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_sim_get_initialization_status( + ffi.Pointer completed, + ) { + return _contacts_sim_get_initialization_status( + completed, + ); + } + + late final _contacts_sim_get_initialization_status_ptr = + _lookup>( + 'contacts_sim_get_initialization_status'); + late final _dart_contacts_sim_get_initialization_status + _contacts_sim_get_initialization_status = + _contacts_sim_get_initialization_status_ptr + .asFunction<_dart_contacts_sim_get_initialization_status>(); + + /// @brief Imports all contacts from SIM of the given SIM slot number to the Contacts Database. + /// @details This function invokes contacts_sim_import_progress_cb() to indicate the progress of imports whenever a contact is imported. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @param[in] sim_slot_no The SIM slot number; 0 means first SIM, 1 means second SIM + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_IPC Unknown IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + /// @see contacts_sim_import_progress_cb() + int contacts_sim_import_all_contacts_by_sim_slot_no( + int sim_slot_no, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _contacts_sim_import_all_contacts_by_sim_slot_no( + sim_slot_no, + callback, + user_data, + ); + } + + late final _contacts_sim_import_all_contacts_by_sim_slot_no_ptr = _lookup< + ffi.NativeFunction< + _c_contacts_sim_import_all_contacts_by_sim_slot_no>>( + 'contacts_sim_import_all_contacts_by_sim_slot_no'); + late final _dart_contacts_sim_import_all_contacts_by_sim_slot_no + _contacts_sim_import_all_contacts_by_sim_slot_no = + _contacts_sim_import_all_contacts_by_sim_slot_no_ptr + .asFunction<_dart_contacts_sim_import_all_contacts_by_sim_slot_no>(); + + /// @brief Checks whether SIM of the given SIM slot number is initialized. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @param[in] sim_slot_no The SIM slot number; 0 means first SIM, 1 means second SIM + /// @param[out] completed @c true if SIM is initialized, + /// otherwise @c false if SIM is not initialized + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_IPC Unknown IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_sim_get_initialization_status_by_sim_slot_no( + int sim_slot_no, + ffi.Pointer completed, + ) { + return _contacts_sim_get_initialization_status_by_sim_slot_no( + sim_slot_no, + completed, + ); + } + + late final _contacts_sim_get_initialization_status_by_sim_slot_no_ptr = + _lookup< + ffi.NativeFunction< + _c_contacts_sim_get_initialization_status_by_sim_slot_no>>( + 'contacts_sim_get_initialization_status_by_sim_slot_no'); + late final _dart_contacts_sim_get_initialization_status_by_sim_slot_no + _contacts_sim_get_initialization_status_by_sim_slot_no = + _contacts_sim_get_initialization_status_by_sim_slot_no_ptr.asFunction< + _dart_contacts_sim_get_initialization_status_by_sim_slot_no>(); + + /// @brief Retrieves all contacts with a record handle (_contacts_contact) from a vCard file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] vcard_file_path The file path of vCard stream file + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_NO_DATA Requested data does not exist + /// @retval #CONTACTS_ERROR_SYSTEM System error + /// @pre contacts_connect() should be called to initialize. + /// @post This function invokes contacts_vcard_parse_cb(). + /// @see contacts_vcard_parse_cb() + int contacts_vcard_parse_to_contact_foreach( + ffi.Pointer vcard_file_path, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _contacts_vcard_parse_to_contact_foreach( + vcard_file_path, + callback, + user_data, + ); + } + + late final _contacts_vcard_parse_to_contact_foreach_ptr = + _lookup>( + 'contacts_vcard_parse_to_contact_foreach'); + late final _dart_contacts_vcard_parse_to_contact_foreach + _contacts_vcard_parse_to_contact_foreach = + _contacts_vcard_parse_to_contact_foreach_ptr + .asFunction<_dart_contacts_vcard_parse_to_contact_foreach>(); + + /// @brief Retrieves all contacts with a contacts list from a vCard stream. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] vcard_stream The vCard stream + /// @param[out] contacts_list The contacts list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to initialize. + int contacts_vcard_parse_to_contacts( + ffi.Pointer vcard_stream, + ffi.Pointer> contacts_list, + ) { + return _contacts_vcard_parse_to_contacts( + vcard_stream, + contacts_list, + ); + } + + late final _contacts_vcard_parse_to_contacts_ptr = + _lookup>( + 'contacts_vcard_parse_to_contacts'); + late final _dart_contacts_vcard_parse_to_contacts + _contacts_vcard_parse_to_contacts = _contacts_vcard_parse_to_contacts_ptr + .asFunction<_dart_contacts_vcard_parse_to_contacts>(); + + /// @brief Retrieves the vCard stream from a contact. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] contact The contact record handle + /// @param[out] vcard_stream The vCard stream + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + int contacts_vcard_make_from_contact( + ffi.Pointer<__contacts_record_h> contact, + ffi.Pointer> vcard_stream, + ) { + return _contacts_vcard_make_from_contact( + contact, + vcard_stream, + ); + } + + late final _contacts_vcard_make_from_contact_ptr = + _lookup>( + 'contacts_vcard_make_from_contact'); + late final _dart_contacts_vcard_make_from_contact + _contacts_vcard_make_from_contact = _contacts_vcard_make_from_contact_ptr + .asFunction<_dart_contacts_vcard_make_from_contact>(); + + /// @brief Retrieves the vCard stream from a contact. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] my_profile The my_profile record handle + /// @param[out] vcard_stream The vCard stream + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + int contacts_vcard_make_from_my_profile( + ffi.Pointer<__contacts_record_h> my_profile, + ffi.Pointer> vcard_stream, + ) { + return _contacts_vcard_make_from_my_profile( + my_profile, + vcard_stream, + ); + } + + late final _contacts_vcard_make_from_my_profile_ptr = + _lookup>( + 'contacts_vcard_make_from_my_profile'); + late final _dart_contacts_vcard_make_from_my_profile + _contacts_vcard_make_from_my_profile = + _contacts_vcard_make_from_my_profile_ptr + .asFunction<_dart_contacts_vcard_make_from_my_profile>(); + + /// @brief Retrieves the vCard stream from a person. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @param[in] person The person record handle + /// @param[out] vcard_stream The vCard stream + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB DB error + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to initialize. + int contacts_vcard_make_from_person( + ffi.Pointer<__contacts_record_h> person, + ffi.Pointer> vcard_stream, + ) { + return _contacts_vcard_make_from_person( + person, + vcard_stream, + ); + } + + late final _contacts_vcard_make_from_person_ptr = + _lookup>( + 'contacts_vcard_make_from_person'); + late final _dart_contacts_vcard_make_from_person + _contacts_vcard_make_from_person = _contacts_vcard_make_from_person_ptr + .asFunction<_dart_contacts_vcard_make_from_person>(); + + /// @brief Retrieves the count of contact entities from a vCard file. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] vcard_file_path The person record handle + /// @param[out] count The count of contact entity + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM System error + int contacts_vcard_get_entity_count( + ffi.Pointer vcard_file_path, + ffi.Pointer count, + ) { + return _contacts_vcard_get_entity_count( + vcard_file_path, + count, + ); + } + + late final _contacts_vcard_get_entity_count_ptr = + _lookup>( + 'contacts_vcard_get_entity_count'); + late final _dart_contacts_vcard_get_entity_count + _contacts_vcard_get_entity_count = _contacts_vcard_get_entity_count_ptr + .asFunction<_dart_contacts_vcard_get_entity_count>(); + + /// @brief Gets the limit size of width and height of photos to append in vCard streams. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.read + /// @param[out] limit_size The limit size of width and height of photos to append in vCard streams. It's in pixels + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + int contacts_vcard_get_limit_size_of_photo( + ffi.Pointer limit_size, + ) { + return _contacts_vcard_get_limit_size_of_photo( + limit_size, + ); + } + + late final _contacts_vcard_get_limit_size_of_photo_ptr = + _lookup>( + 'contacts_vcard_get_limit_size_of_photo'); + late final _dart_contacts_vcard_get_limit_size_of_photo + _contacts_vcard_get_limit_size_of_photo = + _contacts_vcard_get_limit_size_of_photo_ptr + .asFunction<_dart_contacts_vcard_get_limit_size_of_photo>(); + + /// @brief Sets the limit size of width and height of photos to append to vCard streams. + /// @details This function can be used for getting reduced vCard stream. \n + /// When making vCard stream by using contacts_vcard_make_from_person(), contacts_vcard_make_from_my_profile(), contacts_vcard_make_from_contact(), \n + /// if width or height of the photo to append is bigger than the limit size, it is reduced to the limit size while maintaining original aspect ratio, \n + /// so that vCard stream size can be reduced. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @remarks The limit_size should be bigger than or equal to 8 and smaller than 1080. + /// @param[in] limit_size The limit size of width and height of photos to append in vCard streams. It's in pixels + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + int contacts_vcard_set_limit_size_of_photo( + int limit_size, + ) { + return _contacts_vcard_set_limit_size_of_photo( + limit_size, + ); + } + + late final _contacts_vcard_set_limit_size_of_photo_ptr = + _lookup>( + 'contacts_vcard_set_limit_size_of_photo'); + late final _dart_contacts_vcard_set_limit_size_of_photo + _contacts_vcard_set_limit_size_of_photo = + _contacts_vcard_set_limit_size_of_photo_ptr + .asFunction<_dart_contacts_vcard_set_limit_size_of_photo>(); + + /// @brief Deletes an activity record from the contacts database by contact ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @param[in] contact_id The contact ID to delete + /// @return @c 0 on success, + /// otherwise a negative error value (#contacts_error_e) + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_activity_delete_by_contact_id( + int contact_id, + ) { + return _contacts_activity_delete_by_contact_id( + contact_id, + ); + } + + late final _contacts_activity_delete_by_contact_id_ptr = + _lookup>( + 'contacts_activity_delete_by_contact_id'); + late final _dart_contacts_activity_delete_by_contact_id + _contacts_activity_delete_by_contact_id = + _contacts_activity_delete_by_contact_id_ptr + .asFunction<_dart_contacts_activity_delete_by_contact_id>(); + + /// @brief Deletes an activity record from the contacts database by account ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/contact.write + /// @param[in] account_id The account ID to delete + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_activity_delete_by_account_id( + int account_id, + ) { + return _contacts_activity_delete_by_account_id( + account_id, + ); + } + + late final _contacts_activity_delete_by_account_id_ptr = + _lookup>( + 'contacts_activity_delete_by_account_id'); + late final _dart_contacts_activity_delete_by_account_id + _contacts_activity_delete_by_account_id = + _contacts_activity_delete_by_account_id_ptr + .asFunction<_dart_contacts_activity_delete_by_account_id>(); + + /// @brief Resets the phone log's count. + /// @details The number of all types in the phone log will be @c 0. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/callhistory.write + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_phone_log_reset_statistics() { + return _contacts_phone_log_reset_statistics(); + } + + late final _contacts_phone_log_reset_statistics_ptr = + _lookup>( + 'contacts_phone_log_reset_statistics'); + late final _dart_contacts_phone_log_reset_statistics + _contacts_phone_log_reset_statistics = + _contacts_phone_log_reset_statistics_ptr + .asFunction<_dart_contacts_phone_log_reset_statistics>(); + + /// @brief Resets the phone log's count by sim slot no. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/callhistory.write + /// @param[in] sim_slot_no It is related to the SIM slot number. sim_slot_no 0 means first SIM, sim_slot_no 1 means second SIM + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #CONTACTS_ERROR_FILE_NO_SPACE FS Full + /// @retval #CONTACTS_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_DB Database operation failure + /// @retval #CONTACTS_ERROR_IPC IPC error + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre contacts_connect() should be called to open a connection to the contacts service. + /// @see contacts_connect() + int contacts_phone_log_reset_statistics_by_sim( + int sim_slot_no, + ) { + return _contacts_phone_log_reset_statistics_by_sim( + sim_slot_no, + ); + } + + late final _contacts_phone_log_reset_statistics_by_sim_ptr = _lookup< + ffi.NativeFunction<_c_contacts_phone_log_reset_statistics_by_sim>>( + 'contacts_phone_log_reset_statistics_by_sim'); + late final _dart_contacts_phone_log_reset_statistics_by_sim + _contacts_phone_log_reset_statistics_by_sim = + _contacts_phone_log_reset_statistics_by_sim_ptr + .asFunction<_dart_contacts_phone_log_reset_statistics_by_sim>(); + + /// @brief Gets the current status of server. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] status The current status of server + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre This function requires an open connection to the contacts service by contacts_connect(). + /// @see contacts_connect() + int contacts_db_get_status( + ffi.Pointer status, + ) { + return _contacts_db_get_status( + status, + ); + } + + late final _contacts_db_get_status_ptr = + _lookup>( + 'contacts_db_get_status'); + late final _dart_contacts_db_get_status _contacts_db_get_status = + _contacts_db_get_status_ptr.asFunction<_dart_contacts_db_get_status>(); + + /// @brief Registers a callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre This function requires an open connection to the contacts service by contacts_connect(). + /// @see contacts_connect() + /// @see contacts_db_remove_status_changed_cb() + int contacts_db_add_status_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _contacts_db_add_status_changed_cb( + callback, + user_data, + ); + } + + late final _contacts_db_add_status_changed_cb_ptr = + _lookup>( + 'contacts_db_add_status_changed_cb'); + late final _dart_contacts_db_add_status_changed_cb + _contacts_db_add_status_changed_cb = + _contacts_db_add_status_changed_cb_ptr + .asFunction<_dart_contacts_db_add_status_changed_cb>(); + + /// @brief Unregisters a callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #CONTACTS_ERROR_NONE Successful + /// @retval #CONTACTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #CONTACTS_ERROR_NOT_SUPPORTED Not supported + /// @retval #CONTACTS_ERROR_SYSTEM Internal system module error + /// @pre This function requires an open connection to the contacts service by contacts_connect(). + /// @see contacts_connect() + /// @see contacts_db_add_status_changed_cb() + int contacts_db_remove_status_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _contacts_db_remove_status_changed_cb( + callback, + user_data, + ); + } + + late final _contacts_db_remove_status_changed_cb_ptr = + _lookup>( + 'contacts_db_remove_status_changed_cb'); + late final _dart_contacts_db_remove_status_changed_cb + _contacts_db_remove_status_changed_cb = + _contacts_db_remove_status_changed_cb_ptr + .asFunction<_dart_contacts_db_remove_status_changed_cb>(); + + /// @brief Creates a blocking rule. + /// + /// @since_tizen 4.0 + /// + /// @remarks You must release @a rule using phone_number_blocking_rule_destroy(). + /// + /// @param[out] rule The blocking rule handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PHONE_NUMBER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// + /// @pre phone_number_connect() should be called to initialize. + /// + /// @see phone_number_blocking_rule_destroy() + int phone_number_blocking_rule_create( + ffi.Pointer> rule, + ) { + return _phone_number_blocking_rule_create( + rule, + ); + } + + late final _phone_number_blocking_rule_create_ptr = + _lookup>( + 'phone_number_blocking_rule_create'); + late final _dart_phone_number_blocking_rule_create + _phone_number_blocking_rule_create = + _phone_number_blocking_rule_create_ptr + .asFunction<_dart_phone_number_blocking_rule_create>(); + + /// @brief Destroys a blocking rule and releases all its resources. + /// + /// @since_tizen 4.0 + /// + /// @param[in] rule The blocking rule handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// + /// @see phone_number_blocking_rule_create() + int phone_number_blocking_rule_destroy( + ffi.Pointer rule, + ) { + return _phone_number_blocking_rule_destroy( + rule, + ); + } + + late final _phone_number_blocking_rule_destroy_ptr = + _lookup>( + 'phone_number_blocking_rule_destroy'); + late final _dart_phone_number_blocking_rule_destroy + _phone_number_blocking_rule_destroy = + _phone_number_blocking_rule_destroy_ptr + .asFunction<_dart_phone_number_blocking_rule_destroy>(); + + /// @brief Gets a blocked number from a rule. + /// + /// @since_tizen 4.0 + /// + /// @remarks You must release @a number using free(). + /// + /// @param[in] rule The blocking rule handle + /// @param[out] number The blocked number + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// + /// @see phone_number_blocking_rule_set_number() + int phone_number_blocking_rule_get_number( + ffi.Pointer rule, + ffi.Pointer> number, + ) { + return _phone_number_blocking_rule_get_number( + rule, + number, + ); + } + + late final _phone_number_blocking_rule_get_number_ptr = + _lookup>( + 'phone_number_blocking_rule_get_number'); + late final _dart_phone_number_blocking_rule_get_number + _phone_number_blocking_rule_get_number = + _phone_number_blocking_rule_get_number_ptr + .asFunction<_dart_phone_number_blocking_rule_get_number>(); + + /// @brief Gets a rule's match type. + /// + /// @since_tizen 4.0 + /// + /// @param[in] rule The blocking rule handle + /// @param[out] match_type The match type of blocked number + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// + /// @see phone_number_blocking_rule_set_match_type() + int phone_number_blocking_rule_get_match_type( + ffi.Pointer rule, + ffi.Pointer match_type, + ) { + return _phone_number_blocking_rule_get_match_type( + rule, + match_type, + ); + } + + late final _phone_number_blocking_rule_get_match_type_ptr = + _lookup>( + 'phone_number_blocking_rule_get_match_type'); + late final _dart_phone_number_blocking_rule_get_match_type + _phone_number_blocking_rule_get_match_type = + _phone_number_blocking_rule_get_match_type_ptr + .asFunction<_dart_phone_number_blocking_rule_get_match_type>(); + + /// @brief Sets a blocked number to a rule. + /// + /// @since_tizen 4.0 + /// + /// @param[in] rule The blocking rule handle + /// @param[in] number The blocked number + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// + /// @see phone_number_blocking_rule_get_number() + int phone_number_blocking_rule_set_number( + ffi.Pointer rule, + ffi.Pointer number, + ) { + return _phone_number_blocking_rule_set_number( + rule, + number, + ); + } + + late final _phone_number_blocking_rule_set_number_ptr = + _lookup>( + 'phone_number_blocking_rule_set_number'); + late final _dart_phone_number_blocking_rule_set_number + _phone_number_blocking_rule_set_number = + _phone_number_blocking_rule_set_number_ptr + .asFunction<_dart_phone_number_blocking_rule_set_number>(); + + /// @brief Sets a rule's match type. + /// + /// @since_tizen 4.0 + /// + /// @param[in] rule The blocking rule handle + /// @param[in] match_type The match type of blocked number + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// + /// @see phone_number_blocking_rule_get_match_type() + int phone_number_blocking_rule_set_match_type( + ffi.Pointer rule, + int match_type, + ) { + return _phone_number_blocking_rule_set_match_type( + rule, + match_type, + ); + } + + late final _phone_number_blocking_rule_set_match_type_ptr = + _lookup>( + 'phone_number_blocking_rule_set_match_type'); + late final _dart_phone_number_blocking_rule_set_match_type + _phone_number_blocking_rule_set_match_type = + _phone_number_blocking_rule_set_match_type_ptr + .asFunction<_dart_phone_number_blocking_rule_set_match_type>(); + + /// @brief Connects to the phonenumber-utils service. + /// @since_tizen 3.0 + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// @see phone_number_disconnect() + int phone_number_connect() { + return _phone_number_connect(); + } + + late final _phone_number_connect_ptr = + _lookup>( + 'phone_number_connect'); + late final _dart_phone_number_connect _phone_number_connect = + _phone_number_connect_ptr.asFunction<_dart_phone_number_connect>(); + + /// @brief Disconnects from the phonenumber-utils service. + /// @since_tizen 3.0 + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// @see phone_number_connect() + int phone_number_disconnect() { + return _phone_number_disconnect(); + } + + late final _phone_number_disconnect_ptr = + _lookup>( + 'phone_number_disconnect'); + late final _dart_phone_number_disconnect _phone_number_disconnect = + _phone_number_disconnect_ptr.asFunction<_dart_phone_number_disconnect>(); + + /// @brief Gets the location string from number, region, and language. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a location using free(). + /// @remarks The phonenumber-utils is changed to client/server architecture for performance improvement since 3.0. + /// phone_number_connect()/phone_number_disconnect() should be called. + /// @param[in] number The number + /// @param[in] region The region of number + /// @param[in] language The language of location + /// @param[out] location The location string to be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PHONE_NUMBER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PHONE_NUMBER_ERROR_FILE_NO_SPACE_ON_DEVICE FS Full + /// @retval #PHONE_NUMBER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_NO_DATA Requested data does not exist + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// @pre phone_number_connect() should be called to open a connection to the phonenumber-utils service. (Since 3.0) + /// @post phone_number_disconnect() should be called to close a connection to the phonenumber-utils service. (Since 3.0) + int phone_number_get_location_from_number( + ffi.Pointer number, + int region, + int language, + ffi.Pointer> location, + ) { + return _phone_number_get_location_from_number( + number, + region, + language, + location, + ); + } + + late final _phone_number_get_location_from_number_ptr = + _lookup>( + 'phone_number_get_location_from_number'); + late final _dart_phone_number_get_location_from_number + _phone_number_get_location_from_number = + _phone_number_get_location_from_number_ptr + .asFunction<_dart_phone_number_get_location_from_number>(); + + /// @brief Gets the formatted number. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks You must release @a formatted_number using free(). + /// @remarks The phonenumber-utils is changed to client/server architecture for performance improvement since 3.0. + /// phone_number_connect()/phone_number_disconnect() should be called. + /// @param[in] number The number + /// @param[in] region The region of number + /// @param[out] formatted_number The formatted number string to be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PHONE_NUMBER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PHONE_NUMBER_ERROR_FILE_NO_SPACE_ON_DEVICE FS Full + /// @retval #PHONE_NUMBER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_NO_DATA Requested data does not exist + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// @pre phone_number_connect() should be called to open a connection to the phonenumber-utils service. (Since 3.0) + /// @post phone_number_disconnect() should be called to close a connection to the phonenumber-utils service. (Since 3.0) + int phone_number_get_formatted_number( + ffi.Pointer number, + int region, + ffi.Pointer> formatted_number, + ) { + return _phone_number_get_formatted_number( + number, + region, + formatted_number, + ); + } + + late final _phone_number_get_formatted_number_ptr = + _lookup>( + 'phone_number_get_formatted_number'); + late final _dart_phone_number_get_formatted_number + _phone_number_get_formatted_number = + _phone_number_get_formatted_number_ptr + .asFunction<_dart_phone_number_get_formatted_number>(); + + /// @brief Gets the normalized number. + /// @details Normalized number starts with plus('+') and country code, and excludes the separators such + /// as dash or space. It is a format of E.164 standard including the country code based on current network. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// @remarks You must release @a normalized_number using free(). + /// @remarks The phonenumber-utils is changed to client/server architecture for performance improvement since 3.0. + /// phone_number_connect()/phone_number_disconnect() should be called. + /// @param[in] number The number + /// @param[out] normalized_number The normalized number string to be returned + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PHONE_NUMBER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PHONE_NUMBER_ERROR_PERMISSION_DENIED Permission denied + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_NO_DATA Requested data does not exist + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// @pre phone_number_connect() should be called to open a connection to the phonenumber-utils service. (Since 3.0) + /// @post phone_number_disconnect() should be called to close a connection to the phonenumber-utils service. (Since 3.0) + int phone_number_get_normalized_number( + ffi.Pointer number, + ffi.Pointer> normalized_number, + ) { + return _phone_number_get_normalized_number( + number, + normalized_number, + ); + } + + late final _phone_number_get_normalized_number_ptr = + _lookup>( + 'phone_number_get_normalized_number'); + late final _dart_phone_number_get_normalized_number + _phone_number_get_normalized_number = + _phone_number_get_normalized_number_ptr + .asFunction<_dart_phone_number_get_normalized_number>(); + + /// @brief Adds a blocking rule to the phone number database. + /// + /// @since_tizen 4.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/blocknumber.write + /// + /// @param[in] rule The blocking rule handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PHONE_NUMBER_ERROR_DB_FAILED Database operation failure + /// @retval #PHONE_NUMBER_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_IPC Unknown IPC error + /// @retval #PHONE_NUMBER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// @pre phone_number_connect() should be called to open a connection to the phonenumber-utils service. + /// @post phone_number_disconnect() should be called to close a connection to the phonenumber-utils service. + /// @see phone_number_remove_blocking_rule() + int phone_number_add_blocking_rule( + ffi.Pointer rule, + ) { + return _phone_number_add_blocking_rule( + rule, + ); + } + + late final _phone_number_add_blocking_rule_ptr = + _lookup>( + 'phone_number_add_blocking_rule'); + late final _dart_phone_number_add_blocking_rule + _phone_number_add_blocking_rule = _phone_number_add_blocking_rule_ptr + .asFunction<_dart_phone_number_add_blocking_rule>(); + + /// @brief Removes a blocking rule from the phone number database. + /// + /// @since_tizen 4.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/blocknumber.write + /// + /// @remarks The blocking rule to remove should have been gotten from the phone number database using phone_number_get_blocking_rules(). + /// + /// @param[in] rule The blocking rule handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PHONE_NUMBER_ERROR_DB_FAILED Database operation failure + /// @retval #PHONE_NUMBER_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_IPC Unknown IPC error + /// @retval #PHONE_NUMBER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// @pre phone_number_connect() should be called to open a connection to the phonenumber-utils service. + /// @post phone_number_disconnect() should be called to close a connection to the phonenumber-utils service. + /// @see phone_number_add_blocking_rule() + int phone_number_remove_blocking_rule( + ffi.Pointer rule, + ) { + return _phone_number_remove_blocking_rule( + rule, + ); + } + + late final _phone_number_remove_blocking_rule_ptr = + _lookup>( + 'phone_number_remove_blocking_rule'); + late final _dart_phone_number_remove_blocking_rule + _phone_number_remove_blocking_rule = + _phone_number_remove_blocking_rule_ptr + .asFunction<_dart_phone_number_remove_blocking_rule>(); + + /// @brief Retrieves blocking rules as an array. + /// + /// @since_tizen 4.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/blocknumber.read + /// + /// @remarks You must release each blocking rule in the array with phone_number_blocking_rule_destroy() and @a rules using free(). + /// + /// @param[in] offset The index from which to get results + /// @param[in] limit The number to limit results (value 0 is used for all blocking rules) + /// @param[out] rules The array of blocking rule handles + /// @param[out] length The number of blocking rule handles in the array + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PHONE_NUMBER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PHONE_NUMBER_ERROR_DB_FAILED Database operation failure + /// @retval #PHONE_NUMBER_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_IPC Unknown IPC error + /// @retval #PHONE_NUMBER_ERROR_NO_DATA Data does not exist + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// @pre phone_number_connect() should be called to open a connection to the phonenumber-utils service. + /// @post phone_number_disconnect() should be called to close a connection to the phonenumber-utils service. + int phone_number_get_blocking_rules( + int offset, + int limit, + ffi.Pointer>> rules, + ffi.Pointer length, + ) { + return _phone_number_get_blocking_rules( + offset, + limit, + rules, + length, + ); + } + + late final _phone_number_get_blocking_rules_ptr = + _lookup>( + 'phone_number_get_blocking_rules'); + late final _dart_phone_number_get_blocking_rules + _phone_number_get_blocking_rules = _phone_number_get_blocking_rules_ptr + .asFunction<_dart_phone_number_get_blocking_rules>(); + + /// @brief Retrieves blocking rules that block a specific number. + /// + /// @since_tizen 4.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/blocknumber.read + /// + /// @remarks You must release each blocking rule in the array with phone_number_blocking_rule_destroy() and @a rules using free(). + /// + /// @param[in] number The number to get blocking rules related with + /// @param[out] rules The array of blocking rule handles + /// @param[out] length The number of blocking rule handles in the array + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #PHONE_NUMBER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PHONE_NUMBER_ERROR_DB_FAILED Database operation failure + /// @retval #PHONE_NUMBER_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_IPC Unknown IPC error + /// @retval #PHONE_NUMBER_ERROR_NO_DATA Data does not exist + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// @pre phone_number_connect() should be called to open a connection to the phonenumber-utils service. + /// @post phone_number_disconnect() should be called to close a connection to the phonenumber-utils service. + int phone_number_get_blocking_rules_related( + ffi.Pointer number, + ffi.Pointer>> rules, + ffi.Pointer length, + ) { + return _phone_number_get_blocking_rules_related( + number, + rules, + length, + ); + } + + late final _phone_number_get_blocking_rules_related_ptr = + _lookup>( + 'phone_number_get_blocking_rules_related'); + late final _dart_phone_number_get_blocking_rules_related + _phone_number_get_blocking_rules_related = + _phone_number_get_blocking_rules_related_ptr + .asFunction<_dart_phone_number_get_blocking_rules_related>(); + + /// @brief Checks if a specific number is blocked or not. + /// + /// @since_tizen 4.0 + /// @privlevel partner + /// @privilege %http://tizen.org/privilege/blocknumber.read + /// + /// @param[in] number The number to check blocking + /// @param[out] is_blocked The blocking result + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #PHONE_NUMBER_ERROR_NONE Successful + /// @retval #PHONE_NUMBER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #PHONE_NUMBER_ERROR_DB_FAILED Database operation failure + /// @retval #PHONE_NUMBER_ERROR_PERMISSION_DENIED Permission denied. This application does not have the privilege to call this method. + /// @retval #PHONE_NUMBER_ERROR_NOT_SUPPORTED Not supported + /// @retval #PHONE_NUMBER_ERROR_IPC Unknown IPC error + /// @retval #PHONE_NUMBER_ERROR_SYSTEM Internal error + /// @pre phone_number_connect() should be called to open a connection to the phonenumber-utils service. + /// @post phone_number_disconnect() should be called to close a connection to the phonenumber-utils service. + int phone_number_check_blocking( + ffi.Pointer number, + ffi.Pointer is_blocked, + ) { + return _phone_number_check_blocking( + number, + is_blocked, + ); + } + + late final _phone_number_check_blocking_ptr = + _lookup>( + 'phone_number_check_blocking'); + late final _dart_phone_number_check_blocking _phone_number_check_blocking = + _phone_number_check_blocking_ptr + .asFunction<_dart_phone_number_check_blocking>(); + + /// @brief Gets the battery charge percentage. + /// @details It returns an integer value from @c 0 to @c 100 that indicates remaining battery charge + /// as a percentage of the maximum level. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks In order to be notified when the battery state changes, use system_info_set_changed_cb(). + /// @param[out] percent The remaining battery charge percentage (@c 0 ~ @c 100) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + int device_battery_get_percent( + ffi.Pointer percent, + ) { + return _device_battery_get_percent( + percent, + ); + } + + late final _device_battery_get_percent_ptr = + _lookup>( + 'device_battery_get_percent'); + late final _dart_device_battery_get_percent _device_battery_get_percent = + _device_battery_get_percent_ptr + .asFunction<_dart_device_battery_get_percent>(); + + /// @brief Gets the charging state. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] charging The battery charging state + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @see device_add_callback + /// @see device_remove_callback + /// @see #DEVICE_CALLBACK_BATTERY_CHARGING + int device_battery_is_charging( + ffi.Pointer charging, + ) { + return _device_battery_is_charging( + charging, + ); + } + + late final _device_battery_is_charging_ptr = + _lookup>( + 'device_battery_is_charging'); + late final _dart_device_battery_is_charging _device_battery_is_charging = + _device_battery_is_charging_ptr + .asFunction<_dart_device_battery_is_charging>(); + + /// @brief Gets the battery level status. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] status The battery level status + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @see device_battery_level_e + /// @see device_add_callback + /// @see device_remove_callback + /// @see #DEVICE_CALLBACK_BATTERY_LEVEL + int device_battery_get_level_status( + ffi.Pointer status, + ) { + return _device_battery_get_level_status( + status, + ); + } + + late final _device_battery_get_level_status_ptr = + _lookup>( + 'device_battery_get_level_status'); + late final _dart_device_battery_get_level_status + _device_battery_get_level_status = _device_battery_get_level_status_ptr + .asFunction<_dart_device_battery_get_level_status>(); + + /// @brief Gets the battery health information. + /// @since_tizen 3.0 + /// @param[out] health The battery health information + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + int device_battery_get_health( + ffi.Pointer health, + ) { + return _device_battery_get_health( + health, + ); + } + + late final _device_battery_get_health_ptr = + _lookup>( + 'device_battery_get_health'); + late final _dart_device_battery_get_health _device_battery_get_health = + _device_battery_get_health_ptr + .asFunction<_dart_device_battery_get_health>(); + + /// @brief Gets the battery power source information. + /// @since_tizen 3.0 + /// @param[out] source The battery power source information + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + int device_battery_get_power_source( + ffi.Pointer source, + ) { + return _device_battery_get_power_source( + source, + ); + } + + late final _device_battery_get_power_source_ptr = + _lookup>( + 'device_battery_get_power_source'); + late final _dart_device_battery_get_power_source + _device_battery_get_power_source = _device_battery_get_power_source_ptr + .asFunction<_dart_device_battery_get_power_source>(); + + /// @brief Gets the battery properties. + /// @since_tizen 3.0 + /// @param[in] property The property type + /// @param[out] value The battery information for the property given + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + int device_battery_get_property( + int property, + ffi.Pointer value, + ) { + return _device_battery_get_property( + property, + value, + ); + } + + late final _device_battery_get_property_ptr = + _lookup>( + 'device_battery_get_property'); + late final _dart_device_battery_get_property _device_battery_get_property = + _device_battery_get_property_ptr + .asFunction<_dart_device_battery_get_property>(); + + /// @brief Gets the battery status information. + /// @since_tizen 3.0 + /// @param[out] status The battery status information + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + int device_battery_get_status( + ffi.Pointer status, + ) { + return _device_battery_get_status( + status, + ); + } + + late final _device_battery_get_status_ptr = + _lookup>( + 'device_battery_get_status'); + late final _dart_device_battery_get_status _device_battery_get_status = + _device_battery_get_status_ptr + .asFunction<_dart_device_battery_get_status>(); + + /// @brief Adds a callback to the observing device state. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] type The device type to monitor + /// @param[in] callback The callback function to add + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_ALREADY_IN_PROGRESS Operation already + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + int device_add_callback( + int type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _device_add_callback( + type, + callback, + user_data, + ); + } + + late final _device_add_callback_ptr = + _lookup>( + 'device_add_callback'); + late final _dart_device_add_callback _device_add_callback = + _device_add_callback_ptr.asFunction<_dart_device_add_callback>(); + + /// @brief Removes a device callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] type The device type to monitor + /// @param[in] callback The callback function to remove + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + int device_remove_callback( + int type, + ffi.Pointer> callback, + ) { + return _device_remove_callback( + type, + callback, + ); + } + + late final _device_remove_callback_ptr = + _lookup>( + 'device_remove_callback'); + late final _dart_device_remove_callback _device_remove_callback = + _device_remove_callback_ptr.asFunction<_dart_device_remove_callback>(); + + /// @brief Gets the number of display devices. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/display + /// @param[out] device_number The total number of displays + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @see device_display_get_brightness() + /// @see device_display_set_brightness() + /// @see device_display_get_max_brightness() + int device_display_get_numbers( + ffi.Pointer device_number, + ) { + return _device_display_get_numbers( + device_number, + ); + } + + late final _device_display_get_numbers_ptr = + _lookup>( + 'device_display_get_numbers'); + late final _dart_device_display_get_numbers _device_display_get_numbers = + _device_display_get_numbers_ptr + .asFunction<_dart_device_display_get_numbers>(); + + /// @brief Gets the maximum brightness value that can be set. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/display + /// @param[in] display_index The index of the display \n + /// It can be greater than or equal to @c 0 and less than the number of displays returned by device_display_get_numbers(). \n + /// The index zero is always assigned to the main display + /// @param[out] max_brightness The maximum brightness value of the display + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @see device_display_get_numbers() + /// @see device_display_set_brightness() + /// @see device_display_get_brightness() + int device_display_get_max_brightness( + int display_index, + ffi.Pointer max_brightness, + ) { + return _device_display_get_max_brightness( + display_index, + max_brightness, + ); + } + + late final _device_display_get_max_brightness_ptr = + _lookup>( + 'device_display_get_max_brightness'); + late final _dart_device_display_get_max_brightness + _device_display_get_max_brightness = + _device_display_get_max_brightness_ptr + .asFunction<_dart_device_display_get_max_brightness>(); + + /// @brief Gets the display brightness value. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/display + /// @param[in] display_index The index of the display \n + /// It can be greater than or equal to @c 0 and less than the number of displays returned by device_display_get_numbers(). \n + /// The index zero is always assigned to the main display + /// @param[out] brightness The current brightness value of the display + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @see device_display_get_numbers() + /// @see device_display_set_brightness() + /// @see device_display_get_max_brightness() + int device_display_get_brightness( + int display_index, + ffi.Pointer brightness, + ) { + return _device_display_get_brightness( + display_index, + brightness, + ); + } + + late final _device_display_get_brightness_ptr = + _lookup>( + 'device_display_get_brightness'); + late final _dart_device_display_get_brightness + _device_display_get_brightness = _device_display_get_brightness_ptr + .asFunction<_dart_device_display_get_brightness>(); + + /// @brief Sets the display brightness value. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/display + /// @param[in] display_index The index of the display \n + /// It can be greater than or equal to @c 0 and less than the number of displays returned by device_display_get_numbers(). \n + /// The index zero is always assigned to the main display + /// @param[in] brightness The new brightness value to set \n + /// The maximum value can be represented by device_display_get_max_brightness() + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @see device_display_get_numbers() + /// @see device_display_get_max_brightness() + /// @see device_display_get_brightness() + int device_display_set_brightness( + int display_index, + int brightness, + ) { + return _device_display_set_brightness( + display_index, + brightness, + ); + } + + late final _device_display_set_brightness_ptr = + _lookup>( + 'device_display_set_brightness'); + late final _dart_device_display_set_brightness + _device_display_set_brightness = _device_display_set_brightness_ptr + .asFunction<_dart_device_display_set_brightness>(); + + /// @brief Gets the current display state. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[out] state The display state + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @see device_add_callback + /// @see device_remove_callback + /// @see #DEVICE_CALLBACK_DISPLAY_STATE + int device_display_get_state( + ffi.Pointer state, + ) { + return _device_display_get_state( + state, + ); + } + + late final _device_display_get_state_ptr = + _lookup>( + 'device_display_get_state'); + late final _dart_device_display_get_state _device_display_get_state = + _device_display_get_state_ptr + .asFunction<_dart_device_display_get_state>(); + + /// @brief Changes the display state by force. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/display + /// @remarks This API triggers display change process and then updates the status when it completes. While the operation is on-going, the device_display_get_state() function returns previous display state. + /// @param[in] state The display state + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @see device_power_request_lock() + /// @see device_power_release_lock() + /// @see device_add_callback + /// @see device_remove_callback + /// @see #DEVICE_CALLBACK_DISPLAY_STATE + /// + /// @par Example + /// @code + /// ... + /// result = device_display_change_state(DISPLAY_STATE_SCREEN_OFF); + /// if (result < 0) + /// dlog_print(DLOG_ERROR, LOG_TAG, "[ERROR] return value result =%d, \n",result); + /// else + /// dlog_print(DLOG_DEBUG, LOG_TAG, "[SUCCESS] return value result =%d \n",result); + /// ... + /// @endcode + int device_display_change_state( + int state, + ) { + return _device_display_change_state( + state, + ); + } + + late final _device_display_change_state_ptr = + _lookup>( + 'device_display_change_state'); + late final _dart_device_display_change_state _device_display_change_state = + _device_display_change_state_ptr + .asFunction<_dart_device_display_change_state>(); + + /// @brief Gets the number of vibrators. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/haptic + /// @param[in] device_number The number of vibrators + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @retval #DEVICE_ERROR_NOT_SUPPORTED Not supported device + int device_haptic_get_count( + ffi.Pointer device_number, + ) { + return _device_haptic_get_count( + device_number, + ); + } + + late final _device_haptic_get_count_ptr = + _lookup>( + 'device_haptic_get_count'); + late final _dart_device_haptic_get_count _device_haptic_get_count = + _device_haptic_get_count_ptr.asFunction<_dart_device_haptic_get_count>(); + + /// @brief Opens a haptic-vibration device. + /// @details Internally, it makes a connection to the vibrator. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/haptic + /// @remarks You must close the Haptic API using device_haptic_close(). + /// @param[in] device_index The index of device what you want to vibrate \n + /// The index starts from @c 0 + /// @param[out] device_handle The handle of vibrator + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @retval #DEVICE_ERROR_NOT_SUPPORTED Not supported device + /// @see device_haptic_close() + int device_haptic_open( + int device_index, + ffi.Pointer> device_handle, + ) { + return _device_haptic_open( + device_index, + device_handle, + ); + } + + late final _device_haptic_open_ptr = + _lookup>('device_haptic_open'); + late final _dart_device_haptic_open _device_haptic_open = + _device_haptic_open_ptr.asFunction<_dart_device_haptic_open>(); + + /// @brief Closes a haptic-vibration device. + /// @details Internally, it disconnects the connection to the vibrator. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/haptic + /// @param[in] device_handle The device handle from device_haptic_open() + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @retval #DEVICE_ERROR_NOT_SUPPORTED Not supported device + /// @see device_haptic_open() + int device_haptic_close( + ffi.Pointer device_handle, + ) { + return _device_haptic_close( + device_handle, + ); + } + + late final _device_haptic_close_ptr = + _lookup>( + 'device_haptic_close'); + late final _dart_device_haptic_close _device_haptic_close = + _device_haptic_close_ptr.asFunction<_dart_device_haptic_close>(); + + /// @brief Vibrates during the specified time with a constant intensity. + /// @details This function can be used to start monotonous vibration for the specified time. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/haptic + /// @remarks @a feedback level is reserved for auto changing to save variable in the settings. + /// @remarks @a effect_handle effect_handle value can be @c 0(zero). + /// @param[in] device_handle The device handle from device_haptic_open() + /// @param[in] duration The play duration in milliseconds + /// @param[in] feedback The amount of the intensity variation (@c 0 ~ @c 100) + /// @param[out] effect_handle The pointer to the variable that will receive a handle to the playing effect + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @retval #DEVICE_ERROR_NOT_SUPPORTED Not supported device + /// @see device_haptic_stop() + int device_haptic_vibrate( + ffi.Pointer device_handle, + int duration, + int feedback, + ffi.Pointer> effect_handle, + ) { + return _device_haptic_vibrate( + device_handle, + duration, + feedback, + effect_handle, + ); + } + + late final _device_haptic_vibrate_ptr = + _lookup>( + 'device_haptic_vibrate'); + late final _dart_device_haptic_vibrate _device_haptic_vibrate = + _device_haptic_vibrate_ptr.asFunction<_dart_device_haptic_vibrate>(); + + /// @brief Stops all vibration effects which are being played. + /// @details This function can be used to stop all effects started by device_haptic_vibrate(). + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/haptic + /// @param[in] device_handle The device handle from device_haptic_open() + /// @param[in] effect_handle The effect handle from device_haptic_vibrate() + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @retval #DEVICE_ERROR_NOT_SUPPORTED Not supported device + /// @see device_haptic_vibrate() + int device_haptic_stop( + ffi.Pointer device_handle, + ffi.Pointer effect_handle, + ) { + return _device_haptic_stop( + device_handle, + effect_handle, + ); + } + + late final _device_haptic_stop_ptr = + _lookup>('device_haptic_stop'); + late final _dart_device_haptic_stop _device_haptic_stop = + _device_haptic_stop_ptr.asFunction<_dart_device_haptic_stop>(); + + /// @brief Gets the max brightness value of a LED that is located next to the camera. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/led + /// @remarks This API is related to the following feature: %http://tizen.org/feature/camera.back.flash + /// @param[out] max_brightness The max brightness value of the LED + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @retval #DEVICE_ERROR_NOT_SUPPORTED Not supported device + int device_flash_get_max_brightness( + ffi.Pointer max_brightness, + ) { + return _device_flash_get_max_brightness( + max_brightness, + ); + } + + late final _device_flash_get_max_brightness_ptr = + _lookup>( + 'device_flash_get_max_brightness'); + late final _dart_device_flash_get_max_brightness + _device_flash_get_max_brightness = _device_flash_get_max_brightness_ptr + .asFunction<_dart_device_flash_get_max_brightness>(); + + /// @brief Gets the brightness value of a LED that is located next to the camera. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/led + /// @remarks This API is related to the following feature: %http://tizen.org/feature/camera.back.flash + /// @param[out] brightness The brightness value of LED (@c 0 ~ MAX) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @retval #DEVICE_ERROR_NOT_SUPPORTED Not supported device + int device_flash_get_brightness( + ffi.Pointer brightness, + ) { + return _device_flash_get_brightness( + brightness, + ); + } + + late final _device_flash_get_brightness_ptr = + _lookup>( + 'device_flash_get_brightness'); + late final _dart_device_flash_get_brightness _device_flash_get_brightness = + _device_flash_get_brightness_ptr + .asFunction<_dart_device_flash_get_brightness>(); + + /// @brief Sets the brightness value of a LED that is located next to the camera. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/led + /// @remarks Since @if Mobile 2.4 @elseif WEARABLE 3.0 @endif, this API check camera flash status whether camera API preempted flash or not, so it could be failed if flash was preempted by camera API. In this case, API will return #DEVICE_ERROR_RESOURCE_BUSY error. + /// This API is related to the following feature: %http://tizen.org/feature/camera.back.flash + /// @param[in] brightness The brightness value of LED (@c 0 ~ MAX) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @retval #DEVICE_ERROR_NOT_SUPPORTED Not supported device + /// @retval #DEVICE_ERROR_RESOURCE_BUSY Device or resource busy + int device_flash_set_brightness( + int brightness, + ) { + return _device_flash_set_brightness( + brightness, + ); + } + + late final _device_flash_set_brightness_ptr = + _lookup>( + 'device_flash_set_brightness'); + late final _dart_device_flash_set_brightness _device_flash_set_brightness = + _device_flash_set_brightness_ptr + .asFunction<_dart_device_flash_set_brightness>(); + + /// @brief Plays the custom effect of the service LED that is located to the front of a device. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/led + /// @remarks This API is related to the following feature: %http://tizen.org/feature/led + /// @param[in] on Turn on time in milliseconds + /// @param[in] off Turn off time in milliseconds + /// @param[in] color The Color value \n + /// The first byte means opaque and the other 3 bytes are RGB values + /// @param[in] flags The combination of enum #led_custom_flags + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @retval #DEVICE_ERROR_NOT_SUPPORTED Not supported device + int device_led_play_custom( + int on_1, + int off, + int color, + int flags, + ) { + return _device_led_play_custom( + on_1, + off, + color, + flags, + ); + } + + late final _device_led_play_custom_ptr = + _lookup>( + 'device_led_play_custom'); + late final _dart_device_led_play_custom _device_led_play_custom = + _device_led_play_custom_ptr.asFunction<_dart_device_led_play_custom>(); + + /// @brief Stops the custom effect of the service LED that is located to the front of a device. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/led + /// @remarks This API is related to the following feature: %http://tizen.org/feature/led + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @retval #DEVICE_ERROR_NOT_SUPPORTED Not supported device + int device_led_stop_custom() { + return _device_led_stop_custom(); + } + + late final _device_led_stop_custom_ptr = + _lookup>( + 'device_led_stop_custom'); + late final _dart_device_led_stop_custom _device_led_stop_custom = + _device_led_stop_custom_ptr.asFunction<_dart_device_led_stop_custom>(); + + /// @brief Locks the given lock state for a specified time. + /// @details After the given @a timeout_ms (in milliseconds), unlock the given lock state automatically. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/display + /// @remarks If the process dies, then every lock will be removed. + /// @param[in] type The power type to request lock + /// @param[in] timeout_ms The positive number in milliseconds or @c 0 for permanent lock \n + /// So you must release the permanent lock of power state with #device_power_release_lock() if @a timeout_ms is zero + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @see device_power_release_lock() + int device_power_request_lock( + int type, + int timeout_ms, + ) { + return _device_power_request_lock( + type, + timeout_ms, + ); + } + + late final _device_power_request_lock_ptr = + _lookup>( + 'device_power_request_lock'); + late final _dart_device_power_request_lock _device_power_request_lock = + _device_power_request_lock_ptr + .asFunction<_dart_device_power_request_lock>(); + + /// @brief Releases the given lock state which was locked before. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/display + /// @param[in] type The power type to release lock + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @see device_power_request_lock() + int device_power_release_lock( + int type, + ) { + return _device_power_release_lock( + type, + ); + } + + late final _device_power_release_lock_ptr = + _lookup>( + 'device_power_release_lock'); + late final _dart_device_power_release_lock _device_power_release_lock = + _device_power_release_lock_ptr + .asFunction<_dart_device_power_release_lock>(); + + /// @deprecated Deprecated Since @if WEARABLE 3.0 @else 2.4 @endif + /// @brief Changes the current power state to the normal/dim state. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/display + /// @remarks This API triggers turn on process and then updates the status when it completes. While the operation is on-going, the device_display_get_state() function returns previous display state. + /// @param[in] dim Set @c true to set the dim state, + /// otherwise set @c false to not set the dim state + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @post The device will be in #DISPLAY_STATE_NORMAL state. + int device_power_wakeup( + bool dim, + ) { + return _device_power_wakeup( + dim ? 1 : 0, + ); + } + + late final _device_power_wakeup_ptr = + _lookup>( + 'device_power_wakeup'); + late final _dart_device_power_wakeup _device_power_wakeup = + _device_power_wakeup_ptr.asFunction<_dart_device_power_wakeup>(); + + /// @platform + /// @brief Reboots the device. + /// @details Will not return if the reboot is successful. \n + /// It operates asynchronously. + /// @since_tizen 2.3.1 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/reboot + /// @param[in] reason Pass to the platform and kernel to request special reboot reason, or null + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + int device_power_reboot( + ffi.Pointer reason, + ) { + return _device_power_reboot( + reason, + ); + } + + late final _device_power_reboot_ptr = + _lookup>( + 'device_power_reboot'); + late final _dart_device_power_reboot _device_power_reboot = + _device_power_reboot_ptr.asFunction<_dart_device_power_reboot>(); + + /// @brief Gets the information whether IR module is available. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/use_ir + /// @param[out] available The information whether IR is available + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @retval #DEVICE_ERROR_NOT_SUPPORTED Not supported device + int device_ir_is_available( + ffi.Pointer available, + ) { + return _device_ir_is_available( + available, + ); + } + + late final _device_ir_is_available_ptr = + _lookup>( + 'device_ir_is_available'); + late final _dart_device_ir_is_available _device_ir_is_available = + _device_ir_is_available_ptr.asFunction<_dart_device_ir_is_available>(); + + /// @brief Transmits IR command. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/use_ir + /// @param[in] carrier_frequency Carrier frequency to transmit IR command (Hertz) + /// @param[in] pattern Integer array of IR command + /// @param[in] size Size of IR command pattern + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #DEVICE_ERROR_NONE Successful + /// @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DEVICE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed + /// @retval #DEVICE_ERROR_NOT_SUPPORTED Not supported device + int device_ir_transmit( + int carrier_frequency, + ffi.Pointer pattern, + int size, + ) { + return _device_ir_transmit( + carrier_frequency, + pattern, + size, + ); + } + + late final _device_ir_transmit_ptr = + _lookup>('device_ir_transmit'); + late final _dart_device_ir_transmit _device_ir_transmit = + _device_ir_transmit_ptr.asFunction<_dart_device_ir_transmit>(); + + /// @brief Sends log with priority and tag. + /// @details for application. + /// @if MOBILE @since_tizen 2.3 @elseif WEARABLE @since_tizen 2.3.1 @endif + /// @param[in] prio priority level of type #log_priority + /// @param[in] tag tag - a null-terminated string + /// @param[in] fmt format string - same as printf + /// @return On success, the function returns the number of bytes written. + /// On error, a negative errno-style error code + /// @retval #DLOG_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DLOG_ERROR_NOT_PERMITTED Operation not permitted + /// @pre none + /// @post none + /// @see dlog_vprint + /// + /// @code + /// #include + /// int main(void) + /// { + /// int integer = 21; + /// char string[] = "test dlog"; + /// + /// dlog_print(DLOG_INFO, "USR_TAG", "test dlog"); + /// dlog_print(DLOG_INFO, "USR_TAG", "%s, %d", string, integer); + /// return 0; + /// } + /// @endcode + int dlog_print( + int prio, + ffi.Pointer tag, + ffi.Pointer fmt, + ) { + return _dlog_print( + prio, + tag, + fmt, + ); + } + + late final _dlog_print_ptr = + _lookup>('dlog_print'); + late final _dart_dlog_print _dlog_print = + _dlog_print_ptr.asFunction<_dart_dlog_print>(); + + /// @brief Sends log with priority, tag, and va_list. + /// @details for application. + /// @if MOBILE @since_tizen 2.3 @elseif WEARABLE @since_tizen 2.3.1 @endif + /// @param[in] prio priority level of type #log_priority + /// @param[in] tag tag - a null-terminated string + /// @param[in] fmt format string - same as printf + /// @param[in] ap va_list + /// @return On success, the function returns the number of bytes written. + /// On error, a negative errno-style error code + /// @retval #DLOG_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #DLOG_ERROR_NOT_PERMITTED Operation not permitted + /// @pre none + /// @post none + /// @see dlog_print + /// + /// @code + /// #include + /// void my_debug_print(char *format, ...) + /// { + /// va_list ap; + /// + /// va_start(ap, format); + /// dlog_vprint(DLOG_INFO, "USR_TAG", format, ap); + /// va_end(ap); + /// } + /// + /// int main(void) + /// { + /// my_debug_print("%s", "test dlog"); + /// my_debug_print("%s, %d", "test dlog", 21); + /// return 0; + /// } + /// @endcode + int dlog_vprint( + int prio, + ffi.Pointer tag, + ffi.Pointer fmt, + ffi.Pointer ap, + ) { + return _dlog_vprint( + prio, + tag, + fmt, + ap, + ); + } + + late final _dlog_vprint_ptr = + _lookup>('dlog_vprint'); + late final _dart_dlog_vprint _dlog_vprint = + _dlog_vprint_ptr.asFunction<_dart_dlog_vprint>(); + + /// @brief Initializes feedback API. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks If this function is not called in advance, other function will return #FEEDBACK_ERROR_NOT_INITIALIZED. + /// And for controlling haptic device, the privilege should be set to, %http://tizen.org/privilege/haptic. + /// If you don't have the haptic privilege, this function initializes only sound. + /// It does not return any error in this case. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FEEDBACK_ERROR_NONE Successful + /// @post feedback_deinitialize() + /// @see feedback_deinitialize() + int feedback_initialize() { + return _feedback_initialize(); + } + + late final _feedback_initialize_ptr = + _lookup>( + 'feedback_initialize'); + late final _dart_feedback_initialize _feedback_initialize = + _feedback_initialize_ptr.asFunction<_dart_feedback_initialize>(); + + /// @brief Deinitializes feedback API. + /// @details This function must be called when feedback functions are no longer needed. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks If you don't want to use feedback anymore, you need to deinitialize with this function. + /// And for controlling haptic device, the privilege should be set to, %http://tizen.org/privilege/haptic. + /// If you don't have the haptic privilege, this function deinitializes only sound. + /// It does not return any error in this case. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FEEDBACK_ERROR_NONE Successful + /// @retval #FEEDBACK_ERROR_NOT_INITIALIZED Not initialized + /// @pre feedback_initialize() + /// @see feedback_initialize() + int feedback_deinitialize() { + return _feedback_deinitialize(); + } + + late final _feedback_deinitialize_ptr = + _lookup>( + 'feedback_deinitialize'); + late final _dart_feedback_deinitialize _feedback_deinitialize = + _feedback_deinitialize_ptr.asFunction<_dart_feedback_deinitialize>(); + + /// @brief Plays various types of reactions that are pre-defined. + /// @details This function can be used to react to pre-defined actions. \n + /// It play various types of system pre-defined media or vibration patterns. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks Currently, there are two types of reactions: sound and vibration. \n + /// Depending on the settings, some types cannot operate. + /// For example, when set to silent mode, the device doesn't produce any sound. + /// If to play one of the devices is successful, this function regards as success. + /// And for controlling haptic device, the privilege should be set to, %http://tizen.org/privilege/haptic. + /// If you don't have the haptic privilege, it only works sound operation. + /// It does not return any error in this case. + /// @param[in] pattern The pre-defined pattern + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FEEDBACK_ERROR_NONE Successful + /// @retval #FEEDBACK_ERROR_OPERATION_FAILED Operation not permitted + /// @retval #FEEDBACK_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #FEEDBACK_ERROR_NOT_SUPPORTED Not supported device + /// @retval #FEEDBACK_ERROR_NOT_INITIALIZED Not initialized + /// @pre feedback_initialize() + int feedback_play( + int pattern, + ) { + return _feedback_play( + pattern, + ); + } + + late final _feedback_play_ptr = + _lookup>('feedback_play'); + late final _dart_feedback_play _feedback_play = + _feedback_play_ptr.asFunction<_dart_feedback_play>(); + + /// @brief Plays specific type of reactions that are pre-defined. + /// @details This function can be used to react to pre-defined actions. \n + /// It play specific type of system pre-defined pattern. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks Currently, there are two types of reactions: sound and vibration. \n + /// Depending on the settings, some types cannot operate. + /// For example, when set to silent mode, the device doesn't produce any sound. + /// And for controlling haptic device, the privilege should be set to, %http://tizen.org/privilege/haptic. + /// If you don't have the haptic privilege, it returns FEEDBACK_ERROR_PERMISSION_DENIED error. + /// @param[in] type The pattern type + /// @param[in] pattern The pre-defined pattern + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FEEDBACK_ERROR_NONE Successful + /// @retval #FEEDBACK_ERROR_OPERATION_FAILED Operation not permitted + /// @retval #FEEDBACK_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #FEEDBACK_ERROR_NOT_SUPPORTED Not supported device + /// @retval #FEEDBACK_ERROR_PERMISSION_DENIED Permission denied + /// @retval #FEEDBACK_ERROR_NOT_INITIALIZED Not initialized + /// @pre feedback_initialize() + int feedback_play_type( + int type, + int pattern, + ) { + return _feedback_play_type( + type, + pattern, + ); + } + + late final _feedback_play_type_ptr = + _lookup>('feedback_play_type'); + late final _dart_feedback_play_type _feedback_play_type = + _feedback_play_type_ptr.asFunction<_dart_feedback_play_type>(); + + /// @brief Stops various types of reactions. + /// @details This function can be used to stop reaction to pre-defined actions. \n + /// It stops system pre-defined vibration patterns. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks This function does not support to stop media sound actions. \n + /// In this case, it will return FEEDBACK_ERROR_NOT_SUPPORTED error. + /// And for controlling haptic device, the privilege should be set to, %http://tizen.org/privilege/haptic. + /// If you don't have the haptic privilege, it only works sound operation. + /// It does not return any error in this case. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FEEDBACK_ERROR_NONE Successful + /// @retval #FEEDBACK_ERROR_OPERATION_FAILED Operation not permitted + /// @retval #FEEDBACK_ERROR_NOT_SUPPORTED Not supported device + /// @retval #FEEDBACK_ERROR_PERMISSION_DENIED Permission denied + /// @retval #FEEDBACK_ERROR_NOT_INITIALIZED Not initialized + /// @pre feedback_initialize() + int feedback_stop() { + return _feedback_stop(); + } + + late final _feedback_stop_ptr = + _lookup>('feedback_stop'); + late final _dart_feedback_stop _feedback_stop = + _feedback_stop_ptr.asFunction<_dart_feedback_stop>(); + + /// @brief Checks if the pattern is supported. + /// @details This function can be used to check if a specific pattern is supported. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] type The pattern type + /// @param[in] pattern The pre-defined pattern + /// @param[out] status True means the pattern is supported, + /// otherwise not supported + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #FEEDBACK_ERROR_NONE Successful + /// @retval #FEEDBACK_ERROR_OPERATION_FAILED Operation not permitted + /// @retval #FEEDBACK_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #FEEDBACK_ERROR_NOT_SUPPORTED Not supported device + /// @retval #FEEDBACK_ERROR_NOT_INITIALIZED Not initialized + /// @pre feedback_initialize() + int feedback_is_supported_pattern( + int type, + int pattern, + ffi.Pointer status, + ) { + return _feedback_is_supported_pattern( + type, + pattern, + status, + ); + } + + late final _feedback_is_supported_pattern_ptr = + _lookup>( + 'feedback_is_supported_pattern'); + late final _dart_feedback_is_supported_pattern + _feedback_is_supported_pattern = _feedback_is_supported_pattern_ptr + .asFunction<_dart_feedback_is_supported_pattern>(); + + /// @brief Registers a change event callback for all media keys. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_KEY_ERROR_NONE Successful + /// @retval #MEDIA_KEY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_KEY_ERROR_OPERATION_FAILED Reserve key failed + /// @see media_key_release() + int media_key_reserve( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _media_key_reserve( + callback, + user_data, + ); + } + + late final _media_key_reserve_ptr = + _lookup>('media_key_reserve'); + late final _dart_media_key_reserve _media_key_reserve = + _media_key_reserve_ptr.asFunction<_dart_media_key_reserve>(); + + /// @brief Unregisters the change event callback function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #MEDIA_KEY_ERROR_NONE Successful + /// @retval #MEDIA_KEY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #MEDIA_KEY_ERROR_OPERATION_FAILED Release key failed + /// @see media_key_reserve() + int media_key_release() { + return _media_key_release(); + } + + late final _media_key_release_ptr = + _lookup>('media_key_release'); + late final _dart_media_key_release _media_key_release = + _media_key_release_ptr.asFunction<_dart_media_key_release>(); + + /// @brief Gets the integer value of the runtime information. + /// @details This function gets current state of the given key which represents specific runtime information. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[in] key The runtime information status key from which data should be read + /// @param[out] value The current value of the given key + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_IO_ERROR An input/output error occurred when read value from system + /// @retval #RUNTIME_INFO_ERROR_PERMISSION_DENIED No permission to use the api + /// @retval #RUNTIME_INFO_ERROR_NOT_SUPPORTED Not supported parameter + int runtime_info_get_value_int( + int key, + ffi.Pointer value, + ) { + return _runtime_info_get_value_int( + key, + value, + ); + } + + late final _runtime_info_get_value_int_ptr = + _lookup>( + 'runtime_info_get_value_int'); + late final _dart_runtime_info_get_value_int _runtime_info_get_value_int = + _runtime_info_get_value_int_ptr + .asFunction<_dart_runtime_info_get_value_int>(); + + /// @brief Gets the boolean value from the runtime information. + /// @details This function gets current state of the given key which represents specific runtime information. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[in] key The runtime information key from which data should be read + /// @param[out] value The current value of the given key + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_IO_ERROR An input/output error occurred when read value from system + /// @retval #RUNTIME_INFO_ERROR_PERMISSION_DENIED No permission to use the api + /// @retval #RUNTIME_INFO_ERROR_NOT_SUPPORTED Not supported parameter + int runtime_info_get_value_bool( + int key, + ffi.Pointer value, + ) { + return _runtime_info_get_value_bool( + key, + value, + ); + } + + late final _runtime_info_get_value_bool_ptr = + _lookup>( + 'runtime_info_get_value_bool'); + late final _dart_runtime_info_get_value_bool _runtime_info_get_value_bool = + _runtime_info_get_value_bool_ptr + .asFunction<_dart_runtime_info_get_value_bool>(); + + /// @brief Gets the double value from the runtime information. + /// @details This function gets current state of the given key which represents specific runtime information. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[in] key The runtime information key from which data should be read + /// @param[out] value The current value of the given key + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_IO_ERROR An input/output error occurred when read value from system + /// @retval #RUNTIME_INFO_ERROR_PERMISSION_DENIED No permission to use the api + /// @retval #RUNTIME_INFO_ERROR_NOT_SUPPORTED Not supported parameter + int runtime_info_get_value_double( + int key, + ffi.Pointer value, + ) { + return _runtime_info_get_value_double( + key, + value, + ); + } + + late final _runtime_info_get_value_double_ptr = + _lookup>( + 'runtime_info_get_value_double'); + late final _dart_runtime_info_get_value_double + _runtime_info_get_value_double = _runtime_info_get_value_double_ptr + .asFunction<_dart_runtime_info_get_value_double>(); + + /// @brief Gets the string value for specified runtime information. + /// @details This function gets current state of the given key which represents specific runtime information. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @remarks You must release @a value using free(). + /// + /// @param[in] key The runtime information key from which data should be read + /// @param[out] value The current value of the given key + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_IO_ERROR An input/output error occurred when read value from system + /// @retval #RUNTIME_INFO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #RUNTIME_INFO_ERROR_PERMISSION_DENIED No permission to use the api + /// @retval #RUNTIME_INFO_ERROR_NOT_SUPPORTED Not supported parameter + int runtime_info_get_value_string( + int key, + ffi.Pointer> value, + ) { + return _runtime_info_get_value_string( + key, + value, + ); + } + + late final _runtime_info_get_value_string_ptr = + _lookup>( + 'runtime_info_get_value_string'); + late final _dart_runtime_info_get_value_string + _runtime_info_get_value_string = _runtime_info_get_value_string_ptr + .asFunction<_dart_runtime_info_get_value_string>(); + + /// @brief Registers a change event callback for given runtime information key. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[in] key The runtime information type + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_PERMISSION_DENIED No permission to use the api + /// @retval #RUNTIME_INFO_ERROR_NOT_SUPPORTED Not supported parameter + /// + /// @post runtime_info_changed_cb() will be invoked. + /// @see runtime_info_unset_changed_cb() + /// @see runtime_info_changed_cb() + int runtime_info_set_changed_cb( + int key, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _runtime_info_set_changed_cb( + key, + callback, + user_data, + ); + } + + late final _runtime_info_set_changed_cb_ptr = + _lookup>( + 'runtime_info_set_changed_cb'); + late final _dart_runtime_info_set_changed_cb _runtime_info_set_changed_cb = + _runtime_info_set_changed_cb_ptr + .asFunction<_dart_runtime_info_set_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif + /// + /// @param[in] key The runtime information type + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see runtime_info_set_changed_cb() + int runtime_info_unset_changed_cb( + int key, + ) { + return _runtime_info_unset_changed_cb( + key, + ); + } + + late final _runtime_info_unset_changed_cb_ptr = + _lookup>( + 'runtime_info_unset_changed_cb'); + late final _dart_runtime_info_unset_changed_cb + _runtime_info_unset_changed_cb = _runtime_info_unset_changed_cb_ptr + .asFunction<_dart_runtime_info_unset_changed_cb>(); + + /// @brief Gets system memory information. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// + /// @param[out] info The system memory information structure + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_IO_ERROR An Input/Output error occurred while reading from system + /// + /// @see runtime_info_get_process_memory_info() + int runtime_info_get_system_memory_info( + ffi.Pointer info, + ) { + return _runtime_info_get_system_memory_info( + info, + ); + } + + late final _runtime_info_get_system_memory_info_ptr = + _lookup>( + 'runtime_info_get_system_memory_info'); + late final _dart_runtime_info_get_system_memory_info + _runtime_info_get_system_memory_info = + _runtime_info_get_system_memory_info_ptr + .asFunction<_dart_runtime_info_get_system_memory_info>(); + + /// @brief Gets memory information per process. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/systemmonitor + /// @remarks You must release @a s value using free(). \n + /// The size of @a s is the same with @a size. + /// + /// @param[in] pid The process unique id array + /// @param[in] size The size of pid array + /// @param[out] info The memory information structure array of the processes + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_OUT_OF_MEMORY Not able to allocate memory (for output param/other operations) + /// @retval #RUNTIME_INFO_ERROR_REMOTE_IO Call to resource daemon failed (dbus errors/resource daemon errors) + /// @retval #RUNTIME_INFO_ERROR_IO_ERROR An I/O error during dbus message operations + /// @retval #RUNTIME_INFO_ERROR_PERMISSION_DENIED Process not authorized to request process usage info + /// + /// @see runtime_info_get_system_memory_info() + int runtime_info_get_process_memory_info( + ffi.Pointer pid, + int size, + ffi.Pointer> info, + ) { + return _runtime_info_get_process_memory_info( + pid, + size, + info, + ); + } + + late final _runtime_info_get_process_memory_info_ptr = + _lookup>( + 'runtime_info_get_process_memory_info'); + late final _dart_runtime_info_get_process_memory_info + _runtime_info_get_process_memory_info = + _runtime_info_get_process_memory_info_ptr + .asFunction<_dart_runtime_info_get_process_memory_info>(); + + /// @brief Gets CPU information. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// + /// @param[out] usage The CPU usage structure + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_IO_ERROR An input/output error occurred while reading from system + /// + /// @see runtime_info_get_process_cpu_usage() + int runtime_info_get_cpu_usage( + ffi.Pointer usage, + ) { + return _runtime_info_get_cpu_usage( + usage, + ); + } + + late final _runtime_info_get_cpu_usage_ptr = + _lookup>( + 'runtime_info_get_cpu_usage'); + late final _dart_runtime_info_get_cpu_usage _runtime_info_get_cpu_usage = + _runtime_info_get_cpu_usage_ptr + .asFunction<_dart_runtime_info_get_cpu_usage>(); + + /// @brief Gets CPU usage per process. + /// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/systemmonitor + /// @remarks You must release @a s value using free(). \n + /// The size of @a s is the same with @a size. + /// + /// @param[in] pid The process unique id array + /// @param[in] size The size of pid array + /// @param[out] usage The CPU usage structure array of the processes + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_OUT_OF_MEMORY Not able to allocate memory (for output param/other operations) + /// @retval #RUNTIME_INFO_ERROR_REMOTE_IO Call to resource daemon failed (dbus errors/resource daemon errors) + /// @retval #RUNTIME_INFO_ERROR_IO_ERROR An I/O error occurred (during dbus message operations/other IO operations) + /// @retval #RUNTIME_INFO_ERROR_PERMISSION_DENIED Process not authorized to request process usage info + /// + /// @see runtime_info_get_cpu_usage() + int runtime_info_get_process_cpu_usage( + ffi.Pointer pid, + int size, + ffi.Pointer> usage, + ) { + return _runtime_info_get_process_cpu_usage( + pid, + size, + usage, + ); + } + + late final _runtime_info_get_process_cpu_usage_ptr = + _lookup>( + 'runtime_info_get_process_cpu_usage'); + late final _dart_runtime_info_get_process_cpu_usage + _runtime_info_get_process_cpu_usage = + _runtime_info_get_process_cpu_usage_ptr + .asFunction<_dart_runtime_info_get_process_cpu_usage>(); + + /// @brief Gets the number of processors. + /// @since_tizen 3.0 + /// + /// @param[out] num_core The number of whole processors + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_IO_ERROR An I/O error occurred (during file open operation) + int runtime_info_get_processor_count( + ffi.Pointer num_core, + ) { + return _runtime_info_get_processor_count( + num_core, + ); + } + + late final _runtime_info_get_processor_count_ptr = + _lookup>( + 'runtime_info_get_processor_count'); + late final _dart_runtime_info_get_processor_count + _runtime_info_get_processor_count = _runtime_info_get_processor_count_ptr + .asFunction<_dart_runtime_info_get_processor_count>(); + + /// @brief Gets the current frequency of processor. + /// @since_tizen 3.0 + /// + /// @param[in] core_idx The index (from 0) of CPU core that you want to know the frequency + /// @param[out] cpu_freq The current frequency(MHz) of processor + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_IO_ERROR An I/O error occurred (during file open operation) + /// @retval #RUNTIME_INFO_ERROR_NO_DATA No data available (Since 3.0) + int runtime_info_get_processor_current_frequency( + int core_idx, + ffi.Pointer cpu_freq, + ) { + return _runtime_info_get_processor_current_frequency( + core_idx, + cpu_freq, + ); + } + + late final _runtime_info_get_processor_current_frequency_ptr = _lookup< + ffi.NativeFunction<_c_runtime_info_get_processor_current_frequency>>( + 'runtime_info_get_processor_current_frequency'); + late final _dart_runtime_info_get_processor_current_frequency + _runtime_info_get_processor_current_frequency = + _runtime_info_get_processor_current_frequency_ptr + .asFunction<_dart_runtime_info_get_processor_current_frequency>(); + + /// @brief Gets the max frequency of processor. + /// @since_tizen 3.0 + /// + /// @param[in] core_idx The index (from 0) of CPU core that you want to know the frequency + /// @param[out] cpu_freq The max frequency(MHz) of processor + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_IO_ERROR An I/O error occurred (during file open operation) + /// @retval #RUNTIME_INFO_ERROR_NO_DATA No data available (Since 3.0) + int runtime_info_get_processor_max_frequency( + int core_idx, + ffi.Pointer cpu_freq, + ) { + return _runtime_info_get_processor_max_frequency( + core_idx, + cpu_freq, + ); + } + + late final _runtime_info_get_processor_max_frequency_ptr = + _lookup>( + 'runtime_info_get_processor_max_frequency'); + late final _dart_runtime_info_get_processor_max_frequency + _runtime_info_get_processor_max_frequency = + _runtime_info_get_processor_max_frequency_ptr + .asFunction<_dart_runtime_info_get_processor_max_frequency>(); + + /// @brief Gets the physical memory size. + /// @since_tizen 4.0 + /// + /// @param[out] size Physical memory size (KiB) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_IO_ERROR An I/O error occurred (during file open operation) + int runtime_info_get_physical_memory_size( + ffi.Pointer size, + ) { + return _runtime_info_get_physical_memory_size( + size, + ); + } + + late final _runtime_info_get_physical_memory_size_ptr = + _lookup>( + 'runtime_info_get_physical_memory_size'); + late final _dart_runtime_info_get_physical_memory_size + _runtime_info_get_physical_memory_size = + _runtime_info_get_physical_memory_size_ptr + .asFunction<_dart_runtime_info_get_physical_memory_size>(); + + /// @brief Frees an app usage handle. + /// @since_tizen 4.0 + /// + /// @param[in] handle App usage handle to free + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + int runtime_info_app_usage_destroy( + ffi.Pointer handle, + ) { + return _runtime_info_app_usage_destroy( + handle, + ); + } + + late final _runtime_info_app_usage_destroy_ptr = + _lookup>( + 'runtime_info_app_usage_destroy'); + late final _dart_runtime_info_app_usage_destroy + _runtime_info_app_usage_destroy = _runtime_info_app_usage_destroy_ptr + .asFunction<_dart_runtime_info_app_usage_destroy>(); + + /// @brief Gets the app count from an app usage handle. + /// @since_tizen 4.0 + /// + /// @param[in] handle The app usage handle + /// @param[out] count The number of apps on the app list + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see runtime_info_get_all_apps_memory_usage() + /// @see runtime_info_get_all_apps_cpu_rate() + int runtime_info_app_usage_get_count( + ffi.Pointer handle, + ffi.Pointer count, + ) { + return _runtime_info_app_usage_get_count( + handle, + count, + ); + } + + late final _runtime_info_app_usage_get_count_ptr = + _lookup>( + 'runtime_info_app_usage_get_count'); + late final _dart_runtime_info_app_usage_get_count + _runtime_info_app_usage_get_count = _runtime_info_app_usage_get_count_ptr + .asFunction<_dart_runtime_info_app_usage_get_count>(); + + /// @brief Gets the app ID from an app usage handle. + /// @since_tizen 4.0 + /// + /// @remarks You must release @a appid using free(). + /// + /// @param[in] handle The app usage handle + /// @param[in] index The index in the app list; should be between 0 and @a count - 1 (inclusive), \n + /// where @a count is provided by runtime_info_app_usage_get_count() + /// @param[out] appid The app ID + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see runtime_info_get_all_apps_memory_usage() + /// @see runtime_info_get_all_apps_cpu_rate() + int runtime_info_app_usage_get_appid( + ffi.Pointer handle, + int index, + ffi.Pointer> appid, + ) { + return _runtime_info_app_usage_get_appid( + handle, + index, + appid, + ); + } + + late final _runtime_info_app_usage_get_appid_ptr = + _lookup>( + 'runtime_info_app_usage_get_appid'); + late final _dart_runtime_info_app_usage_get_appid + _runtime_info_app_usage_get_appid = _runtime_info_app_usage_get_appid_ptr + .asFunction<_dart_runtime_info_app_usage_get_appid>(); + + /// @brief Gets resource usage from an app usage handle. + /// @since_tizen 4.0 + /// + /// @remarks The meaning of @a usage depends on which function was used to create @a handle. + /// + /// @param[in] handle The app usage handle + /// @param[in] index The index in the app list; should be between 0 and @a count - 1 (inclusive), \n + /// where @a count is provided by runtime_info_app_usage_get_count() + /// @param[out] usage Resource usage + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see runtime_info_get_all_apps_memory_usage() + /// @see runtime_info_get_all_apps_cpu_rate() + int runtime_info_app_usage_get_usage( + ffi.Pointer handle, + int index, + ffi.Pointer usage, + ) { + return _runtime_info_app_usage_get_usage( + handle, + index, + usage, + ); + } + + late final _runtime_info_app_usage_get_usage_ptr = + _lookup>( + 'runtime_info_app_usage_get_usage'); + late final _dart_runtime_info_app_usage_get_usage + _runtime_info_app_usage_get_usage = _runtime_info_app_usage_get_usage_ptr + .asFunction<_dart_runtime_info_app_usage_get_usage>(); + + /// @brief Gets memory usage of all apps. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/systemmonitor + /// @remarks You must release @a usage using runtime_info_app_usage_destroy(). + /// + /// @param[out] usage An array of each app's memory usage (KB) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_OUT_OF_MEMORY Not able to allocate memory (for output param/other operations) + /// @retval #RUNTIME_INFO_ERROR_REMOTE_IO Call to resource daemon failed (dbus errors/resource daemon errors) + /// @retval #RUNTIME_INFO_ERROR_IO_ERROR An I/O error during dbus message operations + /// @retval #RUNTIME_INFO_ERROR_PERMISSION_DENIED Process not authorized to request app usage info + /// @retval #RUNTIME_INFO_ERROR_NO_DATA No app running + /// + /// @code + /// #include + /// + /// void print_memory_usage(void) + /// { + /// int i; + /// int count; + /// app_usage_h mem_usage_handle; + /// char *appid; + /// unsigned int usage; + /// + /// runtime_info_get_all_apps_memory_usage(&mem_usage_handle); + /// runtime_info_app_usage_get_count(mem_usage_handle, &count); + /// + /// for (i = 0; i < count; i++) { + /// runtime_info_app_usage_get_appid(mem_usage_handle, i, &appid); + /// runtime_info_app_usage_get_usage(mem_usage_handle, i, &usage); + /// printf("appid = %s, usage = %u KB\n", appid, usage); + /// free(appid); + /// } + /// + /// runtime_info_app_usage_destroy(mem_usage_handle); + /// + /// } + /// @endcode + int runtime_info_get_all_apps_memory_usage( + ffi.Pointer> usage, + ) { + return _runtime_info_get_all_apps_memory_usage( + usage, + ); + } + + late final _runtime_info_get_all_apps_memory_usage_ptr = + _lookup>( + 'runtime_info_get_all_apps_memory_usage'); + late final _dart_runtime_info_get_all_apps_memory_usage + _runtime_info_get_all_apps_memory_usage = + _runtime_info_get_all_apps_memory_usage_ptr + .asFunction<_dart_runtime_info_get_all_apps_memory_usage>(); + + /// @brief Gets CPU rate of all apps. + /// @since_tizen 4.0 + /// + /// @privlevel public + /// @privilege %http://tizen.org/privilege/systemmonitor + /// @remarks You must release @a rate using runtime_info_app_usage_destroy(). + /// + /// @param[out] rate An array of each app's CPU usage rate (%), the values are rounded down. + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #RUNTIME_INFO_ERROR_NONE Successful + /// @retval #RUNTIME_INFO_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #RUNTIME_INFO_ERROR_OUT_OF_MEMORY Not able to allocate memory (for output param/other operations) + /// @retval #RUNTIME_INFO_ERROR_REMOTE_IO Call to resource daemon failed (dbus errors/resource daemon errors) + /// @retval #RUNTIME_INFO_ERROR_IO_ERROR An I/O error during dbus message operations + /// @retval #RUNTIME_INFO_ERROR_PERMISSION_DENIED Process not authorized to request app usage info + /// @retval #RUNTIME_INFO_ERROR_NO_DATA No app running + /// + /// @code + /// #include + /// + /// void print_cpu_usage(void) + /// { + /// int i; + /// int count; + /// app_usage_h cpu_rate_handle; + /// char *appid; + /// unsigned int rate; + /// + /// runtime_info_get_all_apps_cpu_rate(&cpu_rate_handle); + /// runtime_info_app_usage_get_count(cpu_rate_handle, &count); + /// + /// for (i = 0; i < count; i++) { + /// runtime_info_app_usage_get_appid(cpu_rate_handle, i, &appid); + /// runtime_info_app_usage_get_usage(cpu_rate_handle, i, &rate); + /// printf("appid = %s, rate = %u %%\n", appid, rate); + /// free(appid); + /// } + /// + /// runtime_info_app_usage_destroy(cpu_rate_handle); + /// + /// } + /// @endcode + int runtime_info_get_all_apps_cpu_rate( + ffi.Pointer> rate, + ) { + return _runtime_info_get_all_apps_cpu_rate( + rate, + ); + } + + late final _runtime_info_get_all_apps_cpu_rate_ptr = + _lookup>( + 'runtime_info_get_all_apps_cpu_rate'); + late final _dart_runtime_info_get_all_apps_cpu_rate + _runtime_info_get_all_apps_cpu_rate = + _runtime_info_get_all_apps_cpu_rate_ptr + .asFunction<_dart_runtime_info_get_all_apps_cpu_rate>(); + + /// @brief Checks whether a given sensor type is supported in the current device. + /// @details If the given sensor type is not supported, sensor_get_default_sensor() will return an error. + /// It is thus recommended to check the availability of the sensor before actually acquiring #sensor_h. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] type A sensor type to check + /// @param[out] supported If supported, @c true; Otherwise @c false + /// + /// @return #SENSOR_ERROR_NONE on success; Otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see sensor_is_supported_by_uri() + int sensor_is_supported( + int type, + ffi.Pointer supported, + ) { + return _sensor_is_supported( + type, + supported, + ); + } + + late final _sensor_is_supported_ptr = + _lookup>( + 'sensor_is_supported'); + late final _dart_sensor_is_supported _sensor_is_supported = + _sensor_is_supported_ptr.asFunction<_dart_sensor_is_supported>(); + + /// @brief Checks whether a sensor corresponding to a given URI is supported in the current device. + /// @details To correctly check the availability of a sensor, a valid URI should be provided. + /// The valid form of URIs is explained in \ref CAPI_SYSTEM_SENSOR_LISTENER_MODULE_URI.\n + /// If a URI with the sensor's name is given, for example, %http://tizen.org/sensor/general/light/front, + /// the availability of the @"front@" light sensor is checked. + /// Otherwise, if a URI without the name, %http://tizen.org/sensor/general/light, is given, + /// this function checks the availability of any light sensor in the device.\n + /// It is recommended to check the availability of the sensors corresponding to the URI + /// before actually acquiring #sensor_h. + /// @since_tizen 4.0 + /// + /// @param[in] uri A sensor or a sensor type URI to check + /// @param[out] supported If supported, @c true, otherwise @c false + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see sensor_is_supported() + int sensor_is_supported_by_uri( + ffi.Pointer uri, + ffi.Pointer supported, + ) { + return _sensor_is_supported_by_uri( + uri, + supported, + ); + } + + late final _sensor_is_supported_by_uri_ptr = + _lookup>( + 'sensor_is_supported_by_uri'); + late final _dart_sensor_is_supported_by_uri _sensor_is_supported_by_uri = + _sensor_is_supported_by_uri_ptr + .asFunction<_dart_sensor_is_supported_by_uri>(); + + /// @brief Checks whether a given sensor is a wake-up sensor or not. + /// @details If a sensor is a wake-up sensor, the sensor is able to wake-up the system + /// to report its sensor data even if the system is in sleep mode. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @param[in] sensor A sensor handle to check + /// @param[out] wakeup If the sensor is a wake-up sensor, @c true; + /// Otherwise @c false + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre The handle @c sensor needs to be initialized using + /// sensor_get_default_sensor() or sensor_get_sensor_list() in advance. + int sensor_is_wake_up( + ffi.Pointer sensor, + ffi.Pointer wakeup, + ) { + return _sensor_is_wake_up( + sensor, + wakeup, + ); + } + + late final _sensor_is_wake_up_ptr = + _lookup>('sensor_is_wake_up'); + late final _dart_sensor_is_wake_up _sensor_is_wake_up = + _sensor_is_wake_up_ptr.asFunction<_dart_sensor_is_wake_up>(); + + /// @brief Gets the handle for the default sensor of a given type. + /// @details This function returns the handle for the sensor of a given type. + /// If the device has more than one sensor of the given type, + /// this function returns the default sensor of the given type, + /// which is designated by the device. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks Some sensor types are privileged. An application should have the privilege + /// http://tizen.org/privilege/healthinfo to get handles for the following sensors: + /// #SENSOR_HRM, #SENSOR_HRM_LED_GREEN, #SENSOR_HRM_LED_IR, #SENSOR_HRM_LED_RED, + /// #SENSOR_HUMAN_PEDOMETER, #SENSOR_HUMAN_SLEEP_MONITOR, #SENSOR_HUMAN_SLEEP_DETECTOR, + /// and #SENSOR_HUMAN_STRESS_MONITOR. + /// + /// @param[in] type A sensor type to get the handle of its default sensor + /// @param[out] sensor The sensor handle of the default sensor + /// + /// @return #SENSOR_ERROR_NONE on success; Otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_NOT_SUPPORTED The sensor type is not supported in the current device + /// @retval #SENSOR_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see sensor_get_default_sensor_by_uri() + /// @see sensor_get_sensor_list() + int sensor_get_default_sensor( + int type, + ffi.Pointer> sensor, + ) { + return _sensor_get_default_sensor( + type, + sensor, + ); + } + + late final _sensor_get_default_sensor_ptr = + _lookup>( + 'sensor_get_default_sensor'); + late final _dart_sensor_get_default_sensor _sensor_get_default_sensor = + _sensor_get_default_sensor_ptr + .asFunction<_dart_sensor_get_default_sensor>(); + + /// @brief Gets the handle for the default sensor of a given sensor URI. + /// @details This function returns the handle for the sensor of a given URI. + /// If the device has more than one sensor of the given URI, + /// this function returns the default sensor of the URI, which is designated by the device.\n + /// See \ref CAPI_SYSTEM_SENSOR_LISTENER_MODULE_URI for more details about the URI format. + /// @since_tizen 4.0 + /// + /// @remarks Some sensor types are privileged. An application should have the privilege + /// http://tizen.org/privilege/healthinfo to get handles for the sensor URIs of @"healthinfo@" category. + /// See \ref CAPI_SYSTEM_SENSOR_LISTENER_MODULE_URI to find the @"healthinfo@" category sensor URIs. + /// + /// @param[in] uri A sensor or a sensor type URI to get the handle of its default sensor + /// @param[out] sensor The default sensor handle + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_NOT_SUPPORTED The URI is not supported in the current device + /// @retval #SENSOR_ERROR_PERMISSION_DENIED Permission denied + /// + /// @see sensor_get_default_sensor() + /// @see sensor_get_sensor_list_by_uri() + int sensor_get_default_sensor_by_uri( + ffi.Pointer uri, + ffi.Pointer> sensor, + ) { + return _sensor_get_default_sensor_by_uri( + uri, + sensor, + ); + } + + late final _sensor_get_default_sensor_by_uri_ptr = + _lookup>( + 'sensor_get_default_sensor_by_uri'); + late final _dart_sensor_get_default_sensor_by_uri + _sensor_get_default_sensor_by_uri = _sensor_get_default_sensor_by_uri_ptr + .asFunction<_dart_sensor_get_default_sensor_by_uri>(); + + /// @brief Gets the handle list of the sensors of a given type. + /// @details A device may have more than one sensors of the given type. + /// In such case, this function can be used to get the handles of all sensors of the type.@n + /// The first element of the @a list denotes the default sensor, + /// which can be retrieved by sensor_get_default_sensor(). + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks Some sensor types are privileged. An application should have the privilege + /// http://tizen.org/privilege/healthinfo to get handles for the following sensors: + /// #SENSOR_HRM, #SENSOR_HRM_LED_GREEN, #SENSOR_HRM_LED_IR, #SENSOR_HRM_LED_RED, + /// #SENSOR_HUMAN_PEDOMETER, #SENSOR_HUMAN_SLEEP_MONITOR, #SENSOR_HUMAN_SLEEP_DETECTOR, + /// and #SENSOR_HUMAN_STRESS_MONITOR.@n + /// Instead of specifying a sensor type, by using #SENSOR_ALL, + /// applications can get the list of handles for all available sensors.@n + /// The @a list must be released using free(), if not being used anymore.@n + /// + /// @param[in] type A sensor type to get the list of sensor handles + /// @param[out] list An array of the sensor handles + /// @param[out] sensor_count The number of handles contained in @a list + /// + /// @return #SENSOR_ERROR_NONE on success; Otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_NOT_SUPPORTED The sensor type is not supported in the current device + /// @retval #SENSOR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #SENSOR_ERROR_OUT_OF_MEMORY Out of memory + int sensor_get_sensor_list( + int type, + ffi.Pointer>> list, + ffi.Pointer sensor_count, + ) { + return _sensor_get_sensor_list( + type, + list, + sensor_count, + ); + } + + late final _sensor_get_sensor_list_ptr = + _lookup>( + 'sensor_get_sensor_list'); + late final _dart_sensor_get_sensor_list _sensor_get_sensor_list = + _sensor_get_sensor_list_ptr.asFunction<_dart_sensor_get_sensor_list>(); + + /// @brief Gets the handle list of the sensors of a given URI. + /// @details A device may have more than one sensor of the given URI. + /// In such case, this function can be used to get the handles of all sensors of the given URI.\n + /// See \ref CAPI_SYSTEM_SENSOR_LISTENER_MODULE_URI for more details about the URI format. + /// @since_tizen 4.0 + /// + /// @remarks Some sensors require one or more privileges. An application should have the corresponding privilege + /// to get handles for such sensors. + /// See sensor_get_default_sensor_by_uri() for more details.@n + /// The @a list must be released using free(), if not being used anymore. + /// + /// @param[in] uri A sensor or a sensor type URI to get the list of sensor handles + /// @param[out] list An array of the sensor handles + /// @param[out] sensor_count The number of handles contained in @a list + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_NOT_SUPPORTED The URI is not supported in the current device + /// @retval #SENSOR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #SENSOR_ERROR_OUT_OF_MEMORY Out of memory + int sensor_get_sensor_list_by_uri( + ffi.Pointer uri, + ffi.Pointer>> list, + ffi.Pointer sensor_count, + ) { + return _sensor_get_sensor_list_by_uri( + uri, + list, + sensor_count, + ); + } + + late final _sensor_get_sensor_list_by_uri_ptr = + _lookup>( + 'sensor_get_sensor_list_by_uri'); + late final _dart_sensor_get_sensor_list_by_uri + _sensor_get_sensor_list_by_uri = _sensor_get_sensor_list_by_uri_ptr + .asFunction<_dart_sensor_get_sensor_list_by_uri>(); + + /// @brief Gets the URI of a sensor. + /// @since_tizen 4.0 + /// + /// @remarks The @a uri must be released using free(), if not being used anymore. + /// + /// @param[in] sensor A sensor handle + /// @param[out] uri The URI of the sensor + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + int sensor_get_uri( + ffi.Pointer sensor, + ffi.Pointer> uri, + ) { + return _sensor_get_uri( + sensor, + uri, + ); + } + + late final _sensor_get_uri_ptr = + _lookup>('sensor_get_uri'); + late final _dart_sensor_get_uri _sensor_get_uri = + _sensor_get_uri_ptr.asFunction<_dart_sensor_get_uri>(); + + /// @brief Gets the name of a sensor. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a name must be released using free(), if not being used anymore. + /// + /// @param[in] sensor A sensor handle + /// @param[out] name The name of the sensor + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + int sensor_get_name( + ffi.Pointer sensor, + ffi.Pointer> name, + ) { + return _sensor_get_name( + sensor, + name, + ); + } + + late final _sensor_get_name_ptr = + _lookup>('sensor_get_name'); + late final _dart_sensor_get_name _sensor_get_name = + _sensor_get_name_ptr.asFunction<_dart_sensor_get_name>(); + + /// @brief Gets the vendor of a sensor. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a vendor must be released using free(), if not being used anymore. + /// + /// @param[in] sensor A sensor handle + /// @param[out] vendor The vendor of the sensor + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + int sensor_get_vendor( + ffi.Pointer sensor, + ffi.Pointer> vendor, + ) { + return _sensor_get_vendor( + sensor, + vendor, + ); + } + + late final _sensor_get_vendor_ptr = + _lookup>('sensor_get_vendor'); + late final _dart_sensor_get_vendor _sensor_get_vendor = + _sensor_get_vendor_ptr.asFunction<_dart_sensor_get_vendor>(); + + /// @brief Gets the type of a sensor, if it belongs to the known types defined in #sensor_type_e. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] sensor A sensor handle + /// @param[out] type The type of the sensor + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_NO_DATA No known sensor type for the given sensor + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_get_type( + ffi.Pointer sensor, + ffi.Pointer type, + ) { + return _sensor_get_type( + sensor, + type, + ); + } + + late final _sensor_get_type_ptr = + _lookup>('sensor_get_type'); + late final _dart_sensor_get_type _sensor_get_type = + _sensor_get_type_ptr.asFunction<_dart_sensor_get_type>(); + + /// @brief Gets the lower bound of the sensor reading of a sensor. + /// @details This function returns the lower bound of the range of possible sensor values, + /// which are generated by the corresponding sensor denoted by a sensor handle.@n + /// If all sensor values are in the same unit, e.g., \f$\mbox{m/s}^2\f$ or degrees, + /// the lower bound of all sensor values is returned. + /// Otherwise, the lower bound of the representative sensor value, e.g., + /// the step count of #SENSOR_HUMAN_PEDOMETER, is returned. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] sensor A sensor handle + /// @param[out] min_range The lower bound + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_get_max_range() + int sensor_get_min_range( + ffi.Pointer sensor, + ffi.Pointer min_range, + ) { + return _sensor_get_min_range( + sensor, + min_range, + ); + } + + late final _sensor_get_min_range_ptr = + _lookup>( + 'sensor_get_min_range'); + late final _dart_sensor_get_min_range _sensor_get_min_range = + _sensor_get_min_range_ptr.asFunction<_dart_sensor_get_min_range>(); + + /// @brief Gets the upper bound of the sensor readings of a sensor. + /// @details This function returns the upper bound of the range of possible sensor values, + /// which are generated by the corresponding sensor denoted by a sensor handle.@n + /// If all sensor values are in the same unit, e.g., \f$\mbox{m/s}^2\f$ or degrees, + /// the upper bound of all sensor values is returned. + /// Otherwise, the upper bound of the representative sensor value, e.g., + /// the step count of #SENSOR_HUMAN_PEDOMETER, is returned. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] sensor A sensor handle + /// @param[out] max_range The upper bound + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_get_min_range() + int sensor_get_max_range( + ffi.Pointer sensor, + ffi.Pointer max_range, + ) { + return _sensor_get_max_range( + sensor, + max_range, + ); + } + + late final _sensor_get_max_range_ptr = + _lookup>( + 'sensor_get_max_range'); + late final _dart_sensor_get_max_range _sensor_get_max_range = + _sensor_get_max_range_ptr.asFunction<_dart_sensor_get_max_range>(); + + /// @brief Gets the resolution of the sensor readings of a sensor. + /// @details This function returns the resolution of the sensor readings. + /// The resolution denotes the smallest difference between sensor readings, + /// each of which is in the range that can be verified by + /// sensor_get_min_range() and sensor_get_max_range(). + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] sensor A sensor handle + /// @param[out] resolution The resolution + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_get_resolution( + ffi.Pointer sensor, + ffi.Pointer resolution, + ) { + return _sensor_get_resolution( + sensor, + resolution, + ); + } + + late final _sensor_get_resolution_ptr = + _lookup>( + 'sensor_get_resolution'); + late final _dart_sensor_get_resolution _sensor_get_resolution = + _sensor_get_resolution_ptr.asFunction<_dart_sensor_get_resolution>(); + + /// @brief Gets the possible shorted update interval of a sensor. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] sensor A sensor handle + /// @param[out] min_interval The shorted interval in milliseconds + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_get_min_interval( + ffi.Pointer sensor, + ffi.Pointer min_interval, + ) { + return _sensor_get_min_interval( + sensor, + min_interval, + ); + } + + late final _sensor_get_min_interval_ptr = + _lookup>( + 'sensor_get_min_interval'); + late final _dart_sensor_get_min_interval _sensor_get_min_interval = + _sensor_get_min_interval_ptr.asFunction<_dart_sensor_get_min_interval>(); + + /// @brief Gets the size of the hardware FIFO of a sensor. + /// @details This function returns the size of the hardware FIFO that may be used by + /// a specific sensor to support batching. + /// However, regarding the underlying hardware configuration, + /// the returned count may not mean the maximum number of sensor data that can be batched. + /// See sensor_get_max_batch_count() for such purpose, finding out the + /// possible maximum number of batched data. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] sensor A sensor handle + /// @param[out] fifo_count The FIFO count + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_get_fifo_count( + ffi.Pointer sensor, + ffi.Pointer fifo_count, + ) { + return _sensor_get_fifo_count( + sensor, + fifo_count, + ); + } + + late final _sensor_get_fifo_count_ptr = + _lookup>( + 'sensor_get_fifo_count'); + late final _dart_sensor_get_fifo_count _sensor_get_fifo_count = + _sensor_get_fifo_count_ptr.asFunction<_dart_sensor_get_fifo_count>(); + + /// @brief Gets the maximum batch count of a sensor. + /// @details This function returns the maximum number of sensor data events + /// that can be possibly delivered when the batched data are flushed. + /// Therefore, this count can be used to check whether the sensor supports + /// batching or not.@n + /// If this returns a positive count, i.e., the sensor supports batching, + /// the count also can be used to guess the possible longest batch latency + /// of the sensor, with respect to the update interval to use. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] sensor A sensor handle + /// @param[out] max_batch_count If the sensor does not support batching, 0; + /// Otherwise a positive integer. + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_listener_set_max_batch_latency() + int sensor_get_max_batch_count( + ffi.Pointer sensor, + ffi.Pointer max_batch_count, + ) { + return _sensor_get_max_batch_count( + sensor, + max_batch_count, + ); + } + + late final _sensor_get_max_batch_count_ptr = + _lookup>( + 'sensor_get_max_batch_count'); + late final _dart_sensor_get_max_batch_count _sensor_get_max_batch_count = + _sensor_get_max_batch_count_ptr + .asFunction<_dart_sensor_get_max_batch_count>(); + + /// @brief Adds a callback function to be invoked when a new sensor is added. + /// @since_tizen 4.0 + /// + /// @param[in] callback A callback function to be added + /// @param[in] user_data A user data to be passed to the callback function + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_remove_sensor_added_cb() + int sensor_add_sensor_added_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _sensor_add_sensor_added_cb( + callback, + user_data, + ); + } + + late final _sensor_add_sensor_added_cb_ptr = + _lookup>( + 'sensor_add_sensor_added_cb'); + late final _dart_sensor_add_sensor_added_cb _sensor_add_sensor_added_cb = + _sensor_add_sensor_added_cb_ptr + .asFunction<_dart_sensor_add_sensor_added_cb>(); + + /// @brief Removes a callback function added using sensor_add_sensor_added_cb(). + /// @since_tizen 4.0 + /// + /// @param[in] callback A callback function to be removed + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_add_sensor_added_cb() + int sensor_remove_sensor_added_cb( + ffi.Pointer> callback, + ) { + return _sensor_remove_sensor_added_cb( + callback, + ); + } + + late final _sensor_remove_sensor_added_cb_ptr = + _lookup>( + 'sensor_remove_sensor_added_cb'); + late final _dart_sensor_remove_sensor_added_cb + _sensor_remove_sensor_added_cb = _sensor_remove_sensor_added_cb_ptr + .asFunction<_dart_sensor_remove_sensor_added_cb>(); + + /// @brief Adds a callback function to be invoked when a sensor is removed. + /// @since_tizen 4.0 + /// + /// @param[in] callback A callback function to be removed + /// @param[in] user_data A user data to be passed to the callback function + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_remove_sensor_removed_cb() + int sensor_add_sensor_removed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _sensor_add_sensor_removed_cb( + callback, + user_data, + ); + } + + late final _sensor_add_sensor_removed_cb_ptr = + _lookup>( + 'sensor_add_sensor_removed_cb'); + late final _dart_sensor_add_sensor_removed_cb _sensor_add_sensor_removed_cb = + _sensor_add_sensor_removed_cb_ptr + .asFunction<_dart_sensor_add_sensor_removed_cb>(); + + /// @brief Removes a callback function added using sensor_add_sensor_removed_cb(). + /// @since_tizen 4.0 + /// + /// @param[in] callback A callback function to be removed + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_add_sensor_removed_cb() + int sensor_remove_sensor_removed_cb( + ffi.Pointer> callback, + ) { + return _sensor_remove_sensor_removed_cb( + callback, + ); + } + + late final _sensor_remove_sensor_removed_cb_ptr = + _lookup>( + 'sensor_remove_sensor_removed_cb'); + late final _dart_sensor_remove_sensor_removed_cb + _sensor_remove_sensor_removed_cb = _sensor_remove_sensor_removed_cb_ptr + .asFunction<_dart_sensor_remove_sensor_removed_cb>(); + + /// @brief Creates a sensor listener. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks The @a listener must be released using sensor_destroy_listener(). + /// + /// @param[in] sensor A sensor handle + /// @param[out] listener A listener handle of @a sensor + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @pre The handle @a sensor needs to be initialized using + /// sensor_get_default_sensor() or sensor_get_sensor_list() in advance. + int sensor_create_listener( + ffi.Pointer sensor, + ffi.Pointer> listener, + ) { + return _sensor_create_listener( + sensor, + listener, + ); + } + + late final _sensor_create_listener_ptr = + _lookup>( + 'sensor_create_listener'); + late final _dart_sensor_create_listener _sensor_create_listener = + _sensor_create_listener_ptr.asFunction<_dart_sensor_create_listener>(); + + /// @brief Releases all the resources allocated for a listener. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks If this function is called while the sensor is still running, + /// that is, sensor_listener_start() was called but sensor_listener_stop() was not, + /// then it is implicitly stopped. + /// + /// @param[in] listener A listener handle + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see sensor_create_listener() + int sensor_destroy_listener( + ffi.Pointer listener, + ) { + return _sensor_destroy_listener( + listener, + ); + } + + late final _sensor_destroy_listener_ptr = + _lookup>( + 'sensor_destroy_listener'); + late final _dart_sensor_destroy_listener _sensor_destroy_listener = + _sensor_destroy_listener_ptr.asFunction<_dart_sensor_destroy_listener>(); + + /// @brief Starts observing the sensor events regarding a given sensor listener. + /// @details If a sensor listener is started, its event callback function starts to be called + /// whenever the corresponding sensor events occur.@n + /// For example, #SENSOR_ACCELEROMETER reports its sensor readings repeatedly, + /// with a specific update interval. + /// Note that, unlike the accelerometer, sensors like #SENSOR_PROXIMITY emit events + /// only if their states change. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] listener A listener handle + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @pre The @a listener needs to be created in advance, by using sensor_create_listener(). + /// Then the callback function needs to be attached to the @a listener, by using + /// sensor_listener_set_event_cb(). + /// @see sensor_listener_stop() + int sensor_listener_start( + ffi.Pointer listener, + ) { + return _sensor_listener_start( + listener, + ); + } + + late final _sensor_listener_start_ptr = + _lookup>( + 'sensor_listener_start'); + late final _dart_sensor_listener_start _sensor_listener_start = + _sensor_listener_start_ptr.asFunction<_dart_sensor_listener_start>(); + + /// @brief Stops observing the sensor events regarding a given sensor listener. + /// @details The listener's event callback function stops being called. + /// But the sensor itself may not be stopped if there are other listeners + /// that are using the same sensor. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] listener A listener handle + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_listener_start() + int sensor_listener_stop( + ffi.Pointer listener, + ) { + return _sensor_listener_stop( + listener, + ); + } + + late final _sensor_listener_stop_ptr = + _lookup>( + 'sensor_listener_stop'); + late final _dart_sensor_listener_stop _sensor_listener_stop = + _sensor_listener_stop_ptr.asFunction<_dart_sensor_listener_stop>(); + + /// @brief Registers the callback function to be invoked when sensor events are delivered via a sensor listener. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] listener A listener handle + /// @param[in] interval_ms A desired update interval between sensor events in milliseconds.@n + /// If 0, it will be automatically set to the default interval of the corresponding sensor.@n + /// See sensor_listener_set_interval() for more details. + /// @param[in] callback A callback function to attach with the @a listener handle + /// @param[in] data A user data to be passed to the callback function + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_listener_unset_event_cb() + int sensor_listener_set_event_cb( + ffi.Pointer listener, + int interval_ms, + ffi.Pointer> callback, + ffi.Pointer data, + ) { + return _sensor_listener_set_event_cb( + listener, + interval_ms, + callback, + data, + ); + } + + late final _sensor_listener_set_event_cb_ptr = + _lookup>( + 'sensor_listener_set_event_cb'); + late final _dart_sensor_listener_set_event_cb _sensor_listener_set_event_cb = + _sensor_listener_set_event_cb_ptr + .asFunction<_dart_sensor_listener_set_event_cb>(); + + /// @brief Unregisters the sensor event callback function attached to a given sensor listener. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] listener A listener handle + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_listener_set_event_cb() + int sensor_listener_unset_event_cb( + ffi.Pointer listener, + ) { + return _sensor_listener_unset_event_cb( + listener, + ); + } + + late final _sensor_listener_unset_event_cb_ptr = + _lookup>( + 'sensor_listener_unset_event_cb'); + late final _dart_sensor_listener_unset_event_cb + _sensor_listener_unset_event_cb = _sensor_listener_unset_event_cb_ptr + .asFunction<_dart_sensor_listener_unset_event_cb>(); + + /// @brief Registers the callback function to be invoked when the accuracy of a sensor changes. + /// @details In addition to sensor_event_cb(), sensor_accuracy_changed_cb() also can be attached + /// to sensor listeners. With this accuracy callback function, applications can be notified + /// the changes of the corresponding sensors separately. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] listener A listener handle + /// @param[in] callback A callback function to attach with the @a listener handle + /// @param[in] data A user data to be passed to the callback function + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @pre The @a listener needs to be started to get the change callbacks. + /// @see sensor_listener_unset_accuracy_cb() + int sensor_listener_set_accuracy_cb( + ffi.Pointer listener, + ffi.Pointer> callback, + ffi.Pointer data, + ) { + return _sensor_listener_set_accuracy_cb( + listener, + callback, + data, + ); + } + + late final _sensor_listener_set_accuracy_cb_ptr = + _lookup>( + 'sensor_listener_set_accuracy_cb'); + late final _dart_sensor_listener_set_accuracy_cb + _sensor_listener_set_accuracy_cb = _sensor_listener_set_accuracy_cb_ptr + .asFunction<_dart_sensor_listener_set_accuracy_cb>(); + + /// @brief Unregisters the sensor accuracy change callback function attached to a given sensor listener. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] listener A listener handle + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_listener_set_accuracy_cb() + int sensor_listener_unset_accuracy_cb( + ffi.Pointer listener, + ) { + return _sensor_listener_unset_accuracy_cb( + listener, + ); + } + + late final _sensor_listener_unset_accuracy_cb_ptr = + _lookup>( + 'sensor_listener_unset_accuracy_cb'); + late final _dart_sensor_listener_unset_accuracy_cb + _sensor_listener_unset_accuracy_cb = + _sensor_listener_unset_accuracy_cb_ptr + .asFunction<_dart_sensor_listener_unset_accuracy_cb>(); + + /// @brief Reads the current sensor data via a given sensor listener. + /// @details This function synchronously reads the sensor reading of the corresponding sensor, if available. + /// Otherwise, if the sensor is not ready to report its values, this function fails and returns + /// #SENSOR_ERROR_OPERATION_FAILED. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remark As a sensor usually works in an event-driven manner, it may not be able to read its data on demand. + /// Then this function tries to return the last known values.@n + /// To be able to read the current values or the last known values, the sensor needs to be + /// enabled in advance. As an application cannot be sure that the sensor is already enabled + /// by other applications, it is recommended to start the sensor explicitly by using sensor_listener_start().@n + /// But note that, even if the sensor is started, on-demand reading can fail always, + /// thus it would be better to use the asynchronous callback approach. + /// + /// @param[in] listener A listener handle + /// @param[out] event The retrieved sensor data + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_listener_read_data( + ffi.Pointer listener, + ffi.Pointer event, + ) { + return _sensor_listener_read_data( + listener, + event, + ); + } + + late final _sensor_listener_read_data_ptr = + _lookup>( + 'sensor_listener_read_data'); + late final _dart_sensor_listener_read_data _sensor_listener_read_data = + _sensor_listener_read_data_ptr + .asFunction<_dart_sensor_listener_read_data>(); + + /// @brief Changes the update interval of a sensor. + /// @details The specified interval is only a suggested interval between sensor measurements. + /// You will get at least one sensor measurement within the interval you specify, + /// but the actual interval between sensor measurements can be affected by other applications and the system. + /// To reduce the system overhead, it is recommended to set the longest interval that you can, + /// because the system usually chooses the shortest interval among all intervals specified. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks Normally, a sensor's default update interval is 100 ms, + /// and you can use the default interval by setting the interval to 0. + /// However, please note that, the default interval varies with the sensor and the device.@n + /// In addition, a sensor has the lower and the upper bound of its update interval, + /// usually 10 and 1000 ms respectively. + /// These lower and upper bounds also can vary with the sensor and the device, + /// any invalid input values exceeding the bounds will be implicitly adjusted into the valid range. + /// + /// @param[in] listener A listener handle + /// @param[in] interval_ms A desired update interval between sensor events in milliseconds. + /// If 0, it will be automatically set to the default interval of the corresponding sensor. + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_get_min_interval() + int sensor_listener_set_interval( + ffi.Pointer listener, + int interval_ms, + ) { + return _sensor_listener_set_interval( + listener, + interval_ms, + ); + } + + late final _sensor_listener_set_interval_ptr = + _lookup>( + 'sensor_listener_set_interval'); + late final _dart_sensor_listener_set_interval _sensor_listener_set_interval = + _sensor_listener_set_interval_ptr + .asFunction<_dart_sensor_listener_set_interval>(); + + /// @brief Sets the desired max batch latency of a sensor. + /// @details Sensors that support batching may allow applications to change their maximum batch latencies. + /// For example, if you set the latency as 10,000 ms, the sensor may store its data + /// up to 10,000 ms, before delivering the data through the HAL.@n + /// In cases of non-batching sensors, this function returns #SENSOR_ERROR_NONE, + /// but nothing is affected by the input latency value. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks Even if you set a batch latency, the sensor may not work as you intended, + /// as one sensor can be used by more than one listeners. + /// In addition, some batch sensors may already have fixed batching latency + /// or batching queue size, which cannot be altered by applications. + /// + /// @param[in] listener A listener handle + /// @param[in] max_batch_latency A desired batch latency in milliseconds + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + int sensor_listener_set_max_batch_latency( + ffi.Pointer listener, + int max_batch_latency, + ) { + return _sensor_listener_set_max_batch_latency( + listener, + max_batch_latency, + ); + } + + late final _sensor_listener_set_max_batch_latency_ptr = + _lookup>( + 'sensor_listener_set_max_batch_latency'); + late final _dart_sensor_listener_set_max_batch_latency + _sensor_listener_set_max_batch_latency = + _sensor_listener_set_max_batch_latency_ptr + .asFunction<_dart_sensor_listener_set_max_batch_latency>(); + + /// @brief Sets an attribute to control the behavior of a sensor listener. + /// @details Applications can change the behavior of a sensor listener, for example, + /// what is the reference coordinate of the sensor values, + /// and when the system is allowed to turn off the sensor implicitly to reduce the power consumption. + /// See #sensor_attribute_e for more details about the available control parameters. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @param[in] listener A listener handle + /// @param[in] attribute An attribute to change + /// @param[in] value An attribute value + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + int sensor_listener_set_attribute_int( + ffi.Pointer listener, + int attribute, + int value, + ) { + return _sensor_listener_set_attribute_int( + listener, + attribute, + value, + ); + } + + late final _sensor_listener_set_attribute_int_ptr = + _lookup>( + 'sensor_listener_set_attribute_int'); + late final _dart_sensor_listener_set_attribute_int + _sensor_listener_set_attribute_int = + _sensor_listener_set_attribute_int_ptr + .asFunction<_dart_sensor_listener_set_attribute_int>(); + + /// @brief Changes the power-saving behavior of a sensor listener. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remark sensor_listener_set_attribute_int() with #SENSOR_ATTRIBUTE_PAUSE_POLICY replaces this function. + /// + /// @param[in] listener A listener handle + /// @param[in] option A sensor option + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_listener_set_option( + ffi.Pointer listener, + int option, + ) { + return _sensor_listener_set_option( + listener, + option, + ); + } + + late final _sensor_listener_set_option_ptr = + _lookup>( + 'sensor_listener_set_option'); + late final _dart_sensor_listener_set_option _sensor_listener_set_option = + _sensor_listener_set_option_ptr + .asFunction<_dart_sensor_listener_set_option>(); + + /// @brief Creates a sensor provider. + /// @details This function creates a sensor provider handle with a given URI. + /// The URI should be in the valid form described in \ref CAPI_SYSTEM_SENSOR_LISTENER_MODULE_URI. + /// In addition, it is not allowed to set the vendor in the URI to @"tizen.org@", + /// as it is pre-assigned to the platform-defined sensors.\n + /// @since_tizen 4.0 + /// + /// @remarks If your application needs to publish health-related sensor data, + /// the URI category should be @"healthinfo@". + /// Then the applications without the privilege http://tizen.org/privilege/healthinfo + /// are not allowed to listen your application's health-related sensor. + /// + /// @remarks The @a provider must be released using sensor_destroy_provider(). + /// + /// @param[in] uri The URI of sensor to be created + /// @param[out] provider The sensor provider handle + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_destroy_provider() + int sensor_create_provider( + ffi.Pointer uri, + ffi.Pointer> provider, + ) { + return _sensor_create_provider( + uri, + provider, + ); + } + + late final _sensor_create_provider_ptr = + _lookup>( + 'sensor_create_provider'); + late final _dart_sensor_create_provider _sensor_create_provider = + _sensor_create_provider_ptr.asFunction<_dart_sensor_create_provider>(); + + /// @brief Registers the sensor provider. + /// @details A sensor provider is created via sensor_create_provider(), + /// and the three callback functions sensor_provider_start_cb(), sensor_provider_stop_cb(), + /// and sensor_provider_set_interval_changed_cb() should be set in advance. + /// @since_tizen 4.0 + /// + /// @param[in] provider The sensor provider handle + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_remove_provider() + int sensor_add_provider( + ffi.Pointer<_sensor_provider_s> provider, + ) { + return _sensor_add_provider( + provider, + ); + } + + late final _sensor_add_provider_ptr = + _lookup>( + 'sensor_add_provider'); + late final _dart_sensor_add_provider _sensor_add_provider = + _sensor_add_provider_ptr.asFunction<_dart_sensor_add_provider>(); + + /// @brief Unregisters the sensor provider. + /// @since_tizen 4.0 + /// + /// @param[in] provider The sensor provider handle + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_add_provider() + int sensor_remove_provider( + ffi.Pointer<_sensor_provider_s> provider, + ) { + return _sensor_remove_provider( + provider, + ); + } + + late final _sensor_remove_provider_ptr = + _lookup>( + 'sensor_remove_provider'); + late final _dart_sensor_remove_provider _sensor_remove_provider = + _sensor_remove_provider_ptr.asFunction<_dart_sensor_remove_provider>(); + + /// @brief Releases all the resources allocated for the sensor provider. + /// @since_tizen 4.0 + /// + /// @remarks If this function is called before sensor_remove_provider() is called, + /// then the sensor provider will be implicitly unregistered. + /// + /// @param[in] provider The sensor provider handle + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see sensor_create_provider() + int sensor_destroy_provider( + ffi.Pointer<_sensor_provider_s> provider, + ) { + return _sensor_destroy_provider( + provider, + ); + } + + late final _sensor_destroy_provider_ptr = + _lookup>( + 'sensor_destroy_provider'); + late final _dart_sensor_destroy_provider _sensor_destroy_provider = + _sensor_destroy_provider_ptr.asFunction<_dart_sensor_destroy_provider>(); + + /// @brief Sets the name to the sensor provider. + /// @since_tizen 4.0 + /// + /// @param[in] provider The sensor provider handle + /// @param[in] name The name of the sensor + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre sensor_create_provider() + /// @see sensor_provider_set_vendor() + /// sensor_provider_set_range() + /// sensor_provider_set_resolution() + int sensor_provider_set_name( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer name, + ) { + return _sensor_provider_set_name( + provider, + name, + ); + } + + late final _sensor_provider_set_name_ptr = + _lookup>( + 'sensor_provider_set_name'); + late final _dart_sensor_provider_set_name _sensor_provider_set_name = + _sensor_provider_set_name_ptr + .asFunction<_dart_sensor_provider_set_name>(); + + /// @brief Sets the vendor to the sensor provider. + /// @since_tizen 4.0 + /// + /// @param[in] provider The sensor provider handle + /// @param[in] vendor The vendor of the sensor + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre sensor_create_provider() + /// @see sensor_provider_set_name() + /// sensor_provider_set_range() + /// sensor_provider_set_resolution() + int sensor_provider_set_vendor( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer vendor, + ) { + return _sensor_provider_set_vendor( + provider, + vendor, + ); + } + + late final _sensor_provider_set_vendor_ptr = + _lookup>( + 'sensor_provider_set_vendor'); + late final _dart_sensor_provider_set_vendor _sensor_provider_set_vendor = + _sensor_provider_set_vendor_ptr + .asFunction<_dart_sensor_provider_set_vendor>(); + + /// @brief Sets the range of possible sensor values to the sensor provider. + /// @since_tizen 4.0 + /// + /// @remarks If the application does not set the range, the default values are 0 and 1. + /// + /// @param[in] provider The sensor provider handle + /// @param[in] min_range The lower bound + /// @param[in] max_range The upper bound + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre sensor_create_provider() + /// @see sensor_provider_set_name() + /// sensor_provider_set_vendor() + /// sensor_provider_set_resolution() + int sensor_provider_set_range( + ffi.Pointer<_sensor_provider_s> provider, + double min_range, + double max_range, + ) { + return _sensor_provider_set_range( + provider, + min_range, + max_range, + ); + } + + late final _sensor_provider_set_range_ptr = + _lookup>( + 'sensor_provider_set_range'); + late final _dart_sensor_provider_set_range _sensor_provider_set_range = + _sensor_provider_set_range_ptr + .asFunction<_dart_sensor_provider_set_range>(); + + /// @brief Sets the resolution of sensor values to the sensor provider. + /// @since_tizen 4.0 + /// + /// @remarks If the application does not set the resolution, the default value is 1. + /// + /// @param[in] provider The sensor provider handle + /// @param[in] resolution The resolution + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @pre sensor_create_provider() + /// @see sensor_provider_set_name() + /// sensor_provider_set_vendor() + /// sensor_provider_set_range() + int sensor_provider_set_resolution( + ffi.Pointer<_sensor_provider_s> provider, + double resolution, + ) { + return _sensor_provider_set_resolution( + provider, + resolution, + ); + } + + late final _sensor_provider_set_resolution_ptr = + _lookup>( + 'sensor_provider_set_resolution'); + late final _dart_sensor_provider_set_resolution + _sensor_provider_set_resolution = _sensor_provider_set_resolution_ptr + .asFunction<_dart_sensor_provider_set_resolution>(); + + /// @brief Registers the callback function to be invoked when a listener starts the sensor provider. + /// @since_tizen 4.0 + /// + /// @param[in] provider The provider handle + /// @param[in] callback The callback function to attach to the @a provider handle + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_provider_set_start_cb( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _sensor_provider_set_start_cb( + provider, + callback, + user_data, + ); + } + + late final _sensor_provider_set_start_cb_ptr = + _lookup>( + 'sensor_provider_set_start_cb'); + late final _dart_sensor_provider_set_start_cb _sensor_provider_set_start_cb = + _sensor_provider_set_start_cb_ptr + .asFunction<_dart_sensor_provider_set_start_cb>(); + + /// @brief Registers the callback function to be invoked when a sensor listener stops the sensor provider. + /// @since_tizen 4.0 + /// + /// @param[in] provider The sensor provider handle + /// @param[in] callback The callback function to attach to the @a provider handle + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_provider_set_stop_cb( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _sensor_provider_set_stop_cb( + provider, + callback, + user_data, + ); + } + + late final _sensor_provider_set_stop_cb_ptr = + _lookup>( + 'sensor_provider_set_stop_cb'); + late final _dart_sensor_provider_set_stop_cb _sensor_provider_set_stop_cb = + _sensor_provider_set_stop_cb_ptr + .asFunction<_dart_sensor_provider_set_stop_cb>(); + + /// @brief Registers the callback function to be invoked when the interval is changed. + /// @since_tizen 4.0 + /// + /// @param[in] provider The sensor provider handle + /// @param[in] callback The callback function to attach to the @a provider handle + /// @param[in] user_data The user data to be passed to the callback function + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_provider_set_interval_changed_cb( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ) { + return _sensor_provider_set_interval_changed_cb( + provider, + callback, + user_data, + ); + } + + late final _sensor_provider_set_interval_changed_cb_ptr = + _lookup>( + 'sensor_provider_set_interval_changed_cb'); + late final _dart_sensor_provider_set_interval_changed_cb + _sensor_provider_set_interval_changed_cb = + _sensor_provider_set_interval_changed_cb_ptr + .asFunction<_dart_sensor_provider_set_interval_changed_cb>(); + + /// @brief Publishes a sensor event through the declared sensor. + /// @details This function publishes a sensor's data to its listeners. + /// @since_tizen 4.0 + /// + /// @param[in] provider The sensor provider handle + /// @param[out] event The sensor event + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_provider_publish( + ffi.Pointer<_sensor_provider_s> provider, + sensor_event_s event, + ) { + return _sensor_provider_publish( + provider, + event, + ); + } + + late final _sensor_provider_publish_ptr = + _lookup>( + 'sensor_provider_publish'); + late final _dart_sensor_provider_publish _sensor_provider_publish = + _sensor_provider_publish_ptr.asFunction<_dart_sensor_provider_publish>(); + + /// @brief Checks whether it is supported to record a given sensor type. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @param[in] type A sensor type to check + /// @param[out] supported If supported, @c true; Otherwise @c false + /// + /// @return #SENSOR_ERROR_NONE on success; Otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_recorder_is_supported( + int type, + ffi.Pointer supported, + ) { + return _sensor_recorder_is_supported( + type, + supported, + ); + } + + late final _sensor_recorder_is_supported_ptr = + _lookup>( + 'sensor_recorder_is_supported'); + late final _dart_sensor_recorder_is_supported _sensor_recorder_is_supported = + _sensor_recorder_is_supported_ptr + .asFunction<_dart_sensor_recorder_is_supported>(); + + /// @brief Starts to record a given sensor type. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @remarks Some sensor types are privileged. An application should have the privilege + /// http://tizen.org/privilege/healthinfo to get access to the following sensors: + /// #SENSOR_HRM, #SENSOR_HRM_LED_GREEN, #SENSOR_HRM_LED_IR, #SENSOR_HRM_LED_RED, + /// #SENSOR_HUMAN_PEDOMETER, #SENSOR_HUMAN_SLEEP_MONITOR, #SENSOR_HUMAN_SLEEP_DETECTOR, + /// and #SENSOR_HUMAN_STRESS_MONITOR. + /// + /// @param[in] type A sensor type to be recorded + /// @param[in] option Option + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_NOT_SUPPORTED Not supported to record the sensor type + /// @retval #SENSOR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// @retval #SENSOR_ERROR_NOT_AVAILABLE The sensor is already being recorded by the request of the current application + /// + /// @see sensor_recorder_stop() + int sensor_recorder_start( + int type, + ffi.Pointer option, + ) { + return _sensor_recorder_start( + type, + option, + ); + } + + late final _sensor_recorder_start_ptr = + _lookup>( + 'sensor_recorder_start'); + late final _dart_sensor_recorder_start _sensor_recorder_start = + _sensor_recorder_start_ptr.asFunction<_dart_sensor_recorder_start>(); + + /// @brief Stops recording a given sensor type. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @param[in] type A sensor type being recorded + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_NOT_SUPPORTED The sensor type is not supported + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_recorder_start() + int sensor_recorder_stop( + int type, + ) { + return _sensor_recorder_stop( + type, + ); + } + + late final _sensor_recorder_stop_ptr = + _lookup>( + 'sensor_recorder_stop'); + late final _dart_sensor_recorder_stop _sensor_recorder_stop = + _sensor_recorder_stop_ptr.asFunction<_dart_sensor_recorder_stop>(); + + /// @brief Creates a recorder option handle. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @remarks The @a option must be released using sensor_recorder_destroy_option(). + /// + /// @param[out] option Option handle + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_recorder_create_option( + ffi.Pointer> option, + ) { + return _sensor_recorder_create_option( + option, + ); + } + + late final _sensor_recorder_create_option_ptr = + _lookup>( + 'sensor_recorder_create_option'); + late final _dart_sensor_recorder_create_option + _sensor_recorder_create_option = _sensor_recorder_create_option_ptr + .asFunction<_dart_sensor_recorder_create_option>(); + + /// @brief Destroys a recorder option handle. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @param[in] option Option handle + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_recorder_destroy_option( + ffi.Pointer option, + ) { + return _sensor_recorder_destroy_option( + option, + ); + } + + late final _sensor_recorder_destroy_option_ptr = + _lookup>( + 'sensor_recorder_destroy_option'); + late final _dart_sensor_recorder_destroy_option + _sensor_recorder_destroy_option = _sensor_recorder_destroy_option_ptr + .asFunction<_dart_sensor_recorder_destroy_option>(); + + /// @brief Sets a recording option parameter. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @param[in] option Option handle + /// @param[in] param Option parameter + /// @param[in] value Value + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_recorder_option_set_int( + ffi.Pointer option, + int param, + int value, + ) { + return _sensor_recorder_option_set_int( + option, + param, + value, + ); + } + + late final _sensor_recorder_option_set_int_ptr = + _lookup>( + 'sensor_recorder_option_set_int'); + late final _dart_sensor_recorder_option_set_int + _sensor_recorder_option_set_int = _sensor_recorder_option_set_int_ptr + .asFunction<_dart_sensor_recorder_option_set_int>(); + + /// @brief Creates a recorder query handle. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @remarks The @a query must be released using sensor_recorder_destroy_query(). + /// + /// @param[out] query Query handle + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_recorder_create_query( + ffi.Pointer> query, + ) { + return _sensor_recorder_create_query( + query, + ); + } + + late final _sensor_recorder_create_query_ptr = + _lookup>( + 'sensor_recorder_create_query'); + late final _dart_sensor_recorder_create_query _sensor_recorder_create_query = + _sensor_recorder_create_query_ptr + .asFunction<_dart_sensor_recorder_create_query>(); + + /// @brief Destroys a recorder query handle. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @param[in] query Query handle + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_recorder_destroy_query( + ffi.Pointer query, + ) { + return _sensor_recorder_destroy_query( + query, + ); + } + + late final _sensor_recorder_destroy_query_ptr = + _lookup>( + 'sensor_recorder_destroy_query'); + late final _dart_sensor_recorder_destroy_query + _sensor_recorder_destroy_query = _sensor_recorder_destroy_query_ptr + .asFunction<_dart_sensor_recorder_destroy_query>(); + + /// @brief Sets an integer-type query parameter + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @param[in] query Query handle + /// @param[in] param Query parameter + /// @param[in] value Value + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_recorder_query_set_int( + ffi.Pointer query, + int param, + int value, + ) { + return _sensor_recorder_query_set_int( + query, + param, + value, + ); + } + + late final _sensor_recorder_query_set_int_ptr = + _lookup>( + 'sensor_recorder_query_set_int'); + late final _dart_sensor_recorder_query_set_int + _sensor_recorder_query_set_int = _sensor_recorder_query_set_int_ptr + .asFunction<_dart_sensor_recorder_query_set_int>(); + + /// @brief Sets a time-type query parameter. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @param[in] query Query handle + /// @param[in] param Query parameter + /// @param[in] t Time + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_recorder_query_set_time( + ffi.Pointer query, + int param, + int t, + ) { + return _sensor_recorder_query_set_time( + query, + param, + t, + ); + } + + late final _sensor_recorder_query_set_time_ptr = + _lookup>( + 'sensor_recorder_query_set_time'); + late final _dart_sensor_recorder_query_set_time + _sensor_recorder_query_set_time = _sensor_recorder_query_set_time_ptr + .asFunction<_dart_sensor_recorder_query_set_time>(); + + /// @brief Queries the recorded data asynchronously. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @remarks Some sensor types are privileged. An application should have the privilege + /// http://tizen.org/privilege/healthinfo to get access to the following sensors: + /// #SENSOR_HRM, #SENSOR_HRM_LED_GREEN, #SENSOR_HRM_LED_IR, #SENSOR_HRM_LED_RED, + /// #SENSOR_HUMAN_PEDOMETER, #SENSOR_HUMAN_SLEEP_MONITOR, #SENSOR_HUMAN_SLEEP_DETECTOR, + /// and #SENSOR_HUMAN_STRESS_MONITOR. + /// + /// @param[in] type Sensor type + /// @param[in] query Query handle + /// @param[in] cb Callback function to receive the queried data + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_NOT_SUPPORTED Not supported to record the sensor type + /// @retval #SENSOR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// + /// @see sensor_recorder_read_sync() + int sensor_recorder_read( + int type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _sensor_recorder_read( + type, + query, + cb, + user_data, + ); + } + + late final _sensor_recorder_read_ptr = + _lookup>( + 'sensor_recorder_read'); + late final _dart_sensor_recorder_read _sensor_recorder_read = + _sensor_recorder_read_ptr.asFunction<_dart_sensor_recorder_read>(); + + /// @brief Queries the recorded data synchronously. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @remarks Some sensor types are privileged. An application should have the privilege + /// http://tizen.org/privilege/healthinfo to get access to the following sensors: + /// #SENSOR_HRM, #SENSOR_HRM_LED_GREEN, #SENSOR_HRM_LED_IR, #SENSOR_HRM_LED_RED, + /// #SENSOR_HUMAN_PEDOMETER, #SENSOR_HUMAN_SLEEP_MONITOR, #SENSOR_HUMAN_SLEEP_DETECTOR, + /// and #SENSOR_HUMAN_STRESS_MONITOR. + /// + /// @param[in] type Sensor type + /// @param[in] query Query handle + /// @param[in] cb Callback function to receive the queried data + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_NOT_SUPPORTED Not supported to record the sensor type + /// @retval #SENSOR_ERROR_PERMISSION_DENIED Permission denied + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// @retval #SENSOR_ERROR_NO_DATA No data retrieved + /// + /// @see sensor_recorder_read() + int sensor_recorder_read_sync( + int type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _sensor_recorder_read_sync( + type, + query, + cb, + user_data, + ); + } + + late final _sensor_recorder_read_sync_ptr = + _lookup>( + 'sensor_recorder_read_sync'); + late final _dart_sensor_recorder_read_sync _sensor_recorder_read_sync = + _sensor_recorder_read_sync_ptr + .asFunction<_dart_sensor_recorder_read_sync>(); + + /// @brief Gets the start and the end time of the time period of a given record data. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @param[in] data Record data handle + /// @param[out] start_time Start time of the time period of the record + /// @param[out] end_time End time of the time period of the record + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + int sensor_recorder_data_get_time( + ffi.Pointer data, + ffi.Pointer start_time, + ffi.Pointer end_time, + ) { + return _sensor_recorder_data_get_time( + data, + start_time, + end_time, + ); + } + + late final _sensor_recorder_data_get_time_ptr = + _lookup>( + 'sensor_recorder_data_get_time'); + late final _dart_sensor_recorder_data_get_time + _sensor_recorder_data_get_time = _sensor_recorder_data_get_time_ptr + .asFunction<_dart_sensor_recorder_data_get_time>(); + + /// @brief Gets an integer value from a record data. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @param[in] data Record data handle + /// @param[in] key Data attribute to retrieve + /// @param[out] value Retrieved value + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// @retval #SENSOR_ERROR_NO_DATA No data retrieved + int sensor_recorder_data_get_int( + ffi.Pointer data, + int key, + ffi.Pointer value, + ) { + return _sensor_recorder_data_get_int( + data, + key, + value, + ); + } + + late final _sensor_recorder_data_get_int_ptr = + _lookup>( + 'sensor_recorder_data_get_int'); + late final _dart_sensor_recorder_data_get_int _sensor_recorder_data_get_int = + _sensor_recorder_data_get_int_ptr + .asFunction<_dart_sensor_recorder_data_get_int>(); + + /// @brief Gets a double value from a record data. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// + /// @param[in] data Record data handle + /// @param[in] key Data attribute to retrieve + /// @param[out] value Retrieved value + /// + /// @return #SENSOR_ERROR_NONE on success, otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SENSOR_ERROR_OPERATION_FAILED Operation failed + /// @retval #SENSOR_ERROR_NO_DATA No data retrieved + int sensor_recorder_data_get_double( + ffi.Pointer data, + int key, + ffi.Pointer value, + ) { + return _sensor_recorder_data_get_double( + data, + key, + value, + ); + } + + late final _sensor_recorder_data_get_double_ptr = + _lookup>( + 'sensor_recorder_data_get_double'); + late final _dart_sensor_recorder_data_get_double + _sensor_recorder_data_get_double = _sensor_recorder_data_get_double_ptr + .asFunction<_dart_sensor_recorder_data_get_double>(); + + /// @brief Gets the inclination matrix @"I@" and rotation matrix @"R@" transforming a vector from the device coordinate to the world's coordinate. + /// + /// @details [0 0 g] = R * gravity (g = magnitude of gravity) \n + /// [0 m 0] = I * R * geomagnetic (m = magnitude of the geomagnetic field) \n + /// R is the identity matrix when the device is aligned with the world's coordinate system, that is, when the device's X axis points towards the East, the Y axis points to the North Pole and the device is facing the sky. \n + /// I is a rotation matrix transforming the geomagnetic vector into the same coordinate space as gravity (the world's coordinate space). I is a simple rotation around the X axis. \n + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks Parameters Gx, Gy, and Gz can be obtained from the values returned by #SENSOR_GRAVITY. \n + /// Parameters Mx, My, and Mz can be obtained from the values returned by #SENSOR_MAGNETIC. + /// Output parameter R and I are always returned as a 3x3 matrix array of 9 floats like this form: + ///
+  /// { R[0], R[1], R[2],
+  /// R[3], R[4], R[5],
+  /// R[6], R[7], R[6] }
+  /// 
+ /// + /// + /// @param[in] Gx The X-axis gravity vector in the device's coordinate + /// @param[in] Gy The Y-axis gravity vector in the device's coordinate + /// @param[in] Gz The Z-axis gravity vector in the device's coordinate + /// @param[in] Mx The X-axis geomagnetic vector in the device's coordinate + /// @param[in] My The Y-axis geomagnetic vector in the device's coordinate + /// @param[in] Mz The Z-axis geomagnetic vector in the device's coordinate + /// @param[out] R The array of 9 floats that represent the rotation matrix @"R@" \n + /// It can be null. + /// @param[out] I The array of 9 floats that represent the inclination matrix @"I@" \n + /// It can be null. + /// + /// @return #SENSOR_ERROR_NONE on success; Otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + int sensor_util_get_rotation_matrix( + double Gx, + double Gy, + double Gz, + double Mx, + double My, + double Mz, + ffi.Pointer R, + ffi.Pointer I, + ) { + return _sensor_util_get_rotation_matrix( + Gx, + Gy, + Gz, + Mx, + My, + Mz, + R, + I, + ); + } + + late final _sensor_util_get_rotation_matrix_ptr = + _lookup>( + 'sensor_util_get_rotation_matrix'); + late final _dart_sensor_util_get_rotation_matrix + _sensor_util_get_rotation_matrix = _sensor_util_get_rotation_matrix_ptr + .asFunction<_dart_sensor_util_get_rotation_matrix>(); + + /// @brief Converts a rotation vector to a rotation matrix. + /// + /// @details Rotation vectors (Vx, Vy, Vz) can be obtained from #SENSOR_ROTATION_VECTOR. + /// It returns a 9 element rotation matrix in the array R. R must have length as 9. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] Vx The X-axis rotation vector + /// @param[in] Vy The Y-axis rotation vector + /// @param[in] Vz The Z-axis rotation vector + /// @param[out] R A 9 element rotation matrix in the array R that must have length as 9 + /// + /// @return #SENSOR_ERROR_NONE on success; Otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + int sensor_util_get_rotation_matrix_from_vector( + double Vx, + double Vy, + double Vz, + ffi.Pointer R, + ) { + return _sensor_util_get_rotation_matrix_from_vector( + Vx, + Vy, + Vz, + R, + ); + } + + late final _sensor_util_get_rotation_matrix_from_vector_ptr = _lookup< + ffi.NativeFunction<_c_sensor_util_get_rotation_matrix_from_vector>>( + 'sensor_util_get_rotation_matrix_from_vector'); + late final _dart_sensor_util_get_rotation_matrix_from_vector + _sensor_util_get_rotation_matrix_from_vector = + _sensor_util_get_rotation_matrix_from_vector_ptr + .asFunction<_dart_sensor_util_get_rotation_matrix_from_vector>(); + + /// @brief Rotates the supplied rotation matrix so that it is expressed in a different coordinate system. + /// + /// @details This is typically used when an application needs to compute the three orientation angles of the device in a different coordinate system. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks inR and outR can be the same array, but this is not recommended for performance reasons. + /// This returns an error when X and Y define the same axis. + /// + /// @param[in] inR The rotation matrix (3x3) to be transformed + /// @param[in] x The world axis and direction on which the X axis of the device is mapped + /// @param[in] y The world axis and direction on which the Y axis of the device is mapped + /// @param[out] outR The transformed rotation matrix (3x3) + /// + /// @return #SENSOR_ERROR_NONE on success; Otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + int sensor_util_remap_coordinate_system( + ffi.Pointer inR, + int x, + int y, + ffi.Pointer outR, + ) { + return _sensor_util_remap_coordinate_system( + inR, + x, + y, + outR, + ); + } + + late final _sensor_util_remap_coordinate_system_ptr = + _lookup>( + 'sensor_util_remap_coordinate_system'); + late final _dart_sensor_util_remap_coordinate_system + _sensor_util_remap_coordinate_system = + _sensor_util_remap_coordinate_system_ptr + .asFunction<_dart_sensor_util_remap_coordinate_system>(); + + /// @brief Computes the geomagnetic inclination angle in radians from the inclination matrix I returned by sensor_util_get_rotation_matrix(). + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] I The inclination matrix from sensor_util_get_rotation_matrix() + /// @param[out] inclination The geomagnetic inclination angle in radians + /// + /// @return #SENSOR_ERROR_NONE on success; Otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see sensor_util_get_rotation_matrix() + int sensor_util_get_inclination( + ffi.Pointer I, + ffi.Pointer inclination, + ) { + return _sensor_util_get_inclination( + I, + inclination, + ); + } + + late final _sensor_util_get_inclination_ptr = + _lookup>( + 'sensor_util_get_inclination'); + late final _dart_sensor_util_get_inclination _sensor_util_get_inclination = + _sensor_util_get_inclination_ptr + .asFunction<_dart_sensor_util_get_inclination>(); + + /// @brief Computes the device's orientation based on the rotation matrix. + /// + /// @details When it returns, the array values are filled with the result: + /// - values[0]: azimuth, rotation around the Z axis. + /// - values[1]: pitch, rotation around the X axis. + /// - values[2]: roll, rotation around the Y axis. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks Parameter R must be an array of 9 floats from sensor_util_get_rotation_matrix() \n + /// Returned values are always arrays of 3 floats. + /// + /// @param[in] R A 9 element rotation matrix in the array + /// @param[out] values An array of 3 floats to hold the result + /// + /// @return #SENSOR_ERROR_NONE on success; Otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + /// + /// @see sensor_util_get_rotation_matrix() + int sensor_util_get_orientation( + ffi.Pointer R, + ffi.Pointer values, + ) { + return _sensor_util_get_orientation( + R, + values, + ); + } + + late final _sensor_util_get_orientation_ptr = + _lookup>( + 'sensor_util_get_orientation'); + late final _dart_sensor_util_get_orientation _sensor_util_get_orientation = + _sensor_util_get_orientation_ptr + .asFunction<_dart_sensor_util_get_orientation>(); + + /// @brief Computes the angle change between two rotation matrices. + /// + /// @details Given a current rotation matrix (R) and a previous rotation matrix (prevR), it computes + /// the rotation around the x,y, and z axes which transforms prevR to R. + /// It outputs a 3 element vector containing the x,y, and z angle change at indexes 0, 1, and 2 respectively. \n + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks Each input matrix is a 3x3 matrix like this form: + ///
+  /// { R[0], R[1], R[2],
+  /// R[3], R[4], R[5],
+  /// R[6], R[7], R[6] }
+  /// 
+ /// + /// @param[in] R The current rotation matrix + /// @param[in] prevR The previous rotation matrix + /// @param[out] angleChange An array of floats in which the angle change is stored + /// + /// @return #SENSOR_ERROR_NONE on success; Otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + int sensor_util_get_angle_change( + ffi.Pointer R, + ffi.Pointer prevR, + ffi.Pointer angleChange, + ) { + return _sensor_util_get_angle_change( + R, + prevR, + angleChange, + ); + } + + late final _sensor_util_get_angle_change_ptr = + _lookup>( + 'sensor_util_get_angle_change'); + late final _dart_sensor_util_get_angle_change _sensor_util_get_angle_change = + _sensor_util_get_angle_change_ptr + .asFunction<_dart_sensor_util_get_angle_change>(); + + /// @brief Gets the declination of the horizontal component of the magnetic field from true north, in degrees. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] latitude The latitude in geodetic coordinates + /// @param[in] longitude The longitude in geodetic coordinates + /// @param[in] altitude The altitude in geodetic coordinates + /// @param[out] declination The declination of the horizontal component of the magnetic field in degrees + /// + /// @return #SENSOR_ERROR_NONE on success; Otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + int sensor_util_get_declination( + double latitude, + double longitude, + double altitude, + ffi.Pointer declination, + ) { + return _sensor_util_get_declination( + latitude, + longitude, + altitude, + declination, + ); + } + + late final _sensor_util_get_declination_ptr = + _lookup>( + 'sensor_util_get_declination'); + late final _dart_sensor_util_get_declination _sensor_util_get_declination = + _sensor_util_get_declination_ptr + .asFunction<_dart_sensor_util_get_declination>(); + + /// @brief Gets the altitude from the atmospheric pressure, the pressure at sea level and temperature, in meters. + /// @since_tizen 4.0 + /// + /// @param[in] pressure The atmospheric pressure (hPa) + /// @param[in] sea_level_pressure The sea level pressure (hPa) @n + /// If the sea level pressure is not known, you can use 1013.25 hPa, mean sea level pressure + /// @param[in] temperature The temperature (degrees Celsius) @n + /// If the temperature is not known, you can use 15 degrees Celsius + /// @param[out] altitude The altitude (meters) + /// + /// @return #SENSOR_ERROR_NONE on success; Otherwise a negative error value + /// @retval #SENSOR_ERROR_NONE Successful + /// @retval #SENSOR_ERROR_INVALID_PARAMETER Invalid parameter + int sensor_util_get_altitude( + double pressure, + double sea_level_pressure, + double temperature, + ffi.Pointer altitude, + ) { + return _sensor_util_get_altitude( + pressure, + sea_level_pressure, + temperature, + altitude, + ); + } + + late final _sensor_util_get_altitude_ptr = + _lookup>( + 'sensor_util_get_altitude'); + late final _dart_sensor_util_get_altitude _sensor_util_get_altitude = + _sensor_util_get_altitude_ptr + .asFunction<_dart_sensor_util_get_altitude>(); + + /// @brief Retrieves all the storage in a device. + /// @details This function invokes the callback function once for each storage in a device. \n + /// If storage_device_supported_cb() returns @c false, then the iteration will be finished. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] callback The iteration callback function + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STORAGE_ERROR_NONE Successful + /// @retval #STORAGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @post This function invokes storage_device_supported_cb() repeatedly for each supported device. + /// @see storage_device_supported_cb() + int storage_foreach_device_supported( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _storage_foreach_device_supported( + callback, + user_data, + ); + } + + late final _storage_foreach_device_supported_ptr = + _lookup>( + 'storage_foreach_device_supported'); + late final _dart_storage_foreach_device_supported + _storage_foreach_device_supported = _storage_foreach_device_supported_ptr + .asFunction<_dart_storage_foreach_device_supported>(); + + /// @brief Gets the absolute path to the root directory of the given storage. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks Files saved on the internal/external storage are readable or writable by all applications.\n + /// When an application is uninstalled, the files written by that application are not removed from the internal/external storage.\n + /// If you want to access files or directories in internal storage, you must declare http://tizen.org/privilege/mediastorage.\n + /// If you want to access files or directories in external storage, you must declare http://tizen.org/privilege/externalstorage.\n + /// Refer to Privacy-related Permissions.\n + /// You must release @a path using free(). + /// @param[in] storage_id The storage device + /// @param[out] path The absolute path to the storage directory + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STORAGE_ERROR_NONE Successful + /// @retval #STORAGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STORAGE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STORAGE_ERROR_NOT_SUPPORTED Storage not supported + /// @see storage_get_state() + int storage_get_root_directory( + int storage_id, + ffi.Pointer> path, + ) { + return _storage_get_root_directory( + storage_id, + path, + ); + } + + late final _storage_get_root_directory_ptr = + _lookup>( + 'storage_get_root_directory'); + late final _dart_storage_get_root_directory _storage_get_root_directory = + _storage_get_root_directory_ptr + .asFunction<_dart_storage_get_root_directory>(); + + /// @brief Gets the absolute path to the each directory of the given storage. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks Files saved on the internal/external storage are readable or writable by all applications.\n + /// When an application is uninstalled, the files written by that application are not removed from the internal/external storage.\n + /// The directory path may not exist, so you must make sure that it exists before using it.\n + /// If you want to access files or directories in internal storage, you must declare http://tizen.org/privilege/mediastorage.\n + /// If you want to access files or directories in external storage, you must declare http://tizen.org/privilege/externalstorage.\n + /// Refer to Privacy-related Permissions.\n + /// You must release @a path using free(). + /// @param[in] storage_id The storage device + /// @param[in] type The directory type + /// @param[out] path The absolute path to the directory type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STORAGE_ERROR_NONE Successful + /// @retval #STORAGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STORAGE_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STORAGE_ERROR_NOT_SUPPORTED Storage not supported + /// @see storage_get_state() + int storage_get_directory( + int storage_id, + int type, + ffi.Pointer> path, + ) { + return _storage_get_directory( + storage_id, + type, + path, + ); + } + + late final _storage_get_directory_ptr = + _lookup>( + 'storage_get_directory'); + late final _dart_storage_get_directory _storage_get_directory = + _storage_get_directory_ptr.asFunction<_dart_storage_get_directory>(); + + /// @brief Gets the type of the given storage. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] storage_id The storage device + /// @param[out] type The type of the storage + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STORAGE_ERROR_NONE Successful + /// @retval #STORAGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STORAGE_ERROR_NOT_SUPPORTED Storage not supported + int storage_get_type( + int storage_id, + ffi.Pointer type, + ) { + return _storage_get_type( + storage_id, + type, + ); + } + + late final _storage_get_type_ptr = + _lookup>('storage_get_type'); + late final _dart_storage_get_type _storage_get_type = + _storage_get_type_ptr.asFunction<_dart_storage_get_type>(); + + /// @brief Gets the current state of the given storage. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] storage_id The storage device + /// @param[out] state The current state of the storage + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STORAGE_ERROR_NONE Successful + /// @retval #STORAGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STORAGE_ERROR_NOT_SUPPORTED Storage not supported + /// @see storage_get_root_directory() + /// @see storage_get_total_space() + /// @see storage_get_available_space() + int storage_get_state( + int storage_id, + ffi.Pointer state, + ) { + return _storage_get_state( + storage_id, + state, + ); + } + + late final _storage_get_state_ptr = + _lookup>('storage_get_state'); + late final _dart_storage_get_state _storage_get_state = + _storage_get_state_ptr.asFunction<_dart_storage_get_state>(); + + /// @brief Registers a callback function to be invoked when the state of the storage changes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] storage_id The storage device + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STORAGE_ERROR_NONE Successful + /// @retval #STORAGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STORAGE_ERROR_NOT_SUPPORTED Storage not supported + /// @retval #STORAGE_ERROR_OPERATION_FAILED Operation failed + /// @post storage_state_changed_cb() will be invoked if the state of the registered storage changes. + /// @see storage_state_changed_cb() + /// @see storage_unset_state_changed_cb() + int storage_set_state_changed_cb( + int storage_id, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _storage_set_state_changed_cb( + storage_id, + callback, + user_data, + ); + } + + late final _storage_set_state_changed_cb_ptr = + _lookup>( + 'storage_set_state_changed_cb'); + late final _dart_storage_set_state_changed_cb _storage_set_state_changed_cb = + _storage_set_state_changed_cb_ptr + .asFunction<_dart_storage_set_state_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] storage_id The storage device to monitor + /// @param[in] callback The callback function to register + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STORAGE_ERROR_NONE Successful + /// @retval #STORAGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STORAGE_ERROR_NOT_SUPPORTED Storage not supported + /// @retval #STORAGE_ERROR_OPERATION_FAILED Operation failed + /// @see storage_state_changed_cb() + /// @see storage_set_state_changed_cb() + int storage_unset_state_changed_cb( + int storage_id, + ffi.Pointer> callback, + ) { + return _storage_unset_state_changed_cb( + storage_id, + callback, + ); + } + + late final _storage_unset_state_changed_cb_ptr = + _lookup>( + 'storage_unset_state_changed_cb'); + late final _dart_storage_unset_state_changed_cb + _storage_unset_state_changed_cb = _storage_unset_state_changed_cb_ptr + .asFunction<_dart_storage_unset_state_changed_cb>(); + + /// @brief Registers a callback function to be invoked when the state of the specified storage device type changes. + /// @since_tizen 3.0 + /// @param[in] type The type of the storage device + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STORAGE_ERROR_NONE Successful + /// @retval #STORAGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STORAGE_ERROR_NOT_SUPPORTED Storage not supported + /// @retval #STORAGE_ERROR_OPERATION_FAILED Operation failed + /// @post storage_changed_cb() will be invoked if the state of the registered storage type changes. + /// @see storage_changed_cb() + /// @see storage_unset_changed_cb() + int storage_set_changed_cb( + int type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _storage_set_changed_cb( + type, + callback, + user_data, + ); + } + + late final _storage_set_changed_cb_ptr = + _lookup>( + 'storage_set_changed_cb'); + late final _dart_storage_set_changed_cb _storage_set_changed_cb = + _storage_set_changed_cb_ptr.asFunction<_dart_storage_set_changed_cb>(); + + /// @brief Unregisters the callback function for storage type state changes. + /// @since_tizen 3.0 + /// @param[in] type The type of the the storage device + /// @param[in] callback The callback function to unregister + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STORAGE_ERROR_NONE Successful + /// @retval #STORAGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STORAGE_ERROR_NOT_SUPPORTED Storage not supported + /// @retval #STORAGE_ERROR_OPERATION_FAILED Operation failed + /// @see storage_changed_cb() + /// @see storage_set_changed_cb() + int storage_unset_changed_cb( + int type, + ffi.Pointer> callback, + ) { + return _storage_unset_changed_cb( + type, + callback, + ); + } + + late final _storage_unset_changed_cb_ptr = + _lookup>( + 'storage_unset_changed_cb'); + late final _dart_storage_unset_changed_cb _storage_unset_changed_cb = + _storage_unset_changed_cb_ptr + .asFunction<_dart_storage_unset_changed_cb>(); + + /// @brief Gets the total space of the given storage in bytes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] storage_id The storage device + /// @param[out] bytes The total space size of the storage (bytes) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STORAGE_ERROR_NONE Successful + /// @retval #STORAGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STORAGE_ERROR_NOT_SUPPORTED Storage not supported + /// @retval #STORAGE_ERROR_OPERATION_FAILED Operation failed + /// @see storage_get_state() + /// @see storage_get_available_space() + int storage_get_total_space( + int storage_id, + ffi.Pointer bytes, + ) { + return _storage_get_total_space( + storage_id, + bytes, + ); + } + + late final _storage_get_total_space_ptr = + _lookup>( + 'storage_get_total_space'); + late final _dart_storage_get_total_space _storage_get_total_space = + _storage_get_total_space_ptr.asFunction<_dart_storage_get_total_space>(); + + /// @brief Gets the available space size of the given storage in bytes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] storage_id The storage device + /// @param[out] bytes The available space size of the storage (bytes) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STORAGE_ERROR_NONE Successful + /// @retval #STORAGE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STORAGE_ERROR_NOT_SUPPORTED Storage not supported + /// @retval #STORAGE_ERROR_OPERATION_FAILED Operation failed + /// @see storage_get_state() + /// @see storage_get_total_space() + int storage_get_available_space( + int storage_id, + ffi.Pointer bytes, + ) { + return _storage_get_available_space( + storage_id, + bytes, + ); + } + + late final _storage_get_available_space_ptr = + _lookup>( + 'storage_get_available_space'); + late final _dart_storage_get_available_space _storage_get_available_space = + _storage_get_available_space_ptr + .asFunction<_dart_storage_get_available_space>(); + + int storage_get_internal_memory_size( + ffi.Pointer buf, + ) { + return _storage_get_internal_memory_size( + buf, + ); + } + + late final _storage_get_internal_memory_size_ptr = + _lookup>( + 'storage_get_internal_memory_size'); + late final _dart_storage_get_internal_memory_size + _storage_get_internal_memory_size = _storage_get_internal_memory_size_ptr + .asFunction<_dart_storage_get_internal_memory_size>(); + + int storage_get_external_memory_size( + ffi.Pointer buf, + ) { + return _storage_get_external_memory_size( + buf, + ); + } + + late final _storage_get_external_memory_size_ptr = + _lookup>( + 'storage_get_external_memory_size'); + late final _dart_storage_get_external_memory_size + _storage_get_external_memory_size = _storage_get_external_memory_size_ptr + .asFunction<_dart_storage_get_external_memory_size>(); + + /// @brief Gets the boolean value of the @a platform feature. + /// @since_tizen 2.3 + /// @param[in] key The name of the platform feature to get + /// @param[out] value The value of the given platform feature + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SYSTEM_INFO_ERROR_NONE Successful + /// @retval #SYSTEM_INFO_ERROR_INVALID_PARAMETER Cannot find the @a key in the model config file + /// @retval #SYSTEM_INFO_ERROR_IO_ERROR An input/output error occurred while reading the @a value from the model config file + /// @retval #SYSTEM_INFO_ERROR_PERMISSION_DENIED No permission to use the API + int system_info_get_platform_bool( + ffi.Pointer key, + ffi.Pointer value, + ) { + return _system_info_get_platform_bool( + key, + value, + ); + } + + late final _system_info_get_platform_bool_ptr = + _lookup>( + 'system_info_get_platform_bool'); + late final _dart_system_info_get_platform_bool + _system_info_get_platform_bool = _system_info_get_platform_bool_ptr + .asFunction<_dart_system_info_get_platform_bool>(); + + /// @brief Gets the integer value of the @a platform feature. + /// @since_tizen 2.3 + /// @param[in] key The name of the platform feature to get + /// @param[out] value The value of the given platform feature + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SYSTEM_INFO_ERROR_NONE Successful + /// @retval #SYSTEM_INFO_ERROR_INVALID_PARAMETER Cannot find the @a key in the model config file + /// @retval #SYSTEM_INFO_ERROR_IO_ERROR An input/output error occurred while reading the @a value from the model config file + /// @retval #SYSTEM_INFO_ERROR_PERMISSION_DENIED No permission to use the API + int system_info_get_platform_int( + ffi.Pointer key, + ffi.Pointer value, + ) { + return _system_info_get_platform_int( + key, + value, + ); + } + + late final _system_info_get_platform_int_ptr = + _lookup>( + 'system_info_get_platform_int'); + late final _dart_system_info_get_platform_int _system_info_get_platform_int = + _system_info_get_platform_int_ptr + .asFunction<_dart_system_info_get_platform_int>(); + + /// @brief Gets the double value of the @a platform feature. + /// @since_tizen 2.3 + /// @param[in] key The name of the platform feature to get + /// @param[out] value The value of the given platform feature + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SYSTEM_INFO_ERROR_NONE Successful + /// @retval #SYSTEM_INFO_ERROR_INVALID_PARAMETER Cannot find the @a key in the model config file + /// @retval #SYSTEM_INFO_ERROR_IO_ERROR An input/output error occurred while reading the @a value from the model config file + /// @retval #SYSTEM_INFO_ERROR_PERMISSION_DENIED No permission to use the API + int system_info_get_platform_double( + ffi.Pointer key, + ffi.Pointer value, + ) { + return _system_info_get_platform_double( + key, + value, + ); + } + + late final _system_info_get_platform_double_ptr = + _lookup>( + 'system_info_get_platform_double'); + late final _dart_system_info_get_platform_double + _system_info_get_platform_double = _system_info_get_platform_double_ptr + .asFunction<_dart_system_info_get_platform_double>(); + + /// @brief Gets the string value of the @a platform feature. + /// @since_tizen 2.3 + /// @remarks You must release the @a value using free(). + /// @param[in] key The name of the platform feature to get + /// @param[out] value The value of the given platform feature + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SYSTEM_INFO_ERROR_NONE Successful + /// @retval #SYSTEM_INFO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #SYSTEM_INFO_ERROR_INVALID_PARAMETER Cannot find the @a key in the model config file + /// @retval #SYSTEM_INFO_ERROR_IO_ERROR An input/output error occurred while reading the @a value from the model config file + /// @retval #SYSTEM_INFO_ERROR_PERMISSION_DENIED No permission to use the API + int system_info_get_platform_string( + ffi.Pointer key, + ffi.Pointer> value, + ) { + return _system_info_get_platform_string( + key, + value, + ); + } + + late final _system_info_get_platform_string_ptr = + _lookup>( + 'system_info_get_platform_string'); + late final _dart_system_info_get_platform_string + _system_info_get_platform_string = _system_info_get_platform_string_ptr + .asFunction<_dart_system_info_get_platform_string>(); + + /// @brief Gets the boolean value of the @a custom feature. + /// @since_tizen 2.3 + /// @param[in] key The name of the custom feature to get. NOTE: This custom function uses a custom key which is provided by OEM's + /// @param[out] value The value of the given custom feature + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SYSTEM_INFO_ERROR_NONE Successful + /// @retval #SYSTEM_INFO_ERROR_INVALID_PARAMETER Cannot find the @a key in the model config file + /// @retval #SYSTEM_INFO_ERROR_IO_ERROR An input/output error occurred while reading the @a value from the model config file + /// @retval #SYSTEM_INFO_ERROR_PERMISSION_DENIED No permission to use the API + int system_info_get_custom_bool( + ffi.Pointer key, + ffi.Pointer value, + ) { + return _system_info_get_custom_bool( + key, + value, + ); + } + + late final _system_info_get_custom_bool_ptr = + _lookup>( + 'system_info_get_custom_bool'); + late final _dart_system_info_get_custom_bool _system_info_get_custom_bool = + _system_info_get_custom_bool_ptr + .asFunction<_dart_system_info_get_custom_bool>(); + + /// @brief Gets the integer value of the @a custom feature. + /// @since_tizen 2.3 + /// @param[in] key The name of the custom feature to get. NOTE: This custom function uses a custom key which is provided by OEM's + /// @param[out] value The value of the given custom feature + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SYSTEM_INFO_ERROR_NONE Successful + /// @retval #SYSTEM_INFO_ERROR_INVALID_PARAMETER Cannot the find @a key in the model config file + /// @retval #SYSTEM_INFO_ERROR_IO_ERROR An input/output error occurred while reading the @a value from the model config file + /// @retval #SYSTEM_INFO_ERROR_PERMISSION_DENIED No permission to use the API + int system_info_get_custom_int( + ffi.Pointer key, + ffi.Pointer value, + ) { + return _system_info_get_custom_int( + key, + value, + ); + } + + late final _system_info_get_custom_int_ptr = + _lookup>( + 'system_info_get_custom_int'); + late final _dart_system_info_get_custom_int _system_info_get_custom_int = + _system_info_get_custom_int_ptr + .asFunction<_dart_system_info_get_custom_int>(); + + /// @brief Gets the double value of the @a custom feature. + /// @since_tizen 2.3 + /// @param[in] key The name of the custom feature to get. NOTE: This custom function uses a custom key which is provided by OEM's + /// @param[out] value The value of the given custom feature + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SYSTEM_INFO_ERROR_NONE Successful + /// @retval #SYSTEM_INFO_ERROR_INVALID_PARAMETER Cannot find the @a key in the model config file + /// @retval #SYSTEM_INFO_ERROR_IO_ERROR An input/output error occurred while reading the @a value from the model config file + /// @retval #SYSTEM_INFO_ERROR_PERMISSION_DENIED No permission to use the API + int system_info_get_custom_double( + ffi.Pointer key, + ffi.Pointer value, + ) { + return _system_info_get_custom_double( + key, + value, + ); + } + + late final _system_info_get_custom_double_ptr = + _lookup>( + 'system_info_get_custom_double'); + late final _dart_system_info_get_custom_double + _system_info_get_custom_double = _system_info_get_custom_double_ptr + .asFunction<_dart_system_info_get_custom_double>(); + + /// @brief Gets the string value of the @a custom feature. + /// @since_tizen 2.3 + /// @remarks You must release the @a value using free(). + /// @param[in] key The name of the custom feature to get. NOTE: This custom function uses a custom key which is provided by OEM's + /// @param[out] value The value of the given custom feature + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #SYSTEM_INFO_ERROR_NONE Successful + /// @retval #SYSTEM_INFO_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #SYSTEM_INFO_ERROR_INVALID_PARAMETER Cannot find the @a key in the model config file + /// @retval #SYSTEM_INFO_ERROR_IO_ERROR An input/output error occurred while reading the @a value from the model config file + /// @retval #SYSTEM_INFO_ERROR_PERMISSION_DENIED No permission to use the API + int system_info_get_custom_string( + ffi.Pointer key, + ffi.Pointer> value, + ) { + return _system_info_get_custom_string( + key, + value, + ); + } + + late final _system_info_get_custom_string_ptr = + _lookup>( + 'system_info_get_custom_string'); + late final _dart_system_info_get_custom_string + _system_info_get_custom_string = _system_info_get_custom_string_ptr + .asFunction<_dart_system_info_get_custom_string>(); + + /// @internal + /// @brief Do not use it. It will be removed. + int system_info_get_value_int( + int key, + ffi.Pointer value, + ) { + return _system_info_get_value_int( + key, + value, + ); + } + + late final _system_info_get_value_int_ptr = + _lookup>( + 'system_info_get_value_int'); + late final _dart_system_info_get_value_int _system_info_get_value_int = + _system_info_get_value_int_ptr + .asFunction<_dart_system_info_get_value_int>(); + + /// @internal + /// @brief Do not use it. It will be removed. + int system_info_get_value_bool( + int key, + ffi.Pointer value, + ) { + return _system_info_get_value_bool( + key, + value, + ); + } + + late final _system_info_get_value_bool_ptr = + _lookup>( + 'system_info_get_value_bool'); + late final _dart_system_info_get_value_bool _system_info_get_value_bool = + _system_info_get_value_bool_ptr + .asFunction<_dart_system_info_get_value_bool>(); + + /// @internal + /// @brief Do not use it. It will be removed. + int system_info_get_value_double( + int key, + ffi.Pointer value, + ) { + return _system_info_get_value_double( + key, + value, + ); + } + + late final _system_info_get_value_double_ptr = + _lookup>( + 'system_info_get_value_double'); + late final _dart_system_info_get_value_double _system_info_get_value_double = + _system_info_get_value_double_ptr + .asFunction<_dart_system_info_get_value_double>(); + + /// @internal + /// @brief Do not use it. It will be removed. + int system_info_get_value_string( + int key, + ffi.Pointer> value, + ) { + return _system_info_get_value_string( + key, + value, + ); + } + + late final _system_info_get_value_string_ptr = + _lookup>( + 'system_info_get_value_string'); + late final _dart_system_info_get_value_string _system_info_get_value_string = + _system_info_get_value_string_ptr + .asFunction<_dart_system_info_get_value_string>(); + + /// @internal + /// @brief It is not decided if it should be opened to public. + int system_info_get_platform_type( + ffi.Pointer key, + ffi.Pointer type, + ) { + return _system_info_get_platform_type( + key, + type, + ); + } + + late final _system_info_get_platform_type_ptr = + _lookup>( + 'system_info_get_platform_type'); + late final _dart_system_info_get_platform_type + _system_info_get_platform_type = _system_info_get_platform_type_ptr + .asFunction<_dart_system_info_get_platform_type>(); + + /// @internal + /// @brief It is not decided if it should be opened to public. + int system_info_get_custom_type( + ffi.Pointer key, + ffi.Pointer type, + ) { + return _system_info_get_custom_type( + key, + type, + ); + } + + late final _system_info_get_custom_type_ptr = + _lookup>( + 'system_info_get_custom_type'); + late final _dart_system_info_get_custom_type _system_info_get_custom_type = + _system_info_get_custom_type_ptr + .asFunction<_dart_system_info_get_custom_type>(); + + /// @platform + /// @brief Sets the system settings value associated with the given key as an integer. + /// @since_tizen 2.3 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/systemsettings.admin + /// @remarks When the feature related to the @a key is not supported on the device, #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED will be returned. + /// @param[in] key The key name of the system settings + /// @param[out] value The new system settings value of the given key + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SYSTEM_SETTINGS_ERROR_NONE Successful + /// @retval #SYSTEM_SETTINGS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYSTEM_SETTINGS_ERROR_IO_ERROR Internal I/O error + /// @retval #SYSTEM_SETTINGS_ERROR_PERMISSION_DENIED Permission violation error + /// @retval #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED The related feature is not supported on the device + int system_settings_set_value_int( + int key, + int value, + ) { + return _system_settings_set_value_int( + key, + value, + ); + } + + late final _system_settings_set_value_int_ptr = + _lookup>( + 'system_settings_set_value_int'); + late final _dart_system_settings_set_value_int + _system_settings_set_value_int = _system_settings_set_value_int_ptr + .asFunction<_dart_system_settings_set_value_int>(); + + /// @brief Gets the system settings value associated with the given key as an integer. + /// @since_tizen 2.3 + /// @remarks When the feature related to the @a key is not supported on the device, #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED will be returned. + /// @param[in] key The key name of the system settings + /// @param[out] value The current system settings value of the given key + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SYSTEM_SETTINGS_ERROR_NONE Successful + /// @retval #SYSTEM_SETTINGS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYSTEM_SETTINGS_ERROR_IO_ERROR Internal I/O error + /// @retval #SYSTEM_SETTINGS_ERROR_PERMISSION_DENIED Permission violation error + /// @retval #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED The related feature is not supported on the device + /// @warning %http://tizen.org/privilege/systemsettings (public level privilege) MUST NOT be declared to use this API since 2.3.1. + int system_settings_get_value_int( + int key, + ffi.Pointer value, + ) { + return _system_settings_get_value_int( + key, + value, + ); + } + + late final _system_settings_get_value_int_ptr = + _lookup>( + 'system_settings_get_value_int'); + late final _dart_system_settings_get_value_int + _system_settings_get_value_int = _system_settings_get_value_int_ptr + .asFunction<_dart_system_settings_get_value_int>(); + + /// @platform + /// @brief Sets the system settings value associated with the given key as a boolean. + /// @since_tizen 2.3 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/systemsettings.admin + /// @remarks When the feature related to the @a key is not supported on the device, #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED will be returned. + /// @param[in] key The key name of the system settings + /// @param[out] value The new system settings value of the given key + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SYSTEM_SETTINGS_ERROR_NONE Successful + /// @retval #SYSTEM_SETTINGS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYSTEM_SETTINGS_ERROR_IO_ERROR Internal I/O error + /// @retval #SYSTEM_SETTINGS_ERROR_PERMISSION_DENIED Permission violation error + /// @retval #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED The related feature is not supported on the device + int system_settings_set_value_bool( + int key, + bool value, + ) { + return _system_settings_set_value_bool( + key, + value ? 1 : 0, + ); + } + + late final _system_settings_set_value_bool_ptr = + _lookup>( + 'system_settings_set_value_bool'); + late final _dart_system_settings_set_value_bool + _system_settings_set_value_bool = _system_settings_set_value_bool_ptr + .asFunction<_dart_system_settings_set_value_bool>(); + + /// @brief Gets the system settings value associated with the given key as a boolean. + /// @since_tizen 2.3 + /// @remarks When the feature related to the @a key is not supported on the device, #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED will be returned. + /// @param[in] key The key name of the system settings + /// @param[out] value The current system settings value of the given key + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SYSTEM_SETTINGS_ERROR_NONE Successful + /// @retval #SYSTEM_SETTINGS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYSTEM_SETTINGS_ERROR_IO_ERROR Internal I/O error + /// @retval #SYSTEM_SETTINGS_ERROR_PERMISSION_DENIED Permission violation error + /// @retval #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED The related feature is not supported on the device + /// @warning %http://tizen.org/privilege/systemsettings (public level privilege) MUST NOT be declared to use this API since 2.3.1. + int system_settings_get_value_bool( + int key, + ffi.Pointer value, + ) { + return _system_settings_get_value_bool( + key, + value, + ); + } + + late final _system_settings_get_value_bool_ptr = + _lookup>( + 'system_settings_get_value_bool'); + late final _dart_system_settings_get_value_bool + _system_settings_get_value_bool = _system_settings_get_value_bool_ptr + .asFunction<_dart_system_settings_get_value_bool>(); + + /// @platform + /// @brief Sets the system settings value associated with the given key as a string. + /// @since_tizen 2.3 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/systemsettings.admin + /// @remarks #SYSTEM_SETTINGS_KEY_DEFAULT_FONT_TYPE is not available for setting. When the feature related to the @a key is not supported on the device, #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED will be returned. + /// @param[in] key The key name of the system settings + /// @param[out] value The new system settings value of the given key + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SYSTEM_SETTINGS_ERROR_NONE Successful + /// @retval #SYSTEM_SETTINGS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYSTEM_SETTINGS_ERROR_IO_ERROR Internal I/O error + /// @retval #SYSTEM_SETTINGS_ERROR_PERMISSION_DENIED Permission violation error + /// @retval #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED The related feature is not supported on the device + int system_settings_set_value_string( + int key, + ffi.Pointer value, + ) { + return _system_settings_set_value_string( + key, + value, + ); + } + + late final _system_settings_set_value_string_ptr = + _lookup>( + 'system_settings_set_value_string'); + late final _dart_system_settings_set_value_string + _system_settings_set_value_string = _system_settings_set_value_string_ptr + .asFunction<_dart_system_settings_set_value_string>(); + + /// @brief Gets the system settings value associated with the given key as a string. + /// @since_tizen 2.3 + /// @remarks You must release @a value using free(). When the feature related to the @a key is not supported on the device, #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED will be returned. + /// @param[in] key The key name of the system settings + /// @param[out] value The current system settings value of the given key + /// @return 0 on success, otherwise a negative error value + /// @retval #SYSTEM_SETTINGS_ERROR_NONE Successful + /// @retval #SYSTEM_SETTINGS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYSTEM_SETTINGS_ERROR_IO_ERROR Internal I/O error + /// @retval #SYSTEM_SETTINGS_ERROR_PERMISSION_DENIED Permission violation error + /// @retval #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED The related feature is not supported on the device + /// @warning %http://tizen.org/privilege/systemsettings (public level privilege) MUST NOT be declared to use this API since 2.3.1. + int system_settings_get_value_string( + int key, + ffi.Pointer> value, + ) { + return _system_settings_get_value_string( + key, + value, + ); + } + + late final _system_settings_get_value_string_ptr = + _lookup>( + 'system_settings_get_value_string'); + late final _dart_system_settings_get_value_string + _system_settings_get_value_string = _system_settings_get_value_string_ptr + .asFunction<_dart_system_settings_get_value_string>(); + + /// @brief Registers a change event callback for the given system settings key. + /// @since_tizen 2.3 + /// @remarks #SYSTEM_SETTINGS_KEY_DEFAULT_FONT_TYPE is not available for set_changed_cb. When the feature related to the @a key is not supported on the device, #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED will be returned. + /// @param[in] key The key name of the system settings + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #SYSTEM_SETTINGS_ERROR_NONE Successful + /// @retval #SYSTEM_SETTINGS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYSTEM_SETTINGS_ERROR_PERMISSION_DENIED Permission violation error + /// @retval #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED The related feature is not supported on the device + /// @post system_settings_changed_cb() will be invoked. + /// + /// @see system_settings_unset_changed_cb() + /// @see system_settings_changed_cb() + /// @warning %http://tizen.org/privilege/systemsettings (public level privilege) MUST NOT be declared to use this API since 2.3.1. + int system_settings_set_changed_cb( + int key, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _system_settings_set_changed_cb( + key, + callback, + user_data, + ); + } + + late final _system_settings_set_changed_cb_ptr = + _lookup>( + 'system_settings_set_changed_cb'); + late final _dart_system_settings_set_changed_cb + _system_settings_set_changed_cb = _system_settings_set_changed_cb_ptr + .asFunction<_dart_system_settings_set_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen 2.3 + /// @remarks #SYSTEM_SETTINGS_KEY_DEFAULT_FONT_TYPE is not available for set_changed_cb. When the feature related to the @a key is not supported on the device, #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED will be returned. + /// @param[in] key The key name of the system settings + /// @return 0 on success, otherwise a negative error value + /// @retval #SYSTEM_SETTINGS_ERROR_NONE Successful + /// @retval #SYSTEM_SETTINGS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYSTEM_SETTINGS_ERROR_PERMISSION_DENIED Permission violation error + /// @retval #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED The related feature is not supported on the device + /// + /// @see system_settings_set_changed_cb() + /// @warning %http://tizen.org/privilege/systemsettings (public level privilege) MUST NOT be declared to use this API since 2.3.1. + int system_settings_unset_changed_cb( + int key, + ) { + return _system_settings_unset_changed_cb( + key, + ); + } + + late final _system_settings_unset_changed_cb_ptr = + _lookup>( + 'system_settings_unset_changed_cb'); + late final _dart_system_settings_unset_changed_cb + _system_settings_unset_changed_cb = _system_settings_unset_changed_cb_ptr + .asFunction<_dart_system_settings_unset_changed_cb>(); + + /// @platform + /// @brief Iterate the system settings value associated with the given key as a string type. + /// @since_tizen 3.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/systemsettings.admin + /// @remarks When the feature related to the @a key is not supported on the device, #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED will be returned. + /// @param[in] key The key name of the system settings + /// @param[in] callback The callback-function name for iteration + /// @param[in] user_data The user data passed from caller-side + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SYSTEM_SETTINGS_ERROR_NONE Successful + /// @retval #SYSTEM_SETTINGS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYSTEM_SETTINGS_ERROR_IO_ERROR Internal I/O error + /// @retval #SYSTEM_SETTINGS_ERROR_PERMISSION_DENIED Permission violation error + /// @retval #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED The related feature is not supported on the device + int system_settings_foreach_value_string( + int key, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _system_settings_foreach_value_string( + key, + callback, + user_data, + ); + } + + late final _system_settings_foreach_value_string_ptr = + _lookup>( + 'system_settings_foreach_value_string'); + late final _dart_system_settings_foreach_value_string + _system_settings_foreach_value_string = + _system_settings_foreach_value_string_ptr + .asFunction<_dart_system_settings_foreach_value_string>(); + + /// @platform + /// @brief Adds the system settings value associated with the given key as a string type if it supports List iteration. + /// @since_tizen 3.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/systemsettings.admin + /// @remarks When the feature related to the @a key is not supported on the device, #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED will be returned. + /// @param[in] key The key name of the system settings + /// @param[in] value string typed value to be appended + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SYSTEM_SETTINGS_ERROR_NONE Successful + /// @retval #SYSTEM_SETTINGS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYSTEM_SETTINGS_ERROR_IO_ERROR Internal I/O error + /// @retval #SYSTEM_SETTINGS_ERROR_PERMISSION_DENIED Permission violation error + /// @retval #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED The related feature is not supported on the device + int system_settings_add_value_string( + int key, + ffi.Pointer value, + ) { + return _system_settings_add_value_string( + key, + value, + ); + } + + late final _system_settings_add_value_string_ptr = + _lookup>( + 'system_settings_add_value_string'); + late final _dart_system_settings_add_value_string + _system_settings_add_value_string = _system_settings_add_value_string_ptr + .asFunction<_dart_system_settings_add_value_string>(); + + /// @platform + /// @brief Delete the system settings value associated with the given key as an string type if it supports List iteration. + /// @since_tizen 3.0 + /// @privlevel platform + /// @privilege %http://tizen.org/privilege/systemsettings.admin + /// @remarks When the feature related to the @a key is not supported on the device, #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED will be returned. + /// @param[in] key The key name of the system settings + /// @param[in] value string typed value to be removed + /// @return @c 0 on success, otherwise a negative error value + /// @retval #SYSTEM_SETTINGS_ERROR_NONE Successful + /// @retval #SYSTEM_SETTINGS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYSTEM_SETTINGS_ERROR_IO_ERROR Internal I/O error + /// @retval #SYSTEM_SETTINGS_ERROR_PERMISSION_DENIED Permission violation error + /// @retval #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED The related feature is not supported on the device + int system_settings_delete_value_string( + int key, + ffi.Pointer value, + ) { + return _system_settings_delete_value_string( + key, + value, + ); + } + + late final _system_settings_delete_value_string_ptr = + _lookup>( + 'system_settings_delete_value_string'); + late final _dart_system_settings_delete_value_string + _system_settings_delete_value_string = + _system_settings_delete_value_string_ptr + .asFunction<_dart_system_settings_delete_value_string>(); + + /// @brief Adds a change event callback for the given system settings key. + /// @details The difference between this function and system_settings_set_changed_cb() is that system_settings_set_changed_cb() can set only one callback for a given key, while system_settings_add_changed_cb() can set multiple callbacks for a given key. + /// @since_tizen 4.0 + /// @remarks The @a key cannot be #SYSTEM_SETTINGS_KEY_DEFAULT_FONT_TYPE. When the feature related to the @a key is not supported on the device, #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED will be returned. + /// @param[in] key The key name of the system settings + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return 0 on success, otherwise a negative error value + /// @retval #SYSTEM_SETTINGS_ERROR_NONE Successful + /// @retval #SYSTEM_SETTINGS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED The related feature is not supported on the device + /// @post system_settings_changed_cb() will be invoked. + /// + /// @see system_settings_remove_changed_cb() + /// @see system_settings_changed_cb() + int system_settings_add_changed_cb( + int key, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _system_settings_add_changed_cb( + key, + callback, + user_data, + ); + } + + late final _system_settings_add_changed_cb_ptr = + _lookup>( + 'system_settings_add_changed_cb'); + late final _dart_system_settings_add_changed_cb + _system_settings_add_changed_cb = _system_settings_add_changed_cb_ptr + .asFunction<_dart_system_settings_add_changed_cb>(); + + /// @brief Removes a change event callback function. + /// @details The difference between this function and system_settings_unset_changed_cb() is that system_settings_unset_changed_cb() unsets the callback set with system_settings_set_changed_cb(), while system_settings_remove_changed_cb() removes callbacks added with system_settings_add_changed_cb() + /// @since_tizen 4.0 + /// @remarks The @a key cannot be #SYSTEM_SETTINGS_KEY_DEFAULT_FONT_TYPE. When the feature related to the @a key is not supported on the device, #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED will be returned. + /// @param[in] key The key name of the system settings + /// @param[in] callback The callback function to be removed + /// @return 0 on success, otherwise a negative error value + /// @retval #SYSTEM_SETTINGS_ERROR_NONE Successful + /// @retval #SYSTEM_SETTINGS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED The related feature is not supported on the device + /// + /// @see system_settings_add_changed_cb() + int system_settings_remove_changed_cb( + int key, + ffi.Pointer> callback, + ) { + return _system_settings_remove_changed_cb( + key, + callback, + ); + } + + late final _system_settings_remove_changed_cb_ptr = + _lookup>( + 'system_settings_remove_changed_cb'); + late final _dart_system_settings_remove_changed_cb + _system_settings_remove_changed_cb = + _system_settings_remove_changed_cb_ptr + .asFunction<_dart_system_settings_remove_changed_cb>(); + + /// @brief Writes a trace event to indicate that a synchronous event has begun. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] name The name of event (optionally containing format specifiers) + /// @exception TRACE_ERROR_NONE Success + /// @exception TRACE_ERROR_IO_ERROR I/O error + /// @see trace_end() + void trace_begin( + ffi.Pointer name, + ) { + return _trace_begin( + name, + ); + } + + late final _trace_begin_ptr = + _lookup>('trace_begin'); + late final _dart_trace_begin _trace_begin = + _trace_begin_ptr.asFunction<_dart_trace_begin>(); + + /// @brief Writes a trace event to indicate that the synchronous event has ended. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks trace_end() ends the most recently called trace_begin(). + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @exception TRACE_ERROR_NONE Success + /// @exception TRACE_ERROR_IO_ERROR I/O error + /// @see trace_begin() + void trace_end() { + return _trace_end(); + } + + late final _trace_end_ptr = + _lookup>('trace_end'); + late final _dart_trace_end _trace_end = + _trace_end_ptr.asFunction<_dart_trace_end>(); + + /// @brief Writes a trace event to indicate that an asynchronous event has begun. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] cookie An unique identifier for distinguishing simultaneous events + /// @param[in] name The name of event (optionally containing format specifiers) + /// @exception TRACE_ERROR_NONE Success + /// @exception TRACE_ERROR_IO_ERROR I/O error + /// @see trace_async_end() + void trace_async_begin( + int cookie, + ffi.Pointer name, + ) { + return _trace_async_begin( + cookie, + name, + ); + } + + late final _trace_async_begin_ptr = + _lookup>('trace_async_begin'); + late final _dart_trace_async_begin _trace_async_begin = + _trace_async_begin_ptr.asFunction<_dart_trace_async_begin>(); + + /// @brief Writes a trace event to indicate that the asynchronous event has ended. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks trace_async_end() ends matched trace_async_begin() which has same cookie and name. + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] cookie An unique identifier for distinguishing simultaneous events + /// @param[in] name The name of event (optionally containing format specifiers) + /// @exception TRACE_ERROR_NONE Success + /// @exception TRACE_ERROR_IO_ERROR I/O error + /// @see trace_async_begin() + void trace_async_end( + int cookie, + ffi.Pointer name, + ) { + return _trace_async_end( + cookie, + name, + ); + } + + late final _trace_async_end_ptr = + _lookup>('trace_async_end'); + late final _dart_trace_async_end _trace_async_end = + _trace_async_end_ptr.asFunction<_dart_trace_async_end>(); + + /// @brief Writes a trace event to track change of integer counter + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif + /// @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section. + /// @param[in] value The counter value + /// @param[in] name The name of event (optionally containing format specifiers) + /// @exception TRACE_ERROR_NONE Success + /// @exception TRACE_ERROR_IO_ERROR I/O error + void trace_update_counter( + int value, + ffi.Pointer name, + ) { + return _trace_update_counter( + value, + name, + ); + } + + late final _trace_update_counter_ptr = + _lookup>( + 'trace_update_counter'); + late final _dart_trace_update_counter _trace_update_counter = + _trace_update_counter_ptr.asFunction<_dart_trace_update_counter>(); + + /// @brief Sets a callback function to be invoked when the telephony state changes. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks An application should have the privilege corresponding to each notification ID. \n + /// Please see the #telephony_noti_e to know the privilege. \n + /// If an application has no proper privilege, callback will not be invoked although API returns success. + /// + /// @param[in] handle The handle to use the telephony API + /// @param[in] noti_id The notification ID to set the callback + /// @param[in] cb The callback to be invoked when the telephony state changes + /// @param[in] user_data The user data passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @post telephony_noti_cb() will be invoked. + /// + /// @see telephony_unset_noti_cb() + int telephony_set_noti_cb( + ffi.Pointer handle, + int noti_id, + ffi.Pointer> cb, + ffi.Pointer user_data, + ) { + return _telephony_set_noti_cb( + handle, + noti_id, + cb, + user_data, + ); + } + + late final _telephony_set_noti_cb_ptr = + _lookup>( + 'telephony_set_noti_cb'); + late final _dart_telephony_set_noti_cb _telephony_set_noti_cb = + _telephony_set_noti_cb_ptr.asFunction<_dart_telephony_set_noti_cb>(); + + /// @brief Unsets a callback function. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] handle The handle to use the telephony API + /// @param[in] noti_id The notification ID to unset a callback + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_set_noti_cb() + int telephony_unset_noti_cb( + ffi.Pointer handle, + int noti_id, + ) { + return _telephony_unset_noti_cb( + handle, + noti_id, + ); + } + + late final _telephony_unset_noti_cb_ptr = + _lookup>( + 'telephony_unset_noti_cb'); + late final _dart_telephony_unset_noti_cb _telephony_unset_noti_cb = + _telephony_unset_noti_cb_ptr.asFunction<_dart_telephony_unset_noti_cb>(); + + /// @brief Acquires the list of available handles to use the telephony API. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @remarks You will get two handles in case of dual SIM device. \n + /// In this case, handle[0] means Primary SIM and handle[1] means Secondary SIM. + /// + /// @param[out] list The list contains the number of + /// available handles and array of handles + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_deinit() + int telephony_init( + ffi.Pointer list, + ) { + return _telephony_init( + list, + ); + } + + late final _telephony_init_ptr = + _lookup>('telephony_init'); + late final _dart_telephony_init _telephony_init = + _telephony_init_ptr.asFunction<_dart_telephony_init>(); + + /// @brief Deinitializes the telephony handle list. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// + /// @param[in] list The handle list to be deinitialized + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_init() + int telephony_deinit( + ffi.Pointer list, + ) { + return _telephony_deinit( + list, + ); + } + + late final _telephony_deinit_ptr = + _lookup>('telephony_deinit'); + late final _dart_telephony_deinit _telephony_deinit = + _telephony_deinit_ptr.asFunction<_dart_telephony_deinit>(); + + /// @brief Acquires the telephony state value. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[out] state The state value of telephony + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_set_state_changed_cb() + /// @see telephony_unset_state_changed_cb() + int telephony_get_state( + ffi.Pointer state, + ) { + return _telephony_get_state( + state, + ); + } + + late final _telephony_get_state_ptr = + _lookup>( + 'telephony_get_state'); + late final _dart_telephony_get_state _telephony_get_state = + _telephony_get_state_ptr.asFunction<_dart_telephony_get_state>(); + + /// @brief Sets a callback function to be invoked when the telephony state changes. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] callback The callback to be invoked when the telephony state changes + /// @param[in] user_data The user data passed to the callback function + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @post telephony_state_changed_cb() will be invoked. + /// + /// @see telephony_unset_state_changed_cb() + int telephony_set_state_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _telephony_set_state_changed_cb( + callback, + user_data, + ); + } + + late final _telephony_set_state_changed_cb_ptr = + _lookup>( + 'telephony_set_state_changed_cb'); + late final _dart_telephony_set_state_changed_cb + _telephony_set_state_changed_cb = _telephony_set_state_changed_cb_ptr + .asFunction<_dart_telephony_set_state_changed_cb>(); + + /// @brief Unsets a telephony state callback function. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] callback The callback to unset when the telephony state changes + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_set_state_changed_cb() + int telephony_unset_state_changed_cb( + ffi.Pointer> callback, + ) { + return _telephony_unset_state_changed_cb( + callback, + ); + } + + late final _telephony_unset_state_changed_cb_ptr = + _lookup>( + 'telephony_unset_state_changed_cb'); + late final _dart_telephony_unset_state_changed_cb + _telephony_unset_state_changed_cb = _telephony_unset_state_changed_cb_ptr + .asFunction<_dart_telephony_unset_state_changed_cb>(); + + /// @deprecated Deprecated Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. Use #telephony_call_get_status instead. + /// + /// @brief Gets the voice call state of the telephony service. + /// @details Determines if the voice call is connecting, connected, or idle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks When you are dialing a number or a new voice call is ringing, + /// the state of the voice call is #TELEPHONY_CALL_STATE_CONNECTING. + /// When a new voice call is connecting while another voice call is already connected, + /// the state of the voice call is #TELEPHONY_CALL_STATE_CONNECTING as well. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] call_state The current state of the voice call + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_call_get_voice_call_state( + ffi.Pointer handle, + ffi.Pointer call_state, + ) { + return _telephony_call_get_voice_call_state( + handle, + call_state, + ); + } + + late final _telephony_call_get_voice_call_state_ptr = + _lookup>( + 'telephony_call_get_voice_call_state'); + late final _dart_telephony_call_get_voice_call_state + _telephony_call_get_voice_call_state = + _telephony_call_get_voice_call_state_ptr + .asFunction<_dart_telephony_call_get_voice_call_state>(); + + /// @deprecated Deprecated Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. Use #telephony_call_get_status instead. + /// + /// @brief Gets the video call state of the telephony service. + /// @details Determines if the video call is connecting, connected, or idle. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks When you are dialing a number or a new video call is ringing, + /// the state of the video call is #TELEPHONY_CALL_STATE_CONNECTING. + /// If a video call is connected, then the state of any other call cannot be + /// #TELEPHONY_CALL_STATE_CONNECTING and #TELEPHONY_CALL_STATE_CONNECTED. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] call_state The current state of the video call + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_call_get_video_call_state( + ffi.Pointer handle, + ffi.Pointer call_state, + ) { + return _telephony_call_get_video_call_state( + handle, + call_state, + ); + } + + late final _telephony_call_get_video_call_state_ptr = + _lookup>( + 'telephony_call_get_video_call_state'); + late final _dart_telephony_call_get_video_call_state + _telephony_call_get_video_call_state = + _telephony_call_get_video_call_state_ptr + .asFunction<_dart_telephony_call_get_video_call_state>(); + + /// @brief Gets the current value for the preferred voice call subscription. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] call_sub The currently set preferred call subscription value. (telephony_call_preferred_voice_subs_e) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_call_get_preferred_voice_subscription( + ffi.Pointer handle, + ffi.Pointer call_sub, + ) { + return _telephony_call_get_preferred_voice_subscription( + handle, + call_sub, + ); + } + + late final _telephony_call_get_preferred_voice_subscription_ptr = _lookup< + ffi.NativeFunction< + _c_telephony_call_get_preferred_voice_subscription>>( + 'telephony_call_get_preferred_voice_subscription'); + late final _dart_telephony_call_get_preferred_voice_subscription + _telephony_call_get_preferred_voice_subscription = + _telephony_call_get_preferred_voice_subscription_ptr + .asFunction<_dart_telephony_call_get_preferred_voice_subscription>(); + + /// @brief Gets the list of the current call. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks You must release @c call_list using telephony_call_release_call_list(). + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] count Count of the existing calls + /// @param[out] call_list List of call information for existing calls + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_call_get_call_list( + ffi.Pointer handle, + ffi.Pointer count, + ffi.Pointer>> call_list, + ) { + return _telephony_call_get_call_list( + handle, + count, + call_list, + ); + } + + late final _telephony_call_get_call_list_ptr = + _lookup>( + 'telephony_call_get_call_list'); + late final _dart_telephony_call_get_call_list _telephony_call_get_call_list = + _telephony_call_get_call_list_ptr + .asFunction<_dart_telephony_call_get_call_list>(); + + /// @brief Releases the list allocated from #telephony_call_get_call_list(). + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] count The count of the calls from #telephony_call_get_call_list() + /// @param[in] call_list The handle from #telephony_call_get_call_list() + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The call list should be validated from #telephony_call_get_call_list(). + int telephony_call_release_call_list( + int count, + ffi.Pointer>> call_list, + ) { + return _telephony_call_release_call_list( + count, + call_list, + ); + } + + late final _telephony_call_release_call_list_ptr = + _lookup>( + 'telephony_call_release_call_list'); + late final _dart_telephony_call_release_call_list + _telephony_call_release_call_list = _telephony_call_release_call_list_ptr + .asFunction<_dart_telephony_call_release_call_list>(); + + /// @brief Gets the call handle ID. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] call_handle The handle from #telephony_call_get_call_list() + /// @param[out] handle_id The ID of the call handle + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The call handle should be obtained from #telephony_call_get_call_list(). + /// @post The call list should be released by using #telephony_call_release_call_list(). + int telephony_call_get_handle_id( + ffi.Pointer call_handle, + ffi.Pointer handle_id, + ) { + return _telephony_call_get_handle_id( + call_handle, + handle_id, + ); + } + + late final _telephony_call_get_handle_id_ptr = + _lookup>( + 'telephony_call_get_handle_id'); + late final _dart_telephony_call_get_handle_id _telephony_call_get_handle_id = + _telephony_call_get_handle_id_ptr + .asFunction<_dart_telephony_call_get_handle_id>(); + + /// @brief Gets the call number. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @remarks You must release @c number using free() on success case. + /// + /// @param[in] call_handle The handle from #telephony_call_get_call_list() + /// @param[out] number The number of the call + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The call handle should be obtained from #telephony_call_get_call_list(). + /// @post The call list should be released by using #telephony_call_release_call_list(). + int telephony_call_get_number( + ffi.Pointer call_handle, + ffi.Pointer> number, + ) { + return _telephony_call_get_number( + call_handle, + number, + ); + } + + late final _telephony_call_get_number_ptr = + _lookup>( + 'telephony_call_get_number'); + late final _dart_telephony_call_get_number _telephony_call_get_number = + _telephony_call_get_number_ptr + .asFunction<_dart_telephony_call_get_number>(); + + /// @brief Gets the call type. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] call_handle The handle from #telephony_call_get_call_list() + /// @param[out] type The type of the call (#telephony_call_type_e) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The call handle should be obtained from #telephony_call_get_call_list(). + /// @post The call list should be released by using #telephony_call_release_call_list(). + int telephony_call_get_type( + ffi.Pointer call_handle, + ffi.Pointer type, + ) { + return _telephony_call_get_type( + call_handle, + type, + ); + } + + late final _telephony_call_get_type_ptr = + _lookup>( + 'telephony_call_get_type'); + late final _dart_telephony_call_get_type _telephony_call_get_type = + _telephony_call_get_type_ptr.asFunction<_dart_telephony_call_get_type>(); + + /// @brief Gets the call status. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] call_handle The handle from #telephony_call_get_call_list() + /// @param[out] status The status of the call (#telephony_call_status_e) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The call handle should be obtained from #telephony_call_get_call_list(). + /// @post The call list should be released by using #telephony_call_release_call_list(). + int telephony_call_get_status( + ffi.Pointer call_handle, + ffi.Pointer status, + ) { + return _telephony_call_get_status( + call_handle, + status, + ); + } + + late final _telephony_call_get_status_ptr = + _lookup>( + 'telephony_call_get_status'); + late final _dart_telephony_call_get_status _telephony_call_get_status = + _telephony_call_get_status_ptr + .asFunction<_dart_telephony_call_get_status>(); + + /// @brief Gets whether the call is MO(Mobile Originated) call or MT(Mobile Terminated). + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] call_handle The handle from #telephony_call_get_call_list() + /// @param[out] direction The direction of the call (#telephony_call_direction_e) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The call handle should be obtained from #telephony_call_get_call_list(). + /// @post The call list should be released by using #telephony_call_release_call_list(). + int telephony_call_get_direction( + ffi.Pointer call_handle, + ffi.Pointer direction, + ) { + return _telephony_call_get_direction( + call_handle, + direction, + ); + } + + late final _telephony_call_get_direction_ptr = + _lookup>( + 'telephony_call_get_direction'); + late final _dart_telephony_call_get_direction _telephony_call_get_direction = + _telephony_call_get_direction_ptr + .asFunction<_dart_telephony_call_get_direction>(); + + /// @brief Gets whether the call is conference call or not. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// + /// @param[in] call_handle The handle from #telephony_call_get_call_list() + /// @param[out] conference_status The value whether the call is conference call or not + /// (true: Conference call, false: Single call) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// + /// @pre The call handle should be obtained from #telephony_call_get_call_list(). + /// @post The call list should be released by using #telephony_call_release_call_list(). + int telephony_call_get_conference_status( + ffi.Pointer call_handle, + ffi.Pointer conference_status, + ) { + return _telephony_call_get_conference_status( + call_handle, + conference_status, + ); + } + + late final _telephony_call_get_conference_status_ptr = + _lookup>( + 'telephony_call_get_conference_status'); + late final _dart_telephony_call_get_conference_status + _telephony_call_get_conference_status = + _telephony_call_get_conference_status_ptr + .asFunction<_dart_telephony_call_get_conference_status>(); + + /// @brief Gets the Integrated Circuit Card IDentification (ICC-ID). + /// @details The Integrated Circuit Card Identification number internationally identifies SIM cards. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks You must release @c icc_id using free() on success case. + /// @remarks Since 5.5, privilege level and return type are changed.
+ /// The following table shows the impact of changes: + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + ///
Version 5.0 and lower 5.5 and higher Remarks
Privilegehttp://tizen.org/privilege/telephonyhttp://tizen.org/privilege/securesysteminfoThe required privilege is changed.
Privilege levelPublicPartnerThe application having partner level privilege can use this API
Error#TELEPHONY_ERROR_NONE#TELEPHONY_ERROR_PERMISSION_DENIED If the application doesn't have the required privilege, the error is returned. + ///
+ /// @remarks The applications developed on Tizen 5.0 and lower version having only http://tizen.org/privilege/telephony privilege should check 'permission denied' error. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] icc_id The Integrated Circuit Card Identification + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// @retval #TELEPHONY_ERROR_SIM_NOT_AVAILABLE SIM is not available + /// + /// @pre The SIM state must be #TELEPHONY_SIM_STATE_AVAILABLE. + /// + /// @see telephony_sim_get_state() + int telephony_sim_get_icc_id( + ffi.Pointer handle, + ffi.Pointer> icc_id, + ) { + return _telephony_sim_get_icc_id( + handle, + icc_id, + ); + } + + late final _telephony_sim_get_icc_id_ptr = + _lookup>( + 'telephony_sim_get_icc_id'); + late final _dart_telephony_sim_get_icc_id _telephony_sim_get_icc_id = + _telephony_sim_get_icc_id_ptr + .asFunction<_dart_telephony_sim_get_icc_id>(); + + /// @brief Gets the SIM Operator (MCC [3 digits] + MNC [2~3 digits]). + /// @details The Operator is embedded in the SIM card. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks You must release @c sim_operator using free() on success case. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] sim_operator The SIM Operator + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// @retval #TELEPHONY_ERROR_SIM_NOT_AVAILABLE SIM is not available + /// + /// @pre The SIM state must be #TELEPHONY_SIM_STATE_AVAILABLE. + /// + /// @see telephony_sim_get_state() + int telephony_sim_get_operator( + ffi.Pointer handle, + ffi.Pointer> sim_operator, + ) { + return _telephony_sim_get_operator( + handle, + sim_operator, + ); + } + + late final _telephony_sim_get_operator_ptr = + _lookup>( + 'telephony_sim_get_operator'); + late final _dart_telephony_sim_get_operator _telephony_sim_get_operator = + _telephony_sim_get_operator_ptr + .asFunction<_dart_telephony_sim_get_operator>(); + + /// @brief Gets the Mobile Subscription Identification Number (MSIN [9~10 digits]) of the SIM provider. + /// @details This function gets Mobile Subscription Identification Number embedded in the SIM card. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks You must release @c msin using free() on success case. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] msin The Mobile Subscription Identification Number + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// @retval #TELEPHONY_ERROR_SIM_NOT_AVAILABLE SIM is not available + /// + /// @pre The SIM state must be #TELEPHONY_SIM_STATE_AVAILABLE. + /// + /// @see telephony_sim_get_state() + int telephony_sim_get_msin( + ffi.Pointer handle, + ffi.Pointer> msin, + ) { + return _telephony_sim_get_msin( + handle, + msin, + ); + } + + late final _telephony_sim_get_msin_ptr = + _lookup>( + 'telephony_sim_get_msin'); + late final _dart_telephony_sim_get_msin _telephony_sim_get_msin = + _telephony_sim_get_msin_ptr.asFunction<_dart_telephony_sim_get_msin>(); + + /// @brief Gets the Service Provider Name (SPN) of the SIM card. + /// @details This function gets Service Provider Name embedded in the SIM card. + /// If this value is not stored in SIM card, @c NULL will be returned. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks You must release @c spn using free() on success case. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] spn The Service Provider Name + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// @retval #TELEPHONY_ERROR_SIM_NOT_AVAILABLE SIM is not available + /// + /// @pre The SIM state must be #TELEPHONY_SIM_STATE_AVAILABLE. + /// + /// @see telephony_sim_get_state() + int telephony_sim_get_spn( + ffi.Pointer handle, + ffi.Pointer> spn, + ) { + return _telephony_sim_get_spn( + handle, + spn, + ); + } + + late final _telephony_sim_get_spn_ptr = + _lookup>( + 'telephony_sim_get_spn'); + late final _dart_telephony_sim_get_spn _telephony_sim_get_spn = + _telephony_sim_get_spn_ptr.asFunction<_dart_telephony_sim_get_spn>(); + + /// @brief Checks whether the current SIM card is different from the previous SIM card. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] is_changed @c true if the current SIM card is different from the previous SIM card, + /// otherwise @c false if the SIM card is not changed + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// @retval #TELEPHONY_ERROR_SIM_NOT_AVAILABLE SIM is not available + /// + /// @pre The SIM state must be #TELEPHONY_SIM_STATE_AVAILABLE. + /// + /// @see telephony_sim_get_state() + int telephony_sim_is_changed( + ffi.Pointer handle, + ffi.Pointer is_changed, + ) { + return _telephony_sim_is_changed( + handle, + is_changed, + ); + } + + late final _telephony_sim_is_changed_ptr = + _lookup>( + 'telephony_sim_is_changed'); + late final _dart_telephony_sim_is_changed _telephony_sim_is_changed = + _telephony_sim_is_changed_ptr + .asFunction<_dart_telephony_sim_is_changed>(); + + /// @brief Gets the state of the SIM. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] sim_state The current state of the SIM + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_sim_get_state( + ffi.Pointer handle, + ffi.Pointer sim_state, + ) { + return _telephony_sim_get_state( + handle, + sim_state, + ); + } + + late final _telephony_sim_get_state_ptr = + _lookup>( + 'telephony_sim_get_state'); + late final _dart_telephony_sim_get_state _telephony_sim_get_state = + _telephony_sim_get_state_ptr.asFunction<_dart_telephony_sim_get_state>(); + + /// @brief Gets the list of application on UICC. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] app_list The masking value for below values + /// #TELEPHONY_SIM_APP_TYPE_SIM 0x01 GSM Application + /// #TELEPHONY_SIM_APP_TYPE_USIM 0x02 USIM Application + /// #TELEPHONY_SIM_APP_TYPE_CSIM 0x04 CSIM Application + /// #TELEPHONY_SIM_APP_TYPE_ISIM 0x08 ISIM Application + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// @retval #TELEPHONY_ERROR_SIM_NOT_AVAILABLE SIM is not available + /// + /// @pre The SIM state must be #TELEPHONY_SIM_STATE_AVAILABLE. + /// + /// @see telephony_sim_get_state() + int telephony_sim_get_application_list( + ffi.Pointer handle, + ffi.Pointer app_list, + ) { + return _telephony_sim_get_application_list( + handle, + app_list, + ); + } + + late final _telephony_sim_get_application_list_ptr = + _lookup>( + 'telephony_sim_get_application_list'); + late final _dart_telephony_sim_get_application_list + _telephony_sim_get_application_list = + _telephony_sim_get_application_list_ptr + .asFunction<_dart_telephony_sim_get_application_list>(); + + /// @brief Gets the SIM card subscriber number. + /// @details This function gets subscriber number embedded in the SIM card. + /// This value contains MSISDN related to the subscriber. + /// If this value is not stored in SIM card, @c NULL will be returned. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks You must release @c subscriber_number using free() on success case. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] subscriber_number The subscriber number in the SIM + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// @retval #TELEPHONY_ERROR_SIM_NOT_AVAILABLE SIM is not available + /// + /// @pre The SIM state must be #TELEPHONY_SIM_STATE_AVAILABLE. + /// + /// @see telephony_sim_get_state() + int telephony_sim_get_subscriber_number( + ffi.Pointer handle, + ffi.Pointer> subscriber_number, + ) { + return _telephony_sim_get_subscriber_number( + handle, + subscriber_number, + ); + } + + late final _telephony_sim_get_subscriber_number_ptr = + _lookup>( + 'telephony_sim_get_subscriber_number'); + late final _dart_telephony_sim_get_subscriber_number + _telephony_sim_get_subscriber_number = + _telephony_sim_get_subscriber_number_ptr + .asFunction<_dart_telephony_sim_get_subscriber_number>(); + + /// @brief Gets the Subscriber ID. + /// @details This function gets subscriber ID encoded. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks You must release @c subscriber_id using free() on success case. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] subscriber_id The subscriber ID + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// @retval #TELEPHONY_ERROR_SIM_NOT_AVAILABLE SIM is not available + /// + /// @pre The SIM state must be #TELEPHONY_SIM_STATE_AVAILABLE. + /// + /// @see telephony_sim_get_state() + int telephony_sim_get_subscriber_id( + ffi.Pointer handle, + ffi.Pointer> subscriber_id, + ) { + return _telephony_sim_get_subscriber_id( + handle, + subscriber_id, + ); + } + + late final _telephony_sim_get_subscriber_id_ptr = + _lookup>( + 'telephony_sim_get_subscriber_id'); + late final _dart_telephony_sim_get_subscriber_id + _telephony_sim_get_subscriber_id = _telephony_sim_get_subscriber_id_ptr + .asFunction<_dart_telephony_sim_get_subscriber_id>(); + + /// @brief Gets the lock state of the SIM. + /// @details This function gets SIM card lock state. + /// If SIM state is #TELEPHONY_SIM_STATE_LOCKED, you can use this function to retrieve lock state. + /// + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] lock_state The current lock state of the SIM + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @pre The SIM state must be #TELEPHONY_SIM_STATE_LOCKED. + /// + /// @see telephony_sim_get_state() + int telephony_sim_get_lock_state( + ffi.Pointer handle, + ffi.Pointer lock_state, + ) { + return _telephony_sim_get_lock_state( + handle, + lock_state, + ); + } + + late final _telephony_sim_get_lock_state_ptr = + _lookup>( + 'telephony_sim_get_lock_state'); + late final _dart_telephony_sim_get_lock_state _telephony_sim_get_lock_state = + _telephony_sim_get_lock_state_ptr + .asFunction<_dart_telephony_sim_get_lock_state>(); + + /// @brief Gets the GID1 (Group Identifier Level 1). + /// @details This function gets Group Identifier Level 1(GID1) embedded in the SIM card. + /// If this value is not stored in SIM card, @c NULL will be returned. + /// + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks You must release @c gid1 using free() on success case. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] gid1 The GID1 + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// @retval #TELEPHONY_ERROR_SIM_NOT_AVAILABLE SIM is not available + /// + /// @pre The SIM state must be #TELEPHONY_SIM_STATE_AVAILABLE. + /// + /// @see telephony_sim_get_state() + int telephony_sim_get_group_id1( + ffi.Pointer handle, + ffi.Pointer> gid1, + ) { + return _telephony_sim_get_group_id1( + handle, + gid1, + ); + } + + late final _telephony_sim_get_group_id1_ptr = + _lookup>( + 'telephony_sim_get_group_id1'); + late final _dart_telephony_sim_get_group_id1 _telephony_sim_get_group_id1 = + _telephony_sim_get_group_id1_ptr + .asFunction<_dart_telephony_sim_get_group_id1>(); + + /// @brief Gets the call forwarding indicator state of the SIM. + /// @details If the state is @c true, incoming call will be forwarded to the selected number. + /// @c state indicates the CFU (Call Forwarding Unconditional) indicator status - Voice. + /// (3GPP TS 31.102 4.2.64 EF CFIS) + /// + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] state The value whether incoming call will be forwarded or not. + /// (@c true: forwarded, @c false: not forwarded) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// @retval #TELEPHONY_ERROR_SIM_NOT_AVAILABLE SIM is not available + /// + /// @pre The SIM state must be #TELEPHONY_SIM_STATE_AVAILABLE. + /// + /// @see telephony_sim_get_state() + int telephony_sim_get_call_forwarding_indicator_state( + ffi.Pointer handle, + ffi.Pointer state, + ) { + return _telephony_sim_get_call_forwarding_indicator_state( + handle, + state, + ); + } + + late final _telephony_sim_get_call_forwarding_indicator_state_ptr = _lookup< + ffi.NativeFunction< + _c_telephony_sim_get_call_forwarding_indicator_state>>( + 'telephony_sim_get_call_forwarding_indicator_state'); + late final _dart_telephony_sim_get_call_forwarding_indicator_state + _telephony_sim_get_call_forwarding_indicator_state = + _telephony_sim_get_call_forwarding_indicator_state_ptr.asFunction< + _dart_telephony_sim_get_call_forwarding_indicator_state>(); + + /// @brief Gets the LAC (Location Area Code) of the current location. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location.coarse + /// + /// @remarks This API can be used in GSM / WCDMA network. @n + /// http://tizen.org/privilege/location.coarse privilege is required to use this API since 3.0. @n + /// http://tizen.org/privilege/telephony privilege is no longer required since 3.0. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] lac The Location Area Code, @c -1 if unknown + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_network_get_service_state() + /// @see telephony_network_get_type() + int telephony_network_get_lac( + ffi.Pointer handle, + ffi.Pointer lac, + ) { + return _telephony_network_get_lac( + handle, + lac, + ); + } + + late final _telephony_network_get_lac_ptr = + _lookup>( + 'telephony_network_get_lac'); + late final _dart_telephony_network_get_lac _telephony_network_get_lac = + _telephony_network_get_lac_ptr + .asFunction<_dart_telephony_network_get_lac>(); + + /// @brief Gets the cell ID of the current location. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location.coarse + /// + /// @remarks This API can be used in GSM / WCDMA / LTE network. @n + /// http://tizen.org/privilege/location.coarse privilege is required to use this API since 3.0. @n + /// http://tizen.org/privilege/telephony privilege is no longer required since 3.0. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] cell_id The cell identification number, @c -1 if unknown + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_network_get_service_state() + /// @see telephony_network_get_type() + int telephony_network_get_cell_id( + ffi.Pointer handle, + ffi.Pointer cell_id, + ) { + return _telephony_network_get_cell_id( + handle, + cell_id, + ); + } + + late final _telephony_network_get_cell_id_ptr = + _lookup>( + 'telephony_network_get_cell_id'); + late final _dart_telephony_network_get_cell_id + _telephony_network_get_cell_id = _telephony_network_get_cell_id_ptr + .asFunction<_dart_telephony_network_get_cell_id>(); + + /// @brief Gets the RSSI (Received Signal Strength Indicator). + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] rssi The Received Signal Strength Indicator \n + /// Higher the received number, the stronger the signal strength + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_network_get_rssi( + ffi.Pointer handle, + ffi.Pointer rssi, + ) { + return _telephony_network_get_rssi( + handle, + rssi, + ); + } + + late final _telephony_network_get_rssi_ptr = + _lookup>( + 'telephony_network_get_rssi'); + late final _dart_telephony_network_get_rssi _telephony_network_get_rssi = + _telephony_network_get_rssi_ptr + .asFunction<_dart_telephony_network_get_rssi>(); + + /// @brief Gets the roaming state of the current registered network. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] status @c true if roaming, + /// otherwise @c false if not roaming + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_network_get_roaming_status( + ffi.Pointer handle, + ffi.Pointer status, + ) { + return _telephony_network_get_roaming_status( + handle, + status, + ); + } + + late final _telephony_network_get_roaming_status_ptr = + _lookup>( + 'telephony_network_get_roaming_status'); + late final _dart_telephony_network_get_roaming_status + _telephony_network_get_roaming_status = + _telephony_network_get_roaming_status_ptr + .asFunction<_dart_telephony_network_get_roaming_status>(); + + /// @brief Gets the MCC (Mobile Country Code) of the current registered network. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks This API can be used in GSM / WCDMA / LTE network. + /// You must release @c mcc using free() on success case, empty string if unknown. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] mcc The Mobile Country Code (three digits) + /// Mobile Country Code (MCC) identifies the country where the cell is being used + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_network_get_mcc( + ffi.Pointer handle, + ffi.Pointer> mcc, + ) { + return _telephony_network_get_mcc( + handle, + mcc, + ); + } + + late final _telephony_network_get_mcc_ptr = + _lookup>( + 'telephony_network_get_mcc'); + late final _dart_telephony_network_get_mcc _telephony_network_get_mcc = + _telephony_network_get_mcc_ptr + .asFunction<_dart_telephony_network_get_mcc>(); + + /// @brief Gets the MNC (Mobile Network Code) of the current registered network. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks This API can be used in GSM / WCDMA / LTE network. + /// You must release @c mnc using free() on success case, empty string if unknown. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] mnc The Mobile Network Code (three digits) + /// The Mobile Network Code (MNC) identifies the mobile phone operator and network provider + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_network_get_mnc( + ffi.Pointer handle, + ffi.Pointer> mnc, + ) { + return _telephony_network_get_mnc( + handle, + mnc, + ); + } + + late final _telephony_network_get_mnc_ptr = + _lookup>( + 'telephony_network_get_mnc'); + late final _dart_telephony_network_get_mnc _telephony_network_get_mnc = + _telephony_network_get_mnc_ptr + .asFunction<_dart_telephony_network_get_mnc>(); + + /// @brief Gets the name of the current registered network. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks This API can be used in GSM / WCDMA / LTE network. + /// You must release @c network_name using free() on success case. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] network_name The name of the current registered network, empty string if unknown + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_network_get_network_name( + ffi.Pointer handle, + ffi.Pointer> network_name, + ) { + return _telephony_network_get_network_name( + handle, + network_name, + ); + } + + late final _telephony_network_get_network_name_ptr = + _lookup>( + 'telephony_network_get_network_name'); + late final _dart_telephony_network_get_network_name + _telephony_network_get_network_name = + _telephony_network_get_network_name_ptr + .asFunction<_dart_telephony_network_get_network_name>(); + + /// @brief Gets the network service type of the current registered network. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks This API can be used in case network is in service. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] network_type The network service type + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_network_get_service_state() + int telephony_network_get_type( + ffi.Pointer handle, + ffi.Pointer network_type, + ) { + return _telephony_network_get_type( + handle, + network_type, + ); + } + + late final _telephony_network_get_type_ptr = + _lookup>( + 'telephony_network_get_type'); + late final _dart_telephony_network_get_type _telephony_network_get_type = + _telephony_network_get_type_ptr + .asFunction<_dart_telephony_network_get_type>(); + + /// @brief Gets the packet service type of the current registered network. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks This API can be used in HSDPA network. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] ps_type The type of packet service + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_network_get_service_state() + /// @see telephony_network_get_type() + int telephony_network_get_ps_type( + ffi.Pointer handle, + ffi.Pointer ps_type, + ) { + return _telephony_network_get_ps_type( + handle, + ps_type, + ); + } + + late final _telephony_network_get_ps_type_ptr = + _lookup>( + 'telephony_network_get_ps_type'); + late final _dart_telephony_network_get_ps_type + _telephony_network_get_ps_type = _telephony_network_get_ps_type_ptr + .asFunction<_dart_telephony_network_get_ps_type>(); + + /// @brief Gets the network name option of the current registered network. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] network_name_option The network name display option + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_network_get_network_name_option( + ffi.Pointer handle, + ffi.Pointer network_name_option, + ) { + return _telephony_network_get_network_name_option( + handle, + network_name_option, + ); + } + + late final _telephony_network_get_network_name_option_ptr = + _lookup>( + 'telephony_network_get_network_name_option'); + late final _dart_telephony_network_get_network_name_option + _telephony_network_get_network_name_option = + _telephony_network_get_network_name_option_ptr + .asFunction<_dart_telephony_network_get_network_name_option>(); + + /// @brief Gets the current network state of the telephony service. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks To know the state of data network, refer connection API. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] network_service_state The current network state + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_network_get_service_state( + ffi.Pointer handle, + ffi.Pointer network_service_state, + ) { + return _telephony_network_get_service_state( + handle, + network_service_state, + ); + } + + late final _telephony_network_get_service_state_ptr = + _lookup>( + 'telephony_network_get_service_state'); + late final _dart_telephony_network_get_service_state + _telephony_network_get_service_state = + _telephony_network_get_service_state_ptr + .asFunction<_dart_telephony_network_get_service_state>(); + + /// @brief Gets the current default subscription for data service (Packet Switched). + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] default_sub The current default data subscription + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_network_get_default_data_subscription( + ffi.Pointer handle, + ffi.Pointer default_sub, + ) { + return _telephony_network_get_default_data_subscription( + handle, + default_sub, + ); + } + + late final _telephony_network_get_default_data_subscription_ptr = _lookup< + ffi.NativeFunction< + _c_telephony_network_get_default_data_subscription>>( + 'telephony_network_get_default_data_subscription'); + late final _dart_telephony_network_get_default_data_subscription + _telephony_network_get_default_data_subscription = + _telephony_network_get_default_data_subscription_ptr + .asFunction<_dart_telephony_network_get_default_data_subscription>(); + + /// @brief Gets the current default subscription for voice service (Circuit Switched). + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] default_sub The current default voice subscription + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_network_get_default_subscription( + ffi.Pointer handle, + ffi.Pointer default_sub, + ) { + return _telephony_network_get_default_subscription( + handle, + default_sub, + ); + } + + late final _telephony_network_get_default_subscription_ptr = _lookup< + ffi.NativeFunction<_c_telephony_network_get_default_subscription>>( + 'telephony_network_get_default_subscription'); + late final _dart_telephony_network_get_default_subscription + _telephony_network_get_default_subscription = + _telephony_network_get_default_subscription_ptr + .asFunction<_dart_telephony_network_get_default_subscription>(); + + /// @brief Gets the network selection mode. + /// + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] mode The network selection mode + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_network_get_selection_mode( + ffi.Pointer handle, + ffi.Pointer mode, + ) { + return _telephony_network_get_selection_mode( + handle, + mode, + ); + } + + late final _telephony_network_get_selection_mode_ptr = + _lookup>( + 'telephony_network_get_selection_mode'); + late final _dart_telephony_network_get_selection_mode + _telephony_network_get_selection_mode = + _telephony_network_get_selection_mode_ptr + .asFunction<_dart_telephony_network_get_selection_mode>(); + + /// @brief Gets the TAC (Tracking Area Code) of the current location. + /// + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location.coarse + /// + /// @remarks This API can be used in LTE network. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] tac The Tracking Area Code, @c -1 if unknown + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_network_get_service_state() + /// @see telephony_network_get_type() + int telephony_network_get_tac( + ffi.Pointer handle, + ffi.Pointer tac, + ) { + return _telephony_network_get_tac( + handle, + tac, + ); + } + + late final _telephony_network_get_tac_ptr = + _lookup>( + 'telephony_network_get_tac'); + late final _dart_telephony_network_get_tac _telephony_network_get_tac = + _telephony_network_get_tac_ptr + .asFunction<_dart_telephony_network_get_tac>(); + + /// @brief Gets the system ID of the current location. + /// + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location.coarse + /// + /// @remarks This API can be used in CDMA network. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] sid The system ID, @c -1 if unknown + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_network_get_service_state() + /// @see telephony_network_get_type() + int telephony_network_get_system_id( + ffi.Pointer handle, + ffi.Pointer sid, + ) { + return _telephony_network_get_system_id( + handle, + sid, + ); + } + + late final _telephony_network_get_system_id_ptr = + _lookup>( + 'telephony_network_get_system_id'); + late final _dart_telephony_network_get_system_id + _telephony_network_get_system_id = _telephony_network_get_system_id_ptr + .asFunction<_dart_telephony_network_get_system_id>(); + + /// @brief Gets the network ID of the current location. + /// + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location.coarse + /// + /// @remarks This API can be used in CDMA network. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] nid The network ID, @c -1 if unknown + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_network_get_service_state() + /// @see telephony_network_get_type() + int telephony_network_get_network_id( + ffi.Pointer handle, + ffi.Pointer nid, + ) { + return _telephony_network_get_network_id( + handle, + nid, + ); + } + + late final _telephony_network_get_network_id_ptr = + _lookup>( + 'telephony_network_get_network_id'); + late final _dart_telephony_network_get_network_id + _telephony_network_get_network_id = _telephony_network_get_network_id_ptr + .asFunction<_dart_telephony_network_get_network_id>(); + + /// @brief Gets the base station ID of the current location. + /// + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location.coarse + /// + /// @remarks This API can be used in CDMA network. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] bs_id The base station ID, @c -1 if unknown + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_network_get_service_state() + /// @see telephony_network_get_type() + int telephony_network_get_base_station_id( + ffi.Pointer handle, + ffi.Pointer bs_id, + ) { + return _telephony_network_get_base_station_id( + handle, + bs_id, + ); + } + + late final _telephony_network_get_base_station_id_ptr = + _lookup>( + 'telephony_network_get_base_station_id'); + late final _dart_telephony_network_get_base_station_id + _telephony_network_get_base_station_id = + _telephony_network_get_base_station_id_ptr + .asFunction<_dart_telephony_network_get_base_station_id>(); + + /// @brief Gets the base station latitude of the current location. + /// + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location.coarse + /// + /// @remarks This API can be used in CDMA network. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] bs_latitude The base station latitude, @c 0x7FFFFFFF if unknown + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_network_get_service_state() + /// @see telephony_network_get_type() + int telephony_network_get_base_station_latitude( + ffi.Pointer handle, + ffi.Pointer bs_latitude, + ) { + return _telephony_network_get_base_station_latitude( + handle, + bs_latitude, + ); + } + + late final _telephony_network_get_base_station_latitude_ptr = _lookup< + ffi.NativeFunction<_c_telephony_network_get_base_station_latitude>>( + 'telephony_network_get_base_station_latitude'); + late final _dart_telephony_network_get_base_station_latitude + _telephony_network_get_base_station_latitude = + _telephony_network_get_base_station_latitude_ptr + .asFunction<_dart_telephony_network_get_base_station_latitude>(); + + /// @brief Gets the base station longitude of the current location. + /// + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/location.coarse + /// + /// @remarks This API can be used in CDMA network. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] bs_longitude The base station longitude, @c 0x7FFFFFFF if unknown + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + /// + /// @see telephony_network_get_service_state() + /// @see telephony_network_get_type() + int telephony_network_get_base_station_longitude( + ffi.Pointer handle, + ffi.Pointer bs_longitude, + ) { + return _telephony_network_get_base_station_longitude( + handle, + bs_longitude, + ); + } + + late final _telephony_network_get_base_station_longitude_ptr = _lookup< + ffi.NativeFunction<_c_telephony_network_get_base_station_longitude>>( + 'telephony_network_get_base_station_longitude'); + late final _dart_telephony_network_get_base_station_longitude + _telephony_network_get_base_station_longitude = + _telephony_network_get_base_station_longitude_ptr + .asFunction<_dart_telephony_network_get_base_station_longitude>(); + + /// @brief Gets the received signal strength (dBm). + /// + /// @since_tizen 4.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] dbm The received signal strength in dBm, @c 0 if unknown \n + /// The higher the received number, the stronger the signal + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_network_get_signal_strength( + ffi.Pointer handle, + ffi.Pointer dbm, + ) { + return _telephony_network_get_signal_strength( + handle, + dbm, + ); + } + + late final _telephony_network_get_signal_strength_ptr = + _lookup>( + 'telephony_network_get_signal_strength'); + late final _dart_telephony_network_get_signal_strength + _telephony_network_get_signal_strength = + _telephony_network_get_signal_strength_ptr + .asFunction<_dart_telephony_network_get_signal_strength>(); + + /// @brief Gets the IMEI (International Mobile Station Equipment Identity) of a mobile phone. + /// @details The IMEI number is used by a GSM network to identify valid devices + /// and therefore can be used for stopping a stolen phone from accessing that network. + /// + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks You must release @c imei using free() on success case. + /// @remarks Since 5.5, privilege level and return type are changed.
+ /// The following table shows the impact of changes: + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + ///
Version 5.0 and lower 5.5 and higher Remarks
Privilegehttp://tizen.org/privilege/telephonyhttp://tizen.org/privilege/securesysteminfoThe required privilege is changed.
Privilege levelPublicPartnerThe application having partner level privilege can use this API
Error#TELEPHONY_ERROR_NONE#TELEPHONY_ERROR_PERMISSION_DENIED If the application doesn't have the required privilege, the error is returned. + ///
+ /// @remarks The applications developed on Tizen 5.0 and lower version having only http://tizen.org/privilege/telephony privilege should check 'permission denied' error. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] imei The International Mobile Station Equipment Identity + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_modem_get_imei( + ffi.Pointer handle, + ffi.Pointer> imei, + ) { + return _telephony_modem_get_imei( + handle, + imei, + ); + } + + late final _telephony_modem_get_imei_ptr = + _lookup>( + 'telephony_modem_get_imei'); + late final _dart_telephony_modem_get_imei _telephony_modem_get_imei = + _telephony_modem_get_imei_ptr + .asFunction<_dart_telephony_modem_get_imei>(); + + /// @brief Gets the power status of the modem. + /// + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] status The Modem power status (0=on,1=off,2=reset,3=low) + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_modem_get_power_status( + ffi.Pointer handle, + ffi.Pointer status, + ) { + return _telephony_modem_get_power_status( + handle, + status, + ); + } + + late final _telephony_modem_get_power_status_ptr = + _lookup>( + 'telephony_modem_get_power_status'); + late final _dart_telephony_modem_get_power_status + _telephony_modem_get_power_status = _telephony_modem_get_power_status_ptr + .asFunction<_dart_telephony_modem_get_power_status>(); + + /// @brief Gets the MEID (Mobile Equipment Identifier) of a mobile phone (for CDMA). + /// + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/telephony + /// + /// @remarks You must release @c meid using free() on success case. + /// @remarks Since 5.5, privilege level and return type are changed.
+ /// The following table shows the impact of changes: + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + ///
Version 5.0 and lower 5.5 and higher Remarks
Privilegehttp://tizen.org/privilege/telephonyhttp://tizen.org/privilege/securesysteminfoThe required privilege is changed.
Privilege levelPublicPartnerThe application having partner level privilege can use this API
Error#TELEPHONY_ERROR_NONE#TELEPHONY_ERROR_PERMISSION_DENIED If the application doesn't have the required privilege, the error is returned. + ///
+ /// @remarks The applications developed on Tizen 5.0 and lower version having only http://tizen.org/privilege/telephony privilege should check 'permission denied' error. + /// + /// @param[in] handle The handle from telephony_init() + /// @param[out] meid The Mobile Equipment Identifier + /// + /// @return @c 0 on success, + /// otherwise a negative error value + /// + /// @retval #TELEPHONY_ERROR_NONE Successful + /// @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied + /// @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported + /// @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed + int telephony_modem_get_meid( + ffi.Pointer handle, + ffi.Pointer> meid, + ) { + return _telephony_modem_get_meid( + handle, + meid, + ); + } + + late final _telephony_modem_get_meid_ptr = + _lookup>( + 'telephony_modem_get_meid'); + late final _dart_telephony_modem_get_meid _telephony_modem_get_meid = + _telephony_modem_get_meid_ptr + .asFunction<_dart_telephony_modem_get_meid>(); + + /// @brief Sets @c process_input_device_event event callback function. + /// + /// @remarks The ime_process_input_device_event_cb() callback function is called when the event + /// is received from unconventional input devices that needs to be handled by IMEs. + /// + /// @since_tizen @if WEARABLE 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] callback_func @c inputmethod_process_input_device_event_cb callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_process_input_device_event_cb() + /// @see ime_event_unset_process_input_device_event_cb() + /// @see ime_run() + /// + /// @code + /// static void inputmethod_create_cb(void *user_data); + /// static void inputmethod_terminate_cb(void *user_data); + /// static void inputmethod_show_cb(int context_id, ime_context_h context, void *user_data); + /// static void inputmethod_hide_cb(int context_id, void *user_data); + /// + /// static void inputmethod_process_input_device_event_cb(ime_input_device_type_e device_type, ime_input_device_event_h device_event, void *user_data) + /// { + /// if (device_type == IME_INPUT_DEVICE_TYPE_ROTARY) { + /// dlog_print(DLOG_INFO, "INPUTMETHOD", "Input device type is rotary\n"); + /// } + /// } + /// + /// void ime_app_main(int argc, char **argv) + /// { + /// ime_callback_s basic_callback = { + /// inputmethod_create_cb, + /// inputmethod_terminate_cb, + /// inputmethod_show_cb, + /// inputmethod_hide_cb, + /// }; + /// + /// ime_event_set_process_input_device_event_cb(inputmethod_process_input_device_event_cb, NULL); + /// + /// ime_run(&basic_callback, NULL); + /// } + /// @endcode + int ime_event_set_process_input_device_event_cb( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_process_input_device_event_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_process_input_device_event_cb_ptr = _lookup< + ffi.NativeFunction<_c_ime_event_set_process_input_device_event_cb>>( + 'ime_event_set_process_input_device_event_cb'); + late final _dart_ime_event_set_process_input_device_event_cb + _ime_event_set_process_input_device_event_cb = + _ime_event_set_process_input_device_event_cb_ptr + .asFunction<_dart_ime_event_set_process_input_device_event_cb>(); + + /// @brief Unsets @c process_input_device_event event callback function. + /// + /// @remarks The ime_process_input_device_event_cb() callback function is called when the event + /// is received from unconventional input devices that needs to be handled by IMEs. + /// + /// @since_tizen @if WEARABLE 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @see ime_process_input_device_event_cb() + /// @see ime_event_set_process_input_device_event_cb() + int ime_event_unset_process_input_device_event_cb() { + return _ime_event_unset_process_input_device_event_cb(); + } + + late final _ime_event_unset_process_input_device_event_cb_ptr = _lookup< + ffi.NativeFunction<_c_ime_event_unset_process_input_device_event_cb>>( + 'ime_event_unset_process_input_device_event_cb'); + late final _dart_ime_event_unset_process_input_device_event_cb + _ime_event_unset_process_input_device_event_cb = + _ime_event_unset_process_input_device_event_cb_ptr + .asFunction<_dart_ime_event_unset_process_input_device_event_cb>(); + + /// @brief Gets the direction of the rotary input device event + /// + /// If the device_type parameter of the ime_process_input_device_event_cb function indicates + /// the current input device type is IME_INPUT_DEVICE_TYPE_ROTARY, then the device_event parameter + /// can be used to retrieve rotary device specific parameters, such as direction, as shown in the sample code. + /// + /// @since_tizen @if WEARABLE 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] event_handle The input device event handle + /// @param[out] direction The direction that the rotary input device was rotated to + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @see ime_rotary_input_device_direction_e + /// @see ime_process_input_device_event_cb() + /// + /// @code + /// static void inputmethod_process_input_device_event_cb(ime_input_device_type_e device_type, ime_input_device_event_h device_event) + /// { + /// if (device_type == IME_INPUT_DEVICE_TYPE_ROTARY) { + /// ime_input_device_rotary_direction_e direction; + /// if (IME_ERROR_NONE == ime_input_device_rotary_get_direction(device_event, &direction)) { + /// dlog_print(DLOG_INFO, "INPUTMETHOD", "Direction : %d", direction); + /// } + /// } + /// } + /// @endcode + int ime_input_device_rotary_get_direction( + ffi.Pointer event_handle, + ffi.Pointer direction, + ) { + return _ime_input_device_rotary_get_direction( + event_handle, + direction, + ); + } + + late final _ime_input_device_rotary_get_direction_ptr = + _lookup>( + 'ime_input_device_rotary_get_direction'); + late final _dart_ime_input_device_rotary_get_direction + _ime_input_device_rotary_get_direction = + _ime_input_device_rotary_get_direction_ptr + .asFunction<_dart_ime_input_device_rotary_get_direction>(); + + /// @brief Runs the main loop of IME application. + /// + /// @details This function starts to run IME application's main loop. The ime_create_cb() + /// callback function is called to initialize IME application before the main loop starts up. And + /// the ime_terminate_cb() callback function is called when IME application is terminated. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks IME application MUST implement ime_app_main() function which is the main + /// entry point of IME application. In ime_app_main() function, the ime_run() + /// function MUST be called with the necessary callback functions; ime_create_cb(), + /// ime_terminate_cb(), ime_show_cb(), and ime_hide_cb() callback functions + /// are mandatory for IME application. + /// + /// @param[in] basic_cb The structure pointer of the essential callback functions + /// @param[in] user_data User data to be passed to the callback functions + /// + /// @return 0 if IME application ends successfully, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NO_CALLBACK_FUNCTION Necessary callback function is not set + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @pre The ime_event_set_***() functions can be called to set the event handling callback functions. + /// + /// @see ime_callback_s() + /// @see ime_event_set_focus_in_cb() + /// @see ime_event_set_focus_out_cb() + /// @see ime_event_set_surrounding_text_updated_cb() + /// @see ime_event_set_input_context_reset_cb() + /// @see ime_event_set_cursor_position_updated_cb() + /// @see ime_event_set_language_requested_cb() + /// @see ime_event_set_language_set_cb() + /// @see ime_event_set_imdata_set_cb() + /// @see ime_event_set_layout_set_cb() + /// @see ime_event_set_return_key_type_set_cb() + /// @see ime_event_set_return_key_state_set_cb() + /// @see ime_event_set_geometry_requested_cb() + /// @see ime_event_set_display_language_changed_cb() + /// @see ime_event_set_rotation_degree_changed_cb() + /// @see ime_event_set_accessibility_state_changed_cb() + /// @see ime_event_set_option_window_created_cb() + /// @see ime_event_set_option_window_destroyed_cb() + /// @see ime_event_set_prediction_hint_set_cb() + /// + /// @code + /// static void inputmethod_create_cb(void *user_data); + /// static void inputmethod_terminate_cb(void *user_data); + /// static void inputmethod_show_cb(int context_id, ime_context_h context, void *user_data); + /// static void inputmethod_hide_cb(int context_id, void *user_data); + /// static void inputmethod_focus_in_cb(int context_id, void *user_data); + /// static void inputmethod_focus_out_cb(int context_id, void *user_data); + /// static void inputmethod_cursor_position_updated_cb(int cursor_pos, void *user_data); + /// + /// static void inputmethod_create_cb(void *user_data) + /// { + /// Evas_Object *ime_win = NULL; + /// + /// ime_set_size(480, 400, 800, 400); + /// ime_win = ime_get_main_window(); + /// if (ime_win) { + /// // Prepare before showing IME window. + /// } + /// } + /// + /// static void inputmethod_show_cb(int context_id, ime_context_h context, void *user_data) + /// { + /// Ecore_IMF_Input_Panel_Layout layout; + /// ime_layout_variation_e layout_variation; + /// Evas_Object *ime_win; + /// + /// ime_context_get_layout(context, &layout); + /// ime_context_get_layout_variation(context, &layout_variation); + /// + /// ime_win = ime_get_main_window(); + /// if (ime_win) { + /// // Compose IME UI properly with the context information and show. + /// + /// evas_object_show(ime_win); + /// } + /// } + /// + /// static void inputmethod_hide_cb(int context_id, void *user_data) + /// { + /// Evas_Object *ime_win = ime_get_main_window(); + /// if (ime_win) { + /// evas_object_hide(ime_win); + /// } + /// } + /// + /// void ime_app_main(int argc, char **argv) + /// { + /// ime_callback_s basic_callback = { + /// inputmethod_create_cb, + /// inputmethod_terminate_cb, + /// inputmethod_show_cb, + /// inputmethod_hide_cb, + /// }; + /// + /// ime_event_set_focus_in_cb(inputmethod_focus_in_cb, NULL); + /// ime_event_set_focus_out_cb(inputmethod_focus_out_cb, NULL); + /// ime_event_set_cursor_position_updated_cb(inputmethod_cursor_position_updated_cb, NULL); + /// + /// ime_run(&basic_callback, NULL); + /// } + /// @endcode + int ime_run( + ffi.Pointer basic_cb, + ffi.Pointer user_data, + ) { + return _ime_run( + basic_cb, + user_data, + ); + } + + late final _ime_run_ptr = _lookup>('ime_run'); + late final _dart_ime_run _ime_run = _ime_run_ptr.asFunction<_dart_ime_run>(); + + /// @brief Sets @c focus_in event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_focus_in_cb() callback function is called when an associated text input + /// UI control has focus. + /// + /// @param[in] callback_func @c focus_in event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_focus_in_cb() + /// @see ime_run() + int ime_event_set_focus_in_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_focus_in_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_focus_in_cb_ptr = + _lookup>( + 'ime_event_set_focus_in_cb'); + late final _dart_ime_event_set_focus_in_cb _ime_event_set_focus_in_cb = + _ime_event_set_focus_in_cb_ptr + .asFunction<_dart_ime_event_set_focus_in_cb>(); + + /// @brief Sets @c focus_out event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_focus_out_cb() callback function is called when an associated text input + /// UI control loses focus. + /// + /// @param[in] callback_func @c focus_out event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_focus_out_cb() + /// @see ime_run() + int ime_event_set_focus_out_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_focus_out_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_focus_out_cb_ptr = + _lookup>( + 'ime_event_set_focus_out_cb'); + late final _dart_ime_event_set_focus_out_cb _ime_event_set_focus_out_cb = + _ime_event_set_focus_out_cb_ptr + .asFunction<_dart_ime_event_set_focus_out_cb>(); + + /// @brief Sets @c surrounding_text_updated event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_surrounding_text_updated_cb() callback function is called when an + /// associated text input UI control responds to a request with the surrounding text. + /// + /// @param[in] callback_func @c surrounding_text_updated event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_surrounding_text_updated_cb() + /// @see ime_run() + int ime_event_set_surrounding_text_updated_cb( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_surrounding_text_updated_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_surrounding_text_updated_cb_ptr = + _lookup>( + 'ime_event_set_surrounding_text_updated_cb'); + late final _dart_ime_event_set_surrounding_text_updated_cb + _ime_event_set_surrounding_text_updated_cb = + _ime_event_set_surrounding_text_updated_cb_ptr + .asFunction<_dart_ime_event_set_surrounding_text_updated_cb>(); + + /// @brief Sets @c input_context_reset event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_input_context_reset_cb() callback function is called to reset the input + /// context of an associated text input UI control. + /// + /// @param[in] callback_func @c input_context_reset event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_input_context_reset_cb() + /// @see ime_run() + int ime_event_set_input_context_reset_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_input_context_reset_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_input_context_reset_cb_ptr = + _lookup>( + 'ime_event_set_input_context_reset_cb'); + late final _dart_ime_event_set_input_context_reset_cb + _ime_event_set_input_context_reset_cb = + _ime_event_set_input_context_reset_cb_ptr + .asFunction<_dart_ime_event_set_input_context_reset_cb>(); + + /// @brief Sets @c cursor_position_updated event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_cursor_position_updated_cb() callback function is called when the position + /// of the cursor in an associated text input UI control changes. + /// + /// @param[in] callback_func @c cursor_position_updated event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_cursor_position_updated_cb() + /// @see ime_run() + int ime_event_set_cursor_position_updated_cb( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_cursor_position_updated_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_cursor_position_updated_cb_ptr = + _lookup>( + 'ime_event_set_cursor_position_updated_cb'); + late final _dart_ime_event_set_cursor_position_updated_cb + _ime_event_set_cursor_position_updated_cb = + _ime_event_set_cursor_position_updated_cb_ptr + .asFunction<_dart_ime_event_set_cursor_position_updated_cb>(); + + /// @brief Sets @c language_requested event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_language_requested_cb() callback function is called when an associated + /// text input UI control requests the language from the input panel. + /// + /// @param[in] callback_func @c language_requested event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_language_requested_cb() + /// @see ime_run() + int ime_event_set_language_requested_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_language_requested_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_language_requested_cb_ptr = + _lookup>( + 'ime_event_set_language_requested_cb'); + late final _dart_ime_event_set_language_requested_cb + _ime_event_set_language_requested_cb = + _ime_event_set_language_requested_cb_ptr + .asFunction<_dart_ime_event_set_language_requested_cb>(); + + /// @brief Sets @c language_set event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_language_set_cb() callback function is called to set the preferred + /// language to the input panel. + /// + /// @param[in] callback_func @c language_set event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_language_set_cb() + /// @see ime_run() + int ime_event_set_language_set_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_language_set_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_language_set_cb_ptr = + _lookup>( + 'ime_event_set_language_set_cb'); + late final _dart_ime_event_set_language_set_cb + _ime_event_set_language_set_cb = _ime_event_set_language_set_cb_ptr + .asFunction<_dart_ime_event_set_language_set_cb>(); + + /// @brief Sets @c imdata_set event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_imdata_set_cb() callback function is called to set the application + /// specific data to deliver to the input panel. + /// + /// @param[in] callback_func @c imdata_set event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_imdata_set_cb() + /// @see ime_event_set_imdata_requested_cb() + /// @see ime_run() + int ime_event_set_imdata_set_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_imdata_set_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_imdata_set_cb_ptr = + _lookup>( + 'ime_event_set_imdata_set_cb'); + late final _dart_ime_event_set_imdata_set_cb _ime_event_set_imdata_set_cb = + _ime_event_set_imdata_set_cb_ptr + .asFunction<_dart_ime_event_set_imdata_set_cb>(); + + /// @brief Sets @c imdata_requested event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_imdata_requested_cb() callback function is called when an associated + /// text input UI control requests the application specific data from the input panel. + /// + /// @param[in] callback_func @c imdata_requested event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_imdata_requested_cb() + /// @see ime_event_set_imdata_set_cb() + /// @see ime_run() + int ime_event_set_imdata_requested_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_imdata_requested_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_imdata_requested_cb_ptr = + _lookup>( + 'ime_event_set_imdata_requested_cb'); + late final _dart_ime_event_set_imdata_requested_cb + _ime_event_set_imdata_requested_cb = + _ime_event_set_imdata_requested_cb_ptr + .asFunction<_dart_ime_event_set_imdata_requested_cb>(); + + /// @brief Sets @c layout_set event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_layout_set_cb() callback function is called when an associated text input + /// UI control requests the input panel to set its layout. + /// + /// @param[in] callback_func @c layout_set event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_layout_set_cb() + /// @see ime_run() + int ime_event_set_layout_set_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_layout_set_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_layout_set_cb_ptr = + _lookup>( + 'ime_event_set_layout_set_cb'); + late final _dart_ime_event_set_layout_set_cb _ime_event_set_layout_set_cb = + _ime_event_set_layout_set_cb_ptr + .asFunction<_dart_ime_event_set_layout_set_cb>(); + + /// @brief Sets @c return_key_type_set event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_return_key_type_set_cb() callback function is called when an associated + /// text input UI control requests the input panel to set the @c Return key label. + /// + /// @param[in] callback_func @c return_key_type_set event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_return_key_type_set_cb() + /// @see ime_run() + int ime_event_set_return_key_type_set_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_return_key_type_set_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_return_key_type_set_cb_ptr = + _lookup>( + 'ime_event_set_return_key_type_set_cb'); + late final _dart_ime_event_set_return_key_type_set_cb + _ime_event_set_return_key_type_set_cb = + _ime_event_set_return_key_type_set_cb_ptr + .asFunction<_dart_ime_event_set_return_key_type_set_cb>(); + + /// @brief Sets @c return_key_state_set event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_return_key_state_set_cb() callback function is called when an associated + /// text input UI control requests the input panel to enable or disable the @c Return key state. + /// + /// @param[in] callback_func @c return_key_state_set event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_return_key_state_set_cb() + /// @see ime_run() + int ime_event_set_return_key_state_set_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_return_key_state_set_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_return_key_state_set_cb_ptr = + _lookup>( + 'ime_event_set_return_key_state_set_cb'); + late final _dart_ime_event_set_return_key_state_set_cb + _ime_event_set_return_key_state_set_cb = + _ime_event_set_return_key_state_set_cb_ptr + .asFunction<_dart_ime_event_set_return_key_state_set_cb>(); + + /// @brief Sets @c geometry_requested event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_geometry_requested_cb() callback function is called when an associated + /// text input UI control requests the position and size from the input panel. + /// + /// @param[in] callback_func @c geometry_requested event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_geometry_requested_cb() + /// @see ime_run() + int ime_event_set_geometry_requested_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_geometry_requested_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_geometry_requested_cb_ptr = + _lookup>( + 'ime_event_set_geometry_requested_cb'); + late final _dart_ime_event_set_geometry_requested_cb + _ime_event_set_geometry_requested_cb = + _ime_event_set_geometry_requested_cb_ptr + .asFunction<_dart_ime_event_set_geometry_requested_cb>(); + + /// @brief Sets @c process_key_event event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_process_key_event_cb() callback function is called when the key event + /// is received from the external keyboard devices or ime_send_key_event() function. + /// + /// @param[in] callback_func @c process_key_event event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_process_key_event_cb() + /// @see ime_run() + /// + /// @code + /// static void inputmethod_create_cb(void *user_data); + /// static void inputmethod_terminate_cb(void *user_data); + /// static void inputmethod_show_cb(int context_id, ime_context_h context, void *user_data); + /// static void inputmethod_hide_cb(int context_id, void *user_data); + /// + /// static bool inputmethod_process_key_event_cb(ime_key_code_e keycode, ime_key_mask_e keymask, void *user_data); + /// { + /// if (keymask & IME_KEY_MASK_CONTROL) { + /// return false; // e.g., Cotrol+C key event would be forwarded to UI control of the client application + /// } + /// if (keymask & IME_KEY_MASK_ALT) { + /// return false; + /// } + /// + /// if (!(keymask & IME_KEY_MASK_RELEASED)) { // The key is pressed + /// if (keycode == IME_KEY_1) { + /// ime_update_preedit_string("1"); // Show "1" preedit string + /// return true; + /// } + /// else if (keycode == IME_KEY_2) { + /// ime_commit_string("12"); // Input "12" string + /// return true; + /// } + /// } + /// + /// return false; + /// } + /// + /// void ime_app_main(int argc, char **argv) + /// { + /// ime_callback_s basic_callback = { + /// inputmethod_create_cb, + /// inputmethod_terminate_cb, + /// inputmethod_show_cb, + /// inputmethod_hide_cb, + /// }; + /// + /// ime_event_set_process_key_event_cb(inputmethod_process_key_event_cb, NULL); + /// + /// ime_run(&basic_callback, NULL); + /// } + /// @endcode + int ime_event_set_process_key_event_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_process_key_event_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_process_key_event_cb_ptr = + _lookup>( + 'ime_event_set_process_key_event_cb'); + late final _dart_ime_event_set_process_key_event_cb + _ime_event_set_process_key_event_cb = + _ime_event_set_process_key_event_cb_ptr + .asFunction<_dart_ime_event_set_process_key_event_cb>(); + + /// @brief Sets @c display_language_changed event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_display_language_changed_cb() callback function is called when the system + /// display language is changed. + /// + /// @param[in] callback_func @c display_language_changed event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_display_language_changed_cb() + /// @see ime_run() + int ime_event_set_display_language_changed_cb( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_display_language_changed_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_display_language_changed_cb_ptr = + _lookup>( + 'ime_event_set_display_language_changed_cb'); + late final _dart_ime_event_set_display_language_changed_cb + _ime_event_set_display_language_changed_cb = + _ime_event_set_display_language_changed_cb_ptr + .asFunction<_dart_ime_event_set_display_language_changed_cb>(); + + /// @brief Sets @c rotation_degree_changed event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_rotation_degree_changed_cb() callback function is called when the device + /// is rotated. + /// + /// @param[in] callback_func @c rotation_degree_changed event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_rotation_degree_changed_cb() + /// @see ime_run() + int ime_event_set_rotation_degree_changed_cb( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_rotation_degree_changed_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_rotation_degree_changed_cb_ptr = + _lookup>( + 'ime_event_set_rotation_degree_changed_cb'); + late final _dart_ime_event_set_rotation_degree_changed_cb + _ime_event_set_rotation_degree_changed_cb = + _ime_event_set_rotation_degree_changed_cb_ptr + .asFunction<_dart_ime_event_set_rotation_degree_changed_cb>(); + + /// @brief Sets @c accessibility_state_changed event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_accessibility_state_changed_cb() callback function is called when + /// Accessibility in Settings application is on or off. + /// + /// @param[in] callback_func @c accessibility_state_changed event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_accessibility_state_changed_cb() + /// @see ime_run() + int ime_event_set_accessibility_state_changed_cb( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_accessibility_state_changed_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_accessibility_state_changed_cb_ptr = _lookup< + ffi.NativeFunction<_c_ime_event_set_accessibility_state_changed_cb>>( + 'ime_event_set_accessibility_state_changed_cb'); + late final _dart_ime_event_set_accessibility_state_changed_cb + _ime_event_set_accessibility_state_changed_cb = + _ime_event_set_accessibility_state_changed_cb_ptr + .asFunction<_dart_ime_event_set_accessibility_state_changed_cb>(); + + /// @brief Sets @c option_window_created event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_option_window_created_cb() callback function is called to create the option window. + /// + /// @param[in] callback_func @c option_window_created event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_option_window_created_cb() + /// @see ime_run() + int ime_event_set_option_window_created_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_option_window_created_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_option_window_created_cb_ptr = + _lookup>( + 'ime_event_set_option_window_created_cb'); + late final _dart_ime_event_set_option_window_created_cb + _ime_event_set_option_window_created_cb = + _ime_event_set_option_window_created_cb_ptr + .asFunction<_dart_ime_event_set_option_window_created_cb>(); + + /// @brief Sets @c option_window_destroyed event callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_option_window_destroyed_cb() callback function is called to destroy the option window. + /// + /// @param[in] callback_func @c option_window_destroyed event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_option_window_destroyed_cb() + /// @see ime_run() + int ime_event_set_option_window_destroyed_cb( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_option_window_destroyed_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_option_window_destroyed_cb_ptr = + _lookup>( + 'ime_event_set_option_window_destroyed_cb'); + late final _dart_ime_event_set_option_window_destroyed_cb + _ime_event_set_option_window_destroyed_cb = + _ime_event_set_option_window_destroyed_cb_ptr + .asFunction<_dart_ime_event_set_option_window_destroyed_cb>(); + + /// @brief Sends a key event to the associated text input UI control. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @details This function sends key down or up event with key mask to the client application. + /// If @a forward_key is @c true, this key event goes to the edit filed directly. And if @a forward_key + /// is @c false, the ime_process_key_event_cb() callback function receives the key event before the edit field. + /// + /// @param[in] keycode The key code to be sent + /// @param[in] keymask The modifier key mask + /// @param[in] forward_key The flag to send the key event directly to the edit field + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @post If @a forward_key is @c false, the ime_process_key_event_cb() callback function can compose the text with the key events. + /// + /// @see ime_key_code_e + /// @see ime_key_mask_e + /// @see ime_process_key_event_cb() + int ime_send_key_event( + int keycode, + int keymask, + bool forward_key, + ) { + return _ime_send_key_event( + keycode, + keymask, + forward_key ? 1 : 0, + ); + } + + late final _ime_send_key_event_ptr = + _lookup>('ime_send_key_event'); + late final _dart_ime_send_key_event _ime_send_key_event = + _ime_send_key_event_ptr.asFunction<_dart_ime_send_key_event>(); + + /// @brief Sends the text to the associated text input UI control. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] str The UTF-8 string to be committed + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @see ime_show_preedit_string() + /// @see ime_hide_preedit_string() + /// @see ime_update_preedit_string() + int ime_commit_string( + ffi.Pointer str, + ) { + return _ime_commit_string( + str, + ); + } + + late final _ime_commit_string_ptr = + _lookup>('ime_commit_string'); + late final _dart_ime_commit_string _ime_commit_string = + _ime_commit_string_ptr.asFunction<_dart_ime_commit_string>(); + + /// @brief Requests to show preedit string. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @see ime_commit_string() + /// @see ime_hide_preedit_string() + /// @see ime_update_preedit_string() + int ime_show_preedit_string() { + return _ime_show_preedit_string(); + } + + late final _ime_show_preedit_string_ptr = + _lookup>( + 'ime_show_preedit_string'); + late final _dart_ime_show_preedit_string _ime_show_preedit_string = + _ime_show_preedit_string_ptr.asFunction<_dart_ime_show_preedit_string>(); + + /// @brief Requests to hide preedit string. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @see ime_commit_string() + /// @see ime_show_preedit_string() + /// @see ime_update_preedit_string() + int ime_hide_preedit_string() { + return _ime_hide_preedit_string(); + } + + late final _ime_hide_preedit_string_ptr = + _lookup>( + 'ime_hide_preedit_string'); + late final _dart_ime_hide_preedit_string _ime_hide_preedit_string = + _ime_hide_preedit_string_ptr.asFunction<_dart_ime_hide_preedit_string>(); + + /// @brief Updates a new preedit string. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] str The UTF-8 string to be updated in preedit + /// @param[in] attrs The Eina_List which has #ime_preedit_attribute lists; @a str can be composed of multiple + /// string attributes: underline, highlight color and reversal color. The @a attrs will be released internally + /// on success and it can be NULL if no attributes to set + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @post This function is supposed to be followed by the ime_show_preedit_string() function. + /// + /// @see ime_preedit_attribute + /// @see ime_commit_string() + /// @see ime_show_preedit_string() + /// @see ime_hide_preedit_string() + /// + /// @code + /// { + /// int ret; + /// Eina_List *list = NULL; + /// + /// ime_preedit_attribute *attr = calloc(1, sizeof (ime_preedit_attribute)); + /// attr->start = 0; + /// attr->length = 1; + /// attr->type = IME_ATTR_FONTSTYLE; + /// attr->value = IME_ATTR_FONTSTYLE_UNDERLINE; + /// list = eina_list_append(list, attr); + /// + /// attr = calloc(1, sizeof (ime_preedit_attribute)); + /// attr->start = 1; + /// attr->length = 1; + /// attr->type = IME_ATTR_FONTSTYLE; + /// attr->value = IME_ATTR_FONTSTYLE_HIGHLIGHT; + /// list = eina_list_append(list, attr); + /// + /// attr = calloc(1, sizeof (ime_preedit_attribute)); + /// attr->start = 2; + /// attr->length = 1; + /// attr->type = IME_ATTR_FONTSTYLE; + /// attr->value = IME_ATTR_FONTSTYLE_REVERSAL; + /// list = eina_list_append(list, attr); + /// + /// ret = ime_update_preedit_string("abcd", list); + /// if (ret != IME_ERROR_NONE) { + /// EINA_LIST_FREE(list, attr) + /// free(attr); + /// } + /// } + /// @endcode + int ime_update_preedit_string( + ffi.Pointer str, + ffi.Pointer attrs, + ) { + return _ime_update_preedit_string( + str, + attrs, + ); + } + + late final _ime_update_preedit_string_ptr = + _lookup>( + 'ime_update_preedit_string'); + late final _dart_ime_update_preedit_string _ime_update_preedit_string = + _ime_update_preedit_string_ptr + .asFunction<_dart_ime_update_preedit_string>(); + + /// @brief Requests the surrounding text from the position of the cursor, asynchronously. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] maxlen_before The maximum length of string to be retrieved before the cursor; -1 means unlimited + /// @param[in] maxlen_after The maximum length of string to be retrieved after the cursor; -1 means unlimited + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NO_CALLBACK_FUNCTION Necessary callback function is not set + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @pre The ime_surrounding_text_updated_cb() callback function MUST be set by ime_event_set_surrounding_text_updated_cb(). + /// + /// @post The requested surrounding text can be received using the ime_surrounding_text_updated_cb() callback function. + /// + /// @see ime_delete_surrounding_text() + /// @see ime_event_set_surrounding_text_updated_cb() + /// @see ime_surrounding_text_updated_cb() + int ime_request_surrounding_text( + int maxlen_before, + int maxlen_after, + ) { + return _ime_request_surrounding_text( + maxlen_before, + maxlen_after, + ); + } + + late final _ime_request_surrounding_text_ptr = + _lookup>( + 'ime_request_surrounding_text'); + late final _dart_ime_request_surrounding_text _ime_request_surrounding_text = + _ime_request_surrounding_text_ptr + .asFunction<_dart_ime_request_surrounding_text>(); + + /// @brief Requests to delete surrounding text. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] offset The offset value from the cursor position + /// @param[in] len The length of the text to delete + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @see ime_request_surrounding_text() + int ime_delete_surrounding_text( + int offset, + int len, + ) { + return _ime_delete_surrounding_text( + offset, + len, + ); + } + + late final _ime_delete_surrounding_text_ptr = + _lookup>( + 'ime_delete_surrounding_text'); + late final _dart_ime_delete_surrounding_text _ime_delete_surrounding_text = + _ime_delete_surrounding_text_ptr + .asFunction<_dart_ime_delete_surrounding_text>(); + + /// @brief Gets the surrounding text from the position of the cursor, synchronously. + /// + /// @remarks @a text must be released using free(). + /// + /// @since_tizen 3.0 + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] maxlen_before The maximum length of string to be retrieved before the cursor; -1 means unlimited + /// @param[in] maxlen_after The maximum length of string to be retrieved after the cursor; -1 means unlimited + /// @param[out] text The surrounding text + /// @param[out] cursor_pos The cursor position + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// @retval #IME_ERROR_OUT_OF_MEMORY Failed to obtain text due to out of memory + /// + /// @see ime_delete_surrounding_text() + int ime_get_surrounding_text( + int maxlen_before, + int maxlen_after, + ffi.Pointer> text, + ffi.Pointer cursor_pos, + ) { + return _ime_get_surrounding_text( + maxlen_before, + maxlen_after, + text, + cursor_pos, + ); + } + + late final _ime_get_surrounding_text_ptr = + _lookup>( + 'ime_get_surrounding_text'); + late final _dart_ime_get_surrounding_text _ime_get_surrounding_text = + _ime_get_surrounding_text_ptr + .asFunction<_dart_ime_get_surrounding_text>(); + + /// @brief Requests to set selection. + /// + /// @since_tizen 3.0 + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] start The start cursor position in text (in characters not bytes) + /// @param[in] end The end cursor position in text (in characters not bytes) + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + int ime_set_selection( + int start, + int end, + ) { + return _ime_set_selection( + start, + end, + ); + } + + late final _ime_set_selection_ptr = + _lookup>('ime_set_selection'); + late final _dart_ime_set_selection _ime_set_selection = + _ime_set_selection_ptr.asFunction<_dart_ime_set_selection>(); + + /// @brief Gets the selected text synchronously. + /// + /// @details If multi-line text is selected, the result will contain '\n' for each newline character. + /// And if the selected text is empty, the result will be an empty string. + /// + /// @since_tizen 4.0 + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks @a text must be released using free(). + /// + /// @param[out] text The selected text + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + int ime_get_selected_text( + ffi.Pointer> text, + ) { + return _ime_get_selected_text( + text, + ); + } + + late final _ime_get_selected_text_ptr = + _lookup>( + 'ime_get_selected_text'); + late final _dart_ime_get_selected_text _ime_get_selected_text = + _ime_get_selected_text_ptr.asFunction<_dart_ime_get_selected_text>(); + + /// @brief This API returns the pointer of input panel main window. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The specific error code can be obtained using the get_last_result() method if this function returns NULL. + /// + /// @return The input panel main window object on success, otherwise NULL + /// + /// @exception #IME_ERROR_NONE Successful + /// #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @see ime_create_cb() + /// @see ime_terminate_cb() + /// @see ime_show_cb() + /// @see ime_hide_cb() + ffi.Pointer ime_get_main_window() { + return _ime_get_main_window(); + } + + late final _ime_get_main_window_ptr = + _lookup>( + 'ime_get_main_window'); + late final _dart_ime_get_main_window _ime_get_main_window = + _ime_get_main_window_ptr.asFunction<_dart_ime_get_main_window>(); + + /// @brief This API updates the input panel window's size information. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] portrait_width The width in portrait mode + /// @param[in] portrait_height The height in portrait mode + /// @param[in] landscape_width The width in landscape mode + /// @param[in] landscape_height The height in landscape mode + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @see ime_create_cb() + int ime_set_size( + int portrait_width, + int portrait_height, + int landscape_width, + int landscape_height, + ) { + return _ime_set_size( + portrait_width, + portrait_height, + landscape_width, + landscape_height, + ); + } + + late final _ime_set_size_ptr = + _lookup>('ime_set_size'); + late final _dart_ime_set_size _ime_set_size = + _ime_set_size_ptr.asFunction<_dart_ime_set_size>(); + + /// @brief Requests to create an option window from the input panel. + /// + /// @details The input panel can call this function to open the option window. This + /// function calls ime_option_window_created_cb() callback function with + /// #IME_OPTION_WINDOW_TYPE_KEYBOARD parameter. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NO_CALLBACK_FUNCTION Necessary callback function is not set + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// @retval #IME_ERROR_OPERATION_FAILED Operation failed + /// + /// @pre The ime_option_window_created_cb() and ime_option_window_destroyed_cb() + /// callback functions MUST be set by ime_event_set_option_window_created_cb() and + /// ime_event_set_option_window_destroyed_cb() respectively. + /// + /// @post This function calls ime_option_window_created_cb() callback function to + /// create the option window. And ime_destroy_option_window() function can be called + /// to close the option window. + /// + /// @see ime_event_set_option_window_created_cb() + /// @see ime_option_window_created_cb() + /// @see ime_destroy_option_window() + int ime_create_option_window() { + return _ime_create_option_window(); + } + + late final _ime_create_option_window_ptr = + _lookup>( + 'ime_create_option_window'); + late final _dart_ime_create_option_window _ime_create_option_window = + _ime_create_option_window_ptr + .asFunction<_dart_ime_create_option_window>(); + + /// @brief Requests to destroy an option window. + /// + /// @details The input panel can call this function to close the option window which + /// is created from either the input panel or Settings application. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] window The option window to destroy + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NO_CALLBACK_FUNCTION Necessary callback function is not set + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @pre The ime_option_window_created_cb() and ime_option_window_destroyed_cb() + /// callback functions MUST be set by ime_event_set_option_window_created_cb() and + /// ime_event_set_option_window_destroyed_cb() respectively. + /// + /// @post This function calls ime_option_window_destroyed_cb() callback function + /// to destroy the option window. + /// + /// @see ime_event_set_option_window_destroyed_cb() + /// @see ime_option_window_destroyed_cb() + /// @see ime_create_option_window() + int ime_destroy_option_window( + ffi.Pointer window, + ) { + return _ime_destroy_option_window( + window, + ); + } + + late final _ime_destroy_option_window_ptr = + _lookup>( + 'ime_destroy_option_window'); + late final _dart_ime_destroy_option_window _ime_destroy_option_window = + _ime_destroy_option_window_ptr + .asFunction<_dart_ime_destroy_option_window>(); + + /// @brief Gets the layout information from the given input context. + /// + /// @details Each edit field has various attributes for input panel. This function can be + /// called to get the layout information in ime_show_cb() callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] context The input context information of an associated text input UI control + /// @param[out] layout Layout information + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @post Input panel UI should be drawn or operated by this information accordingly. + /// + /// @see ime_show_cb() + /// @see ime_layout_set_cb() + int ime_context_get_layout( + ffi.Pointer<_ime_context> context, + ffi.Pointer layout, + ) { + return _ime_context_get_layout( + context, + layout, + ); + } + + late final _ime_context_get_layout_ptr = + _lookup>( + 'ime_context_get_layout'); + late final _dart_ime_context_get_layout _ime_context_get_layout = + _ime_context_get_layout_ptr.asFunction<_dart_ime_context_get_layout>(); + + /// @brief Gets the layout variation information from the given input context. + /// + /// @details Each edit field has various attributes for input panel. This function can be + /// called to get the layout variation information in ime_show_cb() callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] context The input context information of an associated text input UI control + /// @param[out] layout_variation Layout variation information + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @post Input panel UI should be drawn or operated by this information accordingly. + /// + /// @see ime_show_cb() + /// @see ime_layout_variation_e + int ime_context_get_layout_variation( + ffi.Pointer<_ime_context> context, + ffi.Pointer layout_variation, + ) { + return _ime_context_get_layout_variation( + context, + layout_variation, + ); + } + + late final _ime_context_get_layout_variation_ptr = + _lookup>( + 'ime_context_get_layout_variation'); + late final _dart_ime_context_get_layout_variation + _ime_context_get_layout_variation = _ime_context_get_layout_variation_ptr + .asFunction<_dart_ime_context_get_layout_variation>(); + + /// @brief Gets the cursor position information from the given input context. + /// + /// @details Each edit field has various attributes for input panel. This function can be + /// called to get the cursor position information in ime_show_cb() callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] context The input context information of an associated text input UI control + /// @param[out] cursor_pos Cursor position information + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @post Input panel UI should be drawn or operated by this information accordingly. + /// + /// @see ime_show_cb() + /// @see ime_cursor_position_updated_cb() + int ime_context_get_cursor_position( + ffi.Pointer<_ime_context> context, + ffi.Pointer cursor_pos, + ) { + return _ime_context_get_cursor_position( + context, + cursor_pos, + ); + } + + late final _ime_context_get_cursor_position_ptr = + _lookup>( + 'ime_context_get_cursor_position'); + late final _dart_ime_context_get_cursor_position + _ime_context_get_cursor_position = _ime_context_get_cursor_position_ptr + .asFunction<_dart_ime_context_get_cursor_position>(); + + /// @brief Gets the autocapital type information from the given input context. + /// + /// @details Each edit field has various attributes for input panel. This function can be + /// called to get the autocapital type information in ime_show_cb() callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] context The input context information of an associated text input UI control + /// @param[out] autocapital_type Autocapital type information + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @post Input panel UI should be drawn or operated by this information accordingly. + /// + /// @see ime_show_cb() + int ime_context_get_autocapital_type( + ffi.Pointer<_ime_context> context, + ffi.Pointer autocapital_type, + ) { + return _ime_context_get_autocapital_type( + context, + autocapital_type, + ); + } + + late final _ime_context_get_autocapital_type_ptr = + _lookup>( + 'ime_context_get_autocapital_type'); + late final _dart_ime_context_get_autocapital_type + _ime_context_get_autocapital_type = _ime_context_get_autocapital_type_ptr + .asFunction<_dart_ime_context_get_autocapital_type>(); + + /// @brief Gets the @c Return key label type information from the given input context. + /// + /// @details Each edit field has various attributes for input panel. This function can be + /// called to get the @c Return key label type information in ime_show_cb() callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] context The input context information of an associated text input UI control + /// @param[out] return_key_type The @c Return key label type information + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @post Input panel UI should be drawn or operated by this information accordingly. + /// + /// @see ime_show_cb() + /// @see ime_return_key_type_set_cb() + int ime_context_get_return_key_type( + ffi.Pointer<_ime_context> context, + ffi.Pointer return_key_type, + ) { + return _ime_context_get_return_key_type( + context, + return_key_type, + ); + } + + late final _ime_context_get_return_key_type_ptr = + _lookup>( + 'ime_context_get_return_key_type'); + late final _dart_ime_context_get_return_key_type + _ime_context_get_return_key_type = _ime_context_get_return_key_type_ptr + .asFunction<_dart_ime_context_get_return_key_type>(); + + /// @brief Gets the @c Return key state information from the given input context. + /// + /// @details Each edit field has various attributes for input panel. This function can be + /// called to get the @c Return key state information in ime_show_cb() callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] context The input context information of an associated text input UI control + /// @param[out] return_key_state The @c Return key state information \n @c true to enable @c Return key + /// button, @c false to disable @c Return key button + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @post Input panel UI should be drawn or operated by this information accordingly. + /// + /// @see ime_show_cb() + /// @see ime_return_key_state_set_cb() + int ime_context_get_return_key_state( + ffi.Pointer<_ime_context> context, + ffi.Pointer return_key_state, + ) { + return _ime_context_get_return_key_state( + context, + return_key_state, + ); + } + + late final _ime_context_get_return_key_state_ptr = + _lookup>( + 'ime_context_get_return_key_state'); + late final _dart_ime_context_get_return_key_state + _ime_context_get_return_key_state = _ime_context_get_return_key_state_ptr + .asFunction<_dart_ime_context_get_return_key_state>(); + + /// @brief Gets the prediction mode information from the given input context. + /// + /// @details Each edit field has various attributes for input panel. This function can be + /// called to get the prediction mode information in ime_show_cb() callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] context The input context information of an associated text input UI control + /// @param[out] prediction_mode Prediction mode information \n @c true to allow the predictive + /// text feature if available, @c false to disable the predictive text feature + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @post Input panel UI should be drawn or operated by this information accordingly. + /// + /// @see ime_show_cb() + int ime_context_get_prediction_mode( + ffi.Pointer<_ime_context> context, + ffi.Pointer prediction_mode, + ) { + return _ime_context_get_prediction_mode( + context, + prediction_mode, + ); + } + + late final _ime_context_get_prediction_mode_ptr = + _lookup>( + 'ime_context_get_prediction_mode'); + late final _dart_ime_context_get_prediction_mode + _ime_context_get_prediction_mode = _ime_context_get_prediction_mode_ptr + .asFunction<_dart_ime_context_get_prediction_mode>(); + + /// @brief Gets the password mode information from the given input context. + /// + /// @details Each edit field has various attributes for input panel. This function can be + /// called to get the password mode information in ime_show_cb() callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks If @a password_mode is @c true, the input panel is advised not to support the predictive text. + /// + /// @param[in] context The input context information of an associated text input UI control + /// @param[out] password_mode Password mode information \n @c true to indicate that a password being inputted, + /// @c false to indicate non-password edit field. + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @post Input panel UI should be drawn or operated by this information accordingly. + /// + /// @see ime_show_cb() + int ime_context_get_password_mode( + ffi.Pointer<_ime_context> context, + ffi.Pointer password_mode, + ) { + return _ime_context_get_password_mode( + context, + password_mode, + ); + } + + late final _ime_context_get_password_mode_ptr = + _lookup>( + 'ime_context_get_password_mode'); + late final _dart_ime_context_get_password_mode + _ime_context_get_password_mode = _ime_context_get_password_mode_ptr + .asFunction<_dart_ime_context_get_password_mode>(); + + /// @brief Gets the input hint information from the given input context. + /// + /// @details Each edit field has various attributes for input panel. This function can be + /// called to get the input hint information in ime_show_cb() callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks @a input_hint is a bit-wise value which recommends the input panel provide + /// an auto completion and so on if it is capable of supporting such features. + /// + /// @param[in] context The input context information of an associated text input UI control + /// @param[out] input_hint Input hint information + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @post Input panel UI should be drawn or operated by this information accordingly. + /// + /// @see ime_show_cb() + int ime_context_get_input_hint( + ffi.Pointer<_ime_context> context, + ffi.Pointer input_hint, + ) { + return _ime_context_get_input_hint( + context, + input_hint, + ); + } + + late final _ime_context_get_input_hint_ptr = + _lookup>( + 'ime_context_get_input_hint'); + late final _dart_ime_context_get_input_hint _ime_context_get_input_hint = + _ime_context_get_input_hint_ptr + .asFunction<_dart_ime_context_get_input_hint>(); + + /// @brief Gets the text bidirectional information from the given input context. + /// + /// @details Each edit field has various attributes for input panel. This function can be + /// called to get the bidirectional information in ime_show_cb() callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] context The input context information of an associated text input UI control + /// @param[out] bidi Text bidirectional information + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @post Input panel UI should be drawn or operated by this information accordingly. + /// + /// @see ime_show_cb() + int ime_context_get_bidi_direction( + ffi.Pointer<_ime_context> context, + ffi.Pointer bidi, + ) { + return _ime_context_get_bidi_direction( + context, + bidi, + ); + } + + late final _ime_context_get_bidi_direction_ptr = + _lookup>( + 'ime_context_get_bidi_direction'); + late final _dart_ime_context_get_bidi_direction + _ime_context_get_bidi_direction = _ime_context_get_bidi_direction_ptr + .asFunction<_dart_ime_context_get_bidi_direction>(); + + /// @brief Gets the preferred language information from the given input context. + /// + /// @details Each edit field has various attributes for input panel. This function can be + /// called to get the preferred language information in ime_show_cb() callback function. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] context The input context information of an associated text input UI control + /// @param[out] language Preferred language information + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @post Input panel UI should be drawn or operated by this information accordingly. + /// + /// @see ime_show_cb() + int ime_context_get_language( + ffi.Pointer<_ime_context> context, + ffi.Pointer language, + ) { + return _ime_context_get_language( + context, + language, + ); + } + + late final _ime_context_get_language_ptr = + _lookup>( + 'ime_context_get_language'); + late final _dart_ime_context_get_language _ime_context_get_language = + _ime_context_get_language_ptr + .asFunction<_dart_ime_context_get_language>(); + + /// @brief Gets the device name of the key event. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks @a dev_name must be released using free(). + /// + /// @param[in] dev_info The device information from the key event + /// @param[out] dev_name The name of key input device. This can be an empty string if the device name is not available + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @see ime_process_key_event_cb() + /// @see ime_device_info_get_class() + /// @see ime_device_info_get_subclass() + int ime_device_info_get_name( + ffi.Pointer<_ime_device_info> dev_info, + ffi.Pointer> dev_name, + ) { + return _ime_device_info_get_name( + dev_info, + dev_name, + ); + } + + late final _ime_device_info_get_name_ptr = + _lookup>( + 'ime_device_info_get_name'); + late final _dart_ime_device_info_get_name _ime_device_info_get_name = + _ime_device_info_get_name_ptr + .asFunction<_dart_ime_device_info_get_name>(); + + /// @brief Gets the device class of the key event. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] dev_info The device information from the key event + /// @param[out] dev_class The class of key input device. This can be #ECORE_IMF_DEVICE_CLASS_NONE if the device class is not available + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @see ime_process_key_event_cb() + /// @see ime_device_info_get_name() + /// @see ime_device_info_get_subclass() + int ime_device_info_get_class( + ffi.Pointer<_ime_device_info> dev_info, + ffi.Pointer dev_class, + ) { + return _ime_device_info_get_class( + dev_info, + dev_class, + ); + } + + late final _ime_device_info_get_class_ptr = + _lookup>( + 'ime_device_info_get_class'); + late final _dart_ime_device_info_get_class _ime_device_info_get_class = + _ime_device_info_get_class_ptr + .asFunction<_dart_ime_device_info_get_class>(); + + /// @brief Gets the device subclass of the key event. + /// + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] dev_info The device information from the key event + /// @param[out] dev_subclass The subclass of key input device. This can be #ECORE_IMF_DEVICE_SUBCLASS_NONE if the device subclass is not available + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @see ime_process_key_event_cb() + /// @see ime_device_info_get_name() + /// @see ime_device_info_get_class() + int ime_device_info_get_subclass( + ffi.Pointer<_ime_device_info> dev_info, + ffi.Pointer dev_subclass, + ) { + return _ime_device_info_get_subclass( + dev_info, + dev_subclass, + ); + } + + late final _ime_device_info_get_subclass_ptr = + _lookup>( + 'ime_device_info_get_subclass'); + late final _dart_ime_device_info_get_subclass _ime_device_info_get_subclass = + _ime_device_info_get_subclass_ptr + .asFunction<_dart_ime_device_info_get_subclass>(); + + /// @brief Sets prediction hint event callback function. + /// + /// @since_tizen 4.0 + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_prediction_hint_set_cb() callback function is called to set the prediction + /// hint string to deliver to the input panel. + /// + /// @param[in] callback_func The prediction hint event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_prediction_hint_set_cb() + /// @see ime_run() + int ime_event_set_prediction_hint_set_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_prediction_hint_set_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_prediction_hint_set_cb_ptr = + _lookup>( + 'ime_event_set_prediction_hint_set_cb'); + late final _dart_ime_event_set_prediction_hint_set_cb + _ime_event_set_prediction_hint_set_cb = + _ime_event_set_prediction_hint_set_cb_ptr + .asFunction<_dart_ime_event_set_prediction_hint_set_cb>(); + + /// @brief Sets MIME type event callback function. + /// + /// @since_tizen 4.0 + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks The ime_mime_type_set_request_cb() callback function is called when an associated text input + /// UI control requests the text entry to set the MIME type. + /// + /// @param[in] callback_func MIME type event callback function + /// @param[in] user_data User data to be passed to the callback function + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// + /// @post The ime_run() function should be called to start to run IME application's main loop. + /// + /// @see ime_mime_type_set_request_cb() + /// @see ime_run() + int ime_event_set_mime_type_set_request_cb( + ffi.Pointer> callback_func, + ffi.Pointer user_data, + ) { + return _ime_event_set_mime_type_set_request_cb( + callback_func, + user_data, + ); + } + + late final _ime_event_set_mime_type_set_request_cb_ptr = + _lookup>( + 'ime_event_set_mime_type_set_request_cb'); + late final _dart_ime_event_set_mime_type_set_request_cb + _ime_event_set_mime_type_set_request_cb = + _ime_event_set_mime_type_set_request_cb_ptr + .asFunction<_dart_ime_event_set_mime_type_set_request_cb>(); + + /// @brief Sends a private command to the associated text input UI control. + /// + /// @details This can be used by IME to deliver specific data to an application. + /// The data format MUST be negotiated by both application and IME. + /// + /// @since_tizen 4.0 + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] command The UTF-8 string to be sent + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + int ime_send_private_command( + ffi.Pointer command, + ) { + return _ime_send_private_command( + command, + ); + } + + late final _ime_send_private_command_ptr = + _lookup>( + 'ime_send_private_command'); + late final _dart_ime_send_private_command _ime_send_private_command = + _ime_send_private_command_ptr + .asFunction<_dart_ime_send_private_command>(); + + /// @brief Commits contents such as image to the associated text input UI control. + /// + /// @since_tizen 4.0 + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] content The content URI to be sent + /// @param[in] description The content description + /// @param[in] mime_type The MIME type received from the ime_mime_type_set_request_cb() + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @see ime_mime_type_set_request_cb() + /// @see ime_event_set_mime_type_set_request_cb() + int ime_commit_content( + ffi.Pointer content, + ffi.Pointer description, + ffi.Pointer mime_type, + ) { + return _ime_commit_content( + content, + description, + mime_type, + ); + } + + late final _ime_commit_content_ptr = + _lookup>('ime_commit_content'); + late final _dart_ime_commit_content _ime_commit_content = + _ime_commit_content_ptr.asFunction<_dart_ime_commit_content>(); + + /// @brief Sets the floating mode or not. + /// + /// @since_tizen 4.0 + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @param[in] floating_mode @c true - floating mode on, @c false - floating mode off + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @see ime_set_floating_drag_start() + /// @see ime_set_floating_drag_end() + int ime_set_floating_mode( + bool floating_mode, + ) { + return _ime_set_floating_mode( + floating_mode ? 1 : 0, + ); + } + + late final _ime_set_floating_mode_ptr = + _lookup>( + 'ime_set_floating_mode'); + late final _dart_ime_set_floating_mode _ime_set_floating_mode = + _ime_set_floating_mode_ptr.asFunction<_dart_ime_set_floating_mode>(); + + /// @brief Allows the floating input panel window to move along with the mouse pointer when the mouse is pressed. + /// + /// @since_tizen 4.0 + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks This function can be used in floating mode. If the floating mode is deactivated, calling this function has no effect. + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @pre The floating mode was turned on with ime_set_floating_mode(). + /// + /// @see ime_set_floating_mode() + /// @see ime_set_floating_drag_end() + int ime_set_floating_drag_start() { + return _ime_set_floating_drag_start(); + } + + late final _ime_set_floating_drag_start_ptr = + _lookup>( + 'ime_set_floating_drag_start'); + late final _dart_ime_set_floating_drag_start _ime_set_floating_drag_start = + _ime_set_floating_drag_start_ptr + .asFunction<_dart_ime_set_floating_drag_start>(); + + /// @brief Disallows the movement of the floating input panel window with the mouse pointer when the mouse is pressed. + /// + /// @details This function must be called after invoking ime_set_floating_drag_start(). Otherwise the call is ignored. + /// + /// @since_tizen 4.0 + /// + /// @privlevel public + /// + /// @privilege %http://tizen.org/privilege/ime + /// + /// @remarks This function can be used in floating mode. If the floating mode is deactivated, calling this function has no effect. + /// + /// @return 0 on success, otherwise a negative error value + /// @retval #IME_ERROR_NONE No error + /// @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet + /// + /// @pre The floating mode was turned on with ime_set_floating_mode(). + /// @pre ime_set_floating_drag_start() was called before. + /// + /// @see ime_set_floating_mode() + /// @see ime_set_floating_drag_start() + int ime_set_floating_drag_end() { + return _ime_set_floating_drag_end(); + } + + late final _ime_set_floating_drag_end_ptr = + _lookup>( + 'ime_set_floating_drag_end'); + late final _dart_ime_set_floating_drag_end _ime_set_floating_drag_end = + _ime_set_floating_drag_end_ptr + .asFunction<_dart_ime_set_floating_drag_end>(); + + /// @brief Requests to open the installed IME list menu. + /// @details This function provides the installed IME list menu for the IME developers who might want to open it to enable their IME. + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/imemanager + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IME_MANAGER_ERROR_NONE No error + /// @retval #IME_MANAGER_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @see ime_manager_show_ime_selector() + int ime_manager_show_ime_list() { + return _ime_manager_show_ime_list(); + } + + late final _ime_manager_show_ime_list_ptr = + _lookup>( + 'ime_manager_show_ime_list'); + late final _dart_ime_manager_show_ime_list _ime_manager_show_ime_list = + _ime_manager_show_ime_list_ptr + .asFunction<_dart_ime_manager_show_ime_list>(); + + /// @brief Requests to open the IME selector menu. + /// @details This function provides the IME selector menu for the IME or other application developers who might want to change the default IME. + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/imemanager + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IME_MANAGER_ERROR_NONE No error + /// @retval #IME_MANAGER_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @see ime_manager_show_ime_list() + int ime_manager_show_ime_selector() { + return _ime_manager_show_ime_selector(); + } + + late final _ime_manager_show_ime_selector_ptr = + _lookup>( + 'ime_manager_show_ime_selector'); + late final _dart_ime_manager_show_ime_selector + _ime_manager_show_ime_selector = _ime_manager_show_ime_selector_ptr + .asFunction<_dart_ime_manager_show_ime_selector>(); + + /// @brief Checks if the specific IME is enabled or disabled in the system keyboard setting. + /// @details The IME developers can use this function to check their IME is enabled or not. + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/imemanager + /// @param[in] app_id The application ID of the IME + /// @param[out] enabled The On (enabled) and Off (disabled) state of the IME + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IME_MANAGER_ERROR_NONE No error + /// @retval #IME_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_MANAGER_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @see ime_manager_show_ime_list() + int ime_manager_is_ime_enabled( + ffi.Pointer app_id, + ffi.Pointer enabled, + ) { + return _ime_manager_is_ime_enabled( + app_id, + enabled, + ); + } + + late final _ime_manager_is_ime_enabled_ptr = + _lookup>( + 'ime_manager_is_ime_enabled'); + late final _dart_ime_manager_is_ime_enabled _ime_manager_is_ime_enabled = + _ime_manager_is_ime_enabled_ptr + .asFunction<_dart_ime_manager_is_ime_enabled>(); + + /// @brief Checks which IME is the current activated (selected) IME. + /// @since_tizen @if MOBILE 2.4 @else 3.0 @endif + /// @remarks @a app_id must be released using free(). + /// @privlevel public + /// @privilege %http://tizen.org/privilege/imemanager + /// @param[out] app_id The application ID of the active IME + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #IME_MANAGER_ERROR_NONE No error + /// @retval #IME_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #IME_MANAGER_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @retval #IME_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @see ime_manager_show_ime_selector() + int ime_manager_get_active_ime( + ffi.Pointer> app_id, + ) { + return _ime_manager_get_active_ime( + app_id, + ); + } + + late final _ime_manager_get_active_ime_ptr = + _lookup>( + 'ime_manager_get_active_ime'); + late final _dart_ime_manager_get_active_ime _ime_manager_get_active_ime = + _ime_manager_get_active_ime_ptr + .asFunction<_dart_ime_manager_get_active_ime>(); + + /// @brief Gets the number of IMEs which are enabled (usable). + /// @since_tizen 3.0 + /// @remarks The specific error code can be obtained using the get_last_result() method. + /// Error codes are described in Exception section. + /// @privlevel public + /// @privilege %http://tizen.org/privilege/imemanager + /// @return The @a number of enabled IMEs on success, + /// otherwise @c 0 + /// @exception IME_MANAGER_ERROR_NONE Successful + /// @exception IME_MANAGER_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function + /// @exception IME_MANAGER_ERROR_OPERATION_FAILED Operation failed + /// @see ime_manager_is_ime_enabled() + /// @see ime_manager_show_ime_selector() + int ime_manager_get_enabled_ime_count() { + return _ime_manager_get_enabled_ime_count(); + } + + late final _ime_manager_get_enabled_ime_count_ptr = + _lookup>( + 'ime_manager_get_enabled_ime_count'); + late final _dart_ime_manager_get_enabled_ime_count + _ime_manager_get_enabled_ime_count = + _ime_manager_get_enabled_ime_count_ptr + .asFunction<_dart_ime_manager_get_enabled_ime_count>(); + + /// @brief Creates a STT handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks If the function succeeds, @a stt handle must be released with stt_destroy(). + /// @param[out] stt The STT handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @post If this function is called, the STT state will be #STT_STATE_CREATED. + /// @see stt_destroy() + int stt_create( + ffi.Pointer> stt, + ) { + return _stt_create( + stt, + ); + } + + late final _stt_create_ptr = + _lookup>('stt_create'); + late final _dart_stt_create _stt_create = + _stt_create_ptr.asFunction<_dart_stt_create>(); + + /// @brief Destroys a STT handle. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @see stt_create() + int stt_destroy( + ffi.Pointer stt, + ) { + return _stt_destroy( + stt, + ); + } + + late final _stt_destroy_ptr = + _lookup>('stt_destroy'); + late final _dart_stt_destroy _stt_destroy = + _stt_destroy_ptr.asFunction<_dart_stt_destroy>(); + + /// @brief Retrieves supported engine information using a callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Success + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE STT Not initialized + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_CREATED. + /// @post This function invokes stt_supported_engine_cb() repeatedly for getting engine information. + /// @see stt_supported_engine_cb() + int stt_foreach_supported_engines( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _stt_foreach_supported_engines( + stt, + callback, + user_data, + ); + } + + late final _stt_foreach_supported_engines_ptr = + _lookup>( + 'stt_foreach_supported_engines'); + late final _dart_stt_foreach_supported_engines + _stt_foreach_supported_engines = _stt_foreach_supported_engines_ptr + .asFunction<_dart_stt_foreach_supported_engines>(); + + /// @brief Gets the current engine ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks If the function is success, @a engine_id must be released using free(). + /// @param[in] stt The STT handle + /// @param[out] engine_id Engine ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Success + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE STT Not initialized + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_CREATED. + /// @see stt_set_engine() + int stt_get_engine( + ffi.Pointer stt, + ffi.Pointer> engine_id, + ) { + return _stt_get_engine( + stt, + engine_id, + ); + } + + late final _stt_get_engine_ptr = + _lookup>('stt_get_engine'); + late final _dart_stt_get_engine _stt_get_engine = + _stt_get_engine_ptr.asFunction<_dart_stt_get_engine>(); + + /// @brief Sets the engine ID. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @privilege %http://tizen.org/privilege/appmanager.launch + /// @remarks A privilege (%http://tizen.org/privilege/appmanager.launch) is necessary since 3.0. + /// @param[in] stt The STT handle + /// @param[in] engine_id Engine ID + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Success + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE STT Not initialized + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_CREATED. + /// @see stt_get_engine() + int stt_set_engine( + ffi.Pointer stt, + ffi.Pointer engine_id, + ) { + return _stt_set_engine( + stt, + engine_id, + ); + } + + late final _stt_set_engine_ptr = + _lookup>('stt_set_engine'); + late final _dart_stt_set_engine _stt_set_engine = + _stt_set_engine_ptr.asFunction<_dart_stt_set_engine>(); + + /// @brief Sets the app credential. + /// @details Using this API, the application can set a credential. + /// The credential is a key to verify the authorization about using the engine. + /// If the application sets the credential, it will be able to use functions of the engine entirely. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The necessity of the credential depends on the engine. In case of the engine which is basically embedded in Tizen, the credential is not necessary so far. + /// However, if the user wants to apply the 3rd party's engine, the credential may be necessary. In that case, please follow the policy provided by the corresponding engine. + /// @param[in] stt The STT handle + /// @param[in] credential The app credential + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Success + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @pre The state should be #STT_STATE_CREATED or #STT_STATE_READY. + /// @see stt_start() + int stt_set_credential( + ffi.Pointer stt, + ffi.Pointer credential, + ) { + return _stt_set_credential( + stt, + credential, + ); + } + + late final _stt_set_credential_ptr = + _lookup>('stt_set_credential'); + late final _dart_stt_set_credential _stt_set_credential = + _stt_set_credential_ptr.asFunction<_dart_stt_set_credential>(); + + /// @brief Sets the private data to stt engine. + /// @details The private data is the setting parameter for applying keys provided by the engine. + /// Using this API, the application can set the private data and use the corresponding key of the engine. + /// For example, if the engine provides 'partial recognition' as a recognition type, the application can set the private data as the following. + /// int ret = stt_set_private_data(stt_h, "recognition_type", "PARTIAL"); + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks If the engine is replaced with the other engine, the key may be ignored. + /// @param[in] stt The STT handle + /// @param[in] key The field name of private data + /// @param[in] data The data for set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_TIMED_OUT No answer from the STT service + /// @pre The state should be #STT_STATE_READY. + /// @see stt_get_private_data() + int stt_set_private_data( + ffi.Pointer stt, + ffi.Pointer key, + ffi.Pointer data, + ) { + return _stt_set_private_data( + stt, + key, + data, + ); + } + + late final _stt_set_private_data_ptr = + _lookup>( + 'stt_set_private_data'); + late final _dart_stt_set_private_data _stt_set_private_data = + _stt_set_private_data_ptr.asFunction<_dart_stt_set_private_data>(); + + /// @brief Gets the private data from stt engine. + /// @details The private data is the information provided by the engine. + /// Using this API, the application can get the private data which corresponds to the key from the engine. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks If the engine is replaced with the other engine, the key may be ignored. + /// @remarks The @a data must be released using free() when it is no longer required. + /// @param[in] stt The STT handle + /// @param[in] key The field name of private data + /// @param[out] data The data field of private data + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_TIMED_OUT No answer from the STT service + /// @pre The state should be #STT_STATE_READY. + /// @see stt_set_private_data() + int stt_get_private_data( + ffi.Pointer stt, + ffi.Pointer key, + ffi.Pointer> data, + ) { + return _stt_get_private_data( + stt, + key, + data, + ); + } + + late final _stt_get_private_data_ptr = + _lookup>( + 'stt_get_private_data'); + late final _dart_stt_get_private_data _stt_get_private_data = + _stt_get_private_data_ptr.asFunction<_dart_stt_get_private_data>(); + + /// @brief Connects the STT service asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_CREATED. + /// @post If this function is successful, the STT state will be #STT_STATE_READY. + /// If this function is failed, the error callback is called. (e.g. #STT_ERROR_ENGINE_NOT_FOUND) + /// @see stt_unprepare() + int stt_prepare( + ffi.Pointer stt, + ) { + return _stt_prepare( + stt, + ); + } + + late final _stt_prepare_ptr = + _lookup>('stt_prepare'); + late final _dart_stt_prepare _stt_prepare = + _stt_prepare_ptr.asFunction<_dart_stt_prepare>(); + + /// @brief Disconnects the STT service. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_READY. + /// @post If this function is called, the STT state will be #STT_STATE_CREATED. + /// @see stt_prepare() + int stt_unprepare( + ffi.Pointer stt, + ) { + return _stt_unprepare( + stt, + ); + } + + late final _stt_unprepare_ptr = + _lookup>('stt_unprepare'); + late final _dart_stt_unprepare _stt_unprepare = + _stt_unprepare_ptr.asFunction<_dart_stt_unprepare>(); + + /// @brief Retrieves all supported languages of current engine using callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_ENGINE_NOT_FOUND No available engine + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @post This function invokes stt_supported_language_cb() repeatedly for getting languages. + /// @see stt_supported_language_cb() + /// @see stt_get_default_language() + int stt_foreach_supported_languages( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _stt_foreach_supported_languages( + stt, + callback, + user_data, + ); + } + + late final _stt_foreach_supported_languages_ptr = + _lookup>( + 'stt_foreach_supported_languages'); + late final _dart_stt_foreach_supported_languages + _stt_foreach_supported_languages = _stt_foreach_supported_languages_ptr + .asFunction<_dart_stt_foreach_supported_languages>(); + + /// @brief Gets the default language set by the user. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks The language is specified as an ISO 3166 alpha-2 two letter country-code followed by ISO 639-1 for the two-letter language code. + /// For example, "ko_KR" for Korean, "en_US" for American English. + /// If the function succeeds, @a language must be released using free() when it is no longer required. + /// @param[in] stt The STT handle + /// @param[out] language The language + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @see stt_foreach_supported_languages() + int stt_get_default_language( + ffi.Pointer stt, + ffi.Pointer> language, + ) { + return _stt_get_default_language( + stt, + language, + ); + } + + late final _stt_get_default_language_ptr = + _lookup>( + 'stt_get_default_language'); + late final _dart_stt_get_default_language _stt_get_default_language = + _stt_get_default_language_ptr + .asFunction<_dart_stt_get_default_language>(); + + /// @brief Gets the current STT state. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @param[out] state The current STT state + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @see stt_start() + /// @see stt_stop() + /// @see stt_cancel() + /// @see stt_state_changed_cb() + int stt_get_state( + ffi.Pointer stt, + ffi.Pointer state, + ) { + return _stt_get_state( + stt, + state, + ); + } + + late final _stt_get_state_ptr = + _lookup>('stt_get_state'); + late final _dart_stt_get_state _stt_get_state = + _stt_get_state_ptr.asFunction<_dart_stt_get_state>(); + + /// @brief Gets the current error message. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks This function should be called during an stt error callback. If not, the error as operation failure will be returned. + /// If the function succeeds, @a err_msg must be released using free() when it is no longer required. + /// @param[in] stt The STT handle + /// @param[out] err_msg The current error message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @see stt_set_error_cb() + /// @see stt_unset_error_cb() + int stt_get_error_message( + ffi.Pointer stt, + ffi.Pointer> err_msg, + ) { + return _stt_get_error_message( + stt, + err_msg, + ); + } + + late final _stt_get_error_message_ptr = + _lookup>( + 'stt_get_error_message'); + late final _dart_stt_get_error_message _stt_get_error_message = + _stt_get_error_message_ptr.asFunction<_dart_stt_get_error_message>(); + + /// @brief Checks whether the recognition type is supported. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @param[in] type The type for recognition (e.g. #STT_RECOGNITION_TYPE_FREE, #STT_RECOGNITION_TYPE_FREE_PARTIAL) + /// @param[out] support The result status @c true = supported, + /// @c false = not supported + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_READY. + int stt_is_recognition_type_supported( + ffi.Pointer stt, + ffi.Pointer type, + ffi.Pointer support, + ) { + return _stt_is_recognition_type_supported( + stt, + type, + support, + ); + } + + late final _stt_is_recognition_type_supported_ptr = + _lookup>( + 'stt_is_recognition_type_supported'); + late final _dart_stt_is_recognition_type_supported + _stt_is_recognition_type_supported = + _stt_is_recognition_type_supported_ptr + .asFunction<_dart_stt_is_recognition_type_supported>(); + + /// @brief Sets the silence detection. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @param[in] type The option type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED_FEATURE Not supported feature of current engine + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_READY. + int stt_set_silence_detection( + ffi.Pointer stt, + int type, + ) { + return _stt_set_silence_detection( + stt, + type, + ); + } + + late final _stt_set_silence_detection_ptr = + _lookup>( + 'stt_set_silence_detection'); + late final _dart_stt_set_silence_detection _stt_set_silence_detection = + _stt_set_silence_detection_ptr + .asFunction<_dart_stt_set_silence_detection>(); + + /// @brief Sets the sound to start recording. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks Sound file type should be wav type. + /// @param[in] stt The STT handle + /// @param[in] filename The sound file path + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_READY. + int stt_set_start_sound( + ffi.Pointer stt, + ffi.Pointer filename, + ) { + return _stt_set_start_sound( + stt, + filename, + ); + } + + late final _stt_set_start_sound_ptr = + _lookup>( + 'stt_set_start_sound'); + late final _dart_stt_set_start_sound _stt_set_start_sound = + _stt_set_start_sound_ptr.asFunction<_dart_stt_set_start_sound>(); + + /// @brief Unsets the sound to start recording. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_READY. + int stt_unset_start_sound( + ffi.Pointer stt, + ) { + return _stt_unset_start_sound( + stt, + ); + } + + late final _stt_unset_start_sound_ptr = + _lookup>( + 'stt_unset_start_sound'); + late final _dart_stt_unset_start_sound _stt_unset_start_sound = + _stt_unset_start_sound_ptr.asFunction<_dart_stt_unset_start_sound>(); + + /// @brief Sets the sound to stop recording. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks Sound file type should be wav type. + /// @param[in] stt The STT handle + /// @param[in] filename The sound file path + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_READY. + int stt_set_stop_sound( + ffi.Pointer stt, + ffi.Pointer filename, + ) { + return _stt_set_stop_sound( + stt, + filename, + ); + } + + late final _stt_set_stop_sound_ptr = + _lookup>('stt_set_stop_sound'); + late final _dart_stt_set_stop_sound _stt_set_stop_sound = + _stt_set_stop_sound_ptr.asFunction<_dart_stt_set_stop_sound>(); + + /// @brief Unsets the sound to stop recording. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_READY. + int stt_unset_stop_sound( + ffi.Pointer stt, + ) { + return _stt_unset_stop_sound( + stt, + ); + } + + late final _stt_unset_stop_sound_ptr = + _lookup>( + 'stt_unset_stop_sound'); + late final _dart_stt_unset_stop_sound _stt_unset_stop_sound = + _stt_unset_stop_sound_ptr.asFunction<_dart_stt_unset_stop_sound>(); + + /// @brief Starts recording and recognition asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks This function starts recording in the STT service and sending recording data to engine. + /// This work continues until stt_stop(), stt_cancel() or silence detected by engine. + /// @param[in] stt The STT handle + /// @param[in] language The language selected from stt_foreach_supported_languages() + /// @param[in] type The type for recognition (e.g. #STT_RECOGNITION_TYPE_FREE, #STT_RECOGNITION_TYPE_FREE_PARTIAL) + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_RECORDER_BUSY Recorder busy + /// @retval #STT_ERROR_INVALID_LANGUAGE Invalid language + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #STT_ERROR_IN_PROGRESS_TO_RECORDING Progress to recording is not finished + /// @pre The state should be #STT_STATE_READY. + /// @post It will invoke stt_state_changed_cb(), if you register a callback with stt_state_changed_cb(). + /// If this function succeeds, the STT state will be #STT_STATE_RECORDING. + /// If you call this function again before state changes, you will receive STT_ERROR_IN_PROGRESS_TO_RECORDING. + /// @see stt_stop() + /// @see stt_cancel() + /// @see stt_state_changed_cb() + int stt_start( + ffi.Pointer stt, + ffi.Pointer language, + ffi.Pointer type, + ) { + return _stt_start( + stt, + language, + type, + ); + } + + late final _stt_start_ptr = + _lookup>('stt_start'); + late final _dart_stt_start _stt_start = + _stt_start_ptr.asFunction<_dart_stt_start>(); + + /// @brief Finishes the recording and starts recognition processing in engine asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #STT_ERROR_IN_PROGRESS_TO_READY Progress to ready is not finished + /// @retval #STT_ERROR_IN_PROGRESS_TO_RECORDING Progress to recording is not finished + /// @retval #STT_ERROR_IN_PROGRESS_TO_PROCESSING Progress to processing is not finished + /// @pre The state should be #STT_STATE_RECORDING. + /// @post It will invoke stt_state_changed_cb(), if you register a callback with stt_state_changed_cb(). + /// If this function succeeds, the STT state will be #STT_STATE_PROCESSING. + /// If you call this function again before state changes, you will receive STT_ERROR_IN_PROGRESS_TO_PROCESSING. + /// After processing of engine, stt_result_cb() is called. + /// @see stt_start() + /// @see stt_cancel() + /// @see stt_state_changed_cb() + int stt_stop( + ffi.Pointer stt, + ) { + return _stt_stop( + stt, + ); + } + + late final _stt_stop_ptr = + _lookup>('stt_stop'); + late final _dart_stt_stop _stt_stop = + _stt_stop_ptr.asFunction<_dart_stt_stop>(); + + /// @brief Cancels processing recognition and recording asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks This function cancels recording and engine cancels recognition processing. + /// After successful cancel, stt_state_changed_cb() is called otherwise if error is occurred, stt_error_cb() is called. + /// @param[in] stt The STT handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @retval #STT_ERROR_IN_PROGRESS_TO_READY Progress to ready is not finished + /// @retval #STT_ERROR_IN_PROGRESS_TO_RECORDING Progress to recording is not finished + /// @retval #STT_ERROR_IN_PROGRESS_TO_PROCESSING Progress to processing is not finished + /// @pre The state should be #STT_STATE_RECORDING or #STT_STATE_PROCESSING. + /// @post It will invoke stt_state_changed_cb(), if you register a callback with stt_state_changed_cb(). + /// If this function succeeds, the STT state will be #STT_STATE_READY. + /// If you call this function again before state changes, you will receive STT_ERROR_IN_PROGRESS_TO_READY. + /// @see stt_start() + /// @see stt_stop() + /// @see stt_state_changed_cb() + int stt_cancel( + ffi.Pointer stt, + ) { + return _stt_cancel( + stt, + ); + } + + late final _stt_cancel_ptr = + _lookup>('stt_cancel'); + late final _dart_stt_cancel _stt_cancel = + _stt_cancel_ptr.asFunction<_dart_stt_cancel>(); + + /// @brief Gets the microphone volume during recording. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @param[out] volume Recording volume + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_RECORDING. + /// @see stt_start() + int stt_get_recording_volume( + ffi.Pointer stt, + ffi.Pointer volume, + ) { + return _stt_get_recording_volume( + stt, + volume, + ); + } + + late final _stt_get_recording_volume_ptr = + _lookup>( + 'stt_get_recording_volume'); + late final _dart_stt_get_recording_volume _stt_get_recording_volume = + _stt_get_recording_volume_ptr + .asFunction<_dart_stt_get_recording_volume>(); + + /// @brief Retrieves the time stamp of the current recognition result using the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks This function should be called in stt_recognition_result_cb(). + /// After stt_recognition_result_cb(), result data is NOT valid. + /// @param[in] stt The STT handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_OPERATION_FAILED Operation failure + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre This function should be called in stt_recognition_result_cb(). + /// @post This function invokes stt_result_time_cb() repeatedly for getting time information. + /// @see stt_result_time_cb() + /// @see stt_recognition_result_cb() + int stt_foreach_detailed_result( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _stt_foreach_detailed_result( + stt, + callback, + user_data, + ); + } + + late final _stt_foreach_detailed_result_ptr = + _lookup>( + 'stt_foreach_detailed_result'); + late final _dart_stt_foreach_detailed_result _stt_foreach_detailed_result = + _stt_foreach_detailed_result_ptr + .asFunction<_dart_stt_foreach_detailed_result>(); + + /// @brief Registers a callback function to get the recognition result. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_CREATED. + /// @see stt_recognition_result_cb() + /// @see stt_unset_recognition_result_cb() + int stt_set_recognition_result_cb( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _stt_set_recognition_result_cb( + stt, + callback, + user_data, + ); + } + + late final _stt_set_recognition_result_cb_ptr = + _lookup>( + 'stt_set_recognition_result_cb'); + late final _dart_stt_set_recognition_result_cb + _stt_set_recognition_result_cb = _stt_set_recognition_result_cb_ptr + .asFunction<_dart_stt_set_recognition_result_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_CREATED. + /// @see stt_set_recognition_result_cb() + int stt_unset_recognition_result_cb( + ffi.Pointer stt, + ) { + return _stt_unset_recognition_result_cb( + stt, + ); + } + + late final _stt_unset_recognition_result_cb_ptr = + _lookup>( + 'stt_unset_recognition_result_cb'); + late final _dart_stt_unset_recognition_result_cb + _stt_unset_recognition_result_cb = _stt_unset_recognition_result_cb_ptr + .asFunction<_dart_stt_unset_recognition_result_cb>(); + + /// @brief Registers a callback function to be called when STT state changes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_CREATED. + /// @see stt_state_changed_cb() + /// @see stt_unset_state_changed_cb() + int stt_set_state_changed_cb( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _stt_set_state_changed_cb( + stt, + callback, + user_data, + ); + } + + late final _stt_set_state_changed_cb_ptr = + _lookup>( + 'stt_set_state_changed_cb'); + late final _dart_stt_set_state_changed_cb _stt_set_state_changed_cb = + _stt_set_state_changed_cb_ptr + .asFunction<_dart_stt_set_state_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_CREATED. + /// @see stt_set_state_changed_cb() + int stt_unset_state_changed_cb( + ffi.Pointer stt, + ) { + return _stt_unset_state_changed_cb( + stt, + ); + } + + late final _stt_unset_state_changed_cb_ptr = + _lookup>( + 'stt_unset_state_changed_cb'); + late final _dart_stt_unset_state_changed_cb _stt_unset_state_changed_cb = + _stt_unset_state_changed_cb_ptr + .asFunction<_dart_stt_unset_state_changed_cb>(); + + /// @brief Registers a callback function to be called when an error occurred. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_CREATED. + /// @see stt_error_cb() + /// @see stt_unset_error_cb() + int stt_set_error_cb( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _stt_set_error_cb( + stt, + callback, + user_data, + ); + } + + late final _stt_set_error_cb_ptr = + _lookup>('stt_set_error_cb'); + late final _dart_stt_set_error_cb _stt_set_error_cb = + _stt_set_error_cb_ptr.asFunction<_dart_stt_set_error_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_CREATED. + /// @see stt_set_error_cb() + int stt_unset_error_cb( + ffi.Pointer stt, + ) { + return _stt_unset_error_cb( + stt, + ); + } + + late final _stt_unset_error_cb_ptr = + _lookup>('stt_unset_error_cb'); + late final _dart_stt_unset_error_cb _stt_unset_error_cb = + _stt_unset_error_cb_ptr.asFunction<_dart_stt_unset_error_cb>(); + + /// @brief Registers a callback function to detect the default language change. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_CREATED. + /// @see stt_default_language_changed_cb() + /// @see stt_unset_default_language_changed_cb() + int stt_set_default_language_changed_cb( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _stt_set_default_language_changed_cb( + stt, + callback, + user_data, + ); + } + + late final _stt_set_default_language_changed_cb_ptr = + _lookup>( + 'stt_set_default_language_changed_cb'); + late final _dart_stt_set_default_language_changed_cb + _stt_set_default_language_changed_cb = + _stt_set_default_language_changed_cb_ptr + .asFunction<_dart_stt_set_default_language_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] stt The STT handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @retval #STT_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #STT_STATE_CREATED. + /// @see stt_set_default_language_changed_cb() + int stt_unset_default_language_changed_cb( + ffi.Pointer stt, + ) { + return _stt_unset_default_language_changed_cb( + stt, + ); + } + + late final _stt_unset_default_language_changed_cb_ptr = + _lookup>( + 'stt_unset_default_language_changed_cb'); + late final _dart_stt_unset_default_language_changed_cb + _stt_unset_default_language_changed_cb = + _stt_unset_default_language_changed_cb_ptr + .asFunction<_dart_stt_unset_default_language_changed_cb>(); + + /// @brief Registers a callback function to detect the engine change. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] stt The STT handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @pre The state should be #STT_STATE_CREATED. + /// @see stt_engine_changed_cb() + /// @see stt_unset_engine_changed_cb() + int stt_set_engine_changed_cb( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _stt_set_engine_changed_cb( + stt, + callback, + user_data, + ); + } + + late final _stt_set_engine_changed_cb_ptr = + _lookup>( + 'stt_set_engine_changed_cb'); + late final _dart_stt_set_engine_changed_cb _stt_set_engine_changed_cb = + _stt_set_engine_changed_cb_ptr + .asFunction<_dart_stt_set_engine_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] stt The STT handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STT_ERROR_NONE Successful + /// @retval #STT_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STT_ERROR_INVALID_STATE Invalid state + /// @retval #STT_ERROR_NOT_SUPPORTED STT NOT supported + /// @pre The state should be #STT_STATE_CREATED. + /// @see stt_set_engine_changed_cb() + int stt_unset_engine_changed_cb( + ffi.Pointer stt, + ) { + return _stt_unset_engine_changed_cb( + stt, + ); + } + + late final _stt_unset_engine_changed_cb_ptr = + _lookup>( + 'stt_unset_engine_changed_cb'); + late final _dart_stt_unset_engine_changed_cb _stt_unset_engine_changed_cb = + _stt_unset_engine_changed_cb_ptr + .asFunction<_dart_stt_unset_engine_changed_cb>(); + + /// @brief Main function for Speech-To-Text (STT) engine. + /// @details This function is the main function for operating STT engine. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks The service_app_main() should be used for working the engine after this function. + /// @param[in] argc The argument count(original) + /// @param[in] argv The argument(original) + /// @param[in] callback The structure of engine request callback function + /// @return This function returns @c zero on success, + /// or negative with error code on failure + /// @retval #STTE_ERROR_NONE Successful + /// @retval #STTE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STTE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #STTE_ERROR_NOT_SUPPORTED Not supported + /// @retval #STTE_ERROR_OPERATION_FAILED Operation failure + /// @see stte_request_callback_s + /// @code + /// #include + /// + /// // Required callback functions - MUST BE IMPLEMENTED + /// static int sttengine_get_info_cb(char** engine_uuid, char** engine_name, char** engine_setting, bool* use_network); + /// static int sttengine_initialize_cb(void); + /// static int sttengine_deinitialize_cb(void); + /// static int sttengine_is_valid_language_cb(const char* language, bool* is_valid); + /// static int sttengine_foreach_supported_langs_cb(stte_supported_language_cb callback, void* user_data); + /// static bool sttengine_support_silence_detection_cb(void); + /// static int sttengine_set_silence_detection_cb(bool is_set); + /// static int sttengine_support_recognition_type_cb(const char* type, bool* is_supported); + /// static int sttengine_get_recording_format_cb(stte_audio_type_e* types, int* rate, int* channels); + /// static int sttengine_set_recording_data_cb(const void* data, unsigned int length); + /// static int sttengine_foreach_result_time_cb(void* time_info, stte_result_time_cb callback, void* user_data); + /// static int sttengine_start_cb(const char* language, const char* type, const char* appid, const char* credential, void *user_data); + /// static int sttengine_stop_cb(void); + /// static int sttengine_cancel_cb(void); + /// static int sttengine_check_app_agreed_cb(const char* appid, bool* is_agreed); + /// static bool sttengine_need_app_credential_cb(void); + /// + /// // Optional callback function + /// static int sttengine_private_data_set_cb(const char* key, const char* data); + /// + /// int main(int argc, char* argv[]) + /// { + /// // 1. Create a structure 'stte_request_callback_s' + /// stte_request_callback_s engine_callback = { 0, }; + /// + /// engine_callback.size = sizeof(stte_request_callback_s); + /// engine_callback.version = 1; + /// engine_callback.get_info = sttengine_get_info_cb; + /// + /// engine_callback.initialize = sttengine_initialize_cb; + /// engine_callback.deinitialize = sttengine_deinitialize_cb; + /// + /// engine_callback.foreach_langs = sttengine_foreach_supported_langs_cb; + /// engine_callback.is_valid_lang = sttengine_is_valid_language_cb; + /// engine_callback.support_silence = sttengine_support_silence_detection_cb; + /// engine_callback.support_recognition_type = sttengine_support_recognition_type_cb; + /// + /// engine_callback.get_audio_format = sttengine_get_recording_format_cb; + /// engine_callback.foreach_result_time = sttengine_foreach_result_time_cb; + /// + /// engine_callback.set_silence_detection = sttengine_set_silence_detection_cb; + /// + /// engine_callback.start = sttengine_start_cb; + /// engine_callback.set_recording = sttengine_set_recording_data_cb; + /// engine_callback.stop = sttengine_stop_cb; + /// engine_callback.cancel = sttengine_cancel_cb; + /// + /// engine_callback.check_app_agreed = sttengine_check_app_agreed_cb; + /// engine_callback.need_app_credential = sttengine_need_app_credential_cb; + /// + /// // 2. Run 'stte_main()' + /// if (0 != stte_main(argc, argv, &engine_callback)) { + /// return -1; + /// } + /// + /// // Optional + /// stte_set_private_data_set_cb(sttengine_private_data_set_cb); + /// + /// // 3. Set event callbacks for service app and Run 'service_app_main()' + /// char ad[50] = { 0, }; + /// + /// service_app_lifecycle_callback_s event_callback; + /// app_event_handler_h handlers[5] = { NULL, }; + /// + /// event_callback.create = service_app_create; + /// event_callback.terminate = service_app_terminate; + /// event_callback.app_control = service_app_control; + /// + /// service_app_add_event_handler(&handlers[APP_EVENT_LOW_BATTERY], APP_EVENT_LOW_BATTERY, service_app_low_battery, &ad); + /// service_app_add_event_handler(&handlers[APP_EVENT_LOW_MEMORY], APP_EVENT_LOW_MEMORY, service_app_low_memory, &ad); + /// service_app_add_event_handler(&handlers[APP_EVENT_LANGUAGE_CHANGED], APP_EVENT_LANGUAGE_CHANGED, service_app_lang_changed, &ad); + /// service_app_add_event_handler(&handlers[APP_EVENT_REGION_FORMAT_CHANGED], APP_EVENT_REGION_FORMAT_CHANGED, service_app_region_changed, &ad); + /// + /// return service_app_main(argc, argv, &event_callback, ad); + /// } + /// + /// @endcode + int stte_main( + int argc, + ffi.Pointer> argv, + ffi.Pointer callback, + ) { + return _stte_main( + argc, + argv, + callback, + ); + } + + late final _stte_main_ptr = + _lookup>('stte_main'); + late final _dart_stte_main _stte_main = + _stte_main_ptr.asFunction<_dart_stte_main>(); + + /// @brief Sends the recognition result to the engine service user. + /// @since_tizen 3.0 + /// @remarks This API is used in stte_set_recording_data_cb() and stte_stop_cb(), when STT engine sends the recognition result to the engine service user. + /// This function is called in the following situations; 1) after stte_stop_cb() is called, 2) the end point of speech is detected from recording, or 3) partial result is occurred. + /// The recognition result and @a user_data must be transferred to the engine service user through this function. + /// Also, @a time_info must be transferred to stte_foreach_result_time_cb(). The type of @a time_info is up to the STT engine developer. + /// @param[in] event The result event + /// @param[in] type The recognition type (e.g. #STTE_RECOGNITION_TYPE_FREE, #STTE_RECOGNITION_TYPE_FREE_PARTIAL) + /// @param[in] result Result texts + /// @param[in] result_count Result text count + /// @param[in] msg Engine message (e.g. #STTE_RESULT_MESSAGE_NONE, #STTE_RESULT_MESSAGE_ERROR_TOO_SHORT) + /// @param[in] time_info The time information + /// @param[in] user_data The user data passed from stte_start_cb() + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STTE_ERROR_NONE Successful + /// @retval #STTE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STTE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #STTE_ERROR_NOT_SUPPORTED Not supported + /// @retval #STTE_ERROR_OPERATION_FAILED Operation failure + /// @pre The stte_main() function should be invoked before this function is called. + /// stte_stop_cb() will invoke this function. + /// @post This function invokes stte_foreach_result_time_cb(). + /// @see stte_start_cb() + /// @see stte_set_recording_data_cb() + /// @see stte_stop_cb() + /// @see stte_foreach_result_time_cb() + int stte_send_result( + int event, + ffi.Pointer type, + ffi.Pointer> result, + int result_count, + ffi.Pointer msg, + ffi.Pointer time_info, + ffi.Pointer user_data, + ) { + return _stte_send_result( + event, + type, + result, + result_count, + msg, + time_info, + user_data, + ); + } + + late final _stte_send_result_ptr = + _lookup>('stte_send_result'); + late final _dart_stte_send_result _stte_send_result = + _stte_send_result_ptr.asFunction<_dart_stte_send_result>(); + + /// @brief Sends the error to the engine service user. + /// @details The following error codes can be delivered. + /// #STTE_ERROR_NONE, + /// #STTE_ERROR_OUT_OF_MEMORY, + /// #STTE_ERROR_IO_ERROR, + /// #STTE_ERROR_INVALID_PARAMETER, + /// #STTE_ERROR_NETWORK_DOWN, + /// #STTE_ERROR_INVALID_STATE, + /// #STTE_ERROR_INVALID_LANGUAGE, + /// #STTE_ERROR_OPERATION_FAILED, + /// #STTE_ERROR_NOT_SUPPORTED_FEATURE, + /// #STTE_ERROR_NOT_SUPPORTED, + /// #STTE_ERROR_PERMISSION_DENIED, + /// #STTE_ERROR_RECORDING_TIMED_OUT. + /// @since_tizen 3.0 + /// @param[in] error The error reason + /// @param[in] msg The error message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STTE_ERROR_NONE Successful + /// @retval #STTE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STTE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #STTE_ERROR_NOT_SUPPORTED Not supported + /// @retval #STTE_ERROR_OPERATION_FAILED Operation failure + /// @pre The stte_main() function should be invoked before this function is called. + int stte_send_error( + int error, + ffi.Pointer msg, + ) { + return _stte_send_error( + error, + msg, + ); + } + + late final _stte_send_error_ptr = + _lookup>('stte_send_error'); + late final _dart_stte_send_error _stte_send_error = + _stte_send_error_ptr.asFunction<_dart_stte_send_error>(); + + /// @brief Sends the speech status to the engine service user when STT engine notifies the change of the speech status. + /// @since_tizen 3.0 + /// @remarks This API is invoked when STT engine wants to notify the change of the speech status anytime. + /// NOTE that this API can be invoked for recognizing the speech. + /// @param[in] status The status of speech (e.g. STTE_SPEECH_STATUS_START_POINT_DETECTED or STTE_SPEECH_STATUS_END_POINT_DETECTED) + /// @param[in] user_data The user data passed from the start function. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STTE_ERROR_NONE Successful + /// @retval #STTE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STTE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #STTE_ERROR_NOT_SUPPORTED Not supported + /// @retval #STTE_ERROR_OPERATION_FAILED Operation failure + /// @pre The stte_main() function should be invoked before this function is called. + /// stte_start_cb() and stte_set_recording_data_cb() will invoke this function. + /// @see stte_start_cb() + /// @see stte_set_recording_data_cb() + int stte_send_speech_status( + int status, + ffi.Pointer user_data, + ) { + return _stte_send_speech_status( + status, + user_data, + ); + } + + late final _stte_send_speech_status_ptr = + _lookup>( + 'stte_send_speech_status'); + late final _dart_stte_send_speech_status _stte_send_speech_status = + _stte_send_speech_status_ptr.asFunction<_dart_stte_send_speech_status>(); + + /// @brief Sets a callback function for setting the private data. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks The stte_private_data_set_cb() function is called when the engine service user sends the private data. + /// @param[in] callback_func stte_private_data_set event callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STTE_ERROR_NONE Successful + /// @retval #STTE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STTE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #STTE_ERROR_NOT_SUPPORTED Not supported + /// @retval #STTE_ERROR_OPERATION_FAILED Operation failure + /// @pre The stte_main() function should be invoked before this function is called. + /// @see stte_private_data_set_cb() + int stte_set_private_data_set_cb( + ffi.Pointer> callback_func, + ) { + return _stte_set_private_data_set_cb( + callback_func, + ); + } + + late final _stte_set_private_data_set_cb_ptr = + _lookup>( + 'stte_set_private_data_set_cb'); + late final _dart_stte_set_private_data_set_cb _stte_set_private_data_set_cb = + _stte_set_private_data_set_cb_ptr + .asFunction<_dart_stte_set_private_data_set_cb>(); + + /// @brief Sets a callback function for requesting the private data. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks The stte_private_data_requested_cb() function is called when the engine service user gets the private data from STT engine. + /// @param[in] callback_func stte_private_data_requested event callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #STTE_ERROR_NONE Successful + /// @retval #STTE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #STTE_ERROR_PERMISSION_DENIED Permission denied + /// @retval #STTE_ERROR_NOT_SUPPORTED Not supported + /// @retval #STTE_ERROR_OPERATION_FAILED Operation failure + /// @pre The stte_main() function should be invoked before this function is called. + /// @see stte_private_data_requested_cb() + int stte_set_private_data_requested_cb( + ffi.Pointer> + callback_func, + ) { + return _stte_set_private_data_requested_cb( + callback_func, + ); + } + + late final _stte_set_private_data_requested_cb_ptr = + _lookup>( + 'stte_set_private_data_requested_cb'); + late final _dart_stte_set_private_data_requested_cb + _stte_set_private_data_requested_cb = + _stte_set_private_data_requested_cb_ptr + .asFunction<_dart_stte_set_private_data_requested_cb>(); + + /// @brief Creates a handle for TTS. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If the function succeeds, @a tts handle must be released with tts_destroy(). + /// @param[out] tts The TTS handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_ENGINE_NOT_FOUND Engine not found + /// @retval #TTS_ERROR_OPERATION_FAILED Operation failure + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @post If this function is called, the TTS state will be #TTS_STATE_CREATED. + /// @see tts_destroy() + int tts_create( + ffi.Pointer> tts, + ) { + return _tts_create( + tts, + ); + } + + late final _tts_create_ptr = + _lookup>('tts_create'); + late final _dart_tts_create _tts_create = + _tts_create_ptr.asFunction<_dart_tts_create>(); + + /// @brief Destroys the handle and disconnects the daemon. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_OPERATION_FAILED Operation failure + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @see tts_create() + int tts_destroy( + ffi.Pointer tts, + ) { + return _tts_destroy( + tts, + ); + } + + late final _tts_destroy_ptr = + _lookup>('tts_destroy'); + late final _dart_tts_destroy _tts_destroy = + _tts_destroy_ptr.asFunction<_dart_tts_destroy>(); + + /// @brief Sets the TTS mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @param[in] mode The mode + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_OPERATION_FAILED Operation failure + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_get_mode() + int tts_set_mode( + ffi.Pointer tts, + int mode, + ) { + return _tts_set_mode( + tts, + mode, + ); + } + + late final _tts_set_mode_ptr = + _lookup>('tts_set_mode'); + late final _dart_tts_set_mode _tts_set_mode = + _tts_set_mode_ptr.asFunction<_dart_tts_set_mode>(); + + /// @brief Gets the TTS mode. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @param[out] mode The mode + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_set_mode() + int tts_get_mode( + ffi.Pointer tts, + ffi.Pointer mode, + ) { + return _tts_get_mode( + tts, + mode, + ); + } + + late final _tts_get_mode_ptr = + _lookup>('tts_get_mode'); + late final _dart_tts_get_mode _tts_get_mode = + _tts_get_mode_ptr.asFunction<_dart_tts_get_mode>(); + + /// @brief Sets the app credential. + /// @details Using this API, the application can set a credential. + /// The credential is a key to verify the authorization about using the engine. + /// If the application sets the credential, it will be able to use functions of the engine entirely. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The necessity of the credential depends on the engine. In case of the engine which is basically embedded in Tizen, the credential is not necessary so far. + /// However, if the user wants to apply the 3rd party's engine, the credential may be necessary. In that case, please follow the policy provided by the corresponding engine. + /// @param[in] tts The TTS handle + /// @param[in] credential The app credential + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Success + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED or #TTS_STATE_READY. + /// @see tts_play() + int tts_set_credential( + ffi.Pointer tts, + ffi.Pointer credential, + ) { + return _tts_set_credential( + tts, + credential, + ); + } + + late final _tts_set_credential_ptr = + _lookup>('tts_set_credential'); + late final _dart_tts_set_credential _tts_set_credential = + _tts_set_credential_ptr.asFunction<_dart_tts_set_credential>(); + + /// @brief Connects the daemon asynchronously. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @post If this function is successful, the TTS state will be #TTS_STATE_READY. + /// If this function is failed, the error callback is called. (e.g. #TTS_ERROR_ENGINE_NOT_FOUND) + /// @see tts_unprepare() + int tts_prepare( + ffi.Pointer tts, + ) { + return _tts_prepare( + tts, + ); + } + + late final _tts_prepare_ptr = + _lookup>('tts_prepare'); + late final _dart_tts_prepare _tts_prepare = + _tts_prepare_ptr.asFunction<_dart_tts_prepare>(); + + /// @brief Disconnects the daemon. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_READY. + /// @post If this function is called, the TTS state will be #TTS_STATE_CREATED. + /// @see tts_prepare() + int tts_unprepare( + ffi.Pointer tts, + ) { + return _tts_unprepare( + tts, + ); + } + + late final _tts_unprepare_ptr = + _lookup>('tts_unprepare'); + late final _dart_tts_unprepare _tts_unprepare = + _tts_unprepare_ptr.asFunction<_dart_tts_unprepare>(); + + /// @brief Retrieves all supported voices of the current engine using callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @param[in] callback The callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_ENGINE_NOT_FOUND Engine not found + /// @retval #TTS_ERROR_OPERATION_FAILED Operation failure + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @post This function invokes tts_supported_voice_cb() repeatedly for getting voices. + /// @see tts_get_default_voice() + int tts_foreach_supported_voices( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _tts_foreach_supported_voices( + tts, + callback, + user_data, + ); + } + + late final _tts_foreach_supported_voices_ptr = + _lookup>( + 'tts_foreach_supported_voices'); + late final _dart_tts_foreach_supported_voices _tts_foreach_supported_voices = + _tts_foreach_supported_voices_ptr + .asFunction<_dart_tts_foreach_supported_voices>(); + + /// @brief Gets the default voice set by the user. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks If the function succeeds, @a language must be released with free(). + /// @param[in] tts The TTS handle + /// @param[out] language Language specified as an ISO 3166 alpha-2 two letter country-code followed by ISO 639-1 for the two-letter language code (for example, "ko_KR" for Korean, "en_US" for American English) + /// @param[out] voice_type The voice type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_ENGINE_NOT_FOUND Engine not found + /// @retval #TTS_ERROR_OPERATION_FAILED Operation failure + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @see tts_foreach_supported_voices() + int tts_get_default_voice( + ffi.Pointer tts, + ffi.Pointer> language, + ffi.Pointer voice_type, + ) { + return _tts_get_default_voice( + tts, + language, + voice_type, + ); + } + + late final _tts_get_default_voice_ptr = + _lookup>( + 'tts_get_default_voice'); + late final _dart_tts_get_default_voice _tts_get_default_voice = + _tts_get_default_voice_ptr.asFunction<_dart_tts_get_default_voice>(); + + /// @brief Sets the private data to tts engine. + /// @details The private data is the setting parameter for applying keys provided by the engine. + /// Using this API, the application can set the private data and use the corresponding key of the engine. + /// For example, if the engine provides 'girl's voice' as a voice type, the application can set the private data as the following. + /// int ret = tts_set_private_data(tts_h, "voice_type", "GIRL"); + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks If the engine is replaced with the other engine, the key may be ignored. + /// @param[in] tts The TTS handle + /// @param[in] key The field name of private data + /// @param[in] data The data for set + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_ENGINE_NOT_FOUND Engine not found + /// @retval #TTS_ERROR_OPERATION_FAILED Operation failure + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_READY. + /// @see tts_get_private_data() + int tts_set_private_data( + ffi.Pointer tts, + ffi.Pointer key, + ffi.Pointer data, + ) { + return _tts_set_private_data( + tts, + key, + data, + ); + } + + late final _tts_set_private_data_ptr = + _lookup>( + 'tts_set_private_data'); + late final _dart_tts_set_private_data _tts_set_private_data = + _tts_set_private_data_ptr.asFunction<_dart_tts_set_private_data>(); + + /// @brief Gets the private data from tts engine. + /// @details The private data is the information provided by the engine. + /// Using this API, the application can get the private data which corresponds to the key from the engine. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks The @a data must be released using free() when it is no longer required. + /// If the engine is replaced with the other engine, the key may be ignored. + /// @param[in] tts The TTS handle + /// @param[in] key The field name of private data + /// @param[out] data The data field of private data + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_ENGINE_NOT_FOUND Engine not found + /// @retval #TTS_ERROR_OPERATION_FAILED Operation failure + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_READY. + /// @see tts_set_private_data() + int tts_get_private_data( + ffi.Pointer tts, + ffi.Pointer key, + ffi.Pointer> data, + ) { + return _tts_get_private_data( + tts, + key, + data, + ); + } + + late final _tts_get_private_data_ptr = + _lookup>( + 'tts_get_private_data'); + late final _dart_tts_get_private_data _tts_get_private_data = + _tts_get_private_data_ptr.asFunction<_dart_tts_get_private_data>(); + + /// @brief Gets the maximum byte size for text. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @param[out] size The maximum byte size for text + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_READY. + /// @see tts_add_text() + int tts_get_max_text_size( + ffi.Pointer tts, + ffi.Pointer size, + ) { + return _tts_get_max_text_size( + tts, + size, + ); + } + + late final _tts_get_max_text_size_ptr = + _lookup>( + 'tts_get_max_text_size'); + late final _dart_tts_get_max_text_size _tts_get_max_text_size = + _tts_get_max_text_size_ptr.asFunction<_dart_tts_get_max_text_size>(); + + /// @brief Gets the current state of TTS. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @param[out] state The current state of TTS + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @see tts_play() + /// @see tts_stop() + /// @see tts_pause() + int tts_get_state( + ffi.Pointer tts, + ffi.Pointer state, + ) { + return _tts_get_state( + tts, + state, + ); + } + + late final _tts_get_state_ptr = + _lookup>('tts_get_state'); + late final _dart_tts_get_state _tts_get_state = + _tts_get_state_ptr.asFunction<_dart_tts_get_state>(); + + /// @brief Gets the speed range. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @param[out] min The minimum speed value + /// @param[out] normal The normal speed value + /// @param[out] max The maximum speed value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_OPERATION_FAILED Operation failure + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_add_text() + int tts_get_speed_range( + ffi.Pointer tts, + ffi.Pointer min, + ffi.Pointer normal, + ffi.Pointer max, + ) { + return _tts_get_speed_range( + tts, + min, + normal, + max, + ); + } + + late final _tts_get_speed_range_ptr = + _lookup>( + 'tts_get_speed_range'); + late final _dart_tts_get_speed_range _tts_get_speed_range = + _tts_get_speed_range_ptr.asFunction<_dart_tts_get_speed_range>(); + + /// @brief Gets the current error message. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @remarks This function should be called from a tts error callback. Calling in any other context will result in an Operation failed error. + /// A successful call will allocate @a err_msg, which must be released by calling free() when it is no longer required. + /// @param[in] tts The TTS handle + /// @param[out] err_msg The current error message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @retval #TTS_ERROR_OPERATION_FAILED Operation failure + /// @see tts_set_error_cb() + /// @see tts_unset_error_cb() + int tts_get_error_message( + ffi.Pointer tts, + ffi.Pointer> err_msg, + ) { + return _tts_get_error_message( + tts, + err_msg, + ); + } + + late final _tts_get_error_message_ptr = + _lookup>( + 'tts_get_error_message'); + late final _dart_tts_get_error_message _tts_get_error_message = + _tts_get_error_message_ptr.asFunction<_dart_tts_get_error_message>(); + + /// @brief Adds a text to the queue. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @remarks Locale(e.g. setlocale()) MUST be set for utf8 text validation check. + /// @param[in] tts The TTS handle + /// @param[in] text An input text based utf8 + /// @param[in] language The language selected from the tts_foreach_supported_voices() (e.g. 'NULL'(Automatic), 'en_US') + /// @param[in] voice_type The voice type selected from the tts_foreach_supported_voices() (e.g. #TTS_VOICE_TYPE_AUTO, #TTS_VOICE_TYPE_FEMALE) + /// @param[in] speed A speaking speed (e.g. #TTS_SPEED_AUTO or the value from tts_get_speed_range()) + /// @param[out] utt_id The utterance ID passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_INVALID_VOICE Invalid voice about language, voice type + /// @retval #TTS_ERROR_OPERATION_FAILED Operation failure + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @retval #TTS_ERROR_PERMISSION_DENIED Permission denied + /// @pre The state should be #TTS_STATE_READY, #TTS_STATE_PLAYING or #TTS_STATE_PAUSED. + /// @see tts_get_max_text_size() + /// @see tts_set_credential() + int tts_add_text( + ffi.Pointer tts, + ffi.Pointer text, + ffi.Pointer language, + int voice_type, + int speed, + ffi.Pointer utt_id, + ) { + return _tts_add_text( + tts, + text, + language, + voice_type, + speed, + utt_id, + ); + } + + late final _tts_add_text_ptr = + _lookup>('tts_add_text'); + late final _dart_tts_add_text _tts_add_text = + _tts_add_text_ptr.asFunction<_dart_tts_add_text>(); + + /// @brief Starts synthesizing voice from the text and plays the synthesized audio data. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_OUT_OF_NETWORK Out of network + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_OPERATION_FAILED Operation failure + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @retval #TTS_ERROR_PERMISSION_DENIED Permission denied + /// @pre The current state should be #TTS_STATE_READY or #TTS_STATE_PAUSED. + /// @post If this function succeeds, the TTS state will be #TTS_STATE_PLAYING. + /// @see tts_add_text() + /// @see tts_pause() + /// @see tts_stop() + /// @see tts_utterance_started_cb() + /// @see tts_utterance_completed_cb() + /// @see tts_error_cb() + /// @see tts_set_credential() + int tts_play( + ffi.Pointer tts, + ) { + return _tts_play( + tts, + ); + } + + late final _tts_play_ptr = + _lookup>('tts_play'); + late final _dart_tts_play _tts_play = + _tts_play_ptr.asFunction<_dart_tts_play>(); + + /// @brief Stops playing the utterance and clears the queue. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_OPERATION_FAILED Operation failure + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The TTS state should be #TTS_STATE_READY or #TTS_STATE_PLAYING or #TTS_STATE_PAUSED. + /// @post If this function succeeds, the TTS state will be #TTS_STATE_READY. + /// This function will remove all text via tts_add_text() and synthesized sound data. + /// @see tts_play() + /// @see tts_pause() + int tts_stop( + ffi.Pointer tts, + ) { + return _tts_stop( + tts, + ); + } + + late final _tts_stop_ptr = + _lookup>('tts_stop'); + late final _dart_tts_stop _tts_stop = + _tts_stop_ptr.asFunction<_dart_tts_stop>(); + + /// @brief Pauses the currently playing utterance. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_OPERATION_FAILED Operation failure + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The TTS state should be #TTS_STATE_PLAYING. + /// @post If this function succeeds, the TTS state will be #TTS_STATE_PAUSED. + /// @see tts_play() + /// @see tts_stop() + /// @see tts_error_cb() + /// @see tts_interrupted_cb() + int tts_pause( + ffi.Pointer tts, + ) { + return _tts_pause( + tts, + ); + } + + late final _tts_pause_ptr = + _lookup>('tts_pause'); + late final _dart_tts_pause _tts_pause = + _tts_pause_ptr.asFunction<_dart_tts_pause>(); + + /// @brief Registers a callback function to be called when the TTS state changes. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_state_changed_cb() + /// @see tts_unset_state_changed_cb() + int tts_set_state_changed_cb( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _tts_set_state_changed_cb( + tts, + callback, + user_data, + ); + } + + late final _tts_set_state_changed_cb_ptr = + _lookup>( + 'tts_set_state_changed_cb'); + late final _dart_tts_set_state_changed_cb _tts_set_state_changed_cb = + _tts_set_state_changed_cb_ptr + .asFunction<_dart_tts_set_state_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_set_state_changed_cb() + int tts_unset_state_changed_cb( + ffi.Pointer tts, + ) { + return _tts_unset_state_changed_cb( + tts, + ); + } + + late final _tts_unset_state_changed_cb_ptr = + _lookup>( + 'tts_unset_state_changed_cb'); + late final _dart_tts_unset_state_changed_cb _tts_unset_state_changed_cb = + _tts_unset_state_changed_cb_ptr + .asFunction<_dart_tts_unset_state_changed_cb>(); + + /// @brief Registers a callback function to detect utterance start. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_utterance_started_cb() + /// @see tts_unset_utterance_started_cb() + int tts_set_utterance_started_cb( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _tts_set_utterance_started_cb( + tts, + callback, + user_data, + ); + } + + late final _tts_set_utterance_started_cb_ptr = + _lookup>( + 'tts_set_utterance_started_cb'); + late final _dart_tts_set_utterance_started_cb _tts_set_utterance_started_cb = + _tts_set_utterance_started_cb_ptr + .asFunction<_dart_tts_set_utterance_started_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_set_utterance_started_cb() + int tts_unset_utterance_started_cb( + ffi.Pointer tts, + ) { + return _tts_unset_utterance_started_cb( + tts, + ); + } + + late final _tts_unset_utterance_started_cb_ptr = + _lookup>( + 'tts_unset_utterance_started_cb'); + late final _dart_tts_unset_utterance_started_cb + _tts_unset_utterance_started_cb = _tts_unset_utterance_started_cb_ptr + .asFunction<_dart_tts_unset_utterance_started_cb>(); + + /// @brief Registers a callback function to detect utterance completion. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_utterance_completed_cb() + /// @see tts_unset_utterance_completed_cb() + int tts_set_utterance_completed_cb( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _tts_set_utterance_completed_cb( + tts, + callback, + user_data, + ); + } + + late final _tts_set_utterance_completed_cb_ptr = + _lookup>( + 'tts_set_utterance_completed_cb'); + late final _dart_tts_set_utterance_completed_cb + _tts_set_utterance_completed_cb = _tts_set_utterance_completed_cb_ptr + .asFunction<_dart_tts_set_utterance_completed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_set_utterance_completed_cb() + int tts_unset_utterance_completed_cb( + ffi.Pointer tts, + ) { + return _tts_unset_utterance_completed_cb( + tts, + ); + } + + late final _tts_unset_utterance_completed_cb_ptr = + _lookup>( + 'tts_unset_utterance_completed_cb'); + late final _dart_tts_unset_utterance_completed_cb + _tts_unset_utterance_completed_cb = _tts_unset_utterance_completed_cb_ptr + .asFunction<_dart_tts_unset_utterance_completed_cb>(); + + /// @brief Registers a callback function to detect errors. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_error_cb() + /// @see tts_unset_error_cb() + int tts_set_error_cb( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _tts_set_error_cb( + tts, + callback, + user_data, + ); + } + + late final _tts_set_error_cb_ptr = + _lookup>('tts_set_error_cb'); + late final _dart_tts_set_error_cb _tts_set_error_cb = + _tts_set_error_cb_ptr.asFunction<_dart_tts_set_error_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_set_error_cb() + int tts_unset_error_cb( + ffi.Pointer tts, + ) { + return _tts_unset_error_cb( + tts, + ); + } + + late final _tts_unset_error_cb_ptr = + _lookup>('tts_unset_error_cb'); + late final _dart_tts_unset_error_cb _tts_unset_error_cb = + _tts_unset_error_cb_ptr.asFunction<_dart_tts_unset_error_cb>(); + + /// @brief Registers a callback function to detect default voice change. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_default_voice_changed_cb() + /// @see tts_unset_default_voice_changed_cb() + int tts_set_default_voice_changed_cb( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _tts_set_default_voice_changed_cb( + tts, + callback, + user_data, + ); + } + + late final _tts_set_default_voice_changed_cb_ptr = + _lookup>( + 'tts_set_default_voice_changed_cb'); + late final _dart_tts_set_default_voice_changed_cb + _tts_set_default_voice_changed_cb = _tts_set_default_voice_changed_cb_ptr + .asFunction<_dart_tts_set_default_voice_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif + /// @param[in] tts The TTS handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_set_default_voice_changed_cb() + int tts_unset_default_voice_changed_cb( + ffi.Pointer tts, + ) { + return _tts_unset_default_voice_changed_cb( + tts, + ); + } + + late final _tts_unset_default_voice_changed_cb_ptr = + _lookup>( + 'tts_unset_default_voice_changed_cb'); + late final _dart_tts_unset_default_voice_changed_cb + _tts_unset_default_voice_changed_cb = + _tts_unset_default_voice_changed_cb_ptr + .asFunction<_dart_tts_unset_default_voice_changed_cb>(); + + /// @brief Registers a callback function to detect the engine change. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] tts The TTS handle + /// @param[in] callback The callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_engine_changed_cb() + /// @see tts_unset_engine_changed_cb() + int tts_set_engine_changed_cb( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _tts_set_engine_changed_cb( + tts, + callback, + user_data, + ); + } + + late final _tts_set_engine_changed_cb_ptr = + _lookup>( + 'tts_set_engine_changed_cb'); + late final _dart_tts_set_engine_changed_cb _tts_set_engine_changed_cb = + _tts_set_engine_changed_cb_ptr + .asFunction<_dart_tts_set_engine_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif + /// @param[in] tts The TTS handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTS_ERROR_NONE Successful + /// @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTS_ERROR_INVALID_STATE Invalid state + /// @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported + /// @pre The state should be #TTS_STATE_CREATED. + /// @see tts_set_engine_changed_cb() + int tts_unset_engine_changed_cb( + ffi.Pointer tts, + ) { + return _tts_unset_engine_changed_cb( + tts, + ); + } + + late final _tts_unset_engine_changed_cb_ptr = + _lookup>( + 'tts_unset_engine_changed_cb'); + late final _dart_tts_unset_engine_changed_cb _tts_unset_engine_changed_cb = + _tts_unset_engine_changed_cb_ptr + .asFunction<_dart_tts_unset_engine_changed_cb>(); + + /// @brief Main function for Text-To-Speech (TTS) engine. + /// @details This function is the main function for operating TTS engine. + /// @since_tizen 3.0 + /// @remarks The service_app_main() should be used for working the engine after this function. + /// @param[in] argc The argument count(original) + /// @param[in] argv The argument(original) + /// @param[in] callback The structure of engine request callback function + /// @return This function returns zero on success, + /// or negative with error code on failure + /// @retval #TTSE_ERROR_NONE Successful + /// @retval #TTSE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTSE_ERROR_OPERATION_FAILED Operation failure + /// @retval #TTSE_ERROR_NOT_SUPPORTED Not supported + /// @see ttse_request_callback_s + /// @code + /// #include + /// + /// // Required callback functions - MUST BE IMPLEMENTED + /// static int ttsengine_get_info_cb(char** engine_uuid, char** engine_name, char** engine_setting, bool* use_network); + /// static int ttsengine_initialize_cb(void); + /// static int ttsengine_deinitialize_cb(void); + /// static int ttsengine_is_valid_voice_cb(const char* language, int type, bool* is_valid); + /// static int ttsengine_foreach_supported_voices_cb(ttse_supported_voice_cb callback, void* user_data); + /// static int ttsengine_set_pitch_cb(int pitch); + /// static int ttsengine_load_voice_cb(const char* language, int type); + /// static int ttsengine_unload_voice_cb(const char* language, int type); + /// static int ttsengine_start_synthesis_cb(const char* language, int type, const char* text, int speed, void* user_data); + /// static int ttsengine_cancel_synthesis_cb(void); + /// static int ttsengine_check_app_agreed_cb(const char* appid, bool* is_agreed); + /// static bool ttsengine_need_app_credential_cb(void); + /// + /// // Optional callback function + /// static int ttsengine_private_data_set_cb(const char* key, const char* data); + /// + /// int main(int argc, char* argv[]) + /// { + /// // 1. Create a structure 'ttse_request_callback_s' + /// ttse_request_callback_s engine_callback = { 0, }; + /// + /// engine_callback.size = sizeof(ttse_request_callback_s); + /// engine_callback.version = 1; + /// engine_callback.get_info = ttsengine_get_info_cb; + /// engine_callback.initialize = ttsengine_initialize_cb; + /// engine_callback.deinitialize = ttsengine_deinitialize_cb; + /// engine_callback.foreach_voices = ttsengine_foreach_supported_voices_cb; + /// engine_callback.is_valid_voice = ttsengine_is_valid_voice_cb; + /// engine_callback.set_pitch = ttsengine_set_pitch_cb; + /// engine_callback.load_voice = ttsengine_load_voice_cb; + /// engine_callback.unload_voice = ttsengine_unload_voice_cb; + /// engine_callback.start_synth = ttsengine_start_synthesis_cb; + /// engine_callback.cancel_synth = ttsengine_cancel_synthesis_cb; + /// engine_callback.check_app_agreed = ttsengine_check_app_agreed_cb; + /// engine_callback.need_app_credential = ttsengine_need_app_credential_cb; + /// + /// // 2. Run 'ttse_main()' + /// if (0 != ttse_main(argc, argv, &engine_callback)) { + /// return -1; + /// } + /// + /// // Optional + /// ttse_set_private_data_set_cb(ttsengine_private_data_set_cb); + /// + /// // 3. Set event callbacks for service app and Run 'service_app_main()' + /// char ad[50] = { 0, }; + /// + /// service_app_lifecycle_callback_s event_callback; + /// app_event_handler_h handlers[5] = { NULL, }; + /// + /// event_callback.create = service_app_create; + /// event_callback.terminate = service_app_terminate; + /// event_callback.app_control = service_app_control; + /// + /// service_app_add_event_handler(&handlers[APP_EVENT_LOW_BATTERY], APP_EVENT_LOW_BATTERY, service_app_low_battery, &ad); + /// service_app_add_event_handler(&handlers[APP_EVENT_LOW_MEMORY], APP_EVENT_LOW_MEMORY, service_app_low_memory, &ad); + /// service_app_add_event_handler(&handlers[APP_EVENT_LANGUAGE_CHANGED], APP_EVENT_LANGUAGE_CHANGED, service_app_lang_changed, &ad); + /// service_app_add_event_handler(&handlers[APP_EVENT_REGION_FORMAT_CHANGED], APP_EVENT_REGION_FORMAT_CHANGED, service_app_region_changed, &ad); + /// + /// return service_app_main(argc, argv, &event_callback, ad); + /// } + /// + /// @endcode + int ttse_main( + int argc, + ffi.Pointer> argv, + ffi.Pointer callback, + ) { + return _ttse_main( + argc, + argv, + callback, + ); + } + + late final _ttse_main_ptr = + _lookup>('ttse_main'); + late final _dart_ttse_main _ttse_main = + _ttse_main_ptr.asFunction<_dart_ttse_main>(); + + /// @brief Gets the speed range from Tizen platform. + /// @since_tizen 3.0 + /// @remarks This API is used when TTS engine wants to get the speed range from Tizen platform. + /// @param[out] min The minimum speed value + /// @param[out] normal The normal speed value + /// @param[out] max The maximum speed value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTSE_ERROR_NONE Successful + /// @retval #TTSE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTSE_ERROR_NOT_SUPPORTED Not supported + /// @retval #TTSE_ERROR_OPERATION_FAILED Operation failure + int ttse_get_speed_range( + ffi.Pointer min, + ffi.Pointer normal, + ffi.Pointer max, + ) { + return _ttse_get_speed_range( + min, + normal, + max, + ); + } + + late final _ttse_get_speed_range_ptr = + _lookup>( + 'ttse_get_speed_range'); + late final _dart_ttse_get_speed_range _ttse_get_speed_range = + _ttse_get_speed_range_ptr.asFunction<_dart_ttse_get_speed_range>(); + + /// @brief Gets the pitch range from Tizen platform. + /// @since_tizen 3.0 + /// @remarks This API is used when TTS engine wants to get the pitch range from Tizen platform. + /// @param[out] min The minimum pitch value + /// @param[out] normal The normal pitch value + /// @param[out] max The maximum pitch value + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTSE_ERROR_NONE Successful + /// @retval #TTSE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTSE_ERROR_NOT_SUPPORTED Not supported + /// @retval #TTSE_ERROR_OPERATION_FAILED Operation failure + int ttse_get_pitch_range( + ffi.Pointer min, + ffi.Pointer normal, + ffi.Pointer max, + ) { + return _ttse_get_pitch_range( + min, + normal, + max, + ); + } + + late final _ttse_get_pitch_range_ptr = + _lookup>( + 'ttse_get_pitch_range'); + late final _dart_ttse_get_pitch_range _ttse_get_pitch_range = + _ttse_get_pitch_range_ptr.asFunction<_dart_ttse_get_pitch_range>(); + + /// @brief Sends the synthesized result to the engine service user. + /// @since_tizen 3.0 + /// @remarks This API is used in ttse_start_synthesis_cb(), when TTS engine sends the synthesized result to the engine service user. + /// The synthesized result and @a user_data must be transferred to the engine service user through this function. + /// @param[in] event The result event + /// @param[in] data Result data + /// @param[in] data_size Result data size + /// @param[in] audio_type The audio type + /// @param[in] rate The sample rate + /// @param[in] user_data The user data passed from ttse_start_synthesis_cb() + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTSE_ERROR_NONE Successful + /// @retval #TTSE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTSE_ERROR_NOT_SUPPORTED Not supported + /// @retval #TTSE_ERROR_OPERATION_FAILED Operation failure + /// @pre The ttse_main() function should be invoked before this function is called. + /// ttse_start_synthesis_cb() will invoke this function. + /// @see ttse_start_synthesis_cb() + int ttse_send_result( + int event, + ffi.Pointer data, + int data_size, + int audio_type, + int rate, + ffi.Pointer user_data, + ) { + return _ttse_send_result( + event, + data, + data_size, + audio_type, + rate, + user_data, + ); + } + + late final _ttse_send_result_ptr = + _lookup>('ttse_send_result'); + late final _dart_ttse_send_result _ttse_send_result = + _ttse_send_result_ptr.asFunction<_dart_ttse_send_result>(); + + /// @brief Sends the error to the engine service user. + /// @details The following error codes can be delivered. + /// #TTSE_ERROR_NONE, + /// #TTSE_ERROR_OUT_OF_MEMORY, + /// #TTSE_ERROR_IO_ERROR, + /// #TTSE_ERROR_INVALID_PARAMETER, + /// #TTSE_ERROR_NETWORK_DOWN, + /// #TTSE_ERROR_PERMISSION_DENIED, + /// #TTSE_ERROR_INVALID_STATE, + /// #TTSE_ERROR_INVALID_VOICE, + /// #TTSE_ERROR_OPERATION_FAILED, + /// #TTSE_ERROR_NOT_SUPPORTED_FEATURE, + /// #TTSE_ERROR_NOT_SUPPORTED. + /// @since_tizen 3.0 + /// @param[in] error The error reason + /// @param[in] msg The error message + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTSE_ERROR_NONE Successful + /// @retval #TTSE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTSE_ERROR_NOT_SUPPORTED Not supported + /// @retval #TTSE_ERROR_OPERATION_FAILED Operation failure + /// @pre The ttse_main() function should be invoked before this function is called. + int ttse_send_error( + int error, + ffi.Pointer msg, + ) { + return _ttse_send_error( + error, + msg, + ); + } + + late final _ttse_send_error_ptr = + _lookup>('ttse_send_error'); + late final _dart_ttse_send_error _ttse_send_error = + _ttse_send_error_ptr.asFunction<_dart_ttse_send_error>(); + + /// @brief Sets a callback function for setting the private data. + /// @since_tizen 3.0 + /// @remarks The ttse_private_data_set_cb() function is called when the engine service user sends the private data. + /// @param[in] callback_func ttse_private_data_set event callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTSE_ERROR_NONE Successful + /// @retval #TTSE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTSE_ERROR_NOT_SUPPORTED Not supported + /// @retval #TTSE_ERROR_OPERATION_FAILED Operation failure + /// @pre The ttse_main() function should be invoked before this function is called. + /// @see ttse_private_data_set_cb() + int ttse_set_private_data_set_cb( + ffi.Pointer> callback_func, + ) { + return _ttse_set_private_data_set_cb( + callback_func, + ); + } + + late final _ttse_set_private_data_set_cb_ptr = + _lookup>( + 'ttse_set_private_data_set_cb'); + late final _dart_ttse_set_private_data_set_cb _ttse_set_private_data_set_cb = + _ttse_set_private_data_set_cb_ptr + .asFunction<_dart_ttse_set_private_data_set_cb>(); + + /// @brief Sets a callback function for requesting the private data. + /// @since_tizen 3.0 + /// @remarks The ttse_private_data_requested_cb() function is called when the engine service user gets the private data from TTS engine. + /// @param[in] callback_func ttse_private_data_requested event callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #TTSE_ERROR_NONE Successful + /// @retval #TTSE_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #TTSE_ERROR_NOT_SUPPORTED Not supported + /// @retval #TTSE_ERROR_OPERATION_FAILED Operation failure + /// @pre The ttse_main() function should be invoked before this function is called. + /// @see ttse_private_data_requested_cb() + int ttse_set_private_data_requested_cb( + ffi.Pointer> + callback_func, + ) { + return _ttse_set_private_data_requested_cb( + callback_func, + ); + } + + late final _ttse_set_private_data_requested_cb_ptr = + _lookup>( + 'ttse_set_private_data_requested_cb'); + late final _dart_ttse_set_private_data_requested_cb + _ttse_set_private_data_requested_cb = + _ttse_set_private_data_requested_cb_ptr + .asFunction<_dart_ttse_set_private_data_requested_cb>(); + + /// @brief Creates a handle for command list. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks If the function succeeds, @a The list handle must be released with vc_cmd_list_destroy(). + /// @param[out] vc_cmd_list The command list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_list_destroy() + int vc_cmd_list_create( + ffi.Pointer> vc_cmd_list, + ) { + return _vc_cmd_list_create( + vc_cmd_list, + ); + } + + late final _vc_cmd_list_create_ptr = + _lookup>('vc_cmd_list_create'); + late final _dart_vc_cmd_list_create _vc_cmd_list_create = + _vc_cmd_list_create_ptr.asFunction<_dart_vc_cmd_list_create>(); + + /// @brief Destroys the handle for command list. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] vc_cmd_list The command list handle + /// @param[in] free_command The command free option @c true = release each commands in list, + /// @c false = remove command from list + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_list_create() + int vc_cmd_list_destroy( + ffi.Pointer vc_cmd_list, + bool free_command, + ) { + return _vc_cmd_list_destroy( + vc_cmd_list, + free_command ? 1 : 0, + ); + } + + late final _vc_cmd_list_destroy_ptr = + _lookup>( + 'vc_cmd_list_destroy'); + late final _dart_vc_cmd_list_destroy _vc_cmd_list_destroy = + _vc_cmd_list_destroy_ptr.asFunction<_dart_vc_cmd_list_destroy>(); + + /// @brief Gets command count of list. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] vc_cmd_list The command list handle + /// @param[out] count The count + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + int vc_cmd_list_get_count( + ffi.Pointer vc_cmd_list, + ffi.Pointer count, + ) { + return _vc_cmd_list_get_count( + vc_cmd_list, + count, + ); + } + + late final _vc_cmd_list_get_count_ptr = + _lookup>( + 'vc_cmd_list_get_count'); + late final _dart_vc_cmd_list_get_count _vc_cmd_list_get_count = + _vc_cmd_list_get_count_ptr.asFunction<_dart_vc_cmd_list_get_count>(); + + /// @brief Adds command to command list. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] vc_cmd_list The command list handle + /// @param[in] vc_command The command handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_list_remove() + int vc_cmd_list_add( + ffi.Pointer vc_cmd_list, + ffi.Pointer vc_command, + ) { + return _vc_cmd_list_add( + vc_cmd_list, + vc_command, + ); + } + + late final _vc_cmd_list_add_ptr = + _lookup>('vc_cmd_list_add'); + late final _dart_vc_cmd_list_add _vc_cmd_list_add = + _vc_cmd_list_add_ptr.asFunction<_dart_vc_cmd_list_add>(); + + /// @brief Removes command from command list. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] vc_cmd_list The command list handle + /// @param[in] vc_command The command handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_list_add() + int vc_cmd_list_remove( + ffi.Pointer vc_cmd_list, + ffi.Pointer vc_command, + ) { + return _vc_cmd_list_remove( + vc_cmd_list, + vc_command, + ); + } + + late final _vc_cmd_list_remove_ptr = + _lookup>('vc_cmd_list_remove'); + late final _dart_vc_cmd_list_remove _vc_cmd_list_remove = + _vc_cmd_list_remove_ptr.asFunction<_dart_vc_cmd_list_remove>(); + + /// @brief Retrieves all commands of command list using callback function. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] vc_cmd_list The command list handle + /// @param[in] callback Callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @post This function invokes vc_cmd_list_cb() repeatedly for getting commands. + /// @see vc_cmd_list_cb() + int vc_cmd_list_foreach_commands( + ffi.Pointer vc_cmd_list, + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _vc_cmd_list_foreach_commands( + vc_cmd_list, + callback, + user_data, + ); + } + + late final _vc_cmd_list_foreach_commands_ptr = + _lookup>( + 'vc_cmd_list_foreach_commands'); + late final _dart_vc_cmd_list_foreach_commands _vc_cmd_list_foreach_commands = + _vc_cmd_list_foreach_commands_ptr + .asFunction<_dart_vc_cmd_list_foreach_commands>(); + + /// @brief Moves index to first command. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] vc_cmd_list The command list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_EMPTY List empty + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_list_last() + int vc_cmd_list_first( + ffi.Pointer vc_cmd_list, + ) { + return _vc_cmd_list_first( + vc_cmd_list, + ); + } + + late final _vc_cmd_list_first_ptr = + _lookup>('vc_cmd_list_first'); + late final _dart_vc_cmd_list_first _vc_cmd_list_first = + _vc_cmd_list_first_ptr.asFunction<_dart_vc_cmd_list_first>(); + + /// @brief Moves index to last command. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] vc_cmd_list The command list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_EMPTY List empty + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_list_first() + int vc_cmd_list_last( + ffi.Pointer vc_cmd_list, + ) { + return _vc_cmd_list_last( + vc_cmd_list, + ); + } + + late final _vc_cmd_list_last_ptr = + _lookup>('vc_cmd_list_last'); + late final _dart_vc_cmd_list_last _vc_cmd_list_last = + _vc_cmd_list_last_ptr.asFunction<_dart_vc_cmd_list_last>(); + + /// @brief Moves index to next command. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] vc_cmd_list The command list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_EMPTY List empty + /// @retval #VC_ERROR_ITERATION_END List reached end + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_list_prev() + int vc_cmd_list_next( + ffi.Pointer vc_cmd_list, + ) { + return _vc_cmd_list_next( + vc_cmd_list, + ); + } + + late final _vc_cmd_list_next_ptr = + _lookup>('vc_cmd_list_next'); + late final _dart_vc_cmd_list_next _vc_cmd_list_next = + _vc_cmd_list_next_ptr.asFunction<_dart_vc_cmd_list_next>(); + + /// @brief Moves index to previous command. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] vc_cmd_list The command list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_EMPTY List empty + /// @retval #VC_ERROR_ITERATION_END List reached end + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_list_next() + int vc_cmd_list_prev( + ffi.Pointer vc_cmd_list, + ) { + return _vc_cmd_list_prev( + vc_cmd_list, + ); + } + + late final _vc_cmd_list_prev_ptr = + _lookup>('vc_cmd_list_prev'); + late final _dart_vc_cmd_list_prev _vc_cmd_list_prev = + _vc_cmd_list_prev_ptr.asFunction<_dart_vc_cmd_list_prev>(); + + /// @brief Get current command from command list by index. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] vc_cmd_list The command list handle + /// @param[out] vc_command The command handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_EMPTY List empty + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_list_first() + /// @see vc_cmd_list_last() + /// @see vc_cmd_list_prev() + /// @see vc_cmd_list_next() + int vc_cmd_list_get_current( + ffi.Pointer vc_cmd_list, + ffi.Pointer> vc_command, + ) { + return _vc_cmd_list_get_current( + vc_cmd_list, + vc_command, + ); + } + + late final _vc_cmd_list_get_current_ptr = + _lookup>( + 'vc_cmd_list_get_current'); + late final _dart_vc_cmd_list_get_current _vc_cmd_list_get_current = + _vc_cmd_list_get_current_ptr.asFunction<_dart_vc_cmd_list_get_current>(); + + /// @brief Creates a handle for command. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remarks If the function succeeds, @a The command handle must be released + /// with vc_cmd_destroy() or vc_cmd_list_destroy(). + /// You should set command and type if command is valid. + /// The command format is set to #VC_COMMAND_FORMAT_FIXED by default and can be changed with vc_cmd_set_format(). + /// @param[out] vc_command The command handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_destroy() + int vc_cmd_create( + ffi.Pointer> vc_command, + ) { + return _vc_cmd_create( + vc_command, + ); + } + + late final _vc_cmd_create_ptr = + _lookup>('vc_cmd_create'); + late final _dart_vc_cmd_create _vc_cmd_create = + _vc_cmd_create_ptr.asFunction<_dart_vc_cmd_create>(); + + /// @brief Destroys the handle. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] vc_command The command handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_create() + int vc_cmd_destroy( + ffi.Pointer vc_command, + ) { + return _vc_cmd_destroy( + vc_command, + ); + } + + late final _vc_cmd_destroy_ptr = + _lookup>('vc_cmd_destroy'); + late final _dart_vc_cmd_destroy _vc_cmd_destroy = + _vc_cmd_destroy_ptr.asFunction<_dart_vc_cmd_destroy>(); + + /// @brief Sets command or action. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] vc_command The command handle + /// @param[in] command The command or action text + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_get_command() + int vc_cmd_set_command( + ffi.Pointer vc_command, + ffi.Pointer command, + ) { + return _vc_cmd_set_command( + vc_command, + command, + ); + } + + late final _vc_cmd_set_command_ptr = + _lookup>('vc_cmd_set_command'); + late final _dart_vc_cmd_set_command _vc_cmd_set_command = + _vc_cmd_set_command_ptr.asFunction<_dart_vc_cmd_set_command>(); + + /// @brief Gets command. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remark If the function succeeds, @a command must be released with free() by you if they are not NULL. + /// @param[in] vc_command The command handle + /// @param[out] command The command text + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_set_command() + int vc_cmd_get_command( + ffi.Pointer vc_command, + ffi.Pointer> command, + ) { + return _vc_cmd_get_command( + vc_command, + command, + ); + } + + late final _vc_cmd_get_command_ptr = + _lookup>('vc_cmd_get_command'); + late final _dart_vc_cmd_get_command _vc_cmd_get_command = + _vc_cmd_get_command_ptr.asFunction<_dart_vc_cmd_get_command>(); + + /// @brief Gets the unfixed command. + /// @since_tizen 3.0 + /// @remark If the function succeeds, the @a command must be released with free() if it is not NULL. + /// If the command of the given @a vc_command is NULL (@a vc_command is NOT NULL), @a command will be also NULL. + /// This function should be used for commands which have non-fixed format. + /// @param[in] vc_command The command handle + /// @param[out] command The unfixed command text + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported feature + int vc_cmd_get_unfixed_command( + ffi.Pointer vc_command, + ffi.Pointer> command, + ) { + return _vc_cmd_get_unfixed_command( + vc_command, + command, + ); + } + + late final _vc_cmd_get_unfixed_command_ptr = + _lookup>( + 'vc_cmd_get_unfixed_command'); + late final _dart_vc_cmd_get_unfixed_command _vc_cmd_get_unfixed_command = + _vc_cmd_get_unfixed_command_ptr + .asFunction<_dart_vc_cmd_get_unfixed_command>(); + + /// @brief Sets command type. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @remark If you do not set the command type, the default value is @c -1. + /// You should set type if command is valid + /// @param[in] vc_command The command handle + /// @param[in] type The command type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_get_type() + int vc_cmd_set_type( + ffi.Pointer vc_command, + int type, + ) { + return _vc_cmd_set_type( + vc_command, + type, + ); + } + + late final _vc_cmd_set_type_ptr = + _lookup>('vc_cmd_set_type'); + late final _dart_vc_cmd_set_type _vc_cmd_set_type = + _vc_cmd_set_type_ptr.asFunction<_dart_vc_cmd_set_type>(); + + /// @brief Gets command type. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @param[in] vc_command The command handle + /// @param[out] type The command type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_cmd_set_type() + int vc_cmd_get_type( + ffi.Pointer vc_command, + ffi.Pointer type, + ) { + return _vc_cmd_get_type( + vc_command, + type, + ); + } + + late final _vc_cmd_get_type_ptr = + _lookup>('vc_cmd_get_type'); + late final _dart_vc_cmd_get_type _vc_cmd_get_type = + _vc_cmd_get_type_ptr.asFunction<_dart_vc_cmd_get_type>(); + + /// @brief Sets the command format. + /// @since_tizen 3.0 + /// @remark The default format is #VC_COMMAND_FORMAT_FIXED. + /// @param[in] vc_command The command handle + /// @param[in] format The command format + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported feature + /// @see vc_cmd_get_format() + int vc_cmd_set_format( + ffi.Pointer vc_command, + int format, + ) { + return _vc_cmd_set_format( + vc_command, + format, + ); + } + + late final _vc_cmd_set_format_ptr = + _lookup>('vc_cmd_set_format'); + late final _dart_vc_cmd_set_format _vc_cmd_set_format = + _vc_cmd_set_format_ptr.asFunction<_dart_vc_cmd_set_format>(); + + /// @brief Gets the command format. + /// @since_tizen 3.0 + /// @remark The default format is #VC_COMMAND_FORMAT_FIXED. + /// @param[in] vc_command The command handle + /// @param[out] format The command format + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported feature + /// @see vc_cmd_set_format() + int vc_cmd_get_format( + ffi.Pointer vc_command, + ffi.Pointer format, + ) { + return _vc_cmd_get_format( + vc_command, + format, + ); + } + + late final _vc_cmd_get_format_ptr = + _lookup>('vc_cmd_get_format'); + late final _dart_vc_cmd_get_format _vc_cmd_get_format = + _vc_cmd_get_format_ptr.asFunction<_dart_vc_cmd_get_format>(); + + /// @brief Initializes voice control. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks If the function succeeds, @a vc must be released with vc_deinitialize(). + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #VC_ERROR_OPERATION_FAILED Operation failure + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @post If this function is called, the state will be #VC_STATE_INITIALIZED. + /// @see vc_deinitialize() + int vc_initialize() { + return _vc_initialize(); + } + + late final _vc_initialize_ptr = + _lookup>('vc_initialize'); + late final _dart_vc_initialize _vc_initialize = + _vc_initialize_ptr.asFunction<_dart_vc_initialize>(); + + /// @brief Deinitializes voice control. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_OPERATION_FAILED Operation failure + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_deinitialize() + int vc_deinitialize() { + return _vc_deinitialize(); + } + + late final _vc_deinitialize_ptr = + _lookup>('vc_deinitialize'); + late final _dart_vc_deinitialize _vc_deinitialize = + _vc_deinitialize_ptr.asFunction<_dart_vc_deinitialize>(); + + /// @brief Connects the voice control service. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_OPERATION_FAILED Operation failure + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_INITIALIZED. + /// @post If this function is called, the state will be #VC_STATE_READY. + /// @see vc_unprepare() + int vc_prepare() { + return _vc_prepare(); + } + + late final _vc_prepare_ptr = + _lookup>('vc_prepare'); + late final _dart_vc_prepare _vc_prepare = + _vc_prepare_ptr.asFunction<_dart_vc_prepare>(); + + /// @brief Disconnects the voice control service. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_READY. + /// @post If this function is called, the state will be #VC_STATE_INITIALIZED. + /// @see vc_prepare() + int vc_unprepare() { + return _vc_unprepare(); + } + + late final _vc_unprepare_ptr = + _lookup>('vc_unprepare'); + late final _dart_vc_unprepare _vc_unprepare = + _vc_unprepare_ptr.asFunction<_dart_vc_unprepare>(); + + /// @brief Retrieves all supported languages using callback function. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] callback Callback function to invoke + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_OPERATION_FAILED Operation failure + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_INITIALIZED or #VC_STATE_READY. + /// @post This function invokes vc_supported_language_cb() repeatedly for getting languages. + /// @see vc_supported_language_cb() + /// @see vc_get_current_language() + int vc_foreach_supported_languages( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _vc_foreach_supported_languages( + callback, + user_data, + ); + } + + late final _vc_foreach_supported_languages_ptr = + _lookup>( + 'vc_foreach_supported_languages'); + late final _dart_vc_foreach_supported_languages + _vc_foreach_supported_languages = _vc_foreach_supported_languages_ptr + .asFunction<_dart_vc_foreach_supported_languages>(); + + /// @brief Gets current language. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remark If the function succeeds, @a language must be released with free() by you when you no longer need it. + /// @param[out] language A language is specified as an ISO 3166 alpha-2 two letter country-code + /// followed by ISO 639-1 for the two-letter language code. + /// For example, "ko_KR" for Korean, "en_US" for American English + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_OUT_OF_MEMORY Out of memory + /// @retval #VC_ERROR_OPERATION_FAILED Operation failure + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_INITIALIZED or #VC_STATE_READY. + /// @see vc_foreach_supported_languages() + int vc_get_current_language( + ffi.Pointer> language, + ) { + return _vc_get_current_language( + language, + ); + } + + late final _vc_get_current_language_ptr = + _lookup>( + 'vc_get_current_language'); + late final _dart_vc_get_current_language _vc_get_current_language = + _vc_get_current_language_ptr.asFunction<_dart_vc_get_current_language>(); + + /// @brief Gets current state of voice control client. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[out] state The current state + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @see vc_state_changed_cb() + /// @see vc_set_state_changed_cb() + int vc_get_state( + ffi.Pointer state, + ) { + return _vc_get_state( + state, + ); + } + + late final _vc_get_state_ptr = + _lookup>('vc_get_state'); + late final _dart_vc_get_state _vc_get_state = + _vc_get_state_ptr.asFunction<_dart_vc_get_state>(); + + /// @brief Gets current state of voice control service. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[out] state The current state + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_READY. + /// @see vc_request_start() + /// @see vc_request_stop() + /// @see vc_request_cancel() + /// @see vc_set_service_state_changed_cb() + /// @see vc_unset_service_state_changed_cb() + int vc_get_service_state( + ffi.Pointer state, + ) { + return _vc_get_service_state( + state, + ); + } + + late final _vc_get_service_state_ptr = + _lookup>( + 'vc_get_service_state'); + late final _dart_vc_get_service_state _vc_get_service_state = + _vc_get_service_state_ptr.asFunction<_dart_vc_get_service_state>(); + + /// @brief Gets the system command list. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks In the system command list, there are system commands predefined by product manufacturers. Those commands have the highest priority. + /// Therefore, the user can not set any commands same with the system commands. + /// The @a vc_sys_cmd_list must be released using free() when it is no longer required. + /// @param[out] vc_sys_cmd_list System command list handle + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The service state should be #VC_SERVICE_STATE_READY. + /// @see vc_unset_command_list() + int vc_get_system_command_list( + ffi.Pointer> vc_sys_cmd_list, + ) { + return _vc_get_system_command_list( + vc_sys_cmd_list, + ); + } + + late final _vc_get_system_command_list_ptr = + _lookup>( + 'vc_get_system_command_list'); + late final _dart_vc_get_system_command_list _vc_get_system_command_list = + _vc_get_system_command_list_ptr + .asFunction<_dart_vc_get_system_command_list>(); + + /// @brief Sets the invocation name. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks Invocation name is used to activate background commands. The invocation name can be the same as the application name or any other phrase. + /// For example, an application "Tizen Sample" has a background command, "Play music", and the invocation name of the application is set to "Tizen Sample". + /// In order to activate the background command, users can say "Tizen Sample, Play music". + /// The invocation name is dependent on the current language. For example, if the current language is "en_US"(English), the invocation name is also "en_US". + /// If the current language is "ja_JP"(Japanese) and the invocation name is "en_US", the invocation name will not be recognized. + /// This function should be called before vc_set_command_list(). + /// @param[in] name Invocation name that an application wants to be invoked by + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_READY. + /// @see vc_set_command_list() + int vc_set_invocation_name( + ffi.Pointer name, + ) { + return _vc_set_invocation_name( + name, + ); + } + + late final _vc_set_invocation_name_ptr = + _lookup>( + 'vc_set_invocation_name'); + late final _dart_vc_set_invocation_name _vc_set_invocation_name = + _vc_set_invocation_name_ptr.asFunction<_dart_vc_set_invocation_name>(); + + /// @brief Requests to set app id which is to want to ask the server dialogue. + /// @details Using this function, the developer can request registering the application on vc framework. + /// If developer requests to register @a app_id with @a credential which is valid, the application will be set on vc framework. + /// and then, when the developer requests the dialogue using vc_request_dialog(), dialog from specific engine server will be played by vc framework. + /// @since_tizen 5.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] app_id App id which is to want to ask server dialog. + /// @param[in] credential Credential key. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The service state should be #VC_SERVICE_STATE_READY. + /// @see vc_unset_server_dialog() + int vc_set_server_dialog( + ffi.Pointer app_id, + ffi.Pointer credential, + ) { + return _vc_set_server_dialog( + app_id, + credential, + ); + } + + late final _vc_set_server_dialog_ptr = + _lookup>( + 'vc_set_server_dialog'); + late final _dart_vc_set_server_dialog _vc_set_server_dialog = + _vc_set_server_dialog_ptr.asFunction<_dart_vc_set_server_dialog>(); + + /// @brief Requests to unset app id which is to not want to ask the server dialogue. + /// @details Using this function, the developer can disable function to ask dialog based on server. + /// @since_tizen 5.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] app_id App id which is to not want to ask server dialog. + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The service state should be #VC_SERVICE_STATE_READY. + /// @see vc_set_server_dialog() + int vc_unset_server_dialog( + ffi.Pointer app_id, + ) { + return _vc_unset_server_dialog( + app_id, + ); + } + + late final _vc_unset_server_dialog_ptr = + _lookup>( + 'vc_unset_server_dialog'); + late final _dart_vc_unset_server_dialog _vc_unset_server_dialog = + _vc_unset_server_dialog_ptr.asFunction<_dart_vc_unset_server_dialog>(); + + /// @brief Requests to start the dialogue. + /// @details Using this function, the developer can request starting the dialogue to the framework. + /// When the developer requests the dialogue, two types of texts, @a disp_text and @a utt_text, can be sent by this function. + /// @a disp_text is a text for displaying, and @a utt_text is that for uttering. + /// For example, if @a disp_text is "October 10th" and @a utt_text is "Today is October 10th.", "October 10th" will be displayed on the screen and "Today is October 10th." will be spoken. + /// Also, the developer can set whether the dialogue starts automatically or not, using @a auto_start. + /// If the developer sets @a auto_start as @c true, the framework will start to record next speech and continue the dialogue. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks If @a auto_start is @c true, the recognition will start again. In this case, it can be restarted up to 4 times. + /// @param[in] disp_text Text to be displayed on the screen + /// @param[in] utt_text Text to be spoken + /// @param[in] auto_start A variable for setting whether the dialog session will be restarted automatically or not + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The service state should be #VC_SERVICE_STATE_READY. + int vc_request_dialog( + ffi.Pointer disp_text, + ffi.Pointer utt_text, + bool auto_start, + ) { + return _vc_request_dialog( + disp_text, + utt_text, + auto_start ? 1 : 0, + ); + } + + late final _vc_request_dialog_ptr = + _lookup>('vc_request_dialog'); + late final _dart_vc_request_dialog _vc_request_dialog = + _vc_request_dialog_ptr.asFunction<_dart_vc_request_dialog>(); + + /// @brief Sets command list. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @remarks The command type is valid for #VC_COMMAND_TYPE_FOREGROUND or #VC_COMMAND_TYPE_BACKGROUND. + /// The matched commands of command list should be set and they should include type and command text at least. + /// @param[in] vc_cmd_list Command list handle + /// @param[in] type Command type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_READY. + /// @see vc_unset_command_list() + int vc_set_command_list( + ffi.Pointer vc_cmd_list, + int type, + ) { + return _vc_set_command_list( + vc_cmd_list, + type, + ); + } + + late final _vc_set_command_list_ptr = + _lookup>( + 'vc_set_command_list'); + late final _dart_vc_set_command_list _vc_set_command_list = + _vc_set_command_list_ptr.asFunction<_dart_vc_set_command_list>(); + + /// @brief Unsets command list. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] type Command type + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_READY. + /// @see vc_set_command_list() + int vc_unset_command_list( + int type, + ) { + return _vc_unset_command_list( + type, + ); + } + + late final _vc_unset_command_list_ptr = + _lookup>( + 'vc_unset_command_list'); + late final _dart_vc_unset_command_list _vc_unset_command_list = + _vc_unset_command_list_ptr.asFunction<_dart_vc_unset_command_list>(); + + /// @brief Gets the recognition result. + /// @since_tizen 3.0 + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] callback Callback function to get recognition result + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_READY. + /// @see vc_result_cb() + int vc_get_result( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _vc_get_result( + callback, + user_data, + ); + } + + late final _vc_get_result_ptr = + _lookup>('vc_get_result'); + late final _dart_vc_get_result _vc_get_result = + _vc_get_result_ptr.asFunction<_dart_vc_get_result>(); + + /// @brief Registers a callback function for getting recognition result. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] callback Callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_INITIALIZED. + /// @see vc_result_cb() + /// @see vc_unset_result_cb() + int vc_set_result_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _vc_set_result_cb( + callback, + user_data, + ); + } + + late final _vc_set_result_cb_ptr = + _lookup>('vc_set_result_cb'); + late final _dart_vc_set_result_cb _vc_set_result_cb = + _vc_set_result_cb_ptr.asFunction<_dart_vc_set_result_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_INITIALIZED. + /// @see vc_set_result_cb() + int vc_unset_result_cb() { + return _vc_unset_result_cb(); + } + + late final _vc_unset_result_cb_ptr = + _lookup>('vc_unset_result_cb'); + late final _dart_vc_unset_result_cb _vc_unset_result_cb = + _vc_unset_result_cb_ptr.asFunction<_dart_vc_unset_result_cb>(); + + /// @brief Registers a callback function to be called when state is changed. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] callback Callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_INITIALIZED. + /// @see vc_service_state_changed_cb() + /// @see vc_unset_service_state_changed_cb() + int vc_set_service_state_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _vc_set_service_state_changed_cb( + callback, + user_data, + ); + } + + late final _vc_set_service_state_changed_cb_ptr = + _lookup>( + 'vc_set_service_state_changed_cb'); + late final _dart_vc_set_service_state_changed_cb + _vc_set_service_state_changed_cb = _vc_set_service_state_changed_cb_ptr + .asFunction<_dart_vc_set_service_state_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_INITIALIZED. + /// @see vc_set_service_state_changed_cb() + int vc_unset_service_state_changed_cb() { + return _vc_unset_service_state_changed_cb(); + } + + late final _vc_unset_service_state_changed_cb_ptr = + _lookup>( + 'vc_unset_service_state_changed_cb'); + late final _dart_vc_unset_service_state_changed_cb + _vc_unset_service_state_changed_cb = + _vc_unset_service_state_changed_cb_ptr + .asFunction<_dart_vc_unset_service_state_changed_cb>(); + + /// @brief Registers a callback function to be called when state is changed. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] callback Callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_INITIALIZED. + /// @see vc_state_changed_cb() + /// @see vc_unset_state_changed_cb() + int vc_set_state_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _vc_set_state_changed_cb( + callback, + user_data, + ); + } + + late final _vc_set_state_changed_cb_ptr = + _lookup>( + 'vc_set_state_changed_cb'); + late final _dart_vc_set_state_changed_cb _vc_set_state_changed_cb = + _vc_set_state_changed_cb_ptr.asFunction<_dart_vc_set_state_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_INITIALIZED. + /// @see vc_set_state_changed_cb() + int vc_unset_state_changed_cb() { + return _vc_unset_state_changed_cb(); + } + + late final _vc_unset_state_changed_cb_ptr = + _lookup>( + 'vc_unset_state_changed_cb'); + late final _dart_vc_unset_state_changed_cb _vc_unset_state_changed_cb = + _vc_unset_state_changed_cb_ptr + .asFunction<_dart_vc_unset_state_changed_cb>(); + + /// @brief Registers a callback function to be called when current language is changed. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] callback Callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_INITIALIZED. + /// @see vc_current_language_changed_cb() + /// @see vc_unset_current_language_changed_cb() + int vc_set_current_language_changed_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _vc_set_current_language_changed_cb( + callback, + user_data, + ); + } + + late final _vc_set_current_language_changed_cb_ptr = + _lookup>( + 'vc_set_current_language_changed_cb'); + late final _dart_vc_set_current_language_changed_cb + _vc_set_current_language_changed_cb = + _vc_set_current_language_changed_cb_ptr + .asFunction<_dart_vc_set_current_language_changed_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_INITIALIZED. + /// @see vc_set_current_language_changed_cb() + int vc_unset_current_language_changed_cb() { + return _vc_unset_current_language_changed_cb(); + } + + late final _vc_unset_current_language_changed_cb_ptr = + _lookup>( + 'vc_unset_current_language_changed_cb'); + late final _dart_vc_unset_current_language_changed_cb + _vc_unset_current_language_changed_cb = + _vc_unset_current_language_changed_cb_ptr + .asFunction<_dart_vc_unset_current_language_changed_cb>(); + + /// @brief Registers a callback function to be called when an error occurred. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @param[in] callback Callback function to register + /// @param[in] user_data The user data to be passed to the callback function + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_PARAMETER Invalid parameter + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_INITIALIZED. + /// @see vc_error_cb() + /// @see vc_unset_error_cb() + int vc_set_error_cb( + ffi.Pointer> callback, + ffi.Pointer user_data, + ) { + return _vc_set_error_cb( + callback, + user_data, + ); + } + + late final _vc_set_error_cb_ptr = + _lookup>('vc_set_error_cb'); + late final _dart_vc_set_error_cb _vc_set_error_cb = + _vc_set_error_cb_ptr.asFunction<_dart_vc_set_error_cb>(); + + /// @brief Unregisters the callback function. + /// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif + /// @privlevel public + /// @privilege %http://tizen.org/privilege/recorder + /// @return @c 0 on success, + /// otherwise a negative error value + /// @retval #VC_ERROR_NONE Successful + /// @retval #VC_ERROR_INVALID_STATE Invalid state + /// @retval #VC_ERROR_PERMISSION_DENIED Permission denied + /// @retval #VC_ERROR_NOT_SUPPORTED Not supported + /// @pre The state should be #VC_STATE_INITIALIZED. + /// @see vc_set_error_cb() + int vc_unset_error_cb() { + return _vc_unset_error_cb(); + } + + late final _vc_unset_error_cb_ptr = + _lookup>('vc_unset_error_cb'); + late final _dart_vc_unset_error_cb _vc_unset_error_cb = + _vc_unset_error_cb_ptr.asFunction<_dart_vc_unset_error_cb>(); +} + +/// @brief Enumeration for the state of capability. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class account_capability_state_e { + /// < Account capability is invalid + static const int ACCOUNT_CAPABILITY_STATE_INVALID = 0; + + /// < Account capability is disabled + static const int ACCOUNT_CAPABILITY_DISABLED = 1; + + /// < Account capability is enabled + static const int ACCOUNT_CAPABILITY_ENABLED = 2; + static const int ACCOUNT_CAPABILITY_STATE_MAX = 3; +} + +/// @brief Enumeration for the state of account secrecy. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class account_secrecy_state_e { + /// < Account secrecy is invalid + static const int ACCOUNT_SECRECY_INVALID = 0; + + /// < Account is not visible + static const int ACCOUNT_SECRECY_INVISIBLE = 1; + + /// < Account is visible + static const int ACCOUNT_SECRECY_VISIBLE = 2; + static const int ACCOUNT_SECRECY_MAX = 3; +} + +/// @brief Enumeration for the account sync status. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class account_sync_state_e { + /// < Account sync is invalid + static const int ACCOUNT_SYNC_INVALID = 0; + + /// < Account sync not supported + static const int ACCOUNT_SYNC_NOT_SUPPORT = 1; + + /// < Account sync supported but all synchronization functionalities are off + static const int ACCOUNT_SYNC_STATUS_OFF = 2; + + /// < Account sync support and sync status is idle + static const int ACCOUNT_SYNC_STATUS_IDLE = 3; + + /// < Account sync support and sync status is running + static const int ACCOUNT_SYNC_STATUS_RUNNING = 4; + + /// < NOT USED, WILL BE REMOVED TO PREVENT BUILD ERROR + static const int ACCOUNT_SUPPORTS_SYNC = 5; + + /// < NOT USED, WILL BE REMOVED TO PREVENT BUILD ERROR + static const int ACCOUNT_NOT_SUPPORTS_SYNC = 6; + static const int ACCOUNT_SYNC_MAX = 7; +} + +/// @brief Enumeration for the account auth type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class account_auth_type_e { + /// < Auth type is invalid + static const int ACCOUNT_AUTH_TYPE_INVALID = 0; + + /// < XAuth type + static const int ACCOUNT_AUTH_TYPE_XAUTH = 1; + + /// < OAuth type + static const int ACCOUNT_AUTH_TYPE_OAUTH = 2; + + /// < Client-Login type + static const int ACCOUNT_AUTH_TYPE_CLIENT_LOGIN = 3; + static const int ACCOUNT_AUTH_TYPE_MAX = 4; +} + +class account_s extends ffi.Opaque {} + +class account_type_s extends ffi.Opaque {} + +class label_s extends ffi.Opaque {} + +class account_subscribe_s extends ffi.Opaque {} + +/// @brief Enumeration for tizen errors. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class tizen_error_e { + /// < Successful + static const int TIZEN_ERROR_NONE = 0; + + /// < Operation not permitted + static const int TIZEN_ERROR_NOT_PERMITTED = -1; + + /// < No such file or directory + static const int TIZEN_ERROR_NO_SUCH_FILE = -2; + + /// < No such process + static const int TIZEN_ERROR_NO_SUCH_PROCESS = -3; + + /// < Interrupted system call + static const int TIZEN_ERROR_INTERRUPTED_SYS_CALL = -4; + + /// < I/O error + static const int TIZEN_ERROR_IO_ERROR = -5; + + /// < No such device or address + static const int TIZEN_ERROR_NO_SUCH_DEVICE = -6; + + /// < Argument list too long + static const int TIZEN_ERROR_ARGUMENT_LIST_TOO_LONG = -7; + + /// < Exec format error + static const int TIZEN_ERROR_EXEC_FORMAT_ERROR = -8; + + /// < Bad file number + static const int TIZEN_ERROR_BAD_FILE_NUMBER = -9; + + /// < Try again + static const int TIZEN_ERROR_TRY_AGAIN = -11; + + /// < Out of memory + static const int TIZEN_ERROR_OUT_OF_MEMORY = -12; + + /// < Permission denied + static const int TIZEN_ERROR_PERMISSION_DENIED = -13; + + /// < Bad address + static const int TIZEN_ERROR_BAD_ADDRESS = -14; + + /// < Block device required + static const int TIZEN_ERROR_BLOCK_DEVICE_REQUIRED = -15; + + /// < Device or resource busy + static const int TIZEN_ERROR_RESOURCE_BUSY = -16; + + /// < File exists + static const int TIZEN_ERROR_FILE_EXISTS = -17; + + /// < Cross-device link + static const int TIZEN_ERROR_CROSS_DEVICE_LINK = -18; + + /// < Not a directory + static const int TIZEN_ERROR_NOT_A_DIRECTORY = -20; + + /// < Is a directory + static const int TIZEN_ERROR_IS_A_DIRECTORY = -21; + + /// < Invalid function parameter + static const int TIZEN_ERROR_INVALID_PARAMETER = -22; + + /// < File table overflow + static const int TIZEN_ERROR_FILE_TABLE_OVERFLOW = -23; + + /// < Too many open files + static const int TIZEN_ERROR_TOO_MANY_OPEN_FILES = -24; + + /// < Not a terminal + static const int TIZEN_ERROR_TOO_NOT_A_TERMINAL = -25; + + /// < Not a terminal + static const int TIZEN_ERROR_TOO_TEXT_FILE_BUSY = -26; + + /// < File too large + static const int TIZEN_ERROR_FILE_TOO_LARGE = -27; + + /// < No space left on device + static const int TIZEN_ERROR_FILE_NO_SPACE_ON_DEVICE = -28; + + /// < Illegal seek + static const int TIZEN_ERROR_ILLEGAL_SEEK = -29; + + /// < Read-only file system + static const int TIZEN_ERROR_READ_ONLY_FILESYSTEM = -30; + + /// < No data available + static const int TIZEN_ERROR_NO_DATA = -61; + + /// < Too many links + static const int TIZEN_ERROR_TOO_MANY_LINKS = -31; + + /// < Broken pipe + static const int TIZEN_ERROR_BROKEN_PIPE = -32; + + /// < Math argument out of domain of func + static const int TIZEN_ERROR_ARGUMENT_OUT_OF_DOMAIN = -33; + + /// < Math result not representable + static const int TIZEN_ERROR_RESULT_OUT_OF_RANGE = -34; + + /// < Resource deadlock would occur + static const int TIZEN_ERROR_WOULD_CAUSE_DEADLOCK = -35; + + /// < File name too long + static const int TIZEN_ERROR_FILE_NAME_TOO_LONG = -36; + + /// < No record locks available + static const int TIZEN_ERROR_FILE_NO_LOCKS_AVAILABLE = -37; + + /// < Function not implemented + static const int TIZEN_ERROR_INVALID_OPERATION = -38; + + /// < Directory not empty + static const int TIZEN_ERROR_DIR_NOT_EMPTY = -39; + + /// < Too many symbolic links encountered + static const int TIZEN_ERROR_TOO_MANY_SYMBOLIC_LINKS = -40; + + /// < Operation would block + static const int TIZEN_ERROR_WOULD_BLOCK = -11; + + /// < Accessing a corrupted shared library + static const int TIZEN_ERROR_CORRUPTED_SHARED_LIB = -80; + + /// < .lib section in a.out corrupted + static const int TIZEN_ERROR_LIB_SECTION_CORRUPTED = -81; + + /// < Attempting to link in too many shared libraries + static const int TIZEN_ERROR_LINK_TOO_MANY_SHARED_LIB = -82; + + /// < Cannot exec a shared library directly + static const int TIZEN_ERROR_SHARED_LIB_EXEC = -83; + + /// < Illegal byte sequence + static const int TIZEN_ERROR_ILLEGAL_BYTE_SEQ = -84; + + /// < Interrupted system call should be restarted + static const int TIZEN_ERROR_SYSTEM_CALL_RESTART = -85; + + /// < Streams pipe error + static const int TIZEN_ERROR_STREAMS_PIPE = -86; + + /// < Too many users + static const int TIZEN_ERROR_TOO_MANY_USERS = -87; + + /// < Socket operation on non-socket + static const int TIZEN_ERROR_NON_SOCKET = -88; + + /// < Destination address required + static const int TIZEN_ERROR_NO_DEST_ADDRESS = -89; + + /// < Message too long + static const int TIZEN_ERROR_MSG_TOO_LONG = -90; + + /// < Protocol wrong type for socket + static const int TIZEN_ERROR_PROTOCOL_WRONG_TYPE = -91; + + /// < Protocol not available + static const int TIZEN_ERROR_PROTOCOL_NOT_AVALIABLE = -92; + + /// < Protocol not supported + static const int TIZEN_ERROR_PROTOCOL_NOT_SUPPORTED = -93; + + /// < Socket type not supported + static const int TIZEN_ERROR_SOCKET_TYPE_NOT_SUPPORTED = -94; + + /// < Operation not supported on transport endpoint + static const int TIZEN_ERROR_ENDPOINT_OPERATIN_NOT_SUPPORTED = -95; + + /// < Protocol family not supported + static const int TIZEN_ERROR_PROTOCOL_FAMILY_NOT_SUPPORTED = -96; + + /// < Address family not supported by protocol + static const int TIZEN_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED = -97; + + /// < Address already in use + static const int TIZEN_ERROR_ADDRES_IN_USE = -98; + + /// < Cannot assign requested address + static const int TIZEN_ERROR_CANNOT_ASSIGN_ADDRESS = -99; + + /// < Network is down + static const int TIZEN_ERROR_NETWORK_DOWN = -100; + + /// < Network is unreachable + static const int TIZEN_ERROR_NETWORK_UNREACHABLE = -101; + + /// < Network dropped connection because of reset + static const int TIZEN_ERROR_NETWORK_RESET = -102; + + /// < Software caused connection abort + static const int TIZEN_ERROR_CONNECTION_ABORTED = -103; + + /// < Connection reset by peer + static const int TIZEN_ERROR_CONNECTION_RESET_BY_PEER = -104; + + /// < No buffer space available + static const int TIZEN_ERROR_BUFFER_SPACE = -105; + + /// < Transport endpoint is already connected + static const int TIZEN_ERROR_ENDPOINT_CONNECTED = -106; + + /// < Transport endpoint is not connected + static const int TIZEN_ERROR_ENDPOINT_NOT_CONNECTED = -107; + + /// < Cannot send after transport endpoint shutdown + static const int TIZEN_ERROR_ENDPOINT_SHUTDOWN = -108; + + /// < Too many references: cannot splice + static const int TIZEN_ERROR_TOO_MANY_REFERENCES = -109; + + /// < Connection timed out + static const int TIZEN_ERROR_CONNECTION_TIME_OUT = -110; + + /// < Connection refused + static const int TIZEN_ERROR_CONNECTION_REFUSED = -111; + + /// < Host is down + static const int TIZEN_ERROR_HOST_DOWN = -112; + + /// < No route to host + static const int TIZEN_ERROR_NO_ROUTE_TO_HOST = -113; + + /// < Operation already in progress + static const int TIZEN_ERROR_ALREADY_IN_PROGRESS = -114; + + /// < Operation now in progress + static const int TIZEN_ERROR_NOW_IN_PROGRESS = -115; + + /// < Stale NFS file handle + static const int TIZEN_ERROR_STALE_NFS_FILE_HANDLE = -116; + + /// < Structure needs cleaning + static const int TIZEN_ERROR_STRUCTURE_UNCLEAN = -117; + + /// < Not a XENIX named type file + static const int TIZEN_ERROR_NOT_XENIX_NAMED_TYPE_FILE = -118; + + /// < No XENIX semaphores available + static const int TIZEN_ERROR_NO_XENIX_SEMAPHORES_AVAILABLE = -119; + + /// < Is a named type file + static const int TIZEN_ERROR_IS_NAMED_TYPE_FILE = -120; + + /// < Remote I/O error + static const int TIZEN_ERROR_REMOTE_IO = -121; + + /// < Quota exceeded + static const int TIZEN_ERROR_QUOTA_EXCEEDED = -122; + + /// < No medium found + static const int TIZEN_ERROR_NO_MEDIUM = -123; + + /// < Wrong medium type + static const int TIZEN_ERROR_WRONG_MEDIUM_TYPE = -124; + + /// < Operation Canceled + static const int TIZEN_ERROR_CANCELED = -125; + + /// < Required key not available + static const int TIZEN_ERROR_KEY_NOT_AVAILABLE = -126; + + /// < Key has expired + static const int TIZEN_ERROR_KEY_EXPIRED = -127; + + /// < Key has been revoked + static const int TIZEN_ERROR_KEY_REVOKED = -128; + + /// < Key was rejected by service + static const int TIZEN_ERROR_KEY_REJECTED = -129; + + /// < Owner died (for robust mutexes) + static const int TIZEN_ERROR_OWNER_DEAD = -130; + + /// < Unknown error + static const int TIZEN_ERROR_UNKNOWN = -1073741824; + + /// < Time out + static const int TIZEN_ERROR_TIMED_OUT = -1073741823; + + /// < Not supported + static const int TIZEN_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Not Consented + static const int TIZEN_ERROR_USER_NOT_CONSENTED = -1073741821; + + /// < Restriction by Device Policy + static const int TIZEN_ERROR_DEVICE_POLICY_RESTRICTION = -1073741820; + static const int TIZEN_ERROR_END_OF_COLLECTION = -1073741819; +} + +/// @brief Enumerations of error codes for ACCOUNT APIs. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class account_error_e { + /// < Successful + static const int ACCOUNT_ERROR_NONE = 0; + + /// < Out of memory + static const int ACCOUNT_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid parameter + static const int ACCOUNT_ERROR_INVALID_PARAMETER = -22; + + /// < Same user name exists in your application + static const int ACCOUNT_ERROR_DUPLICATED = -16777215; + + /// < Empty data + static const int ACCOUNT_ERROR_NO_DATA = -61; + + /// < Related record does not exist + static const int ACCOUNT_ERROR_RECORD_NOT_FOUND = -16777213; + + /// < DB operation failed + static const int ACCOUNT_ERROR_DB_FAILED = -16777212; + + /// < DB is not connected + static const int ACCOUNT_ERROR_DB_NOT_OPENED = -16777211; + + /// < DB query syntax error + static const int ACCOUNT_ERROR_QUERY_SYNTAX_ERROR = -16777210; + + /// < Iterator has reached the end + static const int ACCOUNT_ERROR_ITERATOR_END = -16777209; + + /// < Notification failed + static const int ACCOUNT_ERROR_NOTI_FAILED = -16777208; + + /// < Permission denied + static const int ACCOUNT_ERROR_PERMISSION_DENIED = -13; + + /// < XML parse failed + static const int ACCOUNT_ERROR_XML_PARSE_FAILED = -16777206; + + /// < XML file does not exist + static const int ACCOUNT_ERROR_XML_FILE_NOT_FOUND = -16777205; + + /// < Subscription failed + static const int ACCOUNT_ERROR_EVENT_SUBSCRIPTION_FAIL = -16777204; + + /// < Account provider is not registered + static const int ACCOUNT_ERROR_NOT_REGISTERED_PROVIDER = -16777203; + + /// < Multiple accounts are not supported + static const int ACCOUNT_ERROR_NOT_ALLOW_MULTIPLE = -16777202; + + /// < SQLite busy handler expired + static const int ACCOUNT_ERROR_DATABASE_BUSY = -16777200; + + /// < Not supported (Since 4.0) + static const int ACCOUNT_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Account operation failed (Since 4.0) + static const int ACCOUNT_ERROR_OPERATION_FAIL = -38; +} + +class fido_authenticator_s extends ffi.Opaque {} + +/// @brief Enumerations of error codes for FIDO APIs. +/// @since_tizen 3.0 +abstract class fido_error_e { + /// < Successful. + static const int FIDO_ERROR_NONE = 0; + + /// < Out of memory. + static const int FIDO_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid parameter. + static const int FIDO_ERROR_INVALID_PARAMETER = -22; + + /// < Empty data. + static const int FIDO_ERROR_NO_DATA = -61; + + /// < Permission Denied. + static const int FIDO_ERROR_PERMISSION_DENIED = -13; + + /// < FIDO is unsupported. + static const int FIDO_ERROR_NOT_SUPPORTED = -1073741822; + + /// < User action is in progress. + static const int FIDO_ERROR_USER_ACTION_IN_PROGRESS = -16973823; + + /// < User has canceled the operation. + static const int FIDO_ERROR_USER_CANCELLED = -16973822; + + /// < UAF message's version is not supported. + static const int FIDO_ERROR_UNSUPPORTED_VERSION = -16973821; + + /// < No suitable authenticators found. + static const int FIDO_ERROR_NO_SUITABLE_AUTHENTICATOR = -16973820; + + /// < Protocol error, the interaction may have timed out, or the UAF message is malformed. + static const int FIDO_ERROR_PROTOCOL_ERROR = -16973819; + + /// < The caller's id is not allowed to use this operation. + static const int FIDO_ERROR_UNTRUSTED_FACET_ID = -16973818; + + /// < Unknown system error. + static const int FIDO_ERROR_UNKNOWN = -1073741824; +} + +/// @brief Authenticator's supported algorithm and encoding. +/// @remarks Refer to FIDO UAF Registry document for more details. +/// @since_tizen 3.0 +abstract class fido_auth_algo_e { + /// < SECP256R1 ECDSA SHA256 Raw + static const int FIDO_AUTH_ALGO_SECP256R1_ECDSA_SHA256_RAW = 1; + + /// < SECP256R1 ECDSA SHA256 DER + static const int FIDO_AUTH_ALGO_SECP256R1_ECDSA_SHA256_DER = 2; + + /// < RSA PSS SHA256 Raw + static const int FIDO_AUTH_ALGO_RSASSA_PSS_SHA256_RAW = 3; + + /// < RSA PSS SHA256 DER + static const int FIDO_AUTH_ALGO_RSASSA_PSS_SHA256_DER = 4; + + /// < SECP256K1 ECDSA SHA256 Raw + static const int FIDO_AUTH_ALGO_SECP256K1_ECDSA_SHA256_RAW = 5; + + /// < SECP256K1 ECDSA SHA256 DER + static const int FIDO_AUTH_ALGO_SECP256K1_ECDSA_SHA256_DER = 6; +} + +/// @brief Authenticator's supported Attestation type. +/// @remarks Refer to FIDO UAF Registry document for more details. +/// @since_tizen 3.0 +abstract class fido_auth_attestation_type_e { + /// < Full basic attestation. + static const int FIDO_AUTH_ATT_TYPE_BASIC_FULL = 15879; + + /// < Surrogate basic attestation. + static const int FIDO_AUTH_ATT_TYPE_BASIC_SURROGATE = 15880; +} + +/// @brief Authenticator's supported user verification method type. +/// @remarks Refer to FIDO UAF Registry document for more details. +/// @since_tizen 3.0 +abstract class fido_auth_user_verify_type_e { + /// < User presence verification. + static const int FIDO_AUTH_USR_VERIFY_TYPE_PRESENCE = 1; + + /// < User fingerprint verification. + static const int FIDO_AUTH_USR_VERIFY_TYPE_FINGERPRINT = 2; + + /// < User passcode verification. + static const int FIDO_AUTH_USR_VERIFY_TYPE_PASSCODE = 4; + + /// < User voiceprint verification. + static const int FIDO_AUTH_USR_VERIFY_TYPE_VOICEPRINT = 8; + + /// < User faceprint verification. + static const int FIDO_AUTH_USR_VERIFY_TYPE_FACEPRINT = 16; + + /// < User location verification. + static const int FIDO_AUTH_USR_VERIFY_TYPE_LOCATION = 32; + + /// < User eyeprint verification. + static const int FIDO_AUTH_USR_VERIFY_TYPE_EYEPRINT = 64; + + /// < User pattern verification. + static const int FIDO_AUTH_USR_VERIFY_TYPE_PATTERN = 128; + + /// < User handprint verification. + static const int FIDO_AUTH_USR_VERIFY_TYPE_HANDPRINT = 256; + + /// < Silent verification. + static const int FIDO_AUTH_USR_VERIFY_TYPE_NONE = 512; + + /// < If an authenticator sets multiple flags for user verification types, + /// it may also set this flag to indicate that all verification methods will be enforced + /// (e.g. faceprint AND voiceprint). If flags for multiple user verification methods are set + /// and this flag is not set, verification with only one is necessary + /// (e.g. fingerprint OR passcode). + static const int FIDO_AUTH_USR_VERIFY_TYPE_ALL = 1024; +} + +/// @brief Authenticator's supported key protection method type. +/// @remarks Refer to FIDO UAF Registry document for more details. +/// @since_tizen 3.0 +abstract class fido_auth_key_protection_type_e { + /// < Software based key management. + static const int FIDO_AUTH_KEY_PROT_TYPE_SOFTWARE = 1; + + /// < Hardware based key management. + static const int FIDO_AUTH_KEY_PROT_TYPE_HARDWARE = 2; + + /// < Trusted Execution Environment based key management. + static const int FIDO_AUTH_KEY_PROT_TYPE_TEE = 4; + + /// < Secure Element based key management. + static const int FIDO_AUTH_KEY_PROT_TYPE_SECURE_ELEMENT = 8; + + /// < Authenticator does not store (wrapped) UAuth keys at the client, + /// but relies on a server-provided key handle. + static const int FIDO_AUTH_KEY_PROT_TYPE_REMOTE_HANDLE = 16; +} + +/// @brief Authenticator's supported matcher protection type. +/// @remarks Refer to FIDO UAF Registry document for more details. +/// @since_tizen 3.0 +abstract class fido_auth_matcher_protection_type_e { + /// < Authenticator's matcher is running in software. + static const int FIDO_AUTH_MATCH_PROT_TYPE_SOFTWARE = 1; + + /// < Authenticator's matcher is running inside the Trusted Execution Environment. + static const int FIDO_AUTH_MATCH_PROT_TYPE_TEE = 2; + + /// < Authenticator's matcher is running on the chip. + static const int FIDO_AUTH_MATCH_PROT_TYPE_ON_CHIP = 4; +} + +/// @brief Authenticator's supported method to communicate to FIDO user device. +/// @remarks Refer to FIDO UAF Registry document for more details. +/// @since_tizen 3.0 +abstract class fido_auth_attachment_hint_e { + /// < Authenticator is permanently attached to the FIDO User Device. + static const int FIDO_AUTH_ATTACH_HINT_INTERNAL = 1; + + /// < Authenticator is removable or remote from the FIDO User Device. + static const int FIDO_AUTH_ATTACH_HINT_EXTERNAL = 2; + + /// < The external authenticator currently has an exclusive wired connection. + static const int FIDO_AUTH_ATTACH_HINT_WIRED = 4; + + /// < The external authenticator communicates with the FIDO User Device through + /// wireless means. + static const int FIDO_AUTH_ATTACH_HINT_WIRELESS = 8; + + /// < Authenticator is able to communicate by NFC to the FIDO User Device. + static const int FIDO_AUTH_ATTACH_HINT_NFC = 16; + + /// < Authenticator is able to communicate by Bluetooth to the FIDO User Device. + static const int FIDO_AUTH_ATTACH_HINT_BT = 32; + + /// < Authenticator is connected to the FIDO User Device over a non-exclusive network + /// (e.g. over a TCP/IP LAN or WAN, as opposed to a PAN or point-to-point connection). + static const int FIDO_AUTH_ATTACH_HINT_NW = 64; + + /// < The external authenticator is in a "ready" state. + static const int FIDO_AUTH_ATTACH_HINT_READY = 128; + + /// < The external authenticator is able to + /// communicate using WiFi Direct with the FIDO User Device. + static const int FIDO_AUTH_ATTACH_HINT_WIFI_DIRECT = 256; +} + +/// @brief Transaction confirmation display capability type. +/// @remarks Refer to FIDO UAF Registry document for more details. +/// @since_tizen 3.0 +abstract class fido_auth_tc_display_type_e { + /// < Some form of transaction confirmation display is available on this authenticator. + static const int FIDO_AUTH_TC_DISP_TYPE_ANY = 1; + + /// < Software-based transaction confirmation display operating in a + /// privileged context is available on this authenticator. + static const int FIDO_AUTH_TC_DISP_TYPE_PRIVILEGED_SOFTWARE = 2; + + /// < Transaction confirmation display is in a Trusted Execution Environment. + static const int FIDO_AUTH_TC_DISP_TYPE_TEE = 4; + + /// < Transaction confirmation display based on hardware assisted capabilities is available on this authenticator. + static const int FIDO_AUTH_TC_DISP_TYPE_HW = 8; + + /// < Transaction confirmation display is provided on a distinct device from the FIDO User Device. + static const int FIDO_AUTH_TC_DISP_TYPE_REMOTE = 16; +} + +/// @brief Enumerations for Client authentication scheme, used to sign client id and client secret accordingly. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +/// @remarks Facebook and Google does not support HTTP Basic Authentication, instead they require client credentials to be sent via request body. +/// Default is #OAUTH2_CLIENT_AUTHENTICATION_TYPE_BASIC (rfc2617#section-2) +/// +/// @see oauth2_request_set_client_authentication_type() +abstract class oauth2_client_authentication_type_e { + /// < HTTP Basic Authentication for client authentication. + static const int OAUTH2_CLIENT_AUTHENTICATION_TYPE_BASIC = 0; + + /// < HTTP Digest Authentication for client authentication. + static const int OAUTH2_CLIENT_AUTHENTICATION_TYPE_DIGEST = 1; + + /// < Client credentials are sent via request body + static const int OAUTH2_CLIENT_AUTHENTICATION_TYPE_REQUEST_BODY = 2; +} + +/// @brief Enumerations to set grant_type. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +/// +/// @see oauth2_request_set_grant_type() +abstract class oauth2_grant_type_e { + /// < Access Token Request for Authorization Code Grant type. + static const int OAUTH2_GRANT_TYPE_AUTH_CODE = 0; + + /// < Access Token Request for Resource Owner Password Credentials Grant type. + static const int OAUTH2_GRANT_TYPE_PASSWORD = 1; + + /// < Access Token Request for Client Credentials Grant type. + static const int OAUTH2_GRANT_TYPE_CLIENT_CREDENTIALS = 2; + + /// < Refresh Token Request. + static const int OAUTH2_GRANT_TYPE_REFRESH = 3; +} + +/// @brief Enumerations to set response_type. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +/// +/// @see oauth2_request_set_response_type() +abstract class oauth2_response_type_e { + /// < Requesting an authorization code as response type. + static const int OAUTH2_RESPONSE_TYPE_CODE = 0; + + /// < Requesting an access token(implicit grant) as response type. + static const int OAUTH2_RESPONSE_TYPE_TOKEN = 1; +} + +/// @brief Enumerations of error codes for oauth2 APIs. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class oauth2_error_e { + /// < Successful + static const int OAUTH2_ERROR_NONE = 0; + + /// < Out of memory + static const int OAUTH2_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid parameter + static const int OAUTH2_ERROR_INVALID_PARAMETER = -22; + + /// < Operation already in progress + static const int OAUTH2_ERROR_ALREADY_IN_PROGRESS = -114; + + /// < Operation not supported + static const int OAUTH2_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Permission denied + static const int OAUTH2_ERROR_PERMISSION_DENIED = -13; + + /// < Response parse failed + static const int OAUTH2_ERROR_PARSE_FAILED = -16842751; + + /// < Network error + static const int OAUTH2_ERROR_NETWORK_ERROR = -16842750; + + /// < Server error + static const int OAUTH2_ERROR_SERVER = -16842749; + + /// < User cancelled the operation + static const int OAUTH2_ERROR_USER_CANCELLED = -16842748; + + /// < Value not found + static const int OAUTH2_ERROR_VALUE_NOT_FOUND = -16842747; + + /// < Unknown error + static const int OAUTH2_ERROR_UNKNOWN = -1073741824; +} + +class oauth2_request_s extends ffi.Opaque {} + +class oauth2_error_s extends ffi.Opaque {} + +class oauth2_response_s extends ffi.Opaque {} + +class oauth2_manager_s extends ffi.Opaque {} + +/// @brief Enumerations of error codes for Sync Manager APIs. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class sync_error_e { + /// < Successful + static const int SYNC_ERROR_NONE = 0; + + /// < Not supported (Since 4.0) + static const int SYNC_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Out of memory + static const int SYNC_ERROR_OUT_OF_MEMORY = -12; + + /// < I/O error + static const int SYNC_ERROR_IO_ERROR = -5; + + /// < Permission denied + static const int SYNC_ERROR_PERMISSION_DENIED = -13; + + /// < Duplicate data + static const int SYNC_ERROR_ALREADY_IN_PROGRESS = -114; + + /// < Error in operation + static const int SYNC_ERROR_INVALID_OPERATION = -38; + + /// < Invalid parameter + static const int SYNC_ERROR_INVALID_PARAMETER = -22; + + /// < Quota exceeded + static const int SYNC_ERROR_QUOTA_EXCEEDED = -122; + + /// < Unknown error + static const int SYNC_ERROR_UNKNOWN = -1073741824; + + /// < System error + static const int SYNC_ERROR_SYSTEM = -16908287; + + /// < Sync adapter is not registered + static const int SYNC_ERROR_SYNC_ADAPTER_NOT_FOUND = -16908286; +} + +/// @brief Enumerations for sync options of sync job request APIs. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class sync_option_e { + /// < Sync job will be operated normally + static const int SYNC_OPTION_NONE = 0; + + /// < Sync job will be operated as soon as possible + static const int SYNC_OPTION_EXPEDITED = 1; + + /// < Sync job will not be performed again when it fails + static const int SYNC_OPTION_NO_RETRY = 2; +} + +/// @brief Enumerations for time intervals of a periodic sync. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class sync_period_e { + /// < Sync within 30 minutes + static const int SYNC_PERIOD_INTERVAL_30MIN = 0; + + /// < Sync within 1 hour + static const int SYNC_PERIOD_INTERVAL_1H = 1; + + /// < Sync within 2 hours + static const int SYNC_PERIOD_INTERVAL_2H = 2; + + /// < Sync within 3 hours + static const int SYNC_PERIOD_INTERVAL_3H = 3; + + /// < Sync within 6 hours + static const int SYNC_PERIOD_INTERVAL_6H = 4; + + /// < Sync within 12 hours + static const int SYNC_PERIOD_INTERVAL_12H = 5; + + /// < Sync within 1 day + static const int SYNC_PERIOD_INTERVAL_1DAY = 6; + static const int SYNC_PERIOD_INTERVAL_MAX = 7; +} + +class bundle extends ffi.Opaque {} + +class app_control_s extends ffi.Opaque {} + +/// @brief Enumeration for the application control error. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class app_control_error_e { + /// < Successful + static const int APP_CONTROL_ERROR_NONE = 0; + + /// < Invalid parameter + static const int APP_CONTROL_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int APP_CONTROL_ERROR_OUT_OF_MEMORY = -12; + + /// < The application is not found + static const int APP_CONTROL_ERROR_APP_NOT_FOUND = -17825759; + + /// < Specified key is not found + static const int APP_CONTROL_ERROR_KEY_NOT_FOUND = -126; + + /// < Key is not available + static const int APP_CONTROL_ERROR_KEY_REJECTED = -129; + + /// < Invalid data type + static const int APP_CONTROL_ERROR_INVALID_DATA_TYPE = -17825758; + + /// < The application cannot be launched now + static const int APP_CONTROL_ERROR_LAUNCH_REJECTED = -17825757; + + /// < Permission denied + static const int APP_CONTROL_ERROR_PERMISSION_DENIED = -13; + + /// < Internal launch error + static const int APP_CONTROL_ERROR_LAUNCH_FAILED = -17825756; + + /// < Time out + static const int APP_CONTROL_ERROR_TIMED_OUT = -1073741823; + + /// < IO error + static const int APP_CONTROL_ERROR_IO_ERROR = -5; +} + +/// @brief Enumeration for the application control result. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +/// @see app_control_enable_app_started_result_event() +abstract class app_control_result_e { + /// < Callee application launched actually (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int APP_CONTROL_RESULT_APP_STARTED = 1; + + /// < Operation succeeded + static const int APP_CONTROL_RESULT_SUCCEEDED = 0; + + /// < Operation failed by the callee + static const int APP_CONTROL_RESULT_FAILED = -1; + + /// < Operation canceled by the platform + static const int APP_CONTROL_RESULT_CANCELED = -2; +} + +/// @brief Enumeration for the application control launch mode. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class app_control_launch_mode_e { + /// < Prefer to launch an application as single mode + static const int APP_CONTROL_LAUNCH_MODE_SINGLE = 0; + + /// < Prefer to launch an application as group mode + static const int APP_CONTROL_LAUNCH_MODE_GROUP = 1; +} + +/// @brief Enumeration for application error. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class app_error_e { + /// < Successful + static const int APP_ERROR_NONE = 0; + + /// < Invalid parameter + static const int APP_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int APP_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid application context + static const int APP_ERROR_INVALID_CONTEXT = -17825791; + + /// < No such file or directory + static const int APP_ERROR_NO_SUCH_FILE = -2; + + /// < Not supported (Since 4.0) + static const int APP_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Application is already running + static const int APP_ERROR_ALREADY_RUNNING = -114; + + /// < Permission denied @if MOBILE (Since 2.3.1) @endif + static const int APP_ERROR_PERMISSION_DENIED = -13; +} + +/// @brief Enumeration for system events. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class app_event_type_e { + /// < The low memory event + static const int APP_EVENT_LOW_MEMORY = 0; + + /// < The low battery event + static const int APP_EVENT_LOW_BATTERY = 1; + + /// < The system language changed event + static const int APP_EVENT_LANGUAGE_CHANGED = 2; + + /// < The device orientation changed event + static const int APP_EVENT_DEVICE_ORIENTATION_CHANGED = 3; + + /// < The region format changed event + static const int APP_EVENT_REGION_FORMAT_CHANGED = 4; + + /// < The suspended state changed event of the application (since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + /// @see app_event_get_suspended_state + static const int APP_EVENT_SUSPENDED_STATE_CHANGED = 5; + + /// < The update requested event (Since 3.0) + /// This event can occur when an app needs to be updated. + /// It is dependent on target devices. + static const int APP_EVENT_UPDATE_REQUESTED = 6; +} + +/// @brief Enumeration for device orientation. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class app_device_orientation_e { + /// < The device is oriented in a natural position + static const int APP_DEVICE_ORIENTATION_0 = 0; + + /// < The device's left side is at the top + static const int APP_DEVICE_ORIENTATION_90 = 90; + + /// < The device is upside down + static const int APP_DEVICE_ORIENTATION_180 = 180; + + /// < The device's right side is at the top + static const int APP_DEVICE_ORIENTATION_270 = 270; +} + +/// @brief Enumeration for low memory status. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class app_event_low_memory_status_e { + /// < Normal status + static const int APP_EVENT_LOW_MEMORY_NORMAL = 1; + + /// < Soft warning status + static const int APP_EVENT_LOW_MEMORY_SOFT_WARNING = 2; + + /// < Hard warning status + static const int APP_EVENT_LOW_MEMORY_HARD_WARNING = 4; +} + +/// @brief Enumeration for battery status. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class app_event_low_battery_status_e { + /// < The battery status is under 1% + static const int APP_EVENT_LOW_BATTERY_POWER_OFF = 1; + + /// < The battery status is under 5% + static const int APP_EVENT_LOW_BATTERY_CRITICAL_LOW = 2; +} + +/// @brief Enumeration for suspended state. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class app_suspended_state_e { + /// < Application will enter the suspended state + static const int APP_SUSPENDED_STATE_WILL_ENTER = 0; + + /// < Application did exit from the suspended state + static const int APP_SUSPENDED_STATE_DID_EXIT = 1; +} + +class app_event_handler extends ffi.Opaque {} + +class app_event_info extends ffi.Opaque {} + +/// @brief The structure type containing the set of callback functions for handling application lifecycle events. +/// @details It is one of the input parameters of the ui_app_main() function. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +/// @see ui_app_main() +/// @see app_create_cb() +/// @see app_pause_cb() +/// @see app_resume_cb() +/// @see app_terminate_cb() +/// @see app_control_cb() +class ui_app_lifecycle_callback_s extends ffi.Struct { + /// < This callback function is called at the start of the application. + external ffi.Pointer> create; + + /// < This callback function is called once after the main loop of the application exits. + external ffi.Pointer> terminate; + + /// < This callback function is called each time the application is completely obscured by another application and becomes invisible to the user. + external ffi.Pointer> pause; + + /// < This callback function is called each time the application becomes visible to the user. + external ffi.Pointer> resume; + + /// < This callback function is called when another application sends the launch request to the application. + external ffi.Pointer> app_control; +} + +/// @brief Enumeration for Alarm Error. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class alarm_error_e { + /// < Successful + static const int ALARM_ERROR_NONE = 0; + + /// < Invalid parameter + static const int ALARM_ERROR_INVALID_PARAMETER = -22; + + /// < Invalid time + static const int ALARM_ERROR_INVALID_TIME = -17825787; + + /// < Invalid date + static const int ALARM_ERROR_INVALID_DATE = -17825786; + + /// < The alarm service connection failed + static const int ALARM_ERROR_CONNECTION_FAIL = -17825785; + + /// < Application is not permitted. (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int ALARM_ERROR_NOT_PERMITTED_APP = -17825784; + + /// < Out of memory + static const int ALARM_ERROR_OUT_OF_MEMORY = -12; + + /// < Permission denied + static const int ALARM_ERROR_PERMISSION_DENIED = -13; +} + +/// @brief Enumeration for Alarm Week Flag, the days of the week. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class alarm_week_flag_e { + /// < Sunday + static const int ALARM_WEEK_FLAG_SUNDAY = 1; + + /// < Monday + static const int ALARM_WEEK_FLAG_MONDAY = 2; + + /// < Tuesday + static const int ALARM_WEEK_FLAG_TUESDAY = 4; + + /// < Wednesday + static const int ALARM_WEEK_FLAG_WEDNESDAY = 8; + + /// < Thursday + static const int ALARM_WEEK_FLAG_THURSDAY = 16; + + /// < Friday + static const int ALARM_WEEK_FLAG_FRIDAY = 32; + + /// < Saturday + static const int ALARM_WEEK_FLAG_SATURDAY = 64; +} + +class tm extends ffi.Struct { + @ffi.Int32() + external int tm_sec; + + @ffi.Int32() + external int tm_min; + + @ffi.Int32() + external int tm_hour; + + @ffi.Int32() + external int tm_mday; + + @ffi.Int32() + external int tm_mon; + + @ffi.Int32() + external int tm_year; + + @ffi.Int32() + external int tm_wday; + + @ffi.Int32() + external int tm_yday; + + @ffi.Int32() + external int tm_isdst; + + @ffi.Int64() + external int tm_gmtoff; + + external ffi.Pointer tm_zone; +} + +class notification_h extends ffi.Opaque {} + +class event_handler extends ffi.Opaque {} + +/// @brief Enumeration for Event Error. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class event_error_e { + /// < Successful + static const int EVENT_ERROR_NONE = 0; + + /// < Invalid parameter + static const int EVENT_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int EVENT_ERROR_OUT_OF_MEMORY = -12; + + /// < Time out + static const int EVENT_ERROR_TIMED_OUT = -1073741823; + + /// < IO error + static const int EVENT_ERROR_IO_ERROR = -5; + + /// < Permission denied + static const int EVENT_ERROR_PERMISSION_DENIED = -13; +} + +/// @brief Enumeration for job error. +/// @since_tizen 4.0 +abstract class job_error_e { + /// < Successful + static const int JOB_ERROR_NONE = 0; + + /// < Invalid parameter + static const int JOB_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int JOB_ERROR_OUT_OF_MEMORY = -12; + + /// < IO error + static const int JOB_ERROR_IO_ERROR = -5; + + /// < Not initialized + static const int JOB_ERROR_NOT_INITIALIZED = -49938399; + + /// < No such job + static const int JOB_ERROR_NO_SUCH_JOB = -49938398; + + /// < Already exist + static const int JOB_ERROR_ALREADY_EXIST = -49938397; + + /// < Permission denied + static const int JOB_ERROR_PERMISSION_DENIED = -13; + + /// < Not supported + static const int JOB_ERROR_NOT_SUPPORTED = -1073741822; +} + +/// @brief Enumeration for the job trigger events. +/// @since_tizen 4.0 +abstract class job_trigger_event_e { + /// < The battery level status: Empty + static const int JOB_TRIGGER_EVENT_BATTERY_LEVEL_EMPTY = 0; + + /// < The battery level status: Critical + static const int JOB_TRIGGER_EVENT_BATTERY_LEVEL_CRITICAL = 1; + + /// < The battery level status: Low + static const int JOB_TRIGGER_EVENT_BATTERY_LEVEL_LOW = 2; + + /// < The battery level status: High + static const int JOB_TRIGGER_EVENT_BATTERY_LEVEL_HIGH = 3; + + /// < The charger state: Connected + static const int JOB_TRIGGER_EVENT_CHARGER_STATE_CONNECTED = 4; + + /// < The charger state: Disconnected + static const int JOB_TRIGGER_EVENT_CHARGER_STATE_DISCONNECTED = 5; + + /// < The display state: On + static const int JOB_TRIGGER_EVENT_DISPLAY_STATE_ON = 6; + + /// < The display state: Off + static const int JOB_TRIGGER_EVENT_DISPLAY_STATE_OFF = 7; + + /// < The display state: Dim + static const int JOB_TRIGGER_EVENT_DISPLAY_STATE_DIM = 8; + + /// < The earjack state: Connected + static const int JOB_TRIGGER_EVENT_EARJACK_STATE_CONNECTED = 9; + + /// < The earjack state: Disconnected + static const int JOB_TRIGGER_EVENT_EARJACK_STATE_DISCONNECTED = 10; + + /// < The GPS state: Disabled + static const int JOB_TRIGGER_EVENT_GPS_STATE_DISABLED = 11; + + /// < The GPS state: Searching + static const int JOB_TRIGGER_EVENT_GPS_STATE_SEARCHING = 12; + + /// < The GPS state: Connected + static const int JOB_TRIGGER_EVENT_GPS_STATE_CONNECTED = 13; + + /// < The Power-saving mode: Enabled + static const int JOB_TRIGGER_EVENT_POWERSAVE_MODE_ENABLED = 14; + + /// < The Power-saving mode: Disabled + static const int JOB_TRIGGER_EVENT_POWERSAVE_MODE_DISABLED = 15; + + /// < The USB state: Connected + static const int JOB_TRIGGER_EVENT_USB_STATE_CONNECTED = 16; + + /// < The USB state: Disconnected + static const int JOB_TRIGGER_EVENT_USB_STATE_DISCONNECTED = 17; + + /// < The WiFi state: Disabled @n Privilege: http://tizen.org/privilege/network.get + static const int JOB_TRIGGER_EVENT_WIFI_STATE_DISABLED = 18; + + /// < The WiFi state: Disconnected @n Privilege: http://tizen.org/privilege/network.get + static const int JOB_TRIGGER_EVENT_WIFI_STATE_DISCONNECTED = 19; + + /// < The WiFi state: Connected @n Privilege: http://tizen.org/privilege/network.get + static const int JOB_TRIGGER_EVENT_WIFI_STATE_CONNECTED = 20; +} + +class job_info_s extends ffi.Opaque {} + +class job_service_s extends ffi.Opaque {} + +/// @brief The structure type containing the set of callback functions for handling jobs. +/// @details It is one of the input parameter of the job_scheduler_service_add() function. +/// @since_tizen 4.0 +/// @see job_scheduler_service_add() +/// @see job_service_start_cb() +/// @see job_service_stop_cb() +class job_service_callback_s extends ffi.Struct { + /// < This callback function is called at the start of the job. + external ffi.Pointer> start; + + /// < This callback function is called at the stop of the job. + external ffi.Pointer> stop; +} + +/// @brief Enumeration for Preference Error. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class preference_error_e { + /// < Successful + static const int PREFERENCE_ERROR_NONE = 0; + + /// < Invalid parameter + static const int PREFERENCE_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int PREFERENCE_ERROR_OUT_OF_MEMORY = -12; + + /// < Required key not available + static const int PREFERENCE_ERROR_NO_KEY = -17825744; + + /// < Internal I/O Error + static const int PREFERENCE_ERROR_IO_ERROR = -5; +} + +/// @brief Enumeration for Resource Types +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class app_resource_e { + /// > + select_cb; + + /// < This callback function is called when a response is received for an insert operation from an application using the SQL-friendly interface based data control. + external ffi.Pointer> + insert_cb; + + /// < This callback function is called when a response is received for an update operation from an application using the SQL-friendly interface based data control. + external ffi.Pointer> + update_cb; + + /// < This callback function is called when a response is received for a delete operation from an application using the SQL-friendly interface based data control. + external ffi.Pointer> + delete_cb; +} + +/// @brief The structure type to contain the set of callback functions for handling the response events +/// of the key-value structured data control. +/// @since_tizen 2.3 +/// @see data_control_map_get_response_cb() +/// @see data_control_map_set_response_cb() +/// @see data_control_map_add_response_cb() +/// @see data_control_map_remove_response_cb() +class data_control_map_response_cb extends ffi.Struct { + /// < This callback function is called when the response is received for a getting value from the key-value structured data control provider. + external ffi.Pointer> + get_cb; + + /// < This callback function is called when the response is received for a setting value from the key-value structured data control provider. + external ffi.Pointer> + set_cb; + + /// < This callback function is called when the response is received for an adding value from the key-value structured data control provider. + external ffi.Pointer> + add_cb; + + /// < This callback function is called when the response is for a removing value received from the key-value structured data control provider. + external ffi.Pointer> + remove_cb; +} + +/// @brief The structure type to contain the set of callback functions for handling the request events +/// of SQL-friendly interface based data control. +/// @since_tizen 2.3 +/// +/// @see data_control_provider_sql_select_request_cb() +/// @see data_control_provider_sql_insert_request_cb() +/// @see data_control_provider_sql_update_request_cb() +/// @see data_control_provider_sql_delete_request_cb() +class data_control_provider_sql_cb extends ffi.Struct { + /// < This callback function is called when a request for insert operation is received from other application. + external ffi.Pointer< + ffi.NativeFunction> + insert_cb; + + /// < This callback function is called when a request for select operation is received from other application. + external ffi.Pointer< + ffi.NativeFunction> + select_cb; + + /// < This callback function is called when a request for update operation is received from other application. + external ffi.Pointer< + ffi.NativeFunction> + update_cb; + + /// < This callback function is called when a request for delete operation is received from other application. + external ffi.Pointer< + ffi.NativeFunction> + delete_cb; +} + +/// @brief The structure type to contain the set of callback functions for handling the request events +/// from the key-value structured data control consumer. +/// @since_tizen 2.3 +/// +/// @see data_control_provider_map_get_value_request_cb() +/// @see data_control_provider_map_set_value_request_cb() +/// @see data_control_provider_map_add_value_request_cb() +/// @see data_control_provider_map_remove_value_request_cb() +class data_control_provider_map_cb extends ffi.Struct { + /// < This callback function is called when a request for getting value is received from other application. + external ffi.Pointer< + ffi.NativeFunction> + get_cb; + + /// < This callback function is called when a request for setting value is received from other application. + external ffi.Pointer< + ffi.NativeFunction> + set_cb; + + /// < This callback function is called when a request for adding value is received from other application. + external ffi.Pointer< + ffi.NativeFunction> + add_cb; + + /// < This callback function is called when a request for removing value is received from other application. + external ffi.Pointer< + ffi.NativeFunction> + remove_cb; +} + +/// @brief Enumeration for error codes of a message port. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class message_port_error_e { + /// < Successful + static const int MESSAGE_PORT_ERROR_NONE = 0; + + /// < Internal I/O error + static const int MESSAGE_PORT_ERROR_IO_ERROR = -5; + + /// < Out of memory + static const int MESSAGE_PORT_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid parameter + static const int MESSAGE_PORT_ERROR_INVALID_PARAMETER = -22; + + /// < The message port of the remote application is not found + static const int MESSAGE_PORT_ERROR_PORT_NOT_FOUND = -18022399; + + /// < The remote application is not signed with the same certificate + static const int MESSAGE_PORT_ERROR_CERTIFICATE_NOT_MATCH = -18022398; + + /// < The size of the message has exceeded the maximum limit + static const int MESSAGE_PORT_ERROR_MAX_EXCEEDED = -18022397; + + /// < Resource is temporarily unavailable + static const int MESSAGE_PORT_ERROR_RESOURCE_UNAVAILABLE = -18022396; +} + +class package_info_s extends ffi.Opaque {} + +class package_updateinfo_s extends ffi.Opaque {} + +/// @brief Enumeration for storage type. +/// @since_tizen 2.3 +abstract class package_info_installed_storage_type_e { + /// < Internal storage + static const int PACKAGE_INFO_INTERNAL_STORAGE = 0; + + /// < External storage + static const int PACKAGE_INFO_EXTERNAL_STORAGE = 1; +} + +/// @brief Enumeration for app component type. +/// @since_tizen 2.3 +abstract class package_info_app_component_type_e { + /// < All application + static const int PACKAGE_INFO_ALLAPP = 0; + + /// < UI application + static const int PACKAGE_INFO_UIAPP = 1; + + /// < Service application + static const int PACKAGE_INFO_SERVICEAPP = 2; + + /// < Widget application (Since 4.0) + static const int PACKAGE_INFO_WIDGETAPP = 3; + + /// < Watch application (Since 4.0) + static const int PACKAGE_INFO_WATCHAPP = 4; +} + +/// @brief Enumeration for certification type. +/// @since_tizen 2.3 +abstract class package_cert_type_e { + /// < Author Root Certificate + static const int PACKAGE_INFO_AUTHOR_ROOT_CERT = 0; + + /// < Author Intermediate Certificate + static const int PACKAGE_INFO_AUTHOR_INTERMEDIATE_CERT = 1; + + /// < Author Signer Certificate + static const int PACKAGE_INFO_AUTHOR_SIGNER_CERT = 2; + + /// < Distributor Root Certificate + static const int PACKAGE_INFO_DISTRIBUTOR_ROOT_CERT = 3; + + /// < Distributor Intermediate Certificate + static const int PACKAGE_INFO_DISTRIBUTOR_INTERMEDIATE_CERT = 4; + + /// < Distributor Signer Certificate + static const int PACKAGE_INFO_DISTRIBUTOR_SIGNER_CERT = 5; + + /// < Distributor2 Root Certificate + static const int PACKAGE_INFO_DISTRIBUTOR2_ROOT_CERT = 6; + + /// < Distributor2 Intermediate Certificate + static const int PACKAGE_INFO_DISTRIBUTOR2_INTERMEDIATE_CERT = 7; + + /// < Distributor2 Signer Certificate + static const int PACKAGE_INFO_DISTRIBUTOR2_SIGNER_CERT = 8; +} + +/// @brief Enumeration for package update info type. +/// @since_tizen 4.0 +abstract class package_updateinfo_type_e { + /// < None type + static const int PACKAGE_UPDATEINFO_TYPE_NONE = 0; + + /// < Force type + static const int PACKAGE_UPDATEINFO_TYPE_FORCE = 1; + + /// < Optional type + static const int PACKAGE_UPDATEINFO_TYPE_OPTIONAL = 2; +} + +/// @brief Enumeration for error code. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class package_manager_error_e { + /// < Successful + static const int PACKAGE_MANAGER_ERROR_NONE = 0; + + /// < Invalid parameter + static const int PACKAGE_MANAGER_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY = -12; + + /// < Internal I/O error + static const int PACKAGE_MANAGER_ERROR_IO_ERROR = -5; + + /// < No such package + static const int PACKAGE_MANAGER_ERROR_NO_SUCH_PACKAGE = -18153359; + + /// < Severe system error + static const int PACKAGE_MANAGER_ERROR_SYSTEM_ERROR = -18153358; + + /// < Permission denied + static const int PACKAGE_MANAGER_ERROR_PERMISSION_DENIED = -13; +} + +/// @brief Enumeration for event type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class package_manager_event_type_e { + /// < Install event type + static const int PACKAGE_MANAGER_EVENT_TYPE_INSTALL = 0; + + /// < Uninstall event type + static const int PACKAGE_MANAGER_EVENT_TYPE_UNINSTALL = 1; + + /// < Update event type + static const int PACKAGE_MANAGER_EVENT_TYPE_UPDATE = 2; + + /// < Move event type (Since 3.0) + static const int PACKAGE_MANAGER_EVENT_TYPE_MOVE = 3; + + /// < Clear event type (Since 3.0) + static const int PACKAGE_MANAGER_EVENT_TYPE_CLEAR = 4; + static const int PACAKGE_MANAGER_EVENT_TYPE_INSTALL = 0; + static const int PACAKGE_MANAGER_EVENT_TYPE_UNINSTALL = 1; + static const int PACAKGE_MANAGER_EVENT_TYPE_UPDATE = 2; +} + +/// @brief Enumeration for event state. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class package_manager_event_state_e { + /// < Started event state + static const int PACKAGE_MANAGER_EVENT_STATE_STARTED = 0; + + /// < Processing event state + static const int PACKAGE_MANAGER_EVENT_STATE_PROCESSING = 1; + + /// < Completed event state + static const int PACKAGE_MANAGER_EVENT_STATE_COMPLETED = 2; + + /// < Failed event state + static const int PACKAGE_MANAGER_EVENT_STATE_FAILED = 3; + static const int PACAKGE_MANAGER_EVENT_STATE_STARTED = 0; + static const int PACAKGE_MANAGER_EVENT_STATE_PROCESSING = 1; + static const int PACAKGE_MANAGER_EVENT_STATE_COMPLETED = 2; + static const int PACAKGE_MANAGER_EVENT_STATE_FAILED = 3; +} + +/// @brief Enumeration for move type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class package_manager_move_type_e { + /// < Internal type + static const int PACKAGE_MANAGER_REQUEST_MOVE_TO_INTERNAL = 0; + + /// < External type + static const int PACKAGE_MANAGER_REQUEST_MOVE_TO_EXTERNAL = 1; + static const int PACAKGE_MANAGER_REQUEST_MOVE_TO_INTERNAL = 0; + static const int PACAKGE_MANAGER_REQUEST_MOVE_TO_EXTERNAL = 1; +} + +/// @brief Enumeration for certification compare type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class package_manager_compare_result_type_e { + /// < Matching certification + static const int PACKAGE_MANAGER_COMPARE_MATCH = 0; + + /// < Mismatching certification + static const int PACKAGE_MANAGER_COMPARE_MISMATCH = 1; + + /// < First package has no certification + static const int PACKAGE_MANAGER_COMPARE_LHS_NO_CERT = 2; + + /// < Second package has no certification + static const int PACKAGE_MANAGER_COMPARE_RHS_NO_CERT = 3; + + /// < Both have no certification + static const int PACKAGE_MANAGER_COMPARE_BOTH_NO_CERT = 4; + static const int PACAKGE_MANAGER_COMPARE_MATCH = 0; + static const int PACAKGE_MANAGER_COMPARE_MISMATCH = 1; + static const int PACAKGE_MANAGER_COMPARE_LHS_NO_CERT = 2; + static const int PACAKGE_MANAGER_COMPARE_RHS_NO_CERT = 3; + static const int PACAKGE_MANAGER_COMPARE_BOTH_NO_CERT = 4; +} + +/// @brief Enumeration for permission type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class package_manager_permission_type_e { + /// < Normal permission + static const int PACKAGE_MANAGER_PERMISSION_NORMAL = 0; + + /// < Signature permission + static const int PACKAGE_MANAGER_PERMISSION_SIGNATURE = 1; + + /// < Privilege permission + static const int PACKAGE_MANAGER_PERMISSION_PRIVILEGE = 2; +} + +/// @brief Enumeration for status type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class package_manager_status_type_e { + /// < All status + static const int PACKAGE_MANAGER_STATUS_TYPE_ALL = 0; + + /// < Install package status + static const int PACKAGE_MANAGER_STATUS_TYPE_INSTALL = 1; + + /// < Uninstall package status + static const int PACKAGE_MANAGER_STATUS_TYPE_UNINSTALL = 2; + + /// < Upgrade package status + static const int PACKAGE_MANAGER_STATUS_TYPE_UPGRADE = 4; + + /// < Move package status + static const int PACKAGE_MANAGER_STATUS_TYPE_MOVE = 8; + + /// < Clear data status + static const int PACKAGE_MANAGER_STATUS_TYPE_CLEAR_DATA = 16; + + /// < Install progress status + static const int PACKAGE_MANAGER_STATUS_TYPE_INSTALL_PROGRESS = 32; + + /// < Get size status + static const int PACKAGE_MANAGER_STATUS_TYPE_GET_SIZE = 64; +} + +class package_updateinfo_request_s extends ffi.Opaque {} + +class package_manager_s extends ffi.Opaque {} + +class package_manager_filter_s extends ffi.Opaque {} + +class package_size_info extends ffi.Opaque {} + +/// @platform +/// @brief Enumeration for request mode. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class package_manager_request_mode_e { + /// < @platform Default request mode + static const int PACKAGE_MANAGER_REQUEST_MODE_DEFAULT = 0; + + /// < @platform Quiet request mode + static const int PACKAGE_MANAGER_REQUEST_MODE_QUIET = 1; + static const int PACAKGE_MANAGER_REQUEST_MODE_DEFAULT = 0; + static const int PACAKGE_MANAGER_REQUEST_MODE_QUIET = 1; +} + +class package_manager_request_s extends ffi.Opaque {} + +class package_archive_info_s extends ffi.Opaque {} + +/// @brief The structure type containing the set of callback functions for handling application events. +/// @details It is one of the input parameters of the service_app_efl_main() function. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +/// @see service_app_main() +/// @see service_app_create_cb() +/// @see service_app_terminate_cb() +/// @see service_app_control_cb() +class service_app_lifecycle_callback_s extends ffi.Struct { + /// < This callback function is called at the start of the application. + external ffi.Pointer> create; + + /// < This callback function is called once after the main loop of the application exits. + external ffi.Pointer> terminate; + + /// < This callback function is called when another application sends the launch request to the application. + external ffi.Pointer> app_control; +} + +class _watch_time_s extends ffi.Opaque {} + +/// @brief The structure type containing the set of callback functions for application events handle. +/// @details It is one of the input parameters of the watch_app_main() function. +/// @since_tizen 2.3.1 +/// @see watch_app_main() +/// @see watch_app_create_cb() +/// @see watch_app_control_cb() +/// @see watch_app_pause_cb() +/// @see watch_app_resume_cb() +/// @see watch_app_time_tick_cb() +/// @see watch_app_ambient_tick_cb() +/// @see watch_app_ambient_changed_cb() +/// @see watch_app_terminate_cb() +class watch_app_lifecycle_callback_s extends ffi.Struct { + /// < This callback function is called at the start of the application. + external ffi.Pointer> create; + + /// < This callback function is called when another application sends the launch request to the application. + external ffi.Pointer> app_control; + + /// < This callback function is called each time the application is completely obscured by another application and becomes invisible to the user. + external ffi.Pointer> pause; + + /// < This callback function is called each time the application becomes visible to the user. + external ffi.Pointer> resume; + + /// < This callback function is called before the application exits. + external ffi.Pointer> terminate; + + /// < This callback function is called at each second. + external ffi.Pointer> time_tick; + + /// < This callback function is called at each minute in ambient mode. Since 2.3.2, you can change the period of ambient tick by calling watch_app_set_ambient_tick_type() + external ffi.Pointer> + ambient_tick; + + /// < This callback function is called when the device enters or exits ambient mode. + external ffi.Pointer> + ambient_changed; +} + +/// @brief Enumeration for tick resolution type. +/// @details It is one of the input parameters of the watch_app_set_time_tick_frequency() and watch_app_get_time_tick_frequency() functions. +/// @since_tizen 3.0 +/// @see watch_app_set_time_tick_frequency() +/// @see watch_app_get_time_tick_frequency() +abstract class watch_app_time_tick_resolution_e { + /// < 1 ~ 60 ticks per second + static const int WATCH_APP_TIME_TICKS_PER_SECOND = 0; + + /// < 1 ~ 60 ticks per minute + static const int WATCH_APP_TIME_TICKS_PER_MINUTE = 1; + + /// < 1 ~ 60 ticks per hour + static const int WATCH_APP_TIME_TICKS_PER_HOUR = 2; +} + +/// @brief Enumeration for periodic ambient tick type. +/// @since_tizen 2.3.2 +abstract class watch_app_ambient_tick_type_e { + /// No periodic ambient tick. + /// watch_app_ambient_tick_cb() will be called once when it enters the ambient mode. + static const int WATCH_APP_AMBIENT_TICK_NO_TICK = 0; + + /// watch_app_ambient_tick_cb() will be called every minute. + static const int WATCH_APP_AMBIENT_TICK_EVERY_MINUTE = 1; + + /// watch_app_ambient_tick_cb() will be called every 5 minutes. + /// It will be called at 12:00 AM, 12:05 AM, 12:10 AM ... + static const int WATCH_APP_AMBIENT_TICK_EVERY_FIVE_MINUTES = 2; + + /// watch_app_ambient_tick_cb() will be called every 15 minutes. + /// It will be called at 12:00 AM, 12:15 AM, 12:30 AM ... + static const int WATCH_APP_AMBIENT_TICK_EVERY_FIFTEEN_MINUTES = 3; + + /// watch_app_ambient_tick_cb() will be called every 30 minutes. + /// It will be called at 12:00 AM, 12:30 AM, 1:00 AM ... + static const int WATCH_APP_AMBIENT_TICK_EVERY_THIRTY_MINUTES = 4; + + /// watch_app_ambient_tick_cb() will be called every hour. + /// It will be called at 12:00 AM, 1:00 AM, 2:00 AM ... + static const int WATCH_APP_AMBIENT_TICK_EVERY_HOUR = 5; + + /// watch_app_ambient_tick_cb() will be called every 3 hours. + /// It will be called at 12:00 AM, 3:00 AM, 6:00 AM ... + static const int WATCH_APP_AMBIENT_TICK_EVERY_THREE_HOURS = 6; + + /// watch_app_ambient_tick_cb() will be called every 6 hours. + /// It will be called at 12:00 AM, 6:00 AM, 12:00 PM, 6:00 PM ... + static const int WATCH_APP_AMBIENT_TICK_EVERY_SIX_HOURS = 7; + + /// watch_app_ambient_tick_cb() will be called every 12 hours. + /// It will be called at 12:00 AM, 12:00 PM + static const int WATCH_APP_AMBIENT_TICK_EVERY_TWELVE_HOURS = 8; + + /// watch_app_ambient_tick_cb() will be called at the start of the day. + /// It will be called at 12:00 AM + static const int WATCH_APP_AMBIENT_TICK_EVERY_DAY = 9; +} + +class Evas_Object extends ffi.Opaque {} + +/// @brief Data structure which will be sent as a parameter of smart callback for signals WIDGET_SMART_SIGNAL_XXX. +/// @since_tizen 2.3.1 +/// @see #WIDGET_SMART_SIGNAL_WIDGET_CREATE_ABORTED +/// @see #WIDGET_SMART_SIGNAL_WIDGET_CREATED +/// @see #WIDGET_SMART_SIGNAL_WIDGET_RESIZE_ABORTED +/// @see #WIDGET_SMART_SIGNAL_WIDGET_RESIZED +/// @see #WIDGET_SMART_SIGNAL_WIDGET_FAULTED +/// @see #WIDGET_SMART_SIGNAL_UPDATED +/// @see #WIDGET_SMART_SIGNAL_EXTRA_INFO_UPDATED +/// @see #WIDGET_SMART_SIGNAL_PROVIDER_DISCONNECTED +/// @see #WIDGET_SMART_SIGNAL_CONTROL_SCROLLER +/// @see #WIDGET_SMART_SIGNAL_WIDGET_DELETED +/// @see #WIDGET_SMART_SIGNAL_PERIOD_CHANGED +class widget_evas_event_info_s extends ffi.Struct { + /// < Widget application id + external ffi.Pointer widget_app_id; + + /// < Event type for detail event information - WIDGET_EVENT_XXX, refer the widget_service.h + @ffi.Int32() + external int event; + + /// < Error type - WIDGET_ERROR_XXX, refer the widget_errno.h + @ffi.Int32() + external int error; +} + +/// @brief Enumerations for setting visibility status of a widget. +/// @since_tizen 2.3.1 +/// @see #widget_viewer_evas_freeze_visibility +abstract class widget_visibility_status_e { + /// < Visibility of the widget will be fixed as 'SHOW' + static const int WIDGET_VISIBILITY_STATUS_SHOW_FIXED = 1; + + /// < Visibility of the widget will be fixed as 'HIDE' + static const int WIDGET_VISIBILITY_STATUS_HIDE_FIXED = 2; +} + +/// @brief Enumeration for configuration keys. +/// @since_tizen 2.3.1 +/// @see #widget_viewer_evas_set_option +abstract class widget_evas_conf_e { + /// < Visibility will be changed manually. 1 : on, 0 : off + static const int WIDGET_VIEWER_EVAS_MANUAL_PAUSE_RESUME = 1; + + /// < Widget will be resized to specific size only. 1 : on, 0 : off + static const int WIDGET_VIEWER_EVAS_USE_FIXED_SIZE = 8; + + /// < Easy mode on/off. 1 : on, 0 : off + static const int WIDGET_VIEWER_EVAS_EASY_MODE = 16; + + /// < Box will be scrolled from left to right vice versa. 1 : on, 0 : off + static const int WIDGET_VIEWER_EVAS_SCROLL_X = 32; + + /// < Box will be scrolled from top to bottom vice versa. 1 : on, 0 : off + static const int WIDGET_VIEWER_EVAS_SCROLL_Y = 64; + + /// < Feeds event automatically from the master provider. 1 : on, 0 : off + static const int WIDGET_VIEWER_EVAS_EVENT_AUTO_FEED = 128; + + /// < Delaying the pause/resume when it is automatically changed. 1 : on, 0 : off + static const int WIDGET_VIEWER_EVAS_DELAYED_RESUME = 256; + + /// < Force feeds mouse up event if the box is moved. 1 : on, 0 : off + static const int WIDGET_VIEWER_EVAS_SENSITIVE_MOVE = 512; + + /// < Select render automatically, if a box moved, do not sync using animator, or use the animator. 1 : on, 0 : off + static const int WIDGET_VIEWER_EVAS_AUTO_RENDER_SELECTION = 1024; + + /// < Enable direct update path. 1 : on, 0 : off + static const int WIDGET_VIEWER_EVAS_DIRECT_UPDATE = 2048; + + /// < Use the render animator or not. 1 : on, 0 : off + static const int WIDGET_VIEWER_EVAS_USE_RENDER_ANIMATOR = 4096; + + /// < Even if the viewer cannot get acquired resource id, try to update using default one. 1 : on, 0 : off + static const int WIDGET_VIEWER_EVAS_SKIP_ACQUIRE = 8192; + static const int WIDGET_VIEWER_EVAS_UNKNOWN = 65535; +} + +/// @brief Enumeration of error code. +abstract class mime_type_error_e { + /// < Successful + static const int MIME_TYPE_ERROR_NONE = 0; + + /// < Invalid parameter + static const int MIME_TYPE_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int MIME_TYPE_ERROR_OUT_OF_MEMORY = -12; + + /// < Internal I/O error + static const int MIME_TYPE_ERROR_IO_ERROR = -5; + + /// < No access for the file (Since 4.0) + static const int MIME_TYPE_ERROR_PERMISSION_DENIED = -13; +} + +/// @ingroup CAPI_MEDIA_CONTENT_MODULE +/// @brief Enumeration for the media file format. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +/// @remarks Since 4.0, #MEDIA_CONTENT_TYPE_OTHERS is related to the following feature:\n +/// %http://tizen.org/feature/content.scanning.others\n +/// If this feature is not supported on the device, MEDIA_CONTENT_TYPE_OTHERS type file is not scanned. +abstract class media_content_type_e { + /// data; + + /// < The size of the buffer + @ffi.Uint32() + external int size; + + /// < The width of the image + @ffi.Int32() + external int width; + + /// < The height of the image + @ffi.Int32() + external int height; + + /// < The format of the image pixel + @ffi.Int32() + external int format; + + /// < The exif raw data + external ffi.Pointer exif; + + /// < The size of the exif data + @ffi.Uint32() + external int exif_size; +} + +/// @brief The structure type for face detection. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +class camera_detected_face_s extends ffi.Struct { + /// < The ID of each face + @ffi.Int32() + external int id; + + /// < The confidence level for the detection of the face + @ffi.Int32() + external int score; + + /// < The x coordinates of the face + @ffi.Int32() + external int x; + + /// < The y coordinates of the face + @ffi.Int32() + external int y; + + /// < The width of the face + @ffi.Int32() + external int width; + + /// < The height of the face + @ffi.Int32() + external int height; +} + +/// @brief The structure type to preview stream data. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +class camera_preview_data_s extends ffi.Opaque {} + +class camera_cli_s extends ffi.Opaque {} + +/// @brief Enumeration for the camera display mode. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class camera_display_mode_e { + /// < Letter box + static const int CAMERA_DISPLAY_MODE_LETTER_BOX = 0; + + /// < Origin size + static const int CAMERA_DISPLAY_MODE_ORIGIN_SIZE = 1; + + /// < Full screen + static const int CAMERA_DISPLAY_MODE_FULL = 2; + + /// < Cropped full screen + static const int CAMERA_DISPLAY_MODE_CROPPED_FULL = 3; + + /// < Original size or letter box (Since 3.0) + static const int CAMERA_DISPLAY_MODE_ORIGIN_OR_LETTER_BOX = 4; + + /// < Custom ROI (Since 3.0) + static const int CAMERA_DISPLAY_MODE_CUSTOM_ROI = 5; +} + +/// @brief Enumeration for the color tone, which provides the impression of looking through a tinted glass. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class camera_attr_effect_mode_e { + /// < None + static const int CAMERA_ATTR_EFFECT_NONE = 0; + + /// < Mono + static const int CAMERA_ATTR_EFFECT_MONO = 1; + + /// < Sepia + static const int CAMERA_ATTR_EFFECT_SEPIA = 2; + + /// < Negative + static const int CAMERA_ATTR_EFFECT_NEGATIVE = 3; + + /// < Blue + static const int CAMERA_ATTR_EFFECT_BLUE = 4; + + /// < Green + static const int CAMERA_ATTR_EFFECT_GREEN = 5; + + /// < Aqua + static const int CAMERA_ATTR_EFFECT_AQUA = 6; + + /// < Violet + static const int CAMERA_ATTR_EFFECT_VIOLET = 7; + + /// < Orange + static const int CAMERA_ATTR_EFFECT_ORANGE = 8; + + /// < Gray + static const int CAMERA_ATTR_EFFECT_GRAY = 9; + + /// < Red + static const int CAMERA_ATTR_EFFECT_RED = 10; + + /// < Antique + static const int CAMERA_ATTR_EFFECT_ANTIQUE = 11; + + /// < Warm + static const int CAMERA_ATTR_EFFECT_WARM = 12; + + /// < Pink + static const int CAMERA_ATTR_EFFECT_PINK = 13; + + /// < Yellow + static const int CAMERA_ATTR_EFFECT_YELLOW = 14; + + /// < Purple + static const int CAMERA_ATTR_EFFECT_PURPLE = 15; + + /// < Emboss + static const int CAMERA_ATTR_EFFECT_EMBOSS = 16; + + /// < Outline + static const int CAMERA_ATTR_EFFECT_OUTLINE = 17; + + /// < Solarization + static const int CAMERA_ATTR_EFFECT_SOLARIZATION = 18; + + /// < Sketch + static const int CAMERA_ATTR_EFFECT_SKETCH = 19; + + /// < Washed + static const int CAMERA_ATTR_EFFECT_WASHED = 20; + + /// < Vintage warm + static const int CAMERA_ATTR_EFFECT_VINTAGE_WARM = 21; + + /// < Vintage cold + static const int CAMERA_ATTR_EFFECT_VINTAGE_COLD = 22; + + /// < Posterization + static const int CAMERA_ATTR_EFFECT_POSTERIZATION = 23; + + /// < Cartoon + static const int CAMERA_ATTR_EFFECT_CARTOON = 24; + + /// < Selective color - Red + static const int CAMERA_ATTR_EFFECT_SELECTIVE_RED = 25; + + /// < Selective color - Green + static const int CAMERA_ATTR_EFFECT_SELECTIVE_GREEN = 26; + + /// < Selective color - Blue + static const int CAMERA_ATTR_EFFECT_SELECTIVE_BLUE = 27; + + /// < Selective color - Yellow + static const int CAMERA_ATTR_EFFECT_SELECTIVE_YELLOW = 28; + + /// < Selective color - Red and Yellow + static const int CAMERA_ATTR_EFFECT_SELECTIVE_RED_YELLOW = 29; + + /// < Other Graphic effects + static const int CAMERA_ATTR_EFFECT_OTHER_GRAPHICS = 30; +} + +/// @brief Enumeration for the white balance levels of the camera. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class camera_attr_whitebalance_e { + /// < None + static const int CAMERA_ATTR_WHITE_BALANCE_NONE = 0; + + /// < Automatic + static const int CAMERA_ATTR_WHITE_BALANCE_AUTOMATIC = 1; + + /// < Daylight + static const int CAMERA_ATTR_WHITE_BALANCE_DAYLIGHT = 2; + + /// < Cloudy + static const int CAMERA_ATTR_WHITE_BALANCE_CLOUDY = 3; + + /// < Fluorescent + static const int CAMERA_ATTR_WHITE_BALANCE_FLUORESCENT = 4; + + /// < Incandescent + static const int CAMERA_ATTR_WHITE_BALANCE_INCANDESCENT = 5; + + /// < Shade + static const int CAMERA_ATTR_WHITE_BALANCE_SHADE = 6; + + /// < Horizon + static const int CAMERA_ATTR_WHITE_BALANCE_HORIZON = 7; + + /// < Flash + static const int CAMERA_ATTR_WHITE_BALANCE_FLASH = 8; + + /// < Custom + static const int CAMERA_ATTR_WHITE_BALANCE_CUSTOM = 9; +} + +/// @brief Enumeration for the scene mode. +/// @details The mode of operation can be in daylight, night, or back-light. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class camera_attr_scene_mode_e { + /// < Normal + static const int CAMERA_ATTR_SCENE_MODE_NORMAL = 0; + + /// < Portrait + static const int CAMERA_ATTR_SCENE_MODE_PORTRAIT = 1; + + /// < Landscape + static const int CAMERA_ATTR_SCENE_MODE_LANDSCAPE = 2; + + /// < Sports + static const int CAMERA_ATTR_SCENE_MODE_SPORTS = 3; + + /// < Party & indoor + static const int CAMERA_ATTR_SCENE_MODE_PARTY_N_INDOOR = 4; + + /// < Beach & indoor + static const int CAMERA_ATTR_SCENE_MODE_BEACH_N_INDOOR = 5; + + /// < Sunset + static const int CAMERA_ATTR_SCENE_MODE_SUNSET = 6; + + /// < Dusk & dawn + static const int CAMERA_ATTR_SCENE_MODE_DUSK_N_DAWN = 7; + + /// < Fall + static const int CAMERA_ATTR_SCENE_MODE_FALL_COLOR = 8; + + /// < Night scene + static const int CAMERA_ATTR_SCENE_MODE_NIGHT_SCENE = 9; + + /// < Firework + static const int CAMERA_ATTR_SCENE_MODE_FIREWORK = 10; + + /// < Text + static const int CAMERA_ATTR_SCENE_MODE_TEXT = 11; + + /// < Show window + static const int CAMERA_ATTR_SCENE_MODE_SHOW_WINDOW = 12; + + /// < Candle light + static const int CAMERA_ATTR_SCENE_MODE_CANDLE_LIGHT = 13; + + /// < Backlight + static const int CAMERA_ATTR_SCENE_MODE_BACKLIGHT = 14; + + /// < Aqua + static const int CAMERA_ATTR_SCENE_MODE_AQUA = 15; +} + +/// @brief Enumeration for the auto focus mode. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class camera_attr_af_mode_e { + /// < auto-focus is not set + static const int CAMERA_ATTR_AF_NONE = 0; + + /// < auto-focus in the normal mode + static const int CAMERA_ATTR_AF_NORMAL = 1; + + /// < auto-focus in the macro mode(close distance) + static const int CAMERA_ATTR_AF_MACRO = 2; + + /// < auto-focus in the full mode(all range scan, limited by device spec) + static const int CAMERA_ATTR_AF_FULL = 3; +} + +/// @brief Enumeration for the ISO levels of the camera. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class camera_attr_iso_e { + /// < ISO auto mode + static const int CAMERA_ATTR_ISO_AUTO = 0; + + /// < ISO 50 + static const int CAMERA_ATTR_ISO_50 = 1; + + /// < ISO 100 + static const int CAMERA_ATTR_ISO_100 = 2; + + /// < ISO 200 + static const int CAMERA_ATTR_ISO_200 = 3; + + /// < ISO 400 + static const int CAMERA_ATTR_ISO_400 = 4; + + /// < ISO 800 + static const int CAMERA_ATTR_ISO_800 = 5; + + /// < ISO 1600 + static const int CAMERA_ATTR_ISO_1600 = 6; + + /// < ISO 3200 + static const int CAMERA_ATTR_ISO_3200 = 7; +} + +/// @brief Enumeration for the camera exposure modes. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class camera_attr_exposure_mode_e { + /// < Off + static const int CAMERA_ATTR_EXPOSURE_MODE_OFF = 0; + + /// < All mode + static const int CAMERA_ATTR_EXPOSURE_MODE_ALL = 1; + + /// < Center mode + static const int CAMERA_ATTR_EXPOSURE_MODE_CENTER = 2; + + /// < Spot mode + static const int CAMERA_ATTR_EXPOSURE_MODE_SPOT = 3; + + /// < Custom mode + static const int CAMERA_ATTR_EXPOSURE_MODE_CUSTOM = 4; +} + +/// @brief Enumeration for the orientation values of tag. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class camera_attr_tag_orientation_e { + /// < Row #0 is at the top, Column #0 is to the left + static const int CAMERA_ATTR_TAG_ORIENTATION_TOP_LEFT = 1; + + /// < Row #0 is at the top, Column #0 is to the right (flipped) + static const int CAMERA_ATTR_TAG_ORIENTATION_TOP_RIGHT = 2; + + /// < Row #0 is at the bottom, Column #0 is to the right + static const int CAMERA_ATTR_TAG_ORIENTATION_BOTTOM_RIGHT = 3; + + /// < Row #0 is at the bottom, Column #0 is to the left (flipped) + static const int CAMERA_ATTR_TAG_ORIENTATION_BOTTOM_LEFT = 4; + + /// < Row #0 is to the left, Column #0 is at the top (flipped) + static const int CAMERA_ATTR_TAG_ORIENTATION_LEFT_TOP = 5; + + /// < Row #0 is to the right, Column #0 is at the top + static const int CAMERA_ATTR_TAG_ORIENTATION_RIGHT_TOP = 6; + + /// < Row #0 is to the right, Column #0 is at the bottom (flipped) + static const int CAMERA_ATTR_TAG_ORIENTATION_RIGHT_BOTTOM = 7; + + /// < Row #0 is to the left, Column #0 is at the bottom + static const int CAMERA_ATTR_TAG_ORIENTATION_LEFT_BOTTOM = 8; +} + +/// @brief Enumeration for the flash mode. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class camera_attr_flash_mode_e { + /// < Always off + static const int CAMERA_ATTR_FLASH_MODE_OFF = 0; + + /// < Always splashes + static const int CAMERA_ATTR_FLASH_MODE_ON = 1; + + /// < Depending on intensity of light, strobe starts to flash + static const int CAMERA_ATTR_FLASH_MODE_AUTO = 2; + + /// < Red eye reduction. Multiple flash before capturing + static const int CAMERA_ATTR_FLASH_MODE_REDEYE_REDUCTION = 3; + + /// < Slow sync curtain synchronization + static const int CAMERA_ATTR_FLASH_MODE_SLOW_SYNC = 4; + + /// < Front curtain synchronization + static const int CAMERA_ATTR_FLASH_MODE_FRONT_CURTAIN = 5; + + /// < Rear curtain synchronization + static const int CAMERA_ATTR_FLASH_MODE_REAR_CURTAIN = 6; + + /// < Keep turned on until turning off + static const int CAMERA_ATTR_FLASH_MODE_PERMANENT = 7; +} + +/// @brief Enumeration to preview FPS. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class camera_attr_fps_e { + /// < AUTO FPS + static const int CAMERA_ATTR_FPS_AUTO = 0; + + /// < 7 FPS + static const int CAMERA_ATTR_FPS_7 = 7; + + /// < 8 FPS + static const int CAMERA_ATTR_FPS_8 = 8; + + /// < 15 FPS + static const int CAMERA_ATTR_FPS_15 = 15; + + /// < 20 FPS + static const int CAMERA_ATTR_FPS_20 = 20; + + /// < 24 FPS + static const int CAMERA_ATTR_FPS_24 = 24; + + /// < 25 FPS + static const int CAMERA_ATTR_FPS_25 = 25; + + /// < 30 FPS + static const int CAMERA_ATTR_FPS_30 = 30; + + /// < 60 FPS + static const int CAMERA_ATTR_FPS_60 = 60; + + /// < 90 FPS + static const int CAMERA_ATTR_FPS_90 = 90; + + /// < 120 FPS + static const int CAMERA_ATTR_FPS_120 = 120; +} + +/// @brief Enumeration for the theater mode. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class camera_attr_theater_mode_e { + /// < Disable theater mode - External display shows same image as device display + static const int CAMERA_ATTR_THEATER_MODE_DISABLE = 0; + + /// < Enable theater mode - Preview image is displayed on external display with full screen mode, but preview image is not shown on device display + static const int CAMERA_ATTR_THEATER_MODE_ENABLE = 2; + + /// < Clone mode - Preview image is displayed on external display with full screen mode. Also preview image is shown by the UI on device display + static const int CAMERA_ATTR_THEATER_MODE_CLONE = 1; +} + +/// @brief Enumeration for HDR capture mode. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class camera_attr_hdr_mode_e { + /// < Disable HDR capture + static const int CAMERA_ATTR_HDR_MODE_DISABLE = 0; + + /// < Enable HDR capture + static const int CAMERA_ATTR_HDR_MODE_ENABLE = 1; + + /// < Enable HDR capture and keep original image data + static const int CAMERA_ATTR_HDR_MODE_KEEP_ORIGINAL = 2; +} + +/// @brief Enumeration for PTZ(Pan Tilt Zoom) type. +/// @since_tizen 3.0 +abstract class camera_attr_ptz_type_e { + /// < Move the camera device physically + static const int CAMERA_ATTR_PTZ_TYPE_MECHANICAL = 0; + + /// < Zoom digitally and move into portion of the image + static const int CAMERA_ATTR_PTZ_TYPE_ELECTRONIC = 1; +} + +/// @brief Enumeration for PTZ(Pan Tilt Zoom) movement type. +/// @since_tizen 3.0 +abstract class camera_attr_ptz_move_type_e { + /// < Move to a specific coordinate position + static const int CAMERA_ATTR_PTZ_MOVE_ABSOLUTE = 0; + + /// < Move a specific distance from the current position + static const int CAMERA_ATTR_PTZ_MOVE_RELATIVE = 1; +} + +/// @brief Enumeration for error. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class image_util_error_e { + /// < Successful + static const int IMAGE_UTIL_ERROR_NONE = 0; + + /// < Invalid parameter + static const int IMAGE_UTIL_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int IMAGE_UTIL_ERROR_OUT_OF_MEMORY = -12; + + /// < No such file + static const int IMAGE_UTIL_ERROR_NO_SUCH_FILE = -2; + + /// < Internal error + static const int IMAGE_UTIL_ERROR_INVALID_OPERATION = -38; + + /// < Not supported format + static const int IMAGE_UTIL_ERROR_NOT_SUPPORTED_FORMAT = -26345471; + + /// < Permission denied + static const int IMAGE_UTIL_ERROR_PERMISSION_DENIED = -13; + + /// < Not supported + static const int IMAGE_UTIL_ERROR_NOT_SUPPORTED = -1073741822; +} + +/// @brief Enumeration for colorspace. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class image_util_colorspace_e { + /// < YV12 - YCrCb planar format + static const int IMAGE_UTIL_COLORSPACE_YV12 = 0; + + /// < YUV422 - planar + static const int IMAGE_UTIL_COLORSPACE_YUV422 = 1; + + /// < YUV420 - planar + static const int IMAGE_UTIL_COLORSPACE_I420 = 2; + + /// < NV12- planar + static const int IMAGE_UTIL_COLORSPACE_NV12 = 3; + + /// < UYVY - packed + static const int IMAGE_UTIL_COLORSPACE_UYVY = 4; + + /// < YUYV - packed + static const int IMAGE_UTIL_COLORSPACE_YUYV = 5; + + /// < RGB565, high-byte is Blue + static const int IMAGE_UTIL_COLORSPACE_RGB565 = 6; + + /// < RGB888, high-byte is Blue + static const int IMAGE_UTIL_COLORSPACE_RGB888 = 7; + + /// < ARGB8888, high-byte is Blue + static const int IMAGE_UTIL_COLORSPACE_ARGB8888 = 8; + + /// < BGRA8888, high-byte is Alpha + static const int IMAGE_UTIL_COLORSPACE_BGRA8888 = 9; + + /// < RGBA8888, high-byte is Alpha + static const int IMAGE_UTIL_COLORSPACE_RGBA8888 = 10; + + /// < BGRX8888, high-byte is X + static const int IMAGE_UTIL_COLORSPACE_BGRX8888 = 11; + + /// < NV12- planar + static const int IMAGE_UTIL_COLORSPACE_NV21 = 12; + + /// < NV16- planar + static const int IMAGE_UTIL_COLORSPACE_NV16 = 13; + + /// < NV61- planar + static const int IMAGE_UTIL_COLORSPACE_NV61 = 14; +} + +/// @brief Enumeration for rotation. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class image_util_rotation_e { + /// < None + static const int IMAGE_UTIL_ROTATION_NONE = 0; + + /// < Rotation 90 degree + static const int IMAGE_UTIL_ROTATION_90 = 1; + + /// < Rotation 180 degree + static const int IMAGE_UTIL_ROTATION_180 = 2; + + /// < Rotation 270 degree + static const int IMAGE_UTIL_ROTATION_270 = 3; + + /// < Flip horizontal + static const int IMAGE_UTIL_ROTATION_FLIP_HORZ = 4; + + /// < Flip vertical + static const int IMAGE_UTIL_ROTATION_FLIP_VERT = 5; +} + +class transformation_s extends ffi.Opaque {} + +/// @brief Enumeration for Image types. +/// @since_tizen 3.0 +abstract class image_util_type_e { + /// < Image format JPEG + static const int IMAGE_UTIL_JPEG = 0; + + /// < Image format PNG + static const int IMAGE_UTIL_PNG = 1; + + /// < Image format GIF + static const int IMAGE_UTIL_GIF = 2; + + /// < Image format BMP + static const int IMAGE_UTIL_BMP = 3; +} + +/// @brief Enumeration for scale decoding. +/// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif +abstract class image_util_scale_e { + /// < 1/1 downscale + static const int IMAGE_UTIL_DOWNSCALE_1_1 = 0; + + /// < 1/2 downscale + static const int IMAGE_UTIL_DOWNSCALE_1_2 = 1; + + /// < 1/4 downscale + static const int IMAGE_UTIL_DOWNSCALE_1_4 = 2; + + /// < 1/8 downscale + static const int IMAGE_UTIL_DOWNSCALE_1_8 = 3; +} + +/// @brief Enumeration for PNG compression values. +/// @since_tizen 3.0 +abstract class image_util_png_compression_e { + /// < No compression + static const int IMAGE_UTIL_PNG_COMPRESSION_0 = 0; + + /// < Compression Level 1. Best speed + static const int IMAGE_UTIL_PNG_COMPRESSION_1 = 1; + + /// < Compression Level 2 + static const int IMAGE_UTIL_PNG_COMPRESSION_2 = 2; + + /// < Compression Level 3 + static const int IMAGE_UTIL_PNG_COMPRESSION_3 = 3; + + /// < Compression Level 4 + static const int IMAGE_UTIL_PNG_COMPRESSION_4 = 4; + + /// < Compression Level 5 + static const int IMAGE_UTIL_PNG_COMPRESSION_5 = 5; + + /// < Compression Level 6 + static const int IMAGE_UTIL_PNG_COMPRESSION_6 = 6; + + /// < Compression Level 7 + static const int IMAGE_UTIL_PNG_COMPRESSION_7 = 7; + + /// < Compression Level 8 + static const int IMAGE_UTIL_PNG_COMPRESSION_8 = 8; + + /// < Compression Level 9. Best compression + static const int IMAGE_UTIL_PNG_COMPRESSION_9 = 9; +} + +class media_packet_pool_s extends ffi.Opaque {} + +class mediacodec_s extends ffi.Opaque {} + +/// @brief Enumeration of media codec support type +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +/// @remarks If this codec is to be used as an encoder or decoder, the codec flag must be set to #MEDIACODEC_ENCODER or +/// #MEDIACODEC_DECODER. If user doesn't set optional flag, default flags will be set to #MEDIACODEC_SUPPORT_TYPE_SW. +abstract class mediacodec_support_type_e { + /// < This flag is for using the encoder + static const int MEDIACODEC_ENCODER = 1; + + /// < This flag is for using the decoder + static const int MEDIACODEC_DECODER = 2; + + /// < This is an optional flag for using the h/w codec + static const int MEDIACODEC_SUPPORT_TYPE_HW = 4; + + /// < This is an optional flag for using the s/w codec + static const int MEDIACODEC_SUPPORT_TYPE_SW = 8; +} + +/// @brief Enumerations of media codec type +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class mediacodec_codec_type_e { + /// < NONE + static const int MEDIACODEC_NONE = 0; + + /// < L16 + static const int MEDIACODEC_L16 = 4112; + + /// < ALAW + static const int MEDIACODEC_ALAW = 4128; + + /// < ULAW + static const int MEDIACODEC_ULAW = 4144; + + /// < MEDIACDEC_AMR indicates AMR-NB (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_AMR = 4160; + + /// < AMR-NB (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_AMR_NB = 4160; + + /// < AMR-WB (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_AMR_WB = 4161; + + /// < G729 + static const int MEDIACODEC_G729 = 4176; + + /// < MEDIACDEC_AAC indicates AAC-LC (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_AAC = 4192; + + /// < AAC-LC (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_AAC_LC = 4192; + + /// < HE-AAC (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_AAC_HE = 4193; + + /// < HE-AAC-PS (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_AAC_HE_PS = 4194; + + /// < MP3 + static const int MEDIACODEC_MP3 = 4208; + + /// < VORBIS (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_VORBIS = 4224; + + /// < FLAC (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_FLAC = 4240; + + /// < WMA version 1 (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_WMAV1 = 4256; + + /// < WMA version 2 (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_WMAV2 = 4257; + + /// < WMA Professional (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_WMAPRO = 4258; + + /// < WMA Lossless (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_WMALSL = 4259; + + /// < H.261 + static const int MEDIACODEC_H261 = 8208; + + /// < H.263 + static const int MEDIACODEC_H263 = 8224; + + /// < H.264 + static const int MEDIACODEC_H264 = 8240; + + /// < MJPEG + static const int MEDIACODEC_MJPEG = 8256; + + /// < MPEG1 + static const int MEDIACODEC_MPEG1 = 8272; + + /// < MPEG2 + static const int MEDIACODEC_MPEG2 = 8288; + + /// < MPEG4 + static const int MEDIACODEC_MPEG4 = 8304; + + /// < HEVC (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_HEVC = 8320; + + /// < VP8 (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_VP8 = 8336; + + /// < VP9 (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_VP9 = 8352; + + /// < VC1 (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_VC1 = 8368; +} + +/// @brief Enumeration of media codec error +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class mediacodec_error_e { + /// < Successful + static const int MEDIACODEC_ERROR_NONE = 0; + + /// < Out of memory + static const int MEDIACODEC_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid parameter + static const int MEDIACODEC_ERROR_INVALID_PARAMETER = -22; + + /// < Invalid operation + static const int MEDIACODEC_ERROR_INVALID_OPERATION = -38; + + /// < Not supported + static const int MEDIACODEC_ERROR_NOT_SUPPORTED_ON_DEVICE = -1073741822; + + /// < Permission denied + static const int MEDIACODEC_ERROR_PERMISSION_DENIED = -13; + + /// < Invalid state + static const int MEDIACODEC_ERROR_INVALID_STATE = -26935295; + + /// < Invalid input buffer + static const int MEDIACODEC_ERROR_INVALID_INBUFFER = -26935294; + + /// < Invalid output buffer + static const int MEDIACODEC_ERROR_INVALID_OUTBUFFER = -26935293; + + /// < Internal error + static const int MEDIACODEC_ERROR_INTERNAL = -26935292; + + /// < Not initialized mediacodec + static const int MEDIACODEC_ERROR_NOT_INITIALIZED = -26935291; + + /// < Invalid stream + static const int MEDIACODEC_ERROR_INVALID_STREAM = -26935290; + + /// < Not supported format + static const int MEDIACODEC_ERROR_CODEC_NOT_FOUND = -26935289; + + /// < Error while decoding data + static const int MEDIACODEC_ERROR_DECODE = -26935288; + + /// < Out of storage + static const int MEDIACODEC_ERROR_NO_FREE_SPACE = -26935287; + + /// < Cannot find stream + static const int MEDIACODEC_ERROR_STREAM_NOT_FOUND = -26935286; + + /// < Not supported format + static const int MEDIACODEC_ERROR_NOT_SUPPORTED_FORMAT = -26935285; + + /// < Not available buffer + static const int MEDIACODEC_ERROR_BUFFER_NOT_AVAILABLE = -26935284; + + /// < Overflow input buffer (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_ERROR_OVERFLOW_INBUFFER = -26935283; + + /// < Exceed the instance limits (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int MEDIACODEC_ERROR_RESOURCE_OVERLOADED = -26935282; +} + +/// @brief Enumeration of buffer status +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class mediacodec_status_e { + static const int MEDIACODEC_NEED_DATA = 0; + static const int MEDIACODEC_ENOUGH_DATA = 1; +} + +/// @brief Enumeration for the media controller error. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class mc_error_e { + /// < Successful + static const int MEDIA_CONTROLLER_ERROR_NONE = 0; + + /// < Invalid parameter + static const int MEDIA_CONTROLLER_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int MEDIA_CONTROLLER_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid Operation + static const int MEDIA_CONTROLLER_ERROR_INVALID_OPERATION = -38; + + /// < No space left on device + static const int MEDIA_CONTROLLER_ERROR_FILE_NO_SPACE_ON_DEVICE = -28; + + /// < Permission denied + static const int MEDIA_CONTROLLER_ERROR_PERMISSION_DENIED = -13; +} + +/// @brief Enumeration for the media controller server state. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class mc_server_state_e { + /// < None state + static const int MC_SERVER_STATE_NONE = 0; + + /// < Activate state + static const int MC_SERVER_STATE_ACTIVATE = 1; + + /// < Deactivate state + static const int MC_SERVER_STATE_DEACTIVATE = 2; +} + +/// @brief Enumeration for the media meta info. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class mc_meta_e { + /// < Title + static const int MC_META_MEDIA_TITLE = 0; + + /// < Artist + static const int MC_META_MEDIA_ARTIST = 1; + + /// < Album + static const int MC_META_MEDIA_ALBUM = 2; + + /// < Author + static const int MC_META_MEDIA_AUTHOR = 3; + + /// < Genre + static const int MC_META_MEDIA_GENRE = 4; + + /// < Duration + static const int MC_META_MEDIA_DURATION = 5; + + /// < Date + static const int MC_META_MEDIA_DATE = 6; + + /// < Copyright + static const int MC_META_MEDIA_COPYRIGHT = 7; + + /// < Description + static const int MC_META_MEDIA_DESCRIPTION = 8; + + /// < Track Number + static const int MC_META_MEDIA_TRACK_NUM = 9; + + /// < Picture. Album Art + static const int MC_META_MEDIA_PICTURE = 10; +} + +/// @brief Enumeration for the media playback state. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class mc_playback_states_e { + /// < None + static const int MC_PLAYBACK_STATE_NONE = 0; + + /// < Playing + static const int MC_PLAYBACK_STATE_PLAYING = 1; + + /// < Paused + static const int MC_PLAYBACK_STATE_PAUSED = 2; + + /// < Stopped + static const int MC_PLAYBACK_STATE_STOPPED = 3; + + /// < Next file (Deprecated since 4.0) + static const int MC_PLAYBACK_STATE_NEXT_FILE = 4; + + /// < Previous file (Deprecated since 4.0) + static const int MC_PLAYBACK_STATE_PREV_FILE = 5; + + /// < Fast forward (Deprecated since 4.0) + static const int MC_PLAYBACK_STATE_FAST_FORWARD = 6; + + /// < Rewind (Deprecated since 4.0) + static const int MC_PLAYBACK_STATE_REWIND = 7; + + /// < Moving to the next item (Since 4.0) @if WEARABLE Supported in Mobile only @endif + static const int MC_PLAYBACK_STATE_MOVING_TO_NEXT = 8; + + /// < Moving to the previous item (Since 4.0) @if WEARABLE Supported in Mobile only @endif + static const int MC_PLAYBACK_STATE_MOVING_TO_PREVIOUS = 9; + + /// < Fast forwarding (Since 4.0) @if WEARABLE Supported in Mobile only @endif + static const int MC_PLAYBACK_STATE_FAST_FORWARDING = 10; + + /// < Rewinding (Since 4.0) @if WEARABLE Supported in Mobile only @endif + static const int MC_PLAYBACK_STATE_REWINDING = 11; +} + +/// @MOBILE_ONLY +/// @brief Enumeration for the media playback action. +/// @since_tizen 4.0 @if WEARABLE (Supported in Mobile only) @endif +abstract class mc_playback_action_e { + /// < Play + static const int MC_PLAYBACK_ACTION_PLAY = 0; + + /// < Pause + static const int MC_PLAYBACK_ACTION_PAUSE = 1; + + /// < Stop + static const int MC_PLAYBACK_ACTION_STOP = 2; + + /// < Next item + static const int MC_PLAYBACK_ACTION_NEXT = 3; + + /// < Previous item + static const int MC_PLAYBACK_ACTION_PREV = 4; + + /// < Fast forward + static const int MC_PLAYBACK_ACTION_FAST_FORWARD = 5; + + /// < Rewind + static const int MC_PLAYBACK_ACTION_REWIND = 6; + + /// < Play/Pause toggle + static const int MC_PLAYBACK_ACTION_TOGGLE_PLAY_PAUSE = 7; +} + +/// @brief Enumeration for the shuffle mode. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class mc_shuffle_mode_e { + /// < Shuffle mode on + static const int MC_SHUFFLE_MODE_ON = 0; + + /// < Shuffle mode off + static const int MC_SHUFFLE_MODE_OFF = 1; +} + +/// @brief Enumeration for the repeat mode. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class mc_repeat_mode_e { + /// < Repeat mode on for all media + static const int MC_REPEAT_MODE_ON = 0; + + /// < Repeat mode off + static const int MC_REPEAT_MODE_OFF = 1; + + /// < Repeat mode on for one media (Since 4.0) @if WEARABLE Supported in Mobile only @endif + static const int MC_REPEAT_MODE_ONE_MEDIA = 2; +} + +/// @brief Enumeration for the subscription type. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class mc_subscription_type_e { + /// < Server state + static const int MC_SUBSCRIPTION_TYPE_SERVER_STATE = 0; + + /// < Playback + static const int MC_SUBSCRIPTION_TYPE_PLAYBACK = 1; + + /// < Metadata + static const int MC_SUBSCRIPTION_TYPE_METADATA = 2; + + /// < Shuffle mode + static const int MC_SUBSCRIPTION_TYPE_SHUFFLE_MODE = 3; + + /// < Repeat mode + static const int MC_SUBSCRIPTION_TYPE_REPEAT_MODE = 4; + + /// < Playlist (Since 4.0) @if WEARABLE Supported in Mobile only @endif + static const int MC_SUBSCRIPTION_TYPE_PLAYLIST = 5; +} + +/// @MOBILE_ONLY +/// @brief Enumeration for the playlist update mode. +/// @since_tizen 4.0 @if WEARABLE (Supported in Mobile only) @endif +abstract class mc_playlist_update_mode_e { + /// < Create or Update playlist + static const int MC_PLAYLIST_UPDATED = 0; + + /// < Remove playlist + static const int MC_PLAYLIST_REMOVED = 1; +} + +class mediademuxer_s extends ffi.Opaque {} + +/// @brief Enumeration for media demuxer state +/// @since_tizen 3.0 +abstract class mediademuxer_state { + /// < The mediademuxer is not created + static const int MEDIADEMUXER_STATE_NONE = 0; + + /// < The mediademuxer is created, but not prepared + static const int MEDIADEMUXER_STATE_IDLE = 1; + + /// < The mediademuxer is ready to demux media + static const int MEDIADEMUXER_STATE_READY = 2; + + /// < The mediademuxer is demuxing media + static const int MEDIADEMUXER_STATE_DEMUXING = 3; +} + +/// @brief Enumeration for media demuxer error. +/// @since_tizen 3.0 +abstract class mediademuxer_error_e { + /// < Successful + static const int MEDIADEMUXER_ERROR_NONE = 0; + + /// < Out of memory + static const int MEDIADEMUXER_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid parameter + static const int MEDIADEMUXER_ERROR_INVALID_PARAMETER = -22; + + /// < Invalid operation + static const int MEDIADEMUXER_ERROR_INVALID_OPERATION = -38; + + /// < Not supported + static const int MEDIADEMUXER_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Permission denied + static const int MEDIADEMUXER_ERROR_PERMISSION_DENIED = -13; + + /// < Invalid state + static const int MEDIADEMUXER_ERROR_INVALID_STATE = -27131903; + + /// < Invalid path + static const int MEDIADEMUXER_ERROR_INVALID_PATH = -27131902; + + /// < Resource limit + static const int MEDIADEMUXER_ERROR_RESOURCE_LIMIT = -27131901; + + /// < Seek operation failure + static const int MEDIADEMUXER_ERROR_SEEK_FAILED = -27131900; + + /// < Not permitted format + static const int MEDIADEMUXER_ERROR_DRM_NOT_PERMITTED = -27131899; +} + +class mediamuxer_s extends ffi.Opaque {} + +/// @brief Enumeration for media muxer state +/// @since_tizen 3.0 +abstract class mediamuxer_state_e { + /// < The mediamuxer is not created + static const int MEDIAMUXER_STATE_NONE = 0; + + /// < The mediamuxer is created, but not prepared + static const int MEDIAMUXER_STATE_IDLE = 1; + + /// < The mediamuxer is ready to mux media + static const int MEDIAMUXER_STATE_READY = 2; + + /// < The mediamuxer is muxing media + static const int MEDIAMUXER_STATE_MUXING = 3; + + /// < The mediamuxer is paused while muxing media + static const int MEDIAMUXER_STATE_PAUSED = 4; +} + +/// @brief Enumeration for media muxer error +/// @since_tizen 3.0 +abstract class mediamuxer_error_e { + /// < Successful + static const int MEDIAMUXER_ERROR_NONE = 0; + + /// < Out of memory + static const int MEDIAMUXER_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid parameter + static const int MEDIAMUXER_ERROR_INVALID_PARAMETER = -22; + + /// < Invalid operation + static const int MEDIAMUXER_ERROR_INVALID_OPERATION = -38; + + /// < Not supported + static const int MEDIAMUXER_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Permission denied + static const int MEDIAMUXER_ERROR_PERMISSION_DENIED = -13; + + /// < Invalid state + static const int MEDIAMUXER_ERROR_INVALID_STATE = -27197439; + + /// < Invalid path + static const int MEDIAMUXER_ERROR_INVALID_PATH = -27197438; + + /// < Resource limit + static const int MEDIAMUXER_ERROR_RESOURCE_LIMIT = -27197437; +} + +/// @brief Enumeration for media muxer output format +/// @since_tizen 3.0 +abstract class mediamuxer_output_format_e { + /// < The mediamuxer output format is MP4 container + static const int MEDIAMUXER_CONTAINER_FORMAT_MP4 = 67121168; + + /// < The mediamuxer output format is 3GP container + static const int MEDIAMUXER_CONTAINER_FORMAT_3GP = 67121264; + + /// < The mediamuxer output format is WAV container + static const int MEDIAMUXER_CONTAINER_FORMAT_WAV = 67125264; + + /// < The mediamuxer output format is ARM_NB container + static const int MEDIAMUXER_CONTAINER_FORMAT_AMR_NB = 285216832; + + /// < The mediamuxer output format is AMR_WB container + static const int MEDIAMUXER_CONTAINER_FORMAT_AMR_WB = 285216833; + + /// < The mediamuxer output format is AAC_ADTS container + static const int MEDIAMUXER_CONTAINER_FORMAT_AAC_ADTS = 67125296; +} + +/// @brief Enumeration for media streamer node type. +/// +/// @since_tizen 3.0 +abstract class media_streamer_node_type_e { + /// < Not defined type + static const int MEDIA_STREAMER_NODE_TYPE_NONE = 0; + + /// < Src node type. Not available for media_streamer_node_create(). Use media_streamer_node_create_src() + static const int MEDIA_STREAMER_NODE_TYPE_SRC = 1; + + /// < Sink node type. Not available for media_streamer_node_create(). Use media_streamer_node_create_sink() + static const int MEDIA_STREAMER_NODE_TYPE_SINK = 2; + + /// < Video encoder node type + static const int MEDIA_STREAMER_NODE_TYPE_VIDEO_ENCODER = 3; + + /// < Video decoder node type + static const int MEDIA_STREAMER_NODE_TYPE_VIDEO_DECODER = 4; + + /// < Audio encoder node type + static const int MEDIA_STREAMER_NODE_TYPE_AUDIO_ENCODER = 5; + + /// < Audio decoder node type + static const int MEDIA_STREAMER_NODE_TYPE_AUDIO_DECODER = 6; + + /// < Video converter node type + static const int MEDIA_STREAMER_NODE_TYPE_VIDEO_CONVERTER = 7; + + /// < Audio converter node type + static const int MEDIA_STREAMER_NODE_TYPE_AUDIO_CONVERTER = 8; + + /// < Audio resample node type + static const int MEDIA_STREAMER_NODE_TYPE_AUDIO_RESAMPLE = 9; + + /// < Rtp video payloader + static const int MEDIA_STREAMER_NODE_TYPE_VIDEO_PAY = 10; + + /// < Rtp audio payloader + static const int MEDIA_STREAMER_NODE_TYPE_AUDIO_PAY = 11; + + /// < Rtp video depayloader + static const int MEDIA_STREAMER_NODE_TYPE_VIDEO_DEPAY = 12; + + /// < Rtp audio depayloader + static const int MEDIA_STREAMER_NODE_TYPE_AUDIO_DEPAY = 13; + + /// < Rate node type + static const int MEDIA_STREAMER_NODE_TYPE_VIDEO_RATE = 14; + + /// < Scale node type + static const int MEDIA_STREAMER_NODE_TYPE_VIDEO_SCALE = 15; + + /// < Overlay node type + static const int MEDIA_STREAMER_NODE_TYPE_TEXT_OVERLAY = 16; + + /// < Parser node type + static const int MEDIA_STREAMER_NODE_TYPE_PARSER = 17; + + /// < Filter node type, to limit formats of data + static const int MEDIA_STREAMER_NODE_TYPE_FILTER = 18; + + /// < Tee node type, splits data to multiple path + static const int MEDIA_STREAMER_NODE_TYPE_TEE = 19; + + /// < Queue node type + static const int MEDIA_STREAMER_NODE_TYPE_QUEUE = 20; + + /// < Multiple data queue node type + static const int MEDIA_STREAMER_NODE_TYPE_MQUEUE = 21; + + /// < Muxer node type + static const int MEDIA_STREAMER_NODE_TYPE_MUXER = 22; + + /// < Demuxer node type + static const int MEDIA_STREAMER_NODE_TYPE_DEMUXER = 23; + + /// < Rtp component to send and receive data + static const int MEDIA_STREAMER_NODE_TYPE_RTP = 24; + + /// < N-to-1 input stream selector + static const int MEDIA_STREAMER_NODE_TYPE_INPUT_SELECTOR = 25; + + /// < 1-to-N output stream selector + static const int MEDIA_STREAMER_NODE_TYPE_OUTPUT_SELECTOR = 26; + + /// < Folds many mono channel into one interleaved audio stream + static const int MEDIA_STREAMER_NODE_TYPE_INTERLEAVE = 27; + + /// < Splits multi channel audio into many mono audio + static const int MEDIA_STREAMER_NODE_TYPE_DEINTERLEAVE = 28; +} + +/// @brief Enumeration for media streamer source node type. +/// +/// @since_tizen 3.0 +abstract class media_streamer_node_src_type_e { + /// < Not defined src type + static const int MEDIA_STREAMER_NODE_SRC_TYPE_NONE = 0; + + /// < Local file src type + static const int MEDIA_STREAMER_NODE_SRC_TYPE_FILE = 1; + + /// < Http src type, Network internet feature is required + static const int MEDIA_STREAMER_NODE_SRC_TYPE_HTTP = 2; + + /// < Rtsp src type, Network internet feature is required + static const int MEDIA_STREAMER_NODE_SRC_TYPE_RTSP = 3; + + /// < Camera src type, Camera feature is required + static const int MEDIA_STREAMER_NODE_SRC_TYPE_CAMERA = 4; + + /// < Audio capture src type, Microphone feature is required + static const int MEDIA_STREAMER_NODE_SRC_TYPE_AUDIO_CAPTURE = 5; + + /// < Video capture src type, Camera feature is required + static const int MEDIA_STREAMER_NODE_SRC_TYPE_VIDEO_CAPTURE = 6; + + /// < Audio test src type + static const int MEDIA_STREAMER_NODE_SRC_TYPE_AUDIO_TEST = 7; + + /// < Video test src type + static const int MEDIA_STREAMER_NODE_SRC_TYPE_VIDEO_TEST = 8; + + /// < Custom src type + static const int MEDIA_STREAMER_NODE_SRC_TYPE_CUSTOM = 9; + + /// < Adaptive src type, Network internet feature is required + static const int MEDIA_STREAMER_NODE_SRC_TYPE_ADAPTIVE = 10; +} + +/// @brief Enumeration for media streamer sink node type. +/// +/// @since_tizen 3.0 +abstract class media_streamer_node_sink_type_e { + /// < Not defined sink type + static const int MEDIA_STREAMER_NODE_SINK_TYPE_NONE = 0; + + /// < Local file sink type + static const int MEDIA_STREAMER_NODE_SINK_TYPE_FILE = 1; + + /// < Rtsp sink type, Network internet feature is required + static const int MEDIA_STREAMER_NODE_SINK_TYPE_RTSP = 2; + + /// < Http sink type, Network internet feature is required + static const int MEDIA_STREAMER_NODE_SINK_TYPE_HTTP = 3; + + /// < Audio sink type + static const int MEDIA_STREAMER_NODE_SINK_TYPE_AUDIO = 4; + + /// < Overlay sink type + static const int MEDIA_STREAMER_NODE_SINK_TYPE_OVERLAY = 5; + + /// < Fake sink type + static const int MEDIA_STREAMER_NODE_SINK_TYPE_FAKE = 6; + + /// < Custom sink type + static const int MEDIA_STREAMER_NODE_SINK_TYPE_CUSTOM = 7; + + /// < Adaptive sink type to generate fragmented files + static const int MEDIA_STREAMER_NODE_SINK_TYPE_ADAPTIVE = 8; +} + +/// @brief Enumeration for media streamer state. +/// +/// @since_tizen 3.0 +abstract class media_streamer_state_e { + /// < Streamer is not created + static const int MEDIA_STREAMER_STATE_NONE = 0; + + /// < Streamer is created but not prepared + static const int MEDIA_STREAMER_STATE_IDLE = 1; + + /// < Streamer is ready to play + static const int MEDIA_STREAMER_STATE_READY = 2; + + /// < Streamer is playing + static const int MEDIA_STREAMER_STATE_PLAYING = 3; + + /// < Streamer is paused + static const int MEDIA_STREAMER_STATE_PAUSED = 4; + + /// < Seek is under operation + static const int MEDIA_STREAMER_STATE_SEEKING = 5; +} + +/// @brief Enumeration for media streamer error. +/// +/// @since_tizen 3.0 +abstract class media_streamer_error_e { + /// < Successful + static const int MEDIA_STREAMER_ERROR_NONE = 0; + + /// < Invalid parameter + static const int MEDIA_STREAMER_ERROR_INVALID_PARAMETER = -22; + + /// < Invalid operation + static const int MEDIA_STREAMER_ERROR_INVALID_OPERATION = -38; + + /// < No space left on the device + static const int MEDIA_STREAMER_ERROR_FILE_NO_SPACE_ON_DEVICE = -28; + + /// < The feature is not supported + static const int MEDIA_STREAMER_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Permission denied + static const int MEDIA_STREAMER_ERROR_PERMISSION_DENIED = -13; + + /// < Invalid state + static const int MEDIA_STREAMER_ERROR_INVALID_STATE = -27262975; + + /// < Connection failed + static const int MEDIA_STREAMER_ERROR_CONNECTION_FAILED = -27262974; + + /// < Resource conflict + static const int MEDIA_STREAMER_ERROR_RESOURCE_CONFLICT = -27262973; + + /// < Seek operation failure + static const int MEDIA_STREAMER_ERROR_SEEK_FAILED = -27262972; +} + +/// @brief Enumeration of media streamer buffer status of custom src. +/// +/// @since_tizen 3.0 +abstract class media_streamer_custom_buffer_status_e { + /// < Buffer underrun of custom src + static const int MEDIA_STREAMER_CUSTOM_BUFFER_UNDERRUN = 0; + + /// < Buffer overflow of custom src + static const int MEDIA_STREAMER_CUSTOM_BUFFER_OVERFLOW = 1; +} + +/// @brief Enumeration for media streamer's interruption type. +/// +/// @since_tizen 3.0 +abstract class media_streamer_interrupted_code_e { + /// < Interrupted by a resource conflict + static const int MEDIA_STREAMER_INTERRUPTED_BY_RESOURCE_CONFLICT = 0; + + /// < Interrupted by a security policy + static const int MEDIA_STREAMER_INTERRUPTED_BY_SECURITY = 1; +} + +/// @brief Point in 2D space. +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +class mv_point_s extends ffi.Struct { + /// < X-axis coordinate of the point in 2D space + @ffi.Int32() + external int x; + + /// < Y-axis coordinate of the point in 2D space + @ffi.Int32() + external int y; +} + +/// @brief Location of the object bounded by quadrangle defined by four 2D points. +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +class mv_quadrangle_s extends ffi.Struct { + @ffi.Array.multi([4]) + external ffi.Array points; +} + +/// @brief Location of the object bounded by rectangle defined by +/// coordinates of top left corner, width and height. +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +class mv_rectangle_s extends ffi.Struct { + /// < Top left corner of rectangle coordinates + external mv_point_s point; + + /// < Width of the bounding rectangle + @ffi.Int32() + external int width; + + /// < Height of the bounding rectangle + @ffi.Int32() + external int height; +} + +/// @brief Enumeration for Media Vision error. +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +abstract class mv_error_e { + static const int MEDIA_VISION_ERROR_NONE = 0; + static const int MEDIA_VISION_ERROR_NOT_SUPPORTED = -1073741822; + static const int MEDIA_VISION_ERROR_MSG_TOO_LONG = -90; + static const int MEDIA_VISION_ERROR_NO_DATA = -61; + static const int MEDIA_VISION_ERROR_KEY_NOT_AVAILABLE = -126; + static const int MEDIA_VISION_ERROR_OUT_OF_MEMORY = -12; + static const int MEDIA_VISION_ERROR_INVALID_PARAMETER = -22; + static const int MEDIA_VISION_ERROR_INVALID_OPERATION = -38; + static const int MEDIA_VISION_ERROR_PERMISSION_DENIED = -1; + static const int MEDIA_VISION_ERROR_NOT_SUPPORTED_FORMAT = -27066367; + static const int MEDIA_VISION_ERROR_INTERNAL = -27066366; + static const int MEDIA_VISION_ERROR_INVALID_DATA = -27066365; + static const int MEDIA_VISION_ERROR_INVALID_PATH = -27066364; +} + +/// @brief Enumeration for Media Vision @ref mv_engine_config_h handle attribute +/// type. +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +abstract class mv_config_attribute_type_e { + /// < Double attribute type + static const int MV_ENGINE_CONFIG_ATTR_TYPE_DOUBLE = 0; + + /// < Integer attribute type + static const int MV_ENGINE_CONFIG_ATTR_TYPE_INTEGER = 1; + + /// < Boolean attribute type + static const int MV_ENGINE_CONFIG_ATTR_TYPE_BOOLEAN = 2; + + /// < String attribute type + static const int MV_ENGINE_CONFIG_ATTR_TYPE_STRING = 3; +} + +/// @brief Enumeration for Media Vision colorspace. +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +abstract class mv_colorspace_e { + /// < The colorspace type is invalid + static const int MEDIA_VISION_COLORSPACE_INVALID = 0; + + /// < The colorspace type is Y800 + static const int MEDIA_VISION_COLORSPACE_Y800 = 1; + + /// < The colorspace type is I420 + static const int MEDIA_VISION_COLORSPACE_I420 = 2; + + /// < The colorspace type is NV12 + static const int MEDIA_VISION_COLORSPACE_NV12 = 3; + + /// < The colorspace type is YV12 + static const int MEDIA_VISION_COLORSPACE_YV12 = 4; + + /// < The colorspace type is NV21 + static const int MEDIA_VISION_COLORSPACE_NV21 = 5; + + /// < The colorspace type is YUYV + static const int MEDIA_VISION_COLORSPACE_YUYV = 6; + + /// < The colorspace type is UYVY + static const int MEDIA_VISION_COLORSPACE_UYVY = 7; + + /// < The colorspace type is 422P + static const int MEDIA_VISION_COLORSPACE_422P = 8; + + /// < The colorspace type is RGB565 + static const int MEDIA_VISION_COLORSPACE_RGB565 = 9; + + /// < The colorspace type is RGB888 + static const int MEDIA_VISION_COLORSPACE_RGB888 = 10; + + /// < The colorspace type is RGBA + static const int MEDIA_VISION_COLORSPACE_RGBA = 11; +} + +/// @brief Enumeration for supported barcode types. +/// @details QR codes (versions 1 to 40) and set of 1D barcodes are supported +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +abstract class mv_barcode_type_e { + /// < 2D barcode - Quick Response code + static const int MV_BARCODE_QR = 0; + + /// < 1D barcode - Universal Product Code with 12-digit + static const int MV_BARCODE_UPC_A = 1; + + /// < 1D barcode - Universal Product Code with 6-digit + static const int MV_BARCODE_UPC_E = 2; + + /// < 1D barcode - International Article Number with 8-digit + static const int MV_BARCODE_EAN_8 = 3; + + /// < 1D barcode - International Article Number with 13-digit + static const int MV_BARCODE_EAN_13 = 4; + + /// < 1D barcode - Code 128 + static const int MV_BARCODE_CODE128 = 5; + + /// < 1D barcode - Code 39 + static const int MV_BARCODE_CODE39 = 6; + + /// < 1D barcode - Interleaved Two of Five + static const int MV_BARCODE_I2_5 = 7; + + /// < Undefined + static const int MV_BARCODE_UNDEFINED = 8; +} + +/// @brief Enumeration for supported QR code error correction level. +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +/// @remarks This is unavailable for 1D barcodes +abstract class mv_barcode_qr_ecc_e { + /// < Recovery up to 7% losses + static const int MV_BARCODE_QR_ECC_LOW = 0; + + /// < Recovery up to 15% losses + static const int MV_BARCODE_QR_ECC_MEDIUM = 1; + + /// < Recovery up to 25% losses + static const int MV_BARCODE_QR_ECC_QUARTILE = 2; + + /// < Recovery up to 30% losses + static const int MV_BARCODE_QR_ECC_HIGH = 3; + + /// < Unavailable + static const int MV_BARCODE_QR_ECC_UNAVAILABLE = 4; +} + +/// @brief Enumeration for supported QR code encoding mode. +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +/// @remarks This is unavailable for 1D barcodes +abstract class mv_barcode_qr_mode_e { + /// < Numeric digits + static const int MV_BARCODE_QR_MODE_NUMERIC = 0; + + /// < Alphanumeric characters + static const int MV_BARCODE_QR_MODE_ALPHANUMERIC = 1; + + /// < Raw 8-bit bytes + static const int MV_BARCODE_QR_MODE_BYTE = 2; + + /// < UTF-8 character encoding + static const int MV_BARCODE_QR_MODE_UTF8 = 3; + + /// < Unavailable + static const int MV_BARCODE_QR_MODE_UNAVAILABLE = 4; +} + +/// @brief Enumeration for supported image formats for the barcode generating. +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +abstract class mv_barcode_image_format_e { + static const int MV_BARCODE_IMAGE_FORMAT_UNAVAILABLE = -1; + + /// < BMP image format + static const int MV_BARCODE_IMAGE_FORMAT_BMP = 0; + + /// < JPEG image format + static const int MV_BARCODE_IMAGE_FORMAT_JPG = 1; + + /// < PNG image format + static const int MV_BARCODE_IMAGE_FORMAT_PNG = 2; + + /// < The number of supported image format + static const int MV_BARCODE_IMAGE_FORMAT_NUM = 3; +} + +/// @brief Enumeration to target attribute +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +abstract class mv_barcode_detect_attr_target_e { + /// < 1D and 2D + static const int MV_BARCODE_DETECT_ATTR_TARGET_ALL = 0; + + /// < 1D barcode only + static const int MV_BARCODE_DETECT_ATTR_TARGET_1D_BARCODE = 1; + + /// < 2D barcode only + static const int MV_BARCODE_DETECT_ATTR_TARGET_2D_BARCODE = 2; +} + +/// @brief Enumeration to text attribute +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +abstract class mv_barcode_generate_attr_text_e { + /// < Invisible + static const int MV_BARCODE_GENERATE_ATTR_TEXT_INVISIBLE = 0; + + /// < Visible + static const int MV_BARCODE_GENERATE_ATTR_TEXT_VISIBLE = 1; +} + +/// @brief Enumeration for eyes state type. +/// +/// @since_tizen 3.0 +/// +/// @see mv_face_eye_condition_recognize() +abstract class mv_face_eye_condition_e { + /// < Eyes are open + static const int MV_FACE_EYES_OPEN = 0; + + /// < Eyes are closed + static const int MV_FACE_EYES_CLOSED = 1; + + /// < The eyes condition wasn't determined + static const int MV_FACE_EYES_NOT_FOUND = 2; +} + +/// @brief Enumeration for expression types can be determined for faces. +/// +/// @since_tizen 3.0 +/// +/// @see mv_face_facial_expression_recognize() +abstract class mv_face_facial_expression_e { + /// < Unknown face expression + static const int MV_FACE_UNKNOWN = 0; + + /// < Face expression is neutral + static const int MV_FACE_NEUTRAL = 1; + + /// < Face expression is smiling + static const int MV_FACE_SMILE = 2; + + /// < Face expression is sadness + static const int MV_FACE_SADNESS = 3; + + /// < Face expression is surprise + static const int MV_FACE_SURPRISE = 4; + + /// < Face expression is anger + static const int MV_FACE_ANGER = 5; + + /// < Face expression is fear + static const int MV_FACE_FEAR = 6; + + /// < Face expression is disgust + static const int MV_FACE_DISGUST = 7; +} + +/// @ingroup CAPI_MEDIA_METADATA_EDITOR_MODULE +/// @brief The enumerations of media metadata error. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class metadata_editor_error_e { + /// < Successful + static const int METADATA_EDITOR_ERROR_NONE = 0; + + /// < Invalid parameter + static const int METADATA_EDITOR_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int METADATA_EDITOR_ERROR_OUT_OF_MEMORY = -12; + + /// < File not exist + static const int METADATA_EDITOR_ERROR_FILE_EXISTS = -17; + + /// < Permission denied + static const int METADATA_EDITOR_ERROR_PERMISSION_DENIED = -13; + + /// < Unsupported type + static const int METADATA_EDITOR_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Invalid internal operation + static const int METADATA_EDITOR_ERROR_OPERATION_FAILED = -27000831; +} + +/// @ingroup CAPI_MEDIA_METADATA_EDITOR_MODULE +/// @brief The enumerations of attribute. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class metadata_editor_attr_e { + /// < Artist + static const int METADATA_EDITOR_ATTR_ARTIST = 0; + + /// < Title + static const int METADATA_EDITOR_ATTR_TITLE = 1; + + /// < Album + static const int METADATA_EDITOR_ATTR_ALBUM = 2; + + /// < Genre + static const int METADATA_EDITOR_ATTR_GENRE = 3; + + /// < Author + static const int METADATA_EDITOR_ATTR_AUTHOR = 4; + + /// < Copyright + static const int METADATA_EDITOR_ATTR_COPYRIGHT = 5; + + /// < Date + static const int METADATA_EDITOR_ATTR_DATE = 6; + + /// < Description + static const int METADATA_EDITOR_ATTR_DESCRIPTION = 7; + + /// < Comment + static const int METADATA_EDITOR_ATTR_COMMENT = 8; + + /// < Track number info + static const int METADATA_EDITOR_ATTR_TRACK_NUM = 9; + + /// < Picture number + static const int METADATA_EDITOR_ATTR_PICTURE_NUM = 10; + + /// < Conductor + static const int METADATA_EDITOR_ATTR_CONDUCTOR = 11; + + /// < Unsynchronized lyric + static const int METADATA_EDITOR_ATTR_UNSYNCLYRICS = 12; +} + +/// @ingroup CAPI_METADATA_EXTRACTOR_MODULE +/// @brief Enumeration for metadata extractor error. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class metadata_extractor_error_e { + /// < Successful + static const int METADATA_EXTRACTOR_ERROR_NONE = 0; + + /// < Invalid parameter + static const int METADATA_EXTRACTOR_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int METADATA_EXTRACTOR_ERROR_OUT_OF_MEMORY = -12; + + /// < File does not exist + static const int METADATA_EXTRACTOR_ERROR_FILE_EXISTS = -17; + + /// < Permission denied + static const int METADATA_EXTRACTOR_ERROR_PERMISSION_DENIED = -13; + + /// < Invalid internal operation + static const int METADATA_EXTRACTOR_ERROR_OPERATION_FAILED = -26411007; +} + +/// @ingroup CAPI_METADATA_EXTRACTOR_MODULE +/// @brief Enumeration for attribute. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class metadata_extractor_attr_e { + /// < Duration + static const int METADATA_DURATION = 0; + + /// < Video Bitrate + static const int METADATA_VIDEO_BITRATE = 1; + + /// < Video FPS + static const int METADATA_VIDEO_FPS = 2; + + /// < Video Width + static const int METADATA_VIDEO_WIDTH = 3; + + /// < Video Height + static const int METADATA_VIDEO_HEIGHT = 4; + + /// < Video stream count + static const int METADATA_HAS_VIDEO = 5; + + /// < Audio Bitrate + static const int METADATA_AUDIO_BITRATE = 6; + + /// < Audio Channels + static const int METADATA_AUDIO_CHANNELS = 7; + + /// < Audio Samplerate + static const int METADATA_AUDIO_SAMPLERATE = 8; + + /// < Audio bit per sample + static const int METADATA_AUDIO_BITPERSAMPLE = 9; + + /// < Audio stream count + static const int METADATA_HAS_AUDIO = 10; + + /// < Artist + static const int METADATA_ARTIST = 11; + + /// < Title + static const int METADATA_TITLE = 12; + + /// < Album + static const int METADATA_ALBUM = 13; + + /// < Album_Artist + static const int METADATA_ALBUM_ARTIST = 14; + + /// < Genre + static const int METADATA_GENRE = 15; + + /// < Author (Deprecated since 4.0. Use METADATA_COMPOSER instead) + static const int METADATA_AUTHOR = 16; + + /// < Composer + static const int METADATA_COMPOSER = 16; + + /// < Copyright + static const int METADATA_COPYRIGHT = 17; + + /// < Date + static const int METADATA_DATE = 18; + + /// < Description + static const int METADATA_DESCRIPTION = 19; + + /// < Comment + static const int METADATA_COMMENT = 20; + + /// < Track number info + static const int METADATA_TRACK_NUM = 21; + + /// < Classification + static const int METADATA_CLASSIFICATION = 22; + + /// < Rating + static const int METADATA_RATING = 23; + + /// < Longitude + static const int METADATA_LONGITUDE = 24; + + /// < Latitude + static const int METADATA_LATITUDE = 25; + + /// < Altitude + static const int METADATA_ALTITUDE = 26; + + /// < Conductor + static const int METADATA_CONDUCTOR = 27; + + /// < Unsynchronized lyric + static const int METADATA_UNSYNCLYRICS = 28; + + /// < Synchronized lyric (time/lyric set) number + static const int METADATA_SYNCLYRICS_NUM = 29; + + /// < Recording date + static const int METADATA_RECDATE = 30; + + /// < Rotate(Orientation) Information + static const int METADATA_ROTATE = 31; + + /// < Video Codec (Since 3.0) + static const int METADATA_VIDEO_CODEC = 32; + + /// < Audio Codec (Since 3.0) + static const int METADATA_AUDIO_CODEC = 33; + + /// < Flag indicating if the video is a spherical video (Since 3.0) + static const int METADATA_360 = 34; +} + +class metadata_extractor_s extends ffi.Opaque {} + +class player_s extends ffi.Opaque {} + +/// @brief Enumeration for media player state. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class player_state_e { + /// < Player is not created + static const int PLAYER_STATE_NONE = 0; + + /// < Player is created, but not prepared + static const int PLAYER_STATE_IDLE = 1; + + /// < Player is ready to play media + static const int PLAYER_STATE_READY = 2; + + /// < Player is playing media + static const int PLAYER_STATE_PLAYING = 3; + + /// < Player is paused while playing media + static const int PLAYER_STATE_PAUSED = 4; +} + +/// @brief Enumeration for media player's error codes. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class player_error_e { + /// < Successful + static const int PLAYER_ERROR_NONE = 0; + + /// < Out of memory + static const int PLAYER_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid parameter + static const int PLAYER_ERROR_INVALID_PARAMETER = -22; + + /// < No such file or directory + static const int PLAYER_ERROR_NO_SUCH_FILE = -2; + + /// < Invalid operation + static const int PLAYER_ERROR_INVALID_OPERATION = -38; + + /// < No space left on the device + static const int PLAYER_ERROR_FILE_NO_SPACE_ON_DEVICE = -28; + + /// < Not supported Feature + static const int PLAYER_ERROR_FEATURE_NOT_SUPPORTED_ON_DEVICE = -1073741822; + + /// < Seek operation failure + static const int PLAYER_ERROR_SEEK_FAILED = -26476511; + + /// < Invalid state + static const int PLAYER_ERROR_INVALID_STATE = -26476510; + + /// < File format not supported + static const int PLAYER_ERROR_NOT_SUPPORTED_FILE = -26476509; + + /// < Invalid URI + static const int PLAYER_ERROR_INVALID_URI = -26476508; + + /// < Sound policy error + static const int PLAYER_ERROR_SOUND_POLICY = -26476507; + + /// < Streaming connection failed + static const int PLAYER_ERROR_CONNECTION_FAILED = -26476506; + + /// < Video capture failed + static const int PLAYER_ERROR_VIDEO_CAPTURE_FAILED = -26476505; + + /// < Expired license + static const int PLAYER_ERROR_DRM_EXPIRED = -26476504; + + /// < No license + static const int PLAYER_ERROR_DRM_NO_LICENSE = -26476503; + + /// < License for future use + static const int PLAYER_ERROR_DRM_FUTURE_USE = -26476502; + + /// < Format not permitted + static const int PLAYER_ERROR_DRM_NOT_PERMITTED = -26476501; + + /// < Resource limit + static const int PLAYER_ERROR_RESOURCE_LIMIT = -26476500; + + /// < Permission denied + static const int PLAYER_ERROR_PERMISSION_DENIED = -13; + + /// < Socket connection lost (Since 3.0) + static const int PLAYER_ERROR_SERVICE_DISCONNECTED = -26476499; + + /// < No buffer space available (Since 3.0) + static const int PLAYER_ERROR_BUFFER_SPACE = -105; + + /// < Not supported audio codec but video can be played (Since 4.0) + static const int PLAYER_ERROR_NOT_SUPPORTED_AUDIO_CODEC = -26476498; + + /// < Not supported video codec but audio can be played (Since 4.0) + static const int PLAYER_ERROR_NOT_SUPPORTED_VIDEO_CODEC = -26476497; + + /// < Not supported subtitle format (Since 4.0) + static const int PLAYER_ERROR_NOT_SUPPORTED_SUBTITLE = -26476496; +} + +/// @brief Enumeration for media player's interruption type. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class player_interrupted_code_e { + /// < Interrupt completed (Deprecated since 3.0) + static const int PLAYER_INTERRUPTED_COMPLETED = 0; + + /// < Interrupted by a non-resumable media application (Deprecated since 3.0) + static const int PLAYER_INTERRUPTED_BY_MEDIA = 1; + + /// < Interrupted by an incoming call (Deprecated since 3.0) + static const int PLAYER_INTERRUPTED_BY_CALL = 2; + + /// < Interrupted by unplugging headphones (Deprecated since 3.0) + static const int PLAYER_INTERRUPTED_BY_EARJACK_UNPLUG = 3; + + /// < Interrupted by a resource conflict and the player handle will be paused or unprepared + static const int PLAYER_INTERRUPTED_BY_RESOURCE_CONFLICT = 4; + + /// < Interrupted by an alarm (Deprecated since 3.0) + static const int PLAYER_INTERRUPTED_BY_ALARM = 5; + + /// < Interrupted by an emergency (Deprecated since 3.0) + static const int PLAYER_INTERRUPTED_BY_EMERGENCY = 6; + + /// < Interrupted by a notification (Deprecated since 3.0) + static const int PLAYER_INTERRUPTED_BY_NOTIFICATION = 7; +} + +/// @brief Enumeration for progressive download message type. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class player_pd_message_type_e { + /// < Progressive download is started + static const int PLAYER_PD_STARTED = 0; + + /// < Progressive download is completed + static const int PLAYER_PD_COMPLETED = 1; +} + +/// @brief Enumeration for display type. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class player_display_type_e { + /// < Overlay surface display + static const int PLAYER_DISPLAY_TYPE_OVERLAY = 0; + static const int PLAYER_DISPLAY_TYPE_OBSOLETE_EVAS_WNONE = 1; + static const int PLAYER_DISPLAY_TYPE_OBSOLETE_NONE_WEVAS = 2; + + /// < Evas image object surface display (Since 4.0) + static const int PLAYER_DISPLAY_TYPE_EVAS = 3; + + /// < This disposes of buffers (Since 4.0) + static const int PLAYER_DISPLAY_TYPE_NONE = 4; +} + +/// @brief Enumeration for audio latency mode. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class audio_latency_mode_e { + /// < Low audio latency mode + static const int AUDIO_LATENCY_MODE_LOW = 0; + + /// < Middle audio latency mode + static const int AUDIO_LATENCY_MODE_MID = 1; + + /// < High audio latency mode + static const int AUDIO_LATENCY_MODE_HIGH = 2; +} + +/// @brief Enumeration for stream type. +/// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif +abstract class player_stream_type_e { + /// < Container type + static const int PLAYER_STREAM_TYPE_DEFAULT = 0; + + /// < Audio element stream type + static const int PLAYER_STREAM_TYPE_AUDIO = 1; + + /// < Video element stream type + static const int PLAYER_STREAM_TYPE_VIDEO = 2; + + /// < Text type + static const int PLAYER_STREAM_TYPE_TEXT = 3; +} + +/// @brief Enumeration of media stream buffer status. +/// @since_tizen @if WEARABLE 3.0 @else 2.4 @endif +/// @see player_set_media_stream_buffer_max_size() +/// @see player_set_media_stream_buffer_min_threshold() +abstract class player_media_stream_buffer_status_e { + /// < The buffer level is lower than the threshold + static const int PLAYER_MEDIA_STREAM_BUFFER_UNDERRUN = 0; + + /// < The buffer level is over than the threshold + static const int PLAYER_MEDIA_STREAM_BUFFER_OVERFLOW = 1; +} + +/// @brief Enumeration for display rotation type. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class player_display_rotation_e { + /// < Display is not rotated + static const int PLAYER_DISPLAY_ROTATION_NONE = 0; + + /// < Display is rotated 90 degrees + static const int PLAYER_DISPLAY_ROTATION_90 = 1; + + /// < Display is rotated 180 degrees + static const int PLAYER_DISPLAY_ROTATION_180 = 2; + + /// < Display is rotated 270 degrees + static const int PLAYER_DISPLAY_ROTATION_270 = 3; +} + +/// @brief Enumeration for display mode. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class player_display_mode_e { + /// < Letter box + static const int PLAYER_DISPLAY_MODE_LETTER_BOX = 0; + + /// < Origin size + static const int PLAYER_DISPLAY_MODE_ORIGIN_SIZE = 1; + + /// < Full-screen + static const int PLAYER_DISPLAY_MODE_FULL_SCREEN = 2; + + /// < Cropped full-screen + static const int PLAYER_DISPLAY_MODE_CROPPED_FULL = 3; + + /// < Origin size (if surface size is larger than video size(width/height)) or Letter box (if video size(width/height) is larger than surface size) + static const int PLAYER_DISPLAY_MODE_ORIGIN_OR_LETTER = 4; + + /// < Dst ROI mode + static const int PLAYER_DISPLAY_MODE_DST_ROI = 5; + static const int PLAYER_DISPLAY_MODE_NUM = 6; +} + +/// @brief Enumeration for media stream content information. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class player_content_info_e { + /// < Album + static const int PLAYER_CONTENT_INFO_ALBUM = 0; + + /// < Artist + static const int PLAYER_CONTENT_INFO_ARTIST = 1; + + /// < Author + static const int PLAYER_CONTENT_INFO_AUTHOR = 2; + + /// < Genre + static const int PLAYER_CONTENT_INFO_GENRE = 3; + + /// < Title + static const int PLAYER_CONTENT_INFO_TITLE = 4; + + /// < Year + static const int PLAYER_CONTENT_INFO_YEAR = 5; +} + +class radio_s extends ffi.Opaque {} + +/// @brief Enumeration of radio state. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class radio_state_e { + /// < Ready to play or scan + static const int RADIO_STATE_READY = 0; + + /// < Playing the audio from the tuner + static const int RADIO_STATE_PLAYING = 1; + + /// < Scanning/Searching for the next station signal that starts from a given starting frequency + static const int RADIO_STATE_SCANNING = 2; +} + +/// @brief Enumeration of error codes for the radio. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class radio_error_e { + /// < Successful + static const int RADIO_ERROR_NONE = 0; + + /// < Out of memory + static const int RADIO_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid parameter + static const int RADIO_ERROR_INVALID_PARAMETER = -22; + + /// < Invalid operation + static const int RADIO_ERROR_INVALID_OPERATION = -38; + + /// < Invalid state + static const int RADIO_ERROR_INVALID_STATE = -26869759; + + /// < Sound policy error + static const int RADIO_ERROR_SOUND_POLICY = -26869758; + + /// < No Antenna error (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int RADIO_ERROR_NO_ANTENNA = -26869757; + + /// < Permission denied + static const int RADIO_ERROR_PERMISSION_DENIED = -13; + + /// < Not supported + static const int RADIO_ERROR_NOT_SUPPORTED = -1073741822; +} + +/// @brief Enumeration of radio interrupted type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class radio_interrupted_code_e { + /// < Interrupt completed (Deprecated since 3.0) + static const int RADIO_INTERRUPTED_COMPLETED = 0; + + /// < Interrupted by a non-resumable media application (Deprecated since 3.0) + static const int RADIO_INTERRUPTED_BY_MEDIA = 1; + + /// < Interrupted by an incoming call (Deprecated since 3.0) + static const int RADIO_INTERRUPTED_BY_CALL = 2; + + /// < Interrupted by unplugging headphones (Deprecated since 3.0) + static const int RADIO_INTERRUPTED_BY_EARJACK_UNPLUG = 3; + + /// < Interrupted by a resource conflict + static const int RADIO_INTERRUPTED_BY_RESOURCE_CONFLICT = 4; + + /// < Interrupted by an alarm (Deprecated since 3.0) + static const int RADIO_INTERRUPTED_BY_ALARM = 5; + + /// < Interrupted by an emergency (Deprecated since 3.0) + static const int RADIO_INTERRUPTED_BY_EMERGENCY = 6; + + /// < Interrupted by a resumable media application (Deprecated since 3.0) + static const int RADIO_INTERRUPTED_BY_RESUMABLE_MEDIA = 7; + + /// < Interrupted by a notification (Deprecated since 3.0) + static const int RADIO_INTERRUPTED_BY_NOTIFICATION = 8; +} + +class recorder_s extends ffi.Opaque {} + +/// @brief Enumeration for error code of the media recorder. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class recorder_error_e { + /// < Successful + static const int RECORDER_ERROR_NONE = 0; + + /// < Invalid parameter + static const int RECORDER_ERROR_INVALID_PARAMETER = -22; + + /// < Invalid state + static const int RECORDER_ERROR_INVALID_STATE = -26542062; + + /// < Out of memory + static const int RECORDER_ERROR_OUT_OF_MEMORY = -12; + + /// < Device error + static const int RECORDER_ERROR_DEVICE = -26542060; + + /// < Internal error + static const int RECORDER_ERROR_INVALID_OPERATION = -38; + + /// < Blocked by Audio Session Manager (Deprecated since 3.0) + static const int RECORDER_ERROR_SOUND_POLICY = -26542058; + + /// < Restricted by security system policy + static const int RECORDER_ERROR_SECURITY_RESTRICTED = -26542057; + + /// < Blocked by Audio Session Manager - CALL (Deprecated since 3.0) + static const int RECORDER_ERROR_SOUND_POLICY_BY_CALL = -26542056; + + /// < Blocked by Audio Session Manager - ALARM (Deprecated since 3.0) + static const int RECORDER_ERROR_SOUND_POLICY_BY_ALARM = -26542055; + + /// < ESD situation + static const int RECORDER_ERROR_ESD = -26542054; + + /// < Out of storage + static const int RECORDER_ERROR_OUT_OF_STORAGE = -26542053; + + /// < The access to the resources can not be granted + static const int RECORDER_ERROR_PERMISSION_DENIED = -13; + + /// < The feature is not supported + static const int RECORDER_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Blocked by resource conflict (Since 3.0) + static const int RECORDER_ERROR_RESOURCE_CONFLICT = -26542052; + + /// < Socket connection lost (Since 3.0) + static const int RECORDER_ERROR_SERVICE_DISCONNECTED = -26542051; +} + +/// @brief Enumeration for recorder states. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class recorder_state_e { + /// < Recorder is not created + static const int RECORDER_STATE_NONE = 0; + + /// < Recorder is created, but not prepared + static const int RECORDER_STATE_CREATED = 1; + + /// < Recorder is ready to record \n In case of video recorder, preview display will be shown + static const int RECORDER_STATE_READY = 2; + + /// < Recorder is recording media + static const int RECORDER_STATE_RECORDING = 3; + + /// < Recorder is paused while recording media + static const int RECORDER_STATE_PAUSED = 4; +} + +/// @brief Enumeration for the recording limit. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class recorder_recording_limit_type_e { + /// < Time limit (second) of recording file + static const int RECORDER_RECORDING_LIMIT_TIME = 0; + + /// < Size limit (kilo bytes [KB]) of recording file + static const int RECORDER_RECORDING_LIMIT_SIZE = 1; + + /// < No free space in storage + static const int RECORDER_RECORDING_LIMIT_FREE_SPACE = 2; +} + +/// @brief Enumeration for the file container format. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class recorder_file_format_e { + /// < 3GP file format + static const int RECORDER_FILE_FORMAT_3GP = 0; + + /// < MP4 file format + static const int RECORDER_FILE_FORMAT_MP4 = 1; + + /// < AMR file format + static const int RECORDER_FILE_FORMAT_AMR = 2; + + /// < ADTS file format + static const int RECORDER_FILE_FORMAT_ADTS = 3; + + /// < WAV file format + static const int RECORDER_FILE_FORMAT_WAV = 4; + + /// < OGG file format + static const int RECORDER_FILE_FORMAT_OGG = 5; + + /// < MPEG2-TransportStream file format (Since 3.0) + static const int RECORDER_FILE_FORMAT_M2TS = 6; +} + +/// @brief Enumeration for the audio codec. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class recorder_audio_codec_e { + /// < Disable audio track + static const int RECORDER_AUDIO_CODEC_DISABLE = -1; + + /// < AMR codec + static const int RECORDER_AUDIO_CODEC_AMR = 0; + + /// < AAC codec + static const int RECORDER_AUDIO_CODEC_AAC = 1; + + /// < Vorbis codec + static const int RECORDER_AUDIO_CODEC_VORBIS = 2; + + /// < PCM codec + static const int RECORDER_AUDIO_CODEC_PCM = 3; + + /// < MP3 codec (Since 3.0) + static const int RECORDER_AUDIO_CODEC_MP3 = 4; +} + +/// @brief Enumeration for the video codec. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class recorder_video_codec_e { + /// < H263 codec + static const int RECORDER_VIDEO_CODEC_H263 = 0; + + /// < H264 codec + static const int RECORDER_VIDEO_CODEC_H264 = 1; + + /// < MPEG4 codec + static const int RECORDER_VIDEO_CODEC_MPEG4 = 2; + + /// < Theora codec + static const int RECORDER_VIDEO_CODEC_THEORA = 3; +} + +/// @brief Enumeration for audio capture devices. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class recorder_audio_device_e { + /// < Mic device + static const int RECORDER_AUDIO_DEVICE_MIC = 0; + + /// < Modem + static const int RECORDER_AUDIO_DEVICE_MODEM = 1; +} + +/// @brief Enumeration for the recorder rotation type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class recorder_rotation_e { + /// < No rotation + static const int RECORDER_ROTATION_NONE = 0; + + /// < 90 degree rotation + static const int RECORDER_ROTATION_90 = 1; + + /// < 180 degree rotation + static const int RECORDER_ROTATION_180 = 2; + + /// < 270 degree rotation + static const int RECORDER_ROTATION_270 = 3; +} + +/// @brief Enumeration for the recorder policy. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class recorder_policy_e { + /// < None + static const int RECORDER_POLICY_NONE = 0; + + /// < Sound policy (Deprecated since 3.0) + static const int RECORDER_POLICY_SOUND = 1; + + /// < Sound policy by CALL (Deprecated since 3.0) + static const int RECORDER_POLICY_SOUND_BY_CALL = 2; + + /// < Sound policy by ALARM (Deprecated since 3.0) + static const int RECORDER_POLICY_SOUND_BY_ALARM = 3; + + /// < Security policy + static const int RECORDER_POLICY_SECURITY = 4; + + /// < Resource conflict (Since 3.0) + static const int RECORDER_POLICY_RESOURCE_CONFLICT = 5; +} + +/// @brief Enumeration for the recorder type. +/// @since_tizen 3.0 +abstract class recorder_type_e { + /// < Audio only recorder + static const int RECORDER_TYPE_AUDIO = 0; + + /// < Video recorder (audio is optional) + static const int RECORDER_TYPE_VIDEO = 1; +} + +/// @brief Enumeration for the recorder device state. +/// @since_tizen 3.0 +abstract class recorder_device_state_e { + /// < No recording in progress + static const int RECORDER_DEVICE_STATE_IDLE = 0; + + /// < Now recording + static const int RECORDER_DEVICE_STATE_RECORDING = 1; + + /// < All recordings are paused + static const int RECORDER_DEVICE_STATE_PAUSED = 2; +} + +/// @brief Enumeration for Tizen Sound Pool error. +/// +/// @since_tizen 4.0 +abstract class sound_pool_error_e { + static const int SOUND_POOL_ERROR_NONE = 0; + static const int SOUND_POOL_ERROR_KEY_NOT_AVAILABLE = -126; + static const int SOUND_POOL_ERROR_OUT_OF_MEMORY = -12; + static const int SOUND_POOL_ERROR_INVALID_PARAMETER = -22; + static const int SOUND_POOL_ERROR_INVALID_OPERATION = -38; + static const int SOUND_POOL_ERROR_NOT_PERMITTED = -1; + static const int SOUND_POOL_ERROR_NO_SUCH_FILE = -2; +} + +/// @brief Enumeration of sound pool stream state. +/// +/// @since_tizen 4.0 +abstract class sound_pool_stream_state_e { + /// < Stream state isn't determined + static const int SOUND_POOL_STREAM_STATE_NONE = 0; + + /// < Stream state is playing + static const int SOUND_POOL_STREAM_STATE_PLAYING = 1; + + /// < Stream state is paused + static const int SOUND_POOL_STREAM_STATE_PAUSED = 2; + + /// < Stream state is stopped + static const int SOUND_POOL_STREAM_STATE_STOPPED = 3; + + /// < Stream state is finished + static const int SOUND_POOL_STREAM_STATE_FINISHED = 4; + + /// < Stream state is suspended + static const int SOUND_POOL_STREAM_STATE_SUSPENDED = 5; +} + +/// @brief Enumeration of sound pool stream priority policy. +/// +/// @since_tizen 4.0 +abstract class sound_pool_stream_priority_policy_e { + /// < Stream priority policy is mute + static const int SOUND_POOL_STREAM_PRIORITY_POLICY_MUTE = 0; + + /// < Stream priority policy is suspended + static const int SOUND_POOL_STREAM_PRIORITY_POLICY_SUSPENDED = 1; +} + +/// @brief Enumeration of sound pool state. +/// +/// @since_tizen 4.0 +abstract class sound_pool_state_e { + /// < Sound pool active state: streams can be played + static const int SOUND_POOL_STATE_ACTIVE = 0; + + /// < Sound pool inactive state: streams can't be played + static const int SOUND_POOL_STATE_INACTIVE = 1; +} + +class streamrecorder_s extends ffi.Opaque {} + +/// @brief Enumeration for the source type. +/// @since_tizen 3.0 +abstract class streamrecorder_source_e { + /// < Video only + static const int STREAMRECORDER_SOURCE_VIDEO = 0; + + /// < Audio only + static const int STREAMRECORDER_SOURCE_AUDIO = 1; + + /// < Video and Audio + static const int STREAMRECORDER_SOURCE_VIDEO_AUDIO = 2; +} + +/// @brief Enumeration for the pixel format. +/// @since_tizen 3.0 +abstract class streamrecorder_video_source_format_e { + /// < Invalid pixel format + static const int STREAMRECORDER_VIDEO_SOURCE_FORMAT_INVALID = -1; + + /// < NV12 pixel format + static const int STREAMRECORDER_VIDEO_SOURCE_FORMAT_NV12 = 0; + + /// < NV12 pixel format + static const int STREAMRECORDER_VIDEO_SOURCE_FORMAT_NV21 = 1; + + /// < I420 pixel format + static const int STREAMRECORDER_VIDEO_SOURCE_FORMAT_I420 = 2; + + /// < Number of the video source format + static const int STREAMRECORDER_VIDEO_SOURCE_FORMAT_NUM = 3; +} + +/// @brief Enumeration for the file container format. +/// @since_tizen 3.0 +abstract class streamrecorder_file_format_e { + /// < 3GP file format + static const int STREAMRECORDER_FILE_FORMAT_3GP = 0; + + /// < MP4 file format + static const int STREAMRECORDER_FILE_FORMAT_MP4 = 1; + + /// < AMR file format + static const int STREAMRECORDER_FILE_FORMAT_AMR = 2; + + /// < ADTS file format + static const int STREAMRECORDER_FILE_FORMAT_ADTS = 3; + + /// < WAV file format + static const int STREAMRECORDER_FILE_FORMAT_WAV = 4; +} + +/// @brief Enumeration for the audio codec. +/// @since_tizen 3.0 +abstract class streamrecorder_audio_codec_e { + /// < AMR codec + static const int STREAMRECORDER_AUDIO_CODEC_AMR = 0; + + /// < AAC codec + static const int STREAMRECORDER_AUDIO_CODEC_AAC = 1; + + /// < PCM codec + static const int STREAMRECORDER_AUDIO_CODEC_PCM = 2; +} + +/// @brief Enumeration for the video codec. +/// @since_tizen 3.0 +abstract class streamrecorder_video_codec_e { + /// < H263 codec + static const int STREAMRECORDER_VIDEO_CODEC_H263 = 0; + + /// < MPEG4 codec + static const int STREAMRECORDER_VIDEO_CODEC_MPEG4 = 1; +} + +/// @brief Enumeration for the recording limit reached. +/// @since_tizen 3.0 +abstract class streamrecorder_recording_limit_type_e { + /// < Time limit (second) of recording file + static const int STREAMRECORDER_RECORDING_LIMIT_TYPE_TIME = 0; + + /// < Size limit (kilo bytes [KB]) of recording file + static const int STREAMRECORDER_RECORDING_LIMIT_TYPE_SIZE = 1; +} + +/// @brief Enumeration for Streamrecorder error type. +/// @since_tizen 3.0 +abstract class streamrecorder_error_e { + /// < Successful + static const int STREAMRECORDER_ERROR_NONE = 0; + + /// < Invalid parameter + static const int STREAMRECORDER_ERROR_INVALID_PARAMETER = -22; + + /// < Invalid state + static const int STREAMRECORDER_ERROR_INVALID_STATE = -27328511; + + /// < Out of memory + static const int STREAMRECORDER_ERROR_OUT_OF_MEMORY = -12; + + /// < Internal error + static const int STREAMRECORDER_ERROR_INVALID_OPERATION = -38; + + /// < Out of storage + static const int STREAMRECORDER_ERROR_OUT_OF_STORAGE = -27328510; + + /// < The access to the resources can not be granted + static const int STREAMRECORDER_ERROR_PERMISSION_DENIED = -13; + + /// < The feature is not supported + static const int STREAMRECORDER_ERROR_NOT_SUPPORTED = -1073741822; +} + +/// @brief Enumeration for the Streamrecorder notification. +/// @since_tizen 3.0 +abstract class streamrecorder_notify_e { + /// < None + static const int STREAMRECORDER_NOTIFY_NONE = 0; + + /// < The notification of normal state changes + static const int STREAMRECORDER_NOTIFY_STATE_CHANGED = 1; +} + +/// @brief Enumeration for Streamrecorder states. +/// @since_tizen 3.0 +abstract class streamrecorder_state_e { + /// < StreamRecorder is not created + static const int STREAMRECORDER_STATE_NONE = 0; + + /// < StreamRecorder is created, but not prepared + static const int STREAMRECORDER_STATE_CREATED = 1; + + /// < StreamRecorder is prepared to record + static const int STREAMRECORDER_STATE_PREPARED = 2; + + /// < StreamRecorder is recording media + static const int STREAMRECORDER_STATE_RECORDING = 3; + + /// < StreamRecorder is paused while recording media + static const int STREAMRECORDER_STATE_PAUSED = 4; +} + +/// @ingroup CAPI_MEDIA_THUMBNAIL_UTIL_MODULE +/// @brief Enumeration for a thumbnail util error. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class thumbnail_util_error_e { + /// < Successful + static const int THUMBNAIL_UTIL_ERROR_NONE = 0; + + /// < Invalid parameter + static const int THUMBNAIL_UTIL_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int THUMBNAIL_UTIL_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid Operation + static const int THUMBNAIL_UTIL_ERROR_INVALID_OPERATION = -38; + + /// < No space left on device + static const int THUMBNAIL_UTIL_ERROR_FILE_NO_SPACE_ON_DEVICE = -28; + + /// < Permission denied + static const int THUMBNAIL_UTIL_ERROR_PERMISSION_DENIED = -13; + + /// < Unsupported Content (Since 4.0) + static const int THUMBNAIL_UTIL_ERROR_UNSUPPORTED_CONTENT = -49872895; +} + +class thumbnail_s extends ffi.Opaque {} + +/// @brief Enumeration of error codes for tone player. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class tone_player_error_e { + /// < Successful + static const int TONE_PLAYER_ERROR_NONE = 0; + + /// < Invalid parameter + static const int TONE_PLAYER_ERROR_INVALID_PARAMETER = -22; + + /// < Invalid operation + static const int TONE_PLAYER_ERROR_INVALID_OPERATION = -38; + + /// < Not supported (Since 3.0) + static const int TONE_PLAYER_ERROR_NOT_SUPPORTED_TYPE = -26673151; +} + +/// @brief Enumeration of tone. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class tone_type_e { + /// < The default tone + static const int TONE_TYPE_DEFAULT = 0; + + /// < Predefined DTMF 0 + static const int TONE_TYPE_DTMF_0 = 0; + + /// < Predefined DTMF 1 + static const int TONE_TYPE_DTMF_1 = 1; + + /// < Predefined DTMF 2 + static const int TONE_TYPE_DTMF_2 = 2; + + /// < Predefined DTMF 3 + static const int TONE_TYPE_DTMF_3 = 3; + + /// < Predefined DTMF 4 + static const int TONE_TYPE_DTMF_4 = 4; + + /// < Predefined DTMF 5 + static const int TONE_TYPE_DTMF_5 = 5; + + /// < Predefined DTMF 6 + static const int TONE_TYPE_DTMF_6 = 6; + + /// < Predefined DTMF 7 + static const int TONE_TYPE_DTMF_7 = 7; + + /// < Predefined DTMF 8 + static const int TONE_TYPE_DTMF_8 = 8; + + /// < Predefined DTMF 9 + static const int TONE_TYPE_DTMF_9 = 9; + + /// < Predefined DTMF Star - Asterisk (*) + static const int TONE_TYPE_DTMF_S = 10; + + /// < Predefined DTMF sharP (#) + static const int TONE_TYPE_DTMF_P = 11; + + /// < Predefined DTMF A (A) + static const int TONE_TYPE_DTMF_A = 12; + + /// < Predefined DTMF B (B) + static const int TONE_TYPE_DTMF_B = 13; + + /// < Predefined DTMF C (C) + static const int TONE_TYPE_DTMF_C = 14; + + /// < Predefined DTMF D (D) + static const int TONE_TYPE_DTMF_D = 15; + + /// < Call supervisory tone, Dial tone: CEPT: 425Hz, continuous + static const int TONE_TYPE_SUP_DIAL = 16; + + /// < Call supervisory tone, Dial tone: ANSI (IS-95): 350Hz+440Hz, continuous + static const int TONE_TYPE_ANSI_DIAL = 17; + + /// < Call supervisory tone, Dial tone: JAPAN: 400Hz, continuous + static const int TONE_TYPE_JAPAN_DIAL = 18; + + /// < Call supervisory tone, Busy: CEPT: 425Hz, 500ms ON, 500ms OFF... + static const int TONE_TYPE_SUP_BUSY = 19; + + /// < Call supervisory tone, Busy: ANSI (IS-95): 480Hz+620Hz, 500ms ON, 500ms OFF... + static const int TONE_TYPE_ANSI_BUSY = 20; + + /// < Call supervisory tone, Busy: JAPAN: 400Hz, 500ms ON, 500ms OFF... + static const int TONE_TYPE_JAPAN_BUSY = 21; + + /// < Call supervisory tone, Congestion: CEPT, JAPAN: 425Hz, 200ms ON, 200ms OFF + static const int TONE_TYPE_SUP_CONGESTION = 22; + + /// < Call supervisory tone, Congestion: ANSI (IS-95): 480Hz+620Hz, 250ms ON, 250ms OFF... + static const int TONE_TYPE_ANSI_CONGESTION = 23; + + /// < Call supervisory tone, Radio path acknowledgment : CEPT, ANSI: 425Hz, 200ms ON + static const int TONE_TYPE_SUP_RADIO_ACK = 24; + + /// < Call supervisory tone, Radio path acknowledgment : JAPAN: 400Hz, 1s ON, 2s OFF... + static const int TONE_TYPE_JAPAN_RADIO_ACK = 25; + + /// < Call supervisory tone, Radio path not available: 425Hz, 200ms ON, 200 OFF 3 bursts + static const int TONE_TYPE_SUP_RADIO_NOTAVAIL = 26; + + /// < Call supervisory tone, Error/Special info: 950Hz+1400Hz+1800Hz, 330ms ON, 1s OFF... + static const int TONE_TYPE_SUP_ERROR = 27; + + /// < Call supervisory tone, Call Waiting: CEPT, JAPAN: 425Hz, 200ms ON, 600ms OFF, 200ms ON, 3s OFF... + static const int TONE_TYPE_SUP_CALL_WAITING = 28; + + /// < Call supervisory tone, Call Waiting: ANSI (IS-95): 440 Hz, 300 ms ON, 9.7 s OFF, (100 ms ON, 100 ms OFF, 100 ms ON, 9.7s OFF ...) + static const int TONE_TYPE_ANSI_CALL_WAITING = 29; + + /// < Call supervisory tone, Ring Tone: CEPT, JAPAN: 425Hz, 1s ON, 4s OFF... + static const int TONE_TYPE_SUP_RINGTONE = 30; + + /// < Call supervisory tone, Ring Tone: ANSI (IS-95): 440Hz + 480Hz, 2s ON, 4s OFF... + static const int TONE_TYPE_ANSI_RINGTONE = 31; + + /// < General beep: 400Hz+1200Hz, 35ms ON + static const int TONE_TYPE_PROP_BEEP = 32; + + /// < Proprietary tone, positive acknowledgment: 1200Hz, 100ms ON, 100ms OFF 2 bursts + static const int TONE_TYPE_PROP_ACK = 33; + + /// < Proprietary tone, negative acknowledgment: 300Hz+400Hz+500Hz, 400ms ON + static const int TONE_TYPE_PROP_NACK = 34; + + /// < Proprietary tone, prompt tone: 400Hz+1200Hz, 200ms ON + static const int TONE_TYPE_PROP_PROMPT = 35; + + /// < Proprietary tone, general double beep: twice 400Hz+1200Hz, 35ms ON, 200ms OFF, 35ms ON + static const int TONE_TYPE_PROP_BEEP2 = 36; + + /// < Call supervisory tone (IS-95), intercept tone: alternating 440 Hz and 620 Hz tones, each on for 250 ms + static const int TONE_TYPE_SUP_INTERCEPT = 37; + + /// < Call supervisory tone (IS-95), abbreviated intercept: intercept tone limited to 4 seconds + static const int TONE_TYPE_SUP_INTERCEPT_ABBREV = 38; + + /// < Call supervisory tone (IS-95), abbreviated congestion: congestion tone limited to 4 seconds + static const int TONE_TYPE_SUP_CONGESTION_ABBREV = 39; + + /// < Call supervisory tone (IS-95), confirm tone: a 350 Hz tone added to a 440 Hz tone repeated 3 times in a 100 ms on, 100 ms off cycle + static const int TONE_TYPE_SUP_CONFIRM = 40; + + /// < Call supervisory tone (IS-95), pip tone: four bursts of 480 Hz tone (0.1 s on, 0.1 s off). + static const int TONE_TYPE_SUP_PIP = 41; + + /// < 425Hz continuous + static const int TONE_TYPE_CDMA_DIAL_TONE_LITE = 42; + + /// < CDMA USA Ringback: 440Hz+480Hz 2s ON, 4000 OFF ... + static const int TONE_TYPE_CDMA_NETWORK_USA_RINGBACK = 43; + + /// < CDMA Intercept tone: 440Hz 250ms ON, 620Hz 250ms ON ... + static const int TONE_TYPE_CDMA_INTERCEPT = 44; + + /// < CDMA Abbr Intercept tone: 440Hz 250ms ON, 620Hz 250ms ON + static const int TONE_TYPE_CDMA_ABBR_INTERCEPT = 45; + + /// < CDMA Reorder tone: 480Hz+620Hz 250ms ON, 250ms OFF... + static const int TONE_TYPE_CDMA_REORDER = 46; + + /// < CDMA Abbr Reorder tone: 480Hz+620Hz 250ms ON, 250ms OFF repeated for 8 times + static const int TONE_TYPE_CDMA_ABBR_REORDER = 47; + + /// < CDMA Network Busy tone: 480Hz+620Hz 500ms ON, 500ms OFF continuous + static const int TONE_TYPE_CDMA_NETWORK_BUSY = 48; + + /// < CDMA Confirm tone: 350Hz+440Hz 100ms ON, 100ms OFF repeated for 3 times + static const int TONE_TYPE_CDMA_CONFIRM = 49; + + /// < CDMA answer tone: silent tone - definition Frequency 0, 0ms ON, 0ms OFF + static const int TONE_TYPE_CDMA_ANSWER = 50; + + /// < CDMA Network Callwaiting tone: 440Hz 300ms ON + static const int TONE_TYPE_CDMA_NETWORK_CALLWAITING = 51; + + /// < CDMA PIP tone: 480Hz 100ms ON, 100ms OFF repeated for 4 times + static const int TONE_TYPE_CDMA_PIP = 52; + + /// < ISDN Call Signal Normal tone: {2091Hz 32ms ON, 2556 64ms ON} 20 times, 2091 32ms ON, 2556 48ms ON, 4s OFF + static const int TONE_TYPE_CDMA_CALL_SIGNAL_ISDN_NORMAL = 53; + + /// < ISDN Call Signal Intergroup tone: {2091Hz 32ms ON, 2556 64ms ON} 8 times, 2091Hz 32ms ON, 400ms OFF, {2091Hz 32ms ON, 2556Hz 64ms ON} 8times, 2091Hz 32ms ON, 4s OFF. + static const int TONE_TYPE_CDMA_CALL_SIGNAL_ISDN_INTERGROUP = 54; + + /// < ISDN Call Signal SP PRI tone:{2091Hz 32ms ON, 2556 64ms ON} 4 times 2091Hz 16ms ON, 200ms OFF, {2091Hz 32ms ON, 2556Hz 64ms ON} 4 times, 2091Hz 16ms ON, 200ms OFF + static const int TONE_TYPE_CDMA_CALL_SIGNAL_ISDN_SP_PRI = 55; + + /// < SDN Call sign PAT3 tone: silent tone + static const int TONE_TYPE_CDMA_CALL_SIGNAL_ISDN_PAT3 = 56; + + /// < ISDN Ping Ring tone: {2091Hz 32ms ON, 2556Hz 64ms ON} 5 times 2091Hz 20ms ON + static const int TONE_TYPE_CDMA_CALL_SIGNAL_ISDN_PING_RING = 57; + + /// < ISDN Pat5 tone: silent tone + static const int TONE_TYPE_CDMA_CALL_SIGNAL_ISDN_PAT5 = 58; + + /// < ISDN Pat6 tone: silent tone + static const int TONE_TYPE_CDMA_CALL_SIGNAL_ISDN_PAT6 = 59; + + /// < ISDN Pat7 tone: silent tone + static const int TONE_TYPE_CDMA_CALL_SIGNAL_ISDN_PAT7 = 60; + + /// < TONE_CDMA_HIGH_L tone: {3700Hz 25ms, 4000Hz 25ms} 40 times 4000ms OFF, Repeat .... + static const int TONE_TYPE_CDMA_HIGH_L = 61; + + /// < TONE_CDMA_MED_L tone: {2600Hz 25ms, 2900Hz 25ms} 40 times 4000ms OFF, Repeat .... + static const int TONE_TYPE_CDMA_MED_L = 62; + + /// < TONE_CDMA_LOW_L tone: {1300Hz 25ms, 1450Hz 25ms} 40 times, 4000ms OFF, Repeat .... + static const int TONE_TYPE_CDMA_LOW_L = 63; + + /// < CDMA HIGH SS tone: {3700Hz 25ms, 4000Hz 25ms} repeat 16 times, 400ms OFF, repeat .... + static const int TONE_TYPE_CDMA_HIGH_SS = 64; + + /// < CDMA MED SS tone: {2600Hz 25ms, 2900Hz 25ms} repeat 16 times, 400ms OFF, repeat .... + static const int TONE_TYPE_CDMA_MED_SS = 65; + + /// < CDMA LOW SS tone: {1300z 25ms, 1450Hz 25ms} repeat 16 times, 400ms OFF, repeat .... + static const int TONE_TYPE_CDMA_LOW_SS = 66; + + /// < CDMA HIGH SSL tone: {3700Hz 25ms, 4000Hz 25ms} 8 times, 200ms OFF, {3700Hz 25ms, 4000Hz 25ms} repeat 8 times, 200ms OFF, {3700Hz 25ms, 4000Hz 25ms} repeat 16 times, 4000ms OFF, repeat ... + static const int TONE_TYPE_CDMA_HIGH_SSL = 67; + + /// < CDMA MED SSL tone: {2600Hz 25ms, 2900Hz 25ms} 8 times, 200ms OFF, {2600Hz 25ms, 2900Hz 25ms} repeat 8 times, 200ms OFF, {2600Hz 25ms, 2900Hz 25ms} repeat 16 times, 4000ms OFF, repeat ... + static const int TONE_TYPE_CDMA_MED_SSL = 68; + + /// < CDMA LOW SSL tone: {1300Hz 25ms, 1450Hz 25ms} 8 times, 200ms OFF, {1300Hz 25ms, 1450Hz 25ms} repeat 8 times, 200ms OFF, {1300Hz 25ms, 1450Hz 25ms} repeat 16 times, 4000ms OFF, repeat ... + static const int TONE_TYPE_CDMA_LOW_SSL = 69; + + /// < CDMA HIGH SS2 tone: {3700Hz 25ms, 4000Hz 25ms} 20 times, 1000ms OFF, {3700Hz 25ms, 4000Hz 25ms} 20 times, 3000ms OFF, repeat .... + static const int TONE_TYPE_CDMA_HIGH_SS_2 = 70; + + /// < CDMA MED SS2 tone: {2600Hz 25ms, 2900Hz 25ms} 20 times, 1000ms OFF, {2600Hz 25ms, 2900Hz 25ms} 20 times, 3000ms OFF, repeat .... + static const int TONE_TYPE_CDMA_MED_SS_2 = 71; + + /// < CDMA LOW SS2 tone: {1300Hz 25ms, 1450Hz 25ms} 20 times, 1000ms OFF, {1300Hz 25ms, 1450Hz 25ms} 20 times, 3000ms OFF, repeat .... + static const int TONE_TYPE_CDMA_LOW_SS_2 = 72; + + /// < CDMA HIGH SLS tone: {3700Hz 25ms, 4000Hz 25ms} 10 times, 500ms OFF, {3700Hz 25ms, 4000Hz 25ms} 20 times, 500ms OFF, {3700Hz 25ms, 4000Hz 25ms} 10 times, 3000ms OFF, REPEAT + static const int TONE_TYPE_CDMA_HIGH_SLS = 73; + + /// < CDMA MED SLS tone: {2600Hz 25ms, 2900Hz 25ms} 10 times, 500ms OFF, {2600Hz 25ms, 2900Hz 25ms} 20 times, 500ms OFF, {2600Hz 25ms, 2900Hz 25ms} 10 times, 3000ms OFF, REPEAT + static const int TONE_TYPE_CDMA_MED_SLS = 74; + + /// < CDMA LOW SLS tone: {1300Hz 25ms, 1450Hz 25ms} 10 times, 500ms OFF, {1300Hz 25ms, 1450Hz 25ms} 20 times, 500ms OFF, {1300Hz 25ms, 1450Hz 25ms} 10 times, 3000ms OFF, REPEAT + static const int TONE_TYPE_CDMA_LOW_SLS = 75; + + /// < CDMA HIGH S X4 tone: {3700Hz 25ms, 4000Hz 25ms} 10 times, 500ms OFF, {3700Hz 25ms, 4000Hz 25ms} 10 times, 500ms OFF, {3700Hz 25ms, 4000Hz 25ms} 10 times, 500ms OFF, {3700Hz 25ms, 4000Hz 25ms} 10 times, 2500ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_HIGH_S_X4 = 76; + + /// < CDMA MED S X4 tone: {2600Hz 25ms, 2900Hz 25ms} 10 times, 500ms OFF, {2600Hz 25ms, 2900Hz 25ms} 10 times, 500ms OFF, {2600Hz 25ms, 2900Hz 25ms} 10 times, 500ms OFF, {2600Hz 25ms, 2900Hz 25ms} 10 times, 2500ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_MED_S_X4 = 77; + + /// < CDMA LOW S X4 tone: {2600Hz 25ms, 2900Hz 25ms} 10 times, 500ms OFF, {2600Hz 25ms, 2900Hz 25ms} 10 times, 500ms OFF, {2600Hz 25ms, 2900Hz 25ms} 10 times, 500ms OFF, {2600Hz 25ms, 2900Hz 25ms} 10 times, 2500ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_LOW_S_X4 = 78; + + /// < CDMA HIGH PBX L: {3700Hz 25ms, 4000Hz 25ms}20 times, 2000ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_HIGH_PBX_L = 79; + + /// < CDMA MED PBX L: {2600Hz 25ms, 2900Hz 25ms}20 times, 2000ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_MED_PBX_L = 80; + + /// < CDMA LOW PBX L: {1300Hz 25ms,1450Hz 25ms}20 times, 2000ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_LOW_PBX_L = 81; + + /// < CDMA HIGH PBX SS tone: {3700Hz 25ms, 4000Hz 25ms} 8 times 200 ms OFF, {3700Hz 25ms 4000Hz 25ms}8 times, 2000ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_HIGH_PBX_SS = 82; + + /// < CDMA MED PBX SS tone: {2600Hz 25ms, 2900Hz 25ms} 8 times 200 ms OFF, {2600Hz 25ms 2900Hz 25ms}8 times, 2000ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_MED_PBX_SS = 83; + + /// < CDMA LOW PBX SS tone: {1300Hz 25ms, 1450Hz 25ms} 8 times 200 ms OFF, {1300Hz 25ms 1450Hz 25ms}8 times, 2000ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_LOW_PBX_SS = 84; + + /// < CDMA HIGH PBX SSL tone:{3700Hz 25ms, 4000Hz 25ms} 8 times 200ms OFF, {3700Hz 25ms, 4000Hz 25ms} 8 times, 200ms OFF, {3700Hz 25ms, 4000Hz 25ms} 16 times, 1000ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_HIGH_PBX_SSL = 85; + + /// < CDMA MED PBX SSL tone:{2600Hz 25ms, 2900Hz 25ms} 8 times 200ms OFF, {2600Hz 25ms, 2900Hz 25ms} 8 times, 200ms OFF, {2600Hz 25ms, 2900Hz 25ms} 16 times, 1000ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_MED_PBX_SSL = 86; + + /// < CDMA LOW PBX SSL tone:{1300Hz 25ms, 1450Hz 25ms} 8 times 200ms OFF, {1300Hz 25ms, 1450Hz 25ms} 8 times, 200ms OFF, {1300Hz 25ms, 1450Hz 25ms} 16 times, 1000ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_LOW_PBX_SSL = 87; + + /// < CDMA HIGH PBX SLS tone:{3700Hz 25ms, 4000Hz 25ms} 8 times 200ms OFF, {3700Hz 25ms, 4000Hz 25ms} 16 times, 200ms OFF, {3700Hz 25ms, 4000Hz 25ms} 8 times, 1000ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_HIGH_PBX_SLS = 88; + + /// < CDMA MED PBX SLS tone:{2600Hz 25ms, 2900Hz 25ms} 8 times 200ms OFF, {2600Hz 25ms, 2900Hz 25ms} 16 times, 200ms OFF, {2600Hz 25ms, 2900Hz 25ms} 8 times, 1000ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_MED_PBX_SLS = 89; + + /// < CDMA LOW PBX SLS tone:{1300Hz 25ms, 1450Hz 25ms} 8 times 200ms OFF, {1300Hz 25ms, 1450Hz 25ms} 16 times, 200ms OFF, {1300Hz 25ms, 1450Hz 25ms} 8 times, 1000ms OFF, REPEAT.... + static const int TONE_TYPE_CDMA_LOW_PBX_SLS = 90; + + /// < CDMA HIGH PBX X S4 tone: {3700Hz 25ms 4000Hz 25ms} 8 times, 200ms OFF, {3700Hz 25ms 4000Hz 25ms} 8 times, 200ms OFF, {3700Hz 25ms 4000Hz 25ms} 8 times, 200ms OFF, {3700Hz 25ms 4000Hz 25ms} 8 times, 800ms OFF, REPEAT... + static const int TONE_TYPE_CDMA_HIGH_PBX_S_X4 = 91; + + /// < CDMA MED PBX X S4 tone: {2600Hz 25ms 2900Hz 25ms} 8 times, 200ms OFF, {2600Hz 25ms 2900Hz 25ms} 8 times, 200ms OFF, {2600Hz 25ms 2900Hz 25ms} 8 times, 200ms OFF, {2600Hz 25ms 2900Hz 25ms} 8 times, 800ms OFF, REPEAT... + static const int TONE_TYPE_CDMA_MED_PBX_S_X4 = 92; + + /// < CDMA LOW PBX X S4 tone: {1300Hz 25ms 1450Hz 25ms} 8 times, 200ms OFF, {1300Hz 25ms 1450Hz 25ms} 8 times, 200ms OFF, {1300Hz 25ms 1450Hz 25ms} 8 times, 200ms OFF, {1300Hz 25ms 1450Hz 25ms} 8 times, 800ms OFF, REPEAT... + static const int TONE_TYPE_CDMA_LOW_PBX_S_X4 = 93; + + /// < CDMA Alert Network Lite tone: 1109Hz 62ms ON, 784Hz 62ms ON, 740Hz 62ms ON 622Hz 62ms ON, 1109Hz 62ms ON + static const int TONE_TYPE_CDMA_ALERT_NETWORK_LITE = 94; + + /// < CDMA Alert Auto Redial tone: {1245Hz 62ms ON, 659Hz 62ms ON} 3 times, 1245 62ms ON + static const int TONE_TYPE_CDMA_ALERT_AUTOREDIAL_LITE = 95; + + /// < CDMA One Min Beep tone: 1150Hz+770Hz 400ms ON + static const int TONE_TYPE_CDMA_ONE_MIN_BEEP = 96; + + /// < CDMA KEYPAD Volume key lite tone: 941Hz+1477Hz 120ms ON + static const int TONE_TYPE_CDMA_KEYPAD_VOLUME_KEY_LITE = 97; + + /// < CDMA PRESSHOLDKEY LITE tone: 587Hz 375ms ON, 1175Hz 125ms ON + static const int TONE_TYPE_CDMA_PRESSHOLDKEY_LITE = 98; + + /// < CDMA ALERT INCALL LITE tone: 587Hz 62ms, 784 62ms, 831Hz 62ms, 784Hz 62ms, 1109 62ms, 784Hz 62ms, 831Hz 62ms, 784Hz 62ms + static const int TONE_TYPE_CDMA_ALERT_INCALL_LITE = 99; + + /// < CDMA EMERGENCY RINGBACK tone: {941Hz 125ms ON, 10ms OFF} 3times 4990ms OFF, REPEAT... + static const int TONE_TYPE_CDMA_EMERGENCY_RINGBACK = 100; + + /// < CDMA ALERT CALL GUARD tone: {1319Hz 125ms ON, 125ms OFF} 3 times + static const int TONE_TYPE_CDMA_ALERT_CALL_GUARD = 101; + + /// < CDMA SOFT ERROR LITE tone: 1047Hz 125ms ON, 370Hz 125ms + static const int TONE_TYPE_CDMA_SOFT_ERROR_LITE = 102; + + /// < CDMA CALLDROP LITE tone: 1480Hz 125ms, 1397Hz 125ms, 784Hz 125ms + static const int TONE_TYPE_CDMA_CALLDROP_LITE = 103; + + /// < CDMA_NETWORK_BUSY_ONE_SHOT tone: 425Hz 500ms ON, 500ms OFF. + static const int TONE_TYPE_CDMA_NETWORK_BUSY_ONE_SHOT = 104; + + /// < CDMA_ABBR_ALERT tone: 1150Hz+770Hz 400ms ON + static const int TONE_TYPE_CDMA_ABBR_ALERT = 105; + + /// < CDMA_SIGNAL_OFF - silent tone + static const int TONE_TYPE_CDMA_SIGNAL_OFF = 106; + + /// < User Defined Tone: 100Hz continuous + static const int TONE_TYPE_USER_DEFINED_LOW_FRE = 107; + + /// < User Defined Tone: 200Hz continuous + static const int TONE_TYPE_USER_DEFINED_MED_FRE = 108; + + /// < User Defined Tone: 300Hz continuous + static const int TONE_TYPE_USER_DEFINED_HIGH_FRE = 109; +} + +/// @brief Enumeration of error codes for WAV player. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class wav_player_error_e { + /// < Successful + static const int WAV_PLAYER_ERROR_NONE = 0; + + /// < Invalid parameter + static const int WAV_PLAYER_ERROR_INVALID_PARAMETER = -22; + + /// < Invalid operation + static const int WAV_PLAYER_ERROR_INVALID_OPERATION = -38; + + /// < Format not supported + static const int WAV_PLAYER_ERROR_FORMAT_NOT_SUPPORTED = -26804223; + + /// < Not supported (Since 3.0) + static const int WAV_PLAYER_ERROR_NOT_SUPPORTED_TYPE = -26804222; +} + +/// @brief Enumeration for Application Service Platform (ASP) error code. +/// @since_tizen 4.0 +abstract class asp_error_e { + /// < Successful + static const int ASP_ERROR_NONE = 0; + + /// < Operation not permitted(1) + static const int ASP_ERROR_NOT_PERMITTED = -1; + + /// < Out of memory(12) + static const int ASP_ERROR_OUT_OF_MEMORY = -12; + + /// < Permission denied(13) + static const int ASP_ERROR_PERMISSION_DENIED = -13; + + /// < Device or resource busy(16) + static const int ASP_ERROR_RESOURCE_BUSY = -16; + + /// < Invalid function parameter(22) + static const int ASP_ERROR_INVALID_PARAMETER = -22; + + /// < Connection timed out(110) + static const int ASP_ERROR_CONNECTION_TIME_OUT = -110; + + /// < Not supported + static const int ASP_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Not initialized + static const int ASP_ERROR_NOT_INITIALIZED = -49676287; + + /// < Already initialized + static const int ASP_ERROR_ALREADY_INITIALIZED = -49676286; + + /// < I/O error + static const int ASP_ERROR_COMMUNICATION_FAILED = -49676285; + + /// < Operation failed + static const int ASP_ERROR_OPERATION_FAILED = -49676284; + + /// < In progress + static const int ASP_ERROR_IN_PROGRESS = -49676283; + + /// < Service not found + static const int ASP_ERROR_SERVICE_NOT_FOUND = -49676282; + + /// < Session not found + static const int ASP_ERROR_SESSION_NOT_FOUND = -49676281; + + /// < Requested network role rejected + static const int ASP_ERROR_NETWORK_ROLE_REJECTED = -49676280; +} + +/// @brief Enumeration for Advertise Status event reason. +/// @since_tizen 4.0 +abstract class asp_advert_status_reason_e { + /// < Status reason: Success + static const int ASP_ADVERT_STATUS_REASON_SUCCESS = 0; + + /// < Status reason: Service duplicated + static const int ASP_ADVERT_STATUS_REASON_SERVICE_DUPLICATED = 1; + + /// < Status reason: Other failure + static const int ASP_ADVERT_STATUS_REASON_OTHER_FAILURE = 2; +} + +/// @brief Enumeration for the Wi-Fi P2P role assignment scheme. +/// @since_tizen 4.0 +/// @see asp_advert_set_p2p_role_scheme() +/// @see asp_advert_get_p2p_role_scheme() +/// @see asp_session_set_p2p_role() +/// @see asp_session_get_p2p_role() +abstract class asp_advert_p2p_role_scheme_e { + /// < All roles are acceptable + static const int ASP_ADVERT_P2P_ROLE_SCHEME_ANY = 0; + + /// < The interface should assume the GO role + static const int ASP_ADVERT_P2P_ROLE_SCHEME_GO = 1; + + /// < The interface should assume the GC role + static const int ASP_ADVERT_P2P_ROLE_SCHEME_GC = 2; +} + +/// @brief Enumeration for service discovery mechanism. +/// @since_tizen 4.0 +/// @see asp_advert_set_discovery_tech() +/// @see asp_seek_set_discovery_tech() +abstract class asp_discovery_tech_e { + /// < Use Wi-Fi P2P for discovery mechanism + static const int ASP_DISCOVERY_TECH_P2P = 1; + + /// < Use BLE for discovery mechanism + static const int ASP_DISCOVERY_TECH_BLE = 2; + + /// < Use NFC for discovery mechanism + static const int ASP_DISCOVERY_TECH_NFC = 4; + + /// < Use Wi-Fi Infrastructured for discovery mechanism + static const int ASP_DISCOVERY_TECH_INFRA = 8; + + /// < Use Wi-Fi NAN for discovery mechanism + static const int ASP_DISCOVERY_TECH_NAN = 16; +} + +/// @brief Enumeration for Wi-Fi WPS type. +/// @see asp_advert_set_p2p_config_method() +/// @see asp_advert_get_p2p_config_method() +/// @see asp_session_set_p2p_config_method() +/// @see asp_session_get_p2p_config_method() +/// @since_tizen 4.0 +abstract class asp_wps_type_e { + /// < No WPS type + static const int ASP_WPS_TYPE_NONE = 0; + + /// < Default WPS type both P2PS and PIN + static const int ASP_WPS_TYPE_DEFAULT = 1; + + /// < WPS type PIN code both display and keypad + static const int ASP_WPS_TYPE_PIN_BOTH = 2; + + /// < WPS type display PIN code only + static const int ASP_WPS_TYPE_PIN_DISPLAY = 3; + + /// < WPS type keypad to input the PIN only + static const int ASP_WPS_TYPE_PIN_KEYPAD = 4; +} + +/// @brief Enumeration for Application Service Platform (ASP) Session connect status. +/// @since_tizen 4.0 +abstract class asp_connect_status_e { + /// < Network role rejected + static const int ASP_CONNECT_STATUS_NETWORK_ROLE_REJECTED = 0; + + /// < The device's connection limit has been reached + static const int ASP_CONNECT_STATUS_CONNECTION_LIMIT_REACHED = 1; + + /// < Session request sent + static const int ASP_CONNECT_STATUS_REQUEST_SENT = 2; + + /// < Session request received + static const int ASP_CONNECT_STATUS_REQUEST_RECEIVED = 3; + + /// < Session request deferred + static const int ASP_CONNECT_STATUS_REQUEST_DEFERRED = 4; + + /// < Session request accepted + static const int ASP_CONNECT_STATUS_REQUEST_ACCEPTED = 5; + + /// < Session request failed + static const int ASP_CONNECT_STATUS_REQUEST_FAILED = 6; + + /// < Group formation started + static const int ASP_CONNECT_STATUS_GROUP_FORMATION_STARTED = 7; + + /// < Group formation completed + static const int ASP_CONNECT_STATUS_GROUP_FORMATION_COMPLETED = 8; + + /// < Group formation failed + static const int ASP_CONNECT_STATUS_GROUP_FORMATION_FAILED = 9; +} + +/// @brief Enumeration for Application Service Platform (ASP) general session state. +/// @since_tizen 4.0 +abstract class asp_session_state_e { + /// < Session state error + static const int ASP_SESSION_STATE_ERROR = 0; + + /// < Session state closed + static const int ASP_SESSION_STATE_CLOSED = 1; + + /// < Session state initiated + static const int ASP_SESSION_STATE_INITIATED = 2; + + /// < Session state requested + static const int ASP_SESSION_STATE_REQUESTED = 3; + + /// < Session state open + static const int ASP_SESSION_STATE_OPEN = 4; +} + +/// @brief Enumeration for Application Service Platform (ASP) session close status. +/// @since_tizen 4.0 +abstract class asp_session_close_status_e { + /// < Session closed without error + static const int ASP_SESSION_CLOSE_OK = 0; + + /// < Session closed by disassociation (Wi-Fi Direct connection was broken) + static const int ASP_SESSION_CLOSE_DISASSOCIATED = 1; + + /// < Session closed with local close + static const int ASP_SESSION_CLOSE_LOCAL_CLOSE = 2; + + /// < Session closed with remote close + static const int ASP_SESSION_CLOSE_REMOTE_CLOSE = 3; + + /// < Session closed with system failure + static const int ASP_SESSION_CLOSE_SYSTEM_FAILURE = 4; + + /// < Session closed with no response from remote + static const int ASP_SESSION_CLOSE_NO_RESPONSE = 5; +} + +/// @brief Enumeration for Application Service Platform (ASP) port status. +/// @since_tizen 4.0 +abstract class asp_port_status_e { + /// < Incoming connections are allowed on this local port for this ASP session + static const int ASP_PORT_STATUS_LOCAL_PORT_ALLOWED = 0; + + /// < Incoming connections are no longer allowed in the ASP session for this local port + static const int ASP_PORT_STATUS_LOCAL_PORT_BLOCKED = 1; + + /// < The ASP was unable to set up this local port + static const int ASP_PORT_STATUS_FAILURE = 2; + + /// < The remote service has allowed access to the given remote port for the given protocol + static const int ASP_PORT_STATUS_REMOTE_PORT_ALLOWED = 3; +} + +/// @brief Enumeration for service status. +/// @since_tizen 4.0 +abstract class asp_service_status_e { + /// < Service status not advertised + static const int ASP_SERVICE_STATUS_NOT_ADVERTISED = 0; + + /// < Service status advertised + static const int ASP_SERVICE_STATUS_ADVERTISED = 1; +} + +/// @WEARABLE_ONLY +/// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE +/// @brief Enumeration of PBAP fields. +/// @since_tizen 3.0 +abstract class bt_pbap_field_e { + /// < All field + static const int BT_PBAP_FIELD_ALL = -1; + + /// < vCard Version + static const int BT_PBAP_FIELD_VERSION = 1; + + /// < Formatted Name + static const int BT_PBAP_FIELD_FN = 2; + + /// < Structured Presentation of Name + static const int BT_PBAP_FIELD_N = 4; + + /// < Associated Image or Photo + static const int BT_PBAP_FIELD_PHOTO = 8; + + /// < Birthday + static const int BT_PBAP_FIELD_BDAY = 16; + + /// < Delivery Address + static const int BT_PBAP_FIELD_ADR = 32; + + /// < Delivery + static const int BT_PBAP_FIELD_LABEL = 64; + + /// < Telephone Number + static const int BT_PBAP_FIELD_TEL = 128; + + /// < Electronic Mail Address + static const int BT_PBAP_FIELD_EMAIL = 256; + + /// < Electronic Mail + static const int BT_PBAP_FIELD_MAILER = 512; + + /// < Time Zone + static const int BT_PBAP_FIELD_TZ = 1024; + + /// < Geographic Position + static const int BT_PBAP_FIELD_GEO = 2048; + + /// < Job + static const int BT_PBAP_FIELD_TITLE = 4096; + + /// < Role within the Organization + static const int BT_PBAP_FIELD_ROLE = 8192; + + /// < Organization Logo + static const int BT_PBAP_FIELD_LOGO = 16384; + + /// < vCard of Person Representing + static const int BT_PBAP_FIELD_AGENT = 32768; + + /// < Name of Organization + static const int BT_PBAP_FIELD_ORG = 65536; + + /// < Comments + static const int BT_PBAP_FIELD_NOTE = 131072; + + /// < Revision + static const int BT_PBAP_FIELD_REV = 262144; + + /// < Pronunciation of Name + static const int BT_PBAP_FIELD_SOUND = 524288; + + /// < Uniform Resource Locator + static const int BT_PBAP_FIELD_URL = 1048576; + + /// < Unique ID + static const int BT_PBAP_FIELD_UID = 2097152; + + /// < Public Encryption Key + static const int BT_PBAP_FIELD_KEY = 4194304; + + /// < Nickname + static const int BT_PBAP_FIELD_NICKNAME = 8388608; + + /// < Categories + static const int BT_PBAP_FIELD_CATEGORIES = 16777216; + + /// < Product ID + static const int BT_PBAP_FIELD_PROID = 33554432; + + /// < Class information + static const int BT_PBAP_FIELD_CLASS = 67108864; + + /// < String used for sorting operations + static const int BT_PBAP_FIELD_SORT_STRING = 134217728; + + /// < Time stamp + static const int BT_PBAP_FIELD_X_IRMC_CALL_DATETIME = 268435456; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_MODULE +/// @brief Enumerations of Bluetooth error codes. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class bt_error_e { + /// < Successful + static const int BT_ERROR_NONE = 0; + + /// < Operation cancelled + static const int BT_ERROR_CANCELLED = -125; + + /// < Invalid parameter + static const int BT_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int BT_ERROR_OUT_OF_MEMORY = -12; + + /// < Device or resource busy + static const int BT_ERROR_RESOURCE_BUSY = -16; + + /// < Timeout error + static const int BT_ERROR_TIMED_OUT = -1073741823; + + /// < Operation now in progress + static const int BT_ERROR_NOW_IN_PROGRESS = -115; + + /// < BT is Not Supported + static const int BT_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Permission denied + static const int BT_ERROR_PERMISSION_DENIED = -13; + + /// < Quota exceeded + static const int BT_ERROR_QUOTA_EXCEEDED = -122; + + /// < No data available + static const int BT_ERROR_NO_DATA = -61; + + /// < Device policy restriction (Since 3.0) + static const int BT_ERROR_DEVICE_POLICY_RESTRICTION = -1073741820; + + /// < Local adapter not initialized + static const int BT_ERROR_NOT_INITIALIZED = -29359871; + + /// < Local adapter not enabled + static const int BT_ERROR_NOT_ENABLED = -29359870; + + /// < Operation already done + static const int BT_ERROR_ALREADY_DONE = -29359869; + + /// < Operation failed + static const int BT_ERROR_OPERATION_FAILED = -29359868; + + /// < Operation not in progress + static const int BT_ERROR_NOT_IN_PROGRESS = -29359867; + + /// < Remote device not bonded + static const int BT_ERROR_REMOTE_DEVICE_NOT_BONDED = -29359866; + + /// < Authentication rejected + static const int BT_ERROR_AUTH_REJECTED = -29359865; + + /// < Authentication failed + static const int BT_ERROR_AUTH_FAILED = -29359864; + + /// < Remote device not found + static const int BT_ERROR_REMOTE_DEVICE_NOT_FOUND = -29359863; + + /// < Service search failed + static const int BT_ERROR_SERVICE_SEARCH_FAILED = -29359862; + + /// < Remote device is not connected + static const int BT_ERROR_REMOTE_DEVICE_NOT_CONNECTED = -29359861; + + /// < Resource temporarily unavailable + static const int BT_ERROR_AGAIN = -29359860; + + /// < Service Not Found + static const int BT_ERROR_SERVICE_NOT_FOUND = -29359859; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE +/// @brief Enumerations of the Bluetooth adapter state. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class bt_adapter_state_e { + /// < Bluetooth adapter is disabled + static const int BT_ADAPTER_DISABLED = 0; + + /// < Bluetooth adapter is enabled + static const int BT_ADAPTER_ENABLED = 1; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE +/// @brief Enumerations of the Bluetooth visibility mode. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class bt_adapter_visibility_mode_e { + /// < Other devices cannot find your device via discovery + static const int BT_ADAPTER_VISIBILITY_MODE_NON_DISCOVERABLE = 0; + + /// < Discoverable mode + static const int BT_ADAPTER_VISIBILITY_MODE_GENERAL_DISCOVERABLE = 1; + + /// < Discoverable mode with time limit. After specific period, + /// it is changed to #BT_ADAPTER_VISIBILITY_MODE_NON_DISCOVERABLE. + static const int BT_ADAPTER_VISIBILITY_MODE_LIMITED_DISCOVERABLE = 2; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE +/// @brief Enumerations of the discovery state of Bluetooth device. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class bt_adapter_device_discovery_state_e { + /// < Device discovery is started + static const int BT_ADAPTER_DEVICE_DISCOVERY_STARTED = 0; + + /// < Device discovery is finished + static const int BT_ADAPTER_DEVICE_DISCOVERY_FINISHED = 1; + + /// < The remote Bluetooth device is found + static const int BT_ADAPTER_DEVICE_DISCOVERY_FOUND = 2; +} + +/// @MOBILE_ONLY +/// @deprecated Deprecated since 2.3.1 +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE +/// @brief Enumerations of the discovery state of Bluetooth LE device. +/// @since_tizen 2.3 +abstract class bt_adapter_le_device_discovery_state_e { + /// < LE device discovery is started + static const int BT_ADAPTER_LE_DEVICE_DISCOVERY_STARTED = 0; + + /// < LE device discovery is finished + static const int BT_ADAPTER_LE_DEVICE_DISCOVERY_FINISHED = 1; + + /// < The remote Bluetooth LE device is found + static const int BT_ADAPTER_LE_DEVICE_DISCOVERY_FOUND = 2; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE +/// @brief Enumerations of the Bluetooth advertising state. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class bt_adapter_le_advertising_state_e { + /// < Bluetooth advertising is stopped + static const int BT_ADAPTER_LE_ADVERTISING_STOPPED = 0; + + /// < Bluetooth advertising is started + static const int BT_ADAPTER_LE_ADVERTISING_STARTED = 1; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE +/// @brief Enumerations of the Bluetooth advertising mode. +/// @since_tizen 2.3.1 +abstract class bt_adapter_le_advertising_mode_e { + /// < Balanced advertising mode + static const int BT_ADAPTER_LE_ADVERTISING_MODE_BALANCED = 0; + + /// < Low latency advertising mode + static const int BT_ADAPTER_LE_ADVERTISING_MODE_LOW_LATENCY = 1; + + /// < Low energy advertising mode + static const int BT_ADAPTER_LE_ADVERTISING_MODE_LOW_ENERGY = 2; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE +/// @brief Enumerations of the Bluetooth advertising filter policy. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class bt_adapter_le_advertising_filter_policy_e { + /// < White list is not in use + static const int BT_ADAPTER_LE_ADVERTISING_FILTER_DEFAULT = 0; + + /// < Allow the scan + /// request that in the White list + static const int BT_ADAPTER_LE_ADVERTISING_FILTER_ALLOW_SCAN_WL = 1; + + /// < Allow the connection + /// request that in the White list + static const int BT_ADAPTER_LE_ADVERTISING_FILTER_ALLOW_CONN_WL = 2; + + /// < Allow the + /// scan and connection request that in the White list + static const int BT_ADAPTER_LE_ADVERTISING_FILTER_ALLOW_SCAN_CONN_WL = 3; +} + +/// @MOBILE_ONLY +/// @deprecated Deprecated since 2.3.1 +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE +/// @brief Enumerations of the Bluetooth advertising type. +/// @since_tizen 2.3 +abstract class bt_adapter_le_advertising_type_e { + /// < Connectable undirected advertising (ADV_IND) + static const int BT_ADAPTER_LE_ADVERTISING_CONNECTABLE = 0; + + /// < Connectable high duty cycle directed advertising (ADV_DIRECT_IND) + static const int BT_ADAPTER_LE_ADVERTISING_CONNECTABLE_DIRECT_HIGH = 1; + + /// < Scannable undirected advertising (ADV_SCAN_IND) + static const int BT_ADAPTER_LE_ADVERTISING_SCANNABLE = 2; + + /// < Non connectable undirected advertising (ADV_NONCOND_IND) + static const int BT_ADAPTER_LE_ADVERTISING_NON_CONNECTABLE = 3; + + /// < Connectable low duty cycle directed advertising (ADV_DIRECT_IND) + static const int BT_ADAPTER_LE_ADVERTISING_CONNECTABLE_DIRECT_LOW = 4; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE +/// @brief Enumerations of the Bluetooth LE packet type. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class bt_adapter_le_packet_type_e { + /// < Advertising packet + static const int BT_ADAPTER_LE_PACKET_ADVERTISING = 0; + + /// < Scan response packet + static const int BT_ADAPTER_LE_PACKET_SCAN_RESPONSE = 1; +} + +/// @MOBILE_ONLY +/// @deprecated Deprecated since 2.3.1 +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE +/// @brief Enumerations of the Bluetooth LE data type +/// that can be included in LE packets. +/// @since_tizen 2.3 +abstract class bt_adapter_le_packet_data_type_e { + /// < Complete list of 16 bit UUIDs + static const int + BT_ADAPTER_LE_PACKET_DATA_COMP_LIST_16_BIT_SERVICE_CLASS_UUIDS = 3; + + /// title; + + /// < Artist + external ffi.Pointer artist; + + /// < Album name + external ffi.Pointer album; + + /// < Album Genre + external ffi.Pointer genre; + + /// < The total number of tracks + @ffi.Uint32() + external int total_tracks; + + /// < Track number + @ffi.Uint32() + external int number; + + /// < Duration + @ffi.Uint32() + external int duration; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_HDP_MODULE +/// @brief Enumerations for the data channel type +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class bt_hdp_channel_type_e { + /// < Reliable Data Channel + static const int BT_HDP_CHANNEL_TYPE_RELIABLE = 1; + + /// < Streaming Data Channel + static const int BT_HDP_CHANNEL_TYPE_STREAMING = 2; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE +/// @brief Enumerations of the integer type for GATT handle's value. +/// @since_tizen 2.3.1 +abstract class bt_data_type_int_e { + /// < 8 bit signed int type + static const int BT_DATA_TYPE_SINT8 = 0; + + /// < 16 bit signed int type + static const int BT_DATA_TYPE_SINT16 = 1; + + /// < 32 bit signed int type + static const int BT_DATA_TYPE_SINT32 = 2; + + /// < 8 bit unsigned int type + static const int BT_DATA_TYPE_UINT8 = 3; + + /// < 16 bit unsigned int type + static const int BT_DATA_TYPE_UINT16 = 4; + + /// < 32 bit unsigned int type + static const int BT_DATA_TYPE_UINT32 = 5; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE +/// @brief Enumerations of the float type for GATT handle's value. +/// @since_tizen 2.3.1 +abstract class bt_data_type_float_e { + /// < 32 bit float type + static const int BT_DATA_TYPE_FLOAT = 0; + + /// < 16 bit float type + static const int BT_DATA_TYPE_SFLOAT = 1; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE +/// @brief Enumerations of the write type. +/// @since_tizen 2.3.1 +abstract class bt_gatt_write_type_e { + /// < Write without response type + static const int BT_GATT_WRITE_TYPE_WRITE_NO_RESPONSE = 0; + + /// < Write type + static const int BT_GATT_WRITE_TYPE_WRITE = 1; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE +/// @brief Enumerations of the GATT handle's type. +/// @since_tizen 2.3.1 +abstract class bt_gatt_type_e { + /// < GATT service type + static const int BT_GATT_TYPE_SERVICE = 1; + static const int BT_GATT_TYPE_CHARACTERISTIC = 2; + + /// GATT characteristic type + static const int BT_GATT_TYPE_DESCRIPTOR = 3; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE +/// @brief Enumerations of the service type. +/// @since_tizen 2.3.1 +abstract class bt_gatt_service_type_e { + /// < GATT primary service type + static const int BT_GATT_SERVICE_TYPE_PRIMARY = 1; + + /// < GATT secondary service type + static const int BT_GATT_SERVICE_TYPE_SECONDARY = 2; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE +/// @brief Enumerations of the characteristic's property. +/// @since_tizen 2.3.1 +abstract class bt_gatt_property_e { + /// < Broadcast property + static const int BT_GATT_PROPERTY_BROADCAST = 1; + + /// < Read property + static const int BT_GATT_PROPERTY_READ = 2; + + /// < Write without response property + static const int BT_GATT_PROPERTY_WRITE_WITHOUT_RESPONSE = 4; + + /// < Write property + static const int BT_GATT_PROPERTY_WRITE = 8; + + /// < Notify property + static const int BT_GATT_PROPERTY_NOTIFY = 16; + + /// < Indicate property + static const int BT_GATT_PROPERTY_INDICATE = 32; + + /// < Authenticated signed writes property + static const int BT_GATT_PROPERTY_AUTHENTICATED_SIGNED_WRITES = 64; + + /// < Extended properties + static const int BT_GATT_PROPERTY_EXTENDED_PROPERTIES = 128; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE +/// @brief Enumerations of gatt server's service changing mode. +/// @since_tizen 3.0 +abstract class bt_gatt_client_service_change_type_e { + /// < Service added + static const int BT_GATT_CLIENT_SERVICE_ADDED = 0; + + /// < Service removed + static const int BT_GATT_CLIENT_SERVICE_REMOVED = 1; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_MODULE +/// @brief Enumerations of the attribute's permission. +/// @since_tizen 3.0 +abstract class bt_gatt_permission_e { + /// < Readable permission + static const int BT_GATT_PERMISSION_READ = 1; + + /// < Writable permission + static const int BT_GATT_PERMISSION_WRITE = 2; + + /// < Readable permission required encryption + static const int BT_GATT_PERMISSION_ENCRYPT_READ = 4; + + /// < Writable permission required encryption + static const int BT_GATT_PERMISSION_ENCRYPT_WRITE = 8; + + /// < Readable permission required encryption and authentication + static const int BT_GATT_PERMISSION_ENCRYPT_AUTHENTICATED_READ = 16; + + /// < Writable permission required encryption and authentication + static const int BT_GATT_PERMISSION_ENCRYPT_AUTHENTICATED_WRITE = 32; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_SERVER_MODULE +/// @brief Enumerations of the remote device request types for attributes +/// @since_tizen 3.0 +abstract class bt_gatt_att_request_type_e { + static const int BT_GATT_REQUEST_TYPE_READ = 0; + static const int BT_GATT_REQUEST_TYPE_WRITE = 1; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_PAN_PANU_MODULE +/// @brief Enumerations for the types of PAN(Personal Area Networking) service. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class bt_panu_service_type_e { + /// < Network Access Point + static const int BT_PANU_SERVICE_TYPE_NAP = 0; +} + +/// @WEARABLE_ONLY +/// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE +/// @brief Enumeration of address book location for PBAP. +/// @since_tizen 3.0 +abstract class bt_pbap_address_book_source_e { + /// < Request for Addressbook from remote device + static const int BT_PBAP_SOURCE_DEVICE = 0; + + /// < Request for address book from SIM + static const int BT_PBAP_SOURCE_SIM = 1; +} + +/// @WEARABLE_ONLY +/// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE +/// @brief Enumeration of folder type. +/// @since_tizen 3.0 +abstract class bt_pbap_folder_type_e { + /// < Request for address book + static const int BT_PBAP_FOLDER_PHONE_BOOK = 0; + + /// < Request for incoming calls + static const int BT_PBAP_FOLDER_INCOMING = 1; + + /// < Request for outgoing calls + static const int BT_PBAP_FOLDER_OUTGOING = 2; + + /// < Request for missed calls + static const int BT_PBAP_FOLDER_MISSED = 3; + + /// < Request for combined calls + static const int BT_PBAP_FOLDER_COMBINED = 4; +} + +/// @WEARABLE_ONLY +/// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE +/// @brief Enumeration of phone book search fields. +/// @since_tizen 3.0 +abstract class bt_pbap_search_field_e { + /// < Request for search by name (default) + static const int BT_PBAP_SEARCH_NAME = 0; + + /// < Request for search by phone number + static const int BT_PBAP_SEARCH_NUMBER = 1; + + /// < Request for search by sound + static const int BT_PBAP_SEARCH_SOUND = 2; +} + +/// @WEARABLE_ONLY +/// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE +/// @brief Enumeration of vCard Formats. +/// @since_tizen 3.0 +abstract class bt_pbap_vcard_format_e { + /// < vCard format 2.1 (default) + static const int BT_PBAP_VCARD_FORMAT_VCARD21 = 0; + + /// < vCard format 3.0 + static const int BT_PBAP_VCARD_FORMAT_VCARD30 = 1; +} + +/// @WEARABLE_ONLY +/// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE +/// @brief Enumeration of sorting orders. +/// @since_tizen 3.0 +abstract class bt_pbap_sort_order_e { + /// < Filter order indexed (default) + static const int BT_PBAP_ORDER_INDEXED = 0; + + /// < Filter order alphanumeric + static const int BT_PBAP_ORDER_ALPHANUMERIC = 1; + + /// < Filter order phonetic + static const int BT_PBAP_ORDER_PHONETIC = 2; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE +/// @brief Class structure of device and service. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +/// +/// @see #bt_device_info_s +/// @see #bt_adapter_device_discovery_info_s +/// @see bt_device_bond_created_cb() +/// @see bt_adapter_device_discovery_state_changed_cb() +class bt_class_s extends ffi.Struct { + /// < Major device class. + @ffi.Int32() + external int major_device_class; + + /// < Minor device class. + @ffi.Int32() + external int minor_device_class; + + /// < Major service class mask. + /// This value can be a combination of #bt_major_service_class_e like #BT_MAJOR_SERVICE_CLASS_RENDERING | #BT_MAJOR_SERVICE_CLASS_AUDIO + @ffi.Int32() + external int major_service_class_mask; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_MODULE +/// @brief Structure of device discovery information. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +/// +/// @see #bt_class_s +/// @see bt_adapter_device_discovery_state_changed_cb() +class bt_adapter_device_discovery_info_s extends ffi.Struct { + /// < The address of remote device + external ffi.Pointer remote_address; + + /// < The name of remote device + external ffi.Pointer remote_name; + + /// < The Bluetooth classes + external bt_class_s bt_class; + + /// < The strength indicator of received signal + @ffi.Int32() + external int rssi; + + /// < The bonding state + @ffi.Uint8() + external int is_bonded; + + /// < The UUID list of service + external ffi.Pointer> service_uuid; + + /// < The number of services + @ffi.Int32() + external int service_count; + + /// < The Bluetooth appearance + @ffi.Int32() + external int appearance; + + /// < manufacturer specific data length + @ffi.Int32() + external int manufacturer_data_len; + + /// < manufacturer specific data + external ffi.Pointer manufacturer_data; +} + +/// @MOBILE_ONLY +/// @deprecated Deprecated since 2.3.1 +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE +/// @brief Structure of le device discovery information. +/// @since_tizen 2.3 +/// +/// @see #bt_class_s +/// @see bt_adapter_le_device_discovery_state_changed_cb() +class bt_adapter_le_device_discovery_info_s extends ffi.Struct { + /// < The address of remote device + external ffi.Pointer remote_address; + + /// < The address type of remote device + @ffi.Int32() + external int address_type; + + /// < The strength indicator of received signal + @ffi.Int32() + external int rssi; + + /// < advertising indication data length + @ffi.Int32() + external int adv_data_len; + + /// < advertising indication data + external ffi.Pointer adv_data; + + /// < scan response data length + @ffi.Int32() + external int scan_data_len; + + /// < scan response data + external ffi.Pointer scan_data; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE +/// @brief Structure of le scan result information. +/// @since_tizen 2.3.1 +/// +/// @see bt_adapter_le_start_scan() +class bt_adapter_le_device_scan_result_info_s extends ffi.Struct { + /// < The address of remote device + external ffi.Pointer remote_address; + + /// < The address type of remote device + @ffi.Int32() + external int address_type; + + /// < The strength indicator of received signal + @ffi.Int32() + external int rssi; + + /// < advertising indication data length + @ffi.Int32() + external int adv_data_len; + + /// < advertising indication data + external ffi.Pointer adv_data; + + /// < scan response data length + @ffi.Int32() + external int scan_data_len; + + /// < scan response data + external ffi.Pointer scan_data; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE +/// @brief The structure for LE iBeacon scan result information. +/// @since_tizen 4.0 +/// +/// @see bt_adapter_le_start_scan() +class bt_adapter_le_ibeacon_scan_result_info_s extends ffi.Struct { + /// < Company ID + @ffi.Int32() + external int company_id; + + /// < iBeacon type + @ffi.Int32() + external int ibeacon_type; + + /// < UUID + external ffi.Pointer uuid; + + /// < Major ID + @ffi.Int32() + external int major_id; + + /// < Minor ID + @ffi.Int32() + external int minor_id; + + /// < Measured power + @ffi.Int32() + external int measured_power; +} + +/// @MOBILE_ONLY +/// @deprecated Deprecated since 2.3.1 +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE +/// @brief Structure of advertising parameters. +/// @since_tizen 2.3 +/// +/// @see bt_adapter_le_advertising_state_changed_cb() +/// @see bt_adapter_le_start_advertising() +class bt_adapter_le_advertising_params_s extends ffi.Struct { + /// < Minimum advertising interval for non-directed advertising. + /// A multiple of 0.625ms is only allowed (Time range : 20ms to 10.24sec). + @ffi.Float() + external double interval_min; + + /// < Maximum advertising interval for non-directed advertising. + /// A multiple of 0.625ms is only allowed (Time range : 20ms to 10.24sec). + @ffi.Float() + external double interval_max; + + @ffi.Int8() + external int filter_policy; + + @ffi.Int8() + external int type; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE +/// @brief LE service data structure. +/// @since_tizen 2.3.1 +/// +/// @see bt_adapter_le_get_scan_result_service_data() +class bt_adapter_le_service_data_s extends ffi.Struct { + /// < 16 bit UUID of the service data + external ffi.Pointer service_uuid; + + /// < Service data + external ffi.Pointer service_data; + + /// < Service data length + @ffi.Int32() + external int service_data_len; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE +/// @brief Device information structure used for identifying pear device. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +/// +/// @see #bt_class_s +/// @see bt_device_bond_created_cb() +class bt_device_info_s extends ffi.Struct { + /// < The address of remote device + external ffi.Pointer remote_address; + + /// < The name of remote device + external ffi.Pointer remote_name; + + /// < The Bluetooth classes + external bt_class_s bt_class; + + /// < The UUID list of service + external ffi.Pointer> service_uuid; + + /// < The number of services + @ffi.Int32() + external int service_count; + + /// < The bonding state + @ffi.Uint8() + external int is_bonded; + + /// < The connection state + @ffi.Uint8() + external int is_connected; + + /// < The authorization state + @ffi.Uint8() + external int is_authorized; + + /// < manufacturer specific data length + @ffi.Int32() + external int manufacturer_data_len; + + /// < manufacturer specific data + external ffi.Pointer manufacturer_data; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE +/// @brief Service Discovery Protocol (SDP) data structure. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +/// +/// @details This protocol is used for discovering available services or pear device, +/// and finding one to connect with. +/// +/// @see bt_device_service_searched_cb() +class bt_device_sdp_info_s extends ffi.Struct { + /// < The address of remote device + external ffi.Pointer remote_address; + + /// < The UUID list of service + external ffi.Pointer> service_uuid; + + /// < The number of services. + @ffi.Int32() + external int service_count; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_DEVICE_MODULE +/// @brief Device connection information structure. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +/// +/// @see bt_device_connection_state_changed_cb() +class bt_device_connection_info_s extends ffi.Struct { + /// < The address of remote device + external ffi.Pointer remote_address; + + /// < Link type + @ffi.Int32() + external int link; + + /// < Disconnection reason + @ffi.Int32() + external int disconn_reason; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE +/// @brief Rfcomm connection data used for exchanging data between Bluetooth devices. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +/// +/// @see bt_socket_connection_state_changed_cb() +class bt_socket_connection_s extends ffi.Struct { + /// < The file descriptor of connected socket + @ffi.Int32() + external int socket_fd; + + /// < The file descriptor of the server socket or -1 for client connection + @ffi.Int32() + external int server_fd; + + /// < The local device role in this connection + @ffi.Int32() + external int local_role; + + /// < The remote device address + external ffi.Pointer remote_address; + + /// < The service UUId + external ffi.Pointer service_uuid; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_SOCKET_MODULE +/// @brief Structure of RFCOMM received data. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +/// +/// @remarks User can use standard linux functions for reading/writing +/// data from/to sockets. +/// +/// @see bt_socket_data_received_cb() +class bt_socket_received_data_s extends ffi.Struct { + /// < The socket fd + @ffi.Int32() + external int socket_fd; + + /// < The length of the received data + @ffi.Int32() + external int data_size; + + /// < The received data + external ffi.Pointer data; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_GATT_CLIENT_MODULE +/// @brief Attribute protocol MTU change information structure. +/// @since_tizen 4.0 +/// +/// @see bt_gatt_client_att_mtu_changed_cb() +class bt_gatt_client_att_mtu_info_s extends ffi.Struct { + /// < The address of remote device + external ffi.Pointer remote_address; + + /// < MTU value + @ffi.Uint32() + external int mtu; + + /// < Request status + @ffi.Uint32() + external int status; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_HID_DEVICE_MODULE +/// @brief Enumerations of the Bluetooth HID mouse's button. +/// @since_tizen @if WEARABLE 3.0 @endif +abstract class bt_hid_mouse_button_e { + /// key; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_HID_DEVICE_MODULE +/// @brief Enumerations of the Bluetooth HID header type. +/// @since_tizen @if WEARABLE 3.0 @endif +abstract class bt_hid_header_type_e { + /// < The Bluetooth HID header type: Handshake + static const int BT_HID_HEADER_HANDSHAKE = 0; + + /// < The Bluetooth HID header type: HID control + static const int BT_HID_HEADER_HID_CONTROL = 1; + + /// < The Bluetooth HID header type: Get report + static const int BT_HID_HEADER_GET_REPORT = 2; + + /// < The Bluetooth HID header type: Set report + static const int BT_HID_HEADER_SET_REPORT = 3; + + /// < The Bluetooth HID header type: Get protocol + static const int BT_HID_HEADER_GET_PROTOCOL = 4; + + /// < The Bluetooth HID header type: Set protocol + static const int BT_HID_HEADER_SET_PROTOCOL = 5; + + /// < The Bluetooth HID header type: Data + static const int BT_HID_HEADER_DATA = 6; + + /// < The Bluetooth HID header type: Unknown + static const int BT_HID_HEADER_UNKNOWN = 7; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_HID_DEVICE_MODULE +/// @brief Enumerations of the Bluetooth HID parameter type. +/// @since_tizen @if WEARABLE 3.0 @endif +abstract class bt_hid_param_type_e { + /// < Parameter type: Input + static const int BT_HID_PARAM_DATA_RTYPE_INPUT = 0; + + /// < Parameter type: Output + static const int BT_HID_PARAM_DATA_RTYPE_OUTPUT = 1; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_HID_DEVICE_MODULE +/// @brief Enumerations of the Bluetooth HID handshake type. +/// @since_tizen @if WEARABLE 3.0 @endif +abstract class bt_hid_handshake_type_e { + /// < Handshake error code none + static const int BT_HID_HANDSHAKE_SUCCESSFUL = 0; + + /// < Handshake error code Not Ready + static const int BT_HID_HANDSHAKE_NOT_READY = 1; + + /// < Handshake error code send invalid report id + static const int BT_HID_HANDSHAKE_ERR_INVALID_REPORT_ID = 2; + + /// < Handshake error code request unsupported request + static const int BT_HID_HANDSHAKE_ERR_UNSUPPORTED_REQUEST = 3; + + /// < Handshake error code received invalid parameter + static const int BT_HID_HANDSHAKE_ERR_INVALID_PARAMETER = 4; + + /// < unknown error + static const int BT_HID_HANDSHAKE_ERR_UNKNOWN = 14; + + /// < Fatal error + static const int BT_HID_HANDSHAKE_ERR_FATAL = 15; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_HID_DEVICE_MODULE +/// @brief The structure type containing data received from the HID Host. +/// @since_tizen @if WEARABLE 3.0 @endif +class bt_hid_device_received_data_s extends ffi.Struct { + /// < The remote device's address + external ffi.Pointer address; + + /// < The header type + @ffi.Int32() + external int header_type; + + /// < The parameter type + @ffi.Int32() + external int param_type; + + /// < The length of the received data + @ffi.Int32() + external int data_size; + + /// < The received data + external ffi.Pointer data; +} + +/// @WEARABLE_ONLY +/// @ingroup CAPI_NETWORK_BLUETOOTH_PBAP_MODULE +/// @brief The structure type containing vCard information. +/// @since_tizen 3.0 +/// +/// @see bt_pbap_client_pull_vcard() +class bt_pbap_vcard_info_s extends ffi.Struct { + /// < The vcard index, used as a parameter for bt_pbap_client_pull_vcard() + @ffi.Int32() + external int index; + + /// < The contact name of the vCard + external ffi.Pointer contact_name; +} + +/// @ingroup CAPI_NETWORK_BLUETOOTH_ADAPTER_LE_MODULE +/// @brief Enumeration for the scan filter type. +/// @since_tizen 4.0 +/// @see bt_adapter_le_scan_filter_set_type() +abstract class bt_adapter_le_scan_filter_type_e { + /// < iBeacon filter type + static const int BT_ADAPTER_LE_SCAN_FILTER_TYPE_IBEACON = 0; + + /// < Proximity UUID filter type + static const int BT_ADAPTER_LE_SCAN_FILTER_TYPE_PROXIMITY_UUID = 1; +} + +/// @brief Enumeration for security type of Wi-Fi. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_wifi_security_type_e { + /// < Security disabled + static const int CONNECTION_WIFI_SECURITY_TYPE_NONE = 0; + + /// < WEP + static const int CONNECTION_WIFI_SECURITY_TYPE_WEP = 1; + + /// < WPA-PSK + static const int CONNECTION_WIFI_SECURITY_TYPE_WPA_PSK = 2; + + /// < WPA2-PSK + static const int CONNECTION_WIFI_SECURITY_TYPE_WPA2_PSK = 3; + + /// < EAP + static const int CONNECTION_WIFI_SECURITY_TYPE_EAP = 4; +} + +/// @brief Enumeration for encryption modes. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_wifi_encryption_type_e { + /// < Encryption disabled + static const int CONNECTION_WIFI_ENCRYPTION_TYPE_NONE = 0; + + /// < WEP + static const int CONNECTION_WIFI_ENCRYPTION_TYPE_WEP = 1; + + /// < TKIP + static const int CONNECTION_WIFI_ENCRYPTION_TYPE_TKIP = 2; + + /// < AES + static const int CONNECTION_WIFI_ENCRYPTION_TYPE_AES = 3; + + /// < TKIP and AES are both supported + static const int CONNECTION_WIFI_ENCRYPTION_TYPE_TKIP_AES_MIXED = 4; +} + +/// @brief Enumeration for cellular service type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_cellular_service_type_e { + /// < Unknown + static const int CONNECTION_CELLULAR_SERVICE_TYPE_UNKNOWN = 0; + + /// < Internet + static const int CONNECTION_CELLULAR_SERVICE_TYPE_INTERNET = 1; + + /// < MMS + static const int CONNECTION_CELLULAR_SERVICE_TYPE_MMS = 2; + + /// < Prepaid internet + static const int CONNECTION_CELLULAR_SERVICE_TYPE_PREPAID_INTERNET = 3; + + /// < Prepaid MMS + static const int CONNECTION_CELLULAR_SERVICE_TYPE_PREPAID_MMS = 4; + + /// < Tethering + static const int CONNECTION_CELLULAR_SERVICE_TYPE_TETHERING = 5; + + /// < Specific application + static const int CONNECTION_CELLULAR_SERVICE_TYPE_APPLICATION = 6; +} + +/// @brief Enumeration for cellular pdn type. +/// @since_tizen 3.0 +/// @remarks Use CONNECTION_CELLULAR_PDN_TYPE_IPV4_IPV6 instead of +/// CONNECTION_CELLULAR_PDN_TYPE_IPV4_IPv6. +abstract class connection_cellular_pdn_type_e { + static const int CONNECTION_CELLULAR_PDN_TYPE_UNKNOWN = 0; + + /// > Unknown + static const int CONNECTION_CELLULAR_PDN_TYPE_IPV4 = 1; + + /// > IPv4 + static const int CONNECTION_CELLULAR_PDN_TYPE_IPV6 = 2; + + /// > IPv6 + static const int CONNECTION_CELLULAR_PDN_TYPE_IPV4_IPv6 = 3; + + /// > IPv4 and IPv6 (Deprecated since 4.0) + static const int CONNECTION_CELLULAR_PDN_TYPE_IPV4_IPV6 = 4; +} + +/// @brief Enumeration for cellular authentication type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_cellular_auth_type_e { + /// < No authentication + static const int CONNECTION_CELLULAR_AUTH_TYPE_NONE = 0; + + /// < PAP authentication + static const int CONNECTION_CELLULAR_AUTH_TYPE_PAP = 1; + + /// < CHAP authentication + static const int CONNECTION_CELLULAR_AUTH_TYPE_CHAP = 2; +} + +/// @brief Enumeration for profile state type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_profile_state_e { + /// < Disconnected state + static const int CONNECTION_PROFILE_STATE_DISCONNECTED = 0; + + /// < Association state + static const int CONNECTION_PROFILE_STATE_ASSOCIATION = 1; + + /// < Configuration state + static const int CONNECTION_PROFILE_STATE_CONFIGURATION = 2; + + /// < Connected state + static const int CONNECTION_PROFILE_STATE_CONNECTED = 3; +} + +/// @brief Enumeration for address family. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_address_family_e { + /// < IPV4 Address type + static const int CONNECTION_ADDRESS_FAMILY_IPV4 = 0; + + /// < IPV6 Address type + static const int CONNECTION_ADDRESS_FAMILY_IPV6 = 1; +} + +/// @brief Enumeration for IP configuration type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_ip_config_type_e { + /// Not defined + static const int CONNECTION_IP_CONFIG_TYPE_NONE = 0; + + /// Manual IP configuration + static const int CONNECTION_IP_CONFIG_TYPE_STATIC = 1; + + /// Config IP using DHCP client + static const int CONNECTION_IP_CONFIG_TYPE_DYNAMIC = 2; + + /// Config IP from Auto IP pool (169.254/16). Later with DHCP client, if available + static const int CONNECTION_IP_CONFIG_TYPE_AUTO = 3; + + /// Indicates an IP address that can not be modified + static const int CONNECTION_IP_CONFIG_TYPE_FIXED = 4; +} + +/// @brief Enumeration for proxy method type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_proxy_type_e { + /// Direct connection + static const int CONNECTION_PROXY_TYPE_DIRECT = 0; + + /// Auto configuration (use PAC file). If URL property is not set, + /// DHCP/WPAD auto-discover will be tried + static const int CONNECTION_PROXY_TYPE_AUTO = 1; + + /// Manual configuration + static const int CONNECTION_PROXY_TYPE_MANUAL = 2; +} + +/// @brief Enumeration for DNS configuration type. +/// @since_tizen 4.0 +abstract class connection_dns_config_type_e { + /// < Not defined + static const int CONNECTION_DNS_CONFIG_TYPE_NONE = 0; + + /// < Manual DNS configuration + static const int CONNECTION_DNS_CONFIG_TYPE_STATIC = 1; + + /// < Config DNS using DHCP client + static const int CONNECTION_DNS_CONFIG_TYPE_DYNAMIC = 2; +} + +/// @brief Enumeration for network connection type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_profile_type_e { + /// < Cellular type + static const int CONNECTION_PROFILE_TYPE_CELLULAR = 0; + + /// < Wi-Fi type + static const int CONNECTION_PROFILE_TYPE_WIFI = 1; + + /// < Ethernet type + static const int CONNECTION_PROFILE_TYPE_ETHERNET = 2; + + /// < Bluetooth type + static const int CONNECTION_PROFILE_TYPE_BT = 3; +} + +/// @brief Enumeration for connection type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_type_e { + /// < Disconnected + static const int CONNECTION_TYPE_DISCONNECTED = 0; + + /// < Wi-Fi type + static const int CONNECTION_TYPE_WIFI = 1; + + /// < Cellular type + static const int CONNECTION_TYPE_CELLULAR = 2; + + /// < Ethernet type + static const int CONNECTION_TYPE_ETHERNET = 3; + + /// < Bluetooth type + static const int CONNECTION_TYPE_BT = 4; + + /// < Proxy type for internet connection (Since 3.0) + static const int CONNECTION_TYPE_NET_PROXY = 5; +} + +/// @brief Enumeration for cellular network state. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_cellular_state_e { + /// < Out of service + static const int CONNECTION_CELLULAR_STATE_OUT_OF_SERVICE = 0; + + /// < Flight mode + static const int CONNECTION_CELLULAR_STATE_FLIGHT_MODE = 1; + + /// < Roaming is turned off + static const int CONNECTION_CELLULAR_STATE_ROAMING_OFF = 2; + + /// < Call is only available + static const int CONNECTION_CELLULAR_STATE_CALL_ONLY_AVAILABLE = 3; + + /// < Available but not connected yet + static const int CONNECTION_CELLULAR_STATE_AVAILABLE = 4; + + /// < Connected + static const int CONNECTION_CELLULAR_STATE_CONNECTED = 5; +} + +/// @brief Enumeration for Wi-Fi state. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_wifi_state_e { + /// < Wi-Fi is deactivated + static const int CONNECTION_WIFI_STATE_DEACTIVATED = 0; + + /// < Disconnected + static const int CONNECTION_WIFI_STATE_DISCONNECTED = 1; + + /// < Connected + static const int CONNECTION_WIFI_STATE_CONNECTED = 2; +} + +/// @brief Enumeration for ethernet state. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class connection_ethernet_state_e { + /// < There is no Ethernet profile to open + static const int CONNECTION_ETHERNET_STATE_DEACTIVATED = 0; + + /// < Disconnected + static const int CONNECTION_ETHERNET_STATE_DISCONNECTED = 1; + + /// < Connected + static const int CONNECTION_ETHERNET_STATE_CONNECTED = 2; +} + +/// @brief Enumeration for Bluetooth state. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_bt_state_e { + /// < There is no Bluetooth profile to open + static const int CONNECTION_BT_STATE_DEACTIVATED = 0; + + /// < Disconnected + static const int CONNECTION_BT_STATE_DISCONNECTED = 1; + + /// < Connected + static const int CONNECTION_BT_STATE_CONNECTED = 2; +} + +/// @brief Enumeration for connection iterator type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_iterator_type_e { + /// < The iterator of the registered profile + static const int CONNECTION_ITERATOR_TYPE_REGISTERED = 0; + + /// < The iterator of the connected profile + static const int CONNECTION_ITERATOR_TYPE_CONNECTED = 1; + + /// < The iterator of the default profile + static const int CONNECTION_ITERATOR_TYPE_DEFAULT = 2; +} + +/// @brief Enumeration for reset profile type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_reset_option_e { + /// Initialized with the default profile defined by csc + static const int CONNECTION_RESET_DEFAULT_PROFILE = 0; + + /// Remove all profiles + static const int CONNECTION_RESET_CLEAR_PROFILE = 1; +} + +/// @brief Enumeration for the attached or detached state of ethernet cable. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class connection_ethernet_cable_state_e { + /// < Ethernet cable is detached + static const int CONNECTION_ETHERNET_CABLE_DETACHED = 0; + + /// < Ethernet cable is attached + static const int CONNECTION_ETHERNET_CABLE_ATTACHED = 1; +} + +/// @brief Enumeration for connection errors. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_error_e { + /// Successful + static const int CONNECTION_ERROR_NONE = 0; + + /// Invalid parameter + static const int CONNECTION_ERROR_INVALID_PARAMETER = -22; + + /// Out of memory error + static const int CONNECTION_ERROR_OUT_OF_MEMORY = -12; + + /// Invalid operation + static const int CONNECTION_ERROR_INVALID_OPERATION = -38; + + /// Address family not supported + static const int CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED = -97; + + /// Operation failed + static const int CONNECTION_ERROR_OPERATION_FAILED = -29424639; + + /// End of iteration + static const int CONNECTION_ERROR_ITERATOR_END = -29424638; + + /// There is no connection + static const int CONNECTION_ERROR_NO_CONNECTION = -29424637; + + /// Now inprogress + static const int CONNECTION_ERROR_NOW_IN_PROGRESS = -115; + + /// Already exists + static const int CONNECTION_ERROR_ALREADY_EXISTS = -29424636; + + /// Operation is aborted + static const int CONNECTION_ERROR_OPERATION_ABORTED = -29424635; + + /// DHCP failed + static const int CONNECTION_ERROR_DHCP_FAILED = -29424634; + + /// Invalid key + static const int CONNECTION_ERROR_INVALID_KEY = -29424633; + + /// No reply + static const int CONNECTION_ERROR_NO_REPLY = -29424632; + + /// Permission denied + static const int CONNECTION_ERROR_PERMISSION_DENIED = -13; + + /// Not supported + static const int CONNECTION_ERROR_NOT_SUPPORTED = -1073741822; +} + +/// @brief Enumeration for statistics type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class connection_statistics_type_e { + /// < Last received data + static const int CONNECTION_STATISTICS_TYPE_LAST_RECEIVED_DATA = 0; + + /// < Last sent data + static const int CONNECTION_STATISTICS_TYPE_LAST_SENT_DATA = 1; + + /// < Total received data + static const int CONNECTION_STATISTICS_TYPE_TOTAL_RECEIVED_DATA = 2; + + /// < Total sent data + static const int CONNECTION_STATISTICS_TYPE_TOTAL_SENT_DATA = 3; +} + +/// @brief Enumeration for Network Service Discovery DNSSD error code. +/// @since_tizen 3.0 +abstract class dnssd_error_e { + /// < Successful + static const int DNSSD_ERROR_NONE = 0; + + /// < Out of memory + static const int DNSSD_ERROR_OUT_OF_MEMORY = -12; + + /// < Permission denied + static const int DNSSD_ERROR_PERMISSION_DENIED = -13; + + /// < Invalid operation + static const int DNSSD_ERROR_INVALID_OPERATION = -38; + + /// < Invalid function parameter + static const int DNSSD_ERROR_INVALID_PARAMETER = -22; + + /// < Not supported + static const int DNSSD_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Not Initialized + static const int DNSSD_ERROR_NOT_INITIALIZED = -30015487; + + /// < Already registered + static const int DNSSD_ERROR_ALREADY_REGISTERED = -30015486; + + /// < Name conflict + static const int DNSSD_ERROR_NAME_CONFLICT = -30015485; + + /// < Background daemon not running + static const int DNSSD_ERROR_SERVICE_NOT_RUNNING = -30015484; + + /// < Service not found + static const int DNSSD_ERROR_SERVICE_NOT_FOUND = -30015483; + + /// < Operation failed + static const int DNSSD_ERROR_OPERATION_FAILED = -30015482; +} + +/// @brief Enumeration for Network Service Discovery DNSSD browse state. +/// @since_tizen 3.0 +abstract class dnssd_service_state_e { + /// data; + + /// < The size of the binary data + @ffi.Int32() + external int size; +} + +/// @brief The structure for a policy for storing key/certificate/binary data. +/// @since_tizen 2.3 +class ckmc_policy_s extends ffi.Struct { + /// < Byte array used to encrypt data inside CKM. If it is not null, the data + /// (or key, or certificate) is stored encrypted with this password inside + /// key manager + external ffi.Pointer password; + + /// < If true key may be extracted from storage + @ffi.Uint8() + external int extractable; +} + +/// @brief The structure for key used in key manager CAPI. +/// @since_tizen 2.3 +class ckmc_key_s extends ffi.Struct { + /// < Byte array of key. raw_key may be encrypted with password + external ffi.Pointer raw_key; + + /// < The byte size of raw_key + @ffi.Int32() + external int key_size; + + /// < The raw_key's type + @ffi.Int32() + external int key_type; + + /// < Byte array used to decrypt data raw_key inside key manager. + external ffi.Pointer password; +} + +/// @brief The structure for certificate used in key manager CAPI. +/// @since_tizen 2.3 +class ckmc_cert_s extends ffi.Struct { + /// < Byte array of certificate + external ffi.Pointer raw_cert; + + /// < Byte size of raw_cert + @ffi.Int32() + external int cert_size; + + /// < Raw_cert's encoding format + @ffi.Int32() + external int data_format; +} + +/// @brief The structure for linked list of alias. +/// @since_tizen 2.3 +class ckmc_alias_list_s extends ffi.Struct { + /// < The name of key, certificate or data stored in key manager + external ffi.Pointer alias; + + /// < The pointer pointing to the next ckmc_alias_list_s + external ffi.Pointer next; +} + +/// @brief The structure for linked list of ckmc_cert_s +/// @since_tizen 2.3 +class ckmc_cert_list_s extends ffi.Struct { + /// < The pointer of ckmc_cert_s + external ffi.Pointer cert; + + /// < The pointer pointing to the next ckmc_cert_list_s + external ffi.Pointer next; +} + +/// @brief Enumeration for OCSP status. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class ckmc_ocsp_status_e { + /// < OCSP status is good + static const int CKMC_OCSP_STATUS_GOOD = 0; + + /// < The certificate is revoked + static const int CKMC_OCSP_STATUS_REVOKED = 1; + + /// < Unknown error + static const int CKMC_OCSP_STATUS_UNKNOWN = 2; + + /// < The certificate does not provide OCSP extension + static const int CKMC_OCSP_ERROR_UNSUPPORTED = 3; + + /// < The invalid URL in certificate OCSP extension + static const int CKMC_OCSP_ERROR_INVALID_URL = 4; + + /// < The invalid response from OCSP server + static const int CKMC_OCSP_ERROR_INVALID_RESPONSE = 5; + + /// < OCSP remote server error + static const int CKMC_OCSP_ERROR_REMOTE = 6; + + /// < Network connection error + static const int CKMC_OCSP_ERROR_NET = 7; + + /// < OpenSSL API error + static const int CKMC_OCSP_ERROR_INTERNAL = 8; +} + +/// @brief The structure for PKCS12 used in key manager CAPI. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +class ckmc_pkcs12_s extends ffi.Struct { + /// < The private key, may be null + external ffi.Pointer priv_key; + + /// < The certificate, may be null + external ffi.Pointer cert; + + /// < The chain certificate list, may be null + external ffi.Pointer ca_chain; +} + +/// @brief Enumeration for crypto algorithm parameters. +/// @since_tizen 3.0 +/// @see #ckmc_algo_type_e +abstract class ckmc_param_name_e { + static const int CKMC_PARAM_ALGO_TYPE = 1; + + /// < 16B buffer (up to 2^64-1 bytes long in case of AES GCM) + static const int CKMC_PARAM_ED_IV = 101; + + /// < integer - ctr length in bits + static const int CKMC_PARAM_ED_CTR_LEN = 102; + + /// < buffer + static const int CKMC_PARAM_ED_AAD = 103; + + /// < integer - tag length in bits + static const int CKMC_PARAM_ED_TAG_LEN = 104; + + /// < buffer + static const int CKMC_PARAM_ED_LABEL = 105; +} + +class __ckmc_param_list extends ffi.Opaque {} + +/// @brief Enumeration for crypto algorithm types. +/// @since_tizen 3.0 +/// @see #ckmc_param_name_e +abstract class ckmc_algo_type_e { + /// < AES-CTR algorithm + /// Supported parameters: + /// - CKMC_PARAM_ALGO_TYPE = CKMC_ALGO_AES_CTR(mandatory), + /// - CKMC_PARAM_ED_IV = 16-byte initialization vector(mandatory) + /// - CKMC_PARAM_ED_CTR_LEN = length of counter block in bits + /// (optional, only 128b is supported at the moment) + static const int CKMC_ALGO_AES_CTR = 1; + + /// < AES-CBC algorithm + /// Supported parameters: + /// - CKMC_PARAM_ALGO_TYPE = CKMC_ALGO_AES_CBC(mandatory), + /// - CKMC_PARAM_ED_IV = 16-byte initialization vector(mandatory) + static const int CKMC_ALGO_AES_CBC = 2; + + /// < AES-GCM algorithm + /// Supported parameters: + /// - CKMC_PARAM_ALGO_TYPE = CKMC_ALGO_AES_GCM(mandatory), + /// - CKMC_PARAM_ED_IV = initialization vector(mandatory) + /// - CKMC_PARAM_ED_TAG_LEN = GCM tag length in bits. One of + /// {32, 64, 96, 104, 112, 120, 128} (optional, if not present, the + /// length 128 is used) + /// - CKMC_PARAM_ED_AAD = additional authentication data(optional) + static const int CKMC_ALGO_AES_GCM = 3; + + /// < AES-CFB algorithm + /// Supported parameters: + /// - CKMC_PARAM_ALGO_TYPE = CKMC_ALGO_AES_CFB(mandatory), + /// - CKMC_PARAM_ED_IV = 16-byte initialization vector(mandatory) + static const int CKMC_ALGO_AES_CFB = 4; + + /// < RSA-OAEP algorithm + /// Supported parameters: + /// - CKMC_PARAM_ALGO_TYPE = CKMC_ALGO_RSA_OAEP(required), + /// - CKMC_PARAM_ED_LABEL = label to be associated with the message + /// (optional, not supported at the moment) + static const int CKMC_ALGO_RSA_OAEP = 5; +} + +/// @brief Enumeration for error codes of Privacy Privilege Manager. +/// @since_tizen 4.0 +abstract class ppm_error_e { + /// Successful + static const int PRIVACY_PRIVILEGE_MANAGER_ERROR_NONE = 0; + + /// I/O error + static const int PRIVACY_PRIVILEGE_MANAGER_ERROR_IO_ERROR = -5; + + /// Invalid parameter + static const int PRIVACY_PRIVILEGE_MANAGER_ERROR_INVALID_PARAMETER = -22; + + /// Operation already in progress + static const int PRIVACY_PRIVILEGE_MANAGER_ERROR_ALREADY_IN_PROGRESS = -114; + + /// Out of memory + static const int PRIVACY_PRIVILEGE_MANAGER_ERROR_OUT_OF_MEMORY = -12; + + /// Unknown error + static const int PRIVACY_PRIVILEGE_MANAGER_ERROR_UNKNOWN = -1073741824; +} + +/// @brief Enumeration for results of a permission check. +/// @since_tizen 4.0 +abstract class ppm_check_result_e { + /// The application has permission to use a privilege. + static const int PRIVACY_PRIVILEGE_MANAGER_CHECK_RESULT_ALLOW = 0; + + /// The application doesn't have permission to use a privilege. + static const int PRIVACY_PRIVILEGE_MANAGER_CHECK_RESULT_DENY = 1; + + /// The user has to be asked whether to grant permission to use a privilege. + static const int PRIVACY_PRIVILEGE_MANAGER_CHECK_RESULT_ASK = 2; +} + +/// @brief Enumeration for results of a permission request. +/// @since_tizen 4.0 +abstract class ppm_request_result_e { + /// The user granted permission to use a privilege for an indefinite period of time. + static const int PRIVACY_PRIVILEGE_MANAGER_REQUEST_RESULT_ALLOW_FOREVER = 0; + + /// The user denied granting permission to use a privilege for an indefinite period of time. + static const int PRIVACY_PRIVILEGE_MANAGER_REQUEST_RESULT_DENY_FOREVER = 1; + + /// The user denied granting permission to use a privilege once. + static const int PRIVACY_PRIVILEGE_MANAGER_REQUEST_RESULT_DENY_ONCE = 2; +} + +/// @brief Enumeration for status codes of a permission request. +/// @since_tizen 4.0 +abstract class ppm_call_cause_e { + /// Callback was called with a valid answer. + static const int PRIVACY_PRIVILEGE_MANAGER_CALL_CAUSE_ANSWER = 0; + + /// Callback was called because of an error. + static const int PRIVACY_PRIVILEGE_MANAGER_CALL_CAUSE_ERROR = 1; +} + +/// @brief Enumeration for error code for Privilege Information. +/// @since_tizen @if WEARABLE 2.3.1 @elseif MOBILE 2.3 @endif +abstract class privilege_info_error_e { + /// < Successful + static const int PRVINFO_ERROR_NONE = 0; + + /// < Invalid function parameter + static const int PRVINFO_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int PRVINFO_ERROR_OUT_OF_MEMORY = -12; + + /// < Unknown error + static const int PRVINFO_ERROR_INTERNAL_ERROR = -1073741824; +} + +class yaca_context_s extends ffi.Opaque {} + +class yaca_key_s extends ffi.Opaque {} + +/// @brief Enumeration of YACA key formats. +/// +/// @since_tizen 3.0 +abstract class yaca_key_format_e { + /// Key is either PKCS#1 for RSA or SSLeay for DSA, also use this option for symmetric + static const int YACA_KEY_FORMAT_DEFAULT = 0; + + /// Key is in PKCS#8, can only be used for asymmetric private keys + static const int YACA_KEY_FORMAT_PKCS8 = 1; +} + +/// @brief Enumeration of YACA key file formats. +/// +/// @since_tizen 3.0 +abstract class yaca_key_file_format_e { + /// Key file is in raw binary format, used for symmetric keys + static const int YACA_KEY_FILE_FORMAT_RAW = 0; + + /// Key file is encoded in ASCII-base64, used for symmetric keys + static const int YACA_KEY_FILE_FORMAT_BASE64 = 1; + + /// Key file is in PEM file format, used for asymmetric keys + static const int YACA_KEY_FILE_FORMAT_PEM = 2; + + /// Key file is in DER file format, used for asymmetric keys + static const int YACA_KEY_FILE_FORMAT_DER = 3; +} + +/// @brief Enumeration of YACA key types, Initialization Vector is considered as key. +/// +/// @since_tizen 3.0 +abstract class yaca_key_type_e { + /// Generic symmetric cipher KEY + static const int YACA_KEY_TYPE_SYMMETRIC = 0; + + /// DES* key - must be handled differently because of parity bits + static const int YACA_KEY_TYPE_DES = 1; + + /// Initialization Vector for symmetric algorithms + static const int YACA_KEY_TYPE_IV = 2; + + /// RSA public key + static const int YACA_KEY_TYPE_RSA_PUB = 3; + + /// RSA private key + static const int YACA_KEY_TYPE_RSA_PRIV = 4; + + /// Digital Signature Algorithm public key + static const int YACA_KEY_TYPE_DSA_PUB = 5; + + /// Digital Signature Algorithm private key + static const int YACA_KEY_TYPE_DSA_PRIV = 6; + + /// Diffie-Hellman public key + static const int YACA_KEY_TYPE_DH_PUB = 7; + + /// Diffie-Hellman private key + static const int YACA_KEY_TYPE_DH_PRIV = 8; + + /// Elliptic Curve public key (for DSA and DH) + static const int YACA_KEY_TYPE_EC_PUB = 9; + + /// Elliptic Curve private key (for DSA and DH) + static const int YACA_KEY_TYPE_EC_PRIV = 10; + + /// Digital Signature Algorithm parameters + static const int YACA_KEY_TYPE_DSA_PARAMS = 11; + + /// Diffie-Hellman parameters + static const int YACA_KEY_TYPE_DH_PARAMS = 12; + + /// Elliptic Curve parameters + static const int YACA_KEY_TYPE_EC_PARAMS = 13; +} + +/// @brief Enumeration of YACA key lengths. +/// It is possible to use arbitrary integer instead, +/// this enum values are placed here to avoid magic numbers. +/// +/// @since_tizen 3.0 +abstract class yaca_key_bit_length_e { + /// 64 bits + static const int YACA_KEY_LENGTH_IV_64BIT = 64; + + /// 128 bits + static const int YACA_KEY_LENGTH_IV_128BIT = 128; + + /// 8 bits + static const int YACA_KEY_LENGTH_UNSAFE_8BIT = 8; + + /// 40 bits + static const int YACA_KEY_LENGTH_UNSAFE_40BIT = 40; + + /// 64 bits + static const int YACA_KEY_LENGTH_UNSAFE_64BIT = 64; + + /// 80 bits + static const int YACA_KEY_LENGTH_UNSAFE_80BIT = 80; + + /// 128 bits + static const int YACA_KEY_LENGTH_UNSAFE_128BIT = 128; + + /// 192 bits + static const int YACA_KEY_LENGTH_192BIT = 192; + + /// 256 bits + static const int YACA_KEY_LENGTH_256BIT = 256; + + /// 512 bits + static const int YACA_KEY_LENGTH_512BIT = 512; + + /// 1024 bits + static const int YACA_KEY_LENGTH_1024BIT = 1024; + + /// 2048 bits + static const int YACA_KEY_LENGTH_2048BIT = 2048; + + /// 3072 bits + static const int YACA_KEY_LENGTH_3072BIT = 3072; + + /// 4096 bits + static const int YACA_KEY_LENGTH_4096BIT = 4096; +} + +/// @brief Enumeration of YACA elliptic curve types with their bit lengths. +/// It's meant to be passed or returned as a @a key_bit_len param +/// in appropriate functions when dealing with elliptic curves. +/// +/// @since_tizen 3.0 +abstract class yaca_key_bit_length_ec_e { + /// Elliptic curve prime192v1 + static const int YACA_KEY_LENGTH_EC_PRIME192V1 = 805306560; + + /// Elliptic curve prime256v1 + static const int YACA_KEY_LENGTH_EC_PRIME256V1 = 805306624; + + /// Elliptic curve secp256k1 + static const int YACA_KEY_LENGTH_EC_SECP256K1 = 824180992; + + /// Elliptic curve secp384r1 + static const int YACA_KEY_LENGTH_EC_SECP384R1 = 823132544; + + /// Elliptic curve secp521r1 + static const int YACA_KEY_LENGTH_EC_SECP521R1 = 823132681; +} + +/// @brief Enumeration of YACA DH parameters taken from RFC 5114. +/// It's meant to be passed or returned as a @a key_bit_len param +/// in appropriate functions when dealing with DH and wanting to +/// use RFC 5114 values. +/// +/// @since_tizen 3.0 +abstract class yaca_key_bit_length_dh_rfc_e { + /// RFC 5114 DH parameters 1024_160 + static const int YACA_KEY_LENGTH_DH_RFC_1024_160 = 536871936; + + /// RFC 5114 DH parameters 2048_224 + static const int YACA_KEY_LENGTH_DH_RFC_2048_224 = 553650176; + + /// RFC 5114 DH parameters 2048_256 + static const int YACA_KEY_LENGTH_DH_RFC_2048_256 = 570427392; +} + +/// @brief Enumeration of YACA message digest algorithms. +/// +/// @since_tizen 3.0 +abstract class yaca_digest_algorithm_e { + /// Message digest algorithm MD5 + static const int YACA_DIGEST_MD5 = 0; + + /// Message digest algorithm SHA1 + static const int YACA_DIGEST_SHA1 = 1; + + /// Message digest algorithm SHA2, 224bit + static const int YACA_DIGEST_SHA224 = 2; + + /// Message digest algorithm SHA2, 256bit + static const int YACA_DIGEST_SHA256 = 3; + + /// Message digest algorithm SHA2, 384bit + static const int YACA_DIGEST_SHA384 = 4; + + /// Message digest algorithm SHA2, 512bit + static const int YACA_DIGEST_SHA512 = 5; +} + +/// @brief Enumeration of YACA symmetric encryption algorithms. +/// +/// @since_tizen 3.0 +abstract class yaca_encrypt_algorithm_e { + /// AES encryption. + /// - Supported key lengths: @c 128, @c 192 and @c 256 bits. + /// - Supported block cipher modes:\n + /// #YACA_BCM_CBC,\n + /// #YACA_BCM_OFB,\n + /// #YACA_BCM_CFB,\n + /// #YACA_BCM_CFB1,\n + /// #YACA_BCM_CFB8,\n + /// #YACA_BCM_ECB,\n + /// #YACA_BCM_GCM,\n + /// #YACA_BCM_CCM,\n + /// #YACA_BCM_CTR,\n + /// #YACA_BCM_WRAP + /// - see #yaca_block_cipher_mode_e for details on additional properties (mandatory). + static const int YACA_ENCRYPT_AES = 0; + + /// DES encryption. + /// - Supported key lengths: @c 64 bits. + /// - Supported block cipher modes:\n + /// #YACA_BCM_CBC,\n + /// #YACA_BCM_OFB,\n + /// #YACA_BCM_CFB,\n + /// #YACA_BCM_CFB1,\n + /// #YACA_BCM_CFB8,\n + /// #YACA_BCM_ECB + /// - see #yaca_block_cipher_mode_e for details on additional properties (mandatory). + static const int YACA_ENCRYPT_UNSAFE_DES = 1; + + /// 3DES 2-key encryption. + /// - Supported key lengths: @c 128 bits. + /// - Supported block cipher modes:\n + /// #YACA_BCM_CBC,\n + /// #YACA_BCM_OFB,\n + /// #YACA_BCM_CFB,\n + /// #YACA_BCM_ECB + /// - see #yaca_block_cipher_mode_e for details on additional properties (mandatory). + /// - Use double DES keys to perform corresponding 2-key 3DES encryption. + static const int YACA_ENCRYPT_UNSAFE_3DES_2TDEA = 2; + + /// 3DES 3-key encryption. + /// - Supported key lengths: @c 192 bits. + /// - Supported block cipher modes:\n + /// #YACA_BCM_CBC,\n + /// #YACA_BCM_OFB,\n + /// #YACA_BCM_CFB,\n + /// #YACA_BCM_CFB1,\n + /// #YACA_BCM_CFB8,\n + /// #YACA_BCM_ECB,\n + /// #YACA_BCM_WRAP + /// - see #yaca_block_cipher_mode_e for details on additional properties (mandatory). + /// - Use triple DES keys to perform corresponding 3-key 3DES encryption. + static const int YACA_ENCRYPT_3DES_3TDEA = 3; + + /// RC2 encryption. + /// This is a variable key length cipher. + /// - Supported key lengths: 8-1024 bits in steps of 8 bits. + /// - Effective key bits property by default equals to 128 bits.\n + /// Effective key bits can be set using yaca_context_set_property() and + /// #YACA_PROPERTY_RC2_EFFECTIVE_KEY_BITS.\n + /// It can be set after yaca_encrypt_initialize() / yaca_decrypt_initialize(), and before + /// yaca_encrypt_update() / yaca_decrypt_update() in encryption / decryption operation. + /// + /// - Supported block cipher modes:\n + /// #YACA_BCM_CBC,\n + /// #YACA_BCM_OFB,\n + /// #YACA_BCM_CFB,\n + /// #YACA_BCM_ECB + /// - see #yaca_block_cipher_mode_e for details on additional properties (mandatory). + static const int YACA_ENCRYPT_UNSAFE_RC2 = 4; + + /// RC4 encryption. + /// This is a variable key length cipher. + /// - Supported key lengths: 40–2048 bits in steps of 8 bits. + /// - Initialization Vector is not used. + /// - This cipher doesn't support block cipher modes, use #YACA_BCM_NONE instead. + static const int YACA_ENCRYPT_UNSAFE_RC4 = 5; + + /// CAST5 encryption. + /// This is a variable key length cipher. + /// - Supported key lengths: 40-128 bits in steps of 8 bits. + /// - Supported block cipher modes:\n + /// #YACA_BCM_CBC,\n + /// #YACA_BCM_OFB,\n + /// #YACA_BCM_CFB,\n + /// #YACA_BCM_ECB + /// - see #yaca_block_cipher_mode_e for details on additional properties (mandatory). + static const int YACA_ENCRYPT_CAST5 = 6; +} + +/// @brief Enumeration of YACA chaining modes for block ciphers. +/// +/// @since_tizen 3.0 +abstract class yaca_block_cipher_mode_e { + /// Used when algorithm doesn't support block ciphers modes. + /// Initialization Vector is not used. + static const int YACA_BCM_NONE = 0; + + /// ECB block cipher mode. + /// Initialization Vector is not used. + /// + /// By default the input data is padded using standard block padding (#YACA_PADDING_PKCS7). + /// Padding can be disabled using yaca_context_set_property() and + /// #YACA_PROPERTY_PADDING,#YACA_PADDING_NONE, + /// then the total length of data passed until *_finalize() MUST be a multiple of block size. + /// #YACA_PROPERTY_PADDING can be set at the latest before the *_finalize() call. + static const int YACA_BCM_ECB = 1; + + /// CTR block cipher mode. + /// 128-bit Initialization Vector for AES, + /// 64-bit for other algorithms is mandatory. + static const int YACA_BCM_CTR = 2; + + /// CBC block cipher mode. + /// 128-bit Initialization Vector for AES, + /// 64-bit for other algorithms is mandatory. + /// + /// By default the input data is padded using standard block padding (#YACA_PADDING_PKCS7). + /// Padding can be disabled using yaca_context_set_property() and + /// #YACA_PROPERTY_PADDING, #YACA_PADDING_NONE, + /// then the total length of data passed until *_finalize() MUST be a multiple of block size. + /// #YACA_PROPERTY_PADDING can be set at the latest before the *_finalize() call. + static const int YACA_BCM_CBC = 3; + + /// GCM block cipher mode. + /// This is a variable Initialization Vector length mode (recommended 96-bits). + /// + /// Supported properties: + /// - #YACA_PROPERTY_GCM_TAG_LEN = GCM tag length (optional)\n + /// Supported tag lengths: @c 4, @c 8, @c 12, @c 13, @c 14, @c 15, @c 16 + /// (16 bytes tag by default).\n + /// Set after yaca_encrypt_finalize() / yaca_seal_finalize() and before + /// yaca_context_get_property(#YACA_PROPERTY_GCM_TAG) in encryption / seal operation.\n + /// The @a value should be a size_t variable.\n + /// In decryption / open operation tag length is not set.\n\n + /// + /// - #YACA_PROPERTY_GCM_TAG = GCM tag\n + /// Get after yaca_encrypt_finalize() / yaca_seal_finalize() in encryption / seal operation.\n + /// Set after yaca_decrypt_update() / yaca_open_update() and before + /// yaca_decrypt_finalize() / yaca_open_finalize() in decryption / open operation.\n\n + /// + /// - #YACA_PROPERTY_GCM_AAD = additional authentication data (optional)\n + /// Set after yaca_encrypt_initialize() / yaca_seal_initialize() and before + /// yaca_encrypt_update() / yaca_seal_update() in encryption / seal operation.\n + /// Set after yaca_decrypt_initialize() / yaca_open_initialize() and before + /// yaca_decrypt_update() / yaca_open_update() in decryption / open operation.\n\n + /// + /// @see yaca_context_set_property() + /// @see yaca_context_get_property() + static const int YACA_BCM_GCM = 4; + + /// Default CFB block cipher mode. + /// 128-bit Initialization Vector for AES, + /// 64-bit for other algorithms is mandatory. + static const int YACA_BCM_CFB = 5; + + /// 1 bit CFB block cipher mode. + /// 128-bit Initialization Vector for AES, + /// 64-bit for other algorithms is mandatory. + static const int YACA_BCM_CFB1 = 6; + + /// 8 bits CFB block cipher mode. + /// 128-bit Initialization Vector for AES, + /// 64-bit for other algorithms is mandatory. + static const int YACA_BCM_CFB8 = 7; + + /// OFB block cipher mode. + /// 128-bit Initialization Vector for AES, + /// 64-bit for other algorithms is mandatory. + static const int YACA_BCM_OFB = 8; + + /// CBC-MAC Mode (AES). + /// This is a variable Initialization Vector length mode.\n + /// Supported Initialization Vector lengths: 56-104 bits in steps of 8 bits + /// (recommended 56-bits).\n\n + /// + /// Supported properties: + /// - #YACA_PROPERTY_CCM_TAG_LEN = CCM tag length (optional)\n + /// Supported tag lengths: 4-16 bytes in steps of 2 bytes (12 bytes tag by default).\n + /// Set after yaca_encrypt_initialize() / yaca_seal_initialize() and before + /// yaca_encrypt_update() / yaca_seal_update() in encryption / seal operation.\n + /// The @a value should be a size_t variable.\n + /// In decryption / open operation tag length is not set.\n\n + /// + /// - #YACA_PROPERTY_CCM_TAG = CCM tag\n + /// Get after yaca_encrypt_finalize() / yaca_seal_finalize() in encryption / seal operation.\n + /// Set after yaca_decrypt_initialize() / yaca_open_initialize() and before + /// yaca_decrypt_update() / yaca_open_update() in decryption / open operation.\n\n + /// + /// - #YACA_PROPERTY_CCM_AAD = additional authentication data (optional)\n + /// The total plaintext length must be passed to yaca_encrypt_update() / yaca_seal_update() + /// if AAD is used.\n + /// Set after yaca_encrypt_initialize() / yaca_seal_initialize() and before + /// yaca_encrypt_update() / yaca_seal_update() in encryption / seal operation.\n + /// You can only call yaca_encrypt_update() / yaca_seal_update() once for AAD + /// and once for the plaintext.\n\n + /// + /// The total encrypted text length must be passed to yaca_decrypt_update() / + /// yaca_open_update() if AAD is used.\n + /// Set after yaca_decrypt_initialize() / yaca_open_initialize() and before + /// yaca_decrypt_update() / yaca_open_update() in decryption / open operation.\n + /// You can only call yaca_decrypt_update() / yaca_open_update() once for AAD + /// and once for the encrypted text.\n\n + /// + /// @see yaca_context_set_property() + /// @see yaca_context_get_property() + static const int YACA_BCM_CCM = 9; + + /// Used with #YACA_ENCRYPT_AES or #YACA_ENCRYPT_3DES_3TDEA to perform a key wrapping + /// (key material symmetric encryption). + /// + /// Only a single yaca_encrypt_update() / yaca_decrypt_update() is allowed. + /// + /// Usage in yaca_seal_initialize() / yaca_open_finalize() is forbidden. + /// + /// Key used to do the wrapping with #YACA_ENCRYPT_AES can be a 128-bit key, a 192-bit key, + /// or a 256-bit key.\n + /// 64-bit Initialization Vector is used.\n + /// Wrapped key can be a 128-bit key, a 192-bit key, or a 256-bit key.\n + /// #YACA_ENCRYPT_AES allows wrapping multiple keys together. + /// + /// Key used to do the wrapping with #YACA_ENCRYPT_3DES_3TDEA can be a 192-bit DES key only.\n + /// Initialization Vector is not used.\n + /// Wrapped key can be a 128-bit DES key (two-key), or a 192-bit DES key (three-key).\n + /// #YACA_ENCRYPT_3DES_3TDEA allows wrapping only one key. + static const int YACA_BCM_WRAP = 10; +} + +/// @brief Enumeration of YACA non-standard properties for algorithms. +/// +/// @since_tizen 3.0 +/// +/// @see #yaca_padding_e +abstract class yaca_property_e { + /// Padding for the encrypt/decrypt or sign/verify operation. Property type is #yaca_padding_e. + /// + /// This property can be set at the latest before the *_finalize() call. + static const int YACA_PROPERTY_PADDING = 0; + + /// GCM Additional Authentication Data. Property type is a buffer (e.g. char*) + static const int YACA_PROPERTY_GCM_AAD = 1; + + /// GCM Tag. Property type is a buffer (e.g. char*) + static const int YACA_PROPERTY_GCM_TAG = 2; + + /// GCM Tag length in bytes. Property type is size_t. + static const int YACA_PROPERTY_GCM_TAG_LEN = 3; + + /// CCM Additional Authentication Data. Property type is a buffer (e.g. char*) + static const int YACA_PROPERTY_CCM_AAD = 4; + + /// CCM Tag. Property type is a buffer (e.g. char*) + static const int YACA_PROPERTY_CCM_TAG = 5; + + /// CCM Tag length in bytes. Property type is size_t. + static const int YACA_PROPERTY_CCM_TAG_LEN = 6; + + /// RC2 effective key bits, 1-1024, 1 bit resolution. Property type is size_t. + static const int YACA_PROPERTY_RC2_EFFECTIVE_KEY_BITS = 7; +} + +/// @brief Enumeration of YACA paddings. +/// +/// @since_tizen 3.0 +abstract class yaca_padding_e { + /// No padding at all. This method assumes that the input data already has a proper length for + /// a given cryptographic operation (e.g. it has been padded by the client). Suitable for + /// symmetric encrypt/decrypt operations as well as low-level RSA operations. + static const int YACA_PADDING_NONE = 0; + + /// X9.31 padding. Suitable for RSA sign/verify operation. Not supported in low-level + /// RSA operations. + static const int YACA_PADDING_X931 = 1; + + /// PKCS #1 v1.5 padding. Suitable for RSA sign/verify and low-level RSA operations. + /// For low-level operations the input must be at least 11 bytes shorter than the key length. + static const int YACA_PADDING_PKCS1 = 2; + + /// PKCS #1 PSS padding. Suitable for RSA sign/verify operations. Not supported in low-level + /// RSA operations. + static const int YACA_PADDING_PKCS1_PSS = 3; + + /// EME-OAEP as defined in PKCS #1 v2.0 with SHA-1, MGF1 and an empty encoding parameter. + /// Suitable for low-level RSA public_encrypt/private_decrypt operations. For low-level + /// operations the input must be at least 42 bytes shorter than the key length. + static const int YACA_PADDING_PKCS1_OAEP = 4; + + /// PKCS #1 v1.5 padding with an SSL-specific modification that denotes that the party + /// is SSL3 capable. It is used for rollback attack detection in SSLv3. If during decryption it + /// turns out that both parties are using #YACA_PADDING_PKCS1_SSLV23 (both are communicating + /// using SSL2 and both are SSL3 capable) it is treated as a rollback attack and an error is + /// returned. Suitable for low-level RSA public_encrypt/private_decrypt operations. For + /// low-level operations the input must be at least 11 bytes shorter than the key length. + static const int YACA_PADDING_PKCS1_SSLV23 = 5; + + /// PKCS #7 padding. Suitable for symmetric encrypt/decrypt operation. + static const int YACA_PADDING_PKCS7 = 6; +} + +/// @brief Enumeration of YACA key derivation functions. +/// +/// @since_tizen 3.0 +abstract class yaca_kdf_e { + /// ANSI X9.42 key derivation function, + /// (shared secret derived using Diffie-Helmann key exchange protocol). + static const int YACA_KDF_X942 = 0; + + /// ANSI X9.62 key derivation function, + /// (shared secret derived using EC Diffie-Helmann key exchange protocol). + static const int YACA_KDF_X962 = 1; +} + +/// @brief Enumeration of YACA error values. +/// +/// @since_tizen 3.0 +abstract class yaca_error_e { + /// Successful + static const int YACA_ERROR_NONE = 0; + + /// Invalid function parameter + static const int YACA_ERROR_INVALID_PARAMETER = -22; + + /// Out of memory + static const int YACA_ERROR_OUT_OF_MEMORY = -12; + + /// Internal error + static const int YACA_ERROR_INTERNAL = -31653887; + + /// Data mismatch + static const int YACA_ERROR_DATA_MISMATCH = -31653886; + + /// Invalid password + static const int YACA_ERROR_INVALID_PASSWORD = -31653885; +} + +/// @brief Enumeration for calendar errors. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_error_e { + /// < Successful + static const int CALENDAR_ERROR_NONE = 0; + + /// < Out of memory + static const int CALENDAR_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid parameter + static const int CALENDAR_ERROR_INVALID_PARAMETER = -22; + + /// < Requested data does not exist + static const int CALENDAR_ERROR_NO_DATA = -61; + + /// < Operation now in progress + static const int CALENDAR_ERROR_NOW_IN_PROGRESS = -115; + + /// < Operation already in progress + static const int CALENDAR_ERROR_ALREADY_IN_PROGRESS = -114; + + /// < Operation not permitted + static const int CALENDAR_ERROR_NOT_PERMITTED = -1; + + /// < FS is full + static const int CALENDAR_ERROR_FILE_NO_SPACE = -28; + + /// < Permission denied + static const int CALENDAR_ERROR_PERMISSION_DENIED = -13; + + /// < No access to the database + static const int CALENDAR_ERROR_DB_FAILED = -33554430; + + /// < Iterator is on the last position + static const int CALENDAR_ERROR_ITERATOR_END = -33554428; + + /// < Database not found + static const int CALENDAR_ERROR_DB_RECORD_NOT_FOUND = -33554427; + + /// < Unknown IPC error + static const int CALENDAR_ERROR_IPC = -33554241; + + /// < Error from another modules + static const int CALENDAR_ERROR_SYSTEM = -33554193; + + /// < Not supported (Since 4.0) + static const int CALENDAR_ERROR_NOT_SUPPORTED = -1073741822; +} + +class __calendar_record_h extends ffi.Opaque {} + +class __calendar_filter_h extends ffi.Opaque {} + +class __calendar_list_h extends ffi.Opaque {} + +class __calendar_query_h extends ffi.Opaque {} + +class __calendar_h extends ffi.Opaque {} + +/// @brief Enumeration for the filter match type of a string. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_match_str_flag_e { + /// < Full string, case-sensitive + static const int CALENDAR_MATCH_EXACTLY = 0; + + /// < Full string, case-insensitive + static const int CALENDAR_MATCH_FULLSTRING = 1; + + /// < Sub string, case-insensitive + static const int CALENDAR_MATCH_CONTAINS = 2; + + /// < Start with, case-insensitive + static const int CALENDAR_MATCH_STARTSWITH = 3; + + /// < End with, case-insensitive + static const int CALENDAR_MATCH_ENDSWITH = 4; + + /// < IS NOT NULL + static const int CALENDAR_MATCH_EXISTS = 5; + + /// < Calendar match string flag max enum count + static const int CALENDAR_MATCH_STR_MAX = 6; +} + +/// @brief Enumeration for the filter match type of an integer. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_match_int_flag_e { + /// < '=' + static const int CALENDAR_MATCH_EQUAL = 0; + + /// < '>' + static const int CALENDAR_MATCH_GREATER_THAN = 1; + + /// < '>=' + static const int CALENDAR_MATCH_GREATER_THAN_OR_EQUAL = 2; + + /// < '<' + static const int CALENDAR_MATCH_LESS_THAN = 3; + + /// < '<=' + static const int CALENDAR_MATCH_LESS_THAN_OR_EQUAL = 4; + + /// < '<>', this flag can yield poor performance + static const int CALENDAR_MATCH_NOT_EQUAL = 5; + + /// < IS NULL + static const int CALENDAR_MATCH_NONE = 6; + + /// < Calendar match integer flag max enum count + static const int CALENDAR_MATCH_INT_MAX = 7; +} + +/// @brief Enumeration for a filter operator. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_filter_operator_e { + /// < AND + static const int CALENDAR_FILTER_OPERATOR_AND = 0; + + /// < OR + static const int CALENDAR_FILTER_OPERATOR_OR = 1; + + /// < Calendar filter operator max enum count + static const int CALENDAR_FILTER_OPERATOR_MAX = 2; +} + +/// @brief Enumeration for the calendar book type. +/// @details "OR"ing is supported. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_book_type_e { + /// < Default calendar book type + static const int CALENDAR_BOOK_TYPE_NONE = 0; + + /// < Event calendar book type + static const int CALENDAR_BOOK_TYPE_EVENT = 1; + + /// < To-do calendar book type + static const int CALENDAR_BOOK_TYPE_TODO = 2; +} + +/// @brief Enumeration for the calendar sensitivity type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_sensitivity_e { + /// < Public Sensitivity + static const int CALENDAR_SENSITIVITY_PUBLIC = 0; + + /// < Private Sensitivity + static const int CALENDAR_SENSITIVITY_PRIVATE = 1; + + /// < Confidential Sensitivity + static const int CALENDAR_SENSITIVITY_CONFIDENTIAL = 2; +} + +/// @brief Enumeration for the attendee status. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_attendee_status_e { + /// < Pending status + static const int CALENDAR_ATTENDEE_STATUS_PENDING = 0; + + /// < Accepted status + static const int CALENDAR_ATTENDEE_STATUS_ACCEPTED = 1; + + /// < Declined status + static const int CALENDAR_ATTENDEE_STATUS_DECLINED = 2; + + /// < Tentative status + static const int CALENDAR_ATTENDEE_STATUS_TENTATIVE = 3; + + /// < Delegated status + static const int CALENDAR_ATTENDEE_STATUS_DELEGATED = 4; + + /// < Completed status + static const int CALENDAR_ATTENDEE_STATUS_COMPLETED = 5; + + /// < In process status + static const int CALENDAR_ATTENDEE_STATUS_IN_PROCESS = 6; + + /// < Calendar attendee status max enum count + static const int CALENDAR_ATTENDEE_STATUS_MAX = 7; +} + +/// @brief Enumeration for the attendee role. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_attendee_role_e { + /// < Participation is required + static const int CALENDAR_ATTENDEE_ROLE_REQ_PARTICIPANT = 0; + + /// < Accepted status + static const int CALENDAR_ATTENDEE_ROLE_OPT_PARTICIPANT = 1; + + /// < Non-Participant + static const int CALENDAR_ATTENDEE_ROLE_NON_PARTICIPANT = 2; + + /// < Chairperson + static const int CALENDAR_ATTENDEE_ROLE_CHAIR = 3; + + /// < Calendar attendee role max enum count + static const int CALENDAR_ATTENDEE_ROLE_MAX = 4; +} + +/// @brief Enumeration for the attendee cutype. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_attendee_cutyep_e { + /// < Individual cutype + static const int CALENDAR_ATTENDEE_CUTYPE_INDIVIDUAL = 0; + + /// < Group cutype + static const int CALENDAR_ATTENDEE_CUTYPE_GROUP = 1; + + /// < Resource cutype + static const int CALENDAR_ATTENDEE_CUTYPE_RESOURCE = 2; + + /// < Room cutype + static const int CALENDAR_ATTENDEE_CUTYPE_ROOM = 3; + + /// < Unknown cutype + static const int CALENDAR_ATTENDEE_CUTYPE_UNKNOWN = 4; + + /// < Calendar attendee cutype max enum count + static const int CALENDAR_ATTENDEE_CUTYPE_MAX = 5; +} + +/// @brief Enumeration for the alarm time unit type of an event, such as minutes, hours, days, and so on. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_alarm_time_unit_type_e { + /// < No reminder set + static const int CALENDAR_ALARM_NONE = -1; + + /// < Specific in seconds + static const int CALENDAR_ALARM_TIME_UNIT_SPECIFIC = 1; + + /// < Alarm time unit in minutes + static const int CALENDAR_ALARM_TIME_UNIT_MINUTE = 60; + + /// < Alarm time unit in hours + static const int CALENDAR_ALARM_TIME_UNIT_HOUR = 3600; + + /// < Alarm time unit in days + static const int CALENDAR_ALARM_TIME_UNIT_DAY = 86400; + + /// < Alarm time unit in weeks + static const int CALENDAR_ALARM_TIME_UNIT_WEEK = 604800; +} + +/// @brief Enumeration for the alarm action. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_alarm_action_e { + /// < Audio action + static const int CALENDAR_ALARM_ACTION_AUDIO = 0; + + /// < Display action + static const int CALENDAR_ALARM_ACTION_DISPLAY = 1; + + /// < Email action + static const int CALENDAR_ALARM_ACTION_EMAIL = 2; + + /// < Calendar alarm action max enum count + static const int CALENDAR_ALARM_ACTION_MAX = 3; +} + +/// @brief Enumeration for the frequency of an event's recurrence. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_recurrence_frequency_e { + /// < No recurrence event + static const int CALENDAR_RECURRENCE_NONE = 0; + + /// < An event occurs every day + static const int CALENDAR_RECURRENCE_DAILY = 1; + + /// < An event occurs on the same day of every week. According to the week flag, the event will recur every day of the week + static const int CALENDAR_RECURRENCE_WEEKLY = 2; + + /// < An event occurs on the same day of every month + static const int CALENDAR_RECURRENCE_MONTHLY = 3; + + /// < An event occurs on the same day of every year + static const int CALENDAR_RECURRENCE_YEARLY = 4; +} + +/// @brief Enumeration for the event status. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_event_status_e { + /// < No status + static const int CALENDAR_EVENT_STATUS_NONE = 1; + + /// < The event is tentative + static const int CALENDAR_EVENT_STATUS_TENTATIVE = 2; + + /// < The event is confirmed + static const int CALENDAR_EVENT_STATUS_CONFIRMED = 4; + + /// < The event is canceled + static const int CALENDAR_EVENT_STATUS_CANCELLED = 8; +} + +/// @brief Enumeration for the busy status of an event. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_event_busy_status_e { + /// < The free status + static const int CALENDAR_EVENT_BUSY_STATUS_FREE = 0; + + /// < The busy status + static const int CALENDAR_EVENT_BUSY_STATUS_BUSY = 1; + + /// < The unavailable status + static const int CALENDAR_EVENT_BUSY_STATUS_UNAVAILABLE = 2; + + /// < The tentative status + static const int CALENDAR_EVENT_BUSY_STATUS_TENTATIVE = 3; +} + +/// @brief Enumeration for the calendar event item's priority. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_event_priority_e { + /// < No priority + static const int CALENDAR_EVENT_PRIORITY_NONE = 1; + + /// < Low priority + static const int CALENDAR_EVENT_PRIORITY_LOW = 8; + + /// < Normal priority + static const int CALENDAR_EVENT_PRIORITY_NORMAL = 4; + + /// < High priority + static const int CALENDAR_EVENT_PRIORITY_HIGH = 2; +} + +/// @brief Enumeration for the calendar to-do item's priority. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_todo_priority_e { + /// < No priority + static const int CALENDAR_TODO_PRIORITY_NONE = 1; + + /// < Low priority + static const int CALENDAR_TODO_PRIORITY_LOW = 8; + + /// < Normal priority + static const int CALENDAR_TODO_PRIORITY_NORMAL = 4; + + /// < High priority + static const int CALENDAR_TODO_PRIORITY_HIGH = 2; +} + +/// @brief Enumeration for the status of a to-do. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_todo_status_e { + /// < No status + static const int CALENDAR_TODO_STATUS_NONE = 256; + + /// < Needs action status + static const int CALENDAR_TODO_STATUS_NEEDS_ACTION = 512; + + /// < Completed status + static const int CALENDAR_TODO_STATUS_COMPLETED = 1024; + + /// < Work in process status + static const int CALENDAR_TODO_STATUS_IN_PROCESS = 2048; + + /// < Canceled status + static const int CALENDAR_TODO_STATUS_CANCELED = 4096; +} + +/// @brief Enumeration for the time type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_time_type_e { + /// < Unix time + static const int CALENDAR_TIME_UTIME = 0; + + /// < Local time + static const int CALENDAR_TIME_LOCALTIME = 1; +} + +/// @brief Enumeration for the range type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_range_type_e { + /// < Range until + static const int CALENDAR_RANGE_UNTIL = 0; + + /// < Range count + static const int CALENDAR_RANGE_COUNT = 1; + + /// < No range + static const int CALENDAR_RANGE_NONE = 2; +} + +/// @brief Enumeration for the system type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_system_type_e { + /// < Locale's default calendar + static const int CALENDAR_SYSTEM_NONE = 0; + + /// < Locale's default calendar + static const int CALENDAR_SYSTEM_GREGORIAN = 1; + + /// < East asian lunisolar calendar + static const int CALENDAR_SYSTEM_EAST_ASIAN_LUNISOLAR = 2; +} + +/// @brief Enumeration for the meeting status. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_meeting_status_e { + /// < No meeting + static const int CALENDAR_MEETING_STATUS_NOTMEETING = 0; + + /// < Meeting exists + static const int CALENDAR_MEETING_STATUS_MEETING = 1; + + /// < Meeting received + static const int CALENDAR_MEETING_STATUS_RECEIVED = 2; + + /// < Meeting canceled + static const int CALENDAR_MEETING_STATUS_CANCELED = 3; +} + +/// @brief Enumeration for weekdays. +/// @details Same value as UCalendarDaysOfWeek in ICU. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_days_of_week_e { + /// < Sunday + static const int CALENDAR_SUNDAY = 1; + + /// < Monday + static const int CALENDAR_MONDAY = 2; + + /// < Tuesday + static const int CALENDAR_TUESDAY = 3; + + /// < Wednesday + static const int CALENDAR_WEDNESDAY = 4; + + /// < Thursday + static const int CALENDAR_THURSDAY = 5; + + /// < Friday + static const int CALENDAR_FRIDAY = 6; + + /// < Saturday + static const int CALENDAR_SATURDAY = 7; +} + +/// @brief Enumeration for the modified status of a record. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_record_modified_status_e { + /// < The record is inserted + static const int CALENDAR_RECORD_MODIFIED_STATUS_INSERTED = 0; + + /// < The record is updated + static const int CALENDAR_RECORD_MODIFIED_STATUS_UPDATED = 1; + + /// < The record is deleted + static const int CALENDAR_RECORD_MODIFIED_STATUS_DELETED = 2; +} + +/// @brief The structure of time. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +class calendar_time_s extends ffi.Opaque {} + +/// @brief Enumeration for the type of a record. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_record_type_e { + /// < No record type + static const int CALENDAR_RECORD_TYPE_NONE = 0; + + /// < Book type + static const int CALENDAR_RECORD_TYPE_CALENDAR_BOOK = 1; + + /// < Event type + static const int CALENDAR_RECORD_TYPE_EVENT = 2; + + /// < Todo type + static const int CALENDAR_RECORD_TYPE_TODO = 3; +} + +/// @brief Enumeration for the book mode. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_book_mode_e { + /// < All modules can read and write records of this calendar_book + static const int CALENDAR_BOOK_MODE_NONE = 0; + + /// < All modules can only read records of this calendar book + static const int CALENDAR_BOOK_MODE_RECORD_READONLY = 1; +} + +/// @brief Enumeration for the sync event type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @elseif TV 4.0 @endif +abstract class calendar_book_sync_event_type_e { + /// < This book would not be synced to others except me + static const int CALENDAR_BOOK_SYNC_EVENT_FOR_ME = 0; + + /// < This book would be synced to everyone and deleted events would be deleted on time + static const int CALENDAR_BOOK_SYNC_EVENT_FOR_EVERY_AND_DELETE = 1; + + /// < This book would be synced to everyone but deleted events would be retained. Deleted events are removed by calendar_db_clean_after_sync() API + static const int CALENDAR_BOOK_SYNC_EVENT_FOR_EVERY_AND_REMAIN = 2; +} + +class _calendar_book_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int uid; + + @ffi.Uint32() + external int name; + + @ffi.Uint32() + external int description; + + @ffi.Uint32() + external int color; + + @ffi.Uint32() + external int location; + + @ffi.Uint32() + external int visibility; + + @ffi.Uint32() + external int sync_event; + + @ffi.Uint32() + external int account_id; + + @ffi.Uint32() + external int store_type; + + @ffi.Uint32() + external int sync_data1; + + @ffi.Uint32() + external int sync_data2; + + @ffi.Uint32() + external int sync_data3; + + @ffi.Uint32() + external int sync_data4; + + @ffi.Uint32() + external int mode; +} + +class _calendar_event_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int calendar_book_id; + + @ffi.Uint32() + external int summary; + + @ffi.Uint32() + external int description; + + @ffi.Uint32() + external int location; + + @ffi.Uint32() + external int categories; + + @ffi.Uint32() + external int exdate; + + @ffi.Uint32() + external int event_status; + + @ffi.Uint32() + external int priority; + + @ffi.Uint32() + external int timezone; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int busy_status; + + @ffi.Uint32() + external int sensitivity; + + @ffi.Uint32() + external int uid; + + @ffi.Uint32() + external int organizer_name; + + @ffi.Uint32() + external int organizer_email; + + @ffi.Uint32() + external int meeting_status; + + @ffi.Uint32() + external int original_event_id; + + @ffi.Uint32() + external int latitude; + + @ffi.Uint32() + external int longitude; + + @ffi.Uint32() + external int email_id; + + @ffi.Uint32() + external int created_time; + + @ffi.Uint32() + external int last_modified_time; + + @ffi.Uint32() + external int is_deleted; + + @ffi.Uint32() + external int freq; + + @ffi.Uint32() + external int range_type; + + @ffi.Uint32() + external int until_time; + + @ffi.Uint32() + external int count; + + @ffi.Uint32() + external int interval; + + @ffi.Uint32() + external int bysecond; + + @ffi.Uint32() + external int byminute; + + @ffi.Uint32() + external int byhour; + + @ffi.Uint32() + external int byday; + + @ffi.Uint32() + external int bymonthday; + + @ffi.Uint32() + external int byyearday; + + @ffi.Uint32() + external int byweekno; + + @ffi.Uint32() + external int bymonth; + + @ffi.Uint32() + external int bysetpos; + + @ffi.Uint32() + external int wkst; + + @ffi.Uint32() + external int recurrence_id; + + @ffi.Uint32() + external int rdate; + + @ffi.Uint32() + external int has_attendee; + + @ffi.Uint32() + external int has_alarm; + + @ffi.Uint32() + external int calendar_system_type; + + @ffi.Uint32() + external int sync_data1; + + @ffi.Uint32() + external int sync_data2; + + @ffi.Uint32() + external int sync_data3; + + @ffi.Uint32() + external int sync_data4; + + @ffi.Uint32() + external int start_time; + + @ffi.Uint32() + external int start_tzid; + + @ffi.Uint32() + external int end_time; + + @ffi.Uint32() + external int end_tzid; + + @ffi.Uint32() + external int calendar_alarm; + + @ffi.Uint32() + external int calendar_attendee; + + @ffi.Uint32() + external int exception; + + @ffi.Uint32() + external int extended; + + @ffi.Uint32() + external int is_allday; + + @ffi.Uint32() + external int link_count; + + @ffi.Uint32() + external int link_base_id; +} + +class _calendar_todo_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int calendar_book_id; + + @ffi.Uint32() + external int summary; + + @ffi.Uint32() + external int description; + + @ffi.Uint32() + external int location; + + @ffi.Uint32() + external int categories; + + @ffi.Uint32() + external int todo_status; + + @ffi.Uint32() + external int priority; + + @ffi.Uint32() + external int sensitivity; + + @ffi.Uint32() + external int uid; + + @ffi.Uint32() + external int latitude; + + @ffi.Uint32() + external int longitude; + + @ffi.Uint32() + external int created_time; + + @ffi.Uint32() + external int last_modified_time; + + @ffi.Uint32() + external int completed_time; + + @ffi.Uint32() + external int progress; + + @ffi.Uint32() + external int is_deleted; + + @ffi.Uint32() + external int freq; + + @ffi.Uint32() + external int range_type; + + @ffi.Uint32() + external int until_time; + + @ffi.Uint32() + external int count; + + @ffi.Uint32() + external int interval; + + @ffi.Uint32() + external int bysecond; + + @ffi.Uint32() + external int byminute; + + @ffi.Uint32() + external int byhour; + + @ffi.Uint32() + external int byday; + + @ffi.Uint32() + external int bymonthday; + + @ffi.Uint32() + external int byyearday; + + @ffi.Uint32() + external int byweekno; + + @ffi.Uint32() + external int bymonth; + + @ffi.Uint32() + external int bysetpos; + + @ffi.Uint32() + external int wkst; + + @ffi.Uint32() + external int has_alarm; + + @ffi.Uint32() + external int sync_data1; + + @ffi.Uint32() + external int sync_data2; + + @ffi.Uint32() + external int sync_data3; + + @ffi.Uint32() + external int sync_data4; + + @ffi.Uint32() + external int start_time; + + @ffi.Uint32() + external int start_tzid; + + @ffi.Uint32() + external int due_time; + + @ffi.Uint32() + external int due_tzid; + + @ffi.Uint32() + external int calendar_alarm; + + @ffi.Uint32() + external int organizer_name; + + @ffi.Uint32() + external int organizer_email; + + @ffi.Uint32() + external int has_attendee; + + @ffi.Uint32() + external int calendar_attendee; + + @ffi.Uint32() + external int extended; + + @ffi.Uint32() + external int is_allday; +} + +class _calendar_timezone_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int calendar_book_id; + + @ffi.Uint32() + external int tz_offset_from_gmt; + + @ffi.Uint32() + external int standard_name; + + @ffi.Uint32() + external int standard_start_month; + + @ffi.Uint32() + external int standard_start_position_of_week; + + @ffi.Uint32() + external int standard_start_day; + + @ffi.Uint32() + external int standard_start_hour; + + @ffi.Uint32() + external int standard_bias; + + @ffi.Uint32() + external int day_light_name; + + @ffi.Uint32() + external int day_light_start_month; + + @ffi.Uint32() + external int day_light_start_position_of_week; + + @ffi.Uint32() + external int day_light_start_day; + + @ffi.Uint32() + external int day_light_start_hour; + + @ffi.Uint32() + external int day_light_bias; +} + +class _calendar_attendee_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int parent_id; + + @ffi.Uint32() + external int number; + + @ffi.Uint32() + external int cutype; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int uid; + + @ffi.Uint32() + external int group; + + @ffi.Uint32() + external int email; + + @ffi.Uint32() + external int role; + + @ffi.Uint32() + external int status; + + @ffi.Uint32() + external int rsvp; + + @ffi.Uint32() + external int delegatee_uri; + + @ffi.Uint32() + external int delegator_uri; + + @ffi.Uint32() + external int name; + + @ffi.Uint32() + external int member; +} + +class _calendar_alarm_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int parent_id; + + @ffi.Uint32() + external int tick; + + @ffi.Uint32() + external int tick_unit; + + @ffi.Uint32() + external int description; + + @ffi.Uint32() + external int summary; + + @ffi.Uint32() + external int action; + + @ffi.Uint32() + external int attach; + + @ffi.Uint32() + external int alarm_time; +} + +class _calendar_updated_info_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int calendar_book_id; + + @ffi.Uint32() + external int modified_status; + + @ffi.Uint32() + external int version; +} + +class _calendar_event_calendar_book_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int event_id; + + @ffi.Uint32() + external int calendar_book_id; + + @ffi.Uint32() + external int summary; + + @ffi.Uint32() + external int description; + + @ffi.Uint32() + external int location; + + @ffi.Uint32() + external int categories; + + @ffi.Uint32() + external int exdate; + + @ffi.Uint32() + external int event_status; + + @ffi.Uint32() + external int priority; + + @ffi.Uint32() + external int timezone; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int busy_status; + + @ffi.Uint32() + external int sensitivity; + + @ffi.Uint32() + external int uid; + + @ffi.Uint32() + external int organizer_name; + + @ffi.Uint32() + external int organizer_email; + + @ffi.Uint32() + external int meeting_status; + + @ffi.Uint32() + external int original_event_id; + + @ffi.Uint32() + external int latitude; + + @ffi.Uint32() + external int longitude; + + @ffi.Uint32() + external int email_id; + + @ffi.Uint32() + external int created_time; + + @ffi.Uint32() + external int last_modified_time; + + @ffi.Uint32() + external int freq; + + @ffi.Uint32() + external int range_type; + + @ffi.Uint32() + external int until_time; + + @ffi.Uint32() + external int count; + + @ffi.Uint32() + external int interval; + + @ffi.Uint32() + external int bysecond; + + @ffi.Uint32() + external int byminute; + + @ffi.Uint32() + external int byhour; + + @ffi.Uint32() + external int byday; + + @ffi.Uint32() + external int bymonthday; + + @ffi.Uint32() + external int byyearday; + + @ffi.Uint32() + external int byweekno; + + @ffi.Uint32() + external int bymonth; + + @ffi.Uint32() + external int bysetpos; + + @ffi.Uint32() + external int wkst; + + @ffi.Uint32() + external int recurrence_id; + + @ffi.Uint32() + external int rdate; + + @ffi.Uint32() + external int has_attendee; + + @ffi.Uint32() + external int has_alarm; + + @ffi.Uint32() + external int calendar_system_type; + + @ffi.Uint32() + external int sync_data1; + + @ffi.Uint32() + external int sync_data2; + + @ffi.Uint32() + external int sync_data3; + + @ffi.Uint32() + external int sync_data4; + + @ffi.Uint32() + external int start_time; + + @ffi.Uint32() + external int start_tzid; + + @ffi.Uint32() + external int end_time; + + @ffi.Uint32() + external int end_tzid; + + @ffi.Uint32() + external int is_allday; + + @ffi.Uint32() + external int calendar_book_visibility; + + @ffi.Uint32() + external int calendar_book_account_id; +} + +class _calendar_todo_calendar_book_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int todo_id; + + @ffi.Uint32() + external int calendar_book_id; + + @ffi.Uint32() + external int summary; + + @ffi.Uint32() + external int description; + + @ffi.Uint32() + external int location; + + @ffi.Uint32() + external int categories; + + @ffi.Uint32() + external int todo_status; + + @ffi.Uint32() + external int priority; + + @ffi.Uint32() + external int sensitivity; + + @ffi.Uint32() + external int uid; + + @ffi.Uint32() + external int latitude; + + @ffi.Uint32() + external int longitude; + + @ffi.Uint32() + external int created_time; + + @ffi.Uint32() + external int last_modified_time; + + @ffi.Uint32() + external int completed_time; + + @ffi.Uint32() + external int progress; + + @ffi.Uint32() + external int freq; + + @ffi.Uint32() + external int range_type; + + @ffi.Uint32() + external int until_time; + + @ffi.Uint32() + external int count; + + @ffi.Uint32() + external int interval; + + @ffi.Uint32() + external int bysecond; + + @ffi.Uint32() + external int byminute; + + @ffi.Uint32() + external int byhour; + + @ffi.Uint32() + external int byday; + + @ffi.Uint32() + external int bymonthday; + + @ffi.Uint32() + external int byyearday; + + @ffi.Uint32() + external int byweekno; + + @ffi.Uint32() + external int bymonth; + + @ffi.Uint32() + external int bysetpos; + + @ffi.Uint32() + external int wkst; + + @ffi.Uint32() + external int has_alarm; + + @ffi.Uint32() + external int sync_data1; + + @ffi.Uint32() + external int sync_data2; + + @ffi.Uint32() + external int sync_data3; + + @ffi.Uint32() + external int sync_data4; + + @ffi.Uint32() + external int start_time; + + @ffi.Uint32() + external int start_tzid; + + @ffi.Uint32() + external int due_time; + + @ffi.Uint32() + external int due_tzid; + + @ffi.Uint32() + external int organizer_name; + + @ffi.Uint32() + external int organizer_email; + + @ffi.Uint32() + external int has_attendee; + + @ffi.Uint32() + external int is_allday; + + @ffi.Uint32() + external int calendar_book_visibility; + + @ffi.Uint32() + external int calendar_book_account_id; +} + +class _calendar_event_calendar_book_attendee_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int event_id; + + @ffi.Uint32() + external int calendar_book_id; + + @ffi.Uint32() + external int summary; + + @ffi.Uint32() + external int description; + + @ffi.Uint32() + external int location; + + @ffi.Uint32() + external int categories; + + @ffi.Uint32() + external int exdate; + + @ffi.Uint32() + external int event_status; + + @ffi.Uint32() + external int priority; + + @ffi.Uint32() + external int timezone; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int busy_status; + + @ffi.Uint32() + external int sensitivity; + + @ffi.Uint32() + external int uid; + + @ffi.Uint32() + external int organizer_name; + + @ffi.Uint32() + external int organizer_email; + + @ffi.Uint32() + external int meeting_status; + + @ffi.Uint32() + external int original_event_id; + + @ffi.Uint32() + external int latitude; + + @ffi.Uint32() + external int longitude; + + @ffi.Uint32() + external int email_id; + + @ffi.Uint32() + external int created_time; + + @ffi.Uint32() + external int last_modified_time; + + @ffi.Uint32() + external int freq; + + @ffi.Uint32() + external int range_type; + + @ffi.Uint32() + external int until_time; + + @ffi.Uint32() + external int count; + + @ffi.Uint32() + external int interval; + + @ffi.Uint32() + external int bysecond; + + @ffi.Uint32() + external int byminute; + + @ffi.Uint32() + external int byhour; + + @ffi.Uint32() + external int byday; + + @ffi.Uint32() + external int bymonthday; + + @ffi.Uint32() + external int byyearday; + + @ffi.Uint32() + external int byweekno; + + @ffi.Uint32() + external int bymonth; + + @ffi.Uint32() + external int bysetpos; + + @ffi.Uint32() + external int wkst; + + @ffi.Uint32() + external int recurrence_id; + + @ffi.Uint32() + external int rdate; + + @ffi.Uint32() + external int has_attendee; + + @ffi.Uint32() + external int has_alarm; + + @ffi.Uint32() + external int calendar_system_type; + + @ffi.Uint32() + external int sync_data1; + + @ffi.Uint32() + external int sync_data2; + + @ffi.Uint32() + external int sync_data3; + + @ffi.Uint32() + external int sync_data4; + + @ffi.Uint32() + external int start_time; + + @ffi.Uint32() + external int start_tzid; + + @ffi.Uint32() + external int end_time; + + @ffi.Uint32() + external int end_tzid; + + @ffi.Uint32() + external int is_allday; + + @ffi.Uint32() + external int calendar_book_visibility; + + @ffi.Uint32() + external int calendar_book_account_id; + + @ffi.Uint32() + external int attendee_email; + + @ffi.Uint32() + external int attendee_name; + + @ffi.Uint32() + external int attendee_member; +} + +class _calendar_instance_utime_calendar_book_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int event_id; + + @ffi.Uint32() + external int start_time; + + @ffi.Uint32() + external int end_time; + + @ffi.Uint32() + external int summary; + + @ffi.Uint32() + external int location; + + @ffi.Uint32() + external int calendar_book_id; + + @ffi.Uint32() + external int description; + + @ffi.Uint32() + external int busy_status; + + @ffi.Uint32() + external int event_status; + + @ffi.Uint32() + external int priority; + + @ffi.Uint32() + external int sensitivity; + + @ffi.Uint32() + external int has_rrule; + + @ffi.Uint32() + external int latitude; + + @ffi.Uint32() + external int longitude; + + @ffi.Uint32() + external int has_alarm; + + @ffi.Uint32() + external int original_event_id; + + @ffi.Uint32() + external int calendar_book_visibility; + + @ffi.Uint32() + external int calendar_book_account_id; + + @ffi.Uint32() + external int last_modified_time; + + @ffi.Uint32() + external int sync_data1; +} + +class _calendar_instance_localtime_calendar_book_property_ids + extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int event_id; + + @ffi.Uint32() + external int start_time; + + @ffi.Uint32() + external int end_time; + + @ffi.Uint32() + external int summary; + + @ffi.Uint32() + external int location; + + @ffi.Uint32() + external int calendar_book_id; + + @ffi.Uint32() + external int description; + + @ffi.Uint32() + external int busy_status; + + @ffi.Uint32() + external int event_status; + + @ffi.Uint32() + external int priority; + + @ffi.Uint32() + external int sensitivity; + + @ffi.Uint32() + external int has_rrule; + + @ffi.Uint32() + external int latitude; + + @ffi.Uint32() + external int longitude; + + @ffi.Uint32() + external int has_alarm; + + @ffi.Uint32() + external int original_event_id; + + @ffi.Uint32() + external int calendar_book_visibility; + + @ffi.Uint32() + external int calendar_book_account_id; + + @ffi.Uint32() + external int last_modified_time; + + @ffi.Uint32() + external int sync_data1; + + @ffi.Uint32() + external int is_allday; +} + +class _calendar_instance_utime_calendar_book_extended_property_ids + extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int event_id; + + @ffi.Uint32() + external int start_time; + + @ffi.Uint32() + external int end_time; + + @ffi.Uint32() + external int summary; + + @ffi.Uint32() + external int location; + + @ffi.Uint32() + external int calendar_book_id; + + @ffi.Uint32() + external int description; + + @ffi.Uint32() + external int busy_status; + + @ffi.Uint32() + external int event_status; + + @ffi.Uint32() + external int priority; + + @ffi.Uint32() + external int sensitivity; + + @ffi.Uint32() + external int has_rrule; + + @ffi.Uint32() + external int latitude; + + @ffi.Uint32() + external int longitude; + + @ffi.Uint32() + external int has_alarm; + + @ffi.Uint32() + external int original_event_id; + + @ffi.Uint32() + external int calendar_book_visibility; + + @ffi.Uint32() + external int calendar_book_account_id; + + @ffi.Uint32() + external int last_modified_time; + + @ffi.Uint32() + external int sync_data1; + + @ffi.Uint32() + external int organizer_name; + + @ffi.Uint32() + external int categories; + + @ffi.Uint32() + external int has_attendee; + + @ffi.Uint32() + external int sync_data2; + + @ffi.Uint32() + external int sync_data3; + + @ffi.Uint32() + external int sync_data4; +} + +class _calendar_instance_localtime_calendar_book_extended_property_ids + extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int event_id; + + @ffi.Uint32() + external int start_time; + + @ffi.Uint32() + external int end_time; + + @ffi.Uint32() + external int summary; + + @ffi.Uint32() + external int location; + + @ffi.Uint32() + external int calendar_book_id; + + @ffi.Uint32() + external int description; + + @ffi.Uint32() + external int busy_status; + + @ffi.Uint32() + external int event_status; + + @ffi.Uint32() + external int priority; + + @ffi.Uint32() + external int sensitivity; + + @ffi.Uint32() + external int has_rrule; + + @ffi.Uint32() + external int latitude; + + @ffi.Uint32() + external int longitude; + + @ffi.Uint32() + external int has_alarm; + + @ffi.Uint32() + external int original_event_id; + + @ffi.Uint32() + external int calendar_book_visibility; + + @ffi.Uint32() + external int calendar_book_account_id; + + @ffi.Uint32() + external int last_modified_time; + + @ffi.Uint32() + external int sync_data1; + + @ffi.Uint32() + external int organizer_name; + + @ffi.Uint32() + external int categories; + + @ffi.Uint32() + external int has_attendee; + + @ffi.Uint32() + external int is_allday; + + @ffi.Uint32() + external int sync_data2; + + @ffi.Uint32() + external int sync_data3; + + @ffi.Uint32() + external int sync_data4; +} + +class _calendar_extended_property_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int record_id; + + @ffi.Uint32() + external int record_type; + + @ffi.Uint32() + external int key; + + @ffi.Uint32() + external int value; +} + +/// @brief Enumeration for contacts errors. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_error_e { + /// < Successful + static const int CONTACTS_ERROR_NONE = 0; + + /// < Out of memory + static const int CONTACTS_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid parameter + static const int CONTACTS_ERROR_INVALID_PARAMETER = -22; + + /// < FS Full + static const int CONTACTS_ERROR_FILE_NO_SPACE = -28; + + /// < Permission denied + static const int CONTACTS_ERROR_PERMISSION_DENIED = -13; + + /// < Not supported + static const int CONTACTS_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Requested data does not exist + static const int CONTACTS_ERROR_NO_DATA = -61; + + /// < Database table locked or file locked + static const int CONTACTS_ERROR_DB_LOCKED = -33619839; + + /// < Unknown DB error + static const int CONTACTS_ERROR_DB = -33619809; + + /// < IPC server is not available + static const int CONTACTS_ERROR_IPC_NOT_AVALIABLE = -33619791; + + /// < Unknown IPC error + static const int CONTACTS_ERROR_IPC = -33619777; + + /// < Internal system module error + static const int CONTACTS_ERROR_SYSTEM = -33619729; + + /// < Implementation Error, Temporary Use + static const int CONTACTS_ERROR_INTERNAL = -33619713; +} + +class __contacts_record_h extends ffi.Opaque {} + +class __contacts_filter_h extends ffi.Opaque {} + +class __contacts_list_h extends ffi.Opaque {} + +class __contacts_query_h extends ffi.Opaque {} + +class __contacts_h extends ffi.Opaque {} + +/// @brief Enumeration for contacts data type. +/// @since_tizen 3.0 +abstract class contacts_data_type_e { + static const int CONTACTS_DATA_TYPE_NAME = 1; + static const int CONTACTS_DATA_TYPE_POSTAL = 2; + static const int CONTACTS_DATA_TYPE_MESSENGER = 3; + static const int CONTACTS_DATA_TYPE_URL = 4; + static const int CONTACTS_DATA_TYPE_EVENT = 5; + static const int CONTACTS_DATA_TYPE_COMPANY = 6; + static const int CONTACTS_DATA_TYPE_NICKNAME = 7; + static const int CONTACTS_DATA_TYPE_NUMBER = 8; + static const int CONTACTS_DATA_TYPE_EMAIL = 9; + static const int CONTACTS_DATA_TYPE_PROFILE = 10; + static const int CONTACTS_DATA_TYPE_RELATIONSHIP = 11; + static const int CONTACTS_DATA_TYPE_NOTE = 12; + static const int CONTACTS_DATA_TYPE_IMAGE = 13; + static const int CONTACTS_DATA_TYPE_SIP = 14; + static const int CONTACTS_DATA_TYPE_EXTENSION = 100; +} + +/// @brief Enumeration for contacts number type. +/// @details The number can be made with a set of values by specifying one or more values. +/// Example : CTS_NUM_TYPE_HOME|CTS_NUM_TYPE_VOICE +/// Exceptionally, CTS_NUM_TYPE_CUSTOM is exclusive. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_number_type_e { + /// < Other number type + static const int CONTACTS_NUMBER_TYPE_OTHER = 0; + + /// < Custom number type + static const int CONTACTS_NUMBER_TYPE_CUSTOM = 1; + + /// < A telephone number associated with a residence + static const int CONTACTS_NUMBER_TYPE_HOME = 2; + + /// < A telephone number associated with a place of work + static const int CONTACTS_NUMBER_TYPE_WORK = 4; + + /// < A voice telephone number + static const int CONTACTS_NUMBER_TYPE_VOICE = 8; + + /// < A facsimile telephone number + static const int CONTACTS_NUMBER_TYPE_FAX = 16; + + /// < The telephone number has voice messaging support + static const int CONTACTS_NUMBER_TYPE_MSG = 32; + + /// < A cellular telephone number + static const int CONTACTS_NUMBER_TYPE_CELL = 64; + + /// < A paging device telephone number + static const int CONTACTS_NUMBER_TYPE_PAGER = 128; + + /// < A bulletin board system telephone number + static const int CONTACTS_NUMBER_TYPE_BBS = 256; + + /// < A MODEM connected telephone number + static const int CONTACTS_NUMBER_TYPE_MODEM = 512; + + /// < A car-phone telephone number + static const int CONTACTS_NUMBER_TYPE_CAR = 1024; + + /// < An ISDN service telephone number + static const int CONTACTS_NUMBER_TYPE_ISDN = 2048; + + /// < A video conferencing telephone number + static const int CONTACTS_NUMBER_TYPE_VIDEO = 4096; + + /// < A personal communication services telephone number + static const int CONTACTS_NUMBER_TYPE_PCS = 8192; + + /// < A company main number + static const int CONTACTS_NUMBER_TYPE_COMPANY_MAIN = 16384; + + /// < A radio phone number + static const int CONTACTS_NUMBER_TYPE_RADIO = 32768; + + /// < An additional type for main + static const int CONTACTS_NUMBER_TYPE_MAIN = 536870912; + + /// < An additional type for assistant + static const int CONTACTS_NUMBER_TYPE_ASSISTANT = 1073741824; +} + +/// @brief Enumeration for Contact email type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_email_type_e { + /// < Other email type + static const int CONTACTS_EMAIL_TYPE_OTHER = 0; + + /// < Custom email type + static const int CONTACTS_EMAIL_TYPE_CUSTOM = 1; + + /// < An email address associated with a residence + static const int CONTACTS_EMAIL_TYPE_HOME = 2; + + /// < An email address associated with a place of work + static const int CONTACTS_EMAIL_TYPE_WORK = 4; + + /// < A mobile email address + static const int CONTACTS_EMAIL_TYPE_MOBILE = 8; +} + +/// @brief Enumeration for Contact company type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_company_type_e { + /// < Other company type + static const int CONTACTS_COMPANY_TYPE_OTHER = 0; + + /// < Custom company type + static const int CONTACTS_COMPANY_TYPE_CUSTOM = 1; + + /// < Work company type + static const int CONTACTS_COMPANY_TYPE_WORK = 2; +} + +/// @brief Enumeration for Contact address type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_address_type_e { + /// < Other address type + static const int CONTACTS_ADDRESS_TYPE_OTHER = 0; + + /// < A delivery address for a residence + static const int CONTACTS_ADDRESS_TYPE_CUSTOM = 1; + + /// < A delivery address for a residence + static const int CONTACTS_ADDRESS_TYPE_HOME = 2; + + /// < A delivery address for a place of work + static const int CONTACTS_ADDRESS_TYPE_WORK = 4; + + /// < A domestic delivery address + static const int CONTACTS_ADDRESS_TYPE_DOM = 8; + + /// < An international delivery address + static const int CONTACTS_ADDRESS_TYPE_INTL = 16; + + /// < A postal delivery address + static const int CONTACTS_ADDRESS_TYPE_POSTAL = 32; + + /// < A parcel delivery address + static const int CONTACTS_ADDRESS_TYPE_PARCEL = 64; +} + +/// @brief Enumeration for Contact URL type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_url_type_e { + /// < Other URL type + static const int CONTACTS_URL_TYPE_OTHER = 0; + + /// < Custom URL type + static const int CONTACTS_URL_TYPE_CUSTOM = 1; + + /// < Home URL type + static const int CONTACTS_URL_TYPE_HOME = 2; + + /// < Work URL type + static const int CONTACTS_URL_TYPE_WORK = 3; +} + +/// @brief Enumeration for Contact messenger type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_messenger_type_e { + /// < Other messenger type + static const int CONTACTS_MESSENGER_TYPE_OTHER = 0; + + /// < Custom messenger type + static const int CONTACTS_MESSENGER_TYPE_CUSTOM = 1; + + /// < Google messenger type + static const int CONTACTS_MESSENGER_TYPE_GOOGLE = 2; + + /// < Windows live messenger type + static const int CONTACTS_MESSENGER_TYPE_WLM = 3; + + /// < Yahoo messenger type + static const int CONTACTS_MESSENGER_TYPE_YAHOO = 4; + + /// < Facebook messenger type + static const int CONTACTS_MESSENGER_TYPE_FACEBOOK = 5; + + /// < ICQ type + static const int CONTACTS_MESSENGER_TYPE_ICQ = 6; + + /// < AOL instance messenger type + static const int CONTACTS_MESSENGER_TYPE_AIM = 7; + + /// < QQ type + static const int CONTACTS_MESSENGER_TYPE_QQ = 8; + + /// < Jabber type + static const int CONTACTS_MESSENGER_TYPE_JABBER = 9; + + /// < Skype type + static const int CONTACTS_MESSENGER_TYPE_SKYPE = 10; + + /// < IRC type + static const int CONTACTS_MESSENGER_TYPE_IRC = 11; +} + +/// @brief Enumeration for Call history type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_phone_log_type_e { + /// < None + static const int CONTACTS_PLOG_TYPE_NONE = 0; + + /// < Incoming call + static const int CONTACTS_PLOG_TYPE_VOICE_INCOMING = 1; + + /// < Outgoing call + static const int CONTACTS_PLOG_TYPE_VOICE_OUTGOING = 2; + + /// < Incoming video call + static const int CONTACTS_PLOG_TYPE_VIDEO_INCOMING = 3; + + /// < Outgoing video call + static const int CONTACTS_PLOG_TYPE_VIDEO_OUTGOING = 4; + + /// < Not confirmed missed call + static const int CONTACTS_PLOG_TYPE_VOICE_INCOMING_UNSEEN = 5; + + /// < Confirmed missed call + static const int CONTACTS_PLOG_TYPE_VOICE_INCOMING_SEEN = 6; + + /// < Not confirmed missed video call + static const int CONTACTS_PLOG_TYPE_VIDEO_INCOMING_UNSEEN = 7; + + /// < Confirmed missed video call + static const int CONTACTS_PLOG_TYPE_VIDEO_INCOMING_SEEN = 8; + + /// < Rejected call + static const int CONTACTS_PLOG_TYPE_VOICE_REJECT = 9; + + /// < Rejected video call + static const int CONTACTS_PLOG_TYPE_VIDEO_REJECT = 10; + + /// < Blocked call + static const int CONTACTS_PLOG_TYPE_VOICE_BLOCKED = 11; + + /// < Blocked video call + static const int CONTACTS_PLOG_TYPE_VIDEO_BLOCKED = 12; + + /// < Incoming MMS + static const int CONTACTS_PLOG_TYPE_MMS_INCOMING = 101; + + /// < Outgoing MMS + static const int CONTACTS_PLOG_TYPE_MMS_OUTGOING = 102; + + /// < Incoming SMS + static const int CONTACTS_PLOG_TYPE_SMS_INCOMING = 103; + + /// < Outgoing SMS + static const int CONTACTS_PLOG_TYPE_SMS_OUTGOING = 104; + + /// < Blocked SMS + static const int CONTACTS_PLOG_TYPE_SMS_BLOCKED = 105; + + /// < Blocked MMS + static const int CONTACTS_PLOG_TYPE_MMS_BLOCKED = 106; + + /// < Received email + static const int CONTACTS_PLOG_TYPE_EMAIL_RECEIVED = 201; + + /// < Sent email + static const int CONTACTS_PLOG_TYPE_EMAIL_SENT = 202; +} + +/// @brief Enumeration for Contact event type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_event_type_e { + /// < Other event type + static const int CONTACTS_EVENT_TYPE_OTHER = 0; + + /// < Custom event type + static const int CONTACTS_EVENT_TYPE_CUSTOM = 1; + + /// < Birthday event type + static const int CONTACTS_EVENT_TYPE_BIRTH = 2; + + /// < Anniversary event type + static const int CONTACTS_EVENT_TYPE_ANNIVERSARY = 3; +} + +/// @brief Enumeration for Contact event calendar type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_event_calendar_type_e { + /// < Gregorian calendar + static const int CONTACTS_EVENT_CALENDAR_TYPE_GREGORIAN = 0; + + /// < Chinese calendar + static const int CONTACTS_EVENT_CALENDAR_TYPE_CHINESE = 1; +} + +/// @brief Enumeration for Contact image type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_image_type_e { + /// < Other type + static const int CONTACTS_IMAGE_TYPE_OTHER = 0; + + /// < Custom type + static const int CONTACTS_IMAGE_TYPE_CUSTOM = 1; +} + +/// @brief Enumeration for usage type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_usage_type_e { + /// < None + static const int CONTACTS_USAGE_STAT_TYPE_NONE = 0; + + /// < Outgoing call + static const int CONTACTS_USAGE_STAT_TYPE_OUTGOING_CALL = 1; + + /// < Outgoing message + static const int CONTACTS_USAGE_STAT_TYPE_OUTGOING_MSG = 2; + + /// < Outgoing email (Since 3.0) + static const int CONTACTS_USAGE_STAT_TYPE_OUTGOING_EMAIL = 3; + + /// < Incoming call (Since 3.0) + static const int CONTACTS_USAGE_STAT_TYPE_INCOMING_CALL = 4; + + /// < Incoming message (Since 3.0) + static const int CONTACTS_USAGE_STAT_TYPE_INCOMING_MSG = 5; + + /// < Incoming email (Since 3.0) + static const int CONTACTS_USAGE_STAT_TYPE_INCOMING_EMAIL = 6; + + /// < Missed call (Since 3.0) + static const int CONTACTS_USAGE_STAT_TYPE_MISSED_CALL = 7; + + /// < Rejected call (Since 3.0) + static const int CONTACTS_USAGE_STAT_TYPE_REJECTED_CALL = 8; + + /// < Blocked call (Since 3.0) + static const int CONTACTS_USAGE_STAT_TYPE_BLOCKED_CALL = 9; + + /// < Blocked message (Since 3.0) + static const int CONTACTS_USAGE_STAT_TYPE_BLOCKED_MSG = 10; +} + +/// @brief Enumeration for Contact display name source type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_display_name_source_type_e { + /// < Invalid source of display name + static const int CONTACTS_DISPLAY_NAME_SOURCE_TYPE_INVALID = 0; + + /// < Produced display name from email record + static const int CONTACTS_DISPLAY_NAME_SOURCE_TYPE_EMAIL = 1; + + /// < Produced display name from number record + static const int CONTACTS_DISPLAY_NAME_SOURCE_TYPE_NUMBER = 2; + + /// < Produced display name from nickname record + static const int CONTACTS_DISPLAY_NAME_SOURCE_TYPE_NICKNAME = 3; + + /// < Produced display name from company record + static const int CONTACTS_DISPLAY_NAME_SOURCE_TYPE_COMPANY = 4; + + /// < Produced display name from name record + static const int CONTACTS_DISPLAY_NAME_SOURCE_TYPE_NAME = 5; +} + +/// @brief Enumeration for Address book mode. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_address_book_mode_e { + /// < All module can read and write contacts of this address_book + static const int CONTACTS_ADDRESS_BOOK_MODE_NONE = 0; + + /// < All module can only read contacts of this address_book + static const int CONTACTS_ADDRESS_BOOK_MODE_READONLY = 1; +} + +/// @brief Enumeration for link mode when inserting contact. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_contact_link_mode_e { + /// < Auto link immediately + static const int CONTACTS_CONTACT_LINK_MODE_NONE = 0; + + /// < Do not auto link when the contact is inserted + static const int CONTACTS_CONTACT_LINK_MODE_IGNORE_ONCE = 1; +} + +/// @brief Enumeration for Contact relationship type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_relationship_type_e { + /// < Other relationship type + static const int CONTACTS_RELATIONSHIP_TYPE_OTHER = 0; + + /// < Assistant type + static const int CONTACTS_RELATIONSHIP_TYPE_ASSISTANT = 1; + + /// < Brother type + static const int CONTACTS_RELATIONSHIP_TYPE_BROTHER = 2; + + /// < Child type + static const int CONTACTS_RELATIONSHIP_TYPE_CHILD = 3; + + /// < Domestic Partner type + static const int CONTACTS_RELATIONSHIP_TYPE_DOMESTIC_PARTNER = 4; + + /// < Father type + static const int CONTACTS_RELATIONSHIP_TYPE_FATHER = 5; + + /// < Friend type + static const int CONTACTS_RELATIONSHIP_TYPE_FRIEND = 6; + + /// < Manager type + static const int CONTACTS_RELATIONSHIP_TYPE_MANAGER = 7; + + /// < Mother type + static const int CONTACTS_RELATIONSHIP_TYPE_MOTHER = 8; + + /// < Parent type + static const int CONTACTS_RELATIONSHIP_TYPE_PARENT = 9; + + /// < Partner type + static const int CONTACTS_RELATIONSHIP_TYPE_PARTNER = 10; + + /// < Referred by type + static const int CONTACTS_RELATIONSHIP_TYPE_REFERRED_BY = 11; + + /// < Relative type + static const int CONTACTS_RELATIONSHIP_TYPE_RELATIVE = 12; + + /// < Sister type + static const int CONTACTS_RELATIONSHIP_TYPE_SISTER = 13; + + /// < Spouse type + static const int CONTACTS_RELATIONSHIP_TYPE_SPOUSE = 14; + + /// < Custom type + static const int CONTACTS_RELATIONSHIP_TYPE_CUSTOM = 15; +} + +/// @brief Enumeration for Contact search range. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_search_range_e { + /// < Search record from name + static const int CONTACTS_SEARCH_RANGE_NAME = 1; + + /// < Search record from name and number + static const int CONTACTS_SEARCH_RANGE_NUMBER = 2; + + /// < Search record from name,number and data + static const int CONTACTS_SEARCH_RANGE_DATA = 4; + + /// < Search record from name,number,data and email. Now, support only _contacts_person_email view_uri + static const int CONTACTS_SEARCH_RANGE_EMAIL = 8; +} + +/// @brief Enumeration for SIP(Session Initiation Protocol) type range. +/// @since_tizen 3.0 +abstract class contacts_sip_type_e { + /// < Other sip type + static const int CONTACTS_SIP_TYPE_OTHER = 0; + + /// < Custom sip type + static const int CONTACTS_SIP_TYPE_CUSTOM = 1; + + /// < Home sip type + static const int CONTACTS_SIP_TYPE_HOME = 2; + + /// < Work sip type + static const int CONTACTS_SIP_TYPE_WORK = 3; +} + +class _contacts_address_book_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int account_id; + + @ffi.Uint32() + external int name; + + @ffi.Uint32() + external int mode; +} + +class _contacts_group_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int name; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_path; + + @ffi.Uint32() + external int vibration; + + @ffi.Uint32() + external int extra_data; + + @ffi.Uint32() + external int is_read_only; + + @ffi.Uint32() + external int message_alert; +} + +class _contacts_person_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int display_name_index; + + @ffi.Uint32() + external int display_contact_id; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int vibration; + + @ffi.Uint32() + external int status; + + @ffi.Uint32() + external int is_favorite; + + @ffi.Uint32() + external int favorite_priority; + + @ffi.Uint32() + external int link_count; + + @ffi.Uint32() + external int addressbook_ids; + + @ffi.Uint32() + external int has_phonenumber; + + @ffi.Uint32() + external int has_email; + + @ffi.Uint32() + external int message_alert; + + @ffi.Uint32() + external int snippet_type; + + @ffi.Uint32() + external int snippet_string; +} + +class _contacts_simple_contact_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int display_source_type; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int is_favorite; + + @ffi.Uint32() + external int has_phonenumber; + + @ffi.Uint32() + external int has_email; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int uid; + + @ffi.Uint32() + external int vibration; + + @ffi.Uint32() + external int changed_time; + + @ffi.Uint32() + external int message_alert; +} + +class _contacts_contact_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int display_source_type; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int is_favorite; + + @ffi.Uint32() + external int has_phonenumber; + + @ffi.Uint32() + external int has_email; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int uid; + + @ffi.Uint32() + external int vibration; + + @ffi.Uint32() + external int changed_time; + + @ffi.Uint32() + external int link_mode; + + @ffi.Uint32() + external int name; + + @ffi.Uint32() + external int image; + + @ffi.Uint32() + external int company; + + @ffi.Uint32() + external int note; + + @ffi.Uint32() + external int number; + + @ffi.Uint32() + external int email; + + @ffi.Uint32() + external int event; + + @ffi.Uint32() + external int messenger; + + @ffi.Uint32() + external int address; + + @ffi.Uint32() + external int url; + + @ffi.Uint32() + external int nickname; + + @ffi.Uint32() + external int profile; + + @ffi.Uint32() + external int relationship; + + @ffi.Uint32() + external int group_relation; + + @ffi.Uint32() + external int extension_1; + + @ffi.Uint32() + external int message_alert; + + @ffi.Uint32() + external int sip; +} + +class _contacts_my_profile_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int uid; + + @ffi.Uint32() + external int changed_time; + + @ffi.Uint32() + external int name; + + @ffi.Uint32() + external int image; + + @ffi.Uint32() + external int company; + + @ffi.Uint32() + external int note; + + @ffi.Uint32() + external int number; + + @ffi.Uint32() + external int email; + + @ffi.Uint32() + external int event; + + @ffi.Uint32() + external int messenger; + + @ffi.Uint32() + external int address; + + @ffi.Uint32() + external int url; + + @ffi.Uint32() + external int nickname; + + @ffi.Uint32() + external int profile; + + @ffi.Uint32() + external int relationship; + + @ffi.Uint32() + external int extension_1; + + @ffi.Uint32() + external int sip; +} + +class _contacts_name_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int first; + + @ffi.Uint32() + external int last; + + @ffi.Uint32() + external int addition; + + @ffi.Uint32() + external int suffix; + + @ffi.Uint32() + external int prefix; + + @ffi.Uint32() + external int phonetic_first; + + @ffi.Uint32() + external int phonetic_middle; + + @ffi.Uint32() + external int phonetic_last; +} + +class _contacts_number_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int label; + + @ffi.Uint32() + external int is_default; + + @ffi.Uint32() + external int number; + + @ffi.Uint32() + external int normalized_number; + + @ffi.Uint32() + external int cleaned_number; + + @ffi.Uint32() + external int number_filter; +} + +class _contacts_email_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int label; + + @ffi.Uint32() + external int is_default; + + @ffi.Uint32() + external int email; +} + +class _contacts_address_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int label; + + @ffi.Uint32() + external int postbox; + + @ffi.Uint32() + external int extended; + + @ffi.Uint32() + external int street; + + @ffi.Uint32() + external int locality; + + @ffi.Uint32() + external int region; + + @ffi.Uint32() + external int postal_code; + + @ffi.Uint32() + external int country; + + @ffi.Uint32() + external int is_default; +} + +class _contacts_note_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int note; +} + +class _contacts_url_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int label; + + @ffi.Uint32() + external int url; +} + +class _contacts_event_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int label; + + @ffi.Uint32() + external int date; + + @ffi.Uint32() + external int calendar_type; + + @ffi.Uint32() + external int is_leap_month; +} + +class _contacts_group_relation_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int group_id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int name; +} + +class _contacts_relationship_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int label; + + @ffi.Uint32() + external int name; +} + +class _contacts_image_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int label; + + @ffi.Uint32() + external int path; + + @ffi.Uint32() + external int is_default; +} + +class _contacts_company_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int label; + + @ffi.Uint32() + external int name; + + @ffi.Uint32() + external int department; + + @ffi.Uint32() + external int job_title; + + @ffi.Uint32() + external int assistant_name; + + @ffi.Uint32() + external int role; + + @ffi.Uint32() + external int logo; + + @ffi.Uint32() + external int location; + + @ffi.Uint32() + external int description; + + @ffi.Uint32() + external int phonetic_name; +} + +class _contacts_nickname_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int name; +} + +class _contacts_messenger_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int label; + + @ffi.Uint32() + external int im_id; +} + +class _contacts_extension_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int data1; + + @ffi.Uint32() + external int data2; + + @ffi.Uint32() + external int data3; + + @ffi.Uint32() + external int data4; + + @ffi.Uint32() + external int data5; + + @ffi.Uint32() + external int data6; + + @ffi.Uint32() + external int data7; + + @ffi.Uint32() + external int data8; + + @ffi.Uint32() + external int data9; + + @ffi.Uint32() + external int data10; + + @ffi.Uint32() + external int data11; + + @ffi.Uint32() + external int data12; +} + +class _contacts_sdn_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int name; + + @ffi.Uint32() + external int number; + + @ffi.Uint32() + external int sim_slot_no; +} + +class _contacts_profile_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int uid; + + @ffi.Uint32() + external int text; + + @ffi.Uint32() + external int order; + + @ffi.Uint32() + external int service_operation; + + @ffi.Uint32() + external int mime; + + @ffi.Uint32() + external int app_id; + + @ffi.Uint32() + external int uri; + + @ffi.Uint32() + external int category; + + @ffi.Uint32() + external int extra_data; + + @ffi.Uint32() + external int contact_id; +} + +class _contacts_activity_photo_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int activity_id; + + @ffi.Uint32() + external int photo_url; + + @ffi.Uint32() + external int sort_index; +} + +class _contacts_activity_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int source_name; + + @ffi.Uint32() + external int status; + + @ffi.Uint32() + external int timestamp; + + @ffi.Uint32() + external int service_operation; + + @ffi.Uint32() + external int uri; + + @ffi.Uint32() + external int photo; +} + +class _contacts_speeddial_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int speeddial_number; + + @ffi.Uint32() + external int number_id; + + @ffi.Uint32() + external int number; + + @ffi.Uint32() + external int number_label; + + @ffi.Uint32() + external int number_type; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int normalized_number; + + @ffi.Uint32() + external int cleaned_number; + + @ffi.Uint32() + external int number_filter; +} + +class _contacts_phone_log_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int address; + + @ffi.Uint32() + external int log_time; + + @ffi.Uint32() + external int log_type; + + @ffi.Uint32() + external int extra_data1; + + @ffi.Uint32() + external int extra_data2; + + @ffi.Uint32() + external int normalized_address; + + @ffi.Uint32() + external int cleaned_address; + + @ffi.Uint32() + external int address_filter; + + @ffi.Uint32() + external int sim_slot_no; +} + +class _contacts_contact_updated_info_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int version; + + @ffi.Uint32() + external int image_changed; +} + +class _contacts_my_profile_updated_info_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int last_changed_type; + + @ffi.Uint32() + external int version; +} + +class _contacts_group_updated_info_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int group_id; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int version; +} + +class _contacts_group_member_updated_info_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int group_id; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int version; +} + +class _contacts_grouprel_updated_info_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int group_id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int version; +} + +class _contacts_person_contact_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int display_name_index; + + @ffi.Uint32() + external int display_contact_id; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int vibration; + + @ffi.Uint32() + external int status; + + @ffi.Uint32() + external int is_favorite; + + @ffi.Uint32() + external int link_count; + + @ffi.Uint32() + external int addressbook_ids; + + @ffi.Uint32() + external int has_phonenumber; + + @ffi.Uint32() + external int has_email; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int address_book_name; + + @ffi.Uint32() + external int address_book_mode; + + @ffi.Uint32() + external int message_alert; + + @ffi.Uint32() + external int snippet_type; + + @ffi.Uint32() + external int snippet_string; +} + +class _contacts_person_number_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int display_name_index; + + @ffi.Uint32() + external int display_contact_id; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int vibration; + + @ffi.Uint32() + external int is_favorite; + + @ffi.Uint32() + external int has_phonenumber; + + @ffi.Uint32() + external int has_email; + + @ffi.Uint32() + external int number_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int label; + + @ffi.Uint32() + external int is_primary_default; + + @ffi.Uint32() + external int number; + + @ffi.Uint32() + external int number_filter; + + @ffi.Uint32() + external int normalized_number; + + @ffi.Uint32() + external int message_alert; + + @ffi.Uint32() + external int cleaned_number; + + @ffi.Uint32() + external int snippet_type; + + @ffi.Uint32() + external int snippet_string; +} + +class _contacts_person_email_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int display_name_index; + + @ffi.Uint32() + external int display_contact_id; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int vibration; + + @ffi.Uint32() + external int is_favorite; + + @ffi.Uint32() + external int has_phonenumber; + + @ffi.Uint32() + external int has_email; + + @ffi.Uint32() + external int email_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int label; + + @ffi.Uint32() + external int is_primary_default; + + @ffi.Uint32() + external int email; + + @ffi.Uint32() + external int message_alert; + + @ffi.Uint32() + external int snippet_type; + + @ffi.Uint32() + external int snippet_string; +} + +class _contacts_person_grouprel_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int display_name_index; + + @ffi.Uint32() + external int display_contact_id; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int vibration; + + @ffi.Uint32() + external int status; + + @ffi.Uint32() + external int is_favorite; + + @ffi.Uint32() + external int link_count; + + @ffi.Uint32() + external int addressbook_ids; + + @ffi.Uint32() + external int has_phonenumber; + + @ffi.Uint32() + external int has_email; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int group_id; + + @ffi.Uint32() + external int address_book_name; + + @ffi.Uint32() + external int address_book_mode; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int message_alert; + + @ffi.Uint32() + external int snippet_type; + + @ffi.Uint32() + external int snippet_string; +} + +class _contacts_person_group_assigned_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int display_name_index; + + @ffi.Uint32() + external int display_contact_id; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int vibration; + + @ffi.Uint32() + external int status; + + @ffi.Uint32() + external int is_favorite; + + @ffi.Uint32() + external int link_count; + + @ffi.Uint32() + external int linked_address_book_ids; + + @ffi.Uint32() + external int has_phonenumber; + + @ffi.Uint32() + external int has_email; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int group_id; + + @ffi.Uint32() + external int address_book_mode; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int message_alert; + + @ffi.Uint32() + external int snippet_type; + + @ffi.Uint32() + external int snippet_string; +} + +class _contacts_person_group_not_assigned_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int display_name_index; + + @ffi.Uint32() + external int display_contact_id; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int vibration; + + @ffi.Uint32() + external int status; + + @ffi.Uint32() + external int is_favorite; + + @ffi.Uint32() + external int link_count; + + @ffi.Uint32() + external int linked_address_book_ids; + + @ffi.Uint32() + external int has_phonenumber; + + @ffi.Uint32() + external int has_email; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int address_book_mode; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int message_alert; + + @ffi.Uint32() + external int snippet_type; + + @ffi.Uint32() + external int snippet_string; +} + +class _contacts_person_phone_log_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int log_id; + + @ffi.Uint32() + external int address; + + @ffi.Uint32() + external int address_type; + + @ffi.Uint32() + external int log_time; + + @ffi.Uint32() + external int log_type; + + @ffi.Uint32() + external int extra_data1; + + @ffi.Uint32() + external int extra_data2; + + @ffi.Uint32() + external int normalized_address; + + @ffi.Uint32() + external int cleaned_address; + + @ffi.Uint32() + external int address_filter; + + @ffi.Uint32() + external int sim_slot_no; +} + +class _contacts_person_usage_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int display_name_index; + + @ffi.Uint32() + external int display_contact_id; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int vibration; + + @ffi.Uint32() + external int is_favorite; + + @ffi.Uint32() + external int has_phonenumber; + + @ffi.Uint32() + external int has_email; + + @ffi.Uint32() + external int usage_type; + + @ffi.Uint32() + external int times_used; + + @ffi.Uint32() + external int message_alert; +} + +class _contacts_contact_number_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int display_source_type; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int number_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int label; + + @ffi.Uint32() + external int is_default; + + @ffi.Uint32() + external int number; + + @ffi.Uint32() + external int number_filter; + + @ffi.Uint32() + external int normalized_number; + + @ffi.Uint32() + external int cleaned_number; +} + +class _contacts_contact_email_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int display_source_type; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int email_id; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int label; + + @ffi.Uint32() + external int is_default; + + @ffi.Uint32() + external int email; +} + +class _contacts_contact_grouprel_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int display_source_type; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int group_id; + + @ffi.Uint32() + external int group_name; +} + +class _contacts_contact_activity_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int display_name; + + @ffi.Uint32() + external int display_source_type; + + @ffi.Uint32() + external int address_book_id; + + @ffi.Uint32() + external int account_id; + + @ffi.Uint32() + external int person_id; + + @ffi.Uint32() + external int ringtone_path; + + @ffi.Uint32() + external int image_thumbnail_path; + + @ffi.Uint32() + external int activity_id; + + @ffi.Uint32() + external int source_name; + + @ffi.Uint32() + external int status; + + @ffi.Uint32() + external int timestamp; + + @ffi.Uint32() + external int service_operation; + + @ffi.Uint32() + external int uri; +} + +class _contacts_phone_log_stat_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int log_count; + + @ffi.Uint32() + external int log_type; + + @ffi.Uint32() + external int sim_slot_no; +} + +class _contacts_sip_property_ids extends ffi.Struct { + external ffi.Pointer _uri; + + @ffi.Uint32() + external int id; + + @ffi.Uint32() + external int contact_id; + + @ffi.Uint32() + external int address; + + @ffi.Uint32() + external int type; + + @ffi.Uint32() + external int label; +} + +/// @brief Enumeration for Contacts match string flags. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_match_str_flag_e { + /// < Full string, case-sensitive + static const int CONTACTS_MATCH_EXACTLY = 0; + + /// < Full string, case-insensitive + static const int CONTACTS_MATCH_FULLSTRING = 1; + + /// < Sub string, case-insensitive + static const int CONTACTS_MATCH_CONTAINS = 2; + + /// < Start with, case-insensitive + static const int CONTACTS_MATCH_STARTSWITH = 3; + + /// < End with, case-insensitive + static const int CONTACTS_MATCH_ENDSWITH = 4; + + /// < IS NOT NULL + static const int CONTACTS_MATCH_EXISTS = 5; +} + +/// @brief Enumeration for Contacts match int flags. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_match_int_flag_e { + /// < '=' + static const int CONTACTS_MATCH_EQUAL = 0; + + /// < '>' + static const int CONTACTS_MATCH_GREATER_THAN = 1; + + /// < '>=' + static const int CONTACTS_MATCH_GREATER_THAN_OR_EQUAL = 2; + + /// < '<' + static const int CONTACTS_MATCH_LESS_THAN = 3; + + /// < '<=' + static const int CONTACTS_MATCH_LESS_THAN_OR_EQUAL = 4; + + /// < '<>', this flag can yield poor performance + static const int CONTACTS_MATCH_NOT_EQUAL = 5; + + /// < IS NULL + static const int CONTACTS_MATCH_NONE = 6; +} + +/// @brief Enumeration for Contacts filter operators. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_filter_operator_e { + /// < AND + static const int CONTACTS_FILTER_OPERATOR_AND = 0; + + /// < OR + static const int CONTACTS_FILTER_OPERATOR_OR = 1; +} + +/// @brief Enumeration for contact change state. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_changed_e { + /// < Inserted + static const int CONTACTS_CHANGE_INSERTED = 0; + + /// < Updated + static const int CONTACTS_CHANGE_UPDATED = 1; + + /// < Deleted + static const int CONTACTS_CHANGE_DELETED = 2; +} + +/// @brief Enumeration for name display order. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_name_display_order_e { + /// < First name comes at the first + static const int CONTACTS_NAME_DISPLAY_ORDER_FIRSTLAST = 0; + + /// < First name comes at the last + static const int CONTACTS_NAME_DISPLAY_ORDER_LASTFIRST = 1; +} + +/// @brief Enumeration for name sorting order. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_name_sorting_order_e { + /// < Contacts are first sorted based on the first name + static const int CONTACTS_NAME_SORTING_ORDER_FIRSTLAST = 0; + + /// < Contacts are first sorted based on the last name + static const int CONTACTS_NAME_SORTING_ORDER_LASTFIRST = 1; +} + +/// @brief Enumeration for Contacts person properties. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_person_property_e { + /// < Default contacts record + static const int CONTACTS_PERSON_PROPERTY_NAME_CONTACT = 0; + + /// < Default number record + static const int CONTACTS_PERSON_PROPERTY_NUMBER = 1; + + /// < Default email record + static const int CONTACTS_PERSON_PROPERTY_EMAIL = 2; + + /// < Default image record + static const int CONTACTS_PERSON_PROPERTY_IMAGE = 3; +} + +/// @brief Enumeration for contact DB status. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 3.0 @endif +abstract class contacts_db_status_e { + /// < Normal + static const int CONTACTS_DB_STATUS_NORMAL = 0; + + /// < DB status is Changing collation + static const int CONTACTS_DB_STATUS_CHANGING_COLLATION = 1; +} + +/// @brief Enumeration for language type. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class phone_number_lang_e { + /// < Amharic + static const int PHONE_NUMBER_LANG_AMHARIC = 0; + + /// < Arabic + static const int PHONE_NUMBER_LANG_ARABIC = 1; + + /// < Belarusian + static const int PHONE_NUMBER_LANG_BELARUSIAN = 2; + + /// < Bulgarian + static const int PHONE_NUMBER_LANG_BULGARIAN = 3; + + /// < Chinese + static const int PHONE_NUMBER_LANG_CHINESE = 4; + + /// < Chinese(Traditional) + static const int PHONE_NUMBER_LANG_CHINESE_TRADITIONAL = 5; + + /// < Czech + static const int PHONE_NUMBER_LANG_CZECH = 6; + + /// < Dutch + static const int PHONE_NUMBER_LANG_DUTCH = 7; + + /// < English + static const int PHONE_NUMBER_LANG_ENGLISH = 8; + + /// < Finnish + static const int PHONE_NUMBER_LANG_FINNISH = 9; + + /// < French + static const int PHONE_NUMBER_LANG_FRENCH = 10; + + /// < German + static const int PHONE_NUMBER_LANG_GERMAN = 11; + + /// < Greek + static const int PHONE_NUMBER_LANG_GREEK = 12; + + /// < Hungarian + static const int PHONE_NUMBER_LANG_HUNGARIAN = 13; + + /// < Indonesian + static const int PHONE_NUMBER_LANG_INDONESIAN = 14; + + /// < Italian + static const int PHONE_NUMBER_LANG_ITALIAN = 15; + + /// < Japanese + static const int PHONE_NUMBER_LANG_JAPANESE = 16; + + /// < Korean + static const int PHONE_NUMBER_LANG_KOREAN = 17; + + /// < Northern Sami + static const int PHONE_NUMBER_LANG_NORTHERN_SAMI = 18; + + /// < Persian + static const int PHONE_NUMBER_LANG_PERSIAN = 19; + + /// < Polish + static const int PHONE_NUMBER_LANG_POLISH = 20; + + /// < Portuguese + static const int PHONE_NUMBER_LANG_PORTUGUESE = 21; + + /// < Romanian + static const int PHONE_NUMBER_LANG_ROMANIAN = 22; + + /// < Russian + static const int PHONE_NUMBER_LANG_RUSSIAN = 23; + + /// < Serbian + static const int PHONE_NUMBER_LANG_SERBIAN = 24; + + /// < Spanish + static const int PHONE_NUMBER_LANG_SPANISH = 25; + + /// < Swedish + static const int PHONE_NUMBER_LANG_SWEDISH = 26; + + /// < Thai + static const int PHONE_NUMBER_LANG_THAI = 27; + + /// < Turkish + static const int PHONE_NUMBER_LANG_TURKISH = 28; + + /// < Vietnamese + static const int PHONE_NUMBER_LANG_VIETNAMESE = 29; + + /// < Current System Value (Since 3.0) + static const int PHONE_NUMBER_LANG_SYSTEM = 30; + static const int PHONE_NUMBER_LANG_MAX = 31; +} + +/// @brief Enumeration for region type. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class phone_number_region_e { + /// < Aland Islands + static const int PHONE_NUMBER_REGION_ALAND_ISLANDS = 0; + + /// < Albania + static const int PHONE_NUMBER_REGION_ALBANIA = 1; + + /// < Algeria + static const int PHONE_NUMBER_REGION_ALGERIA = 2; + + /// < American Samoa + static const int PHONE_NUMBER_REGION_AMERICAN_SAMOA = 3; + + /// < Angola + static const int PHONE_NUMBER_REGION_ANGOLA = 4; + + /// < Anguilla + static const int PHONE_NUMBER_REGION_ANGUILLA = 5; + + /// < Argentina + static const int PHONE_NUMBER_REGION_ARGENTINA = 6; + + /// < Armenia + static const int PHONE_NUMBER_REGION_ARMENIA = 7; + + /// < Ascension Island + static const int PHONE_NUMBER_REGION_ASCENSION_ISLAND = 8; + + /// < Atigua and Barbuda + static const int PHONE_NUMBER_REGION_ATIGUA_AND_BARBUDA = 9; + + /// < Austria + static const int PHONE_NUMBER_REGION_AUSTRIA = 10; + + /// < Bahamas + static const int PHONE_NUMBER_REGION_BAHAMAS = 11; + + /// < Barbados + static const int PHONE_NUMBER_REGION_BARBADOS = 12; + + /// < Belarus + static const int PHONE_NUMBER_REGION_BELARUS = 13; + + /// < Belgium + static const int PHONE_NUMBER_REGION_BELGIUM = 14; + + /// < Benin + static const int PHONE_NUMBER_REGION_BENIN = 15; + + /// < Bermuda + static const int PHONE_NUMBER_REGION_BERMUDA = 16; + + /// < Bonaire Sint Eustatius and Saba + static const int PHONE_NUMBER_REGION_BONAIRE_SINT_EUSTATIUS_AND_SABA = 17; + + /// < Botswana + static const int PHONE_NUMBER_REGION_BOTSWANA = 18; + + /// < Brazil + static const int PHONE_NUMBER_REGION_BRAZIL = 19; + + /// < Bulgaria + static const int PHONE_NUMBER_REGION_BULGARIA = 20; + + /// < Burkina Faso + static const int PHONE_NUMBER_REGION_BURKINA_FASO = 21; + + /// < Burundi + static const int PHONE_NUMBER_REGION_BURUNDI = 22; + + /// < Cabo Verde + static const int PHONE_NUMBER_REGION_CABO_VERDE = 23; + + /// < Cameroon + static const int PHONE_NUMBER_REGION_CAMEROON = 24; + + /// < Canada + static const int PHONE_NUMBER_REGION_CANADA = 25; + + /// < Cayman Island + static const int PHONE_NUMBER_REGION_CAYMAN_ISLAND = 26; + + /// < Chile + static const int PHONE_NUMBER_REGION_CHILE = 27; + + /// < China + static const int PHONE_NUMBER_REGION_CHINA = 28; + + /// < Colombia + static const int PHONE_NUMBER_REGION_COLOMBIA = 29; + + /// < Comoros + static const int PHONE_NUMBER_REGION_COMOROS = 30; + + /// < Congo + static const int PHONE_NUMBER_REGION_CONGO = 31; + + /// < Cote d'Ivoire + static const int PHONE_NUMBER_REGION_COTE_D_IVOIRE = 32; + + /// < Cuba + static const int PHONE_NUMBER_REGION_CUBA = 33; + + /// < Curacao + static const int PHONE_NUMBER_REGION_CURACAO = 34; + + /// < Czech Republic + static const int PHONE_NUMBER_REGION_CZECH_REPUBLIC = 35; + + /// < Congo (Democratic Republic of the) + static const int PHONE_NUMBER_REGION_DEMOCRATIC_REPUBLIC_OF_THE_CONGO = 36; + + /// < Dominica + static const int PHONE_NUMBER_REGION_DOMINICA = 37; + + /// < Domoinican Republic + static const int PHONE_NUMBER_REGION_DOMINICAN_REPUBLIC = 38; + + /// < Egypt + static const int PHONE_NUMBER_REGION_EGYPT = 39; + + /// < Estonia + static const int PHONE_NUMBER_REGION_ESTONIA = 40; + + /// < Ethiopia + static const int PHONE_NUMBER_REGION_ETHIOPIA = 41; + + /// < Finland + static const int PHONE_NUMBER_REGION_FINLAND = 42; + + /// < France + static const int PHONE_NUMBER_REGION_FRANCE = 43; + + /// < Gabon + static const int PHONE_NUMBER_REGION_GABON = 44; + + /// < Gambia + static const int PHONE_NUMBER_REGION_GAMBIA = 45; + + /// < Germany + static const int PHONE_NUMBER_REGION_GERMANY = 46; + + /// < Ghana + static const int PHONE_NUMBER_REGION_GHANA = 47; + + /// < Greece + static const int PHONE_NUMBER_REGION_GREECE = 48; + + /// < Greenland + static const int PHONE_NUMBER_REGION_GREENLAND = 49; + + /// < Grenada + static const int PHONE_NUMBER_REGION_GRENADA = 50; + + /// < Guam + static const int PHONE_NUMBER_REGION_GUAM = 51; + + /// < Guernsey + static const int PHONE_NUMBER_REGION_GUERNSEY = 52; + + /// < Guinea + static const int PHONE_NUMBER_REGION_GUINEA = 53; + + /// < Guinea-Bissau + static const int PHONE_NUMBER_REGION_GUINEA_BISSAU = 54; + + /// < Hungary + static const int PHONE_NUMBER_REGION_HUNGARY = 55; + + /// < Iceland + static const int PHONE_NUMBER_REGION_ICELAND = 56; + + /// < India + static const int PHONE_NUMBER_REGION_INDIA = 57; + + /// < Indonesia + static const int PHONE_NUMBER_REGION_INDONESIA = 58; + + /// < Ireland + static const int PHONE_NUMBER_REGION_IRELAND = 59; + + /// < Iran (Islamic Republic of) + static const int PHONE_NUMBER_REGION_ISLAMIC_REPUBLIC_OF_IRAN = 60; + + /// < Isle of Man + static const int PHONE_NUMBER_REGION_ISLE_OF_MAN = 61; + + /// < Italy + static const int PHONE_NUMBER_REGION_ITALY = 62; + + /// < Jamaica + static const int PHONE_NUMBER_REGION_JAMAICA = 63; + + /// < Japan + static const int PHONE_NUMBER_REGION_JAPAN = 64; + + /// < Jersey + static const int PHONE_NUMBER_REGION_JERSEY = 65; + + /// < Jordan + static const int PHONE_NUMBER_REGION_JORDAN = 66; + + /// < Kazakhstan + static const int PHONE_NUMBER_REGION_KAZAKHSTAN = 67; + + /// < Kenya + static const int PHONE_NUMBER_REGION_KENYA = 68; + + /// < Kiribati + static const int PHONE_NUMBER_REGION_KIRIBATI = 69; + + /// < Latvia + static const int PHONE_NUMBER_REGION_LATVIA = 70; + + /// < Lesotho + static const int PHONE_NUMBER_REGION_LESOTHO = 71; + + /// < Lithuania + static const int PHONE_NUMBER_REGION_LITHUANIA = 72; + + /// < Luxembourg + static const int PHONE_NUMBER_REGION_LUXEMBOURG = 73; + + /// < Madagascar + static const int PHONE_NUMBER_REGION_MADAGASCAR = 74; + + /// < Mauritania + static const int PHONE_NUMBER_REGION_MAURITANIA = 75; + + /// < Maritius + static const int PHONE_NUMBER_REGION_MAURITIUS = 76; + + /// < Montserrat + static const int PHONE_NUMBER_REGION_MONTSERRAT = 77; + + /// < Morocco + static const int PHONE_NUMBER_REGION_MOROCCO = 78; + + /// < Mazambique + static const int PHONE_NUMBER_REGION_MOZAMBIQUE = 79; + + /// < Namibia + static const int PHONE_NUMBER_REGION_NAMIBIA = 80; + + /// < Netherlands + static const int PHONE_NUMBER_REGION_NETHERLANDS = 81; + + /// < Nigeria + static const int PHONE_NUMBER_REGION_NIGERIA = 82; + + /// < Northern Mariana Island + static const int PHONE_NUMBER_REGION_NORTHERN_MARIANA_ISLANDS = 83; + + /// < Norway + static const int PHONE_NUMBER_REGION_NORWAY = 84; + + /// < Peru + static const int PHONE_NUMBER_REGION_PERU = 85; + + /// < Poland + static const int PHONE_NUMBER_REGION_POLAND = 86; + + /// < Portugal + static const int PHONE_NUMBER_REGION_PORTUGAL = 87; + + /// < Puerto Rico + static const int PHONE_NUMBER_REGION_PUERTO_RICO = 88; + + /// < Korea (Republic of) + static const int PHONE_NUMBER_REGION_REPUBLIC_OF_KOREA = 89; + + /// < Moldova (Republic of) + static const int PHONE_NUMBER_REGION_REPUBLIC_OF_MOLDOVA = 90; + + /// < Romania + static const int PHONE_NUMBER_REGION_ROMANIA = 91; + + /// < Russian Federation + static const int PHONE_NUMBER_REGION_RUSSIAN_FEDERATION = 92; + + /// < Saint Helena, Ascension and Tristan da Cunha + static const int PHONE_NUMBER_REGION_SAINT_HELENA = 93; + + /// < Saint Kitts and Nevis + static const int PHONE_NUMBER_REGION_SAINT_KITTS_AND_NEVIS = 94; + + /// < Saint Lucia + static const int PHONE_NUMBER_REGION_SAINT_LUCIA = 95; + + /// < Saint Vincent and the Grenadines + static const int PHONE_NUMBER_REGION_SAINT_VINCENT_AND_THE_GRENADINES = 96; + + /// < Sao Tome and Principe + static const int PHONE_NUMBER_REGION_SAO_TOME_AND_PRINCIPE = 97; + + /// < Saudi Arabia + static const int PHONE_NUMBER_REGION_SAUDI_ARABIA = 98; + + /// < Senegal + static const int PHONE_NUMBER_REGION_SENEGAL = 99; + + /// < Serbia + static const int PHONE_NUMBER_REGION_SERBIA = 100; + + /// < Sierra Leone + static const int PHONE_NUMBER_REGION_SIERRA_LEONE = 101; + + /// < Sint maarten (Dutch part) + static const int PHONE_NUMBER_REGION_SINT_MAARTEN = 102; + + /// < Slovakia + static const int PHONE_NUMBER_REGION_SLOVAKIA = 103; + + /// < Somalia + static const int PHONE_NUMBER_REGION_SOMALIA = 104; + + /// < South Africa + static const int PHONE_NUMBER_REGION_SOUTH_AFRICA = 105; + + /// < Spain + static const int PHONE_NUMBER_REGION_SPAIN = 106; + + /// < Sri Lanka + static const int PHONE_NUMBER_REGION_SRI_LANKA = 107; + + /// < Sudan + static const int PHONE_NUMBER_REGION_SUDAN = 108; + + /// < Svalbard and Jan Mayen + static const int PHONE_NUMBER_REGION_SVALBARD_AND_JAN_MAYEN = 109; + + /// < Swaziland + static const int PHONE_NUMBER_REGION_SWAZILAND = 110; + + /// < Sweden + static const int PHONE_NUMBER_REGION_SWEDEN = 111; + + /// < Switzerland + static const int PHONE_NUMBER_REGION_SWITZERLAND = 112; + + /// < Chinese Taiwan + static const int PHONE_NUMBER_REGION_TAIWAN_PROVINCE_OF_CHINA = 113; + + /// < Thailand + static const int PHONE_NUMBER_REGION_THAILAND = 114; + + /// < Macedonia (the Former Yugoslav Republic of) + static const int + PHONE_NUMBER_REGION_THE_FORMER_YUGOSLAV_REPUBLIC_OF_MACEDONIA = 115; + + /// < Togo + static const int PHONE_NUMBER_REGION_TOGO = 116; + + /// < Trinidad and Tobago + static const int PHONE_NUMBER_REGION_TRINIDAD_AND_TOBAGO = 117; + + /// < Tristan da Cunha + static const int PHONE_NUMBER_REGION_TRISTAN_DA_CUNHA = 118; + + /// < Tunisia + static const int PHONE_NUMBER_REGION_TUNISIA = 119; + + /// < Turkey + static const int PHONE_NUMBER_REGION_TURKEY = 120; + + /// < Turks and Caicos Islands + static const int PHONE_NUMBER_REGION_TURKS_AND_CAICOS_ISLANDS = 121; + + /// < Uganda + static const int PHONE_NUMBER_REGION_UGANDA = 122; + + /// < United Kingdom + static const int PHONE_NUMBER_REGION_UNITED_KINGDOM = 123; + + /// < United States of America + static const int PHONE_NUMBER_REGION_UNITED_STATES_OF_AMERICA = 124; + + /// < Venezuela + static const int PHONE_NUMBER_REGION_VENEZUELA = 125; + + /// < Viet Nam + static const int PHONE_NUMBER_REGION_VIET_NAM = 126; + + /// < Virgin Island (British) + static const int PHONE_NUMBER_REGION_VIRGIN_ISLAND_BRITISH = 127; + + /// < Virgin Island (U.S.) + static const int PHONE_NUMBER_REGION_VIRGIN_ISLAND_US = 128; + + /// < Western Sahara + static const int PHONE_NUMBER_REGION_WESTERN_SAHARA = 129; + + /// < Zambia + static const int PHONE_NUMBER_REGION_ZAMBIA = 130; + + /// < Zimbabwe + static const int PHONE_NUMBER_REGION_ZIMBABWE = 131; + + /// < Andorra (Since 3.0) + static const int PHONE_NUMBER_REGION_ANDORRA = 132; + + /// < United Arab Emirates (Since 3.0) + static const int PHONE_NUMBER_REGION_UNITED_ARAB_EMIRATES = 133; + + /// < Afghanistan (Since 3.0) + static const int PHONE_NUMBER_REGION_AFGHANISTAN = 134; + + /// < Australia (Since 3.0) + static const int PHONE_NUMBER_REGION_AUSTRALIA = 135; + + /// < Aruba (Since 3.0) + static const int PHONE_NUMBER_REGION_ARUBA = 136; + + /// < Azerbaijan (Since 3.0) + static const int PHONE_NUMBER_REGION_AZERBAIJAN = 137; + + /// < Bosnia and Herzegovina (Since 3.0) + static const int PHONE_NUMBER_REGION_BOSNIA_AND_HERZEGOVINA = 138; + + /// < Bangladesh (Since 3.0) + static const int PHONE_NUMBER_REGION_BANGLADESH = 139; + + /// < Bahrain (Since 3.0) + static const int PHONE_NUMBER_REGION_BAHRAIN = 140; + + /// < Saint Barthelemy, French Antilles (Since 3.0) + static const int PHONE_NUMBER_REGION_SAINT_BARTHELEMY = 141; + + /// < Brunei Darussalam (Since 3.0) + static const int PHONE_NUMBER_REGION_BRUNEI_DARUSSALAM = 142; + + /// < Bolivia (Since 3.0) + static const int PHONE_NUMBER_REGION_BOLIVIA = 143; + + /// < Bhutan (Since 3.0) + static const int PHONE_NUMBER_REGION_BHUTAN = 144; + + /// < Belize (Since 3.0) + static const int PHONE_NUMBER_REGION_BELIZE = 145; + + /// < Cocos Islands (Since 3.0) + static const int PHONE_NUMBER_REGION_COCOS_ISLANDS = 146; + + /// < Central African Republic (Since 3.0) + static const int PHONE_NUMBER_REGION_CENTRAL_AFRICAN_REPUBLIC = 147; + + /// < Cook Islands (Since 3.0) + static const int PHONE_NUMBER_REGION_COOK_ISLANDS = 148; + + /// < Costa Rica (Since 3.0) + static const int PHONE_NUMBER_REGION_COSTA_RICA = 149; + + /// < Christmas Islands (Since 3.0) + static const int PHONE_NUMBER_REGION_CHRISTMAS_ISLANDS = 150; + + /// < Cyprus (Since 3.0) + static const int PHONE_NUMBER_REGION_CYPRUS = 151; + + /// < Djibouti (Since 3.0) + static const int PHONE_NUMBER_REGION_DJIBOUTI = 152; + + /// < Denmark (Since 3.0) + static const int PHONE_NUMBER_REGION_DENMARK = 153; + + /// < Ecuador (Since 3.0) + static const int PHONE_NUMBER_REGION_ECUADOR = 154; + + /// < Eritrea (Since 3.0) + static const int PHONE_NUMBER_REGION_ERITREA = 155; + + /// < Fiji (Since 3.0) + static const int PHONE_NUMBER_REGION_FIJI = 156; + + /// < Falkland Islands (Since 3.0) + static const int PHONE_NUMBER_REGION_FALKLAND_ISLANDS = 157; + + /// < Micronesia, Federated States of (Since 3.0) + static const int PHONE_NUMBER_REGION_MICRONESIA = 158; + + /// < Faroe Islands (Since 3.0) + static const int PHONE_NUMBER_REGION_FAROE_ISLANDS = 159; + + /// < Georgia (Since 3.0) + static const int PHONE_NUMBER_REGION_GEORGIA = 160; + + /// < French Guiana (Since 3.0) + static const int PHONE_NUMBER_REGION_FRENCH_GUIANA = 161; + + /// < Gibraltar (Since 3.0) + static const int PHONE_NUMBER_REGION_GIBRALTAR = 162; + + /// < Guadeloupe (Since 3.0) + static const int PHONE_NUMBER_REGION_GUADELOUPE = 163; + + /// < Equatorial Guinea (Since 3.0) + static const int PHONE_NUMBER_REGION_EQUATORIAL_GUINEA = 164; + + /// < Guatemala (Since 3.0) + static const int PHONE_NUMBER_REGION_GUATEMALA = 165; + + /// < Guyana (Since 3.0) + static const int PHONE_NUMBER_REGION_GUYANA = 166; + + /// < Chinese Hong Kong (Since 3.0) + static const int PHONE_NUMBER_REGION_HONG_KONG = 167; + + /// < Honduras (Since 3.0) + static const int PHONE_NUMBER_REGION_HONDURAS = 168; + + /// < Croatia (Since 3.0) + static const int PHONE_NUMBER_REGION_CROATIA = 169; + + /// < Haiti (Since 3.0) + static const int PHONE_NUMBER_REGION_HAITI = 170; + + /// < Israel (Since 3.0) + static const int PHONE_NUMBER_REGION_ISRAEL = 171; + + /// < British Indian Ocean Territory / Diego Garcia (Since 3.0) + static const int PHONE_NUMBER_REGION_DIEGO_GARCIA = 172; + + /// < Iraq (Since 3.0) + static const int PHONE_NUMBER_REGION_IRAQ = 173; + + /// < Kyrgyzstan (Since 3.0) + static const int PHONE_NUMBER_REGION_KYRGYZSTAN = 174; + + /// < Cambodia (Since 3.0) + static const int PHONE_NUMBER_REGION_CAMBODIA = 175; + + /// < Korea, Dem. People's Rep. of (Since 3.0) + static const int PHONE_NUMBER_REGION_NORTH_KOREA = 176; + + /// < Kuwait (Since 3.0) + static const int PHONE_NUMBER_REGION_KUWAIT = 177; + + /// < Lao People's Dem. Rep. (Since 3.0) + static const int PHONE_NUMBER_REGION_LAOS = 178; + + /// < Lebanon (Since 3.0) + static const int PHONE_NUMBER_REGION_LEBANON = 179; + + /// < Liechtenstein (Since 3.0) + static const int PHONE_NUMBER_REGION_LIECHTENSTEIN = 180; + + /// < Liberia (Since 3.0) + static const int PHONE_NUMBER_REGION_LIBERIA = 181; + + /// < Libya (Soc. People's Libyan Arab Jamahiriya) (Since 3.0) + static const int PHONE_NUMBER_REGION_LIBYA = 182; + + /// < Monaco (Since 3.0) + static const int PHONE_NUMBER_REGION_MONACO = 183; + + /// < Montenegro (Since 3.0) + static const int PHONE_NUMBER_REGION_MONTENEGRO = 184; + + /// < Saint-Martin, French Antilles (Since 3.0) + static const int PHONE_NUMBER_REGION_SAINT_MARTIN = 185; + + /// < Marshall Islands (Since 3.0) + static const int PHONE_NUMBER_REGION_MARSHALL_ISLANDS = 186; + + /// < Mali (Since 3.0) + static const int PHONE_NUMBER_REGION_MALI = 187; + + /// < Myanmar (Since 3.0) + static const int PHONE_NUMBER_REGION_MYANMAR = 188; + + /// < Mongolia (Since 3.0) + static const int PHONE_NUMBER_REGION_MONGOLIA = 189; + + /// < Macao, China (Since 3.0) + static const int PHONE_NUMBER_REGION_MACAO = 190; + + /// < Martinique (French Dept. of) (Since 3.0) + static const int PHONE_NUMBER_REGION_MARTINIQUE = 191; + + /// < Malta (Since 3.0) + static const int PHONE_NUMBER_REGION_MALTA = 192; + + /// < Maldives (Since 3.0) + static const int PHONE_NUMBER_REGION_MALDIVES = 193; + + /// < Malawi (Since 3.0) + static const int PHONE_NUMBER_REGION_MALAWI = 194; + + /// < Mexico (Since 3.0) + static const int PHONE_NUMBER_REGION_MEXICO = 195; + + /// < Malaysia (Since 3.0) + static const int PHONE_NUMBER_REGION_MALAYSIA = 196; + + /// < New Caledonia (Territoire francais d'outre-mer) (Since 3.0) + static const int PHONE_NUMBER_REGION_NEW_CALEDONIA = 197; + + /// < Niger (Since 3.0) + static const int PHONE_NUMBER_REGION_NIGER = 198; + + /// < Norfolk Island (Since 3.0) + static const int PHONE_NUMBER_REGION_NORFOLK_ISLAND = 199; + + /// < Nicaragua (Since 3.0) + static const int PHONE_NUMBER_REGION_NICARAGUA = 200; + + /// < Nepal (Since 3.0) + static const int PHONE_NUMBER_REGION_NEPAL = 201; + + /// < Nauru (Since 3.0) + static const int PHONE_NUMBER_REGION_NAURU = 202; + + /// < Niue (Since 3.0) + static const int PHONE_NUMBER_REGION_NIUE = 203; + + /// < New Zealand (Since 3.0) + static const int PHONE_NUMBER_REGION_NEW_ZEALAND = 204; + + /// < Oman (Since 3.0) + static const int PHONE_NUMBER_REGION_OMAN = 205; + + /// < Panama (Since 3.0) + static const int PHONE_NUMBER_REGION_PANAMA = 206; + + /// < French Polynesia (Tahiti) (Territoire francais d'outre-mer) (Since 3.0) + static const int PHONE_NUMBER_REGION_FRENCH_POLYNESIA = 207; + + /// < Papua New Guinea (Since 3.0) + static const int PHONE_NUMBER_REGION_PAPUA_NEW_GUINEA = 208; + + /// < Philippines (Since 3.0) + static const int PHONE_NUMBER_REGION_PHILIPPINES = 209; + + /// < Pakistan (Since 3.0) + static const int PHONE_NUMBER_REGION_PAKISTAN = 210; + + /// < Saint Pierre and Miquelon (Collectivite territoriale de la Republique francaise) (Since 3.0) + static const int PHONE_NUMBER_REGION_SAINT_PIERRE_AND_MIQUELON = 211; + + /// < Palestinian Authority (Since 3.0) + static const int PHONE_NUMBER_REGION_PALESTINIAN_AUTHORITY = 212; + + /// < Palau (Since 3.0) + static const int PHONE_NUMBER_REGION_PALAU = 213; + + /// < Paraguay (Since 3.0) + static const int PHONE_NUMBER_REGION_PARAGUAY = 214; + + /// < Qatar (Since 3.0) + static const int PHONE_NUMBER_REGION_QATAR = 215; + + /// < Reunion (French Departments and Territories in the Indian Ocean) (Since 3.0) + static const int PHONE_NUMBER_REGION_REUNION = 216; + + /// < Rwanda (Since 3.0) + static const int PHONE_NUMBER_REGION_RWANDA = 217; + + /// < Solomon Islands (Since 3.0) + static const int PHONE_NUMBER_REGION_SOLOMON_ISLANDS = 218; + + /// < Seychelles (Since 3.0) + static const int PHONE_NUMBER_REGION_SEYCHELLES = 219; + + /// < Singapore (Since 3.0) + static const int PHONE_NUMBER_REGION_SINGAPORE = 220; + + /// < Slovenia (Since 3.0) + static const int PHONE_NUMBER_REGION_SLOVENIA = 221; + + /// < San Marino (Since 3.0) + static const int PHONE_NUMBER_REGION_SAN_MARINO = 222; + + /// < Suriname (Since 3.0) + static const int PHONE_NUMBER_REGION_SURINAME = 223; + + /// < South Sudan (Since 3.0) + static const int PHONE_NUMBER_REGION_SOUTH_SUDAN = 224; + + /// < El Salvador (Since 3.0) + static const int PHONE_NUMBER_REGION_EL_SALVADOR = 225; + + /// < Syrian Arab Republic (Since 3.0) + static const int PHONE_NUMBER_REGION_SYRIAN_ARAB_REPUBLIC = 226; + + /// < Chad (Since 3.0) + static const int PHONE_NUMBER_REGION_CHAD = 227; + + /// < Tajikistan (Since 3.0) + static const int PHONE_NUMBER_REGION_TAJIKISTAN = 228; + + /// < Tokelau (Since 3.0) + static const int PHONE_NUMBER_REGION_TOKELAU = 229; + + /// < Timor-Leste (East Timor) (Since 3.0) + static const int PHONE_NUMBER_REGION_TIMOR_LESTE = 230; + + /// < Turkmenistan (Since 3.0) + static const int PHONE_NUMBER_REGION_TURKMENISTAN = 231; + + /// < Tonga (Since 3.0) + static const int PHONE_NUMBER_REGION_TONGA = 232; + + /// < Tuvalu (Since 3.0) + static const int PHONE_NUMBER_REGION_TUVALU = 233; + + /// < Tanzania (Since 3.0) + static const int PHONE_NUMBER_REGION_TANZANIA = 234; + + /// < Ukraine (Since 3.0) + static const int PHONE_NUMBER_REGION_UKRAINE = 235; + + /// < Uruguay (Since 3.0) + static const int PHONE_NUMBER_REGION_URUGUAY = 236; + + /// < Uzbekistan (Since 3.0) + static const int PHONE_NUMBER_REGION_UZBEKISTAN = 237; + + /// < Vatican City (Since 3.0) + static const int PHONE_NUMBER_REGION_VATICAN_CITY = 238; + + /// < Vanuatu (Since 3.0) + static const int PHONE_NUMBER_REGION_VANUATU = 239; + + /// < Wallis and Futuna (Territoire francais d'outre-mer) (Since 3.0) + static const int PHONE_NUMBER_REGION_WALLIS_AND_FUTUNA = 240; + + /// < Samoa (Since 3.0) + static const int PHONE_NUMBER_REGION_SAMOA = 241; + + /// < Yemen (Since 3.0) + static const int PHONE_NUMBER_REGION_YEMEN = 242; + + /// < Mayotte (Since 3.0) + static const int PHONE_NUMBER_REGION_MAYOTTE = 243; + + /// < Current System Value (Since 3.0) + static const int PHONE_NUMBER_REGION_SYSTEM = 244; + static const int PHONE_NUMBER_REGION_MAX = 245; +} + +/// @brief Enumeration for match type. +/// @since_tizen 4.0 +abstract class phone_number_blocking_rule_match_type_e { + /// < Exact match + static const int PHONE_NUMBER_MATCH_TYPE_EXACTLY = 0; + + /// < Includes + static const int PHONE_NUMBER_MATCH_TYPE_INCLUDES = 1; + + /// < Starts with + static const int PHONE_NUMBER_MATCH_TYPE_STARTS_WITH = 2; + + /// < Ends with + static const int PHONE_NUMBER_MATCH_TYPE_ENDS_WITH = 3; +} + +/// @brief Enumeration for phone number errors. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class phone_number_error_e { + /// < Successful + static const int PHONE_NUMBER_ERROR_NONE = 0; + + /// < I/O Error + static const int PHONE_NUMBER_ERROR_IO_ERROR = -5; + + /// < Out of memory + static const int PHONE_NUMBER_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid parameter + static const int PHONE_NUMBER_ERROR_INVALID_PARAMETER = -22; + + /// < FS Full + static const int PHONE_NUMBER_ERROR_FILE_NO_SPACE_ON_DEVICE = -28; + + /// < Permission denied + static const int PHONE_NUMBER_ERROR_PERMISSION_DENIED = -13; + + /// < Not supported + static const int PHONE_NUMBER_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Requested data does not exist + static const int PHONE_NUMBER_ERROR_NO_DATA = -61; + + /// < Internal error (Since 3.0) + static const int PHONE_NUMBER_ERROR_SYSTEM = -33685265; + + /// < No access to the database (Since 4.0) + static const int PHONE_NUMBER_ERROR_DB_FAILED = -33685502; + + /// < Unknown IPC error (Since 4.0) + static const int PHONE_NUMBER_ERROR_IPC = -33685313; +} + +/// @brief Enumeration for device's error code. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class device_error_e { + /// < Successful + static const int DEVICE_ERROR_NONE = 0; + + /// < Operation not permitted + static const int DEVICE_ERROR_OPERATION_FAILED = -1; + + /// < Permission denied + static const int DEVICE_ERROR_PERMISSION_DENIED = -13; + + /// < Invalid parameter + static const int DEVICE_ERROR_INVALID_PARAMETER = -22; + + /// < Operation already in progress + static const int DEVICE_ERROR_ALREADY_IN_PROGRESS = -114; + + /// < Not supported in this device + static const int DEVICE_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Device or resource busy + static const int DEVICE_ERROR_RESOURCE_BUSY = -16; + + /// < Not initialized + static const int DEVICE_ERROR_NOT_INITIALIZED = -37748717; +} + +/// @brief Enumeration for the battery level status. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class device_battery_level_e { + /// < The battery goes empty. Prepare for the safe termination of the application, because the device starts a shutdown process soon after entering this level. + static const int DEVICE_BATTERY_LEVEL_EMPTY = 0; + + /// < The battery charge is at a critical state. You may have to stop using multimedia features, because they are not guaranteed to work correctly at this battery status. + static const int DEVICE_BATTERY_LEVEL_CRITICAL = 1; + + /// < The battery has little charge left. + static const int DEVICE_BATTERY_LEVEL_LOW = 2; + + /// < The battery status is not to be careful. + static const int DEVICE_BATTERY_LEVEL_HIGH = 3; + + /// < The battery status is fully charged. It means no more charge. + static const int DEVICE_BATTERY_LEVEL_FULL = 4; +} + +/// @brief Enumeration for battery health information. +/// @since_tizen 3.0 +abstract class device_battery_health_e { + /// < The battery health is good + static const int DEVICE_BATTERY_HEALTH_GOOD = 0; + + /// < The temperature of the battery is cold + static const int DEVICE_BATTERY_HEALTH_COLD = 1; + + /// < The battery is dead + static const int DEVICE_BATTERY_HEALTH_DEAD = 2; + + /// < The temperature of the battery is high + static const int DEVICE_BATTERY_HEALTH_OVER_HEAT = 3; + + /// < The battery is in over voltage state + static const int DEVICE_BATTERY_HEALTH_OVER_VOLTAGE = 4; +} + +/// @brief Enumeration for power source information. +/// @since_tizen 3.0 +abstract class device_battery_power_source_e { + /// < There is no power source + static const int DEVICE_BATTERY_POWER_SOURCE_NONE = 0; + + /// < AC power cable is connected + static const int DEVICE_BATTERY_POWER_SOURCE_AC = 1; + + /// < USB power cable is connected + static const int DEVICE_BATTERY_POWER_SOURCE_USB = 2; + + /// < Power is provided by a wireless source + static const int DEVICE_BATTERY_POWER_SOURCE_WIRELESS = 3; +} + +/// @brief Enumeration for battery property information. +/// @since_tizen 3.0 +abstract class device_battery_property_e { + /// < The battery capacity (0 ~ 100 %) + static const int DEVICE_BATTERY_PROPERTY_CAPACITY = 0; + + /// < The battery current (uA) + static const int DEVICE_BATTERY_PROPERTY_CURRENT_NOW = 1; + + /// < The average battery current (uA) + static const int DEVICE_BATTERY_PROPERTY_CURRENT_AVERAGE = 2; +} + +/// @brief Enumeration for battery status information. +/// @since_tizen 3.0 +abstract class device_battery_status_e { + /// < Battery is charging + static const int DEVICE_BATTERY_STATUS_CHARGING = 0; + + /// < Battery is discharging + static const int DEVICE_BATTERY_STATUS_DISCHARGING = 1; + + /// < Battery is fully charged + static const int DEVICE_BATTERY_STATUS_FULL = 2; + + /// < Battery is not charging + static const int DEVICE_BATTERY_STATUS_NOT_CHARGING = 3; +} + +/// @brief Enumeration for the device state callback. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class device_callback_e { + /// < Called when a battery charge percentage is changed + static const int DEVICE_CALLBACK_BATTERY_CAPACITY = 0; + + /// < Called when a battery level is changed + static const int DEVICE_CALLBACK_BATTERY_LEVEL = 1; + + /// < Called when battery charging state is changed + static const int DEVICE_CALLBACK_BATTERY_CHARGING = 2; + + /// < Called when a display state is changed + static const int DEVICE_CALLBACK_DISPLAY_STATE = 3; + + /// < Called when a flash brightness is changed (Since Tizen @if Mobile 2.4 @elseif WEARABLE 3.0 @endif) + static const int DEVICE_CALLBACK_FLASH_BRIGHTNESS = 4; + static const int DEVICE_CALLBACK_MAX = 5; +} + +/// @brief Enumeration for the available display states. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class display_state_e { + /// < Normal state + static const int DISPLAY_STATE_NORMAL = 0; + + /// < Screen dim state + static const int DISPLAY_STATE_SCREEN_DIM = 1; + + /// < Screen off state + static const int DISPLAY_STATE_SCREEN_OFF = 2; +} + +/// @brief Enumeration for custom LED flags. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class led_custom_flags { + /// < blink LED + static const int LED_CUSTOM_DUTY_ON = 1; + + /// < Default flag + static const int LED_CUSTOM_DEFAULT = 1; +} + +/// @brief Enumeration for lock type. +/// @details Each enum ensures that the suitable device is on until all the lock requests have been released or after a timeout. +/// +/// +/// +/// +/// +///
Enum TypeCPUBrightness(Display)
POWER_LOCK_CPUONOFF
POWER_LOCK_DISPLAYONON(Normal)
POWER_LOCK_DISPLAY_DIMONON(Dim)
+/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +/// @remarks An application can lock the specific type. +/// @remarks These enums are mutually exclusive. +/// @remarks You cannot combine with an enum below. +abstract class power_lock_e { + /// < CPU lock + static const int POWER_LOCK_CPU = 0; + + /// < Display normal lock + static const int POWER_LOCK_DISPLAY = 1; + + /// < Display dim lock + static const int POWER_LOCK_DISPLAY_DIM = 2; +} + +/// @brief Enumeration for Dlog Error. +/// @if MOBILE @since_tizen 2.3 @elseif WEARABLE @since_tizen 2.3.1 @endif +abstract class dlog_error_e { + /// < Successful + static const int DLOG_ERROR_NONE = 0; + + /// < Invalid parameter + static const int DLOG_ERROR_INVALID_PARAMETER = -22; + + /// < Operation not permitted + static const int DLOG_ERROR_NOT_PERMITTED = -1; +} + +/// @brief Enumeration for log priority values in ascending priority order. +/// @if MOBILE @since_tizen 2.3 @elseif WEARABLE @since_tizen 2.3.1 @endif +abstract class log_priority { + /// < Keep this always at the start + static const int DLOG_UNKNOWN = 0; + + /// < Default + static const int DLOG_DEFAULT = 1; + + /// < Verbose + static const int DLOG_VERBOSE = 2; + + /// < Debug + static const int DLOG_DEBUG = 3; + + /// < Info + static const int DLOG_INFO = 4; + + /// < Warning + static const int DLOG_WARN = 5; + + /// < Error + static const int DLOG_ERROR = 6; + + /// < Fatal + static const int DLOG_FATAL = 7; + + /// < Silent + static const int DLOG_SILENT = 8; + + /// < Keep this always at the end. + static const int DLOG_PRIO_MAX = 9; +} + +/// @brief Enumeration for feedback interface type. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class feedback_type_e { + /// < Feedback type none + static const int FEEDBACK_TYPE_NONE = 0; + + /// < Feedback type for sound + static const int FEEDBACK_TYPE_SOUND = 1; + + /// < Feedback type for vibration + static const int FEEDBACK_TYPE_VIBRATION = 2; + static const int FEEDBACK_TYPE_END = 3; +} + +/// @brief Enumeration for feedback interface of the system pre-defined patterns. +/// @details Each feedback pattern can have separate media files of each types. +/// But depending on vendor design, pattern may not have any type of file. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class feedback_pattern_e { + static const int FEEDBACK_PATTERN_NONE = -1; + + /// < Feedback pattern when general touch + static const int FEEDBACK_PATTERN_TAP = 0; + + /// < Feedback pattern when touch text key + static const int FEEDBACK_PATTERN_SIP = 1; + + /// < Feedback pattern when touch numeric 0 key + static const int FEEDBACK_PATTERN_KEY0 = 6; + + /// < Feedback pattern when touch numeric 1 key + static const int FEEDBACK_PATTERN_KEY1 = 7; + + /// < Feedback pattern when touch numeric 2 key + static const int FEEDBACK_PATTERN_KEY2 = 8; + + /// < Feedback pattern when touch numeric 3 key + static const int FEEDBACK_PATTERN_KEY3 = 9; + + /// < Feedback pattern when touch numeric 4 key + static const int FEEDBACK_PATTERN_KEY4 = 10; + + /// < Feedback pattern when touch numeric 5 key + static const int FEEDBACK_PATTERN_KEY5 = 11; + + /// < Feedback pattern when touch numeric 6 key + static const int FEEDBACK_PATTERN_KEY6 = 12; + + /// < Feedback pattern when touch numeric 7 key + static const int FEEDBACK_PATTERN_KEY7 = 13; + + /// < Feedback pattern when touch numeric 8 key + static const int FEEDBACK_PATTERN_KEY8 = 14; + + /// < Feedback pattern when touch numeric 9 key + static const int FEEDBACK_PATTERN_KEY9 = 15; + + /// < Feedback pattern when touch star key + static const int FEEDBACK_PATTERN_KEY_STAR = 16; + + /// < Feedback pattern when touch sharp key + static const int FEEDBACK_PATTERN_KEY_SHARP = 17; + + /// < Feedback pattern when touch backspace key + static const int FEEDBACK_PATTERN_KEY_BACK = 18; + + /// < Feedback pattern when touch hold + static const int FEEDBACK_PATTERN_HOLD = 19; + + /// < Feedback pattern when press hardware key + static const int FEEDBACK_PATTERN_HW_TAP = 21; + + /// < Feedback pattern when holding press hardware key + static const int FEEDBACK_PATTERN_HW_HOLD = 22; + + /// < Feedback pattern when incoming a message + static const int FEEDBACK_PATTERN_MESSAGE = 23; + + /// < Feedback pattern when incoming an email + static const int FEEDBACK_PATTERN_EMAIL = 25; + + /// < Feedback pattern when alert wake up call + static const int FEEDBACK_PATTERN_WAKEUP = 27; + + /// < Feedback pattern when alert schedule alarm + static const int FEEDBACK_PATTERN_SCHEDULE = 29; + + /// < Feedback pattern when alert timer + static const int FEEDBACK_PATTERN_TIMER = 31; + + /// < Feedback pattern when alert general event + static const int FEEDBACK_PATTERN_GENERAL = 33; + + /// < Feedback pattern when power on + static const int FEEDBACK_PATTERN_POWERON = 36; + + /// < Feedback pattern when power off + static const int FEEDBACK_PATTERN_POWEROFF = 37; + + /// < Feedback pattern when connecting charger + static const int FEEDBACK_PATTERN_CHARGERCONN = 38; + + /// < Feedback pattern when occuring charging error + static const int FEEDBACK_PATTERN_CHARGING_ERROR = 40; + + /// < Feedback pattern when full charged + static const int FEEDBACK_PATTERN_FULLCHARGED = 42; + + /// < Feedback pattern when low battery + static const int FEEDBACK_PATTERN_LOWBATT = 44; + + /// < Feedback pattern when lock + static const int FEEDBACK_PATTERN_LOCK = 46; + + /// < Feedback pattern when unlock + static const int FEEDBACK_PATTERN_UNLOCK = 47; + + /// < Feedback pattern when turn on vibration mode + static const int FEEDBACK_PATTERN_VIBRATION_ON = 55; + + /// < Feedback pattern when turn off silent mode + static const int FEEDBACK_PATTERN_SILENT_OFF = 56; + + /// < Feedback pattern when connecting with bluetooth + static const int FEEDBACK_PATTERN_BT_CONNECTED = 57; + + /// < Feedback pattern when disconnecting with bluetooth + static const int FEEDBACK_PATTERN_BT_DISCONNECTED = 58; + + /// < Feedback pattern when list reorder + static const int FEEDBACK_PATTERN_LIST_REORDER = 62; + + /// < Feedback pattern when list slider sweep + static const int FEEDBACK_PATTERN_LIST_SLIDER = 63; + + /// < Feedback pattern when pressed volume key + static const int FEEDBACK_PATTERN_VOLUME_KEY = 64; + + /// < Feedback pattern for short feedback (Since 4.0) + static const int FEEDBACK_PATTERN_SYSTEM_SHORT = 107; + + /// < Feedback pattern for error (Since 4.0) + static const int FEEDBACK_PATTERN_SYSTEM_ERROR = 108; + + /// < Feedback pattern for long feedback (Since 4.0) + static const int FEEDBACK_PATTERN_SYSTEM_LONG = 112; + + /// < Feedback pattern for normal feedback (Since 4.0) + static const int FEEDBACK_PATTERN_SYSTEM_MID = 113; + + /// < Feedback pattern for end of effect (Since 4.0) + static const int FEEDBACK_PATTERN_END_EFFECT = 117; + + /// < Feedback pattern for strong buzz (Since 4.0) + static const int FEEDBACK_PATTERN_GENERAL_STRONG_BUZZ = 135; + static const int FEEDBACK_PATTERN_END = 10000; +} + +/// @brief Enumeration for the Feedback API error codes. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class feedback_error_e { + /// < Successful + static const int FEEDBACK_ERROR_NONE = 0; + + /// < Operation failed + static const int FEEDBACK_ERROR_OPERATION_FAILED = -1; + + /// < Invalid parameter + static const int FEEDBACK_ERROR_INVALID_PARAMETER = -22; + + /// < Not supported in this device + static const int FEEDBACK_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Permission denied + static const int FEEDBACK_ERROR_PERMISSION_DENIED = -13; + + /// < Not initialized + static const int FEEDBACK_ERROR_NOT_INITIALIZED = -38404095; +} + +/// @brief Enumeration for error codes of a media key. +/// +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class media_key_error_e { + /// < Successful + static const int MEDIA_KEY_ERROR_NONE = 0; + + /// < Invalid parameter + static const int MEDIA_KEY_ERROR_INVALID_PARAMETER = -22; + + /// < Reserve/Release failed + static const int MEDIA_KEY_ERROR_OPERATION_FAILED = -37879807; +} + +/// @brief Enumeration for media keys. +/// +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class media_key_e { + /// < Play key + static const int MEDIA_KEY_PLAY = 0; + + /// < Stop key + static const int MEDIA_KEY_STOP = 1; + + /// < Pause key + static const int MEDIA_KEY_PAUSE = 2; + + /// < Previous key + static const int MEDIA_KEY_PREVIOUS = 3; + + /// < Next key + static const int MEDIA_KEY_NEXT = 4; + + /// < Fastforward key + static const int MEDIA_KEY_FASTFORWARD = 5; + + /// < Rewind key + static const int MEDIA_KEY_REWIND = 6; + + /// < Playpause key + static const int MEDIA_KEY_PLAYPAUSE = 7; + + /// < Media key for earjack + static const int MEDIA_KEY_MEDIA = 8; + + /// < Unknown key + static const int MEDIA_KEY_UNKNOWN = 9; +} + +/// @brief Enumeration for event statuses of a media key. +/// +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class media_key_event_e { + /// < Pressed status + static const int MEDIA_KEY_STATUS_PRESSED = 0; + + /// < Released status + static const int MEDIA_KEY_STATUS_RELEASED = 1; + + /// < Unknown status + static const int MEDIA_KEY_STATUS_UNKNOWN = 2; +} + +/// @brief Enumeration for error codes for runtime information. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class runtime_info_error_e { + /// < Successful + static const int RUNTIME_INFO_ERROR_NONE = 0; + + /// < Invalid parameter + static const int RUNTIME_INFO_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int RUNTIME_INFO_ERROR_OUT_OF_MEMORY = -12; + + /// < An input/output error occurred when read value from system + static const int RUNTIME_INFO_ERROR_IO_ERROR = -5; + + /// < Remote I/O error occurred + static const int RUNTIME_INFO_ERROR_REMOTE_IO = -121; + + /// < No permission to use the api + static const int RUNTIME_INFO_ERROR_PERMISSION_DENIED = -13; + + /// < Not supported parameter + static const int RUNTIME_INFO_ERROR_NOT_SUPPORTED = -1073741822; + + /// < No data available (Since 3.0) + static const int RUNTIME_INFO_ERROR_NO_DATA = -61; +} + +/// @brief Enumeration for keys for runtime information. +/// @since_tizen @if WEARABLE 2.3.1 @else 2.3 @endif +abstract class runtime_info_key_e { + /// values; +} + +/// @brief Enumeration for sensor data accuracy. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class sensor_data_accuracy_e { + /// < Undefined + static const int SENSOR_DATA_ACCURACY_UNDEFINED = -1; + + /// < Not accurate + static const int SENSOR_DATA_ACCURACY_BAD = 0; + + /// < Moderately accurate + static const int SENSOR_DATA_ACCURACY_NORMAL = 1; + + /// < Highly accurate + static const int SENSOR_DATA_ACCURACY_GOOD = 2; + + /// < Very highly accurate + static const int SENSOR_DATA_ACCURACY_VERYGOOD = 3; +} + +/// @brief Enumeration for sensor listener behavior attributes +/// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif +abstract class sensor_attribute_e { + /// < Reference orientation of sensor data to be reported.@n + /// See #sensor_axis_e for available attribute values. + static const int SENSOR_ATTRIBUTE_AXIS_ORIENTATION = 1; + + /// < Pause-and-resume policy of sensors.@n + /// See #sensor_pause_e for available attribute values. + static const int SENSOR_ATTRIBUTE_PAUSE_POLICY = 2; +} + +abstract class sensor_option_e { + /// < Does not receive data when the LCD is off and in the power save mode + static const int SENSOR_OPTION_DEFAULT = 0; + + /// < Receives data when the LCD is off + static const int SENSOR_OPTION_ON_IN_SCREEN_OFF = 1; + + /// < Receives data in the power save mode + static const int SENSOR_OPTION_ON_IN_POWERSAVE_MODE = 2; + + /// < Receives data when the LCD is off and in the power save mode + static const int SENSOR_OPTION_ALWAYS_ON = 3; +} + +/// @brief Enumeration for reference orientations of sensor data +/// @details The sensor's physical orientation may differ from what applications are aware of, +/// in cases that the device has a rotated screen, physically or logically. +/// For example, a watch device may have right hand mode, which logically rotates +/// the display 180 degrees. +/// Applications may not be aware of such situations, thus they may receives +/// sensor data inverted in X and Y directions. +/// With #SENSOR_AXIS_DISPLAY_ORIENTED option, applications can get data that +/// are properly aligned with the orientation of which they are aware.@n +/// By default, #SENSOR_AXIS_DISPLAY_ORIENTED is used. +/// If you need to use the data that are not affected by display orientations, +/// #SENSOR_AXIS_DEVICE_ORIENTED needs to be set. +/// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif +abstract class sensor_axis_e { + /// < Using the device orientation as the reference coordinate system + static const int SENSOR_AXIS_DEVICE_ORIENTED = 1; + + /// < Using the display orientation as the reference coordinate system + static const int SENSOR_AXIS_DISPLAY_ORIENTED = 2; +} + +/// @brief Enumeration for pause policies of sensor listeners +/// @details To be power-efficient, you can set the policy of how to pause and resume +/// a sensor listener regarding the system status. +/// By default, #SENSOR_PAUSE_ALL is used to obtain the maximum power efficiency. +/// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif +abstract class sensor_pause_e { + /// < The sensor will not pause, unless the system goes into sleep mode + static const int SENSOR_PAUSE_NONE = 0; + + /// < The sensor pauses while the display is off + static const int SENSOR_PAUSE_ON_DISPLAY_OFF = 1; + + /// < The sensor pauses while the power-save mode is enabled + static const int SENSOR_PAUSE_ON_POWERSAVE_MODE = 2; + + /// < The sensor pauses in all the above cases + static const int SENSOR_PAUSE_ALL = 3; +} + +class _sensor_provider_s extends ffi.Opaque {} + +/// @brief Enumeration for option parameters for sensor recording. +/// @details None, one, or more option parameters can be set to #sensor_recorder_option_h, +/// then applications can request to record a specific sensor with the parameters via +/// sensor_recorder_start(). +/// If a parameter is not supported for the specified sensor type, it will be ignored. +/// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif +abstract class sensor_recorder_option_e { + /// < Desired retention period for the recorded sensor data (hours); int; + static const int SENSOR_RECORDER_OPTION_RETENTION_PERIOD = 0; + + /// < Desired interval between data records (minutes); int; see #sensor_recorder_interval_e + static const int SENSOR_RECORDER_OPTION_INTERVAL = 1; +} + +/// @brief Enumeration for intervals between data records. +/// @details Some sensor types including #SENSOR_HRM may not fit to continuous monitoring and recording. +/// To reduce the battery use for recording such sensors, recording interval between each +/// sensor data is chosen. For example, an application set the interval of 1 hour, +/// the platform tries to retrieve the sensor data only once per hour, thus it will be more +/// battery efficient than to listen the sensor data continuously.@n +/// If the application does not set the interval explicitly, the default value is chosen. +/// The default values are differ from sensor to sensor. +/// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif +/// @remarks If more than one applications set different intervals, the shortest value is chosen. +abstract class sensor_recorder_interval_e { + /// < 10 Minutes + static const int SENSOR_RECORDER_INTERVAL_10_MINUTES = 10; + + /// < 1 Hour + static const int SENSOR_RECORDER_INTERVAL_1_HOUR = 60; + + /// < 3 Hours + static const int SENSOR_RECORDER_INTERVAL_3_HOURS = 180; + + /// < 6 Hours + static const int SENSOR_RECORDER_INTERVAL_6_HOURS = 360; + + /// < 12 Hours + static const int SENSOR_RECORDER_INTERVAL_12_HOURS = 720; + + /// < 1 Day + static const int SENSOR_RECORDER_INTERVAL_1_DAY = 1440; +} + +/// @brief Enumeration for filtering and aggregation parameters for querying sensor records. +/// @details None, one, or more query parameters can be set to #sensor_recorder_query_h, +/// to specify the data to be retrieved via sensor_recorder_read(). +/// If a necessary parameter is not set, the default value is chosen. +/// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif +abstract class sensor_recorder_query_e { + /// < Start time of the data to be queried (Epoch); time_t; If unspecified, 1 day ago + static const int SENSOR_RECORDER_QUERY_START_TIME = 0; + + /// < End time of the data to be queried (Epoch); time_t; If unspecified, the current time + static const int SENSOR_RECORDER_QUERY_END_TIME = 1; + + /// < The anchor time to slice the querying duration of time (Epoch); time_t; + /// It needs to be set with #SENSOR_RECORDER_QUERY_TIME_INTERVAL, otherwise, it is ignored + static const int SENSOR_RECORDER_QUERY_ANCHOR_TIME = 2; + + /// < The interval of each sliced querying duration (minutes); int + static const int SENSOR_RECORDER_QUERY_TIME_INTERVAL = 3; +} + +/// @brief Enumeration for data attributes can be contained in #sensor_recorder_data_h. +/// @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif +/// @see sensor_recorder_data_get_int() +/// @see sensor_recorder_data_get_double() +abstract class sensor_recorder_data_e { + /// < Count of both walking and running steps; int + /// @if WEARABLE (Since 3.0) @endif + static const int SENSOR_RECORDER_DATA_STEPS = 0; + + /// < Count of walking steps; int + /// @if WEARABLE (Since 3.0) @endif + static const int SENSOR_RECORDER_DATA_WALK_STEPS = 1; + + /// < Count of running steps; int + /// @if WEARABLE (Since 3.0) @endif + static const int SENSOR_RECORDER_DATA_RUN_STEPS = 2; + + /// < Distance walked or ran (m); double + /// @if WEARABLE (Since 3.0) @endif + static const int SENSOR_RECORDER_DATA_DISTANCE = 3; + + /// < Calorie burned (kcal); double + /// @if WEARABLE (Since 3.0) @endif + static const int SENSOR_RECORDER_DATA_CALORIE = 4; + + /// < Heart Rate (BPM); int + /// @if WEARABLE (Since 3.0) @endif + static const int SENSOR_RECORDER_DATA_HEART_RATE = 16; + + /// < Sleep state; int; One of #sensor_sleep_state_e + /// @if WEARABLE (Since 3.0) @endif + static const int SENSOR_RECORDER_DATA_SLEEP_STATE = 32; + + /// < Pressure; double + static const int SENSOR_RECORDER_DATA_PRESSURE = 48; + + /// < Max pressure; double + static const int SENSOR_RECORDER_DATA_MAX_PRESSURE = 49; + + /// < Min pressure; double + static const int SENSOR_RECORDER_DATA_MIN_PRESSURE = 50; + + /// < Average pressure; double + static const int SENSOR_RECORDER_DATA_AVERAGE_PRESSURE = 51; +} + +/// @brief Enumeration of the axis used in sensor_util_remap_coordinate_system(). +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class sensor_util_axis_e { + /// < -X + static const int SENSOR_UTIL_AXIS_MINUS_X = 0; + + /// < -Y + static const int SENSOR_UTIL_AXIS_MINUS_Y = 1; + + /// < -Z + static const int SENSOR_UTIL_AXIS_MINUS_Z = 2; + + /// < +X + static const int SENSOR_UTIL_AXIS_X = 3; + + /// < +Y + static const int SENSOR_UTIL_AXIS_Y = 4; + + /// < +Z + static const int SENSOR_UTIL_AXIS_Z = 5; + static const int sensor_util_axis_minus_x = 0; + static const int sensor_util_axis_minus_y = 1; + static const int sensor_util_axis_minus_z = 2; + static const int sensor_util_axis_x = 3; + static const int sensor_util_axis_y = 4; + static const int sensor_util_axis_z = 5; +} + +/// @brief Enumeration for Storage of error codes. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class storage_error_e { + /// < Successful + static const int STORAGE_ERROR_NONE = 0; + + /// < Invalid parameter + static const int STORAGE_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int STORAGE_ERROR_OUT_OF_MEMORY = -12; + + /// < Storage not supported + static const int STORAGE_ERROR_NOT_SUPPORTED = -6; + + /// < Operation failed + static const int STORAGE_ERROR_OPERATION_FAILED = -131054; +} + +/// @brief Enumeration for the storage types. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class storage_type_e { + /// < Internal device storage (built-in storage in a device, non-removable) + static const int STORAGE_TYPE_INTERNAL = 0; + + /// < External storage + static const int STORAGE_TYPE_EXTERNAL = 1; + + /// < Extended internal storage (External storage used as internal storage) (Since 4.0) + static const int STORAGE_TYPE_EXTENDED_INTERNAL = 2; +} + +/// @brief Enumeration for storage devices state. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class storage_state_e { + /// < Storage is present but cannot be mounted. Typically it happens if the file system of the storage is corrupted + static const int STORAGE_STATE_UNMOUNTABLE = -2; + + /// < Storage is not present + static const int STORAGE_STATE_REMOVED = -1; + + /// < Storage is present and mounted with read/write access + static const int STORAGE_STATE_MOUNTED = 0; + + /// < Storage is present and mounted with read only access + static const int STORAGE_STATE_MOUNTED_READ_ONLY = 1; +} + +/// @brief Enumeration for the storage directory types. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class storage_directory_e { + /// < Image directory + static const int STORAGE_DIRECTORY_IMAGES = 0; + + /// < Sounds directory + static const int STORAGE_DIRECTORY_SOUNDS = 1; + + /// < Videos directory + static const int STORAGE_DIRECTORY_VIDEOS = 2; + + /// < Camera directory + static const int STORAGE_DIRECTORY_CAMERA = 3; + + /// < Downloads directory + static const int STORAGE_DIRECTORY_DOWNLOADS = 4; + + /// < Music directory + static const int STORAGE_DIRECTORY_MUSIC = 5; + + /// < Documents directory + static const int STORAGE_DIRECTORY_DOCUMENTS = 6; + + /// < Others directory + static const int STORAGE_DIRECTORY_OTHERS = 7; + + /// < System ringtones directory. Only available for internal storage. + static const int STORAGE_DIRECTORY_SYSTEM_RINGTONES = 8; + static const int STORAGE_DIRECTORY_MAX = 9; +} + +/// @brief Enumeration for storage device types. +/// @since_tizen 3.0 +abstract class storage_dev_e { + /// < SD card device (external storage) + static const int STORAGE_DEV_EXT_SDCARD = 1001; + + /// < USB storage device (external storage) + static const int STORAGE_DEV_EXT_USB_MASS_STORAGE = 1002; + + /// < Extended internal storage device (External storage used as internal storage) (Since 4.0) + static const int STORAGE_DEV_EXTENDED_INTERNAL = 1003; +} + +class statvfs extends ffi.Struct { + @ffi.Uint64() + external int f_bsize; + + @ffi.Uint64() + external int f_frsize; + + @ffi.Uint64() + external int f_blocks; + + @ffi.Uint64() + external int f_bfree; + + @ffi.Uint64() + external int f_bavail; + + @ffi.Uint64() + external int f_files; + + @ffi.Uint64() + external int f_ffree; + + @ffi.Uint64() + external int f_favail; + + @ffi.Uint64() + external int f_fsid; + + @ffi.Int32() + external int __f_unused; + + @ffi.Uint64() + external int f_flag; + + @ffi.Uint64() + external int f_namemax; + + @ffi.Array.multi([6]) + external ffi.Array __f_spare; +} + +/// @brief Enumeration for system information error codes. +abstract class system_info_error_e { + /// < Successful + static const int SYSTEM_INFO_ERROR_NONE = 0; + + /// < Invalid parameter + static const int SYSTEM_INFO_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int SYSTEM_INFO_ERROR_OUT_OF_MEMORY = -12; + + /// < An input/output error occurred when reading value from system + static const int SYSTEM_INFO_ERROR_IO_ERROR = -5; + + /// < No permission to use the API + static const int SYSTEM_INFO_ERROR_PERMISSION_DENIED = -13; + + /// < Not supported parameter (Since 3.0) + static const int SYSTEM_INFO_ERROR_NOT_SUPPORTED = -1073741822; +} + +/// @internal +/// @brief It is not decided if it should be opened to public. +abstract class system_info_type_e { + static const int SYSTEM_INFO_BOOL = 0; + static const int SYSTEM_INFO_INT = 1; + static const int SYSTEM_INFO_DOUBLE = 2; + static const int SYSTEM_INFO_STRING = 3; +} + +/// @internal +/// @brief Enumeration for system information key. +abstract class system_info_key_e { + /// < @internal The model of the device + static const int SYSTEM_INFO_KEY_MODEL = 0; + + /// < @internal The version of the Tizen API + static const int SYSTEM_INFO_KEY_TIZEN_VERSION = 1; + + /// < @internal The name of platform + static const int SYSTEM_INFO_KEY_PLATFORM_NAME = 2; + + /// < @internal The name of tizen version + static const int SYSTEM_INFO_KEY_TIZEN_VERSION_NAME = 3; + + /// < @internal The manufacturer of the device + static const int SYSTEM_INFO_KEY_MANUFACTURER = 4; + + /// < @internal The CORE CPU architecture of model + static const int SYSTEM_INFO_KEY_CORE_CPU_ARCH = 5; + + /// < @internal The CORE CPU frequency of model + static const int SYSTEM_INFO_KEY_CORE_CPU_FREQ = 6; + + /// < @internal The build string of platform binary + static const int SYSTEM_INFO_KEY_BUILD_STRING = 7; + + /// < @internal The build date of platform binary + static const int SYSTEM_INFO_KEY_BUILD_DATE = 8; + + /// < @internal The build time of platform binary + static const int SYSTEM_INFO_KEY_BUILD_TIME = 9; + + /// < @internal The height of the screen in pixels + static const int SYSTEM_INFO_KEY_SCREEN_HEIGHT = 10; + + /// < @internal The width of the screen in pixels + static const int SYSTEM_INFO_KEY_SCREEN_WIDTH = 11; + + /// < @internal The physical screen height in millimeters + static const int SYSTEM_INFO_KEY_PHYSICAL_SCREEN_HEIGHT = 12; + + /// < @internal The physical screen width in millimeters + static const int SYSTEM_INFO_KEY_PHYSICAL_SCREEN_WIDTH = 13; + + /// < @internal Indicates whether the device supports tethering + static const int SYSTEM_INFO_KEY_TETHERING_SUPPORTED = 14; +} + +/// @brief Enumeration for system settings error. +/// @since_tizen 2.3 +abstract class system_settings_error_e { + /// < Successful + static const int SYSTEM_SETTINGS_ERROR_NONE = 0; + + /// < Invalid parameter + static const int SYSTEM_SETTINGS_ERROR_INVALID_PARAMETER = -22; + + /// < Out of memory + static const int SYSTEM_SETTINGS_ERROR_OUT_OF_MEMORY = -12; + + /// < Internal I/O error + static const int SYSTEM_SETTINGS_ERROR_IO_ERROR = -5; + + /// < Permission denied + static const int SYSTEM_SETTINGS_ERROR_PERMISSION_DENIED = -13; + + /// < Not supported @if MOBILE (Since 2.3.1) @endif + static const int SYSTEM_SETTINGS_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Not supported @if MOBILE (Since 2.3.1) @endif + static const int SYSTEM_SETTINGS_ERROR_CALL_UNSUPPORTED_API = -1073741822; + + /// < Current lock screen app set 'password' type + static const int SYSTEM_SETTINGS_ERROR_LOCKSCREEN_APP_PASSWORD_MODE = + -38141951; +} + +/// @brief Enumeration for System Settings Key. +/// @since_tizen 2.3 +abstract class system_settings_key_e { + /// < (string) The file path of the current ringtone + static const int SYSTEM_SETTINGS_KEY_INCOMING_CALL_RINGTONE = 0; + + /// < (string) The file path of the current home screen wallpaper + static const int SYSTEM_SETTINGS_KEY_WALLPAPER_HOME_SCREEN = 1; + + /// < (string) The file path of the current lock screen wallpaper + static const int SYSTEM_SETTINGS_KEY_WALLPAPER_LOCK_SCREEN = 2; + + /// < (int) The current system font size + static const int SYSTEM_SETTINGS_KEY_FONT_SIZE = 3; + + /// < (string) The current system font type + static const int SYSTEM_SETTINGS_KEY_FONT_TYPE = 4; + + /// < (bool) Indicates whether the motion service is activated + static const int SYSTEM_SETTINGS_KEY_MOTION_ACTIVATION = 5; + + /// < (string) The file path of the current email alert ringtone + static const int SYSTEM_SETTINGS_KEY_EMAIL_ALERT_RINGTONE = 6; + + /// < (bool) Indicates whether the USB debugging is enabled (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int SYSTEM_SETTINGS_KEY_USB_DEBUGGING_ENABLED = 7; + + /// < (bool) Indicates whether the 3G data network is enabled (Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) + static const int SYSTEM_SETTINGS_KEY_3G_DATA_NETWORK_ENABLED = 8; + + /// < (string) Indicates lockscreen app pkg name + static const int SYSTEM_SETTINGS_KEY_LOCKSCREEN_APP = 10; + + /// < (string) The current system default font type (only support Get) + static const int SYSTEM_SETTINGS_KEY_DEFAULT_FONT_TYPE = 11; + + /// < (string) Indicates the current country setting in the _ syntax. The country setting is in the ISO 639-2 format, and the region setting is in the ISO 3166-1 alpha-2 format + static const int SYSTEM_SETTINGS_KEY_LOCALE_COUNTRY = 12; + + /// < (string) Indicates the current language setting in the _ syntax. The language setting is in the ISO 639-2 format and the region setting is in the ISO 3166-1 alpha-2 format. + static const int SYSTEM_SETTINGS_KEY_LOCALE_LANGUAGE = 13; + + /// < (bool) Indicates whether the 24-hour clock is used. If the value is @c false, the 12-hour clock is used. + static const int SYSTEM_SETTINGS_KEY_LOCALE_TIMEFORMAT_24HOUR = 14; + + /// < (string) Indicates the current time zone. + static const int SYSTEM_SETTINGS_KEY_LOCALE_TIMEZONE = 15; + + /// < (int) Once System changes time, this event occurs to notify time change. + static const int SYSTEM_SETTINGS_KEY_TIME_CHANGED = 16; + + /// < GET (bool) Indicates whether the screen lock sound is enabled on the device. ex) LCD on/off sound + static const int SYSTEM_SETTINGS_KEY_SOUND_LOCK = 17; + + /// < GET (bool) Indicates whether the device is in the silent mode. + static const int SYSTEM_SETTINGS_KEY_SOUND_SILENT_MODE = 18; + + /// < GET (bool) Indicates whether the screen touch sound is enabled on the device. + static const int SYSTEM_SETTINGS_KEY_SOUND_TOUCH = 19; + + /// < GET (bool) Indicates whether rotation control is automatic. + static const int SYSTEM_SETTINGS_KEY_DISPLAY_SCREEN_ROTATION_AUTO = 20; + + /// < GET (string) Indicates device name. + static const int SYSTEM_SETTINGS_KEY_DEVICE_NAME = 21; + + /// < GET (bool) Indicates whether the device user has enabled the motion feature. + static const int SYSTEM_SETTINGS_KEY_MOTION_ENABLED = 22; + + /// < GET (bool) Indicates whether Wi-Fi-related notifications are enabled on the device. + static const int SYSTEM_SETTINGS_KEY_NETWORK_WIFI_NOTIFICATION = 23; + + /// < GET (bool) Indicates whether the device is in the flight mode. + static const int SYSTEM_SETTINGS_KEY_NETWORK_FLIGHT_MODE = 24; + + /// < (int) Indicates the backlight time (in seconds). @internal The following values can be used: 15, 30, 60, 120, 300, and 600. + static const int SYSTEM_SETTINGS_KEY_SCREEN_BACKLIGHT_TIME = 25; + + /// < (string) Indicates the file path of the current notification tone set by the user. + static const int SYSTEM_SETTINGS_KEY_SOUND_NOTIFICATION = 26; + + /// < (int) Indicates the time period for notification repetitions. + static const int SYSTEM_SETTINGS_KEY_SOUND_NOTIFICATION_REPETITION_PERIOD = + 27; + + /// < (int) Indicates the current lock state + static const int SYSTEM_SETTINGS_KEY_LOCK_STATE = 28; + + /// < (string) Indicates Ads ID for each device (Since 3.0) + static const int SYSTEM_SETTINGS_KEY_ADS_ID = 29; + + /// < (int) Indicates Ultra Data Save status, one of #system_settings_uds_state_e values (Since 4.0) + static const int SYSTEM_SETTINGS_KEY_ULTRA_DATA_SAVE = 30; + + /// < (string) Indicates Ultra Data Save Package List (Since 4.0), the list is a string containing whitelisted package names separated with semicolons (;) + static const int SYSTEM_SETTINGS_KEY_ULTRA_DATA_SAVE_PKG_LIST = 31; + + /// < GET (bool) Indicates whether the accessibility TTS is enabled on the device. (Since 4.0) + static const int SYSTEM_SETTINGS_KEY_ACCESSIBILITY_TTS = 32; + + /// < (bool) Indicates whether vibration is enabled on the device. (Since 4.0) + static const int SYSTEM_SETTINGS_KEY_VIBRATION = 33; + static const int SYSTEM_SETTINGS_KEY_MAX = 34; +} + +/// @brief Enumeration for Idle Lock State +/// @since_tizen 2.3.1 +abstract class system_settings_idle_lock_state_e { + /// < Device is unlocked + static const int SYSTEM_SETTINGS_LOCK_STATE_UNLOCK = 0; + + /// < Device is locked + static const int SYSTEM_SETTINGS_LOCK_STATE_LOCK = 1; + + /// < Device is being locked + static const int SYSTEM_SETTINGS_LOCK_STATE_LAUNCHING_LOCK = 2; +} + +/// @brief Enumeration for font size. +/// @since_tizen 2.3 +abstract class system_settings_font_size_e { + /// < A small size + static const int SYSTEM_SETTINGS_FONT_SIZE_SMALL = 0; + + /// < A normal size + static const int SYSTEM_SETTINGS_FONT_SIZE_NORMAL = 1; + + /// < A large size + static const int SYSTEM_SETTINGS_FONT_SIZE_LARGE = 2; + + /// < A huge size + static const int SYSTEM_SETTINGS_FONT_SIZE_HUGE = 3; + + /// < A giant size + static const int SYSTEM_SETTINGS_FONT_SIZE_GIANT = 4; +} + +/// @brief Enumeration for Ultra Data Save +/// @since_tizen 4.0 +abstract class system_settings_uds_state_e { + /// < OFF + static const int SYSTEM_SETTINGS_UDS_OFF = 0; + + /// < ON + static const int SYSTEM_SETTINGS_UDS_ON = 1; + + /// < UDS on and the app is whitelisted + static const int SYSTEM_SETTINGS_UDS_ON_WHITELISTED = 2; +} + +/// @brief Enumeration for Trace Error. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 2.3.2 @endif +abstract class trace_error_e { + /// < Successful + static const int TRACE_ERROR_NONE = 0; + + /// < I/O error + static const int TRACE_ERROR_IO_ERROR = -5; +} + +class telephony_data extends ffi.Opaque {} + +/// @brief The structure type for the list of handles to use the Telephony API. +/// @remarks There are two handles in case of dual SIM device. \n +/// In this case, handle[0] means Primary SIM and handle[1] means Secondary SIM. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +class telephony_handle_list_s extends ffi.Struct { + /// < Number of available handle + @ffi.Uint32() + external int count; + + /// < Handle to use Telephony API + external ffi.Pointer> handle; +} + +/// @brief Enumeration for Telephony error. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class telephony_error_e { + /// < Successful + static const int TELEPHONY_ERROR_NONE = 0; + + /// < Out of memory + static const int TELEPHONY_ERROR_OUT_OF_MEMORY = -12; + + /// < Invalid parameter + static const int TELEPHONY_ERROR_INVALID_PARAMETER = -22; + + /// < Permission denied + static const int TELEPHONY_ERROR_PERMISSION_DENIED = -13; + + /// < Not supported + static const int TELEPHONY_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Operation failed + static const int TELEPHONY_ERROR_OPERATION_FAILED = -39845887; + + /// < SIM is not available + static const int TELEPHONY_ERROR_SIM_NOT_AVAILABLE = -39841791; +} + +/// @brief Enumeration for Telephony notification. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class telephony_noti_e { + /// < Notification to be invoked when the SIM card state changes. @n + /// '#telephony_sim_state_e' will be delivered in notification data @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_SIM_STATUS = 16; + + /// < Notification to be invoked when the SIM call forwarding indicator state changes. @n + /// 'state(bool)' will be delivered in notification data (@b Since: 3.0) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_SIM_CALL_FORWARDING_INDICATOR_STATE = 17; + + /// < Notification to be invoked when the network service state changes. @n + /// '#telephony_network_service_state_e' will be delivered in notification data @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_NETWORK_SERVICE_STATE = 32; + + /// < Notification to be invoked when the cell ID changes. @n + /// 'cell_id(int)' will be delivered in notification data @n + /// Privilege : http://tizen.org/privilege/location.coarse (@b Since: 3.0) @n + /// http://tizen.org/privilege/telephony privilege is no longer required since 3.0. + static const int TELEPHONY_NOTI_NETWORK_CELLID = 33; + + /// < Notification to be invoked when the roaming status changes. @n + /// 'roaming_status(bool)' will be delivered in notification data @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_NETWORK_ROAMING_STATUS = 34; + + /// < Notification to be invoked when the signal strength changes. @n + /// '#telephony_network_rssi_e' will be delivered in notification data @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_NETWORK_SIGNALSTRENGTH_LEVEL = 35; + + /// < Notification to be invoked when the network name changes. @n + /// 'network_name(char *)' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_NETWORK_NETWORK_NAME = 36; + + /// < Notification to be invoked when the ps type changes. @n + /// '#telephony_network_ps_type_e' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_NETWORK_PS_TYPE = 37; + + /// < Notification to be invoked when the default data subscription changes. @n + /// '#telephony_network_default_data_subs_e' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_NETWORK_DEFAULT_DATA_SUBSCRIPTION = 38; + + /// < Notification to be invoked when the default subscription changes. @n + /// '#telephony_network_default_subs_e' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_NETWORK_DEFAULT_SUBSCRIPTION = 39; + + /// < Notification to be invoked when the LAC (Location Area Code) changes. @n + /// 'lac(int)' will be delivered in notification data (@b Since: 3.0) @n + /// Privilege : http://tizen.org/privilege/location.coarse + static const int TELEPHONY_NOTI_NETWORK_LAC = 40; + + /// < Notification to be invoked when the TAC (Tracking Area Code) changes. @n + /// 'tac(int)' will be delivered in notification data (@b Since: 3.0) @n + /// Privilege : http://tizen.org/privilege/location.coarse + static const int TELEPHONY_NOTI_NETWORK_TAC = 41; + + /// < Notification to be invoked when the system ID changes. @n + /// 'sid(int)' will be delivered in notification data (@b Since: 3.0) @n + /// Privilege : http://tizen.org/privilege/location.coarse + static const int TELEPHONY_NOTI_NETWORK_SYSTEM_ID = 42; + + /// < Notification to be invoked when the network ID changes. @n + /// 'nid(int)' will be delivered in notification data (@b Since: 3.0) @n + /// Privilege : http://tizen.org/privilege/location.coarse + static const int TELEPHONY_NOTI_NETWORK_NETWORK_ID = 43; + + /// < Notification to be invoked when the base station ID changes. @n + /// 'bs_id(int)' will be delivered in notification data (@b Since: 3.0) @n + /// Privilege : http://tizen.org/privilege/location.coarse + static const int TELEPHONY_NOTI_NETWORK_BS_ID = 44; + + /// < Notification to be invoked when the base station latitude changes. @n + /// 'bs_latitude(int)' will be delivered in notification data (@b Since: 3.0) @n + /// Privilege : http://tizen.org/privilege/location.coarse + static const int TELEPHONY_NOTI_NETWORK_BS_LATITUDE = 45; + + /// < Notification to be invoked when the base station longitude changes. @n + /// 'bs_longitue(int)' will be delivered in notification data (@b Since: 3.0) @n + /// Privilege : http://tizen.org/privilege/location.coarse + static const int TELEPHONY_NOTI_NETWORK_BS_LONGITUDE = 46; + + /// < Notification to be invoked when the voice call state changes. @n + /// '#telephony_call_state_e' will be delivered in notification data (Deprecated Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. Use TELEPHONY_NOTI_VOICE_CALL_STATUS_XXX instead.) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_VOICE_CALL_STATE = 48; + + /// < Notification to be invoked when the video call state changes. @n + /// '#telephony_call_state_e' will be delivered in notification data (Deprecated Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. Use TELEPHONY_NOTI_VIDEO_CALL_STATUS_XXX instead.) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_VIDEO_CALL_STATE = 49; + + /// < Notification to be invoked when a voice call is in idle status. @n + /// 'handle_id(unsigned int)' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_VOICE_CALL_STATUS_IDLE = 50; + + /// < Notification to be invoked when a voice call is in active status. @n + /// 'handle_id(unsigned int)' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_VOICE_CALL_STATUS_ACTIVE = 51; + + /// < Notification to be invoked when a voice call is in held status. @n + /// 'handle_id(unsigned int)' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_VOICE_CALL_STATUS_HELD = 52; + + /// < Notification to be invoked when a voice call is in dialing status. @n + /// 'handle_id(unsigned int)' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_VOICE_CALL_STATUS_DIALING = 53; + + /// < Notification to be invoked when a voice call is in alerting status. @n + /// 'handle_id(unsigned int)' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_VOICE_CALL_STATUS_ALERTING = 54; + + /// < Notification to be invoked when a voice call is in incoming status. @n + /// 'handle_id(unsigned int)' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_VOICE_CALL_STATUS_INCOMING = 55; + + /// < Notification to be invoked when a video call is in idle status. @n + /// 'handle_id(unsigned int)' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_VIDEO_CALL_STATUS_IDLE = 56; + + /// < Notification to be invoked when a video call is in active status. @n + /// 'handle_id(unsigned int)' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_VIDEO_CALL_STATUS_ACTIVE = 57; + + /// < Notification to be invoked when a video call is in dialing status. @n + /// 'handle_id(unsigned int)' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_VIDEO_CALL_STATUS_DIALING = 58; + + /// < Notification to be invoked when a video call is in alerting status. @n + /// 'handle_id(unsigned int)' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_VIDEO_CALL_STATUS_ALERTING = 59; + + /// < Notification to be invoked when a video call is in incoming status. @n + /// 'handle_id(unsigned int)' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_VIDEO_CALL_STATUS_INCOMING = 60; + + /// < Notification to be invoked when the preferred voice subscription changes. @n + /// '#telephony_call_preferred_voice_subs_e' will be delivered in notification data (@b Since: @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_CALL_PREFERRED_VOICE_SUBSCRIPTION = 61; + + /// < Notification to be invoked when the modem power status changes. @n + /// '#telephony_modem_power_status_e' will be delivered in notification data (@b Since: 4.0) @n + /// Privilege : http://tizen.org/privilege/telephony + static const int TELEPHONY_NOTI_MODEM_POWER_STATUS = 62; +} + +/// @brief Enumeration for the telephony state. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class telephony_state_e { + /// < Telephony state is not ready + static const int TELEPHONY_STATE_NOT_READY = 0; + + /// < Telephony state is ready + static const int TELEPHONY_STATE_READY = 1; +} + +class telephony_call_info_s extends ffi.Opaque {} + +/// @deprecated Deprecated Since @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif. Use #telephony_call_status_e instead. +/// +/// @brief Enumeration for the call state. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class telephony_call_state_e { + /// < There exists no calls. + static const int TELEPHONY_CALL_STATE_IDLE = 0; + + /// < There exists at least one call that is dialing, alerting or incoming + static const int TELEPHONY_CALL_STATE_CONNECTING = 1; + + /// < There exist active or held calls, and no calls are dialing, alerting or incoming + static const int TELEPHONY_CALL_STATE_CONNECTED = 2; +} + +/// @brief Enumeration for the call status. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class telephony_call_status_e { + /// < Idle status + static const int TELEPHONY_CALL_STATUS_IDLE = 0; + + /// < Active status + static const int TELEPHONY_CALL_STATUS_ACTIVE = 1; + + /// < Held status + static const int TELEPHONY_CALL_STATUS_HELD = 2; + + /// < Dialing status + static const int TELEPHONY_CALL_STATUS_DIALING = 3; + + /// < Alerting status + static const int TELEPHONY_CALL_STATUS_ALERTING = 4; + + /// < Incoming status + static const int TELEPHONY_CALL_STATUS_INCOMING = 5; +} + +/// @brief Enumeration for the preferred voice call subscription. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class telephony_call_preferred_voice_subs_e { + /// < Unknown status + static const int TELEPHONY_CALL_PREFERRED_VOICE_SUBS_UNKNOWN = -1; + + /// < Current network + static const int TELEPHONY_CALL_PREFERRED_VOICE_SUBS_CURRENT_NETWORK = 0; + + /// < ASK Always + static const int TELEPHONY_CALL_PREFERRED_VOICE_SUBS_ASK_ALWAYS = 1; + + /// < SIM 1 + static const int TELEPHONY_CALL_PREFERRED_VOICE_SUBS_SIM1 = 2; + + /// < SIM 2 + static const int TELEPHONY_CALL_PREFERRED_VOICE_SUBS_SIM2 = 3; +} + +/// @brief Enumeration for the call type. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class telephony_call_type_e { + /// < Voice call + static const int TELEPHONY_CALL_TYPE_VOICE = 0; + + /// < Video call + static const int TELEPHONY_CALL_TYPE_VIDEO = 1; + + /// < Emergency call + static const int TELEPHONY_CALL_TYPE_E911 = 2; +} + +/// @brief Enumeration for the call direction. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class telephony_call_direction_e { + /// < MO(Mobile Originated) call + static const int TELEPHONY_CALL_DIRECTION_MO = 0; + + /// < MT(Mobile Terminated) call + static const int TELEPHONY_CALL_DIRECTION_MT = 1; +} + +/// @brief Enumeration for the state of SIM card. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class telephony_sim_state_e { + /// < SIM is not available on this device + static const int TELEPHONY_SIM_STATE_UNAVAILABLE = 0; + + /// < SIM is locked + static const int TELEPHONY_SIM_STATE_LOCKED = 1; + + /// < SIM is available on this device (SIM is not locked) + static const int TELEPHONY_SIM_STATE_AVAILABLE = 2; + + /// < SIM is in transition between states + static const int TELEPHONY_SIM_STATE_UNKNOWN = 3; +} + +/// @brief Enumeration for the lock state of SIM card. +/// @since_tizen 3.0 +abstract class telephony_sim_lock_state_e { + /// < SIM is not in lock + static const int TELEPHONY_SIM_LOCK_STATE_UNKNOWN = 0; + + /// < SIM is PIN(Personal Identification Number) locked + static const int TELEPHONY_SIM_LOCK_STATE_PIN_REQUIRED = 1; + + /// < SIM is PUK(Personal Unblocking Code) locked + static const int TELEPHONY_SIM_LOCK_STATE_PUK_REQUIRED = 2; + + /// < SIM is permanently blocked(All the attempts for PIN/PUK failed) + static const int TELEPHONY_SIM_LOCK_STATE_PERM_LOCKED = 3; + + /// < SIM is NCK(Network Control Key) locked + static const int TELEPHONY_SIM_LOCK_STATE_NCK_REQUIRED = 4; +} + +/// @brief Enumeration for the type of SIM card. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class telephony_sim_application_type_e { + /// < SIM(GSM) Application + static const int TELEPHONY_SIM_APP_TYPE_SIM = 1; + + /// < USIM Application + static const int TELEPHONY_SIM_APP_TYPE_USIM = 2; + + /// < CDMA Application + static const int TELEPHONY_SIM_APP_TYPE_CSIM = 4; + + /// < ISIM Application + static const int TELEPHONY_SIM_APP_TYPE_ISIM = 8; +} + +/// @brief Enumeration for RSSI (Receive Signal Strength Indicator). +/// @details #TELEPHONY_NETWORK_RSSI_6 indicates the highest strength. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class telephony_network_rssi_e { + /// < Strength 0 + static const int TELEPHONY_NETWORK_RSSI_0 = 0; + + /// < Strength 1 + static const int TELEPHONY_NETWORK_RSSI_1 = 1; + + /// < Strength 2 + static const int TELEPHONY_NETWORK_RSSI_2 = 2; + + /// < Strength 3 + static const int TELEPHONY_NETWORK_RSSI_3 = 3; + + /// < Strength 4 + static const int TELEPHONY_NETWORK_RSSI_4 = 4; + + /// < Strength 5 + static const int TELEPHONY_NETWORK_RSSI_5 = 5; + + /// < Strength 6 + static const int TELEPHONY_NETWORK_RSSI_6 = 6; +} + +/// @brief Enumeration for Network Type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class telephony_network_type_e { + /// < Unknown + static const int TELEPHONY_NETWORK_TYPE_UNKNOWN = 0; + + /// < 2G GSM network type + static const int TELEPHONY_NETWORK_TYPE_GSM = 1; + + /// < 2.5G GPRS network type + static const int TELEPHONY_NETWORK_TYPE_GPRS = 2; + + /// < 2.5G EDGE network type + static const int TELEPHONY_NETWORK_TYPE_EDGE = 3; + + /// < 3G UMTS network type + static const int TELEPHONY_NETWORK_TYPE_UMTS = 4; + + /// < HSDPA network type + static const int TELEPHONY_NETWORK_TYPE_HSDPA = 5; + + /// < LTE network type + static const int TELEPHONY_NETWORK_TYPE_LTE = 6; + + /// < IS95A network type (Since: 3.0) + static const int TELEPHONY_NETWORK_TYPE_IS95A = 7; + + /// < IS95B network type (Since: 3.0) + static const int TELEPHONY_NETWORK_TYPE_IS95B = 8; + + /// < CDMA 1x network type (Since: 3.0) + static const int TELEPHONY_NETWORK_TYPE_CDMA_1X = 9; + + /// < EVDO revision 0 network type (Since: 3.0) + static const int TELEPHONY_NETWORK_TYPE_EVDO_REV_0 = 10; + + /// < EVDO revision A network type (Since: 3.0) + static const int TELEPHONY_NETWORK_TYPE_EVDO_REV_A = 11; + + /// < EVDO revision B network type (Since: 3.0) + static const int TELEPHONY_NETWORK_TYPE_EVDO_REV_B = 12; + + /// < EVDV network type (Since: 3.0) + static const int TELEPHONY_NETWORK_TYPE_EVDV = 13; + + /// < EHRPD network type (Since: 3.0) + static const int TELEPHONY_NETWORK_TYPE_EHRPD = 14; +} + +/// @brief Enumeration for PS Type. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class telephony_network_ps_type_e { + /// < Unknown + static const int TELEPHONY_NETWORK_PS_TYPE_UNKNOWN = 0; + + /// < HSDPA ps type + static const int TELEPHONY_NETWORK_PS_TYPE_HSDPA = 1; + + /// < HSUPA ps type + static const int TELEPHONY_NETWORK_PS_TYPE_HSUPA = 2; + + /// < HSPA ps type + static const int TELEPHONY_NETWORK_PS_TYPE_HSPA = 3; + + /// < HSPAP ps type + static const int TELEPHONY_NETWORK_PS_TYPE_HSPAP = 4; +} + +/// @brief Enumeration for Network Service State. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class telephony_network_service_state_e { + /// < In service + static const int TELEPHONY_NETWORK_SERVICE_STATE_IN_SERVICE = 0; + + /// < Out of service + static const int TELEPHONY_NETWORK_SERVICE_STATE_OUT_OF_SERVICE = 1; + + /// < Only emergency call is allowed + static const int TELEPHONY_NETWORK_SERVICE_STATE_EMERGENCY_ONLY = 2; +} + +/// @brief Enumeration for Network Name Priority. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class telephony_network_name_option_e { + /// < Unknown + static const int TELEPHONY_NETWORK_NAME_OPTION_UNKNOWN = 0; + + /// < Network name displayed by SPN + static const int TELEPHONY_NETWORK_NAME_OPTION_SPN = 1; + + /// < Network name displayed by Network + static const int TELEPHONY_NETWORK_NAME_OPTION_NETWORK = 2; + + /// < Network name displayed by SPN or Network + static const int TELEPHONY_NETWORK_NAME_OPTION_ANY = 3; +} + +/// @brief Enumeration for the possible 'default' Data Subscriptions for Packet Switched(PS). +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class telephony_network_default_data_subs_e { + /// < Unknown status + static const int TELEPHONY_NETWORK_DEFAULT_DATA_SUBS_UNKNOWN = -1; + + /// < SIM 1 + static const int TELEPHONY_NETWORK_DEFAULT_DATA_SUBS_SIM1 = 0; + + /// < SIM 2 + static const int TELEPHONY_NETWORK_DEFAULT_DATA_SUBS_SIM2 = 1; +} + +/// @brief Enumeration for defining possible 'default' Subscriptions for Circuit Switched(CS). +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class telephony_network_default_subs_e { + /// < Unknown status + static const int TELEPHONY_NETWORK_DEFAULT_SUBS_UNKNOWN = -1; + + /// < SIM 1 network + static const int TELEPHONY_NETWORK_DEFAULT_SUBS_SIM1 = 0; + + /// < SIM 2 network + static const int TELEPHONY_NETWORK_DEFAULT_SUBS_SIM2 = 1; +} + +/// @brief Enumeration for network selection mode. +/// @since_tizen 3.0 +abstract class telephony_network_selection_mode_e { + /// < Automatic mode + static const int TELEPHONY_NETWORK_SELECTION_MODE_AUTOMATIC = 0; + + /// < Manual mode + static const int TELEPHONY_NETWORK_SELECTION_MODE_MANUAL = 1; +} + +/// @brief Enumeration for Modem Power Status. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class telephony_modem_power_status_e { + /// < Unknown + static const int TELEPHONY_MODEM_POWER_STATUS_UNKNOWN = -1; + + /// < Modem power ON + static const int TELEPHONY_MODEM_POWER_STATUS_ON = 0; + + /// < Modem power OFF + static const int TELEPHONY_MODEM_POWER_STATUS_OFF = 1; + + /// < Modem power RESET + static const int TELEPHONY_MODEM_POWER_STATUS_RESET = 2; + + /// < Modem power LOW + static const int TELEPHONY_MODEM_POWER_STATUS_LOW = 3; +} + +/// @brief Enumeration for the key codes. +/// If keycode & 0xff000000 == 0x01000000 then this key code is directly encoded 24-bit UCS character. +/// The UCS value is keycode & 0x00ffffff. +/// @details Defines the list of keys supported by the system. +/// Note that certain keys may not be available on all devices. +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +abstract class ime_key_code_e { + /// < The backspace key + static const int IME_KEY_BackSpace = 65288; + + /// < The tab key + static const int IME_KEY_Tab = 65289; + + /// < The linefeed key + static const int IME_KEY_Linefeed = 65290; + + /// < The clear key + static const int IME_KEY_Clear = 65291; + + /// < The return key + static const int IME_KEY_Return = 65293; + + /// < The pause key + static const int IME_KEY_Pause = 65299; + + /// < The scroll lock key + static const int IME_KEY_Scroll_Lock = 65300; + + /// < The sys req key + static const int IME_KEY_Sys_Req = 65301; + + /// < The escape key + static const int IME_KEY_Escape = 65307; + + /// < The delete key + static const int IME_KEY_Delete = 65535; + + /// < The home key + static const int IME_KEY_Home = 65360; + + /// < The left directional key + static const int IME_KEY_Left = 65361; + + /// < The up directional key + static const int IME_KEY_Up = 65362; + + /// < The right directional key + static const int IME_KEY_Right = 65363; + + /// < The down directional key + static const int IME_KEY_Down = 65364; + + /// < The prior, previous key + static const int IME_KEY_Prior = 65365; + + /// < The page up key + static const int IME_KEY_Page_Up = 65365; + + /// < The next key + static const int IME_KEY_Next = 65366; + + /// < The page down key + static const int IME_KEY_Page_Down = 65366; + + /// < The end key + static const int IME_KEY_End = 65367; + + /// < The begin key + static const int IME_KEY_Begin = 65368; + + /// < The select key + static const int IME_KEY_Select = 65376; + + /// < The print key + static const int IME_KEY_Print = 65377; + + /// < The execute, run, do key + static const int IME_KEY_Execute = 65378; + + /// < The insert key + static const int IME_KEY_Insert = 65379; + + /// < The undo key + static const int IME_KEY_Undo = 65381; + + /// < The redo key + static const int IME_KEY_Redo = 65382; + + /// < The menu key + static const int IME_KEY_Menu = 65383; + + /// < The find key + static const int IME_KEY_Find = 65384; + + /// < The cancel, stop, abort, exit key + static const int IME_KEY_Cancel = 65385; + + /// < The help key + static const int IME_KEY_Help = 65386; + + /// < The break key + static const int IME_KEY_Break = 65387; + + /// < The character set switch key + static const int IME_KEY_Mode_switch = 65406; + + /// < The num lock key + static const int IME_KEY_Num_Lock = 65407; + + /// < The Numpad space key + static const int IME_KEY_KP_Space = 65408; + + /// < The Numpad tab key + static const int IME_KEY_KP_Tab = 65417; + + /// < The Numpad enter key + static const int IME_KEY_KP_Enter = 65421; + + /// < The Numpad function 1 key + static const int IME_KEY_KP_F1 = 65425; + + /// < The Numpad function 2 key + static const int IME_KEY_KP_F2 = 65426; + + /// < The Numpad function 3 key + static const int IME_KEY_KP_F3 = 65427; + + /// < The Numpad function 4 key + static const int IME_KEY_KP_F4 = 65428; + + /// < The Numpad home key + static const int IME_KEY_KP_Home = 65429; + + /// < The Numpad left key + static const int IME_KEY_KP_Left = 65430; + + /// < The Numpad up key + static const int IME_KEY_KP_Up = 65431; + + /// < The Numpad right key + static const int IME_KEY_KP_Right = 65432; + + /// < The Numpad down key + static const int IME_KEY_KP_Down = 65433; + + /// < The Numpad prior, previous key + static const int IME_KEY_KP_Prior = 65434; + + /// < The Numpad page up key + static const int IME_KEY_KP_Page_Up = 65434; + + /// < The Numpad next key + static const int IME_KEY_KP_Next = 65435; + + /// < The Numpad page down key + static const int IME_KEY_KP_Page_Down = 65435; + + /// < The Numpad end key + static const int IME_KEY_KP_End = 65436; + + /// < The Numpad begin key + static const int IME_KEY_KP_Begin = 65437; + + /// < The Numpad insert key + static const int IME_KEY_KP_Insert = 65438; + + /// < The Numpad delete key + static const int IME_KEY_KP_Delete = 65439; + + /// < The Numpad equal key + static const int IME_KEY_KP_Equal = 65469; + + /// < The Numpad multiply key + static const int IME_KEY_KP_Multiply = 65450; + + /// < The Numpad add key + static const int IME_KEY_KP_Add = 65451; + + /// < The Numpad separator key + static const int IME_KEY_KP_Separator = 65452; + + /// < The Numpad subtract key + static const int IME_KEY_KP_Subtract = 65453; + + /// < The Numpad decimal key + static const int IME_KEY_KP_Decimal = 65454; + + /// < The Numpad divide key + static const int IME_KEY_KP_Divide = 65455; + + /// < The Numpad 0 key + static const int IME_KEY_KP_0 = 65456; + + /// < The Numpad 1 key + static const int IME_KEY_KP_1 = 65457; + + /// < The Numpad 2 key + static const int IME_KEY_KP_2 = 65458; + + /// < The Numpad 3 key + static const int IME_KEY_KP_3 = 65459; + + /// < The Numpad 4 key + static const int IME_KEY_KP_4 = 65460; + + /// < The Numpad 5 key + static const int IME_KEY_KP_5 = 65461; + + /// < The Numpad 6 key + static const int IME_KEY_KP_6 = 65462; + + /// < The Numpad 7 key + static const int IME_KEY_KP_7 = 65463; + + /// < The Numpad 8 key + static const int IME_KEY_KP_8 = 65464; + + /// < The Numpad 9 key + static const int IME_KEY_KP_9 = 65465; + + /// < The function 1 key + static const int IME_KEY_F1 = 65470; + + /// < The function 2 key + static const int IME_KEY_F2 = 65471; + + /// < The function 3 key + static const int IME_KEY_F3 = 65472; + + /// < The function 4 key + static const int IME_KEY_F4 = 65473; + + /// < The function 5 key + static const int IME_KEY_F5 = 65474; + + /// < The function 6 key + static const int IME_KEY_F6 = 65475; + + /// < The function 7 key + static const int IME_KEY_F7 = 65476; + + /// < The function 8 key + static const int IME_KEY_F8 = 65477; + + /// < The function 9 key + static const int IME_KEY_F9 = 65478; + + /// < The function 10 key + static const int IME_KEY_F10 = 65479; + + /// < The function 11 key + static const int IME_KEY_F11 = 65480; + + /// < The function 12 key + static const int IME_KEY_F12 = 65481; + + /// < The function 13 key + static const int IME_KEY_F13 = 65482; + + /// < The function 14 key + static const int IME_KEY_F14 = 65483; + + /// < The function 15 key + static const int IME_KEY_F15 = 65484; + + /// < The function 16 key + static const int IME_KEY_F16 = 65485; + + /// < The function 17 key + static const int IME_KEY_F17 = 65486; + + /// < The function 18 key + static const int IME_KEY_F18 = 65487; + + /// < The function 19 key + static const int IME_KEY_F19 = 65488; + + /// < The function 20 key + static const int IME_KEY_F20 = 65489; + + /// < The function 21 key + static const int IME_KEY_F21 = 65490; + + /// < The function 22 key + static const int IME_KEY_F22 = 65491; + + /// < The function 23 key + static const int IME_KEY_F23 = 65492; + + /// < The function 24 key + static const int IME_KEY_F24 = 65493; + + /// < The function 25 key + static const int IME_KEY_F25 = 65494; + + /// < The function 26 key + static const int IME_KEY_F26 = 65495; + + /// < The function 27 key + static const int IME_KEY_F27 = 65496; + + /// < The function 28 key + static const int IME_KEY_F28 = 65497; + + /// < The function 29 key + static const int IME_KEY_F29 = 65498; + + /// < The function 30 key + static const int IME_KEY_F30 = 65499; + + /// < The function 31 key + static const int IME_KEY_F31 = 65500; + + /// < The function 32 key + static const int IME_KEY_F32 = 65501; + + /// < The function 33 key + static const int IME_KEY_F33 = 65502; + + /// < The function 34 key + static const int IME_KEY_F34 = 65503; + + /// < The function 35 key + static const int IME_KEY_F35 = 65504; + + /// < The left shift key + static const int IME_KEY_Shift_L = 65505; + + /// < The right shift key + static const int IME_KEY_Shift_R = 65506; + + /// < The left control key + static const int IME_KEY_Control_L = 65507; + + /// < The right control key + static const int IME_KEY_Control_R = 65508; + + /// < The caps lock key + static const int IME_KEY_Caps_Lock = 65509; + + /// < The shift lock key + static const int IME_KEY_Shift_Lock = 65510; + + /// < The left meta key + static const int IME_KEY_Meta_L = 65511; + + /// < The right meta key + static const int IME_KEY_Meta_R = 65512; + + /// < The left alt key + static const int IME_KEY_Alt_L = 65513; + + /// < The right alt key + static const int IME_KEY_Alt_R = 65514; + + /// < The left super key + static const int IME_KEY_Super_L = 65515; + + /// < The right super key + static const int IME_KEY_Super_R = 65516; + + /// < The left hyper key + static const int IME_KEY_Hyper_L = 65517; + + /// < The right hyper key + static const int IME_KEY_Hyper_R = 65518; + + /// < The space key + static const int IME_KEY_space = 32; + + /// < The exclamation key + static const int IME_KEY_exclam = 33; + + /// < The quotedbl key + static const int IME_KEY_quotedbl = 34; + + /// < The number sign key + static const int IME_KEY_numbersign = 35; + + /// < The dollar key + static const int IME_KEY_dollar = 36; + + /// < The percent key + static const int IME_KEY_percent = 37; + + /// < The ampersand key + static const int IME_KEY_ampersand = 38; + + /// < The apostrophe key + static const int IME_KEY_apostrophe = 39; + + /// < The parenleft key + static const int IME_KEY_parenleft = 40; + + /// < The parenright key + static const int IME_KEY_parenright = 41; + + /// < The asterisk key + static const int IME_KEY_asterisk = 42; + + /// < The plus key + static const int IME_KEY_plus = 43; + + /// < The comma key + static const int IME_KEY_comma = 44; + + /// < The minus key + static const int IME_KEY_minus = 45; + + /// < The period key + static const int IME_KEY_period = 46; + + /// < The slash key + static const int IME_KEY_slash = 47; + + /// < The 0 key + static const int IME_KEY_0 = 48; + + /// < The 1 key + static const int IME_KEY_1 = 49; + + /// < The 2 key + static const int IME_KEY_2 = 50; + + /// < The 3 key + static const int IME_KEY_3 = 51; + + /// < The 4 key + static const int IME_KEY_4 = 52; + + /// < The 5 key + static const int IME_KEY_5 = 53; + + /// < The 6 key + static const int IME_KEY_6 = 54; + + /// < The 7 key + static const int IME_KEY_7 = 55; + + /// < The 8 key + static const int IME_KEY_8 = 56; + + /// < The 9 key + static const int IME_KEY_9 = 57; + + /// < The colon key + static const int IME_KEY_colon = 58; + + /// < The semicolon key + static const int IME_KEY_semicolon = 59; + + /// < The less key + static const int IME_KEY_less = 60; + + /// < The equal key + static const int IME_KEY_equal = 61; + + /// < The greater key + static const int IME_KEY_greater = 62; + + /// < The question key + static const int IME_KEY_question = 63; + + /// < The at key + static const int IME_KEY_at = 64; + + /// < The A key + static const int IME_KEY_A = 65; + + /// < The B key + static const int IME_KEY_B = 66; + + /// < The C key + static const int IME_KEY_C = 67; + + /// < The D key + static const int IME_KEY_D = 68; + + /// < The E key + static const int IME_KEY_E = 69; + + /// < The F key + static const int IME_KEY_F = 70; + + /// < The G key + static const int IME_KEY_G = 71; + + /// < The H key + static const int IME_KEY_H = 72; + + /// < The I key + static const int IME_KEY_I = 73; + + /// < The J key + static const int IME_KEY_J = 74; + + /// < The K key + static const int IME_KEY_K = 75; + + /// < The L key + static const int IME_KEY_L = 76; + + /// < The M key + static const int IME_KEY_M = 77; + + /// < The N key + static const int IME_KEY_N = 78; + + /// < The O key + static const int IME_KEY_O = 79; + + /// < The P key + static const int IME_KEY_P = 80; + + /// < The Q key + static const int IME_KEY_Q = 81; + + /// < The R key + static const int IME_KEY_R = 82; + + /// < The S key + static const int IME_KEY_S = 83; + + /// < The T key + static const int IME_KEY_T = 84; + + /// < The U key + static const int IME_KEY_U = 85; + + /// < The V key + static const int IME_KEY_V = 86; + + /// < The W key + static const int IME_KEY_W = 87; + + /// < The X key + static const int IME_KEY_X = 88; + + /// < The Y key + static const int IME_KEY_Y = 89; + + /// < The Z key + static const int IME_KEY_Z = 90; + + /// < The left bracket key + static const int IME_KEY_bracketleft = 91; + + /// < The backslash key + static const int IME_KEY_backslash = 92; + + /// < The right bracket key + static const int IME_KEY_bracketright = 93; + + /// < The circumflex key + static const int IME_KEY_asciicircum = 94; + + /// < The underscore key + static const int IME_KEY_underscore = 95; + + /// < The grave key + static const int IME_KEY_grave = 96; + + /// < The a key + static const int IME_KEY_a = 97; + + /// < The b key + static const int IME_KEY_b = 98; + + /// < The c key + static const int IME_KEY_c = 99; + + /// < The d key + static const int IME_KEY_d = 100; + + /// < The e key + static const int IME_KEY_e = 101; + + /// < The f key + static const int IME_KEY_f = 102; + + /// < The g key + static const int IME_KEY_g = 103; + + /// < The h key + static const int IME_KEY_h = 104; + + /// < The i key + static const int IME_KEY_i = 105; + + /// < The j key + static const int IME_KEY_j = 106; + + /// < The k key + static const int IME_KEY_k = 107; + + /// < The l key + static const int IME_KEY_l = 108; + + /// < The m key + static const int IME_KEY_m = 109; + + /// < The n key + static const int IME_KEY_n = 110; + + /// < The o key + static const int IME_KEY_o = 111; + + /// < The p key + static const int IME_KEY_p = 112; + + /// < The q key + static const int IME_KEY_q = 113; + + /// < The r key + static const int IME_KEY_r = 114; + + /// < The s key + static const int IME_KEY_s = 115; + + /// < The t key + static const int IME_KEY_t = 116; + + /// < The u key + static const int IME_KEY_u = 117; + + /// < The v key + static const int IME_KEY_v = 118; + + /// < The w key + static const int IME_KEY_w = 119; + + /// < The x key + static const int IME_KEY_x = 120; + + /// < The y key + static const int IME_KEY_y = 121; + + /// < The z key + static const int IME_KEY_z = 122; + + /// < The left brace key + static const int IME_KEY_braceleft = 123; + + /// < The bar key + static const int IME_KEY_bar = 124; + + /// < The right brace key + static const int IME_KEY_braceright = 125; + + /// < The tilde key + static const int IME_KEY_asciitilde = 126; +} + +/// @brief Enumeration for the key masks. +/// The key masks indicate which modifier keys is pressed down during the keyboard hit. +/// The special IME_KEY_MASK_RELEASED indicates the key release event. +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +abstract class ime_key_mask_e { + /// < Key press event without modifier key + static const int IME_KEY_MASK_PRESSED = 0; + + /// < The Shift key is pressed down + static const int IME_KEY_MASK_SHIFT = 1; + + /// < The CapsLock key is pressed down + static const int IME_KEY_MASK_CAPSLOCK = 2; + + /// < The Control key is pressed down + static const int IME_KEY_MASK_CONTROL = 4; + + /// < The Alt key is pressed down + static const int IME_KEY_MASK_ALT = 8; + + /// < The Meta key is pressed down + static const int IME_KEY_MASK_META = 16; + + /// < The Win (between Control and Alt) is pressed down + static const int IME_KEY_MASK_WIN = 32; + + /// < The Hyper key is pressed down + static const int IME_KEY_MASK_HYPER = 64; + + /// < The NumLock key is pressed down + static const int IME_KEY_MASK_NUMLOCK = 128; + + /// < Key release event + static const int IME_KEY_MASK_RELEASED = 32768; +} + +/// @brief Enumeration of unconventional input devices +/// +/// @since_tizen @if WEARABLE 3.0 @endif +/// +/// @see ime_event_set_process_input_device_event_cb() +abstract class ime_input_device_type_e { + /// < Undefined unconventional input device + static const int IME_INPUT_DEVICE_TYPE_UNKNOWN = 0; + + /// < A rotary input device such as bezel that can be found on a wearable device + static const int IME_INPUT_DEVICE_TYPE_ROTARY = 1; +} + +/// @brief Enumeration of directions for rotary input device's rotation event +/// +/// @since_tizen @if WEARABLE 3.0 @endif +/// +/// @see ime_input_device_rotary_get_direction() +abstract class ime_input_device_rotary_direction_e { + /// < Rotary is rotated clockwise direction + static const int IME_INPUT_DEVICE_ROTARY_DIRECTION_CLOCKWISE = 0; + + /// < Rotary is rotated counter clockwise direction + static const int IME_INPUT_DEVICE_ROTARY_DIRECTION_COUNTER_CLOCKWISE = 1; +} + +/// @brief Enumeration for input method function error +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +abstract class ime_error_e { + /// < Successful + static const int IME_ERROR_NONE = 0; + + /// < Invalid parameter + static const int IME_ERROR_INVALID_PARAMETER = -22; + + /// < Permission denied + static const int IME_ERROR_PERMISSION_DENIED = -13; + + /// < Necessary callback function is not set + static const int IME_ERROR_NO_CALLBACK_FUNCTION = -49414143; + + /// < IME main loop isn't started yet + static const int IME_ERROR_NOT_RUNNING = -49414142; + + /// < Operation failed + static const int IME_ERROR_OPERATION_FAILED = -49414141; + + /// < out of memory + static const int IME_ERROR_OUT_OF_MEMORY = -12; +} + +/// @brief Enumeration of the option window type +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +/// +/// @see ime_option_window_created_cb() +abstract class ime_option_window_type_e { + /// < Open from Keyboard + static const int IME_OPTION_WINDOW_TYPE_KEYBOARD = 0; + + /// < Open from Setting application + static const int IME_OPTION_WINDOW_TYPE_SETTING_APPLICATION = 1; +} + +/// @brief Enumeration of layout variation +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +/// +/// @see ime_context_get_layout_variation() +abstract class ime_layout_variation_e { + /// < The plain normal layout + static const int IME_LAYOUT_NORMAL_VARIATION_NORMAL = 0; + + /// < Filename layout; symbols such as '/', '*', '\', '|', '<', '>', '?', '"' and ':' should be disabled + static const int IME_LAYOUT_NORMAL_VARIATION_FILENAME = 1; + + /// < The name of a person + static const int IME_LAYOUT_NORMAL_VARIATION_PERSON_NAME = 2; + + /// < The plain normal number layout + static const int IME_LAYOUT_NUMBERONLY_VARIATION_NORMAL = 0; + + /// < The number layout to allow a negative sign + static const int IME_LAYOUT_NUMBERONLY_VARIATION_SIGNED = 1; + + /// < The number layout to allow decimal point to provide fractional value + static const int IME_LAYOUT_NUMBERONLY_VARIATION_DECIMAL = 2; + + /// < The number layout to allow decimal point and negative sign + static const int IME_LAYOUT_NUMBERONLY_VARIATION_SIGNED_AND_DECIMAL = 3; + + /// < The normal password layout + static const int IME_LAYOUT_PASSWORD_VARIATION_NORMAL = 0; + + /// < The password layout to allow only number + static const int IME_LAYOUT_PASSWORD_VARIATION_NUMBERONLY = 1; +} + +/// @brief Enumeration of string attribute type +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +/// +/// @remarks Currently, a font style is available to use. +/// +/// @see ime_preedit_attribute() +/// @see ime_update_preedit_string() +abstract class ime_attribute_type { + /// < No attribute + static const int IME_ATTR_NONE = 0; + + /// < A font style attribute, e.g., underline, etc. + static const int IME_ATTR_FONTSTYLE = 1; +} + +/// @brief The structure type to contain the attributes for preedit string. +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +/// +/// @remarks A preedit string may have one or more different attributes. This structure describes each attribute of the string. +/// +/// @see ime_update_preedit_string() +/// @see ime_attribute_type +class ime_preedit_attribute extends ffi.Struct { + /// < The start position in the string of this attribute + @ffi.Uint32() + external int start; + + /// < The character length of this attribute, the range is [start, start+length] + @ffi.Uint32() + external int length; + + /// < The type of this attribute + @ffi.Int32() + external int type; + + /// < The value of this attribute + @ffi.Uint32() + external int value; +} + +class _ime_context extends ffi.Opaque {} + +class _ime_device_info extends ffi.Opaque {} + +/// @brief The structure type to contain the set of the essential callback functions for IME application lifecycle and appearance. +/// +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +/// +/// @remarks These four callback functions are mandatory for IME application. +/// +/// @see ime_run() +class ime_callback_s extends ffi.Struct { + /// < Called when the input panel is created + external ffi.Pointer> create; + + /// < Called when the input panel is terminated + external ffi.Pointer> terminate; + + /// < Called when the input panel is requested to show itself + external ffi.Pointer> show_1; + + /// < Called when the input panel is requested to hide itself + external ffi.Pointer> hide_1; +} + +/// @struct _Eina_List_Accounting +/// Cache used to store the last element of a list and the number of +/// elements, for fast access. It is for private used and must not be +/// touched. +class Eina_List_Accounting extends ffi.Struct { + /// < Pointer to the last element of the list - don't touch + external ffi.Pointer last; + + /// < Number of elements of the list - don't touch + @ffi.Uint32() + external int count; + + @ffi.Uint32() + external int __magic; +} + +/// @struct _Eina_List +/// Type for a generic double linked list. +class Eina_List extends ffi.Struct { + /// < Pointer to list element payload + external ffi.Pointer data; + + /// < Next member in the list + external ffi.Pointer next; + + /// < Previous member in the list + external ffi.Pointer prev; + + /// < Private list accounting info - don't touch + external ffi.Pointer accounting; + + @ffi.Uint32() + external int __magic; +} + +/// @brief Enumeration for input method manager function error. +/// @since_tizen @if MOBILE 2.4 @else 3.0 @endif +abstract class ime_manager_error_e { + /// < Successful + static const int IME_MANAGER_ERROR_NONE = 0; + + /// < Invalid parameter + static const int IME_MANAGER_ERROR_INVALID_PARAMETER = -22; + + /// < Permission denied + static const int IME_MANAGER_ERROR_PERMISSION_DENIED = -13; + + /// < Operation failed + static const int IME_MANAGER_ERROR_OPERATION_FAILED = -49414128; +} + +/// @brief Enumeration for error codes. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class stt_error_e { + /// < Successful + static const int STT_ERROR_NONE = 0; + + /// < Out of Memory + static const int STT_ERROR_OUT_OF_MEMORY = -12; + + /// < I/O error + static const int STT_ERROR_IO_ERROR = -5; + + /// < Invalid parameter + static const int STT_ERROR_INVALID_PARAMETER = -22; + + /// < No answer from the STT service + static const int STT_ERROR_TIMED_OUT = -1073741823; + + /// < Device or resource busy + static const int STT_ERROR_RECORDER_BUSY = -16; + + /// < Network is down + static const int STT_ERROR_OUT_OF_NETWORK = -100; + + /// < Permission denied + static const int STT_ERROR_PERMISSION_DENIED = -13; + + /// < STT NOT supported + static const int STT_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Invalid state + static const int STT_ERROR_INVALID_STATE = -49283071; + + /// < Invalid language + static const int STT_ERROR_INVALID_LANGUAGE = -49283070; + + /// < No available engine + static const int STT_ERROR_ENGINE_NOT_FOUND = -49283069; + + /// < Operation failed + static const int STT_ERROR_OPERATION_FAILED = -49283068; + + /// < Not supported feature of current engine + static const int STT_ERROR_NOT_SUPPORTED_FEATURE = -49283067; + + /// < Recording timed out @if MOBILE (Since 3.0) @elseif WEARABLE (Since 2.3.2) @endif + static const int STT_ERROR_RECORDING_TIMED_OUT = -49283066; + + /// < No speech while recording @if MOBILE (Since 3.0) @elseif WEARABLE (Since 2.3.2) @endif + static const int STT_ERROR_NO_SPEECH = -49283065; + + /// < Progress to ready is not finished @if MOBILE (Since 3.0) @elseif WEARABLE (Since 2.3.2) @endif + static const int STT_ERROR_IN_PROGRESS_TO_READY = -49283064; + + /// < Progress to recording is not finished @if MOBILE (Since 3.0) @elseif WEARABLE (Since 2.3.2) @endif + static const int STT_ERROR_IN_PROGRESS_TO_RECORDING = -49283063; + + /// < Progress to processing is not finished @if MOBILE (Since 3.0) @elseif WEARABLE (Since 2.3.2) @endif + static const int STT_ERROR_IN_PROGRESS_TO_PROCESSING = -49283056; + + /// < Service reset @if MOBILE (Since 3.0) @elseif WEARABLE (Since 2.3.2) @endif + static const int STT_ERROR_SERVICE_RESET = -49283055; +} + +/// @brief Enumeration for state. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class stt_state_e { + /// < 'CREATED' state + static const int STT_STATE_CREATED = 0; + + /// < 'READY' state + static const int STT_STATE_READY = 1; + + /// < 'RECORDING' state + static const int STT_STATE_RECORDING = 2; + + /// < 'PROCESSING' state + static const int STT_STATE_PROCESSING = 3; +} + +/// @brief Enumeration for result event. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class stt_result_event_e { + /// < Event when the recognition full or last result is ready + static const int STT_RESULT_EVENT_FINAL_RESULT = 0; + + /// < Event when the recognition partial result is ready + static const int STT_RESULT_EVENT_PARTIAL_RESULT = 1; + + /// < Event when the recognition has failed + static const int STT_RESULT_EVENT_ERROR = 2; +} + +/// @brief Enumeration for result time callback event. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class stt_result_time_event_e { + /// < Event when the token is beginning type + static const int STT_RESULT_TIME_EVENT_BEGINNING = 0; + + /// < Event when the token is middle type + static const int STT_RESULT_TIME_EVENT_MIDDLE = 1; + + /// < Event when the token is end type + static const int STT_RESULT_TIME_EVENT_END = 2; +} + +/// @brief Enumeration for silence detection type. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class stt_option_silence_detection_e { + /// < Silence detection type - False + static const int STT_OPTION_SILENCE_DETECTION_FALSE = 0; + + /// < Silence detection type - True + static const int STT_OPTION_SILENCE_DETECTION_TRUE = 1; + + /// < Silence detection type - Auto + static const int STT_OPTION_SILENCE_DETECTION_AUTO = 2; +} + +class stt_s extends ffi.Opaque {} + +/// @brief Enumeration for error codes. +/// @since_tizen 3.0 +abstract class stte_error_e { + /// < Successful + static const int STTE_ERROR_NONE = 0; + + /// < Out of Memory + static const int STTE_ERROR_OUT_OF_MEMORY = -12; + + /// < I/O error + static const int STTE_ERROR_IO_ERROR = -5; + + /// < Invalid parameter + static const int STTE_ERROR_INVALID_PARAMETER = -22; + + /// < Network down(Out of network) + static const int STTE_ERROR_NETWORK_DOWN = -100; + + /// < Invalid state + static const int STTE_ERROR_INVALID_STATE = -49283071; + + /// < Invalid language + static const int STTE_ERROR_INVALID_LANGUAGE = -49283070; + + /// < Operation failed + static const int STTE_ERROR_OPERATION_FAILED = -49283068; + + /// < Not supported feature + static const int STTE_ERROR_NOT_SUPPORTED_FEATURE = -49283067; + + /// < Not supported + static const int STTE_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Permission denied + static const int STTE_ERROR_PERMISSION_DENIED = -13; + + /// < Recording timed out + static const int STTE_ERROR_RECORDING_TIMED_OUT = -49283066; +} + +/// @brief Enumeration for audio type. +/// @since_tizen 3.0 +abstract class stte_audio_type_e { + /// < Signed 16bit audio type, Little endian + static const int STTE_AUDIO_TYPE_PCM_S16_LE = 0; + + /// < Unsigned 8bit audio type + static const int STTE_AUDIO_TYPE_PCM_U8 = 1; +} + +/// @brief Enumeration for callback event. +/// @since_tizen 3.0 +abstract class stte_result_event_e { + /// < Event when either the full matched or the final result is delivered + static const int STTE_RESULT_EVENT_FINAL_RESULT = 0; + + /// < Event when the partial matched result is delivered + static const int STTE_RESULT_EVENT_PARTIAL_RESULT = 1; + + /// < Event when the recognition has failed + static const int STTE_RESULT_EVENT_ERROR = 2; +} + +/// @brief Enumeration for result time callback event. +/// @since_tizen 3.0 +abstract class stte_result_time_event_e { + /// < Event when the token is beginning type + static const int STTE_RESULT_TIME_EVENT_BEGINNING = 0; + + /// < Event when the token is middle type + static const int STTE_RESULT_TIME_EVENT_MIDDLE = 1; + + /// < Event when the token is end type + static const int STTE_RESULT_TIME_EVENT_END = 2; +} + +/// @brief Enumeration for speech status. +/// @since_tizen 3.0 +abstract class stte_speech_status_e { + /// < Beginning point of speech is detected + static const int STTE_SPEECH_STATUS_BEGINNING_POINT_DETECTED = 0; + + /// < End point of speech is detected + static const int STTE_SPEECH_STATUS_END_POINT_DETECTED = 1; +} + +/// @brief A structure for the STT engine functions. +/// @details This structure contains essential callback functions for operating STT engine. +/// @since_tizen 3.0 +/// @remarks These functions are mandatory for operating STT engine. Therefore, all functions MUST be implemented. +class stte_request_callback_s extends ffi.Struct { + /// < The version of the structure 'stte_request_callback_s' + @ffi.Int32() + external int version; + + /// < Called when the engine service user requests the basic information of STT engine + external ffi.Pointer> get_info; + + /// < Called when the engine service user initializes STT engine + external ffi.Pointer> initialize; + + /// < Called when the engine service user deinitializes STT engine + external ffi.Pointer> deinitialize; + + /// < Called when the engine service user gets the whole supported language list + external ffi.Pointer> + foreach_langs; + + /// < Called when the engine service user checks whether the corresponding language is valid or not + external ffi.Pointer> + is_valid_lang; + + /// < Called when the engine service user checks whether STT engine supports silence detection + external ffi.Pointer> + support_silence; + + /// < Called when the engine service user checks whether STT engine supports the corresponding recognition type + external ffi.Pointer> + support_recognition_type; + + /// < Called when the engine service user gets the proper recording format of STT engine + external ffi.Pointer> + get_audio_format; + + /// < Called when the engine service user gets the result time information(stamp) + external ffi.Pointer> + foreach_result_time; + + /// < Called when the engine service user sets the silence detection + external ffi.Pointer> + set_silence_detection; + + /// < Called when the engine service user starts to recognize the recording data + external ffi.Pointer> start; + + /// < Called when the engine service user sets and sends the recording data for speech recognition + external ffi.Pointer> + set_recording; + + /// < Called when the engine service user stops to recognize the recording data + external ffi.Pointer> stop; + + /// < Called when the engine service user cancels to recognize the recording data + external ffi.Pointer> cancel; + + /// < Called when the engine service user requests for STT engine to check whether the application agreed the usage of STT engine + external ffi.Pointer> + check_app_agreed; + + /// < Called when the engine service user checks whether STT engine needs the application's credential + external ffi.Pointer> + need_app_credential; +} + +/// @brief Enumeration for error code. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class tts_error_e { + /// < Successful + static const int TTS_ERROR_NONE = 0; + + /// < Out of Memory + static const int TTS_ERROR_OUT_OF_MEMORY = -12; + + /// < I/O error + static const int TTS_ERROR_IO_ERROR = -5; + + /// < Invalid parameter + static const int TTS_ERROR_INVALID_PARAMETER = -22; + + /// < Network is down + static const int TTS_ERROR_OUT_OF_NETWORK = -100; + + /// < No answer from the daemon + static const int TTS_ERROR_TIMED_OUT = -1073741823; + + /// < Permission denied + static const int TTS_ERROR_PERMISSION_DENIED = -13; + + /// < TTS NOT supported + static const int TTS_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Invalid state + static const int TTS_ERROR_INVALID_STATE = -49348607; + + /// < Invalid voice + static const int TTS_ERROR_INVALID_VOICE = -49348606; + + /// < No available engine + static const int TTS_ERROR_ENGINE_NOT_FOUND = -49348605; + + /// < Operation failed + static const int TTS_ERROR_OPERATION_FAILED = -49348604; + + /// < Audio policy blocked + static const int TTS_ERROR_AUDIO_POLICY_BLOCKED = -49348603; + + /// < Not supported feature of current engine @if MOBILE (Since 3.0) @elseif WEARABLE (Since 2.3.2) @endif + static const int TTS_ERROR_NOT_SUPPORTED_FEATURE = -49348602; + + /// < Service reset @if MOBILE (Since 3.0) @elseif WEARABLE (Since 2.3.2) @endif + static const int TTS_ERROR_SERVICE_RESET = -49348601; +} + +/// @brief Enumeration for TTS mode. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class tts_mode_e { + /// < Default mode for normal application + static const int TTS_MODE_DEFAULT = 0; + + /// < Notification mode + static const int TTS_MODE_NOTIFICATION = 1; + + /// < Accessibiliity mode + static const int TTS_MODE_SCREEN_READER = 2; +} + +/// @brief Enumeration for state. +/// @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif +abstract class tts_state_e { + /// < 'CREATED' state + static const int TTS_STATE_CREATED = 0; + + /// < 'READY' state + static const int TTS_STATE_READY = 1; + + /// < 'PLAYING' state + static const int TTS_STATE_PLAYING = 2; + + /// < 'PAUSED' state + static const int TTS_STATE_PAUSED = 3; +} + +class tts_s extends ffi.Opaque {} + +/// @brief Enumeration for error codes. +/// @since_tizen 3.0 +abstract class ttse_error_e { + /// < Successful + static const int TTSE_ERROR_NONE = 0; + + /// < Out of Memory + static const int TTSE_ERROR_OUT_OF_MEMORY = -12; + + /// < I/O error + static const int TTSE_ERROR_IO_ERROR = -5; + + /// < Invalid parameter + static const int TTSE_ERROR_INVALID_PARAMETER = -22; + + /// < Out of network + static const int TTSE_ERROR_NETWORK_DOWN = -100; + + /// < Permission denied + static const int TTSE_ERROR_PERMISSION_DENIED = -13; + + /// < Invalid state + static const int TTSE_ERROR_INVALID_STATE = -49348607; + + /// < Invalid voice + static const int TTSE_ERROR_INVALID_VOICE = -49348606; + + /// < Operation failed + static const int TTSE_ERROR_OPERATION_FAILED = -49348604; + + /// < Not supported feature + static const int TTSE_ERROR_NOT_SUPPORTED_FEATURE = -49348602; + + /// < Not supported + static const int TTSE_ERROR_NOT_SUPPORTED = -1073741822; +} + +/// @brief Enumeration for audio type. +/// @since_tizen 3.0 +abstract class ttse_audio_type_e { + /// < Signed 16-bit audio type + static const int TTSE_AUDIO_TYPE_RAW_S16 = 0; + + /// < Unsigned 8-bit audio type + static const int TTSE_AUDIO_TYPE_RAW_U8 = 1; + static const int TTSE_AUDIO_TYPE_MAX = 2; +} + +/// @brief Enumeration for result event type. +/// @since_tizen 3.0 +abstract class ttse_result_event_e { + /// < Event when the voice synthesis is failed + static const int TTSE_RESULT_EVENT_FAIL = -1; + + /// < Event when the sound data is first data by callback function + static const int TTSE_RESULT_EVENT_START = 1; + + /// < Event when the next sound data exist, not first and not last + static const int TTSE_RESULT_EVENT_CONTINUE = 2; + + /// < Event when the sound data is last data or sound data is only one result + static const int TTSE_RESULT_EVENT_FINISH = 3; +} + +/// @brief A structure for the TTS engine functions. +/// @details This structure contains essential callback functions for operating TTS engine. +/// @since_tizen 3.0 +/// @remarks These functions are mandatory for operating TTS engine. Therefore, all functions MUST be implemented. +class ttse_request_callback_s extends ffi.Struct { + /// < The version of the structure 'ttse_request_callback_s' + @ffi.Int32() + external int version; + + /// < Called when the engine service user requests the basic information of TTS engine + external ffi.Pointer> get_info; + + /// < Called when the engine service user initializes TTS engine + external ffi.Pointer> initialize; + + /// < Called when the engine service user deinitializes TTS engine + external ffi.Pointer> deinitialize; + + /// < Called when the engine service user gets the whole supported voice list + external ffi.Pointer> + foreach_voices; + + /// < Called when the engine service user checks whether the voice is valid or not in TTS engine + external ffi.Pointer> + is_valid_voice; + + /// < Called when the engine service user sets the default pitch of TTS engine + external ffi.Pointer> set_pitch; + + /// < Called when the engine service user requests to load the corresponding voice type for the first time + external ffi.Pointer> load_voice; + + /// < Called when the engine service user requests to unload the corresponding voice type or to stop using voice + external ffi.Pointer> unload_voice; + + /// < Called when the engine service user starts to synthesize a voice, asynchronously + external ffi.Pointer> start_synth; + + /// < Called when the engine service user cancels to synthesize a voice + external ffi.Pointer> + cancel_synth; + + /// < Called when the engine service user requests for TTS engine to check whether the application agreed the usage of TTS engine + external ffi.Pointer> + check_app_agreed; + + /// < Called when the engine service user checks whether TTS engine needs the application's credential + external ffi.Pointer> + need_app_credential; +} + +class vc_cmd_s extends ffi.Opaque {} + +class vc_cmd_list_s extends ffi.Opaque {} + +/// @brief Enumeration for error codes. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class vc_error_e { + /// < Successful + static const int VC_ERROR_NONE = 0; + + /// < Out of Memory + static const int VC_ERROR_OUT_OF_MEMORY = -12; + + /// < I/O error + static const int VC_ERROR_IO_ERROR = -5; + + /// < Invalid parameter + static const int VC_ERROR_INVALID_PARAMETER = -22; + + /// < No answer from service + static const int VC_ERROR_TIMED_OUT = -1073741823; + + /// < Busy recorder + static const int VC_ERROR_RECORDER_BUSY = -16; + + /// < Permission denied + static const int VC_ERROR_PERMISSION_DENIED = -13; + + /// < VC NOT supported + static const int VC_ERROR_NOT_SUPPORTED = -1073741822; + + /// < Invalid state + static const int VC_ERROR_INVALID_STATE = -49610735; + + /// < Invalid language + static const int VC_ERROR_INVALID_LANGUAGE = -49610734; + + /// < No available engine + static const int VC_ERROR_ENGINE_NOT_FOUND = -49610733; + + /// < Operation failed + static const int VC_ERROR_OPERATION_FAILED = -49610732; + + /// < Operation rejected + static const int VC_ERROR_OPERATION_REJECTED = -49610731; + + /// < List reached end + static const int VC_ERROR_ITERATION_END = -49610730; + + /// < List empty + static const int VC_ERROR_EMPTY = -49610729; + + /// < Service daemon reset (Since 3.0) + static const int VC_ERROR_SERVICE_RESET = -49610728; + + /// < In progress to ready (Since 3.0) + static const int VC_ERROR_IN_PROGRESS_TO_READY = -49610727; + + /// < In progress to recording (Since 3.0) + static const int VC_ERROR_IN_PROGRESS_TO_RECORDING = -49610720; + + /// < In progress to processing (Since 3.0) + static const int VC_ERROR_IN_PROGRESS_TO_PROCESSING = -49610719; + + /// < Not supported feature of current engine (Since 4.0) + static const int VC_ERROR_NOT_SUPPORTED_FEATURE = -49610718; +} + +/// @brief Enumeration for result event. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class vc_result_event_e { + /// < Normal result + static const int VC_RESULT_EVENT_RESULT_SUCCESS = 0; + + /// < Rejected result + static const int VC_RESULT_EVENT_REJECTED = 1; +} + +/// @brief Enumeration for service state. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class vc_service_state_e { + /// < 'None' state + static const int VC_SERVICE_STATE_NONE = 0; + + /// < 'Ready' state + static const int VC_SERVICE_STATE_READY = 1; + + /// < 'Recording' state + static const int VC_SERVICE_STATE_RECORDING = 2; + + /// < 'Processing' state + static const int VC_SERVICE_STATE_PROCESSING = 3; +} + +/// @brief Enumeration for client state. +/// @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif +abstract class vc_state_e { + /// < 'None' state + static const int VC_STATE_NONE = 0; + + /// < 'Initialized' state + static const int VC_STATE_INITIALIZED = 1; + + /// < 'Ready' state + static const int VC_STATE_READY = 2; +} + +/// @brief Enumerations of audio types. +/// @since_tizen 5.0 +abstract class vc_audio_type_e { + /// < Signed 16bit audio type, Little endian + static const int VC_AUDIO_TYPE_PCM_S16_LE = 0; + + /// < Unsigned 8bit audio type + static const int VC_AUDIO_TYPE_PCM_U8 = 1; +} + +/// @brief Enumerations for audio channels +/// @since_tizen 5.0 +abstract class vc_audio_channel_e { + /// < 1 channel, mono + static const int VC_AUDIO_CHANNEL_MONO = 0; + + /// < 2 channels, stereo + static const int VC_AUDIO_CHANNEL_STEREO = 1; +} + +/// @brief Enumeration for TTS feedback events +/// @since_tizen 5.0 +abstract class vc_feedback_event_e { + /// < Failed + static const int VC_FEEDBACK_EVENT_FAIL = -1; + + /// < Start event + static const int VC_FEEDBACK_EVENT_START = 1; + + /// < Continue event + static const int VC_FEEDBACK_EVENT_CONTINUE = 2; + + /// < Finish event + static const int VC_FEEDBACK_EVENT_FINISH = 3; +} + +const String ACCOUNT_NOTI_NAME_INSERT = 'insert'; + +const String ACCOUNT_NOTI_NAME_UPDATE = 'update'; + +const String ACCOUNT_NOTI_NAME_DELETE = 'delete'; + +const String ACCOUNT_NOTI_NAME_SYNC_UPDATE = 'sync_update'; + +const String ACCOUNT_DATA_USERNAME = 'http://tizen.org/account/data/username'; + +const String ACCOUNT_DATA_ID = 'http://tizen.org/appcontrol/data/account/id'; + +const String ACCOUNT_OPERATION_SIGNIN = + 'http://tizen.org/appcontrol/operation/account/add'; + +const String ACCOUNT_OPERATION_VIEW = + 'http://tizen.org/appcontrol/operation/account/configure'; + +const String ACCOUNT_SUPPORTS_CAPABILITY_CONTACT = + 'http://tizen.org/account/capability/contact'; + +const String ACCOUNT_SUPPORTS_CAPABILITY_CALENDAR = + 'http://tizen.org/account/capability/calendar'; + +const String ACCOUNT_SUPPORTS_CAPABILITY_EMAIL = + 'http://tizen.org/account/capability/email'; + +const String ACCOUNT_SUPPORTS_CAPABILITY_PHOTO = + 'http://tizen.org/account/capability/photo'; + +const String ACCOUNT_SUPPORTS_CAPABILITY_VIDEO = + 'http://tizen.org/account/capability/video'; + +const String ACCOUNT_SUPPORTS_CAPABILITY_MUSIC = + 'http://tizen.org/account/capability/music'; + +const String ACCOUNT_SUPPORTS_CAPABILITY_DOCUMENT = + 'http://tizen.org/account/capability/document'; + +const String ACCOUNT_SUPPORTS_CAPABILITY_MESSAGE = + 'http://tizen.org/account/capability/message'; + +const String ACCOUNT_SUPPORTS_CAPABILITY_GAME = + 'http://tizen.org/account/capability/game'; + +const int NULL = 0; + +const int TIZEN_ERROR_MAX_PLATFORM_ERROR = 0; + +const int TIZEN_ERROR_MIN_PLATFORM_ERROR = -1073741824; + +const int TIZEN_ERROR_MIN_MODULE_ERROR = -2147483648; + +const int TIZEN_ERROR_MAX_MODULE_ERROR = -1073741825; + +const int TIZEN_ERROR_APPLICATION_CLASS = -512; + +const int TIZEN_ERROR_BASE_CLASS = -1024; + +const int TIZEN_ERROR_CONTENT_CLASS = -2048; + +const int TIZEN_ERROR_LOCATION_CLASS = -4096; + +const int TIZEN_ERROR_MULTIMEDIA_CLASS = -8192; + +const int TIZEN_ERROR_MESSAGING_CLASS = -16384; + +const int TIZEN_ERROR_NETWORK_CLASS = -32768; + +const int TIZEN_ERROR_SOCIAL_CLASS = -65536; + +const int TIZEN_ERROR_SYSTEM_CLASS = -131072; + +const int TIZEN_ERROR_TELEPHONY_CLASS = -262144; + +const int TIZEN_ERROR_UI_CLASS = -524288; + +const int TIZEN_ERROR_UIX_CLASS = -1048576; + +const int TIZEN_ERROR_AD_CLASS = -2097152; + +const int TIZEN_ERROR_WEB_CLASS = -4194304; + +const int TIZEN_ERROR_DRM_CLASS = -8388608; + +const int TIZEN_ERROR_ACCOUNT_CLASS = -16777216; + +const int TIZEN_ERROR_ACCOUNT = -16777216; + +const int TIZEN_ERROR_ACCOUNT_OAUTH = -16842752; + +const int TIZEN_ERROR_SYNC_MANAGER = -16908288; + +const int TIZEN_ERROR_FIDO = -16973824; + +const int TIZEN_ERROR_APPLICATION = -17825792; + +const int TIZEN_ERROR_APPLICATION_MANAGER = -17891328; + +const int TIZEN_ERROR_BADGE = -17956864; + +const int TIZEN_ERROR_MESSAGE_PORT = -18022400; + +const int TIZEN_ERROR_NOTIFICATION = -18087936; + +const int TIZEN_ERROR_PACKAGE_MANAGER = -18153472; + +const int TIZEN_ERROR_SHORTCUT = -18219008; + +const int TIZEN_ERROR_BUNDLE = -18350080; + +const int TIZEN_ERROR_DATA_CONTROL = -18415616; + +const int TIZEN_ERROR_SERVICE_APPLICATION = -18874368; + +const int TIZEN_ERROR_MINICONTROL = -18939904; + +const int TIZEN_ERROR_UTILITY_ICU = -22020096; + +const int TIZEN_ERROR_MIME_TYPE = -23068672; + +const int TIZEN_ERROR_MEDIA_CONTENT = -23134208; + +const int TIZEN_ERROR_EMAIL_SERVICE = -24117248; + +const int TIZEN_ERROR_MESSAGING_SERVICE = -24182784; + +const int TIZEN_ERROR_PUSH = -24248320; + +const int TIZEN_ERROR_AUDIO_IO = -26214400; + +const int TIZEN_ERROR_CAMERA = -26279936; + +const int TIZEN_ERROR_IMAGE_UTIL = -26345472; + +const int TIZEN_ERROR_METADATA_EXTRACTOR = -26411008; + +const int TIZEN_ERROR_PLAYER = -26476544; + +const int TIZEN_ERROR_RECORDER = -26542080; + +const int TIZEN_ERROR_SOUND_MANAGER = -26607616; + +const int TIZEN_ERROR_TONE_PLAYER = -26673152; + +const int TIZEN_ERROR_VIDEO_UTIL = -26738688; + +const int TIZEN_ERROR_WAV_PLAYER = -26804224; + +const int TIZEN_ERROR_RADIO = -26869760; + +const int TIZEN_ERROR_MEDIACODEC = -26935296; + +const int TIZEN_ERROR_METADATA_EDITOR = -27000832; + +const int TIZEN_ERROR_MEDIA_VISION = -27066368; + +const int TIZEN_ERROR_MEDIA_DEMUXER = -27131904; + +const int TIZEN_ERROR_MEDIA_MUXER = -27197440; + +const int TIZEN_ERROR_MEDIA_STREAMER = -27262976; + +const int TIZEN_ERROR_STREAMRECORDER = -27328512; + +const int TIZEN_ERROR_MEDIA_TOOL = -27394048; + +const int TIZEN_ERROR_BLUETOOTH = -29360128; + +const int TIZEN_ERROR_CONNECTION = -29425664; + +const int TIZEN_ERROR_NFC = -29491200; + +const int TIZEN_ERROR_SERIAL = -29556736; + +const int TIZEN_ERROR_TETHERING = -29622272; + +const int TIZEN_ERROR_WIFI = -29687808; + +const int TIZEN_ERROR_WIFI_DIRECT = -29753344; + +const int TIZEN_ERROR_SMARTCARD = -29818880; + +const int TIZEN_ERROR_IOTCON = -29884416; + +const int TIZEN_ERROR_SSDP = -29949952; + +const int TIZEN_ERROR_DNSSD = -30015488; + +const int TIZEN_ERROR_VPNSVC = -30081024; + +const int TIZEN_ERROR_MTP = -30146560; + +const int TIZEN_ERROR_HTTP = -30212096; + +const int TIZEN_ERROR_WIFI_MANAGER = -30277632; + +const int TIZEN_ERROR_PRIVACY_MANAGER = -31457280; + +const int TIZEN_ERROR_KEY_MANAGER = -31522816; + +const int TIZEN_ERROR_PRIVILEGE_INFORMATION = -31588352; + +const int TIZEN_ERROR_CSR = -31653888; + +const int TIZEN_ERROR_CALENDAR = -33554432; + +const int TIZEN_ERROR_CONTACTS = -33619968; + +const int TIZEN_ERROR_PHONENUMBER_UTILS = -33685504; + +const int TIZEN_ERROR_STORAGE = -35651584; + +const int TIZEN_ERROR_VCONF = -35717120; + +const int TIZEN_ERROR_DEVICE = -37748736; + +const int TIZEN_ERROR_DLOG = -37814272; + +const int TIZEN_ERROR_MEDIA_KEY = -37879808; + +const int TIZEN_ERROR_RUNTIME_INFORMATION = -37945344; + +const int TIZEN_ERROR_SENSOR = -38010880; + +const int TIZEN_ERROR_SYSTEM_INFORMATION = -38076416; + +const int TIZEN_ERROR_SYSTEM_SETTING = -38141952; + +const int TIZEN_ERROR_SYSTEM_RESOURCE = -38207488; + +const int TIZEN_ERROR_CONTEXT = -38273024; + +const int TIZEN_ERROR_HEALTH = -38338560; + +const int TIZEN_ERROR_FEEDBACK = -38404096; + +const int TIZEN_ERROR_USB_HOST = -38469632; + +const int TIZEN_ERROR_TELEPHONY = -39845888; + +const int TIZEN_ERROR_EFL_UTIL = -41943040; + +const int TIZEN_ERROR_UTILX = -42008576; + +const int TIZEN_ERROR_NATIVE_BUFFER = -42074112; + +const int TIZEN_ERROR_TBM = -42139648; + +const int TIZEN_ERROR_EOM = -42205184; + +const int TIZEN_ERROR_PANEL = -42270720; + +const int TIZEN_ERROR_TZSH = -42336256; + +const int TIZEN_ERROR_DOWNLOAD = -44040192; + +const int TIZEN_ERROR_WEBVIEW = -44105728; + +const int TIZEN_ERROR_LOCATION_MANAGER = -46137344; + +const int TIZEN_ERROR_GEOFENCE_MANAGER = -46202880; + +const int TIZEN_ERROR_MAPS_SERVICE = -46268416; + +const int TIZEN_ERROR_STT = -49283072; + +const int TIZEN_ERROR_TTS = -49348608; + +const int TIZEN_ERROR_IME = -49414144; + +const int TIZEN_ERROR_SERVICE_ADAPTOR = -49479680; + +const int TIZEN_ERROR_WIDGET = -49545216; + +const int TIZEN_ERROR_VOICE_CONTROL = -49610752; + +const int TIZEN_ERROR_ASP = -49676288; + +const int TIZEN_ERROR_ZIGBEE = -49741824; + +const int TIZEN_ERROR_STC = -49807360; + +const int TIZEN_ERROR_THUMBNAIL_UTIL = -49872896; + +const int TIZEN_ERROR_JOB_SCHEDULER = -49938432; + +const int FIDO_SERVER_STATUS_CODE_OK = 1200; + +const String SYNC_SUPPORTS_CAPABILITY_CALENDAR = + 'http://tizen.org/sync/capability/calendar'; + +const String SYNC_SUPPORTS_CAPABILITY_CONTACT = + 'http://tizen.org/sync/capability/contact'; + +const String SYNC_SUPPORTS_CAPABILITY_IMAGE = + 'http://tizen.org/sync/capability/image'; + +const String SYNC_SUPPORTS_CAPABILITY_VIDEO = + 'http://tizen.org/sync/capability/video'; + +const String SYNC_SUPPORTS_CAPABILITY_SOUND = + 'http://tizen.org/sync/capability/sound'; + +const String SYNC_SUPPORTS_CAPABILITY_MUSIC = + 'http://tizen.org/sync/capability/music'; + +const String APP_CONTROL_OPERATION_MAIN = + 'http://tizen.org/appcontrol/operation/main'; + +const String APP_CONTROL_OPERATION_DEFAULT = + 'http://tizen.org/appcontrol/operation/default'; + +const String APP_CONTROL_OPERATION_EDIT = + 'http://tizen.org/appcontrol/operation/edit'; + +const String APP_CONTROL_OPERATION_VIEW = + 'http://tizen.org/appcontrol/operation/view'; + +const String APP_CONTROL_OPERATION_PICK = + 'http://tizen.org/appcontrol/operation/pick'; + +const String APP_CONTROL_OPERATION_CREATE_CONTENT = + 'http://tizen.org/appcontrol/operation/create_content'; + +const String APP_CONTROL_OPERATION_CALL = + 'http://tizen.org/appcontrol/operation/call'; + +const String APP_CONTROL_OPERATION_SEND = + 'http://tizen.org/appcontrol/operation/send'; + +const String APP_CONTROL_OPERATION_SEND_TEXT = + 'http://tizen.org/appcontrol/operation/send_text'; + +const String APP_CONTROL_OPERATION_SHARE = + 'http://tizen.org/appcontrol/operation/share'; + +const String APP_CONTROL_OPERATION_MULTI_SHARE = + 'http://tizen.org/appcontrol/operation/multi_share'; + +const String APP_CONTROL_OPERATION_SHARE_TEXT = + 'http://tizen.org/appcontrol/operation/share_text'; + +const String APP_CONTROL_OPERATION_DIAL = + 'http://tizen.org/appcontrol/operation/dial'; + +const String APP_CONTROL_OPERATION_SEARCH = + 'http://tizen.org/appcontrol/operation/search'; + +const String APP_CONTROL_OPERATION_DOWNLOAD = + 'http://tizen.org/appcontrol/operation/download'; + +const String APP_CONTROL_OPERATION_PRINT = + 'http://tizen.org/appcontrol/operation/print'; + +const String APP_CONTROL_OPERATION_COMPOSE = + 'http://tizen.org/appcontrol/operation/compose'; + +const String APP_CONTROL_OPERATION_LAUNCH_ON_EVENT = + 'http://tizen.org/appcontrol/operation/launch_on_event'; + +const String APP_CONTROL_OPERATION_ADD = + 'http://tizen.org/appcontrol/operation/add'; + +const String APP_CONTROL_OPERATION_IMAGE_CAPTURE = + 'http://tizen.org/appcontrol/operation/image_capture'; + +const String APP_CONTROL_OPERATION_VIDEO_CAPTURE = + 'http://tizen.org/appcontrol/operation/video_capture'; + +const String APP_CONTROL_OPERATION_SETTING_BT_ENABLE = + 'http://tizen.org/appcontrol/operation/setting/bt_enable'; + +const String APP_CONTROL_OPERATION_SETTING_BT_VISIBILITY = + 'http://tizen.org/appcontrol/operation/setting/bt_visibility'; + +const String APP_CONTROL_OPERATION_SETTING_LOCATION = + 'http://tizen.org/appcontrol/operation/setting/location'; + +const String APP_CONTROL_OPERATION_SETTING_NFC = + 'http://tizen.org/appcontrol/operation/setting/nfc'; + +const String APP_CONTROL_OPERATION_SETTING = + 'http://tizen.org/appcontrol/operation/setting'; + +const String APP_CONTROL_OPERATION_SETTING_WIFI = + 'http://tizen.org/appcontrol/operation/setting/wifi'; + +const String APP_CONTROL_OPERATION_SETTING_VPN = + 'http://tizen.org/appcontrol/operation/setting/vpn'; + +const String APP_CONTROL_OPERATION_GET_INPUT = + 'http://tizen.org/appcontrol/operation/get_input'; + +const String APP_CONTROL_OPERATION_MEDIA_CONTROLLER = + 'http://tizen.org/appcontrol/operation/media_control'; + +const String APP_CONTROL_DATA_SUBJECT = + 'http://tizen.org/appcontrol/data/subject'; + +const String APP_CONTROL_DATA_TO = 'http://tizen.org/appcontrol/data/to'; + +const String APP_CONTROL_DATA_CC = 'http://tizen.org/appcontrol/data/cc'; + +const String APP_CONTROL_DATA_BCC = 'http://tizen.org/appcontrol/data/bcc'; + +const String APP_CONTROL_DATA_TEXT = 'http://tizen.org/appcontrol/data/text'; + +const String APP_CONTROL_DATA_TITLE = 'http://tizen.org/appcontrol/data/title'; + +const String APP_CONTROL_DATA_SELECTED = + 'http://tizen.org/appcontrol/data/selected'; + +const String APP_CONTROL_DATA_PATH = 'http://tizen.org/appcontrol/data/path'; + +const String APP_CONTROL_DATA_SELECTION_MODE = + 'http://tizen.org/appcontrol/data/selection_mode'; + +const String APP_CONTROL_DATA_CALENDAR_ALL_DAY = + 'http://tizen.org/appcontrol/data/calendar/all_day'; + +const String APP_CONTROL_DATA_CALENDAR_START_TIME = + 'http://tizen.org/appcontrol/data/calendar/start_time'; + +const String APP_CONTROL_DATA_CALENDAR_END_TIME = + 'http://tizen.org/appcontrol/data/calendar/end_time'; + +const String APP_CONTROL_DATA_EMAIL = 'http://tizen.org/appcontrol/data/email'; + +const String APP_CONTROL_DATA_PHONE = 'http://tizen.org/appcontrol/data/phone'; + +const String APP_CONTROL_DATA_URL = 'http://tizen.org/appcontrol/data/url'; + +const String APP_CONTROL_DATA_ID = 'http://tizen.org/appcontrol/data/id'; + +const String APP_CONTROL_DATA_TYPE = 'http://tizen.org/appcontrol/data/type'; + +const String APP_CONTROL_DATA_TOTAL_COUNT = + 'http://tizen.org/appcontrol/data/total_count'; + +const String APP_CONTROL_DATA_TOTAL_SIZE = + 'http://tizen.org/appcontrol/data/total_size'; + +const String APP_CONTROL_DATA_NAME = 'http://tizen.org/appcontrol/data/name'; + +const String APP_CONTROL_DATA_LOCATION = + 'http://tizen.org/appcontrol/data/location'; + +const String APP_CONTROL_DATA_INPUT_TYPE = + 'http://tizen.org/appcontrol/data/input_type'; + +const String APP_CONTROL_DATA_INPUT_DEFAULT_TEXT = + 'http://tizen.org/appcontrol/data/input_default_text'; + +const String APP_CONTROL_DATA_INPUT_GUIDE_TEXT = + 'http://tizen.org/appcontrol/data/input_guide_text'; + +const String APP_CONTROL_DATA_INPUT_PREDICTION_HINT = + 'http://tizen.org/appcontrol/data/input_prediction_hint'; + +const String APP_CONTROL_DATA_INPUT_RETURNKEY_TYPE = + 'http://tizen.org/appcontrol/data/input_returnkey_type'; + +const String APP_CONTROL_DATA_INPUT_MAX_TEXT_LENGTH = + 'http://tizen.org/appcontrol/data/input_max_text_length'; + +const String APP_CONTROL_DATA_INPUT_CURSOR_POSITION_SET = + 'http://tizen.org/appcontrol/data/input_cursor_position_set'; + +const String APP_CONTROL_DATA_INPUT_CURSOR_POSITION_GET = + 'http://tizen.org/appcontrol/data/input_cursor_position_get'; + +const String APP_CONTROL_DATA_INPUT_REPLY_TYPE = + 'http://tizen.org/appcontrol/data/input_reply_type'; + +const String APP_CONTROL_DATA_WIDGET_INSTANCE_ID = + 'http://tizen.org/appcontrol/data/widget_instance_id'; + +const String APP_CONTROL_DATA_WIDGET_CONTENT = + 'http://tizen.org/appcontrol/data/widget_content'; + +const String APP_CONTROL_DATA_WIDGET_APP_ID = + 'http://tizen.org/appcontrol/data/widget_app_id'; + +const String APP_CONTROL_DATA_ALARM_ID = + 'http://tizen.org/appcontrol/data/alarm_id'; + +const String SYSTEM_EVENT_BATTERY_CHARGER_STATUS = + 'tizen.system.event.battery_charger_status'; + +const String EVENT_KEY_BATTERY_CHARGER_STATUS = 'battery_charger_status'; + +const String EVENT_VAL_BATTERY_CHARGER_DISCONNECTED = 'disconnected'; + +const String EVENT_VAL_BATTERY_CHARGER_CONNECTED = 'connected'; + +const String EVENT_VAL_BATTERY_CHARGER_CHARGING = 'charging'; + +const String EVENT_VAL_BATTERY_CHARGER_DISCHARGING = 'discharging'; + +const String SYSTEM_EVENT_BATTERY_LEVEL_STATUS = + 'tizen.system.event.battery_level_status'; + +const String EVENT_KEY_BATTERY_LEVEL_STATUS = 'battery_level_status'; + +const String EVENT_VAL_BATTERY_LEVEL_EMPTY = 'empty'; + +const String EVENT_VAL_BATTERY_LEVEL_CRITICAL = 'critical'; + +const String EVENT_VAL_BATTERY_LEVEL_LOW = 'low'; + +const String EVENT_VAL_BATTERY_LEVEL_HIGH = 'high'; + +const String EVENT_VAL_BATTERY_LEVEL_FULL = 'full'; + +const String SYSTEM_EVENT_USB_STATUS = 'tizen.system.event.usb_status'; + +const String EVENT_KEY_USB_STATUS = 'usb_status'; + +const String EVENT_VAL_USB_DISCONNECTED = 'disconnected'; + +const String EVENT_VAL_USB_CONNECTED = 'connected'; + +const String EVENT_VAL_USB_AVAILABLE = 'available'; + +const String SYSTEM_EVENT_EARJACK_STATUS = 'tizen.system.event.earjack_status'; + +const String EVENT_KEY_EARJACK_STATUS = 'earjack_status'; + +const String EVENT_VAL_EARJACK_DISCONNECTED = 'disconnected'; + +const String EVENT_VAL_EARJACK_CONNECTED = 'connected'; + +const String SYSTEM_EVENT_DISPLAY_STATE = 'tizen.system.event.display_state'; + +const String EVENT_KEY_DISPLAY_STATE = 'display_state'; + +const String EVENT_VAL_DISPLAY_NORMAL = 'normal'; + +const String EVENT_VAL_DISPLAY_DIM = 'dim'; + +const String EVENT_VAL_DISPLAY_OFF = 'off'; + +const String SYSTEM_EVENT_BOOT_COMPLETED = 'tizen.system.event.boot_completed'; + +const String SYSTEM_EVENT_SYSTEM_SHUTDOWN = + 'tizen.system.event.system_shutdown'; + +const String SYSTEM_EVENT_LOW_MEMORY = 'tizen.system.event.low_memory'; + +const String EVENT_KEY_LOW_MEMORY = 'low_memory'; + +const String EVENT_VAL_MEMORY_NORMAL = 'normal'; + +const String EVENT_VAL_MEMORY_SOFT_WARNING = 'soft_warning'; + +const String EVENT_VAL_MEMORY_HARD_WARNING = 'hard_warning'; + +const String SYSTEM_EVENT_WIFI_STATE = 'tizen.system.event.wifi_state'; + +const String EVENT_KEY_WIFI_STATE = 'wifi_state'; + +const String EVENT_VAL_WIFI_OFF = 'off'; + +const String EVENT_VAL_WIFI_ON = 'on'; + +const String EVENT_VAL_WIFI_CONNECTED = 'connected'; + +const String SYSTEM_EVENT_BT_STATE = 'tizen.system.event.bt_state'; + +const String EVENT_KEY_BT_STATE = 'bt_state'; + +const String EVENT_VAL_BT_OFF = 'off'; + +const String EVENT_VAL_BT_ON = 'on'; + +const String EVENT_KEY_BT_LE_STATE = 'bt_le_state'; + +const String EVENT_VAL_BT_LE_OFF = 'off'; + +const String EVENT_VAL_BT_LE_ON = 'on'; + +const String EVENT_KEY_BT_TRANSFERING_STATE = 'bt_transfering_state'; + +const String EVENT_VAL_BT_NON_TRANSFERING = 'non_transfering'; + +const String EVENT_VAL_BT_TRANSFERING = 'transfering'; + +const String SYSTEM_EVENT_LOCATION_ENABLE_STATE = + 'tizen.system.event.location_enable_state'; + +const String EVENT_KEY_LOCATION_ENABLE_STATE = 'location_enable_state'; + +const String EVENT_VAL_LOCATION_DISABLED = 'disabled'; + +const String EVENT_VAL_LOCATION_ENABLED = 'enabled'; + +const String SYSTEM_EVENT_GPS_ENABLE_STATE = + 'tizen.system.event.gps_enable_state'; + +const String EVENT_KEY_GPS_ENABLE_STATE = 'gps_enable_state'; + +const String EVENT_VAL_GPS_DISABLED = 'disabled'; + +const String EVENT_VAL_GPS_ENABLED = 'enabled'; + +const String SYSTEM_EVENT_NPS_ENABLE_STATE = + 'tizen.system.event.nps_enable_state'; + +const String EVENT_KEY_NPS_ENABLE_STATE = 'nps_enable_state'; + +const String EVENT_VAL_NPS_DISABLED = 'disabled'; + +const String EVENT_VAL_NPS_ENABLED = 'enabled'; + +const String SYSTEM_EVENT_INCOMING_MSG = 'tizen.system.event.incoming_msg'; + +const String EVENT_KEY_MSG_TYPE = 'msg_type'; + +const String EVENT_VAL_SMS = 'sms'; + +const String EVENT_VAL_MMS = 'mms'; + +const String EVENT_VAL_PUSH = 'push'; + +const String EVENT_VAL_CB = 'cb'; + +const String EVENT_KEY_MSG_ID = 'msg_id'; + +const String SYSTEM_EVENT_OUTGOING_MSG = 'tizen.system.event.outgoing_msg'; + +const String EVENT_KEY_OUT_MSG_TYPE = 'msg_type'; + +const String EVENT_KEY_OUT_MSG_ID = 'msg_id'; + +const String SYSTEM_EVENT_TIME_CHANGED = 'tizen.system.event.time_changed'; + +const String SYSTEM_EVENT_TIME_ZONE = 'tizen.system.event.time_zone'; + +const String EVENT_KEY_TIME_ZONE = 'time_zone'; + +const String SYSTEM_EVENT_HOUR_FORMAT = 'tizen.system.event.hour_format'; + +const String EVENT_KEY_HOUR_FORMAT = 'hour_format'; + +const String EVENT_VAL_HOURFORMAT_12 = '12'; + +const String EVENT_VAL_HOURFORMAT_24 = '24'; + +const String SYSTEM_EVENT_LANGUAGE_SET = 'tizen.system.event.language_set'; + +const String EVENT_KEY_LANGUAGE_SET = 'language_set'; + +const String SYSTEM_EVENT_REGION_FORMAT = 'tizen.system.event.region_format'; + +const String EVENT_KEY_REGION_FORMAT = 'region_format'; + +const String SYSTEM_EVENT_SILENT_MODE = 'tizen.system.event.silent_mode'; + +const String EVENT_KEY_SILENT_MODE = 'silent_mode'; + +const String EVENT_VAL_SILENTMODE_ON = 'on'; + +const String EVENT_VAL_SILENTMODE_OFF = 'off'; + +const String SYSTEM_EVENT_VIBRATION_STATE = + 'tizen.system.event.vibration_state'; + +const String EVENT_KEY_VIBRATION_STATE = 'vibration_state'; + +const String EVENT_VAL_VIBRATION_ON = 'on'; + +const String EVENT_VAL_VIBRATION_OFF = 'off'; + +const String SYSTEM_EVENT_SCREEN_AUTOROTATE_STATE = + 'tizen.system.event.screen_autorotate_state'; + +const String EVENT_KEY_SCREEN_AUTOROTATE_STATE = 'screen_autorotate_state'; + +const String EVENT_VAL_SCREEN_AUTOROTATE_ON = 'on'; + +const String EVENT_VAL_SCREEN_AUTOROTATE_OFF = 'off'; + +const String SYSTEM_EVENT_MOBILE_DATA_STATE = + 'tizen.system.event.mobile_data_state'; + +const String EVENT_KEY_MOBILE_DATA_STATE = 'mobile_data_state'; + +const String EVENT_VAL_MOBILE_DATA_OFF = 'off'; + +const String EVENT_VAL_MOBILE_DATA_ON = 'on'; + +const String SYSTEM_EVENT_DATA_ROAMING_STATE = + 'tizen.system.event.data_roaming_state'; + +const String EVENT_KEY_DATA_ROAMING_STATE = 'data_roaming_state'; + +const String EVENT_VAL_DATA_ROAMING_OFF = 'off'; + +const String EVENT_VAL_DATA_ROAMING_ON = 'on'; + +const String SYSTEM_EVENT_FONT_SET = 'tizen.system.event.font_set'; + +const String EVENT_KEY_FONT_SET = 'font_set'; + +const String SYSTEM_EVENT_NETWORK_STATUS = 'tizen.system.event.network_status'; + +const String EVENT_KEY_NETWORK_STATUS = 'network_status'; + +const String EVENT_VAL_NETWORK_DISCONNECTED = 'disconnected'; + +const String EVENT_VAL_NETWORK_WIFI = 'wifi'; + +const String EVENT_VAL_NETWORK_CELLULAR = 'cellular'; + +const String EVENT_VAL_NETWORK_ETHERNET = 'ethernet'; + +const String EVENT_VAL_NETWORK_BT = 'bt'; + +const String EVENT_VAL_NETWORK_NET_PROXY = 'net_proxy'; + +const String PACKAGE_INFO_PROP_APP_ID = 'PACKAGE_INFO_PROP_APP_ID'; + +const String PACKAGE_INFO_PROP_APP_TYPE = 'PACKAGE_INFO_PROP_APP_TYPE'; + +const String PACKAGE_INFO_PROP_APP_CATEGORY = 'PACKAGE_INFO_PROP_APP_CATEGORY'; + +const String PACKAGE_INFO_PROP_APP_INSTALLED_STORAGE = + 'PACKAGE_INFO_PROP_APP_INSTALLED_STORAGE'; + +const String PACKAGE_INFO_PROP_APP_NODISPLAY = + 'PACKAGE_INFO_PROP_APP_NODISPLAY'; + +const String PACKAGE_INFO_PROP_APP_TASKMANAGE = + 'PACKAGE_INFO_PROP_APP_TASKMANAGE'; + +const String PACKAGE_INFO_PROP_APP_DISABLED = 'PACKAGE_INFO_PROP_APP_DISABLED'; + +const String PACKAGE_INFO_PROP_APP_COMPONENT_TYPE = + 'PACKAGE_INFO_PROP_APP_COMPONENT_TYPE'; + +const String PACKAGE_MANAGER_PKGINFO_PROP_REMOVABLE = + 'PMINFO_PKGINFO_PROP_PACKAGE_REMOVABLE'; + +const String PACKAGE_MANAGER_PKGINFO_PROP_READONLY = + 'PMINFO_PKGINFO_PROP_PACKAGE_READONLY'; + +const String PACKAGE_MANAGER_PKGINFO_PROP_SUPPORT_DISABLE = + 'PMINFO_PKGINFO_PROP_PACKAGE_SUPPORT_DISABLE'; + +const String PACKAGE_MANAGER_PKGINFO_PROP_DISABLE = + 'PMINFO_PKGINFO_PROP_PACKAGE_DISABLE'; + +const String PACKAGE_MANAGER_PKGINFO_PROP_PRELOAD = + 'PMINFO_PKGINFO_PROP_PACKAGE_PRELOAD'; + +const double WIDGET_VIEWER_EVAS_DEFAULT_PERIOD = -1.0; + +const String WIDGET_SMART_SIGNAL_WIDGET_CREATE_ABORTED = + 'widget,create,aborted'; + +const String WIDGET_SMART_SIGNAL_WIDGET_CREATED = 'widget,created'; + +const String WIDGET_SMART_SIGNAL_WIDGET_RESIZE_ABORTED = + 'widget,resize,aborted'; + +const String WIDGET_SMART_SIGNAL_WIDGET_RESIZED = 'widget,resized'; + +const String WIDGET_SMART_SIGNAL_WIDGET_FAULTED = 'widget,faulted'; + +const String WIDGET_SMART_SIGNAL_UPDATED = 'updated'; + +const String WIDGET_SMART_SIGNAL_EXTRA_INFO_UPDATED = 'info,updated'; + +const String WIDGET_SMART_SIGNAL_PROVIDER_DISCONNECTED = + 'provider,disconnected'; + +const String WIDGET_SMART_SIGNAL_CONTROL_SCROLLER = 'control,scroller'; + +const String WIDGET_SMART_SIGNAL_WIDGET_DELETED = 'widget,deleted'; + +const String WIDGET_SMART_SIGNAL_PERIOD_CHANGED = 'widget,period,changed'; + +const int MEDIA_CONTENT_ERROR_CLASS = -23134208; + +const String MEDIA_ID = 'MEDIA_ID'; + +const String MEDIA_PATH = 'MEDIA_PATH'; + +const String MEDIA_DISPLAY_NAME = 'MEDIA_DISPLAY_NAME'; + +const String MEDIA_TYPE = 'MEDIA_TYPE'; + +const String MEDIA_MIME_TYPE = 'MEDIA_MIME_TYPE'; + +const String MEDIA_SIZE = 'MEDIA_SIZE'; + +const String MEDIA_ADDED_TIME = 'MEDIA_ADDED_TIME'; + +const String MEDIA_MODIFIED_TIME = 'MEDIA_MODIFIED_TIME'; + +const String MEDIA_TIMELINE = 'MEDIA_TIMELINE'; + +const String MEDIA_THUMBNAIL_PATH = 'MEDIA_THUMBNAIL_PATH'; + +const String MEDIA_TITLE = 'MEDIA_TITLE'; + +const String MEDIA_ALBUM = 'MEDIA_ALBUM'; + +const String MEDIA_ARTIST = 'MEDIA_ARTIST'; + +const String MEDIA_ALBUM_ARTIST = 'MEDIA_ALBUM_ARTIST'; + +const String MEDIA_GENRE = 'MEDIA_GENRE'; + +const String MEDIA_COMPOSER = 'MEDIA_COMPOSER'; + +const String MEDIA_YEAR = 'MEDIA_YEAR'; + +const String MEDIA_RECORDED_DATE = 'MEDIA_RECORDED_DATE'; + +const String MEDIA_COPYRIGHT = 'MEDIA_COPYRIGHT'; + +const String MEDIA_TRACK_NUM = 'MEDIA_TRACK_NUM'; + +const String MEDIA_DESCRIPTION = 'MEDIA_DESCRIPTION'; + +const String MEDIA_BITRATE = 'MEDIA_BITRATE'; + +const String MEDIA_BITPERSAMPLE = 'MEDIA_BITPERSAMPLE'; + +const String MEDIA_SAMPLERATE = 'MEDIA_SAMPLERATE'; + +const String MEDIA_CHANNEL = 'MEDIA_CHANNEL'; + +const String MEDIA_DURATION = 'MEDIA_DURATION'; + +const String MEDIA_LONGITUDE = 'MEDIA_LONGITUDE'; + +const String MEDIA_LATITUDE = 'MEDIA_LATITUDE'; + +const String MEDIA_ALTITUDE = 'MEDIA_ALTITUDE'; + +const String MEDIA_WIDTH = 'MEDIA_WIDTH'; + +const String MEDIA_HEIGHT = 'MEDIA_HEIGHT'; + +const String MEDIA_DATETAKEN = 'MEDIA_DATETAKEN'; + +const String MEDIA_ORIENTATION = 'MEDIA_ORIENTATION'; + +const String MEDIA_BURST_ID = 'BURST_ID'; + +const String MEDIA_PLAYED_COUNT = 'MEDIA_PLAYED_COUNT'; + +const String MEDIA_LAST_PLAYED_TIME = 'MEDIA_LAST_PLAYED_TIME'; + +const String MEDIA_LAST_PLAYED_POSITION = 'MEDIA_LAST_PLAYED_POSITION'; + +const String MEDIA_RATING = 'MEDIA_RATING'; + +const String MEDIA_FAVOURITE = 'MEDIA_FAVOURITE'; + +const String MEDIA_AUTHOR = 'MEDIA_AUTHOR'; + +const String MEDIA_PROVIDER = 'MEDIA_PROVIDER'; + +const String MEDIA_CONTENT_NAME = 'MEDIA_CONTENT_NAME'; + +const String MEDIA_CATEGORY = 'MEDIA_CATEGORY'; + +const String MEDIA_LOCATION_TAG = 'MEDIA_LOCATION_TAG'; + +const String MEDIA_AGE_RATING = 'MEDIA_AGE_RATING'; + +const String MEDIA_KEYWORD = 'MEDIA_KEYWORD'; + +const String MEDIA_WEATHER = 'MEDIA_WEATHER'; + +const String MEDIA_IS_DRM = 'MEDIA_IS_DRM'; + +const String MEDIA_STORAGE_TYPE = 'MEDIA_STORAGE_TYPE'; + +const String MEDIA_EXPOSURE_TIME = 'MEDIA_EXPOSURE_TIME'; + +const String MEDIA_FNUMBER = 'MEDIA_FNUMBER'; + +const String MEDIA_ISO = 'MEDIA_ISO'; + +const String MEDIA_MODEL = 'MEDIA_MODEL'; + +const String MEDIA_FILE_NAME_PINYIN = 'MEDIA_FILE_NAME_PINYIN'; + +const String MEDIA_TITLE_PINYIN = 'MEDIA_TITLE_PINYIN'; + +const String MEDIA_ALBUM_PINYIN = 'MEDIA_ALBUM_PINYIN'; + +const String MEDIA_ARTIST_PINYIN = 'MEDIA_ARTIST_PINYIN'; + +const String MEDIA_ALBUM_ARTIST_PINYIN = 'MEDIA_ALBUM_ARTIST_PINYIN'; + +const String MEDIA_GENRE_PINYIN = 'MEDIA_GENRE_PINYIN'; + +const String MEDIA_COMPOSER_PINYIN = 'MEDIA_COMPOSER_PINYIN'; + +const String MEDIA_COPYRIGHT_PINYIN = 'MEDIA_COPYRIGHT_PINYIN'; + +const String MEDIA_DESCRIPTION_PINYIN = 'MEDIA_DESCRIPTION_PINYIN'; + +const String MEDIA_AUTHOR_PINYIN = 'MEDIA_AUTHOR_PINYIN'; + +const String MEDIA_PROVIDER_PINYIN = 'MEDIA_PROVIDER_PINYIN'; + +const String MEDIA_CONTENT_NAME_PINYIN = 'MEDIA_CONTENT_NAME_PINYIN'; + +const String MEDIA_CATEGORY_PINYIN = 'MEDIA_CATEGORY_PINYIN'; + +const String MEDIA_LOCATION_TAG_PINYIN = 'MEDIA_LOCATION_TAG_PINYIN'; + +const String MEDIA_AGE_RATING_PINYIN = 'MEDIA_AGE_RATING_PINYIN'; + +const String MEDIA_KEYWORD_PINYIN = 'MEDIA_KEYWORD_PINYIN'; + +const String MEDIA_360 = 'MEDIA_360'; + +const String FOLDER_ID = 'FOLDER_ID'; + +const String FOLDER_PATH = 'FOLDER_PATH'; + +const String FOLDER_NAME = 'FOLDER_NAME'; + +const String FOLDER_MODIFIED_TIME = 'FOLDER_MODIFIED_TIME'; + +const String FOLDER_STORAGE_TYPE = 'FOLDER_STORAGE_TYPE'; + +const String FOLDER_NAME_PINYIN = 'FOLDER_NAME_PINYIN'; + +const String FOLDER_ORDER = 'FOLDER_ORDER'; + +const String FOLDER_PARENT_FOLDER_ID = 'FOLDER_PARENT_FOLDER_ID'; + +const String PLAYLIST_NAME = 'PLAYLIST_NAME'; + +const String MEDIA_PLAYLIST_ID = 'PLAYLIST_ID'; + +const String PLAYLIST_MEMBER_ORDER = 'PLAYLIST_MEMBER_ORDER'; + +const String PLAYLIST_MEDIA_COUNT = 'PLAYLIST_MEDIA_COUNT'; + +const String TAG_NAME = 'TAG_NAME'; + +const String MEDIA_TAG_ID = 'TAG_ID'; + +const String TAG_MEDIA_COUNT = 'TAG_MEDIA_COUNT'; + +const String BOOKMARK_MARKED_TIME = 'BOOKMARK_MARKED_TIME'; + +const String MEDIA_BOOKMARK_ID = 'BOOKMARK_ID'; + +const String BOOKMARK_NAME = 'BOOKMARK_NAME'; + +const String MEDIA_STORAGE_ID = 'STORAGE_ID'; + +const String MEDIA_STORAGE_PATH = 'STORAGE_PATH'; + +const String MEDIA_FACE_TAG = 'MEDIA_FACE_TAG'; + +const String MEDIA_FACE_ID = 'MEDIA_FACE_ID'; + +const int LOCATION_BOUNDS_ERROR_CLASS = -46137312; + +const String MAPS_PLACE_FILTER_TYPE = 'MAPS_PLACE_FILTER_TYPE'; + +const String MAPS_PLACE_FILTER_SORT_BY = 'MAPS_PLACE_FILTER_SORT_BY'; + +const String MAPS_ROUTE_FREEFORM_ADDR_TO_AVOID = + 'MAPS_ROUTE_FREEFORM_ADDR_TO_AVOID'; + +const String MAPS_ROUTE_STRUCTED_ADDR_TO_AVOID = + 'MAPS_ROUTE_STRUCTED_ADDR_TO_AVOID'; + +const String MAPS_ROUTE_CIRCLE_AREA_TO_AVOID = + 'MAPS_ROUTE_CIRCLE_AREA_TO_AVOID'; + +const String MAPS_ROUTE_RECT_AREA_TO_AVOID = 'MAPS_ROUTE_RECT_AREA_TO_AVOID'; + +const String MAPS_ROUTE_GEOMETRY_BOUNDING_BOX = + 'MAPS_ROUTE_GEOMETRY_BOUNDING_BOX'; + +const String MAPS_ROUTE_GEOMETRY_RETRIEVAL = 'MAPS_ROUTE_GEOMETRY_RETRIEVAL'; + +const String MAPS_ROUTE_INSTRUCTION_GEOMETRY = + 'MAPS_ROUTE_INSTRUCTION_GEOMETRY'; + +const String MAPS_ROUTE_INSTRUCTION_BOUNDING_BOX = + 'MAPS_ROUTE_INSTRUCTION_BOUNDING_BOX'; + +const String MAPS_ROUTE_INSTRUCTION_RETRIEVAL = + 'MAPS_ROUTE_INSTRUCTION_RETRIEVAL'; + +const String MAPS_ROUTE_REALTIME_TRAFFIC = 'MAPS_ROUTE_REALTIME_TRAFFIC'; + +const String APP_CONTROL_DATA_PUSH_LAUNCH_TYPE = + 'http://tizen.org/appcontrol/data/push/launch_type'; + +const int CAMERA_ERROR_CLASS = -26279936; + +const int IMAGE_UTIL_ERROR_CLASS = -26345472; + +const String MEDIA_STREAMER_PARAM_CAMERA_ID = 'camera-id'; + +const String MEDIA_STREAMER_PARAM_CAPTURE_WIDTH = 'capture-width'; + +const String MEDIA_STREAMER_PARAM_CAPTURE_HEIGHT = 'capture-height'; + +const String MEDIA_STREAMER_PARAM_IS_LIVE_STREAM = 'is-live'; + +const String MEDIA_STREAMER_PARAM_URI = 'uri'; + +const String MEDIA_STREAMER_PARAM_USER_AGENT = 'user-agent'; + +const String MEDIA_STREAMER_PARAM_STREAM_TYPE = 'stream-type'; + +const String MEDIA_STREAMER_PARAM_PORT = 'port'; + +const String MEDIA_STREAMER_PARAM_VIDEO_IN_PORT = 'video_in_port'; + +const String MEDIA_STREAMER_PARAM_AUDIO_IN_PORT = 'audio_in_port'; + +const String MEDIA_STREAMER_PARAM_VIDEO_OUT_PORT = 'video_out_port'; + +const String MEDIA_STREAMER_PARAM_AUDIO_OUT_PORT = 'audio_out_port'; + +const String MEDIA_STREAMER_PARAM_IP_ADDRESS = 'address'; + +const String MEDIA_STREAMER_PARAM_AUDIO_DEVICE = 'audio_device'; + +const String MEDIA_STREAMER_PARAM_CLOCK_SYNCHRONIZED = 'sync'; + +const String MEDIA_STREAMER_PARAM_ROTATE = 'rotate'; + +const String MEDIA_STREAMER_PARAM_FLIP = 'flip'; + +const String MEDIA_STREAMER_PARAM_DISPLAY_GEOMETRY_METHOD = + 'display-geometry-method'; + +const String MEDIA_STREAMER_PARAM_DISPLAY = 'display'; + +const String MEDIA_STREAMER_PARAM_VISIBLE = 'visible'; + +const String MEDIA_STREAMER_PARAM_HOST = 'host'; + +const String MEDIA_STREAMER_PARAM_SEGMENT_LOCATION = 'location'; + +const String MEDIA_STREAMER_PARAM_PLAYLIST_LOCATION = 'playlist-location'; + +const String MV_BARCODE_DETECT_ATTR_TARGET = 'MV_BARCODE_DETECT_ATTR_TARGET'; + +const String MV_BARCODE_GENERATE_ATTR_TEXT = 'MV_BARCODE_GENERATE_ATTR_TEXT'; + +const String MV_BARCODE_GENERATE_ATTR_COLOR_FRONT = + 'MV_BARCODE_GENERATE_ATTR_COLOR_FRONT'; + +const String MV_BARCODE_GENERATE_ATTR_COLOR_BACK = + 'MV_BARCODE_GENERATE_ATTR_COLOR_BACK'; + +const String MV_FACE_DETECTION_MODEL_FILE_PATH = + 'MV_FACE_DETECTION_MODEL_FILE_PATH'; + +const String MV_FACE_RECOGNITION_MODEL_TYPE = 'MV_FACE_RECOGNITION_MODEL_TYPE'; + +const String MV_FACE_DETECTION_ROI_X = 'MV_FACE_DETECTION_ROI_X'; + +const String MV_FACE_DETECTION_ROI_Y = 'MV_FACE_DETECTION_ROI_Y'; + +const String MV_FACE_DETECTION_ROI_WIDTH = 'MV_FACE_DETECTION_ROI_WIDTH'; + +const String MV_FACE_DETECTION_ROI_HEIGHT = 'MV_FACE_DETECTION_ROI_HEIGHT'; + +const String MV_FACE_DETECTION_MIN_SIZE_WIDTH = + 'MV_FACE_DETECTION_MIN_SIZE_WIDTH'; + +const String MV_FACE_DETECTION_MIN_SIZE_HEIGHT = + 'MV_FACE_DETECTION_MIN_SIZE_HEIGHT'; + +const String MV_IMAGE_RECOGNITION_OBJECT_SCALE_FACTOR = + 'MV_IMAGE_RECOGNITION_OBJECT_SCALE_FACTOR'; + +const String MV_IMAGE_RECOGNITION_OBJECT_MAX_KEYPOINTS_NUM = + 'MV_IMAGE_RECOGNITION_OBJECT_MAX_KEYPOINTS_NUM'; + +const String MV_IMAGE_RECOGNITION_SCENE_SCALE_FACTOR = + 'MV_IMAGE_RECOGNITION_SCENE_SCALE_FACTOR'; + +const String MV_IMAGE_RECOGNITION_SCENE_MAX_KEYPOINTS_NUM = + 'MV_IMAGE_RECOGNITION_SCENE_MAX_KEYPOINTS_NUM'; + +const String MV_IMAGE_RECOGNITION_MIN_MATCH_NUM = + 'MV_IMAGE_RECOGNITION_MIN_MATCH_NUM'; + +const String MV_IMAGE_RECOGNITION_REQ_MATCH_PART = + 'MV_IMAGE_RECOGNITION_REQ_MATCH_PART'; + +const String MV_IMAGE_RECOGNITION_TOLERANT_MATCH_PART_ERR = + 'MV_IMAGE_RECOGNITION_TOLERANT_MATCH_PART_ERR'; + +const String MV_IMAGE_TRACKING_HISTORY_AMOUNT = + 'MV_IMAGE_TRACKING_HISTORY_AMOUNT'; + +const String MV_IMAGE_TRACKING_EXPECTED_OFFSET = + 'MV_IMAGE_TRACKING_EXPECTED_OFFSET'; + +const String MV_IMAGE_TRACKING_USE_STABLIZATION = + 'MV_IMAGE_TRACKING_USE_STABLIZATION'; + +const String MV_IMAGE_TRACKING_STABLIZATION_TOLERANT_SHIFT = + 'MV_IMAGE_TRACKING_STABLIZATION_TOLERANT_SHIFT'; + +const String MV_IMAGE_TRACKING_STABLIZATION_SPEED = + 'MV_IMAGE_TRACKING_STABLIZATION_SPEED'; + +const String MV_IMAGE_TRACKING_STABLIZATION_ACCELERATION = + 'MV_IMAGE_TRACKING_STABLIZATION_ACCELERATION'; + +const String MV_SURVEILLANCE_EVENT_TYPE_MOVEMENT_DETECTED = + 'MV_SURVEILLANCE_EVENT_MOVEMENT_DETECTED'; + +const String MV_SURVEILLANCE_MOVEMENT_NUMBER_OF_REGIONS = + 'NUMBER_OF_MOVEMENT_REGIONS'; + +const String MV_SURVEILLANCE_MOVEMENT_REGIONS = 'MOVEMENT_REGIONS'; + +const String MV_SURVEILLANCE_EVENT_TYPE_PERSON_APPEARED_DISAPPEARED = + 'MV_SURVEILLANCE_EVENT_PERSON_APPEARED_DISAPEARED'; + +const String MV_SURVEILLANCE_PERSONS_APPEARED_NUMBER = + 'NUMBER_OF_APPEARED_PERSONS'; + +const String MV_SURVEILLANCE_PERSONS_DISAPPEARED_NUMBER = + 'NUMBER_OF_DISAPPEARED_PERSONS'; + +const String MV_SURVEILLANCE_PERSONS_TRACKED_NUMBER = + 'NUMBER_OF_TRACKED_PERSONS'; + +const String MV_SURVEILLANCE_PERSONS_APPEARED_LOCATIONS = + 'APPEARED_PERSONS_LOCATIONS'; + +const String MV_SURVEILLANCE_PERSONS_DISAPPEARED_LOCATIONS = + 'DISAPPEARED_PERSONS_LOCATIONS'; + +const String MV_SURVEILLANCE_PERSONS_TRACKED_LOCATIONS = + 'TRACKED_PERSONS_LOCATIONS'; + +const String MV_SURVEILLANCE_EVENT_TYPE_PERSON_RECOGNIZED = + 'MV_SURVEILLANCE_EVENT_PERSON_RECOGNIZED'; + +const String MV_SURVEILLANCE_PERSONS_RECOGNIZED_NUMBER = 'NUMBER_OF_PERSONS'; + +const String MV_SURVEILLANCE_PERSONS_RECOGNIZED_LOCATIONS = 'PERSONS_LOCATIONS'; + +const String MV_SURVEILLANCE_PERSONS_RECOGNIZED_LABELS = 'PERSONS_LABELS'; + +const String MV_SURVEILLANCE_PERSONS_RECOGNIZED_CONFIDENCES = + 'PERSONS_CONFIDENCES'; + +const String MV_SURVEILLANCE_FACE_RECOGNITION_MODEL_FILE_PATH = + 'MV_SURVEILLANCE_FACE_RECOGNITION_MODEL_FILE_PATH'; + +const String MV_SURVEILLANCE_MOVEMENT_DETECTION_THRESHOLD = + 'MV_SURVEILLANCE_MOVEMENT_DETECTION_THRESHOLD'; + +const String MV_SURVEILLANCE_SKIP_FRAMES_COUNT = + 'MV_SURVEILLANCE_SKIP_FRAMES_COUNT'; + +const int METADATA_EDITOR_ERROR_CLASS = -27000832; + +const int METADATA_EXTRACTOR_ERROR_CLASS = -26411008; + +const int PLAYER_ERROR_CLASS = -26476512; + +const int PLAYER_CUSTOM_ERROR_CLASS = -26472448; + +const int RECORDER_ERROR_CLASS = -26542064; + +const int THUMBNAIL_UTIL_ERROR_CLASS = -49872896; + +const int TONE_PLAYER_ERROR_CLASS = -8096; + +const int WAV_PLAYER_ERROR_CLASS = -8112; + +const int IOTCON_MULTICAST_ADDRESS = 0; + +const int IOTCON_FUNC_STOP = 0; + +const int IOTCON_FUNC_CONTINUE = 1; + +const String IOTCON_INTERFACE_DEFAULT = 'oic.if.baseline'; + +const String IOTCON_INTERFACE_LINK = 'oic.if.ll'; + +const String IOTCON_INTERFACE_BATCH = 'oic.if.b'; + +const String IOTCON_INTERFACE_GROUP = 'oic.mi.grp'; + +const String IOTCON_INTERFACE_READONLY = 'oic.if.r'; + +const int NFC_ERROR_CLASS = -29491200; + +const int SMARTCARD_ERROR_CLASS = -29818880; + +const int YACA_KEYLEN_COMPONENT_TYPE_MASK = -268435456; + +const int YACA_KEYLEN_COMPONENT_TYPE_BITS = 0; + +const int YACA_KEYLEN_COMPONENT_TYPE_DH = 268435456; + +const int YACA_KEYLEN_COMPONENT_TYPE_DH_RFC = 536870912; + +const int YACA_KEYLEN_COMPONENT_TYPE_EC = 805306368; + +const int YACA_KEYLEN_COMPONENT_DH_GEN_MASK = 251658240; + +const int YACA_KEYLEN_COMPONENT_DH_GEN_2 = 0; + +const int YACA_KEYLEN_COMPONENT_DH_GEN_5 = 16777216; + +const int YACA_KEYLEN_COMPONENT_DH_PRIME_MASK = 65535; + +const int YACA_KEYLEN_COMPONENT_DH_RFC_MASK = 251658240; + +const int YACA_KEYLEN_COMPONENT_DH_RFC_160 = 0; + +const int YACA_KEYLEN_COMPONENT_DH_RFC_224 = 16777216; + +const int YACA_KEYLEN_COMPONENT_DH_RFC_256 = 33554432; + +const int YACA_KEYLEN_COMPONENT_EC_PRIME = 0; + +const int YACA_KEYLEN_COMPONENT_EC_SECP = 16777216; + +const int YACA_KEYLEN_COMPONENT_EC_SECT = 33554432; + +const int YACA_KEYLEN_COMPONENT_EC_BRAINPOOL = 50331648; + +const int YACA_KEYLEN_COMPONENT_EC_V = 0; + +const int YACA_KEYLEN_COMPONENT_EC_R = 1048576; + +const int YACA_KEYLEN_COMPONENT_EC_K = 2097152; + +const int YACA_KEYLEN_COMPONENT_EC_T = 3145728; + +const int YACA_KEYLEN_COMPONENT_EC_1 = 0; + +const int YACA_KEYLEN_COMPONENT_EC_2 = 65536; + +const int YACA_KEYLEN_COMPONENT_EC_3 = 131072; + +const int YACA_KEYLEN_COMPONENT_EC_4 = 196608; + +const int YACA_KEY_LENGTH_DH_GENERATOR_2 = 268435456; + +const int YACA_KEY_LENGTH_DH_GENERATOR_5 = 285212672; + +const int TIZEN_ERROR_YACA = -31653888; + +const int CALENDAR_CONNECT_FLAG_NONE = 0; + +const int CALENDAR_CONNECT_FLAG_RETRY = 1; + +const int DEFAULT_EVENT_CALENDAR_BOOK_ID = 1; + +const int DEFAULT_TODO_CALENDAR_BOOK_ID = 2; + +const int DEFAULT_BIRTHDAY_CALENDAR_BOOK_ID = 3; + +const int CALENDAR_TODO_NO_DUE_DATE = 9223372036854775807; + +const int CALENDAR_TODO_NO_START_DATE = -9223372036854775807; + +const int CALENDAR_RECORD_NO_UNTIL = 9223372036854775807; + +const double CALENDAR_RECORD_NO_COORDINATE = 1000.0; + +const int CALENDAR_BOOK_FILTER_ALL = -1; + +const int CONTACTS_CONNECT_FLAG_RETRY = 1; + +const int CONTACTS_CONNECT_FLAG_NONE = 0; + +const int LOG_TAG = 0; + +const int MAX_VALUE_SIZE = 16; + +const int IME_ATTR_FONTSTYLE_UNDERLINE = 1; + +const int IME_ATTR_FONTSTYLE_HIGHLIGHT = 2; + +const int IME_ATTR_FONTSTYLE_REVERSAL = 4; + +const String STT_RECOGNITION_TYPE_FREE = 'stt.recognition.type.FREE'; + +const String STT_RECOGNITION_TYPE_FREE_PARTIAL = + 'stt.recognition.type.FREE.PARTIAL'; + +const String STT_RECOGNITION_TYPE_SEARCH = 'stt.recognition.type.SEARCH'; + +const String STT_RECOGNITION_TYPE_WEB_SEARCH = + 'stt.recognition.type.WEB_SEARCH'; + +const String STT_RECOGNITION_TYPE_MAP = 'stt.recognition.type.MAP'; + +const String STT_RESULT_MESSAGE_NONE = 'stt.result.message.none'; + +const String STT_RESULT_MESSAGE_ERROR_TOO_SOON = + 'stt.result.message.error.too.soon'; + +const String STT_RESULT_MESSAGE_ERROR_TOO_SHORT = + 'stt.result.message.error.too.short'; + +const String STT_RESULT_MESSAGE_ERROR_TOO_LONG = + 'stt.result.message.error.too.long'; + +const String STT_RESULT_MESSAGE_ERROR_TOO_QUIET = + 'stt.result.message.error.too.quiet'; + +const String STT_RESULT_MESSAGE_ERROR_TOO_LOUD = + 'stt.result.message.error.too.loud'; + +const String STT_RESULT_MESSAGE_ERROR_TOO_FAST = + 'stt.result.message.error.too.fast'; + +const String STTE_RECOGNITION_TYPE_FREE = 'stt.recognition.type.FREE'; + +const String STTE_RECOGNITION_TYPE_FREE_PARTIAL = + 'stt.recognition.type.FREE.PARTIAL'; + +const String STTE_RESULT_MESSAGE_NONE = 'stt.result.message.none'; + +const String STTE_RESULT_MESSAGE_ERROR_TOO_SOON = + 'stt.result.message.error.too.soon'; + +const String STTE_RESULT_MESSAGE_ERROR_TOO_SHORT = + 'stt.result.message.error.too.short'; + +const String STTE_RESULT_MESSAGE_ERROR_TOO_LONG = + 'stt.result.message.error.too.long'; + +const String STTE_RESULT_MESSAGE_ERROR_TOO_QUIET = + 'stt.result.message.error.too.quiet'; + +const String STTE_RESULT_MESSAGE_ERROR_TOO_LOUD = + 'stt.result.message.error.too.loud'; + +const String STTE_RESULT_MESSAGE_ERROR_TOO_FAST = + 'stt.result.message.error.too.fast'; + +const int TTS_SPEED_AUTO = 0; + +const int TTS_VOICE_TYPE_AUTO = 0; + +const int TTS_VOICE_TYPE_MALE = 1; + +const int TTS_VOICE_TYPE_FEMALE = 2; + +const int TTS_VOICE_TYPE_CHILD = 3; + +const int TTSE_VOICE_TYPE_MALE = 1; + +const int TTSE_VOICE_TYPE_FEMALE = 2; + +const int TTSE_VOICE_TYPE_CHILD = 3; + +const int VC_COMMAND_FORMAT_FIXED = 0; + +const int VC_COMMAND_FORMAT_FIXED_AND_VFIXED = 1; + +const int VC_COMMAND_FORMAT_VFIXED_AND_FIXED = 2; + +const int VC_COMMAND_FORMAT_FIXED_AND_NONFIXED = 3; + +const int VC_COMMAND_FORMAT_NONFIXED_AND_FIXED = 4; + +const int VC_COMMAND_TYPE_FOREGROUND = 1; + +const int VC_COMMAND_TYPE_BACKGROUND = 2; + +const int VC_DIALOG_END = 0; + +const int VC_DIALOG_CONTINUE = 1; + +typedef _c_get_last_result = ffi.Int32 Function(); + +typedef _dart_get_last_result = int Function(); + +typedef _c_set_last_result = ffi.Void Function( + ffi.Int32 err, +); + +typedef _dart_set_last_result = void Function( + int err, +); + +typedef _c_get_error_message = ffi.Pointer Function( + ffi.Int32 err, +); + +typedef _dart_get_error_message = ffi.Pointer Function( + int err, +); + +typedef _c_account_connect = ffi.Int32 Function(); + +typedef _dart_account_connect = int Function(); + +typedef _c_account_connect_readonly = ffi.Int32 Function(); + +typedef _dart_account_connect_readonly = int Function(); + +typedef _c_account_disconnect = ffi.Int32 Function(); + +typedef _dart_account_disconnect = int Function(); + +typedef _c_account_create = ffi.Int32 Function( + ffi.Pointer> account, +); + +typedef _dart_account_create = int Function( + ffi.Pointer> account, +); + +typedef _c_account_destroy = ffi.Int32 Function( + ffi.Pointer account, +); + +typedef _dart_account_destroy = int Function( + ffi.Pointer account, +); + +typedef _c_account_insert_to_db = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer account_db_id, +); + +typedef _dart_account_insert_to_db = int Function( + ffi.Pointer account, + ffi.Pointer account_db_id, +); + +typedef _c_account_delete_from_db_by_id = ffi.Int32 Function( + ffi.Int32 account_db_id, +); + +typedef _dart_account_delete_from_db_by_id = int Function( + int account_db_id, +); + +typedef _c_account_delete_from_db_by_user_name = ffi.Int32 Function( + ffi.Pointer user_name, + ffi.Pointer package_name, +); + +typedef _dart_account_delete_from_db_by_user_name = int Function( + ffi.Pointer user_name, + ffi.Pointer package_name, +); + +typedef _c_account_delete_from_db_by_package_name = ffi.Int32 Function( + ffi.Pointer package_name, +); + +typedef _dart_account_delete_from_db_by_package_name = int Function( + ffi.Pointer package_name, +); + +typedef _c_account_update_to_db_by_id = ffi.Int32 Function( + ffi.Pointer account, + ffi.Int32 account_id, +); + +typedef _dart_account_update_to_db_by_id = int Function( + ffi.Pointer account, + int account_id, +); + +typedef _c_account_update_to_db_by_id_ex = ffi.Int32 Function( + ffi.Pointer account, + ffi.Int32 account_id, +); + +typedef _dart_account_update_to_db_by_id_ex = int Function( + ffi.Pointer account, + int account_id, +); + +typedef _c_account_update_to_db_by_user_name = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer user_name, + ffi.Pointer package_name, +); + +typedef _dart_account_update_to_db_by_user_name = int Function( + ffi.Pointer account, + ffi.Pointer user_name, + ffi.Pointer package_name, +); + +typedef _c_account_get_account_id = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer account_id, +); + +typedef _dart_account_get_account_id = int Function( + ffi.Pointer account, + ffi.Pointer account_id, +); + +typedef _c_account_get_user_name = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer> user_name, +); + +typedef _dart_account_get_user_name = int Function( + ffi.Pointer account, + ffi.Pointer> user_name, +); + +typedef _c_account_set_user_name = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer user_name, +); + +typedef _dart_account_set_user_name = int Function( + ffi.Pointer account, + ffi.Pointer user_name, +); + +typedef _c_account_get_display_name = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer> display_name, +); + +typedef _dart_account_get_display_name = int Function( + ffi.Pointer account, + ffi.Pointer> display_name, +); + +typedef _c_account_set_display_name = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer display_name, +); + +typedef _dart_account_set_display_name = int Function( + ffi.Pointer account, + ffi.Pointer display_name, +); + +typedef _c_account_get_capability = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer capability_type, + ffi.Pointer capability_value, +); + +typedef _dart_account_get_capability = int Function( + ffi.Pointer account, + ffi.Pointer capability_type, + ffi.Pointer capability_value, +); + +typedef capability_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_account_get_capability_all = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_account_get_capability_all = int Function( + ffi.Pointer account, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_account_set_capability = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer capability_type, + ffi.Int32 capability_state, +); + +typedef _dart_account_set_capability = int Function( + ffi.Pointer account, + ffi.Pointer capability_type, + int capability_state, +); + +typedef _c_account_get_icon_path = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer> icon_path, +); + +typedef _dart_account_get_icon_path = int Function( + ffi.Pointer account, + ffi.Pointer> icon_path, +); + +typedef _c_account_set_icon_path = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer icon_path, +); + +typedef _dart_account_set_icon_path = int Function( + ffi.Pointer account, + ffi.Pointer icon_path, +); + +typedef _c_account_get_domain_name = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer> domain_name, +); + +typedef _dart_account_get_domain_name = int Function( + ffi.Pointer account, + ffi.Pointer> domain_name, +); + +typedef _c_account_set_domain_name = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer domain_name, +); + +typedef _dart_account_set_domain_name = int Function( + ffi.Pointer account, + ffi.Pointer domain_name, +); + +typedef _c_account_get_email_address = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer> email_address, +); + +typedef _dart_account_get_email_address = int Function( + ffi.Pointer account, + ffi.Pointer> email_address, +); + +typedef _c_account_set_email_address = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer email_address, +); + +typedef _dart_account_set_email_address = int Function( + ffi.Pointer account, + ffi.Pointer email_address, +); + +typedef _c_account_get_package_name = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer> package_name, +); + +typedef _dart_account_get_package_name = int Function( + ffi.Pointer account, + ffi.Pointer> package_name, +); + +typedef _c_account_set_package_name = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer package_name, +); + +typedef _dart_account_set_package_name = int Function( + ffi.Pointer account, + ffi.Pointer package_name, +); + +typedef _c_account_get_access_token = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer> access_token, +); + +typedef _dart_account_get_access_token = int Function( + ffi.Pointer account, + ffi.Pointer> access_token, +); + +typedef _c_account_set_access_token = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer access_token, +); + +typedef _dart_account_set_access_token = int Function( + ffi.Pointer account, + ffi.Pointer access_token, +); + +typedef _c_account_get_user_text = ffi.Int32 Function( + ffi.Pointer account, + ffi.Int32 user_text_index, + ffi.Pointer> user_text, +); + +typedef _dart_account_get_user_text = int Function( + ffi.Pointer account, + int user_text_index, + ffi.Pointer> user_text, +); + +typedef _c_account_set_user_text = ffi.Int32 Function( + ffi.Pointer account, + ffi.Int32 user_text_index, + ffi.Pointer user_text, +); + +typedef _dart_account_set_user_text = int Function( + ffi.Pointer account, + int user_text_index, + ffi.Pointer user_text, +); + +typedef _c_account_get_user_int = ffi.Int32 Function( + ffi.Pointer account, + ffi.Int32 user_int_index, + ffi.Pointer user_integer, +); + +typedef _dart_account_get_user_int = int Function( + ffi.Pointer account, + int user_int_index, + ffi.Pointer user_integer, +); + +typedef _c_account_set_user_int = ffi.Int32 Function( + ffi.Pointer account, + ffi.Int32 user_int_index, + ffi.Int32 user_integer, +); + +typedef _dart_account_set_user_int = int Function( + ffi.Pointer account, + int user_int_index, + int user_integer, +); + +typedef _c_account_get_auth_type = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer auth_type, +); + +typedef _dart_account_get_auth_type = int Function( + ffi.Pointer account, + ffi.Pointer auth_type, +); + +typedef _c_account_set_auth_type = ffi.Int32 Function( + ffi.Pointer account, + ffi.Int32 auth_type, +); + +typedef _dart_account_set_auth_type = int Function( + ffi.Pointer account, + int auth_type, +); + +typedef _c_account_get_secret = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer secret, +); + +typedef _dart_account_get_secret = int Function( + ffi.Pointer account, + ffi.Pointer secret, +); + +typedef _c_account_set_secret = ffi.Int32 Function( + ffi.Pointer account, + ffi.Int32 secret, +); + +typedef _dart_account_set_secret = int Function( + ffi.Pointer account, + int secret, +); + +typedef _c_account_get_sync_support = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer sync_support, +); + +typedef _dart_account_get_sync_support = int Function( + ffi.Pointer account, + ffi.Pointer sync_support, +); + +typedef _c_account_set_sync_support = ffi.Int32 Function( + ffi.Pointer account, + ffi.Int32 sync_support, +); + +typedef _dart_account_set_sync_support = int Function( + ffi.Pointer account, + int sync_support, +); + +typedef _c_account_get_source = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer> source, +); + +typedef _dart_account_get_source = int Function( + ffi.Pointer account, + ffi.Pointer> source, +); + +typedef _c_account_set_source = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer source, +); + +typedef _dart_account_set_source = int Function( + ffi.Pointer account, + ffi.Pointer source, +); + +typedef _c_account_set_custom = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_account_set_custom = int Function( + ffi.Pointer account, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_account_get_custom = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer key, + ffi.Pointer> value, +); + +typedef _dart_account_get_custom = int Function( + ffi.Pointer account, + ffi.Pointer key, + ffi.Pointer> value, +); + +typedef account_custom_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_account_get_custom_all = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_account_get_custom_all = int Function( + ffi.Pointer account, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef account_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_account_foreach_account_from_db = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_account_foreach_account_from_db = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_account_query_account_by_account_id = ffi.Int32 Function( + ffi.Int32 account_db_id, + ffi.Pointer> account, +); + +typedef _dart_account_query_account_by_account_id = int Function( + int account_db_id, + ffi.Pointer> account, +); + +typedef _c_account_query_account_by_user_name = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_name, + ffi.Pointer user_data, +); + +typedef _dart_account_query_account_by_user_name = int Function( + ffi.Pointer> callback, + ffi.Pointer user_name, + ffi.Pointer user_data, +); + +typedef _c_account_query_account_by_package_name = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer package_name, + ffi.Pointer user_data, +); + +typedef _dart_account_query_account_by_package_name = int Function( + ffi.Pointer> callback, + ffi.Pointer package_name, + ffi.Pointer user_data, +); + +typedef _c_account_query_account_by_capability = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer capability_type, + ffi.Int32 capability_value, + ffi.Pointer user_data, +); + +typedef _dart_account_query_account_by_capability = int Function( + ffi.Pointer> callback, + ffi.Pointer capability_type, + int capability_value, + ffi.Pointer user_data, +); + +typedef _c_account_query_account_by_capability_type = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer capability_type, + ffi.Pointer user_data, +); + +typedef _dart_account_query_account_by_capability_type = int Function( + ffi.Pointer> callback, + ffi.Pointer capability_type, + ffi.Pointer user_data, +); + +typedef _c_account_query_capability_by_account_id = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Int32 account_db_id, + ffi.Pointer user_data, +); + +typedef _dart_account_query_capability_by_account_id = int Function( + ffi.Pointer> callback, + int account_db_id, + ffi.Pointer user_data, +); + +typedef _c_account_get_total_count_from_db = ffi.Int32 Function( + ffi.Pointer count, +); + +typedef _dart_account_get_total_count_from_db = int Function( + ffi.Pointer count, +); + +typedef _c_account_update_sync_status_by_id = ffi.Int32 Function( + ffi.Int32 account_db_id, + ffi.Int32 sync_status, +); + +typedef _dart_account_update_sync_status_by_id = int Function( + int account_db_id, + int sync_status, +); + +typedef _c_account_type_create = ffi.Int32 Function( + ffi.Pointer> account_type, +); + +typedef _dart_account_type_create = int Function( + ffi.Pointer> account_type, +); + +typedef _c_account_type_destroy = ffi.Int32 Function( + ffi.Pointer account_type, +); + +typedef _dart_account_type_destroy = int Function( + ffi.Pointer account_type, +); + +typedef provider_feature_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_account_type_query_provider_feature_by_app_id = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer app_id, + ffi.Pointer user_data, +); + +typedef _dart_account_type_query_provider_feature_by_app_id = int Function( + ffi.Pointer> callback, + ffi.Pointer app_id, + ffi.Pointer user_data, +); + +typedef _c_account_type_query_supported_feature = ffi.Uint8 Function( + ffi.Pointer app_id, + ffi.Pointer capability, +); + +typedef _dart_account_type_query_supported_feature = int Function( + ffi.Pointer app_id, + ffi.Pointer capability, +); + +typedef _c_account_type_get_app_id = ffi.Int32 Function( + ffi.Pointer account_type, + ffi.Pointer> app_id, +); + +typedef _dart_account_type_get_app_id = int Function( + ffi.Pointer account_type, + ffi.Pointer> app_id, +); + +typedef _c_account_type_get_service_provider_id = ffi.Int32 Function( + ffi.Pointer account_type, + ffi.Pointer> service_provider_id, +); + +typedef _dart_account_type_get_service_provider_id = int Function( + ffi.Pointer account_type, + ffi.Pointer> service_provider_id, +); + +typedef _c_account_type_get_icon_path = ffi.Int32 Function( + ffi.Pointer account_type, + ffi.Pointer> icon_path, +); + +typedef _dart_account_type_get_icon_path = int Function( + ffi.Pointer account_type, + ffi.Pointer> icon_path, +); + +typedef _c_account_type_get_small_icon_path = ffi.Int32 Function( + ffi.Pointer account_type, + ffi.Pointer> small_icon_path, +); + +typedef _dart_account_type_get_small_icon_path = int Function( + ffi.Pointer account_type, + ffi.Pointer> small_icon_path, +); + +typedef _c_account_type_get_multiple_account_support = ffi.Int32 Function( + ffi.Pointer account_type, + ffi.Pointer multiple_account_support, +); + +typedef _dart_account_type_get_multiple_account_support = int Function( + ffi.Pointer account_type, + ffi.Pointer multiple_account_support, +); + +typedef _c_account_type_get_provider_feature_all = ffi.Int32 Function( + ffi.Pointer account_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_account_type_get_provider_feature_all = int Function( + ffi.Pointer account_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_account_type_get_label_by_locale = ffi.Int32 Function( + ffi.Pointer account_type, + ffi.Pointer locale, + ffi.Pointer> label, +); + +typedef _dart_account_type_get_label_by_locale = int Function( + ffi.Pointer account_type, + ffi.Pointer locale, + ffi.Pointer> label, +); + +typedef account_label_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_account_type_get_label = ffi.Int32 Function( + ffi.Pointer account_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_account_type_get_label = int Function( + ffi.Pointer account_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_account_type_query_label_by_app_id = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer app_id, + ffi.Pointer user_data, +); + +typedef _dart_account_type_query_label_by_app_id = int Function( + ffi.Pointer> callback, + ffi.Pointer app_id, + ffi.Pointer user_data, +); + +typedef _c_account_type_query_by_app_id = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer> account_type, +); + +typedef _dart_account_type_query_by_app_id = int Function( + ffi.Pointer app_id, + ffi.Pointer> account_type, +); + +typedef account_type_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_account_type_foreach_account_type_from_db = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_account_type_foreach_account_type_from_db = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_account_type_query_label_by_locale = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer locale, + ffi.Pointer> label, +); + +typedef _dart_account_type_query_label_by_locale = int Function( + ffi.Pointer app_id, + ffi.Pointer locale, + ffi.Pointer> label, +); + +typedef _c_account_type_query_by_provider_feature = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer key, + ffi.Pointer user_data, +); + +typedef _dart_account_type_query_by_provider_feature = int Function( + ffi.Pointer> callback, + ffi.Pointer key, + ffi.Pointer user_data, +); + +typedef _c_account_type_query_app_id_exist = ffi.Int32 Function( + ffi.Pointer app_id, +); + +typedef _dart_account_type_query_app_id_exist = int Function( + ffi.Pointer app_id, +); + +typedef _c_account_subscribe_create = ffi.Int32 Function( + ffi.Pointer> account_subscribe, +); + +typedef _dart_account_subscribe_create = int Function( + ffi.Pointer> account_subscribe, +); + +typedef account_event_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_account_subscribe_notification = ffi.Int32 Function( + ffi.Pointer account_subscribe, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_account_subscribe_notification = int Function( + ffi.Pointer account_subscribe, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_account_unsubscribe_notification = ffi.Int32 Function( + ffi.Pointer account_subscribe, +); + +typedef _dart_account_unsubscribe_notification = int Function( + ffi.Pointer account_subscribe, +); + +typedef fido_authenticator_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_fido_foreach_authenticator = ffi.Int32 Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_fido_foreach_authenticator = int Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_fido_authenticator_get_title = ffi.Int32 Function( + ffi.Pointer auth, + ffi.Pointer> title, +); + +typedef _dart_fido_authenticator_get_title = int Function( + ffi.Pointer auth, + ffi.Pointer> title, +); + +typedef _c_fido_authenticator_get_aaid = ffi.Int32 Function( + ffi.Pointer auth, + ffi.Pointer> aaid, +); + +typedef _dart_fido_authenticator_get_aaid = int Function( + ffi.Pointer auth, + ffi.Pointer> aaid, +); + +typedef _c_fido_authenticator_get_description = ffi.Int32 Function( + ffi.Pointer auth, + ffi.Pointer> desc, +); + +typedef _dart_fido_authenticator_get_description = int Function( + ffi.Pointer auth, + ffi.Pointer> desc, +); + +typedef _c_fido_authenticator_get_assertion_scheme = ffi.Int32 Function( + ffi.Pointer auth, + ffi.Pointer> scheme, +); + +typedef _dart_fido_authenticator_get_assertion_scheme = int Function( + ffi.Pointer auth, + ffi.Pointer> scheme, +); + +typedef _c_fido_authenticator_get_algorithm = ffi.Int32 Function( + ffi.Pointer auth, + ffi.Pointer algo, +); + +typedef _dart_fido_authenticator_get_algorithm = int Function( + ffi.Pointer auth, + ffi.Pointer algo, +); + +typedef fido_attestation_type_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_fido_authenticator_foreach_attestation_type = ffi.Int32 Function( + ffi.Pointer auth, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_fido_authenticator_foreach_attestation_type = int Function( + ffi.Pointer auth, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_fido_authenticator_get_verification_method = ffi.Int32 Function( + ffi.Pointer auth, + ffi.Pointer user_verification, +); + +typedef _dart_fido_authenticator_get_verification_method = int Function( + ffi.Pointer auth, + ffi.Pointer user_verification, +); + +typedef _c_fido_authenticator_get_key_protection_method = ffi.Int32 Function( + ffi.Pointer auth, + ffi.Pointer key_protection, +); + +typedef _dart_fido_authenticator_get_key_protection_method = int Function( + ffi.Pointer auth, + ffi.Pointer key_protection, +); + +typedef _c_fido_authenticator_get_matcher_protection_method = ffi.Int32 + Function( + ffi.Pointer auth, + ffi.Pointer matcher_protection, +); + +typedef _dart_fido_authenticator_get_matcher_protection_method = int Function( + ffi.Pointer auth, + ffi.Pointer matcher_protection, +); + +typedef _c_fido_authenticator_get_attachment_hint = ffi.Int32 Function( + ffi.Pointer auth, + ffi.Pointer attachment_hint, +); + +typedef _dart_fido_authenticator_get_attachment_hint = int Function( + ffi.Pointer auth, + ffi.Pointer attachment_hint, +); + +typedef _c_fido_authenticator_get_is_second_factor_only = ffi.Uint8 Function( + ffi.Pointer auth, +); + +typedef _dart_fido_authenticator_get_is_second_factor_only = int Function( + ffi.Pointer auth, +); + +typedef _c_fido_authenticator_get_tc_discplay = ffi.Int32 Function( + ffi.Pointer auth, + ffi.Pointer tc_display, +); + +typedef _dart_fido_authenticator_get_tc_discplay = int Function( + ffi.Pointer auth, + ffi.Pointer tc_display, +); + +typedef _c_fido_authenticator_get_tc_display_type = ffi.Int32 Function( + ffi.Pointer auth, + ffi.Pointer> tc_display_content_type, +); + +typedef _dart_fido_authenticator_get_tc_display_type = int Function( + ffi.Pointer auth, + ffi.Pointer> tc_display_content_type, +); + +typedef _c_fido_authenticator_get_icon = ffi.Int32 Function( + ffi.Pointer auth, + ffi.Pointer> icon, +); + +typedef _dart_fido_authenticator_get_icon = int Function( + ffi.Pointer auth, + ffi.Pointer> icon, +); + +typedef _c_fido_get_client_vendor = ffi.Int32 Function( + ffi.Pointer> vendor_name, +); + +typedef _dart_fido_get_client_vendor = int Function( + ffi.Pointer> vendor_name, +); + +typedef _c_fido_get_client_version = ffi.Int32 Function( + ffi.Pointer client_major_version, + ffi.Pointer client_minor_version, +); + +typedef _dart_fido_get_client_version = int Function( + ffi.Pointer client_major_version, + ffi.Pointer client_minor_version, +); + +typedef _c_fido_uaf_is_supported = ffi.Int32 Function( + ffi.Pointer uaf_message_json, + ffi.Pointer is_supported, +); + +typedef _dart_fido_uaf_is_supported = int Function( + ffi.Pointer uaf_message_json, + ffi.Pointer is_supported, +); + +typedef fido_uaf_response_message_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_fido_uaf_get_response_message = ffi.Int32 Function( + ffi.Pointer uaf_request_json, + ffi.Pointer channel_binding, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_fido_uaf_get_response_message = int Function( + ffi.Pointer uaf_request_json, + ffi.Pointer channel_binding, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_fido_uaf_set_server_result = ffi.Int32 Function( + ffi.Int32 response_code, + ffi.Pointer uaf_response_json, +); + +typedef _dart_fido_uaf_set_server_result = int Function( + int response_code, + ffi.Pointer uaf_response_json, +); + +typedef _c_oauth2_request_create = ffi.Int32 Function( + ffi.Pointer> handle, +); + +typedef _dart_oauth2_request_create = int Function( + ffi.Pointer> handle, +); + +typedef _c_oauth2_request_destroy = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_oauth2_request_destroy = int Function( + ffi.Pointer handle, +); + +typedef _c_oauth2_request_set_auth_end_point_url = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer url, +); + +typedef _dart_oauth2_request_set_auth_end_point_url = int Function( + ffi.Pointer handle, + ffi.Pointer url, +); + +typedef _c_oauth2_request_set_token_end_point_url = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer url, +); + +typedef _dart_oauth2_request_set_token_end_point_url = int Function( + ffi.Pointer handle, + ffi.Pointer url, +); + +typedef _c_oauth2_request_set_redirection_url = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer url, +); + +typedef _dart_oauth2_request_set_redirection_url = int Function( + ffi.Pointer handle, + ffi.Pointer url, +); + +typedef _c_oauth2_request_set_refresh_token_url = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer url, +); + +typedef _dart_oauth2_request_set_refresh_token_url = int Function( + ffi.Pointer handle, + ffi.Pointer url, +); + +typedef _c_oauth2_request_set_refresh_token = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer refresh_token, +); + +typedef _dart_oauth2_request_set_refresh_token = int Function( + ffi.Pointer handle, + ffi.Pointer refresh_token, +); + +typedef _c_oauth2_request_set_response_type = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 response_type, +); + +typedef _dart_oauth2_request_set_response_type = int Function( + ffi.Pointer handle, + int response_type, +); + +typedef _c_oauth2_request_set_client_id = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer client_id, +); + +typedef _dart_oauth2_request_set_client_id = int Function( + ffi.Pointer handle, + ffi.Pointer client_id, +); + +typedef _c_oauth2_request_set_client_secret = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer client_secret, +); + +typedef _dart_oauth2_request_set_client_secret = int Function( + ffi.Pointer handle, + ffi.Pointer client_secret, +); + +typedef _c_oauth2_request_set_client_authentication_type = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 client_auth_type, +); + +typedef _dart_oauth2_request_set_client_authentication_type = int Function( + ffi.Pointer handle, + int client_auth_type, +); + +typedef _c_oauth2_request_set_scope = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer scope, +); + +typedef _dart_oauth2_request_set_scope = int Function( + ffi.Pointer handle, + ffi.Pointer scope, +); + +typedef _c_oauth2_request_set_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer state, +); + +typedef _dart_oauth2_request_set_state = int Function( + ffi.Pointer handle, + ffi.Pointer state, +); + +typedef _c_oauth2_request_set_grant_type = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 grant_type, +); + +typedef _dart_oauth2_request_set_grant_type = int Function( + ffi.Pointer handle, + int grant_type, +); + +typedef _c_oauth2_request_set_authorization_code = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer code, +); + +typedef _dart_oauth2_request_set_authorization_code = int Function( + ffi.Pointer handle, + ffi.Pointer code, +); + +typedef _c_oauth2_request_set_user_name = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer user_name, +); + +typedef _dart_oauth2_request_set_user_name = int Function( + ffi.Pointer handle, + ffi.Pointer user_name, +); + +typedef _c_oauth2_request_set_password = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer password, +); + +typedef _dart_oauth2_request_set_password = int Function( + ffi.Pointer handle, + ffi.Pointer password, +); + +typedef _c_oauth2_request_add_custom_data = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_oauth2_request_add_custom_data = int Function( + ffi.Pointer handle, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_oauth2_request_get_auth_end_point_url = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> url, +); + +typedef _dart_oauth2_request_get_auth_end_point_url = int Function( + ffi.Pointer handle, + ffi.Pointer> url, +); + +typedef _c_oauth2_request_get_token_end_point_url = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> url, +); + +typedef _dart_oauth2_request_get_token_end_point_url = int Function( + ffi.Pointer handle, + ffi.Pointer> url, +); + +typedef _c_oauth2_request_get_redirection_url = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> url, +); + +typedef _dart_oauth2_request_get_redirection_url = int Function( + ffi.Pointer handle, + ffi.Pointer> url, +); + +typedef _c_oauth2_request_get_refresh_token_url = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> url, +); + +typedef _dart_oauth2_request_get_refresh_token_url = int Function( + ffi.Pointer handle, + ffi.Pointer> url, +); + +typedef _c_oauth2_request_get_refresh_token = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> refresh_token, +); + +typedef _dart_oauth2_request_get_refresh_token = int Function( + ffi.Pointer handle, + ffi.Pointer> refresh_token, +); + +typedef _c_oauth2_request_get_response_type = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer response_type, +); + +typedef _dart_oauth2_request_get_response_type = int Function( + ffi.Pointer handle, + ffi.Pointer response_type, +); + +typedef _c_oauth2_request_get_client_id = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> client_id, +); + +typedef _dart_oauth2_request_get_client_id = int Function( + ffi.Pointer handle, + ffi.Pointer> client_id, +); + +typedef _c_oauth2_request_get_client_secret = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> client_secret, +); + +typedef _dart_oauth2_request_get_client_secret = int Function( + ffi.Pointer handle, + ffi.Pointer> client_secret, +); + +typedef _c_oauth2_request_get_scope = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> scope, +); + +typedef _dart_oauth2_request_get_scope = int Function( + ffi.Pointer handle, + ffi.Pointer> scope, +); + +typedef _c_oauth2_request_get_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> state, +); + +typedef _dart_oauth2_request_get_state = int Function( + ffi.Pointer handle, + ffi.Pointer> state, +); + +typedef _c_oauth2_request_get_grant_type = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer grant_type, +); + +typedef _dart_oauth2_request_get_grant_type = int Function( + ffi.Pointer handle, + ffi.Pointer grant_type, +); + +typedef _c_oauth2_request_get_authorization_code = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> code, +); + +typedef _dart_oauth2_request_get_authorization_code = int Function( + ffi.Pointer handle, + ffi.Pointer> code, +); + +typedef _c_oauth2_request_get_user_name = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> user_name, +); + +typedef _dart_oauth2_request_get_user_name = int Function( + ffi.Pointer handle, + ffi.Pointer> user_name, +); + +typedef _c_oauth2_request_get_password = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> password, +); + +typedef _dart_oauth2_request_get_password = int Function( + ffi.Pointer handle, + ffi.Pointer> password, +); + +typedef _c_oauth2_request_get_custom_data = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer custom_key, + ffi.Pointer> custom_value, +); + +typedef _dart_oauth2_request_get_custom_data = int Function( + ffi.Pointer handle, + ffi.Pointer custom_key, + ffi.Pointer> custom_value, +); + +typedef _c_oauth2_error_get_code = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer server_error_code, + ffi.Pointer platform_error_code, +); + +typedef _dart_oauth2_error_get_code = int Function( + ffi.Pointer handle, + ffi.Pointer server_error_code, + ffi.Pointer platform_error_code, +); + +typedef _c_oauth2_error_get_description = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> description, +); + +typedef _dart_oauth2_error_get_description = int Function( + ffi.Pointer handle, + ffi.Pointer> description, +); + +typedef _c_oauth2_error_get_uri = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> uri, +); + +typedef _dart_oauth2_error_get_uri = int Function( + ffi.Pointer handle, + ffi.Pointer> uri, +); + +typedef _c_oauth2_error_get_custom_data = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer custom_key, + ffi.Pointer> custom_value, +); + +typedef _dart_oauth2_error_get_custom_data = int Function( + ffi.Pointer handle, + ffi.Pointer custom_key, + ffi.Pointer> custom_value, +); + +typedef _c_oauth2_response_destroy = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_oauth2_response_destroy = int Function( + ffi.Pointer handle, +); + +typedef _c_oauth2_response_get_authorization_code = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> code, +); + +typedef _dart_oauth2_response_get_authorization_code = int Function( + ffi.Pointer handle, + ffi.Pointer> code, +); + +typedef _c_oauth2_response_get_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> state, +); + +typedef _dart_oauth2_response_get_state = int Function( + ffi.Pointer handle, + ffi.Pointer> state, +); + +typedef _c_oauth2_response_get_access_token = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> access_token, +); + +typedef _dart_oauth2_response_get_access_token = int Function( + ffi.Pointer handle, + ffi.Pointer> access_token, +); + +typedef _c_oauth2_response_get_token_type = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> token_type, +); + +typedef _dart_oauth2_response_get_token_type = int Function( + ffi.Pointer handle, + ffi.Pointer> token_type, +); + +typedef _c_oauth2_response_get_expires_in = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer expires_in, +); + +typedef _dart_oauth2_response_get_expires_in = int Function( + ffi.Pointer handle, + ffi.Pointer expires_in, +); + +typedef _c_oauth2_response_get_refresh_token = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> refresh_token, +); + +typedef _dart_oauth2_response_get_refresh_token = int Function( + ffi.Pointer handle, + ffi.Pointer> refresh_token, +); + +typedef _c_oauth2_response_get_scope = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> scope, +); + +typedef _dart_oauth2_response_get_scope = int Function( + ffi.Pointer handle, + ffi.Pointer> scope, +); + +typedef _c_oauth2_response_get_error = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> error, +); + +typedef _dart_oauth2_response_get_error = int Function( + ffi.Pointer handle, + ffi.Pointer> error, +); + +typedef _c_oauth2_response_get_custom_data = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer custom_key, + ffi.Pointer> custom_value, +); + +typedef _dart_oauth2_response_get_custom_data = int Function( + ffi.Pointer handle, + ffi.Pointer custom_key, + ffi.Pointer> custom_value, +); + +typedef _c_oauth2_manager_create = ffi.Int32 Function( + ffi.Pointer> handle, +); + +typedef _dart_oauth2_manager_create = int Function( + ffi.Pointer> handle, +); + +typedef _c_oauth2_manager_destroy = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_oauth2_manager_destroy = int Function( + ffi.Pointer handle, +); + +typedef oauth2_token_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_oauth2_manager_request_token = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_oauth2_manager_request_token = int Function( + ffi.Pointer handle, + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef oauth2_auth_grant_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_oauth2_manager_request_authorization_grant = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_oauth2_manager_request_authorization_grant = int Function( + ffi.Pointer handle, + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef oauth2_access_token_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_oauth2_manager_request_access_token = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_oauth2_manager_request_access_token = int Function( + ffi.Pointer handle, + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef oauth2_refresh_token_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_oauth2_manager_refresh_access_token = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_oauth2_manager_refresh_access_token = int Function( + ffi.Pointer handle, + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_oauth2_manager_is_request_in_progress = ffi.Uint8 Function( + ffi.Pointer handle, +); + +typedef _dart_oauth2_manager_is_request_in_progress = int Function( + ffi.Pointer handle, +); + +typedef _c_oauth2_manager_clear_cookies = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_oauth2_manager_clear_cookies = int Function( + ffi.Pointer handle, +); + +typedef _c_oauth2_manager_clear_cache = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_oauth2_manager_clear_cache = int Function( + ffi.Pointer handle, +); + +typedef _c_sync_manager_on_demand_sync_job = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer sync_job_name, + ffi.Int32 sync_option, + ffi.Pointer sync_job_user_data, + ffi.Pointer sync_job_id, +); + +typedef _dart_sync_manager_on_demand_sync_job = int Function( + ffi.Pointer account, + ffi.Pointer sync_job_name, + int sync_option, + ffi.Pointer sync_job_user_data, + ffi.Pointer sync_job_id, +); + +typedef _c_sync_manager_add_periodic_sync_job = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer sync_job_name, + ffi.Int32 sync_period, + ffi.Int32 sync_option, + ffi.Pointer sync_job_user_data, + ffi.Pointer sync_job_id, +); + +typedef _dart_sync_manager_add_periodic_sync_job = int Function( + ffi.Pointer account, + ffi.Pointer sync_job_name, + int sync_period, + int sync_option, + ffi.Pointer sync_job_user_data, + ffi.Pointer sync_job_id, +); + +typedef _c_sync_manager_add_data_change_sync_job = ffi.Int32 Function( + ffi.Pointer account, + ffi.Pointer sync_capability, + ffi.Int32 sync_option, + ffi.Pointer sync_job_user_data, + ffi.Pointer sync_job_id, +); + +typedef _dart_sync_manager_add_data_change_sync_job = int Function( + ffi.Pointer account, + ffi.Pointer sync_capability, + int sync_option, + ffi.Pointer sync_job_user_data, + ffi.Pointer sync_job_id, +); + +typedef _c_sync_manager_remove_sync_job = ffi.Int32 Function( + ffi.Int32 sync_job_id, +); + +typedef _dart_sync_manager_remove_sync_job = int Function( + int sync_job_id, +); + +typedef sync_manager_sync_job_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_sync_manager_foreach_sync_job = ffi.Int32 Function( + ffi.Pointer> sync_job_cb, + ffi.Pointer user_data, +); + +typedef _dart_sync_manager_foreach_sync_job = int Function( + ffi.Pointer> sync_job_cb, + ffi.Pointer user_data, +); + +typedef sync_adapter_start_sync_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef sync_adapter_cancel_sync_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_sync_adapter_set_callbacks = ffi.Int32 Function( + ffi.Pointer> on_start_cb, + ffi.Pointer> on_cancel_cb, +); + +typedef _dart_sync_adapter_set_callbacks = int Function( + ffi.Pointer> on_start_cb, + ffi.Pointer> on_cancel_cb, +); + +typedef _c_sync_adapter_unset_callbacks = ffi.Int32 Function(); + +typedef _dart_sync_adapter_unset_callbacks = int Function(); + +typedef _c_app_control_create = ffi.Int32 Function( + ffi.Pointer> app_control, +); + +typedef _dart_app_control_create = int Function( + ffi.Pointer> app_control, +); + +typedef _c_app_control_destroy = ffi.Int32 Function( + ffi.Pointer app_control, +); + +typedef _dart_app_control_destroy = int Function( + ffi.Pointer app_control, +); + +typedef _c_app_control_set_operation = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer operation, +); + +typedef _dart_app_control_set_operation = int Function( + ffi.Pointer app_control, + ffi.Pointer operation, +); + +typedef _c_app_control_get_operation = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer> operation, +); + +typedef _dart_app_control_get_operation = int Function( + ffi.Pointer app_control, + ffi.Pointer> operation, +); + +typedef _c_app_control_set_uri = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer uri, +); + +typedef _dart_app_control_set_uri = int Function( + ffi.Pointer app_control, + ffi.Pointer uri, +); + +typedef _c_app_control_get_uri = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer> uri, +); + +typedef _dart_app_control_get_uri = int Function( + ffi.Pointer app_control, + ffi.Pointer> uri, +); + +typedef _c_app_control_set_mime = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer mime, +); + +typedef _dart_app_control_set_mime = int Function( + ffi.Pointer app_control, + ffi.Pointer mime, +); + +typedef _c_app_control_get_mime = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer> mime, +); + +typedef _dart_app_control_get_mime = int Function( + ffi.Pointer app_control, + ffi.Pointer> mime, +); + +typedef _c_app_control_set_category = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer category, +); + +typedef _dart_app_control_set_category = int Function( + ffi.Pointer app_control, + ffi.Pointer category, +); + +typedef _c_app_control_get_category = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer> category, +); + +typedef _dart_app_control_get_category = int Function( + ffi.Pointer app_control, + ffi.Pointer> category, +); + +typedef _c_app_control_set_app_id = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer app_id, +); + +typedef _dart_app_control_set_app_id = int Function( + ffi.Pointer app_control, + ffi.Pointer app_id, +); + +typedef _c_app_control_get_app_id = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer> app_id, +); + +typedef _dart_app_control_get_app_id = int Function( + ffi.Pointer app_control, + ffi.Pointer> app_id, +); + +typedef _c_app_control_add_extra_data = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_app_control_add_extra_data = int Function( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_app_control_add_extra_data_array = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer> value, + ffi.Int32 length, +); + +typedef _dart_app_control_add_extra_data_array = int Function( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer> value, + int length, +); + +typedef _c_app_control_remove_extra_data = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer key, +); + +typedef _dart_app_control_remove_extra_data = int Function( + ffi.Pointer app_control, + ffi.Pointer key, +); + +typedef _c_app_control_get_extra_data = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer> value, +); + +typedef _dart_app_control_get_extra_data = int Function( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer> value, +); + +typedef _c_app_control_get_extra_data_array = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer>> value, + ffi.Pointer length, +); + +typedef _dart_app_control_get_extra_data_array = int Function( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer>> value, + ffi.Pointer length, +); + +typedef _c_app_control_is_extra_data_array = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer array, +); + +typedef _dart_app_control_is_extra_data_array = int Function( + ffi.Pointer app_control, + ffi.Pointer key, + ffi.Pointer array, +); + +typedef app_control_extra_data_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_app_control_foreach_extra_data = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_app_control_foreach_extra_data = int Function( + ffi.Pointer app_control, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef app_control_app_matched_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_app_control_foreach_app_matched = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_app_control_foreach_app_matched = int Function( + ffi.Pointer app_control, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef app_control_reply_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_app_control_send_launch_request = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_app_control_send_launch_request = int Function( + ffi.Pointer app_control, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_app_control_send_terminate_request = ffi.Int32 Function( + ffi.Pointer app_control, +); + +typedef _dart_app_control_send_terminate_request = int Function( + ffi.Pointer app_control, +); + +typedef _c_app_control_reply_to_launch_request = ffi.Int32 Function( + ffi.Pointer reply, + ffi.Pointer request, + ffi.Int32 result, +); + +typedef _dart_app_control_reply_to_launch_request = int Function( + ffi.Pointer reply, + ffi.Pointer request, + int result, +); + +typedef _c_app_control_clone = ffi.Int32 Function( + ffi.Pointer> clone, + ffi.Pointer app_control, +); + +typedef _dart_app_control_clone = int Function( + ffi.Pointer> clone, + ffi.Pointer app_control, +); + +typedef _c_app_control_get_caller = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer> id, +); + +typedef _dart_app_control_get_caller = int Function( + ffi.Pointer app_control, + ffi.Pointer> id, +); + +typedef _c_app_control_is_reply_requested = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer requested, +); + +typedef _dart_app_control_is_reply_requested = int Function( + ffi.Pointer app_control, + ffi.Pointer requested, +); + +typedef _c_app_control_set_launch_mode = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Int32 mode, +); + +typedef _dart_app_control_set_launch_mode = int Function( + ffi.Pointer app_control, + int mode, +); + +typedef _c_app_control_get_launch_mode = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer mode, +); + +typedef _dart_app_control_get_launch_mode = int Function( + ffi.Pointer app_control, + ffi.Pointer mode, +); + +typedef _c_app_control_enable_app_started_result_event = ffi.Int32 Function( + ffi.Pointer app_control, +); + +typedef _dart_app_control_enable_app_started_result_event = int Function( + ffi.Pointer app_control, +); + +typedef _c_app_event_get_low_memory_status = ffi.Int32 Function( + ffi.Pointer event_info, + ffi.Pointer status, +); + +typedef _dart_app_event_get_low_memory_status = int Function( + ffi.Pointer event_info, + ffi.Pointer status, +); + +typedef _c_app_event_get_low_battery_status = ffi.Int32 Function( + ffi.Pointer event_info, + ffi.Pointer status, +); + +typedef _dart_app_event_get_low_battery_status = int Function( + ffi.Pointer event_info, + ffi.Pointer status, +); + +typedef _c_app_event_get_language = ffi.Int32 Function( + ffi.Pointer event_info, + ffi.Pointer> lang, +); + +typedef _dart_app_event_get_language = int Function( + ffi.Pointer event_info, + ffi.Pointer> lang, +); + +typedef _c_app_event_get_region_format = ffi.Int32 Function( + ffi.Pointer event_info, + ffi.Pointer> region, +); + +typedef _dart_app_event_get_region_format = int Function( + ffi.Pointer event_info, + ffi.Pointer> region, +); + +typedef _c_app_event_get_device_orientation = ffi.Int32 Function( + ffi.Pointer event_info, + ffi.Pointer orientation, +); + +typedef _dart_app_event_get_device_orientation = int Function( + ffi.Pointer event_info, + ffi.Pointer orientation, +); + +typedef _c_app_event_get_suspended_state = ffi.Int32 Function( + ffi.Pointer event_info, + ffi.Pointer state, +); + +typedef _dart_app_event_get_suspended_state = int Function( + ffi.Pointer event_info, + ffi.Pointer state, +); + +typedef _c_app_get_id = ffi.Int32 Function( + ffi.Pointer> id, +); + +typedef _dart_app_get_id = int Function( + ffi.Pointer> id, +); + +typedef _c_app_get_name = ffi.Int32 Function( + ffi.Pointer> name, +); + +typedef _dart_app_get_name = int Function( + ffi.Pointer> name, +); + +typedef _c_app_get_version = ffi.Int32 Function( + ffi.Pointer> version, +); + +typedef _dart_app_get_version = int Function( + ffi.Pointer> version, +); + +typedef _c_app_get_data_path = ffi.Pointer Function(); + +typedef _dart_app_get_data_path = ffi.Pointer Function(); + +typedef _c_app_get_cache_path = ffi.Pointer Function(); + +typedef _dart_app_get_cache_path = ffi.Pointer Function(); + +typedef _c_app_get_resource_path = ffi.Pointer Function(); + +typedef _dart_app_get_resource_path = ffi.Pointer Function(); + +typedef _c_app_get_shared_data_path = ffi.Pointer Function(); + +typedef _dart_app_get_shared_data_path = ffi.Pointer Function(); + +typedef _c_app_get_shared_resource_path = ffi.Pointer Function(); + +typedef _dart_app_get_shared_resource_path = ffi.Pointer Function(); + +typedef _c_app_get_shared_trusted_path = ffi.Pointer Function(); + +typedef _dart_app_get_shared_trusted_path = ffi.Pointer Function(); + +typedef _c_app_get_external_data_path = ffi.Pointer Function(); + +typedef _dart_app_get_external_data_path = ffi.Pointer Function(); + +typedef _c_app_get_external_cache_path = ffi.Pointer Function(); + +typedef _dart_app_get_external_cache_path = ffi.Pointer Function(); + +typedef _c_app_get_external_shared_data_path = ffi.Pointer Function(); + +typedef _dart_app_get_external_shared_data_path = ffi.Pointer + Function(); + +typedef _c_app_get_tep_resource_path = ffi.Pointer Function(); + +typedef _dart_app_get_tep_resource_path = ffi.Pointer Function(); + +typedef _c_i18n_get_text = ffi.Pointer Function( + ffi.Pointer message, +); + +typedef _dart_i18n_get_text = ffi.Pointer Function( + ffi.Pointer message, +); + +typedef _c_app_get_device_orientation = ffi.Int32 Function(); + +typedef _dart_app_get_device_orientation = int Function(); + +typedef _c_ui_app_main = ffi.Int32 Function( + ffi.Int32 argc, + ffi.Pointer> argv, + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _dart_ui_app_main = int Function( + int argc, + ffi.Pointer> argv, + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _c_ui_app_exit = ffi.Void Function(); + +typedef _dart_ui_app_exit = void Function(); + +typedef app_event_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_ui_app_add_event_handler = ffi.Int32 Function( + ffi.Pointer> event_handler, + ffi.Int32 event_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_ui_app_add_event_handler = int Function( + ffi.Pointer> event_handler, + int event_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_ui_app_remove_event_handler = ffi.Int32 Function( + ffi.Pointer event_handler, +); + +typedef _dart_ui_app_remove_event_handler = int Function( + ffi.Pointer event_handler, +); + +typedef _c_alarm_schedule_after_delay = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Int32 delay, + ffi.Int32 period, + ffi.Pointer alarm_id, +); + +typedef _dart_alarm_schedule_after_delay = int Function( + ffi.Pointer app_control, + int delay, + int period, + ffi.Pointer alarm_id, +); + +typedef _c_alarm_schedule_at_date = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer date, + ffi.Int32 period, + ffi.Pointer alarm_id, +); + +typedef _dart_alarm_schedule_at_date = int Function( + ffi.Pointer app_control, + ffi.Pointer date, + int period, + ffi.Pointer alarm_id, +); + +typedef _c_alarm_schedule_once_after_delay = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Int32 delay, + ffi.Pointer alarm_id, +); + +typedef _dart_alarm_schedule_once_after_delay = int Function( + ffi.Pointer app_control, + int delay, + ffi.Pointer alarm_id, +); + +typedef _c_alarm_schedule_once_at_date = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer date, + ffi.Pointer alarm_id, +); + +typedef _dart_alarm_schedule_once_at_date = int Function( + ffi.Pointer app_control, + ffi.Pointer date, + ffi.Pointer alarm_id, +); + +typedef _c_alarm_schedule_with_recurrence_week_flag = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer date, + ffi.Int32 week_flag, + ffi.Pointer alarm_id, +); + +typedef _dart_alarm_schedule_with_recurrence_week_flag = int Function( + ffi.Pointer app_control, + ffi.Pointer date, + int week_flag, + ffi.Pointer alarm_id, +); + +typedef _c_alarm_get_scheduled_recurrence_week_flag = ffi.Int32 Function( + ffi.Int32 alarm_id, + ffi.Pointer week_flag, +); + +typedef _dart_alarm_get_scheduled_recurrence_week_flag = int Function( + int alarm_id, + ffi.Pointer week_flag, +); + +typedef _c_alarm_cancel = ffi.Int32 Function( + ffi.Int32 alarm_id, +); + +typedef _dart_alarm_cancel = int Function( + int alarm_id, +); + +typedef _c_alarm_cancel_all = ffi.Int32 Function(); + +typedef _dart_alarm_cancel_all = int Function(); + +typedef alarm_registered_alarm_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_alarm_foreach_registered_alarm = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_alarm_foreach_registered_alarm = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_alarm_get_scheduled_date = ffi.Int32 Function( + ffi.Int32 alarm_id, + ffi.Pointer date, +); + +typedef _dart_alarm_get_scheduled_date = int Function( + int alarm_id, + ffi.Pointer date, +); + +typedef _c_alarm_get_scheduled_period = ffi.Int32 Function( + ffi.Int32 alarm_id, + ffi.Pointer period, +); + +typedef _dart_alarm_get_scheduled_period = int Function( + int alarm_id, + ffi.Pointer period, +); + +typedef _c_alarm_get_current_time = ffi.Int32 Function( + ffi.Pointer date, +); + +typedef _dart_alarm_get_current_time = int Function( + ffi.Pointer date, +); + +typedef _c_alarm_get_app_control = ffi.Int32 Function( + ffi.Int32 alarm_id, + ffi.Pointer> app_control, +); + +typedef _dart_alarm_get_app_control = int Function( + int alarm_id, + ffi.Pointer> app_control, +); + +typedef _c_alarm_set_global = ffi.Int32 Function( + ffi.Int32 alarm_id, + ffi.Uint8 global, +); + +typedef _dart_alarm_set_global = int Function( + int alarm_id, + int global, +); + +typedef _c_alarm_get_global = ffi.Int32 Function( + ffi.Int32 alarm_id, + ffi.Pointer global, +); + +typedef _dart_alarm_get_global = int Function( + int alarm_id, + ffi.Pointer global, +); + +typedef _c_alarm_schedule_noti_once_at_date = ffi.Int32 Function( + ffi.Pointer noti, + ffi.Pointer date, + ffi.Pointer alarm_id, +); + +typedef _dart_alarm_schedule_noti_once_at_date = int Function( + ffi.Pointer noti, + ffi.Pointer date, + ffi.Pointer alarm_id, +); + +typedef _c_alarm_schedule_noti_after_delay = ffi.Int32 Function( + ffi.Pointer noti, + ffi.Int32 delay, + ffi.Int32 period, + ffi.Pointer alarm_id, +); + +typedef _dart_alarm_schedule_noti_after_delay = int Function( + ffi.Pointer noti, + int delay, + int period, + ffi.Pointer alarm_id, +); + +typedef _c_alarm_schedule_noti_once_after_delay = ffi.Int32 Function( + ffi.Pointer noti, + ffi.Int32 delay, + ffi.Pointer alarm_id, +); + +typedef _dart_alarm_schedule_noti_once_after_delay = int Function( + ffi.Pointer noti, + int delay, + ffi.Pointer alarm_id, +); + +typedef _c_alarm_schedule_noti_with_recurrence_week_flag = ffi.Int32 Function( + ffi.Pointer noti, + ffi.Pointer date, + ffi.Int32 week_flag, + ffi.Pointer alarm_id, +); + +typedef _dart_alarm_schedule_noti_with_recurrence_week_flag = int Function( + ffi.Pointer noti, + ffi.Pointer date, + int week_flag, + ffi.Pointer alarm_id, +); + +typedef _c_alarm_get_notification = ffi.Int32 Function( + ffi.Int32 alarm_id, + ffi.Pointer> noti, +); + +typedef _dart_alarm_get_notification = int Function( + int alarm_id, + ffi.Pointer> noti, +); + +typedef _c_alarm_update_delay = ffi.Int32 Function( + ffi.Int32 alarm_id, + ffi.Int32 delay, +); + +typedef _dart_alarm_update_delay = int Function( + int alarm_id, + int delay, +); + +typedef _c_alarm_update_date = ffi.Int32 Function( + ffi.Int32 alarm_id, + ffi.Pointer date, +); + +typedef _dart_alarm_update_date = int Function( + int alarm_id, + ffi.Pointer date, +); + +typedef _c_alarm_update_period = ffi.Int32 Function( + ffi.Int32 alarm_id, + ffi.Int32 period, +); + +typedef _dart_alarm_update_period = int Function( + int alarm_id, + int period, +); + +typedef _c_alarm_update_week_flag = ffi.Int32 Function( + ffi.Int32 alarm_id, + ffi.Int32 week_flag, +); + +typedef _dart_alarm_update_week_flag = int Function( + int alarm_id, + int week_flag, +); + +typedef event_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_event_add_event_handler = ffi.Int32 Function( + ffi.Pointer event_name, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer> event_handler, +); + +typedef _dart_event_add_event_handler = int Function( + ffi.Pointer event_name, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer> event_handler, +); + +typedef _c_event_remove_event_handler = ffi.Int32 Function( + ffi.Pointer event_handler, +); + +typedef _dart_event_remove_event_handler = int Function( + ffi.Pointer event_handler, +); + +typedef _c_event_publish_app_event = ffi.Int32 Function( + ffi.Pointer event_name, + ffi.Pointer event_data, +); + +typedef _dart_event_publish_app_event = int Function( + ffi.Pointer event_name, + ffi.Pointer event_data, +); + +typedef _c_event_publish_trusted_app_event = ffi.Int32 Function( + ffi.Pointer event_name, + ffi.Pointer event_data, +); + +typedef _dart_event_publish_trusted_app_event = int Function( + ffi.Pointer event_name, + ffi.Pointer event_data, +); + +typedef _c_event_keep_last_event_data = ffi.Int32 Function( + ffi.Pointer event_name, +); + +typedef _dart_event_keep_last_event_data = int Function( + ffi.Pointer event_name, +); + +typedef _c_job_info_create = ffi.Int32 Function( + ffi.Pointer> job_info, +); + +typedef _dart_job_info_create = int Function( + ffi.Pointer> job_info, +); + +typedef _c_job_info_destroy = ffi.Int32 Function( + ffi.Pointer job_info, +); + +typedef _dart_job_info_destroy = int Function( + ffi.Pointer job_info, +); + +typedef _c_job_info_set_periodic = ffi.Int32 Function( + ffi.Pointer job_info, + ffi.Uint32 interval, +); + +typedef _dart_job_info_set_periodic = int Function( + ffi.Pointer job_info, + int interval, +); + +typedef _c_job_info_set_persistent = ffi.Int32 Function( + ffi.Pointer job_info, + ffi.Uint8 persistent, +); + +typedef _dart_job_info_set_persistent = int Function( + ffi.Pointer job_info, + int persistent, +); + +typedef _c_job_info_set_once = ffi.Int32 Function( + ffi.Pointer job_info, + ffi.Uint8 once, +); + +typedef _dart_job_info_set_once = int Function( + ffi.Pointer job_info, + int once, +); + +typedef _c_job_info_set_requirement_timeout = ffi.Int32 Function( + ffi.Pointer job_info, + ffi.Uint32 timeout, +); + +typedef _dart_job_info_set_requirement_timeout = int Function( + ffi.Pointer job_info, + int timeout, +); + +typedef _c_job_info_set_requires_battery_not_low = ffi.Int32 Function( + ffi.Pointer job_info, + ffi.Uint8 battery_not_low, +); + +typedef _dart_job_info_set_requires_battery_not_low = int Function( + ffi.Pointer job_info, + int battery_not_low, +); + +typedef _c_job_info_set_requires_charging = ffi.Int32 Function( + ffi.Pointer job_info, + ffi.Uint8 charging, +); + +typedef _dart_job_info_set_requires_charging = int Function( + ffi.Pointer job_info, + int charging, +); + +typedef _c_job_info_set_requires_wifi_connection = ffi.Int32 Function( + ffi.Pointer job_info, + ffi.Uint8 wifi_connection, +); + +typedef _dart_job_info_set_requires_wifi_connection = int Function( + ffi.Pointer job_info, + int wifi_connection, +); + +typedef _c_job_info_add_trigger_event = ffi.Int32 Function( + ffi.Pointer job_info, + ffi.Int32 event, +); + +typedef _dart_job_info_add_trigger_event = int Function( + ffi.Pointer job_info, + int event, +); + +typedef _c_job_info_remove_trigger_event = ffi.Int32 Function( + ffi.Pointer job_info, + ffi.Int32 event, +); + +typedef _dart_job_info_remove_trigger_event = int Function( + ffi.Pointer job_info, + int event, +); + +typedef _c_job_info_get_job_id = ffi.Int32 Function( + ffi.Pointer job_info, + ffi.Pointer> job_id, +); + +typedef _dart_job_info_get_job_id = int Function( + ffi.Pointer job_info, + ffi.Pointer> job_id, +); + +typedef _c_job_info_clone = ffi.Int32 Function( + ffi.Pointer job_info, + ffi.Pointer> clone, +); + +typedef _dart_job_info_clone = int Function( + ffi.Pointer job_info, + ffi.Pointer> clone, +); + +typedef _c_job_scheduler_init = ffi.Int32 Function(); + +typedef _dart_job_scheduler_init = int Function(); + +typedef _c_job_scheduler_finish = ffi.Int32 Function(); + +typedef _dart_job_scheduler_finish = int Function(); + +typedef _c_job_scheduler_schedule = ffi.Int32 Function( + ffi.Pointer job_info, + ffi.Pointer job_id, +); + +typedef _dart_job_scheduler_schedule = int Function( + ffi.Pointer job_info, + ffi.Pointer job_id, +); + +typedef _c_job_scheduler_cancel = ffi.Int32 Function( + ffi.Pointer job_id, +); + +typedef _dart_job_scheduler_cancel = int Function( + ffi.Pointer job_id, +); + +typedef _c_job_scheduler_cancel_all = ffi.Int32 Function(); + +typedef _dart_job_scheduler_cancel_all = int Function(); + +typedef _c_job_scheduler_notify_job_finished = ffi.Int32 Function( + ffi.Pointer job_id, +); + +typedef _dart_job_scheduler_notify_job_finished = int Function( + ffi.Pointer job_id, +); + +typedef job_scheduler_foreach_job_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_job_scheduler_foreach_job = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_job_scheduler_foreach_job = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_job_scheduler_service_add = ffi.Int32 Function( + ffi.Pointer job_id, + ffi.Pointer callback, + ffi.Pointer user_data, + ffi.Pointer> job_service, +); + +typedef _dart_job_scheduler_service_add = int Function( + ffi.Pointer job_id, + ffi.Pointer callback, + ffi.Pointer user_data, + ffi.Pointer> job_service, +); + +typedef _c_job_scheduler_service_remove = ffi.Int32 Function( + ffi.Pointer job_service, +); + +typedef _dart_job_scheduler_service_remove = int Function( + ffi.Pointer job_service, +); + +typedef _c_preference_set_int = ffi.Int32 Function( + ffi.Pointer key, + ffi.Int32 value, +); + +typedef _dart_preference_set_int = int Function( + ffi.Pointer key, + int value, +); + +typedef _c_preference_get_int = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_preference_get_int = int Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_preference_set_double = ffi.Int32 Function( + ffi.Pointer key, + ffi.Double value, +); + +typedef _dart_preference_set_double = int Function( + ffi.Pointer key, + double value, +); + +typedef _c_preference_get_double = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_preference_get_double = int Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_preference_set_string = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_preference_set_string = int Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_preference_get_string = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer> value, +); + +typedef _dart_preference_get_string = int Function( + ffi.Pointer key, + ffi.Pointer> value, +); + +typedef _c_preference_set_boolean = ffi.Int32 Function( + ffi.Pointer key, + ffi.Uint8 value, +); + +typedef _dart_preference_set_boolean = int Function( + ffi.Pointer key, + int value, +); + +typedef _c_preference_get_boolean = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_preference_get_boolean = int Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_preference_remove = ffi.Int32 Function( + ffi.Pointer key, +); + +typedef _dart_preference_remove = int Function( + ffi.Pointer key, +); + +typedef _c_preference_is_existing = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer existing, +); + +typedef _dart_preference_is_existing = int Function( + ffi.Pointer key, + ffi.Pointer existing, +); + +typedef _c_preference_remove_all = ffi.Int32 Function(); + +typedef _dart_preference_remove_all = int Function(); + +typedef preference_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_preference_set_changed_cb = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_preference_set_changed_cb = int Function( + ffi.Pointer key, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_preference_unset_changed_cb = ffi.Int32 Function( + ffi.Pointer key, +); + +typedef _dart_preference_unset_changed_cb = int Function( + ffi.Pointer key, +); + +typedef preference_item_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_preference_foreach_item = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_preference_foreach_item = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_app_resource_manager_init = ffi.Int32 Function(); + +typedef _dart_app_resource_manager_init = int Function(); + +typedef _c_app_resource_manager_get = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer id, + ffi.Pointer> path, +); + +typedef _dart_app_resource_manager_get = int Function( + int type, + ffi.Pointer id, + ffi.Pointer> path, +); + +typedef _c_app_resource_manager_release = ffi.Int32 Function(); + +typedef _dart_app_resource_manager_release = int Function(); + +typedef _c_app_context_destroy = ffi.Int32 Function( + ffi.Pointer app_context, +); + +typedef _dart_app_context_destroy = int Function( + ffi.Pointer app_context, +); + +typedef _c_app_context_get_package = ffi.Int32 Function( + ffi.Pointer app_context, + ffi.Pointer> package, +); + +typedef _dart_app_context_get_package = int Function( + ffi.Pointer app_context, + ffi.Pointer> package, +); + +typedef _c_app_context_get_app_id = ffi.Int32 Function( + ffi.Pointer app_context, + ffi.Pointer> app_id, +); + +typedef _dart_app_context_get_app_id = int Function( + ffi.Pointer app_context, + ffi.Pointer> app_id, +); + +typedef _c_app_context_get_pid = ffi.Int32 Function( + ffi.Pointer app_context, + ffi.Pointer pid, +); + +typedef _dart_app_context_get_pid = int Function( + ffi.Pointer app_context, + ffi.Pointer pid, +); + +typedef _c_app_context_get_package_id = ffi.Int32 Function( + ffi.Pointer app_context, + ffi.Pointer> pkg_id, +); + +typedef _dart_app_context_get_package_id = int Function( + ffi.Pointer app_context, + ffi.Pointer> pkg_id, +); + +typedef _c_app_context_get_app_state = ffi.Int32 Function( + ffi.Pointer app_context, + ffi.Pointer state, +); + +typedef _dart_app_context_get_app_state = int Function( + ffi.Pointer app_context, + ffi.Pointer state, +); + +typedef _c_app_context_is_terminated = ffi.Int32 Function( + ffi.Pointer app_context, + ffi.Pointer terminated, +); + +typedef _dart_app_context_is_terminated = int Function( + ffi.Pointer app_context, + ffi.Pointer terminated, +); + +typedef _c_app_context_is_equal = ffi.Int32 Function( + ffi.Pointer lhs, + ffi.Pointer rhs, + ffi.Pointer equal, +); + +typedef _dart_app_context_is_equal = int Function( + ffi.Pointer lhs, + ffi.Pointer rhs, + ffi.Pointer equal, +); + +typedef _c_app_context_is_sub_app = ffi.Int32 Function( + ffi.Pointer app_context, + ffi.Pointer is_sub_app, +); + +typedef _dart_app_context_is_sub_app = int Function( + ffi.Pointer app_context, + ffi.Pointer is_sub_app, +); + +typedef _c_app_context_clone = ffi.Int32 Function( + ffi.Pointer> clone, + ffi.Pointer app_context, +); + +typedef _dart_app_context_clone = int Function( + ffi.Pointer> clone, + ffi.Pointer app_context, +); + +typedef _c_app_info_create = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer> app_info, +); + +typedef _dart_app_info_create = int Function( + ffi.Pointer app_id, + ffi.Pointer> app_info, +); + +typedef _c_app_info_destroy = ffi.Int32 Function( + ffi.Pointer app_info, +); + +typedef _dart_app_info_destroy = int Function( + ffi.Pointer app_info, +); + +typedef _c_app_info_get_app_id = ffi.Int32 Function( + ffi.Pointer app_info, + ffi.Pointer> app_id, +); + +typedef _dart_app_info_get_app_id = int Function( + ffi.Pointer app_info, + ffi.Pointer> app_id, +); + +typedef _c_app_info_get_exec = ffi.Int32 Function( + ffi.Pointer app_info, + ffi.Pointer> exec, +); + +typedef _dart_app_info_get_exec = int Function( + ffi.Pointer app_info, + ffi.Pointer> exec, +); + +typedef _c_app_info_get_label = ffi.Int32 Function( + ffi.Pointer app_info, + ffi.Pointer> label, +); + +typedef _dart_app_info_get_label = int Function( + ffi.Pointer app_info, + ffi.Pointer> label, +); + +typedef _c_app_info_get_localed_label = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer locale, + ffi.Pointer> label, +); + +typedef _dart_app_info_get_localed_label = int Function( + ffi.Pointer app_id, + ffi.Pointer locale, + ffi.Pointer> label, +); + +typedef _c_app_info_get_icon = ffi.Int32 Function( + ffi.Pointer app_info, + ffi.Pointer> path, +); + +typedef _dart_app_info_get_icon = int Function( + ffi.Pointer app_info, + ffi.Pointer> path, +); + +typedef _c_app_info_get_package = ffi.Int32 Function( + ffi.Pointer app_info, + ffi.Pointer> package, +); + +typedef _dart_app_info_get_package = int Function( + ffi.Pointer app_info, + ffi.Pointer> package, +); + +typedef _c_app_info_get_type = ffi.Int32 Function( + ffi.Pointer app_info, + ffi.Pointer> type, +); + +typedef _dart_app_info_get_type = int Function( + ffi.Pointer app_info, + ffi.Pointer> type, +); + +typedef _c_app_info_get_app_component_type = ffi.Int32 Function( + ffi.Pointer app_info, + ffi.Pointer type, +); + +typedef _dart_app_info_get_app_component_type = int Function( + ffi.Pointer app_info, + ffi.Pointer type, +); + +typedef app_info_metadata_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_app_info_foreach_metadata = ffi.Int32 Function( + ffi.Pointer app_info, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_app_info_foreach_metadata = int Function( + ffi.Pointer app_info, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_app_info_is_nodisplay = ffi.Int32 Function( + ffi.Pointer app_info, + ffi.Pointer nodisplay, +); + +typedef _dart_app_info_is_nodisplay = int Function( + ffi.Pointer app_info, + ffi.Pointer nodisplay, +); + +typedef _c_app_info_is_equal = ffi.Int32 Function( + ffi.Pointer lhs, + ffi.Pointer rhs, + ffi.Pointer equal, +); + +typedef _dart_app_info_is_equal = int Function( + ffi.Pointer lhs, + ffi.Pointer rhs, + ffi.Pointer equal, +); + +typedef _c_app_info_is_enabled = ffi.Int32 Function( + ffi.Pointer app_info, + ffi.Pointer enabled, +); + +typedef _dart_app_info_is_enabled = int Function( + ffi.Pointer app_info, + ffi.Pointer enabled, +); + +typedef _c_app_info_is_onboot = ffi.Int32 Function( + ffi.Pointer app_info, + ffi.Pointer onboot, +); + +typedef _dart_app_info_is_onboot = int Function( + ffi.Pointer app_info, + ffi.Pointer onboot, +); + +typedef _c_app_info_is_preload = ffi.Int32 Function( + ffi.Pointer app_info, + ffi.Pointer preload, +); + +typedef _dart_app_info_is_preload = int Function( + ffi.Pointer app_info, + ffi.Pointer preload, +); + +typedef _c_app_info_clone = ffi.Int32 Function( + ffi.Pointer> clone, + ffi.Pointer app_info, +); + +typedef _dart_app_info_clone = int Function( + ffi.Pointer> clone, + ffi.Pointer app_info, +); + +typedef app_info_category_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_app_info_foreach_category = ffi.Int32 Function( + ffi.Pointer app_info, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_app_info_foreach_category = int Function( + ffi.Pointer app_info, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_app_info_filter_create = ffi.Int32 Function( + ffi.Pointer> handle, +); + +typedef _dart_app_info_filter_create = int Function( + ffi.Pointer> handle, +); + +typedef _c_app_info_filter_destroy = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_app_info_filter_destroy = int Function( + ffi.Pointer handle, +); + +typedef _c_app_info_filter_add_bool = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer property, + ffi.Uint8 value, +); + +typedef _dart_app_info_filter_add_bool = int Function( + ffi.Pointer handle, + ffi.Pointer property, + int value, +); + +typedef _c_app_info_filter_add_string = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer property, + ffi.Pointer value, +); + +typedef _dart_app_info_filter_add_string = int Function( + ffi.Pointer handle, + ffi.Pointer property, + ffi.Pointer value, +); + +typedef _c_app_info_filter_count_appinfo = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer count, +); + +typedef _dart_app_info_filter_count_appinfo = int Function( + ffi.Pointer handle, + ffi.Pointer count, +); + +typedef app_info_filter_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_app_info_filter_foreach_appinfo = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_app_info_filter_foreach_appinfo = int Function( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_app_info_metadata_filter_create = ffi.Int32 Function( + ffi.Pointer> handle, +); + +typedef _dart_app_info_metadata_filter_create = int Function( + ffi.Pointer> handle, +); + +typedef _c_app_info_metadata_filter_destroy = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_app_info_metadata_filter_destroy = int Function( + ffi.Pointer handle, +); + +typedef _c_app_info_metadata_filter_add = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_app_info_metadata_filter_add = int Function( + ffi.Pointer handle, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_app_info_metadata_filter_foreach = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_app_info_metadata_filter_foreach = int Function( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef app_manager_app_context_event_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_app_manager_set_app_context_event_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_app_manager_set_app_context_event_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_app_manager_unset_app_context_event_cb = ffi.Void Function(); + +typedef _dart_app_manager_unset_app_context_event_cb = void Function(); + +typedef app_manager_app_context_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_app_manager_foreach_app_context = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_app_manager_foreach_app_context = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_app_manager_foreach_running_app_context = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_app_manager_foreach_running_app_context = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_app_manager_get_app_context = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer> app_context, +); + +typedef _dart_app_manager_get_app_context = int Function( + ffi.Pointer app_id, + ffi.Pointer> app_context, +); + +typedef _c_app_manager_get_app_id = ffi.Int32 Function( + ffi.Int32 pid, + ffi.Pointer> app_id, +); + +typedef _dart_app_manager_get_app_id = int Function( + int pid, + ffi.Pointer> app_id, +); + +typedef _c_app_manager_is_running = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer running, +); + +typedef _dart_app_manager_is_running = int Function( + ffi.Pointer app_id, + ffi.Pointer running, +); + +typedef _c_app_manager_resume_app = ffi.Int32 Function( + ffi.Pointer app_context, +); + +typedef _dart_app_manager_resume_app = int Function( + ffi.Pointer app_context, +); + +typedef _c_app_manager_request_terminate_bg_app = ffi.Int32 Function( + ffi.Pointer app_context, +); + +typedef _dart_app_manager_request_terminate_bg_app = int Function( + ffi.Pointer app_context, +); + +typedef app_manager_app_info_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_app_manager_foreach_app_info = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_app_manager_foreach_app_info = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_app_manager_get_app_info = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer> app_info, +); + +typedef _dart_app_manager_get_app_info = int Function( + ffi.Pointer app_id, + ffi.Pointer> app_info, +); + +typedef _c_app_manager_get_shared_data_path = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer> path, +); + +typedef _dart_app_manager_get_shared_data_path = int Function( + ffi.Pointer app_id, + ffi.Pointer> path, +); + +typedef _c_app_manager_get_shared_resource_path = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer> path, +); + +typedef _dart_app_manager_get_shared_resource_path = int Function( + ffi.Pointer app_id, + ffi.Pointer> path, +); + +typedef _c_app_manager_get_shared_trusted_path = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer> path, +); + +typedef _dart_app_manager_get_shared_trusted_path = int Function( + ffi.Pointer app_id, + ffi.Pointer> path, +); + +typedef _c_app_manager_get_external_shared_data_path = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer> path, +); + +typedef _dart_app_manager_get_external_shared_data_path = int Function( + ffi.Pointer app_id, + ffi.Pointer> path, +); + +typedef _c_app_manager_event_create = ffi.Int32 Function( + ffi.Pointer> handle, +); + +typedef _dart_app_manager_event_create = int Function( + ffi.Pointer> handle, +); + +typedef _c_app_manager_event_set_status = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 status_type, +); + +typedef _dart_app_manager_event_set_status = int Function( + ffi.Pointer handle, + int status_type, +); + +typedef app_manager_event_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_app_manager_set_event_cb = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_app_manager_set_event_cb = int Function( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_app_manager_unset_event_cb = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_app_manager_unset_event_cb = int Function( + ffi.Pointer handle, +); + +typedef _c_app_manager_event_destroy = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_app_manager_event_destroy = int Function( + ffi.Pointer handle, +); + +typedef _c_badge_new = ffi.Int32 Function( + ffi.Pointer writable_app_id, +); + +typedef _dart_badge_new = int Function( + ffi.Pointer writable_app_id, +); + +typedef _c_badge_add = ffi.Int32 Function( + ffi.Pointer badge_app_id, +); + +typedef _dart_badge_add = int Function( + ffi.Pointer badge_app_id, +); + +typedef _c_badge_remove = ffi.Int32 Function( + ffi.Pointer app_id, +); + +typedef _dart_badge_remove = int Function( + ffi.Pointer app_id, +); + +typedef _c_badge_set_count = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Uint32 count, +); + +typedef _dart_badge_set_count = int Function( + ffi.Pointer app_id, + int count, +); + +typedef _c_badge_get_count = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer count, +); + +typedef _dart_badge_get_count = int Function( + ffi.Pointer app_id, + ffi.Pointer count, +); + +typedef _c_badge_set_display = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Uint32 is_display, +); + +typedef _dart_badge_set_display = int Function( + ffi.Pointer app_id, + int is_display, +); + +typedef _c_badge_get_display = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer is_display, +); + +typedef _dart_badge_get_display = int Function( + ffi.Pointer app_id, + ffi.Pointer is_display, +); + +typedef badge_foreach_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_badge_foreach = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_badge_foreach = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef badge_change_cb = ffi.Void Function( + ffi.Uint32, + ffi.Pointer, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_badge_register_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_badge_register_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_badge_unregister_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, +); + +typedef _dart_badge_unregister_changed_cb = int Function( + ffi.Pointer> callback, +); + +typedef _c_data_control_sql_step_first = ffi.Int32 Function( + ffi.Pointer cursor, +); + +typedef _dart_data_control_sql_step_first = int Function( + ffi.Pointer cursor, +); + +typedef _c_data_control_sql_step_last = ffi.Int32 Function( + ffi.Pointer cursor, +); + +typedef _dart_data_control_sql_step_last = int Function( + ffi.Pointer cursor, +); + +typedef _c_data_control_sql_step_next = ffi.Int32 Function( + ffi.Pointer cursor, +); + +typedef _dart_data_control_sql_step_next = int Function( + ffi.Pointer cursor, +); + +typedef _c_data_control_sql_step_previous = ffi.Int32 Function( + ffi.Pointer cursor, +); + +typedef _dart_data_control_sql_step_previous = int Function( + ffi.Pointer cursor, +); + +typedef _c_data_control_sql_get_column_count = ffi.Int32 Function( + ffi.Pointer cursor, +); + +typedef _dart_data_control_sql_get_column_count = int Function( + ffi.Pointer cursor, +); + +typedef _c_data_control_sql_get_column_name = ffi.Int32 Function( + ffi.Pointer cursor, + ffi.Int32 column_index, + ffi.Pointer name, +); + +typedef _dart_data_control_sql_get_column_name = int Function( + ffi.Pointer cursor, + int column_index, + ffi.Pointer name, +); + +typedef _c_data_control_sql_get_column_item_size = ffi.Int32 Function( + ffi.Pointer cursor, + ffi.Int32 column_index, +); + +typedef _dart_data_control_sql_get_column_item_size = int Function( + ffi.Pointer cursor, + int column_index, +); + +typedef _c_data_control_sql_get_column_item_type = ffi.Int32 Function( + ffi.Pointer cursor, + ffi.Int32 column_index, + ffi.Pointer type, +); + +typedef _dart_data_control_sql_get_column_item_type = int Function( + ffi.Pointer cursor, + int column_index, + ffi.Pointer type, +); + +typedef _c_data_control_sql_get_blob_data = ffi.Int32 Function( + ffi.Pointer cursor, + ffi.Int32 column_index, + ffi.Pointer data, + ffi.Int32 size, +); + +typedef _dart_data_control_sql_get_blob_data = int Function( + ffi.Pointer cursor, + int column_index, + ffi.Pointer data, + int size, +); + +typedef _c_data_control_sql_get_int_data = ffi.Int32 Function( + ffi.Pointer cursor, + ffi.Int32 column_index, + ffi.Pointer data, +); + +typedef _dart_data_control_sql_get_int_data = int Function( + ffi.Pointer cursor, + int column_index, + ffi.Pointer data, +); + +typedef _c_data_control_sql_get_int64_data = ffi.Int32 Function( + ffi.Pointer cursor, + ffi.Int32 column_index, + ffi.Pointer data, +); + +typedef _dart_data_control_sql_get_int64_data = int Function( + ffi.Pointer cursor, + int column_index, + ffi.Pointer data, +); + +typedef _c_data_control_sql_get_double_data = ffi.Int32 Function( + ffi.Pointer cursor, + ffi.Int32 column_index, + ffi.Pointer data, +); + +typedef _dart_data_control_sql_get_double_data = int Function( + ffi.Pointer cursor, + int column_index, + ffi.Pointer data, +); + +typedef _c_data_control_sql_get_text_data = ffi.Int32 Function( + ffi.Pointer cursor, + ffi.Int32 column_index, + ffi.Pointer data, +); + +typedef _dart_data_control_sql_get_text_data = int Function( + ffi.Pointer cursor, + int column_index, + ffi.Pointer data, +); + +typedef _c_data_control_bulk_data_get_data = ffi.Int32 Function( + ffi.Pointer bulk_data, + ffi.Int32 idx, + ffi.Pointer> data, +); + +typedef _dart_data_control_bulk_data_get_data = int Function( + ffi.Pointer bulk_data, + int idx, + ffi.Pointer> data, +); + +typedef _c_data_control_bulk_data_get_count = ffi.Int32 Function( + ffi.Pointer bulk_data, + ffi.Pointer count, +); + +typedef _dart_data_control_bulk_data_get_count = int Function( + ffi.Pointer bulk_data, + ffi.Pointer count, +); + +typedef _c_data_control_bulk_data_add = ffi.Int32 Function( + ffi.Pointer bulk_data, + ffi.Pointer data, +); + +typedef _dart_data_control_bulk_data_add = int Function( + ffi.Pointer bulk_data, + ffi.Pointer data, +); + +typedef _c_data_control_bulk_data_create = ffi.Int32 Function( + ffi.Pointer> bulk_data, +); + +typedef _dart_data_control_bulk_data_create = int Function( + ffi.Pointer> bulk_data, +); + +typedef _c_data_control_bulk_data_destroy = ffi.Int32 Function( + ffi.Pointer bulk_data, +); + +typedef _dart_data_control_bulk_data_destroy = int Function( + ffi.Pointer bulk_data, +); + +typedef _c_data_control_bulk_result_data_get_result_data = ffi.Int32 Function( + ffi.Pointer result_data, + ffi.Int32 idx, + ffi.Pointer> data, + ffi.Pointer result, +); + +typedef _dart_data_control_bulk_result_data_get_result_data = int Function( + ffi.Pointer result_data, + int idx, + ffi.Pointer> data, + ffi.Pointer result, +); + +typedef _c_data_control_bulk_result_data_get_count = ffi.Int32 Function( + ffi.Pointer result_data, + ffi.Pointer count, +); + +typedef _dart_data_control_bulk_result_data_get_count = int Function( + ffi.Pointer result_data, + ffi.Pointer count, +); + +typedef _c_data_control_bulk_result_data_add = ffi.Int32 Function( + ffi.Pointer result_data, + ffi.Pointer data, + ffi.Int32 result, +); + +typedef _dart_data_control_bulk_result_data_add = int Function( + ffi.Pointer result_data, + ffi.Pointer data, + int result, +); + +typedef _c_data_control_bulk_result_data_create = ffi.Int32 Function( + ffi.Pointer> result_data, +); + +typedef _dart_data_control_bulk_result_data_create = int Function( + ffi.Pointer> result_data, +); + +typedef _c_data_control_bulk_result_data_destroy = ffi.Int32 Function( + ffi.Pointer result_data, +); + +typedef _dart_data_control_bulk_result_data_destroy = int Function( + ffi.Pointer result_data, +); + +typedef _c_data_control_sql_create = ffi.Int32 Function( + ffi.Pointer> provider, +); + +typedef _dart_data_control_sql_create = int Function( + ffi.Pointer> provider, +); + +typedef _c_data_control_sql_destroy = ffi.Int32 Function( + ffi.Pointer provider, +); + +typedef _dart_data_control_sql_destroy = int Function( + ffi.Pointer provider, +); + +typedef _c_data_control_sql_set_provider_id = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer provider_id, +); + +typedef _dart_data_control_sql_set_provider_id = int Function( + ffi.Pointer provider, + ffi.Pointer provider_id, +); + +typedef _c_data_control_sql_get_provider_id = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer> provider_id, +); + +typedef _dart_data_control_sql_get_provider_id = int Function( + ffi.Pointer provider, + ffi.Pointer> provider_id, +); + +typedef _c_data_control_sql_set_data_id = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer data_id, +); + +typedef _dart_data_control_sql_set_data_id = int Function( + ffi.Pointer provider, + ffi.Pointer data_id, +); + +typedef _c_data_control_sql_get_data_id = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer> data_id, +); + +typedef _dart_data_control_sql_get_data_id = int Function( + ffi.Pointer provider, + ffi.Pointer> data_id, +); + +typedef _c_data_control_sql_register_response_cb = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _dart_data_control_sql_register_response_cb = int Function( + ffi.Pointer provider, + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _c_data_control_sql_unregister_response_cb = ffi.Int32 Function( + ffi.Pointer provider, +); + +typedef _dart_data_control_sql_unregister_response_cb = int Function( + ffi.Pointer provider, +); + +typedef _c_data_control_sql_delete = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer where, + ffi.Pointer request_id, +); + +typedef _dart_data_control_sql_delete = int Function( + ffi.Pointer provider, + ffi.Pointer where, + ffi.Pointer request_id, +); + +typedef _c_data_control_sql_insert = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer insert_data, + ffi.Pointer request_id, +); + +typedef _dart_data_control_sql_insert = int Function( + ffi.Pointer provider, + ffi.Pointer insert_data, + ffi.Pointer request_id, +); + +typedef _c_data_control_sql_select = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer> column_list, + ffi.Int32 column_count, + ffi.Pointer where, + ffi.Pointer order, + ffi.Pointer request_id, +); + +typedef _dart_data_control_sql_select = int Function( + ffi.Pointer provider, + ffi.Pointer> column_list, + int column_count, + ffi.Pointer where, + ffi.Pointer order, + ffi.Pointer request_id, +); + +typedef _c_data_control_sql_select_with_page = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer> column_list, + ffi.Int32 column_count, + ffi.Pointer where, + ffi.Pointer order, + ffi.Int32 page_number, + ffi.Int32 count_per_page, + ffi.Pointer request_id, +); + +typedef _dart_data_control_sql_select_with_page = int Function( + ffi.Pointer provider, + ffi.Pointer> column_list, + int column_count, + ffi.Pointer where, + ffi.Pointer order, + int page_number, + int count_per_page, + ffi.Pointer request_id, +); + +typedef _c_data_control_sql_update = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer update_data, + ffi.Pointer where, + ffi.Pointer request_id, +); + +typedef _dart_data_control_sql_update = int Function( + ffi.Pointer provider, + ffi.Pointer update_data, + ffi.Pointer where, + ffi.Pointer request_id, +); + +typedef _c_data_control_sql_insert_bulk_data = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer bulk_data, + ffi.Pointer request_id, +); + +typedef _dart_data_control_sql_insert_bulk_data = int Function( + ffi.Pointer provider, + ffi.Pointer bulk_data, + ffi.Pointer request_id, +); + +typedef data_control_bulk_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_data_control_sql_register_insert_bulk_data_response_cb = ffi.Int32 + Function( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_data_control_sql_register_insert_bulk_data_response_cb = int + Function( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_data_control_sql_unregister_insert_bulk_data_response_cb = ffi.Int32 + Function( + ffi.Pointer provider, +); + +typedef _dart_data_control_sql_unregister_insert_bulk_data_response_cb = int + Function( + ffi.Pointer provider, +); + +typedef _c_data_control_sql_bind_response_cb = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _dart_data_control_sql_bind_response_cb = int Function( + ffi.Pointer provider, + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _c_data_control_sql_unbind_response_cb = ffi.Int32 Function( + ffi.Pointer provider, +); + +typedef _dart_data_control_sql_unbind_response_cb = int Function( + ffi.Pointer provider, +); + +typedef _c_data_control_sql_bind_insert_bulk_data_response_cb = ffi.Int32 + Function( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_data_control_sql_bind_insert_bulk_data_response_cb = int Function( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_data_control_sql_unbind_insert_bulk_data_response_cb = ffi.Int32 + Function( + ffi.Pointer provider, +); + +typedef _dart_data_control_sql_unbind_insert_bulk_data_response_cb = int + Function( + ffi.Pointer provider, +); + +typedef _c_data_control_sql_get_handle_id = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer handle_id, +); + +typedef _dart_data_control_sql_get_handle_id = int Function( + ffi.Pointer provider, + ffi.Pointer handle_id, +); + +typedef _c_data_control_map_create = ffi.Int32 Function( + ffi.Pointer> provider, +); + +typedef _dart_data_control_map_create = int Function( + ffi.Pointer> provider, +); + +typedef _c_data_control_map_destroy = ffi.Int32 Function( + ffi.Pointer provider, +); + +typedef _dart_data_control_map_destroy = int Function( + ffi.Pointer provider, +); + +typedef _c_data_control_map_set_provider_id = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer provider_id, +); + +typedef _dart_data_control_map_set_provider_id = int Function( + ffi.Pointer provider, + ffi.Pointer provider_id, +); + +typedef _c_data_control_map_get_provider_id = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer> provider_id, +); + +typedef _dart_data_control_map_get_provider_id = int Function( + ffi.Pointer provider, + ffi.Pointer> provider_id, +); + +typedef _c_data_control_map_set_data_id = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer data_id, +); + +typedef _dart_data_control_map_set_data_id = int Function( + ffi.Pointer provider, + ffi.Pointer data_id, +); + +typedef _c_data_control_map_get_data_id = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer> data_id, +); + +typedef _dart_data_control_map_get_data_id = int Function( + ffi.Pointer provider, + ffi.Pointer> data_id, +); + +typedef _c_data_control_map_register_response_cb = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _dart_data_control_map_register_response_cb = int Function( + ffi.Pointer provider, + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _c_data_control_map_unregister_response_cb = ffi.Int32 Function( + ffi.Pointer provider, +); + +typedef _dart_data_control_map_unregister_response_cb = int Function( + ffi.Pointer provider, +); + +typedef _c_data_control_map_get = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer request_id, +); + +typedef _dart_data_control_map_get = int Function( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer request_id, +); + +typedef _c_data_control_map_get_with_page = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer request_id, + ffi.Int32 page_number, + ffi.Int32 count_per_page, +); + +typedef _dart_data_control_map_get_with_page = int Function( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer request_id, + int page_number, + int count_per_page, +); + +typedef _c_data_control_map_set = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer old_value, + ffi.Pointer new_value, + ffi.Pointer request_id, +); + +typedef _dart_data_control_map_set = int Function( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer old_value, + ffi.Pointer new_value, + ffi.Pointer request_id, +); + +typedef _c_data_control_map_add = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer value, + ffi.Pointer request_id, +); + +typedef _dart_data_control_map_add = int Function( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer value, + ffi.Pointer request_id, +); + +typedef _c_data_control_map_remove = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer value, + ffi.Pointer request_id, +); + +typedef _dart_data_control_map_remove = int Function( + ffi.Pointer provider, + ffi.Pointer key, + ffi.Pointer value, + ffi.Pointer request_id, +); + +typedef _c_data_control_map_add_bulk_data = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer bulk_data, + ffi.Pointer request_id, +); + +typedef _dart_data_control_map_add_bulk_data = int Function( + ffi.Pointer provider, + ffi.Pointer bulk_data, + ffi.Pointer request_id, +); + +typedef _c_data_control_map_register_add_bulk_data_response_cb = ffi.Int32 + Function( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_data_control_map_register_add_bulk_data_response_cb = int + Function( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_data_control_map_unregister_add_bulk_data_response_cb = ffi.Int32 + Function( + ffi.Pointer provider, +); + +typedef _dart_data_control_map_unregister_add_bulk_data_response_cb = int + Function( + ffi.Pointer provider, +); + +typedef _c_data_control_map_bind_response_cb = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _dart_data_control_map_bind_response_cb = int Function( + ffi.Pointer provider, + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _c_data_control_map_unbind_response_cb = ffi.Int32 Function( + ffi.Pointer provider, +); + +typedef _dart_data_control_map_unbind_response_cb = int Function( + ffi.Pointer provider, +); + +typedef _c_data_control_map_bind_add_bulk_data_response_cb = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_data_control_map_bind_add_bulk_data_response_cb = int Function( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_data_control_map_unbind_add_bulk_data_response_cb = ffi.Int32 + Function( + ffi.Pointer provider, +); + +typedef _dart_data_control_map_unbind_add_bulk_data_response_cb = int Function( + ffi.Pointer provider, +); + +typedef _c_data_control_map_get_handle_id = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer handle_id, +); + +typedef _dart_data_control_map_get_handle_id = int Function( + ffi.Pointer provider, + ffi.Pointer handle_id, +); + +typedef _c_data_control_provider_sql_register_cb = ffi.Int32 Function( + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _dart_data_control_provider_sql_register_cb = int Function( + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _c_data_control_provider_sql_unregister_cb = ffi.Int32 Function(); + +typedef _dart_data_control_provider_sql_unregister_cb = int Function(); + +typedef _c_data_control_provider_map_register_cb = ffi.Int32 Function( + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _dart_data_control_provider_map_register_cb = int Function( + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _c_data_control_provider_map_unregister_cb = ffi.Int32 Function(); + +typedef _dart_data_control_provider_map_unregister_cb = int Function(); + +typedef _c_data_control_provider_get_client_appid = ffi.Int32 Function( + ffi.Int32 request_id, + ffi.Pointer> appid, +); + +typedef _dart_data_control_provider_get_client_appid = int Function( + int request_id, + ffi.Pointer> appid, +); + +typedef _c_data_control_provider_send_select_result = ffi.Int32 Function( + ffi.Int32 request_id, + ffi.Pointer db_handle, +); + +typedef _dart_data_control_provider_send_select_result = int Function( + int request_id, + ffi.Pointer db_handle, +); + +typedef _c_data_control_provider_send_insert_result = ffi.Int32 Function( + ffi.Int32 request_id, + ffi.Int64 row_id, +); + +typedef _dart_data_control_provider_send_insert_result = int Function( + int request_id, + int row_id, +); + +typedef _c_data_control_provider_send_update_result = ffi.Int32 Function( + ffi.Int32 request_id, +); + +typedef _dart_data_control_provider_send_update_result = int Function( + int request_id, +); + +typedef _c_data_control_provider_send_delete_result = ffi.Int32 Function( + ffi.Int32 request_id, +); + +typedef _dart_data_control_provider_send_delete_result = int Function( + int request_id, +); + +typedef _c_data_control_provider_send_error = ffi.Int32 Function( + ffi.Int32 request_id, + ffi.Pointer error, +); + +typedef _dart_data_control_provider_send_error = int Function( + int request_id, + ffi.Pointer error, +); + +typedef _c_data_control_provider_send_map_result = ffi.Int32 Function( + ffi.Int32 request_id, +); + +typedef _dart_data_control_provider_send_map_result = int Function( + int request_id, +); + +typedef _c_data_control_provider_send_map_get_value_result = ffi.Int32 Function( + ffi.Int32 request_id, + ffi.Pointer> value_list, + ffi.Int32 value_count, +); + +typedef _dart_data_control_provider_send_map_get_value_result = int Function( + int request_id, + ffi.Pointer> value_list, + int value_count, +); + +typedef _c_data_control_provider_create_insert_statement = ffi.Pointer + Function( + ffi.Pointer provider, + ffi.Pointer insert_map, +); + +typedef _dart_data_control_provider_create_insert_statement + = ffi.Pointer Function( + ffi.Pointer provider, + ffi.Pointer insert_map, +); + +typedef _c_data_control_provider_create_delete_statement = ffi.Pointer + Function( + ffi.Pointer provider, + ffi.Pointer where, +); + +typedef _dart_data_control_provider_create_delete_statement + = ffi.Pointer Function( + ffi.Pointer provider, + ffi.Pointer where, +); + +typedef _c_data_control_provider_create_update_statement = ffi.Pointer + Function( + ffi.Pointer provider, + ffi.Pointer update_map, + ffi.Pointer where, +); + +typedef _dart_data_control_provider_create_update_statement + = ffi.Pointer Function( + ffi.Pointer provider, + ffi.Pointer update_map, + ffi.Pointer where, +); + +typedef _c_data_control_provider_create_select_statement = ffi.Pointer + Function( + ffi.Pointer provider, + ffi.Pointer> column_list, + ffi.Int32 column_count, + ffi.Pointer where, + ffi.Pointer order, +); + +typedef _dart_data_control_provider_create_select_statement + = ffi.Pointer Function( + ffi.Pointer provider, + ffi.Pointer> column_list, + int column_count, + ffi.Pointer where, + ffi.Pointer order, +); + +typedef _c_data_control_provider_match_provider_id = ffi.Uint8 Function( + ffi.Pointer provider, + ffi.Pointer provider_id, +); + +typedef _dart_data_control_provider_match_provider_id = int Function( + ffi.Pointer provider, + ffi.Pointer provider_id, +); + +typedef _c_data_control_provider_match_data_id = ffi.Uint8 Function( + ffi.Pointer provider, + ffi.Pointer data_id, +); + +typedef _dart_data_control_provider_match_data_id = int Function( + ffi.Pointer provider, + ffi.Pointer data_id, +); + +typedef _c_data_control_provider_send_data_change_noti = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Int32 type, + ffi.Pointer data, +); + +typedef _dart_data_control_provider_send_data_change_noti = int Function( + ffi.Pointer provider, + int type, + ffi.Pointer data, +); + +typedef data_control_provider_data_change_consumer_filter_cb = ffi.Uint8 + Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_data_control_provider_add_data_change_consumer_filter_cb = ffi.Int32 + Function( + ffi.Pointer< + ffi.NativeFunction< + data_control_provider_data_change_consumer_filter_cb>> + callback, + ffi.Pointer user_data, + ffi.Pointer callback_id, +); + +typedef _dart_data_control_provider_add_data_change_consumer_filter_cb = int + Function( + ffi.Pointer< + ffi.NativeFunction< + data_control_provider_data_change_consumer_filter_cb>> + callback, + ffi.Pointer user_data, + ffi.Pointer callback_id, +); + +typedef _c_data_control_provider_remove_data_change_consumer_filter_cb + = ffi.Int32 Function( + ffi.Int32 callback_id, +); + +typedef _dart_data_control_provider_remove_data_change_consumer_filter_cb = int + Function( + int callback_id, +); + +typedef data_control_provider_data_change_consumer_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_data_control_provider_foreach_data_change_consumer = ffi.Int32 + Function( + ffi.Pointer provider, + ffi.Pointer> + list_cb, + ffi.Pointer user_data, +); + +typedef _dart_data_control_provider_foreach_data_change_consumer = int Function( + ffi.Pointer provider, + ffi.Pointer> + list_cb, + ffi.Pointer user_data, +); + +typedef _c_data_control_provider_send_bulk_insert_result = ffi.Int32 Function( + ffi.Int32 request_id, + ffi.Pointer bulk_results, +); + +typedef _dart_data_control_provider_send_bulk_insert_result = int Function( + int request_id, + ffi.Pointer bulk_results, +); + +typedef _c_data_control_provider_send_map_bulk_add_result = ffi.Int32 Function( + ffi.Int32 request_id, + ffi.Pointer bulk_results, +); + +typedef _dart_data_control_provider_send_map_bulk_add_result = int Function( + int request_id, + ffi.Pointer bulk_results, +); + +typedef data_control_provider_bulk_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_data_control_provider_sql_register_insert_bulk_data_request_cb + = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_data_control_provider_sql_register_insert_bulk_data_request_cb + = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_data_control_provider_sql_unregister_insert_bulk_data_request_cb + = ffi.Int32 Function(); + +typedef _dart_data_control_provider_sql_unregister_insert_bulk_data_request_cb + = int Function(); + +typedef _c_data_control_provider_map_register_add_bulk_data_request_cb + = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_data_control_provider_map_register_add_bulk_data_request_cb = int + Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_data_control_provider_map_unregister_add_bulk_data_request_cb + = ffi.Int32 Function(); + +typedef _dart_data_control_provider_map_unregister_add_bulk_data_request_cb + = int Function(); + +typedef data_control_data_change_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_add_callback_result_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_data_control_add_data_change_cb = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer> + result_callback, + ffi.Pointer result_cb_user_data, + ffi.Pointer callback_id, +); + +typedef _dart_data_control_add_data_change_cb = int Function( + ffi.Pointer provider, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer> + result_callback, + ffi.Pointer result_cb_user_data, + ffi.Pointer callback_id, +); + +typedef _c_data_control_remove_data_change_cb = ffi.Int32 Function( + ffi.Pointer provider, + ffi.Int32 callback_id, +); + +typedef _dart_data_control_remove_data_change_cb = int Function( + ffi.Pointer provider, + int callback_id, +); + +typedef message_port_message_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_message_port_register_local_port = ffi.Int32 Function( + ffi.Pointer local_port, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_message_port_register_local_port = int Function( + ffi.Pointer local_port, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef message_port_trusted_message_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_message_port_register_trusted_local_port = ffi.Int32 Function( + ffi.Pointer trusted_local_port, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_message_port_register_trusted_local_port = int Function( + ffi.Pointer trusted_local_port, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_message_port_unregister_local_port = ffi.Int32 Function( + ffi.Int32 local_port_id, +); + +typedef _dart_message_port_unregister_local_port = int Function( + int local_port_id, +); + +typedef _c_message_port_unregister_trusted_local_port = ffi.Int32 Function( + ffi.Int32 trusted_local_port_id, +); + +typedef _dart_message_port_unregister_trusted_local_port = int Function( + int trusted_local_port_id, +); + +typedef _c_message_port_check_remote_port = ffi.Int32 Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer exist, +); + +typedef _dart_message_port_check_remote_port = int Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer exist, +); + +typedef _c_message_port_check_trusted_remote_port = ffi.Int32 Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer exist, +); + +typedef _dart_message_port_check_trusted_remote_port = int Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer exist, +); + +typedef _c_message_port_send_message = ffi.Int32 Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer message, +); + +typedef _dart_message_port_send_message = int Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer message, +); + +typedef _c_message_port_send_trusted_message = ffi.Int32 Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer message, +); + +typedef _dart_message_port_send_trusted_message = int Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer message, +); + +typedef _c_message_port_send_message_with_local_port = ffi.Int32 Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer message, + ffi.Int32 local_port_id, +); + +typedef _dart_message_port_send_message_with_local_port = int Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer message, + int local_port_id, +); + +typedef _c_message_port_send_trusted_message_with_local_port = ffi.Int32 + Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer message, + ffi.Int32 local_port_id, +); + +typedef _dart_message_port_send_trusted_message_with_local_port = int Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Pointer message, + int local_port_id, +); + +typedef message_port_registration_event_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_message_port_add_registered_cb = ffi.Int32 Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Uint8 trusted_remote_port, + ffi.Pointer> + registered_cb, + ffi.Pointer user_data, + ffi.Pointer watcher_id, +); + +typedef _dart_message_port_add_registered_cb = int Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + int trusted_remote_port, + ffi.Pointer> + registered_cb, + ffi.Pointer user_data, + ffi.Pointer watcher_id, +); + +typedef _c_message_port_add_unregistered_cb = ffi.Int32 Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + ffi.Uint8 trusted_remote_port, + ffi.Pointer> + unregistered_cb, + ffi.Pointer user_data, + ffi.Pointer watcher_id, +); + +typedef _dart_message_port_add_unregistered_cb = int Function( + ffi.Pointer remote_app_id, + ffi.Pointer remote_port, + int trusted_remote_port, + ffi.Pointer> + unregistered_cb, + ffi.Pointer user_data, + ffi.Pointer watcher_id, +); + +typedef _c_message_port_remove_registration_event_cb = ffi.Int32 Function( + ffi.Int32 watcher_id, +); + +typedef _dart_message_port_remove_registration_event_cb = int Function( + int watcher_id, +); + +typedef package_info_app_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_package_info_foreach_app_from_package = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Int32 comp_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_package_info_foreach_app_from_package = int Function( + ffi.Pointer package_info, + int comp_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_package_info_destroy = ffi.Int32 Function( + ffi.Pointer package_info, +); + +typedef _dart_package_info_destroy = int Function( + ffi.Pointer package_info, +); + +typedef _c_package_info_get_package = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer> package, +); + +typedef _dart_package_info_get_package = int Function( + ffi.Pointer package_info, + ffi.Pointer> package, +); + +typedef _c_package_info_get_main_app_id = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer> main_app_id, +); + +typedef _dart_package_info_get_main_app_id = int Function( + ffi.Pointer package_info, + ffi.Pointer> main_app_id, +); + +typedef _c_package_info_get_label = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer> label, +); + +typedef _dart_package_info_get_label = int Function( + ffi.Pointer package_info, + ffi.Pointer> label, +); + +typedef _c_package_info_get_icon = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer> path, +); + +typedef _dart_package_info_get_icon = int Function( + ffi.Pointer package_info, + ffi.Pointer> path, +); + +typedef _c_package_info_get_version = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer> version, +); + +typedef _dart_package_info_get_version = int Function( + ffi.Pointer package_info, + ffi.Pointer> version, +); + +typedef _c_package_info_get_type = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer> type, +); + +typedef _dart_package_info_get_type = int Function( + ffi.Pointer package_info, + ffi.Pointer> type, +); + +typedef _c_package_info_get_installed_storage = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer storage, +); + +typedef _dart_package_info_get_installed_storage = int Function( + ffi.Pointer package_info, + ffi.Pointer storage, +); + +typedef _c_package_info_get_root_path = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer> path, +); + +typedef _dart_package_info_get_root_path = int Function( + ffi.Pointer package_info, + ffi.Pointer> path, +); + +typedef _c_package_info_get_tep_name = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer> name, +); + +typedef _dart_package_info_get_tep_name = int Function( + ffi.Pointer package_info, + ffi.Pointer> name, +); + +typedef _c_package_info_is_system_package = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer system, +); + +typedef _dart_package_info_is_system_package = int Function( + ffi.Pointer package_info, + ffi.Pointer system, +); + +typedef _c_package_info_is_removable_package = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer removable, +); + +typedef _dart_package_info_is_removable_package = int Function( + ffi.Pointer package_info, + ffi.Pointer removable, +); + +typedef _c_package_info_is_preload_package = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer preload, +); + +typedef _dart_package_info_is_preload_package = int Function( + ffi.Pointer package_info, + ffi.Pointer preload, +); + +typedef _c_package_info_is_equal = ffi.Int32 Function( + ffi.Pointer lhs, + ffi.Pointer rhs, + ffi.Pointer equal, +); + +typedef _dart_package_info_is_equal = int Function( + ffi.Pointer lhs, + ffi.Pointer rhs, + ffi.Pointer equal, +); + +typedef _c_package_info_is_accessible = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer accessible, +); + +typedef _dart_package_info_is_accessible = int Function( + ffi.Pointer package_info, + ffi.Pointer accessible, +); + +typedef _c_package_info_get_installed_time = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer installed_time, +); + +typedef _dart_package_info_get_installed_time = int Function( + ffi.Pointer package_info, + ffi.Pointer installed_time, +); + +typedef _c_package_info_clone = ffi.Int32 Function( + ffi.Pointer> clone, + ffi.Pointer package_info, +); + +typedef _dart_package_info_clone = int Function( + ffi.Pointer> clone, + ffi.Pointer package_info, +); + +typedef _c_package_info_create = ffi.Int32 Function( + ffi.Pointer package, + ffi.Pointer> package_info, +); + +typedef _dart_package_info_create = int Function( + ffi.Pointer package, + ffi.Pointer> package_info, +); + +typedef package_info_cert_info_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_package_info_foreach_cert_info = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_package_info_foreach_cert_info = int Function( + ffi.Pointer package_info, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef package_info_privilege_info_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_package_info_foreach_privilege_info = ffi.Int32 Function( + ffi.Pointer package_info, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_package_info_foreach_privilege_info = int Function( + ffi.Pointer package_info, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_package_info_updateinfo_create = ffi.Int32 Function( + ffi.Pointer pkgid, + ffi.Pointer> info, +); + +typedef _dart_package_info_updateinfo_create = int Function( + ffi.Pointer pkgid, + ffi.Pointer> info, +); + +typedef _c_package_info_updateinfo_get_pkgid = ffi.Int32 Function( + ffi.Pointer info, + ffi.Pointer> package, +); + +typedef _dart_package_info_updateinfo_get_pkgid = int Function( + ffi.Pointer info, + ffi.Pointer> package, +); + +typedef _c_package_info_updateinfo_get_version = ffi.Int32 Function( + ffi.Pointer info, + ffi.Pointer> version, +); + +typedef _dart_package_info_updateinfo_get_version = int Function( + ffi.Pointer info, + ffi.Pointer> version, +); + +typedef _c_package_info_updateinfo_get_type = ffi.Int32 Function( + ffi.Pointer info, + ffi.Pointer type, +); + +typedef _dart_package_info_updateinfo_get_type = int Function( + ffi.Pointer info, + ffi.Pointer type, +); + +typedef _c_package_info_updateinfo_destroy = ffi.Int32 Function( + ffi.Pointer info, +); + +typedef _dart_package_info_updateinfo_destroy = int Function( + ffi.Pointer info, +); + +typedef package_info_updateinfo_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_package_info_updateinfo_foreach_info = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_package_info_updateinfo_foreach_info = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_package_manager_create = ffi.Int32 Function( + ffi.Pointer> manager, +); + +typedef _dart_package_manager_create = int Function( + ffi.Pointer> manager, +); + +typedef _c_package_manager_destroy = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_package_manager_destroy = int Function( + ffi.Pointer manager, +); + +typedef _c_package_manager_set_event_status = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Int32 status_type, +); + +typedef _dart_package_manager_set_event_status = int Function( + ffi.Pointer manager, + int status_type, +); + +typedef package_manager_event_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_package_manager_set_event_cb = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_package_manager_set_event_cb = int Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_package_manager_unset_event_cb = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_package_manager_unset_event_cb = int Function( + ffi.Pointer manager, +); + +typedef package_manager_package_info_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_package_manager_foreach_package_info = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_package_manager_foreach_package_info = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_package_manager_get_package_id_by_app_id = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer> package_id, +); + +typedef _dart_package_manager_get_package_id_by_app_id = int Function( + ffi.Pointer app_id, + ffi.Pointer> package_id, +); + +typedef _c_package_manager_get_package_info = ffi.Int32 Function( + ffi.Pointer package_id, + ffi.Pointer> package_info, +); + +typedef _dart_package_manager_get_package_info = int Function( + ffi.Pointer package_id, + ffi.Pointer> package_info, +); + +typedef _c_package_manager_compare_package_cert_info = ffi.Int32 Function( + ffi.Pointer lhs_package_id, + ffi.Pointer rhs_package_id, + ffi.Pointer compare_result, +); + +typedef _dart_package_manager_compare_package_cert_info = int Function( + ffi.Pointer lhs_package_id, + ffi.Pointer rhs_package_id, + ffi.Pointer compare_result, +); + +typedef _c_package_manager_compare_app_cert_info = ffi.Int32 Function( + ffi.Pointer lhs_app_id, + ffi.Pointer rhs_app_id, + ffi.Pointer compare_result, +); + +typedef _dart_package_manager_compare_app_cert_info = int Function( + ffi.Pointer lhs_app_id, + ffi.Pointer rhs_app_id, + ffi.Pointer compare_result, +); + +typedef _c_package_manager_is_preload_package_by_app_id = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer preload, +); + +typedef _dart_package_manager_is_preload_package_by_app_id = int Function( + ffi.Pointer app_id, + ffi.Pointer preload, +); + +typedef _c_package_manager_get_permission_type = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer permission_type, +); + +typedef _dart_package_manager_get_permission_type = int Function( + ffi.Pointer app_id, + ffi.Pointer permission_type, +); + +typedef _c_package_manager_clear_cache_dir = ffi.Int32 Function( + ffi.Pointer package_id, +); + +typedef _dart_package_manager_clear_cache_dir = int Function( + ffi.Pointer package_id, +); + +typedef _c_package_manager_clear_all_cache_dir = ffi.Int32 Function(); + +typedef _dart_package_manager_clear_all_cache_dir = int Function(); + +typedef _c_package_manager_clear_data_dir = ffi.Int32 Function( + ffi.Pointer package_id, +); + +typedef _dart_package_manager_clear_data_dir = int Function( + ffi.Pointer package_id, +); + +typedef package_manager_size_info_receive_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_package_manager_get_package_size_info = ffi.Int32 Function( + ffi.Pointer package_id, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_package_manager_get_package_size_info = int Function( + ffi.Pointer package_id, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef package_manager_total_size_info_receive_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_package_manager_get_total_package_size_info = ffi.Int32 Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_package_manager_get_total_package_size_info = int Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_package_manager_filter_create = ffi.Int32 Function( + ffi.Pointer> handle, +); + +typedef _dart_package_manager_filter_create = int Function( + ffi.Pointer> handle, +); + +typedef _c_package_manager_filter_destroy = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_package_manager_filter_destroy = int Function( + ffi.Pointer handle, +); + +typedef _c_package_manager_filter_add_bool = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer property, + ffi.Uint8 value, +); + +typedef _dart_package_manager_filter_add_bool = int Function( + ffi.Pointer handle, + ffi.Pointer property, + int value, +); + +typedef _c_package_manager_filter_count = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer count, +); + +typedef _dart_package_manager_filter_count = int Function( + ffi.Pointer handle, + ffi.Pointer count, +); + +typedef _c_package_manager_filter_foreach_package_info = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_package_manager_filter_foreach_package_info = int Function( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_package_manager_drm_generate_license_request = ffi.Int32 Function( + ffi.Pointer resp_data, + ffi.Pointer> req_data, + ffi.Pointer> license_url, +); + +typedef _dart_package_manager_drm_generate_license_request = int Function( + ffi.Pointer resp_data, + ffi.Pointer> req_data, + ffi.Pointer> license_url, +); + +typedef _c_package_manager_drm_register_license = ffi.Int32 Function( + ffi.Pointer resp_data, +); + +typedef _dart_package_manager_drm_register_license = int Function( + ffi.Pointer resp_data, +); + +typedef _c_package_manager_drm_decrypt_package = ffi.Int32 Function( + ffi.Pointer drm_file_path, + ffi.Pointer decrypted_file_path, +); + +typedef _dart_package_manager_drm_decrypt_package = int Function( + ffi.Pointer drm_file_path, + ffi.Pointer decrypted_file_path, +); + +typedef _c_package_size_info_get_data_size = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer data_size, +); + +typedef _dart_package_size_info_get_data_size = int Function( + ffi.Pointer handle, + ffi.Pointer data_size, +); + +typedef _c_package_size_info_get_cache_size = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer cache_size, +); + +typedef _dart_package_size_info_get_cache_size = int Function( + ffi.Pointer handle, + ffi.Pointer cache_size, +); + +typedef _c_package_size_info_get_app_size = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer app_size, +); + +typedef _dart_package_size_info_get_app_size = int Function( + ffi.Pointer handle, + ffi.Pointer app_size, +); + +typedef _c_package_size_info_get_external_data_size = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer ext_data_size, +); + +typedef _dart_package_size_info_get_external_data_size = int Function( + ffi.Pointer handle, + ffi.Pointer ext_data_size, +); + +typedef _c_package_size_info_get_external_cache_size = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer ext_cache_size, +); + +typedef _dart_package_size_info_get_external_cache_size = int Function( + ffi.Pointer handle, + ffi.Pointer ext_cache_size, +); + +typedef _c_package_size_info_get_external_app_size = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer ext_app_size, +); + +typedef _dart_package_size_info_get_external_app_size = int Function( + ffi.Pointer handle, + ffi.Pointer ext_app_size, +); + +typedef _c_package_manager_request_create = ffi.Int32 Function( + ffi.Pointer> request, +); + +typedef _dart_package_manager_request_create = int Function( + ffi.Pointer> request, +); + +typedef _c_package_manager_request_destroy = ffi.Int32 Function( + ffi.Pointer request, +); + +typedef _dart_package_manager_request_destroy = int Function( + ffi.Pointer request, +); + +typedef package_manager_request_event_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_package_manager_request_set_event_cb = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_package_manager_request_set_event_cb = int Function( + ffi.Pointer request, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_package_manager_request_unset_event_cb = ffi.Int32 Function( + ffi.Pointer request, +); + +typedef _dart_package_manager_request_unset_event_cb = int Function( + ffi.Pointer request, +); + +typedef _c_package_manager_request_set_type = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer type, +); + +typedef _dart_package_manager_request_set_type = int Function( + ffi.Pointer request, + ffi.Pointer type, +); + +typedef _c_package_manager_request_set_mode = ffi.Int32 Function( + ffi.Pointer request, + ffi.Int32 mode, +); + +typedef _dart_package_manager_request_set_mode = int Function( + ffi.Pointer request, + int mode, +); + +typedef _c_package_manager_request_set_tep = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer tep_path, +); + +typedef _dart_package_manager_request_set_tep = int Function( + ffi.Pointer request, + ffi.Pointer tep_path, +); + +typedef _c_package_manager_request_install = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer path, + ffi.Pointer id, +); + +typedef _dart_package_manager_request_install = int Function( + ffi.Pointer request, + ffi.Pointer path, + ffi.Pointer id, +); + +typedef _c_package_manager_request_install_with_cb = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer path, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _dart_package_manager_request_install_with_cb = int Function( + ffi.Pointer request, + ffi.Pointer path, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _c_package_manager_request_uninstall = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer name, + ffi.Pointer id, +); + +typedef _dart_package_manager_request_uninstall = int Function( + ffi.Pointer request, + ffi.Pointer name, + ffi.Pointer id, +); + +typedef _c_package_manager_request_uninstall_with_cb = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer name, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _dart_package_manager_request_uninstall_with_cb = int Function( + ffi.Pointer request, + ffi.Pointer name, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _c_package_manager_request_move = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer name, + ffi.Int32 move_type, +); + +typedef _dart_package_manager_request_move = int Function( + ffi.Pointer request, + ffi.Pointer name, + int move_type, +); + +typedef _c_package_manager_request_move_with_cb = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer name, + ffi.Int32 move_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _dart_package_manager_request_move_with_cb = int Function( + ffi.Pointer request, + ffi.Pointer name, + int move_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _c_package_manager_updateinfo_request_create = ffi.Int32 Function( + ffi.Pointer> pkg_updateinfo_req, +); + +typedef _dart_package_manager_updateinfo_request_create = int Function( + ffi.Pointer> pkg_updateinfo_req, +); + +typedef _c_package_manager_updateinfo_set_pkgid = ffi.Int32 Function( + ffi.Pointer pkg_updateinfo_req, + ffi.Pointer pkgid, +); + +typedef _dart_package_manager_updateinfo_set_pkgid = int Function( + ffi.Pointer pkg_updateinfo_req, + ffi.Pointer pkgid, +); + +typedef _c_package_manager_updateinfo_set_version = ffi.Int32 Function( + ffi.Pointer pkg_updateinfo_req, + ffi.Pointer version, +); + +typedef _dart_package_manager_updateinfo_set_version = int Function( + ffi.Pointer pkg_updateinfo_req, + ffi.Pointer version, +); + +typedef _c_package_manager_updateinfo_set_type = ffi.Int32 Function( + ffi.Pointer pkg_updateinfo_req, + ffi.Int32 type, +); + +typedef _dart_package_manager_updateinfo_set_type = int Function( + ffi.Pointer pkg_updateinfo_req, + int type, +); + +typedef _c_package_manager_updateinfo_request_register = ffi.Int32 Function( + ffi.Pointer pkg_updateinfo_req, +); + +typedef _dart_package_manager_updateinfo_request_register = int Function( + ffi.Pointer pkg_updateinfo_req, +); + +typedef _c_package_manager_updateinfo_request_destroy = ffi.Int32 Function( + ffi.Pointer pkg_updateinfo_req, +); + +typedef _dart_package_manager_updateinfo_request_destroy = int Function( + ffi.Pointer pkg_updateinfo_req, +); + +typedef _c_package_manager_updateinfo_request_unregister = ffi.Int32 Function( + ffi.Pointer pkg_updateinfo_req, + ffi.Pointer pkgid, +); + +typedef _dart_package_manager_updateinfo_request_unregister = int Function( + ffi.Pointer pkg_updateinfo_req, + ffi.Pointer pkgid, +); + +typedef _c_package_manager_updateinfo_request_unregister_all = ffi.Int32 + Function( + ffi.Pointer pkg_updateinfo_req, +); + +typedef _dart_package_manager_updateinfo_request_unregister_all = int Function( + ffi.Pointer pkg_updateinfo_req, +); + +typedef _c_package_archive_info_create = ffi.Int32 Function( + ffi.Pointer path, + ffi.Pointer> archive_info, +); + +typedef _dart_package_archive_info_create = int Function( + ffi.Pointer path, + ffi.Pointer> archive_info, +); + +typedef _c_package_archive_info_destroy = ffi.Int32 Function( + ffi.Pointer archive_info, +); + +typedef _dart_package_archive_info_destroy = int Function( + ffi.Pointer archive_info, +); + +typedef _c_package_archive_info_get_package = ffi.Int32 Function( + ffi.Pointer archive_info, + ffi.Pointer> package, +); + +typedef _dart_package_archive_info_get_package = int Function( + ffi.Pointer archive_info, + ffi.Pointer> package, +); + +typedef _c_package_archive_info_get_type = ffi.Int32 Function( + ffi.Pointer archive_info, + ffi.Pointer> type, +); + +typedef _dart_package_archive_info_get_type = int Function( + ffi.Pointer archive_info, + ffi.Pointer> type, +); + +typedef _c_package_archive_info_get_version = ffi.Int32 Function( + ffi.Pointer archive_info, + ffi.Pointer> version, +); + +typedef _dart_package_archive_info_get_version = int Function( + ffi.Pointer archive_info, + ffi.Pointer> version, +); + +typedef _c_package_archive_info_get_api_version = ffi.Int32 Function( + ffi.Pointer archive_info, + ffi.Pointer> api_version, +); + +typedef _dart_package_archive_info_get_api_version = int Function( + ffi.Pointer archive_info, + ffi.Pointer> api_version, +); + +typedef _c_package_archive_info_get_description = ffi.Int32 Function( + ffi.Pointer archive_info, + ffi.Pointer> description, +); + +typedef _dart_package_archive_info_get_description = int Function( + ffi.Pointer archive_info, + ffi.Pointer> description, +); + +typedef _c_package_archive_info_get_label = ffi.Int32 Function( + ffi.Pointer archive_info, + ffi.Pointer> label, +); + +typedef _dart_package_archive_info_get_label = int Function( + ffi.Pointer archive_info, + ffi.Pointer> label, +); + +typedef _c_package_archive_info_get_author = ffi.Int32 Function( + ffi.Pointer archive_info, + ffi.Pointer> author, +); + +typedef _dart_package_archive_info_get_author = int Function( + ffi.Pointer archive_info, + ffi.Pointer> author, +); + +typedef _c_package_archive_info_get_icon = ffi.Int32 Function( + ffi.Pointer archive_info, + ffi.Pointer> icon, + ffi.Pointer icon_size, +); + +typedef _dart_package_archive_info_get_icon = int Function( + ffi.Pointer archive_info, + ffi.Pointer> icon, + ffi.Pointer icon_size, +); + +typedef _c_service_app_add_event_handler = ffi.Int32 Function( + ffi.Pointer> handler, + ffi.Int32 event_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_service_app_add_event_handler = int Function( + ffi.Pointer> handler, + int event_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_service_app_remove_event_handler = ffi.Int32 Function( + ffi.Pointer event_handler, +); + +typedef _dart_service_app_remove_event_handler = int Function( + ffi.Pointer event_handler, +); + +typedef _c_service_app_main = ffi.Int32 Function( + ffi.Int32 argc, + ffi.Pointer> argv, + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _dart_service_app_main = int Function( + int argc, + ffi.Pointer> argv, + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _c_service_app_exit = ffi.Void Function(); + +typedef _dart_service_app_exit = void Function(); + +typedef _c_watch_app_add_event_handler = ffi.Int32 Function( + ffi.Pointer> handler, + ffi.Int32 event_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_watch_app_add_event_handler = int Function( + ffi.Pointer> handler, + int event_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_watch_app_remove_event_handler = ffi.Int32 Function( + ffi.Pointer event_handler, +); + +typedef _dart_watch_app_remove_event_handler = int Function( + ffi.Pointer event_handler, +); + +typedef _c_watch_app_main = ffi.Int32 Function( + ffi.Int32 argc, + ffi.Pointer> argv, + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _dart_watch_app_main = int Function( + int argc, + ffi.Pointer> argv, + ffi.Pointer callback, + ffi.Pointer user_data, +); + +typedef _c_watch_app_exit = ffi.Void Function(); + +typedef _dart_watch_app_exit = void Function(); + +typedef _c_watch_app_set_time_tick_frequency = ffi.Int32 Function( + ffi.Int32 ticks, + ffi.Int32 type, +); + +typedef _dart_watch_app_set_time_tick_frequency = int Function( + int ticks, + int type, +); + +typedef _c_watch_app_get_time_tick_frequency = ffi.Int32 Function( + ffi.Pointer ticks, + ffi.Pointer type, +); + +typedef _dart_watch_app_get_time_tick_frequency = int Function( + ffi.Pointer ticks, + ffi.Pointer type, +); + +typedef _c_watch_app_set_ambient_tick_type = ffi.Int32 Function( + ffi.Int32 type, +); + +typedef _dart_watch_app_set_ambient_tick_type = int Function( + int type, +); + +typedef _c_watch_app_get_ambient_tick_type = ffi.Int32 Function( + ffi.Pointer type, +); + +typedef _dart_watch_app_get_ambient_tick_type = int Function( + ffi.Pointer type, +); + +typedef _c_watch_time_get_current_time = ffi.Int32 Function( + ffi.Pointer> watch_time, +); + +typedef _dart_watch_time_get_current_time = int Function( + ffi.Pointer> watch_time, +); + +typedef _c_watch_time_delete = ffi.Int32 Function( + ffi.Pointer<_watch_time_s> watch_time, +); + +typedef _dart_watch_time_delete = int Function( + ffi.Pointer<_watch_time_s> watch_time, +); + +typedef _c_watch_time_get_year = ffi.Int32 Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer year, +); + +typedef _dart_watch_time_get_year = int Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer year, +); + +typedef _c_watch_time_get_month = ffi.Int32 Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer month, +); + +typedef _dart_watch_time_get_month = int Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer month, +); + +typedef _c_watch_time_get_day = ffi.Int32 Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer day, +); + +typedef _dart_watch_time_get_day = int Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer day, +); + +typedef _c_watch_time_get_day_of_week = ffi.Int32 Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer day_of_week, +); + +typedef _dart_watch_time_get_day_of_week = int Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer day_of_week, +); + +typedef _c_watch_time_get_hour = ffi.Int32 Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer hour, +); + +typedef _dart_watch_time_get_hour = int Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer hour, +); + +typedef _c_watch_time_get_hour24 = ffi.Int32 Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer hour24, +); + +typedef _dart_watch_time_get_hour24 = int Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer hour24, +); + +typedef _c_watch_time_get_minute = ffi.Int32 Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer minute, +); + +typedef _dart_watch_time_get_minute = int Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer minute, +); + +typedef _c_watch_time_get_second = ffi.Int32 Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer second, +); + +typedef _dart_watch_time_get_second = int Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer second, +); + +typedef _c_watch_time_get_millisecond = ffi.Int32 Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer millisecond, +); + +typedef _dart_watch_time_get_millisecond = int Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer millisecond, +); + +typedef _c_watch_time_get_utc_time = ffi.Int32 Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer utc_time, +); + +typedef _dart_watch_time_get_utc_time = int Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer utc_time, +); + +typedef _c_watch_time_get_utc_timestamp = ffi.Int32 Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer utc_timestamp, +); + +typedef _dart_watch_time_get_utc_timestamp = int Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer utc_timestamp, +); + +typedef _c_watch_time_get_time_zone = ffi.Int32 Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer> time_zone_id, +); + +typedef _dart_watch_time_get_time_zone = int Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer> time_zone_id, +); + +typedef _c_watch_time_get_dst_status = ffi.Int32 Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer status, +); + +typedef _dart_watch_time_get_dst_status = int Function( + ffi.Pointer<_watch_time_s> watch_time, + ffi.Pointer status, +); + +typedef _c_watch_app_get_elm_win = ffi.Int32 Function( + ffi.Pointer> win, +); + +typedef _dart_watch_app_get_elm_win = int Function( + ffi.Pointer> win, +); + +typedef _c_widget_viewer_evas_init = ffi.Int32 Function( + ffi.Pointer win, +); + +typedef _dart_widget_viewer_evas_init = int Function( + ffi.Pointer win, +); + +typedef _c_widget_viewer_evas_fini = ffi.Int32 Function(); + +typedef _dart_widget_viewer_evas_fini = int Function(); + +typedef _c_widget_viewer_evas_add_widget = ffi.Pointer Function( + ffi.Pointer parent, + ffi.Pointer widget_id, + ffi.Pointer content_info, + ffi.Double period, +); + +typedef _dart_widget_viewer_evas_add_widget = ffi.Pointer Function( + ffi.Pointer parent, + ffi.Pointer widget_id, + ffi.Pointer content_info, + double period, +); + +typedef _c_widget_viewer_evas_notify_resumed_status_of_viewer = ffi.Int32 + Function(); + +typedef _dart_widget_viewer_evas_notify_resumed_status_of_viewer = int + Function(); + +typedef _c_widget_viewer_evas_notify_paused_status_of_viewer = ffi.Int32 + Function(); + +typedef _dart_widget_viewer_evas_notify_paused_status_of_viewer = int + Function(); + +typedef _c_widget_viewer_evas_notify_orientation_of_viewer = ffi.Int32 Function( + ffi.Int32 orientation, +); + +typedef _dart_widget_viewer_evas_notify_orientation_of_viewer = int Function( + int orientation, +); + +typedef _c_widget_viewer_evas_pause_widget = ffi.Int32 Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_pause_widget = int Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_resume_widget = ffi.Int32 Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_resume_widget = int Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_set_option = ffi.Int32 Function( + ffi.Int32 type, + ffi.Int32 value, +); + +typedef _dart_widget_viewer_evas_set_option = int Function( + int type, + int value, +); + +typedef _c_widget_viewer_evas_get_content_info = ffi.Pointer Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_get_content_info = ffi.Pointer + Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_get_title_string = ffi.Pointer Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_get_title_string = ffi.Pointer + Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_get_widget_id = ffi.Pointer Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_get_widget_id = ffi.Pointer Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_get_period = ffi.Double Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_get_period = double Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_cancel_click_event = ffi.Void Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_cancel_click_event = void Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_disable_preview = ffi.Void Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_disable_preview = void Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_disable_overlay_text = ffi.Void Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_disable_overlay_text = void Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_disable_loading = ffi.Void Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_disable_loading = void Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_feed_mouse_up_event = ffi.Int32 Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_feed_mouse_up_event = int Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_activate_faulted_widget = ffi.Void Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_activate_faulted_widget = void Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_is_faulted = ffi.Uint8 Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_is_faulted = int Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_freeze_visibility = ffi.Int32 Function( + ffi.Pointer widget, + ffi.Int32 status, +); + +typedef _dart_widget_viewer_evas_freeze_visibility = int Function( + ffi.Pointer widget, + int status, +); + +typedef _c_widget_viewer_evas_thaw_visibility = ffi.Int32 Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_thaw_visibility = int Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_is_visibility_frozen = ffi.Uint8 Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_is_visibility_frozen = int Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_is_widget = ffi.Uint8 Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_is_widget = int Function( + ffi.Pointer widget, +); + +typedef _c_widget_viewer_evas_set_permanent_delete = ffi.Void Function( + ffi.Pointer widget, + ffi.Int32 flag, +); + +typedef _dart_widget_viewer_evas_set_permanent_delete = void Function( + ffi.Pointer widget, + int flag, +); + +typedef _c_widget_viewer_evas_get_widget_instance_id = ffi.Pointer + Function( + ffi.Pointer widget, +); + +typedef _dart_widget_viewer_evas_get_widget_instance_id = ffi.Pointer + Function( + ffi.Pointer widget, +); + +typedef _c_mime_type_get_mime_type = ffi.Int32 Function( + ffi.Pointer file_extension, + ffi.Pointer> mime_type, +); + +typedef _dart_mime_type_get_mime_type = int Function( + ffi.Pointer file_extension, + ffi.Pointer> mime_type, +); + +typedef _c_mime_type_get_file_extension = ffi.Int32 Function( + ffi.Pointer mime_type, + ffi.Pointer>> file_extension, + ffi.Pointer length, +); + +typedef _dart_mime_type_get_file_extension = int Function( + ffi.Pointer mime_type, + ffi.Pointer>> file_extension, + ffi.Pointer length, +); + +typedef _c_mime_type_get_mime_type_for_data = ffi.Int32 Function( + ffi.Pointer data, + ffi.Int32 len, + ffi.Pointer> mime_type, +); + +typedef _dart_mime_type_get_mime_type_for_data = int Function( + ffi.Pointer data, + int len, + ffi.Pointer> mime_type, +); + +typedef _c_mime_type_get_mime_type_for_file = ffi.Int32 Function( + ffi.Pointer file_path, + ffi.Pointer> mime_type, +); + +typedef _dart_mime_type_get_mime_type_for_file = int Function( + ffi.Pointer file_path, + ffi.Pointer> mime_type, +); + +typedef _c_audio_meta_clone = ffi.Int32 Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _dart_audio_meta_clone = int Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _c_audio_meta_destroy = ffi.Int32 Function( + ffi.Pointer audio, +); + +typedef _dart_audio_meta_destroy = int Function( + ffi.Pointer audio, +); + +typedef _c_audio_meta_get_media_id = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer> media_id, +); + +typedef _dart_audio_meta_get_media_id = int Function( + ffi.Pointer audio, + ffi.Pointer> media_id, +); + +typedef _c_audio_meta_get_album = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer> album, +); + +typedef _dart_audio_meta_get_album = int Function( + ffi.Pointer audio, + ffi.Pointer> album, +); + +typedef _c_audio_meta_get_artist = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer> artist, +); + +typedef _dart_audio_meta_get_artist = int Function( + ffi.Pointer audio, + ffi.Pointer> artist, +); + +typedef _c_audio_meta_get_album_artist = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer> album_artist, +); + +typedef _dart_audio_meta_get_album_artist = int Function( + ffi.Pointer audio, + ffi.Pointer> album_artist, +); + +typedef _c_audio_meta_get_genre = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer> genre, +); + +typedef _dart_audio_meta_get_genre = int Function( + ffi.Pointer audio, + ffi.Pointer> genre, +); + +typedef _c_audio_meta_get_composer = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer> composer, +); + +typedef _dart_audio_meta_get_composer = int Function( + ffi.Pointer audio, + ffi.Pointer> composer, +); + +typedef _c_audio_meta_get_year = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer> year, +); + +typedef _dart_audio_meta_get_year = int Function( + ffi.Pointer audio, + ffi.Pointer> year, +); + +typedef _c_audio_meta_get_recorded_date = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer> recorded_date, +); + +typedef _dart_audio_meta_get_recorded_date = int Function( + ffi.Pointer audio, + ffi.Pointer> recorded_date, +); + +typedef _c_audio_meta_get_copyright = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer> copyright, +); + +typedef _dart_audio_meta_get_copyright = int Function( + ffi.Pointer audio, + ffi.Pointer> copyright, +); + +typedef _c_audio_meta_get_track_num = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer> track_num, +); + +typedef _dart_audio_meta_get_track_num = int Function( + ffi.Pointer audio, + ffi.Pointer> track_num, +); + +typedef _c_audio_meta_get_bit_rate = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer bit_rate, +); + +typedef _dart_audio_meta_get_bit_rate = int Function( + ffi.Pointer audio, + ffi.Pointer bit_rate, +); + +typedef _c_audio_meta_get_bitpersample = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer bitpersample, +); + +typedef _dart_audio_meta_get_bitpersample = int Function( + ffi.Pointer audio, + ffi.Pointer bitpersample, +); + +typedef _c_audio_meta_get_sample_rate = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer sample_rate, +); + +typedef _dart_audio_meta_get_sample_rate = int Function( + ffi.Pointer audio, + ffi.Pointer sample_rate, +); + +typedef _c_audio_meta_get_channel = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer channel, +); + +typedef _dart_audio_meta_get_channel = int Function( + ffi.Pointer audio, + ffi.Pointer channel, +); + +typedef _c_audio_meta_get_duration = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer duration, +); + +typedef _dart_audio_meta_get_duration = int Function( + ffi.Pointer audio, + ffi.Pointer duration, +); + +typedef _c_audio_meta_get_played_count = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer played_count, +); + +typedef _dart_audio_meta_get_played_count = int Function( + ffi.Pointer audio, + ffi.Pointer played_count, +); + +typedef _c_audio_meta_get_played_time = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer played_time, +); + +typedef _dart_audio_meta_get_played_time = int Function( + ffi.Pointer audio, + ffi.Pointer played_time, +); + +typedef _c_audio_meta_get_played_position = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Pointer played_position, +); + +typedef _dart_audio_meta_get_played_position = int Function( + ffi.Pointer audio, + ffi.Pointer played_position, +); + +typedef _c_audio_meta_set_played_count = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Int32 played_count, +); + +typedef _dart_audio_meta_set_played_count = int Function( + ffi.Pointer audio, + int played_count, +); + +typedef _c_audio_meta_set_played_time = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Int64 played_time, +); + +typedef _dart_audio_meta_set_played_time = int Function( + ffi.Pointer audio, + int played_time, +); + +typedef _c_audio_meta_set_played_position = ffi.Int32 Function( + ffi.Pointer audio, + ffi.Int32 played_position, +); + +typedef _dart_audio_meta_set_played_position = int Function( + ffi.Pointer audio, + int played_position, +); + +typedef _c_audio_meta_update_to_db = ffi.Int32 Function( + ffi.Pointer audio, +); + +typedef _dart_audio_meta_update_to_db = int Function( + ffi.Pointer audio, +); + +typedef _c_media_filter_create = ffi.Int32 Function( + ffi.Pointer> filter, +); + +typedef _dart_media_filter_create = int Function( + ffi.Pointer> filter, +); + +typedef _c_media_filter_destroy = ffi.Int32 Function( + ffi.Pointer filter, +); + +typedef _dart_media_filter_destroy = int Function( + ffi.Pointer filter, +); + +typedef _c_media_filter_set_offset = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Int32 offset, + ffi.Int32 count, +); + +typedef _dart_media_filter_set_offset = int Function( + ffi.Pointer filter, + int offset, + int count, +); + +typedef _c_media_filter_set_condition = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer condition, + ffi.Int32 collate_type, +); + +typedef _dart_media_filter_set_condition = int Function( + ffi.Pointer filter, + ffi.Pointer condition, + int collate_type, +); + +typedef _c_media_filter_set_order = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Int32 order_type, + ffi.Pointer order_keyword, + ffi.Int32 collate_type, +); + +typedef _dart_media_filter_set_order = int Function( + ffi.Pointer filter, + int order_type, + ffi.Pointer order_keyword, + int collate_type, +); + +typedef _c_media_filter_set_storage = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer storage_id, +); + +typedef _dart_media_filter_set_storage = int Function( + ffi.Pointer filter, + ffi.Pointer storage_id, +); + +typedef _c_media_filter_get_offset = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer offset, + ffi.Pointer count, +); + +typedef _dart_media_filter_get_offset = int Function( + ffi.Pointer filter, + ffi.Pointer offset, + ffi.Pointer count, +); + +typedef _c_media_filter_get_condition = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> condition, + ffi.Pointer collate_type, +); + +typedef _dart_media_filter_get_condition = int Function( + ffi.Pointer filter, + ffi.Pointer> condition, + ffi.Pointer collate_type, +); + +typedef _c_media_filter_get_order = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer order_type, + ffi.Pointer> order_keyword, + ffi.Pointer collate_type, +); + +typedef _dart_media_filter_get_order = int Function( + ffi.Pointer filter, + ffi.Pointer order_type, + ffi.Pointer> order_keyword, + ffi.Pointer collate_type, +); + +typedef _c_media_filter_get_storage = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> storage_id, +); + +typedef _dart_media_filter_get_storage = int Function( + ffi.Pointer filter, + ffi.Pointer> storage_id, +); + +typedef _c_media_folder_get_folder_count_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer folder_count, +); + +typedef _dart_media_folder_get_folder_count_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer folder_count, +); + +typedef media_folder_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_media_folder_foreach_folder_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_folder_foreach_folder_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_folder_get_media_count_from_db = ffi.Int32 Function( + ffi.Pointer folder_id, + ffi.Pointer filter, + ffi.Pointer media_count, +); + +typedef _dart_media_folder_get_media_count_from_db = int Function( + ffi.Pointer folder_id, + ffi.Pointer filter, + ffi.Pointer media_count, +); + +typedef media_info_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_media_folder_foreach_media_from_db = ffi.Int32 Function( + ffi.Pointer folder_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_folder_foreach_media_from_db = int Function( + ffi.Pointer folder_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_folder_clone = ffi.Int32 Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _dart_media_folder_clone = int Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _c_media_folder_destroy = ffi.Int32 Function( + ffi.Pointer folder, +); + +typedef _dart_media_folder_destroy = int Function( + ffi.Pointer folder, +); + +typedef _c_media_folder_get_folder_id = ffi.Int32 Function( + ffi.Pointer folder, + ffi.Pointer> folder_id, +); + +typedef _dart_media_folder_get_folder_id = int Function( + ffi.Pointer folder, + ffi.Pointer> folder_id, +); + +typedef _c_media_folder_get_parent_folder_id = ffi.Int32 Function( + ffi.Pointer folder, + ffi.Pointer> parent_folder_id, +); + +typedef _dart_media_folder_get_parent_folder_id = int Function( + ffi.Pointer folder, + ffi.Pointer> parent_folder_id, +); + +typedef _c_media_folder_get_path = ffi.Int32 Function( + ffi.Pointer folder, + ffi.Pointer> path, +); + +typedef _dart_media_folder_get_path = int Function( + ffi.Pointer folder, + ffi.Pointer> path, +); + +typedef _c_media_folder_get_name = ffi.Int32 Function( + ffi.Pointer folder, + ffi.Pointer> folder_name, +); + +typedef _dart_media_folder_get_name = int Function( + ffi.Pointer folder, + ffi.Pointer> folder_name, +); + +typedef _c_media_folder_get_modified_time = ffi.Int32 Function( + ffi.Pointer folder, + ffi.Pointer date, +); + +typedef _dart_media_folder_get_modified_time = int Function( + ffi.Pointer folder, + ffi.Pointer date, +); + +typedef _c_media_folder_get_storage_type = ffi.Int32 Function( + ffi.Pointer folder, + ffi.Pointer storage_type, +); + +typedef _dart_media_folder_get_storage_type = int Function( + ffi.Pointer folder, + ffi.Pointer storage_type, +); + +typedef _c_media_folder_get_storage_id = ffi.Int32 Function( + ffi.Pointer folder, + ffi.Pointer> storage_id, +); + +typedef _dart_media_folder_get_storage_id = int Function( + ffi.Pointer folder, + ffi.Pointer> storage_id, +); + +typedef _c_media_folder_get_order = ffi.Int32 Function( + ffi.Pointer folder, + ffi.Pointer order, +); + +typedef _dart_media_folder_get_order = int Function( + ffi.Pointer folder, + ffi.Pointer order, +); + +typedef _c_media_folder_get_folder_from_db = ffi.Int32 Function( + ffi.Pointer folder_id, + ffi.Pointer> folder, +); + +typedef _dart_media_folder_get_folder_from_db = int Function( + ffi.Pointer folder_id, + ffi.Pointer> folder, +); + +typedef _c_media_folder_set_name = ffi.Int32 Function( + ffi.Pointer folder, + ffi.Pointer name, +); + +typedef _dart_media_folder_set_name = int Function( + ffi.Pointer folder, + ffi.Pointer name, +); + +typedef _c_media_folder_set_order = ffi.Int32 Function( + ffi.Pointer folder, + ffi.Int32 order, +); + +typedef _dart_media_folder_set_order = int Function( + ffi.Pointer folder, + int order, +); + +typedef _c_media_folder_update_to_db = ffi.Int32 Function( + ffi.Pointer folder, +); + +typedef _dart_media_folder_update_to_db = int Function( + ffi.Pointer folder, +); + +typedef _c_image_meta_clone = ffi.Int32 Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _dart_image_meta_clone = int Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _c_image_meta_destroy = ffi.Int32 Function( + ffi.Pointer image, +); + +typedef _dart_image_meta_destroy = int Function( + ffi.Pointer image, +); + +typedef _c_image_meta_get_media_id = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer> media_id, +); + +typedef _dart_image_meta_get_media_id = int Function( + ffi.Pointer image, + ffi.Pointer> media_id, +); + +typedef _c_image_meta_get_width = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer width, +); + +typedef _dart_image_meta_get_width = int Function( + ffi.Pointer image, + ffi.Pointer width, +); + +typedef _c_image_meta_get_height = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer height, +); + +typedef _dart_image_meta_get_height = int Function( + ffi.Pointer image, + ffi.Pointer height, +); + +typedef _c_image_meta_get_orientation = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer orientation, +); + +typedef _dart_image_meta_get_orientation = int Function( + ffi.Pointer image, + ffi.Pointer orientation, +); + +typedef _c_image_meta_get_date_taken = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer> date_taken, +); + +typedef _dart_image_meta_get_date_taken = int Function( + ffi.Pointer image, + ffi.Pointer> date_taken, +); + +typedef _c_image_meta_get_burst_id = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer> burst_id, +); + +typedef _dart_image_meta_get_burst_id = int Function( + ffi.Pointer image, + ffi.Pointer> burst_id, +); + +typedef _c_image_meta_get_exposure_time = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer> exposure_time, +); + +typedef _dart_image_meta_get_exposure_time = int Function( + ffi.Pointer image, + ffi.Pointer> exposure_time, +); + +typedef _c_image_meta_get_fnumber = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer fnumber, +); + +typedef _dart_image_meta_get_fnumber = int Function( + ffi.Pointer image, + ffi.Pointer fnumber, +); + +typedef _c_image_meta_get_iso = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer iso, +); + +typedef _dart_image_meta_get_iso = int Function( + ffi.Pointer image, + ffi.Pointer iso, +); + +typedef _c_image_meta_get_model = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer> model, +); + +typedef _dart_image_meta_get_model = int Function( + ffi.Pointer image, + ffi.Pointer> model, +); + +typedef _c_image_meta_is_burst_shot = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer is_burst_shot, +); + +typedef _dart_image_meta_is_burst_shot = int Function( + ffi.Pointer image, + ffi.Pointer is_burst_shot, +); + +typedef _c_image_meta_set_orientation = ffi.Int32 Function( + ffi.Pointer image, + ffi.Int32 orientation, +); + +typedef _dart_image_meta_set_orientation = int Function( + ffi.Pointer image, + int orientation, +); + +typedef _c_image_meta_update_to_db = ffi.Int32 Function( + ffi.Pointer image, +); + +typedef _dart_image_meta_update_to_db = int Function( + ffi.Pointer image, +); + +typedef _c_media_info_insert_to_db = ffi.Int32 Function( + ffi.Pointer path, + ffi.Pointer> info, +); + +typedef _dart_media_info_insert_to_db = int Function( + ffi.Pointer path, + ffi.Pointer> info, +); + +typedef media_insert_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_media_info_insert_batch_to_db = ffi.Int32 Function( + ffi.Pointer> path_array, + ffi.Uint32 array_length, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_info_insert_batch_to_db = int Function( + ffi.Pointer> path_array, + int array_length, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef media_insert_burst_shot_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_media_info_insert_burst_shot_to_db = ffi.Int32 Function( + ffi.Pointer> path_array, + ffi.Uint32 array_length, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_media_info_insert_burst_shot_to_db = int Function( + ffi.Pointer> path_array, + int array_length, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_media_info_delete_from_db = ffi.Int32 Function( + ffi.Pointer media_id, +); + +typedef _dart_media_info_delete_from_db = int Function( + ffi.Pointer media_id, +); + +typedef _c_media_info_delete_batch_from_db = ffi.Int32 Function( + ffi.Pointer filter, +); + +typedef _dart_media_info_delete_batch_from_db = int Function( + ffi.Pointer filter, +); + +typedef _c_media_info_destroy = ffi.Int32 Function( + ffi.Pointer media, +); + +typedef _dart_media_info_destroy = int Function( + ffi.Pointer media, +); + +typedef _c_media_info_clone = ffi.Int32 Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _dart_media_info_clone = int Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _c_media_info_get_media_count_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer media_count, +); + +typedef _dart_media_info_get_media_count_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer media_count, +); + +typedef _c_media_info_foreach_media_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_info_foreach_media_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_info_get_tag_count_from_db = ffi.Int32 Function( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer tag_count, +); + +typedef _dart_media_info_get_tag_count_from_db = int Function( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer tag_count, +); + +typedef media_tag_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_media_info_foreach_tag_from_db = ffi.Int32 Function( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_info_foreach_tag_from_db = int Function( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_info_get_bookmark_count_from_db = ffi.Int32 Function( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer bookmark_count, +); + +typedef _dart_media_info_get_bookmark_count_from_db = int Function( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer bookmark_count, +); + +typedef media_bookmark_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_media_info_foreach_bookmark_from_db = ffi.Int32 Function( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_info_foreach_bookmark_from_db = int Function( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_info_get_face_count_from_db = ffi.Int32 Function( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer face_count, +); + +typedef _dart_media_info_get_face_count_from_db = int Function( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer face_count, +); + +typedef media_face_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_media_info_foreach_face_from_db = ffi.Int32 Function( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_info_foreach_face_from_db = int Function( + ffi.Pointer media_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_info_get_image = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> image, +); + +typedef _dart_media_info_get_image = int Function( + ffi.Pointer media, + ffi.Pointer> image, +); + +typedef _c_media_info_get_video = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> video, +); + +typedef _dart_media_info_get_video = int Function( + ffi.Pointer media, + ffi.Pointer> video, +); + +typedef _c_media_info_get_audio = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> audio, +); + +typedef _dart_media_info_get_audio = int Function( + ffi.Pointer media, + ffi.Pointer> audio, +); + +typedef _c_media_info_get_media_id = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> media_id, +); + +typedef _dart_media_info_get_media_id = int Function( + ffi.Pointer media, + ffi.Pointer> media_id, +); + +typedef _c_media_info_get_file_path = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> path, +); + +typedef _dart_media_info_get_file_path = int Function( + ffi.Pointer media, + ffi.Pointer> path, +); + +typedef _c_media_info_get_display_name = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> name, +); + +typedef _dart_media_info_get_display_name = int Function( + ffi.Pointer media, + ffi.Pointer> name, +); + +typedef _c_media_info_get_media_type = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer type, +); + +typedef _dart_media_info_get_media_type = int Function( + ffi.Pointer media, + ffi.Pointer type, +); + +typedef _c_media_info_get_mime_type = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> mime_type, +); + +typedef _dart_media_info_get_mime_type = int Function( + ffi.Pointer media, + ffi.Pointer> mime_type, +); + +typedef _c_media_info_get_size = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer size, +); + +typedef _dart_media_info_get_size = int Function( + ffi.Pointer media, + ffi.Pointer size, +); + +typedef _c_media_info_get_added_time = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer added_time, +); + +typedef _dart_media_info_get_added_time = int Function( + ffi.Pointer media, + ffi.Pointer added_time, +); + +typedef _c_media_info_get_modified_time = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer time, +); + +typedef _dart_media_info_get_modified_time = int Function( + ffi.Pointer media, + ffi.Pointer time, +); + +typedef _c_media_info_get_timeline = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer time, +); + +typedef _dart_media_info_get_timeline = int Function( + ffi.Pointer media, + ffi.Pointer time, +); + +typedef _c_media_info_get_thumbnail_path = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> path, +); + +typedef _dart_media_info_get_thumbnail_path = int Function( + ffi.Pointer media, + ffi.Pointer> path, +); + +typedef _c_media_info_get_description = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> description, +); + +typedef _dart_media_info_get_description = int Function( + ffi.Pointer media, + ffi.Pointer> description, +); + +typedef _c_media_info_get_longitude = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer longitude, +); + +typedef _dart_media_info_get_longitude = int Function( + ffi.Pointer media, + ffi.Pointer longitude, +); + +typedef _c_media_info_get_latitude = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer latitude, +); + +typedef _dart_media_info_get_latitude = int Function( + ffi.Pointer media, + ffi.Pointer latitude, +); + +typedef _c_media_info_get_altitude = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer altitude, +); + +typedef _dart_media_info_get_altitude = int Function( + ffi.Pointer media, + ffi.Pointer altitude, +); + +typedef _c_media_info_get_weather = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> weather, +); + +typedef _dart_media_info_get_weather = int Function( + ffi.Pointer media, + ffi.Pointer> weather, +); + +typedef _c_media_info_get_rating = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer rating, +); + +typedef _dart_media_info_get_rating = int Function( + ffi.Pointer media, + ffi.Pointer rating, +); + +typedef _c_media_info_get_favorite = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer favorite, +); + +typedef _dart_media_info_get_favorite = int Function( + ffi.Pointer media, + ffi.Pointer favorite, +); + +typedef _c_media_info_get_author = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> author, +); + +typedef _dart_media_info_get_author = int Function( + ffi.Pointer media, + ffi.Pointer> author, +); + +typedef _c_media_info_get_provider = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> provider, +); + +typedef _dart_media_info_get_provider = int Function( + ffi.Pointer media, + ffi.Pointer> provider, +); + +typedef _c_media_info_get_content_name = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> content_name, +); + +typedef _dart_media_info_get_content_name = int Function( + ffi.Pointer media, + ffi.Pointer> content_name, +); + +typedef _c_media_info_get_title = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> title, +); + +typedef _dart_media_info_get_title = int Function( + ffi.Pointer media, + ffi.Pointer> title, +); + +typedef _c_media_info_get_category = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> category, +); + +typedef _dart_media_info_get_category = int Function( + ffi.Pointer media, + ffi.Pointer> category, +); + +typedef _c_media_info_get_location_tag = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> location_tag, +); + +typedef _dart_media_info_get_location_tag = int Function( + ffi.Pointer media, + ffi.Pointer> location_tag, +); + +typedef _c_media_info_get_age_rating = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> age_rating, +); + +typedef _dart_media_info_get_age_rating = int Function( + ffi.Pointer media, + ffi.Pointer> age_rating, +); + +typedef _c_media_info_get_keyword = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> keyword, +); + +typedef _dart_media_info_get_keyword = int Function( + ffi.Pointer media, + ffi.Pointer> keyword, +); + +typedef _c_media_info_get_storage_id = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> storage_id, +); + +typedef _dart_media_info_get_storage_id = int Function( + ffi.Pointer media, + ffi.Pointer> storage_id, +); + +typedef _c_media_info_is_drm = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer is_drm, +); + +typedef _dart_media_info_is_drm = int Function( + ffi.Pointer media, + ffi.Pointer is_drm, +); + +typedef _c_media_info_is_360_content = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer is_360, +); + +typedef _dart_media_info_is_360_content = int Function( + ffi.Pointer media, + ffi.Pointer is_360, +); + +typedef _c_media_info_get_storage_type = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer storage_type, +); + +typedef _dart_media_info_get_storage_type = int Function( + ffi.Pointer media, + ffi.Pointer storage_type, +); + +typedef _c_media_info_get_played_count = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer played_count, +); + +typedef _dart_media_info_get_played_count = int Function( + ffi.Pointer media, + ffi.Pointer played_count, +); + +typedef _c_media_info_get_played_time = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer played_time, +); + +typedef _dart_media_info_get_played_time = int Function( + ffi.Pointer media, + ffi.Pointer played_time, +); + +typedef _c_media_info_get_media_from_db = ffi.Int32 Function( + ffi.Pointer media_id, + ffi.Pointer> media, +); + +typedef _dart_media_info_get_media_from_db = int Function( + ffi.Pointer media_id, + ffi.Pointer> media, +); + +typedef _c_media_info_increase_played_count = ffi.Int32 Function( + ffi.Pointer media, +); + +typedef _dart_media_info_increase_played_count = int Function( + ffi.Pointer media, +); + +typedef _c_media_info_set_played_time = ffi.Int32 Function( + ffi.Pointer media, +); + +typedef _dart_media_info_set_played_time = int Function( + ffi.Pointer media, +); + +typedef _c_media_info_set_display_name = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer display_name, +); + +typedef _dart_media_info_set_display_name = int Function( + ffi.Pointer media, + ffi.Pointer display_name, +); + +typedef _c_media_info_set_description = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer description, +); + +typedef _dart_media_info_set_description = int Function( + ffi.Pointer media, + ffi.Pointer description, +); + +typedef _c_media_info_set_longitude = ffi.Int32 Function( + ffi.Pointer media, + ffi.Double longitude, +); + +typedef _dart_media_info_set_longitude = int Function( + ffi.Pointer media, + double longitude, +); + +typedef _c_media_info_set_latitude = ffi.Int32 Function( + ffi.Pointer media, + ffi.Double latitude, +); + +typedef _dart_media_info_set_latitude = int Function( + ffi.Pointer media, + double latitude, +); + +typedef _c_media_info_set_altitude = ffi.Int32 Function( + ffi.Pointer media, + ffi.Double altitude, +); + +typedef _dart_media_info_set_altitude = int Function( + ffi.Pointer media, + double altitude, +); + +typedef _c_media_info_set_weather = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer weather, +); + +typedef _dart_media_info_set_weather = int Function( + ffi.Pointer media, + ffi.Pointer weather, +); + +typedef _c_media_info_set_rating = ffi.Int32 Function( + ffi.Pointer media, + ffi.Int32 rating, +); + +typedef _dart_media_info_set_rating = int Function( + ffi.Pointer media, + int rating, +); + +typedef _c_media_info_set_favorite = ffi.Int32 Function( + ffi.Pointer media, + ffi.Uint8 favorite, +); + +typedef _dart_media_info_set_favorite = int Function( + ffi.Pointer media, + int favorite, +); + +typedef _c_media_info_set_author = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer author, +); + +typedef _dart_media_info_set_author = int Function( + ffi.Pointer media, + ffi.Pointer author, +); + +typedef _c_media_info_set_provider = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer provider, +); + +typedef _dart_media_info_set_provider = int Function( + ffi.Pointer media, + ffi.Pointer provider, +); + +typedef _c_media_info_set_content_name = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer content_name, +); + +typedef _dart_media_info_set_content_name = int Function( + ffi.Pointer media, + ffi.Pointer content_name, +); + +typedef _c_media_info_set_category = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer category, +); + +typedef _dart_media_info_set_category = int Function( + ffi.Pointer media, + ffi.Pointer category, +); + +typedef _c_media_info_set_location_tag = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer location_tag, +); + +typedef _dart_media_info_set_location_tag = int Function( + ffi.Pointer media, + ffi.Pointer location_tag, +); + +typedef _c_media_info_set_age_rating = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer age_rating, +); + +typedef _dart_media_info_set_age_rating = int Function( + ffi.Pointer media, + ffi.Pointer age_rating, +); + +typedef _c_media_info_set_keyword = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer keyword, +); + +typedef _dart_media_info_set_keyword = int Function( + ffi.Pointer media, + ffi.Pointer keyword, +); + +typedef _c_media_info_update_to_db = ffi.Int32 Function( + ffi.Pointer media, +); + +typedef _dart_media_info_update_to_db = int Function( + ffi.Pointer media, +); + +typedef _c_media_info_refresh_metadata_to_db = ffi.Int32 Function( + ffi.Pointer media_id, +); + +typedef _dart_media_info_refresh_metadata_to_db = int Function( + ffi.Pointer media_id, +); + +typedef _c_media_info_set_added_time = ffi.Int32 Function( + ffi.Pointer media, + ffi.Int64 added_time, +); + +typedef _dart_media_info_set_added_time = int Function( + ffi.Pointer media, + int added_time, +); + +typedef _c_media_info_move_to_db = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer dst_path, +); + +typedef _dart_media_info_move_to_db = int Function( + ffi.Pointer media, + ffi.Pointer dst_path, +); + +typedef media_thumbnail_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_media_info_create_thumbnail = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_info_create_thumbnail = int Function( + ffi.Pointer media, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_info_cancel_thumbnail = ffi.Int32 Function( + ffi.Pointer media, +); + +typedef _dart_media_info_cancel_thumbnail = int Function( + ffi.Pointer media, +); + +typedef media_face_detection_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_media_info_start_face_detection = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_info_start_face_detection = int Function( + ffi.Pointer media, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_info_cancel_face_detection = ffi.Int32 Function( + ffi.Pointer media, +); + +typedef _dart_media_info_cancel_face_detection = int Function( + ffi.Pointer media, +); + +typedef _c_media_info_create = ffi.Int32 Function( + ffi.Pointer path, + ffi.Pointer> media, +); + +typedef _dart_media_info_create = int Function( + ffi.Pointer path, + ffi.Pointer> media, +); + +typedef _c_media_info_insert_to_db_with_data = ffi.Int32 Function( + ffi.Pointer media, +); + +typedef _dart_media_info_insert_to_db_with_data = int Function( + ffi.Pointer media, +); + +typedef _c_media_info_set_title = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer title, +); + +typedef _dart_media_info_set_title = int Function( + ffi.Pointer media, + ffi.Pointer title, +); + +typedef _c_media_info_set_album = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer album, +); + +typedef _dart_media_info_set_album = int Function( + ffi.Pointer media, + ffi.Pointer album, +); + +typedef _c_media_info_set_artist = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer artist, +); + +typedef _dart_media_info_set_artist = int Function( + ffi.Pointer media, + ffi.Pointer artist, +); + +typedef _c_media_info_set_genre = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer genre, +); + +typedef _dart_media_info_set_genre = int Function( + ffi.Pointer media, + ffi.Pointer genre, +); + +typedef _c_media_info_set_recorded_date = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer recorded_date, +); + +typedef _dart_media_info_set_recorded_date = int Function( + ffi.Pointer media, + ffi.Pointer recorded_date, +); + +typedef _c_media_tag_insert_to_db = ffi.Int32 Function( + ffi.Pointer tag_name, + ffi.Pointer> tag, +); + +typedef _dart_media_tag_insert_to_db = int Function( + ffi.Pointer tag_name, + ffi.Pointer> tag, +); + +typedef _c_media_tag_delete_from_db = ffi.Int32 Function( + ffi.Int32 tag_id, +); + +typedef _dart_media_tag_delete_from_db = int Function( + int tag_id, +); + +typedef _c_media_tag_get_tag_count_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer tag_count, +); + +typedef _dart_media_tag_get_tag_count_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer tag_count, +); + +typedef _c_media_tag_foreach_tag_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_tag_foreach_tag_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_tag_get_media_count_from_db = ffi.Int32 Function( + ffi.Int32 tag_id, + ffi.Pointer filter, + ffi.Pointer media_count, +); + +typedef _dart_media_tag_get_media_count_from_db = int Function( + int tag_id, + ffi.Pointer filter, + ffi.Pointer media_count, +); + +typedef _c_media_tag_foreach_media_from_db = ffi.Int32 Function( + ffi.Int32 tag_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_tag_foreach_media_from_db = int Function( + int tag_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_tag_clone = ffi.Int32 Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _dart_media_tag_clone = int Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _c_media_tag_destroy = ffi.Int32 Function( + ffi.Pointer tag, +); + +typedef _dart_media_tag_destroy = int Function( + ffi.Pointer tag, +); + +typedef _c_media_tag_get_tag_id = ffi.Int32 Function( + ffi.Pointer tag, + ffi.Pointer tag_id, +); + +typedef _dart_media_tag_get_tag_id = int Function( + ffi.Pointer tag, + ffi.Pointer tag_id, +); + +typedef _c_media_tag_get_name = ffi.Int32 Function( + ffi.Pointer tag, + ffi.Pointer> tag_name, +); + +typedef _dart_media_tag_get_name = int Function( + ffi.Pointer tag, + ffi.Pointer> tag_name, +); + +typedef _c_media_tag_get_tag_from_db = ffi.Int32 Function( + ffi.Int32 tag_id, + ffi.Pointer> tag, +); + +typedef _dart_media_tag_get_tag_from_db = int Function( + int tag_id, + ffi.Pointer> tag, +); + +typedef _c_media_tag_add_media = ffi.Int32 Function( + ffi.Pointer tag, + ffi.Pointer media_id, +); + +typedef _dart_media_tag_add_media = int Function( + ffi.Pointer tag, + ffi.Pointer media_id, +); + +typedef _c_media_tag_remove_media = ffi.Int32 Function( + ffi.Pointer tag, + ffi.Pointer media_id, +); + +typedef _dart_media_tag_remove_media = int Function( + ffi.Pointer tag, + ffi.Pointer media_id, +); + +typedef _c_media_tag_set_name = ffi.Int32 Function( + ffi.Pointer tag, + ffi.Pointer tag_name, +); + +typedef _dart_media_tag_set_name = int Function( + ffi.Pointer tag, + ffi.Pointer tag_name, +); + +typedef _c_media_tag_update_to_db = ffi.Int32 Function( + ffi.Pointer tag, +); + +typedef _dart_media_tag_update_to_db = int Function( + ffi.Pointer tag, +); + +typedef _c_video_meta_clone = ffi.Int32 Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _dart_video_meta_clone = int Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _c_video_meta_destroy = ffi.Int32 Function( + ffi.Pointer video, +); + +typedef _dart_video_meta_destroy = int Function( + ffi.Pointer video, +); + +typedef _c_video_meta_get_media_id = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer> media_id, +); + +typedef _dart_video_meta_get_media_id = int Function( + ffi.Pointer video, + ffi.Pointer> media_id, +); + +typedef _c_video_meta_get_album = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer> album, +); + +typedef _dart_video_meta_get_album = int Function( + ffi.Pointer video, + ffi.Pointer> album, +); + +typedef _c_video_meta_get_artist = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer> artist, +); + +typedef _dart_video_meta_get_artist = int Function( + ffi.Pointer video, + ffi.Pointer> artist, +); + +typedef _c_video_meta_get_album_artist = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer> album_artist, +); + +typedef _dart_video_meta_get_album_artist = int Function( + ffi.Pointer video, + ffi.Pointer> album_artist, +); + +typedef _c_video_meta_get_genre = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer> genre, +); + +typedef _dart_video_meta_get_genre = int Function( + ffi.Pointer video, + ffi.Pointer> genre, +); + +typedef _c_video_meta_get_composer = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer> composer, +); + +typedef _dart_video_meta_get_composer = int Function( + ffi.Pointer video, + ffi.Pointer> composer, +); + +typedef _c_video_meta_get_year = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer> year, +); + +typedef _dart_video_meta_get_year = int Function( + ffi.Pointer video, + ffi.Pointer> year, +); + +typedef _c_video_meta_get_recorded_date = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer> recorded_date, +); + +typedef _dart_video_meta_get_recorded_date = int Function( + ffi.Pointer video, + ffi.Pointer> recorded_date, +); + +typedef _c_video_meta_get_copyright = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer> copyright, +); + +typedef _dart_video_meta_get_copyright = int Function( + ffi.Pointer video, + ffi.Pointer> copyright, +); + +typedef _c_video_meta_get_track_num = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer> track_num, +); + +typedef _dart_video_meta_get_track_num = int Function( + ffi.Pointer video, + ffi.Pointer> track_num, +); + +typedef _c_video_meta_get_bit_rate = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer bit_rate, +); + +typedef _dart_video_meta_get_bit_rate = int Function( + ffi.Pointer video, + ffi.Pointer bit_rate, +); + +typedef _c_video_meta_get_duration = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer duration, +); + +typedef _dart_video_meta_get_duration = int Function( + ffi.Pointer video, + ffi.Pointer duration, +); + +typedef _c_video_meta_get_width = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer width, +); + +typedef _dart_video_meta_get_width = int Function( + ffi.Pointer video, + ffi.Pointer width, +); + +typedef _c_video_meta_get_height = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer height, +); + +typedef _dart_video_meta_get_height = int Function( + ffi.Pointer video, + ffi.Pointer height, +); + +typedef _c_video_meta_get_rotation = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer rotation, +); + +typedef _dart_video_meta_get_rotation = int Function( + ffi.Pointer video, + ffi.Pointer rotation, +); + +typedef _c_video_meta_get_played_count = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer played_count, +); + +typedef _dart_video_meta_get_played_count = int Function( + ffi.Pointer video, + ffi.Pointer played_count, +); + +typedef _c_video_meta_get_played_time = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer played_time, +); + +typedef _dart_video_meta_get_played_time = int Function( + ffi.Pointer video, + ffi.Pointer played_time, +); + +typedef _c_video_meta_get_played_position = ffi.Int32 Function( + ffi.Pointer video, + ffi.Pointer played_position, +); + +typedef _dart_video_meta_get_played_position = int Function( + ffi.Pointer video, + ffi.Pointer played_position, +); + +typedef _c_video_meta_set_played_count = ffi.Int32 Function( + ffi.Pointer video, + ffi.Int32 played_count, +); + +typedef _dart_video_meta_set_played_count = int Function( + ffi.Pointer video, + int played_count, +); + +typedef _c_video_meta_set_played_time = ffi.Int32 Function( + ffi.Pointer video, + ffi.Int64 played_time, +); + +typedef _dart_video_meta_set_played_time = int Function( + ffi.Pointer video, + int played_time, +); + +typedef _c_video_meta_set_played_position = ffi.Int32 Function( + ffi.Pointer video, + ffi.Int32 played_position, +); + +typedef _dart_video_meta_set_played_position = int Function( + ffi.Pointer video, + int played_position, +); + +typedef _c_video_meta_update_to_db = ffi.Int32 Function( + ffi.Pointer video, +); + +typedef _dart_video_meta_update_to_db = int Function( + ffi.Pointer video, +); + +typedef _c_media_album_get_album_count_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer album_count, +); + +typedef _dart_media_album_get_album_count_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer album_count, +); + +typedef media_album_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_media_album_foreach_album_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_album_foreach_album_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_album_get_media_count_from_db = ffi.Int32 Function( + ffi.Int32 album_id, + ffi.Pointer filter, + ffi.Pointer media_count, +); + +typedef _dart_media_album_get_media_count_from_db = int Function( + int album_id, + ffi.Pointer filter, + ffi.Pointer media_count, +); + +typedef _c_media_album_foreach_media_from_db = ffi.Int32 Function( + ffi.Int32 album_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_album_foreach_media_from_db = int Function( + int album_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_album_destroy = ffi.Int32 Function( + ffi.Pointer album, +); + +typedef _dart_media_album_destroy = int Function( + ffi.Pointer album, +); + +typedef _c_media_album_clone = ffi.Int32 Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _dart_media_album_clone = int Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _c_media_album_get_album_id = ffi.Int32 Function( + ffi.Pointer album, + ffi.Pointer album_id, +); + +typedef _dart_media_album_get_album_id = int Function( + ffi.Pointer album, + ffi.Pointer album_id, +); + +typedef _c_media_album_get_name = ffi.Int32 Function( + ffi.Pointer album, + ffi.Pointer> album_name, +); + +typedef _dart_media_album_get_name = int Function( + ffi.Pointer album, + ffi.Pointer> album_name, +); + +typedef _c_media_album_get_artist = ffi.Int32 Function( + ffi.Pointer album, + ffi.Pointer> artist, +); + +typedef _dart_media_album_get_artist = int Function( + ffi.Pointer album, + ffi.Pointer> artist, +); + +typedef _c_media_album_get_album_art = ffi.Int32 Function( + ffi.Pointer album, + ffi.Pointer> album_art, +); + +typedef _dart_media_album_get_album_art = int Function( + ffi.Pointer album, + ffi.Pointer> album_art, +); + +typedef _c_media_album_get_album_from_db = ffi.Int32 Function( + ffi.Int32 album_id, + ffi.Pointer> album, +); + +typedef _dart_media_album_get_album_from_db = int Function( + int album_id, + ffi.Pointer> album, +); + +typedef _c_media_group_get_group_count_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Int32 group, + ffi.Pointer group_count, +); + +typedef _dart_media_group_get_group_count_from_db = int Function( + ffi.Pointer filter, + int group, + ffi.Pointer group_count, +); + +typedef media_group_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_media_group_foreach_group_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Int32 group, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_group_foreach_group_from_db = int Function( + ffi.Pointer filter, + int group, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_group_get_media_count_from_db = ffi.Int32 Function( + ffi.Pointer group_name, + ffi.Int32 group, + ffi.Pointer filter, + ffi.Pointer media_count, +); + +typedef _dart_media_group_get_media_count_from_db = int Function( + ffi.Pointer group_name, + int group, + ffi.Pointer filter, + ffi.Pointer media_count, +); + +typedef _c_media_group_foreach_media_from_db = ffi.Int32 Function( + ffi.Pointer group_name, + ffi.Int32 group, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_group_foreach_media_from_db = int Function( + ffi.Pointer group_name, + int group, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_playlist_get_playlist_count_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer playlist_count, +); + +typedef _dart_media_playlist_get_playlist_count_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer playlist_count, +); + +typedef media_playlist_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_media_playlist_foreach_playlist_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_playlist_foreach_playlist_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_playlist_get_media_count_from_db = ffi.Int32 Function( + ffi.Int32 playlist_id, + ffi.Pointer filter, + ffi.Pointer media_count, +); + +typedef _dart_media_playlist_get_media_count_from_db = int Function( + int playlist_id, + ffi.Pointer filter, + ffi.Pointer media_count, +); + +typedef playlist_member_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_media_playlist_foreach_media_from_db = ffi.Int32 Function( + ffi.Int32 playlist_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_playlist_foreach_media_from_db = int Function( + int playlist_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_playlist_insert_to_db = ffi.Int32 Function( + ffi.Pointer name, + ffi.Pointer> playlist, +); + +typedef _dart_media_playlist_insert_to_db = int Function( + ffi.Pointer name, + ffi.Pointer> playlist, +); + +typedef _c_media_playlist_delete_from_db = ffi.Int32 Function( + ffi.Int32 playlist_id, +); + +typedef _dart_media_playlist_delete_from_db = int Function( + int playlist_id, +); + +typedef _c_media_playlist_get_playlist_from_db = ffi.Int32 Function( + ffi.Int32 playlist_id, + ffi.Pointer> playlist, +); + +typedef _dart_media_playlist_get_playlist_from_db = int Function( + int playlist_id, + ffi.Pointer> playlist, +); + +typedef _c_media_playlist_destroy = ffi.Int32 Function( + ffi.Pointer playlist, +); + +typedef _dart_media_playlist_destroy = int Function( + ffi.Pointer playlist, +); + +typedef _c_media_playlist_clone = ffi.Int32 Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _dart_media_playlist_clone = int Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _c_media_playlist_get_playlist_id = ffi.Int32 Function( + ffi.Pointer playlist, + ffi.Pointer playlist_id, +); + +typedef _dart_media_playlist_get_playlist_id = int Function( + ffi.Pointer playlist, + ffi.Pointer playlist_id, +); + +typedef _c_media_playlist_get_name = ffi.Int32 Function( + ffi.Pointer playlist, + ffi.Pointer> playlist_name, +); + +typedef _dart_media_playlist_get_name = int Function( + ffi.Pointer playlist, + ffi.Pointer> playlist_name, +); + +typedef _c_media_playlist_set_name = ffi.Int32 Function( + ffi.Pointer playlist, + ffi.Pointer playlist_name, +); + +typedef _dart_media_playlist_set_name = int Function( + ffi.Pointer playlist, + ffi.Pointer playlist_name, +); + +typedef _c_media_playlist_get_thumbnail_path = ffi.Int32 Function( + ffi.Pointer playlist, + ffi.Pointer> path, +); + +typedef _dart_media_playlist_get_thumbnail_path = int Function( + ffi.Pointer playlist, + ffi.Pointer> path, +); + +typedef _c_media_playlist_set_thumbnail_path = ffi.Int32 Function( + ffi.Pointer playlist, + ffi.Pointer path, +); + +typedef _dart_media_playlist_set_thumbnail_path = int Function( + ffi.Pointer playlist, + ffi.Pointer path, +); + +typedef _c_media_playlist_set_play_order = ffi.Int32 Function( + ffi.Pointer playlist, + ffi.Int32 playlist_member_id, + ffi.Int32 play_order, +); + +typedef _dart_media_playlist_set_play_order = int Function( + ffi.Pointer playlist, + int playlist_member_id, + int play_order, +); + +typedef _c_media_playlist_add_media = ffi.Int32 Function( + ffi.Pointer playlist, + ffi.Pointer media_id, +); + +typedef _dart_media_playlist_add_media = int Function( + ffi.Pointer playlist, + ffi.Pointer media_id, +); + +typedef _c_media_playlist_remove_media = ffi.Int32 Function( + ffi.Pointer playlist, + ffi.Int32 playlist_member_id, +); + +typedef _dart_media_playlist_remove_media = int Function( + ffi.Pointer playlist, + int playlist_member_id, +); + +typedef _c_media_playlist_get_play_order = ffi.Int32 Function( + ffi.Pointer playlist, + ffi.Int32 playlist_member_id, + ffi.Pointer play_order, +); + +typedef _dart_media_playlist_get_play_order = int Function( + ffi.Pointer playlist, + int playlist_member_id, + ffi.Pointer play_order, +); + +typedef _c_media_playlist_update_to_db = ffi.Int32 Function( + ffi.Pointer playlist, +); + +typedef _dart_media_playlist_update_to_db = int Function( + ffi.Pointer playlist, +); + +typedef _c_media_playlist_import_from_file = ffi.Int32 Function( + ffi.Pointer playlist_name, + ffi.Pointer path, + ffi.Pointer> playlist, +); + +typedef _dart_media_playlist_import_from_file = int Function( + ffi.Pointer playlist_name, + ffi.Pointer path, + ffi.Pointer> playlist, +); + +typedef _c_media_playlist_export_to_file = ffi.Int32 Function( + ffi.Pointer playlist, + ffi.Pointer path, +); + +typedef _dart_media_playlist_export_to_file = int Function( + ffi.Pointer playlist, + ffi.Pointer path, +); + +typedef _c_media_bookmark_insert_to_db = ffi.Int32 Function( + ffi.Pointer media_id, + ffi.Int64 time, + ffi.Pointer thumbnail_path, +); + +typedef _dart_media_bookmark_insert_to_db = int Function( + ffi.Pointer media_id, + int time, + ffi.Pointer thumbnail_path, +); + +typedef _c_media_bookmark_delete_from_db = ffi.Int32 Function( + ffi.Int32 bookmark_id, +); + +typedef _dart_media_bookmark_delete_from_db = int Function( + int bookmark_id, +); + +typedef _c_media_bookmark_get_bookmark_count_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer bookmark_count, +); + +typedef _dart_media_bookmark_get_bookmark_count_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer bookmark_count, +); + +typedef _c_media_bookmark_foreach_bookmark_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_bookmark_foreach_bookmark_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_bookmark_clone = ffi.Int32 Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _dart_media_bookmark_clone = int Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _c_media_bookmark_destroy = ffi.Int32 Function( + ffi.Pointer bookmark, +); + +typedef _dart_media_bookmark_destroy = int Function( + ffi.Pointer bookmark, +); + +typedef _c_media_bookmark_get_bookmark_id = ffi.Int32 Function( + ffi.Pointer bookmark, + ffi.Pointer bookmark_id, +); + +typedef _dart_media_bookmark_get_bookmark_id = int Function( + ffi.Pointer bookmark, + ffi.Pointer bookmark_id, +); + +typedef _c_media_bookmark_get_marked_time = ffi.Int32 Function( + ffi.Pointer bookmark, + ffi.Pointer marked_time, +); + +typedef _dart_media_bookmark_get_marked_time = int Function( + ffi.Pointer bookmark, + ffi.Pointer marked_time, +); + +typedef _c_media_bookmark_get_thumbnail_path = ffi.Int32 Function( + ffi.Pointer bookmark, + ffi.Pointer> path, +); + +typedef _dart_media_bookmark_get_thumbnail_path = int Function( + ffi.Pointer bookmark, + ffi.Pointer> path, +); + +typedef _c_media_bookmark_get_name = ffi.Int32 Function( + ffi.Pointer bookmark, + ffi.Pointer> name, +); + +typedef _dart_media_bookmark_get_name = int Function( + ffi.Pointer bookmark, + ffi.Pointer> name, +); + +typedef _c_media_bookmark_set_name = ffi.Int32 Function( + ffi.Pointer bookmark, + ffi.Pointer name, +); + +typedef _dart_media_bookmark_set_name = int Function( + ffi.Pointer bookmark, + ffi.Pointer name, +); + +typedef _c_media_bookmark_update_to_db = ffi.Int32 Function( + ffi.Pointer bookmark, +); + +typedef _dart_media_bookmark_update_to_db = int Function( + ffi.Pointer bookmark, +); + +typedef _c_media_storage_get_storage_info_from_db = ffi.Int32 Function( + ffi.Pointer storage_id, + ffi.Pointer> storage, +); + +typedef _dart_media_storage_get_storage_info_from_db = int Function( + ffi.Pointer storage_id, + ffi.Pointer> storage, +); + +typedef _c_media_storage_get_storage_count_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer storage_count, +); + +typedef _dart_media_storage_get_storage_count_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer storage_count, +); + +typedef media_storage_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_media_storage_foreach_storage_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_storage_foreach_storage_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_storage_get_media_count_from_db = ffi.Int32 Function( + ffi.Pointer storage_id, + ffi.Pointer filter, + ffi.Pointer media_count, +); + +typedef _dart_media_storage_get_media_count_from_db = int Function( + ffi.Pointer storage_id, + ffi.Pointer filter, + ffi.Pointer media_count, +); + +typedef _c_media_storage_foreach_media_from_db = ffi.Int32 Function( + ffi.Pointer storage_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_storage_foreach_media_from_db = int Function( + ffi.Pointer storage_id, + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_storage_destroy = ffi.Int32 Function( + ffi.Pointer storage, +); + +typedef _dart_media_storage_destroy = int Function( + ffi.Pointer storage, +); + +typedef _c_media_storage_clone = ffi.Int32 Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _dart_media_storage_clone = int Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _c_media_storage_get_id = ffi.Int32 Function( + ffi.Pointer storage, + ffi.Pointer> storage_id, +); + +typedef _dart_media_storage_get_id = int Function( + ffi.Pointer storage, + ffi.Pointer> storage_id, +); + +typedef _c_media_storage_get_name = ffi.Int32 Function( + ffi.Pointer storage, + ffi.Pointer> storage_name, +); + +typedef _dart_media_storage_get_name = int Function( + ffi.Pointer storage, + ffi.Pointer> storage_name, +); + +typedef _c_media_storage_get_path = ffi.Int32 Function( + ffi.Pointer storage, + ffi.Pointer> storage_path, +); + +typedef _dart_media_storage_get_path = int Function( + ffi.Pointer storage, + ffi.Pointer> storage_path, +); + +typedef _c_media_storage_get_type = ffi.Int32 Function( + ffi.Pointer storage, + ffi.Pointer storage_type, +); + +typedef _dart_media_storage_get_type = int Function( + ffi.Pointer storage, + ffi.Pointer storage_type, +); + +typedef _c_media_face_clone = ffi.Int32 Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _dart_media_face_clone = int Function( + ffi.Pointer> dst, + ffi.Pointer src, +); + +typedef _c_media_face_destroy = ffi.Int32 Function( + ffi.Pointer face, +); + +typedef _dart_media_face_destroy = int Function( + ffi.Pointer face, +); + +typedef _c_media_face_get_face_id = ffi.Int32 Function( + ffi.Pointer face, + ffi.Pointer> face_id, +); + +typedef _dart_media_face_get_face_id = int Function( + ffi.Pointer face, + ffi.Pointer> face_id, +); + +typedef _c_media_face_get_media_id = ffi.Int32 Function( + ffi.Pointer face, + ffi.Pointer> media_id, +); + +typedef _dart_media_face_get_media_id = int Function( + ffi.Pointer face, + ffi.Pointer> media_id, +); + +typedef _c_media_face_get_face_rect = ffi.Int32 Function( + ffi.Pointer face, + ffi.Pointer rect_x, + ffi.Pointer rect_y, + ffi.Pointer rect_w, + ffi.Pointer rect_h, +); + +typedef _dart_media_face_get_face_rect = int Function( + ffi.Pointer face, + ffi.Pointer rect_x, + ffi.Pointer rect_y, + ffi.Pointer rect_w, + ffi.Pointer rect_h, +); + +typedef _c_media_face_get_orientation = ffi.Int32 Function( + ffi.Pointer face, + ffi.Pointer orientation, +); + +typedef _dart_media_face_get_orientation = int Function( + ffi.Pointer face, + ffi.Pointer orientation, +); + +typedef _c_media_face_get_tag = ffi.Int32 Function( + ffi.Pointer face, + ffi.Pointer> tag, +); + +typedef _dart_media_face_get_tag = int Function( + ffi.Pointer face, + ffi.Pointer> tag, +); + +typedef _c_media_face_create = ffi.Int32 Function( + ffi.Pointer media_id, + ffi.Pointer> face, +); + +typedef _dart_media_face_create = int Function( + ffi.Pointer media_id, + ffi.Pointer> face, +); + +typedef _c_media_face_set_face_rect = ffi.Int32 Function( + ffi.Pointer face, + ffi.Uint32 rect_x, + ffi.Uint32 rect_y, + ffi.Uint32 rect_w, + ffi.Uint32 rect_h, +); + +typedef _dart_media_face_set_face_rect = int Function( + ffi.Pointer face, + int rect_x, + int rect_y, + int rect_w, + int rect_h, +); + +typedef _c_media_face_set_orientation = ffi.Int32 Function( + ffi.Pointer face, + ffi.Int32 orientation, +); + +typedef _dart_media_face_set_orientation = int Function( + ffi.Pointer face, + int orientation, +); + +typedef _c_media_face_set_tag = ffi.Int32 Function( + ffi.Pointer face, + ffi.Pointer tag, +); + +typedef _dart_media_face_set_tag = int Function( + ffi.Pointer face, + ffi.Pointer tag, +); + +typedef _c_media_face_insert_to_db = ffi.Int32 Function( + ffi.Pointer face, +); + +typedef _dart_media_face_insert_to_db = int Function( + ffi.Pointer face, +); + +typedef _c_media_face_update_to_db = ffi.Int32 Function( + ffi.Pointer face, +); + +typedef _dart_media_face_update_to_db = int Function( + ffi.Pointer face, +); + +typedef _c_media_face_delete_from_db = ffi.Int32 Function( + ffi.Pointer face_id, +); + +typedef _dart_media_face_delete_from_db = int Function( + ffi.Pointer face_id, +); + +typedef _c_media_face_get_face_count_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer face_count, +); + +typedef _dart_media_face_get_face_count_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer face_count, +); + +typedef _c_media_face_foreach_face_from_db = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_face_foreach_face_from_db = int Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_content_connect = ffi.Int32 Function(); + +typedef _dart_media_content_connect = int Function(); + +typedef _c_media_content_disconnect = ffi.Int32 Function(); + +typedef _dart_media_content_disconnect = int Function(); + +typedef _c_media_content_scan_file = ffi.Int32 Function( + ffi.Pointer path, +); + +typedef _dart_media_content_scan_file = int Function( + ffi.Pointer path, +); + +typedef media_scan_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_media_content_scan_folder = ffi.Int32 Function( + ffi.Pointer path, + ffi.Uint8 is_recursive, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_content_scan_folder = int Function( + ffi.Pointer path, + int is_recursive, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_content_cancel_scan_folder = ffi.Int32 Function( + ffi.Pointer path, +); + +typedef _dart_media_content_cancel_scan_folder = int Function( + ffi.Pointer path, +); + +typedef media_content_db_update_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_media_content_set_db_updated_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_content_set_db_updated_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_content_unset_db_updated_cb = ffi.Int32 Function(); + +typedef _dart_media_content_unset_db_updated_cb = int Function(); + +typedef _c_media_content_add_db_updated_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer> noti_handle, +); + +typedef _dart_media_content_add_db_updated_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer> noti_handle, +); + +typedef _c_media_content_remove_db_updated_cb = ffi.Int32 Function( + ffi.Pointer noti_handle, +); + +typedef _dart_media_content_remove_db_updated_cb = int Function( + ffi.Pointer noti_handle, +); + +typedef _c_activity_is_supported = ffi.Int32 Function( + ffi.Int32 activity, + ffi.Pointer supported, +); + +typedef _dart_activity_is_supported = int Function( + int activity, + ffi.Pointer supported, +); + +typedef _c_activity_create = ffi.Int32 Function( + ffi.Pointer> handle, +); + +typedef _dart_activity_create = int Function( + ffi.Pointer> handle, +); + +typedef _c_activity_release = ffi.Int32 Function( + ffi.Pointer<_activity_handle_s> handle, +); + +typedef _dart_activity_release = int Function( + ffi.Pointer<_activity_handle_s> handle, +); + +typedef activity_recognition_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer<_activity_data_s>, + ffi.Double, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_activity_start_recognition = ffi.Int32 Function( + ffi.Pointer<_activity_handle_s> handle, + ffi.Int32 activity, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_activity_start_recognition = int Function( + ffi.Pointer<_activity_handle_s> handle, + int activity, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_activity_stop_recognition = ffi.Int32 Function( + ffi.Pointer<_activity_handle_s> handle, +); + +typedef _dart_activity_stop_recognition = int Function( + ffi.Pointer<_activity_handle_s> handle, +); + +typedef _c_activity_get_accuracy = ffi.Int32 Function( + ffi.Pointer<_activity_data_s> data, + ffi.Pointer accuracy, +); + +typedef _dart_activity_get_accuracy = int Function( + ffi.Pointer<_activity_data_s> data, + ffi.Pointer accuracy, +); + +typedef _c_gesture_is_supported = ffi.Int32 Function( + ffi.Int32 gesture, + ffi.Pointer supported, +); + +typedef _dart_gesture_is_supported = int Function( + int gesture, + ffi.Pointer supported, +); + +typedef _c_gesture_create = ffi.Int32 Function( + ffi.Pointer> handle, +); + +typedef _dart_gesture_create = int Function( + ffi.Pointer> handle, +); + +typedef _c_gesture_release = ffi.Int32 Function( + ffi.Pointer<_gesture_handle_s> handle, +); + +typedef _dart_gesture_release = int Function( + ffi.Pointer<_gesture_handle_s> handle, +); + +typedef gesture_recognition_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer<_gesture_data_s>, + ffi.Double, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_gesture_start_recognition = ffi.Int32 Function( + ffi.Pointer<_gesture_handle_s> handle, + ffi.Int32 gesture, + ffi.Int32 option, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_gesture_start_recognition = int Function( + ffi.Pointer<_gesture_handle_s> handle, + int gesture, + int option, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_gesture_stop_recognition = ffi.Int32 Function( + ffi.Pointer<_gesture_handle_s> handle, +); + +typedef _dart_gesture_stop_recognition = int Function( + ffi.Pointer<_gesture_handle_s> handle, +); + +typedef _c_gesture_get_event = ffi.Int32 Function( + ffi.Pointer<_gesture_data_s> data, + ffi.Pointer event, +); + +typedef _dart_gesture_get_event = int Function( + ffi.Pointer<_gesture_data_s> data, + ffi.Pointer event, +); + +typedef _c_gesture_get_tilt = ffi.Int32 Function( + ffi.Pointer<_gesture_data_s> data, + ffi.Pointer x, + ffi.Pointer y, +); + +typedef _dart_gesture_get_tilt = int Function( + ffi.Pointer<_gesture_data_s> data, + ffi.Pointer x, + ffi.Pointer y, +); + +typedef _c_location_bounds_create_rect = ffi.Int32 Function( + location_coords_s top_left, + location_coords_s bottom_right, + ffi.Pointer> bounds, +); + +typedef _dart_location_bounds_create_rect = int Function( + location_coords_s top_left, + location_coords_s bottom_right, + ffi.Pointer> bounds, +); + +typedef _c_location_bounds_create_circle = ffi.Int32 Function( + location_coords_s center, + ffi.Double radius, + ffi.Pointer> bounds, +); + +typedef _dart_location_bounds_create_circle = int Function( + location_coords_s center, + double radius, + ffi.Pointer> bounds, +); + +typedef _c_location_bounds_create_polygon = ffi.Int32 Function( + ffi.Pointer coords_list, + ffi.Int32 length, + ffi.Pointer> bounds, +); + +typedef _dart_location_bounds_create_polygon = int Function( + ffi.Pointer coords_list, + int length, + ffi.Pointer> bounds, +); + +typedef _c_location_bounds_contains_coordinates = ffi.Uint8 Function( + ffi.Pointer bounds, + location_coords_s coords, +); + +typedef _dart_location_bounds_contains_coordinates = int Function( + ffi.Pointer bounds, + location_coords_s coords, +); + +typedef _c_location_bounds_get_type = ffi.Int32 Function( + ffi.Pointer bounds, + ffi.Pointer type, +); + +typedef _dart_location_bounds_get_type = int Function( + ffi.Pointer bounds, + ffi.Pointer type, +); + +typedef _c_location_bounds_get_rect_coords = ffi.Int32 Function( + ffi.Pointer bounds, + ffi.Pointer top_left, + ffi.Pointer bottom_right, +); + +typedef _dart_location_bounds_get_rect_coords = int Function( + ffi.Pointer bounds, + ffi.Pointer top_left, + ffi.Pointer bottom_right, +); + +typedef _c_location_bounds_get_circle_coords = ffi.Int32 Function( + ffi.Pointer bounds, + ffi.Pointer center, + ffi.Pointer radius, +); + +typedef _dart_location_bounds_get_circle_coords = int Function( + ffi.Pointer bounds, + ffi.Pointer center, + ffi.Pointer radius, +); + +typedef polygon_coords_cb = ffi.Uint8 Function( + location_coords_s, + ffi.Pointer, +); + +typedef _c_location_bounds_foreach_polygon_coords = ffi.Int32 Function( + ffi.Pointer bounds, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_location_bounds_foreach_polygon_coords = int Function( + ffi.Pointer bounds, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_location_bounds_destroy = ffi.Int32 Function( + ffi.Pointer bounds, +); + +typedef _dart_location_bounds_destroy = int Function( + ffi.Pointer bounds, +); + +typedef location_bounds_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_location_bounds_set_state_changed_cb = ffi.Int32 Function( + ffi.Pointer bounds, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_location_bounds_set_state_changed_cb = int Function( + ffi.Pointer bounds, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_location_bounds_unset_state_changed_cb = ffi.Int32 Function( + ffi.Pointer bounds, +); + +typedef _dart_location_bounds_unset_state_changed_cb = int Function( + ffi.Pointer bounds, +); + +typedef _c_location_manager_is_supported_method = ffi.Uint8 Function( + ffi.Int32 method, +); + +typedef _dart_location_manager_is_supported_method = int Function( + int method, +); + +typedef _c_location_manager_is_enabled_method = ffi.Int32 Function( + ffi.Int32 method, + ffi.Pointer enable, +); + +typedef _dart_location_manager_is_enabled_method = int Function( + int method, + ffi.Pointer enable, +); + +typedef _c_location_manager_enable_method = ffi.Int32 Function( + ffi.Int32 method, + ffi.Uint8 enable, +); + +typedef _dart_location_manager_enable_method = int Function( + int method, + int enable, +); + +typedef _c_location_manager_create = ffi.Int32 Function( + ffi.Int32 method, + ffi.Pointer> manager, +); + +typedef _dart_location_manager_create = int Function( + int method, + ffi.Pointer> manager, +); + +typedef _c_location_manager_destroy = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_location_manager_destroy = int Function( + ffi.Pointer manager, +); + +typedef location_updated_cb = ffi.Void Function( + ffi.Int32, + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Int64, + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Pointer, +); + +typedef _c_location_manager_request_single_location = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Int32 timeout, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_location_manager_request_single_location = int Function( + ffi.Pointer manager, + int timeout, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_location_manager_start = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_location_manager_start = int Function( + ffi.Pointer manager, +); + +typedef _c_location_manager_stop = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_location_manager_stop = int Function( + ffi.Pointer manager, +); + +typedef _c_location_manager_add_boundary = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer bounds, +); + +typedef _dart_location_manager_add_boundary = int Function( + ffi.Pointer manager, + ffi.Pointer bounds, +); + +typedef _c_location_manager_remove_boundary = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer bounds, +); + +typedef _dart_location_manager_remove_boundary = int Function( + ffi.Pointer manager, + ffi.Pointer bounds, +); + +typedef location_bounds_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_location_manager_foreach_boundary = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_location_manager_foreach_boundary = int Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_location_manager_get_method = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer method, +); + +typedef _dart_location_manager_get_method = int Function( + ffi.Pointer manager, + ffi.Pointer method, +); + +typedef _c_location_manager_get_position = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer altitude, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer timestamp, +); + +typedef _dart_location_manager_get_position = int Function( + ffi.Pointer manager, + ffi.Pointer altitude, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer timestamp, +); + +typedef _c_location_manager_get_location = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer altitude, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer climb, + ffi.Pointer direction, + ffi.Pointer speed, + ffi.Pointer level, + ffi.Pointer horizontal, + ffi.Pointer vertical, + ffi.Pointer timestamp, +); + +typedef _dart_location_manager_get_location = int Function( + ffi.Pointer manager, + ffi.Pointer altitude, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer climb, + ffi.Pointer direction, + ffi.Pointer speed, + ffi.Pointer level, + ffi.Pointer horizontal, + ffi.Pointer vertical, + ffi.Pointer timestamp, +); + +typedef _c_location_manager_get_velocity = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer climb, + ffi.Pointer direction, + ffi.Pointer speed, + ffi.Pointer timestamp, +); + +typedef _dart_location_manager_get_velocity = int Function( + ffi.Pointer manager, + ffi.Pointer climb, + ffi.Pointer direction, + ffi.Pointer speed, + ffi.Pointer timestamp, +); + +typedef _c_location_manager_get_accuracy = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer level, + ffi.Pointer horizontal, + ffi.Pointer vertical, +); + +typedef _dart_location_manager_get_accuracy = int Function( + ffi.Pointer manager, + ffi.Pointer level, + ffi.Pointer horizontal, + ffi.Pointer vertical, +); + +typedef _c_location_manager_get_last_position = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer altitude, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer timestamp, +); + +typedef _dart_location_manager_get_last_position = int Function( + ffi.Pointer manager, + ffi.Pointer altitude, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer timestamp, +); + +typedef _c_location_manager_get_last_location = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer altitude, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer climb, + ffi.Pointer direction, + ffi.Pointer speed, + ffi.Pointer level, + ffi.Pointer horizontal, + ffi.Pointer vertical, + ffi.Pointer timestamp, +); + +typedef _dart_location_manager_get_last_location = int Function( + ffi.Pointer manager, + ffi.Pointer altitude, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer climb, + ffi.Pointer direction, + ffi.Pointer speed, + ffi.Pointer level, + ffi.Pointer horizontal, + ffi.Pointer vertical, + ffi.Pointer timestamp, +); + +typedef _c_location_manager_get_last_velocity = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer climb, + ffi.Pointer direction, + ffi.Pointer speed, + ffi.Pointer timestamp, +); + +typedef _dart_location_manager_get_last_velocity = int Function( + ffi.Pointer manager, + ffi.Pointer climb, + ffi.Pointer direction, + ffi.Pointer speed, + ffi.Pointer timestamp, +); + +typedef _c_location_manager_get_last_accuracy = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer level, + ffi.Pointer horizontal, + ffi.Pointer vertical, +); + +typedef _dart_location_manager_get_last_accuracy = int Function( + ffi.Pointer manager, + ffi.Pointer level, + ffi.Pointer horizontal, + ffi.Pointer vertical, +); + +typedef _c_location_manager_get_accessibility_state = ffi.Int32 Function( + ffi.Pointer state, +); + +typedef _dart_location_manager_get_accessibility_state = int Function( + ffi.Pointer state, +); + +typedef location_position_updated_cb = ffi.Void Function( + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Int64, + ffi.Pointer, +); + +typedef _c_location_manager_set_position_updated_cb = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Int32 interval, + ffi.Pointer user_data, +); + +typedef _dart_location_manager_set_position_updated_cb = int Function( + ffi.Pointer manager, + ffi.Pointer> callback, + int interval, + ffi.Pointer user_data, +); + +typedef _c_location_manager_unset_position_updated_cb = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_location_manager_unset_position_updated_cb = int Function( + ffi.Pointer manager, +); + +typedef location_velocity_updated_cb = ffi.Void Function( + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Int64, + ffi.Pointer, +); + +typedef _c_location_manager_set_velocity_updated_cb = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Int32 interval, + ffi.Pointer user_data, +); + +typedef _dart_location_manager_set_velocity_updated_cb = int Function( + ffi.Pointer manager, + ffi.Pointer> callback, + int interval, + ffi.Pointer user_data, +); + +typedef _c_location_manager_unset_velocity_updated_cb = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_location_manager_unset_velocity_updated_cb = int Function( + ffi.Pointer manager, +); + +typedef location_service_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_location_manager_set_service_state_changed_cb = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_location_manager_set_service_state_changed_cb = int Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_location_manager_unset_service_state_changed_cb = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_location_manager_unset_service_state_changed_cb = int Function( + ffi.Pointer manager, +); + +typedef location_zone_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Int64, + ffi.Pointer, +); + +typedef _c_location_manager_set_zone_changed_cb = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_location_manager_set_zone_changed_cb = int Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_location_manager_unset_zone_changed_cb = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_location_manager_unset_zone_changed_cb = int Function( + ffi.Pointer manager, +); + +typedef location_setting_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_location_manager_set_setting_changed_cb = ffi.Int32 Function( + ffi.Int32 method, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_location_manager_set_setting_changed_cb = int Function( + int method, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_location_manager_unset_setting_changed_cb = ffi.Int32 Function( + ffi.Int32 method, +); + +typedef _dart_location_manager_unset_setting_changed_cb = int Function( + int method, +); + +typedef _c_location_manager_get_distance = ffi.Int32 Function( + ffi.Double start_latitude, + ffi.Double start_longitude, + ffi.Double end_latitude, + ffi.Double end_longitude, + ffi.Pointer distance, +); + +typedef _dart_location_manager_get_distance = int Function( + double start_latitude, + double start_longitude, + double end_latitude, + double end_longitude, + ffi.Pointer distance, +); + +typedef location_changed_cb = ffi.Void Function( + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Int64, + ffi.Pointer, +); + +typedef _c_location_manager_set_distance_based_location_changed_cb = ffi.Int32 + Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Int32 interval, + ffi.Double distance, + ffi.Pointer user_data, +); + +typedef _dart_location_manager_set_distance_based_location_changed_cb = int + Function( + ffi.Pointer manager, + ffi.Pointer> callback, + int interval, + double distance, + ffi.Pointer user_data, +); + +typedef _c_location_manager_unset_distance_based_location_changed_cb = ffi.Int32 + Function( + ffi.Pointer manager, +); + +typedef _dart_location_manager_unset_distance_based_location_changed_cb = int + Function( + ffi.Pointer manager, +); + +typedef _c_location_manager_set_location_changed_cb = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Int32 interval, + ffi.Pointer user_data, +); + +typedef _dart_location_manager_set_location_changed_cb = int Function( + ffi.Pointer manager, + ffi.Pointer> callback, + int interval, + ffi.Pointer user_data, +); + +typedef _c_location_manager_unset_location_changed_cb = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_location_manager_unset_location_changed_cb = int Function( + ffi.Pointer manager, +); + +typedef location_batch_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_location_manager_set_location_batch_cb = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Int32 batch_interval, + ffi.Int32 batch_period, + ffi.Pointer user_data, +); + +typedef _dart_location_manager_set_location_batch_cb = int Function( + ffi.Pointer manager, + ffi.Pointer> callback, + int batch_interval, + int batch_period, + ffi.Pointer user_data, +); + +typedef _c_location_manager_unset_location_batch_cb = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_location_manager_unset_location_batch_cb = int Function( + ffi.Pointer manager, +); + +typedef _c_location_manager_start_batch = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_location_manager_start_batch = int Function( + ffi.Pointer manager, +); + +typedef _c_location_manager_stop_batch = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_location_manager_stop_batch = int Function( + ffi.Pointer manager, +); + +typedef location_batch_get_location_cb = ffi.Uint8 Function( + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Int64, + ffi.Pointer, +); + +typedef _c_location_manager_foreach_location_batch = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_location_manager_foreach_location_batch = int Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_location_manager_is_enabled_mock_location = ffi.Int32 Function( + ffi.Pointer enabled, +); + +typedef _dart_location_manager_is_enabled_mock_location = int Function( + ffi.Pointer enabled, +); + +typedef _c_location_manager_enable_mock_location = ffi.Int32 Function( + ffi.Uint8 enable, +); + +typedef _dart_location_manager_enable_mock_location = int Function( + int enable, +); + +typedef _c_location_manager_set_mock_location = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Double latitude, + ffi.Double longitude, + ffi.Double altitude, + ffi.Double speed, + ffi.Double direction, + ffi.Double accuracy, +); + +typedef _dart_location_manager_set_mock_location = int Function( + ffi.Pointer manager, + double latitude, + double longitude, + double altitude, + double speed, + double direction, + double accuracy, +); + +typedef _c_location_manager_clear_mock_location = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_location_manager_clear_mock_location = int Function( + ffi.Pointer manager, +); + +typedef _c_location_manager_set_fused_mode = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Int32 mode, +); + +typedef _dart_location_manager_set_fused_mode = int Function( + ffi.Pointer manager, + int mode, +); + +typedef _c_gps_status_get_nmea = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer> nmea, +); + +typedef _dart_gps_status_get_nmea = int Function( + ffi.Pointer manager, + ffi.Pointer> nmea, +); + +typedef _c_gps_status_get_satellite = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer num_of_active, + ffi.Pointer num_of_inview, + ffi.Pointer timestamp, +); + +typedef _dart_gps_status_get_satellite = int Function( + ffi.Pointer manager, + ffi.Pointer num_of_active, + ffi.Pointer num_of_inview, + ffi.Pointer timestamp, +); + +typedef gps_status_satellite_updated_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Int64, + ffi.Pointer, +); + +typedef _c_gps_status_set_satellite_updated_cb = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Int32 interval, + ffi.Pointer user_data, +); + +typedef _dart_gps_status_set_satellite_updated_cb = int Function( + ffi.Pointer manager, + ffi.Pointer> callback, + int interval, + ffi.Pointer user_data, +); + +typedef _c_gps_status_unset_satellite_updated_cb = ffi.Int32 Function( + ffi.Pointer manager, +); + +typedef _dart_gps_status_unset_satellite_updated_cb = int Function( + ffi.Pointer manager, +); + +typedef gps_status_get_satellites_cb = ffi.Uint8 Function( + ffi.Uint32, + ffi.Uint32, + ffi.Uint32, + ffi.Int32, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_gps_status_foreach_satellites_in_view = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_gps_status_foreach_satellites_in_view = int Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_gps_status_get_last_satellite = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer num_of_active, + ffi.Pointer num_of_inview, + ffi.Pointer timestamp, +); + +typedef _dart_gps_status_get_last_satellite = int Function( + ffi.Pointer manager, + ffi.Pointer num_of_active, + ffi.Pointer num_of_inview, + ffi.Pointer timestamp, +); + +typedef _c_gps_status_foreach_last_satellites_in_view = ffi.Int32 Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_gps_status_foreach_last_satellites_in_view = int Function( + ffi.Pointer manager, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_maps_address_create = ffi.Int32 Function( + ffi.Pointer> address, +); + +typedef _dart_maps_address_create = int Function( + ffi.Pointer> address, +); + +typedef _c_maps_address_destroy = ffi.Int32 Function( + ffi.Pointer address, +); + +typedef _dart_maps_address_destroy = int Function( + ffi.Pointer address, +); + +typedef _c_maps_address_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_address_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_address_get_building_number = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer> building_number, +); + +typedef _dart_maps_address_get_building_number = int Function( + ffi.Pointer address, + ffi.Pointer> building_number, +); + +typedef _c_maps_address_get_street = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer> street, +); + +typedef _dart_maps_address_get_street = int Function( + ffi.Pointer address, + ffi.Pointer> street, +); + +typedef _c_maps_address_get_district = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer> district, +); + +typedef _dart_maps_address_get_district = int Function( + ffi.Pointer address, + ffi.Pointer> district, +); + +typedef _c_maps_address_get_city = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer> city, +); + +typedef _dart_maps_address_get_city = int Function( + ffi.Pointer address, + ffi.Pointer> city, +); + +typedef _c_maps_address_get_state = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer> state, +); + +typedef _dart_maps_address_get_state = int Function( + ffi.Pointer address, + ffi.Pointer> state, +); + +typedef _c_maps_address_get_country = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer> country, +); + +typedef _dart_maps_address_get_country = int Function( + ffi.Pointer address, + ffi.Pointer> country, +); + +typedef _c_maps_address_get_country_code = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer> country_code, +); + +typedef _dart_maps_address_get_country_code = int Function( + ffi.Pointer address, + ffi.Pointer> country_code, +); + +typedef _c_maps_address_get_county = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer> county, +); + +typedef _dart_maps_address_get_county = int Function( + ffi.Pointer address, + ffi.Pointer> county, +); + +typedef _c_maps_address_get_postal_code = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer> postal_code, +); + +typedef _dart_maps_address_get_postal_code = int Function( + ffi.Pointer address, + ffi.Pointer> postal_code, +); + +typedef _c_maps_address_get_freetext = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer> freetext, +); + +typedef _dart_maps_address_get_freetext = int Function( + ffi.Pointer address, + ffi.Pointer> freetext, +); + +typedef _c_maps_address_set_building_number = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer building_number, +); + +typedef _dart_maps_address_set_building_number = int Function( + ffi.Pointer address, + ffi.Pointer building_number, +); + +typedef _c_maps_address_set_street = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer street, +); + +typedef _dart_maps_address_set_street = int Function( + ffi.Pointer address, + ffi.Pointer street, +); + +typedef _c_maps_address_set_district = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer district, +); + +typedef _dart_maps_address_set_district = int Function( + ffi.Pointer address, + ffi.Pointer district, +); + +typedef _c_maps_address_set_city = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer city, +); + +typedef _dart_maps_address_set_city = int Function( + ffi.Pointer address, + ffi.Pointer city, +); + +typedef _c_maps_address_set_state = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer state, +); + +typedef _dart_maps_address_set_state = int Function( + ffi.Pointer address, + ffi.Pointer state, +); + +typedef _c_maps_address_set_country = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer country, +); + +typedef _dart_maps_address_set_country = int Function( + ffi.Pointer address, + ffi.Pointer country, +); + +typedef _c_maps_address_set_country_code = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer country_code, +); + +typedef _dart_maps_address_set_country_code = int Function( + ffi.Pointer address, + ffi.Pointer country_code, +); + +typedef _c_maps_address_set_county = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer county, +); + +typedef _dart_maps_address_set_county = int Function( + ffi.Pointer address, + ffi.Pointer county, +); + +typedef _c_maps_address_set_postal_code = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer postal_code, +); + +typedef _dart_maps_address_set_postal_code = int Function( + ffi.Pointer address, + ffi.Pointer postal_code, +); + +typedef _c_maps_address_set_freetext = ffi.Int32 Function( + ffi.Pointer address, + ffi.Pointer freetext, +); + +typedef _dart_maps_address_set_freetext = int Function( + ffi.Pointer address, + ffi.Pointer freetext, +); + +typedef _c_maps_address_list_create = ffi.Int32 Function( + ffi.Pointer> address_list, +); + +typedef _dart_maps_address_list_create = int Function( + ffi.Pointer> address_list, +); + +typedef _c_maps_address_list_append = ffi.Int32 Function( + ffi.Pointer address_list, + ffi.Pointer address, +); + +typedef _dart_maps_address_list_append = int Function( + ffi.Pointer address_list, + ffi.Pointer address, +); + +typedef _c_maps_address_list_remove = ffi.Int32 Function( + ffi.Pointer address_list, + ffi.Pointer address, +); + +typedef _dart_maps_address_list_remove = int Function( + ffi.Pointer address_list, + ffi.Pointer address, +); + +typedef _c_maps_address_list_get_length = ffi.Int32 Function( + ffi.Pointer address_list, + ffi.Pointer length, +); + +typedef _dart_maps_address_list_get_length = int Function( + ffi.Pointer address_list, + ffi.Pointer length, +); + +typedef maps_address_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_address_list_foreach = ffi.Int32 Function( + ffi.Pointer address_list, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_address_list_foreach = int Function( + ffi.Pointer address_list, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_maps_address_list_destroy = ffi.Int32 Function( + ffi.Pointer address_list, +); + +typedef _dart_maps_address_list_destroy = int Function( + ffi.Pointer address_list, +); + +typedef _c_maps_coordinates_create = ffi.Int32 Function( + ffi.Double latitude, + ffi.Double longitude, + ffi.Pointer> coordinates, +); + +typedef _dart_maps_coordinates_create = int Function( + double latitude, + double longitude, + ffi.Pointer> coordinates, +); + +typedef _c_maps_coordinates_destroy = ffi.Int32 Function( + ffi.Pointer coordinates, +); + +typedef _dart_maps_coordinates_destroy = int Function( + ffi.Pointer coordinates, +); + +typedef _c_maps_coordinates_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_coordinates_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_coordinates_get_latitude = ffi.Int32 Function( + ffi.Pointer coordinates, + ffi.Pointer latitude, +); + +typedef _dart_maps_coordinates_get_latitude = int Function( + ffi.Pointer coordinates, + ffi.Pointer latitude, +); + +typedef _c_maps_coordinates_get_longitude = ffi.Int32 Function( + ffi.Pointer coordinates, + ffi.Pointer longitude, +); + +typedef _dart_maps_coordinates_get_longitude = int Function( + ffi.Pointer coordinates, + ffi.Pointer longitude, +); + +typedef _c_maps_coordinates_get_latitude_longitude = ffi.Int32 Function( + ffi.Pointer coordinates, + ffi.Pointer latitude, + ffi.Pointer longitude, +); + +typedef _dart_maps_coordinates_get_latitude_longitude = int Function( + ffi.Pointer coordinates, + ffi.Pointer latitude, + ffi.Pointer longitude, +); + +typedef _c_maps_coordinates_set_latitude = ffi.Int32 Function( + ffi.Pointer coordinates, + ffi.Double latitude, +); + +typedef _dart_maps_coordinates_set_latitude = int Function( + ffi.Pointer coordinates, + double latitude, +); + +typedef _c_maps_coordinates_set_longitude = ffi.Int32 Function( + ffi.Pointer coordinates, + ffi.Double longitude, +); + +typedef _dart_maps_coordinates_set_longitude = int Function( + ffi.Pointer coordinates, + double longitude, +); + +typedef _c_maps_coordinates_set_latitude_longitude = ffi.Int32 Function( + ffi.Pointer coordinates, + ffi.Double latitude, + ffi.Double longitude, +); + +typedef _dart_maps_coordinates_set_latitude_longitude = int Function( + ffi.Pointer coordinates, + double latitude, + double longitude, +); + +typedef _c_maps_coordinates_list_create = ffi.Int32 Function( + ffi.Pointer> coordinates_list, +); + +typedef _dart_maps_coordinates_list_create = int Function( + ffi.Pointer> coordinates_list, +); + +typedef _c_maps_coordinates_list_destroy = ffi.Int32 Function( + ffi.Pointer coordinates_list, +); + +typedef _dart_maps_coordinates_list_destroy = int Function( + ffi.Pointer coordinates_list, +); + +typedef _c_maps_coordinates_list_append = ffi.Int32 Function( + ffi.Pointer coordinates_list, + ffi.Pointer coordinates, +); + +typedef _dart_maps_coordinates_list_append = int Function( + ffi.Pointer coordinates_list, + ffi.Pointer coordinates, +); + +typedef _c_maps_coordinates_list_remove = ffi.Int32 Function( + ffi.Pointer coordinates_list, + ffi.Pointer coordinates, +); + +typedef _dart_maps_coordinates_list_remove = int Function( + ffi.Pointer coordinates_list, + ffi.Pointer coordinates, +); + +typedef _c_maps_coordinates_list_get_length = ffi.Int32 Function( + ffi.Pointer coordinates_list, + ffi.Pointer length, +); + +typedef _dart_maps_coordinates_list_get_length = int Function( + ffi.Pointer coordinates_list, + ffi.Pointer length, +); + +typedef maps_coordinates_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_coordinates_list_foreach = ffi.Int32 Function( + ffi.Pointer coordinates_list, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_coordinates_list_foreach = int Function( + ffi.Pointer coordinates_list, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_maps_area_create_rectangle = ffi.Int32 Function( + ffi.Pointer top_left, + ffi.Pointer bottom_right, + ffi.Pointer> area, +); + +typedef _dart_maps_area_create_rectangle = int Function( + ffi.Pointer top_left, + ffi.Pointer bottom_right, + ffi.Pointer> area, +); + +typedef _c_maps_area_create_circle = ffi.Int32 Function( + ffi.Pointer center, + ffi.Double radius, + ffi.Pointer> area, +); + +typedef _dart_maps_area_create_circle = int Function( + ffi.Pointer center, + double radius, + ffi.Pointer> area, +); + +typedef _c_maps_area_destroy = ffi.Int32 Function( + ffi.Pointer area, +); + +typedef _dart_maps_area_destroy = int Function( + ffi.Pointer area, +); + +typedef _c_maps_area_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_area_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_place_category_create = ffi.Int32 Function( + ffi.Pointer> category, +); + +typedef _dart_maps_place_category_create = int Function( + ffi.Pointer> category, +); + +typedef _c_maps_place_category_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_place_category_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_place_category_destroy = ffi.Int32 Function( + ffi.Pointer category, +); + +typedef _dart_maps_place_category_destroy = int Function( + ffi.Pointer category, +); + +typedef _c_maps_place_category_get_id = ffi.Int32 Function( + ffi.Pointer category, + ffi.Pointer> id, +); + +typedef _dart_maps_place_category_get_id = int Function( + ffi.Pointer category, + ffi.Pointer> id, +); + +typedef _c_maps_place_category_get_name = ffi.Int32 Function( + ffi.Pointer category, + ffi.Pointer> name, +); + +typedef _dart_maps_place_category_get_name = int Function( + ffi.Pointer category, + ffi.Pointer> name, +); + +typedef _c_maps_place_category_get_url = ffi.Int32 Function( + ffi.Pointer category, + ffi.Pointer> url, +); + +typedef _dart_maps_place_category_get_url = int Function( + ffi.Pointer category, + ffi.Pointer> url, +); + +typedef _c_maps_place_category_set_id = ffi.Int32 Function( + ffi.Pointer category, + ffi.Pointer id, +); + +typedef _dart_maps_place_category_set_id = int Function( + ffi.Pointer category, + ffi.Pointer id, +); + +typedef _c_maps_place_category_set_name = ffi.Int32 Function( + ffi.Pointer category, + ffi.Pointer name, +); + +typedef _dart_maps_place_category_set_name = int Function( + ffi.Pointer category, + ffi.Pointer name, +); + +typedef _c_maps_place_category_set_url = ffi.Int32 Function( + ffi.Pointer category, + ffi.Pointer url, +); + +typedef _dart_maps_place_category_set_url = int Function( + ffi.Pointer category, + ffi.Pointer url, +); + +typedef _c_maps_place_attribute_destroy = ffi.Int32 Function( + ffi.Pointer attribute, +); + +typedef _dart_maps_place_attribute_destroy = int Function( + ffi.Pointer attribute, +); + +typedef _c_maps_place_attribute_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_place_attribute_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_place_attribute_get_id = ffi.Int32 Function( + ffi.Pointer attribute, + ffi.Pointer> id, +); + +typedef _dart_maps_place_attribute_get_id = int Function( + ffi.Pointer attribute, + ffi.Pointer> id, +); + +typedef _c_maps_place_attribute_get_label = ffi.Int32 Function( + ffi.Pointer attribute, + ffi.Pointer> label, +); + +typedef _dart_maps_place_attribute_get_label = int Function( + ffi.Pointer attribute, + ffi.Pointer> label, +); + +typedef _c_maps_place_attribute_get_text = ffi.Int32 Function( + ffi.Pointer attribute, + ffi.Pointer> text, +); + +typedef _dart_maps_place_attribute_get_text = int Function( + ffi.Pointer attribute, + ffi.Pointer> text, +); + +typedef _c_maps_place_contact_destroy = ffi.Int32 Function( + ffi.Pointer contact, +); + +typedef _dart_maps_place_contact_destroy = int Function( + ffi.Pointer contact, +); + +typedef _c_maps_place_contact_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_place_contact_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_place_contact_get_label = ffi.Int32 Function( + ffi.Pointer contact, + ffi.Pointer> label, +); + +typedef _dart_maps_place_contact_get_label = int Function( + ffi.Pointer contact, + ffi.Pointer> label, +); + +typedef _c_maps_place_contact_get_type = ffi.Int32 Function( + ffi.Pointer contact, + ffi.Pointer> type, +); + +typedef _dart_maps_place_contact_get_type = int Function( + ffi.Pointer contact, + ffi.Pointer> type, +); + +typedef _c_maps_place_contact_get_value = ffi.Int32 Function( + ffi.Pointer contact, + ffi.Pointer> value, +); + +typedef _dart_maps_place_contact_get_value = int Function( + ffi.Pointer contact, + ffi.Pointer> value, +); + +typedef _c_maps_place_link_object_destroy = ffi.Int32 Function( + ffi.Pointer link, +); + +typedef _dart_maps_place_link_object_destroy = int Function( + ffi.Pointer link, +); + +typedef _c_maps_place_link_object_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_place_link_object_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_place_link_object_get_id = ffi.Int32 Function( + ffi.Pointer link, + ffi.Pointer> id, +); + +typedef _dart_maps_place_link_object_get_id = int Function( + ffi.Pointer link, + ffi.Pointer> id, +); + +typedef _c_maps_place_link_object_get_name = ffi.Int32 Function( + ffi.Pointer link, + ffi.Pointer> name, +); + +typedef _dart_maps_place_link_object_get_name = int Function( + ffi.Pointer link, + ffi.Pointer> name, +); + +typedef _c_maps_place_link_object_get_string = ffi.Int32 Function( + ffi.Pointer link, + ffi.Pointer> string, +); + +typedef _dart_maps_place_link_object_get_string = int Function( + ffi.Pointer link, + ffi.Pointer> string, +); + +typedef _c_maps_place_link_object_get_type = ffi.Int32 Function( + ffi.Pointer link, + ffi.Pointer> type, +); + +typedef _dart_maps_place_link_object_get_type = int Function( + ffi.Pointer link, + ffi.Pointer> type, +); + +typedef _c_maps_place_media_destroy = ffi.Int32 Function( + ffi.Pointer media, +); + +typedef _dart_maps_place_media_destroy = int Function( + ffi.Pointer media, +); + +typedef _c_maps_place_media_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_place_media_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_place_media_get_attribution = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> attribution, +); + +typedef _dart_maps_place_media_get_attribution = int Function( + ffi.Pointer media, + ffi.Pointer> attribution, +); + +typedef _c_maps_place_media_get_supplier = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> supplier, +); + +typedef _dart_maps_place_media_get_supplier = int Function( + ffi.Pointer media, + ffi.Pointer> supplier, +); + +typedef _c_maps_place_media_get_via = ffi.Int32 Function( + ffi.Pointer media, + ffi.Pointer> via, +); + +typedef _dart_maps_place_media_get_via = int Function( + ffi.Pointer media, + ffi.Pointer> via, +); + +typedef _c_maps_place_editorial_destroy = ffi.Int32 Function( + ffi.Pointer editorial, +); + +typedef _dart_maps_place_editorial_destroy = int Function( + ffi.Pointer editorial, +); + +typedef _c_maps_place_editorial_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_place_editorial_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_place_editorial_get_description = ffi.Int32 Function( + ffi.Pointer editorial, + ffi.Pointer> description, +); + +typedef _dart_maps_place_editorial_get_description = int Function( + ffi.Pointer editorial, + ffi.Pointer> description, +); + +typedef _c_maps_place_editorial_get_language = ffi.Int32 Function( + ffi.Pointer editorial, + ffi.Pointer> language, +); + +typedef _dart_maps_place_editorial_get_language = int Function( + ffi.Pointer editorial, + ffi.Pointer> language, +); + +typedef _c_maps_place_editorial_get_media = ffi.Int32 Function( + ffi.Pointer editorial, + ffi.Pointer> media, +); + +typedef _dart_maps_place_editorial_get_media = int Function( + ffi.Pointer editorial, + ffi.Pointer> media, +); + +typedef _c_maps_place_image_destroy = ffi.Int32 Function( + ffi.Pointer image, +); + +typedef _dart_maps_place_image_destroy = int Function( + ffi.Pointer image, +); + +typedef _c_maps_place_image_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_place_image_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_place_image_get_id = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer> id, +); + +typedef _dart_maps_place_image_get_id = int Function( + ffi.Pointer image, + ffi.Pointer> id, +); + +typedef _c_maps_place_image_get_url = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer> url, +); + +typedef _dart_maps_place_image_get_url = int Function( + ffi.Pointer image, + ffi.Pointer> url, +); + +typedef _c_maps_place_image_get_width = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer width, +); + +typedef _dart_maps_place_image_get_width = int Function( + ffi.Pointer image, + ffi.Pointer width, +); + +typedef _c_maps_place_image_get_height = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer height, +); + +typedef _dart_maps_place_image_get_height = int Function( + ffi.Pointer image, + ffi.Pointer height, +); + +typedef _c_maps_place_image_get_user_link = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer> user, +); + +typedef _dart_maps_place_image_get_user_link = int Function( + ffi.Pointer image, + ffi.Pointer> user, +); + +typedef _c_maps_place_image_get_media = ffi.Int32 Function( + ffi.Pointer image, + ffi.Pointer> media, +); + +typedef _dart_maps_place_image_get_media = int Function( + ffi.Pointer image, + ffi.Pointer> media, +); + +typedef _c_maps_place_review_destroy = ffi.Int32 Function( + ffi.Pointer review, +); + +typedef _dart_maps_place_review_destroy = int Function( + ffi.Pointer review, +); + +typedef _c_maps_place_review_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_place_review_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_place_review_get_date = ffi.Int32 Function( + ffi.Pointer review, + ffi.Pointer> date, +); + +typedef _dart_maps_place_review_get_date = int Function( + ffi.Pointer review, + ffi.Pointer> date, +); + +typedef _c_maps_place_review_get_title = ffi.Int32 Function( + ffi.Pointer review, + ffi.Pointer> title, +); + +typedef _dart_maps_place_review_get_title = int Function( + ffi.Pointer review, + ffi.Pointer> title, +); + +typedef _c_maps_place_review_get_rating = ffi.Int32 Function( + ffi.Pointer review, + ffi.Pointer rating, +); + +typedef _dart_maps_place_review_get_rating = int Function( + ffi.Pointer review, + ffi.Pointer rating, +); + +typedef _c_maps_place_review_get_description = ffi.Int32 Function( + ffi.Pointer review, + ffi.Pointer> description, +); + +typedef _dart_maps_place_review_get_description = int Function( + ffi.Pointer review, + ffi.Pointer> description, +); + +typedef _c_maps_place_review_get_language = ffi.Int32 Function( + ffi.Pointer review, + ffi.Pointer> language, +); + +typedef _dart_maps_place_review_get_language = int Function( + ffi.Pointer review, + ffi.Pointer> language, +); + +typedef _c_maps_place_review_get_media = ffi.Int32 Function( + ffi.Pointer review, + ffi.Pointer> media, +); + +typedef _dart_maps_place_review_get_media = int Function( + ffi.Pointer review, + ffi.Pointer> media, +); + +typedef _c_maps_place_review_get_user_link = ffi.Int32 Function( + ffi.Pointer review, + ffi.Pointer> user, +); + +typedef _dart_maps_place_review_get_user_link = int Function( + ffi.Pointer review, + ffi.Pointer> user, +); + +typedef _c_maps_place_rating_destroy = ffi.Int32 Function( + ffi.Pointer rating, +); + +typedef _dart_maps_place_rating_destroy = int Function( + ffi.Pointer rating, +); + +typedef _c_maps_place_rating_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_place_rating_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_place_rating_get_count = ffi.Int32 Function( + ffi.Pointer rating, + ffi.Pointer count, +); + +typedef _dart_maps_place_rating_get_count = int Function( + ffi.Pointer rating, + ffi.Pointer count, +); + +typedef _c_maps_place_rating_get_average = ffi.Int32 Function( + ffi.Pointer rating, + ffi.Pointer average, +); + +typedef _dart_maps_place_rating_get_average = int Function( + ffi.Pointer rating, + ffi.Pointer average, +); + +typedef _c_maps_place_destroy = ffi.Int32 Function( + ffi.Pointer place, +); + +typedef _dart_maps_place_destroy = int Function( + ffi.Pointer place, +); + +typedef _c_maps_place_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_place_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_place_get_id = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> id, +); + +typedef _dart_maps_place_get_id = int Function( + ffi.Pointer place, + ffi.Pointer> id, +); + +typedef _c_maps_place_get_name = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> name, +); + +typedef _dart_maps_place_get_name = int Function( + ffi.Pointer place, + ffi.Pointer> name, +); + +typedef _c_maps_place_get_uri = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> uri, +); + +typedef _dart_maps_place_get_uri = int Function( + ffi.Pointer place, + ffi.Pointer> uri, +); + +typedef _c_maps_place_get_location = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> location, +); + +typedef _dart_maps_place_get_location = int Function( + ffi.Pointer place, + ffi.Pointer> location, +); + +typedef _c_maps_place_get_distance = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer distance, +); + +typedef _dart_maps_place_get_distance = int Function( + ffi.Pointer place, + ffi.Pointer distance, +); + +typedef _c_maps_place_get_address = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> address, +); + +typedef _dart_maps_place_get_address = int Function( + ffi.Pointer place, + ffi.Pointer> address, +); + +typedef _c_maps_place_get_rating = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> rating, +); + +typedef _dart_maps_place_get_rating = int Function( + ffi.Pointer place, + ffi.Pointer> rating, +); + +typedef maps_place_properties_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_place_foreach_property = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_place_foreach_property = int Function( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef maps_place_categories_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_place_foreach_category = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_place_foreach_category = int Function( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef maps_place_attributes_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_place_foreach_attribute = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_place_foreach_attribute = int Function( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef maps_place_contacts_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_place_foreach_contact = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_place_foreach_contact = int Function( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef maps_place_editorials_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_place_foreach_editorial = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_place_foreach_editorial = int Function( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef maps_place_images_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_place_foreach_image = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_place_foreach_image = int Function( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef maps_place_reviews_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_place_foreach_review = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_place_foreach_review = int Function( + ffi.Pointer place, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_maps_place_get_supplier_link = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> supplier, +); + +typedef _dart_maps_place_get_supplier_link = int Function( + ffi.Pointer place, + ffi.Pointer> supplier, +); + +typedef _c_maps_place_get_related_link = ffi.Int32 Function( + ffi.Pointer place, + ffi.Pointer> related, +); + +typedef _dart_maps_place_get_related_link = int Function( + ffi.Pointer place, + ffi.Pointer> related, +); + +typedef maps_place_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_place_list_foreach = ffi.Int32 Function( + ffi.Pointer place_list, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_place_list_foreach = int Function( + ffi.Pointer place_list, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_maps_place_list_destroy = ffi.Int32 Function( + ffi.Pointer place_list, +); + +typedef _dart_maps_place_list_destroy = int Function( + ffi.Pointer place_list, +); + +typedef _c_maps_place_filter_create = ffi.Int32 Function( + ffi.Pointer> filter, +); + +typedef _dart_maps_place_filter_create = int Function( + ffi.Pointer> filter, +); + +typedef _c_maps_place_filter_destroy = ffi.Int32 Function( + ffi.Pointer filter, +); + +typedef _dart_maps_place_filter_destroy = int Function( + ffi.Pointer filter, +); + +typedef _c_maps_place_filter_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_place_filter_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_place_filter_get = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer key, + ffi.Pointer> value, +); + +typedef _dart_maps_place_filter_get = int Function( + ffi.Pointer filter, + ffi.Pointer key, + ffi.Pointer> value, +); + +typedef _c_maps_place_filter_get_keyword = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> keyword, +); + +typedef _dart_maps_place_filter_get_keyword = int Function( + ffi.Pointer filter, + ffi.Pointer> keyword, +); + +typedef _c_maps_place_filter_get_place_name = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> place_name, +); + +typedef _dart_maps_place_filter_get_place_name = int Function( + ffi.Pointer filter, + ffi.Pointer> place_name, +); + +typedef _c_maps_place_filter_get_category = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> category, +); + +typedef _dart_maps_place_filter_get_category = int Function( + ffi.Pointer filter, + ffi.Pointer> category, +); + +typedef maps_place_filter_properties_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_place_filter_foreach_property = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_place_filter_foreach_property = int Function( + ffi.Pointer filter, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_maps_place_filter_get_place_address = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer> place_address, +); + +typedef _dart_maps_place_filter_get_place_address = int Function( + ffi.Pointer filter, + ffi.Pointer> place_address, +); + +typedef _c_maps_place_filter_set = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_maps_place_filter_set = int Function( + ffi.Pointer filter, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_maps_place_filter_set_keyword = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer keyword, +); + +typedef _dart_maps_place_filter_set_keyword = int Function( + ffi.Pointer filter, + ffi.Pointer keyword, +); + +typedef _c_maps_place_filter_set_place_name = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer place_name, +); + +typedef _dart_maps_place_filter_set_place_name = int Function( + ffi.Pointer filter, + ffi.Pointer place_name, +); + +typedef _c_maps_place_filter_set_category = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer category, +); + +typedef _dart_maps_place_filter_set_category = int Function( + ffi.Pointer filter, + ffi.Pointer category, +); + +typedef _c_maps_place_filter_set_place_address = ffi.Int32 Function( + ffi.Pointer filter, + ffi.Pointer place_address, +); + +typedef _dart_maps_place_filter_set_place_address = int Function( + ffi.Pointer filter, + ffi.Pointer place_address, +); + +typedef _c_maps_route_maneuver_destroy = ffi.Int32 Function( + ffi.Pointer maneuver, +); + +typedef _dart_maps_route_maneuver_destroy = int Function( + ffi.Pointer maneuver, +); + +typedef _c_maps_route_maneuver_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_route_maneuver_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_route_maneuver_get_direction_id = ffi.Int32 Function( + ffi.Pointer maneuver, + ffi.Pointer direction_id, +); + +typedef _dart_maps_route_maneuver_get_direction_id = int Function( + ffi.Pointer maneuver, + ffi.Pointer direction_id, +); + +typedef _c_maps_route_maneuver_get_turn_type = ffi.Int32 Function( + ffi.Pointer maneuver, + ffi.Pointer turn_type, +); + +typedef _dart_maps_route_maneuver_get_turn_type = int Function( + ffi.Pointer maneuver, + ffi.Pointer turn_type, +); + +typedef _c_maps_route_maneuver_get_position = ffi.Int32 Function( + ffi.Pointer maneuver, + ffi.Pointer> position, +); + +typedef _dart_maps_route_maneuver_get_position = int Function( + ffi.Pointer maneuver, + ffi.Pointer> position, +); + +typedef _c_maps_route_maneuver_get_road_name = ffi.Int32 Function( + ffi.Pointer maneuver, + ffi.Pointer> road_name, +); + +typedef _dart_maps_route_maneuver_get_road_name = int Function( + ffi.Pointer maneuver, + ffi.Pointer> road_name, +); + +typedef _c_maps_route_maneuver_get_instruction_text = ffi.Int32 Function( + ffi.Pointer maneuver, + ffi.Pointer> instruction_text, +); + +typedef _dart_maps_route_maneuver_get_instruction_text = int Function( + ffi.Pointer maneuver, + ffi.Pointer> instruction_text, +); + +typedef _c_maps_route_maneuver_get_locale = ffi.Int32 Function( + ffi.Pointer maneuver, + ffi.Pointer> locale, +); + +typedef _dart_maps_route_maneuver_get_locale = int Function( + ffi.Pointer maneuver, + ffi.Pointer> locale, +); + +typedef _c_maps_route_maneuver_get_time_to_next_instruction = ffi.Int32 + Function( + ffi.Pointer maneuver, + ffi.Pointer time_to_next_instruction, +); + +typedef _dart_maps_route_maneuver_get_time_to_next_instruction = int Function( + ffi.Pointer maneuver, + ffi.Pointer time_to_next_instruction, +); + +typedef _c_maps_route_maneuver_get_distance_to_next_instruction = ffi.Int32 + Function( + ffi.Pointer maneuver, + ffi.Pointer distance_to_next_instruction, +); + +typedef _dart_maps_route_maneuver_get_distance_to_next_instruction = int + Function( + ffi.Pointer maneuver, + ffi.Pointer distance_to_next_instruction, +); + +typedef _c_maps_route_segment_destroy = ffi.Int32 Function( + ffi.Pointer segment, +); + +typedef _dart_maps_route_segment_destroy = int Function( + ffi.Pointer segment, +); + +typedef _c_maps_route_segment_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_route_segment_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_route_segment_get_origin = ffi.Int32 Function( + ffi.Pointer segment, + ffi.Pointer> origin, +); + +typedef _dart_maps_route_segment_get_origin = int Function( + ffi.Pointer segment, + ffi.Pointer> origin, +); + +typedef _c_maps_route_segment_get_destination = ffi.Int32 Function( + ffi.Pointer segment, + ffi.Pointer> destination, +); + +typedef _dart_maps_route_segment_get_destination = int Function( + ffi.Pointer segment, + ffi.Pointer> destination, +); + +typedef _c_maps_route_segment_get_bounding_box = ffi.Int32 Function( + ffi.Pointer segment, + ffi.Pointer> bounding_box, +); + +typedef _dart_maps_route_segment_get_bounding_box = int Function( + ffi.Pointer segment, + ffi.Pointer> bounding_box, +); + +typedef _c_maps_route_segment_get_distance = ffi.Int32 Function( + ffi.Pointer segment, + ffi.Pointer distance, +); + +typedef _dart_maps_route_segment_get_distance = int Function( + ffi.Pointer segment, + ffi.Pointer distance, +); + +typedef _c_maps_route_segment_get_duration = ffi.Int32 Function( + ffi.Pointer segment, + ffi.Pointer duration, +); + +typedef _dart_maps_route_segment_get_duration = int Function( + ffi.Pointer segment, + ffi.Pointer duration, +); + +typedef maps_route_segment_path_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_route_segment_foreach_path = ffi.Int32 Function( + ffi.Pointer segment, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_route_segment_foreach_path = int Function( + ffi.Pointer segment, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef maps_route_segment_maneuver_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_route_segment_foreach_maneuver = ffi.Int32 Function( + ffi.Pointer segment, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_route_segment_foreach_maneuver = int Function( + ffi.Pointer segment, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_maps_preference_create = ffi.Int32 Function( + ffi.Pointer> preference, +); + +typedef _dart_maps_preference_create = int Function( + ffi.Pointer> preference, +); + +typedef _c_maps_preference_destroy = ffi.Int32 Function( + ffi.Pointer preference, +); + +typedef _dart_maps_preference_destroy = int Function( + ffi.Pointer preference, +); + +typedef _c_maps_preference_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_preference_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_preference_get_distance_unit = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Pointer unit, +); + +typedef _dart_maps_preference_get_distance_unit = int Function( + ffi.Pointer preference, + ffi.Pointer unit, +); + +typedef _c_maps_preference_get_language = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Pointer> language, +); + +typedef _dart_maps_preference_get_language = int Function( + ffi.Pointer preference, + ffi.Pointer> language, +); + +typedef _c_maps_preference_get_max_results = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Pointer max_results, +); + +typedef _dart_maps_preference_get_max_results = int Function( + ffi.Pointer preference, + ffi.Pointer max_results, +); + +typedef _c_maps_preference_get_country_code = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Pointer> country_code, +); + +typedef _dart_maps_preference_get_country_code = int Function( + ffi.Pointer preference, + ffi.Pointer> country_code, +); + +typedef _c_maps_preference_get_route_optimization = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Pointer optimization, +); + +typedef _dart_maps_preference_get_route_optimization = int Function( + ffi.Pointer preference, + ffi.Pointer optimization, +); + +typedef _c_maps_preference_get_route_transport_mode = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Pointer transport_mode, +); + +typedef _dart_maps_preference_get_route_transport_mode = int Function( + ffi.Pointer preference, + ffi.Pointer transport_mode, +); + +typedef _c_maps_preference_get_route_feature_weight = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Pointer feature_weight, +); + +typedef _dart_maps_preference_get_route_feature_weight = int Function( + ffi.Pointer preference, + ffi.Pointer feature_weight, +); + +typedef _c_maps_preference_get_route_feature = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Pointer feature, +); + +typedef _dart_maps_preference_get_route_feature = int Function( + ffi.Pointer preference, + ffi.Pointer feature, +); + +typedef _c_maps_preference_get_route_alternatives_enabled = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Pointer enable, +); + +typedef _dart_maps_preference_get_route_alternatives_enabled = int Function( + ffi.Pointer preference, + ffi.Pointer enable, +); + +typedef _c_maps_preference_get = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Pointer key, + ffi.Pointer> value, +); + +typedef _dart_maps_preference_get = int Function( + ffi.Pointer preference, + ffi.Pointer key, + ffi.Pointer> value, +); + +typedef maps_preference_properties_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_preference_foreach_property = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_preference_foreach_property = int Function( + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_maps_preference_set_distance_unit = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Int32 unit, +); + +typedef _dart_maps_preference_set_distance_unit = int Function( + ffi.Pointer preference, + int unit, +); + +typedef _c_maps_preference_set_language = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Pointer language, +); + +typedef _dart_maps_preference_set_language = int Function( + ffi.Pointer preference, + ffi.Pointer language, +); + +typedef _c_maps_preference_set_max_results = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Int32 max_results, +); + +typedef _dart_maps_preference_set_max_results = int Function( + ffi.Pointer preference, + int max_results, +); + +typedef _c_maps_preference_set_country_code = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Pointer country_code, +); + +typedef _dart_maps_preference_set_country_code = int Function( + ffi.Pointer preference, + ffi.Pointer country_code, +); + +typedef _c_maps_preference_set_route_optimization = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Int32 optimization, +); + +typedef _dart_maps_preference_set_route_optimization = int Function( + ffi.Pointer preference, + int optimization, +); + +typedef _c_maps_preference_set_route_transport_mode = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Int32 transport_mode, +); + +typedef _dart_maps_preference_set_route_transport_mode = int Function( + ffi.Pointer preference, + int transport_mode, +); + +typedef _c_maps_preference_set_route_feature_weight = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Int32 feature_weight, +); + +typedef _dart_maps_preference_set_route_feature_weight = int Function( + ffi.Pointer preference, + int feature_weight, +); + +typedef _c_maps_preference_set_route_feature = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Int32 feature, +); + +typedef _dart_maps_preference_set_route_feature = int Function( + ffi.Pointer preference, + int feature, +); + +typedef _c_maps_preference_set_route_alternatives_enabled = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Uint8 enable, +); + +typedef _dart_maps_preference_set_route_alternatives_enabled = int Function( + ffi.Pointer preference, + int enable, +); + +typedef _c_maps_preference_set_property = ffi.Int32 Function( + ffi.Pointer preference, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_maps_preference_set_property = int Function( + ffi.Pointer preference, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_maps_route_destroy = ffi.Int32 Function( + ffi.Pointer route, +); + +typedef _dart_maps_route_destroy = int Function( + ffi.Pointer route, +); + +typedef _c_maps_route_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_route_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_route_get_route_id = ffi.Int32 Function( + ffi.Pointer route, + ffi.Pointer> route_id, +); + +typedef _dart_maps_route_get_route_id = int Function( + ffi.Pointer route, + ffi.Pointer> route_id, +); + +typedef _c_maps_route_get_origin = ffi.Int32 Function( + ffi.Pointer route, + ffi.Pointer> origin, +); + +typedef _dart_maps_route_get_origin = int Function( + ffi.Pointer route, + ffi.Pointer> origin, +); + +typedef _c_maps_route_get_destination = ffi.Int32 Function( + ffi.Pointer route, + ffi.Pointer> destination, +); + +typedef _dart_maps_route_get_destination = int Function( + ffi.Pointer route, + ffi.Pointer> destination, +); + +typedef _c_maps_route_get_bounding_box = ffi.Int32 Function( + ffi.Pointer route, + ffi.Pointer> bounding_box, +); + +typedef _dart_maps_route_get_bounding_box = int Function( + ffi.Pointer route, + ffi.Pointer> bounding_box, +); + +typedef _c_maps_route_get_transport_mode = ffi.Int32 Function( + ffi.Pointer route, + ffi.Pointer transport_mode, +); + +typedef _dart_maps_route_get_transport_mode = int Function( + ffi.Pointer route, + ffi.Pointer transport_mode, +); + +typedef _c_maps_route_get_total_distance = ffi.Int32 Function( + ffi.Pointer route, + ffi.Pointer total_distance, +); + +typedef _dart_maps_route_get_total_distance = int Function( + ffi.Pointer route, + ffi.Pointer total_distance, +); + +typedef _c_maps_route_get_total_duration = ffi.Int32 Function( + ffi.Pointer route, + ffi.Pointer total_duration, +); + +typedef _dart_maps_route_get_total_duration = int Function( + ffi.Pointer route, + ffi.Pointer total_duration, +); + +typedef _c_maps_route_get_distance_unit = ffi.Int32 Function( + ffi.Pointer route, + ffi.Pointer distance_unit, +); + +typedef _dart_maps_route_get_distance_unit = int Function( + ffi.Pointer route, + ffi.Pointer distance_unit, +); + +typedef maps_route_properties_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_route_foreach_property = ffi.Int32 Function( + ffi.Pointer route, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_route_foreach_property = int Function( + ffi.Pointer route, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef maps_route_path_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_route_foreach_path = ffi.Int32 Function( + ffi.Pointer route, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_route_foreach_path = int Function( + ffi.Pointer route, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef maps_route_segment_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_route_foreach_segment = ffi.Int32 Function( + ffi.Pointer route, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_route_foreach_segment = int Function( + ffi.Pointer route, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_maps_view_object_create_marker = ffi.Int32 Function( + ffi.Pointer coordinates, + ffi.Pointer image_file_path, + ffi.Int32 type, + ffi.Pointer> marker, +); + +typedef _dart_maps_view_object_create_marker = int Function( + ffi.Pointer coordinates, + ffi.Pointer image_file_path, + int type, + ffi.Pointer> marker, +); + +typedef _c_maps_view_object_create_polyline = ffi.Int32 Function( + ffi.Pointer coordinates, + ffi.Uint8 r, + ffi.Uint8 g, + ffi.Uint8 b, + ffi.Uint8 a, + ffi.Int32 width, + ffi.Pointer> polyline, +); + +typedef _dart_maps_view_object_create_polyline = int Function( + ffi.Pointer coordinates, + int r, + int g, + int b, + int a, + int width, + ffi.Pointer> polyline, +); + +typedef _c_maps_view_object_create_polygon = ffi.Int32 Function( + ffi.Pointer coordinates, + ffi.Uint8 r, + ffi.Uint8 g, + ffi.Uint8 b, + ffi.Uint8 a, + ffi.Pointer> polygon, +); + +typedef _dart_maps_view_object_create_polygon = int Function( + ffi.Pointer coordinates, + int r, + int g, + int b, + int a, + ffi.Pointer> polygon, +); + +typedef _c_maps_view_object_create_overlay = ffi.Int32 Function( + ffi.Pointer coordinates, + ffi.Pointer object, + ffi.Int32 type, + ffi.Pointer> overlay, +); + +typedef _dart_maps_view_object_create_overlay = int Function( + ffi.Pointer coordinates, + ffi.Pointer object, + int type, + ffi.Pointer> overlay, +); + +typedef _c_maps_view_object_destroy = ffi.Int32 Function( + ffi.Pointer object, +); + +typedef _dart_maps_view_object_destroy = int Function( + ffi.Pointer object, +); + +typedef _c_maps_view_object_get_type = ffi.Int32 Function( + ffi.Pointer object, + ffi.Pointer type, +); + +typedef _dart_maps_view_object_get_type = int Function( + ffi.Pointer object, + ffi.Pointer type, +); + +typedef _c_maps_view_object_set_visible = ffi.Int32 Function( + ffi.Pointer object, + ffi.Uint8 visible, +); + +typedef _dart_maps_view_object_set_visible = int Function( + ffi.Pointer object, + int visible, +); + +typedef _c_maps_view_object_get_visible = ffi.Int32 Function( + ffi.Pointer object, + ffi.Pointer visible, +); + +typedef _dart_maps_view_object_get_visible = int Function( + ffi.Pointer object, + ffi.Pointer visible, +); + +typedef _c_maps_view_object_polyline_set_polyline = ffi.Int32 Function( + ffi.Pointer polyline, + ffi.Pointer points, +); + +typedef _dart_maps_view_object_polyline_set_polyline = int Function( + ffi.Pointer polyline, + ffi.Pointer points, +); + +typedef _c_maps_view_object_polyline_foreach_point = ffi.Int32 Function( + ffi.Pointer polyline, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_view_object_polyline_foreach_point = int Function( + ffi.Pointer polyline, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_maps_view_object_polyline_set_color = ffi.Int32 Function( + ffi.Pointer polyline, + ffi.Uint8 r, + ffi.Uint8 g, + ffi.Uint8 b, + ffi.Uint8 a, +); + +typedef _dart_maps_view_object_polyline_set_color = int Function( + ffi.Pointer polyline, + int r, + int g, + int b, + int a, +); + +typedef _c_maps_view_object_polyline_get_color = ffi.Int32 Function( + ffi.Pointer polyline, + ffi.Pointer r, + ffi.Pointer g, + ffi.Pointer b, + ffi.Pointer a, +); + +typedef _dart_maps_view_object_polyline_get_color = int Function( + ffi.Pointer polyline, + ffi.Pointer r, + ffi.Pointer g, + ffi.Pointer b, + ffi.Pointer a, +); + +typedef _c_maps_view_object_polyline_set_width = ffi.Int32 Function( + ffi.Pointer polyline, + ffi.Int32 width, +); + +typedef _dart_maps_view_object_polyline_set_width = int Function( + ffi.Pointer polyline, + int width, +); + +typedef _c_maps_view_object_polyline_get_width = ffi.Int32 Function( + ffi.Pointer polyline, + ffi.Pointer width, +); + +typedef _dart_maps_view_object_polyline_get_width = int Function( + ffi.Pointer polyline, + ffi.Pointer width, +); + +typedef _c_maps_view_object_polygon_set_polygon = ffi.Int32 Function( + ffi.Pointer polygon, + ffi.Pointer points, +); + +typedef _dart_maps_view_object_polygon_set_polygon = int Function( + ffi.Pointer polygon, + ffi.Pointer points, +); + +typedef _c_maps_view_object_polygon_foreach_point = ffi.Int32 Function( + ffi.Pointer polygon, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_view_object_polygon_foreach_point = int Function( + ffi.Pointer polygon, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_maps_view_object_polygon_set_fill_color = ffi.Int32 Function( + ffi.Pointer polygon, + ffi.Uint8 r, + ffi.Uint8 g, + ffi.Uint8 b, + ffi.Uint8 a, +); + +typedef _dart_maps_view_object_polygon_set_fill_color = int Function( + ffi.Pointer polygon, + int r, + int g, + int b, + int a, +); + +typedef _c_maps_view_object_polygon_get_fill_color = ffi.Int32 Function( + ffi.Pointer polygon, + ffi.Pointer r, + ffi.Pointer g, + ffi.Pointer b, + ffi.Pointer a, +); + +typedef _dart_maps_view_object_polygon_get_fill_color = int Function( + ffi.Pointer polygon, + ffi.Pointer r, + ffi.Pointer g, + ffi.Pointer b, + ffi.Pointer a, +); + +typedef _c_maps_view_object_marker_set_coordinates = ffi.Int32 Function( + ffi.Pointer marker, + ffi.Pointer coordinates, +); + +typedef _dart_maps_view_object_marker_set_coordinates = int Function( + ffi.Pointer marker, + ffi.Pointer coordinates, +); + +typedef _c_maps_view_object_marker_resize = ffi.Int32 Function( + ffi.Pointer marker, + ffi.Int32 width, + ffi.Int32 height, +); + +typedef _dart_maps_view_object_marker_resize = int Function( + ffi.Pointer marker, + int width, + int height, +); + +typedef _c_maps_view_object_marker_set_image_file = ffi.Int32 Function( + ffi.Pointer marker, + ffi.Pointer file_path, +); + +typedef _dart_maps_view_object_marker_set_image_file = int Function( + ffi.Pointer marker, + ffi.Pointer file_path, +); + +typedef _c_maps_view_object_marker_get_image_file = ffi.Int32 Function( + ffi.Pointer marker, + ffi.Pointer> file_path, +); + +typedef _dart_maps_view_object_marker_get_image_file = int Function( + ffi.Pointer marker, + ffi.Pointer> file_path, +); + +typedef _c_maps_view_object_marker_get_coordinates = ffi.Int32 Function( + ffi.Pointer marker, + ffi.Pointer> coordinates, +); + +typedef _dart_maps_view_object_marker_get_coordinates = int Function( + ffi.Pointer marker, + ffi.Pointer> coordinates, +); + +typedef _c_maps_view_object_marker_get_size = ffi.Int32 Function( + ffi.Pointer marker, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _dart_maps_view_object_marker_get_size = int Function( + ffi.Pointer marker, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _c_maps_view_object_marker_get_type = ffi.Int32 Function( + ffi.Pointer marker, + ffi.Pointer type, +); + +typedef _dart_maps_view_object_marker_get_type = int Function( + ffi.Pointer marker, + ffi.Pointer type, +); + +typedef _c_maps_view_object_marker_set_z_order = ffi.Int32 Function( + ffi.Pointer marker, + ffi.Int32 z_order, +); + +typedef _dart_maps_view_object_marker_set_z_order = int Function( + ffi.Pointer marker, + int z_order, +); + +typedef _c_maps_view_object_marker_get_z_order = ffi.Int32 Function( + ffi.Pointer marker, + ffi.Pointer z_order, +); + +typedef _dart_maps_view_object_marker_get_z_order = int Function( + ffi.Pointer marker, + ffi.Pointer z_order, +); + +typedef _c_maps_view_object_overlay_get_object = ffi.Int32 Function( + ffi.Pointer overlay, + ffi.Pointer> object, +); + +typedef _dart_maps_view_object_overlay_get_object = int Function( + ffi.Pointer overlay, + ffi.Pointer> object, +); + +typedef _c_maps_view_object_overlay_set_coordinates = ffi.Int32 Function( + ffi.Pointer overlay, + ffi.Pointer coordinates, +); + +typedef _dart_maps_view_object_overlay_set_coordinates = int Function( + ffi.Pointer overlay, + ffi.Pointer coordinates, +); + +typedef _c_maps_view_object_overlay_get_coordinates = ffi.Int32 Function( + ffi.Pointer overlay, + ffi.Pointer> coordinates, +); + +typedef _dart_maps_view_object_overlay_get_coordinates = int Function( + ffi.Pointer overlay, + ffi.Pointer> coordinates, +); + +typedef _c_maps_view_object_overlay_set_min_zoom_level = ffi.Int32 Function( + ffi.Pointer overlay, + ffi.Int32 zoom, +); + +typedef _dart_maps_view_object_overlay_set_min_zoom_level = int Function( + ffi.Pointer overlay, + int zoom, +); + +typedef _c_maps_view_object_overlay_get_min_zoom_level = ffi.Int32 Function( + ffi.Pointer overlay, + ffi.Pointer zoom, +); + +typedef _dart_maps_view_object_overlay_get_min_zoom_level = int Function( + ffi.Pointer overlay, + ffi.Pointer zoom, +); + +typedef _c_maps_view_object_overlay_set_max_zoom_level = ffi.Int32 Function( + ffi.Pointer overlay, + ffi.Int32 zoom, +); + +typedef _dart_maps_view_object_overlay_set_max_zoom_level = int Function( + ffi.Pointer overlay, + int zoom, +); + +typedef _c_maps_view_object_overlay_get_max_zoom_level = ffi.Int32 Function( + ffi.Pointer overlay, + ffi.Pointer zoom, +); + +typedef _dart_maps_view_object_overlay_get_max_zoom_level = int Function( + ffi.Pointer overlay, + ffi.Pointer zoom, +); + +typedef _c_maps_view_event_data_destroy = ffi.Int32 Function( + ffi.Pointer event, +); + +typedef _dart_maps_view_event_data_destroy = int Function( + ffi.Pointer event, +); + +typedef _c_maps_view_event_data_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _dart_maps_view_event_data_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned, +); + +typedef _c_maps_view_event_data_get_type = ffi.Int32 Function( + ffi.Pointer event, + ffi.Pointer event_type, +); + +typedef _dart_maps_view_event_data_get_type = int Function( + ffi.Pointer event, + ffi.Pointer event_type, +); + +typedef _c_maps_view_event_data_get_gesture_type = ffi.Int32 Function( + ffi.Pointer event, + ffi.Pointer gesture_type, +); + +typedef _dart_maps_view_event_data_get_gesture_type = int Function( + ffi.Pointer event, + ffi.Pointer gesture_type, +); + +typedef _c_maps_view_event_data_get_action_type = ffi.Int32 Function( + ffi.Pointer event, + ffi.Pointer action_type, +); + +typedef _dart_maps_view_event_data_get_action_type = int Function( + ffi.Pointer event, + ffi.Pointer action_type, +); + +typedef _c_maps_view_event_data_get_center = ffi.Int32 Function( + ffi.Pointer event, + ffi.Pointer> center, +); + +typedef _dart_maps_view_event_data_get_center = int Function( + ffi.Pointer event, + ffi.Pointer> center, +); + +typedef _c_maps_view_event_data_get_delta = ffi.Int32 Function( + ffi.Pointer event, + ffi.Pointer delta_x, + ffi.Pointer delta_y, +); + +typedef _dart_maps_view_event_data_get_delta = int Function( + ffi.Pointer event, + ffi.Pointer delta_x, + ffi.Pointer delta_y, +); + +typedef _c_maps_view_event_data_get_position = ffi.Int32 Function( + ffi.Pointer event, + ffi.Pointer x, + ffi.Pointer y, +); + +typedef _dart_maps_view_event_data_get_position = int Function( + ffi.Pointer event, + ffi.Pointer x, + ffi.Pointer y, +); + +typedef _c_maps_view_event_data_get_coordinates = ffi.Int32 Function( + ffi.Pointer event, + ffi.Pointer> coordinates, +); + +typedef _dart_maps_view_event_data_get_coordinates = int Function( + ffi.Pointer event, + ffi.Pointer> coordinates, +); + +typedef _c_maps_view_event_data_get_fingers = ffi.Int32 Function( + ffi.Pointer event, + ffi.Pointer fingers, +); + +typedef _dart_maps_view_event_data_get_fingers = int Function( + ffi.Pointer event, + ffi.Pointer fingers, +); + +typedef _c_maps_view_event_data_get_zoom_factor = ffi.Int32 Function( + ffi.Pointer event, + ffi.Pointer zoom_factor, +); + +typedef _dart_maps_view_event_data_get_zoom_factor = int Function( + ffi.Pointer event, + ffi.Pointer zoom_factor, +); + +typedef _c_maps_view_event_data_get_rotation_angle = ffi.Int32 Function( + ffi.Pointer event, + ffi.Pointer rotation_angle, +); + +typedef _dart_maps_view_event_data_get_rotation_angle = int Function( + ffi.Pointer event, + ffi.Pointer rotation_angle, +); + +typedef _c_maps_view_event_data_get_object = ffi.Int32 Function( + ffi.Pointer event, + ffi.Pointer> object, +); + +typedef _dart_maps_view_event_data_get_object = int Function( + ffi.Pointer event, + ffi.Pointer> object, +); + +typedef _c_maps_view_capture_snapshot = ffi.Int32 Function( + ffi.Pointer view, + ffi.Int32 type, + ffi.Int32 quality, + ffi.Pointer path, +); + +typedef _dart_maps_view_capture_snapshot = int Function( + ffi.Pointer view, + int type, + int quality, + ffi.Pointer path, +); + +typedef _c_maps_view_create = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer obj, + ffi.Pointer> view, +); + +typedef _dart_maps_view_create = int Function( + ffi.Pointer maps, + ffi.Pointer obj, + ffi.Pointer> view, +); + +typedef _c_maps_view_destroy = ffi.Int32 Function( + ffi.Pointer view, +); + +typedef _dart_maps_view_destroy = int Function( + ffi.Pointer view, +); + +typedef _c_maps_view_set_center = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer coordinates, +); + +typedef _dart_maps_view_set_center = int Function( + ffi.Pointer view, + ffi.Pointer coordinates, +); + +typedef _c_maps_view_get_center = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer> coordinates, +); + +typedef _dart_maps_view_get_center = int Function( + ffi.Pointer view, + ffi.Pointer> coordinates, +); + +typedef _c_maps_view_set_zoom_level = ffi.Int32 Function( + ffi.Pointer view, + ffi.Int32 level, +); + +typedef _dart_maps_view_set_zoom_level = int Function( + ffi.Pointer view, + int level, +); + +typedef _c_maps_view_get_zoom_level = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer level, +); + +typedef _dart_maps_view_get_zoom_level = int Function( + ffi.Pointer view, + ffi.Pointer level, +); + +typedef _c_maps_view_set_min_zoom_level = ffi.Int32 Function( + ffi.Pointer view, + ffi.Int32 level, +); + +typedef _dart_maps_view_set_min_zoom_level = int Function( + ffi.Pointer view, + int level, +); + +typedef _c_maps_view_get_min_zoom_level = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer min_zoom_level, +); + +typedef _dart_maps_view_get_min_zoom_level = int Function( + ffi.Pointer view, + ffi.Pointer min_zoom_level, +); + +typedef _c_maps_view_set_max_zoom_level = ffi.Int32 Function( + ffi.Pointer view, + ffi.Int32 level, +); + +typedef _dart_maps_view_set_max_zoom_level = int Function( + ffi.Pointer view, + int level, +); + +typedef _c_maps_view_get_max_zoom_level = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer max_zoom_level, +); + +typedef _dart_maps_view_get_max_zoom_level = int Function( + ffi.Pointer view, + ffi.Pointer max_zoom_level, +); + +typedef _c_maps_view_set_orientation = ffi.Int32 Function( + ffi.Pointer view, + ffi.Double angle, +); + +typedef _dart_maps_view_set_orientation = int Function( + ffi.Pointer view, + double angle, +); + +typedef _c_maps_view_get_orientation = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer rotation_angle, +); + +typedef _dart_maps_view_get_orientation = int Function( + ffi.Pointer view, + ffi.Pointer rotation_angle, +); + +typedef _c_maps_view_screen_to_geolocation = ffi.Int32 Function( + ffi.Pointer view, + ffi.Int32 x, + ffi.Int32 y, + ffi.Pointer> coordinates, +); + +typedef _dart_maps_view_screen_to_geolocation = int Function( + ffi.Pointer view, + int x, + int y, + ffi.Pointer> coordinates, +); + +typedef _c_maps_view_geolocation_to_screen = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer coordinates, + ffi.Pointer x, + ffi.Pointer y, +); + +typedef _dart_maps_view_geolocation_to_screen = int Function( + ffi.Pointer view, + ffi.Pointer coordinates, + ffi.Pointer x, + ffi.Pointer y, +); + +typedef _c_maps_view_set_type = ffi.Int32 Function( + ffi.Pointer view, + ffi.Int32 type, +); + +typedef _dart_maps_view_set_type = int Function( + ffi.Pointer view, + int type, +); + +typedef _c_maps_view_get_type = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer type, +); + +typedef _dart_maps_view_get_type = int Function( + ffi.Pointer view, + ffi.Pointer type, +); + +typedef _c_maps_view_set_buildings_enabled = ffi.Int32 Function( + ffi.Pointer view, + ffi.Uint8 enable, +); + +typedef _dart_maps_view_set_buildings_enabled = int Function( + ffi.Pointer view, + int enable, +); + +typedef _c_maps_view_get_buildings_enabled = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer enable, +); + +typedef _dart_maps_view_get_buildings_enabled = int Function( + ffi.Pointer view, + ffi.Pointer enable, +); + +typedef _c_maps_view_set_traffic_enabled = ffi.Int32 Function( + ffi.Pointer view, + ffi.Uint8 enable, +); + +typedef _dart_maps_view_set_traffic_enabled = int Function( + ffi.Pointer view, + int enable, +); + +typedef _c_maps_view_get_traffic_enabled = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer enable, +); + +typedef _dart_maps_view_get_traffic_enabled = int Function( + ffi.Pointer view, + ffi.Pointer enable, +); + +typedef _c_maps_view_set_public_transit_enabled = ffi.Int32 Function( + ffi.Pointer view, + ffi.Uint8 enable, +); + +typedef _dart_maps_view_set_public_transit_enabled = int Function( + ffi.Pointer view, + int enable, +); + +typedef _c_maps_view_get_public_transit_enabled = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer enable, +); + +typedef _dart_maps_view_get_public_transit_enabled = int Function( + ffi.Pointer view, + ffi.Pointer enable, +); + +typedef _c_maps_view_set_language = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer language, +); + +typedef _dart_maps_view_set_language = int Function( + ffi.Pointer view, + ffi.Pointer language, +); + +typedef _c_maps_view_get_language = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer> language, +); + +typedef _dart_maps_view_get_language = int Function( + ffi.Pointer view, + ffi.Pointer> language, +); + +typedef _c_maps_view_set_scalebar_enabled = ffi.Int32 Function( + ffi.Pointer view, + ffi.Uint8 enable, +); + +typedef _dart_maps_view_set_scalebar_enabled = int Function( + ffi.Pointer view, + int enable, +); + +typedef _c_maps_view_get_scalebar_enabled = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer enabled, +); + +typedef _dart_maps_view_get_scalebar_enabled = int Function( + ffi.Pointer view, + ffi.Pointer enabled, +); + +typedef _c_maps_view_get_viewport = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer> viewport, +); + +typedef _dart_maps_view_get_viewport = int Function( + ffi.Pointer view, + ffi.Pointer> viewport, +); + +typedef _c_maps_view_set_screen_location = ffi.Int32 Function( + ffi.Pointer view, + ffi.Int32 x, + ffi.Int32 y, + ffi.Int32 width, + ffi.Int32 height, +); + +typedef _dart_maps_view_set_screen_location = int Function( + ffi.Pointer view, + int x, + int y, + int width, + int height, +); + +typedef _c_maps_view_get_screen_location = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer x, + ffi.Pointer y, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _dart_maps_view_get_screen_location = int Function( + ffi.Pointer view, + ffi.Pointer x, + ffi.Pointer y, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _c_maps_view_move = ffi.Int32 Function( + ffi.Pointer view, + ffi.Int32 x, + ffi.Int32 y, +); + +typedef _dart_maps_view_move = int Function( + ffi.Pointer view, + int x, + int y, +); + +typedef _c_maps_view_resize = ffi.Int32 Function( + ffi.Pointer view, + ffi.Int32 width, + ffi.Int32 height, +); + +typedef _dart_maps_view_resize = int Function( + ffi.Pointer view, + int width, + int height, +); + +typedef _c_maps_view_set_visibility = ffi.Int32 Function( + ffi.Pointer view, + ffi.Uint8 visible, +); + +typedef _dart_maps_view_set_visibility = int Function( + ffi.Pointer view, + int visible, +); + +typedef _c_maps_view_get_visibility = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer visible, +); + +typedef _dart_maps_view_get_visibility = int Function( + ffi.Pointer view, + ffi.Pointer visible, +); + +typedef maps_view_on_event_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_view_set_event_cb = ffi.Int32 Function( + ffi.Pointer view, + ffi.Int32 type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_view_set_event_cb = int Function( + ffi.Pointer view, + int type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_maps_view_unset_event_cb = ffi.Int32 Function( + ffi.Pointer view, + ffi.Int32 type, +); + +typedef _dart_maps_view_unset_event_cb = int Function( + ffi.Pointer view, + int type, +); + +typedef _c_maps_view_set_gesture_enabled = ffi.Int32 Function( + ffi.Pointer view, + ffi.Int32 gesture, + ffi.Uint8 enabled, +); + +typedef _dart_maps_view_set_gesture_enabled = int Function( + ffi.Pointer view, + int gesture, + int enabled, +); + +typedef _c_maps_view_get_gesture_enabled = ffi.Int32 Function( + ffi.Pointer view, + ffi.Int32 gesture, + ffi.Pointer enabled, +); + +typedef _dart_maps_view_get_gesture_enabled = int Function( + ffi.Pointer view, + int gesture, + ffi.Pointer enabled, +); + +typedef _c_maps_view_add_object = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer object, +); + +typedef _dart_maps_view_add_object = int Function( + ffi.Pointer view, + ffi.Pointer object, +); + +typedef _c_maps_view_remove_object = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer object, +); + +typedef _dart_maps_view_remove_object = int Function( + ffi.Pointer view, + ffi.Pointer object, +); + +typedef _c_maps_view_remove_all_objects = ffi.Int32 Function( + ffi.Pointer view, +); + +typedef _dart_maps_view_remove_all_objects = int Function( + ffi.Pointer view, +); + +typedef maps_view_object_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_view_foreach_object = ffi.Int32 Function( + ffi.Pointer view, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_view_foreach_object = int Function( + ffi.Pointer view, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef maps_service_provider_info_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_service_foreach_provider = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_service_foreach_provider = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef maps_service_request_user_consent_cb = ffi.Void Function( + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_service_request_user_consent = ffi.Int32 Function( + ffi.Pointer maps_provider, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_maps_service_request_user_consent = int Function( + ffi.Pointer maps_provider, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_maps_service_create = ffi.Int32 Function( + ffi.Pointer maps_provider, + ffi.Pointer> maps, +); + +typedef _dart_maps_service_create = int Function( + ffi.Pointer maps_provider, + ffi.Pointer> maps, +); + +typedef _c_maps_service_destroy = ffi.Int32 Function( + ffi.Pointer maps, +); + +typedef _dart_maps_service_destroy = int Function( + ffi.Pointer maps, +); + +typedef _c_maps_service_set_provider_key = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer provider_key, +); + +typedef _dart_maps_service_set_provider_key = int Function( + ffi.Pointer maps, + ffi.Pointer provider_key, +); + +typedef _c_maps_service_get_provider_key = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer> provider_key, +); + +typedef _dart_maps_service_get_provider_key = int Function( + ffi.Pointer maps, + ffi.Pointer> provider_key, +); + +typedef _c_maps_service_set_preference = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer preference, +); + +typedef _dart_maps_service_set_preference = int Function( + ffi.Pointer maps, + ffi.Pointer preference, +); + +typedef _c_maps_service_get_preference = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer> preference, +); + +typedef _dart_maps_service_get_preference = int Function( + ffi.Pointer maps, + ffi.Pointer> preference, +); + +typedef _c_maps_service_provider_is_service_supported = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Int32 service, + ffi.Pointer supported, +); + +typedef _dart_maps_service_provider_is_service_supported = int Function( + ffi.Pointer maps, + int service, + ffi.Pointer supported, +); + +typedef _c_maps_service_provider_is_data_supported = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Int32 data, + ffi.Pointer supported, +); + +typedef _dart_maps_service_provider_is_data_supported = int Function( + ffi.Pointer maps, + int data, + ffi.Pointer supported, +); + +typedef _c_maps_service_cancel_request = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Int32 request_id, +); + +typedef _dart_maps_service_cancel_request = int Function( + ffi.Pointer maps, + int request_id, +); + +typedef maps_service_geocode_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_service_geocode = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer address, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _dart_maps_service_geocode = int Function( + ffi.Pointer maps, + ffi.Pointer address, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _c_maps_service_geocode_inside_area = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer address, + ffi.Pointer bounds, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _dart_maps_service_geocode_inside_area = int Function( + ffi.Pointer maps, + ffi.Pointer address, + ffi.Pointer bounds, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _c_maps_service_geocode_by_structured_address = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer address, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _dart_maps_service_geocode_by_structured_address = int Function( + ffi.Pointer maps, + ffi.Pointer address, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef maps_service_reverse_geocode_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_service_reverse_geocode = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Double latitude, + ffi.Double longitude, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _dart_maps_service_reverse_geocode = int Function( + ffi.Pointer maps, + double latitude, + double longitude, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef maps_service_multi_reverse_geocode_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_service_multi_reverse_geocode = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer coordinates_list, + ffi.Pointer preference, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _dart_maps_service_multi_reverse_geocode = int Function( + ffi.Pointer maps, + ffi.Pointer coordinates_list, + ffi.Pointer preference, + ffi.Pointer> + callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef maps_service_search_place_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_service_search_place = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer position, + ffi.Int32 distance, + ffi.Pointer filter, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _dart_maps_service_search_place = int Function( + ffi.Pointer maps, + ffi.Pointer position, + int distance, + ffi.Pointer filter, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _c_maps_service_search_place_by_area = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer boundary, + ffi.Pointer filter, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _dart_maps_service_search_place_by_area = int Function( + ffi.Pointer maps, + ffi.Pointer boundary, + ffi.Pointer filter, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _c_maps_service_search_place_by_address = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer address, + ffi.Pointer boundary, + ffi.Pointer filter, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _dart_maps_service_search_place_by_address = int Function( + ffi.Pointer maps, + ffi.Pointer address, + ffi.Pointer boundary, + ffi.Pointer filter, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef maps_service_search_place_list_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_service_search_place_list = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer boundary, + ffi.Pointer filter, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _dart_maps_service_search_place_list = int Function( + ffi.Pointer maps, + ffi.Pointer boundary, + ffi.Pointer filter, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef maps_service_get_place_details_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_service_get_place_details = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer uri, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _dart_maps_service_get_place_details = int Function( + ffi.Pointer maps, + ffi.Pointer uri, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef maps_service_search_route_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_maps_service_search_route = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer origin, + ffi.Pointer destination, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _dart_maps_service_search_route = int Function( + ffi.Pointer maps, + ffi.Pointer origin, + ffi.Pointer destination, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _c_maps_service_search_route_waypoints = ffi.Int32 Function( + ffi.Pointer maps, + ffi.Pointer> waypoint_list, + ffi.Int32 waypoint_num, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _dart_maps_service_search_route_waypoints = int Function( + ffi.Pointer maps, + ffi.Pointer> waypoint_list, + int waypoint_num, + ffi.Pointer preference, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer request_id, +); + +typedef _c_email_create_message = ffi.Int32 Function( + ffi.Pointer> email, +); + +typedef _dart_email_create_message = int Function( + ffi.Pointer> email, +); + +typedef _c_email_destroy_message = ffi.Int32 Function( + ffi.Pointer email, +); + +typedef _dart_email_destroy_message = int Function( + ffi.Pointer email, +); + +typedef _c_email_set_subject = ffi.Int32 Function( + ffi.Pointer email, + ffi.Pointer subject, +); + +typedef _dart_email_set_subject = int Function( + ffi.Pointer email, + ffi.Pointer subject, +); + +typedef _c_email_set_body = ffi.Int32 Function( + ffi.Pointer email, + ffi.Pointer body, +); + +typedef _dart_email_set_body = int Function( + ffi.Pointer email, + ffi.Pointer body, +); + +typedef _c_email_add_recipient = ffi.Int32 Function( + ffi.Pointer email, + ffi.Int32 type, + ffi.Pointer address, +); + +typedef _dart_email_add_recipient = int Function( + ffi.Pointer email, + int type, + ffi.Pointer address, +); + +typedef _c_email_remove_all_recipients = ffi.Int32 Function( + ffi.Pointer email, +); + +typedef _dart_email_remove_all_recipients = int Function( + ffi.Pointer email, +); + +typedef _c_email_add_attach = ffi.Int32 Function( + ffi.Pointer email, + ffi.Pointer filepath, +); + +typedef _dart_email_add_attach = int Function( + ffi.Pointer email, + ffi.Pointer filepath, +); + +typedef _c_email_remove_all_attachments = ffi.Int32 Function( + ffi.Pointer email, +); + +typedef _dart_email_remove_all_attachments = int Function( + ffi.Pointer email, +); + +typedef _c_email_save_message = ffi.Int32 Function( + ffi.Pointer email, +); + +typedef _dart_email_save_message = int Function( + ffi.Pointer email, +); + +typedef _c_email_send_message = ffi.Int32 Function( + ffi.Pointer email, + ffi.Uint8 save_to_sentbox, +); + +typedef _dart_email_send_message = int Function( + ffi.Pointer email, + int save_to_sentbox, +); + +typedef email_message_sent_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_email_set_message_sent_cb = ffi.Int32 Function( + ffi.Pointer email, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_email_set_message_sent_cb = int Function( + ffi.Pointer email, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_email_unset_message_sent_cb = ffi.Int32 Function( + ffi.Pointer msg, +); + +typedef _dart_email_unset_message_sent_cb = int Function( + ffi.Pointer msg, +); + +typedef _c_messages_open_service = ffi.Int32 Function( + ffi.Pointer> service, +); + +typedef _dart_messages_open_service = int Function( + ffi.Pointer> service, +); + +typedef _c_messages_close_service = ffi.Int32 Function( + ffi.Pointer service, +); + +typedef _dart_messages_close_service = int Function( + ffi.Pointer service, +); + +typedef _c_messages_create_message = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer> msg, +); + +typedef _dart_messages_create_message = int Function( + int type, + ffi.Pointer> msg, +); + +typedef _c_messages_destroy_message = ffi.Int32 Function( + ffi.Pointer msg, +); + +typedef _dart_messages_destroy_message = int Function( + ffi.Pointer msg, +); + +typedef _c_messages_add_message = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer msg, + ffi.Pointer msg_id, +); + +typedef _dart_messages_add_message = int Function( + ffi.Pointer service, + ffi.Pointer msg, + ffi.Pointer msg_id, +); + +typedef _c_messages_get_message_id = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Pointer msg_id, +); + +typedef _dart_messages_get_message_id = int Function( + ffi.Pointer msg, + ffi.Pointer msg_id, +); + +typedef _c_messages_set_sim_id = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Int32 sim_id, +); + +typedef _dart_messages_set_sim_id = int Function( + ffi.Pointer msg, + int sim_id, +); + +typedef _c_messages_get_sim_id = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Pointer sim_id, +); + +typedef _dart_messages_get_sim_id = int Function( + ffi.Pointer msg, + ffi.Pointer sim_id, +); + +typedef _c_messages_set_mbox_type = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Int32 mbox, +); + +typedef _dart_messages_set_mbox_type = int Function( + ffi.Pointer msg, + int mbox, +); + +typedef _c_messages_get_mbox_type = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Pointer mbox, +); + +typedef _dart_messages_get_mbox_type = int Function( + ffi.Pointer msg, + ffi.Pointer mbox, +); + +typedef _c_messages_get_message_port = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Pointer port, +); + +typedef _dart_messages_get_message_port = int Function( + ffi.Pointer msg, + ffi.Pointer port, +); + +typedef _c_messages_get_message_type = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Pointer type, +); + +typedef _dart_messages_get_message_type = int Function( + ffi.Pointer msg, + ffi.Pointer type, +); + +typedef _c_messages_add_address = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Pointer address, + ffi.Int32 type, +); + +typedef _dart_messages_add_address = int Function( + ffi.Pointer msg, + ffi.Pointer address, + int type, +); + +typedef _c_messages_get_address_count = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Pointer count, +); + +typedef _dart_messages_get_address_count = int Function( + ffi.Pointer msg, + ffi.Pointer count, +); + +typedef _c_messages_get_address = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Int32 index, + ffi.Pointer> address, + ffi.Pointer type, +); + +typedef _dart_messages_get_address = int Function( + ffi.Pointer msg, + int index, + ffi.Pointer> address, + ffi.Pointer type, +); + +typedef _c_messages_remove_all_addresses = ffi.Int32 Function( + ffi.Pointer msg, +); + +typedef _dart_messages_remove_all_addresses = int Function( + ffi.Pointer msg, +); + +typedef _c_messages_set_text = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Pointer text, +); + +typedef _dart_messages_set_text = int Function( + ffi.Pointer msg, + ffi.Pointer text, +); + +typedef _c_messages_get_text = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Pointer> text, +); + +typedef _dart_messages_get_text = int Function( + ffi.Pointer msg, + ffi.Pointer> text, +); + +typedef _c_messages_set_time = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Int64 time, +); + +typedef _dart_messages_set_time = int Function( + ffi.Pointer msg, + int time, +); + +typedef _c_messages_get_time = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Pointer time, +); + +typedef _dart_messages_get_time = int Function( + ffi.Pointer msg, + ffi.Pointer time, +); + +typedef messages_sent_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_messages_send_message = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer msg, + ffi.Uint8 save_to_sentbox, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_messages_send_message = int Function( + ffi.Pointer service, + ffi.Pointer msg, + int save_to_sentbox, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_messages_get_message_count = ffi.Int32 Function( + ffi.Pointer service, + ffi.Int32 mbox, + ffi.Int32 type, + ffi.Pointer count, +); + +typedef _dart_messages_get_message_count = int Function( + ffi.Pointer service, + int mbox, + int type, + ffi.Pointer count, +); + +typedef _c_messages_search_message = ffi.Int32 Function( + ffi.Pointer service, + ffi.Int32 mbox, + ffi.Int32 type, + ffi.Pointer keyword, + ffi.Pointer address, + ffi.Int32 offset, + ffi.Int32 limit, + ffi.Pointer>> message_array, + ffi.Pointer length, + ffi.Pointer total, +); + +typedef _dart_messages_search_message = int Function( + ffi.Pointer service, + int mbox, + int type, + ffi.Pointer keyword, + ffi.Pointer address, + int offset, + int limit, + ffi.Pointer>> message_array, + ffi.Pointer length, + ffi.Pointer total, +); + +typedef _c_messages_search_message_by_id = ffi.Int32 Function( + ffi.Pointer service, + ffi.Int32 msg_id, + ffi.Pointer> msg, +); + +typedef _dart_messages_search_message_by_id = int Function( + ffi.Pointer service, + int msg_id, + ffi.Pointer> msg, +); + +typedef _c_messages_free_message_array = ffi.Int32 Function( + ffi.Pointer> message_array, +); + +typedef _dart_messages_free_message_array = int Function( + ffi.Pointer> message_array, +); + +typedef messages_search_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_messages_foreach_message = ffi.Int32 Function( + ffi.Pointer service, + ffi.Int32 mbox, + ffi.Int32 type, + ffi.Pointer keyword, + ffi.Pointer address, + ffi.Int32 offset, + ffi.Int32 limit, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_messages_foreach_message = int Function( + ffi.Pointer service, + int mbox, + int type, + ffi.Pointer keyword, + ffi.Pointer address, + int offset, + int limit, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef messages_incoming_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_messages_set_message_incoming_cb = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_messages_set_message_incoming_cb = int Function( + ffi.Pointer service, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_messages_unset_message_incoming_cb = ffi.Int32 Function( + ffi.Pointer service, +); + +typedef _dart_messages_unset_message_incoming_cb = int Function( + ffi.Pointer service, +); + +typedef _c_messages_add_sms_listening_port = ffi.Int32 Function( + ffi.Pointer service, + ffi.Int32 port, +); + +typedef _dart_messages_add_sms_listening_port = int Function( + ffi.Pointer service, + int port, +); + +typedef _c_messages_mms_set_subject = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Pointer subject, +); + +typedef _dart_messages_mms_set_subject = int Function( + ffi.Pointer msg, + ffi.Pointer subject, +); + +typedef _c_messages_mms_get_subject = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Pointer> subject, +); + +typedef _dart_messages_mms_get_subject = int Function( + ffi.Pointer msg, + ffi.Pointer> subject, +); + +typedef _c_messages_mms_add_attachment = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Int32 type, + ffi.Pointer path, +); + +typedef _dart_messages_mms_add_attachment = int Function( + ffi.Pointer msg, + int type, + ffi.Pointer path, +); + +typedef _c_messages_mms_get_attachment = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Int32 index, + ffi.Pointer type, + ffi.Pointer> path, +); + +typedef _dart_messages_mms_get_attachment = int Function( + ffi.Pointer msg, + int index, + ffi.Pointer type, + ffi.Pointer> path, +); + +typedef _c_messages_mms_get_attachment_count = ffi.Int32 Function( + ffi.Pointer msg, + ffi.Pointer count, +); + +typedef _dart_messages_mms_get_attachment_count = int Function( + ffi.Pointer msg, + ffi.Pointer count, +); + +typedef _c_messages_mms_remove_all_attachments = ffi.Int32 Function( + ffi.Pointer msg, +); + +typedef _dart_messages_mms_remove_all_attachments = int Function( + ffi.Pointer msg, +); + +typedef messages_push_incoming_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_messages_push_add_incoming_cb = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer app_id, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_messages_push_add_incoming_cb = int Function( + ffi.Pointer service, + ffi.Pointer app_id, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_messages_push_remove_incoming_cb = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer app_id, +); + +typedef _dart_messages_push_remove_incoming_cb = int Function( + ffi.Pointer service, + ffi.Pointer app_id, +); + +typedef _c_messages_push_register = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer content_type, + ffi.Pointer app_id, +); + +typedef _dart_messages_push_register = int Function( + ffi.Pointer service, + ffi.Pointer content_type, + ffi.Pointer app_id, +); + +typedef _c_messages_push_deregister = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer content_type, + ffi.Pointer app_id, +); + +typedef _dart_messages_push_deregister = int Function( + ffi.Pointer service, + ffi.Pointer content_type, + ffi.Pointer app_id, +); + +typedef _c_messages_push_reregister = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer content_type, + ffi.Pointer app_id, + ffi.Pointer dst_content_type, + ffi.Pointer dst_app_id, +); + +typedef _dart_messages_push_reregister = int Function( + ffi.Pointer service, + ffi.Pointer content_type, + ffi.Pointer app_id, + ffi.Pointer dst_content_type, + ffi.Pointer dst_app_id, +); + +typedef push_service_state_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef push_service_notify_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_push_service_connect = ffi.Int32 Function( + ffi.Pointer push_app_id, + ffi.Pointer> state_callback, + ffi.Pointer> notify_callback, + ffi.Pointer user_data, + ffi.Pointer> connection, +); + +typedef _dart_push_service_connect = int Function( + ffi.Pointer push_app_id, + ffi.Pointer> state_callback, + ffi.Pointer> notify_callback, + ffi.Pointer user_data, + ffi.Pointer> connection, +); + +typedef _c_push_service_disconnect = ffi.Void Function( + ffi.Pointer connection, +); + +typedef _dart_push_service_disconnect = void Function( + ffi.Pointer connection, +); + +typedef push_service_result_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_push_service_register = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer> result_callback, + ffi.Pointer user_data, +); + +typedef _dart_push_service_register = int Function( + ffi.Pointer connection, + ffi.Pointer> result_callback, + ffi.Pointer user_data, +); + +typedef _c_push_service_deregister = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer> result_callback, + ffi.Pointer user_data, +); + +typedef _dart_push_service_deregister = int Function( + ffi.Pointer connection, + ffi.Pointer> result_callback, + ffi.Pointer user_data, +); + +typedef _c_push_service_app_control_to_noti_data = ffi.Pointer + Function( + ffi.Pointer app_control, + ffi.Pointer operation, +); + +typedef _dart_push_service_app_control_to_noti_data = ffi.Pointer + Function( + ffi.Pointer app_control, + ffi.Pointer operation, +); + +typedef _c_push_service_app_control_to_notification = ffi.Int32 Function( + ffi.Pointer app_control, + ffi.Pointer operation, + ffi.Pointer> noti, +); + +typedef _dart_push_service_app_control_to_notification = int Function( + ffi.Pointer app_control, + ffi.Pointer operation, + ffi.Pointer> noti, +); + +typedef _c_push_service_get_notification_data = ffi.Int32 Function( + ffi.Pointer notification, + ffi.Pointer> data, +); + +typedef _dart_push_service_get_notification_data = int Function( + ffi.Pointer notification, + ffi.Pointer> data, +); + +typedef _c_push_service_get_notification_message = ffi.Int32 Function( + ffi.Pointer notification, + ffi.Pointer> msg, +); + +typedef _dart_push_service_get_notification_message = int Function( + ffi.Pointer notification, + ffi.Pointer> msg, +); + +typedef _c_push_service_get_notification_time = ffi.Int32 Function( + ffi.Pointer notification, + ffi.Pointer received_time, +); + +typedef _dart_push_service_get_notification_time = int Function( + ffi.Pointer notification, + ffi.Pointer received_time, +); + +typedef _c_push_service_get_notification_sender = ffi.Int32 Function( + ffi.Pointer notification, + ffi.Pointer> sender, +); + +typedef _dart_push_service_get_notification_sender = int Function( + ffi.Pointer notification, + ffi.Pointer> sender, +); + +typedef _c_push_service_get_notification_session_info = ffi.Int32 Function( + ffi.Pointer notification, + ffi.Pointer> session_info, +); + +typedef _dart_push_service_get_notification_session_info = int Function( + ffi.Pointer notification, + ffi.Pointer> session_info, +); + +typedef _c_push_service_get_notification_request_id = ffi.Int32 Function( + ffi.Pointer notification, + ffi.Pointer> request_id, +); + +typedef _dart_push_service_get_notification_request_id = int Function( + ffi.Pointer notification, + ffi.Pointer> request_id, +); + +typedef _c_push_service_get_notification_type = ffi.Int32 Function( + ffi.Pointer notification, + ffi.Pointer type, +); + +typedef _dart_push_service_get_notification_type = int Function( + ffi.Pointer notification, + ffi.Pointer type, +); + +typedef _c_push_service_get_unread_notification = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer> noti, +); + +typedef _dart_push_service_get_unread_notification = int Function( + ffi.Pointer connection, + ffi.Pointer> noti, +); + +typedef _c_push_service_request_unread_notification = ffi.Int32 Function( + ffi.Pointer connection, +); + +typedef _dart_push_service_request_unread_notification = int Function( + ffi.Pointer connection, +); + +typedef _c_push_service_get_registration_id = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer> reg_id, +); + +typedef _dart_push_service_get_registration_id = int Function( + ffi.Pointer connection, + ffi.Pointer> reg_id, +); + +typedef _c_push_service_free_notification = ffi.Void Function( + ffi.Pointer noti, +); + +typedef _dart_push_service_free_notification = void Function( + ffi.Pointer noti, +); + +typedef _c_sound_manager_get_max_volume = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer max, +); + +typedef _dart_sound_manager_get_max_volume = int Function( + int type, + ffi.Pointer max, +); + +typedef _c_sound_manager_set_volume = ffi.Int32 Function( + ffi.Int32 type, + ffi.Int32 volume, +); + +typedef _dart_sound_manager_set_volume = int Function( + int type, + int volume, +); + +typedef _c_sound_manager_get_volume = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer volume, +); + +typedef _dart_sound_manager_get_volume = int Function( + int type, + ffi.Pointer volume, +); + +typedef _c_sound_manager_set_current_sound_type = ffi.Int32 Function( + ffi.Int32 type, +); + +typedef _dart_sound_manager_set_current_sound_type = int Function( + int type, +); + +typedef _c_sound_manager_get_current_sound_type = ffi.Int32 Function( + ffi.Pointer type, +); + +typedef _dart_sound_manager_get_current_sound_type = int Function( + ffi.Pointer type, +); + +typedef _c_sound_manager_unset_current_sound_type = ffi.Int32 Function(); + +typedef _dart_sound_manager_unset_current_sound_type = int Function(); + +typedef sound_manager_volume_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_sound_manager_set_volume_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_sound_manager_set_volume_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_sound_manager_unset_volume_changed_cb = ffi.Int32 Function(); + +typedef _dart_sound_manager_unset_volume_changed_cb = int Function(); + +typedef _c_sound_manager_add_volume_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _dart_sound_manager_add_volume_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _c_sound_manager_remove_volume_changed_cb = ffi.Int32 Function( + ffi.Int32 id, +); + +typedef _dart_sound_manager_remove_volume_changed_cb = int Function( + int id, +); + +typedef sound_stream_focus_state_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_sound_manager_create_stream_information = ffi.Int32 Function( + ffi.Int32 stream_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer> stream_info, +); + +typedef _dart_sound_manager_create_stream_information = int Function( + int stream_type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer> stream_info, +); + +typedef _c_sound_manager_destroy_stream_information = ffi.Int32 Function( + ffi.Pointer stream_info, +); + +typedef _dart_sound_manager_destroy_stream_information = int Function( + ffi.Pointer stream_info, +); + +typedef _c_sound_manager_get_sound_type = ffi.Int32 Function( + ffi.Pointer stream_info, + ffi.Pointer sound_type, +); + +typedef _dart_sound_manager_get_sound_type = int Function( + ffi.Pointer stream_info, + ffi.Pointer sound_type, +); + +typedef _c_sound_manager_add_device_for_stream_routing = ffi.Int32 Function( + ffi.Pointer stream_info, + ffi.Pointer device, +); + +typedef _dart_sound_manager_add_device_for_stream_routing = int Function( + ffi.Pointer stream_info, + ffi.Pointer device, +); + +typedef _c_sound_manager_remove_device_for_stream_routing = ffi.Int32 Function( + ffi.Pointer stream_info, + ffi.Pointer device, +); + +typedef _dart_sound_manager_remove_device_for_stream_routing = int Function( + ffi.Pointer stream_info, + ffi.Pointer device, +); + +typedef _c_sound_manager_remove_all_devices_for_stream_routing = ffi.Int32 + Function( + ffi.Pointer stream_info, +); + +typedef _dart_sound_manager_remove_all_devices_for_stream_routing = int + Function( + ffi.Pointer stream_info, +); + +typedef _c_sound_manager_apply_stream_routing = ffi.Int32 Function( + ffi.Pointer stream_info, +); + +typedef _dart_sound_manager_apply_stream_routing = int Function( + ffi.Pointer stream_info, +); + +typedef _c_sound_manager_acquire_focus = ffi.Int32 Function( + ffi.Pointer stream_info, + ffi.Int32 focus_mask, + ffi.Int32 sound_behavior, + ffi.Pointer extra_info, +); + +typedef _dart_sound_manager_acquire_focus = int Function( + ffi.Pointer stream_info, + int focus_mask, + int sound_behavior, + ffi.Pointer extra_info, +); + +typedef _c_sound_manager_release_focus = ffi.Int32 Function( + ffi.Pointer stream_info, + ffi.Int32 focus_mask, + ffi.Int32 sound_behavior, + ffi.Pointer extra_info, +); + +typedef _dart_sound_manager_release_focus = int Function( + ffi.Pointer stream_info, + int focus_mask, + int sound_behavior, + ffi.Pointer extra_info, +); + +typedef _c_sound_manager_acquire_focus_all = ffi.Int32 Function( + ffi.Pointer stream_info, + ffi.Int32 sound_behavior, + ffi.Pointer extra_info, +); + +typedef _dart_sound_manager_acquire_focus_all = int Function( + ffi.Pointer stream_info, + int sound_behavior, + ffi.Pointer extra_info, +); + +typedef _c_sound_manager_release_focus_all = ffi.Int32 Function( + ffi.Pointer stream_info, + ffi.Int32 sound_behavior, + ffi.Pointer extra_info, +); + +typedef _dart_sound_manager_release_focus_all = int Function( + ffi.Pointer stream_info, + int sound_behavior, + ffi.Pointer extra_info, +); + +typedef _c_sound_manager_get_focus_state = ffi.Int32 Function( + ffi.Pointer stream_info, + ffi.Pointer state_for_playback, + ffi.Pointer state_for_recording, +); + +typedef _dart_sound_manager_get_focus_state = int Function( + ffi.Pointer stream_info, + ffi.Pointer state_for_playback, + ffi.Pointer state_for_recording, +); + +typedef _c_sound_manager_set_focus_reacquisition = ffi.Int32 Function( + ffi.Pointer stream_info, + ffi.Uint8 enable, +); + +typedef _dart_sound_manager_set_focus_reacquisition = int Function( + ffi.Pointer stream_info, + int enable, +); + +typedef _c_sound_manager_get_focus_reacquisition = ffi.Int32 Function( + ffi.Pointer stream_info, + ffi.Pointer enabled, +); + +typedef _dart_sound_manager_get_focus_reacquisition = int Function( + ffi.Pointer stream_info, + ffi.Pointer enabled, +); + +typedef _c_sound_manager_deliver_focus = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer destination, + ffi.Int32 focus_mask, +); + +typedef _dart_sound_manager_deliver_focus = int Function( + ffi.Pointer source, + ffi.Pointer destination, + int focus_mask, +); + +typedef _c_sound_manager_is_stream_on_device = ffi.Int32 Function( + ffi.Pointer stream_info, + ffi.Pointer device, + ffi.Pointer is_on, +); + +typedef _dart_sound_manager_is_stream_on_device = int Function( + ffi.Pointer stream_info, + ffi.Pointer device, + ffi.Pointer is_on, +); + +typedef _c_sound_manager_get_current_media_playback_device_type = ffi.Int32 + Function( + ffi.Pointer device_type, +); + +typedef _dart_sound_manager_get_current_media_playback_device_type = int + Function( + ffi.Pointer device_type, +); + +typedef _c_sound_manager_get_current_playback_focus = ffi.Int32 Function( + ffi.Pointer acquired_by, + ffi.Pointer sound_behavior, + ffi.Pointer> extra_info, +); + +typedef _dart_sound_manager_get_current_playback_focus = int Function( + ffi.Pointer acquired_by, + ffi.Pointer sound_behavior, + ffi.Pointer> extra_info, +); + +typedef _c_sound_manager_get_current_recording_focus = ffi.Int32 Function( + ffi.Pointer acquired_by, + ffi.Pointer sound_behavior, + ffi.Pointer> extra_info, +); + +typedef _dart_sound_manager_get_current_recording_focus = int Function( + ffi.Pointer acquired_by, + ffi.Pointer sound_behavior, + ffi.Pointer> extra_info, +); + +typedef sound_stream_focus_state_watch_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_sound_manager_add_focus_state_watch_cb = ffi.Int32 Function( + ffi.Int32 focus_mask, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _dart_sound_manager_add_focus_state_watch_cb = int Function( + int focus_mask, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _c_sound_manager_remove_focus_state_watch_cb = ffi.Int32 Function( + ffi.Int32 id, +); + +typedef _dart_sound_manager_remove_focus_state_watch_cb = int Function( + int id, +); + +typedef _c_sound_manager_set_session_type = ffi.Int32 Function( + ffi.Int32 type, +); + +typedef _dart_sound_manager_set_session_type = int Function( + int type, +); + +typedef _c_sound_manager_get_session_type = ffi.Int32 Function( + ffi.Pointer type, +); + +typedef _dart_sound_manager_get_session_type = int Function( + ffi.Pointer type, +); + +typedef _c_sound_manager_set_media_session_option = ffi.Int32 Function( + ffi.Int32 s_option, + ffi.Int32 d_option, +); + +typedef _dart_sound_manager_set_media_session_option = int Function( + int s_option, + int d_option, +); + +typedef _c_sound_manager_get_media_session_option = ffi.Int32 Function( + ffi.Pointer s_option, + ffi.Pointer d_option, +); + +typedef _dart_sound_manager_get_media_session_option = int Function( + ffi.Pointer s_option, + ffi.Pointer d_option, +); + +typedef _c_sound_manager_set_media_session_resumption_option = ffi.Int32 + Function( + ffi.Int32 option, +); + +typedef _dart_sound_manager_set_media_session_resumption_option = int Function( + int option, +); + +typedef _c_sound_manager_get_media_session_resumption_option = ffi.Int32 + Function( + ffi.Pointer option, +); + +typedef _dart_sound_manager_get_media_session_resumption_option = int Function( + ffi.Pointer option, +); + +typedef _c_sound_manager_set_voip_session_mode = ffi.Int32 Function( + ffi.Int32 mode, +); + +typedef _dart_sound_manager_set_voip_session_mode = int Function( + int mode, +); + +typedef _c_sound_manager_get_voip_session_mode = ffi.Int32 Function( + ffi.Pointer mode, +); + +typedef _dart_sound_manager_get_voip_session_mode = int Function( + ffi.Pointer mode, +); + +typedef sound_session_interrupted_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_sound_manager_set_session_interrupted_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_sound_manager_set_session_interrupted_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_sound_manager_unset_session_interrupted_cb = ffi.Int32 Function(); + +typedef _dart_sound_manager_unset_session_interrupted_cb = int Function(); + +typedef _c_sound_manager_get_current_device_list = ffi.Int32 Function( + ffi.Int32 device_mask, + ffi.Pointer> device_list, +); + +typedef _dart_sound_manager_get_current_device_list = int Function( + int device_mask, + ffi.Pointer> device_list, +); + +typedef _c_sound_manager_get_device_list = ffi.Int32 Function( + ffi.Int32 device_mask, + ffi.Pointer> device_list, +); + +typedef _dart_sound_manager_get_device_list = int Function( + int device_mask, + ffi.Pointer> device_list, +); + +typedef _c_sound_manager_free_device_list = ffi.Int32 Function( + ffi.Pointer device_list, +); + +typedef _dart_sound_manager_free_device_list = int Function( + ffi.Pointer device_list, +); + +typedef _c_sound_manager_get_next_device = ffi.Int32 Function( + ffi.Pointer device_list, + ffi.Pointer> device, +); + +typedef _dart_sound_manager_get_next_device = int Function( + ffi.Pointer device_list, + ffi.Pointer> device, +); + +typedef _c_sound_manager_get_prev_device = ffi.Int32 Function( + ffi.Pointer device_list, + ffi.Pointer> device, +); + +typedef _dart_sound_manager_get_prev_device = int Function( + ffi.Pointer device_list, + ffi.Pointer> device, +); + +typedef _c_sound_manager_get_device_type = ffi.Int32 Function( + ffi.Pointer device, + ffi.Pointer type, +); + +typedef _dart_sound_manager_get_device_type = int Function( + ffi.Pointer device, + ffi.Pointer type, +); + +typedef _c_sound_manager_get_device_io_direction = ffi.Int32 Function( + ffi.Pointer device, + ffi.Pointer io_direction, +); + +typedef _dart_sound_manager_get_device_io_direction = int Function( + ffi.Pointer device, + ffi.Pointer io_direction, +); + +typedef _c_sound_manager_get_device_id = ffi.Int32 Function( + ffi.Pointer device, + ffi.Pointer id, +); + +typedef _dart_sound_manager_get_device_id = int Function( + ffi.Pointer device, + ffi.Pointer id, +); + +typedef _c_sound_manager_get_device_name = ffi.Int32 Function( + ffi.Pointer device, + ffi.Pointer> name, +); + +typedef _dart_sound_manager_get_device_name = int Function( + ffi.Pointer device, + ffi.Pointer> name, +); + +typedef _c_sound_manager_get_device_state = ffi.Int32 Function( + ffi.Pointer device, + ffi.Pointer state, +); + +typedef _dart_sound_manager_get_device_state = int Function( + ffi.Pointer device, + ffi.Pointer state, +); + +typedef sound_device_connected_cb = ffi.Void Function( + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_sound_manager_set_device_connected_cb = ffi.Int32 Function( + ffi.Int32 device_mask, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_sound_manager_set_device_connected_cb = int Function( + int device_mask, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_sound_manager_unset_device_connected_cb = ffi.Int32 Function(); + +typedef _dart_sound_manager_unset_device_connected_cb = int Function(); + +typedef sound_device_connection_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_sound_manager_add_device_connection_changed_cb = ffi.Int32 Function( + ffi.Int32 device_mask, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _dart_sound_manager_add_device_connection_changed_cb = int Function( + int device_mask, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _c_sound_manager_remove_device_connection_changed_cb = ffi.Int32 + Function( + ffi.Int32 id, +); + +typedef _dart_sound_manager_remove_device_connection_changed_cb = int Function( + int id, +); + +typedef sound_device_information_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_sound_manager_set_device_information_changed_cb = ffi.Int32 Function( + ffi.Int32 device_mask, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_sound_manager_set_device_information_changed_cb = int Function( + int device_mask, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_sound_manager_unset_device_information_changed_cb = ffi.Int32 + Function(); + +typedef _dart_sound_manager_unset_device_information_changed_cb = int + Function(); + +typedef sound_device_state_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_sound_manager_add_device_state_changed_cb = ffi.Int32 Function( + ffi.Int32 device_mask, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _dart_sound_manager_add_device_state_changed_cb = int Function( + int device_mask, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _c_sound_manager_remove_device_state_changed_cb = ffi.Int32 Function( + ffi.Int32 id, +); + +typedef _dart_sound_manager_remove_device_state_changed_cb = int Function( + int id, +); + +typedef _c_audio_in_create = ffi.Int32 Function( + ffi.Int32 sample_rate, + ffi.Int32 channel, + ffi.Int32 type, + ffi.Pointer> input, +); + +typedef _dart_audio_in_create = int Function( + int sample_rate, + int channel, + int type, + ffi.Pointer> input, +); + +typedef _c_audio_in_create_loopback = ffi.Int32 Function( + ffi.Int32 sample_rate, + ffi.Int32 channel, + ffi.Int32 type, + ffi.Pointer> input, +); + +typedef _dart_audio_in_create_loopback = int Function( + int sample_rate, + int channel, + int type, + ffi.Pointer> input, +); + +typedef _c_audio_in_destroy = ffi.Int32 Function( + ffi.Pointer input, +); + +typedef _dart_audio_in_destroy = int Function( + ffi.Pointer input, +); + +typedef _c_audio_in_set_sound_stream_info = ffi.Int32 Function( + ffi.Pointer input, + ffi.Pointer stream_info, +); + +typedef _dart_audio_in_set_sound_stream_info = int Function( + ffi.Pointer input, + ffi.Pointer stream_info, +); + +typedef _c_audio_in_prepare = ffi.Int32 Function( + ffi.Pointer input, +); + +typedef _dart_audio_in_prepare = int Function( + ffi.Pointer input, +); + +typedef _c_audio_in_unprepare = ffi.Int32 Function( + ffi.Pointer input, +); + +typedef _dart_audio_in_unprepare = int Function( + ffi.Pointer input, +); + +typedef _c_audio_in_pause = ffi.Int32 Function( + ffi.Pointer input, +); + +typedef _dart_audio_in_pause = int Function( + ffi.Pointer input, +); + +typedef _c_audio_in_resume = ffi.Int32 Function( + ffi.Pointer input, +); + +typedef _dart_audio_in_resume = int Function( + ffi.Pointer input, +); + +typedef _c_audio_in_flush = ffi.Int32 Function( + ffi.Pointer input, +); + +typedef _dart_audio_in_flush = int Function( + ffi.Pointer input, +); + +typedef _c_audio_in_read = ffi.Int32 Function( + ffi.Pointer input, + ffi.Pointer buffer, + ffi.Uint32 length, +); + +typedef _dart_audio_in_read = int Function( + ffi.Pointer input, + ffi.Pointer buffer, + int length, +); + +typedef _c_audio_in_get_buffer_size = ffi.Int32 Function( + ffi.Pointer input, + ffi.Pointer size, +); + +typedef _dart_audio_in_get_buffer_size = int Function( + ffi.Pointer input, + ffi.Pointer size, +); + +typedef _c_audio_in_get_sample_rate = ffi.Int32 Function( + ffi.Pointer input, + ffi.Pointer sample_rate, +); + +typedef _dart_audio_in_get_sample_rate = int Function( + ffi.Pointer input, + ffi.Pointer sample_rate, +); + +typedef _c_audio_in_get_channel = ffi.Int32 Function( + ffi.Pointer input, + ffi.Pointer channel, +); + +typedef _dart_audio_in_get_channel = int Function( + ffi.Pointer input, + ffi.Pointer channel, +); + +typedef _c_audio_in_get_sample_type = ffi.Int32 Function( + ffi.Pointer input, + ffi.Pointer type, +); + +typedef _dart_audio_in_get_sample_type = int Function( + ffi.Pointer input, + ffi.Pointer type, +); + +typedef audio_io_interrupted_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_audio_in_set_interrupted_cb = ffi.Int32 Function( + ffi.Pointer input, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_audio_in_set_interrupted_cb = int Function( + ffi.Pointer input, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_audio_in_unset_interrupted_cb = ffi.Int32 Function( + ffi.Pointer input, +); + +typedef _dart_audio_in_unset_interrupted_cb = int Function( + ffi.Pointer input, +); + +typedef _c_audio_in_ignore_session = ffi.Int32 Function( + ffi.Pointer input, +); + +typedef _dart_audio_in_ignore_session = int Function( + ffi.Pointer input, +); + +typedef audio_in_stream_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_audio_in_set_stream_cb = ffi.Int32 Function( + ffi.Pointer input, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_audio_in_set_stream_cb = int Function( + ffi.Pointer input, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_audio_in_unset_stream_cb = ffi.Int32 Function( + ffi.Pointer input, +); + +typedef _dart_audio_in_unset_stream_cb = int Function( + ffi.Pointer input, +); + +typedef _c_audio_in_peek = ffi.Int32 Function( + ffi.Pointer input, + ffi.Pointer> buffer, + ffi.Pointer length, +); + +typedef _dart_audio_in_peek = int Function( + ffi.Pointer input, + ffi.Pointer> buffer, + ffi.Pointer length, +); + +typedef _c_audio_in_drop = ffi.Int32 Function( + ffi.Pointer input, +); + +typedef _dart_audio_in_drop = int Function( + ffi.Pointer input, +); + +typedef audio_in_state_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_audio_in_set_state_changed_cb = ffi.Int32 Function( + ffi.Pointer input, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_audio_in_set_state_changed_cb = int Function( + ffi.Pointer input, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_audio_in_unset_state_changed_cb = ffi.Int32 Function( + ffi.Pointer input, +); + +typedef _dart_audio_in_unset_state_changed_cb = int Function( + ffi.Pointer input, +); + +typedef _c_audio_out_create = ffi.Int32 Function( + ffi.Int32 sample_rate, + ffi.Int32 channel, + ffi.Int32 type, + ffi.Int32 sound_type, + ffi.Pointer> output, +); + +typedef _dart_audio_out_create = int Function( + int sample_rate, + int channel, + int type, + int sound_type, + ffi.Pointer> output, +); + +typedef _c_audio_out_create_new = ffi.Int32 Function( + ffi.Int32 sample_rate, + ffi.Int32 channel, + ffi.Int32 type, + ffi.Pointer> output, +); + +typedef _dart_audio_out_create_new = int Function( + int sample_rate, + int channel, + int type, + ffi.Pointer> output, +); + +typedef _c_audio_out_destroy = ffi.Int32 Function( + ffi.Pointer output, +); + +typedef _dart_audio_out_destroy = int Function( + ffi.Pointer output, +); + +typedef _c_audio_out_set_sound_stream_info = ffi.Int32 Function( + ffi.Pointer output, + ffi.Pointer stream_info, +); + +typedef _dart_audio_out_set_sound_stream_info = int Function( + ffi.Pointer output, + ffi.Pointer stream_info, +); + +typedef _c_audio_out_prepare = ffi.Int32 Function( + ffi.Pointer output, +); + +typedef _dart_audio_out_prepare = int Function( + ffi.Pointer output, +); + +typedef _c_audio_out_unprepare = ffi.Int32 Function( + ffi.Pointer output, +); + +typedef _dart_audio_out_unprepare = int Function( + ffi.Pointer output, +); + +typedef _c_audio_out_pause = ffi.Int32 Function( + ffi.Pointer output, +); + +typedef _dart_audio_out_pause = int Function( + ffi.Pointer output, +); + +typedef _c_audio_out_resume = ffi.Int32 Function( + ffi.Pointer output, +); + +typedef _dart_audio_out_resume = int Function( + ffi.Pointer output, +); + +typedef _c_audio_out_drain = ffi.Int32 Function( + ffi.Pointer output, +); + +typedef _dart_audio_out_drain = int Function( + ffi.Pointer output, +); + +typedef _c_audio_out_flush = ffi.Int32 Function( + ffi.Pointer output, +); + +typedef _dart_audio_out_flush = int Function( + ffi.Pointer output, +); + +typedef _c_audio_out_write = ffi.Int32 Function( + ffi.Pointer output, + ffi.Pointer buffer, + ffi.Uint32 length, +); + +typedef _dart_audio_out_write = int Function( + ffi.Pointer output, + ffi.Pointer buffer, + int length, +); + +typedef _c_audio_out_get_buffer_size = ffi.Int32 Function( + ffi.Pointer output, + ffi.Pointer size, +); + +typedef _dart_audio_out_get_buffer_size = int Function( + ffi.Pointer output, + ffi.Pointer size, +); + +typedef _c_audio_out_get_sample_rate = ffi.Int32 Function( + ffi.Pointer output, + ffi.Pointer sample_rate, +); + +typedef _dart_audio_out_get_sample_rate = int Function( + ffi.Pointer output, + ffi.Pointer sample_rate, +); + +typedef _c_audio_out_get_channel = ffi.Int32 Function( + ffi.Pointer output, + ffi.Pointer channel, +); + +typedef _dart_audio_out_get_channel = int Function( + ffi.Pointer output, + ffi.Pointer channel, +); + +typedef _c_audio_out_get_sample_type = ffi.Int32 Function( + ffi.Pointer output, + ffi.Pointer type, +); + +typedef _dart_audio_out_get_sample_type = int Function( + ffi.Pointer output, + ffi.Pointer type, +); + +typedef _c_audio_out_get_sound_type = ffi.Int32 Function( + ffi.Pointer output, + ffi.Pointer type, +); + +typedef _dart_audio_out_get_sound_type = int Function( + ffi.Pointer output, + ffi.Pointer type, +); + +typedef _c_audio_out_set_interrupted_cb = ffi.Int32 Function( + ffi.Pointer output, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_audio_out_set_interrupted_cb = int Function( + ffi.Pointer output, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_audio_out_unset_interrupted_cb = ffi.Int32 Function( + ffi.Pointer output, +); + +typedef _dart_audio_out_unset_interrupted_cb = int Function( + ffi.Pointer output, +); + +typedef _c_audio_out_ignore_session = ffi.Int32 Function( + ffi.Pointer output, +); + +typedef _dart_audio_out_ignore_session = int Function( + ffi.Pointer output, +); + +typedef audio_out_stream_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_audio_out_set_stream_cb = ffi.Int32 Function( + ffi.Pointer output, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_audio_out_set_stream_cb = int Function( + ffi.Pointer output, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_audio_out_unset_stream_cb = ffi.Int32 Function( + ffi.Pointer output, +); + +typedef _dart_audio_out_unset_stream_cb = int Function( + ffi.Pointer output, +); + +typedef audio_out_state_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_audio_out_set_state_changed_cb = ffi.Int32 Function( + ffi.Pointer output, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_audio_out_set_state_changed_cb = int Function( + ffi.Pointer output, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_audio_out_unset_state_changed_cb = ffi.Int32 Function( + ffi.Pointer output, +); + +typedef _dart_audio_out_unset_state_changed_cb = int Function( + ffi.Pointer output, +); + +typedef _c_media_format_create = ffi.Int32 Function( + ffi.Pointer> fmt, +); + +typedef _dart_media_format_create = int Function( + ffi.Pointer> fmt, +); + +typedef _c_media_format_get_type = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer formattype, +); + +typedef _dart_media_format_get_type = int Function( + ffi.Pointer fmt, + ffi.Pointer formattype, +); + +typedef _c_media_format_get_container_mime = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer mimetype, +); + +typedef _dart_media_format_get_container_mime = int Function( + ffi.Pointer fmt, + ffi.Pointer mimetype, +); + +typedef _c_media_format_get_text_info = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer mimetype, + ffi.Pointer type, +); + +typedef _dart_media_format_get_text_info = int Function( + ffi.Pointer fmt, + ffi.Pointer mimetype, + ffi.Pointer type, +); + +typedef _c_media_format_get_video_info = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer mimetype, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer avg_bps, + ffi.Pointer max_bps, +); + +typedef _dart_media_format_get_video_info = int Function( + ffi.Pointer fmt, + ffi.Pointer mimetype, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer avg_bps, + ffi.Pointer max_bps, +); + +typedef _c_media_format_get_audio_info = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer mimetype, + ffi.Pointer channel, + ffi.Pointer samplerate, + ffi.Pointer bit, + ffi.Pointer avg_bps, +); + +typedef _dart_media_format_get_audio_info = int Function( + ffi.Pointer fmt, + ffi.Pointer mimetype, + ffi.Pointer channel, + ffi.Pointer samplerate, + ffi.Pointer bit, + ffi.Pointer avg_bps, +); + +typedef _c_media_format_get_audio_aac_type = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer is_adts, +); + +typedef _dart_media_format_get_audio_aac_type = int Function( + ffi.Pointer fmt, + ffi.Pointer is_adts, +); + +typedef _c_media_format_get_audio_aac_header_type = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer aac_header_type, +); + +typedef _dart_media_format_get_audio_aac_header_type = int Function( + ffi.Pointer fmt, + ffi.Pointer aac_header_type, +); + +typedef _c_media_format_get_video_frame_rate = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer frame_rate, +); + +typedef _dart_media_format_get_video_frame_rate = int Function( + ffi.Pointer fmt, + ffi.Pointer frame_rate, +); + +typedef _c_media_format_set_container_mime = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 mimetype, +); + +typedef _dart_media_format_set_container_mime = int Function( + ffi.Pointer fmt, + int mimetype, +); + +typedef _c_media_format_set_text_mime = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 mimetype, +); + +typedef _dart_media_format_set_text_mime = int Function( + ffi.Pointer fmt, + int mimetype, +); + +typedef _c_media_format_set_text_type = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 type, +); + +typedef _dart_media_format_set_text_type = int Function( + ffi.Pointer fmt, + int type, +); + +typedef _c_media_format_set_video_mime = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 mimetype, +); + +typedef _dart_media_format_set_video_mime = int Function( + ffi.Pointer fmt, + int mimetype, +); + +typedef _c_media_format_set_video_width = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 width, +); + +typedef _dart_media_format_set_video_width = int Function( + ffi.Pointer fmt, + int width, +); + +typedef _c_media_format_set_video_height = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 height, +); + +typedef _dart_media_format_set_video_height = int Function( + ffi.Pointer fmt, + int height, +); + +typedef _c_media_format_set_video_avg_bps = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 avg_bps, +); + +typedef _dart_media_format_set_video_avg_bps = int Function( + ffi.Pointer fmt, + int avg_bps, +); + +typedef _c_media_format_set_video_max_bps = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 max_bps, +); + +typedef _dart_media_format_set_video_max_bps = int Function( + ffi.Pointer fmt, + int max_bps, +); + +typedef _c_media_format_set_video_frame_rate = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 frame_rate, +); + +typedef _dart_media_format_set_video_frame_rate = int Function( + ffi.Pointer fmt, + int frame_rate, +); + +typedef _c_media_format_set_audio_mime = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 mimetype, +); + +typedef _dart_media_format_set_audio_mime = int Function( + ffi.Pointer fmt, + int mimetype, +); + +typedef _c_media_format_set_audio_channel = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 channel, +); + +typedef _dart_media_format_set_audio_channel = int Function( + ffi.Pointer fmt, + int channel, +); + +typedef _c_media_format_set_audio_samplerate = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 samplerate, +); + +typedef _dart_media_format_set_audio_samplerate = int Function( + ffi.Pointer fmt, + int samplerate, +); + +typedef _c_media_format_set_audio_bit = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 bit, +); + +typedef _dart_media_format_set_audio_bit = int Function( + ffi.Pointer fmt, + int bit, +); + +typedef _c_media_format_set_audio_avg_bps = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 avg_bps, +); + +typedef _dart_media_format_set_audio_avg_bps = int Function( + ffi.Pointer fmt, + int avg_bps, +); + +typedef _c_media_format_set_audio_aac_type = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Uint8 is_adts, +); + +typedef _dart_media_format_set_audio_aac_type = int Function( + ffi.Pointer fmt, + int is_adts, +); + +typedef _c_media_format_set_audio_aac_header_type = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Int32 aac_header_type, +); + +typedef _dart_media_format_set_audio_aac_header_type = int Function( + ffi.Pointer fmt, + int aac_header_type, +); + +typedef _c_media_format_ref = ffi.Int32 Function( + ffi.Pointer fmt, +); + +typedef _dart_media_format_ref = int Function( + ffi.Pointer fmt, +); + +typedef _c_media_format_unref = ffi.Int32 Function( + ffi.Pointer fmt, +); + +typedef _dart_media_format_unref = int Function( + ffi.Pointer fmt, +); + +typedef _c_media_format_is_writable = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer is_writable, +); + +typedef _dart_media_format_is_writable = int Function( + ffi.Pointer fmt, + ffi.Pointer is_writable, +); + +typedef _c_media_format_make_writable = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer> out_fmt, +); + +typedef _dart_media_format_make_writable = int Function( + ffi.Pointer fmt, + ffi.Pointer> out_fmt, +); + +typedef _c_media_format_set_extra = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer extra_data, +); + +typedef _dart_media_format_set_extra = int Function( + ffi.Pointer fmt, + ffi.Pointer extra_data, +); + +typedef _c_media_format_get_extra = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer> extra_data, +); + +typedef _dart_media_format_get_extra = int Function( + ffi.Pointer fmt, + ffi.Pointer> extra_data, +); + +typedef media_packet_finalize_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_media_packet_create_alloc = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> packet, +); + +typedef _dart_media_packet_create_alloc = int Function( + ffi.Pointer fmt, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> packet, +); + +typedef _c_media_packet_create = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> packet, +); + +typedef _dart_media_packet_create = int Function( + ffi.Pointer fmt, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> packet, +); + +typedef _c_media_packet_copy = ffi.Int32 Function( + ffi.Pointer org_packet, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> new_packet, +); + +typedef _dart_media_packet_copy = int Function( + ffi.Pointer org_packet, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> new_packet, +); + +typedef _c_media_packet_alloc = ffi.Int32 Function( + ffi.Pointer packet, +); + +typedef _dart_media_packet_alloc = int Function( + ffi.Pointer packet, +); + +typedef _c_media_packet_create_from_tbm_surface = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer surface, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> packet, +); + +typedef _dart_media_packet_create_from_tbm_surface = int Function( + ffi.Pointer fmt, + ffi.Pointer surface, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> packet, +); + +typedef _c_media_packet_create_from_external_memory = ffi.Int32 Function( + ffi.Pointer fmt, + ffi.Pointer mem_ptr, + ffi.Uint64 size, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> packet, +); + +typedef _dart_media_packet_create_from_external_memory = int Function( + ffi.Pointer fmt, + ffi.Pointer mem_ptr, + int size, + ffi.Pointer> fcb, + ffi.Pointer fcb_data, + ffi.Pointer> packet, +); + +typedef _c_media_packet_get_format = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer> fmt, +); + +typedef _dart_media_packet_get_format = int Function( + ffi.Pointer packet, + ffi.Pointer> fmt, +); + +typedef _c_media_packet_set_format = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer fmt, +); + +typedef _dart_media_packet_set_format = int Function( + ffi.Pointer packet, + ffi.Pointer fmt, +); + +typedef _c_media_packet_set_pts = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Uint64 pts, +); + +typedef _dart_media_packet_set_pts = int Function( + ffi.Pointer packet, + int pts, +); + +typedef _c_media_packet_set_dts = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Uint64 dts, +); + +typedef _dart_media_packet_set_dts = int Function( + ffi.Pointer packet, + int dts, +); + +typedef _c_media_packet_set_duration = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Uint64 duration, +); + +typedef _dart_media_packet_set_duration = int Function( + ffi.Pointer packet, + int duration, +); + +typedef _c_media_packet_set_buffer_size = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Uint64 size, +); + +typedef _dart_media_packet_set_buffer_size = int Function( + ffi.Pointer packet, + int size, +); + +typedef _c_media_packet_get_pts = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer pts, +); + +typedef _dart_media_packet_get_pts = int Function( + ffi.Pointer packet, + ffi.Pointer pts, +); + +typedef _c_media_packet_get_dts = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer dts, +); + +typedef _dart_media_packet_get_dts = int Function( + ffi.Pointer packet, + ffi.Pointer dts, +); + +typedef _c_media_packet_get_duration = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer duration, +); + +typedef _dart_media_packet_get_duration = int Function( + ffi.Pointer packet, + ffi.Pointer duration, +); + +typedef _c_media_packet_get_buffer_size = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer size, +); + +typedef _dart_media_packet_get_buffer_size = int Function( + ffi.Pointer packet, + ffi.Pointer size, +); + +typedef _c_media_packet_get_buffer_data_ptr = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer> data, +); + +typedef _dart_media_packet_get_buffer_data_ptr = int Function( + ffi.Pointer packet, + ffi.Pointer> data, +); + +typedef _c_media_packet_get_tbm_surface = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer> surface, +); + +typedef _dart_media_packet_get_tbm_surface = int Function( + ffi.Pointer packet, + ffi.Pointer> surface, +); + +typedef _c_media_packet_set_extra = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer extra, +); + +typedef _dart_media_packet_set_extra = int Function( + ffi.Pointer packet, + ffi.Pointer extra, +); + +typedef _c_media_packet_get_extra = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer> extra, +); + +typedef _dart_media_packet_get_extra = int Function( + ffi.Pointer packet, + ffi.Pointer> extra, +); + +typedef _c_media_packet_is_video = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer is_video, +); + +typedef _dart_media_packet_is_video = int Function( + ffi.Pointer packet, + ffi.Pointer is_video, +); + +typedef _c_media_packet_is_audio = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer is_audio, +); + +typedef _dart_media_packet_is_audio = int Function( + ffi.Pointer packet, + ffi.Pointer is_audio, +); + +typedef _c_media_packet_is_text = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer is_text, +); + +typedef _dart_media_packet_is_text = int Function( + ffi.Pointer packet, + ffi.Pointer is_text, +); + +typedef _c_media_packet_is_encoded = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer is_encoded, +); + +typedef _dart_media_packet_is_encoded = int Function( + ffi.Pointer packet, + ffi.Pointer is_encoded, +); + +typedef _c_media_packet_is_raw = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer is_raw, +); + +typedef _dart_media_packet_is_raw = int Function( + ffi.Pointer packet, + ffi.Pointer is_raw, +); + +typedef _c_media_packet_get_flags = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer flags, +); + +typedef _dart_media_packet_get_flags = int Function( + ffi.Pointer packet, + ffi.Pointer flags, +); + +typedef _c_media_packet_set_flags = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Int32 flags, +); + +typedef _dart_media_packet_set_flags = int Function( + ffi.Pointer packet, + int flags, +); + +typedef _c_media_packet_unset_flags = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Int32 flags, +); + +typedef _dart_media_packet_unset_flags = int Function( + ffi.Pointer packet, + int flags, +); + +typedef _c_media_packet_is_codec_config = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer is_codec_config, +); + +typedef _dart_media_packet_is_codec_config = int Function( + ffi.Pointer packet, + ffi.Pointer is_codec_config, +); + +typedef _c_media_packet_is_end_of_stream = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer is_eos, +); + +typedef _dart_media_packet_is_end_of_stream = int Function( + ffi.Pointer packet, + ffi.Pointer is_eos, +); + +typedef _c_media_packet_is_sync_frame = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer is_sync, +); + +typedef _dart_media_packet_is_sync_frame = int Function( + ffi.Pointer packet, + ffi.Pointer is_sync, +); + +typedef _c_media_packet_has_tbm_surface_buffer = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer has_tbm_surface, +); + +typedef _dart_media_packet_has_tbm_surface_buffer = int Function( + ffi.Pointer packet, + ffi.Pointer has_tbm_surface, +); + +typedef _c_media_packet_get_number_of_video_planes = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer num, +); + +typedef _dart_media_packet_get_number_of_video_planes = int Function( + ffi.Pointer packet, + ffi.Pointer num, +); + +typedef _c_media_packet_get_video_stride_width = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Int32 plane_idx, + ffi.Pointer stride_width, +); + +typedef _dart_media_packet_get_video_stride_width = int Function( + ffi.Pointer packet, + int plane_idx, + ffi.Pointer stride_width, +); + +typedef _c_media_packet_get_video_stride_height = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Int32 plane_idx, + ffi.Pointer stride_height, +); + +typedef _dart_media_packet_get_video_stride_height = int Function( + ffi.Pointer packet, + int plane_idx, + ffi.Pointer stride_height, +); + +typedef _c_media_packet_get_video_plane_data_ptr = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Int32 plane_idx, + ffi.Pointer> plane_data_ptr, +); + +typedef _dart_media_packet_get_video_plane_data_ptr = int Function( + ffi.Pointer packet, + int plane_idx, + ffi.Pointer> plane_data_ptr, +); + +typedef _c_media_packet_get_codec_data = ffi.Int32 Function( + ffi.Pointer packet, + ffi.Pointer> codec_data, + ffi.Pointer codec_data_size, +); + +typedef _dart_media_packet_get_codec_data = int Function( + ffi.Pointer packet, + ffi.Pointer> codec_data, + ffi.Pointer codec_data_size, +); + +typedef _c_media_packet_destroy = ffi.Int32 Function( + ffi.Pointer packet, +); + +typedef _dart_media_packet_destroy = int Function( + ffi.Pointer packet, +); + +typedef _c_camera_create = ffi.Int32 Function( + ffi.Int32 device, + ffi.Pointer> camera, +); + +typedef _dart_camera_create = int Function( + int device, + ffi.Pointer> camera, +); + +typedef _c_camera_change_device = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 device, +); + +typedef _dart_camera_change_device = int Function( + ffi.Pointer camera, + int device, +); + +typedef _c_camera_destroy = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_destroy = int Function( + ffi.Pointer camera, +); + +typedef _c_camera_start_preview = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_start_preview = int Function( + ffi.Pointer camera, +); + +typedef _c_camera_stop_preview = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_stop_preview = int Function( + ffi.Pointer camera, +); + +typedef camera_capturing_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef camera_capture_completed_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef _c_camera_start_capture = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> capturing_cb, + ffi.Pointer> completed_cb, + ffi.Pointer user_data, +); + +typedef _dart_camera_start_capture = int Function( + ffi.Pointer camera, + ffi.Pointer> capturing_cb, + ffi.Pointer> completed_cb, + ffi.Pointer user_data, +); + +typedef _c_camera_start_continuous_capture = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 count, + ffi.Int32 interval, + ffi.Pointer> capturing_cb, + ffi.Pointer> completed_cb, + ffi.Pointer user_data, +); + +typedef _dart_camera_start_continuous_capture = int Function( + ffi.Pointer camera, + int count, + int interval, + ffi.Pointer> capturing_cb, + ffi.Pointer> completed_cb, + ffi.Pointer user_data, +); + +typedef _c_camera_stop_continuous_capture = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_stop_continuous_capture = int Function( + ffi.Pointer camera, +); + +typedef _c_camera_get_state = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer state, +); + +typedef _dart_camera_get_state = int Function( + ffi.Pointer camera, + ffi.Pointer state, +); + +typedef _c_camera_start_focusing = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Uint8 continuous, +); + +typedef _dart_camera_start_focusing = int Function( + ffi.Pointer camera, + int continuous, +); + +typedef _c_camera_cancel_focusing = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_cancel_focusing = int Function( + ffi.Pointer camera, +); + +typedef _c_camera_set_display = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 type, + ffi.Pointer display, +); + +typedef _dart_camera_set_display = int Function( + ffi.Pointer camera, + int type, + ffi.Pointer display, +); + +typedef _c_camera_set_preview_resolution = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 width, + ffi.Int32 height, +); + +typedef _dart_camera_set_preview_resolution = int Function( + ffi.Pointer camera, + int width, + int height, +); + +typedef _c_camera_get_preview_resolution = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _dart_camera_get_preview_resolution = int Function( + ffi.Pointer camera, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _c_camera_get_recommended_preview_resolution = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _dart_camera_get_recommended_preview_resolution = int Function( + ffi.Pointer camera, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef camera_face_detected_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_start_face_detection = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_start_face_detection = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_stop_face_detection = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_stop_face_detection = int Function( + ffi.Pointer camera, +); + +typedef _c_camera_is_supported_continuous_capture = ffi.Uint8 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_is_supported_continuous_capture = int Function( + ffi.Pointer camera, +); + +typedef camera_supported_preview_resolution_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_foreach_supported_preview_resolution = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_foreach_supported_preview_resolution = int Function( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_camera_set_display_rotation = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 rotation, +); + +typedef _dart_camera_set_display_rotation = int Function( + ffi.Pointer camera, + int rotation, +); + +typedef _c_camera_get_display_rotation = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer rotation, +); + +typedef _dart_camera_get_display_rotation = int Function( + ffi.Pointer camera, + ffi.Pointer rotation, +); + +typedef _c_camera_set_display_flip = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 flip, +); + +typedef _dart_camera_set_display_flip = int Function( + ffi.Pointer camera, + int flip, +); + +typedef _c_camera_get_display_flip = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer flip, +); + +typedef _dart_camera_get_display_flip = int Function( + ffi.Pointer camera, + ffi.Pointer flip, +); + +typedef _c_camera_set_display_visible = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Uint8 visible, +); + +typedef _dart_camera_set_display_visible = int Function( + ffi.Pointer camera, + int visible, +); + +typedef _c_camera_is_display_visible = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer visible, +); + +typedef _dart_camera_is_display_visible = int Function( + ffi.Pointer camera, + ffi.Pointer visible, +); + +typedef _c_camera_set_display_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 mode, +); + +typedef _dart_camera_set_display_mode = int Function( + ffi.Pointer camera, + int mode, +); + +typedef _c_camera_get_display_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer mode, +); + +typedef _dart_camera_get_display_mode = int Function( + ffi.Pointer camera, + ffi.Pointer mode, +); + +typedef _c_camera_set_display_reuse_hint = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Uint8 hint, +); + +typedef _dart_camera_set_display_reuse_hint = int Function( + ffi.Pointer camera, + int hint, +); + +typedef _c_camera_get_display_reuse_hint = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer hint, +); + +typedef _dart_camera_get_display_reuse_hint = int Function( + ffi.Pointer camera, + ffi.Pointer hint, +); + +typedef _c_camera_set_capture_resolution = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 width, + ffi.Int32 height, +); + +typedef _dart_camera_set_capture_resolution = int Function( + ffi.Pointer camera, + int width, + int height, +); + +typedef _c_camera_get_capture_resolution = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _dart_camera_get_capture_resolution = int Function( + ffi.Pointer camera, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef camera_supported_capture_resolution_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_foreach_supported_capture_resolution = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_foreach_supported_capture_resolution = int Function( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_camera_set_capture_format = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 format, +); + +typedef _dart_camera_set_capture_format = int Function( + ffi.Pointer camera, + int format, +); + +typedef _c_camera_get_capture_format = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer format, +); + +typedef _dart_camera_get_capture_format = int Function( + ffi.Pointer camera, + ffi.Pointer format, +); + +typedef camera_supported_capture_format_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_foreach_supported_capture_format = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_foreach_supported_capture_format = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_set_preview_format = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 format, +); + +typedef _dart_camera_set_preview_format = int Function( + ffi.Pointer camera, + int format, +); + +typedef _c_camera_get_preview_format = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer format, +); + +typedef _dart_camera_get_preview_format = int Function( + ffi.Pointer camera, + ffi.Pointer format, +); + +typedef _c_camera_get_facing_direction = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer facing_direction, +); + +typedef _dart_camera_get_facing_direction = int Function( + ffi.Pointer camera, + ffi.Pointer facing_direction, +); + +typedef _c_camera_get_flash_state = ffi.Int32 Function( + ffi.Int32 device, + ffi.Pointer state, +); + +typedef _dart_camera_get_flash_state = int Function( + int device, + ffi.Pointer state, +); + +typedef camera_supported_preview_format_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_foreach_supported_preview_format = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_foreach_supported_preview_format = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_is_supported_face_detection = ffi.Uint8 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_is_supported_face_detection = int Function( + ffi.Pointer camera, +); + +typedef _c_camera_is_supported_zero_shutter_lag = ffi.Uint8 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_is_supported_zero_shutter_lag = int Function( + ffi.Pointer camera, +); + +typedef _c_camera_get_device_count = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer device_count, +); + +typedef _dart_camera_get_device_count = int Function( + ffi.Pointer camera, + ffi.Pointer device_count, +); + +typedef _c_camera_is_supported_media_packet_preview_cb = ffi.Uint8 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_is_supported_media_packet_preview_cb = int Function( + ffi.Pointer camera, +); + +typedef camera_preview_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_camera_set_preview_cb = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_set_preview_cb = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_unset_preview_cb = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_unset_preview_cb = int Function( + ffi.Pointer camera, +); + +typedef camera_media_packet_preview_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_camera_set_media_packet_preview_cb = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_set_media_packet_preview_cb = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_unset_media_packet_preview_cb = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_unset_media_packet_preview_cb = int Function( + ffi.Pointer camera, +); + +typedef camera_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_camera_set_state_changed_cb = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_set_state_changed_cb = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_unset_state_changed_cb = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_unset_state_changed_cb = int Function( + ffi.Pointer camera, +); + +typedef camera_interrupted_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_set_interrupted_cb = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_set_interrupted_cb = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_unset_interrupted_cb = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_unset_interrupted_cb = int Function( + ffi.Pointer camera, +); + +typedef camera_interrupt_started_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_set_interrupt_started_cb = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_set_interrupt_started_cb = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_unset_interrupt_started_cb = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_unset_interrupt_started_cb = int Function( + ffi.Pointer camera, +); + +typedef camera_focus_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_set_focus_changed_cb = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_set_focus_changed_cb = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_unset_focus_changed_cb = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_unset_focus_changed_cb = int Function( + ffi.Pointer camera, +); + +typedef camera_error_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_set_error_cb = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_set_error_cb = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_unset_error_cb = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_unset_error_cb = int Function( + ffi.Pointer camera, +); + +typedef _c_camera_get_device_state = ffi.Int32 Function( + ffi.Int32 device, + ffi.Pointer state, +); + +typedef _dart_camera_get_device_state = int Function( + int device, + ffi.Pointer state, +); + +typedef camera_device_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_add_device_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer cb_id, +); + +typedef _dart_camera_add_device_state_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer cb_id, +); + +typedef _c_camera_remove_device_state_changed_cb = ffi.Int32 Function( + ffi.Int32 cb_id, +); + +typedef _dart_camera_remove_device_state_changed_cb = int Function( + int cb_id, +); + +typedef _c_camera_attr_set_preview_fps = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 fps, +); + +typedef _dart_camera_attr_set_preview_fps = int Function( + ffi.Pointer camera, + int fps, +); + +typedef _c_camera_attr_get_preview_fps = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer fps, +); + +typedef _dart_camera_attr_get_preview_fps = int Function( + ffi.Pointer camera, + ffi.Pointer fps, +); + +typedef camera_attr_supported_fps_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_attr_foreach_supported_fps = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_attr_foreach_supported_fps = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_attr_foreach_supported_fps_by_resolution = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 width, + ffi.Int32 height, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_attr_foreach_supported_fps_by_resolution = int Function( + ffi.Pointer camera, + int width, + int height, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_attr_set_image_quality = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 quality, +); + +typedef _dart_camera_attr_set_image_quality = int Function( + ffi.Pointer camera, + int quality, +); + +typedef _c_camera_attr_get_image_quality = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer quality, +); + +typedef _dart_camera_attr_get_image_quality = int Function( + ffi.Pointer camera, + ffi.Pointer quality, +); + +typedef _c_camera_attr_get_encoded_preview_bitrate = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer bitrate, +); + +typedef _dart_camera_attr_get_encoded_preview_bitrate = int Function( + ffi.Pointer camera, + ffi.Pointer bitrate, +); + +typedef _c_camera_attr_set_encoded_preview_bitrate = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 bitrate, +); + +typedef _dart_camera_attr_set_encoded_preview_bitrate = int Function( + ffi.Pointer camera, + int bitrate, +); + +typedef _c_camera_attr_get_encoded_preview_gop_interval = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer interval, +); + +typedef _dart_camera_attr_get_encoded_preview_gop_interval = int Function( + ffi.Pointer camera, + ffi.Pointer interval, +); + +typedef _c_camera_attr_set_encoded_preview_gop_interval = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 interval, +); + +typedef _dart_camera_attr_set_encoded_preview_gop_interval = int Function( + ffi.Pointer camera, + int interval, +); + +typedef _c_camera_attr_set_zoom = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 zoom, +); + +typedef _dart_camera_attr_set_zoom = int Function( + ffi.Pointer camera, + int zoom, +); + +typedef _c_camera_attr_get_zoom = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer zoom, +); + +typedef _dart_camera_attr_get_zoom = int Function( + ffi.Pointer camera, + ffi.Pointer zoom, +); + +typedef _c_camera_attr_get_zoom_range = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _dart_camera_attr_get_zoom_range = int Function( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _c_camera_attr_set_af_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 mode, +); + +typedef _dart_camera_attr_set_af_mode = int Function( + ffi.Pointer camera, + int mode, +); + +typedef _c_camera_attr_get_af_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer mode, +); + +typedef _dart_camera_attr_get_af_mode = int Function( + ffi.Pointer camera, + ffi.Pointer mode, +); + +typedef _c_camera_attr_set_af_area = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 x, + ffi.Int32 y, +); + +typedef _dart_camera_attr_set_af_area = int Function( + ffi.Pointer camera, + int x, + int y, +); + +typedef _c_camera_attr_clear_af_area = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_attr_clear_af_area = int Function( + ffi.Pointer camera, +); + +typedef camera_attr_supported_af_mode_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_attr_foreach_supported_af_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_attr_foreach_supported_af_mode = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_attr_set_exposure_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 mode, +); + +typedef _dart_camera_attr_set_exposure_mode = int Function( + ffi.Pointer camera, + int mode, +); + +typedef _c_camera_attr_get_exposure_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer mode, +); + +typedef _dart_camera_attr_get_exposure_mode = int Function( + ffi.Pointer camera, + ffi.Pointer mode, +); + +typedef camera_attr_supported_exposure_mode_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_attr_foreach_supported_exposure_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_attr_foreach_supported_exposure_mode = int Function( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_camera_attr_set_exposure = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 value, +); + +typedef _dart_camera_attr_set_exposure = int Function( + ffi.Pointer camera, + int value, +); + +typedef _c_camera_attr_get_exposure = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer value, +); + +typedef _dart_camera_attr_get_exposure = int Function( + ffi.Pointer camera, + ffi.Pointer value, +); + +typedef _c_camera_attr_get_exposure_range = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _dart_camera_attr_get_exposure_range = int Function( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _c_camera_attr_set_iso = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 iso, +); + +typedef _dart_camera_attr_set_iso = int Function( + ffi.Pointer camera, + int iso, +); + +typedef _c_camera_attr_get_iso = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer iso, +); + +typedef _dart_camera_attr_get_iso = int Function( + ffi.Pointer camera, + ffi.Pointer iso, +); + +typedef camera_attr_supported_iso_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_attr_foreach_supported_iso = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_attr_foreach_supported_iso = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_attr_set_theater_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 mode, +); + +typedef _dart_camera_attr_set_theater_mode = int Function( + ffi.Pointer camera, + int mode, +); + +typedef _c_camera_attr_get_theater_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer mode, +); + +typedef _dart_camera_attr_get_theater_mode = int Function( + ffi.Pointer camera, + ffi.Pointer mode, +); + +typedef camera_attr_supported_theater_mode_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_attr_foreach_supported_theater_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_attr_foreach_supported_theater_mode = int Function( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_camera_attr_set_brightness = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 level, +); + +typedef _dart_camera_attr_set_brightness = int Function( + ffi.Pointer camera, + int level, +); + +typedef _c_camera_attr_get_brightness = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer level, +); + +typedef _dart_camera_attr_get_brightness = int Function( + ffi.Pointer camera, + ffi.Pointer level, +); + +typedef _c_camera_attr_get_brightness_range = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _dart_camera_attr_get_brightness_range = int Function( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _c_camera_attr_set_contrast = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 level, +); + +typedef _dart_camera_attr_set_contrast = int Function( + ffi.Pointer camera, + int level, +); + +typedef _c_camera_attr_get_contrast = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer level, +); + +typedef _dart_camera_attr_get_contrast = int Function( + ffi.Pointer camera, + ffi.Pointer level, +); + +typedef _c_camera_attr_get_contrast_range = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _dart_camera_attr_get_contrast_range = int Function( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _c_camera_attr_set_hue = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 level, +); + +typedef _dart_camera_attr_set_hue = int Function( + ffi.Pointer camera, + int level, +); + +typedef _c_camera_attr_get_hue = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer level, +); + +typedef _dart_camera_attr_get_hue = int Function( + ffi.Pointer camera, + ffi.Pointer level, +); + +typedef _c_camera_attr_get_hue_range = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _dart_camera_attr_get_hue_range = int Function( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _c_camera_attr_set_whitebalance = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 whitebalance, +); + +typedef _dart_camera_attr_set_whitebalance = int Function( + ffi.Pointer camera, + int whitebalance, +); + +typedef _c_camera_attr_get_whitebalance = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer whitebalance, +); + +typedef _dart_camera_attr_get_whitebalance = int Function( + ffi.Pointer camera, + ffi.Pointer whitebalance, +); + +typedef camera_attr_supported_whitebalance_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_attr_foreach_supported_whitebalance = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_attr_foreach_supported_whitebalance = int Function( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_camera_attr_set_effect = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 effect, +); + +typedef _dart_camera_attr_set_effect = int Function( + ffi.Pointer camera, + int effect, +); + +typedef _c_camera_attr_get_effect = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer effect, +); + +typedef _dart_camera_attr_get_effect = int Function( + ffi.Pointer camera, + ffi.Pointer effect, +); + +typedef camera_attr_supported_effect_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_attr_foreach_supported_effect = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_attr_foreach_supported_effect = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_attr_set_scene_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 mode, +); + +typedef _dart_camera_attr_set_scene_mode = int Function( + ffi.Pointer camera, + int mode, +); + +typedef _c_camera_attr_get_scene_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer mode, +); + +typedef _dart_camera_attr_get_scene_mode = int Function( + ffi.Pointer camera, + ffi.Pointer mode, +); + +typedef camera_attr_supported_scene_mode_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_attr_foreach_supported_scene_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_attr_foreach_supported_scene_mode = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_attr_enable_tag = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Uint8 enable, +); + +typedef _dart_camera_attr_enable_tag = int Function( + ffi.Pointer camera, + int enable, +); + +typedef _c_camera_attr_is_enabled_tag = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer enabled, +); + +typedef _dart_camera_attr_is_enabled_tag = int Function( + ffi.Pointer camera, + ffi.Pointer enabled, +); + +typedef _c_camera_attr_set_tag_image_description = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer description, +); + +typedef _dart_camera_attr_set_tag_image_description = int Function( + ffi.Pointer camera, + ffi.Pointer description, +); + +typedef _c_camera_attr_get_tag_image_description = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> description, +); + +typedef _dart_camera_attr_get_tag_image_description = int Function( + ffi.Pointer camera, + ffi.Pointer> description, +); + +typedef _c_camera_attr_set_tag_orientation = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 orientation, +); + +typedef _dart_camera_attr_set_tag_orientation = int Function( + ffi.Pointer camera, + int orientation, +); + +typedef _c_camera_attr_get_tag_orientation = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer orientation, +); + +typedef _dart_camera_attr_get_tag_orientation = int Function( + ffi.Pointer camera, + ffi.Pointer orientation, +); + +typedef _c_camera_attr_set_tag_software = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer software, +); + +typedef _dart_camera_attr_set_tag_software = int Function( + ffi.Pointer camera, + ffi.Pointer software, +); + +typedef _c_camera_attr_get_tag_software = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> software, +); + +typedef _dart_camera_attr_get_tag_software = int Function( + ffi.Pointer camera, + ffi.Pointer> software, +); + +typedef _c_camera_attr_set_geotag = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Double latitude, + ffi.Double longitude, + ffi.Double altitude, +); + +typedef _dart_camera_attr_set_geotag = int Function( + ffi.Pointer camera, + double latitude, + double longitude, + double altitude, +); + +typedef _c_camera_attr_get_geotag = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer altitude, +); + +typedef _dart_camera_attr_get_geotag = int Function( + ffi.Pointer camera, + ffi.Pointer latitude, + ffi.Pointer longitude, + ffi.Pointer altitude, +); + +typedef _c_camera_attr_remove_geotag = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_attr_remove_geotag = int Function( + ffi.Pointer camera, +); + +typedef _c_camera_attr_set_flash_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 mode, +); + +typedef _dart_camera_attr_set_flash_mode = int Function( + ffi.Pointer camera, + int mode, +); + +typedef _c_camera_attr_get_flash_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer mode, +); + +typedef _dart_camera_attr_get_flash_mode = int Function( + ffi.Pointer camera, + ffi.Pointer mode, +); + +typedef camera_attr_supported_flash_mode_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_attr_foreach_supported_flash_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_attr_foreach_supported_flash_mode = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_attr_get_lens_orientation = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer angle, +); + +typedef _dart_camera_attr_get_lens_orientation = int Function( + ffi.Pointer camera, + ffi.Pointer angle, +); + +typedef _c_camera_attr_set_stream_rotation = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 rotation, +); + +typedef _dart_camera_attr_set_stream_rotation = int Function( + ffi.Pointer camera, + int rotation, +); + +typedef _c_camera_attr_get_stream_rotation = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer rotation, +); + +typedef _dart_camera_attr_get_stream_rotation = int Function( + ffi.Pointer camera, + ffi.Pointer rotation, +); + +typedef camera_attr_supported_stream_rotation_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_attr_foreach_supported_stream_rotation = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_attr_foreach_supported_stream_rotation = int Function( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_camera_attr_set_stream_flip = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 flip, +); + +typedef _dart_camera_attr_set_stream_flip = int Function( + ffi.Pointer camera, + int flip, +); + +typedef _c_camera_attr_get_stream_flip = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer flip, +); + +typedef _dart_camera_attr_get_stream_flip = int Function( + ffi.Pointer camera, + ffi.Pointer flip, +); + +typedef camera_attr_supported_stream_flip_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_attr_foreach_supported_stream_flip = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_attr_foreach_supported_stream_flip = int Function( + ffi.Pointer camera, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_camera_attr_set_hdr_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 mode, +); + +typedef _dart_camera_attr_set_hdr_mode = int Function( + ffi.Pointer camera, + int mode, +); + +typedef _c_camera_attr_get_hdr_mode = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer mode, +); + +typedef _dart_camera_attr_get_hdr_mode = int Function( + ffi.Pointer camera, + ffi.Pointer mode, +); + +typedef camera_attr_hdr_progress_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_attr_set_hdr_capture_progress_cb = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_attr_set_hdr_capture_progress_cb = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_attr_unset_hdr_capture_progress_cb = ffi.Int32 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_attr_unset_hdr_capture_progress_cb = int Function( + ffi.Pointer camera, +); + +typedef _c_camera_attr_is_supported_hdr_capture = ffi.Uint8 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_attr_is_supported_hdr_capture = int Function( + ffi.Pointer camera, +); + +typedef _c_camera_attr_enable_anti_shake = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Uint8 enable, +); + +typedef _dart_camera_attr_enable_anti_shake = int Function( + ffi.Pointer camera, + int enable, +); + +typedef _c_camera_attr_is_enabled_anti_shake = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer enabled, +); + +typedef _dart_camera_attr_is_enabled_anti_shake = int Function( + ffi.Pointer camera, + ffi.Pointer enabled, +); + +typedef _c_camera_attr_is_supported_anti_shake = ffi.Uint8 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_attr_is_supported_anti_shake = int Function( + ffi.Pointer camera, +); + +typedef _c_camera_attr_enable_video_stabilization = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Uint8 enable, +); + +typedef _dart_camera_attr_enable_video_stabilization = int Function( + ffi.Pointer camera, + int enable, +); + +typedef _c_camera_attr_is_enabled_video_stabilization = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer enabled, +); + +typedef _dart_camera_attr_is_enabled_video_stabilization = int Function( + ffi.Pointer camera, + ffi.Pointer enabled, +); + +typedef _c_camera_attr_is_supported_video_stabilization = ffi.Uint8 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_attr_is_supported_video_stabilization = int Function( + ffi.Pointer camera, +); + +typedef _c_camera_attr_enable_auto_contrast = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Uint8 enable, +); + +typedef _dart_camera_attr_enable_auto_contrast = int Function( + ffi.Pointer camera, + int enable, +); + +typedef _c_camera_attr_is_enabled_auto_contrast = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer enabled, +); + +typedef _dart_camera_attr_is_enabled_auto_contrast = int Function( + ffi.Pointer camera, + ffi.Pointer enabled, +); + +typedef _c_camera_attr_is_supported_auto_contrast = ffi.Uint8 Function( + ffi.Pointer camera, +); + +typedef _dart_camera_attr_is_supported_auto_contrast = int Function( + ffi.Pointer camera, +); + +typedef _c_camera_attr_disable_shutter_sound = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Uint8 disable, +); + +typedef _dart_camera_attr_disable_shutter_sound = int Function( + ffi.Pointer camera, + int disable, +); + +typedef _c_camera_attr_set_pan = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 move_type, + ffi.Int32 pan_step, +); + +typedef _dart_camera_attr_set_pan = int Function( + ffi.Pointer camera, + int move_type, + int pan_step, +); + +typedef _c_camera_attr_get_pan = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer pan_step, +); + +typedef _dart_camera_attr_get_pan = int Function( + ffi.Pointer camera, + ffi.Pointer pan_step, +); + +typedef _c_camera_attr_get_pan_range = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _dart_camera_attr_get_pan_range = int Function( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _c_camera_attr_set_tilt = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 move_type, + ffi.Int32 tilt_step, +); + +typedef _dart_camera_attr_set_tilt = int Function( + ffi.Pointer camera, + int move_type, + int tilt_step, +); + +typedef _c_camera_attr_get_tilt = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer tilt_step, +); + +typedef _dart_camera_attr_get_tilt = int Function( + ffi.Pointer camera, + ffi.Pointer tilt_step, +); + +typedef _c_camera_attr_get_tilt_range = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _dart_camera_attr_get_tilt_range = int Function( + ffi.Pointer camera, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _c_camera_attr_set_ptz_type = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 ptz_type, +); + +typedef _dart_camera_attr_set_ptz_type = int Function( + ffi.Pointer camera, + int ptz_type, +); + +typedef camera_attr_supported_ptz_type_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_camera_attr_foreach_supported_ptz_type = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_camera_attr_foreach_supported_ptz_type = int Function( + ffi.Pointer camera, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_camera_attr_set_display_roi_area = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Int32 x, + ffi.Int32 y, + ffi.Int32 width, + ffi.Int32 height, +); + +typedef _dart_camera_attr_set_display_roi_area = int Function( + ffi.Pointer camera, + int x, + int y, + int width, + int height, +); + +typedef _c_camera_attr_get_display_roi_area = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer x, + ffi.Pointer y, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _dart_camera_attr_get_display_roi_area = int Function( + ffi.Pointer camera, + ffi.Pointer x, + ffi.Pointer y, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _c_image_util_decode_create = ffi.Int32 Function( + ffi.Pointer> handle, +); + +typedef _dart_image_util_decode_create = int Function( + ffi.Pointer> handle, +); + +typedef _c_image_util_decode_set_input_path = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer path, +); + +typedef _dart_image_util_decode_set_input_path = int Function( + ffi.Pointer handle, + ffi.Pointer path, +); + +typedef _c_image_util_decode_set_input_buffer = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer src_buffer, + ffi.Uint64 src_size, +); + +typedef _dart_image_util_decode_set_input_buffer = int Function( + ffi.Pointer handle, + ffi.Pointer src_buffer, + int src_size, +); + +typedef _c_image_util_decode_set_output_buffer = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> dst_buffer, +); + +typedef _dart_image_util_decode_set_output_buffer = int Function( + ffi.Pointer handle, + ffi.Pointer> dst_buffer, +); + +typedef _c_image_util_decode_set_colorspace = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 colorspace, +); + +typedef _dart_image_util_decode_set_colorspace = int Function( + ffi.Pointer handle, + int colorspace, +); + +typedef _c_image_util_decode_set_jpeg_downscale = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 down_scale, +); + +typedef _dart_image_util_decode_set_jpeg_downscale = int Function( + ffi.Pointer handle, + int down_scale, +); + +typedef _c_image_util_decode_run = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, +); + +typedef _dart_image_util_decode_run = int Function( + ffi.Pointer handle, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, +); + +typedef image_util_decode_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Uint64, + ffi.Uint64, + ffi.Uint64, +); + +typedef _c_image_util_decode_run_async = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_image_util_decode_run_async = int Function( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_image_util_decode_destroy = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_image_util_decode_destroy = int Function( + ffi.Pointer handle, +); + +typedef _c_image_util_decode_jpeg = ffi.Int32 Function( + ffi.Pointer path, + ffi.Int32 colorspace, + ffi.Pointer> image_buffer, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, +); + +typedef _dart_image_util_decode_jpeg = int Function( + ffi.Pointer path, + int colorspace, + ffi.Pointer> image_buffer, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, +); + +typedef _c_image_util_decode_jpeg_from_memory = ffi.Int32 Function( + ffi.Pointer jpeg_buffer, + ffi.Int32 jpeg_size, + ffi.Int32 colorspace, + ffi.Pointer> image_buffer, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, +); + +typedef _dart_image_util_decode_jpeg_from_memory = int Function( + ffi.Pointer jpeg_buffer, + int jpeg_size, + int colorspace, + ffi.Pointer> image_buffer, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, +); + +typedef _c_image_util_decode_jpeg_with_downscale = ffi.Int32 Function( + ffi.Pointer path, + ffi.Int32 colorspace, + ffi.Int32 downscale, + ffi.Pointer> image_buffer, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, +); + +typedef _dart_image_util_decode_jpeg_with_downscale = int Function( + ffi.Pointer path, + int colorspace, + int downscale, + ffi.Pointer> image_buffer, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, +); + +typedef _c_image_util_decode_jpeg_from_memory_with_downscale = ffi.Int32 + Function( + ffi.Pointer jpeg_buffer, + ffi.Int32 jpeg_size, + ffi.Int32 colorspace, + ffi.Int32 downscale, + ffi.Pointer> image_buffer, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, +); + +typedef _dart_image_util_decode_jpeg_from_memory_with_downscale = int Function( + ffi.Pointer jpeg_buffer, + int jpeg_size, + int colorspace, + int downscale, + ffi.Pointer> image_buffer, + ffi.Pointer width, + ffi.Pointer height, + ffi.Pointer size, +); + +typedef _c_image_util_encode_create = ffi.Int32 Function( + ffi.Int32 image_type, + ffi.Pointer> handle, +); + +typedef _dart_image_util_encode_create = int Function( + int image_type, + ffi.Pointer> handle, +); + +typedef _c_image_util_encode_set_resolution = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Uint64 width, + ffi.Uint64 height, +); + +typedef _dart_image_util_encode_set_resolution = int Function( + ffi.Pointer handle, + int width, + int height, +); + +typedef _c_image_util_encode_set_colorspace = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 colorspace, +); + +typedef _dart_image_util_encode_set_colorspace = int Function( + ffi.Pointer handle, + int colorspace, +); + +typedef _c_image_util_encode_set_quality = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 quality, +); + +typedef _dart_image_util_encode_set_quality = int Function( + ffi.Pointer handle, + int quality, +); + +typedef _c_image_util_encode_set_png_compression = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 compression, +); + +typedef _dart_image_util_encode_set_png_compression = int Function( + ffi.Pointer handle, + int compression, +); + +typedef _c_image_util_encode_set_gif_frame_delay_time = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Uint64 delay_time, +); + +typedef _dart_image_util_encode_set_gif_frame_delay_time = int Function( + ffi.Pointer handle, + int delay_time, +); + +typedef _c_image_util_encode_set_input_buffer = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer src_buffer, +); + +typedef _dart_image_util_encode_set_input_buffer = int Function( + ffi.Pointer handle, + ffi.Pointer src_buffer, +); + +typedef _c_image_util_encode_set_output_path = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer path, +); + +typedef _dart_image_util_encode_set_output_path = int Function( + ffi.Pointer handle, + ffi.Pointer path, +); + +typedef _c_image_util_encode_set_output_buffer = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> dst_buffer, +); + +typedef _dart_image_util_encode_set_output_buffer = int Function( + ffi.Pointer handle, + ffi.Pointer> dst_buffer, +); + +typedef _c_image_util_encode_run = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer size, +); + +typedef _dart_image_util_encode_run = int Function( + ffi.Pointer handle, + ffi.Pointer size, +); + +typedef image_util_encode_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Uint64, +); + +typedef _c_image_util_encode_run_async = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_image_util_encode_run_async = int Function( + ffi.Pointer handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_image_util_encode_destroy = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_image_util_encode_destroy = int Function( + ffi.Pointer handle, +); + +typedef _c_image_util_encode_jpeg = ffi.Int32 Function( + ffi.Pointer buffer, + ffi.Int32 width, + ffi.Int32 height, + ffi.Int32 colorspace, + ffi.Int32 quality, + ffi.Pointer path, +); + +typedef _dart_image_util_encode_jpeg = int Function( + ffi.Pointer buffer, + int width, + int height, + int colorspace, + int quality, + ffi.Pointer path, +); + +typedef _c_image_util_encode_jpeg_to_memory = ffi.Int32 Function( + ffi.Pointer image_buffer, + ffi.Int32 width, + ffi.Int32 height, + ffi.Int32 colorspace, + ffi.Int32 quality, + ffi.Pointer> jpeg_buffer, + ffi.Pointer jpeg_size, +); + +typedef _dart_image_util_encode_jpeg_to_memory = int Function( + ffi.Pointer image_buffer, + int width, + int height, + int colorspace, + int quality, + ffi.Pointer> jpeg_buffer, + ffi.Pointer jpeg_size, +); + +typedef _c_image_util_calculate_buffer_size = ffi.Int32 Function( + ffi.Int32 width, + ffi.Int32 height, + ffi.Int32 colorspace, + ffi.Pointer size, +); + +typedef _dart_image_util_calculate_buffer_size = int Function( + int width, + int height, + int colorspace, + ffi.Pointer size, +); + +typedef _c_image_util_extract_color_from_memory = ffi.Int32 Function( + ffi.Pointer image_buffer, + ffi.Int32 width, + ffi.Int32 height, + ffi.Pointer rgb_r, + ffi.Pointer rgb_g, + ffi.Pointer rgb_b, +); + +typedef _dart_image_util_extract_color_from_memory = int Function( + ffi.Pointer image_buffer, + int width, + int height, + ffi.Pointer rgb_r, + ffi.Pointer rgb_g, + ffi.Pointer rgb_b, +); + +typedef _c_image_util_transform_create = ffi.Int32 Function( + ffi.Pointer> handle, +); + +typedef _dart_image_util_transform_create = int Function( + ffi.Pointer> handle, +); + +typedef _c_image_util_transform_set_hardware_acceleration = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Uint8 mode, +); + +typedef _dart_image_util_transform_set_hardware_acceleration = int Function( + ffi.Pointer handle, + int mode, +); + +typedef _c_image_util_transform_set_colorspace = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 colorspace, +); + +typedef _dart_image_util_transform_set_colorspace = int Function( + ffi.Pointer handle, + int colorspace, +); + +typedef _c_image_util_transform_set_resolution = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Uint32 width, + ffi.Uint32 height, +); + +typedef _dart_image_util_transform_set_resolution = int Function( + ffi.Pointer handle, + int width, + int height, +); + +typedef _c_image_util_transform_set_rotation = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 rotation, +); + +typedef _dart_image_util_transform_set_rotation = int Function( + ffi.Pointer handle, + int rotation, +); + +typedef _c_image_util_transform_set_crop_area = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Uint32 start_x, + ffi.Uint32 start_y, + ffi.Uint32 end_x, + ffi.Uint32 end_y, +); + +typedef _dart_image_util_transform_set_crop_area = int Function( + ffi.Pointer handle, + int start_x, + int start_y, + int end_x, + int end_y, +); + +typedef _c_image_util_transform_get_colorspace = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer colorspace, +); + +typedef _dart_image_util_transform_get_colorspace = int Function( + ffi.Pointer handle, + ffi.Pointer colorspace, +); + +typedef _c_image_util_transform_get_resolution = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _dart_image_util_transform_get_resolution = int Function( + ffi.Pointer handle, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _c_image_util_transform_get_rotation = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer rotation, +); + +typedef _dart_image_util_transform_get_rotation = int Function( + ffi.Pointer handle, + ffi.Pointer rotation, +); + +typedef _c_image_util_transform_get_crop_area = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer start_x, + ffi.Pointer start_y, + ffi.Pointer end_x, + ffi.Pointer end_y, +); + +typedef _dart_image_util_transform_get_crop_area = int Function( + ffi.Pointer handle, + ffi.Pointer start_x, + ffi.Pointer start_y, + ffi.Pointer end_x, + ffi.Pointer end_y, +); + +typedef image_util_transform_completed_cb = ffi.Void Function( + ffi.Pointer>, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_image_util_transform_run = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer src, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_image_util_transform_run = int Function( + ffi.Pointer handle, + ffi.Pointer src, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_image_util_transform_destroy = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_image_util_transform_destroy = int Function( + ffi.Pointer handle, +); + +typedef image_util_supported_jpeg_colorspace_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_image_util_foreach_supported_jpeg_colorspace = ffi.Int32 Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_image_util_foreach_supported_jpeg_colorspace = int Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef image_util_supported_colorspace_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_image_util_foreach_supported_colorspace = ffi.Int32 Function( + ffi.Int32 image_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_image_util_foreach_supported_colorspace = int Function( + int image_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_packet_pool_create = ffi.Int32 Function( + ffi.Pointer> pool, +); + +typedef _dart_media_packet_pool_create = int Function( + ffi.Pointer> pool, +); + +typedef _c_media_packet_pool_set_media_format = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Pointer fmt, +); + +typedef _dart_media_packet_pool_set_media_format = int Function( + ffi.Pointer pool, + ffi.Pointer fmt, +); + +typedef _c_media_packet_pool_set_size = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Int32 min_buffers, + ffi.Int32 max_buffers, +); + +typedef _dart_media_packet_pool_set_size = int Function( + ffi.Pointer pool, + int min_buffers, + int max_buffers, +); + +typedef _c_media_packet_pool_get_size = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Pointer min_buffers, + ffi.Pointer max_buffers, + ffi.Pointer curr_buffers, +); + +typedef _dart_media_packet_pool_get_size = int Function( + ffi.Pointer pool, + ffi.Pointer min_buffers, + ffi.Pointer max_buffers, + ffi.Pointer curr_buffers, +); + +typedef _c_media_packet_pool_allocate = ffi.Int32 Function( + ffi.Pointer pool, +); + +typedef _dart_media_packet_pool_allocate = int Function( + ffi.Pointer pool, +); + +typedef _c_media_packet_pool_acquire_packet = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Pointer> pkt, + ffi.Int64 timeout, +); + +typedef _dart_media_packet_pool_acquire_packet = int Function( + ffi.Pointer pool, + ffi.Pointer> pkt, + int timeout, +); + +typedef _c_media_packet_pool_release_packet = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Pointer pkt, +); + +typedef _dart_media_packet_pool_release_packet = int Function( + ffi.Pointer pool, + ffi.Pointer pkt, +); + +typedef _c_media_packet_pool_deallocate = ffi.Int32 Function( + ffi.Pointer pool, +); + +typedef _dart_media_packet_pool_deallocate = int Function( + ffi.Pointer pool, +); + +typedef _c_media_packet_pool_destroy = ffi.Int32 Function( + ffi.Pointer pool, +); + +typedef _dart_media_packet_pool_destroy = int Function( + ffi.Pointer pool, +); + +typedef _c_mediacodec_create = ffi.Int32 Function( + ffi.Pointer> mediacodec, +); + +typedef _dart_mediacodec_create = int Function( + ffi.Pointer> mediacodec, +); + +typedef _c_mediacodec_destroy = ffi.Int32 Function( + ffi.Pointer mediacodec, +); + +typedef _dart_mediacodec_destroy = int Function( + ffi.Pointer mediacodec, +); + +typedef _c_mediacodec_set_codec = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Int32 codec_type, + ffi.Int32 flags, +); + +typedef _dart_mediacodec_set_codec = int Function( + ffi.Pointer mediacodec, + int codec_type, + int flags, +); + +typedef _c_mediacodec_set_vdec_info = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Int32 width, + ffi.Int32 height, +); + +typedef _dart_mediacodec_set_vdec_info = int Function( + ffi.Pointer mediacodec, + int width, + int height, +); + +typedef _c_mediacodec_set_venc_info = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Int32 width, + ffi.Int32 height, + ffi.Int32 fps, + ffi.Int32 target_bits, +); + +typedef _dart_mediacodec_set_venc_info = int Function( + ffi.Pointer mediacodec, + int width, + int height, + int fps, + int target_bits, +); + +typedef _c_mediacodec_set_adec_info = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Int32 samplerate, + ffi.Int32 channel, + ffi.Int32 bit, +); + +typedef _dart_mediacodec_set_adec_info = int Function( + ffi.Pointer mediacodec, + int samplerate, + int channel, + int bit, +); + +typedef _c_mediacodec_set_aenc_info = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Int32 samplerate, + ffi.Int32 channel, + ffi.Int32 bit, + ffi.Int32 bitrate, +); + +typedef _dart_mediacodec_set_aenc_info = int Function( + ffi.Pointer mediacodec, + int samplerate, + int channel, + int bit, + int bitrate, +); + +typedef _c_mediacodec_configure_from_media_format = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Pointer format, + ffi.Int32 flags, +); + +typedef _dart_mediacodec_configure_from_media_format = int Function( + ffi.Pointer mediacodec, + ffi.Pointer format, + int flags, +); + +typedef _c_mediacodec_prepare = ffi.Int32 Function( + ffi.Pointer mediacodec, +); + +typedef _dart_mediacodec_prepare = int Function( + ffi.Pointer mediacodec, +); + +typedef _c_mediacodec_unprepare = ffi.Int32 Function( + ffi.Pointer mediacodec, +); + +typedef _dart_mediacodec_unprepare = int Function( + ffi.Pointer mediacodec, +); + +typedef _c_mediacodec_process_input = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Pointer inbuf, + ffi.Uint64 timeOutUs, +); + +typedef _dart_mediacodec_process_input = int Function( + ffi.Pointer mediacodec, + ffi.Pointer inbuf, + int timeOutUs, +); + +typedef _c_mediacodec_get_output = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Pointer> outbuf, + ffi.Uint64 timeOutUs, +); + +typedef _dart_mediacodec_get_output = int Function( + ffi.Pointer mediacodec, + ffi.Pointer> outbuf, + int timeOutUs, +); + +typedef _c_mediacodec_flush_buffers = ffi.Int32 Function( + ffi.Pointer mediacodec, +); + +typedef _dart_mediacodec_flush_buffers = int Function( + ffi.Pointer mediacodec, +); + +typedef mediacodec_input_buffer_used_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mediacodec_set_input_buffer_used_cb = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mediacodec_set_input_buffer_used_cb = int Function( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mediacodec_unset_input_buffer_used_cb = ffi.Int32 Function( + ffi.Pointer mediacodec, +); + +typedef _dart_mediacodec_unset_input_buffer_used_cb = int Function( + ffi.Pointer mediacodec, +); + +typedef mediacodec_output_buffer_available_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mediacodec_set_output_buffer_available_cb = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_mediacodec_set_output_buffer_available_cb = int Function( + ffi.Pointer mediacodec, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_mediacodec_unset_output_buffer_available_cb = ffi.Int32 Function( + ffi.Pointer mediacodec, +); + +typedef _dart_mediacodec_unset_output_buffer_available_cb = int Function( + ffi.Pointer mediacodec, +); + +typedef mediacodec_error_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mediacodec_set_error_cb = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mediacodec_set_error_cb = int Function( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mediacodec_unset_error_cb = ffi.Int32 Function( + ffi.Pointer mediacodec, +); + +typedef _dart_mediacodec_unset_error_cb = int Function( + ffi.Pointer mediacodec, +); + +typedef mediacodec_eos_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef _c_mediacodec_set_eos_cb = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mediacodec_set_eos_cb = int Function( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mediacodec_unset_eos_cb = ffi.Int32 Function( + ffi.Pointer mediacodec, +); + +typedef _dart_mediacodec_unset_eos_cb = int Function( + ffi.Pointer mediacodec, +); + +typedef mediacodec_buffer_status_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mediacodec_set_buffer_status_cb = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mediacodec_set_buffer_status_cb = int Function( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mediacodec_unset_buffer_status_cb = ffi.Int32 Function( + ffi.Pointer mediacodec, +); + +typedef _dart_mediacodec_unset_buffer_status_cb = int Function( + ffi.Pointer mediacodec, +); + +typedef mediacodec_supported_codec_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mediacodec_foreach_supported_codec = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mediacodec_foreach_supported_codec = int Function( + ffi.Pointer mediacodec, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mediacodec_get_supported_type = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Int32 codec_type, + ffi.Uint8 encoder, + ffi.Pointer support_type, +); + +typedef _dart_mediacodec_get_supported_type = int Function( + ffi.Pointer mediacodec, + int codec_type, + int encoder, + ffi.Pointer support_type, +); + +typedef _c_mediacodec_get_packet_pool = ffi.Int32 Function( + ffi.Pointer mediacodec, + ffi.Pointer> pool, +); + +typedef _dart_mediacodec_get_packet_pool = int Function( + ffi.Pointer mediacodec, + ffi.Pointer> pool, +); + +typedef _c_mc_playlist_get_name = ffi.Int32 Function( + ffi.Pointer playlist, + ffi.Pointer> playlist_name, +); + +typedef _dart_mc_playlist_get_name = int Function( + ffi.Pointer playlist, + ffi.Pointer> playlist_name, +); + +typedef mc_playlist_item_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mc_playlist_foreach_item = ffi.Int32 Function( + ffi.Pointer playlist, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_playlist_foreach_item = int Function( + ffi.Pointer playlist, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_playlist_clone = ffi.Int32 Function( + ffi.Pointer src, + ffi.Pointer> dst, +); + +typedef _dart_mc_playlist_clone = int Function( + ffi.Pointer src, + ffi.Pointer> dst, +); + +typedef _c_mc_playlist_destroy = ffi.Int32 Function( + ffi.Pointer playlist, +); + +typedef _dart_mc_playlist_destroy = int Function( + ffi.Pointer playlist, +); + +typedef _c_mc_metadata_clone = ffi.Int32 Function( + ffi.Pointer src, + ffi.Pointer> dst, +); + +typedef _dart_mc_metadata_clone = int Function( + ffi.Pointer src, + ffi.Pointer> dst, +); + +typedef _c_mc_metadata_destroy = ffi.Int32 Function( + ffi.Pointer metadata, +); + +typedef _dart_mc_metadata_destroy = int Function( + ffi.Pointer metadata, +); + +typedef _c_mc_metadata_get = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Int32 attribute, + ffi.Pointer> value, +); + +typedef _dart_mc_metadata_get = int Function( + ffi.Pointer metadata, + int attribute, + ffi.Pointer> value, +); + +typedef _c_mc_server_create = ffi.Int32 Function( + ffi.Pointer> server, +); + +typedef _dart_mc_server_create = int Function( + ffi.Pointer> server, +); + +typedef _c_mc_server_set_playback_state = ffi.Int32 Function( + ffi.Pointer server, + ffi.Int32 state, +); + +typedef _dart_mc_server_set_playback_state = int Function( + ffi.Pointer server, + int state, +); + +typedef _c_mc_server_set_playback_position = ffi.Int32 Function( + ffi.Pointer server, + ffi.Uint64 position, +); + +typedef _dart_mc_server_set_playback_position = int Function( + ffi.Pointer server, + int position, +); + +typedef _c_mc_server_set_playlist_item_index = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer index, +); + +typedef _dart_mc_server_set_playlist_item_index = int Function( + ffi.Pointer server, + ffi.Pointer index, +); + +typedef _c_mc_server_update_playback_info = ffi.Int32 Function( + ffi.Pointer server, +); + +typedef _dart_mc_server_update_playback_info = int Function( + ffi.Pointer server, +); + +typedef _c_mc_server_set_metadata = ffi.Int32 Function( + ffi.Pointer server, + ffi.Int32 attribute, + ffi.Pointer value, +); + +typedef _dart_mc_server_set_metadata = int Function( + ffi.Pointer server, + int attribute, + ffi.Pointer value, +); + +typedef _c_mc_server_update_metadata = ffi.Int32 Function( + ffi.Pointer server, +); + +typedef _dart_mc_server_update_metadata = int Function( + ffi.Pointer server, +); + +typedef _c_mc_server_update_shuffle_mode = ffi.Int32 Function( + ffi.Pointer server, + ffi.Int32 mode, +); + +typedef _dart_mc_server_update_shuffle_mode = int Function( + ffi.Pointer server, + int mode, +); + +typedef _c_mc_server_update_repeat_mode = ffi.Int32 Function( + ffi.Pointer server, + ffi.Int32 mode, +); + +typedef _dart_mc_server_update_repeat_mode = int Function( + ffi.Pointer server, + int mode, +); + +typedef mc_server_playback_state_command_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mc_server_set_playback_state_command_received_cb = ffi.Int32 + Function( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_server_set_playback_state_command_received_cb = int Function( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_mc_server_unset_playback_state_command_received_cb = ffi.Int32 + Function( + ffi.Pointer server, +); + +typedef _dart_mc_server_unset_playback_state_command_received_cb = int Function( + ffi.Pointer server, +); + +typedef mc_server_playback_action_cmd_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mc_server_set_playback_action_cmd_received_cb = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_server_set_playback_action_cmd_received_cb = int Function( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_mc_server_unset_playback_action_cmd_received_cb = ffi.Int32 Function( + ffi.Pointer server, +); + +typedef _dart_mc_server_unset_playback_action_cmd_received_cb = int Function( + ffi.Pointer server, +); + +typedef mc_server_playback_position_cmd_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Uint64, + ffi.Pointer, +); + +typedef _c_mc_server_set_playback_position_cmd_received_cb = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_server_set_playback_position_cmd_received_cb = int Function( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_mc_server_unset_playback_position_cmd_received_cb = ffi.Int32 + Function( + ffi.Pointer server, +); + +typedef _dart_mc_server_unset_playback_position_cmd_received_cb = int Function( + ffi.Pointer server, +); + +typedef mc_server_shuffle_mode_cmd_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mc_server_set_shuffle_mode_cmd_received_cb = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_server_set_shuffle_mode_cmd_received_cb = int Function( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_mc_server_unset_shuffle_mode_cmd_received_cb = ffi.Int32 Function( + ffi.Pointer server, +); + +typedef _dart_mc_server_unset_shuffle_mode_cmd_received_cb = int Function( + ffi.Pointer server, +); + +typedef mc_server_repeat_mode_cmd_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mc_server_set_repeat_mode_cmd_received_cb = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_server_set_repeat_mode_cmd_received_cb = int Function( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_mc_server_unset_repeat_mode_cmd_received_cb = ffi.Int32 Function( + ffi.Pointer server, +); + +typedef _dart_mc_server_unset_repeat_mode_cmd_received_cb = int Function( + ffi.Pointer server, +); + +typedef mc_server_custom_command_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mc_server_set_custom_command_received_cb = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_server_set_custom_command_received_cb = int Function( + ffi.Pointer server, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_mc_server_unset_custom_command_received_cb = ffi.Int32 Function( + ffi.Pointer server, +); + +typedef _dart_mc_server_unset_custom_command_received_cb = int Function( + ffi.Pointer server, +); + +typedef _c_mc_server_send_command_reply = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer client_name, + ffi.Int32 result_code, + ffi.Pointer data, +); + +typedef _dart_mc_server_send_command_reply = int Function( + ffi.Pointer server, + ffi.Pointer client_name, + int result_code, + ffi.Pointer data, +); + +typedef mc_server_playlist_cmd_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Uint64, + ffi.Pointer, +); + +typedef _c_mc_server_set_playlist_cmd_received_cb = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_server_set_playlist_cmd_received_cb = int Function( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_server_unset_playlist_cmd_received_cb = ffi.Int32 Function( + ffi.Pointer server, +); + +typedef _dart_mc_server_unset_playlist_cmd_received_cb = int Function( + ffi.Pointer server, +); + +typedef mc_server_custom_cmd_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mc_server_set_custom_cmd_received_cb = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_server_set_custom_cmd_received_cb = int Function( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_server_unset_custom_cmd_received_cb = ffi.Int32 Function( + ffi.Pointer server, +); + +typedef _dart_mc_server_unset_custom_cmd_received_cb = int Function( + ffi.Pointer server, +); + +typedef _c_mc_server_send_cmd_reply = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer client_name, + ffi.Pointer request_id, + ffi.Int32 result_code, + ffi.Pointer data, +); + +typedef _dart_mc_server_send_cmd_reply = int Function( + ffi.Pointer server, + ffi.Pointer client_name, + ffi.Pointer request_id, + int result_code, + ffi.Pointer data, +); + +typedef mc_activated_client_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mc_server_foreach_client = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_server_foreach_client = int Function( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_server_send_custom_event = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer client_name, + ffi.Pointer event, + ffi.Pointer data, + ffi.Pointer> request_id, +); + +typedef _dart_mc_server_send_custom_event = int Function( + ffi.Pointer server, + ffi.Pointer client_name, + ffi.Pointer event, + ffi.Pointer data, + ffi.Pointer> request_id, +); + +typedef mc_server_event_reply_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mc_server_set_event_reply_received_cb = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_server_set_event_reply_received_cb = int Function( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_server_unset_event_reply_received_cb = ffi.Int32 Function( + ffi.Pointer server, +); + +typedef _dart_mc_server_unset_event_reply_received_cb = int Function( + ffi.Pointer server, +); + +typedef _c_mc_server_destroy = ffi.Int32 Function( + ffi.Pointer server, +); + +typedef _dart_mc_server_destroy = int Function( + ffi.Pointer server, +); + +typedef _c_mc_server_create_playlist = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer playlist_name, + ffi.Pointer> playlist, +); + +typedef _dart_mc_server_create_playlist = int Function( + ffi.Pointer server, + ffi.Pointer playlist_name, + ffi.Pointer> playlist, +); + +typedef _c_mc_server_add_item_to_playlist = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer playlist, + ffi.Pointer index, + ffi.Int32 attribute, + ffi.Pointer value, +); + +typedef _dart_mc_server_add_item_to_playlist = int Function( + ffi.Pointer server, + ffi.Pointer playlist, + ffi.Pointer index, + int attribute, + ffi.Pointer value, +); + +typedef _c_mc_server_update_playlist_done = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer playlist, +); + +typedef _dart_mc_server_update_playlist_done = int Function( + ffi.Pointer server, + ffi.Pointer playlist, +); + +typedef _c_mc_server_delete_playlist = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer playlist, +); + +typedef _dart_mc_server_delete_playlist = int Function( + ffi.Pointer server, + ffi.Pointer playlist, +); + +typedef mc_playlist_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mc_server_foreach_playlist = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_server_foreach_playlist = int Function( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_create = ffi.Int32 Function( + ffi.Pointer> client, +); + +typedef _dart_mc_client_create = int Function( + ffi.Pointer> client, +); + +typedef mc_server_state_updated_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mc_client_set_server_update_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_set_server_update_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_unset_server_update_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_mc_client_unset_server_update_cb = int Function( + ffi.Pointer client, +); + +typedef mc_playback_updated_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mc_client_set_playback_update_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_set_playback_update_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_unset_playback_update_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_mc_client_unset_playback_update_cb = int Function( + ffi.Pointer client, +); + +typedef mc_metadata_updated_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mc_client_set_metadata_update_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_set_metadata_update_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_unset_metadata_update_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_mc_client_unset_metadata_update_cb = int Function( + ffi.Pointer client, +); + +typedef mc_shuffle_mode_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mc_client_set_shuffle_mode_update_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_set_shuffle_mode_update_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_unset_shuffle_mode_update_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_mc_client_unset_shuffle_mode_update_cb = int Function( + ffi.Pointer client, +); + +typedef mc_repeat_mode_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mc_client_set_repeat_mode_update_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_set_repeat_mode_update_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_unset_repeat_mode_update_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_mc_client_unset_repeat_mode_update_cb = int Function( + ffi.Pointer client, +); + +typedef _c_mc_client_set_server_updated_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_set_server_updated_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_unset_server_updated_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_mc_client_unset_server_updated_cb = int Function( + ffi.Pointer client, +); + +typedef _c_mc_client_set_playback_updated_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_set_playback_updated_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_unset_playback_updated_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_mc_client_unset_playback_updated_cb = int Function( + ffi.Pointer client, +); + +typedef _c_mc_client_set_metadata_updated_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_set_metadata_updated_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_unset_metadata_updated_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_mc_client_unset_metadata_updated_cb = int Function( + ffi.Pointer client, +); + +typedef mc_shuffle_mode_updated_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mc_client_set_shuffle_mode_updated_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_set_shuffle_mode_updated_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_unset_shuffle_mode_updated_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_mc_client_unset_shuffle_mode_updated_cb = int Function( + ffi.Pointer client, +); + +typedef mc_repeat_mode_updated_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mc_client_set_repeat_mode_updated_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_set_repeat_mode_updated_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_unset_repeat_mode_updated_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_mc_client_unset_repeat_mode_updated_cb = int Function( + ffi.Pointer client, +); + +typedef mc_cmd_reply_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mc_client_set_cmd_reply_received_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_set_cmd_reply_received_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_unset_cmd_reply_received_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_mc_client_unset_cmd_reply_received_cb = int Function( + ffi.Pointer client, +); + +typedef mc_playlist_updated_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mc_client_set_playlist_updated_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_set_playlist_updated_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_unset_playlist_updated_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_mc_client_unset_playlist_updated_cb = int Function( + ffi.Pointer client, +); + +typedef mc_client_custom_event_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mc_client_set_custom_event_received_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_set_custom_event_received_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_unset_custom_event_received_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_mc_client_unset_custom_event_received_cb = int Function( + ffi.Pointer client, +); + +typedef _c_mc_client_send_event_reply = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer request_id, + ffi.Int32 result_code, + ffi.Pointer data, +); + +typedef _dart_mc_client_send_event_reply = int Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer request_id, + int result_code, + ffi.Pointer data, +); + +typedef _c_mc_client_subscribe = ffi.Int32 Function( + ffi.Pointer client, + ffi.Int32 subscription_type, + ffi.Pointer server_name, +); + +typedef _dart_mc_client_subscribe = int Function( + ffi.Pointer client, + int subscription_type, + ffi.Pointer server_name, +); + +typedef _c_mc_client_unsubscribe = ffi.Int32 Function( + ffi.Pointer client, + ffi.Int32 subscription_type, + ffi.Pointer server_name, +); + +typedef _dart_mc_client_unsubscribe = int Function( + ffi.Pointer client, + int subscription_type, + ffi.Pointer server_name, +); + +typedef mc_subscribed_server_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mc_client_foreach_server_subscribed = ffi.Int32 Function( + ffi.Pointer client, + ffi.Int32 subscription_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_foreach_server_subscribed = int Function( + ffi.Pointer client, + int subscription_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_get_playback_state = ffi.Int32 Function( + ffi.Pointer playback, + ffi.Pointer state, +); + +typedef _dart_mc_client_get_playback_state = int Function( + ffi.Pointer playback, + ffi.Pointer state, +); + +typedef _c_mc_client_get_playback_position = ffi.Int32 Function( + ffi.Pointer playback, + ffi.Pointer position, +); + +typedef _dart_mc_client_get_playback_position = int Function( + ffi.Pointer playback, + ffi.Pointer position, +); + +typedef _c_mc_client_get_playlist_item_index = ffi.Int32 Function( + ffi.Pointer playback, + ffi.Pointer> index, +); + +typedef _dart_mc_client_get_playlist_item_index = int Function( + ffi.Pointer playback, + ffi.Pointer> index, +); + +typedef _c_mc_client_destroy_playback = ffi.Int32 Function( + ffi.Pointer playback, +); + +typedef _dart_mc_client_destroy_playback = int Function( + ffi.Pointer playback, +); + +typedef _c_mc_client_get_metadata = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Int32 attribute, + ffi.Pointer> value, +); + +typedef _dart_mc_client_get_metadata = int Function( + ffi.Pointer metadata, + int attribute, + ffi.Pointer> value, +); + +typedef _c_mc_client_destroy_metadata = ffi.Int32 Function( + ffi.Pointer metadata, +); + +typedef _dart_mc_client_destroy_metadata = int Function( + ffi.Pointer metadata, +); + +typedef _c_mc_client_get_latest_server_info = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> server_name, + ffi.Pointer server_state, +); + +typedef _dart_mc_client_get_latest_server_info = int Function( + ffi.Pointer client, + ffi.Pointer> server_name, + ffi.Pointer server_state, +); + +typedef _c_mc_client_get_server_playback_info = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer> playback, +); + +typedef _dart_mc_client_get_server_playback_info = int Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer> playback, +); + +typedef _c_mc_client_get_server_metadata = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer> metadata, +); + +typedef _dart_mc_client_get_server_metadata = int Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer> metadata, +); + +typedef _c_mc_client_get_server_shuffle_mode = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer mode, +); + +typedef _dart_mc_client_get_server_shuffle_mode = int Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer mode, +); + +typedef _c_mc_client_get_server_repeat_mode = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer mode, +); + +typedef _dart_mc_client_get_server_repeat_mode = int Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer mode, +); + +typedef mc_activated_server_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mc_client_foreach_server = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_foreach_server = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_foreach_server_playlist = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_foreach_server_playlist = int Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_send_playback_state_command = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Int32 state, +); + +typedef _dart_mc_client_send_playback_state_command = int Function( + ffi.Pointer client, + ffi.Pointer server_name, + int state, +); + +typedef _c_mc_client_send_playback_action_cmd = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Int32 action, + ffi.Pointer> request_id, +); + +typedef _dart_mc_client_send_playback_action_cmd = int Function( + ffi.Pointer client, + ffi.Pointer server_name, + int action, + ffi.Pointer> request_id, +); + +typedef _c_mc_client_send_playback_position_cmd = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Uint64 position, + ffi.Pointer> request_id, +); + +typedef _dart_mc_client_send_playback_position_cmd = int Function( + ffi.Pointer client, + ffi.Pointer server_name, + int position, + ffi.Pointer> request_id, +); + +typedef _c_mc_client_send_shuffle_mode_cmd = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Int32 shuffle_mode, + ffi.Pointer> request_id, +); + +typedef _dart_mc_client_send_shuffle_mode_cmd = int Function( + ffi.Pointer client, + ffi.Pointer server_name, + int shuffle_mode, + ffi.Pointer> request_id, +); + +typedef _c_mc_client_send_repeat_mode_cmd = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Int32 repeat_mode, + ffi.Pointer> request_id, +); + +typedef _dart_mc_client_send_repeat_mode_cmd = int Function( + ffi.Pointer client, + ffi.Pointer server_name, + int repeat_mode, + ffi.Pointer> request_id, +); + +typedef mc_command_reply_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mc_client_send_custom_command = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer command, + ffi.Pointer data, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mc_client_send_custom_command = int Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer command, + ffi.Pointer data, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mc_client_send_playlist_cmd = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer playlist_name, + ffi.Pointer index, + ffi.Int32 action, + ffi.Uint64 position, + ffi.Pointer> request_id, +); + +typedef _dart_mc_client_send_playlist_cmd = int Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer playlist_name, + ffi.Pointer index, + int action, + int position, + ffi.Pointer> request_id, +); + +typedef _c_mc_client_send_custom_cmd = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer command, + ffi.Pointer data, + ffi.Pointer> request_id, +); + +typedef _dart_mc_client_send_custom_cmd = int Function( + ffi.Pointer client, + ffi.Pointer server_name, + ffi.Pointer command, + ffi.Pointer data, + ffi.Pointer> request_id, +); + +typedef _c_mc_client_destroy = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_mc_client_destroy = int Function( + ffi.Pointer client, +); + +typedef _c_mediademuxer_create = ffi.Int32 Function( + ffi.Pointer> demuxer, +); + +typedef _dart_mediademuxer_create = int Function( + ffi.Pointer> demuxer, +); + +typedef _c_mediademuxer_set_data_source = ffi.Int32 Function( + ffi.Pointer demuxer, + ffi.Pointer path, +); + +typedef _dart_mediademuxer_set_data_source = int Function( + ffi.Pointer demuxer, + ffi.Pointer path, +); + +typedef _c_mediademuxer_prepare = ffi.Int32 Function( + ffi.Pointer demuxer, +); + +typedef _dart_mediademuxer_prepare = int Function( + ffi.Pointer demuxer, +); + +typedef _c_mediademuxer_get_track_count = ffi.Int32 Function( + ffi.Pointer demuxer, + ffi.Pointer count, +); + +typedef _dart_mediademuxer_get_track_count = int Function( + ffi.Pointer demuxer, + ffi.Pointer count, +); + +typedef _c_mediademuxer_select_track = ffi.Int32 Function( + ffi.Pointer demuxer, + ffi.Int32 track_index, +); + +typedef _dart_mediademuxer_select_track = int Function( + ffi.Pointer demuxer, + int track_index, +); + +typedef _c_mediademuxer_start = ffi.Int32 Function( + ffi.Pointer demuxer, +); + +typedef _dart_mediademuxer_start = int Function( + ffi.Pointer demuxer, +); + +typedef _c_mediademuxer_get_track_info = ffi.Int32 Function( + ffi.Pointer demuxer, + ffi.Int32 track_index, + ffi.Pointer> format, +); + +typedef _dart_mediademuxer_get_track_info = int Function( + ffi.Pointer demuxer, + int track_index, + ffi.Pointer> format, +); + +typedef _c_mediademuxer_read_sample = ffi.Int32 Function( + ffi.Pointer demuxer, + ffi.Int32 track_index, + ffi.Pointer> outbuf, +); + +typedef _dart_mediademuxer_read_sample = int Function( + ffi.Pointer demuxer, + int track_index, + ffi.Pointer> outbuf, +); + +typedef _c_mediademuxer_seek = ffi.Int32 Function( + ffi.Pointer demuxer, + ffi.Int64 pos, +); + +typedef _dart_mediademuxer_seek = int Function( + ffi.Pointer demuxer, + int pos, +); + +typedef _c_mediademuxer_unselect_track = ffi.Int32 Function( + ffi.Pointer demuxer, + ffi.Int32 track_index, +); + +typedef _dart_mediademuxer_unselect_track = int Function( + ffi.Pointer demuxer, + int track_index, +); + +typedef _c_mediademuxer_stop = ffi.Int32 Function( + ffi.Pointer demuxer, +); + +typedef _dart_mediademuxer_stop = int Function( + ffi.Pointer demuxer, +); + +typedef _c_mediademuxer_unprepare = ffi.Int32 Function( + ffi.Pointer demuxer, +); + +typedef _dart_mediademuxer_unprepare = int Function( + ffi.Pointer demuxer, +); + +typedef _c_mediademuxer_destroy = ffi.Int32 Function( + ffi.Pointer demuxer, +); + +typedef _dart_mediademuxer_destroy = int Function( + ffi.Pointer demuxer, +); + +typedef _c_mediademuxer_get_state = ffi.Int32 Function( + ffi.Pointer demuxer, + ffi.Pointer state, +); + +typedef _dart_mediademuxer_get_state = int Function( + ffi.Pointer demuxer, + ffi.Pointer state, +); + +typedef mediademuxer_error_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mediademuxer_set_error_cb = ffi.Int32 Function( + ffi.Pointer demuxer, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mediademuxer_set_error_cb = int Function( + ffi.Pointer demuxer, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mediademuxer_unset_error_cb = ffi.Int32 Function( + ffi.Pointer demuxer, +); + +typedef _dart_mediademuxer_unset_error_cb = int Function( + ffi.Pointer demuxer, +); + +typedef mediademuxer_eos_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mediademuxer_set_eos_cb = ffi.Int32 Function( + ffi.Pointer demuxer, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mediademuxer_set_eos_cb = int Function( + ffi.Pointer demuxer, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mediademuxer_unset_eos_cb = ffi.Int32 Function( + ffi.Pointer demuxer, +); + +typedef _dart_mediademuxer_unset_eos_cb = int Function( + ffi.Pointer demuxer, +); + +typedef _c_mediamuxer_create = ffi.Int32 Function( + ffi.Pointer> muxer, +); + +typedef _dart_mediamuxer_create = int Function( + ffi.Pointer> muxer, +); + +typedef _c_mediamuxer_set_data_sink = ffi.Int32 Function( + ffi.Pointer muxer, + ffi.Pointer path, + ffi.Int32 format, +); + +typedef _dart_mediamuxer_set_data_sink = int Function( + ffi.Pointer muxer, + ffi.Pointer path, + int format, +); + +typedef _c_mediamuxer_add_track = ffi.Int32 Function( + ffi.Pointer muxer, + ffi.Pointer media_format, + ffi.Pointer track_index, +); + +typedef _dart_mediamuxer_add_track = int Function( + ffi.Pointer muxer, + ffi.Pointer media_format, + ffi.Pointer track_index, +); + +typedef _c_mediamuxer_prepare = ffi.Int32 Function( + ffi.Pointer muxer, +); + +typedef _dart_mediamuxer_prepare = int Function( + ffi.Pointer muxer, +); + +typedef _c_mediamuxer_start = ffi.Int32 Function( + ffi.Pointer muxer, +); + +typedef _dart_mediamuxer_start = int Function( + ffi.Pointer muxer, +); + +typedef _c_mediamuxer_write_sample = ffi.Int32 Function( + ffi.Pointer muxer, + ffi.Int32 track_index, + ffi.Pointer inbuf, +); + +typedef _dart_mediamuxer_write_sample = int Function( + ffi.Pointer muxer, + int track_index, + ffi.Pointer inbuf, +); + +typedef _c_mediamuxer_close_track = ffi.Int32 Function( + ffi.Pointer muxer, + ffi.Int32 track_index, +); + +typedef _dart_mediamuxer_close_track = int Function( + ffi.Pointer muxer, + int track_index, +); + +typedef _c_mediamuxer_pause = ffi.Int32 Function( + ffi.Pointer muxer, +); + +typedef _dart_mediamuxer_pause = int Function( + ffi.Pointer muxer, +); + +typedef _c_mediamuxer_resume = ffi.Int32 Function( + ffi.Pointer muxer, +); + +typedef _dart_mediamuxer_resume = int Function( + ffi.Pointer muxer, +); + +typedef _c_mediamuxer_stop = ffi.Int32 Function( + ffi.Pointer muxer, +); + +typedef _dart_mediamuxer_stop = int Function( + ffi.Pointer muxer, +); + +typedef _c_mediamuxer_unprepare = ffi.Int32 Function( + ffi.Pointer muxer, +); + +typedef _dart_mediamuxer_unprepare = int Function( + ffi.Pointer muxer, +); + +typedef _c_mediamuxer_destroy = ffi.Int32 Function( + ffi.Pointer muxer, +); + +typedef _dart_mediamuxer_destroy = int Function( + ffi.Pointer muxer, +); + +typedef _c_mediamuxer_get_state = ffi.Int32 Function( + ffi.Pointer muxer, + ffi.Pointer state, +); + +typedef _dart_mediamuxer_get_state = int Function( + ffi.Pointer muxer, + ffi.Pointer state, +); + +typedef mediamuxer_error_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mediamuxer_set_error_cb = ffi.Int32 Function( + ffi.Pointer muxer, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mediamuxer_set_error_cb = int Function( + ffi.Pointer muxer, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mediamuxer_unset_error_cb = ffi.Int32 Function( + ffi.Pointer muxer, +); + +typedef _dart_mediamuxer_unset_error_cb = int Function( + ffi.Pointer muxer, +); + +typedef mediamuxer_eos_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef _c_mediamuxer_set_eos_cb = ffi.Int32 Function( + ffi.Pointer muxer, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mediamuxer_set_eos_cb = int Function( + ffi.Pointer muxer, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mediamuxer_unset_eos_cb = ffi.Int32 Function( + ffi.Pointer muxer, +); + +typedef _dart_mediamuxer_unset_eos_cb = int Function( + ffi.Pointer muxer, +); + +typedef media_streamer_error_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_media_streamer_set_error_cb = ffi.Int32 Function( + ffi.Pointer streamer, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_streamer_set_error_cb = int Function( + ffi.Pointer streamer, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_streamer_unset_error_cb = ffi.Int32 Function( + ffi.Pointer streamer, +); + +typedef _dart_media_streamer_unset_error_cb = int Function( + ffi.Pointer streamer, +); + +typedef media_streamer_state_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_media_streamer_set_state_change_cb = ffi.Int32 Function( + ffi.Pointer streamer, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_streamer_set_state_change_cb = int Function( + ffi.Pointer streamer, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_streamer_unset_state_change_cb = ffi.Int32 Function( + ffi.Pointer streamer, +); + +typedef _dart_media_streamer_unset_state_change_cb = int Function( + ffi.Pointer streamer, +); + +typedef media_streamer_interrupted_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_media_streamer_set_interrupted_cb = ffi.Int32 Function( + ffi.Pointer streamer, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_streamer_set_interrupted_cb = int Function( + ffi.Pointer streamer, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_streamer_unset_interrupted_cb = ffi.Int32 Function( + ffi.Pointer streamer, +); + +typedef _dart_media_streamer_unset_interrupted_cb = int Function( + ffi.Pointer streamer, +); + +typedef media_streamer_custom_buffer_status_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_media_streamer_src_set_buffer_status_cb = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_media_streamer_src_set_buffer_status_cb = int Function( + ffi.Pointer source, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_media_streamer_src_unset_buffer_status_cb = ffi.Int32 Function( + ffi.Pointer source, +); + +typedef _dart_media_streamer_src_unset_buffer_status_cb = int Function( + ffi.Pointer source, +); + +typedef media_streamer_sink_data_ready_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_media_streamer_sink_set_data_ready_cb = ffi.Int32 Function( + ffi.Pointer sink, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_streamer_sink_set_data_ready_cb = int Function( + ffi.Pointer sink, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_streamer_sink_unset_data_ready_cb = ffi.Int32 Function( + ffi.Pointer sink, +); + +typedef _dart_media_streamer_sink_unset_data_ready_cb = int Function( + ffi.Pointer sink, +); + +typedef media_streamer_sink_eos_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_media_streamer_sink_set_eos_cb = ffi.Int32 Function( + ffi.Pointer sink, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_streamer_sink_set_eos_cb = int Function( + ffi.Pointer sink, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_streamer_sink_unset_eos_cb = ffi.Int32 Function( + ffi.Pointer sink, +); + +typedef _dart_media_streamer_sink_unset_eos_cb = int Function( + ffi.Pointer sink, +); + +typedef _c_media_streamer_create = ffi.Int32 Function( + ffi.Pointer> streamer, +); + +typedef _dart_media_streamer_create = int Function( + ffi.Pointer> streamer, +); + +typedef _c_media_streamer_prepare = ffi.Int32 Function( + ffi.Pointer streamer, +); + +typedef _dart_media_streamer_prepare = int Function( + ffi.Pointer streamer, +); + +typedef _c_media_streamer_unprepare = ffi.Int32 Function( + ffi.Pointer streamer, +); + +typedef _dart_media_streamer_unprepare = int Function( + ffi.Pointer streamer, +); + +typedef _c_media_streamer_play = ffi.Int32 Function( + ffi.Pointer streamer, +); + +typedef _dart_media_streamer_play = int Function( + ffi.Pointer streamer, +); + +typedef _c_media_streamer_pause = ffi.Int32 Function( + ffi.Pointer streamer, +); + +typedef _dart_media_streamer_pause = int Function( + ffi.Pointer streamer, +); + +typedef _c_media_streamer_stop = ffi.Int32 Function( + ffi.Pointer streamer, +); + +typedef _dart_media_streamer_stop = int Function( + ffi.Pointer streamer, +); + +typedef _c_media_streamer_destroy = ffi.Int32 Function( + ffi.Pointer streamer, +); + +typedef _dart_media_streamer_destroy = int Function( + ffi.Pointer streamer, +); + +typedef media_streamer_position_changed_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef _c_media_streamer_set_play_position = ffi.Int32 Function( + ffi.Pointer streamer, + ffi.Int32 time, + ffi.Uint8 accurate, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_streamer_set_play_position = int Function( + ffi.Pointer streamer, + int time, + int accurate, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_streamer_get_play_position = ffi.Int32 Function( + ffi.Pointer streamer, + ffi.Pointer time, +); + +typedef _dart_media_streamer_get_play_position = int Function( + ffi.Pointer streamer, + ffi.Pointer time, +); + +typedef _c_media_streamer_get_duration = ffi.Int32 Function( + ffi.Pointer streamer, + ffi.Pointer duration, +); + +typedef _dart_media_streamer_get_duration = int Function( + ffi.Pointer streamer, + ffi.Pointer duration, +); + +typedef _c_media_streamer_get_state = ffi.Int32 Function( + ffi.Pointer streamer, + ffi.Pointer state, +); + +typedef _dart_media_streamer_get_state = int Function( + ffi.Pointer streamer, + ffi.Pointer state, +); + +typedef _c_media_streamer_node_create_src = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer> src, +); + +typedef _dart_media_streamer_node_create_src = int Function( + int type, + ffi.Pointer> src, +); + +typedef _c_media_streamer_node_push_packet = ffi.Int32 Function( + ffi.Pointer src, + ffi.Pointer packet, +); + +typedef _dart_media_streamer_node_push_packet = int Function( + ffi.Pointer src, + ffi.Pointer packet, +); + +typedef _c_media_streamer_node_create_sink = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer> sink, +); + +typedef _dart_media_streamer_node_create_sink = int Function( + int type, + ffi.Pointer> sink, +); + +typedef _c_media_streamer_node_pull_packet = ffi.Int32 Function( + ffi.Pointer sink, + ffi.Pointer> packet, +); + +typedef _dart_media_streamer_node_pull_packet = int Function( + ffi.Pointer sink, + ffi.Pointer> packet, +); + +typedef _c_media_streamer_node_create = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer in_fmt, + ffi.Pointer out_fmt, + ffi.Pointer> node, +); + +typedef _dart_media_streamer_node_create = int Function( + int type, + ffi.Pointer in_fmt, + ffi.Pointer out_fmt, + ffi.Pointer> node, +); + +typedef _c_media_streamer_node_add = ffi.Int32 Function( + ffi.Pointer streamer, + ffi.Pointer node, +); + +typedef _dart_media_streamer_node_add = int Function( + ffi.Pointer streamer, + ffi.Pointer node, +); + +typedef _c_media_streamer_node_destroy = ffi.Int32 Function( + ffi.Pointer node, +); + +typedef _dart_media_streamer_node_destroy = int Function( + ffi.Pointer node, +); + +typedef _c_media_streamer_node_remove = ffi.Int32 Function( + ffi.Pointer streamer, + ffi.Pointer node, +); + +typedef _dart_media_streamer_node_remove = int Function( + ffi.Pointer streamer, + ffi.Pointer node, +); + +typedef _c_media_streamer_node_link = ffi.Int32 Function( + ffi.Pointer src_node, + ffi.Pointer src_pad_name, + ffi.Pointer dest_node, + ffi.Pointer sink_pad_name, +); + +typedef _dart_media_streamer_node_link = int Function( + ffi.Pointer src_node, + ffi.Pointer src_pad_name, + ffi.Pointer dest_node, + ffi.Pointer sink_pad_name, +); + +typedef _c_media_streamer_node_set_pad_format = ffi.Int32 Function( + ffi.Pointer node, + ffi.Pointer pad_name, + ffi.Pointer fmt, +); + +typedef _dart_media_streamer_node_set_pad_format = int Function( + ffi.Pointer node, + ffi.Pointer pad_name, + ffi.Pointer fmt, +); + +typedef _c_media_streamer_node_get_pad_format = ffi.Int32 Function( + ffi.Pointer node, + ffi.Pointer pad_name, + ffi.Pointer> fmt, +); + +typedef _dart_media_streamer_node_get_pad_format = int Function( + ffi.Pointer node, + ffi.Pointer pad_name, + ffi.Pointer> fmt, +); + +typedef _c_media_streamer_node_get_pad_name = ffi.Int32 Function( + ffi.Pointer node, + ffi.Pointer>> src_pad_name, + ffi.Pointer src_pad_num, + ffi.Pointer>> sink_pad_name, + ffi.Pointer sink_pad_num, +); + +typedef _dart_media_streamer_node_get_pad_name = int Function( + ffi.Pointer node, + ffi.Pointer>> src_pad_name, + ffi.Pointer src_pad_num, + ffi.Pointer>> sink_pad_name, + ffi.Pointer sink_pad_num, +); + +typedef _c_media_streamer_node_set_params = ffi.Int32 Function( + ffi.Pointer node, + ffi.Pointer param_list, +); + +typedef _dart_media_streamer_node_set_params = int Function( + ffi.Pointer node, + ffi.Pointer param_list, +); + +typedef _c_media_streamer_node_get_params = ffi.Int32 Function( + ffi.Pointer node, + ffi.Pointer> param_list, +); + +typedef _dart_media_streamer_node_get_params = int Function( + ffi.Pointer node, + ffi.Pointer> param_list, +); + +typedef _c_media_streamer_node_set_param = ffi.Int32 Function( + ffi.Pointer node, + ffi.Pointer param_name, + ffi.Pointer param_value, +); + +typedef _dart_media_streamer_node_set_param = int Function( + ffi.Pointer node, + ffi.Pointer param_name, + ffi.Pointer param_value, +); + +typedef _c_media_streamer_node_get_param = ffi.Int32 Function( + ffi.Pointer node, + ffi.Pointer param_name, + ffi.Pointer> param_value, +); + +typedef _dart_media_streamer_node_get_param = int Function( + ffi.Pointer node, + ffi.Pointer param_name, + ffi.Pointer> param_value, +); + +typedef _c_mv_create_source = ffi.Int32 Function( + ffi.Pointer> source, +); + +typedef _dart_mv_create_source = int Function( + ffi.Pointer> source, +); + +typedef _c_mv_destroy_source = ffi.Int32 Function( + ffi.Pointer source, +); + +typedef _dart_mv_destroy_source = int Function( + ffi.Pointer source, +); + +typedef _c_mv_source_fill_by_media_packet = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer media_packet, +); + +typedef _dart_mv_source_fill_by_media_packet = int Function( + ffi.Pointer source, + ffi.Pointer media_packet, +); + +typedef _c_mv_source_fill_by_buffer = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer data_buffer, + ffi.Uint32 buffer_size, + ffi.Uint32 image_width, + ffi.Uint32 image_height, + ffi.Int32 image_colorspace, +); + +typedef _dart_mv_source_fill_by_buffer = int Function( + ffi.Pointer source, + ffi.Pointer data_buffer, + int buffer_size, + int image_width, + int image_height, + int image_colorspace, +); + +typedef _c_mv_source_clear = ffi.Int32 Function( + ffi.Pointer source, +); + +typedef _dart_mv_source_clear = int Function( + ffi.Pointer source, +); + +typedef _c_mv_source_get_buffer = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer> data_buffer, + ffi.Pointer buffer_size, +); + +typedef _dart_mv_source_get_buffer = int Function( + ffi.Pointer source, + ffi.Pointer> data_buffer, + ffi.Pointer buffer_size, +); + +typedef _c_mv_source_get_height = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer image_height, +); + +typedef _dart_mv_source_get_height = int Function( + ffi.Pointer source, + ffi.Pointer image_height, +); + +typedef _c_mv_source_get_width = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer image_width, +); + +typedef _dart_mv_source_get_width = int Function( + ffi.Pointer source, + ffi.Pointer image_width, +); + +typedef _c_mv_source_get_colorspace = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer image_colorspace, +); + +typedef _dart_mv_source_get_colorspace = int Function( + ffi.Pointer source, + ffi.Pointer image_colorspace, +); + +typedef _c_mv_create_engine_config = ffi.Int32 Function( + ffi.Pointer> engine_cfg, +); + +typedef _dart_mv_create_engine_config = int Function( + ffi.Pointer> engine_cfg, +); + +typedef _c_mv_destroy_engine_config = ffi.Int32 Function( + ffi.Pointer engine_cfg, +); + +typedef _dart_mv_destroy_engine_config = int Function( + ffi.Pointer engine_cfg, +); + +typedef _c_mv_engine_config_set_double_attribute = ffi.Int32 Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Double value, +); + +typedef _dart_mv_engine_config_set_double_attribute = int Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + double value, +); + +typedef _c_mv_engine_config_set_int_attribute = ffi.Int32 Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Int32 value, +); + +typedef _dart_mv_engine_config_set_int_attribute = int Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + int value, +); + +typedef _c_mv_engine_config_set_bool_attribute = ffi.Int32 Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Uint8 value, +); + +typedef _dart_mv_engine_config_set_bool_attribute = int Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + int value, +); + +typedef _c_mv_engine_config_set_string_attribute = ffi.Int32 Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer value, +); + +typedef _dart_mv_engine_config_set_string_attribute = int Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer value, +); + +typedef _c_mv_engine_config_get_double_attribute = ffi.Int32 Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer value, +); + +typedef _dart_mv_engine_config_get_double_attribute = int Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer value, +); + +typedef _c_mv_engine_config_get_int_attribute = ffi.Int32 Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer value, +); + +typedef _dart_mv_engine_config_get_int_attribute = int Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer value, +); + +typedef _c_mv_engine_config_get_bool_attribute = ffi.Int32 Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer value, +); + +typedef _dart_mv_engine_config_get_bool_attribute = int Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer value, +); + +typedef _c_mv_engine_config_get_string_attribute = ffi.Int32 Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer> value, +); + +typedef _dart_mv_engine_config_get_string_attribute = int Function( + ffi.Pointer engine_cfg, + ffi.Pointer name, + ffi.Pointer> value, +); + +typedef mv_supported_attribute_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mv_engine_config_foreach_supported_attribute = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mv_engine_config_foreach_supported_attribute = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef mv_barcode_detected_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer>, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mv_barcode_detect = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer engine_cfg, + mv_rectangle_s roi, + ffi.Pointer> detect_cb, + ffi.Pointer user_data, +); + +typedef _dart_mv_barcode_detect = int Function( + ffi.Pointer source, + ffi.Pointer engine_cfg, + mv_rectangle_s roi, + ffi.Pointer> detect_cb, + ffi.Pointer user_data, +); + +typedef _c_mv_barcode_generate_source = ffi.Int32 Function( + ffi.Pointer engine_cfg, + ffi.Pointer message, + ffi.Int32 type, + ffi.Int32 qr_enc_mode, + ffi.Int32 qr_ecc, + ffi.Int32 qr_version, + ffi.Pointer image, +); + +typedef _dart_mv_barcode_generate_source = int Function( + ffi.Pointer engine_cfg, + ffi.Pointer message, + int type, + int qr_enc_mode, + int qr_ecc, + int qr_version, + ffi.Pointer image, +); + +typedef _c_mv_barcode_generate_image = ffi.Int32 Function( + ffi.Pointer engine_cfg, + ffi.Pointer message, + ffi.Int32 image_width, + ffi.Int32 image_height, + ffi.Int32 type, + ffi.Int32 qr_enc_mode, + ffi.Int32 qr_ecc, + ffi.Int32 qr_version, + ffi.Pointer image_path, + ffi.Int32 image_format, +); + +typedef _dart_mv_barcode_generate_image = int Function( + ffi.Pointer engine_cfg, + ffi.Pointer message, + int image_width, + int image_height, + int type, + int qr_enc_mode, + int qr_ecc, + int qr_version, + ffi.Pointer image_path, + int image_format, +); + +typedef mv_face_detected_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mv_face_detect = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer engine_cfg, + ffi.Pointer> detected_cb, + ffi.Pointer user_data, +); + +typedef _dart_mv_face_detect = int Function( + ffi.Pointer source, + ffi.Pointer engine_cfg, + ffi.Pointer> detected_cb, + ffi.Pointer user_data, +); + +typedef mv_face_recognized_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Double, + ffi.Pointer, +); + +typedef _c_mv_face_recognize = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer recognition_model, + ffi.Pointer engine_cfg, + ffi.Pointer face_location, + ffi.Pointer> recognized_cb, + ffi.Pointer user_data, +); + +typedef _dart_mv_face_recognize = int Function( + ffi.Pointer source, + ffi.Pointer recognition_model, + ffi.Pointer engine_cfg, + ffi.Pointer face_location, + ffi.Pointer> recognized_cb, + ffi.Pointer user_data, +); + +typedef mv_face_tracked_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Double, + ffi.Pointer, +); + +typedef _c_mv_face_track = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer tracking_model, + ffi.Pointer engine_cfg, + ffi.Pointer> tracked_cb, + ffi.Uint8 do_learn, + ffi.Pointer user_data, +); + +typedef _dart_mv_face_track = int Function( + ffi.Pointer source, + ffi.Pointer tracking_model, + ffi.Pointer engine_cfg, + ffi.Pointer> tracked_cb, + int do_learn, + ffi.Pointer user_data, +); + +typedef mv_face_eye_condition_recognized_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + mv_rectangle_s, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mv_face_eye_condition_recognize = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer engine_cfg, + mv_rectangle_s face_location, + ffi.Pointer> + eye_condition_recognized_cb, + ffi.Pointer user_data, +); + +typedef _dart_mv_face_eye_condition_recognize = int Function( + ffi.Pointer source, + ffi.Pointer engine_cfg, + mv_rectangle_s face_location, + ffi.Pointer> + eye_condition_recognized_cb, + ffi.Pointer user_data, +); + +typedef mv_face_facial_expression_recognized_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + mv_rectangle_s, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_mv_face_facial_expression_recognize = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer engine_cfg, + mv_rectangle_s face_location, + ffi.Pointer> + expression_recognized_cb, + ffi.Pointer user_data, +); + +typedef _dart_mv_face_facial_expression_recognize = int Function( + ffi.Pointer source, + ffi.Pointer engine_cfg, + mv_rectangle_s face_location, + ffi.Pointer> + expression_recognized_cb, + ffi.Pointer user_data, +); + +typedef _c_mv_face_recognition_model_create = ffi.Int32 Function( + ffi.Pointer> recognition_model, +); + +typedef _dart_mv_face_recognition_model_create = int Function( + ffi.Pointer> recognition_model, +); + +typedef _c_mv_face_recognition_model_destroy = ffi.Int32 Function( + ffi.Pointer recognition_model, +); + +typedef _dart_mv_face_recognition_model_destroy = int Function( + ffi.Pointer recognition_model, +); + +typedef _c_mv_face_recognition_model_clone = ffi.Int32 Function( + ffi.Pointer src, + ffi.Pointer> dst, +); + +typedef _dart_mv_face_recognition_model_clone = int Function( + ffi.Pointer src, + ffi.Pointer> dst, +); + +typedef _c_mv_face_recognition_model_save = ffi.Int32 Function( + ffi.Pointer file_name, + ffi.Pointer recognition_model, +); + +typedef _dart_mv_face_recognition_model_save = int Function( + ffi.Pointer file_name, + ffi.Pointer recognition_model, +); + +typedef _c_mv_face_recognition_model_load = ffi.Int32 Function( + ffi.Pointer file_name, + ffi.Pointer> recognition_model, +); + +typedef _dart_mv_face_recognition_model_load = int Function( + ffi.Pointer file_name, + ffi.Pointer> recognition_model, +); + +typedef _c_mv_face_recognition_model_add = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer recognition_model, + ffi.Pointer example_location, + ffi.Int32 face_label, +); + +typedef _dart_mv_face_recognition_model_add = int Function( + ffi.Pointer source, + ffi.Pointer recognition_model, + ffi.Pointer example_location, + int face_label, +); + +typedef _c_mv_face_recognition_model_reset = ffi.Int32 Function( + ffi.Pointer recognition_model, + ffi.Pointer face_label, +); + +typedef _dart_mv_face_recognition_model_reset = int Function( + ffi.Pointer recognition_model, + ffi.Pointer face_label, +); + +typedef _c_mv_face_recognition_model_learn = ffi.Int32 Function( + ffi.Pointer engine_cfg, + ffi.Pointer recognition_model, +); + +typedef _dart_mv_face_recognition_model_learn = int Function( + ffi.Pointer engine_cfg, + ffi.Pointer recognition_model, +); + +typedef _c_mv_face_recognition_model_query_labels = ffi.Int32 Function( + ffi.Pointer recognition_model, + ffi.Pointer> labels, + ffi.Pointer number_of_labels, +); + +typedef _dart_mv_face_recognition_model_query_labels = int Function( + ffi.Pointer recognition_model, + ffi.Pointer> labels, + ffi.Pointer number_of_labels, +); + +typedef _c_mv_face_tracking_model_create = ffi.Int32 Function( + ffi.Pointer> tracking_model, +); + +typedef _dart_mv_face_tracking_model_create = int Function( + ffi.Pointer> tracking_model, +); + +typedef _c_mv_face_tracking_model_destroy = ffi.Int32 Function( + ffi.Pointer tracking_model, +); + +typedef _dart_mv_face_tracking_model_destroy = int Function( + ffi.Pointer tracking_model, +); + +typedef _c_mv_face_tracking_model_prepare = ffi.Int32 Function( + ffi.Pointer tracking_model, + ffi.Pointer engine_cfg, + ffi.Pointer source, + ffi.Pointer location, +); + +typedef _dart_mv_face_tracking_model_prepare = int Function( + ffi.Pointer tracking_model, + ffi.Pointer engine_cfg, + ffi.Pointer source, + ffi.Pointer location, +); + +typedef _c_mv_face_tracking_model_clone = ffi.Int32 Function( + ffi.Pointer src, + ffi.Pointer> dst, +); + +typedef _dart_mv_face_tracking_model_clone = int Function( + ffi.Pointer src, + ffi.Pointer> dst, +); + +typedef _c_mv_face_tracking_model_save = ffi.Int32 Function( + ffi.Pointer file_name, + ffi.Pointer tracking_model, +); + +typedef _dart_mv_face_tracking_model_save = int Function( + ffi.Pointer file_name, + ffi.Pointer tracking_model, +); + +typedef _c_mv_face_tracking_model_load = ffi.Int32 Function( + ffi.Pointer file_name, + ffi.Pointer> tracking_model, +); + +typedef _dart_mv_face_tracking_model_load = int Function( + ffi.Pointer file_name, + ffi.Pointer> tracking_model, +); + +typedef mv_image_recognized_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer>, + ffi.Pointer>, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_mv_image_recognize = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer> image_objects, + ffi.Int32 number_of_objects, + ffi.Pointer engine_cfg, + ffi.Pointer> recognized_cb, + ffi.Pointer user_data, +); + +typedef _dart_mv_image_recognize = int Function( + ffi.Pointer source, + ffi.Pointer> image_objects, + int number_of_objects, + ffi.Pointer engine_cfg, + ffi.Pointer> recognized_cb, + ffi.Pointer user_data, +); + +typedef mv_image_tracked_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mv_image_track = ffi.Int32 Function( + ffi.Pointer source, + ffi.Pointer image_tracking_model, + ffi.Pointer engine_cfg, + ffi.Pointer> tracked_cb, + ffi.Pointer user_data, +); + +typedef _dart_mv_image_track = int Function( + ffi.Pointer source, + ffi.Pointer image_tracking_model, + ffi.Pointer engine_cfg, + ffi.Pointer> tracked_cb, + ffi.Pointer user_data, +); + +typedef _c_mv_image_object_create = ffi.Int32 Function( + ffi.Pointer> image_object, +); + +typedef _dart_mv_image_object_create = int Function( + ffi.Pointer> image_object, +); + +typedef _c_mv_image_object_destroy = ffi.Int32 Function( + ffi.Pointer image_object, +); + +typedef _dart_mv_image_object_destroy = int Function( + ffi.Pointer image_object, +); + +typedef _c_mv_image_object_fill = ffi.Int32 Function( + ffi.Pointer image_object, + ffi.Pointer engine_cfg, + ffi.Pointer source, + ffi.Pointer location, +); + +typedef _dart_mv_image_object_fill = int Function( + ffi.Pointer image_object, + ffi.Pointer engine_cfg, + ffi.Pointer source, + ffi.Pointer location, +); + +typedef _c_mv_image_object_get_recognition_rate = ffi.Int32 Function( + ffi.Pointer image_object, + ffi.Pointer recognition_rate, +); + +typedef _dart_mv_image_object_get_recognition_rate = int Function( + ffi.Pointer image_object, + ffi.Pointer recognition_rate, +); + +typedef _c_mv_image_object_set_label = ffi.Int32 Function( + ffi.Pointer image_object, + ffi.Int32 label, +); + +typedef _dart_mv_image_object_set_label = int Function( + ffi.Pointer image_object, + int label, +); + +typedef _c_mv_image_object_get_label = ffi.Int32 Function( + ffi.Pointer image_object, + ffi.Pointer label, +); + +typedef _dart_mv_image_object_get_label = int Function( + ffi.Pointer image_object, + ffi.Pointer label, +); + +typedef _c_mv_image_object_clone = ffi.Int32 Function( + ffi.Pointer src, + ffi.Pointer> dst, +); + +typedef _dart_mv_image_object_clone = int Function( + ffi.Pointer src, + ffi.Pointer> dst, +); + +typedef _c_mv_image_object_save = ffi.Int32 Function( + ffi.Pointer file_name, + ffi.Pointer image_object, +); + +typedef _dart_mv_image_object_save = int Function( + ffi.Pointer file_name, + ffi.Pointer image_object, +); + +typedef _c_mv_image_object_load = ffi.Int32 Function( + ffi.Pointer file_name, + ffi.Pointer> image_object, +); + +typedef _dart_mv_image_object_load = int Function( + ffi.Pointer file_name, + ffi.Pointer> image_object, +); + +typedef _c_mv_image_tracking_model_create = ffi.Int32 Function( + ffi.Pointer> image_tracking_model, +); + +typedef _dart_mv_image_tracking_model_create = int Function( + ffi.Pointer> image_tracking_model, +); + +typedef _c_mv_image_tracking_model_set_target = ffi.Int32 Function( + ffi.Pointer image_object, + ffi.Pointer image_tracking_model, +); + +typedef _dart_mv_image_tracking_model_set_target = int Function( + ffi.Pointer image_object, + ffi.Pointer image_tracking_model, +); + +typedef _c_mv_image_tracking_model_destroy = ffi.Int32 Function( + ffi.Pointer image_tracking_model, +); + +typedef _dart_mv_image_tracking_model_destroy = int Function( + ffi.Pointer image_tracking_model, +); + +typedef _c_mv_image_tracking_model_refresh = ffi.Int32 Function( + ffi.Pointer image_tracking_model, + ffi.Pointer engine_cfg, +); + +typedef _dart_mv_image_tracking_model_refresh = int Function( + ffi.Pointer image_tracking_model, + ffi.Pointer engine_cfg, +); + +typedef _c_mv_image_tracking_model_clone = ffi.Int32 Function( + ffi.Pointer src, + ffi.Pointer> dst, +); + +typedef _dart_mv_image_tracking_model_clone = int Function( + ffi.Pointer src, + ffi.Pointer> dst, +); + +typedef _c_mv_image_tracking_model_save = ffi.Int32 Function( + ffi.Pointer file_name, + ffi.Pointer image_tracking_model, +); + +typedef _dart_mv_image_tracking_model_save = int Function( + ffi.Pointer file_name, + ffi.Pointer image_tracking_model, +); + +typedef _c_mv_image_tracking_model_load = ffi.Int32 Function( + ffi.Pointer file_name, + ffi.Pointer> image_tracking_model, +); + +typedef _dart_mv_image_tracking_model_load = int Function( + ffi.Pointer file_name, + ffi.Pointer> image_tracking_model, +); + +typedef _c_mv_surveillance_event_trigger_create = ffi.Int32 Function( + ffi.Pointer event_type, + ffi.Pointer> trigger, +); + +typedef _dart_mv_surveillance_event_trigger_create = int Function( + ffi.Pointer event_type, + ffi.Pointer> trigger, +); + +typedef _c_mv_surveillance_event_trigger_destroy = ffi.Int32 Function( + ffi.Pointer trigger, +); + +typedef _dart_mv_surveillance_event_trigger_destroy = int Function( + ffi.Pointer trigger, +); + +typedef _c_mv_surveillance_get_event_trigger_type = ffi.Int32 Function( + ffi.Pointer trigger, + ffi.Pointer> event_type, +); + +typedef _dart_mv_surveillance_get_event_trigger_type = int Function( + ffi.Pointer trigger, + ffi.Pointer> event_type, +); + +typedef _c_mv_surveillance_set_event_trigger_roi = ffi.Int32 Function( + ffi.Pointer trigger, + ffi.Int32 number_of_points, + ffi.Pointer roi, +); + +typedef _dart_mv_surveillance_set_event_trigger_roi = int Function( + ffi.Pointer trigger, + int number_of_points, + ffi.Pointer roi, +); + +typedef _c_mv_surveillance_get_event_trigger_roi = ffi.Int32 Function( + ffi.Pointer trigger, + ffi.Pointer number_of_points, + ffi.Pointer> roi, +); + +typedef _dart_mv_surveillance_get_event_trigger_roi = int Function( + ffi.Pointer trigger, + ffi.Pointer number_of_points, + ffi.Pointer> roi, +); + +typedef mv_surveillance_event_occurred_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mv_surveillance_subscribe_event_trigger = ffi.Int32 Function( + ffi.Pointer trigger, + ffi.Int32 video_stream_id, + ffi.Pointer engine_cfg, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mv_surveillance_subscribe_event_trigger = int Function( + ffi.Pointer trigger, + int video_stream_id, + ffi.Pointer engine_cfg, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_mv_surveillance_unsubscribe_event_trigger = ffi.Int32 Function( + ffi.Pointer trigger, + ffi.Int32 video_stream_id, +); + +typedef _dart_mv_surveillance_unsubscribe_event_trigger = int Function( + ffi.Pointer trigger, + int video_stream_id, +); + +typedef _c_mv_surveillance_push_source = ffi.Int32 Function( + ffi.Pointer source, + ffi.Int32 video_stream_id, +); + +typedef _dart_mv_surveillance_push_source = int Function( + ffi.Pointer source, + int video_stream_id, +); + +typedef mv_surveillance_event_type_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mv_surveillance_foreach_supported_event_type = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_mv_surveillance_foreach_supported_event_type = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef mv_surveillance_event_result_name_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_mv_surveillance_foreach_event_result_name = ffi.Int32 Function( + ffi.Pointer event_type, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_mv_surveillance_foreach_event_result_name = int Function( + ffi.Pointer event_type, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_mv_surveillance_get_result_value = ffi.Int32 Function( + ffi.Pointer result, + ffi.Pointer name, + ffi.Pointer value, +); + +typedef _dart_mv_surveillance_get_result_value = int Function( + ffi.Pointer result, + ffi.Pointer name, + ffi.Pointer value, +); + +typedef _c_metadata_editor_create = ffi.Int32 Function( + ffi.Pointer> metadata, +); + +typedef _dart_metadata_editor_create = int Function( + ffi.Pointer> metadata, +); + +typedef _c_metadata_editor_set_path = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Pointer path, +); + +typedef _dart_metadata_editor_set_path = int Function( + ffi.Pointer metadata, + ffi.Pointer path, +); + +typedef _c_metadata_editor_get_metadata = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Int32 attribute, + ffi.Pointer> value, +); + +typedef _dart_metadata_editor_get_metadata = int Function( + ffi.Pointer metadata, + int attribute, + ffi.Pointer> value, +); + +typedef _c_metadata_editor_set_metadata = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Int32 attribute, + ffi.Pointer value, +); + +typedef _dart_metadata_editor_set_metadata = int Function( + ffi.Pointer metadata, + int attribute, + ffi.Pointer value, +); + +typedef _c_metadata_editor_update_metadata = ffi.Int32 Function( + ffi.Pointer metadata, +); + +typedef _dart_metadata_editor_update_metadata = int Function( + ffi.Pointer metadata, +); + +typedef _c_metadata_editor_get_picture = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Int32 index, + ffi.Pointer> picture, + ffi.Pointer size, + ffi.Pointer> mime_type, +); + +typedef _dart_metadata_editor_get_picture = int Function( + ffi.Pointer metadata, + int index, + ffi.Pointer> picture, + ffi.Pointer size, + ffi.Pointer> mime_type, +); + +typedef _c_metadata_editor_append_picture = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Pointer picture_path, +); + +typedef _dart_metadata_editor_append_picture = int Function( + ffi.Pointer metadata, + ffi.Pointer picture_path, +); + +typedef _c_metadata_editor_remove_picture = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Int32 index, +); + +typedef _dart_metadata_editor_remove_picture = int Function( + ffi.Pointer metadata, + int index, +); + +typedef _c_metadata_editor_destroy = ffi.Int32 Function( + ffi.Pointer metadata, +); + +typedef _dart_metadata_editor_destroy = int Function( + ffi.Pointer metadata, +); + +typedef _c_metadata_extractor_create = ffi.Int32 Function( + ffi.Pointer> metadata, +); + +typedef _dart_metadata_extractor_create = int Function( + ffi.Pointer> metadata, +); + +typedef _c_metadata_extractor_set_path = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Pointer path, +); + +typedef _dart_metadata_extractor_set_path = int Function( + ffi.Pointer metadata, + ffi.Pointer path, +); + +typedef _c_metadata_extractor_set_buffer = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Pointer buffer, + ffi.Int32 size, +); + +typedef _dart_metadata_extractor_set_buffer = int Function( + ffi.Pointer metadata, + ffi.Pointer buffer, + int size, +); + +typedef _c_metadata_extractor_destroy = ffi.Int32 Function( + ffi.Pointer metadata, +); + +typedef _dart_metadata_extractor_destroy = int Function( + ffi.Pointer metadata, +); + +typedef _c_metadata_extractor_get_metadata = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Int32 attribute, + ffi.Pointer> value, +); + +typedef _dart_metadata_extractor_get_metadata = int Function( + ffi.Pointer metadata, + int attribute, + ffi.Pointer> value, +); + +typedef _c_metadata_extractor_get_artwork = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Pointer> artwork, + ffi.Pointer size, + ffi.Pointer> mime_type, +); + +typedef _dart_metadata_extractor_get_artwork = int Function( + ffi.Pointer metadata, + ffi.Pointer> artwork, + ffi.Pointer size, + ffi.Pointer> mime_type, +); + +typedef _c_metadata_extractor_get_frame = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Pointer> frame, + ffi.Pointer size, +); + +typedef _dart_metadata_extractor_get_frame = int Function( + ffi.Pointer metadata, + ffi.Pointer> frame, + ffi.Pointer size, +); + +typedef _c_metadata_extractor_get_synclyrics = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Int32 index, + ffi.Pointer time_stamp, + ffi.Pointer> lyrics, +); + +typedef _dart_metadata_extractor_get_synclyrics = int Function( + ffi.Pointer metadata, + int index, + ffi.Pointer time_stamp, + ffi.Pointer> lyrics, +); + +typedef _c_metadata_extractor_get_frame_at_time = ffi.Int32 Function( + ffi.Pointer metadata, + ffi.Uint64 timestamp, + ffi.Uint8 is_accurate, + ffi.Pointer> frame, + ffi.Pointer size, +); + +typedef _dart_metadata_extractor_get_frame_at_time = int Function( + ffi.Pointer metadata, + int timestamp, + int is_accurate, + ffi.Pointer> frame, + ffi.Pointer size, +); + +typedef _c_player_create = ffi.Int32 Function( + ffi.Pointer> player, +); + +typedef _dart_player_create = int Function( + ffi.Pointer> player, +); + +typedef _c_player_destroy = ffi.Int32 Function( + ffi.Pointer player, +); + +typedef _dart_player_destroy = int Function( + ffi.Pointer player, +); + +typedef _c_player_prepare = ffi.Int32 Function( + ffi.Pointer player, +); + +typedef _dart_player_prepare = int Function( + ffi.Pointer player, +); + +typedef player_prepared_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef _c_player_prepare_async = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_player_prepare_async = int Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_player_unprepare = ffi.Int32 Function( + ffi.Pointer player, +); + +typedef _dart_player_unprepare = int Function( + ffi.Pointer player, +); + +typedef _c_player_set_uri = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer uri, +); + +typedef _dart_player_set_uri = int Function( + ffi.Pointer player, + ffi.Pointer uri, +); + +typedef _c_player_set_memory_buffer = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer data, + ffi.Int32 size, +); + +typedef _dart_player_set_memory_buffer = int Function( + ffi.Pointer player, + ffi.Pointer data, + int size, +); + +typedef _c_player_get_state = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer state, +); + +typedef _dart_player_get_state = int Function( + ffi.Pointer player, + ffi.Pointer state, +); + +typedef _c_player_set_volume = ffi.Int32 Function( + ffi.Pointer player, + ffi.Float left, + ffi.Float right, +); + +typedef _dart_player_set_volume = int Function( + ffi.Pointer player, + double left, + double right, +); + +typedef _c_player_get_volume = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer left, + ffi.Pointer right, +); + +typedef _dart_player_get_volume = int Function( + ffi.Pointer player, + ffi.Pointer left, + ffi.Pointer right, +); + +typedef _c_player_set_sound_type = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, +); + +typedef _dart_player_set_sound_type = int Function( + ffi.Pointer player, + int type, +); + +typedef _c_player_set_sound_stream_info = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer stream_info, +); + +typedef _dart_player_set_sound_stream_info = int Function( + ffi.Pointer player, + ffi.Pointer stream_info, +); + +typedef _c_player_set_audio_latency_mode = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 latency_mode, +); + +typedef _dart_player_set_audio_latency_mode = int Function( + ffi.Pointer player, + int latency_mode, +); + +typedef _c_player_get_audio_latency_mode = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer latency_mode, +); + +typedef _dart_player_get_audio_latency_mode = int Function( + ffi.Pointer player, + ffi.Pointer latency_mode, +); + +typedef _c_player_start = ffi.Int32 Function( + ffi.Pointer player, +); + +typedef _dart_player_start = int Function( + ffi.Pointer player, +); + +typedef _c_player_stop = ffi.Int32 Function( + ffi.Pointer player, +); + +typedef _dart_player_stop = int Function( + ffi.Pointer player, +); + +typedef _c_player_pause = ffi.Int32 Function( + ffi.Pointer player, +); + +typedef _dart_player_pause = int Function( + ffi.Pointer player, +); + +typedef player_seek_completed_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef _c_player_set_play_position = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 millisecond, + ffi.Uint8 accurate, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_player_set_play_position = int Function( + ffi.Pointer player, + int millisecond, + int accurate, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_player_get_play_position = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer millisecond, +); + +typedef _dart_player_get_play_position = int Function( + ffi.Pointer player, + ffi.Pointer millisecond, +); + +typedef _c_player_set_mute = ffi.Int32 Function( + ffi.Pointer player, + ffi.Uint8 muted, +); + +typedef _dart_player_set_mute = int Function( + ffi.Pointer player, + int muted, +); + +typedef _c_player_is_muted = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer muted, +); + +typedef _dart_player_is_muted = int Function( + ffi.Pointer player, + ffi.Pointer muted, +); + +typedef _c_player_set_looping = ffi.Int32 Function( + ffi.Pointer player, + ffi.Uint8 looping, +); + +typedef _dart_player_set_looping = int Function( + ffi.Pointer player, + int looping, +); + +typedef _c_player_is_looping = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer looping, +); + +typedef _dart_player_is_looping = int Function( + ffi.Pointer player, + ffi.Pointer looping, +); + +typedef _c_player_set_display = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, + ffi.Pointer display, +); + +typedef _dart_player_set_display = int Function( + ffi.Pointer player, + int type, + ffi.Pointer display, +); + +typedef player_media_packet_video_decoded_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_player_set_media_packet_video_frame_decoded_cb = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_player_set_media_packet_video_frame_decoded_cb = int Function( + ffi.Pointer player, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_player_unset_media_packet_video_frame_decoded_cb = ffi.Int32 + Function( + ffi.Pointer player, +); + +typedef _dart_player_unset_media_packet_video_frame_decoded_cb = int Function( + ffi.Pointer player, +); + +typedef _c_player_push_media_stream = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer packet, +); + +typedef _dart_player_push_media_stream = int Function( + ffi.Pointer player, + ffi.Pointer packet, +); + +typedef _c_player_set_media_stream_info = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, + ffi.Pointer format, +); + +typedef _dart_player_set_media_stream_info = int Function( + ffi.Pointer player, + int type, + ffi.Pointer format, +); + +typedef player_media_stream_buffer_status_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_player_set_media_stream_buffer_status_cb = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_player_set_media_stream_buffer_status_cb = int Function( + ffi.Pointer player, + int type, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_player_unset_media_stream_buffer_status_cb = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, +); + +typedef _dart_player_unset_media_stream_buffer_status_cb = int Function( + ffi.Pointer player, + int type, +); + +typedef player_media_stream_seek_cb = ffi.Void Function( + ffi.Uint64, + ffi.Pointer, +); + +typedef _c_player_set_media_stream_seek_cb = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_player_set_media_stream_seek_cb = int Function( + ffi.Pointer player, + int type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_player_unset_media_stream_seek_cb = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, +); + +typedef _dart_player_unset_media_stream_seek_cb = int Function( + ffi.Pointer player, + int type, +); + +typedef _c_player_set_media_stream_buffer_max_size = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, + ffi.Uint64 max_size, +); + +typedef _dart_player_set_media_stream_buffer_max_size = int Function( + ffi.Pointer player, + int type, + int max_size, +); + +typedef _c_player_get_media_stream_buffer_max_size = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, + ffi.Pointer max_size, +); + +typedef _dart_player_get_media_stream_buffer_max_size = int Function( + ffi.Pointer player, + int type, + ffi.Pointer max_size, +); + +typedef _c_player_set_media_stream_buffer_min_threshold = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, + ffi.Uint32 percent, +); + +typedef _dart_player_set_media_stream_buffer_min_threshold = int Function( + ffi.Pointer player, + int type, + int percent, +); + +typedef _c_player_get_media_stream_buffer_min_threshold = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, + ffi.Pointer percent, +); + +typedef _dart_player_get_media_stream_buffer_min_threshold = int Function( + ffi.Pointer player, + int type, + ffi.Pointer percent, +); + +typedef _c_player_set_display_mode = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 mode, +); + +typedef _dart_player_set_display_mode = int Function( + ffi.Pointer player, + int mode, +); + +typedef _c_player_get_display_mode = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer mode, +); + +typedef _dart_player_get_display_mode = int Function( + ffi.Pointer player, + ffi.Pointer mode, +); + +typedef _c_player_set_display_roi_area = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 x, + ffi.Int32 y, + ffi.Int32 width, + ffi.Int32 height, +); + +typedef _dart_player_set_display_roi_area = int Function( + ffi.Pointer player, + int x, + int y, + int width, + int height, +); + +typedef _c_player_set_display_visible = ffi.Int32 Function( + ffi.Pointer player, + ffi.Uint8 visible, +); + +typedef _dart_player_set_display_visible = int Function( + ffi.Pointer player, + int visible, +); + +typedef _c_player_is_display_visible = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer visible, +); + +typedef _dart_player_is_display_visible = int Function( + ffi.Pointer player, + ffi.Pointer visible, +); + +typedef _c_player_set_display_rotation = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 rotation, +); + +typedef _dart_player_set_display_rotation = int Function( + ffi.Pointer player, + int rotation, +); + +typedef _c_player_get_display_rotation = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer rotation, +); + +typedef _dart_player_get_display_rotation = int Function( + ffi.Pointer player, + ffi.Pointer rotation, +); + +typedef _c_player_get_content_info = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 key, + ffi.Pointer> value, +); + +typedef _dart_player_get_content_info = int Function( + ffi.Pointer player, + int key, + ffi.Pointer> value, +); + +typedef _c_player_get_codec_info = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer> audio_codec, + ffi.Pointer> video_codec, +); + +typedef _dart_player_get_codec_info = int Function( + ffi.Pointer player, + ffi.Pointer> audio_codec, + ffi.Pointer> video_codec, +); + +typedef _c_player_get_audio_stream_info = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer sample_rate, + ffi.Pointer channel, + ffi.Pointer bit_rate, +); + +typedef _dart_player_get_audio_stream_info = int Function( + ffi.Pointer player, + ffi.Pointer sample_rate, + ffi.Pointer channel, + ffi.Pointer bit_rate, +); + +typedef _c_player_get_video_stream_info = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer fps, + ffi.Pointer bit_rate, +); + +typedef _dart_player_get_video_stream_info = int Function( + ffi.Pointer player, + ffi.Pointer fps, + ffi.Pointer bit_rate, +); + +typedef _c_player_get_video_size = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _dart_player_get_video_size = int Function( + ffi.Pointer player, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _c_player_get_album_art = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer> album_art, + ffi.Pointer size, +); + +typedef _dart_player_get_album_art = int Function( + ffi.Pointer player, + ffi.Pointer> album_art, + ffi.Pointer size, +); + +typedef _c_player_get_duration = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer duration, +); + +typedef _dart_player_get_duration = int Function( + ffi.Pointer player, + ffi.Pointer duration, +); + +typedef _c_player_audio_effect_get_equalizer_bands_count = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer count, +); + +typedef _dart_player_audio_effect_get_equalizer_bands_count = int Function( + ffi.Pointer player, + ffi.Pointer count, +); + +typedef _c_player_audio_effect_set_equalizer_band_level = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 index, + ffi.Int32 level, +); + +typedef _dart_player_audio_effect_set_equalizer_band_level = int Function( + ffi.Pointer player, + int index, + int level, +); + +typedef _c_player_audio_effect_get_equalizer_band_level = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 index, + ffi.Pointer level, +); + +typedef _dart_player_audio_effect_get_equalizer_band_level = int Function( + ffi.Pointer player, + int index, + ffi.Pointer level, +); + +typedef _c_player_audio_effect_set_equalizer_all_bands = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer band_levels, + ffi.Int32 length, +); + +typedef _dart_player_audio_effect_set_equalizer_all_bands = int Function( + ffi.Pointer player, + ffi.Pointer band_levels, + int length, +); + +typedef _c_player_audio_effect_get_equalizer_level_range = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _dart_player_audio_effect_get_equalizer_level_range = int Function( + ffi.Pointer player, + ffi.Pointer min, + ffi.Pointer max, +); + +typedef _c_player_audio_effect_get_equalizer_band_frequency = ffi.Int32 + Function( + ffi.Pointer player, + ffi.Int32 index, + ffi.Pointer frequency, +); + +typedef _dart_player_audio_effect_get_equalizer_band_frequency = int Function( + ffi.Pointer player, + int index, + ffi.Pointer frequency, +); + +typedef _c_player_audio_effect_get_equalizer_band_frequency_range = ffi.Int32 + Function( + ffi.Pointer player, + ffi.Int32 index, + ffi.Pointer range, +); + +typedef _dart_player_audio_effect_get_equalizer_band_frequency_range = int + Function( + ffi.Pointer player, + int index, + ffi.Pointer range, +); + +typedef _c_player_audio_effect_equalizer_clear = ffi.Int32 Function( + ffi.Pointer player, +); + +typedef _dart_player_audio_effect_equalizer_clear = int Function( + ffi.Pointer player, +); + +typedef _c_player_audio_effect_equalizer_is_available = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer available, +); + +typedef _dart_player_audio_effect_equalizer_is_available = int Function( + ffi.Pointer player, + ffi.Pointer available, +); + +typedef player_video_captured_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_player_capture_video = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_player_capture_video = int Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_player_set_streaming_cookie = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer cookie, + ffi.Int32 size, +); + +typedef _dart_player_set_streaming_cookie = int Function( + ffi.Pointer player, + ffi.Pointer cookie, + int size, +); + +typedef _c_player_set_streaming_user_agent = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer user_agent, + ffi.Int32 size, +); + +typedef _dart_player_set_streaming_user_agent = int Function( + ffi.Pointer player, + ffi.Pointer user_agent, + int size, +); + +typedef _c_player_get_streaming_download_progress = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer start, + ffi.Pointer current, +); + +typedef _dart_player_get_streaming_download_progress = int Function( + ffi.Pointer player, + ffi.Pointer start, + ffi.Pointer current, +); + +typedef player_completed_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef _c_player_set_completed_cb = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_player_set_completed_cb = int Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_player_unset_completed_cb = ffi.Int32 Function( + ffi.Pointer player, +); + +typedef _dart_player_unset_completed_cb = int Function( + ffi.Pointer player, +); + +typedef player_interrupted_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_player_set_interrupted_cb = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_player_set_interrupted_cb = int Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_player_unset_interrupted_cb = ffi.Int32 Function( + ffi.Pointer player, +); + +typedef _dart_player_unset_interrupted_cb = int Function( + ffi.Pointer player, +); + +typedef player_error_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_player_set_error_cb = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_player_set_error_cb = int Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_player_unset_error_cb = ffi.Int32 Function( + ffi.Pointer player, +); + +typedef _dart_player_unset_error_cb = int Function( + ffi.Pointer player, +); + +typedef player_buffering_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_player_set_buffering_cb = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_player_set_buffering_cb = int Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_player_unset_buffering_cb = ffi.Int32 Function( + ffi.Pointer player, +); + +typedef _dart_player_unset_buffering_cb = int Function( + ffi.Pointer player, +); + +typedef _c_player_set_progressive_download_path = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer path, +); + +typedef _dart_player_set_progressive_download_path = int Function( + ffi.Pointer player, + ffi.Pointer path, +); + +typedef _c_player_get_progressive_download_status = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer current, + ffi.Pointer total_size, +); + +typedef _dart_player_get_progressive_download_status = int Function( + ffi.Pointer player, + ffi.Pointer current, + ffi.Pointer total_size, +); + +typedef player_pd_message_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_player_set_progressive_download_message_cb = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_player_set_progressive_download_message_cb = int Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_player_unset_progressive_download_message_cb = ffi.Int32 Function( + ffi.Pointer player, +); + +typedef _dart_player_unset_progressive_download_message_cb = int Function( + ffi.Pointer player, +); + +typedef _c_player_set_playback_rate = ffi.Int32 Function( + ffi.Pointer player, + ffi.Float rate, +); + +typedef _dart_player_set_playback_rate = int Function( + ffi.Pointer player, + double rate, +); + +typedef _c_player_set_subtitle_path = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer path, +); + +typedef _dart_player_set_subtitle_path = int Function( + ffi.Pointer player, + ffi.Pointer path, +); + +typedef player_subtitle_updated_cb = ffi.Void Function( + ffi.Uint64, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_player_set_subtitle_updated_cb = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_player_set_subtitle_updated_cb = int Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_player_unset_subtitle_updated_cb = ffi.Int32 Function( + ffi.Pointer player, +); + +typedef _dart_player_unset_subtitle_updated_cb = int Function( + ffi.Pointer player, +); + +typedef _c_player_set_subtitle_position_offset = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 millisecond, +); + +typedef _dart_player_set_subtitle_position_offset = int Function( + ffi.Pointer player, + int millisecond, +); + +typedef player_video_stream_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_player_set_video_stream_changed_cb = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_player_set_video_stream_changed_cb = int Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_player_unset_video_stream_changed_cb = ffi.Int32 Function( + ffi.Pointer player, +); + +typedef _dart_player_unset_video_stream_changed_cb = int Function( + ffi.Pointer player, +); + +typedef _c_player_get_current_track = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, + ffi.Pointer index, +); + +typedef _dart_player_get_current_track = int Function( + ffi.Pointer player, + int type, + ffi.Pointer index, +); + +typedef _c_player_get_track_language_code = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, + ffi.Int32 index, + ffi.Pointer> code, +); + +typedef _dart_player_get_track_language_code = int Function( + ffi.Pointer player, + int type, + int index, + ffi.Pointer> code, +); + +typedef _c_player_get_track_count = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, + ffi.Pointer count, +); + +typedef _dart_player_get_track_count = int Function( + ffi.Pointer player, + int type, + ffi.Pointer count, +); + +typedef _c_player_select_track = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 type, + ffi.Int32 index, +); + +typedef _dart_player_select_track = int Function( + ffi.Pointer player, + int type, + int index, +); + +typedef player_adaptive_variant_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_player_foreach_adaptive_variant = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_player_foreach_adaptive_variant = int Function( + ffi.Pointer player, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_player_set_max_adaptive_variant_limit = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 bandwidth, + ffi.Int32 width, + ffi.Int32 height, +); + +typedef _dart_player_set_max_adaptive_variant_limit = int Function( + ffi.Pointer player, + int bandwidth, + int width, + int height, +); + +typedef _c_player_get_max_adaptive_variant_limit = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer bandwidth, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _dart_player_get_max_adaptive_variant_limit = int Function( + ffi.Pointer player, + ffi.Pointer bandwidth, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _c_player_set_audio_only = ffi.Int32 Function( + ffi.Pointer player, + ffi.Uint8 audio_only, +); + +typedef _dart_player_set_audio_only = int Function( + ffi.Pointer player, + int audio_only, +); + +typedef _c_player_is_audio_only = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer audio_only, +); + +typedef _dart_player_is_audio_only = int Function( + ffi.Pointer player, + ffi.Pointer audio_only, +); + +typedef _c_player_set_streaming_buffering_time = ffi.Int32 Function( + ffi.Pointer player, + ffi.Int32 prebuffer_ms, + ffi.Int32 rebuffer_ms, +); + +typedef _dart_player_set_streaming_buffering_time = int Function( + ffi.Pointer player, + int prebuffer_ms, + int rebuffer_ms, +); + +typedef _c_player_get_streaming_buffering_time = ffi.Int32 Function( + ffi.Pointer player, + ffi.Pointer prebuffer_ms, + ffi.Pointer rebuffer_ms, +); + +typedef _dart_player_get_streaming_buffering_time = int Function( + ffi.Pointer player, + ffi.Pointer prebuffer_ms, + ffi.Pointer rebuffer_ms, +); + +typedef _c_radio_create = ffi.Int32 Function( + ffi.Pointer> radio, +); + +typedef _dart_radio_create = int Function( + ffi.Pointer> radio, +); + +typedef _c_radio_destroy = ffi.Int32 Function( + ffi.Pointer radio, +); + +typedef _dart_radio_destroy = int Function( + ffi.Pointer radio, +); + +typedef _c_radio_get_state = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Pointer state, +); + +typedef _dart_radio_get_state = int Function( + ffi.Pointer radio, + ffi.Pointer state, +); + +typedef _c_radio_start = ffi.Int32 Function( + ffi.Pointer radio, +); + +typedef _dart_radio_start = int Function( + ffi.Pointer radio, +); + +typedef _c_radio_stop = ffi.Int32 Function( + ffi.Pointer radio, +); + +typedef _dart_radio_stop = int Function( + ffi.Pointer radio, +); + +typedef radio_seek_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_radio_seek_up = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_radio_seek_up = int Function( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_radio_seek_down = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_radio_seek_down = int Function( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_radio_set_frequency = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Int32 frequency, +); + +typedef _dart_radio_set_frequency = int Function( + ffi.Pointer radio, + int frequency, +); + +typedef _c_radio_get_frequency = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Pointer frequency, +); + +typedef _dart_radio_get_frequency = int Function( + ffi.Pointer radio, + ffi.Pointer frequency, +); + +typedef _c_radio_get_signal_strength = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Pointer strength, +); + +typedef _dart_radio_get_signal_strength = int Function( + ffi.Pointer radio, + ffi.Pointer strength, +); + +typedef radio_scan_updated_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_radio_scan_start = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_radio_scan_start = int Function( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef radio_scan_stopped_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef _c_radio_scan_stop = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_radio_scan_stop = int Function( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_radio_set_mute = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Uint8 muted, +); + +typedef _dart_radio_set_mute = int Function( + ffi.Pointer radio, + int muted, +); + +typedef _c_radio_is_muted = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Pointer muted, +); + +typedef _dart_radio_is_muted = int Function( + ffi.Pointer radio, + ffi.Pointer muted, +); + +typedef radio_scan_completed_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef _c_radio_set_scan_completed_cb = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_radio_set_scan_completed_cb = int Function( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_radio_unset_scan_completed_cb = ffi.Int32 Function( + ffi.Pointer radio, +); + +typedef _dart_radio_unset_scan_completed_cb = int Function( + ffi.Pointer radio, +); + +typedef radio_interrupted_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_radio_set_interrupted_cb = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_radio_set_interrupted_cb = int Function( + ffi.Pointer radio, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_radio_unset_interrupted_cb = ffi.Int32 Function( + ffi.Pointer radio, +); + +typedef _dart_radio_unset_interrupted_cb = int Function( + ffi.Pointer radio, +); + +typedef _c_radio_get_frequency_range = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Pointer min_freq, + ffi.Pointer max_freq, +); + +typedef _dart_radio_get_frequency_range = int Function( + ffi.Pointer radio, + ffi.Pointer min_freq, + ffi.Pointer max_freq, +); + +typedef _c_radio_get_channel_spacing = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Pointer channel_spacing, +); + +typedef _dart_radio_get_channel_spacing = int Function( + ffi.Pointer radio, + ffi.Pointer channel_spacing, +); + +typedef _c_radio_set_volume = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Float volume, +); + +typedef _dart_radio_set_volume = int Function( + ffi.Pointer radio, + double volume, +); + +typedef _c_radio_get_volume = ffi.Int32 Function( + ffi.Pointer radio, + ffi.Pointer volume, +); + +typedef _dart_radio_get_volume = int Function( + ffi.Pointer radio, + ffi.Pointer volume, +); + +typedef _c_recorder_create_videorecorder = ffi.Int32 Function( + ffi.Pointer camera, + ffi.Pointer> recorder, +); + +typedef _dart_recorder_create_videorecorder = int Function( + ffi.Pointer camera, + ffi.Pointer> recorder, +); + +typedef _c_recorder_create_audiorecorder = ffi.Int32 Function( + ffi.Pointer> recorder, +); + +typedef _dart_recorder_create_audiorecorder = int Function( + ffi.Pointer> recorder, +); + +typedef _c_recorder_destroy = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_destroy = int Function( + ffi.Pointer recorder, +); + +typedef _c_recorder_prepare = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_prepare = int Function( + ffi.Pointer recorder, +); + +typedef _c_recorder_unprepare = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_unprepare = int Function( + ffi.Pointer recorder, +); + +typedef _c_recorder_start = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_start = int Function( + ffi.Pointer recorder, +); + +typedef _c_recorder_pause = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_pause = int Function( + ffi.Pointer recorder, +); + +typedef _c_recorder_commit = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_commit = int Function( + ffi.Pointer recorder, +); + +typedef _c_recorder_cancel = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_cancel = int Function( + ffi.Pointer recorder, +); + +typedef _c_recorder_get_state = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer state, +); + +typedef _dart_recorder_get_state = int Function( + ffi.Pointer recorder, + ffi.Pointer state, +); + +typedef _c_recorder_get_audio_level = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer dB, +); + +typedef _dart_recorder_get_audio_level = int Function( + ffi.Pointer recorder, + ffi.Pointer dB, +); + +typedef _c_recorder_set_filename = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer path, +); + +typedef _dart_recorder_set_filename = int Function( + ffi.Pointer recorder, + ffi.Pointer path, +); + +typedef _c_recorder_get_filename = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> path, +); + +typedef _dart_recorder_get_filename = int Function( + ffi.Pointer recorder, + ffi.Pointer> path, +); + +typedef _c_recorder_set_file_format = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 format, +); + +typedef _dart_recorder_set_file_format = int Function( + ffi.Pointer recorder, + int format, +); + +typedef _c_recorder_get_file_format = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer format, +); + +typedef _dart_recorder_get_file_format = int Function( + ffi.Pointer recorder, + ffi.Pointer format, +); + +typedef _c_recorder_set_sound_stream_info = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer stream_info, +); + +typedef _dart_recorder_set_sound_stream_info = int Function( + ffi.Pointer recorder, + ffi.Pointer stream_info, +); + +typedef recorder_supported_file_format_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_recorder_foreach_supported_file_format = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_recorder_foreach_supported_file_format = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_recorder_set_audio_encoder = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 codec, +); + +typedef _dart_recorder_set_audio_encoder = int Function( + ffi.Pointer recorder, + int codec, +); + +typedef _c_recorder_get_audio_encoder = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer codec, +); + +typedef _dart_recorder_get_audio_encoder = int Function( + ffi.Pointer recorder, + ffi.Pointer codec, +); + +typedef recorder_supported_audio_encoder_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_recorder_foreach_supported_audio_encoder = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_recorder_foreach_supported_audio_encoder = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_recorder_set_video_resolution = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 width, + ffi.Int32 height, +); + +typedef _dart_recorder_set_video_resolution = int Function( + ffi.Pointer recorder, + int width, + int height, +); + +typedef _c_recorder_get_video_resolution = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _dart_recorder_get_video_resolution = int Function( + ffi.Pointer recorder, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef recorder_supported_video_resolution_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_recorder_foreach_supported_video_resolution = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> + foreach_cb, + ffi.Pointer user_data, +); + +typedef _dart_recorder_foreach_supported_video_resolution = int Function( + ffi.Pointer recorder, + ffi.Pointer> + foreach_cb, + ffi.Pointer user_data, +); + +typedef _c_recorder_set_video_encoder = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 codec, +); + +typedef _dart_recorder_set_video_encoder = int Function( + ffi.Pointer recorder, + int codec, +); + +typedef _c_recorder_get_video_encoder = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer codec, +); + +typedef _dart_recorder_get_video_encoder = int Function( + ffi.Pointer recorder, + ffi.Pointer codec, +); + +typedef recorder_supported_video_encoder_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_recorder_foreach_supported_video_encoder = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_recorder_foreach_supported_video_encoder = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef recorder_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_recorder_set_state_changed_cb = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_recorder_set_state_changed_cb = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_recorder_unset_state_changed_cb = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_unset_state_changed_cb = int Function( + ffi.Pointer recorder, +); + +typedef recorder_interrupted_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_recorder_set_interrupted_cb = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_recorder_set_interrupted_cb = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_recorder_unset_interrupted_cb = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_unset_interrupted_cb = int Function( + ffi.Pointer recorder, +); + +typedef recorder_interrupt_started_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_recorder_set_interrupt_started_cb = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_recorder_set_interrupt_started_cb = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_recorder_unset_interrupt_started_cb = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_unset_interrupt_started_cb = int Function( + ffi.Pointer recorder, +); + +typedef recorder_audio_stream_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_recorder_set_audio_stream_cb = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_recorder_set_audio_stream_cb = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_recorder_unset_audio_stream_cb = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_unset_audio_stream_cb = int Function( + ffi.Pointer recorder, +); + +typedef recorder_muxed_stream_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Uint64, + ffi.Pointer, +); + +typedef _c_recorder_set_muxed_stream_cb = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_recorder_set_muxed_stream_cb = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_recorder_unset_muxed_stream_cb = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_unset_muxed_stream_cb = int Function( + ffi.Pointer recorder, +); + +typedef recorder_recording_status_cb = ffi.Void Function( + ffi.Uint64, + ffi.Uint64, + ffi.Pointer, +); + +typedef _c_recorder_set_recording_status_cb = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_recorder_set_recording_status_cb = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_recorder_unset_recording_status_cb = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_unset_recording_status_cb = int Function( + ffi.Pointer recorder, +); + +typedef recorder_recording_limit_reached_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_recorder_set_recording_limit_reached_cb = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_recorder_set_recording_limit_reached_cb = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_recorder_unset_recording_limit_reached_cb = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_unset_recording_limit_reached_cb = int Function( + ffi.Pointer recorder, +); + +typedef recorder_error_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_recorder_set_error_cb = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_recorder_set_error_cb = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_recorder_unset_error_cb = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_unset_error_cb = int Function( + ffi.Pointer recorder, +); + +typedef _c_recorder_get_device_state = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer state, +); + +typedef _dart_recorder_get_device_state = int Function( + int type, + ffi.Pointer state, +); + +typedef recorder_device_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_recorder_add_device_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer cb_id, +); + +typedef _dart_recorder_add_device_state_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer cb_id, +); + +typedef _c_recorder_remove_device_state_changed_cb = ffi.Int32 Function( + ffi.Int32 cb_id, +); + +typedef _dart_recorder_remove_device_state_changed_cb = int Function( + int cb_id, +); + +typedef _c_recorder_attr_set_size_limit = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 kbyte, +); + +typedef _dart_recorder_attr_set_size_limit = int Function( + ffi.Pointer recorder, + int kbyte, +); + +typedef _c_recorder_attr_get_size_limit = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer kbyte, +); + +typedef _dart_recorder_attr_get_size_limit = int Function( + ffi.Pointer recorder, + ffi.Pointer kbyte, +); + +typedef _c_recorder_attr_set_time_limit = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 second, +); + +typedef _dart_recorder_attr_set_time_limit = int Function( + ffi.Pointer recorder, + int second, +); + +typedef _c_recorder_attr_get_time_limit = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer second, +); + +typedef _dart_recorder_attr_get_time_limit = int Function( + ffi.Pointer recorder, + ffi.Pointer second, +); + +typedef _c_recorder_attr_set_audio_device = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 device, +); + +typedef _dart_recorder_attr_set_audio_device = int Function( + ffi.Pointer recorder, + int device, +); + +typedef _c_recorder_attr_get_audio_device = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer device, +); + +typedef _dart_recorder_attr_get_audio_device = int Function( + ffi.Pointer recorder, + ffi.Pointer device, +); + +typedef _c_recorder_attr_set_audio_samplerate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 samplerate, +); + +typedef _dart_recorder_attr_set_audio_samplerate = int Function( + ffi.Pointer recorder, + int samplerate, +); + +typedef _c_recorder_attr_get_audio_samplerate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer samplerate, +); + +typedef _dart_recorder_attr_get_audio_samplerate = int Function( + ffi.Pointer recorder, + ffi.Pointer samplerate, +); + +typedef _c_recorder_attr_set_audio_encoder_bitrate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 bitrate, +); + +typedef _dart_recorder_attr_set_audio_encoder_bitrate = int Function( + ffi.Pointer recorder, + int bitrate, +); + +typedef _c_recorder_attr_set_video_encoder_bitrate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 bitrate, +); + +typedef _dart_recorder_attr_set_video_encoder_bitrate = int Function( + ffi.Pointer recorder, + int bitrate, +); + +typedef _c_recorder_attr_get_audio_encoder_bitrate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer bitrate, +); + +typedef _dart_recorder_attr_get_audio_encoder_bitrate = int Function( + ffi.Pointer recorder, + ffi.Pointer bitrate, +); + +typedef _c_recorder_attr_get_video_encoder_bitrate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer bitrate, +); + +typedef _dart_recorder_attr_get_video_encoder_bitrate = int Function( + ffi.Pointer recorder, + ffi.Pointer bitrate, +); + +typedef _c_recorder_attr_set_mute = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Uint8 enable, +); + +typedef _dart_recorder_attr_set_mute = int Function( + ffi.Pointer recorder, + int enable, +); + +typedef _c_recorder_attr_is_muted = ffi.Uint8 Function( + ffi.Pointer recorder, +); + +typedef _dart_recorder_attr_is_muted = int Function( + ffi.Pointer recorder, +); + +typedef _c_recorder_attr_set_recording_motion_rate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Double rate, +); + +typedef _dart_recorder_attr_set_recording_motion_rate = int Function( + ffi.Pointer recorder, + double rate, +); + +typedef _c_recorder_attr_get_recording_motion_rate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer rate, +); + +typedef _dart_recorder_attr_get_recording_motion_rate = int Function( + ffi.Pointer recorder, + ffi.Pointer rate, +); + +typedef _c_recorder_attr_set_audio_channel = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 channel_count, +); + +typedef _dart_recorder_attr_set_audio_channel = int Function( + ffi.Pointer recorder, + int channel_count, +); + +typedef _c_recorder_attr_get_audio_channel = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer channel_count, +); + +typedef _dart_recorder_attr_get_audio_channel = int Function( + ffi.Pointer recorder, + ffi.Pointer channel_count, +); + +typedef _c_recorder_attr_set_orientation_tag = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 orientation, +); + +typedef _dart_recorder_attr_set_orientation_tag = int Function( + ffi.Pointer recorder, + int orientation, +); + +typedef _c_recorder_attr_get_orientation_tag = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer orientation, +); + +typedef _dart_recorder_attr_get_orientation_tag = int Function( + ffi.Pointer recorder, + ffi.Pointer orientation, +); + +typedef _c_sound_pool_create = ffi.Int32 Function( + ffi.Pointer> pool, +); + +typedef _dart_sound_pool_create = int Function( + ffi.Pointer> pool, +); + +typedef _c_sound_pool_destroy = ffi.Int32 Function( + ffi.Pointer pool, +); + +typedef _dart_sound_pool_destroy = int Function( + ffi.Pointer pool, +); + +typedef _c_sound_pool_load_source_from_file = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Pointer file_name, + ffi.Pointer tag, +); + +typedef _dart_sound_pool_load_source_from_file = int Function( + ffi.Pointer pool, + ffi.Pointer file_name, + ffi.Pointer tag, +); + +typedef _c_sound_pool_unload_source = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Pointer tag, +); + +typedef _dart_sound_pool_unload_source = int Function( + ffi.Pointer pool, + ffi.Pointer tag, +); + +typedef _c_sound_pool_activate = ffi.Int32 Function( + ffi.Pointer pool, +); + +typedef _dart_sound_pool_activate = int Function( + ffi.Pointer pool, +); + +typedef _c_sound_pool_deactivate = ffi.Int32 Function( + ffi.Pointer pool, +); + +typedef _dart_sound_pool_deactivate = int Function( + ffi.Pointer pool, +); + +typedef _c_sound_pool_set_volume = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Float volume, +); + +typedef _dart_sound_pool_set_volume = int Function( + ffi.Pointer pool, + double volume, +); + +typedef _c_sound_pool_get_volume = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Pointer volume, +); + +typedef _dart_sound_pool_get_volume = int Function( + ffi.Pointer pool, + ffi.Pointer volume, +); + +typedef _c_sound_pool_get_state = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Pointer state, +); + +typedef _dart_sound_pool_get_state = int Function( + ffi.Pointer pool, + ffi.Pointer state, +); + +typedef sound_pool_state_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_sound_pool_set_state_changed_cb = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_sound_pool_set_state_changed_cb = int Function( + ffi.Pointer pool, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_sound_pool_unset_state_changed_cb = ffi.Int32 Function( + ffi.Pointer pool, +); + +typedef _dart_sound_pool_unset_state_changed_cb = int Function( + ffi.Pointer pool, +); + +typedef sound_pool_stream_state_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Uint32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_sound_pool_stream_play = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Pointer tag, + ffi.Uint32 loop, + ffi.Float volume, + ffi.Uint32 priority, + ffi.Int32 priority_policy, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _dart_sound_pool_stream_play = int Function( + ffi.Pointer pool, + ffi.Pointer tag, + int loop, + double volume, + int priority, + int priority_policy, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _c_sound_pool_stream_pause = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Uint32 id, +); + +typedef _dart_sound_pool_stream_pause = int Function( + ffi.Pointer pool, + int id, +); + +typedef _c_sound_pool_stream_resume = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Uint32 id, +); + +typedef _dart_sound_pool_stream_resume = int Function( + ffi.Pointer pool, + int id, +); + +typedef _c_sound_pool_stream_stop = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Uint32 id, +); + +typedef _dart_sound_pool_stream_stop = int Function( + ffi.Pointer pool, + int id, +); + +typedef _c_sound_pool_stream_set_volume = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Uint32 id, + ffi.Float volume, +); + +typedef _dart_sound_pool_stream_set_volume = int Function( + ffi.Pointer pool, + int id, + double volume, +); + +typedef _c_sound_pool_stream_get_volume = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Uint32 id, + ffi.Pointer volume, +); + +typedef _dart_sound_pool_stream_get_volume = int Function( + ffi.Pointer pool, + int id, + ffi.Pointer volume, +); + +typedef _c_sound_pool_stream_set_priority = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Uint32 id, + ffi.Uint32 priority, +); + +typedef _dart_sound_pool_stream_set_priority = int Function( + ffi.Pointer pool, + int id, + int priority, +); + +typedef _c_sound_pool_stream_get_priority = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Uint32 id, + ffi.Pointer priority, +); + +typedef _dart_sound_pool_stream_get_priority = int Function( + ffi.Pointer pool, + int id, + ffi.Pointer priority, +); + +typedef _c_sound_pool_stream_get_state = ffi.Int32 Function( + ffi.Pointer pool, + ffi.Uint32 id, + ffi.Pointer state, +); + +typedef _dart_sound_pool_stream_get_state = int Function( + ffi.Pointer pool, + int id, + ffi.Pointer state, +); + +typedef _c_streamrecorder_create = ffi.Int32 Function( + ffi.Pointer> recorder, +); + +typedef _dart_streamrecorder_create = int Function( + ffi.Pointer> recorder, +); + +typedef _c_streamrecorder_destroy = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_streamrecorder_destroy = int Function( + ffi.Pointer recorder, +); + +typedef _c_streamrecorder_prepare = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_streamrecorder_prepare = int Function( + ffi.Pointer recorder, +); + +typedef _c_streamrecorder_unprepare = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_streamrecorder_unprepare = int Function( + ffi.Pointer recorder, +); + +typedef _c_streamrecorder_start = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_streamrecorder_start = int Function( + ffi.Pointer recorder, +); + +typedef _c_streamrecorder_pause = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_streamrecorder_pause = int Function( + ffi.Pointer recorder, +); + +typedef _c_streamrecorder_commit = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_streamrecorder_commit = int Function( + ffi.Pointer recorder, +); + +typedef _c_streamrecorder_cancel = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_streamrecorder_cancel = int Function( + ffi.Pointer recorder, +); + +typedef _c_streamrecorder_push_stream_buffer = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer inbuf, +); + +typedef _dart_streamrecorder_push_stream_buffer = int Function( + ffi.Pointer recorder, + ffi.Pointer inbuf, +); + +typedef _c_streamrecorder_enable_source_buffer = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 type, +); + +typedef _dart_streamrecorder_enable_source_buffer = int Function( + ffi.Pointer recorder, + int type, +); + +typedef _c_streamrecorder_get_state = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer state, +); + +typedef _dart_streamrecorder_get_state = int Function( + ffi.Pointer recorder, + ffi.Pointer state, +); + +typedef _c_streamrecorder_set_filename = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer path, +); + +typedef _dart_streamrecorder_set_filename = int Function( + ffi.Pointer recorder, + ffi.Pointer path, +); + +typedef _c_streamrecorder_get_filename = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> path, +); + +typedef _dart_streamrecorder_get_filename = int Function( + ffi.Pointer recorder, + ffi.Pointer> path, +); + +typedef _c_streamrecorder_set_file_format = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 format, +); + +typedef _dart_streamrecorder_set_file_format = int Function( + ffi.Pointer recorder, + int format, +); + +typedef _c_streamrecorder_get_file_format = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer format, +); + +typedef _dart_streamrecorder_get_file_format = int Function( + ffi.Pointer recorder, + ffi.Pointer format, +); + +typedef _c_streamrecorder_set_audio_encoder = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 codec, +); + +typedef _dart_streamrecorder_set_audio_encoder = int Function( + ffi.Pointer recorder, + int codec, +); + +typedef _c_streamrecorder_get_audio_encoder = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer codec, +); + +typedef _dart_streamrecorder_get_audio_encoder = int Function( + ffi.Pointer recorder, + ffi.Pointer codec, +); + +typedef _c_streamrecorder_set_video_resolution = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 width, + ffi.Int32 height, +); + +typedef _dart_streamrecorder_set_video_resolution = int Function( + ffi.Pointer recorder, + int width, + int height, +); + +typedef _c_streamrecorder_get_video_resolution = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _dart_streamrecorder_get_video_resolution = int Function( + ffi.Pointer recorder, + ffi.Pointer width, + ffi.Pointer height, +); + +typedef _c_streamrecorder_set_video_encoder = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 codec, +); + +typedef _dart_streamrecorder_set_video_encoder = int Function( + ffi.Pointer recorder, + int codec, +); + +typedef _c_streamrecorder_get_video_encoder = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer codec, +); + +typedef _dart_streamrecorder_get_video_encoder = int Function( + ffi.Pointer recorder, + ffi.Pointer codec, +); + +typedef _c_streamrecorder_set_video_framerate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 framerate, +); + +typedef _dart_streamrecorder_set_video_framerate = int Function( + ffi.Pointer recorder, + int framerate, +); + +typedef _c_streamrecorder_get_video_framerate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer framerate, +); + +typedef _dart_streamrecorder_get_video_framerate = int Function( + ffi.Pointer recorder, + ffi.Pointer framerate, +); + +typedef _c_streamrecorder_set_video_source_format = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 format, +); + +typedef _dart_streamrecorder_set_video_source_format = int Function( + ffi.Pointer recorder, + int format, +); + +typedef _c_streamrecorder_get_video_source_format = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer format, +); + +typedef _dart_streamrecorder_get_video_source_format = int Function( + ffi.Pointer recorder, + ffi.Pointer format, +); + +typedef _c_streamrecorder_set_recording_limit = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 type, + ffi.Int32 limit, +); + +typedef _dart_streamrecorder_set_recording_limit = int Function( + ffi.Pointer recorder, + int type, + int limit, +); + +typedef _c_streamrecorder_get_recording_limit = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 type, + ffi.Pointer limit, +); + +typedef _dart_streamrecorder_get_recording_limit = int Function( + ffi.Pointer recorder, + int type, + ffi.Pointer limit, +); + +typedef _c_streamrecorder_set_audio_samplerate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 samplerate, +); + +typedef _dart_streamrecorder_set_audio_samplerate = int Function( + ffi.Pointer recorder, + int samplerate, +); + +typedef _c_streamrecorder_get_audio_samplerate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer samplerate, +); + +typedef _dart_streamrecorder_get_audio_samplerate = int Function( + ffi.Pointer recorder, + ffi.Pointer samplerate, +); + +typedef _c_streamrecorder_set_audio_encoder_bitrate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 bitrate, +); + +typedef _dart_streamrecorder_set_audio_encoder_bitrate = int Function( + ffi.Pointer recorder, + int bitrate, +); + +typedef _c_streamrecorder_set_video_encoder_bitrate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 bitrate, +); + +typedef _dart_streamrecorder_set_video_encoder_bitrate = int Function( + ffi.Pointer recorder, + int bitrate, +); + +typedef _c_streamrecorder_get_audio_encoder_bitrate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer bitrate, +); + +typedef _dart_streamrecorder_get_audio_encoder_bitrate = int Function( + ffi.Pointer recorder, + ffi.Pointer bitrate, +); + +typedef _c_streamrecorder_get_video_encoder_bitrate = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer bitrate, +); + +typedef _dart_streamrecorder_get_video_encoder_bitrate = int Function( + ffi.Pointer recorder, + ffi.Pointer bitrate, +); + +typedef _c_streamrecorder_set_audio_channel = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Int32 channel_count, +); + +typedef _dart_streamrecorder_set_audio_channel = int Function( + ffi.Pointer recorder, + int channel_count, +); + +typedef _c_streamrecorder_get_audio_channel = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer channel_count, +); + +typedef _dart_streamrecorder_get_audio_channel = int Function( + ffi.Pointer recorder, + ffi.Pointer channel_count, +); + +typedef streamrecorder_supported_file_format_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_streamrecorder_foreach_supported_file_format = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_streamrecorder_foreach_supported_file_format = int Function( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef streamrecorder_supported_audio_encoder_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_streamrecorder_foreach_supported_audio_encoder = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_streamrecorder_foreach_supported_audio_encoder = int Function( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef streamrecorder_supported_video_encoder_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_streamrecorder_foreach_supported_video_encoder = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_streamrecorder_foreach_supported_video_encoder = int Function( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef streamrecorder_supported_video_resolution_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_streamrecorder_foreach_supported_video_resolution = ffi.Int32 + Function( + ffi.Pointer recorder, + ffi.Pointer> + foreach_cb, + ffi.Pointer user_data, +); + +typedef _dart_streamrecorder_foreach_supported_video_resolution = int Function( + ffi.Pointer recorder, + ffi.Pointer> + foreach_cb, + ffi.Pointer user_data, +); + +typedef streamrecorder_notify_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_streamrecorder_set_notify_cb = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_streamrecorder_set_notify_cb = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_streamrecorder_unset_notify_cb = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_streamrecorder_unset_notify_cb = int Function( + ffi.Pointer recorder, +); + +typedef streamrecorder_recording_status_cb = ffi.Void Function( + ffi.Uint64, + ffi.Uint64, + ffi.Pointer, +); + +typedef _c_streamrecorder_set_recording_status_cb = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_streamrecorder_set_recording_status_cb = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_streamrecorder_unset_recording_status_cb = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_streamrecorder_unset_recording_status_cb = int Function( + ffi.Pointer recorder, +); + +typedef streamrecorder_recording_limit_reached_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_streamrecorder_set_recording_limit_reached_cb = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_streamrecorder_set_recording_limit_reached_cb = int Function( + ffi.Pointer recorder, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_streamrecorder_unset_recording_limit_reached_cb = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_streamrecorder_unset_recording_limit_reached_cb = int Function( + ffi.Pointer recorder, +); + +typedef streamrecorder_error_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_streamrecorder_set_error_cb = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_streamrecorder_set_error_cb = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_streamrecorder_unset_error_cb = ffi.Int32 Function( + ffi.Pointer recorder, +); + +typedef _dart_streamrecorder_unset_error_cb = int Function( + ffi.Pointer recorder, +); + +typedef streamrecorder_consume_completed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_streamrecorder_set_buffer_consume_completed_cb = ffi.Int32 Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_streamrecorder_set_buffer_consume_completed_cb = int Function( + ffi.Pointer recorder, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_streamrecorder_unset_buffer_consume_completed_cb = ffi.Int32 + Function( + ffi.Pointer recorder, +); + +typedef _dart_streamrecorder_unset_buffer_consume_completed_cb = int Function( + ffi.Pointer recorder, +); + +typedef _c_thumbnail_util_create = ffi.Int32 Function( + ffi.Pointer> thumb, +); + +typedef _dart_thumbnail_util_create = int Function( + ffi.Pointer> thumb, +); + +typedef thumbnail_extracted_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_thumbnail_util_extract = ffi.Int32 Function( + ffi.Pointer thumb, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer> request_id, +); + +typedef _dart_thumbnail_util_extract = int Function( + ffi.Pointer thumb, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer> request_id, +); + +typedef _c_thumbnail_util_set_path = ffi.Int32 Function( + ffi.Pointer thumb, + ffi.Pointer path, +); + +typedef _dart_thumbnail_util_set_path = int Function( + ffi.Pointer thumb, + ffi.Pointer path, +); + +typedef _c_thumbnail_util_set_size = ffi.Int32 Function( + ffi.Pointer thumb, + ffi.Int32 width, + ffi.Int32 height, +); + +typedef _dart_thumbnail_util_set_size = int Function( + ffi.Pointer thumb, + int width, + int height, +); + +typedef _c_thumbnail_util_cancel = ffi.Int32 Function( + ffi.Pointer thumb, + ffi.Pointer request_id, +); + +typedef _dart_thumbnail_util_cancel = int Function( + ffi.Pointer thumb, + ffi.Pointer request_id, +); + +typedef _c_thumbnail_util_cancel_all = ffi.Int32 Function( + ffi.Pointer thumb, +); + +typedef _dart_thumbnail_util_cancel_all = int Function( + ffi.Pointer thumb, +); + +typedef _c_thumbnail_util_destroy = ffi.Int32 Function( + ffi.Pointer thumb, +); + +typedef _dart_thumbnail_util_destroy = int Function( + ffi.Pointer thumb, +); + +typedef _c_tone_player_start = ffi.Int32 Function( + ffi.Int32 tone, + ffi.Int32 type, + ffi.Int32 duration_ms, + ffi.Pointer id, +); + +typedef _dart_tone_player_start = int Function( + int tone, + int type, + int duration_ms, + ffi.Pointer id, +); + +typedef _c_tone_player_start_new = ffi.Int32 Function( + ffi.Int32 tone, + ffi.Pointer stream_info, + ffi.Int32 duration_ms, + ffi.Pointer id, +); + +typedef _dart_tone_player_start_new = int Function( + int tone, + ffi.Pointer stream_info, + int duration_ms, + ffi.Pointer id, +); + +typedef _c_tone_player_stop = ffi.Int32 Function( + ffi.Int32 id, +); + +typedef _dart_tone_player_stop = int Function( + int id, +); + +typedef wav_player_playback_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_wav_player_start = ffi.Int32 Function( + ffi.Pointer path, + ffi.Int32 type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _dart_wav_player_start = int Function( + ffi.Pointer path, + int type, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _c_wav_player_start_new = ffi.Int32 Function( + ffi.Pointer path, + ffi.Pointer stream_info, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _dart_wav_player_start_new = int Function( + ffi.Pointer path, + ffi.Pointer stream_info, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _c_wav_player_stop = ffi.Int32 Function( + ffi.Int32 id, +); + +typedef _dart_wav_player_stop = int Function( + int id, +); + +typedef _c_asp_initialize = ffi.Int32 Function(); + +typedef _dart_asp_initialize = int Function(); + +typedef _c_asp_deinitialize = ffi.Int32 Function(); + +typedef _dart_asp_deinitialize = int Function(); + +typedef asp_seek_search_result_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Uint32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_asp_seek_set_search_result_cb = ffi.Int32 Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_asp_seek_set_search_result_cb = int Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_asp_seek_unset_search_result_cb = ffi.Int32 Function(); + +typedef _dart_asp_seek_unset_search_result_cb = int Function(); + +typedef asp_advert_status_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_asp_advert_set_status_changed_cb = ffi.Int32 Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_asp_advert_set_status_changed_cb = int Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_asp_advert_unset_status_changed_cb = ffi.Int32 Function(); + +typedef _dart_asp_advert_unset_status_changed_cb = int Function(); + +typedef asp_session_request_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_asp_session_set_request_cb = ffi.Int32 Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_asp_session_set_request_cb = int Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_asp_session_unset_request_cb = ffi.Int32 Function(); + +typedef _dart_asp_session_unset_request_cb = int Function(); + +typedef asp_session_config_request_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_asp_session_set_config_request_cb = ffi.Int32 Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_asp_session_set_config_request_cb = int Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_asp_session_unset_config_request_cb = ffi.Int32 Function(); + +typedef _dart_asp_session_unset_config_request_cb = int Function(); + +typedef asp_session_connect_status_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_asp_session_set_connect_status_cb = ffi.Int32 Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_asp_session_set_connect_status_cb = int Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_asp_session_unset_connect_status_cb = ffi.Int32 Function(); + +typedef _dart_asp_session_unset_connect_status_cb = int Function(); + +typedef asp_session_status_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_asp_session_set_status_cb = ffi.Int32 Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_asp_session_set_status_cb = int Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_asp_session_unset_status_cb = ffi.Int32 Function(); + +typedef _dart_asp_session_unset_status_cb = int Function(); + +typedef asp_session_port_status_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_asp_session_set_port_status_cb = ffi.Int32 Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_asp_session_set_port_status_cb = int Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_asp_session_unset_port_status_cb = ffi.Int32 Function(); + +typedef _dart_asp_session_unset_port_status_cb = int Function(); + +typedef _c_asp_advert_create = ffi.Int32 Function( + ffi.Pointer instance_name, + ffi.Pointer> adv_service, +); + +typedef _dart_asp_advert_create = int Function( + ffi.Pointer instance_name, + ffi.Pointer> adv_service, +); + +typedef _c_asp_advert_destroy = ffi.Int32 Function( + ffi.Pointer adv_service, +); + +typedef _dart_asp_advert_destroy = int Function( + ffi.Pointer adv_service, +); + +typedef _c_asp_advert_set_service_type = ffi.Int32 Function( + ffi.Pointer adv_service, + ffi.Pointer service_type, +); + +typedef _dart_asp_advert_set_service_type = int Function( + ffi.Pointer adv_service, + ffi.Pointer service_type, +); + +typedef _c_asp_advert_set_auto_accept = ffi.Int32 Function( + ffi.Pointer adv_service, + ffi.Uint8 auto_accept, +); + +typedef _dart_asp_advert_set_auto_accept = int Function( + ffi.Pointer adv_service, + int auto_accept, +); + +typedef _c_asp_advert_add_info = ffi.Int32 Function( + ffi.Pointer adv_service, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_asp_advert_add_info = int Function( + ffi.Pointer adv_service, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_asp_advert_get_info = ffi.Int32 Function( + ffi.Pointer adv_service, + ffi.Pointer key, + ffi.Pointer length, + ffi.Pointer> value, +); + +typedef _dart_asp_advert_get_info = int Function( + ffi.Pointer adv_service, + ffi.Pointer key, + ffi.Pointer length, + ffi.Pointer> value, +); + +typedef _c_asp_advert_remove_info = ffi.Int32 Function( + ffi.Pointer adv_service, + ffi.Pointer key, +); + +typedef _dart_asp_advert_remove_info = int Function( + ffi.Pointer adv_service, + ffi.Pointer key, +); + +typedef _c_asp_advert_set_status = ffi.Int32 Function( + ffi.Pointer adv_service, + ffi.Uint8 status, +); + +typedef _dart_asp_advert_set_status = int Function( + ffi.Pointer adv_service, + int status, +); + +typedef _c_asp_advert_set_discovery_tech = ffi.Int32 Function( + ffi.Pointer adv_service, + ffi.Int32 discovery_tech, +); + +typedef _dart_asp_advert_set_discovery_tech = int Function( + ffi.Pointer adv_service, + int discovery_tech, +); + +typedef _c_asp_advert_set_preferred_connection = ffi.Int32 Function( + ffi.Pointer adv_service, + ffi.Uint8 preferred_connection, +); + +typedef _dart_asp_advert_set_preferred_connection = int Function( + ffi.Pointer adv_service, + int preferred_connection, +); + +typedef _c_asp_advert_set_p2p_role_scheme = ffi.Int32 Function( + ffi.Pointer adv_service, + ffi.Int32 role, +); + +typedef _dart_asp_advert_set_p2p_role_scheme = int Function( + ffi.Pointer adv_service, + int role, +); + +typedef _c_asp_advert_get_p2p_role_scheme = ffi.Int32 Function( + ffi.Pointer adv_service, + ffi.Pointer role, +); + +typedef _dart_asp_advert_get_p2p_role_scheme = int Function( + ffi.Pointer adv_service, + ffi.Pointer role, +); + +typedef _c_asp_advert_set_p2p_config_method = ffi.Int32 Function( + ffi.Pointer adv_service, + ffi.Int32 config_method, +); + +typedef _dart_asp_advert_set_p2p_config_method = int Function( + ffi.Pointer adv_service, + int config_method, +); + +typedef _c_asp_advert_get_p2p_config_method = ffi.Int32 Function( + ffi.Pointer adv_service, + ffi.Pointer config_method, +); + +typedef _dart_asp_advert_get_p2p_config_method = int Function( + ffi.Pointer adv_service, + ffi.Pointer config_method, +); + +typedef _c_asp_advert_set_p2p_response = ffi.Int32 Function( + ffi.Pointer adv_service, + ffi.Pointer rsp_info, + ffi.Int32 length, +); + +typedef _dart_asp_advert_set_p2p_response = int Function( + ffi.Pointer adv_service, + ffi.Pointer rsp_info, + int length, +); + +typedef _c_asp_advert_start_advertising = ffi.Int32 Function( + ffi.Pointer adv_service, +); + +typedef _dart_asp_advert_start_advertising = int Function( + ffi.Pointer adv_service, +); + +typedef _c_asp_advert_stop_advertising = ffi.Int32 Function( + ffi.Pointer adv_service, +); + +typedef _dart_asp_advert_stop_advertising = int Function( + ffi.Pointer adv_service, +); + +typedef _c_asp_advert_change_service_status = ffi.Int32 Function( + ffi.Pointer adv_service, + ffi.Uint8 status, +); + +typedef _dart_asp_advert_change_service_status = int Function( + ffi.Pointer adv_service, + int status, +); + +typedef _c_asp_seek_create = ffi.Int32 Function( + ffi.Pointer service_type, + ffi.Pointer> seek_service, +); + +typedef _dart_asp_seek_create = int Function( + ffi.Pointer service_type, + ffi.Pointer> seek_service, +); + +typedef _c_asp_seek_destroy = ffi.Int32 Function( + ffi.Pointer seek_service, +); + +typedef _dart_asp_seek_destroy = int Function( + ffi.Pointer seek_service, +); + +typedef _c_asp_seek_add_info = ffi.Int32 Function( + ffi.Pointer seek_service, + ffi.Pointer key, +); + +typedef _dart_asp_seek_add_info = int Function( + ffi.Pointer seek_service, + ffi.Pointer key, +); + +typedef _c_asp_seek_remove_info = ffi.Int32 Function( + ffi.Pointer seek_service, + ffi.Pointer key, +); + +typedef _dart_asp_seek_remove_info = int Function( + ffi.Pointer seek_service, + ffi.Pointer key, +); + +typedef _c_asp_seek_set_discovery_tech = ffi.Int32 Function( + ffi.Pointer seek_service, + ffi.Int32 discovery_tech, +); + +typedef _dart_asp_seek_set_discovery_tech = int Function( + ffi.Pointer seek_service, + int discovery_tech, +); + +typedef _c_asp_seek_set_preferred_connection = ffi.Int32 Function( + ffi.Pointer seek_service, + ffi.Uint8 preferred_connection, +); + +typedef _dart_asp_seek_set_preferred_connection = int Function( + ffi.Pointer seek_service, + int preferred_connection, +); + +typedef _c_asp_seek_start = ffi.Int32 Function( + ffi.Pointer seek_service, +); + +typedef _dart_asp_seek_start = int Function( + ffi.Pointer seek_service, +); + +typedef _c_asp_seek_stop = ffi.Int32 Function( + ffi.Pointer seek_service, +); + +typedef _dart_asp_seek_stop = int Function( + ffi.Pointer seek_service, +); + +typedef _c_asp_session_create = ffi.Int32 Function( + ffi.Pointer service_mac, + ffi.Uint32 adv_id, + ffi.Pointer> session, +); + +typedef _dart_asp_session_create = int Function( + ffi.Pointer service_mac, + int adv_id, + ffi.Pointer> session, +); + +typedef _c_asp_session_destroy = ffi.Int32 Function( + ffi.Pointer session, +); + +typedef _dart_asp_session_destroy = int Function( + ffi.Pointer session, +); + +typedef _c_asp_session_get_mac = ffi.Int32 Function( + ffi.Pointer session, + ffi.Pointer> session_mac, +); + +typedef _dart_asp_session_get_mac = int Function( + ffi.Pointer session, + ffi.Pointer> session_mac, +); + +typedef _c_asp_session_get_id = ffi.Int32 Function( + ffi.Pointer session, + ffi.Pointer session_id, +); + +typedef _dart_asp_session_get_id = int Function( + ffi.Pointer session, + ffi.Pointer session_id, +); + +typedef _c_asp_session_set_info = ffi.Int32 Function( + ffi.Pointer session, + ffi.Pointer session_info, +); + +typedef _dart_asp_session_set_info = int Function( + ffi.Pointer session, + ffi.Pointer session_info, +); + +typedef _c_asp_session_get_info = ffi.Int32 Function( + ffi.Pointer session, + ffi.Pointer> session_info, +); + +typedef _dart_asp_session_get_info = int Function( + ffi.Pointer session, + ffi.Pointer> session_info, +); + +typedef _c_asp_session_set_p2p_role_scheme = ffi.Int32 Function( + ffi.Pointer session, + ffi.Int32 role, +); + +typedef _dart_asp_session_set_p2p_role_scheme = int Function( + ffi.Pointer session, + int role, +); + +typedef _c_asp_session_get_p2p_role_scheme = ffi.Int32 Function( + ffi.Pointer session, + ffi.Pointer role, +); + +typedef _dart_asp_session_get_p2p_role_scheme = int Function( + ffi.Pointer session, + ffi.Pointer role, +); + +typedef _c_asp_session_set_p2p_config_method = ffi.Int32 Function( + ffi.Pointer session, + ffi.Int32 config_method, +); + +typedef _dart_asp_session_set_p2p_config_method = int Function( + ffi.Pointer session, + int config_method, +); + +typedef _c_asp_session_get_p2p_config_method = ffi.Int32 Function( + ffi.Pointer session, + ffi.Pointer config_method, +); + +typedef _dart_asp_session_get_p2p_config_method = int Function( + ffi.Pointer session, + ffi.Pointer config_method, +); + +typedef _c_asp_session_get_close_status = ffi.Int32 Function( + ffi.Pointer session, + ffi.Pointer status, +); + +typedef _dart_asp_session_get_close_status = int Function( + ffi.Pointer session, + ffi.Pointer status, +); + +typedef _c_asp_session_connect = ffi.Int32 Function( + ffi.Pointer session, +); + +typedef _dart_asp_session_connect = int Function( + ffi.Pointer session, +); + +typedef _c_asp_session_confirm = ffi.Int32 Function( + ffi.Pointer session, + ffi.Uint8 confirmed, + ffi.Pointer pin, +); + +typedef _dart_asp_session_confirm = int Function( + ffi.Pointer session, + int confirmed, + ffi.Pointer pin, +); + +typedef _c_asp_session_get_handle = ffi.Int32 Function( + ffi.Pointer session_mac, + ffi.Uint32 session_id, + ffi.Pointer> session, +); + +typedef _dart_asp_session_get_handle = int Function( + ffi.Pointer session_mac, + int session_id, + ffi.Pointer> session, +); + +typedef _c_asp_session_set_state_ready = ffi.Int32 Function( + ffi.Pointer session, +); + +typedef _dart_asp_session_set_state_ready = int Function( + ffi.Pointer session, +); + +typedef _c_asp_session_close = ffi.Int32 Function( + ffi.Pointer session, +); + +typedef _dart_asp_session_close = int Function( + ffi.Pointer session, +); + +typedef _c_asp_session_bind_port = ffi.Int32 Function( + ffi.Pointer session, + ffi.Pointer ip_address, + ffi.Int32 port, + ffi.Int32 proto, +); + +typedef _dart_asp_session_bind_port = int Function( + ffi.Pointer session, + ffi.Pointer ip_address, + int port, + int proto, +); + +typedef _c_asp_session_release_port = ffi.Int32 Function( + ffi.Pointer session, + ffi.Pointer ip_address, + ffi.Int32 port, + ffi.Int32 proto, +); + +typedef _dart_asp_session_release_port = int Function( + ffi.Pointer session, + ffi.Pointer ip_address, + int port, + int proto, +); + +typedef _c_bt_initialize = ffi.Int32 Function(); + +typedef _dart_bt_initialize = int Function(); + +typedef _c_bt_deinitialize = ffi.Int32 Function(); + +typedef _dart_bt_deinitialize = int Function(); + +typedef _c_bt_get_uuid_name = ffi.Int32 Function( + ffi.Pointer uuid, + ffi.Pointer> name, +); + +typedef _dart_bt_get_uuid_name = int Function( + ffi.Pointer uuid, + ffi.Pointer> name, +); + +typedef _c_bt_adapter_get_state = ffi.Int32 Function( + ffi.Pointer adapter_state, +); + +typedef _dart_bt_adapter_get_state = int Function( + ffi.Pointer adapter_state, +); + +typedef _c_bt_adapter_get_address = ffi.Int32 Function( + ffi.Pointer> local_address, +); + +typedef _dart_bt_adapter_get_address = int Function( + ffi.Pointer> local_address, +); + +typedef _c_bt_adapter_get_name = ffi.Int32 Function( + ffi.Pointer> local_name, +); + +typedef _dart_bt_adapter_get_name = int Function( + ffi.Pointer> local_name, +); + +typedef _c_bt_adapter_set_name = ffi.Int32 Function( + ffi.Pointer local_name, +); + +typedef _dart_bt_adapter_set_name = int Function( + ffi.Pointer local_name, +); + +typedef _c_bt_adapter_get_visibility = ffi.Int32 Function( + ffi.Pointer mode, + ffi.Pointer duration, +); + +typedef _dart_bt_adapter_get_visibility = int Function( + ffi.Pointer mode, + ffi.Pointer duration, +); + +typedef _c_bt_adapter_start_device_discovery = ffi.Int32 Function(); + +typedef _dart_bt_adapter_start_device_discovery = int Function(); + +typedef _c_bt_adapter_stop_device_discovery = ffi.Int32 Function(); + +typedef _dart_bt_adapter_stop_device_discovery = int Function(); + +typedef _c_bt_adapter_is_discovering = ffi.Int32 Function( + ffi.Pointer is_discovering, +); + +typedef _dart_bt_adapter_is_discovering = int Function( + ffi.Pointer is_discovering, +); + +typedef _c_bt_device_get_service_mask_from_uuid_list = ffi.Int32 Function( + ffi.Pointer> uuids, + ffi.Int32 no_of_service, + ffi.Pointer service_mask_list, +); + +typedef _dart_bt_device_get_service_mask_from_uuid_list = int Function( + ffi.Pointer> uuids, + int no_of_service, + ffi.Pointer service_mask_list, +); + +typedef bt_adapter_bonded_device_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_adapter_foreach_bonded_device = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_adapter_foreach_bonded_device = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_adapter_get_bonded_device_info = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Pointer> device_info, +); + +typedef _dart_bt_adapter_get_bonded_device_info = int Function( + ffi.Pointer remote_address, + ffi.Pointer> device_info, +); + +typedef _c_bt_adapter_free_device_info = ffi.Int32 Function( + ffi.Pointer device_info, +); + +typedef _dart_bt_adapter_free_device_info = int Function( + ffi.Pointer device_info, +); + +typedef _c_bt_adapter_is_service_used = ffi.Int32 Function( + ffi.Pointer service_uuid, + ffi.Pointer used, +); + +typedef _dart_bt_adapter_is_service_used = int Function( + ffi.Pointer service_uuid, + ffi.Pointer used, +); + +typedef bt_adapter_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_adapter_set_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_adapter_set_state_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_adapter_unset_state_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_adapter_unset_state_changed_cb = int Function(); + +typedef bt_adapter_name_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_adapter_set_name_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_adapter_set_name_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_adapter_unset_name_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_adapter_unset_name_changed_cb = int Function(); + +typedef bt_adapter_visibility_mode_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_adapter_set_visibility_mode_changed_cb = ffi.Int32 Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_adapter_set_visibility_mode_changed_cb = int Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_bt_adapter_unset_visibility_mode_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_adapter_unset_visibility_mode_changed_cb = int Function(); + +typedef bt_adapter_visibility_duration_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_adapter_set_visibility_duration_changed_cb = ffi.Int32 Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_adapter_set_visibility_duration_changed_cb = int Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_bt_adapter_unset_visibility_duration_changed_cb = ffi.Int32 + Function(); + +typedef _dart_bt_adapter_unset_visibility_duration_changed_cb = int Function(); + +typedef bt_adapter_device_discovery_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_adapter_set_device_discovery_state_changed_cb = ffi.Int32 + Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_adapter_set_device_discovery_state_changed_cb = int Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_bt_adapter_unset_device_discovery_state_changed_cb = ffi.Int32 + Function(); + +typedef _dart_bt_adapter_unset_device_discovery_state_changed_cb = int + Function(); + +typedef _c_bt_adapter_get_local_oob_data = ffi.Int32 Function( + ffi.Pointer> hash, + ffi.Pointer> randomizer, + ffi.Pointer hash_len, + ffi.Pointer randomizer_len, +); + +typedef _dart_bt_adapter_get_local_oob_data = int Function( + ffi.Pointer> hash, + ffi.Pointer> randomizer, + ffi.Pointer hash_len, + ffi.Pointer randomizer_len, +); + +typedef _c_bt_adapter_set_remote_oob_data = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Pointer hash, + ffi.Pointer randomizer, + ffi.Int32 hash_len, + ffi.Int32 randomizer_len, +); + +typedef _dart_bt_adapter_set_remote_oob_data = int Function( + ffi.Pointer remote_address, + ffi.Pointer hash, + ffi.Pointer randomizer, + int hash_len, + int randomizer_len, +); + +typedef _c_bt_adapter_get_local_oob_ext_data = ffi.Int32 Function( + ffi.Pointer> hash192, + ffi.Pointer> randomizer192, + ffi.Pointer hash192_len, + ffi.Pointer randomizer192_len, + ffi.Pointer> hash256, + ffi.Pointer> randomizer256, + ffi.Pointer hash256_len, + ffi.Pointer randomizer256_len, +); + +typedef _dart_bt_adapter_get_local_oob_ext_data = int Function( + ffi.Pointer> hash192, + ffi.Pointer> randomizer192, + ffi.Pointer hash192_len, + ffi.Pointer randomizer192_len, + ffi.Pointer> hash256, + ffi.Pointer> randomizer256, + ffi.Pointer hash256_len, + ffi.Pointer randomizer256_len, +); + +typedef _c_bt_adapter_set_remote_oob_ext_data = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Pointer hash192, + ffi.Pointer randomizer192, + ffi.Int32 hash192_len, + ffi.Int32 randomizer192_len, + ffi.Pointer hash256, + ffi.Pointer randomizer256, + ffi.Int32 hash256_len, + ffi.Int32 randomizer256_len, +); + +typedef _dart_bt_adapter_set_remote_oob_ext_data = int Function( + ffi.Pointer remote_address, + ffi.Pointer hash192, + ffi.Pointer randomizer192, + int hash192_len, + int randomizer192_len, + ffi.Pointer hash256, + ffi.Pointer randomizer256, + int hash256_len, + int randomizer256_len, +); + +typedef _c_bt_adapter_remove_remote_oob_data = ffi.Int32 Function( + ffi.Pointer remote_address, +); + +typedef _dart_bt_adapter_remove_remote_oob_data = int Function( + ffi.Pointer remote_address, +); + +typedef _c_bt_adapter_le_start_device_discovery = ffi.Int32 Function(); + +typedef _dart_bt_adapter_le_start_device_discovery = int Function(); + +typedef _c_bt_adapter_le_stop_device_discovery = ffi.Int32 Function(); + +typedef _dart_bt_adapter_le_stop_device_discovery = int Function(); + +typedef _c_bt_adapter_le_is_discovering = ffi.Int32 Function( + ffi.Pointer is_discovering, +); + +typedef _dart_bt_adapter_le_is_discovering = int Function( + ffi.Pointer is_discovering, +); + +typedef bt_adapter_le_device_discovery_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_adapter_le_set_device_discovery_state_changed_cb = ffi.Int32 + Function( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_adapter_le_set_device_discovery_state_changed_cb = int + Function( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _c_bt_adapter_le_unset_device_discovery_state_changed_cb = ffi.Int32 + Function(); + +typedef _dart_bt_adapter_le_unset_device_discovery_state_changed_cb = int + Function(); + +typedef bt_adapter_le_scan_result_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_adapter_le_start_scan = ffi.Int32 Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_bt_adapter_le_start_scan = int Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_bt_adapter_le_stop_scan = ffi.Int32 Function(); + +typedef _dart_bt_adapter_le_stop_scan = int Function(); + +typedef _c_bt_adapter_le_get_scan_result_service_uuids = ffi.Int32 Function( + ffi.Pointer info, + ffi.Int32 pkt_type, + ffi.Pointer>> uuids, + ffi.Pointer count, +); + +typedef _dart_bt_adapter_le_get_scan_result_service_uuids = int Function( + ffi.Pointer info, + int pkt_type, + ffi.Pointer>> uuids, + ffi.Pointer count, +); + +typedef _c_bt_adapter_le_get_scan_result_device_name = ffi.Int32 Function( + ffi.Pointer info, + ffi.Int32 pkt_type, + ffi.Pointer> name, +); + +typedef _dart_bt_adapter_le_get_scan_result_device_name = int Function( + ffi.Pointer info, + int pkt_type, + ffi.Pointer> name, +); + +typedef _c_bt_adapter_le_get_scan_result_tx_power_level = ffi.Int32 Function( + ffi.Pointer info, + ffi.Int32 pkt_type, + ffi.Pointer power_level, +); + +typedef _dart_bt_adapter_le_get_scan_result_tx_power_level = int Function( + ffi.Pointer info, + int pkt_type, + ffi.Pointer power_level, +); + +typedef _c_bt_adapter_le_get_scan_result_service_solicitation_uuids = ffi.Int32 + Function( + ffi.Pointer info, + ffi.Int32 pkt_type, + ffi.Pointer>> uuids, + ffi.Pointer count, +); + +typedef _dart_bt_adapter_le_get_scan_result_service_solicitation_uuids = int + Function( + ffi.Pointer info, + int pkt_type, + ffi.Pointer>> uuids, + ffi.Pointer count, +); + +typedef _c_bt_adapter_le_get_scan_result_service_data_list = ffi.Int32 Function( + ffi.Pointer info, + ffi.Int32 pkt_type, + ffi.Pointer> data_list, + ffi.Pointer count, +); + +typedef _dart_bt_adapter_le_get_scan_result_service_data_list = int Function( + ffi.Pointer info, + int pkt_type, + ffi.Pointer> data_list, + ffi.Pointer count, +); + +typedef _c_bt_adapter_le_free_service_data_list = ffi.Int32 Function( + ffi.Pointer data_list, + ffi.Int32 count, +); + +typedef _dart_bt_adapter_le_free_service_data_list = int Function( + ffi.Pointer data_list, + int count, +); + +typedef _c_bt_adapter_le_get_scan_result_appearance = ffi.Int32 Function( + ffi.Pointer info, + ffi.Int32 pkt_type, + ffi.Pointer appearance, +); + +typedef _dart_bt_adapter_le_get_scan_result_appearance = int Function( + ffi.Pointer info, + int pkt_type, + ffi.Pointer appearance, +); + +typedef _c_bt_adapter_le_get_scan_result_manufacturer_data = ffi.Int32 Function( + ffi.Pointer info, + ffi.Int32 pkt_type, + ffi.Pointer manufacturer_id, + ffi.Pointer> manufacturer_data, + ffi.Pointer manufacturer_data_len, +); + +typedef _dart_bt_adapter_le_get_scan_result_manufacturer_data = int Function( + ffi.Pointer info, + int pkt_type, + ffi.Pointer manufacturer_id, + ffi.Pointer> manufacturer_data, + ffi.Pointer manufacturer_data_len, +); + +typedef _c_bt_adapter_le_get_scan_result_ibeacon_report = ffi.Int32 Function( + ffi.Pointer info, + ffi.Int32 pkt_type, + ffi.Pointer> + ibeacon_info, +); + +typedef _dart_bt_adapter_le_get_scan_result_ibeacon_report = int Function( + ffi.Pointer info, + int pkt_type, + ffi.Pointer> + ibeacon_info, +); + +typedef _c_bt_adapter_le_free_ibeacon_report = ffi.Int32 Function( + ffi.Pointer ibeacon_info, +); + +typedef _dart_bt_adapter_le_free_ibeacon_report = int Function( + ffi.Pointer ibeacon_info, +); + +typedef _c_bt_adapter_le_create_advertiser = ffi.Int32 Function( + ffi.Pointer> advertiser, +); + +typedef _dart_bt_adapter_le_create_advertiser = int Function( + ffi.Pointer> advertiser, +); + +typedef _c_bt_adapter_le_destroy_advertiser = ffi.Int32 Function( + ffi.Pointer advertiser, +); + +typedef _dart_bt_adapter_le_destroy_advertiser = int Function( + ffi.Pointer advertiser, +); + +typedef bt_ipsp_init_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_bt_ipsp_initialize = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_ipsp_initialize = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_ipsp_deinitialize = ffi.Int32 Function(); + +typedef _dart_bt_ipsp_deinitialize = int Function(); + +typedef _c_bt_ipsp_connect = ffi.Int32 Function( + ffi.Pointer remote_address, +); + +typedef _dart_bt_ipsp_connect = int Function( + ffi.Pointer remote_address, +); + +typedef _c_bt_ipsp_disconnect = ffi.Int32 Function( + ffi.Pointer remote_address, +); + +typedef _dart_bt_ipsp_disconnect = int Function( + ffi.Pointer remote_address, +); + +typedef bt_ipsp_connection_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_ipsp_set_connection_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_ipsp_set_connection_state_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_ipsp_unset_connection_state_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_ipsp_unset_connection_state_changed_cb = int Function(); + +typedef _c_bt_adapter_le_add_advertising_data = ffi.Int32 Function( + ffi.Pointer advertiser, + ffi.Int32 pkt_type, + ffi.Int32 data_type, + ffi.Pointer data, + ffi.Uint32 data_size, +); + +typedef _dart_bt_adapter_le_add_advertising_data = int Function( + ffi.Pointer advertiser, + int pkt_type, + int data_type, + ffi.Pointer data, + int data_size, +); + +typedef _c_bt_adapter_le_add_advertising_service_uuid = ffi.Int32 Function( + ffi.Pointer advertiser, + ffi.Int32 pkt_type, + ffi.Pointer uuid, +); + +typedef _dart_bt_adapter_le_add_advertising_service_uuid = int Function( + ffi.Pointer advertiser, + int pkt_type, + ffi.Pointer uuid, +); + +typedef _c_bt_adapter_le_add_advertising_service_solicitation_uuid = ffi.Int32 + Function( + ffi.Pointer advertiser, + ffi.Int32 pkt_type, + ffi.Pointer uuid, +); + +typedef _dart_bt_adapter_le_add_advertising_service_solicitation_uuid = int + Function( + ffi.Pointer advertiser, + int pkt_type, + ffi.Pointer uuid, +); + +typedef _c_bt_adapter_le_add_advertising_service_data = ffi.Int32 Function( + ffi.Pointer advertiser, + ffi.Int32 pkt_type, + ffi.Pointer uuid, + ffi.Pointer service_data, + ffi.Int32 service_data_len, +); + +typedef _dart_bt_adapter_le_add_advertising_service_data = int Function( + ffi.Pointer advertiser, + int pkt_type, + ffi.Pointer uuid, + ffi.Pointer service_data, + int service_data_len, +); + +typedef _c_bt_adapter_le_set_advertising_appearance = ffi.Int32 Function( + ffi.Pointer advertiser, + ffi.Int32 pkt_type, + ffi.Int32 appearance, +); + +typedef _dart_bt_adapter_le_set_advertising_appearance = int Function( + ffi.Pointer advertiser, + int pkt_type, + int appearance, +); + +typedef _c_bt_adapter_le_add_advertising_manufacturer_data = ffi.Int32 Function( + ffi.Pointer advertiser, + ffi.Int32 pkt_type, + ffi.Int32 manufacturer_id, + ffi.Pointer manufacturer_data, + ffi.Int32 manufacturer_data_len, +); + +typedef _dart_bt_adapter_le_add_advertising_manufacturer_data = int Function( + ffi.Pointer advertiser, + int pkt_type, + int manufacturer_id, + ffi.Pointer manufacturer_data, + int manufacturer_data_len, +); + +typedef _c_bt_adapter_le_set_advertising_device_name = ffi.Int32 Function( + ffi.Pointer advertiser, + ffi.Int32 pkt_type, + ffi.Uint8 include_name, +); + +typedef _dart_bt_adapter_le_set_advertising_device_name = int Function( + ffi.Pointer advertiser, + int pkt_type, + int include_name, +); + +typedef _c_bt_adapter_le_set_advertising_tx_power_level = ffi.Int32 Function( + ffi.Pointer advertiser, + ffi.Int32 pkt_type, + ffi.Uint8 include_tx_power, +); + +typedef _dart_bt_adapter_le_set_advertising_tx_power_level = int Function( + ffi.Pointer advertiser, + int pkt_type, + int include_tx_power, +); + +typedef _c_bt_adapter_le_remove_advertising_data = ffi.Int32 Function( + ffi.Pointer advertiser, + ffi.Int32 pkt_type, + ffi.Int32 data_type, +); + +typedef _dart_bt_adapter_le_remove_advertising_data = int Function( + ffi.Pointer advertiser, + int pkt_type, + int data_type, +); + +typedef _c_bt_adapter_le_clear_advertising_data = ffi.Int32 Function( + ffi.Pointer advertiser, + ffi.Int32 pkt_type, +); + +typedef _dart_bt_adapter_le_clear_advertising_data = int Function( + ffi.Pointer advertiser, + int pkt_type, +); + +typedef bt_adapter_le_advertising_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_adapter_le_start_advertising = ffi.Int32 Function( + ffi.Pointer advertiser, + ffi.Pointer adv_params, + ffi.Pointer> + cb, + ffi.Pointer user_data, +); + +typedef _dart_bt_adapter_le_start_advertising = int Function( + ffi.Pointer advertiser, + ffi.Pointer adv_params, + ffi.Pointer> + cb, + ffi.Pointer user_data, +); + +typedef _c_bt_adapter_le_stop_advertising = ffi.Int32 Function( + ffi.Pointer advertiser, +); + +typedef _dart_bt_adapter_le_stop_advertising = int Function( + ffi.Pointer advertiser, +); + +typedef _c_bt_adapter_le_start_advertising_new = ffi.Int32 Function( + ffi.Pointer advertiser, + ffi.Pointer> + cb, + ffi.Pointer user_data, +); + +typedef _dart_bt_adapter_le_start_advertising_new = int Function( + ffi.Pointer advertiser, + ffi.Pointer> + cb, + ffi.Pointer user_data, +); + +typedef _c_bt_adapter_le_set_advertising_mode = ffi.Int32 Function( + ffi.Pointer advertiser, + ffi.Int32 mode, +); + +typedef _dart_bt_adapter_le_set_advertising_mode = int Function( + ffi.Pointer advertiser, + int mode, +); + +typedef _c_bt_adapter_le_set_advertising_connectable = ffi.Int32 Function( + ffi.Pointer advertiser, + ffi.Uint8 connectable, +); + +typedef _dart_bt_adapter_le_set_advertising_connectable = int Function( + ffi.Pointer advertiser, + int connectable, +); + +typedef _c_bt_adapter_le_set_scan_mode = ffi.Int32 Function( + ffi.Int32 scan_mode, +); + +typedef _dart_bt_adapter_le_set_scan_mode = int Function( + int scan_mode, +); + +typedef _c_bt_device_create_bond = ffi.Int32 Function( + ffi.Pointer remote_address, +); + +typedef _dart_bt_device_create_bond = int Function( + ffi.Pointer remote_address, +); + +typedef _c_bt_device_cancel_bonding = ffi.Int32 Function(); + +typedef _dart_bt_device_cancel_bonding = int Function(); + +typedef _c_bt_device_destroy_bond = ffi.Int32 Function( + ffi.Pointer remote_address, +); + +typedef _dart_bt_device_destroy_bond = int Function( + ffi.Pointer remote_address, +); + +typedef _c_bt_device_set_alias = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Pointer alias, +); + +typedef _dart_bt_device_set_alias = int Function( + ffi.Pointer remote_address, + ffi.Pointer alias, +); + +typedef _c_bt_device_set_authorization = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Int32 authorization_state, +); + +typedef _dart_bt_device_set_authorization = int Function( + ffi.Pointer remote_address, + int authorization_state, +); + +typedef _c_bt_device_start_service_search = ffi.Int32 Function( + ffi.Pointer remote_address, +); + +typedef _dart_bt_device_start_service_search = int Function( + ffi.Pointer remote_address, +); + +typedef bt_device_connected_profile = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_device_foreach_connected_profiles = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_device_foreach_connected_profiles = int Function( + ffi.Pointer remote_address, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_device_is_profile_connected = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Int32 bt_profile, + ffi.Pointer connected_status, +); + +typedef _dart_bt_device_is_profile_connected = int Function( + ffi.Pointer remote_address, + int bt_profile, + ffi.Pointer connected_status, +); + +typedef _c_bt_device_update_le_connection_mode = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Int32 mode, +); + +typedef _dart_bt_device_update_le_connection_mode = int Function( + ffi.Pointer remote_address, + int mode, +); + +typedef bt_device_bond_created_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_device_set_bond_created_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_device_set_bond_created_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_device_unset_bond_created_cb = ffi.Int32 Function(); + +typedef _dart_bt_device_unset_bond_created_cb = int Function(); + +typedef bt_device_bond_destroyed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_device_set_bond_destroyed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_device_set_bond_destroyed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_device_unset_bond_destroyed_cb = ffi.Int32 Function(); + +typedef _dart_bt_device_unset_bond_destroyed_cb = int Function(); + +typedef bt_device_authorization_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_device_set_authorization_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_device_set_authorization_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_device_unset_authorization_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_device_unset_authorization_changed_cb = int Function(); + +typedef bt_device_service_searched_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_device_set_service_searched_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_device_set_service_searched_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_device_unset_service_searched_cb = ffi.Int32 Function(); + +typedef _dart_bt_device_unset_service_searched_cb = int Function(); + +typedef bt_device_connection_state_changed_cb = ffi.Void Function( + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_device_set_connection_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_device_set_connection_state_changed_cb = int Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_bt_device_unset_connection_state_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_device_unset_connection_state_changed_cb = int Function(); + +typedef _c_bt_socket_create_rfcomm = ffi.Int32 Function( + ffi.Pointer service_uuid, + ffi.Pointer socket_fd, +); + +typedef _dart_bt_socket_create_rfcomm = int Function( + ffi.Pointer service_uuid, + ffi.Pointer socket_fd, +); + +typedef _c_bt_socket_destroy_rfcomm = ffi.Int32 Function( + ffi.Int32 socket_fd, +); + +typedef _dart_bt_socket_destroy_rfcomm = int Function( + int socket_fd, +); + +typedef _c_bt_socket_listen_and_accept_rfcomm = ffi.Int32 Function( + ffi.Int32 socket_fd, + ffi.Int32 max_pending_connections, +); + +typedef _dart_bt_socket_listen_and_accept_rfcomm = int Function( + int socket_fd, + int max_pending_connections, +); + +typedef _c_bt_socket_connect_rfcomm = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Pointer service_uuid, +); + +typedef _dart_bt_socket_connect_rfcomm = int Function( + ffi.Pointer remote_address, + ffi.Pointer service_uuid, +); + +typedef _c_bt_socket_disconnect_rfcomm = ffi.Int32 Function( + ffi.Int32 socket_fd, +); + +typedef _dart_bt_socket_disconnect_rfcomm = int Function( + int socket_fd, +); + +typedef _c_bt_socket_send_data = ffi.Int32 Function( + ffi.Int32 socket_fd, + ffi.Pointer data, + ffi.Int32 length, +); + +typedef _dart_bt_socket_send_data = int Function( + int socket_fd, + ffi.Pointer data, + int length, +); + +typedef bt_socket_data_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_socket_set_data_received_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_socket_set_data_received_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_socket_unset_data_received_cb = ffi.Int32 Function(); + +typedef _dart_bt_socket_unset_data_received_cb = int Function(); + +typedef bt_socket_connection_requested_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_socket_set_connection_requested_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_socket_set_connection_requested_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_socket_unset_connection_requested_cb = ffi.Int32 Function(); + +typedef _dart_bt_socket_unset_connection_requested_cb = int Function(); + +typedef bt_socket_connection_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_socket_set_connection_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_socket_set_connection_state_changed_cb = int Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_bt_socket_unset_connection_state_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_socket_unset_connection_state_changed_cb = int Function(); + +typedef bt_opp_server_connection_requested_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_opp_server_initialize_by_connection_request = ffi.Int32 Function( + ffi.Pointer destination, + ffi.Pointer> + connection_requested_cb, + ffi.Pointer user_data, +); + +typedef _dart_bt_opp_server_initialize_by_connection_request = int Function( + ffi.Pointer destination, + ffi.Pointer> + connection_requested_cb, + ffi.Pointer user_data, +); + +typedef _c_bt_opp_server_deinitialize = ffi.Int32 Function(); + +typedef _dart_bt_opp_server_deinitialize = int Function(); + +typedef bt_opp_server_transfer_progress_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int64, + ffi.Int32, + ffi.Pointer, +); + +typedef bt_opp_server_transfer_finished_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Int64, + ffi.Pointer, +); + +typedef _c_bt_opp_server_accept = ffi.Int32 Function( + ffi.Pointer> + progress_cb, + ffi.Pointer> + finished_cb, + ffi.Pointer name, + ffi.Pointer user_data, + ffi.Pointer transfer_id, +); + +typedef _dart_bt_opp_server_accept = int Function( + ffi.Pointer> + progress_cb, + ffi.Pointer> + finished_cb, + ffi.Pointer name, + ffi.Pointer user_data, + ffi.Pointer transfer_id, +); + +typedef _c_bt_opp_server_reject = ffi.Int32 Function(); + +typedef _dart_bt_opp_server_reject = int Function(); + +typedef _c_bt_opp_server_cancel_transfer = ffi.Int32 Function( + ffi.Int32 transfer_id, +); + +typedef _dart_bt_opp_server_cancel_transfer = int Function( + int transfer_id, +); + +typedef _c_bt_opp_server_set_destination = ffi.Int32 Function( + ffi.Pointer destination, +); + +typedef _dart_bt_opp_server_set_destination = int Function( + ffi.Pointer destination, +); + +typedef _c_bt_opp_client_initialize = ffi.Int32 Function(); + +typedef _dart_bt_opp_client_initialize = int Function(); + +typedef _c_bt_opp_client_deinitialize = ffi.Int32 Function(); + +typedef _dart_bt_opp_client_deinitialize = int Function(); + +typedef _c_bt_opp_client_add_file = ffi.Int32 Function( + ffi.Pointer file, +); + +typedef _dart_bt_opp_client_add_file = int Function( + ffi.Pointer file, +); + +typedef _c_bt_opp_client_clear_files = ffi.Int32 Function(); + +typedef _dart_bt_opp_client_clear_files = int Function(); + +typedef bt_opp_client_push_responded_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef bt_opp_client_push_progress_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int64, + ffi.Int32, + ffi.Pointer, +); + +typedef bt_opp_client_push_finished_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_opp_client_push_files = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Pointer> responded_cb, + ffi.Pointer> progress_cb, + ffi.Pointer> finished_cb, + ffi.Pointer user_data, +); + +typedef _dart_bt_opp_client_push_files = int Function( + ffi.Pointer remote_address, + ffi.Pointer> responded_cb, + ffi.Pointer> progress_cb, + ffi.Pointer> finished_cb, + ffi.Pointer user_data, +); + +typedef _c_bt_opp_client_cancel_push = ffi.Int32 Function(); + +typedef _dart_bt_opp_client_cancel_push = int Function(); + +typedef bt_hid_host_connection_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_hid_host_initialize = ffi.Int32 Function( + ffi.Pointer> + connection_cb, + ffi.Pointer user_data, +); + +typedef _dart_bt_hid_host_initialize = int Function( + ffi.Pointer> + connection_cb, + ffi.Pointer user_data, +); + +typedef _c_bt_hid_host_deinitialize = ffi.Int32 Function(); + +typedef _dart_bt_hid_host_deinitialize = int Function(); + +typedef _c_bt_hid_host_connect = ffi.Int32 Function( + ffi.Pointer remote_address, +); + +typedef _dart_bt_hid_host_connect = int Function( + ffi.Pointer remote_address, +); + +typedef _c_bt_hid_host_disconnect = ffi.Int32 Function( + ffi.Pointer remote_address, +); + +typedef _dart_bt_hid_host_disconnect = int Function( + ffi.Pointer remote_address, +); + +typedef bt_hid_device_connection_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_hid_device_activate = ffi.Int32 Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_hid_device_activate = int Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_bt_hid_device_deactivate = ffi.Int32 Function(); + +typedef _dart_bt_hid_device_deactivate = int Function(); + +typedef _c_bt_hid_device_connect = ffi.Int32 Function( + ffi.Pointer remote_address, +); + +typedef _dart_bt_hid_device_connect = int Function( + ffi.Pointer remote_address, +); + +typedef _c_bt_hid_device_disconnect = ffi.Int32 Function( + ffi.Pointer remote_address, +); + +typedef _dart_bt_hid_device_disconnect = int Function( + ffi.Pointer remote_address, +); + +typedef _c_bt_hid_device_send_mouse_event = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Pointer mouse_data, +); + +typedef _dart_bt_hid_device_send_mouse_event = int Function( + ffi.Pointer remote_address, + ffi.Pointer mouse_data, +); + +typedef _c_bt_hid_device_send_key_event = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Pointer key_data, +); + +typedef _dart_bt_hid_device_send_key_event = int Function( + ffi.Pointer remote_address, + ffi.Pointer key_data, +); + +typedef bt_hid_device_data_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_hid_device_set_data_received_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_hid_device_set_data_received_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_hid_device_unset_data_received_cb = ffi.Int32 Function(); + +typedef _dart_bt_hid_device_unset_data_received_cb = int Function(); + +typedef _c_bt_hid_device_reply_to_report = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Int32 header_type, + ffi.Int32 param_type, + ffi.Pointer data, + ffi.Uint32 data_len, +); + +typedef _dart_bt_hid_device_reply_to_report = int Function( + ffi.Pointer remote_address, + int header_type, + int param_type, + ffi.Pointer data, + int data_len, +); + +typedef _c_bt_audio_initialize = ffi.Int32 Function(); + +typedef _dart_bt_audio_initialize = int Function(); + +typedef _c_bt_audio_deinitialize = ffi.Int32 Function(); + +typedef _dart_bt_audio_deinitialize = int Function(); + +typedef _c_bt_audio_connect = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Int32 type, +); + +typedef _dart_bt_audio_connect = int Function( + ffi.Pointer remote_address, + int type, +); + +typedef _c_bt_audio_disconnect = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Int32 type, +); + +typedef _dart_bt_audio_disconnect = int Function( + ffi.Pointer remote_address, + int type, +); + +typedef bt_audio_connection_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Uint8, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_audio_set_connection_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_audio_set_connection_state_changed_cb = int Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_bt_audio_unset_connection_state_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_audio_unset_connection_state_changed_cb = int Function(); + +typedef bt_avrcp_target_connection_state_changed_cb = ffi.Void Function( + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_avrcp_target_initialize = ffi.Int32 Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_avrcp_target_initialize = int Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_bt_avrcp_target_deinitialize = ffi.Int32 Function(); + +typedef _dart_bt_avrcp_target_deinitialize = int Function(); + +typedef _c_bt_avrcp_target_notify_equalizer_state = ffi.Int32 Function( + ffi.Int32 state, +); + +typedef _dart_bt_avrcp_target_notify_equalizer_state = int Function( + int state, +); + +typedef _c_bt_avrcp_target_notify_repeat_mode = ffi.Int32 Function( + ffi.Int32 mode, +); + +typedef _dart_bt_avrcp_target_notify_repeat_mode = int Function( + int mode, +); + +typedef _c_bt_avrcp_target_notify_shuffle_mode = ffi.Int32 Function( + ffi.Int32 mode, +); + +typedef _dart_bt_avrcp_target_notify_shuffle_mode = int Function( + int mode, +); + +typedef _c_bt_avrcp_target_notify_scan_mode = ffi.Int32 Function( + ffi.Int32 mode, +); + +typedef _dart_bt_avrcp_target_notify_scan_mode = int Function( + int mode, +); + +typedef _c_bt_avrcp_target_notify_player_state = ffi.Int32 Function( + ffi.Int32 state, +); + +typedef _dart_bt_avrcp_target_notify_player_state = int Function( + int state, +); + +typedef _c_bt_avrcp_target_notify_position = ffi.Int32 Function( + ffi.Uint32 position, +); + +typedef _dart_bt_avrcp_target_notify_position = int Function( + int position, +); + +typedef _c_bt_avrcp_target_notify_track = ffi.Int32 Function( + ffi.Pointer title, + ffi.Pointer artist, + ffi.Pointer album, + ffi.Pointer genre, + ffi.Uint32 track_num, + ffi.Uint32 total_tracks, + ffi.Uint32 duration, +); + +typedef _dart_bt_avrcp_target_notify_track = int Function( + ffi.Pointer title, + ffi.Pointer artist, + ffi.Pointer album, + ffi.Pointer genre, + int track_num, + int total_tracks, + int duration, +); + +typedef bt_avrcp_equalizer_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_avrcp_set_equalizer_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_avrcp_set_equalizer_state_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_avrcp_unset_equalizer_state_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_avrcp_unset_equalizer_state_changed_cb = int Function(); + +typedef bt_avrcp_repeat_mode_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_avrcp_set_repeat_mode_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_avrcp_set_repeat_mode_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_avrcp_unset_repeat_mode_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_avrcp_unset_repeat_mode_changed_cb = int Function(); + +typedef bt_avrcp_shuffle_mode_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_avrcp_set_shuffle_mode_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_avrcp_set_shuffle_mode_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_avrcp_unset_shuffle_mode_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_avrcp_unset_shuffle_mode_changed_cb = int Function(); + +typedef bt_avrcp_scan_mode_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_avrcp_set_scan_mode_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_avrcp_set_scan_mode_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_avrcp_unset_scan_mode_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_avrcp_unset_scan_mode_changed_cb = int Function(); + +typedef bt_avrcp_position_changed_cb = ffi.Void Function( + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_bt_avrcp_set_position_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_avrcp_set_position_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_avrcp_unset_position_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_avrcp_unset_position_changed_cb = int Function(); + +typedef bt_avrcp_play_status_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_avrcp_set_play_status_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_avrcp_set_play_status_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_avrcp_unset_play_status_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_avrcp_unset_play_status_changed_cb = int Function(); + +typedef bt_avrcp_track_info_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_avrcp_set_track_info_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_avrcp_set_track_info_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_avrcp_unset_track_info_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_avrcp_unset_track_info_changed_cb = int Function(); + +typedef bt_avrcp_control_connection_state_changed_cb = ffi.Void Function( + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_avrcp_control_initialize = ffi.Int32 Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_avrcp_control_initialize = int Function( + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_bt_avrcp_control_deinitialize = ffi.Int32 Function(); + +typedef _dart_bt_avrcp_control_deinitialize = int Function(); + +typedef _c_bt_avrcp_control_connect = ffi.Int32 Function( + ffi.Pointer remote_address, +); + +typedef _dart_bt_avrcp_control_connect = int Function( + ffi.Pointer remote_address, +); + +typedef _c_bt_avrcp_control_disconnect = ffi.Int32 Function( + ffi.Pointer remote_address, +); + +typedef _dart_bt_avrcp_control_disconnect = int Function( + ffi.Pointer remote_address, +); + +typedef _c_bt_avrcp_control_send_player_command = ffi.Int32 Function( + ffi.Int32 cmd, +); + +typedef _dart_bt_avrcp_control_send_player_command = int Function( + int cmd, +); + +typedef _c_bt_avrcp_control_set_equalizer_state = ffi.Int32 Function( + ffi.Int32 state, +); + +typedef _dart_bt_avrcp_control_set_equalizer_state = int Function( + int state, +); + +typedef _c_bt_avrcp_control_get_equalizer_state = ffi.Int32 Function( + ffi.Pointer state, +); + +typedef _dart_bt_avrcp_control_get_equalizer_state = int Function( + ffi.Pointer state, +); + +typedef _c_bt_avrcp_control_set_repeat_mode = ffi.Int32 Function( + ffi.Int32 mode, +); + +typedef _dart_bt_avrcp_control_set_repeat_mode = int Function( + int mode, +); + +typedef _c_bt_avrcp_control_get_repeat_mode = ffi.Int32 Function( + ffi.Pointer mode, +); + +typedef _dart_bt_avrcp_control_get_repeat_mode = int Function( + ffi.Pointer mode, +); + +typedef _c_bt_avrcp_control_set_shuffle_mode = ffi.Int32 Function( + ffi.Int32 mode, +); + +typedef _dart_bt_avrcp_control_set_shuffle_mode = int Function( + int mode, +); + +typedef _c_bt_avrcp_control_get_shuffle_mode = ffi.Int32 Function( + ffi.Pointer mode, +); + +typedef _dart_bt_avrcp_control_get_shuffle_mode = int Function( + ffi.Pointer mode, +); + +typedef _c_bt_avrcp_control_set_scan_mode = ffi.Int32 Function( + ffi.Int32 mode, +); + +typedef _dart_bt_avrcp_control_set_scan_mode = int Function( + int mode, +); + +typedef _c_bt_avrcp_control_get_scan_mode = ffi.Int32 Function( + ffi.Pointer mode, +); + +typedef _dart_bt_avrcp_control_get_scan_mode = int Function( + ffi.Pointer mode, +); + +typedef _c_bt_avrcp_control_get_position = ffi.Int32 Function( + ffi.Pointer position, +); + +typedef _dart_bt_avrcp_control_get_position = int Function( + ffi.Pointer position, +); + +typedef _c_bt_avrcp_control_get_play_status = ffi.Int32 Function( + ffi.Pointer status, +); + +typedef _dart_bt_avrcp_control_get_play_status = int Function( + ffi.Pointer status, +); + +typedef _c_bt_avrcp_control_get_track_info = ffi.Int32 Function( + ffi.Pointer> track, +); + +typedef _dart_bt_avrcp_control_get_track_info = int Function( + ffi.Pointer> track, +); + +typedef _c_bt_avrcp_control_free_track_info = ffi.Int32 Function( + ffi.Pointer track, +); + +typedef _dart_bt_avrcp_control_free_track_info = int Function( + ffi.Pointer track, +); + +typedef _c_bt_hdp_register_sink_app = ffi.Int32 Function( + ffi.Uint16 data_type, + ffi.Pointer> app_id, +); + +typedef _dart_bt_hdp_register_sink_app = int Function( + int data_type, + ffi.Pointer> app_id, +); + +typedef _c_bt_hdp_unregister_sink_app = ffi.Int32 Function( + ffi.Pointer app_id, +); + +typedef _dart_bt_hdp_unregister_sink_app = int Function( + ffi.Pointer app_id, +); + +typedef _c_bt_hdp_connect_to_source = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Pointer app_id, +); + +typedef _dart_bt_hdp_connect_to_source = int Function( + ffi.Pointer remote_address, + ffi.Pointer app_id, +); + +typedef _c_bt_hdp_disconnect = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Uint32 channel, +); + +typedef _dart_bt_hdp_disconnect = int Function( + ffi.Pointer remote_address, + int channel, +); + +typedef _c_bt_hdp_send_data = ffi.Int32 Function( + ffi.Uint32 channel, + ffi.Pointer data, + ffi.Uint32 size, +); + +typedef _dart_bt_hdp_send_data = int Function( + int channel, + ffi.Pointer data, + int size, +); + +typedef bt_hdp_connected_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Uint32, + ffi.Pointer, +); + +typedef bt_hdp_disconnected_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_bt_hdp_set_connection_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> connected_cb, + ffi.Pointer> disconnected_cb, + ffi.Pointer user_data, +); + +typedef _dart_bt_hdp_set_connection_state_changed_cb = int Function( + ffi.Pointer> connected_cb, + ffi.Pointer> disconnected_cb, + ffi.Pointer user_data, +); + +typedef _c_bt_hdp_unset_connection_state_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_hdp_unset_connection_state_changed_cb = int Function(); + +typedef bt_hdp_data_received_cb = ffi.Void Function( + ffi.Uint32, + ffi.Pointer, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_bt_hdp_set_data_received_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_hdp_set_data_received_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_hdp_unset_data_received_cb = ffi.Int32 Function(); + +typedef _dart_bt_hdp_unset_data_received_cb = int Function(); + +typedef bt_gatt_primary_service_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_gatt_foreach_primary_services = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_foreach_primary_services = int Function( + ffi.Pointer remote_address, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef bt_gatt_characteristics_discovered_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_gatt_discover_characteristics = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_discover_characteristics = int Function( + ffi.Pointer service, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_bt_gatt_get_service_uuid = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer> uuid, +); + +typedef _dart_bt_gatt_get_service_uuid = int Function( + ffi.Pointer service, + ffi.Pointer> uuid, +); + +typedef bt_gatt_included_service_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_gatt_foreach_included_services = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_foreach_included_services = int Function( + ffi.Pointer service, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef bt_gatt_characteristic_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_gatt_set_characteristic_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_set_characteristic_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_gatt_unset_characteristic_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_gatt_unset_characteristic_changed_cb = int Function(); + +typedef _c_bt_gatt_watch_characteristic_changes = ffi.Int32 Function( + ffi.Pointer service, +); + +typedef _dart_bt_gatt_watch_characteristic_changes = int Function( + ffi.Pointer service, +); + +typedef _c_bt_gatt_unwatch_characteristic_changes = ffi.Int32 Function( + ffi.Pointer service, +); + +typedef _dart_bt_gatt_unwatch_characteristic_changes = int Function( + ffi.Pointer service, +); + +typedef _c_bt_gatt_get_characteristic_declaration = ffi.Int32 Function( + ffi.Pointer characteristic, + ffi.Pointer> uuid, + ffi.Pointer> value, + ffi.Pointer value_length, +); + +typedef _dart_bt_gatt_get_characteristic_declaration = int Function( + ffi.Pointer characteristic, + ffi.Pointer> uuid, + ffi.Pointer> value, + ffi.Pointer value_length, +); + +typedef _c_bt_gatt_set_characteristic_value = ffi.Int32 Function( + ffi.Pointer characteristic, + ffi.Pointer value, + ffi.Int32 value_length, +); + +typedef _dart_bt_gatt_set_characteristic_value = int Function( + ffi.Pointer characteristic, + ffi.Pointer value, + int value_length, +); + +typedef bt_gatt_characteristic_write_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef _c_bt_gatt_set_characteristic_value_request = ffi.Int32 Function( + ffi.Pointer characteristic, + ffi.Pointer value, + ffi.Int32 value_length, + ffi.Pointer> callback, +); + +typedef _dart_bt_gatt_set_characteristic_value_request = int Function( + ffi.Pointer characteristic, + ffi.Pointer value, + int value_length, + ffi.Pointer> callback, +); + +typedef _c_bt_gatt_clone_attribute_handle = ffi.Int32 Function( + ffi.Pointer> clone, + ffi.Pointer origin, +); + +typedef _dart_bt_gatt_clone_attribute_handle = int Function( + ffi.Pointer> clone, + ffi.Pointer origin, +); + +typedef _c_bt_gatt_destroy_attribute_handle = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_bt_gatt_destroy_attribute_handle = int Function( + ffi.Pointer handle, +); + +typedef bt_gatt_characteristic_read_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_gatt_read_characteristic_value = ffi.Int32 Function( + ffi.Pointer char_handle, + ffi.Pointer> callback, +); + +typedef _dart_bt_gatt_read_characteristic_value = int Function( + ffi.Pointer char_handle, + ffi.Pointer> callback, +); + +typedef bt_gatt_characteristic_descriptor_discovered_cb = ffi.Void Function( + ffi.Int32, + ffi.Uint8, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_gatt_discover_characteristic_descriptor = ffi.Int32 Function( + ffi.Pointer characteristic_handle, + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_discover_characteristic_descriptor = int Function( + ffi.Pointer characteristic_handle, + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _c_bt_gatt_get_value = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Pointer> value, + ffi.Pointer value_length, +); + +typedef _dart_bt_gatt_get_value = int Function( + ffi.Pointer gatt_handle, + ffi.Pointer> value, + ffi.Pointer value_length, +); + +typedef _c_bt_gatt_get_int_value = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Int32 type, + ffi.Int32 offset, + ffi.Pointer value, +); + +typedef _dart_bt_gatt_get_int_value = int Function( + ffi.Pointer gatt_handle, + int type, + int offset, + ffi.Pointer value, +); + +typedef _c_bt_gatt_get_float_value = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Int32 type, + ffi.Int32 offset, + ffi.Pointer value, +); + +typedef _dart_bt_gatt_get_float_value = int Function( + ffi.Pointer gatt_handle, + int type, + int offset, + ffi.Pointer value, +); + +typedef _c_bt_gatt_set_value = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Pointer value, + ffi.Int32 value_length, +); + +typedef _dart_bt_gatt_set_value = int Function( + ffi.Pointer gatt_handle, + ffi.Pointer value, + int value_length, +); + +typedef _c_bt_gatt_set_int_value = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Int32 type, + ffi.Int32 value, + ffi.Int32 offset, +); + +typedef _dart_bt_gatt_set_int_value = int Function( + ffi.Pointer gatt_handle, + int type, + int value, + int offset, +); + +typedef _c_bt_gatt_set_float_value = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Int32 type, + ffi.Int32 mantissa, + ffi.Int32 exponent, + ffi.Int32 offset, +); + +typedef _dart_bt_gatt_set_float_value = int Function( + ffi.Pointer gatt_handle, + int type, + int mantissa, + int exponent, + int offset, +); + +typedef _c_bt_gatt_get_uuid = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Pointer> uuid, +); + +typedef _dart_bt_gatt_get_uuid = int Function( + ffi.Pointer gatt_handle, + ffi.Pointer> uuid, +); + +typedef _c_bt_gatt_get_type = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Pointer gatt_type, +); + +typedef _dart_bt_gatt_get_type = int Function( + ffi.Pointer gatt_handle, + ffi.Pointer gatt_type, +); + +typedef _c_bt_gatt_service_get_client = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer> client, +); + +typedef _dart_bt_gatt_service_get_client = int Function( + ffi.Pointer service, + ffi.Pointer> client, +); + +typedef _c_bt_gatt_service_get_characteristic = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer uuid, + ffi.Pointer> characteristic, +); + +typedef _dart_bt_gatt_service_get_characteristic = int Function( + ffi.Pointer service, + ffi.Pointer uuid, + ffi.Pointer> characteristic, +); + +typedef bt_gatt_foreach_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_gatt_service_foreach_characteristics = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_service_foreach_characteristics = int Function( + ffi.Pointer service, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_gatt_service_get_included_service = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer uuid, + ffi.Pointer> included_service, +); + +typedef _dart_bt_gatt_service_get_included_service = int Function( + ffi.Pointer service, + ffi.Pointer uuid, + ffi.Pointer> included_service, +); + +typedef _c_bt_gatt_service_foreach_included_services = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_service_foreach_included_services = int Function( + ffi.Pointer service, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_gatt_characteristic_get_service = ffi.Int32 Function( + ffi.Pointer characteristic, + ffi.Pointer> service, +); + +typedef _dart_bt_gatt_characteristic_get_service = int Function( + ffi.Pointer characteristic, + ffi.Pointer> service, +); + +typedef _c_bt_gatt_characteristic_get_properties = ffi.Int32 Function( + ffi.Pointer characteristic, + ffi.Pointer properties, +); + +typedef _dart_bt_gatt_characteristic_get_properties = int Function( + ffi.Pointer characteristic, + ffi.Pointer properties, +); + +typedef _c_bt_gatt_characteristic_get_write_type = ffi.Int32 Function( + ffi.Pointer characteristic, + ffi.Pointer write_type, +); + +typedef _dart_bt_gatt_characteristic_get_write_type = int Function( + ffi.Pointer characteristic, + ffi.Pointer write_type, +); + +typedef _c_bt_gatt_characteristic_set_write_type = ffi.Int32 Function( + ffi.Pointer characteristic, + ffi.Int32 write_type, +); + +typedef _dart_bt_gatt_characteristic_set_write_type = int Function( + ffi.Pointer characteristic, + int write_type, +); + +typedef _c_bt_gatt_characteristic_get_descriptor = ffi.Int32 Function( + ffi.Pointer characteristic, + ffi.Pointer uuid, + ffi.Pointer> descriptor, +); + +typedef _dart_bt_gatt_characteristic_get_descriptor = int Function( + ffi.Pointer characteristic, + ffi.Pointer uuid, + ffi.Pointer> descriptor, +); + +typedef _c_bt_gatt_characteristic_foreach_descriptors = ffi.Int32 Function( + ffi.Pointer characteristic, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_characteristic_foreach_descriptors = int Function( + ffi.Pointer characteristic, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_gatt_descriptor_get_characteristic = ffi.Int32 Function( + ffi.Pointer descriptor, + ffi.Pointer> characteristic, +); + +typedef _dart_bt_gatt_descriptor_get_characteristic = int Function( + ffi.Pointer descriptor, + ffi.Pointer> characteristic, +); + +typedef _c_bt_gatt_client_create = ffi.Int32 Function( + ffi.Pointer remote_address, + ffi.Pointer> client, +); + +typedef _dart_bt_gatt_client_create = int Function( + ffi.Pointer remote_address, + ffi.Pointer> client, +); + +typedef _c_bt_gatt_client_destroy = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_bt_gatt_client_destroy = int Function( + ffi.Pointer client, +); + +typedef _c_bt_gatt_client_get_remote_address = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> remote_address, +); + +typedef _dart_bt_gatt_client_get_remote_address = int Function( + ffi.Pointer client, + ffi.Pointer> remote_address, +); + +typedef bt_gatt_client_request_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_gatt_client_read_value = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_client_read_value = int Function( + ffi.Pointer gatt_handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_gatt_client_write_value = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_client_write_value = int Function( + ffi.Pointer gatt_handle, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_gatt_client_request_att_mtu_change = ffi.Int32 Function( + ffi.Pointer client, + ffi.Uint32 mtu, +); + +typedef _dart_bt_gatt_client_request_att_mtu_change = int Function( + ffi.Pointer client, + int mtu, +); + +typedef _c_bt_gatt_client_get_att_mtu = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer mtu, +); + +typedef _dart_bt_gatt_client_get_att_mtu = int Function( + ffi.Pointer client, + ffi.Pointer mtu, +); + +typedef bt_gatt_client_att_mtu_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_gatt_client_set_att_mtu_changed_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_client_set_att_mtu_changed_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_gatt_client_unset_att_mtu_changed_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_bt_gatt_client_unset_att_mtu_changed_cb = int Function( + ffi.Pointer client, +); + +typedef bt_gatt_client_characteristic_value_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_gatt_client_set_characteristic_value_changed_cb = ffi.Int32 + Function( + ffi.Pointer characteristic, + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_client_set_characteristic_value_changed_cb = int Function( + ffi.Pointer characteristic, + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _c_bt_gatt_client_unset_characteristic_value_changed_cb = ffi.Int32 + Function( + ffi.Pointer characteristic, +); + +typedef _dart_bt_gatt_client_unset_characteristic_value_changed_cb = int + Function( + ffi.Pointer characteristic, +); + +typedef _c_bt_gatt_client_get_service = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer uuid, + ffi.Pointer> service, +); + +typedef _dart_bt_gatt_client_get_service = int Function( + ffi.Pointer client, + ffi.Pointer uuid, + ffi.Pointer> service, +); + +typedef _c_bt_gatt_client_foreach_services = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_client_foreach_services = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef bt_gatt_client_service_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_gatt_client_set_service_changed_cb = ffi.Int32 Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_client_set_service_changed_cb = int Function( + ffi.Pointer client, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_gatt_client_unset_service_changed_cb = ffi.Int32 Function( + ffi.Pointer client, +); + +typedef _dart_bt_gatt_client_unset_service_changed_cb = int Function( + ffi.Pointer client, +); + +typedef _c_bt_gatt_connect = ffi.Int32 Function( + ffi.Pointer address, + ffi.Uint8 auto_connect, +); + +typedef _dart_bt_gatt_connect = int Function( + ffi.Pointer address, + int auto_connect, +); + +typedef _c_bt_gatt_disconnect = ffi.Int32 Function( + ffi.Pointer address, +); + +typedef _dart_bt_gatt_disconnect = int Function( + ffi.Pointer address, +); + +typedef bt_gatt_connection_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_gatt_set_connection_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_set_connection_state_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_gatt_unset_connection_state_changed_cb = ffi.Int32 Function(); + +typedef _dart_bt_gatt_unset_connection_state_changed_cb = int Function(); + +typedef _c_bt_gatt_service_destroy = ffi.Int32 Function( + ffi.Pointer gatt_handle, +); + +typedef _dart_bt_gatt_service_destroy = int Function( + ffi.Pointer gatt_handle, +); + +typedef _c_bt_gatt_characteristic_destroy = ffi.Int32 Function( + ffi.Pointer gatt_handle, +); + +typedef _dart_bt_gatt_characteristic_destroy = int Function( + ffi.Pointer gatt_handle, +); + +typedef _c_bt_gatt_descriptor_destroy = ffi.Int32 Function( + ffi.Pointer gatt_handle, +); + +typedef _dart_bt_gatt_descriptor_destroy = int Function( + ffi.Pointer gatt_handle, +); + +typedef _c_bt_gatt_characteristic_get_permissions = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Pointer permissions, +); + +typedef _dart_bt_gatt_characteristic_get_permissions = int Function( + ffi.Pointer gatt_handle, + ffi.Pointer permissions, +); + +typedef _c_bt_gatt_descriptor_get_permissions = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Pointer permissions, +); + +typedef _dart_bt_gatt_descriptor_get_permissions = int Function( + ffi.Pointer gatt_handle, + ffi.Pointer permissions, +); + +typedef _c_bt_gatt_service_create = ffi.Int32 Function( + ffi.Pointer uuid, + ffi.Int32 type, + ffi.Pointer> service, +); + +typedef _dart_bt_gatt_service_create = int Function( + ffi.Pointer uuid, + int type, + ffi.Pointer> service, +); + +typedef _c_bt_gatt_service_add_characteristic = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer characteristic, +); + +typedef _dart_bt_gatt_service_add_characteristic = int Function( + ffi.Pointer service, + ffi.Pointer characteristic, +); + +typedef _c_bt_gatt_service_add_included_service = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer included_service, +); + +typedef _dart_bt_gatt_service_add_included_service = int Function( + ffi.Pointer service, + ffi.Pointer included_service, +); + +typedef _c_bt_gatt_service_get_server = ffi.Int32 Function( + ffi.Pointer service, + ffi.Pointer> server, +); + +typedef _dart_bt_gatt_service_get_server = int Function( + ffi.Pointer service, + ffi.Pointer> server, +); + +typedef _c_bt_gatt_characteristic_create = ffi.Int32 Function( + ffi.Pointer uuid, + ffi.Int32 permissions, + ffi.Int32 properties, + ffi.Pointer value, + ffi.Int32 value_length, + ffi.Pointer> characteristic, +); + +typedef _dart_bt_gatt_characteristic_create = int Function( + ffi.Pointer uuid, + int permissions, + int properties, + ffi.Pointer value, + int value_length, + ffi.Pointer> characteristic, +); + +typedef _c_bt_gatt_characteristic_add_descriptor = ffi.Int32 Function( + ffi.Pointer characteristic, + ffi.Pointer descriptor, +); + +typedef _dart_bt_gatt_characteristic_add_descriptor = int Function( + ffi.Pointer characteristic, + ffi.Pointer descriptor, +); + +typedef _c_bt_gatt_descriptor_create = ffi.Int32 Function( + ffi.Pointer uuid, + ffi.Int32 permissions, + ffi.Pointer value, + ffi.Int32 value_length, + ffi.Pointer> descriptor, +); + +typedef _dart_bt_gatt_descriptor_create = int Function( + ffi.Pointer uuid, + int permissions, + ffi.Pointer value, + int value_length, + ffi.Pointer> descriptor, +); + +typedef _c_bt_gatt_server_initialize = ffi.Int32 Function(); + +typedef _dart_bt_gatt_server_initialize = int Function(); + +typedef _c_bt_gatt_server_deinitialize = ffi.Int32 Function(); + +typedef _dart_bt_gatt_server_deinitialize = int Function(); + +typedef _c_bt_gatt_server_create = ffi.Int32 Function( + ffi.Pointer> server, +); + +typedef _dart_bt_gatt_server_create = int Function( + ffi.Pointer> server, +); + +typedef _c_bt_gatt_server_destroy = ffi.Int32 Function( + ffi.Pointer server, +); + +typedef _dart_bt_gatt_server_destroy = int Function( + ffi.Pointer server, +); + +typedef bt_gatt_server_read_value_requested_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_gatt_server_set_read_value_requested_cb = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_server_set_read_value_requested_cb = int Function( + ffi.Pointer gatt_handle, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef bt_gatt_server_characteristic_notification_state_changed_cb = ffi.Void + Function( + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_gatt_server_set_characteristic_notification_state_change_cb + = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Pointer< + ffi.NativeFunction< + bt_gatt_server_characteristic_notification_state_changed_cb>> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_server_set_characteristic_notification_state_change_cb + = int Function( + ffi.Pointer gatt_handle, + ffi.Pointer< + ffi.NativeFunction< + bt_gatt_server_characteristic_notification_state_changed_cb>> + callback, + ffi.Pointer user_data, +); + +typedef bt_gatt_server_write_value_requested_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Uint8, + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_gatt_server_set_write_value_requested_cb = ffi.Int32 Function( + ffi.Pointer gatt_handle, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_server_set_write_value_requested_cb = int Function( + ffi.Pointer gatt_handle, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_bt_gatt_server_register_service = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer service, +); + +typedef _dart_bt_gatt_server_register_service = int Function( + ffi.Pointer server, + ffi.Pointer service, +); + +typedef _c_bt_gatt_server_unregister_service = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer service, +); + +typedef _dart_bt_gatt_server_unregister_service = int Function( + ffi.Pointer server, + ffi.Pointer service, +); + +typedef _c_bt_gatt_server_unregister_all_services = ffi.Int32 Function( + ffi.Pointer server, +); + +typedef _dart_bt_gatt_server_unregister_all_services = int Function( + ffi.Pointer server, +); + +typedef _c_bt_gatt_server_start = ffi.Int32 Function(); + +typedef _dart_bt_gatt_server_start = int Function(); + +typedef _c_bt_gatt_server_send_response = ffi.Int32 Function( + ffi.Int32 request_id, + ffi.Int32 request_type, + ffi.Int32 offset, + ffi.Int32 resp_status, + ffi.Pointer value, + ffi.Int32 value_length, +); + +typedef _dart_bt_gatt_server_send_response = int Function( + int request_id, + int request_type, + int offset, + int resp_status, + ffi.Pointer value, + int value_length, +); + +typedef bt_gatt_server_notification_sent_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_bt_gatt_server_notify_characteristic_changed_value = ffi.Int32 + Function( + ffi.Pointer characteristic, + ffi.Pointer> callback, + ffi.Pointer device_address, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_server_notify_characteristic_changed_value = int Function( + ffi.Pointer characteristic, + ffi.Pointer> callback, + ffi.Pointer device_address, + ffi.Pointer user_data, +); + +typedef _c_bt_gatt_server_get_service = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer uuid, + ffi.Pointer> service, +); + +typedef _dart_bt_gatt_server_get_service = int Function( + ffi.Pointer server, + ffi.Pointer uuid, + ffi.Pointer> service, +); + +typedef _c_bt_gatt_server_foreach_services = ffi.Int32 Function( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_gatt_server_foreach_services = int Function( + ffi.Pointer server, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_pbap_client_initialize = ffi.Int32 Function(); + +typedef _dart_bt_pbap_client_initialize = int Function(); + +typedef _c_bt_pbap_client_deinitialize = ffi.Int32 Function(); + +typedef _dart_bt_pbap_client_deinitialize = int Function(); + +typedef bt_pbap_connection_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_pbap_client_set_connection_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_pbap_client_set_connection_state_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_pbap_client_unset_connection_state_changed_cb = ffi.Int32 + Function(); + +typedef _dart_bt_pbap_client_unset_connection_state_changed_cb = int Function(); + +typedef _c_bt_pbap_client_connect = ffi.Int32 Function( + ffi.Pointer address, +); + +typedef _dart_bt_pbap_client_connect = int Function( + ffi.Pointer address, +); + +typedef _c_bt_pbap_client_disconnect = ffi.Int32 Function( + ffi.Pointer address, +); + +typedef _dart_bt_pbap_client_disconnect = int Function( + ffi.Pointer address, +); + +typedef bt_pbap_phone_book_size_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_pbap_client_get_phone_book_size = ffi.Int32 Function( + ffi.Pointer address, + ffi.Int32 source, + ffi.Int32 folder_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_pbap_client_get_phone_book_size = int Function( + ffi.Pointer address, + int source, + int folder_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef bt_pbap_phone_book_received_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_bt_pbap_client_get_phone_book = ffi.Int32 Function( + ffi.Pointer address, + ffi.Int32 source, + ffi.Int32 folder_type, + ffi.Int32 format, + ffi.Int32 order, + ffi.Uint16 offset, + ffi.Uint16 max_list_count, + ffi.Uint32 fields, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_pbap_client_get_phone_book = int Function( + ffi.Pointer address, + int source, + int folder_type, + int format, + int order, + int offset, + int max_list_count, + int fields, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef bt_pbap_list_vcards_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_bt_pbap_client_get_list = ffi.Int32 Function( + ffi.Pointer address, + ffi.Int32 source, + ffi.Int32 folder_type, + ffi.Int32 order, + ffi.Uint16 offset, + ffi.Uint16 max_list_count, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_pbap_client_get_list = int Function( + ffi.Pointer address, + int source, + int folder_type, + int order, + int offset, + int max_list_count, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_pbap_client_pull_vcard = ffi.Int32 Function( + ffi.Pointer address, + ffi.Int32 source, + ffi.Int32 folder_type, + ffi.Int32 index, + ffi.Int32 format, + ffi.Uint32 fields, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_pbap_client_pull_vcard = int Function( + ffi.Pointer address, + int source, + int folder_type, + int index, + int format, + int fields, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_pbap_client_search_phone_book = ffi.Int32 Function( + ffi.Pointer address, + ffi.Int32 source, + ffi.Int32 folder_type, + ffi.Int32 search_attribute, + ffi.Pointer search_value, + ffi.Int32 order, + ffi.Uint16 offset, + ffi.Uint16 max_list_count, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_bt_pbap_client_search_phone_book = int Function( + ffi.Pointer address, + int source, + int folder_type, + int search_attribute, + ffi.Pointer search_value, + int order, + int offset, + int max_list_count, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_bt_adapter_le_scan_filter_create = ffi.Int32 Function( + ffi.Pointer> scan_filter, +); + +typedef _dart_bt_adapter_le_scan_filter_create = int Function( + ffi.Pointer> scan_filter, +); + +typedef _c_bt_adapter_le_scan_filter_destroy = ffi.Int32 Function( + ffi.Pointer scan_filter, +); + +typedef _dart_bt_adapter_le_scan_filter_destroy = int Function( + ffi.Pointer scan_filter, +); + +typedef _c_bt_adapter_le_scan_filter_set_device_address = ffi.Int32 Function( + ffi.Pointer scan_filter, + ffi.Pointer address, +); + +typedef _dart_bt_adapter_le_scan_filter_set_device_address = int Function( + ffi.Pointer scan_filter, + ffi.Pointer address, +); + +typedef _c_bt_adapter_le_scan_filter_set_device_name = ffi.Int32 Function( + ffi.Pointer scan_filter, + ffi.Pointer name, +); + +typedef _dart_bt_adapter_le_scan_filter_set_device_name = int Function( + ffi.Pointer scan_filter, + ffi.Pointer name, +); + +typedef _c_bt_adapter_le_scan_filter_set_service_uuid = ffi.Int32 Function( + ffi.Pointer scan_filter, + ffi.Pointer uuid, +); + +typedef _dart_bt_adapter_le_scan_filter_set_service_uuid = int Function( + ffi.Pointer scan_filter, + ffi.Pointer uuid, +); + +typedef _c_bt_adapter_le_scan_filter_set_service_uuid_with_mask = ffi.Int32 + Function( + ffi.Pointer scan_filter, + ffi.Pointer uuid, + ffi.Pointer mask, +); + +typedef _dart_bt_adapter_le_scan_filter_set_service_uuid_with_mask = int + Function( + ffi.Pointer scan_filter, + ffi.Pointer uuid, + ffi.Pointer mask, +); + +typedef _c_bt_adapter_le_scan_filter_set_service_solicitation_uuid = ffi.Int32 + Function( + ffi.Pointer scan_filter, + ffi.Pointer uuid, +); + +typedef _dart_bt_adapter_le_scan_filter_set_service_solicitation_uuid = int + Function( + ffi.Pointer scan_filter, + ffi.Pointer uuid, +); + +typedef _c_bt_adapter_le_scan_filter_set_service_solicitation_uuid_with_mask + = ffi.Int32 Function( + ffi.Pointer scan_filter, + ffi.Pointer uuid, + ffi.Pointer mask, +); + +typedef _dart_bt_adapter_le_scan_filter_set_service_solicitation_uuid_with_mask + = int Function( + ffi.Pointer scan_filter, + ffi.Pointer uuid, + ffi.Pointer mask, +); + +typedef _c_bt_adapter_le_scan_filter_set_service_data = ffi.Int32 Function( + ffi.Pointer scan_filter, + ffi.Pointer uuid, + ffi.Pointer data, + ffi.Uint32 data_len, +); + +typedef _dart_bt_adapter_le_scan_filter_set_service_data = int Function( + ffi.Pointer scan_filter, + ffi.Pointer uuid, + ffi.Pointer data, + int data_len, +); + +typedef _c_bt_adapter_le_scan_filter_set_service_data_with_mask = ffi.Int32 + Function( + ffi.Pointer scan_filter, + ffi.Pointer uuid, + ffi.Pointer data, + ffi.Uint32 data_len, + ffi.Pointer mask, + ffi.Uint32 mask_len, +); + +typedef _dart_bt_adapter_le_scan_filter_set_service_data_with_mask = int + Function( + ffi.Pointer scan_filter, + ffi.Pointer uuid, + ffi.Pointer data, + int data_len, + ffi.Pointer mask, + int mask_len, +); + +typedef _c_bt_adapter_le_scan_filter_set_manufacturer_data = ffi.Int32 Function( + ffi.Pointer scan_filter, + ffi.Int32 manufacturer_id, + ffi.Pointer data, + ffi.Uint32 data_len, +); + +typedef _dart_bt_adapter_le_scan_filter_set_manufacturer_data = int Function( + ffi.Pointer scan_filter, + int manufacturer_id, + ffi.Pointer data, + int data_len, +); + +typedef _c_bt_adapter_le_scan_filter_set_manufacturer_data_with_mask = ffi.Int32 + Function( + ffi.Pointer scan_filter, + ffi.Int32 manufacturer_id, + ffi.Pointer data, + ffi.Uint32 data_len, + ffi.Pointer mask, + ffi.Uint32 mask_len, +); + +typedef _dart_bt_adapter_le_scan_filter_set_manufacturer_data_with_mask = int + Function( + ffi.Pointer scan_filter, + int manufacturer_id, + ffi.Pointer data, + int data_len, + ffi.Pointer mask, + int mask_len, +); + +typedef _c_bt_adapter_le_scan_filter_set_type = ffi.Int32 Function( + ffi.Pointer scan_filter, + ffi.Int32 mode, +); + +typedef _dart_bt_adapter_le_scan_filter_set_type = int Function( + ffi.Pointer scan_filter, + int mode, +); + +typedef _c_bt_adapter_le_scan_filter_register = ffi.Int32 Function( + ffi.Pointer scan_filter, +); + +typedef _dart_bt_adapter_le_scan_filter_register = int Function( + ffi.Pointer scan_filter, +); + +typedef _c_bt_adapter_le_scan_filter_unregister = ffi.Int32 Function( + ffi.Pointer scan_filter, +); + +typedef _dart_bt_adapter_le_scan_filter_unregister = int Function( + ffi.Pointer scan_filter, +); + +typedef _c_bt_adapter_le_scan_filter_unregister_all = ffi.Int32 Function(); + +typedef _dart_bt_adapter_le_scan_filter_unregister_all = int Function(); + +typedef _c_connection_profile_create = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer keyword, + ffi.Pointer> profile, +); + +typedef _dart_connection_profile_create = int Function( + int type, + ffi.Pointer keyword, + ffi.Pointer> profile, +); + +typedef _c_connection_profile_destroy = ffi.Int32 Function( + ffi.Pointer profile, +); + +typedef _dart_connection_profile_destroy = int Function( + ffi.Pointer profile, +); + +typedef _c_connection_profile_clone = ffi.Int32 Function( + ffi.Pointer> cloned_profile, + ffi.Pointer origin_profile, +); + +typedef _dart_connection_profile_clone = int Function( + ffi.Pointer> cloned_profile, + ffi.Pointer origin_profile, +); + +typedef _c_connection_profile_get_id = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer> profile_id, +); + +typedef _dart_connection_profile_get_id = int Function( + ffi.Pointer profile, + ffi.Pointer> profile_id, +); + +typedef _c_connection_profile_get_name = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer> profile_name, +); + +typedef _dart_connection_profile_get_name = int Function( + ffi.Pointer profile, + ffi.Pointer> profile_name, +); + +typedef _c_connection_profile_get_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer type, +); + +typedef _dart_connection_profile_get_type = int Function( + ffi.Pointer profile, + ffi.Pointer type, +); + +typedef _c_connection_profile_get_network_interface_name = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer> interface_name, +); + +typedef _dart_connection_profile_get_network_interface_name = int Function( + ffi.Pointer profile, + ffi.Pointer> interface_name, +); + +typedef _c_connection_profile_refresh = ffi.Int32 Function( + ffi.Pointer profile, +); + +typedef _dart_connection_profile_refresh = int Function( + ffi.Pointer profile, +); + +typedef _c_connection_profile_get_state = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer state, +); + +typedef _dart_connection_profile_get_state = int Function( + ffi.Pointer profile, + ffi.Pointer state, +); + +typedef _c_connection_profile_get_ip_config_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Pointer type, +); + +typedef _dart_connection_profile_get_ip_config_type = int Function( + ffi.Pointer profile, + int address_family, + ffi.Pointer type, +); + +typedef _c_connection_profile_get_ip_address = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Pointer> ip_address, +); + +typedef _dart_connection_profile_get_ip_address = int Function( + ffi.Pointer profile, + int address_family, + ffi.Pointer> ip_address, +); + +typedef _c_connection_profile_get_subnet_mask = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Pointer> subnet_mask, +); + +typedef _dart_connection_profile_get_subnet_mask = int Function( + ffi.Pointer profile, + int address_family, + ffi.Pointer> subnet_mask, +); + +typedef _c_connection_profile_get_gateway_address = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Pointer> gateway_address, +); + +typedef _dart_connection_profile_get_gateway_address = int Function( + ffi.Pointer profile, + int address_family, + ffi.Pointer> gateway_address, +); + +typedef _c_connection_profile_get_dhcp_server_address = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Pointer> dhcp_server, +); + +typedef _dart_connection_profile_get_dhcp_server_address = int Function( + ffi.Pointer profile, + int address_family, + ffi.Pointer> dhcp_server, +); + +typedef _c_connection_profile_get_dhcp_lease_duration = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Pointer dhcp_lease_duration, +); + +typedef _dart_connection_profile_get_dhcp_lease_duration = int Function( + ffi.Pointer profile, + int address_family, + ffi.Pointer dhcp_lease_duration, +); + +typedef _c_connection_profile_get_dns_address = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 order, + ffi.Int32 address_family, + ffi.Pointer> dns_address, +); + +typedef _dart_connection_profile_get_dns_address = int Function( + ffi.Pointer profile, + int order, + int address_family, + ffi.Pointer> dns_address, +); + +typedef _c_connection_profile_get_proxy_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer type, +); + +typedef _dart_connection_profile_get_proxy_type = int Function( + ffi.Pointer profile, + ffi.Pointer type, +); + +typedef _c_connection_profile_get_proxy_address = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Pointer> proxy_address, +); + +typedef _dart_connection_profile_get_proxy_address = int Function( + ffi.Pointer profile, + int address_family, + ffi.Pointer> proxy_address, +); + +typedef _c_connection_profile_set_ip_config_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Int32 type, +); + +typedef _dart_connection_profile_set_ip_config_type = int Function( + ffi.Pointer profile, + int address_family, + int type, +); + +typedef _c_connection_profile_set_ip_address = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Pointer ip_address, +); + +typedef _dart_connection_profile_set_ip_address = int Function( + ffi.Pointer profile, + int address_family, + ffi.Pointer ip_address, +); + +typedef _c_connection_profile_set_subnet_mask = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Pointer subnet_mask, +); + +typedef _dart_connection_profile_set_subnet_mask = int Function( + ffi.Pointer profile, + int address_family, + ffi.Pointer subnet_mask, +); + +typedef _c_connection_profile_set_gateway_address = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Pointer gateway_address, +); + +typedef _dart_connection_profile_set_gateway_address = int Function( + ffi.Pointer profile, + int address_family, + ffi.Pointer gateway_address, +); + +typedef _c_connection_profile_set_dns_address = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 order, + ffi.Int32 address_family, + ffi.Pointer dns_address, +); + +typedef _dart_connection_profile_set_dns_address = int Function( + ffi.Pointer profile, + int order, + int address_family, + ffi.Pointer dns_address, +); + +typedef _c_connection_profile_set_proxy_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 type, +); + +typedef _dart_connection_profile_set_proxy_type = int Function( + ffi.Pointer profile, + int type, +); + +typedef _c_connection_profile_set_proxy_address = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Pointer proxy_address, +); + +typedef _dart_connection_profile_set_proxy_address = int Function( + ffi.Pointer profile, + int address_family, + ffi.Pointer proxy_address, +); + +typedef connection_profile_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_connection_profile_set_state_changed_cb = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_connection_profile_set_state_changed_cb = int Function( + ffi.Pointer profile, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_connection_profile_unset_state_changed_cb = ffi.Int32 Function( + ffi.Pointer profile, +); + +typedef _dart_connection_profile_unset_state_changed_cb = int Function( + ffi.Pointer profile, +); + +typedef _c_connection_profile_get_ipv6_state = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer state, +); + +typedef _dart_connection_profile_get_ipv6_state = int Function( + ffi.Pointer profile, + ffi.Pointer state, +); + +typedef _c_connection_profile_set_dns_config_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Int32 type, +); + +typedef _dart_connection_profile_set_dns_config_type = int Function( + ffi.Pointer profile, + int address_family, + int type, +); + +typedef _c_connection_profile_get_dns_config_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Pointer type, +); + +typedef _dart_connection_profile_get_dns_config_type = int Function( + ffi.Pointer profile, + int address_family, + ffi.Pointer type, +); + +typedef _c_connection_profile_get_prefix_length = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Pointer prefix_len, +); + +typedef _dart_connection_profile_get_prefix_length = int Function( + ffi.Pointer profile, + int address_family, + ffi.Pointer prefix_len, +); + +typedef _c_connection_profile_set_prefix_length = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 address_family, + ffi.Int32 prefix_len, +); + +typedef _dart_connection_profile_set_prefix_length = int Function( + ffi.Pointer profile, + int address_family, + int prefix_len, +); + +typedef _c_connection_profile_get_wifi_essid = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer> essid, +); + +typedef _dart_connection_profile_get_wifi_essid = int Function( + ffi.Pointer profile, + ffi.Pointer> essid, +); + +typedef _c_connection_profile_get_wifi_bssid = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer> bssid, +); + +typedef _dart_connection_profile_get_wifi_bssid = int Function( + ffi.Pointer profile, + ffi.Pointer> bssid, +); + +typedef _c_connection_profile_get_wifi_rssi = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer rssi, +); + +typedef _dart_connection_profile_get_wifi_rssi = int Function( + ffi.Pointer profile, + ffi.Pointer rssi, +); + +typedef _c_connection_profile_get_wifi_frequency = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer frequency, +); + +typedef _dart_connection_profile_get_wifi_frequency = int Function( + ffi.Pointer profile, + ffi.Pointer frequency, +); + +typedef _c_connection_profile_get_wifi_max_speed = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer max_speed, +); + +typedef _dart_connection_profile_get_wifi_max_speed = int Function( + ffi.Pointer profile, + ffi.Pointer max_speed, +); + +typedef _c_connection_profile_get_wifi_security_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer type, +); + +typedef _dart_connection_profile_get_wifi_security_type = int Function( + ffi.Pointer profile, + ffi.Pointer type, +); + +typedef _c_connection_profile_get_wifi_encryption_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer type, +); + +typedef _dart_connection_profile_get_wifi_encryption_type = int Function( + ffi.Pointer profile, + ffi.Pointer type, +); + +typedef _c_connection_profile_is_wifi_passphrase_required = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer required, +); + +typedef _dart_connection_profile_is_wifi_passphrase_required = int Function( + ffi.Pointer profile, + ffi.Pointer required, +); + +typedef _c_connection_profile_set_wifi_passphrase = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer passphrase, +); + +typedef _dart_connection_profile_set_wifi_passphrase = int Function( + ffi.Pointer profile, + ffi.Pointer passphrase, +); + +typedef _c_connection_profile_is_wifi_wps_supported = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer supported, +); + +typedef _dart_connection_profile_is_wifi_wps_supported = int Function( + ffi.Pointer profile, + ffi.Pointer supported, +); + +typedef _c_connection_profile_get_cellular_service_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer type, +); + +typedef _dart_connection_profile_get_cellular_service_type = int Function( + ffi.Pointer profile, + ffi.Pointer type, +); + +typedef _c_connection_profile_get_cellular_apn = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer> apn, +); + +typedef _dart_connection_profile_get_cellular_apn = int Function( + ffi.Pointer profile, + ffi.Pointer> apn, +); + +typedef _c_connection_profile_get_cellular_auth_info = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer type, + ffi.Pointer> user_name, + ffi.Pointer> password, +); + +typedef _dart_connection_profile_get_cellular_auth_info = int Function( + ffi.Pointer profile, + ffi.Pointer type, + ffi.Pointer> user_name, + ffi.Pointer> password, +); + +typedef _c_connection_profile_get_cellular_home_url = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer> home_url, +); + +typedef _dart_connection_profile_get_cellular_home_url = int Function( + ffi.Pointer profile, + ffi.Pointer> home_url, +); + +typedef _c_connection_profile_get_cellular_pdn_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer type, +); + +typedef _dart_connection_profile_get_cellular_pdn_type = int Function( + ffi.Pointer profile, + ffi.Pointer type, +); + +typedef _c_connection_profile_get_cellular_roam_pdn_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer type, +); + +typedef _dart_connection_profile_get_cellular_roam_pdn_type = int Function( + ffi.Pointer profile, + ffi.Pointer type, +); + +typedef _c_connection_profile_is_cellular_roaming = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer is_roaming, +); + +typedef _dart_connection_profile_is_cellular_roaming = int Function( + ffi.Pointer profile, + ffi.Pointer is_roaming, +); + +typedef _c_connection_profile_is_cellular_hidden = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer is_hidden, +); + +typedef _dart_connection_profile_is_cellular_hidden = int Function( + ffi.Pointer profile, + ffi.Pointer is_hidden, +); + +typedef _c_connection_profile_is_cellular_editable = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer is_editable, +); + +typedef _dart_connection_profile_is_cellular_editable = int Function( + ffi.Pointer profile, + ffi.Pointer is_editable, +); + +typedef _c_connection_profile_is_cellular_default = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer is_default, +); + +typedef _dart_connection_profile_is_cellular_default = int Function( + ffi.Pointer profile, + ffi.Pointer is_default, +); + +typedef _c_connection_profile_set_cellular_service_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 service_type, +); + +typedef _dart_connection_profile_set_cellular_service_type = int Function( + ffi.Pointer profile, + int service_type, +); + +typedef _c_connection_profile_set_cellular_apn = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer apn, +); + +typedef _dart_connection_profile_set_cellular_apn = int Function( + ffi.Pointer profile, + ffi.Pointer apn, +); + +typedef _c_connection_profile_set_cellular_auth_info = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 type, + ffi.Pointer user_name, + ffi.Pointer password, +); + +typedef _dart_connection_profile_set_cellular_auth_info = int Function( + ffi.Pointer profile, + int type, + ffi.Pointer user_name, + ffi.Pointer password, +); + +typedef _c_connection_profile_set_cellular_home_url = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Pointer home_url, +); + +typedef _dart_connection_profile_set_cellular_home_url = int Function( + ffi.Pointer profile, + ffi.Pointer home_url, +); + +typedef _c_connection_profile_set_cellular_pdn_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 type, +); + +typedef _dart_connection_profile_set_cellular_pdn_type = int Function( + ffi.Pointer profile, + int type, +); + +typedef _c_connection_profile_set_cellular_roam_pdn_type = ffi.Int32 Function( + ffi.Pointer profile, + ffi.Int32 type, +); + +typedef _dart_connection_profile_set_cellular_roam_pdn_type = int Function( + ffi.Pointer profile, + int type, +); + +typedef _c_connection_create = ffi.Int32 Function( + ffi.Pointer> connection, +); + +typedef _dart_connection_create = int Function( + ffi.Pointer> connection, +); + +typedef _c_connection_destroy = ffi.Int32 Function( + ffi.Pointer connection, +); + +typedef _dart_connection_destroy = int Function( + ffi.Pointer connection, +); + +typedef _c_connection_get_type = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer type, +); + +typedef _dart_connection_get_type = int Function( + ffi.Pointer connection, + ffi.Pointer type, +); + +typedef _c_connection_get_ip_address = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Int32 address_family, + ffi.Pointer> ip_address, +); + +typedef _dart_connection_get_ip_address = int Function( + ffi.Pointer connection, + int address_family, + ffi.Pointer> ip_address, +); + +typedef _c_connection_get_proxy = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Int32 address_family, + ffi.Pointer> proxy, +); + +typedef _dart_connection_get_proxy = int Function( + ffi.Pointer connection, + int address_family, + ffi.Pointer> proxy, +); + +typedef _c_connection_get_mac_address = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Int32 type, + ffi.Pointer> mac_addr, +); + +typedef _dart_connection_get_mac_address = int Function( + ffi.Pointer connection, + int type, + ffi.Pointer> mac_addr, +); + +typedef _c_connection_is_metered_network = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer is_metered, +); + +typedef _dart_connection_is_metered_network = int Function( + ffi.Pointer connection, + ffi.Pointer is_metered, +); + +typedef _c_connection_get_cellular_state = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer state, +); + +typedef _dart_connection_get_cellular_state = int Function( + ffi.Pointer connection, + ffi.Pointer state, +); + +typedef _c_connection_get_wifi_state = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer state, +); + +typedef _dart_connection_get_wifi_state = int Function( + ffi.Pointer connection, + ffi.Pointer state, +); + +typedef _c_connection_get_ethernet_state = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer state, +); + +typedef _dart_connection_get_ethernet_state = int Function( + ffi.Pointer connection, + ffi.Pointer state, +); + +typedef _c_connection_get_ethernet_cable_state = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer state, +); + +typedef _dart_connection_get_ethernet_cable_state = int Function( + ffi.Pointer connection, + ffi.Pointer state, +); + +typedef connection_ethernet_cable_state_chaged_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_connection_set_ethernet_cable_state_chaged_cb = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_connection_set_ethernet_cable_state_chaged_cb = int Function( + ffi.Pointer connection, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_connection_unset_ethernet_cable_state_chaged_cb = ffi.Int32 Function( + ffi.Pointer connection, +); + +typedef _dart_connection_unset_ethernet_cable_state_chaged_cb = int Function( + ffi.Pointer connection, +); + +typedef connection_ethernet_cable_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_connection_set_ethernet_cable_state_changed_cb = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_connection_set_ethernet_cable_state_changed_cb = int Function( + ffi.Pointer connection, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_connection_unset_ethernet_cable_state_changed_cb = ffi.Int32 + Function( + ffi.Pointer connection, +); + +typedef _dart_connection_unset_ethernet_cable_state_changed_cb = int Function( + ffi.Pointer connection, +); + +typedef _c_connection_get_bt_state = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer state, +); + +typedef _dart_connection_get_bt_state = int Function( + ffi.Pointer connection, + ffi.Pointer state, +); + +typedef connection_type_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_connection_set_type_changed_cb = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_connection_set_type_changed_cb = int Function( + ffi.Pointer connection, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_connection_unset_type_changed_cb = ffi.Int32 Function( + ffi.Pointer connection, +); + +typedef _dart_connection_unset_type_changed_cb = int Function( + ffi.Pointer connection, +); + +typedef connection_address_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_connection_set_ip_address_changed_cb = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_connection_set_ip_address_changed_cb = int Function( + ffi.Pointer connection, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_connection_unset_ip_address_changed_cb = ffi.Int32 Function( + ffi.Pointer connection, +); + +typedef _dart_connection_unset_ip_address_changed_cb = int Function( + ffi.Pointer connection, +); + +typedef _c_connection_set_proxy_address_changed_cb = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_connection_set_proxy_address_changed_cb = int Function( + ffi.Pointer connection, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_connection_unset_proxy_address_changed_cb = ffi.Int32 Function( + ffi.Pointer connection, +); + +typedef _dart_connection_unset_proxy_address_changed_cb = int Function( + ffi.Pointer connection, +); + +typedef _c_connection_add_profile = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer profile, +); + +typedef _dart_connection_add_profile = int Function( + ffi.Pointer connection, + ffi.Pointer profile, +); + +typedef _c_connection_remove_profile = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer profile, +); + +typedef _dart_connection_remove_profile = int Function( + ffi.Pointer connection, + ffi.Pointer profile, +); + +typedef _c_connection_update_profile = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer profile, +); + +typedef _dart_connection_update_profile = int Function( + ffi.Pointer connection, + ffi.Pointer profile, +); + +typedef _c_connection_get_profile_iterator = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Int32 type, + ffi.Pointer> profile_iterator, +); + +typedef _dart_connection_get_profile_iterator = int Function( + ffi.Pointer connection, + int type, + ffi.Pointer> profile_iterator, +); + +typedef _c_connection_profile_iterator_next = ffi.Int32 Function( + ffi.Pointer profile_iterator, + ffi.Pointer> profile, +); + +typedef _dart_connection_profile_iterator_next = int Function( + ffi.Pointer profile_iterator, + ffi.Pointer> profile, +); + +typedef _c_connection_profile_iterator_has_next = ffi.Uint8 Function( + ffi.Pointer profile_iterator, +); + +typedef _dart_connection_profile_iterator_has_next = int Function( + ffi.Pointer profile_iterator, +); + +typedef _c_connection_destroy_profile_iterator = ffi.Int32 Function( + ffi.Pointer profile_iterator, +); + +typedef _dart_connection_destroy_profile_iterator = int Function( + ffi.Pointer profile_iterator, +); + +typedef _c_connection_get_current_profile = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer> profile, +); + +typedef _dart_connection_get_current_profile = int Function( + ffi.Pointer connection, + ffi.Pointer> profile, +); + +typedef _c_connection_get_default_cellular_service_profile = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Int32 type, + ffi.Pointer> profile, +); + +typedef _dart_connection_get_default_cellular_service_profile = int Function( + ffi.Pointer connection, + int type, + ffi.Pointer> profile, +); + +typedef _c_connection_set_default_cellular_service_profile = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Int32 type, + ffi.Pointer profile, +); + +typedef _dart_connection_set_default_cellular_service_profile = int Function( + ffi.Pointer connection, + int type, + ffi.Pointer profile, +); + +typedef connection_set_default_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_connection_set_default_cellular_service_profile_async = ffi.Int32 + Function( + ffi.Pointer connection, + ffi.Int32 type, + ffi.Pointer profile, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_connection_set_default_cellular_service_profile_async = int + Function( + ffi.Pointer connection, + int type, + ffi.Pointer profile, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef connection_opened_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_connection_open_profile = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer profile, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_connection_open_profile = int Function( + ffi.Pointer connection, + ffi.Pointer profile, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef connection_closed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_connection_close_profile = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer profile, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_connection_close_profile = int Function( + ffi.Pointer connection, + ffi.Pointer profile, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef connection_reset_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_connection_reset_profile = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Int32 type, + ffi.Int32 id, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_connection_reset_profile = int Function( + ffi.Pointer connection, + int type, + int id, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_connection_add_route = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer interface_name, + ffi.Pointer host_address, +); + +typedef _dart_connection_add_route = int Function( + ffi.Pointer connection, + ffi.Pointer interface_name, + ffi.Pointer host_address, +); + +typedef _c_connection_remove_route = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer interface_name, + ffi.Pointer host_address, +); + +typedef _dart_connection_remove_route = int Function( + ffi.Pointer connection, + ffi.Pointer interface_name, + ffi.Pointer host_address, +); + +typedef _c_connection_add_route_ipv6 = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer interface_name, + ffi.Pointer host_address, + ffi.Pointer gateway, +); + +typedef _dart_connection_add_route_ipv6 = int Function( + ffi.Pointer connection, + ffi.Pointer interface_name, + ffi.Pointer host_address, + ffi.Pointer gateway, +); + +typedef _c_connection_remove_route_ipv6 = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Pointer interface_name, + ffi.Pointer host_address, + ffi.Pointer gateway, +); + +typedef _dart_connection_remove_route_ipv6 = int Function( + ffi.Pointer connection, + ffi.Pointer interface_name, + ffi.Pointer host_address, + ffi.Pointer gateway, +); + +typedef _c_connection_add_route_entry = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Int32 address_family, + ffi.Pointer interface_name, + ffi.Pointer host_address, + ffi.Pointer gateway, +); + +typedef _dart_connection_add_route_entry = int Function( + ffi.Pointer connection, + int address_family, + ffi.Pointer interface_name, + ffi.Pointer host_address, + ffi.Pointer gateway, +); + +typedef _c_connection_remove_route_entry = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Int32 address_family, + ffi.Pointer interface_name, + ffi.Pointer host_address, + ffi.Pointer gateway, +); + +typedef _dart_connection_remove_route_entry = int Function( + ffi.Pointer connection, + int address_family, + ffi.Pointer interface_name, + ffi.Pointer host_address, + ffi.Pointer gateway, +); + +typedef connection_ipv6_address_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_connection_foreach_ipv6_address = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Int32 connection_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_connection_foreach_ipv6_address = int Function( + ffi.Pointer connection, + int connection_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_connection_get_statistics = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Int32 connection_type, + ffi.Int32 statistics_type, + ffi.Pointer size, +); + +typedef _dart_connection_get_statistics = int Function( + ffi.Pointer connection, + int connection_type, + int statistics_type, + ffi.Pointer size, +); + +typedef _c_connection_reset_statistics = ffi.Int32 Function( + ffi.Pointer connection, + ffi.Int32 connection_type, + ffi.Int32 statistics_type, +); + +typedef _dart_connection_reset_statistics = int Function( + ffi.Pointer connection, + int connection_type, + int statistics_type, +); + +typedef _c_dnssd_initialize = ffi.Int32 Function(); + +typedef _dart_dnssd_initialize = int Function(); + +typedef _c_dnssd_deinitialize = ffi.Int32 Function(); + +typedef _dart_dnssd_deinitialize = int Function(); + +typedef _c_dnssd_create_local_service = ffi.Int32 Function( + ffi.Pointer service_type, + ffi.Pointer dnssd_service, +); + +typedef _dart_dnssd_create_local_service = int Function( + ffi.Pointer service_type, + ffi.Pointer dnssd_service, +); + +typedef _c_dnssd_destroy_local_service = ffi.Int32 Function( + ffi.Uint32 dnssd_service, +); + +typedef _dart_dnssd_destroy_local_service = int Function( + int dnssd_service, +); + +typedef _c_dnssd_service_set_name = ffi.Int32 Function( + ffi.Uint32 local_service, + ffi.Pointer service_name, +); + +typedef _dart_dnssd_service_set_name = int Function( + int local_service, + ffi.Pointer service_name, +); + +typedef _c_dnssd_service_set_port = ffi.Int32 Function( + ffi.Uint32 local_service, + ffi.Int32 port, +); + +typedef _dart_dnssd_service_set_port = int Function( + int local_service, + int port, +); + +typedef _c_dnssd_service_add_txt_record = ffi.Int32 Function( + ffi.Uint32 local_service, + ffi.Pointer key, + ffi.Uint16 length, + ffi.Pointer value, +); + +typedef _dart_dnssd_service_add_txt_record = int Function( + int local_service, + ffi.Pointer key, + int length, + ffi.Pointer value, +); + +typedef _c_dnssd_service_remove_txt_record = ffi.Int32 Function( + ffi.Uint32 local_service, + ffi.Pointer key, +); + +typedef _dart_dnssd_service_remove_txt_record = int Function( + int local_service, + ffi.Pointer key, +); + +typedef _c_dnssd_service_set_record = ffi.Int32 Function( + ffi.Uint32 local_service, + ffi.Uint16 type, + ffi.Uint16 length, + ffi.Pointer data, +); + +typedef _dart_dnssd_service_set_record = int Function( + int local_service, + int type, + int length, + ffi.Pointer data, +); + +typedef _c_dnssd_service_unset_record = ffi.Int32 Function( + ffi.Uint32 local_service, + ffi.Uint16 type, +); + +typedef _dart_dnssd_service_unset_record = int Function( + int local_service, + int type, +); + +typedef dnssd_registered_cb = ffi.Void Function( + ffi.Int32, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_dnssd_register_local_service = ffi.Int32 Function( + ffi.Uint32 local_service, + ffi.Pointer> register_cb, + ffi.Pointer user_data, +); + +typedef _dart_dnssd_register_local_service = int Function( + int local_service, + ffi.Pointer> register_cb, + ffi.Pointer user_data, +); + +typedef _c_dnssd_deregister_local_service = ffi.Int32 Function( + ffi.Uint32 local_service, +); + +typedef _dart_dnssd_deregister_local_service = int Function( + int local_service, +); + +typedef dnssd_found_cb = ffi.Void Function( + ffi.Int32, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_dnssd_start_browsing_service = ffi.Int32 Function( + ffi.Pointer service_type, + ffi.Pointer dnssd_service, + ffi.Pointer> found_cb, + ffi.Pointer user_data, +); + +typedef _dart_dnssd_start_browsing_service = int Function( + ffi.Pointer service_type, + ffi.Pointer dnssd_service, + ffi.Pointer> found_cb, + ffi.Pointer user_data, +); + +typedef _c_dnssd_stop_browsing_service = ffi.Int32 Function( + ffi.Uint32 dnssd_service, +); + +typedef _dart_dnssd_stop_browsing_service = int Function( + int dnssd_service, +); + +typedef _c_dnssd_service_get_type = ffi.Int32 Function( + ffi.Uint32 dnssd_service, + ffi.Pointer> service_type, +); + +typedef _dart_dnssd_service_get_type = int Function( + int dnssd_service, + ffi.Pointer> service_type, +); + +typedef _c_dnssd_service_get_name = ffi.Int32 Function( + ffi.Uint32 dnssd_service, + ffi.Pointer> service_name, +); + +typedef _dart_dnssd_service_get_name = int Function( + int dnssd_service, + ffi.Pointer> service_name, +); + +typedef _c_dnssd_service_get_ip = ffi.Int32 Function( + ffi.Uint32 dnssd_service, + ffi.Pointer> ip_v4_address, + ffi.Pointer> ip_v6_address, +); + +typedef _dart_dnssd_service_get_ip = int Function( + int dnssd_service, + ffi.Pointer> ip_v4_address, + ffi.Pointer> ip_v6_address, +); + +typedef _c_dnssd_service_get_port = ffi.Int32 Function( + ffi.Uint32 dnssd_service, + ffi.Pointer port, +); + +typedef _dart_dnssd_service_get_port = int Function( + int dnssd_service, + ffi.Pointer port, +); + +typedef _c_dnssd_service_get_all_txt_record = ffi.Int32 Function( + ffi.Uint32 dnssd_service, + ffi.Pointer length, + ffi.Pointer> value, +); + +typedef _dart_dnssd_service_get_all_txt_record = int Function( + int dnssd_service, + ffi.Pointer length, + ffi.Pointer> value, +); + +typedef _c_http_init = ffi.Int32 Function(); + +typedef _dart_http_init = int Function(); + +typedef _c_http_deinit = ffi.Int32 Function(); + +typedef _dart_http_deinit = int Function(); + +typedef _c_http_session_create = ffi.Int32 Function( + ffi.Int32 mode, + ffi.Pointer> http_session, +); + +typedef _dart_http_session_create = int Function( + int mode, + ffi.Pointer> http_session, +); + +typedef _c_http_session_destroy = ffi.Int32 Function( + ffi.Pointer http_session, +); + +typedef _dart_http_session_destroy = int Function( + ffi.Pointer http_session, +); + +typedef _c_http_session_open_transaction = ffi.Int32 Function( + ffi.Pointer http_session, + ffi.Int32 method, + ffi.Pointer> http_transaction, +); + +typedef _dart_http_session_open_transaction = int Function( + ffi.Pointer http_session, + int method, + ffi.Pointer> http_transaction, +); + +typedef _c_http_session_set_auto_redirection = ffi.Int32 Function( + ffi.Pointer http_session, + ffi.Uint8 auto_redirection, +); + +typedef _dart_http_session_set_auto_redirection = int Function( + ffi.Pointer http_session, + int auto_redirection, +); + +typedef _c_http_session_get_auto_redirection = ffi.Int32 Function( + ffi.Pointer http_session, + ffi.Pointer auto_redirect, +); + +typedef _dart_http_session_get_auto_redirection = int Function( + ffi.Pointer http_session, + ffi.Pointer auto_redirect, +); + +typedef _c_http_session_get_active_transaction_count = ffi.Int32 Function( + ffi.Pointer http_session, + ffi.Pointer active_transaction_count, +); + +typedef _dart_http_session_get_active_transaction_count = int Function( + ffi.Pointer http_session, + ffi.Pointer active_transaction_count, +); + +typedef _c_http_session_get_max_transaction_count = ffi.Int32 Function( + ffi.Pointer http_session, + ffi.Pointer transaction_count, +); + +typedef _dart_http_session_get_max_transaction_count = int Function( + ffi.Pointer http_session, + ffi.Pointer transaction_count, +); + +typedef _c_http_session_destroy_all_transactions = ffi.Int32 Function( + ffi.Pointer http_session, +); + +typedef _dart_http_session_destroy_all_transactions = int Function( + ffi.Pointer http_session, +); + +typedef _c_http_transaction_submit = ffi.Int32 Function( + ffi.Pointer http_transaction, +); + +typedef _dart_http_transaction_submit = int Function( + ffi.Pointer http_transaction, +); + +typedef _c_http_transaction_destroy = ffi.Int32 Function( + ffi.Pointer http_transaction, +); + +typedef _dart_http_transaction_destroy = int Function( + ffi.Pointer http_transaction, +); + +typedef http_transaction_header_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_http_transaction_set_received_header_cb = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer> header_cb, + ffi.Pointer user_data, +); + +typedef _dart_http_transaction_set_received_header_cb = int Function( + ffi.Pointer http_transaction, + ffi.Pointer> header_cb, + ffi.Pointer user_data, +); + +typedef http_transaction_body_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_http_transaction_set_received_body_cb = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer> body_cb, + ffi.Pointer user_data, +); + +typedef _dart_http_transaction_set_received_body_cb = int Function( + ffi.Pointer http_transaction, + ffi.Pointer> body_cb, + ffi.Pointer user_data, +); + +typedef http_transaction_write_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_http_transaction_set_uploaded_cb = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer> write_cb, + ffi.Pointer user_data, +); + +typedef _dart_http_transaction_set_uploaded_cb = int Function( + ffi.Pointer http_transaction, + ffi.Pointer> write_cb, + ffi.Pointer user_data, +); + +typedef http_transaction_completed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_http_transaction_set_completed_cb = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer> completed_cb, + ffi.Pointer user_data, +); + +typedef _dart_http_transaction_set_completed_cb = int Function( + ffi.Pointer http_transaction, + ffi.Pointer> completed_cb, + ffi.Pointer user_data, +); + +typedef http_transaction_aborted_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_http_transaction_set_aborted_cb = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer> aborted_cb, + ffi.Pointer user_data, +); + +typedef _dart_http_transaction_set_aborted_cb = int Function( + ffi.Pointer http_transaction, + ffi.Pointer> aborted_cb, + ffi.Pointer user_data, +); + +typedef http_transaction_progress_cb = ffi.Void Function( + ffi.Pointer, + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Double, + ffi.Pointer, +); + +typedef _c_http_transaction_set_progress_cb = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer> progress_cb, + ffi.Pointer user_data, +); + +typedef _dart_http_transaction_set_progress_cb = int Function( + ffi.Pointer http_transaction, + ffi.Pointer> progress_cb, + ffi.Pointer user_data, +); + +typedef _c_http_transaction_set_timeout = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Int32 timeout, +); + +typedef _dart_http_transaction_set_timeout = int Function( + ffi.Pointer http_transaction, + int timeout, +); + +typedef _c_http_transaction_get_timeout = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer timeout, +); + +typedef _dart_http_transaction_get_timeout = int Function( + ffi.Pointer http_transaction, + ffi.Pointer timeout, +); + +typedef _c_http_transaction_resume = ffi.Int32 Function( + ffi.Pointer http_transaction, +); + +typedef _dart_http_transaction_resume = int Function( + ffi.Pointer http_transaction, +); + +typedef _c_http_transaction_pause = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Int32 pause_type, +); + +typedef _dart_http_transaction_pause = int Function( + ffi.Pointer http_transaction, + int pause_type, +); + +typedef _c_http_transaction_cancel = ffi.Int32 Function( + ffi.Pointer http_transaction, +); + +typedef _dart_http_transaction_cancel = int Function( + ffi.Pointer http_transaction, +); + +typedef _c_http_transaction_set_ready_to_write = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Uint8 read_to_write, +); + +typedef _dart_http_transaction_set_ready_to_write = int Function( + ffi.Pointer http_transaction, + int read_to_write, +); + +typedef _c_http_transaction_set_interface_name = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer interface_name, +); + +typedef _dart_http_transaction_set_interface_name = int Function( + ffi.Pointer http_transaction, + ffi.Pointer interface_name, +); + +typedef _c_http_transaction_get_interface_name = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer> interface_name, +); + +typedef _dart_http_transaction_get_interface_name = int Function( + ffi.Pointer http_transaction, + ffi.Pointer> interface_name, +); + +typedef _c_http_transaction_set_server_certificate_verification = ffi.Int32 + Function( + ffi.Pointer http_transaction, + ffi.Uint8 verify, +); + +typedef _dart_http_transaction_set_server_certificate_verification = int + Function( + ffi.Pointer http_transaction, + int verify, +); + +typedef _c_http_transaction_get_server_certificate_verification = ffi.Int32 + Function( + ffi.Pointer http_transaction, + ffi.Pointer verify, +); + +typedef _dart_http_transaction_get_server_certificate_verification = int + Function( + ffi.Pointer http_transaction, + ffi.Pointer verify, +); + +typedef _c_http_transaction_header_add_field = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer field_name, + ffi.Pointer field_value, +); + +typedef _dart_http_transaction_header_add_field = int Function( + ffi.Pointer http_transaction, + ffi.Pointer field_name, + ffi.Pointer field_value, +); + +typedef _c_http_transaction_header_remove_field = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer field_name, +); + +typedef _dart_http_transaction_header_remove_field = int Function( + ffi.Pointer http_transaction, + ffi.Pointer field_name, +); + +typedef _c_http_transaction_header_get_field_value = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer field_name, + ffi.Pointer> field_value, +); + +typedef _dart_http_transaction_header_get_field_value = int Function( + ffi.Pointer http_transaction, + ffi.Pointer field_name, + ffi.Pointer> field_value, +); + +typedef _c_http_transaction_request_set_method = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Int32 method, +); + +typedef _dart_http_transaction_request_set_method = int Function( + ffi.Pointer http_transaction, + int method, +); + +typedef _c_http_transaction_request_get_method = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer method, +); + +typedef _dart_http_transaction_request_get_method = int Function( + ffi.Pointer http_transaction, + ffi.Pointer method, +); + +typedef _c_http_transaction_request_set_version = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Int32 version, +); + +typedef _dart_http_transaction_request_set_version = int Function( + ffi.Pointer http_transaction, + int version, +); + +typedef _c_http_transaction_request_get_version = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer version, +); + +typedef _dart_http_transaction_request_get_version = int Function( + ffi.Pointer http_transaction, + ffi.Pointer version, +); + +typedef _c_http_transaction_request_set_uri = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer host_uri, +); + +typedef _dart_http_transaction_request_set_uri = int Function( + ffi.Pointer http_transaction, + ffi.Pointer host_uri, +); + +typedef _c_http_transaction_request_get_uri = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer> host_uri, +); + +typedef _dart_http_transaction_request_get_uri = int Function( + ffi.Pointer http_transaction, + ffi.Pointer> host_uri, +); + +typedef _c_http_transaction_request_set_accept_encoding = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer encoding, +); + +typedef _dart_http_transaction_request_set_accept_encoding = int Function( + ffi.Pointer http_transaction, + ffi.Pointer encoding, +); + +typedef _c_http_transaction_request_get_accept_encoding = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer> encoding, +); + +typedef _dart_http_transaction_request_get_accept_encoding = int Function( + ffi.Pointer http_transaction, + ffi.Pointer> encoding, +); + +typedef _c_http_transaction_request_set_cookie = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer cookie, +); + +typedef _dart_http_transaction_request_set_cookie = int Function( + ffi.Pointer http_transaction, + ffi.Pointer cookie, +); + +typedef _c_http_transaction_request_get_cookie = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer> cookie, +); + +typedef _dart_http_transaction_request_get_cookie = int Function( + ffi.Pointer http_transaction, + ffi.Pointer> cookie, +); + +typedef _c_http_transaction_request_write_body = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer body, +); + +typedef _dart_http_transaction_request_write_body = int Function( + ffi.Pointer http_transaction, + ffi.Pointer body, +); + +typedef _c_http_transaction_request_set_upload_file = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer file_path, +); + +typedef _dart_http_transaction_request_set_upload_file = int Function( + ffi.Pointer http_transaction, + ffi.Pointer file_path, +); + +typedef _c_http_transaction_response_get_status_code = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer status_code, +); + +typedef _dart_http_transaction_response_get_status_code = int Function( + ffi.Pointer http_transaction, + ffi.Pointer status_code, +); + +typedef _c_http_transaction_response_get_status_text = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer> status_text, +); + +typedef _dart_http_transaction_response_get_status_text = int Function( + ffi.Pointer http_transaction, + ffi.Pointer> status_text, +); + +typedef _c_http_transaction_response_get_version = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer version, +); + +typedef _dart_http_transaction_response_get_version = int Function( + ffi.Pointer http_transaction, + ffi.Pointer version, +); + +typedef _c_http_transaction_open_authentication = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer> http_auth_transaction, +); + +typedef _dart_http_transaction_open_authentication = int Function( + ffi.Pointer http_transaction, + ffi.Pointer> http_auth_transaction, +); + +typedef _c_http_transaction_set_credentials = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer user_name, + ffi.Pointer password, +); + +typedef _dart_http_transaction_set_credentials = int Function( + ffi.Pointer http_transaction, + ffi.Pointer user_name, + ffi.Pointer password, +); + +typedef _c_http_transaction_get_credentials = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer> user_name, + ffi.Pointer> password, +); + +typedef _dart_http_transaction_get_credentials = int Function( + ffi.Pointer http_transaction, + ffi.Pointer> user_name, + ffi.Pointer> password, +); + +typedef _c_http_transaction_set_http_auth_scheme = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Int32 auth_scheme, +); + +typedef _dart_http_transaction_set_http_auth_scheme = int Function( + ffi.Pointer http_transaction, + int auth_scheme, +); + +typedef _c_http_transaction_get_http_auth_scheme = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer auth_scheme, +); + +typedef _dart_http_transaction_get_http_auth_scheme = int Function( + ffi.Pointer http_transaction, + ffi.Pointer auth_scheme, +); + +typedef _c_http_transaction_get_realm = ffi.Int32 Function( + ffi.Pointer http_transaction, + ffi.Pointer> realm, +); + +typedef _dart_http_transaction_get_realm = int Function( + ffi.Pointer http_transaction, + ffi.Pointer> realm, +); + +typedef _c_iotcon_list_create = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer> list, +); + +typedef _dart_iotcon_list_create = int Function( + int type, + ffi.Pointer> list, +); + +typedef _c_iotcon_list_destroy = ffi.Int32 Function( + ffi.Pointer list, +); + +typedef _dart_iotcon_list_destroy = int Function( + ffi.Pointer list, +); + +typedef _c_iotcon_list_add_int = ffi.Int32 Function( + ffi.Pointer list, + ffi.Int32 val, + ffi.Int32 pos, +); + +typedef _dart_iotcon_list_add_int = int Function( + ffi.Pointer list, + int val, + int pos, +); + +typedef _c_iotcon_list_add_bool = ffi.Int32 Function( + ffi.Pointer list, + ffi.Uint8 val, + ffi.Int32 pos, +); + +typedef _dart_iotcon_list_add_bool = int Function( + ffi.Pointer list, + int val, + int pos, +); + +typedef _c_iotcon_list_add_double = ffi.Int32 Function( + ffi.Pointer list, + ffi.Double val, + ffi.Int32 pos, +); + +typedef _dart_iotcon_list_add_double = int Function( + ffi.Pointer list, + double val, + int pos, +); + +typedef _c_iotcon_list_add_str = ffi.Int32 Function( + ffi.Pointer list, + ffi.Pointer val, + ffi.Int32 pos, +); + +typedef _dart_iotcon_list_add_str = int Function( + ffi.Pointer list, + ffi.Pointer val, + int pos, +); + +typedef _c_iotcon_list_add_byte_str = ffi.Int32 Function( + ffi.Pointer list, + ffi.Pointer val, + ffi.Int32 len, + ffi.Int32 pos, +); + +typedef _dart_iotcon_list_add_byte_str = int Function( + ffi.Pointer list, + ffi.Pointer val, + int len, + int pos, +); + +typedef _c_iotcon_list_add_list = ffi.Int32 Function( + ffi.Pointer list, + ffi.Pointer val, + ffi.Int32 pos, +); + +typedef _dart_iotcon_list_add_list = int Function( + ffi.Pointer list, + ffi.Pointer val, + int pos, +); + +typedef _c_iotcon_list_add_attributes = ffi.Int32 Function( + ffi.Pointer list, + ffi.Pointer val, + ffi.Int32 pos, +); + +typedef _dart_iotcon_list_add_attributes = int Function( + ffi.Pointer list, + ffi.Pointer val, + int pos, +); + +typedef _c_iotcon_list_get_nth_int = ffi.Int32 Function( + ffi.Pointer list, + ffi.Int32 pos, + ffi.Pointer val, +); + +typedef _dart_iotcon_list_get_nth_int = int Function( + ffi.Pointer list, + int pos, + ffi.Pointer val, +); + +typedef _c_iotcon_list_get_nth_bool = ffi.Int32 Function( + ffi.Pointer list, + ffi.Int32 pos, + ffi.Pointer val, +); + +typedef _dart_iotcon_list_get_nth_bool = int Function( + ffi.Pointer list, + int pos, + ffi.Pointer val, +); + +typedef _c_iotcon_list_get_nth_double = ffi.Int32 Function( + ffi.Pointer list, + ffi.Int32 pos, + ffi.Pointer val, +); + +typedef _dart_iotcon_list_get_nth_double = int Function( + ffi.Pointer list, + int pos, + ffi.Pointer val, +); + +typedef _c_iotcon_list_get_nth_str = ffi.Int32 Function( + ffi.Pointer list, + ffi.Int32 pos, + ffi.Pointer> val, +); + +typedef _dart_iotcon_list_get_nth_str = int Function( + ffi.Pointer list, + int pos, + ffi.Pointer> val, +); + +typedef _c_iotcon_list_get_nth_byte_str = ffi.Int32 Function( + ffi.Pointer list, + ffi.Int32 pos, + ffi.Pointer> val, + ffi.Pointer len, +); + +typedef _dart_iotcon_list_get_nth_byte_str = int Function( + ffi.Pointer list, + int pos, + ffi.Pointer> val, + ffi.Pointer len, +); + +typedef _c_iotcon_list_get_nth_list = ffi.Int32 Function( + ffi.Pointer src, + ffi.Int32 pos, + ffi.Pointer> dest, +); + +typedef _dart_iotcon_list_get_nth_list = int Function( + ffi.Pointer src, + int pos, + ffi.Pointer> dest, +); + +typedef _c_iotcon_list_get_nth_attributes = ffi.Int32 Function( + ffi.Pointer list, + ffi.Int32 pos, + ffi.Pointer> attributes, +); + +typedef _dart_iotcon_list_get_nth_attributes = int Function( + ffi.Pointer list, + int pos, + ffi.Pointer> attributes, +); + +typedef _c_iotcon_list_remove_nth = ffi.Int32 Function( + ffi.Pointer list, + ffi.Int32 pos, +); + +typedef _dart_iotcon_list_remove_nth = int Function( + ffi.Pointer list, + int pos, +); + +typedef _c_iotcon_list_get_type = ffi.Int32 Function( + ffi.Pointer list, + ffi.Pointer type, +); + +typedef _dart_iotcon_list_get_type = int Function( + ffi.Pointer list, + ffi.Pointer type, +); + +typedef _c_iotcon_list_get_length = ffi.Int32 Function( + ffi.Pointer list, + ffi.Pointer length, +); + +typedef _dart_iotcon_list_get_length = int Function( + ffi.Pointer list, + ffi.Pointer length, +); + +typedef iotcon_list_int_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_iotcon_list_foreach_int = ffi.Int32 Function( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_list_foreach_int = int Function( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef iotcon_list_bool_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_iotcon_list_foreach_bool = ffi.Int32 Function( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_list_foreach_bool = int Function( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef iotcon_list_double_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Double, + ffi.Pointer, +); + +typedef _c_iotcon_list_foreach_double = ffi.Int32 Function( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_list_foreach_double = int Function( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef iotcon_list_byte_str_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_iotcon_list_foreach_byte_str = ffi.Int32 Function( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_list_foreach_byte_str = int Function( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef iotcon_list_str_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_list_foreach_str = ffi.Int32 Function( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_list_foreach_str = int Function( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef iotcon_list_list_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_list_foreach_list = ffi.Int32 Function( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_list_foreach_list = int Function( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef iotcon_list_attributes_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_list_foreach_attributes = ffi.Int32 Function( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_list_foreach_attributes = int Function( + ffi.Pointer list, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_query_create = ffi.Int32 Function( + ffi.Pointer> query, +); + +typedef _dart_iotcon_query_create = int Function( + ffi.Pointer> query, +); + +typedef _c_iotcon_query_destroy = ffi.Int32 Function( + ffi.Pointer query, +); + +typedef _dart_iotcon_query_destroy = int Function( + ffi.Pointer query, +); + +typedef _c_iotcon_query_get_resource_type = ffi.Int32 Function( + ffi.Pointer query, + ffi.Pointer> resource_type, +); + +typedef _dart_iotcon_query_get_resource_type = int Function( + ffi.Pointer query, + ffi.Pointer> resource_type, +); + +typedef _c_iotcon_query_get_interface = ffi.Int32 Function( + ffi.Pointer query, + ffi.Pointer> resource_iface, +); + +typedef _dart_iotcon_query_get_interface = int Function( + ffi.Pointer query, + ffi.Pointer> resource_iface, +); + +typedef _c_iotcon_query_set_resource_type = ffi.Int32 Function( + ffi.Pointer query, + ffi.Pointer resource_type, +); + +typedef _dart_iotcon_query_set_resource_type = int Function( + ffi.Pointer query, + ffi.Pointer resource_type, +); + +typedef _c_iotcon_query_set_interface = ffi.Int32 Function( + ffi.Pointer query, + ffi.Pointer resource_iface, +); + +typedef _dart_iotcon_query_set_interface = int Function( + ffi.Pointer query, + ffi.Pointer resource_iface, +); + +typedef _c_iotcon_query_add = ffi.Int32 Function( + ffi.Pointer query, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_iotcon_query_add = int Function( + ffi.Pointer query, + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_iotcon_query_remove = ffi.Int32 Function( + ffi.Pointer query, + ffi.Pointer key, +); + +typedef _dart_iotcon_query_remove = int Function( + ffi.Pointer query, + ffi.Pointer key, +); + +typedef _c_iotcon_query_lookup = ffi.Int32 Function( + ffi.Pointer query, + ffi.Pointer key, + ffi.Pointer> data, +); + +typedef _dart_iotcon_query_lookup = int Function( + ffi.Pointer query, + ffi.Pointer key, + ffi.Pointer> data, +); + +typedef iotcon_query_foreach_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_query_foreach = ffi.Int32 Function( + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_query_foreach = int Function( + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_attributes_create = ffi.Int32 Function( + ffi.Pointer> attributes, +); + +typedef _dart_iotcon_attributes_create = int Function( + ffi.Pointer> attributes, +); + +typedef _c_iotcon_attributes_destroy = ffi.Int32 Function( + ffi.Pointer attributes, +); + +typedef _dart_iotcon_attributes_destroy = int Function( + ffi.Pointer attributes, +); + +typedef _c_iotcon_attributes_clone = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer> attributes_clone, +); + +typedef _dart_iotcon_attributes_clone = int Function( + ffi.Pointer attributes, + ffi.Pointer> attributes_clone, +); + +typedef _c_iotcon_attributes_add_int = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Int32 val, +); + +typedef _dart_iotcon_attributes_add_int = int Function( + ffi.Pointer attributes, + ffi.Pointer key, + int val, +); + +typedef _c_iotcon_attributes_add_bool = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Uint8 val, +); + +typedef _dart_iotcon_attributes_add_bool = int Function( + ffi.Pointer attributes, + ffi.Pointer key, + int val, +); + +typedef _c_iotcon_attributes_add_double = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Double val, +); + +typedef _dart_iotcon_attributes_add_double = int Function( + ffi.Pointer attributes, + ffi.Pointer key, + double val, +); + +typedef _c_iotcon_attributes_add_str = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, +); + +typedef _dart_iotcon_attributes_add_str = int Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, +); + +typedef _c_iotcon_attributes_add_byte_str = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, + ffi.Int32 len, +); + +typedef _dart_iotcon_attributes_add_byte_str = int Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, + int len, +); + +typedef _c_iotcon_attributes_add_list = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer list, +); + +typedef _dart_iotcon_attributes_add_list = int Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer list, +); + +typedef _c_iotcon_attributes_add_attributes = ffi.Int32 Function( + ffi.Pointer dest, + ffi.Pointer key, + ffi.Pointer src, +); + +typedef _dart_iotcon_attributes_add_attributes = int Function( + ffi.Pointer dest, + ffi.Pointer key, + ffi.Pointer src, +); + +typedef _c_iotcon_attributes_add_null = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, +); + +typedef _dart_iotcon_attributes_add_null = int Function( + ffi.Pointer attributes, + ffi.Pointer key, +); + +typedef _c_iotcon_attributes_get_int = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, +); + +typedef _dart_iotcon_attributes_get_int = int Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, +); + +typedef _c_iotcon_attributes_get_bool = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, +); + +typedef _dart_iotcon_attributes_get_bool = int Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, +); + +typedef _c_iotcon_attributes_get_double = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, +); + +typedef _dart_iotcon_attributes_get_double = int Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer val, +); + +typedef _c_iotcon_attributes_get_str = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer> val, +); + +typedef _dart_iotcon_attributes_get_str = int Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer> val, +); + +typedef _c_iotcon_attributes_get_byte_str = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer> val, + ffi.Pointer len, +); + +typedef _dart_iotcon_attributes_get_byte_str = int Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer> val, + ffi.Pointer len, +); + +typedef _c_iotcon_attributes_get_list = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer> list, +); + +typedef _dart_iotcon_attributes_get_list = int Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer> list, +); + +typedef _c_iotcon_attributes_get_attributes = ffi.Int32 Function( + ffi.Pointer src, + ffi.Pointer key, + ffi.Pointer> dest, +); + +typedef _dart_iotcon_attributes_get_attributes = int Function( + ffi.Pointer src, + ffi.Pointer key, + ffi.Pointer> dest, +); + +typedef _c_iotcon_attributes_is_null = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer is_null, +); + +typedef _dart_iotcon_attributes_is_null = int Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer is_null, +); + +typedef _c_iotcon_attributes_remove = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, +); + +typedef _dart_iotcon_attributes_remove = int Function( + ffi.Pointer attributes, + ffi.Pointer key, +); + +typedef _c_iotcon_attributes_get_type = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer type, +); + +typedef _dart_iotcon_attributes_get_type = int Function( + ffi.Pointer attributes, + ffi.Pointer key, + ffi.Pointer type, +); + +typedef iotcon_attributes_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_attributes_foreach = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_attributes_foreach = int Function( + ffi.Pointer attributes, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_attributes_get_keys_count = ffi.Int32 Function( + ffi.Pointer attributes, + ffi.Pointer count, +); + +typedef _dart_iotcon_attributes_get_keys_count = int Function( + ffi.Pointer attributes, + ffi.Pointer count, +); + +typedef _c_iotcon_options_create = ffi.Int32 Function( + ffi.Pointer> options, +); + +typedef _dart_iotcon_options_create = int Function( + ffi.Pointer> options, +); + +typedef _c_iotcon_options_destroy = ffi.Int32 Function( + ffi.Pointer options, +); + +typedef _dart_iotcon_options_destroy = int Function( + ffi.Pointer options, +); + +typedef _c_iotcon_options_add = ffi.Int32 Function( + ffi.Pointer options, + ffi.Uint16 id, + ffi.Pointer data, +); + +typedef _dart_iotcon_options_add = int Function( + ffi.Pointer options, + int id, + ffi.Pointer data, +); + +typedef _c_iotcon_options_remove = ffi.Int32 Function( + ffi.Pointer options, + ffi.Uint16 id, +); + +typedef _dart_iotcon_options_remove = int Function( + ffi.Pointer options, + int id, +); + +typedef _c_iotcon_options_lookup = ffi.Int32 Function( + ffi.Pointer options, + ffi.Uint16 id, + ffi.Pointer> data, +); + +typedef _dart_iotcon_options_lookup = int Function( + ffi.Pointer options, + int id, + ffi.Pointer> data, +); + +typedef iotcon_options_foreach_cb = ffi.Uint8 Function( + ffi.Uint16, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_options_foreach = ffi.Int32 Function( + ffi.Pointer options, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_options_foreach = int Function( + ffi.Pointer options, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_representation_create = ffi.Int32 Function( + ffi.Pointer> repr, +); + +typedef _dart_iotcon_representation_create = int Function( + ffi.Pointer> repr, +); + +typedef _c_iotcon_representation_destroy = ffi.Int32 Function( + ffi.Pointer repr, +); + +typedef _dart_iotcon_representation_destroy = int Function( + ffi.Pointer repr, +); + +typedef _c_iotcon_representation_clone = ffi.Int32 Function( + ffi.Pointer src, + ffi.Pointer> dest, +); + +typedef _dart_iotcon_representation_clone = int Function( + ffi.Pointer src, + ffi.Pointer> dest, +); + +typedef _c_iotcon_representation_set_uri_path = ffi.Int32 Function( + ffi.Pointer repr, + ffi.Pointer uri_path, +); + +typedef _dart_iotcon_representation_set_uri_path = int Function( + ffi.Pointer repr, + ffi.Pointer uri_path, +); + +typedef _c_iotcon_representation_get_uri_path = ffi.Int32 Function( + ffi.Pointer repr, + ffi.Pointer> uri_path, +); + +typedef _dart_iotcon_representation_get_uri_path = int Function( + ffi.Pointer repr, + ffi.Pointer> uri_path, +); + +typedef _c_iotcon_representation_set_resource_types = ffi.Int32 Function( + ffi.Pointer repr, + ffi.Pointer types, +); + +typedef _dart_iotcon_representation_set_resource_types = int Function( + ffi.Pointer repr, + ffi.Pointer types, +); + +typedef _c_iotcon_representation_get_resource_types = ffi.Int32 Function( + ffi.Pointer repr, + ffi.Pointer> types, +); + +typedef _dart_iotcon_representation_get_resource_types = int Function( + ffi.Pointer repr, + ffi.Pointer> types, +); + +typedef _c_iotcon_representation_set_resource_interfaces = ffi.Int32 Function( + ffi.Pointer repr, + ffi.Pointer ifaces, +); + +typedef _dart_iotcon_representation_set_resource_interfaces = int Function( + ffi.Pointer repr, + ffi.Pointer ifaces, +); + +typedef _c_iotcon_representation_get_resource_interfaces = ffi.Int32 Function( + ffi.Pointer repr, + ffi.Pointer> ifaces, +); + +typedef _dart_iotcon_representation_get_resource_interfaces = int Function( + ffi.Pointer repr, + ffi.Pointer> ifaces, +); + +typedef _c_iotcon_representation_set_attributes = ffi.Int32 Function( + ffi.Pointer repr, + ffi.Pointer attributes, +); + +typedef _dart_iotcon_representation_set_attributes = int Function( + ffi.Pointer repr, + ffi.Pointer attributes, +); + +typedef _c_iotcon_representation_get_attributes = ffi.Int32 Function( + ffi.Pointer repr, + ffi.Pointer> attributes, +); + +typedef _dart_iotcon_representation_get_attributes = int Function( + ffi.Pointer repr, + ffi.Pointer> attributes, +); + +typedef _c_iotcon_representation_add_child = ffi.Int32 Function( + ffi.Pointer parent, + ffi.Pointer child, +); + +typedef _dart_iotcon_representation_add_child = int Function( + ffi.Pointer parent, + ffi.Pointer child, +); + +typedef _c_iotcon_representation_remove_child = ffi.Int32 Function( + ffi.Pointer parent, + ffi.Pointer child, +); + +typedef _dart_iotcon_representation_remove_child = int Function( + ffi.Pointer parent, + ffi.Pointer child, +); + +typedef iotcon_children_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_representation_foreach_children = ffi.Int32 Function( + ffi.Pointer parent, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_representation_foreach_children = int Function( + ffi.Pointer parent, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_representation_get_child_count = ffi.Int32 Function( + ffi.Pointer parent, + ffi.Pointer count, +); + +typedef _dart_iotcon_representation_get_child_count = int Function( + ffi.Pointer parent, + ffi.Pointer count, +); + +typedef _c_iotcon_representation_get_nth_child = ffi.Int32 Function( + ffi.Pointer parent, + ffi.Int32 pos, + ffi.Pointer> child, +); + +typedef _dart_iotcon_representation_get_nth_child = int Function( + ffi.Pointer parent, + int pos, + ffi.Pointer> child, +); + +typedef _c_iotcon_resource_types_create = ffi.Int32 Function( + ffi.Pointer> types, +); + +typedef _dart_iotcon_resource_types_create = int Function( + ffi.Pointer> types, +); + +typedef _c_iotcon_resource_types_destroy = ffi.Int32 Function( + ffi.Pointer types, +); + +typedef _dart_iotcon_resource_types_destroy = int Function( + ffi.Pointer types, +); + +typedef _c_iotcon_resource_types_add = ffi.Int32 Function( + ffi.Pointer types, + ffi.Pointer type, +); + +typedef _dart_iotcon_resource_types_add = int Function( + ffi.Pointer types, + ffi.Pointer type, +); + +typedef _c_iotcon_resource_types_remove = ffi.Int32 Function( + ffi.Pointer types, + ffi.Pointer type, +); + +typedef _dart_iotcon_resource_types_remove = int Function( + ffi.Pointer types, + ffi.Pointer type, +); + +typedef iotcon_resource_types_foreach_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_resource_types_foreach = ffi.Int32 Function( + ffi.Pointer types, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_resource_types_foreach = int Function( + ffi.Pointer types, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_resource_types_clone = ffi.Int32 Function( + ffi.Pointer src, + ffi.Pointer> dest, +); + +typedef _dart_iotcon_resource_types_clone = int Function( + ffi.Pointer src, + ffi.Pointer> dest, +); + +typedef _c_iotcon_resource_interfaces_create = ffi.Int32 Function( + ffi.Pointer> ifaces, +); + +typedef _dart_iotcon_resource_interfaces_create = int Function( + ffi.Pointer> ifaces, +); + +typedef _c_iotcon_resource_interfaces_destroy = ffi.Int32 Function( + ffi.Pointer ifaces, +); + +typedef _dart_iotcon_resource_interfaces_destroy = int Function( + ffi.Pointer ifaces, +); + +typedef _c_iotcon_resource_interfaces_add = ffi.Int32 Function( + ffi.Pointer ifaces, + ffi.Pointer iface, +); + +typedef _dart_iotcon_resource_interfaces_add = int Function( + ffi.Pointer ifaces, + ffi.Pointer iface, +); + +typedef _c_iotcon_resource_interfaces_remove = ffi.Int32 Function( + ffi.Pointer ifaces, + ffi.Pointer iface, +); + +typedef _dart_iotcon_resource_interfaces_remove = int Function( + ffi.Pointer ifaces, + ffi.Pointer iface, +); + +typedef iotcon_resource_interfaces_foreach_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_resource_interfaces_foreach = ffi.Int32 Function( + ffi.Pointer ifaces, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_resource_interfaces_foreach = int Function( + ffi.Pointer ifaces, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_resource_interfaces_clone = ffi.Int32 Function( + ffi.Pointer src, + ffi.Pointer> dest, +); + +typedef _dart_iotcon_resource_interfaces_clone = int Function( + ffi.Pointer src, + ffi.Pointer> dest, +); + +typedef iotcon_request_handler_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_resource_create = ffi.Int32 Function( + ffi.Pointer uri_path, + ffi.Pointer res_types, + ffi.Pointer ifaces, + ffi.Uint8 policies, + ffi.Pointer> cb, + ffi.Pointer user_data, + ffi.Pointer> resource_handle, +); + +typedef _dart_iotcon_resource_create = int Function( + ffi.Pointer uri_path, + ffi.Pointer res_types, + ffi.Pointer ifaces, + int policies, + ffi.Pointer> cb, + ffi.Pointer user_data, + ffi.Pointer> resource_handle, +); + +typedef _c_iotcon_resource_destroy = ffi.Int32 Function( + ffi.Pointer resource_handle, +); + +typedef _dart_iotcon_resource_destroy = int Function( + ffi.Pointer resource_handle, +); + +typedef _c_iotcon_resource_bind_interface = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer iface, +); + +typedef _dart_iotcon_resource_bind_interface = int Function( + ffi.Pointer resource, + ffi.Pointer iface, +); + +typedef _c_iotcon_resource_bind_type = ffi.Int32 Function( + ffi.Pointer resource_handle, + ffi.Pointer resource_type, +); + +typedef _dart_iotcon_resource_bind_type = int Function( + ffi.Pointer resource_handle, + ffi.Pointer resource_type, +); + +typedef _c_iotcon_resource_set_request_handler = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_resource_set_request_handler = int Function( + ffi.Pointer resource, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_resource_bind_child_resource = ffi.Int32 Function( + ffi.Pointer parent, + ffi.Pointer child, +); + +typedef _dart_iotcon_resource_bind_child_resource = int Function( + ffi.Pointer parent, + ffi.Pointer child, +); + +typedef _c_iotcon_resource_unbind_child_resource = ffi.Int32 Function( + ffi.Pointer parent, + ffi.Pointer child, +); + +typedef _dart_iotcon_resource_unbind_child_resource = int Function( + ffi.Pointer parent, + ffi.Pointer child, +); + +typedef _c_iotcon_resource_notify = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer repr, + ffi.Pointer observers, + ffi.Int32 qos, +); + +typedef _dart_iotcon_resource_notify = int Function( + ffi.Pointer resource, + ffi.Pointer repr, + ffi.Pointer observers, + int qos, +); + +typedef _c_iotcon_resource_get_child_count = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer count, +); + +typedef _dart_iotcon_resource_get_child_count = int Function( + ffi.Pointer resource, + ffi.Pointer count, +); + +typedef _c_iotcon_resource_get_nth_child = ffi.Int32 Function( + ffi.Pointer parent, + ffi.Int32 index, + ffi.Pointer> child, +); + +typedef _dart_iotcon_resource_get_nth_child = int Function( + ffi.Pointer parent, + int index, + ffi.Pointer> child, +); + +typedef _c_iotcon_resource_get_uri_path = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer> uri_path, +); + +typedef _dart_iotcon_resource_get_uri_path = int Function( + ffi.Pointer resource, + ffi.Pointer> uri_path, +); + +typedef _c_iotcon_resource_get_types = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer> types, +); + +typedef _dart_iotcon_resource_get_types = int Function( + ffi.Pointer resource, + ffi.Pointer> types, +); + +typedef _c_iotcon_resource_get_interfaces = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer> ifaces, +); + +typedef _dart_iotcon_resource_get_interfaces = int Function( + ffi.Pointer resource, + ffi.Pointer> ifaces, +); + +typedef _c_iotcon_resource_get_policies = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer policies, +); + +typedef _dart_iotcon_resource_get_policies = int Function( + ffi.Pointer resource, + ffi.Pointer policies, +); + +typedef iotcon_lite_resource_post_request_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_lite_resource_create = ffi.Int32 Function( + ffi.Pointer uri_path, + ffi.Pointer res_types, + ffi.Uint8 policies, + ffi.Pointer attributes, + ffi.Pointer> cb, + ffi.Pointer user_data, + ffi.Pointer> resource_handle, +); + +typedef _dart_iotcon_lite_resource_create = int Function( + ffi.Pointer uri_path, + ffi.Pointer res_types, + int policies, + ffi.Pointer attributes, + ffi.Pointer> cb, + ffi.Pointer user_data, + ffi.Pointer> resource_handle, +); + +typedef _c_iotcon_lite_resource_destroy = ffi.Int32 Function( + ffi.Pointer resource, +); + +typedef _dart_iotcon_lite_resource_destroy = int Function( + ffi.Pointer resource, +); + +typedef _c_iotcon_lite_resource_update_attributes = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer attributes, +); + +typedef _dart_iotcon_lite_resource_update_attributes = int Function( + ffi.Pointer resource, + ffi.Pointer attributes, +); + +typedef _c_iotcon_lite_resource_get_attributes = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer> attributes, +); + +typedef _dart_iotcon_lite_resource_get_attributes = int Function( + ffi.Pointer resource, + ffi.Pointer> attributes, +); + +typedef _c_iotcon_response_create = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer> response, +); + +typedef _dart_iotcon_response_create = int Function( + ffi.Pointer request, + ffi.Pointer> response, +); + +typedef _c_iotcon_response_destroy = ffi.Int32 Function( + ffi.Pointer resp, +); + +typedef _dart_iotcon_response_destroy = int Function( + ffi.Pointer resp, +); + +typedef _c_iotcon_response_get_options = ffi.Int32 Function( + ffi.Pointer resp, + ffi.Pointer> options, +); + +typedef _dart_iotcon_response_get_options = int Function( + ffi.Pointer resp, + ffi.Pointer> options, +); + +typedef _c_iotcon_response_get_representation = ffi.Int32 Function( + ffi.Pointer resp, + ffi.Pointer> repr, +); + +typedef _dart_iotcon_response_get_representation = int Function( + ffi.Pointer resp, + ffi.Pointer> repr, +); + +typedef _c_iotcon_response_get_result = ffi.Int32 Function( + ffi.Pointer resp, + ffi.Pointer result, +); + +typedef _dart_iotcon_response_get_result = int Function( + ffi.Pointer resp, + ffi.Pointer result, +); + +typedef _c_iotcon_response_set_result = ffi.Int32 Function( + ffi.Pointer resp, + ffi.Int32 result, +); + +typedef _dart_iotcon_response_set_result = int Function( + ffi.Pointer resp, + int result, +); + +typedef _c_iotcon_response_set_representation = ffi.Int32 Function( + ffi.Pointer resp, + ffi.Pointer repr, +); + +typedef _dart_iotcon_response_set_representation = int Function( + ffi.Pointer resp, + ffi.Pointer repr, +); + +typedef _c_iotcon_response_set_options = ffi.Int32 Function( + ffi.Pointer resp, + ffi.Pointer options, +); + +typedef _dart_iotcon_response_set_options = int Function( + ffi.Pointer resp, + ffi.Pointer options, +); + +typedef _c_iotcon_response_send = ffi.Int32 Function( + ffi.Pointer resp, +); + +typedef _dart_iotcon_response_send = int Function( + ffi.Pointer resp, +); + +typedef _c_iotcon_observers_create = ffi.Int32 Function( + ffi.Pointer> observers, +); + +typedef _dart_iotcon_observers_create = int Function( + ffi.Pointer> observers, +); + +typedef _c_iotcon_observers_destroy = ffi.Int32 Function( + ffi.Pointer observers, +); + +typedef _dart_iotcon_observers_destroy = int Function( + ffi.Pointer observers, +); + +typedef _c_iotcon_observers_add = ffi.Int32 Function( + ffi.Pointer observers, + ffi.Int32 obs_id, +); + +typedef _dart_iotcon_observers_add = int Function( + ffi.Pointer observers, + int obs_id, +); + +typedef _c_iotcon_observers_remove = ffi.Int32 Function( + ffi.Pointer observers, + ffi.Int32 obs_id, +); + +typedef _dart_iotcon_observers_remove = int Function( + ffi.Pointer observers, + int obs_id, +); + +typedef _c_iotcon_request_get_host_address = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer> host_address, +); + +typedef _dart_iotcon_request_get_host_address = int Function( + ffi.Pointer request, + ffi.Pointer> host_address, +); + +typedef _c_iotcon_request_get_connectivity_type = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer connectivity_type, +); + +typedef _dart_iotcon_request_get_connectivity_type = int Function( + ffi.Pointer request, + ffi.Pointer connectivity_type, +); + +typedef _c_iotcon_request_get_representation = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer> repr, +); + +typedef _dart_iotcon_request_get_representation = int Function( + ffi.Pointer request, + ffi.Pointer> repr, +); + +typedef _c_iotcon_request_get_request_type = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer type, +); + +typedef _dart_iotcon_request_get_request_type = int Function( + ffi.Pointer request, + ffi.Pointer type, +); + +typedef _c_iotcon_request_get_options = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer> options, +); + +typedef _dart_iotcon_request_get_options = int Function( + ffi.Pointer request, + ffi.Pointer> options, +); + +typedef _c_iotcon_request_get_query = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer> query, +); + +typedef _dart_iotcon_request_get_query = int Function( + ffi.Pointer request, + ffi.Pointer> query, +); + +typedef _c_iotcon_request_get_observe_type = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer observe_type, +); + +typedef _dart_iotcon_request_get_observe_type = int Function( + ffi.Pointer request, + ffi.Pointer observe_type, +); + +typedef _c_iotcon_request_get_observe_id = ffi.Int32 Function( + ffi.Pointer request, + ffi.Pointer observe_id, +); + +typedef _dart_iotcon_request_get_observe_id = int Function( + ffi.Pointer request, + ffi.Pointer observe_id, +); + +typedef _c_iotcon_start_presence = ffi.Int32 Function( + ffi.Uint32 time_to_live, +); + +typedef _dart_iotcon_start_presence = int Function( + int time_to_live, +); + +typedef _c_iotcon_stop_presence = ffi.Int32 Function(); + +typedef _dart_iotcon_stop_presence = int Function(); + +typedef _c_iotcon_set_device_name = ffi.Int32 Function( + ffi.Pointer device_name, +); + +typedef _dart_iotcon_set_device_name = int Function( + ffi.Pointer device_name, +); + +typedef _c_iotcon_remote_resource_create = ffi.Int32 Function( + ffi.Pointer host_address, + ffi.Int32 connectivity_type, + ffi.Pointer uri_path, + ffi.Uint8 policies, + ffi.Pointer resource_types, + ffi.Pointer resource_ifaces, + ffi.Pointer> remote_resource, +); + +typedef _dart_iotcon_remote_resource_create = int Function( + ffi.Pointer host_address, + int connectivity_type, + ffi.Pointer uri_path, + int policies, + ffi.Pointer resource_types, + ffi.Pointer resource_ifaces, + ffi.Pointer> remote_resource, +); + +typedef _c_iotcon_remote_resource_destroy = ffi.Int32 Function( + ffi.Pointer resource, +); + +typedef _dart_iotcon_remote_resource_destroy = int Function( + ffi.Pointer resource, +); + +typedef _c_iotcon_remote_resource_clone = ffi.Int32 Function( + ffi.Pointer src, + ffi.Pointer> dest, +); + +typedef _dart_iotcon_remote_resource_clone = int Function( + ffi.Pointer src, + ffi.Pointer> dest, +); + +typedef iotcon_remote_resource_observe_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_remote_resource_observe_register = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Int32 observe_policy, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_remote_resource_observe_register = int Function( + ffi.Pointer resource, + int observe_policy, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_remote_resource_observe_deregister = ffi.Int32 Function( + ffi.Pointer resource, +); + +typedef _dart_iotcon_remote_resource_observe_deregister = int Function( + ffi.Pointer resource, +); + +typedef iotcon_remote_resource_response_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_remote_resource_get = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_remote_resource_get = int Function( + ffi.Pointer resource, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_remote_resource_put = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer repr, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_remote_resource_put = int Function( + ffi.Pointer resource, + ffi.Pointer repr, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_remote_resource_post = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer repr, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_remote_resource_post = int Function( + ffi.Pointer resource, + ffi.Pointer repr, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_remote_resource_delete = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_remote_resource_delete = int Function( + ffi.Pointer resource, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef iotcon_remote_resource_cached_representation_changed_cb = ffi.Void + Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_remote_resource_start_caching = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer< + ffi.NativeFunction< + iotcon_remote_resource_cached_representation_changed_cb>> + cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_remote_resource_start_caching = int Function( + ffi.Pointer resource, + ffi.Pointer< + ffi.NativeFunction< + iotcon_remote_resource_cached_representation_changed_cb>> + cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_remote_resource_stop_caching = ffi.Int32 Function( + ffi.Pointer resource, +); + +typedef _dart_iotcon_remote_resource_stop_caching = int Function( + ffi.Pointer resource, +); + +typedef iotcon_remote_resource_state_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_iotcon_remote_resource_start_monitoring = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_remote_resource_start_monitoring = int Function( + ffi.Pointer resource, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_remote_resource_stop_monitoring = ffi.Int32 Function( + ffi.Pointer resource, +); + +typedef _dart_iotcon_remote_resource_stop_monitoring = int Function( + ffi.Pointer resource, +); + +typedef _c_iotcon_remote_resource_get_uri_path = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer> uri_path, +); + +typedef _dart_iotcon_remote_resource_get_uri_path = int Function( + ffi.Pointer resource, + ffi.Pointer> uri_path, +); + +typedef _c_iotcon_remote_resource_get_connectivity_type = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer connectivity_type, +); + +typedef _dart_iotcon_remote_resource_get_connectivity_type = int Function( + ffi.Pointer resource, + ffi.Pointer connectivity_type, +); + +typedef _c_iotcon_remote_resource_get_host_address = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer> host_address, +); + +typedef _dart_iotcon_remote_resource_get_host_address = int Function( + ffi.Pointer resource, + ffi.Pointer> host_address, +); + +typedef _c_iotcon_remote_resource_get_device_id = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer> device_id, +); + +typedef _dart_iotcon_remote_resource_get_device_id = int Function( + ffi.Pointer resource, + ffi.Pointer> device_id, +); + +typedef _c_iotcon_remote_resource_get_device_name = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer> device_name, +); + +typedef _dart_iotcon_remote_resource_get_device_name = int Function( + ffi.Pointer resource, + ffi.Pointer> device_name, +); + +typedef _c_iotcon_remote_resource_get_types = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer> types, +); + +typedef _dart_iotcon_remote_resource_get_types = int Function( + ffi.Pointer resource, + ffi.Pointer> types, +); + +typedef _c_iotcon_remote_resource_get_interfaces = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer> ifaces, +); + +typedef _dart_iotcon_remote_resource_get_interfaces = int Function( + ffi.Pointer resource, + ffi.Pointer> ifaces, +); + +typedef _c_iotcon_remote_resource_get_policies = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer policies, +); + +typedef _dart_iotcon_remote_resource_get_policies = int Function( + ffi.Pointer resource, + ffi.Pointer policies, +); + +typedef _c_iotcon_remote_resource_get_options = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer> options, +); + +typedef _dart_iotcon_remote_resource_get_options = int Function( + ffi.Pointer resource, + ffi.Pointer> options, +); + +typedef _c_iotcon_remote_resource_set_options = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer options, +); + +typedef _dart_iotcon_remote_resource_set_options = int Function( + ffi.Pointer resource, + ffi.Pointer options, +); + +typedef _c_iotcon_remote_resource_get_cached_representation = ffi.Int32 + Function( + ffi.Pointer resource, + ffi.Pointer> representation, +); + +typedef _dart_iotcon_remote_resource_get_cached_representation = int Function( + ffi.Pointer resource, + ffi.Pointer> representation, +); + +typedef _c_iotcon_remote_resource_get_checking_interval = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Pointer interval, +); + +typedef _dart_iotcon_remote_resource_get_checking_interval = int Function( + ffi.Pointer resource, + ffi.Pointer interval, +); + +typedef _c_iotcon_remote_resource_set_checking_interval = ffi.Int32 Function( + ffi.Pointer resource, + ffi.Int32 interval, +); + +typedef _dart_iotcon_remote_resource_set_checking_interval = int Function( + ffi.Pointer resource, + int interval, +); + +typedef iotcon_presence_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_add_presence_cb = ffi.Int32 Function( + ffi.Pointer host_address, + ffi.Int32 connectivity_type, + ffi.Pointer resource_type, + ffi.Pointer> cb, + ffi.Pointer user_data, + ffi.Pointer> presence_handle, +); + +typedef _dart_iotcon_add_presence_cb = int Function( + ffi.Pointer host_address, + int connectivity_type, + ffi.Pointer resource_type, + ffi.Pointer> cb, + ffi.Pointer user_data, + ffi.Pointer> presence_handle, +); + +typedef _c_iotcon_remove_presence_cb = ffi.Int32 Function( + ffi.Pointer presence_handle, +); + +typedef _dart_iotcon_remove_presence_cb = int Function( + ffi.Pointer presence_handle, +); + +typedef _c_iotcon_presence_get_host_address = ffi.Int32 Function( + ffi.Pointer presence, + ffi.Pointer> host_address, +); + +typedef _dart_iotcon_presence_get_host_address = int Function( + ffi.Pointer presence, + ffi.Pointer> host_address, +); + +typedef _c_iotcon_presence_get_connectivity_type = ffi.Int32 Function( + ffi.Pointer presence, + ffi.Pointer connectivity_type, +); + +typedef _dart_iotcon_presence_get_connectivity_type = int Function( + ffi.Pointer presence, + ffi.Pointer connectivity_type, +); + +typedef _c_iotcon_presence_get_resource_type = ffi.Int32 Function( + ffi.Pointer presence, + ffi.Pointer> resource_type, +); + +typedef _dart_iotcon_presence_get_resource_type = int Function( + ffi.Pointer presence, + ffi.Pointer> resource_type, +); + +typedef _c_iotcon_presence_response_get_result = ffi.Int32 Function( + ffi.Pointer response, + ffi.Pointer result, +); + +typedef _dart_iotcon_presence_response_get_result = int Function( + ffi.Pointer response, + ffi.Pointer result, +); + +typedef _c_iotcon_presence_response_get_trigger = ffi.Int32 Function( + ffi.Pointer response, + ffi.Pointer trigger, +); + +typedef _dart_iotcon_presence_response_get_trigger = int Function( + ffi.Pointer response, + ffi.Pointer trigger, +); + +typedef _c_iotcon_presence_response_get_host_address = ffi.Int32 Function( + ffi.Pointer response, + ffi.Pointer> host_address, +); + +typedef _dart_iotcon_presence_response_get_host_address = int Function( + ffi.Pointer response, + ffi.Pointer> host_address, +); + +typedef _c_iotcon_presence_response_get_connectivity_type = ffi.Int32 Function( + ffi.Pointer response, + ffi.Pointer connectivity_type, +); + +typedef _dart_iotcon_presence_response_get_connectivity_type = int Function( + ffi.Pointer response, + ffi.Pointer connectivity_type, +); + +typedef _c_iotcon_presence_response_get_resource_type = ffi.Int32 Function( + ffi.Pointer response, + ffi.Pointer> resource_type, +); + +typedef _dart_iotcon_presence_response_get_resource_type = int Function( + ffi.Pointer response, + ffi.Pointer> resource_type, +); + +typedef iotcon_found_resource_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_iotcon_find_resource = ffi.Int32 Function( + ffi.Pointer host_address, + ffi.Int32 connectivity_type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_find_resource = int Function( + ffi.Pointer host_address, + int connectivity_type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef iotcon_device_info_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_iotcon_find_device_info = ffi.Int32 Function( + ffi.Pointer host_address, + ffi.Int32 connectivity_type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_find_device_info = int Function( + ffi.Pointer host_address, + int connectivity_type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_device_info_get_property = ffi.Int32 Function( + ffi.Pointer device_info, + ffi.Int32 property, + ffi.Pointer> value, +); + +typedef _dart_iotcon_device_info_get_property = int Function( + ffi.Pointer device_info, + int property, + ffi.Pointer> value, +); + +typedef iotcon_platform_info_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_iotcon_find_platform_info = ffi.Int32 Function( + ffi.Pointer host_address, + ffi.Int32 connectivity_type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_find_platform_info = int Function( + ffi.Pointer host_address, + int connectivity_type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_platform_info_get_property = ffi.Int32 Function( + ffi.Pointer platform_info, + ffi.Int32 property, + ffi.Pointer> value, +); + +typedef _dart_iotcon_platform_info_get_property = int Function( + ffi.Pointer platform_info, + int property, + ffi.Pointer> value, +); + +typedef _c_iotcon_initialize = ffi.Int32 Function( + ffi.Pointer file_path, +); + +typedef _dart_iotcon_initialize = int Function( + ffi.Pointer file_path, +); + +typedef _c_iotcon_deinitialize = ffi.Int32 Function(); + +typedef _dart_iotcon_deinitialize = int Function(); + +typedef _c_iotcon_get_timeout = ffi.Int32 Function( + ffi.Pointer timeout_seconds, +); + +typedef _dart_iotcon_get_timeout = int Function( + ffi.Pointer timeout_seconds, +); + +typedef _c_iotcon_set_timeout = ffi.Int32 Function( + ffi.Int32 timeout_seconds, +); + +typedef _dart_iotcon_set_timeout = int Function( + int timeout_seconds, +); + +typedef _c_iotcon_polling_get_interval = ffi.Int32 Function( + ffi.Pointer interval, +); + +typedef _dart_iotcon_polling_get_interval = int Function( + ffi.Pointer interval, +); + +typedef _c_iotcon_polling_set_interval = ffi.Int32 Function( + ffi.Int32 interval, +); + +typedef _dart_iotcon_polling_set_interval = int Function( + int interval, +); + +typedef _c_iotcon_polling_invoke = ffi.Int32 Function(); + +typedef _dart_iotcon_polling_invoke = int Function(); + +typedef iotcon_generated_pin_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_iotcon_add_generated_pin_cb = ffi.Int32 Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_iotcon_add_generated_pin_cb = int Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_iotcon_remove_generated_pin_cb = ffi.Int32 Function( + ffi.Pointer> cb, +); + +typedef _dart_iotcon_remove_generated_pin_cb = int Function( + ffi.Pointer> cb, +); + +typedef _c_nfc_manager_is_supported = ffi.Uint8 Function(); + +typedef _dart_nfc_manager_is_supported = int Function(); + +typedef nfc_activation_changed_cb = ffi.Void Function( + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_nfc_manager_set_activation_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_manager_set_activation_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_nfc_manager_unset_activation_changed_cb = ffi.Void Function(); + +typedef _dart_nfc_manager_unset_activation_changed_cb = void Function(); + +typedef nfc_activation_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_manager_set_activation = ffi.Int32 Function( + ffi.Uint8 activation, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_manager_set_activation = int Function( + int activation, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_nfc_manager_is_activated = ffi.Uint8 Function(); + +typedef _dart_nfc_manager_is_activated = int Function(); + +typedef _c_nfc_manager_initialize = ffi.Int32 Function(); + +typedef _dart_nfc_manager_initialize = int Function(); + +typedef _c_nfc_manager_deinitialize = ffi.Int32 Function(); + +typedef _dart_nfc_manager_deinitialize = int Function(); + +typedef nfc_tag_discovered_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer<_net_nfc_target_info_s>, + ffi.Pointer, +); + +typedef _c_nfc_manager_set_tag_discovered_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_manager_set_tag_discovered_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_nfc_manager_unset_tag_discovered_cb = ffi.Void Function(); + +typedef _dart_nfc_manager_unset_tag_discovered_cb = void Function(); + +typedef nfc_ndef_discovered_cb = ffi.Void Function( + ffi.Pointer<_ndef_message_s>, + ffi.Pointer, +); + +typedef _c_nfc_manager_set_ndef_discovered_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_manager_set_ndef_discovered_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_nfc_manager_unset_ndef_discovered_cb = ffi.Void Function(); + +typedef _dart_nfc_manager_unset_ndef_discovered_cb = void Function(); + +typedef nfc_p2p_target_discovered_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_nfc_manager_set_p2p_target_discovered_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_manager_set_p2p_target_discovered_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_nfc_manager_unset_p2p_target_discovered_cb = ffi.Void Function(); + +typedef _dart_nfc_manager_unset_p2p_target_discovered_cb = void Function(); + +typedef nfc_se_event_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_manager_set_se_event_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_manager_set_se_event_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_nfc_manager_unset_se_event_cb = ffi.Void Function(); + +typedef _dart_nfc_manager_unset_se_event_cb = void Function(); + +typedef nfc_se_transaction_event_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_manager_set_se_transaction_event_cb = ffi.Int32 Function( + ffi.Int32 se_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_manager_set_se_transaction_event_cb = int Function( + int se_type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_nfc_manager_unset_se_transaction_event_cb = ffi.Void Function( + ffi.Int32 se_type, +); + +typedef _dart_nfc_manager_unset_se_transaction_event_cb = void Function( + int se_type, +); + +typedef nfc_hce_event_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_nfc_manager_set_hce_event_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_manager_set_hce_event_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_nfc_manager_unset_hce_event_cb = ffi.Void Function(); + +typedef _dart_nfc_manager_unset_hce_event_cb = void Function(); + +typedef _c_nfc_manager_enable_transaction_fg_dispatch = ffi.Int32 Function(); + +typedef _dart_nfc_manager_enable_transaction_fg_dispatch = int Function(); + +typedef _c_nfc_manager_disable_transaction_fg_dispatch = ffi.Int32 Function(); + +typedef _dart_nfc_manager_disable_transaction_fg_dispatch = int Function(); + +typedef _c_nfc_manager_get_cached_message = ffi.Int32 Function( + ffi.Pointer> ndef_message, +); + +typedef _dart_nfc_manager_get_cached_message = int Function( + ffi.Pointer> ndef_message, +); + +typedef _c_nfc_manager_set_tag_filter = ffi.Void Function( + ffi.Int32 filter, +); + +typedef _dart_nfc_manager_set_tag_filter = void Function( + int filter, +); + +typedef _c_nfc_manager_get_tag_filter = ffi.Int32 Function(); + +typedef _dart_nfc_manager_get_tag_filter = int Function(); + +typedef _c_nfc_manager_get_connected_tag = ffi.Int32 Function( + ffi.Pointer> tag, +); + +typedef _dart_nfc_manager_get_connected_tag = int Function( + ffi.Pointer> tag, +); + +typedef _c_nfc_manager_get_connected_target = ffi.Int32 Function( + ffi.Pointer> target, +); + +typedef _dart_nfc_manager_get_connected_target = int Function( + ffi.Pointer> target, +); + +typedef _c_nfc_manager_set_system_handler_enable = ffi.Int32 Function( + ffi.Uint8 enable, +); + +typedef _dart_nfc_manager_set_system_handler_enable = int Function( + int enable, +); + +typedef _c_nfc_manager_is_system_handler_enabled = ffi.Uint8 Function(); + +typedef _dart_nfc_manager_is_system_handler_enabled = int Function(); + +typedef _c_nfc_manager_set_se_type = ffi.Int32 Function( + ffi.Int32 type, +); + +typedef _dart_nfc_manager_set_se_type = int Function( + int type, +); + +typedef _c_nfc_manager_get_se_type = ffi.Int32 Function( + ffi.Pointer type, +); + +typedef _dart_nfc_manager_get_se_type = int Function( + ffi.Pointer type, +); + +typedef _c_nfc_ndef_record_create = ffi.Int32 Function( + ffi.Pointer> record, + ffi.Int32 tnf, + ffi.Pointer type, + ffi.Int32 type_size, + ffi.Pointer id, + ffi.Int32 id_size, + ffi.Pointer payload, + ffi.Uint32 payload_size, +); + +typedef _dart_nfc_ndef_record_create = int Function( + ffi.Pointer> record, + int tnf, + ffi.Pointer type, + int type_size, + ffi.Pointer id, + int id_size, + ffi.Pointer payload, + int payload_size, +); + +typedef _c_nfc_ndef_record_create_text = ffi.Int32 Function( + ffi.Pointer> record, + ffi.Pointer text, + ffi.Pointer lang_code, + ffi.Int32 encode, +); + +typedef _dart_nfc_ndef_record_create_text = int Function( + ffi.Pointer> record, + ffi.Pointer text, + ffi.Pointer lang_code, + int encode, +); + +typedef _c_nfc_ndef_record_create_uri = ffi.Int32 Function( + ffi.Pointer> record, + ffi.Pointer uri, +); + +typedef _dart_nfc_ndef_record_create_uri = int Function( + ffi.Pointer> record, + ffi.Pointer uri, +); + +typedef _c_nfc_ndef_record_create_mime = ffi.Int32 Function( + ffi.Pointer> record, + ffi.Pointer mime_type, + ffi.Pointer data, + ffi.Uint32 data_size, +); + +typedef _dart_nfc_ndef_record_create_mime = int Function( + ffi.Pointer> record, + ffi.Pointer mime_type, + ffi.Pointer data, + int data_size, +); + +typedef _c_nfc_ndef_record_destroy = ffi.Int32 Function( + ffi.Pointer<_ndef_record_s> record, +); + +typedef _dart_nfc_ndef_record_destroy = int Function( + ffi.Pointer<_ndef_record_s> record, +); + +typedef _c_nfc_ndef_record_set_id = ffi.Int32 Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer id, + ffi.Int32 id_size, +); + +typedef _dart_nfc_ndef_record_set_id = int Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer id, + int id_size, +); + +typedef _c_nfc_ndef_record_get_id = ffi.Int32 Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> id, + ffi.Pointer size, +); + +typedef _dart_nfc_ndef_record_get_id = int Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> id, + ffi.Pointer size, +); + +typedef _c_nfc_ndef_record_get_payload = ffi.Int32 Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> payload, + ffi.Pointer size, +); + +typedef _dart_nfc_ndef_record_get_payload = int Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> payload, + ffi.Pointer size, +); + +typedef _c_nfc_ndef_record_get_type = ffi.Int32 Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> type, + ffi.Pointer size, +); + +typedef _dart_nfc_ndef_record_get_type = int Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> type, + ffi.Pointer size, +); + +typedef _c_nfc_ndef_record_get_tnf = ffi.Int32 Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer tnf, +); + +typedef _dart_nfc_ndef_record_get_tnf = int Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer tnf, +); + +typedef _c_nfc_ndef_record_get_text = ffi.Int32 Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> text, +); + +typedef _dart_nfc_ndef_record_get_text = int Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> text, +); + +typedef _c_nfc_ndef_record_get_langcode = ffi.Int32 Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> lang_code, +); + +typedef _dart_nfc_ndef_record_get_langcode = int Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> lang_code, +); + +typedef _c_nfc_ndef_record_get_encode_type = ffi.Int32 Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer encode, +); + +typedef _dart_nfc_ndef_record_get_encode_type = int Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer encode, +); + +typedef _c_nfc_ndef_record_get_uri = ffi.Int32 Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> uri, +); + +typedef _dart_nfc_ndef_record_get_uri = int Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> uri, +); + +typedef _c_nfc_ndef_record_get_mime_type = ffi.Int32 Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> mime_type, +); + +typedef _dart_nfc_ndef_record_get_mime_type = int Function( + ffi.Pointer<_ndef_record_s> record, + ffi.Pointer> mime_type, +); + +typedef _c_nfc_ndef_message_create = ffi.Int32 Function( + ffi.Pointer> ndef_message, +); + +typedef _dart_nfc_ndef_message_create = int Function( + ffi.Pointer> ndef_message, +); + +typedef _c_nfc_ndef_message_create_from_rawdata = ffi.Int32 Function( + ffi.Pointer> ndef_message, + ffi.Pointer rawdata, + ffi.Uint32 rawdata_size, +); + +typedef _dart_nfc_ndef_message_create_from_rawdata = int Function( + ffi.Pointer> ndef_message, + ffi.Pointer rawdata, + int rawdata_size, +); + +typedef _c_nfc_ndef_message_destroy = ffi.Int32 Function( + ffi.Pointer<_ndef_message_s> ndef_message, +); + +typedef _dart_nfc_ndef_message_destroy = int Function( + ffi.Pointer<_ndef_message_s> ndef_message, +); + +typedef _c_nfc_ndef_message_get_record_count = ffi.Int32 Function( + ffi.Pointer<_ndef_message_s> ndef_message, + ffi.Pointer count, +); + +typedef _dart_nfc_ndef_message_get_record_count = int Function( + ffi.Pointer<_ndef_message_s> ndef_message, + ffi.Pointer count, +); + +typedef _c_nfc_ndef_message_get_rawdata = ffi.Int32 Function( + ffi.Pointer<_ndef_message_s> ndef_message, + ffi.Pointer> rawdata, + ffi.Pointer rawdata_size, +); + +typedef _dart_nfc_ndef_message_get_rawdata = int Function( + ffi.Pointer<_ndef_message_s> ndef_message, + ffi.Pointer> rawdata, + ffi.Pointer rawdata_size, +); + +typedef _c_nfc_ndef_message_append_record = ffi.Int32 Function( + ffi.Pointer<_ndef_message_s> ndef_message, + ffi.Pointer<_ndef_record_s> record, +); + +typedef _dart_nfc_ndef_message_append_record = int Function( + ffi.Pointer<_ndef_message_s> ndef_message, + ffi.Pointer<_ndef_record_s> record, +); + +typedef _c_nfc_ndef_message_insert_record = ffi.Int32 Function( + ffi.Pointer<_ndef_message_s> ndef_message, + ffi.Int32 index, + ffi.Pointer<_ndef_record_s> record, +); + +typedef _dart_nfc_ndef_message_insert_record = int Function( + ffi.Pointer<_ndef_message_s> ndef_message, + int index, + ffi.Pointer<_ndef_record_s> record, +); + +typedef _c_nfc_ndef_message_remove_record = ffi.Int32 Function( + ffi.Pointer<_ndef_message_s> ndef_message, + ffi.Int32 index, +); + +typedef _dart_nfc_ndef_message_remove_record = int Function( + ffi.Pointer<_ndef_message_s> ndef_message, + int index, +); + +typedef _c_nfc_ndef_message_get_record = ffi.Int32 Function( + ffi.Pointer<_ndef_message_s> ndef_message, + ffi.Int32 index, + ffi.Pointer> record, +); + +typedef _dart_nfc_ndef_message_get_record = int Function( + ffi.Pointer<_ndef_message_s> ndef_message, + int index, + ffi.Pointer> record, +); + +typedef _c_nfc_tag_get_type = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer type, +); + +typedef _dart_nfc_tag_get_type = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer type, +); + +typedef _c_nfc_tag_is_support_ndef = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer is_supported, +); + +typedef _dart_nfc_tag_is_support_ndef = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer is_supported, +); + +typedef _c_nfc_tag_get_maximum_ndef_size = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer maximum_ndef_bytes_size, +); + +typedef _dart_nfc_tag_get_maximum_ndef_size = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer maximum_ndef_bytes_size, +); + +typedef _c_nfc_tag_get_ndef_size = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer ndef_bytes_size, +); + +typedef _dart_nfc_tag_get_ndef_size = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer ndef_bytes_size, +); + +typedef nfc_tag_information_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_tag_foreach_information = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_tag_foreach_information = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef nfc_tag_transceive_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_tag_transceive = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer buffer, + ffi.Int32 buffer_size, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_tag_transceive = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer buffer, + int buffer_size, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef nfc_tag_read_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer<_ndef_message_s>, + ffi.Pointer, +); + +typedef _c_nfc_tag_read_ndef = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_tag_read_ndef = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef nfc_tag_write_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_tag_write_ndef = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer<_ndef_message_s> msg, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_tag_write_ndef = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer<_ndef_message_s> msg, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef nfc_tag_format_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_tag_format_ndef = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer key, + ffi.Int32 key_size, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_tag_format_ndef = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Pointer key, + int key_size, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef nfc_mifare_authenticate_with_keyA_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_mifare_authenticate_with_keyA = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Int32 sector_index, + ffi.Pointer auth_key, + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_mifare_authenticate_with_keyA = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + int sector_index, + ffi.Pointer auth_key, + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef nfc_mifare_authenticate_with_keyB_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_mifare_authenticate_with_keyB = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Int32 sector_index, + ffi.Pointer auth_key, + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_mifare_authenticate_with_keyB = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + int sector_index, + ffi.Pointer auth_key, + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef nfc_mifare_read_block_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_mifare_read_block = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Int32 block_index, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_mifare_read_block = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + int block_index, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef nfc_mifare_read_page_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_mifare_read_page = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Int32 page_index, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_mifare_read_page = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + int page_index, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef nfc_mifare_write_block_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_mifare_write_block = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Int32 block_index, + ffi.Pointer buffer, + ffi.Int32 buffer_size, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_mifare_write_block = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + int block_index, + ffi.Pointer buffer, + int buffer_size, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef nfc_mifare_write_page_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_mifare_write_page = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Int32 page_index, + ffi.Pointer buffer, + ffi.Int32 buffer_size, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_mifare_write_page = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + int page_index, + ffi.Pointer buffer, + int buffer_size, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef nfc_mifare_increment_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_mifare_increment = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Int32 block_index, + ffi.Int32 value, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_mifare_increment = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + int block_index, + int value, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef nfc_mifare_decrement_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_mifare_decrement = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Int32 block_index, + ffi.Int32 value, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_mifare_decrement = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + int block_index, + int value, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef nfc_mifare_transfer_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_mifare_transfer = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Int32 block_index, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_mifare_transfer = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + int block_index, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef nfc_mifare_restore_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_mifare_restore = ffi.Int32 Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + ffi.Int32 block_index, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_mifare_restore = int Function( + ffi.Pointer<_net_nfc_target_info_s> tag, + int block_index, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef nfc_p2p_data_received_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer<_ndef_message_s>, + ffi.Pointer, +); + +typedef _c_nfc_p2p_set_data_received_cb = ffi.Int32 Function( + ffi.Pointer target, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_p2p_set_data_received_cb = int Function( + ffi.Pointer target, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_nfc_p2p_unset_data_received_cb = ffi.Int32 Function( + ffi.Pointer target, +); + +typedef _dart_nfc_p2p_unset_data_received_cb = int Function( + ffi.Pointer target, +); + +typedef nfc_p2p_send_completed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_nfc_p2p_send = ffi.Int32 Function( + ffi.Pointer target, + ffi.Pointer<_ndef_message_s> message, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_p2p_send = int Function( + ffi.Pointer target, + ffi.Pointer<_ndef_message_s> message, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef nfc_snep_event_cb = ffi.Void Function( + ffi.Pointer<_nfc_p2p_snep_s>, + ffi.Int32, + ffi.Int32, + ffi.Pointer<_ndef_message_s>, + ffi.Pointer, +); + +typedef _c_nfc_snep_start_server = ffi.Int32 Function( + ffi.Pointer target, + ffi.Pointer san, + ffi.Int32 sap, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_snep_start_server = int Function( + ffi.Pointer target, + ffi.Pointer san, + int sap, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_nfc_snep_start_client = ffi.Int32 Function( + ffi.Pointer target, + ffi.Pointer san, + ffi.Int32 sap, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_snep_start_client = int Function( + ffi.Pointer target, + ffi.Pointer san, + int sap, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_nfc_snep_send_client_request = ffi.Int32 Function( + ffi.Pointer<_nfc_p2p_snep_s> handle, + ffi.Int32 type, + ffi.Pointer<_ndef_message_s> msg, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_snep_send_client_request = int Function( + ffi.Pointer<_nfc_p2p_snep_s> handle, + int type, + ffi.Pointer<_ndef_message_s> msg, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_nfc_snep_stop_service = ffi.Int32 Function( + ffi.Pointer target, + ffi.Pointer<_nfc_p2p_snep_s> service, +); + +typedef _dart_nfc_snep_stop_service = int Function( + ffi.Pointer target, + ffi.Pointer<_nfc_p2p_snep_s> service, +); + +typedef _c_nfc_snep_register_server = ffi.Int32 Function( + ffi.Pointer san, + ffi.Int32 sap, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_snep_register_server = int Function( + ffi.Pointer san, + int sap, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_nfc_snep_unregister_server = ffi.Int32 Function( + ffi.Pointer san, + ffi.Int32 sap, +); + +typedef _dart_nfc_snep_unregister_server = int Function( + ffi.Pointer san, + int sap, +); + +typedef _c_nfc_se_enable_card_emulation = ffi.Int32 Function(); + +typedef _dart_nfc_se_enable_card_emulation = int Function(); + +typedef _c_nfc_se_disable_card_emulation = ffi.Int32 Function(); + +typedef _dart_nfc_se_disable_card_emulation = int Function(); + +typedef _c_nfc_se_get_card_emulation_mode = ffi.Int32 Function( + ffi.Pointer type, +); + +typedef _dart_nfc_se_get_card_emulation_mode = int Function( + ffi.Pointer type, +); + +typedef _c_nfc_hce_send_apdu_response = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer resp, + ffi.Uint32 resp_len, +); + +typedef _dart_nfc_hce_send_apdu_response = int Function( + ffi.Pointer handle, + ffi.Pointer resp, + int resp_len, +); + +typedef _c_nfc_se_set_default_route = ffi.Int32 Function( + ffi.Int32 powered_on_status, + ffi.Int32 powered_off_status, + ffi.Int32 low_battery_status, +); + +typedef _dart_nfc_se_set_default_route = int Function( + int powered_on_status, + int powered_off_status, + int low_battery_status, +); + +typedef _c_nfc_se_is_activated_handler_for_aid = ffi.Int32 Function( + ffi.Int32 se_type, + ffi.Pointer aid, + ffi.Pointer is_activated_handler, +); + +typedef _dart_nfc_se_is_activated_handler_for_aid = int Function( + int se_type, + ffi.Pointer aid, + ffi.Pointer is_activated_handler, +); + +typedef _c_nfc_se_is_activated_handler_for_category = ffi.Int32 Function( + ffi.Int32 se_type, + ffi.Int32 category, + ffi.Pointer is_activated_handler, +); + +typedef _dart_nfc_se_is_activated_handler_for_category = int Function( + int se_type, + int category, + ffi.Pointer is_activated_handler, +); + +typedef _c_nfc_se_register_aid = ffi.Int32 Function( + ffi.Int32 se_type, + ffi.Int32 category, + ffi.Pointer aid, +); + +typedef _dart_nfc_se_register_aid = int Function( + int se_type, + int category, + ffi.Pointer aid, +); + +typedef _c_nfc_se_unregister_aid = ffi.Int32 Function( + ffi.Int32 se_type, + ffi.Int32 category, + ffi.Pointer aid, +); + +typedef _dart_nfc_se_unregister_aid = int Function( + int se_type, + int category, + ffi.Pointer aid, +); + +typedef nfc_se_registered_aid_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_nfc_se_foreach_registered_aids = ffi.Int32 Function( + ffi.Int32 se_type, + ffi.Int32 category, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_nfc_se_foreach_registered_aids = int Function( + int se_type, + int category, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_nfc_se_set_preferred_handler = ffi.Int32 Function(); + +typedef _dart_nfc_se_set_preferred_handler = int Function(); + +typedef _c_nfc_se_unset_preferred_handler = ffi.Int32 Function(); + +typedef _dart_nfc_se_unset_preferred_handler = int Function(); + +typedef _c_ssdp_initialize = ffi.Int32 Function(); + +typedef _dart_ssdp_initialize = int Function(); + +typedef _c_ssdp_deinitialize = ffi.Int32 Function(); + +typedef _dart_ssdp_deinitialize = int Function(); + +typedef _c_ssdp_create_local_service = ffi.Int32 Function( + ffi.Pointer target, + ffi.Pointer local_service, +); + +typedef _dart_ssdp_create_local_service = int Function( + ffi.Pointer target, + ffi.Pointer local_service, +); + +typedef _c_ssdp_destroy_local_service = ffi.Int32 Function( + ffi.Uint32 local_service, +); + +typedef _dart_ssdp_destroy_local_service = int Function( + int local_service, +); + +typedef _c_ssdp_service_set_usn = ffi.Int32 Function( + ffi.Uint32 local_service, + ffi.Pointer usn, +); + +typedef _dart_ssdp_service_set_usn = int Function( + int local_service, + ffi.Pointer usn, +); + +typedef _c_ssdp_service_set_url = ffi.Int32 Function( + ffi.Uint32 local_service, + ffi.Pointer url, +); + +typedef _dart_ssdp_service_set_url = int Function( + int local_service, + ffi.Pointer url, +); + +typedef _c_ssdp_service_get_target = ffi.Int32 Function( + ffi.Uint32 service, + ffi.Pointer> target, +); + +typedef _dart_ssdp_service_get_target = int Function( + int service, + ffi.Pointer> target, +); + +typedef _c_ssdp_service_get_usn = ffi.Int32 Function( + ffi.Uint32 service, + ffi.Pointer> usn, +); + +typedef _dart_ssdp_service_get_usn = int Function( + int service, + ffi.Pointer> usn, +); + +typedef _c_ssdp_service_get_url = ffi.Int32 Function( + ffi.Uint32 service, + ffi.Pointer> url, +); + +typedef _dart_ssdp_service_get_url = int Function( + int service, + ffi.Pointer> url, +); + +typedef ssdp_registered_cb = ffi.Void Function( + ffi.Int32, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_ssdp_register_local_service = ffi.Int32 Function( + ffi.Uint32 local_service, + ffi.Pointer> registered_cb, + ffi.Pointer user_data, +); + +typedef _dart_ssdp_register_local_service = int Function( + int local_service, + ffi.Pointer> registered_cb, + ffi.Pointer user_data, +); + +typedef _c_ssdp_deregister_local_service = ffi.Int32 Function( + ffi.Uint32 local_service, +); + +typedef _dart_ssdp_deregister_local_service = int Function( + int local_service, +); + +typedef ssdp_found_cb = ffi.Void Function( + ffi.Int32, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_ssdp_start_browsing_service = ffi.Int32 Function( + ffi.Pointer target, + ffi.Pointer ssdp_browser, + ffi.Pointer> found_cb, + ffi.Pointer user_data, +); + +typedef _dart_ssdp_start_browsing_service = int Function( + ffi.Pointer target, + ffi.Pointer ssdp_browser, + ffi.Pointer> found_cb, + ffi.Pointer user_data, +); + +typedef _c_ssdp_stop_browsing_service = ffi.Int32 Function( + ffi.Uint32 ssdp_browser, +); + +typedef _dart_ssdp_stop_browsing_service = int Function( + int ssdp_browser, +); + +typedef _c_stc_initialize = ffi.Int32 Function( + ffi.Pointer> stc, +); + +typedef _dart_stc_initialize = int Function( + ffi.Pointer> stc, +); + +typedef _c_stc_deinitialize = ffi.Int32 Function( + ffi.Pointer stc, +); + +typedef _dart_stc_deinitialize = int Function( + ffi.Pointer stc, +); + +typedef stc_stats_info_cb = ffi.Int32 Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_stc_get_stats = ffi.Int32 Function( + ffi.Pointer stc, + ffi.Pointer rule, + ffi.Pointer> info_cb, + ffi.Pointer user_data, +); + +typedef _dart_stc_get_stats = int Function( + ffi.Pointer stc, + ffi.Pointer rule, + ffi.Pointer> info_cb, + ffi.Pointer user_data, +); + +typedef _c_stc_foreach_stats = ffi.Int32 Function( + ffi.Pointer stc, + ffi.Pointer rule, + ffi.Pointer> info_cb, + ffi.Pointer user_data, +); + +typedef _dart_stc_foreach_stats = int Function( + ffi.Pointer stc, + ffi.Pointer rule, + ffi.Pointer> info_cb, + ffi.Pointer user_data, +); + +typedef _c_stc_get_total_stats = ffi.Int32 Function( + ffi.Pointer stc, + ffi.Pointer rule, + ffi.Pointer> info_cb, + ffi.Pointer user_data, +); + +typedef _dart_stc_get_total_stats = int Function( + ffi.Pointer stc, + ffi.Pointer rule, + ffi.Pointer> info_cb, + ffi.Pointer user_data, +); + +typedef _c_stc_stats_rule_create = ffi.Int32 Function( + ffi.Pointer stc, + ffi.Pointer> rule, +); + +typedef _dart_stc_stats_rule_create = int Function( + ffi.Pointer stc, + ffi.Pointer> rule, +); + +typedef _c_stc_stats_rule_destroy = ffi.Int32 Function( + ffi.Pointer rule, +); + +typedef _dart_stc_stats_rule_destroy = int Function( + ffi.Pointer rule, +); + +typedef _c_stc_stats_rule_set_app_id = ffi.Int32 Function( + ffi.Pointer rule, + ffi.Pointer app_id, +); + +typedef _dart_stc_stats_rule_set_app_id = int Function( + ffi.Pointer rule, + ffi.Pointer app_id, +); + +typedef _c_stc_stats_rule_set_time_interval = ffi.Int32 Function( + ffi.Pointer rule, + ffi.Int64 from, + ffi.Int64 to, +); + +typedef _dart_stc_stats_rule_set_time_interval = int Function( + ffi.Pointer rule, + int from, + int to, +); + +typedef _c_stc_stats_rule_set_iface_type = ffi.Int32 Function( + ffi.Pointer rule, + ffi.Int32 iface_type, +); + +typedef _dart_stc_stats_rule_set_iface_type = int Function( + ffi.Pointer rule, + int iface_type, +); + +typedef _c_stc_stats_rule_set_time_period = ffi.Int32 Function( + ffi.Pointer rule, + ffi.Int32 time_period, +); + +typedef _dart_stc_stats_rule_set_time_period = int Function( + ffi.Pointer rule, + int time_period, +); + +typedef _c_stc_stats_rule_get_app_id = ffi.Int32 Function( + ffi.Pointer rule, + ffi.Pointer> app_id, +); + +typedef _dart_stc_stats_rule_get_app_id = int Function( + ffi.Pointer rule, + ffi.Pointer> app_id, +); + +typedef _c_stc_stats_rule_get_time_interval = ffi.Int32 Function( + ffi.Pointer rule, + ffi.Pointer from, + ffi.Pointer to, +); + +typedef _dart_stc_stats_rule_get_time_interval = int Function( + ffi.Pointer rule, + ffi.Pointer from, + ffi.Pointer to, +); + +typedef _c_stc_stats_rule_get_iface_type = ffi.Int32 Function( + ffi.Pointer rule, + ffi.Pointer iface_type, +); + +typedef _dart_stc_stats_rule_get_iface_type = int Function( + ffi.Pointer rule, + ffi.Pointer iface_type, +); + +typedef _c_stc_stats_rule_get_time_period = ffi.Int32 Function( + ffi.Pointer rule, + ffi.Pointer time_period, +); + +typedef _dart_stc_stats_rule_get_time_period = int Function( + ffi.Pointer rule, + ffi.Pointer time_period, +); + +typedef _c_stc_stats_info_get_app_id = ffi.Int32 Function( + ffi.Pointer info, + ffi.Pointer> app_id, +); + +typedef _dart_stc_stats_info_get_app_id = int Function( + ffi.Pointer info, + ffi.Pointer> app_id, +); + +typedef _c_stc_stats_info_get_iface_name = ffi.Int32 Function( + ffi.Pointer info, + ffi.Pointer> iface_name, +); + +typedef _dart_stc_stats_info_get_iface_name = int Function( + ffi.Pointer info, + ffi.Pointer> iface_name, +); + +typedef _c_stc_stats_info_get_time_interval = ffi.Int32 Function( + ffi.Pointer info, + ffi.Pointer from, + ffi.Pointer to, +); + +typedef _dart_stc_stats_info_get_time_interval = int Function( + ffi.Pointer info, + ffi.Pointer from, + ffi.Pointer to, +); + +typedef _c_stc_stats_info_get_iface_type = ffi.Int32 Function( + ffi.Pointer info, + ffi.Pointer iface_type, +); + +typedef _dart_stc_stats_info_get_iface_type = int Function( + ffi.Pointer info, + ffi.Pointer iface_type, +); + +typedef _c_stc_stats_info_get_counter = ffi.Int32 Function( + ffi.Pointer info, + ffi.Pointer incoming, + ffi.Pointer outgoing, +); + +typedef _dart_stc_stats_info_get_counter = int Function( + ffi.Pointer info, + ffi.Pointer incoming, + ffi.Pointer outgoing, +); + +typedef _c_stc_stats_info_get_roaming_type = ffi.Int32 Function( + ffi.Pointer info, + ffi.Pointer roaming_type, +); + +typedef _dart_stc_stats_info_get_roaming_type = int Function( + ffi.Pointer info, + ffi.Pointer roaming_type, +); + +typedef _c_stc_stats_info_get_protocol_type = ffi.Int32 Function( + ffi.Pointer info, + ffi.Pointer protocol, +); + +typedef _dart_stc_stats_info_get_protocol_type = int Function( + ffi.Pointer info, + ffi.Pointer protocol, +); + +typedef _c_stc_stats_info_get_process_state = ffi.Int32 Function( + ffi.Pointer info, + ffi.Pointer state, +); + +typedef _dart_stc_stats_info_get_process_state = int Function( + ffi.Pointer info, + ffi.Pointer state, +); + +typedef _c_smartcard_initialize = ffi.Int32 Function(); + +typedef _dart_smartcard_initialize = int Function(); + +typedef _c_smartcard_deinitialize = ffi.Int32 Function(); + +typedef _dart_smartcard_deinitialize = int Function(); + +typedef _c_smartcard_get_version = ffi.Int32 Function( + ffi.Pointer> version, +); + +typedef _dart_smartcard_get_version = int Function( + ffi.Pointer> version, +); + +typedef _c_smartcard_get_readers = ffi.Int32 Function( + ffi.Pointer> readers, + ffi.Pointer length, +); + +typedef _dart_smartcard_get_readers = int Function( + ffi.Pointer> readers, + ffi.Pointer length, +); + +typedef _c_smartcard_reader_get_name = ffi.Int32 Function( + ffi.Int32 reader, + ffi.Pointer> reader_name, +); + +typedef _dart_smartcard_reader_get_name = int Function( + int reader, + ffi.Pointer> reader_name, +); + +typedef _c_smartcard_reader_is_secure_element_present = ffi.Int32 Function( + ffi.Int32 reader, + ffi.Pointer is_present, +); + +typedef _dart_smartcard_reader_is_secure_element_present = int Function( + int reader, + ffi.Pointer is_present, +); + +typedef _c_smartcard_reader_open_session = ffi.Int32 Function( + ffi.Int32 reader, + ffi.Pointer session, +); + +typedef _dart_smartcard_reader_open_session = int Function( + int reader, + ffi.Pointer session, +); + +typedef _c_smartcard_reader_close_sessions = ffi.Int32 Function( + ffi.Int32 reader, +); + +typedef _dart_smartcard_reader_close_sessions = int Function( + int reader, +); + +typedef smartcard_reader_event_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_smartcard_reader_set_event_cb = ffi.Int32 Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_smartcard_reader_set_event_cb = int Function( + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_smartcard_reader_unset_event_cb = ffi.Int32 Function(); + +typedef _dart_smartcard_reader_unset_event_cb = int Function(); + +typedef _c_smartcard_session_get_reader = ffi.Int32 Function( + ffi.Int32 session, + ffi.Pointer reader, +); + +typedef _dart_smartcard_session_get_reader = int Function( + int session, + ffi.Pointer reader, +); + +typedef _c_smartcard_session_get_atr = ffi.Int32 Function( + ffi.Int32 session, + ffi.Pointer> atr, + ffi.Pointer length, +); + +typedef _dart_smartcard_session_get_atr = int Function( + int session, + ffi.Pointer> atr, + ffi.Pointer length, +); + +typedef _c_smartcard_session_close = ffi.Int32 Function( + ffi.Int32 session, +); + +typedef _dart_smartcard_session_close = int Function( + int session, +); + +typedef _c_smartcard_session_is_closed = ffi.Int32 Function( + ffi.Int32 session, + ffi.Pointer is_closed, +); + +typedef _dart_smartcard_session_is_closed = int Function( + int session, + ffi.Pointer is_closed, +); + +typedef _c_smartcard_session_close_channels = ffi.Int32 Function( + ffi.Int32 session, +); + +typedef _dart_smartcard_session_close_channels = int Function( + int session, +); + +typedef _c_smartcard_session_open_basic_channel = ffi.Int32 Function( + ffi.Int32 session, + ffi.Pointer aid, + ffi.Int32 aid_len, + ffi.Uint8 P2, + ffi.Pointer channel, +); + +typedef _dart_smartcard_session_open_basic_channel = int Function( + int session, + ffi.Pointer aid, + int aid_len, + int P2, + ffi.Pointer channel, +); + +typedef _c_smartcard_session_open_logical_channel = ffi.Int32 Function( + ffi.Int32 session, + ffi.Pointer aid, + ffi.Int32 aid_len, + ffi.Uint8 P2, + ffi.Pointer channel, +); + +typedef _dart_smartcard_session_open_logical_channel = int Function( + int session, + ffi.Pointer aid, + int aid_len, + int P2, + ffi.Pointer channel, +); + +typedef _c_smartcard_channel_close = ffi.Int32 Function( + ffi.Int32 channel, +); + +typedef _dart_smartcard_channel_close = int Function( + int channel, +); + +typedef _c_smartcard_channel_is_basic_channel = ffi.Int32 Function( + ffi.Int32 channel, + ffi.Pointer is_basic_channel, +); + +typedef _dart_smartcard_channel_is_basic_channel = int Function( + int channel, + ffi.Pointer is_basic_channel, +); + +typedef _c_smartcard_channel_is_closed = ffi.Int32 Function( + ffi.Int32 channel, + ffi.Pointer is_closed, +); + +typedef _dart_smartcard_channel_is_closed = int Function( + int channel, + ffi.Pointer is_closed, +); + +typedef _c_smartcard_channel_get_select_response = ffi.Int32 Function( + ffi.Int32 channel, + ffi.Pointer> select_resp, + ffi.Pointer length, +); + +typedef _dart_smartcard_channel_get_select_response = int Function( + int channel, + ffi.Pointer> select_resp, + ffi.Pointer length, +); + +typedef _c_smartcard_channel_get_session = ffi.Int32 Function( + ffi.Int32 channel, + ffi.Pointer session, +); + +typedef _dart_smartcard_channel_get_session = int Function( + int channel, + ffi.Pointer session, +); + +typedef _c_smartcard_channel_transmit = ffi.Int32 Function( + ffi.Int32 channel, + ffi.Pointer cmd, + ffi.Int32 cmd_len, + ffi.Pointer> resp, + ffi.Pointer length, +); + +typedef _dart_smartcard_channel_transmit = int Function( + int channel, + ffi.Pointer cmd, + int cmd_len, + ffi.Pointer> resp, + ffi.Pointer length, +); + +typedef _c_smartcard_channel_transmit_retrieve_response = ffi.Int32 Function( + ffi.Int32 channel, + ffi.Pointer> resp, + ffi.Pointer length, +); + +typedef _dart_smartcard_channel_transmit_retrieve_response = int Function( + int channel, + ffi.Pointer> resp, + ffi.Pointer length, +); + +typedef _c_smartcard_channel_select_next = ffi.Int32 Function( + ffi.Int32 channel, + ffi.Pointer is_success, +); + +typedef _dart_smartcard_channel_select_next = int Function( + int channel, + ffi.Pointer is_success, +); + +typedef _c_wifi_manager_initialize = ffi.Int32 Function( + ffi.Pointer> wifi, +); + +typedef _dart_wifi_manager_initialize = int Function( + ffi.Pointer> wifi, +); + +typedef _c_wifi_manager_deinitialize = ffi.Int32 Function( + ffi.Pointer wifi, +); + +typedef _dart_wifi_manager_deinitialize = int Function( + ffi.Pointer wifi, +); + +typedef wifi_manager_activated_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_wifi_manager_activate = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_activate = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_activate_with_wifi_picker_tested = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_activate_with_wifi_picker_tested = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef wifi_manager_deactivated_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_wifi_manager_deactivate = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_deactivate = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_is_activated = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer activated, +); + +typedef _dart_wifi_manager_is_activated = int Function( + ffi.Pointer wifi, + ffi.Pointer activated, +); + +typedef _c_wifi_manager_get_mac_address = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> mac_address, +); + +typedef _dart_wifi_manager_get_mac_address = int Function( + ffi.Pointer wifi, + ffi.Pointer> mac_address, +); + +typedef _c_wifi_manager_get_network_interface_name = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> name, +); + +typedef _dart_wifi_manager_get_network_interface_name = int Function( + ffi.Pointer wifi, + ffi.Pointer> name, +); + +typedef wifi_manager_scan_finished_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_wifi_manager_scan = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_scan = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_get_scan_state = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer scan_state, +); + +typedef _dart_wifi_manager_get_scan_state = int Function( + ffi.Pointer wifi, + ffi.Pointer scan_state, +); + +typedef _c_wifi_manager_scan_specific_ap = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer essid, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_scan_specific_ap = int Function( + ffi.Pointer wifi, + ffi.Pointer essid, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_specific_scan_create = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> specific_scan, +); + +typedef _dart_wifi_manager_specific_scan_create = int Function( + ffi.Pointer wifi, + ffi.Pointer> specific_scan, +); + +typedef _c_wifi_manager_specific_scan_destroy = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer specific_scan, +); + +typedef _dart_wifi_manager_specific_scan_destroy = int Function( + ffi.Pointer wifi, + ffi.Pointer specific_scan, +); + +typedef _c_wifi_manager_specific_scan_set_ssid = ffi.Int32 Function( + ffi.Pointer specific_scan, + ffi.Pointer essid, +); + +typedef _dart_wifi_manager_specific_scan_set_ssid = int Function( + ffi.Pointer specific_scan, + ffi.Pointer essid, +); + +typedef _c_wifi_manager_specific_scan_set_freq = ffi.Int32 Function( + ffi.Pointer specific_scan, + ffi.Int32 freq, +); + +typedef _dart_wifi_manager_specific_scan_set_freq = int Function( + ffi.Pointer specific_scan, + int freq, +); + +typedef _c_wifi_manager_specific_ap_start_multi_scan = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer specific_scan, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_specific_ap_start_multi_scan = int Function( + ffi.Pointer wifi, + ffi.Pointer specific_scan, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef wifi_manager_connected_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_wifi_manager_connect_hidden_ap = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer essid, + ffi.Int32 sec_type, + ffi.Pointer passphrase, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_connect_hidden_ap = int Function( + ffi.Pointer wifi, + ffi.Pointer essid, + int sec_type, + ffi.Pointer passphrase, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_get_connected_ap = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> ap, +); + +typedef _dart_wifi_manager_get_connected_ap = int Function( + ffi.Pointer wifi, + ffi.Pointer> ap, +); + +typedef wifi_manager_found_ap_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_wifi_manager_foreach_found_ap = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_foreach_found_ap = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_foreach_found_specific_ap = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_foreach_found_specific_ap = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_foreach_found_bssid_ap = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_foreach_found_bssid_ap = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_connect = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer ap, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_connect = int Function( + ffi.Pointer wifi, + ffi.Pointer ap, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef wifi_manager_disconnected_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_wifi_manager_disconnect = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer ap, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_disconnect = int Function( + ffi.Pointer wifi, + ffi.Pointer ap, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_connect_by_wps_pbc = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer ap, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_connect_by_wps_pbc = int Function( + ffi.Pointer wifi, + ffi.Pointer ap, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_connect_by_wps_pin = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer ap, + ffi.Pointer pin, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_connect_by_wps_pin = int Function( + ffi.Pointer wifi, + ffi.Pointer ap, + ffi.Pointer pin, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_connect_by_wps_pbc_without_ssid = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_connect_by_wps_pbc_without_ssid = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_connect_by_wps_pin_without_ssid = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer pin, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_connect_by_wps_pin_without_ssid = int Function( + ffi.Pointer wifi, + ffi.Pointer pin, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_cancel_wps = ffi.Int32 Function( + ffi.Pointer wifi, +); + +typedef _dart_wifi_manager_cancel_wps = int Function( + ffi.Pointer wifi, +); + +typedef _c_wifi_manager_forget_ap = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer ap, +); + +typedef _dart_wifi_manager_forget_ap = int Function( + ffi.Pointer wifi, + ffi.Pointer ap, +); + +typedef _c_wifi_manager_update_ap = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer ap, +); + +typedef _dart_wifi_manager_update_ap = int Function( + ffi.Pointer wifi, + ffi.Pointer ap, +); + +typedef _c_wifi_manager_add_vsie = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Int32 frame_id, + ffi.Pointer vsie_str, +); + +typedef _dart_wifi_manager_add_vsie = int Function( + ffi.Pointer wifi, + int frame_id, + ffi.Pointer vsie_str, +); + +typedef _c_wifi_manager_get_vsie = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Int32 frame_id, + ffi.Pointer> vsie_str, +); + +typedef _dart_wifi_manager_get_vsie = int Function( + ffi.Pointer wifi, + int frame_id, + ffi.Pointer> vsie_str, +); + +typedef _c_wifi_manager_remove_vsie = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Int32 frame_id, + ffi.Pointer vsie_str, +); + +typedef _dart_wifi_manager_remove_vsie = int Function( + ffi.Pointer wifi, + int frame_id, + ffi.Pointer vsie_str, +); + +typedef _c_wifi_manager_get_connection_state = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer connection_state, +); + +typedef _dart_wifi_manager_get_connection_state = int Function( + ffi.Pointer wifi, + ffi.Pointer connection_state, +); + +typedef wifi_manager_device_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_wifi_manager_set_device_state_changed_cb = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_set_device_state_changed_cb = int Function( + ffi.Pointer wifi, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_unset_device_state_changed_cb = ffi.Int32 Function( + ffi.Pointer wifi, +); + +typedef _dart_wifi_manager_unset_device_state_changed_cb = int Function( + ffi.Pointer wifi, +); + +typedef _c_wifi_manager_set_background_scan_cb = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_set_background_scan_cb = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_unset_background_scan_cb = ffi.Int32 Function( + ffi.Pointer wifi, +); + +typedef _dart_wifi_manager_unset_background_scan_cb = int Function( + ffi.Pointer wifi, +); + +typedef wifi_manager_scan_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_wifi_manager_set_scan_state_changed_cb = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_set_scan_state_changed_cb = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_unset_scan_state_changed_cb = ffi.Int32 Function( + ffi.Pointer wifi, +); + +typedef _dart_wifi_manager_unset_scan_state_changed_cb = int Function( + ffi.Pointer wifi, +); + +typedef wifi_manager_connection_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_wifi_manager_set_connection_state_changed_cb = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_set_connection_state_changed_cb = int Function( + ffi.Pointer wifi, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_unset_connection_state_changed_cb = ffi.Int32 Function( + ffi.Pointer wifi, +); + +typedef _dart_wifi_manager_unset_connection_state_changed_cb = int Function( + ffi.Pointer wifi, +); + +typedef wifi_manager_rssi_level_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_wifi_manager_set_rssi_level_changed_cb = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_set_rssi_level_changed_cb = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_unset_rssi_level_changed_cb = ffi.Int32 Function( + ffi.Pointer wifi, +); + +typedef _dart_wifi_manager_unset_rssi_level_changed_cb = int Function( + ffi.Pointer wifi, +); + +typedef wifi_manager_module_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_wifi_manager_set_module_state_changed_cb = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_set_module_state_changed_cb = int Function( + ffi.Pointer wifi, + ffi.Pointer> + callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_unset_module_state_changed_cb = ffi.Int32 Function( + ffi.Pointer wifi, +); + +typedef _dart_wifi_manager_unset_module_state_changed_cb = int Function( + ffi.Pointer wifi, +); + +typedef _c_wifi_manager_get_module_state = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer state, +); + +typedef _dart_wifi_manager_get_module_state = int Function( + ffi.Pointer wifi, + ffi.Pointer state, +); + +typedef wifi_manager_bssid_scan_finished_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_wifi_manager_bssid_scan = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_bssid_scan = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_ap_create = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer essid, + ffi.Pointer> ap, +); + +typedef _dart_wifi_manager_ap_create = int Function( + ffi.Pointer wifi, + ffi.Pointer essid, + ffi.Pointer> ap, +); + +typedef _c_wifi_manager_ap_hidden_create = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer essid, + ffi.Pointer> ap, +); + +typedef _dart_wifi_manager_ap_hidden_create = int Function( + ffi.Pointer wifi, + ffi.Pointer essid, + ffi.Pointer> ap, +); + +typedef _c_wifi_manager_ap_destroy = ffi.Int32 Function( + ffi.Pointer ap, +); + +typedef _dart_wifi_manager_ap_destroy = int Function( + ffi.Pointer ap, +); + +typedef _c_wifi_manager_ap_clone = ffi.Int32 Function( + ffi.Pointer> cloned_ap, + ffi.Pointer origin, +); + +typedef _dart_wifi_manager_ap_clone = int Function( + ffi.Pointer> cloned_ap, + ffi.Pointer origin, +); + +typedef _c_wifi_manager_ap_refresh = ffi.Int32 Function( + ffi.Pointer ap, +); + +typedef _dart_wifi_manager_ap_refresh = int Function( + ffi.Pointer ap, +); + +typedef _c_wifi_manager_ap_get_essid = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer> essid, +); + +typedef _dart_wifi_manager_ap_get_essid = int Function( + ffi.Pointer ap, + ffi.Pointer> essid, +); + +typedef _c_wifi_manager_ap_get_raw_ssid = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer> ssid, + ffi.Pointer ssid_len, +); + +typedef _dart_wifi_manager_ap_get_raw_ssid = int Function( + ffi.Pointer ap, + ffi.Pointer> ssid, + ffi.Pointer ssid_len, +); + +typedef _c_wifi_manager_ap_get_bssid = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer> bssid, +); + +typedef _dart_wifi_manager_ap_get_bssid = int Function( + ffi.Pointer ap, + ffi.Pointer> bssid, +); + +typedef _c_wifi_manager_ap_get_rssi = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer rssi, +); + +typedef _dart_wifi_manager_ap_get_rssi = int Function( + ffi.Pointer ap, + ffi.Pointer rssi, +); + +typedef _c_wifi_manager_ap_get_rssi_level = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer rssi_level, +); + +typedef _dart_wifi_manager_ap_get_rssi_level = int Function( + ffi.Pointer ap, + ffi.Pointer rssi_level, +); + +typedef _c_wifi_manager_ap_get_frequency = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer frequency, +); + +typedef _dart_wifi_manager_ap_get_frequency = int Function( + ffi.Pointer ap, + ffi.Pointer frequency, +); + +typedef _c_wifi_manager_ap_get_max_speed = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer max_speed, +); + +typedef _dart_wifi_manager_ap_get_max_speed = int Function( + ffi.Pointer ap, + ffi.Pointer max_speed, +); + +typedef _c_wifi_manager_ap_is_favorite = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer favorite, +); + +typedef _dart_wifi_manager_ap_is_favorite = int Function( + ffi.Pointer ap, + ffi.Pointer favorite, +); + +typedef _c_wifi_manager_ap_is_passpoint = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer passpoint, +); + +typedef _dart_wifi_manager_ap_is_passpoint = int Function( + ffi.Pointer ap, + ffi.Pointer passpoint, +); + +typedef _c_wifi_manager_ap_get_connection_state = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer state, +); + +typedef _dart_wifi_manager_ap_get_connection_state = int Function( + ffi.Pointer ap, + ffi.Pointer state, +); + +typedef _c_wifi_manager_ap_get_ip_config_type = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Pointer type, +); + +typedef _dart_wifi_manager_ap_get_ip_config_type = int Function( + ffi.Pointer ap, + int address_family, + ffi.Pointer type, +); + +typedef _c_wifi_manager_ap_set_ip_config_type = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Int32 type, +); + +typedef _dart_wifi_manager_ap_set_ip_config_type = int Function( + ffi.Pointer ap, + int address_family, + int type, +); + +typedef _c_wifi_manager_ap_get_ip_address = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Pointer> ip_address, +); + +typedef _dart_wifi_manager_ap_get_ip_address = int Function( + ffi.Pointer ap, + int address_family, + ffi.Pointer> ip_address, +); + +typedef _c_wifi_manager_ap_set_ip_address = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Pointer ip_address, +); + +typedef _dart_wifi_manager_ap_set_ip_address = int Function( + ffi.Pointer ap, + int address_family, + ffi.Pointer ip_address, +); + +typedef wifi_manager_ap_ipv6_address_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_wifi_manager_ap_foreach_ipv6_address = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_ap_foreach_ipv6_address = int Function( + ffi.Pointer ap, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_ap_get_subnet_mask = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Pointer> subnet_mask, +); + +typedef _dart_wifi_manager_ap_get_subnet_mask = int Function( + ffi.Pointer ap, + int address_family, + ffi.Pointer> subnet_mask, +); + +typedef _c_wifi_manager_ap_set_subnet_mask = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Pointer subnet_mask, +); + +typedef _dart_wifi_manager_ap_set_subnet_mask = int Function( + ffi.Pointer ap, + int address_family, + ffi.Pointer subnet_mask, +); + +typedef _c_wifi_manager_ap_get_gateway_address = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Pointer> gateway_address, +); + +typedef _dart_wifi_manager_ap_get_gateway_address = int Function( + ffi.Pointer ap, + int address_family, + ffi.Pointer> gateway_address, +); + +typedef _c_wifi_manager_ap_set_gateway_address = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Pointer gateway_address, +); + +typedef _dart_wifi_manager_ap_set_gateway_address = int Function( + ffi.Pointer ap, + int address_family, + ffi.Pointer gateway_address, +); + +typedef _c_wifi_manager_ap_get_dhcp_server_address = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Pointer> dhcp_server, +); + +typedef _dart_wifi_manager_ap_get_dhcp_server_address = int Function( + ffi.Pointer ap, + int address_family, + ffi.Pointer> dhcp_server, +); + +typedef _c_wifi_manager_ap_get_dhcp_lease_duration = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Pointer dhcp_lease_duration, +); + +typedef _dart_wifi_manager_ap_get_dhcp_lease_duration = int Function( + ffi.Pointer ap, + int address_family, + ffi.Pointer dhcp_lease_duration, +); + +typedef _c_wifi_manager_ap_get_proxy_address = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Pointer> proxy_address, +); + +typedef _dart_wifi_manager_ap_get_proxy_address = int Function( + ffi.Pointer ap, + int address_family, + ffi.Pointer> proxy_address, +); + +typedef _c_wifi_manager_ap_set_proxy_address = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Pointer proxy_address, +); + +typedef _dart_wifi_manager_ap_set_proxy_address = int Function( + ffi.Pointer ap, + int address_family, + ffi.Pointer proxy_address, +); + +typedef _c_wifi_manager_ap_get_proxy_type = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer proxy_type, +); + +typedef _dart_wifi_manager_ap_get_proxy_type = int Function( + ffi.Pointer ap, + ffi.Pointer proxy_type, +); + +typedef _c_wifi_manager_ap_set_proxy_type = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 proxy_type, +); + +typedef _dart_wifi_manager_ap_set_proxy_type = int Function( + ffi.Pointer ap, + int proxy_type, +); + +typedef _c_wifi_manager_ap_get_dns_address = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 order, + ffi.Int32 address_family, + ffi.Pointer> dns_address, +); + +typedef _dart_wifi_manager_ap_get_dns_address = int Function( + ffi.Pointer ap, + int order, + int address_family, + ffi.Pointer> dns_address, +); + +typedef _c_wifi_manager_ap_set_dns_address = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 order, + ffi.Int32 address_family, + ffi.Pointer dns_address, +); + +typedef _dart_wifi_manager_ap_set_dns_address = int Function( + ffi.Pointer ap, + int order, + int address_family, + ffi.Pointer dns_address, +); + +typedef _c_wifi_manager_ap_get_dns_config_type = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Pointer type, +); + +typedef _dart_wifi_manager_ap_get_dns_config_type = int Function( + ffi.Pointer ap, + int address_family, + ffi.Pointer type, +); + +typedef _c_wifi_manager_ap_set_dns_config_type = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Int32 type, +); + +typedef _dart_wifi_manager_ap_set_dns_config_type = int Function( + ffi.Pointer ap, + int address_family, + int type, +); + +typedef _c_wifi_manager_ap_get_prefix_length = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Pointer prefix_len, +); + +typedef _dart_wifi_manager_ap_get_prefix_length = int Function( + ffi.Pointer ap, + int address_family, + ffi.Pointer prefix_len, +); + +typedef _c_wifi_manager_ap_set_prefix_length = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 address_family, + ffi.Int32 prefix_len, +); + +typedef _dart_wifi_manager_ap_set_prefix_length = int Function( + ffi.Pointer ap, + int address_family, + int prefix_len, +); + +typedef _c_wifi_manager_ap_get_disconnect_reason = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer disconnect_reason, +); + +typedef _dart_wifi_manager_ap_get_disconnect_reason = int Function( + ffi.Pointer ap, + ffi.Pointer disconnect_reason, +); + +typedef _c_wifi_manager_ap_get_error_state = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer error_state, +); + +typedef _dart_wifi_manager_ap_get_error_state = int Function( + ffi.Pointer ap, + ffi.Pointer error_state, +); + +typedef _c_wifi_manager_ap_get_assoc_status_code = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer status_code, +); + +typedef _dart_wifi_manager_ap_get_assoc_status_code = int Function( + ffi.Pointer ap, + ffi.Pointer status_code, +); + +typedef _c_wifi_manager_ap_get_vsie = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer> vsie, + ffi.Pointer length, +); + +typedef _dart_wifi_manager_ap_get_vsie = int Function( + ffi.Pointer ap, + ffi.Pointer> vsie, + ffi.Pointer length, +); + +typedef _c_wifi_manager_ap_get_security_type = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer type, +); + +typedef _dart_wifi_manager_ap_get_security_type = int Function( + ffi.Pointer ap, + ffi.Pointer type, +); + +typedef _c_wifi_manager_ap_set_security_type = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 type, +); + +typedef _dart_wifi_manager_ap_set_security_type = int Function( + ffi.Pointer ap, + int type, +); + +typedef _c_wifi_manager_ap_get_encryption_type = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer type, +); + +typedef _dart_wifi_manager_ap_get_encryption_type = int Function( + ffi.Pointer ap, + ffi.Pointer type, +); + +typedef _c_wifi_manager_ap_set_encryption_type = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 type, +); + +typedef _dart_wifi_manager_ap_set_encryption_type = int Function( + ffi.Pointer ap, + int type, +); + +typedef _c_wifi_manager_ap_is_passphrase_required = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer required, +); + +typedef _dart_wifi_manager_ap_is_passphrase_required = int Function( + ffi.Pointer ap, + ffi.Pointer required, +); + +typedef _c_wifi_manager_ap_set_passphrase = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer passphrase, +); + +typedef _dart_wifi_manager_ap_set_passphrase = int Function( + ffi.Pointer ap, + ffi.Pointer passphrase, +); + +typedef _c_wifi_manager_ap_is_wps_supported = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer supported, +); + +typedef _dart_wifi_manager_ap_is_wps_supported = int Function( + ffi.Pointer ap, + ffi.Pointer supported, +); + +typedef _c_wifi_manager_ap_set_eap_passphrase = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer user_name, + ffi.Pointer password, +); + +typedef _dart_wifi_manager_ap_set_eap_passphrase = int Function( + ffi.Pointer ap, + ffi.Pointer user_name, + ffi.Pointer password, +); + +typedef _c_wifi_manager_ap_get_eap_passphrase = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer> user_name, + ffi.Pointer is_password_set, +); + +typedef _dart_wifi_manager_ap_get_eap_passphrase = int Function( + ffi.Pointer ap, + ffi.Pointer> user_name, + ffi.Pointer is_password_set, +); + +typedef _c_wifi_manager_ap_get_eap_ca_cert_file = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer> file, +); + +typedef _dart_wifi_manager_ap_get_eap_ca_cert_file = int Function( + ffi.Pointer ap, + ffi.Pointer> file, +); + +typedef _c_wifi_manager_ap_set_eap_ca_cert_file = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer file, +); + +typedef _dart_wifi_manager_ap_set_eap_ca_cert_file = int Function( + ffi.Pointer ap, + ffi.Pointer file, +); + +typedef _c_wifi_manager_ap_get_eap_client_cert_file = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer> file, +); + +typedef _dart_wifi_manager_ap_get_eap_client_cert_file = int Function( + ffi.Pointer ap, + ffi.Pointer> file, +); + +typedef _c_wifi_manager_ap_set_eap_client_cert_file = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer file, +); + +typedef _dart_wifi_manager_ap_set_eap_client_cert_file = int Function( + ffi.Pointer ap, + ffi.Pointer file, +); + +typedef _c_wifi_manager_ap_get_eap_private_key_file = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer> file, +); + +typedef _dart_wifi_manager_ap_get_eap_private_key_file = int Function( + ffi.Pointer ap, + ffi.Pointer> file, +); + +typedef _c_wifi_manager_ap_set_eap_private_key_info = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer file, + ffi.Pointer password, +); + +typedef _dart_wifi_manager_ap_set_eap_private_key_info = int Function( + ffi.Pointer ap, + ffi.Pointer file, + ffi.Pointer password, +); + +typedef _c_wifi_manager_ap_get_eap_type = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer type, +); + +typedef _dart_wifi_manager_ap_get_eap_type = int Function( + ffi.Pointer ap, + ffi.Pointer type, +); + +typedef _c_wifi_manager_ap_set_eap_type = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 type, +); + +typedef _dart_wifi_manager_ap_set_eap_type = int Function( + ffi.Pointer ap, + int type, +); + +typedef _c_wifi_manager_ap_get_eap_auth_type = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Pointer type, +); + +typedef _dart_wifi_manager_ap_get_eap_auth_type = int Function( + ffi.Pointer ap, + ffi.Pointer type, +); + +typedef _c_wifi_manager_ap_set_eap_auth_type = ffi.Int32 Function( + ffi.Pointer ap, + ffi.Int32 type, +); + +typedef _dart_wifi_manager_ap_set_eap_auth_type = int Function( + ffi.Pointer ap, + int type, +); + +typedef _c_wifi_manager_config_create = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer name, + ffi.Pointer passphrase, + ffi.Int32 security_type, + ffi.Pointer> config, +); + +typedef _dart_wifi_manager_config_create = int Function( + ffi.Pointer wifi, + ffi.Pointer name, + ffi.Pointer passphrase, + int security_type, + ffi.Pointer> config, +); + +typedef _c_wifi_manager_config_clone = ffi.Int32 Function( + ffi.Pointer origin, + ffi.Pointer> cloned_config, +); + +typedef _dart_wifi_manager_config_clone = int Function( + ffi.Pointer origin, + ffi.Pointer> cloned_config, +); + +typedef _c_wifi_manager_config_destroy = ffi.Int32 Function( + ffi.Pointer config, +); + +typedef _dart_wifi_manager_config_destroy = int Function( + ffi.Pointer config, +); + +typedef _c_wifi_manager_config_save = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer config, +); + +typedef _dart_wifi_manager_config_save = int Function( + ffi.Pointer wifi, + ffi.Pointer config, +); + +typedef _c_wifi_manager_config_remove = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer config, +); + +typedef _dart_wifi_manager_config_remove = int Function( + ffi.Pointer wifi, + ffi.Pointer config, +); + +typedef wifi_manager_config_list_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_wifi_manager_config_foreach_configuration = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_config_foreach_configuration = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_config_get_name = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer> name, +); + +typedef _dart_wifi_manager_config_get_name = int Function( + ffi.Pointer config, + ffi.Pointer> name, +); + +typedef _c_wifi_manager_config_get_security_type = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer security_type, +); + +typedef _dart_wifi_manager_config_get_security_type = int Function( + ffi.Pointer config, + ffi.Pointer security_type, +); + +typedef _c_wifi_manager_config_set_proxy_address = ffi.Int32 Function( + ffi.Pointer config, + ffi.Int32 address_family, + ffi.Pointer proxy_address, +); + +typedef _dart_wifi_manager_config_set_proxy_address = int Function( + ffi.Pointer config, + int address_family, + ffi.Pointer proxy_address, +); + +typedef _c_wifi_manager_config_get_proxy_address = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer address_family, + ffi.Pointer> proxy_address, +); + +typedef _dart_wifi_manager_config_get_proxy_address = int Function( + ffi.Pointer config, + ffi.Pointer address_family, + ffi.Pointer> proxy_address, +); + +typedef _c_wifi_manager_config_set_hidden_ap_property = ffi.Int32 Function( + ffi.Pointer config, + ffi.Uint8 is_hidden, +); + +typedef _dart_wifi_manager_config_set_hidden_ap_property = int Function( + ffi.Pointer config, + int is_hidden, +); + +typedef _c_wifi_manager_config_get_hidden_ap_property = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer is_hidden, +); + +typedef _dart_wifi_manager_config_get_hidden_ap_property = int Function( + ffi.Pointer config, + ffi.Pointer is_hidden, +); + +typedef _c_wifi_manager_config_get_eap_anonymous_identity = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer> anonymous_identity, +); + +typedef _dart_wifi_manager_config_get_eap_anonymous_identity = int Function( + ffi.Pointer config, + ffi.Pointer> anonymous_identity, +); + +typedef _c_wifi_manager_config_set_eap_anonymous_identity = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer anonymous_identity, +); + +typedef _dart_wifi_manager_config_set_eap_anonymous_identity = int Function( + ffi.Pointer config, + ffi.Pointer anonymous_identity, +); + +typedef _c_wifi_manager_config_get_eap_ca_cert_file = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer> ca_cert, +); + +typedef _dart_wifi_manager_config_get_eap_ca_cert_file = int Function( + ffi.Pointer config, + ffi.Pointer> ca_cert, +); + +typedef _c_wifi_manager_config_set_eap_ca_cert_file = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer ca_cert, +); + +typedef _dart_wifi_manager_config_set_eap_ca_cert_file = int Function( + ffi.Pointer config, + ffi.Pointer ca_cert, +); + +typedef _c_wifi_manager_config_get_eap_client_cert_file = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer> client_cert, +); + +typedef _dart_wifi_manager_config_get_eap_client_cert_file = int Function( + ffi.Pointer config, + ffi.Pointer> client_cert, +); + +typedef _c_wifi_manager_config_set_eap_client_cert_file = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer private_key, + ffi.Pointer client_cert, +); + +typedef _dart_wifi_manager_config_set_eap_client_cert_file = int Function( + ffi.Pointer config, + ffi.Pointer private_key, + ffi.Pointer client_cert, +); + +typedef _c_wifi_manager_config_get_eap_identity = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer> identity, +); + +typedef _dart_wifi_manager_config_get_eap_identity = int Function( + ffi.Pointer config, + ffi.Pointer> identity, +); + +typedef _c_wifi_manager_config_set_eap_identity = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer identity, +); + +typedef _dart_wifi_manager_config_set_eap_identity = int Function( + ffi.Pointer config, + ffi.Pointer identity, +); + +typedef _c_wifi_manager_config_get_eap_type = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer eap_type, +); + +typedef _dart_wifi_manager_config_get_eap_type = int Function( + ffi.Pointer config, + ffi.Pointer eap_type, +); + +typedef _c_wifi_manager_config_set_eap_type = ffi.Int32 Function( + ffi.Pointer config, + ffi.Int32 eap_type, +); + +typedef _dart_wifi_manager_config_set_eap_type = int Function( + ffi.Pointer config, + int eap_type, +); + +typedef _c_wifi_manager_config_get_eap_auth_type = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer eap_auth_type, +); + +typedef _dart_wifi_manager_config_get_eap_auth_type = int Function( + ffi.Pointer config, + ffi.Pointer eap_auth_type, +); + +typedef _c_wifi_manager_config_set_eap_auth_type = ffi.Int32 Function( + ffi.Pointer config, + ffi.Int32 eap_auth_type, +); + +typedef _dart_wifi_manager_config_set_eap_auth_type = int Function( + ffi.Pointer config, + int eap_auth_type, +); + +typedef _c_wifi_manager_config_get_eap_subject_match = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer> subject_match, +); + +typedef _dart_wifi_manager_config_get_eap_subject_match = int Function( + ffi.Pointer config, + ffi.Pointer> subject_match, +); + +typedef _c_wifi_manager_config_set_eap_subject_match = ffi.Int32 Function( + ffi.Pointer config, + ffi.Pointer subject_match, +); + +typedef _dart_wifi_manager_config_set_eap_subject_match = int Function( + ffi.Pointer config, + ffi.Pointer subject_match, +); + +typedef wifi_manager_tdls_discovered_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_wifi_manager_tdls_set_discovered_cb = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_tdls_set_discovered_cb = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_tdls_unset_discovered_cb = ffi.Int32 Function( + ffi.Pointer wifi, +); + +typedef _dart_wifi_manager_tdls_unset_discovered_cb = int Function( + ffi.Pointer wifi, +); + +typedef _c_wifi_manager_tdls_start_discovery = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, +); + +typedef _dart_wifi_manager_tdls_start_discovery = int Function( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, +); + +typedef _c_wifi_manager_tdls_connect = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, +); + +typedef _dart_wifi_manager_tdls_connect = int Function( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, +); + +typedef _c_wifi_manager_tdls_disconnect = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, +); + +typedef _dart_wifi_manager_tdls_disconnect = int Function( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, +); + +typedef _c_wifi_manager_tdls_get_connected_peer = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> peer_mac_addr, +); + +typedef _dart_wifi_manager_tdls_get_connected_peer = int Function( + ffi.Pointer wifi, + ffi.Pointer> peer_mac_addr, +); + +typedef wifi_manager_tdls_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_wifi_manager_tdls_set_state_changed_cb = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_tdls_set_state_changed_cb = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_tdls_unset_state_changed_cb = ffi.Int32 Function( + ffi.Pointer wifi, +); + +typedef _dart_wifi_manager_tdls_unset_state_changed_cb = int Function( + ffi.Pointer wifi, +); + +typedef _c_wifi_manager_tdls_enable_channel_switching = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, + ffi.Int32 freq, +); + +typedef _dart_wifi_manager_tdls_enable_channel_switching = int Function( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, + int freq, +); + +typedef _c_wifi_manager_tdls_disable_channel_switching = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, +); + +typedef _dart_wifi_manager_tdls_disable_channel_switching = int Function( + ffi.Pointer wifi, + ffi.Pointer peer_mac_addr, +); + +typedef wifi_manager_ip_conflict_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_wifi_manager_set_ip_conflict_cb = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_wifi_manager_set_ip_conflict_cb = int Function( + ffi.Pointer wifi, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_wifi_manager_unset_ip_conflict_cb = ffi.Int32 Function( + ffi.Pointer wifi, +); + +typedef _dart_wifi_manager_unset_ip_conflict_cb = int Function( + ffi.Pointer wifi, +); + +typedef _c_wifi_manager_set_ip_conflict_detect_enable = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Uint8 detect, +); + +typedef _dart_wifi_manager_set_ip_conflict_detect_enable = int Function( + ffi.Pointer wifi, + int detect, +); + +typedef _c_wifi_manager_ip_conflict_detect_is_enabled = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer state, +); + +typedef _dart_wifi_manager_ip_conflict_detect_is_enabled = int Function( + ffi.Pointer wifi, + ffi.Pointer state, +); + +typedef _c_wifi_manager_get_ip_conflict_state = ffi.Int32 Function( + ffi.Pointer wifi, + ffi.Pointer state, +); + +typedef _dart_wifi_manager_get_ip_conflict_state = int Function( + ffi.Pointer wifi, + ffi.Pointer state, +); + +typedef _c_csr_get_current_engine = ffi.Int32 Function( + ffi.Int32 id, + ffi.Pointer> engine, +); + +typedef _dart_csr_get_current_engine = int Function( + int id, + ffi.Pointer> engine, +); + +typedef _c_csr_engine_get_vendor = ffi.Int32 Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer> vendor, +); + +typedef _dart_csr_engine_get_vendor = int Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer> vendor, +); + +typedef _c_csr_engine_get_name = ffi.Int32 Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer> name, +); + +typedef _dart_csr_engine_get_name = int Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer> name, +); + +typedef _c_csr_engine_get_version = ffi.Int32 Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer> version, +); + +typedef _dart_csr_engine_get_version = int Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer> version, +); + +typedef _c_csr_engine_get_data_version = ffi.Int32 Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer> version, +); + +typedef _dart_csr_engine_get_data_version = int Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer> version, +); + +typedef _c_csr_engine_get_latest_update_time = ffi.Int32 Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer time, +); + +typedef _dart_csr_engine_get_latest_update_time = int Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer time, +); + +typedef _c_csr_engine_get_activated = ffi.Int32 Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer activated, +); + +typedef _dart_csr_engine_get_activated = int Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer activated, +); + +typedef _c_csr_engine_set_state = ffi.Int32 Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Int32 state, +); + +typedef _dart_csr_engine_set_state = int Function( + ffi.Pointer<__csr_engine_h> engine, + int state, +); + +typedef _c_csr_engine_get_state = ffi.Int32 Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer state, +); + +typedef _dart_csr_engine_get_state = int Function( + ffi.Pointer<__csr_engine_h> engine, + ffi.Pointer state, +); + +typedef _c_csr_engine_destroy = ffi.Int32 Function( + ffi.Pointer<__csr_engine_h> engine, +); + +typedef _dart_csr_engine_destroy = int Function( + ffi.Pointer<__csr_engine_h> engine, +); + +typedef _c_csr_cs_context_create = ffi.Int32 Function( + ffi.Pointer> handle, +); + +typedef _dart_csr_cs_context_create = int Function( + ffi.Pointer> handle, +); + +typedef _c_csr_cs_context_destroy = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, +); + +typedef _dart_csr_cs_context_destroy = int Function( + ffi.Pointer<__csr_cs_context_s> handle, +); + +typedef _c_csr_cs_set_ask_user = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Int32 ask_user, +); + +typedef _dart_csr_cs_set_ask_user = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + int ask_user, +); + +typedef _c_csr_cs_set_popup_message = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer message, +); + +typedef _dart_csr_cs_set_popup_message = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer message, +); + +typedef _c_csr_cs_set_core_usage = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Int32 usage, +); + +typedef _dart_csr_cs_set_core_usage = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + int usage, +); + +typedef _c_csr_cs_set_scan_on_cloud = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Uint8 scan_on_cloud, +); + +typedef _dart_csr_cs_set_scan_on_cloud = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + int scan_on_cloud, +); + +typedef _c_csr_cs_scan_data = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer data, + ffi.Int32 length, + ffi.Pointer> malware, +); + +typedef _dart_csr_cs_scan_data = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer data, + int length, + ffi.Pointer> malware, +); + +typedef _c_csr_cs_scan_file = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer file_path, + ffi.Pointer> malware, +); + +typedef _dart_csr_cs_scan_file = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer file_path, + ffi.Pointer> malware, +); + +typedef csr_cs_file_scanned_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_csr_cs_set_file_scanned_cb = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, +); + +typedef _dart_csr_cs_set_file_scanned_cb = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, +); + +typedef csr_cs_detected_cb = ffi.Void Function( + ffi.Pointer<__csr_cs_malware_s>, + ffi.Pointer, +); + +typedef _c_csr_cs_set_detected_cb = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, +); + +typedef _dart_csr_cs_set_detected_cb = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, +); + +typedef csr_cs_completed_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef _c_csr_cs_set_completed_cb = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, +); + +typedef _dart_csr_cs_set_completed_cb = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, +); + +typedef csr_cs_cancelled_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef _c_csr_cs_set_cancelled_cb = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, +); + +typedef _dart_csr_cs_set_cancelled_cb = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, +); + +typedef csr_cs_error_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_csr_cs_set_error_cb = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, +); + +typedef _dart_csr_cs_set_error_cb = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> callback, +); + +typedef _c_csr_cs_scan_files_async = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> file_paths, + ffi.Int32 count, + ffi.Pointer user_data, +); + +typedef _dart_csr_cs_scan_files_async = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> file_paths, + int count, + ffi.Pointer user_data, +); + +typedef _c_csr_cs_scan_dir_async = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer dir_path, + ffi.Pointer user_data, +); + +typedef _dart_csr_cs_scan_dir_async = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer dir_path, + ffi.Pointer user_data, +); + +typedef _c_csr_cs_scan_dirs_async = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> dir_paths, + ffi.Int32 count, + ffi.Pointer user_data, +); + +typedef _dart_csr_cs_scan_dirs_async = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> dir_paths, + int count, + ffi.Pointer user_data, +); + +typedef _c_csr_cs_cancel_scanning = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, +); + +typedef _dart_csr_cs_cancel_scanning = int Function( + ffi.Pointer<__csr_cs_context_s> handle, +); + +typedef _c_csr_cs_malware_get_severity = ffi.Int32 Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer severity, +); + +typedef _dart_csr_cs_malware_get_severity = int Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer severity, +); + +typedef _c_csr_cs_malware_get_name = ffi.Int32 Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer> name, +); + +typedef _dart_csr_cs_malware_get_name = int Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer> name, +); + +typedef _c_csr_cs_malware_get_detailed_url = ffi.Int32 Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer> detailed_url, +); + +typedef _dart_csr_cs_malware_get_detailed_url = int Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer> detailed_url, +); + +typedef _c_csr_cs_malware_get_timestamp = ffi.Int32 Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer timestamp, +); + +typedef _dart_csr_cs_malware_get_timestamp = int Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer timestamp, +); + +typedef _c_csr_cs_malware_get_file_name = ffi.Int32 Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer> file_name, +); + +typedef _dart_csr_cs_malware_get_file_name = int Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer> file_name, +); + +typedef _c_csr_cs_malware_get_user_response = ffi.Int32 Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer response, +); + +typedef _dart_csr_cs_malware_get_user_response = int Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer response, +); + +typedef _c_csr_cs_malware_is_app = ffi.Int32 Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer is_app, +); + +typedef _dart_csr_cs_malware_is_app = int Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer is_app, +); + +typedef _c_csr_cs_malware_get_pkg_id = ffi.Int32 Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer> pkg_id, +); + +typedef _dart_csr_cs_malware_get_pkg_id = int Function( + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Pointer> pkg_id, +); + +typedef _c_csr_cs_judge_detected_malware = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer<__csr_cs_malware_s> malware, + ffi.Int32 action, +); + +typedef _dart_csr_cs_judge_detected_malware = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer<__csr_cs_malware_s> malware, + int action, +); + +typedef _c_csr_cs_get_detected_malware = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer file_path, + ffi.Pointer> malware, +); + +typedef _dart_csr_cs_get_detected_malware = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer file_path, + ffi.Pointer> malware, +); + +typedef _c_csr_cs_get_detected_malwares = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> dir_paths, + ffi.Int32 count, + ffi.Pointer> list, + ffi.Pointer list_count, +); + +typedef _dart_csr_cs_get_detected_malwares = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> dir_paths, + int count, + ffi.Pointer> list, + ffi.Pointer list_count, +); + +typedef _c_csr_cs_get_ignored_malware = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer file_path, + ffi.Pointer> malware, +); + +typedef _dart_csr_cs_get_ignored_malware = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer file_path, + ffi.Pointer> malware, +); + +typedef _c_csr_cs_get_ignored_malwares = ffi.Int32 Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> dir_paths, + ffi.Int32 count, + ffi.Pointer> list, + ffi.Pointer list_count, +); + +typedef _dart_csr_cs_get_ignored_malwares = int Function( + ffi.Pointer<__csr_cs_context_s> handle, + ffi.Pointer> dir_paths, + int count, + ffi.Pointer> list, + ffi.Pointer list_count, +); + +typedef _c_csr_cs_malware_list_get_malware = ffi.Int32 Function( + ffi.Pointer<__csr_cs_malware_list_s> list, + ffi.Int32 index, + ffi.Pointer> malware, +); + +typedef _dart_csr_cs_malware_list_get_malware = int Function( + ffi.Pointer<__csr_cs_malware_list_s> list, + int index, + ffi.Pointer> malware, +); + +typedef _c_csr_wp_context_create = ffi.Int32 Function( + ffi.Pointer> handle, +); + +typedef _dart_csr_wp_context_create = int Function( + ffi.Pointer> handle, +); + +typedef _c_csr_wp_context_destroy = ffi.Int32 Function( + ffi.Pointer<__csr_wp_context_s> handle, +); + +typedef _dart_csr_wp_context_destroy = int Function( + ffi.Pointer<__csr_wp_context_s> handle, +); + +typedef _c_csr_wp_set_ask_user = ffi.Int32 Function( + ffi.Pointer<__csr_wp_context_s> handle, + ffi.Int32 ask_user, +); + +typedef _dart_csr_wp_set_ask_user = int Function( + ffi.Pointer<__csr_wp_context_s> handle, + int ask_user, +); + +typedef _c_csr_wp_set_popup_message = ffi.Int32 Function( + ffi.Pointer<__csr_wp_context_s> handle, + ffi.Pointer message, +); + +typedef _dart_csr_wp_set_popup_message = int Function( + ffi.Pointer<__csr_wp_context_s> handle, + ffi.Pointer message, +); + +typedef _c_csr_wp_check_url = ffi.Int32 Function( + ffi.Pointer<__csr_wp_context_s> handle, + ffi.Pointer url, + ffi.Pointer> result, +); + +typedef _dart_csr_wp_check_url = int Function( + ffi.Pointer<__csr_wp_context_s> handle, + ffi.Pointer url, + ffi.Pointer> result, +); + +typedef _c_csr_wp_result_get_risk_level = ffi.Int32 Function( + ffi.Pointer<__csr_wp_check_result_h> result, + ffi.Pointer level, +); + +typedef _dart_csr_wp_result_get_risk_level = int Function( + ffi.Pointer<__csr_wp_check_result_h> result, + ffi.Pointer level, +); + +typedef _c_csr_wp_result_get_detailed_url = ffi.Int32 Function( + ffi.Pointer<__csr_wp_check_result_h> result, + ffi.Pointer> detailed_url, +); + +typedef _dart_csr_wp_result_get_detailed_url = int Function( + ffi.Pointer<__csr_wp_check_result_h> result, + ffi.Pointer> detailed_url, +); + +typedef _c_csr_wp_result_get_user_response = ffi.Int32 Function( + ffi.Pointer<__csr_wp_check_result_h> result, + ffi.Pointer response, +); + +typedef _dart_csr_wp_result_get_user_response = int Function( + ffi.Pointer<__csr_wp_check_result_h> result, + ffi.Pointer response, +); + +typedef _c_dpm_manager_create = ffi.Pointer Function(); + +typedef _dart_dpm_manager_create = ffi.Pointer Function(); + +typedef _c_dpm_manager_destroy = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_dpm_manager_destroy = int Function( + ffi.Pointer handle, +); + +typedef dpm_policy_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_dpm_add_policy_changed_cb = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer name, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _dart_dpm_add_policy_changed_cb = int Function( + ffi.Pointer handle, + ffi.Pointer name, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _c_dpm_remove_policy_changed_cb = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 id, +); + +typedef _dart_dpm_remove_policy_changed_cb = int Function( + ffi.Pointer handle, + int id, +); + +typedef dpm_signal_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_dpm_add_signal_cb = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer signal, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _dart_dpm_add_signal_cb = int Function( + ffi.Pointer handle, + ffi.Pointer signal, + ffi.Pointer> callback, + ffi.Pointer user_data, + ffi.Pointer id, +); + +typedef _c_dpm_remove_signal_cb = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 id, +); + +typedef _dart_dpm_remove_signal_cb = int Function( + ffi.Pointer handle, + int id, +); + +typedef _c_dpm_password_set_quality = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 quality, +); + +typedef _dart_dpm_password_set_quality = int Function( + ffi.Pointer handle, + int quality, +); + +typedef _c_dpm_password_get_quality = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer quality, +); + +typedef _dart_dpm_password_get_quality = int Function( + ffi.Pointer handle, + ffi.Pointer quality, +); + +typedef _c_dpm_password_set_minimum_length = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 value, +); + +typedef _dart_dpm_password_set_minimum_length = int Function( + ffi.Pointer handle, + int value, +); + +typedef _c_dpm_password_get_minimum_length = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _dart_dpm_password_get_minimum_length = int Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _c_dpm_password_set_min_complex_chars = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 value, +); + +typedef _dart_dpm_password_set_min_complex_chars = int Function( + ffi.Pointer handle, + int value, +); + +typedef _c_dpm_password_get_min_complex_chars = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _dart_dpm_password_get_min_complex_chars = int Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _c_dpm_password_set_maximum_failed_attempts_for_wipe = ffi.Int32 + Function( + ffi.Pointer handle, + ffi.Int32 value, +); + +typedef _dart_dpm_password_set_maximum_failed_attempts_for_wipe = int Function( + ffi.Pointer handle, + int value, +); + +typedef _c_dpm_password_get_maximum_failed_attempts_for_wipe = ffi.Int32 + Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _dart_dpm_password_get_maximum_failed_attempts_for_wipe = int Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _c_dpm_password_set_expires = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 value, +); + +typedef _dart_dpm_password_set_expires = int Function( + ffi.Pointer handle, + int value, +); + +typedef _c_dpm_password_get_expires = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _dart_dpm_password_get_expires = int Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _c_dpm_password_set_history = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 value, +); + +typedef _dart_dpm_password_set_history = int Function( + ffi.Pointer handle, + int value, +); + +typedef _c_dpm_password_get_history = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _dart_dpm_password_get_history = int Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _c_dpm_password_set_pattern = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer pattern, +); + +typedef _dart_dpm_password_set_pattern = int Function( + ffi.Pointer handle, + ffi.Pointer pattern, +); + +typedef _c_dpm_password_reset = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer password, +); + +typedef _dart_dpm_password_reset = int Function( + ffi.Pointer handle, + ffi.Pointer password, +); + +typedef _c_dpm_password_enforce_change = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_dpm_password_enforce_change = int Function( + ffi.Pointer handle, +); + +typedef _c_dpm_password_set_max_inactivity_time_device_lock = ffi.Int32 + Function( + ffi.Pointer handle, + ffi.Int32 value, +); + +typedef _dart_dpm_password_set_max_inactivity_time_device_lock = int Function( + ffi.Pointer handle, + int value, +); + +typedef _c_dpm_password_get_max_inactivity_time_device_lock = ffi.Int32 + Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _dart_dpm_password_get_max_inactivity_time_device_lock = int Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _c_dpm_password_set_status = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 status, +); + +typedef _dart_dpm_password_set_status = int Function( + ffi.Pointer handle, + int status, +); + +typedef _c_dpm_password_get_status = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer status, +); + +typedef _dart_dpm_password_get_status = int Function( + ffi.Pointer handle, + ffi.Pointer status, +); + +typedef _c_dpm_password_delete_pattern = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_dpm_password_delete_pattern = int Function( + ffi.Pointer handle, +); + +typedef _c_dpm_password_get_pattern = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> pattern, +); + +typedef _dart_dpm_password_get_pattern = int Function( + ffi.Pointer handle, + ffi.Pointer> pattern, +); + +typedef _c_dpm_password_set_maximum_character_occurrences = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 value, +); + +typedef _dart_dpm_password_set_maximum_character_occurrences = int Function( + ffi.Pointer handle, + int value, +); + +typedef _c_dpm_password_get_maximum_character_occurrences = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _dart_dpm_password_get_maximum_character_occurrences = int Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _c_dpm_password_set_maximum_numeric_sequence_length = ffi.Int32 + Function( + ffi.Pointer handle, + ffi.Int32 value, +); + +typedef _dart_dpm_password_set_maximum_numeric_sequence_length = int Function( + ffi.Pointer handle, + int value, +); + +typedef _c_dpm_password_get_maximum_numeric_sequence_length = ffi.Int32 + Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _dart_dpm_password_get_maximum_numeric_sequence_length = int Function( + ffi.Pointer handle, + ffi.Pointer value, +); + +typedef _c_dpm_password_create_iterator = ffi.Pointer Function( + ffi.Pointer handle, +); + +typedef _dart_dpm_password_create_iterator = ffi.Pointer Function( + ffi.Pointer handle, +); + +typedef _c_dpm_password_iterator_next = ffi.Int32 Function( + ffi.Pointer iter, + ffi.Pointer> forbidden_string, +); + +typedef _dart_dpm_password_iterator_next = int Function( + ffi.Pointer iter, + ffi.Pointer> forbidden_string, +); + +typedef _c_dpm_password_destroy_iterator = ffi.Int32 Function( + ffi.Pointer iter, +); + +typedef _dart_dpm_password_destroy_iterator = int Function( + ffi.Pointer iter, +); + +typedef _c_dpm_password_set_forbidden_strings = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> strings, + ffi.Int32 length, +); + +typedef _dart_dpm_password_set_forbidden_strings = int Function( + ffi.Pointer handle, + ffi.Pointer> strings, + int length, +); + +typedef _c_dpm_restriction_set_camera_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_camera_state = int Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_camera_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_camera_state = int Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_microphone_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_microphone_state = int Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_microphone_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_microphone_state = int Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_location_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_location_state = int Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_location_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_location_state = int Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_external_storage_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_external_storage_state = int Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_external_storage_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_external_storage_state = int Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_clipboard_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_clipboard_state = int Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_clipboard_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_clipboard_state = int Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_usb_debugging_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_usb_debugging_state = int Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_usb_debugging_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_usb_debugging_state = int Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_wifi_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_wifi_state = int Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_wifi_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_wifi_state = int Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_wifi_hotspot_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_wifi_hotspot_state = int Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_wifi_hotspot_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_wifi_hotspot_state = int Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_bluetooth_tethering_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_bluetooth_tethering_state = int Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_bluetooth_tethering_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_bluetooth_tethering_state = int Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_usb_tethering_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_usb_tethering_state = int Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_usb_tethering_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_usb_tethering_state = int Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_bluetooth_mode_change_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_bluetooth_mode_change_state = int Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_bluetooth_mode_change_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_bluetooth_mode_change_state = int Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_bluetooth_desktop_connectivity_state = ffi.Int32 + Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_bluetooth_desktop_connectivity_state = int + Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_bluetooth_desktop_connectivity_state = ffi.Int32 + Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_bluetooth_desktop_connectivity_state = int + Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_bluetooth_pairing_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_bluetooth_pairing_state = int Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_bluetooth_pairing_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_bluetooth_pairing_state = int Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_messaging_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer sim_id, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_messaging_state = int Function( + ffi.Pointer handle, + ffi.Pointer sim_id, + int allow, +); + +typedef _c_dpm_restriction_get_messaging_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer sim_id, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_messaging_state = int Function( + ffi.Pointer handle, + ffi.Pointer sim_id, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_popimap_email_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_popimap_email_state = int Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_popimap_email_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_popimap_email_state = int Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_restriction_set_browser_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 allow, +); + +typedef _dart_dpm_restriction_set_browser_state = int Function( + ffi.Pointer handle, + int allow, +); + +typedef _c_dpm_restriction_get_browser_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _dart_dpm_restriction_get_browser_state = int Function( + ffi.Pointer handle, + ffi.Pointer is_allowed, +); + +typedef _c_dpm_security_lockout_screen = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_dpm_security_lockout_screen = int Function( + ffi.Pointer handle, +); + +typedef _c_dpm_security_set_internal_storage_encryption = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 encrypt, +); + +typedef _dart_dpm_security_set_internal_storage_encryption = int Function( + ffi.Pointer handle, + int encrypt, +); + +typedef _c_dpm_security_is_internal_storage_encrypted = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_encrypted, +); + +typedef _dart_dpm_security_is_internal_storage_encrypted = int Function( + ffi.Pointer handle, + ffi.Pointer is_encrypted, +); + +typedef _c_dpm_security_set_external_storage_encryption = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 encrypt, +); + +typedef _dart_dpm_security_set_external_storage_encryption = int Function( + ffi.Pointer handle, + int encrypt, +); + +typedef _c_dpm_security_is_external_storage_encrypted = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_encrypted, +); + +typedef _dart_dpm_security_is_external_storage_encrypted = int Function( + ffi.Pointer handle, + ffi.Pointer is_encrypted, +); + +typedef _c_dpm_security_wipe_data = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 type, +); + +typedef _dart_dpm_security_wipe_data = int Function( + ffi.Pointer handle, + int type, +); + +typedef _c_dpm_zone_create = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer name, + ffi.Pointer pkgname, +); + +typedef _dart_dpm_zone_create = int Function( + ffi.Pointer handle, + ffi.Pointer name, + ffi.Pointer pkgname, +); + +typedef _c_dpm_zone_destroy = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer name, +); + +typedef _dart_dpm_zone_destroy = int Function( + ffi.Pointer handle, + ffi.Pointer name, +); + +typedef _c_dpm_zone_get_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer name, + ffi.Pointer state, +); + +typedef _dart_dpm_zone_get_state = int Function( + ffi.Pointer handle, + ffi.Pointer name, + ffi.Pointer state, +); + +typedef dpm_zone_foreach_name_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_dpm_zone_foreach_name = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 state, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_dpm_zone_foreach_name = int Function( + ffi.Pointer handle, + int state, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_ckmc_alias_new = ffi.Int32 Function( + ffi.Pointer owner_id, + ffi.Pointer alias, + ffi.Pointer> full_alias, +); + +typedef _dart_ckmc_alias_new = int Function( + ffi.Pointer owner_id, + ffi.Pointer alias, + ffi.Pointer> full_alias, +); + +typedef _c_ckmc_key_new = ffi.Int32 Function( + ffi.Pointer raw_key, + ffi.Int32 key_size, + ffi.Int32 key_type, + ffi.Pointer password, + ffi.Pointer> ppkey, +); + +typedef _dart_ckmc_key_new = int Function( + ffi.Pointer raw_key, + int key_size, + int key_type, + ffi.Pointer password, + ffi.Pointer> ppkey, +); + +typedef _c_ckmc_key_free = ffi.Void Function( + ffi.Pointer key, +); + +typedef _dart_ckmc_key_free = void Function( + ffi.Pointer key, +); + +typedef _c_ckmc_buffer_new = ffi.Int32 Function( + ffi.Pointer data, + ffi.Int32 size, + ffi.Pointer> ppbuffer, +); + +typedef _dart_ckmc_buffer_new = int Function( + ffi.Pointer data, + int size, + ffi.Pointer> ppbuffer, +); + +typedef _c_ckmc_buffer_free = ffi.Void Function( + ffi.Pointer buffer, +); + +typedef _dart_ckmc_buffer_free = void Function( + ffi.Pointer buffer, +); + +typedef _c_ckmc_cert_new = ffi.Int32 Function( + ffi.Pointer raw_cert, + ffi.Int32 cert_size, + ffi.Int32 data_format, + ffi.Pointer> ppcert, +); + +typedef _dart_ckmc_cert_new = int Function( + ffi.Pointer raw_cert, + int cert_size, + int data_format, + ffi.Pointer> ppcert, +); + +typedef _c_ckmc_cert_free = ffi.Void Function( + ffi.Pointer cert, +); + +typedef _dart_ckmc_cert_free = void Function( + ffi.Pointer cert, +); + +typedef _c_ckmc_load_cert_from_file = ffi.Int32 Function( + ffi.Pointer file_path, + ffi.Pointer> cert, +); + +typedef _dart_ckmc_load_cert_from_file = int Function( + ffi.Pointer file_path, + ffi.Pointer> cert, +); + +typedef _c_ckmc_pkcs12_new = ffi.Int32 Function( + ffi.Pointer private_key, + ffi.Pointer cert, + ffi.Pointer ca_cert_list, + ffi.Pointer> pkcs12_bundle, +); + +typedef _dart_ckmc_pkcs12_new = int Function( + ffi.Pointer private_key, + ffi.Pointer cert, + ffi.Pointer ca_cert_list, + ffi.Pointer> pkcs12_bundle, +); + +typedef _c_ckmc_load_from_pkcs12_file = ffi.Int32 Function( + ffi.Pointer file_path, + ffi.Pointer passphrase, + ffi.Pointer> private_key, + ffi.Pointer> cert, + ffi.Pointer> ca_cert_list, +); + +typedef _dart_ckmc_load_from_pkcs12_file = int Function( + ffi.Pointer file_path, + ffi.Pointer passphrase, + ffi.Pointer> private_key, + ffi.Pointer> cert, + ffi.Pointer> ca_cert_list, +); + +typedef _c_ckmc_pkcs12_load = ffi.Int32 Function( + ffi.Pointer file_path, + ffi.Pointer passphrase, + ffi.Pointer> pkcs12_bundle, +); + +typedef _dart_ckmc_pkcs12_load = int Function( + ffi.Pointer file_path, + ffi.Pointer passphrase, + ffi.Pointer> pkcs12_bundle, +); + +typedef _c_ckmc_pkcs12_free = ffi.Void Function( + ffi.Pointer pkcs12, +); + +typedef _dart_ckmc_pkcs12_free = void Function( + ffi.Pointer pkcs12, +); + +typedef _c_ckmc_alias_list_new = ffi.Int32 Function( + ffi.Pointer alias, + ffi.Pointer> ppalias_list, +); + +typedef _dart_ckmc_alias_list_new = int Function( + ffi.Pointer alias, + ffi.Pointer> ppalias_list, +); + +typedef _c_ckmc_alias_list_add = ffi.Int32 Function( + ffi.Pointer previous, + ffi.Pointer alias, + ffi.Pointer> pplast, +); + +typedef _dart_ckmc_alias_list_add = int Function( + ffi.Pointer previous, + ffi.Pointer alias, + ffi.Pointer> pplast, +); + +typedef _c_ckmc_alias_list_free = ffi.Void Function( + ffi.Pointer first, +); + +typedef _dart_ckmc_alias_list_free = void Function( + ffi.Pointer first, +); + +typedef _c_ckmc_alias_list_all_free = ffi.Void Function( + ffi.Pointer first, +); + +typedef _dart_ckmc_alias_list_all_free = void Function( + ffi.Pointer first, +); + +typedef _c_ckmc_cert_list_new = ffi.Int32 Function( + ffi.Pointer cert, + ffi.Pointer> ppalias_list, +); + +typedef _dart_ckmc_cert_list_new = int Function( + ffi.Pointer cert, + ffi.Pointer> ppalias_list, +); + +typedef _c_ckmc_cert_list_add = ffi.Int32 Function( + ffi.Pointer previous, + ffi.Pointer cert, + ffi.Pointer> pplast, +); + +typedef _dart_ckmc_cert_list_add = int Function( + ffi.Pointer previous, + ffi.Pointer cert, + ffi.Pointer> pplast, +); + +typedef _c_ckmc_cert_list_free = ffi.Void Function( + ffi.Pointer first, +); + +typedef _dart_ckmc_cert_list_free = void Function( + ffi.Pointer first, +); + +typedef _c_ckmc_cert_list_all_free = ffi.Void Function( + ffi.Pointer first, +); + +typedef _dart_ckmc_cert_list_all_free = void Function( + ffi.Pointer first, +); + +typedef _c_ckmc_param_list_new = ffi.Int32 Function( + ffi.Pointer> pparams, +); + +typedef _dart_ckmc_param_list_new = int Function( + ffi.Pointer> pparams, +); + +typedef _c_ckmc_param_list_set_integer = ffi.Int32 Function( + ffi.Pointer<__ckmc_param_list> params, + ffi.Int32 name, + ffi.Uint64 value, +); + +typedef _dart_ckmc_param_list_set_integer = int Function( + ffi.Pointer<__ckmc_param_list> params, + int name, + int value, +); + +typedef _c_ckmc_param_list_set_buffer = ffi.Int32 Function( + ffi.Pointer<__ckmc_param_list> params, + ffi.Int32 name, + ffi.Pointer buffer, +); + +typedef _dart_ckmc_param_list_set_buffer = int Function( + ffi.Pointer<__ckmc_param_list> params, + int name, + ffi.Pointer buffer, +); + +typedef _c_ckmc_param_list_get_integer = ffi.Int32 Function( + ffi.Pointer<__ckmc_param_list> params, + ffi.Int32 name, + ffi.Pointer pvalue, +); + +typedef _dart_ckmc_param_list_get_integer = int Function( + ffi.Pointer<__ckmc_param_list> params, + int name, + ffi.Pointer pvalue, +); + +typedef _c_ckmc_param_list_get_buffer = ffi.Int32 Function( + ffi.Pointer<__ckmc_param_list> params, + ffi.Int32 name, + ffi.Pointer> ppbuffer, +); + +typedef _dart_ckmc_param_list_get_buffer = int Function( + ffi.Pointer<__ckmc_param_list> params, + int name, + ffi.Pointer> ppbuffer, +); + +typedef _c_ckmc_param_list_free = ffi.Void Function( + ffi.Pointer<__ckmc_param_list> params, +); + +typedef _dart_ckmc_param_list_free = void Function( + ffi.Pointer<__ckmc_param_list> params, +); + +typedef _c_ckmc_generate_new_params = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer> pparams, +); + +typedef _dart_ckmc_generate_new_params = int Function( + int type, + ffi.Pointer> pparams, +); + +typedef _c_ckmc_save_key = ffi.Int32 Function( + ffi.Pointer alias, + ckmc_key_s key, + ckmc_policy_s policy, +); + +typedef _dart_ckmc_save_key = int Function( + ffi.Pointer alias, + ckmc_key_s key, + ckmc_policy_s policy, +); + +typedef _c_ckmc_remove_key = ffi.Int32 Function( + ffi.Pointer alias, +); + +typedef _dart_ckmc_remove_key = int Function( + ffi.Pointer alias, +); + +typedef _c_ckmc_get_key = ffi.Int32 Function( + ffi.Pointer alias, + ffi.Pointer password, + ffi.Pointer> ppkey, +); + +typedef _dart_ckmc_get_key = int Function( + ffi.Pointer alias, + ffi.Pointer password, + ffi.Pointer> ppkey, +); + +typedef _c_ckmc_get_key_alias_list = ffi.Int32 Function( + ffi.Pointer> ppalias_list, +); + +typedef _dart_ckmc_get_key_alias_list = int Function( + ffi.Pointer> ppalias_list, +); + +typedef _c_ckmc_save_cert = ffi.Int32 Function( + ffi.Pointer alias, + ckmc_cert_s cert, + ckmc_policy_s policy, +); + +typedef _dart_ckmc_save_cert = int Function( + ffi.Pointer alias, + ckmc_cert_s cert, + ckmc_policy_s policy, +); + +typedef _c_ckmc_remove_cert = ffi.Int32 Function( + ffi.Pointer alias, +); + +typedef _dart_ckmc_remove_cert = int Function( + ffi.Pointer alias, +); + +typedef _c_ckmc_get_cert = ffi.Int32 Function( + ffi.Pointer alias, + ffi.Pointer password, + ffi.Pointer> ppcert, +); + +typedef _dart_ckmc_get_cert = int Function( + ffi.Pointer alias, + ffi.Pointer password, + ffi.Pointer> ppcert, +); + +typedef _c_ckmc_get_cert_alias_list = ffi.Int32 Function( + ffi.Pointer> ppalias_list, +); + +typedef _dart_ckmc_get_cert_alias_list = int Function( + ffi.Pointer> ppalias_list, +); + +typedef _c_ckmc_save_pkcs12 = ffi.Int32 Function( + ffi.Pointer alias, + ffi.Pointer pkcs, + ckmc_policy_s key_policy, + ckmc_policy_s cert_policy, +); + +typedef _dart_ckmc_save_pkcs12 = int Function( + ffi.Pointer alias, + ffi.Pointer pkcs, + ckmc_policy_s key_policy, + ckmc_policy_s cert_policy, +); + +typedef _c_ckmc_get_pkcs12 = ffi.Int32 Function( + ffi.Pointer alias, + ffi.Pointer key_password, + ffi.Pointer cert_password, + ffi.Pointer> pkcs12, +); + +typedef _dart_ckmc_get_pkcs12 = int Function( + ffi.Pointer alias, + ffi.Pointer key_password, + ffi.Pointer cert_password, + ffi.Pointer> pkcs12, +); + +typedef _c_ckmc_save_data = ffi.Int32 Function( + ffi.Pointer alias, + ckmc_raw_buffer_s data, + ckmc_policy_s policy, +); + +typedef _dart_ckmc_save_data = int Function( + ffi.Pointer alias, + ckmc_raw_buffer_s data, + ckmc_policy_s policy, +); + +typedef _c_ckmc_remove_data = ffi.Int32 Function( + ffi.Pointer alias, +); + +typedef _dart_ckmc_remove_data = int Function( + ffi.Pointer alias, +); + +typedef _c_ckmc_get_data = ffi.Int32 Function( + ffi.Pointer alias, + ffi.Pointer password, + ffi.Pointer> ppdata, +); + +typedef _dart_ckmc_get_data = int Function( + ffi.Pointer alias, + ffi.Pointer password, + ffi.Pointer> ppdata, +); + +typedef _c_ckmc_get_data_alias_list = ffi.Int32 Function( + ffi.Pointer> ppalias_list, +); + +typedef _dart_ckmc_get_data_alias_list = int Function( + ffi.Pointer> ppalias_list, +); + +typedef _c_ckmc_create_key_pair_rsa = ffi.Int32 Function( + ffi.Int32 size, + ffi.Pointer private_key_alias, + ffi.Pointer public_key_alias, + ckmc_policy_s policy_private_key, + ckmc_policy_s policy_public_key, +); + +typedef _dart_ckmc_create_key_pair_rsa = int Function( + int size, + ffi.Pointer private_key_alias, + ffi.Pointer public_key_alias, + ckmc_policy_s policy_private_key, + ckmc_policy_s policy_public_key, +); + +typedef _c_ckmc_create_key_pair_dsa = ffi.Int32 Function( + ffi.Int32 size, + ffi.Pointer private_key_alias, + ffi.Pointer public_key_alias, + ckmc_policy_s policy_private_key, + ckmc_policy_s policy_public_key, +); + +typedef _dart_ckmc_create_key_pair_dsa = int Function( + int size, + ffi.Pointer private_key_alias, + ffi.Pointer public_key_alias, + ckmc_policy_s policy_private_key, + ckmc_policy_s policy_public_key, +); + +typedef _c_ckmc_create_key_pair_ecdsa = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer private_key_alias, + ffi.Pointer public_key_alias, + ckmc_policy_s policy_private_key, + ckmc_policy_s policy_public_key, +); + +typedef _dart_ckmc_create_key_pair_ecdsa = int Function( + int type, + ffi.Pointer private_key_alias, + ffi.Pointer public_key_alias, + ckmc_policy_s policy_private_key, + ckmc_policy_s policy_public_key, +); + +typedef _c_ckmc_create_key_aes = ffi.Int32 Function( + ffi.Int32 size, + ffi.Pointer key_alias, + ckmc_policy_s key_policy, +); + +typedef _dart_ckmc_create_key_aes = int Function( + int size, + ffi.Pointer key_alias, + ckmc_policy_s key_policy, +); + +typedef _c_ckmc_create_signature = ffi.Int32 Function( + ffi.Pointer private_key_alias, + ffi.Pointer password, + ckmc_raw_buffer_s message, + ffi.Int32 hash, + ffi.Int32 padding, + ffi.Pointer> ppsignature, +); + +typedef _dart_ckmc_create_signature = int Function( + ffi.Pointer private_key_alias, + ffi.Pointer password, + ckmc_raw_buffer_s message, + int hash, + int padding, + ffi.Pointer> ppsignature, +); + +typedef _c_ckmc_verify_signature = ffi.Int32 Function( + ffi.Pointer public_key_alias, + ffi.Pointer password, + ckmc_raw_buffer_s message, + ckmc_raw_buffer_s signature, + ffi.Int32 hash, + ffi.Int32 padding, +); + +typedef _dart_ckmc_verify_signature = int Function( + ffi.Pointer public_key_alias, + ffi.Pointer password, + ckmc_raw_buffer_s message, + ckmc_raw_buffer_s signature, + int hash, + int padding, +); + +typedef _c_ckmc_get_cert_chain = ffi.Int32 Function( + ffi.Pointer cert, + ffi.Pointer untrustedcerts, + ffi.Pointer> ppcert_chain_list, +); + +typedef _dart_ckmc_get_cert_chain = int Function( + ffi.Pointer cert, + ffi.Pointer untrustedcerts, + ffi.Pointer> ppcert_chain_list, +); + +typedef _c_ckmc_get_cert_chain_with_alias = ffi.Int32 Function( + ffi.Pointer cert, + ffi.Pointer untrustedcerts, + ffi.Pointer> ppcert_chain_list, +); + +typedef _dart_ckmc_get_cert_chain_with_alias = int Function( + ffi.Pointer cert, + ffi.Pointer untrustedcerts, + ffi.Pointer> ppcert_chain_list, +); + +typedef _c_ckmc_get_cert_chain_with_trustedcert = ffi.Int32 Function( + ffi.Pointer cert, + ffi.Pointer untrustedcerts, + ffi.Pointer trustedcerts, + ffi.Uint8 use_trustedsystemcerts, + ffi.Pointer> ppcert_chain_list, +); + +typedef _dart_ckmc_get_cert_chain_with_trustedcert = int Function( + ffi.Pointer cert, + ffi.Pointer untrustedcerts, + ffi.Pointer trustedcerts, + int use_trustedsystemcerts, + ffi.Pointer> ppcert_chain_list, +); + +typedef _c_ckmc_ocsp_check = ffi.Int32 Function( + ffi.Pointer pcert_chain_list, + ffi.Pointer ocsp_status, +); + +typedef _dart_ckmc_ocsp_check = int Function( + ffi.Pointer pcert_chain_list, + ffi.Pointer ocsp_status, +); + +typedef _c_ckmc_allow_access = ffi.Int32 Function( + ffi.Pointer alias, + ffi.Pointer accessor, + ffi.Int32 granted, +); + +typedef _dart_ckmc_allow_access = int Function( + ffi.Pointer alias, + ffi.Pointer accessor, + int granted, +); + +typedef _c_ckmc_set_permission = ffi.Int32 Function( + ffi.Pointer alias, + ffi.Pointer accessor, + ffi.Int32 permissions, +); + +typedef _dart_ckmc_set_permission = int Function( + ffi.Pointer alias, + ffi.Pointer accessor, + int permissions, +); + +typedef _c_ckmc_deny_access = ffi.Int32 Function( + ffi.Pointer alias, + ffi.Pointer accessor, +); + +typedef _dart_ckmc_deny_access = int Function( + ffi.Pointer alias, + ffi.Pointer accessor, +); + +typedef _c_ckmc_remove_alias = ffi.Int32 Function( + ffi.Pointer alias, +); + +typedef _dart_ckmc_remove_alias = int Function( + ffi.Pointer alias, +); + +typedef _c_ckmc_encrypt_data = ffi.Int32 Function( + ffi.Pointer<__ckmc_param_list> params, + ffi.Pointer key_alias, + ffi.Pointer password, + ckmc_raw_buffer_s decrypted, + ffi.Pointer> ppencrypted, +); + +typedef _dart_ckmc_encrypt_data = int Function( + ffi.Pointer<__ckmc_param_list> params, + ffi.Pointer key_alias, + ffi.Pointer password, + ckmc_raw_buffer_s decrypted, + ffi.Pointer> ppencrypted, +); + +typedef _c_ckmc_decrypt_data = ffi.Int32 Function( + ffi.Pointer<__ckmc_param_list> params, + ffi.Pointer key_alias, + ffi.Pointer password, + ckmc_raw_buffer_s encrypted, + ffi.Pointer> ppdecrypted, +); + +typedef _dart_ckmc_decrypt_data = int Function( + ffi.Pointer<__ckmc_param_list> params, + ffi.Pointer key_alias, + ffi.Pointer password, + ckmc_raw_buffer_s encrypted, + ffi.Pointer> ppdecrypted, +); + +typedef _c_ppm_check_permission = ffi.Int32 Function( + ffi.Pointer privilege, + ffi.Pointer result, +); + +typedef _dart_ppm_check_permission = int Function( + ffi.Pointer privilege, + ffi.Pointer result, +); + +typedef ppm_request_response_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_ppm_request_permission = ffi.Int32 Function( + ffi.Pointer privilege, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_ppm_request_permission = int Function( + ffi.Pointer privilege, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_privilege_info_get_display_name = ffi.Int32 Function( + ffi.Pointer api_version, + ffi.Pointer privilege, + ffi.Pointer> display_name, +); + +typedef _dart_privilege_info_get_display_name = int Function( + ffi.Pointer api_version, + ffi.Pointer privilege, + ffi.Pointer> display_name, +); + +typedef _c_privilege_info_get_display_name_by_pkgtype = ffi.Int32 Function( + ffi.Pointer package_type, + ffi.Pointer api_version, + ffi.Pointer privilege, + ffi.Pointer> display_name, +); + +typedef _dart_privilege_info_get_display_name_by_pkgtype = int Function( + ffi.Pointer package_type, + ffi.Pointer api_version, + ffi.Pointer privilege, + ffi.Pointer> display_name, +); + +typedef _c_privilege_info_get_description = ffi.Int32 Function( + ffi.Pointer api_version, + ffi.Pointer privilege, + ffi.Pointer> description, +); + +typedef _dart_privilege_info_get_description = int Function( + ffi.Pointer api_version, + ffi.Pointer privilege, + ffi.Pointer> description, +); + +typedef _c_privilege_info_get_description_by_pkgtype = ffi.Int32 Function( + ffi.Pointer package_type, + ffi.Pointer api_version, + ffi.Pointer privilege, + ffi.Pointer> description, +); + +typedef _dart_privilege_info_get_description_by_pkgtype = int Function( + ffi.Pointer package_type, + ffi.Pointer api_version, + ffi.Pointer privilege, + ffi.Pointer> description, +); + +typedef _c_privilege_info_get_privacy_display_name = ffi.Int32 Function( + ffi.Pointer privilege, + ffi.Pointer> privacy_name, +); + +typedef _dart_privilege_info_get_privacy_display_name = int Function( + ffi.Pointer privilege, + ffi.Pointer> privacy_name, +); + +typedef _c_privilege_info_get_privacy_privilege_status = ffi.Int32 Function( + ffi.Pointer privilege, + ffi.Pointer status, +); + +typedef _dart_privilege_info_get_privacy_privilege_status = int Function( + ffi.Pointer privilege, + ffi.Pointer status, +); + +typedef _c_yaca_initialize = ffi.Int32 Function(); + +typedef _dart_yaca_initialize = int Function(); + +typedef _c_yaca_cleanup = ffi.Void Function(); + +typedef _dart_yaca_cleanup = void Function(); + +typedef _c_yaca_malloc = ffi.Int32 Function( + ffi.Int32 size, + ffi.Pointer> memory, +); + +typedef _dart_yaca_malloc = int Function( + int size, + ffi.Pointer> memory, +); + +typedef _c_yaca_zalloc = ffi.Int32 Function( + ffi.Int32 size, + ffi.Pointer> memory, +); + +typedef _dart_yaca_zalloc = int Function( + int size, + ffi.Pointer> memory, +); + +typedef _c_yaca_realloc = ffi.Int32 Function( + ffi.Int32 size, + ffi.Pointer> memory, +); + +typedef _dart_yaca_realloc = int Function( + int size, + ffi.Pointer> memory, +); + +typedef _c_yaca_free = ffi.Void Function( + ffi.Pointer memory, +); + +typedef _dart_yaca_free = void Function( + ffi.Pointer memory, +); + +typedef _c_yaca_memcmp = ffi.Int32 Function( + ffi.Pointer first, + ffi.Pointer second, + ffi.Int32 len, +); + +typedef _dart_yaca_memcmp = int Function( + ffi.Pointer first, + ffi.Pointer second, + int len, +); + +typedef _c_yaca_randomize_bytes = ffi.Int32 Function( + ffi.Pointer data, + ffi.Int32 data_len, +); + +typedef _dart_yaca_randomize_bytes = int Function( + ffi.Pointer data, + int data_len, +); + +typedef _c_yaca_context_set_property = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Int32 property, + ffi.Pointer value, + ffi.Int32 value_len, +); + +typedef _dart_yaca_context_set_property = int Function( + ffi.Pointer ctx, + int property, + ffi.Pointer value, + int value_len, +); + +typedef _c_yaca_context_get_property = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Int32 property, + ffi.Pointer> value, + ffi.Pointer value_len, +); + +typedef _dart_yaca_context_get_property = int Function( + ffi.Pointer ctx, + int property, + ffi.Pointer> value, + ffi.Pointer value_len, +); + +typedef _c_yaca_context_get_output_length = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Int32 input_len, + ffi.Pointer output_len, +); + +typedef _dart_yaca_context_get_output_length = int Function( + ffi.Pointer ctx, + int input_len, + ffi.Pointer output_len, +); + +typedef _c_yaca_context_destroy = ffi.Void Function( + ffi.Pointer ctx, +); + +typedef _dart_yaca_context_destroy = void Function( + ffi.Pointer ctx, +); + +typedef _c_yaca_encrypt_get_iv_bit_length = ffi.Int32 Function( + ffi.Int32 algo, + ffi.Int32 bcm, + ffi.Int32 key_bit_len, + ffi.Pointer iv_bit_len, +); + +typedef _dart_yaca_encrypt_get_iv_bit_length = int Function( + int algo, + int bcm, + int key_bit_len, + ffi.Pointer iv_bit_len, +); + +typedef _c_yaca_encrypt_initialize = ffi.Int32 Function( + ffi.Pointer> ctx, + ffi.Int32 algo, + ffi.Int32 bcm, + ffi.Pointer sym_key, + ffi.Pointer iv, +); + +typedef _dart_yaca_encrypt_initialize = int Function( + ffi.Pointer> ctx, + int algo, + int bcm, + ffi.Pointer sym_key, + ffi.Pointer iv, +); + +typedef _c_yaca_encrypt_update = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Pointer plaintext, + ffi.Int32 plaintext_len, + ffi.Pointer ciphertext, + ffi.Pointer ciphertext_len, +); + +typedef _dart_yaca_encrypt_update = int Function( + ffi.Pointer ctx, + ffi.Pointer plaintext, + int plaintext_len, + ffi.Pointer ciphertext, + ffi.Pointer ciphertext_len, +); + +typedef _c_yaca_encrypt_finalize = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Pointer ciphertext, + ffi.Pointer ciphertext_len, +); + +typedef _dart_yaca_encrypt_finalize = int Function( + ffi.Pointer ctx, + ffi.Pointer ciphertext, + ffi.Pointer ciphertext_len, +); + +typedef _c_yaca_decrypt_initialize = ffi.Int32 Function( + ffi.Pointer> ctx, + ffi.Int32 algo, + ffi.Int32 bcm, + ffi.Pointer sym_key, + ffi.Pointer iv, +); + +typedef _dart_yaca_decrypt_initialize = int Function( + ffi.Pointer> ctx, + int algo, + int bcm, + ffi.Pointer sym_key, + ffi.Pointer iv, +); + +typedef _c_yaca_decrypt_update = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Pointer ciphertext, + ffi.Int32 ciphertext_len, + ffi.Pointer plaintext, + ffi.Pointer plaintext_len, +); + +typedef _dart_yaca_decrypt_update = int Function( + ffi.Pointer ctx, + ffi.Pointer ciphertext, + int ciphertext_len, + ffi.Pointer plaintext, + ffi.Pointer plaintext_len, +); + +typedef _c_yaca_decrypt_finalize = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Pointer plaintext, + ffi.Pointer plaintext_len, +); + +typedef _dart_yaca_decrypt_finalize = int Function( + ffi.Pointer ctx, + ffi.Pointer plaintext, + ffi.Pointer plaintext_len, +); + +typedef _c_yaca_seal_initialize = ffi.Int32 Function( + ffi.Pointer> ctx, + ffi.Pointer pub_key, + ffi.Int32 algo, + ffi.Int32 bcm, + ffi.Int32 sym_key_bit_len, + ffi.Pointer> sym_key, + ffi.Pointer> iv, +); + +typedef _dart_yaca_seal_initialize = int Function( + ffi.Pointer> ctx, + ffi.Pointer pub_key, + int algo, + int bcm, + int sym_key_bit_len, + ffi.Pointer> sym_key, + ffi.Pointer> iv, +); + +typedef _c_yaca_seal_update = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Pointer plaintext, + ffi.Int32 plaintext_len, + ffi.Pointer ciphertext, + ffi.Pointer ciphertext_len, +); + +typedef _dart_yaca_seal_update = int Function( + ffi.Pointer ctx, + ffi.Pointer plaintext, + int plaintext_len, + ffi.Pointer ciphertext, + ffi.Pointer ciphertext_len, +); + +typedef _c_yaca_seal_finalize = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Pointer ciphertext, + ffi.Pointer ciphertext_len, +); + +typedef _dart_yaca_seal_finalize = int Function( + ffi.Pointer ctx, + ffi.Pointer ciphertext, + ffi.Pointer ciphertext_len, +); + +typedef _c_yaca_open_initialize = ffi.Int32 Function( + ffi.Pointer> ctx, + ffi.Pointer prv_key, + ffi.Int32 algo, + ffi.Int32 bcm, + ffi.Int32 sym_key_bit_len, + ffi.Pointer sym_key, + ffi.Pointer iv, +); + +typedef _dart_yaca_open_initialize = int Function( + ffi.Pointer> ctx, + ffi.Pointer prv_key, + int algo, + int bcm, + int sym_key_bit_len, + ffi.Pointer sym_key, + ffi.Pointer iv, +); + +typedef _c_yaca_open_update = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Pointer ciphertext, + ffi.Int32 ciphertext_len, + ffi.Pointer plaintext, + ffi.Pointer plaintext_len, +); + +typedef _dart_yaca_open_update = int Function( + ffi.Pointer ctx, + ffi.Pointer ciphertext, + int ciphertext_len, + ffi.Pointer plaintext, + ffi.Pointer plaintext_len, +); + +typedef _c_yaca_open_finalize = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Pointer plaintext, + ffi.Pointer plaintext_len, +); + +typedef _dart_yaca_open_finalize = int Function( + ffi.Pointer ctx, + ffi.Pointer plaintext, + ffi.Pointer plaintext_len, +); + +typedef _c_yaca_sign_initialize = ffi.Int32 Function( + ffi.Pointer> ctx, + ffi.Int32 algo, + ffi.Pointer prv_key, +); + +typedef _dart_yaca_sign_initialize = int Function( + ffi.Pointer> ctx, + int algo, + ffi.Pointer prv_key, +); + +typedef _c_yaca_sign_initialize_hmac = ffi.Int32 Function( + ffi.Pointer> ctx, + ffi.Int32 algo, + ffi.Pointer sym_key, +); + +typedef _dart_yaca_sign_initialize_hmac = int Function( + ffi.Pointer> ctx, + int algo, + ffi.Pointer sym_key, +); + +typedef _c_yaca_sign_initialize_cmac = ffi.Int32 Function( + ffi.Pointer> ctx, + ffi.Int32 algo, + ffi.Pointer sym_key, +); + +typedef _dart_yaca_sign_initialize_cmac = int Function( + ffi.Pointer> ctx, + int algo, + ffi.Pointer sym_key, +); + +typedef _c_yaca_sign_update = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Pointer message, + ffi.Int32 message_len, +); + +typedef _dart_yaca_sign_update = int Function( + ffi.Pointer ctx, + ffi.Pointer message, + int message_len, +); + +typedef _c_yaca_sign_finalize = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Pointer signature, + ffi.Pointer signature_len, +); + +typedef _dart_yaca_sign_finalize = int Function( + ffi.Pointer ctx, + ffi.Pointer signature, + ffi.Pointer signature_len, +); + +typedef _c_yaca_verify_initialize = ffi.Int32 Function( + ffi.Pointer> ctx, + ffi.Int32 algo, + ffi.Pointer pub_key, +); + +typedef _dart_yaca_verify_initialize = int Function( + ffi.Pointer> ctx, + int algo, + ffi.Pointer pub_key, +); + +typedef _c_yaca_verify_update = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Pointer message, + ffi.Int32 message_len, +); + +typedef _dart_yaca_verify_update = int Function( + ffi.Pointer ctx, + ffi.Pointer message, + int message_len, +); + +typedef _c_yaca_verify_finalize = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Pointer signature, + ffi.Int32 signature_len, +); + +typedef _dart_yaca_verify_finalize = int Function( + ffi.Pointer ctx, + ffi.Pointer signature, + int signature_len, +); + +typedef _c_yaca_digest_initialize = ffi.Int32 Function( + ffi.Pointer> ctx, + ffi.Int32 algo, +); + +typedef _dart_yaca_digest_initialize = int Function( + ffi.Pointer> ctx, + int algo, +); + +typedef _c_yaca_digest_update = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Pointer message, + ffi.Int32 message_len, +); + +typedef _dart_yaca_digest_update = int Function( + ffi.Pointer ctx, + ffi.Pointer message, + int message_len, +); + +typedef _c_yaca_digest_finalize = ffi.Int32 Function( + ffi.Pointer ctx, + ffi.Pointer digest, + ffi.Pointer digest_len, +); + +typedef _dart_yaca_digest_finalize = int Function( + ffi.Pointer ctx, + ffi.Pointer digest, + ffi.Pointer digest_len, +); + +typedef _c_yaca_key_get_type = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer key_type, +); + +typedef _dart_yaca_key_get_type = int Function( + ffi.Pointer key, + ffi.Pointer key_type, +); + +typedef _c_yaca_key_get_bit_length = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer key_bit_len, +); + +typedef _dart_yaca_key_get_bit_length = int Function( + ffi.Pointer key, + ffi.Pointer key_bit_len, +); + +typedef _c_yaca_key_import = ffi.Int32 Function( + ffi.Int32 key_type, + ffi.Pointer password, + ffi.Pointer data, + ffi.Int32 data_len, + ffi.Pointer> key, +); + +typedef _dart_yaca_key_import = int Function( + int key_type, + ffi.Pointer password, + ffi.Pointer data, + int data_len, + ffi.Pointer> key, +); + +typedef _c_yaca_key_export = ffi.Int32 Function( + ffi.Pointer key, + ffi.Int32 key_fmt, + ffi.Int32 key_file_fmt, + ffi.Pointer password, + ffi.Pointer> data, + ffi.Pointer data_len, +); + +typedef _dart_yaca_key_export = int Function( + ffi.Pointer key, + int key_fmt, + int key_file_fmt, + ffi.Pointer password, + ffi.Pointer> data, + ffi.Pointer data_len, +); + +typedef _c_yaca_key_generate = ffi.Int32 Function( + ffi.Int32 key_type, + ffi.Int32 key_bit_len, + ffi.Pointer> key, +); + +typedef _dart_yaca_key_generate = int Function( + int key_type, + int key_bit_len, + ffi.Pointer> key, +); + +typedef _c_yaca_key_generate_from_parameters = ffi.Int32 Function( + ffi.Pointer params, + ffi.Pointer> prv_key, +); + +typedef _dart_yaca_key_generate_from_parameters = int Function( + ffi.Pointer params, + ffi.Pointer> prv_key, +); + +typedef _c_yaca_key_extract_public = ffi.Int32 Function( + ffi.Pointer prv_key, + ffi.Pointer> pub_key, +); + +typedef _dart_yaca_key_extract_public = int Function( + ffi.Pointer prv_key, + ffi.Pointer> pub_key, +); + +typedef _c_yaca_key_extract_parameters = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer> params, +); + +typedef _dart_yaca_key_extract_parameters = int Function( + ffi.Pointer key, + ffi.Pointer> params, +); + +typedef _c_yaca_key_derive_dh = ffi.Int32 Function( + ffi.Pointer prv_key, + ffi.Pointer pub_key, + ffi.Pointer> secret, + ffi.Pointer secret_len, +); + +typedef _dart_yaca_key_derive_dh = int Function( + ffi.Pointer prv_key, + ffi.Pointer pub_key, + ffi.Pointer> secret, + ffi.Pointer secret_len, +); + +typedef _c_yaca_key_derive_kdf = ffi.Int32 Function( + ffi.Int32 kdf, + ffi.Int32 algo, + ffi.Pointer secret, + ffi.Int32 secret_len, + ffi.Pointer info, + ffi.Int32 info_len, + ffi.Int32 key_material_len, + ffi.Pointer> key_material, +); + +typedef _dart_yaca_key_derive_kdf = int Function( + int kdf, + int algo, + ffi.Pointer secret, + int secret_len, + ffi.Pointer info, + int info_len, + int key_material_len, + ffi.Pointer> key_material, +); + +typedef _c_yaca_key_derive_pbkdf2 = ffi.Int32 Function( + ffi.Pointer password, + ffi.Pointer salt, + ffi.Int32 salt_len, + ffi.Int32 iterations, + ffi.Int32 algo, + ffi.Int32 key_bit_len, + ffi.Pointer> key, +); + +typedef _dart_yaca_key_derive_pbkdf2 = int Function( + ffi.Pointer password, + ffi.Pointer salt, + int salt_len, + int iterations, + int algo, + int key_bit_len, + ffi.Pointer> key, +); + +typedef _c_yaca_key_destroy = ffi.Void Function( + ffi.Pointer key, +); + +typedef _dart_yaca_key_destroy = void Function( + ffi.Pointer key, +); + +typedef _c_yaca_rsa_public_encrypt = ffi.Int32 Function( + ffi.Int32 padding, + ffi.Pointer pub_key, + ffi.Pointer plaintext, + ffi.Int32 plaintext_len, + ffi.Pointer> ciphertext, + ffi.Pointer ciphertext_len, +); + +typedef _dart_yaca_rsa_public_encrypt = int Function( + int padding, + ffi.Pointer pub_key, + ffi.Pointer plaintext, + int plaintext_len, + ffi.Pointer> ciphertext, + ffi.Pointer ciphertext_len, +); + +typedef _c_yaca_rsa_private_decrypt = ffi.Int32 Function( + ffi.Int32 padding, + ffi.Pointer prv_key, + ffi.Pointer ciphertext, + ffi.Int32 ciphertext_len, + ffi.Pointer> plaintext, + ffi.Pointer plaintext_len, +); + +typedef _dart_yaca_rsa_private_decrypt = int Function( + int padding, + ffi.Pointer prv_key, + ffi.Pointer ciphertext, + int ciphertext_len, + ffi.Pointer> plaintext, + ffi.Pointer plaintext_len, +); + +typedef _c_yaca_rsa_private_encrypt = ffi.Int32 Function( + ffi.Int32 padding, + ffi.Pointer prv_key, + ffi.Pointer plaintext, + ffi.Int32 plaintext_len, + ffi.Pointer> ciphertext, + ffi.Pointer ciphertext_len, +); + +typedef _dart_yaca_rsa_private_encrypt = int Function( + int padding, + ffi.Pointer prv_key, + ffi.Pointer plaintext, + int plaintext_len, + ffi.Pointer> ciphertext, + ffi.Pointer ciphertext_len, +); + +typedef _c_yaca_rsa_public_decrypt = ffi.Int32 Function( + ffi.Int32 padding, + ffi.Pointer pub_key, + ffi.Pointer ciphertext, + ffi.Int32 ciphertext_len, + ffi.Pointer> plaintext, + ffi.Pointer plaintext_len, +); + +typedef _dart_yaca_rsa_public_decrypt = int Function( + int padding, + ffi.Pointer pub_key, + ffi.Pointer ciphertext, + int ciphertext_len, + ffi.Pointer> plaintext, + ffi.Pointer plaintext_len, +); + +typedef _c_yaca_simple_encrypt = ffi.Int32 Function( + ffi.Int32 algo, + ffi.Int32 bcm, + ffi.Pointer sym_key, + ffi.Pointer iv, + ffi.Pointer plaintext, + ffi.Int32 plaintext_len, + ffi.Pointer> ciphertext, + ffi.Pointer ciphertext_len, +); + +typedef _dart_yaca_simple_encrypt = int Function( + int algo, + int bcm, + ffi.Pointer sym_key, + ffi.Pointer iv, + ffi.Pointer plaintext, + int plaintext_len, + ffi.Pointer> ciphertext, + ffi.Pointer ciphertext_len, +); + +typedef _c_yaca_simple_decrypt = ffi.Int32 Function( + ffi.Int32 algo, + ffi.Int32 bcm, + ffi.Pointer sym_key, + ffi.Pointer iv, + ffi.Pointer ciphertext, + ffi.Int32 ciphertext_len, + ffi.Pointer> plaintext, + ffi.Pointer plaintext_len, +); + +typedef _dart_yaca_simple_decrypt = int Function( + int algo, + int bcm, + ffi.Pointer sym_key, + ffi.Pointer iv, + ffi.Pointer ciphertext, + int ciphertext_len, + ffi.Pointer> plaintext, + ffi.Pointer plaintext_len, +); + +typedef _c_yaca_simple_calculate_digest = ffi.Int32 Function( + ffi.Int32 algo, + ffi.Pointer message, + ffi.Int32 message_len, + ffi.Pointer> digest, + ffi.Pointer digest_len, +); + +typedef _dart_yaca_simple_calculate_digest = int Function( + int algo, + ffi.Pointer message, + int message_len, + ffi.Pointer> digest, + ffi.Pointer digest_len, +); + +typedef _c_yaca_simple_calculate_signature = ffi.Int32 Function( + ffi.Int32 algo, + ffi.Pointer prv_key, + ffi.Pointer message, + ffi.Int32 message_len, + ffi.Pointer> signature, + ffi.Pointer signature_len, +); + +typedef _dart_yaca_simple_calculate_signature = int Function( + int algo, + ffi.Pointer prv_key, + ffi.Pointer message, + int message_len, + ffi.Pointer> signature, + ffi.Pointer signature_len, +); + +typedef _c_yaca_simple_verify_signature = ffi.Int32 Function( + ffi.Int32 algo, + ffi.Pointer pub_key, + ffi.Pointer message, + ffi.Int32 message_len, + ffi.Pointer signature, + ffi.Int32 signature_len, +); + +typedef _dart_yaca_simple_verify_signature = int Function( + int algo, + ffi.Pointer pub_key, + ffi.Pointer message, + int message_len, + ffi.Pointer signature, + int signature_len, +); + +typedef _c_yaca_simple_calculate_hmac = ffi.Int32 Function( + ffi.Int32 algo, + ffi.Pointer sym_key, + ffi.Pointer message, + ffi.Int32 message_len, + ffi.Pointer> mac, + ffi.Pointer mac_len, +); + +typedef _dart_yaca_simple_calculate_hmac = int Function( + int algo, + ffi.Pointer sym_key, + ffi.Pointer message, + int message_len, + ffi.Pointer> mac, + ffi.Pointer mac_len, +); + +typedef _c_yaca_simple_calculate_cmac = ffi.Int32 Function( + ffi.Int32 algo, + ffi.Pointer sym_key, + ffi.Pointer message, + ffi.Int32 message_len, + ffi.Pointer> mac, + ffi.Pointer mac_len, +); + +typedef _dart_yaca_simple_calculate_cmac = int Function( + int algo, + ffi.Pointer sym_key, + ffi.Pointer message, + int message_len, + ffi.Pointer> mac, + ffi.Pointer mac_len, +); + +typedef _c_calendar_db_insert_record = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Pointer record_id, +); + +typedef _dart_calendar_db_insert_record = int Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Pointer record_id, +); + +typedef _c_calendar_db_get_record = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Int32 record_id, + ffi.Pointer> record, +); + +typedef _dart_calendar_db_get_record = int Function( + ffi.Pointer view_uri, + int record_id, + ffi.Pointer> record, +); + +typedef _c_calendar_db_update_record = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, +); + +typedef _dart_calendar_db_update_record = int Function( + ffi.Pointer<__calendar_record_h> record, +); + +typedef _c_calendar_db_delete_record = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Int32 record_id, +); + +typedef _dart_calendar_db_delete_record = int Function( + ffi.Pointer view_uri, + int record_id, +); + +typedef _c_calendar_db_get_all_records = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Int32 offset, + ffi.Int32 limit, + ffi.Pointer> record_list, +); + +typedef _dart_calendar_db_get_all_records = int Function( + ffi.Pointer view_uri, + int offset, + int limit, + ffi.Pointer> record_list, +); + +typedef _c_calendar_db_get_records_with_query = ffi.Int32 Function( + ffi.Pointer<__calendar_query_h> query, + ffi.Int32 offset, + ffi.Int32 limit, + ffi.Pointer> record_list, +); + +typedef _dart_calendar_db_get_records_with_query = int Function( + ffi.Pointer<__calendar_query_h> query, + int offset, + int limit, + ffi.Pointer> record_list, +); + +typedef _c_calendar_db_get_count = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer count, +); + +typedef _dart_calendar_db_get_count = int Function( + ffi.Pointer view_uri, + ffi.Pointer count, +); + +typedef _c_calendar_db_get_count_with_query = ffi.Int32 Function( + ffi.Pointer<__calendar_query_h> query, + ffi.Pointer count, +); + +typedef _dart_calendar_db_get_count_with_query = int Function( + ffi.Pointer<__calendar_query_h> query, + ffi.Pointer count, +); + +typedef _c_calendar_db_insert_records = ffi.Int32 Function( + ffi.Pointer<__calendar_list_h> record_list, + ffi.Pointer> record_id_array, + ffi.Pointer count, +); + +typedef _dart_calendar_db_insert_records = int Function( + ffi.Pointer<__calendar_list_h> record_list, + ffi.Pointer> record_id_array, + ffi.Pointer count, +); + +typedef _c_calendar_db_update_records = ffi.Int32 Function( + ffi.Pointer<__calendar_list_h> record_list, +); + +typedef _dart_calendar_db_update_records = int Function( + ffi.Pointer<__calendar_list_h> record_list, +); + +typedef _c_calendar_db_delete_records = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer record_id_array, + ffi.Int32 count, +); + +typedef _dart_calendar_db_delete_records = int Function( + ffi.Pointer view_uri, + ffi.Pointer record_id_array, + int count, +); + +typedef _c_calendar_db_get_current_version = ffi.Int32 Function( + ffi.Pointer calendar_db_version, +); + +typedef _dart_calendar_db_get_current_version = int Function( + ffi.Pointer calendar_db_version, +); + +typedef calendar_db_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_calendar_db_add_changed_cb = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_calendar_db_add_changed_cb = int Function( + ffi.Pointer view_uri, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_calendar_db_remove_changed_cb = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_calendar_db_remove_changed_cb = int Function( + ffi.Pointer view_uri, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_calendar_db_get_changes_by_version = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Int32 calendar_book_id, + ffi.Int32 calendar_db_version, + ffi.Pointer> record_list, + ffi.Pointer current_calendar_db_version, +); + +typedef _dart_calendar_db_get_changes_by_version = int Function( + ffi.Pointer view_uri, + int calendar_book_id, + int calendar_db_version, + ffi.Pointer> record_list, + ffi.Pointer current_calendar_db_version, +); + +typedef _c_calendar_db_insert_vcalendars = ffi.Int32 Function( + ffi.Pointer vcalendar_stream, + ffi.Pointer> record_id_array, + ffi.Pointer count, +); + +typedef _dart_calendar_db_insert_vcalendars = int Function( + ffi.Pointer vcalendar_stream, + ffi.Pointer> record_id_array, + ffi.Pointer count, +); + +typedef _c_calendar_db_replace_vcalendars = ffi.Int32 Function( + ffi.Pointer vcalendar_stream, + ffi.Pointer record_id_array, + ffi.Int32 count, +); + +typedef _dart_calendar_db_replace_vcalendars = int Function( + ffi.Pointer vcalendar_stream, + ffi.Pointer record_id_array, + int count, +); + +typedef _c_calendar_db_replace_record = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Int32 record_id, +); + +typedef _dart_calendar_db_replace_record = int Function( + ffi.Pointer<__calendar_record_h> record, + int record_id, +); + +typedef _c_calendar_db_replace_records = ffi.Int32 Function( + ffi.Pointer<__calendar_list_h> record_list, + ffi.Pointer record_id_array, + ffi.Int32 count, +); + +typedef _dart_calendar_db_replace_records = int Function( + ffi.Pointer<__calendar_list_h> record_list, + ffi.Pointer record_id_array, + int count, +); + +typedef _c_calendar_db_get_last_change_version = ffi.Int32 Function( + ffi.Pointer last_change_version, +); + +typedef _dart_calendar_db_get_last_change_version = int Function( + ffi.Pointer last_change_version, +); + +typedef _c_calendar_db_get_changes_exception_by_version = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Int32 original_event_id, + ffi.Int32 calendar_db_version, + ffi.Pointer> list, +); + +typedef _dart_calendar_db_get_changes_exception_by_version = int Function( + ffi.Pointer view_uri, + int original_event_id, + int calendar_db_version, + ffi.Pointer> list, +); + +typedef _c_calendar_db_clean_after_sync = ffi.Int32 Function( + ffi.Int32 calendar_book_id, + ffi.Int32 calendar_db_version, +); + +typedef _dart_calendar_db_clean_after_sync = int Function( + int calendar_book_id, + int calendar_db_version, +); + +typedef _c_calendar_db_link_record = ffi.Int32 Function( + ffi.Int32 base_id, + ffi.Int32 record_id, +); + +typedef _dart_calendar_db_link_record = int Function( + int base_id, + int record_id, +); + +typedef _c_calendar_db_unlink_record = ffi.Int32 Function( + ffi.Int32 record_id, +); + +typedef _dart_calendar_db_unlink_record = int Function( + int record_id, +); + +typedef _c_calendar_filter_create = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer> filter, +); + +typedef _dart_calendar_filter_create = int Function( + ffi.Pointer view_uri, + ffi.Pointer> filter, +); + +typedef _c_calendar_filter_destroy = ffi.Int32 Function( + ffi.Pointer<__calendar_filter_h> filter, +); + +typedef _dart_calendar_filter_destroy = int Function( + ffi.Pointer<__calendar_filter_h> filter, +); + +typedef _c_calendar_filter_add_str = ffi.Int32 Function( + ffi.Pointer<__calendar_filter_h> filter, + ffi.Uint32 property_id, + ffi.Int32 match, + ffi.Pointer match_value, +); + +typedef _dart_calendar_filter_add_str = int Function( + ffi.Pointer<__calendar_filter_h> filter, + int property_id, + int match, + ffi.Pointer match_value, +); + +typedef _c_calendar_filter_add_int = ffi.Int32 Function( + ffi.Pointer<__calendar_filter_h> filter, + ffi.Uint32 property_id, + ffi.Int32 match, + ffi.Int32 match_value, +); + +typedef _dart_calendar_filter_add_int = int Function( + ffi.Pointer<__calendar_filter_h> filter, + int property_id, + int match, + int match_value, +); + +typedef _c_calendar_filter_add_double = ffi.Int32 Function( + ffi.Pointer<__calendar_filter_h> filter, + ffi.Uint32 property_id, + ffi.Int32 match, + ffi.Double match_value, +); + +typedef _dart_calendar_filter_add_double = int Function( + ffi.Pointer<__calendar_filter_h> filter, + int property_id, + int match, + double match_value, +); + +typedef _c_calendar_filter_add_lli = ffi.Int32 Function( + ffi.Pointer<__calendar_filter_h> filter, + ffi.Uint32 property_id, + ffi.Int32 match, + ffi.Int64 match_value, +); + +typedef _dart_calendar_filter_add_lli = int Function( + ffi.Pointer<__calendar_filter_h> filter, + int property_id, + int match, + int match_value, +); + +typedef _c_calendar_filter_add_filter = ffi.Int32 Function( + ffi.Pointer<__calendar_filter_h> parent_filter, + ffi.Pointer<__calendar_filter_h> child_filter, +); + +typedef _dart_calendar_filter_add_filter = int Function( + ffi.Pointer<__calendar_filter_h> parent_filter, + ffi.Pointer<__calendar_filter_h> child_filter, +); + +typedef _c_calendar_filter_add_operator = ffi.Int32 Function( + ffi.Pointer<__calendar_filter_h> filter, + ffi.Int32 operator_type, +); + +typedef _dart_calendar_filter_add_operator = int Function( + ffi.Pointer<__calendar_filter_h> filter, + int operator_type, +); + +typedef _c_calendar_list_create = ffi.Int32 Function( + ffi.Pointer> out_list, +); + +typedef _dart_calendar_list_create = int Function( + ffi.Pointer> out_list, +); + +typedef _c_calendar_list_destroy = ffi.Int32 Function( + ffi.Pointer<__calendar_list_h> list, + ffi.Uint8 delete_record, +); + +typedef _dart_calendar_list_destroy = int Function( + ffi.Pointer<__calendar_list_h> list, + int delete_record, +); + +typedef _c_calendar_list_get_count = ffi.Int32 Function( + ffi.Pointer<__calendar_list_h> list, + ffi.Pointer count, +); + +typedef _dart_calendar_list_get_count = int Function( + ffi.Pointer<__calendar_list_h> list, + ffi.Pointer count, +); + +typedef _c_calendar_list_add = ffi.Int32 Function( + ffi.Pointer<__calendar_list_h> list, + ffi.Pointer<__calendar_record_h> record, +); + +typedef _dart_calendar_list_add = int Function( + ffi.Pointer<__calendar_list_h> list, + ffi.Pointer<__calendar_record_h> record, +); + +typedef _c_calendar_list_remove = ffi.Int32 Function( + ffi.Pointer<__calendar_list_h> list, + ffi.Pointer<__calendar_record_h> record, +); + +typedef _dart_calendar_list_remove = int Function( + ffi.Pointer<__calendar_list_h> list, + ffi.Pointer<__calendar_record_h> record, +); + +typedef _c_calendar_list_get_current_record_p = ffi.Int32 Function( + ffi.Pointer<__calendar_list_h> list, + ffi.Pointer> record, +); + +typedef _dart_calendar_list_get_current_record_p = int Function( + ffi.Pointer<__calendar_list_h> list, + ffi.Pointer> record, +); + +typedef _c_calendar_list_prev = ffi.Int32 Function( + ffi.Pointer<__calendar_list_h> list, +); + +typedef _dart_calendar_list_prev = int Function( + ffi.Pointer<__calendar_list_h> list, +); + +typedef _c_calendar_list_next = ffi.Int32 Function( + ffi.Pointer<__calendar_list_h> list, +); + +typedef _dart_calendar_list_next = int Function( + ffi.Pointer<__calendar_list_h> list, +); + +typedef _c_calendar_list_first = ffi.Int32 Function( + ffi.Pointer<__calendar_list_h> list, +); + +typedef _dart_calendar_list_first = int Function( + ffi.Pointer<__calendar_list_h> list, +); + +typedef _c_calendar_list_last = ffi.Int32 Function( + ffi.Pointer<__calendar_list_h> list, +); + +typedef _dart_calendar_list_last = int Function( + ffi.Pointer<__calendar_list_h> list, +); + +typedef _c_calendar_query_create = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer> query, +); + +typedef _dart_calendar_query_create = int Function( + ffi.Pointer view_uri, + ffi.Pointer> query, +); + +typedef _c_calendar_query_destroy = ffi.Int32 Function( + ffi.Pointer<__calendar_query_h> query, +); + +typedef _dart_calendar_query_destroy = int Function( + ffi.Pointer<__calendar_query_h> query, +); + +typedef _c_calendar_query_set_projection = ffi.Int32 Function( + ffi.Pointer<__calendar_query_h> query, + ffi.Pointer property_id_array, + ffi.Int32 count, +); + +typedef _dart_calendar_query_set_projection = int Function( + ffi.Pointer<__calendar_query_h> query, + ffi.Pointer property_id_array, + int count, +); + +typedef _c_calendar_query_set_distinct = ffi.Int32 Function( + ffi.Pointer<__calendar_query_h> query, + ffi.Uint8 set_1, +); + +typedef _dart_calendar_query_set_distinct = int Function( + ffi.Pointer<__calendar_query_h> query, + int set_1, +); + +typedef _c_calendar_query_set_filter = ffi.Int32 Function( + ffi.Pointer<__calendar_query_h> query, + ffi.Pointer<__calendar_filter_h> filter, +); + +typedef _dart_calendar_query_set_filter = int Function( + ffi.Pointer<__calendar_query_h> query, + ffi.Pointer<__calendar_filter_h> filter, +); + +typedef _c_calendar_query_set_sort = ffi.Int32 Function( + ffi.Pointer<__calendar_query_h> query, + ffi.Uint32 property_id, + ffi.Uint8 is_ascending, +); + +typedef _dart_calendar_query_set_sort = int Function( + ffi.Pointer<__calendar_query_h> query, + int property_id, + int is_ascending, +); + +typedef _c_calendar_record_create = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer> out_record, +); + +typedef _dart_calendar_record_create = int Function( + ffi.Pointer view_uri, + ffi.Pointer> out_record, +); + +typedef _c_calendar_record_destroy = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint8 delete_child, +); + +typedef _dart_calendar_record_destroy = int Function( + ffi.Pointer<__calendar_record_h> record, + int delete_child, +); + +typedef _c_calendar_record_clone = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Pointer> out_record, +); + +typedef _dart_calendar_record_clone = int Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Pointer> out_record, +); + +typedef _c_calendar_record_get_uri_p = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Pointer> uri, +); + +typedef _dart_calendar_record_get_uri_p = int Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Pointer> uri, +); + +typedef _c_calendar_record_get_str = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer> out_str, +); + +typedef _dart_calendar_record_get_str = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer> out_str, +); + +typedef _c_calendar_record_get_str_p = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer> out_str, +); + +typedef _dart_calendar_record_get_str_p = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer> out_str, +); + +typedef _c_calendar_record_get_int = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer out_value, +); + +typedef _dart_calendar_record_get_int = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer out_value, +); + +typedef _c_calendar_record_get_double = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer out_value, +); + +typedef _dart_calendar_record_get_double = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer out_value, +); + +typedef _c_calendar_record_get_lli = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer out_value, +); + +typedef _dart_calendar_record_get_lli = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer out_value, +); + +typedef _c_calendar_record_get_caltime = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer out_value, +); + +typedef _dart_calendar_record_get_caltime = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer out_value, +); + +typedef _c_calendar_record_set_str = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer value, +); + +typedef _dart_calendar_record_set_str = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer value, +); + +typedef _c_calendar_record_set_int = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Int32 value, +); + +typedef _dart_calendar_record_set_int = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + int value, +); + +typedef _c_calendar_record_set_double = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Double value, +); + +typedef _dart_calendar_record_set_double = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + double value, +); + +typedef _c_calendar_record_set_lli = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Int64 value, +); + +typedef _dart_calendar_record_set_lli = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + int value, +); + +typedef _c_calendar_record_add_child_record = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer<__calendar_record_h> child_record, +); + +typedef _dart_calendar_record_add_child_record = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer<__calendar_record_h> child_record, +); + +typedef _c_calendar_record_remove_child_record = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer<__calendar_record_h> child_record, +); + +typedef _dart_calendar_record_remove_child_record = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer<__calendar_record_h> child_record, +); + +typedef _c_calendar_record_get_child_record_count = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer count, +); + +typedef _dart_calendar_record_get_child_record_count = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer count, +); + +typedef _c_calendar_record_get_child_record_at_p = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Int32 index, + ffi.Pointer> child_record, +); + +typedef _dart_calendar_record_get_child_record_at_p = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + int index, + ffi.Pointer> child_record, +); + +typedef _c_calendar_record_clone_child_record_list = ffi.Int32 Function( + ffi.Pointer<__calendar_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer> out_list, +); + +typedef _dart_calendar_record_clone_child_record_list = int Function( + ffi.Pointer<__calendar_record_h> record, + int property_id, + ffi.Pointer> out_list, +); + +typedef _c_calendar_connect = ffi.Int32 Function(); + +typedef _dart_calendar_connect = int Function(); + +typedef _c_calendar_disconnect = ffi.Int32 Function(); + +typedef _dart_calendar_disconnect = int Function(); + +typedef _c_calendar_connect_on_thread = ffi.Int32 Function(); + +typedef _dart_calendar_connect_on_thread = int Function(); + +typedef _c_calendar_disconnect_on_thread = ffi.Int32 Function(); + +typedef _dart_calendar_disconnect_on_thread = int Function(); + +typedef _c_calendar_connect_with_flags = ffi.Int32 Function( + ffi.Uint32 flags, +); + +typedef _dart_calendar_connect_with_flags = int Function( + int flags, +); + +typedef _c_calendar_vcalendar_make_from_records = ffi.Int32 Function( + ffi.Pointer<__calendar_list_h> calendar_list, + ffi.Pointer> vcalendar_stream, +); + +typedef _dart_calendar_vcalendar_make_from_records = int Function( + ffi.Pointer<__calendar_list_h> calendar_list, + ffi.Pointer> vcalendar_stream, +); + +typedef _c_calendar_vcalendar_parse_to_calendar = ffi.Int32 Function( + ffi.Pointer vcalendar_stream, + ffi.Pointer> calendar_list, +); + +typedef _dart_calendar_vcalendar_parse_to_calendar = int Function( + ffi.Pointer vcalendar_stream, + ffi.Pointer> calendar_list, +); + +typedef calendar_vcalendar_parse_cb = ffi.Uint8 Function( + ffi.Pointer<__calendar_record_h>, + ffi.Pointer, +); + +typedef _c_calendar_vcalendar_parse_to_calendar_foreach = ffi.Int32 Function( + ffi.Pointer vcalendar_file_path, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_calendar_vcalendar_parse_to_calendar_foreach = int Function( + ffi.Pointer vcalendar_file_path, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef calendar_reminder_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_calendar_reminder_add_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_calendar_reminder_add_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_calendar_reminder_remove_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_calendar_reminder_remove_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_contacts_connect = ffi.Int32 Function(); + +typedef _dart_contacts_connect = int Function(); + +typedef _c_contacts_disconnect = ffi.Int32 Function(); + +typedef _dart_contacts_disconnect = int Function(); + +typedef _c_contacts_connect_on_thread = ffi.Int32 Function(); + +typedef _dart_contacts_connect_on_thread = int Function(); + +typedef _c_contacts_disconnect_on_thread = ffi.Int32 Function(); + +typedef _dart_contacts_disconnect_on_thread = int Function(); + +typedef _c_contacts_connect_with_flags = ffi.Int32 Function( + ffi.Uint32 flags, +); + +typedef _dart_contacts_connect_with_flags = int Function( + int flags, +); + +typedef _c_contacts_record_create = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer> record, +); + +typedef _dart_contacts_record_create = int Function( + ffi.Pointer view_uri, + ffi.Pointer> record, +); + +typedef _c_contacts_record_destroy = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint8 delete_child, +); + +typedef _dart_contacts_record_destroy = int Function( + ffi.Pointer<__contacts_record_h> record, + int delete_child, +); + +typedef _c_contacts_record_clone = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Pointer> cloned_record, +); + +typedef _dart_contacts_record_clone = int Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Pointer> cloned_record, +); + +typedef _c_contacts_record_get_str = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer> value, +); + +typedef _dart_contacts_record_get_str = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer> value, +); + +typedef _c_contacts_record_get_str_p = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer> value, +); + +typedef _dart_contacts_record_get_str_p = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer> value, +); + +typedef _c_contacts_record_set_str = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer value, +); + +typedef _dart_contacts_record_set_str = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer value, +); + +typedef _c_contacts_record_get_int = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer value, +); + +typedef _dart_contacts_record_get_int = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer value, +); + +typedef _c_contacts_record_set_int = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Int32 value, +); + +typedef _dart_contacts_record_set_int = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + int value, +); + +typedef _c_contacts_record_get_lli = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer value, +); + +typedef _dart_contacts_record_get_lli = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer value, +); + +typedef _c_contacts_record_set_lli = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Int64 value, +); + +typedef _dart_contacts_record_set_lli = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + int value, +); + +typedef _c_contacts_record_get_bool = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer value, +); + +typedef _dart_contacts_record_get_bool = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer value, +); + +typedef _c_contacts_record_set_bool = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Uint8 value, +); + +typedef _dart_contacts_record_set_bool = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + int value, +); + +typedef _c_contacts_record_get_double = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer value, +); + +typedef _dart_contacts_record_get_double = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer value, +); + +typedef _c_contacts_record_set_double = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Double value, +); + +typedef _dart_contacts_record_set_double = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + double value, +); + +typedef _c_contacts_record_add_child_record = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer<__contacts_record_h> child_record, +); + +typedef _dart_contacts_record_add_child_record = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer<__contacts_record_h> child_record, +); + +typedef _c_contacts_record_remove_child_record = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer<__contacts_record_h> child_record, +); + +typedef _dart_contacts_record_remove_child_record = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer<__contacts_record_h> child_record, +); + +typedef _c_contacts_record_get_child_record_count = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer count, +); + +typedef _dart_contacts_record_get_child_record_count = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer count, +); + +typedef _c_contacts_record_get_child_record_at_p = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Int32 index, + ffi.Pointer> child_record, +); + +typedef _dart_contacts_record_get_child_record_at_p = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + int index, + ffi.Pointer> child_record, +); + +typedef _c_contacts_record_clone_child_record_list = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Uint32 property_id, + ffi.Pointer> cloned_list, +); + +typedef _dart_contacts_record_clone_child_record_list = int Function( + ffi.Pointer<__contacts_record_h> record, + int property_id, + ffi.Pointer> cloned_list, +); + +typedef _c_contacts_record_get_uri_p = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Pointer> view_uri, +); + +typedef _dart_contacts_record_get_uri_p = int Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Pointer> view_uri, +); + +typedef _c_contacts_list_create = ffi.Int32 Function( + ffi.Pointer> contacts_list, +); + +typedef _dart_contacts_list_create = int Function( + ffi.Pointer> contacts_list, +); + +typedef _c_contacts_list_destroy = ffi.Int32 Function( + ffi.Pointer<__contacts_list_h> contacts_list, + ffi.Uint8 delete_child, +); + +typedef _dart_contacts_list_destroy = int Function( + ffi.Pointer<__contacts_list_h> contacts_list, + int delete_child, +); + +typedef _c_contacts_list_get_count = ffi.Int32 Function( + ffi.Pointer<__contacts_list_h> contacts_list, + ffi.Pointer count, +); + +typedef _dart_contacts_list_get_count = int Function( + ffi.Pointer<__contacts_list_h> contacts_list, + ffi.Pointer count, +); + +typedef _c_contacts_list_add = ffi.Int32 Function( + ffi.Pointer<__contacts_list_h> contacts_list, + ffi.Pointer<__contacts_record_h> record, +); + +typedef _dart_contacts_list_add = int Function( + ffi.Pointer<__contacts_list_h> contacts_list, + ffi.Pointer<__contacts_record_h> record, +); + +typedef _c_contacts_list_remove = ffi.Int32 Function( + ffi.Pointer<__contacts_list_h> contacts_list, + ffi.Pointer<__contacts_record_h> record, +); + +typedef _dart_contacts_list_remove = int Function( + ffi.Pointer<__contacts_list_h> contacts_list, + ffi.Pointer<__contacts_record_h> record, +); + +typedef _c_contacts_list_get_current_record_p = ffi.Int32 Function( + ffi.Pointer<__contacts_list_h> contacts_list, + ffi.Pointer> record, +); + +typedef _dart_contacts_list_get_current_record_p = int Function( + ffi.Pointer<__contacts_list_h> contacts_list, + ffi.Pointer> record, +); + +typedef _c_contacts_list_prev = ffi.Int32 Function( + ffi.Pointer<__contacts_list_h> contacts_list, +); + +typedef _dart_contacts_list_prev = int Function( + ffi.Pointer<__contacts_list_h> contacts_list, +); + +typedef _c_contacts_list_next = ffi.Int32 Function( + ffi.Pointer<__contacts_list_h> contacts_list, +); + +typedef _dart_contacts_list_next = int Function( + ffi.Pointer<__contacts_list_h> contacts_list, +); + +typedef _c_contacts_list_first = ffi.Int32 Function( + ffi.Pointer<__contacts_list_h> contacts_list, +); + +typedef _dart_contacts_list_first = int Function( + ffi.Pointer<__contacts_list_h> contacts_list, +); + +typedef _c_contacts_list_last = ffi.Int32 Function( + ffi.Pointer<__contacts_list_h> contacts_list, +); + +typedef _dart_contacts_list_last = int Function( + ffi.Pointer<__contacts_list_h> contacts_list, +); + +typedef _c_contacts_filter_create = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer> filter, +); + +typedef _dart_contacts_filter_create = int Function( + ffi.Pointer view_uri, + ffi.Pointer> filter, +); + +typedef _c_contacts_filter_destroy = ffi.Int32 Function( + ffi.Pointer<__contacts_filter_h> filter, +); + +typedef _dart_contacts_filter_destroy = int Function( + ffi.Pointer<__contacts_filter_h> filter, +); + +typedef _c_contacts_filter_add_str = ffi.Int32 Function( + ffi.Pointer<__contacts_filter_h> filter, + ffi.Uint32 property_id, + ffi.Int32 match, + ffi.Pointer match_value, +); + +typedef _dart_contacts_filter_add_str = int Function( + ffi.Pointer<__contacts_filter_h> filter, + int property_id, + int match, + ffi.Pointer match_value, +); + +typedef _c_contacts_filter_add_int = ffi.Int32 Function( + ffi.Pointer<__contacts_filter_h> filter, + ffi.Uint32 property_id, + ffi.Int32 match, + ffi.Int32 match_value, +); + +typedef _dart_contacts_filter_add_int = int Function( + ffi.Pointer<__contacts_filter_h> filter, + int property_id, + int match, + int match_value, +); + +typedef _c_contacts_filter_add_lli = ffi.Int32 Function( + ffi.Pointer<__contacts_filter_h> filter, + ffi.Uint32 property_id, + ffi.Int32 match, + ffi.Int64 match_value, +); + +typedef _dart_contacts_filter_add_lli = int Function( + ffi.Pointer<__contacts_filter_h> filter, + int property_id, + int match, + int match_value, +); + +typedef _c_contacts_filter_add_double = ffi.Int32 Function( + ffi.Pointer<__contacts_filter_h> filter, + ffi.Uint32 property_id, + ffi.Int32 match, + ffi.Double match_value, +); + +typedef _dart_contacts_filter_add_double = int Function( + ffi.Pointer<__contacts_filter_h> filter, + int property_id, + int match, + double match_value, +); + +typedef _c_contacts_filter_add_bool = ffi.Int32 Function( + ffi.Pointer<__contacts_filter_h> filter, + ffi.Uint32 property_id, + ffi.Uint8 match_value, +); + +typedef _dart_contacts_filter_add_bool = int Function( + ffi.Pointer<__contacts_filter_h> filter, + int property_id, + int match_value, +); + +typedef _c_contacts_filter_add_operator = ffi.Int32 Function( + ffi.Pointer<__contacts_filter_h> filter, + ffi.Int32 operator_type, +); + +typedef _dart_contacts_filter_add_operator = int Function( + ffi.Pointer<__contacts_filter_h> filter, + int operator_type, +); + +typedef _c_contacts_filter_add_filter = ffi.Int32 Function( + ffi.Pointer<__contacts_filter_h> parent_filter, + ffi.Pointer<__contacts_filter_h> child_filter, +); + +typedef _dart_contacts_filter_add_filter = int Function( + ffi.Pointer<__contacts_filter_h> parent_filter, + ffi.Pointer<__contacts_filter_h> child_filter, +); + +typedef _c_contacts_query_create = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer> query, +); + +typedef _dart_contacts_query_create = int Function( + ffi.Pointer view_uri, + ffi.Pointer> query, +); + +typedef _c_contacts_query_destroy = ffi.Int32 Function( + ffi.Pointer<__contacts_query_h> query, +); + +typedef _dart_contacts_query_destroy = int Function( + ffi.Pointer<__contacts_query_h> query, +); + +typedef _c_contacts_query_set_projection = ffi.Int32 Function( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer property_id_array, + ffi.Int32 count, +); + +typedef _dart_contacts_query_set_projection = int Function( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer property_id_array, + int count, +); + +typedef _c_contacts_query_set_distinct = ffi.Int32 Function( + ffi.Pointer<__contacts_query_h> query, + ffi.Uint8 set_1, +); + +typedef _dart_contacts_query_set_distinct = int Function( + ffi.Pointer<__contacts_query_h> query, + int set_1, +); + +typedef _c_contacts_query_set_filter = ffi.Int32 Function( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer<__contacts_filter_h> filter, +); + +typedef _dart_contacts_query_set_filter = int Function( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer<__contacts_filter_h> filter, +); + +typedef _c_contacts_query_set_sort = ffi.Int32 Function( + ffi.Pointer<__contacts_query_h> query, + ffi.Uint32 property_id, + ffi.Uint8 is_ascending, +); + +typedef _dart_contacts_query_set_sort = int Function( + ffi.Pointer<__contacts_query_h> query, + int property_id, + int is_ascending, +); + +typedef _c_contacts_db_insert_record = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Pointer id, +); + +typedef _dart_contacts_db_insert_record = int Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Pointer id, +); + +typedef _c_contacts_db_get_record = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Int32 record_id, + ffi.Pointer> record, +); + +typedef _dart_contacts_db_get_record = int Function( + ffi.Pointer view_uri, + int record_id, + ffi.Pointer> record, +); + +typedef _c_contacts_db_update_record = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, +); + +typedef _dart_contacts_db_update_record = int Function( + ffi.Pointer<__contacts_record_h> record, +); + +typedef _c_contacts_db_delete_record = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Int32 record_id, +); + +typedef _dart_contacts_db_delete_record = int Function( + ffi.Pointer view_uri, + int record_id, +); + +typedef _c_contacts_db_replace_record = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> record, + ffi.Int32 id, +); + +typedef _dart_contacts_db_replace_record = int Function( + ffi.Pointer<__contacts_record_h> record, + int id, +); + +typedef _c_contacts_db_get_all_records = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Int32 offset, + ffi.Int32 limit, + ffi.Pointer> record_list, +); + +typedef _dart_contacts_db_get_all_records = int Function( + ffi.Pointer view_uri, + int offset, + int limit, + ffi.Pointer> record_list, +); + +typedef _c_contacts_db_get_records_with_query = ffi.Int32 Function( + ffi.Pointer<__contacts_query_h> query, + ffi.Int32 offset, + ffi.Int32 limit, + ffi.Pointer> record_list, +); + +typedef _dart_contacts_db_get_records_with_query = int Function( + ffi.Pointer<__contacts_query_h> query, + int offset, + int limit, + ffi.Pointer> record_list, +); + +typedef _c_contacts_db_insert_records = ffi.Int32 Function( + ffi.Pointer<__contacts_list_h> record_list, + ffi.Pointer> ids, + ffi.Pointer count, +); + +typedef _dart_contacts_db_insert_records = int Function( + ffi.Pointer<__contacts_list_h> record_list, + ffi.Pointer> ids, + ffi.Pointer count, +); + +typedef _c_contacts_db_update_records = ffi.Int32 Function( + ffi.Pointer<__contacts_list_h> record_list, +); + +typedef _dart_contacts_db_update_records = int Function( + ffi.Pointer<__contacts_list_h> record_list, +); + +typedef _c_contacts_db_delete_records = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer record_id_array, + ffi.Int32 count, +); + +typedef _dart_contacts_db_delete_records = int Function( + ffi.Pointer view_uri, + ffi.Pointer record_id_array, + int count, +); + +typedef _c_contacts_db_replace_records = ffi.Int32 Function( + ffi.Pointer<__contacts_list_h> list, + ffi.Pointer record_id_array, + ffi.Int32 count, +); + +typedef _dart_contacts_db_replace_records = int Function( + ffi.Pointer<__contacts_list_h> list, + ffi.Pointer record_id_array, + int count, +); + +typedef _c_contacts_db_get_current_version = ffi.Int32 Function( + ffi.Pointer contacts_db_version, +); + +typedef _dart_contacts_db_get_current_version = int Function( + ffi.Pointer contacts_db_version, +); + +typedef contacts_db_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_contacts_db_add_changed_cb = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_contacts_db_add_changed_cb = int Function( + ffi.Pointer view_uri, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_contacts_db_remove_changed_cb = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_contacts_db_remove_changed_cb = int Function( + ffi.Pointer view_uri, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_contacts_db_get_changes_by_version = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Int32 address_book_id, + ffi.Int32 contacts_db_version, + ffi.Pointer> change_record_list, + ffi.Pointer current_contacts_db_version, +); + +typedef _dart_contacts_db_get_changes_by_version = int Function( + ffi.Pointer view_uri, + int address_book_id, + int contacts_db_version, + ffi.Pointer> change_record_list, + ffi.Pointer current_contacts_db_version, +); + +typedef _c_contacts_db_search_records = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer keyword, + ffi.Int32 offset, + ffi.Int32 limit, + ffi.Pointer> record_list, +); + +typedef _dart_contacts_db_search_records = int Function( + ffi.Pointer view_uri, + ffi.Pointer keyword, + int offset, + int limit, + ffi.Pointer> record_list, +); + +typedef _c_contacts_db_search_records_with_query = ffi.Int32 Function( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer keyword, + ffi.Int32 offset, + ffi.Int32 limit, + ffi.Pointer> record_list, +); + +typedef _dart_contacts_db_search_records_with_query = int Function( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer keyword, + int offset, + int limit, + ffi.Pointer> record_list, +); + +typedef _c_contacts_db_search_records_with_range = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer keyword, + ffi.Int32 offset, + ffi.Int32 limit, + ffi.Int32 range, + ffi.Pointer> record_list, +); + +typedef _dart_contacts_db_search_records_with_range = int Function( + ffi.Pointer view_uri, + ffi.Pointer keyword, + int offset, + int limit, + int range, + ffi.Pointer> record_list, +); + +typedef _c_contacts_db_search_records_for_snippet = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer keyword, + ffi.Int32 offset, + ffi.Int32 limit, + ffi.Pointer start_match, + ffi.Pointer end_match, + ffi.Int32 token_number, + ffi.Pointer> record_list, +); + +typedef _dart_contacts_db_search_records_for_snippet = int Function( + ffi.Pointer view_uri, + ffi.Pointer keyword, + int offset, + int limit, + ffi.Pointer start_match, + ffi.Pointer end_match, + int token_number, + ffi.Pointer> record_list, +); + +typedef _c_contacts_db_search_records_with_query_for_snippet = ffi.Int32 + Function( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer keyword, + ffi.Int32 offset, + ffi.Int32 limit, + ffi.Pointer start_match, + ffi.Pointer end_match, + ffi.Int32 token_number, + ffi.Pointer> record_list, +); + +typedef _dart_contacts_db_search_records_with_query_for_snippet = int Function( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer keyword, + int offset, + int limit, + ffi.Pointer start_match, + ffi.Pointer end_match, + int token_number, + ffi.Pointer> record_list, +); + +typedef _c_contacts_db_search_records_with_range_for_snippet = ffi.Int32 + Function( + ffi.Pointer view_uri, + ffi.Pointer keyword, + ffi.Int32 offset, + ffi.Int32 limit, + ffi.Int32 range, + ffi.Pointer start_match, + ffi.Pointer end_match, + ffi.Int32 token_number, + ffi.Pointer> record_list, +); + +typedef _dart_contacts_db_search_records_with_range_for_snippet = int Function( + ffi.Pointer view_uri, + ffi.Pointer keyword, + int offset, + int limit, + int range, + ffi.Pointer start_match, + ffi.Pointer end_match, + int token_number, + ffi.Pointer> record_list, +); + +typedef _c_contacts_db_get_count = ffi.Int32 Function( + ffi.Pointer view_uri, + ffi.Pointer count, +); + +typedef _dart_contacts_db_get_count = int Function( + ffi.Pointer view_uri, + ffi.Pointer count, +); + +typedef _c_contacts_db_get_count_with_query = ffi.Int32 Function( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer count, +); + +typedef _dart_contacts_db_get_count_with_query = int Function( + ffi.Pointer<__contacts_query_h> query, + ffi.Pointer count, +); + +typedef _c_contacts_db_get_last_change_version = ffi.Int32 Function( + ffi.Pointer last_change_version, +); + +typedef _dart_contacts_db_get_last_change_version = int Function( + ffi.Pointer last_change_version, +); + +typedef _c_contacts_setting_get_name_display_order = ffi.Int32 Function( + ffi.Pointer name_display_order, +); + +typedef _dart_contacts_setting_get_name_display_order = int Function( + ffi.Pointer name_display_order, +); + +typedef _c_contacts_setting_set_name_display_order = ffi.Int32 Function( + ffi.Int32 name_display_order, +); + +typedef _dart_contacts_setting_set_name_display_order = int Function( + int name_display_order, +); + +typedef _c_contacts_setting_get_name_sorting_order = ffi.Int32 Function( + ffi.Pointer name_sorting_order, +); + +typedef _dart_contacts_setting_get_name_sorting_order = int Function( + ffi.Pointer name_sorting_order, +); + +typedef _c_contacts_setting_set_name_sorting_order = ffi.Int32 Function( + ffi.Int32 name_sorting_order, +); + +typedef _dart_contacts_setting_set_name_sorting_order = int Function( + int name_sorting_order, +); + +typedef contacts_setting_name_display_order_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_contacts_setting_add_name_display_order_changed_cb = ffi.Int32 + Function( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _dart_contacts_setting_add_name_display_order_changed_cb = int Function( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _c_contacts_setting_remove_name_display_order_changed_cb = ffi.Int32 + Function( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _dart_contacts_setting_remove_name_display_order_changed_cb = int + Function( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef contacts_setting_name_sorting_order_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_contacts_setting_add_name_sorting_order_changed_cb = ffi.Int32 + Function( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _dart_contacts_setting_add_name_sorting_order_changed_cb = int Function( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _c_contacts_setting_remove_name_sorting_order_changed_cb = ffi.Int32 + Function( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _dart_contacts_setting_remove_name_sorting_order_changed_cb = int + Function( + ffi.Pointer< + ffi.NativeFunction> + callback, + ffi.Pointer user_data, +); + +typedef _c_contacts_person_link_person = ffi.Int32 Function( + ffi.Int32 base_person_id, + ffi.Int32 person_id, +); + +typedef _dart_contacts_person_link_person = int Function( + int base_person_id, + int person_id, +); + +typedef _c_contacts_person_unlink_contact = ffi.Int32 Function( + ffi.Int32 person_id, + ffi.Int32 contact_id, + ffi.Pointer unlinked_person_id, +); + +typedef _dart_contacts_person_unlink_contact = int Function( + int person_id, + int contact_id, + ffi.Pointer unlinked_person_id, +); + +typedef _c_contacts_person_reset_usage = ffi.Int32 Function( + ffi.Int32 person_id, + ffi.Int32 type, +); + +typedef _dart_contacts_person_reset_usage = int Function( + int person_id, + int type, +); + +typedef _c_contacts_person_set_favorite_order = ffi.Int32 Function( + ffi.Int32 person_id, + ffi.Int32 previous_person_id, + ffi.Int32 next_person_id, +); + +typedef _dart_contacts_person_set_favorite_order = int Function( + int person_id, + int previous_person_id, + int next_person_id, +); + +typedef _c_contacts_person_set_default_property = ffi.Int32 Function( + ffi.Int32 property, + ffi.Int32 person_id, + ffi.Int32 id, +); + +typedef _dart_contacts_person_set_default_property = int Function( + int property, + int person_id, + int id, +); + +typedef _c_contacts_person_get_default_property = ffi.Int32 Function( + ffi.Int32 property, + ffi.Int32 person_id, + ffi.Pointer id, +); + +typedef _dart_contacts_person_get_default_property = int Function( + int property, + int person_id, + ffi.Pointer id, +); + +typedef _c_contacts_person_get_aggregation_suggestions = ffi.Int32 Function( + ffi.Int32 person_id, + ffi.Int32 limit, + ffi.Pointer> record_list, +); + +typedef _dart_contacts_person_get_aggregation_suggestions = int Function( + int person_id, + int limit, + ffi.Pointer> record_list, +); + +typedef _c_contacts_group_add_contact = ffi.Int32 Function( + ffi.Int32 group_id, + ffi.Int32 contact_id, +); + +typedef _dart_contacts_group_add_contact = int Function( + int group_id, + int contact_id, +); + +typedef _c_contacts_group_remove_contact = ffi.Int32 Function( + ffi.Int32 group_id, + ffi.Int32 contact_id, +); + +typedef _dart_contacts_group_remove_contact = int Function( + int group_id, + int contact_id, +); + +typedef _c_contacts_group_set_group_order = ffi.Int32 Function( + ffi.Int32 group_id, + ffi.Int32 previous_group_id, + ffi.Int32 next_group_id, +); + +typedef _dart_contacts_group_set_group_order = int Function( + int group_id, + int previous_group_id, + int next_group_id, +); + +typedef _c_contacts_sim_import_all_contacts = ffi.Int32 Function(); + +typedef _dart_contacts_sim_import_all_contacts = int Function(); + +typedef _c_contacts_sim_get_initialization_status = ffi.Int32 Function( + ffi.Pointer completed, +); + +typedef _dart_contacts_sim_get_initialization_status = int Function( + ffi.Pointer completed, +); + +typedef contacts_sim_import_progress_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_contacts_sim_import_all_contacts_by_sim_slot_no = ffi.Int32 Function( + ffi.Int32 sim_slot_no, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_contacts_sim_import_all_contacts_by_sim_slot_no = int Function( + int sim_slot_no, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_contacts_sim_get_initialization_status_by_sim_slot_no = ffi.Int32 + Function( + ffi.Int32 sim_slot_no, + ffi.Pointer completed, +); + +typedef _dart_contacts_sim_get_initialization_status_by_sim_slot_no = int + Function( + int sim_slot_no, + ffi.Pointer completed, +); + +typedef contacts_vcard_parse_cb = ffi.Uint8 Function( + ffi.Pointer<__contacts_record_h>, + ffi.Pointer, +); + +typedef _c_contacts_vcard_parse_to_contact_foreach = ffi.Int32 Function( + ffi.Pointer vcard_file_path, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_contacts_vcard_parse_to_contact_foreach = int Function( + ffi.Pointer vcard_file_path, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_contacts_vcard_parse_to_contacts = ffi.Int32 Function( + ffi.Pointer vcard_stream, + ffi.Pointer> contacts_list, +); + +typedef _dart_contacts_vcard_parse_to_contacts = int Function( + ffi.Pointer vcard_stream, + ffi.Pointer> contacts_list, +); + +typedef _c_contacts_vcard_make_from_contact = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> contact, + ffi.Pointer> vcard_stream, +); + +typedef _dart_contacts_vcard_make_from_contact = int Function( + ffi.Pointer<__contacts_record_h> contact, + ffi.Pointer> vcard_stream, +); + +typedef _c_contacts_vcard_make_from_my_profile = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> my_profile, + ffi.Pointer> vcard_stream, +); + +typedef _dart_contacts_vcard_make_from_my_profile = int Function( + ffi.Pointer<__contacts_record_h> my_profile, + ffi.Pointer> vcard_stream, +); + +typedef _c_contacts_vcard_make_from_person = ffi.Int32 Function( + ffi.Pointer<__contacts_record_h> person, + ffi.Pointer> vcard_stream, +); + +typedef _dart_contacts_vcard_make_from_person = int Function( + ffi.Pointer<__contacts_record_h> person, + ffi.Pointer> vcard_stream, +); + +typedef _c_contacts_vcard_get_entity_count = ffi.Int32 Function( + ffi.Pointer vcard_file_path, + ffi.Pointer count, +); + +typedef _dart_contacts_vcard_get_entity_count = int Function( + ffi.Pointer vcard_file_path, + ffi.Pointer count, +); + +typedef _c_contacts_vcard_get_limit_size_of_photo = ffi.Int32 Function( + ffi.Pointer limit_size, +); + +typedef _dart_contacts_vcard_get_limit_size_of_photo = int Function( + ffi.Pointer limit_size, +); + +typedef _c_contacts_vcard_set_limit_size_of_photo = ffi.Int32 Function( + ffi.Uint32 limit_size, +); + +typedef _dart_contacts_vcard_set_limit_size_of_photo = int Function( + int limit_size, +); + +typedef _c_contacts_activity_delete_by_contact_id = ffi.Int32 Function( + ffi.Int32 contact_id, +); + +typedef _dart_contacts_activity_delete_by_contact_id = int Function( + int contact_id, +); + +typedef _c_contacts_activity_delete_by_account_id = ffi.Int32 Function( + ffi.Int32 account_id, +); + +typedef _dart_contacts_activity_delete_by_account_id = int Function( + int account_id, +); + +typedef _c_contacts_phone_log_reset_statistics = ffi.Int32 Function(); + +typedef _dart_contacts_phone_log_reset_statistics = int Function(); + +typedef _c_contacts_phone_log_reset_statistics_by_sim = ffi.Int32 Function( + ffi.Int32 sim_slot_no, +); + +typedef _dart_contacts_phone_log_reset_statistics_by_sim = int Function( + int sim_slot_no, +); + +typedef _c_contacts_db_get_status = ffi.Int32 Function( + ffi.Pointer status, +); + +typedef _dart_contacts_db_get_status = int Function( + ffi.Pointer status, +); + +typedef contacts_db_status_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_contacts_db_add_status_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_contacts_db_add_status_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_contacts_db_remove_status_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_contacts_db_remove_status_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_phone_number_blocking_rule_create = ffi.Int32 Function( + ffi.Pointer> rule, +); + +typedef _dart_phone_number_blocking_rule_create = int Function( + ffi.Pointer> rule, +); + +typedef _c_phone_number_blocking_rule_destroy = ffi.Int32 Function( + ffi.Pointer rule, +); + +typedef _dart_phone_number_blocking_rule_destroy = int Function( + ffi.Pointer rule, +); + +typedef _c_phone_number_blocking_rule_get_number = ffi.Int32 Function( + ffi.Pointer rule, + ffi.Pointer> number, +); + +typedef _dart_phone_number_blocking_rule_get_number = int Function( + ffi.Pointer rule, + ffi.Pointer> number, +); + +typedef _c_phone_number_blocking_rule_get_match_type = ffi.Int32 Function( + ffi.Pointer rule, + ffi.Pointer match_type, +); + +typedef _dart_phone_number_blocking_rule_get_match_type = int Function( + ffi.Pointer rule, + ffi.Pointer match_type, +); + +typedef _c_phone_number_blocking_rule_set_number = ffi.Int32 Function( + ffi.Pointer rule, + ffi.Pointer number, +); + +typedef _dart_phone_number_blocking_rule_set_number = int Function( + ffi.Pointer rule, + ffi.Pointer number, +); + +typedef _c_phone_number_blocking_rule_set_match_type = ffi.Int32 Function( + ffi.Pointer rule, + ffi.Int32 match_type, +); + +typedef _dart_phone_number_blocking_rule_set_match_type = int Function( + ffi.Pointer rule, + int match_type, +); + +typedef _c_phone_number_connect = ffi.Int32 Function(); + +typedef _dart_phone_number_connect = int Function(); + +typedef _c_phone_number_disconnect = ffi.Int32 Function(); + +typedef _dart_phone_number_disconnect = int Function(); + +typedef _c_phone_number_get_location_from_number = ffi.Int32 Function( + ffi.Pointer number, + ffi.Int32 region, + ffi.Int32 language, + ffi.Pointer> location, +); + +typedef _dart_phone_number_get_location_from_number = int Function( + ffi.Pointer number, + int region, + int language, + ffi.Pointer> location, +); + +typedef _c_phone_number_get_formatted_number = ffi.Int32 Function( + ffi.Pointer number, + ffi.Int32 region, + ffi.Pointer> formatted_number, +); + +typedef _dart_phone_number_get_formatted_number = int Function( + ffi.Pointer number, + int region, + ffi.Pointer> formatted_number, +); + +typedef _c_phone_number_get_normalized_number = ffi.Int32 Function( + ffi.Pointer number, + ffi.Pointer> normalized_number, +); + +typedef _dart_phone_number_get_normalized_number = int Function( + ffi.Pointer number, + ffi.Pointer> normalized_number, +); + +typedef _c_phone_number_add_blocking_rule = ffi.Int32 Function( + ffi.Pointer rule, +); + +typedef _dart_phone_number_add_blocking_rule = int Function( + ffi.Pointer rule, +); + +typedef _c_phone_number_remove_blocking_rule = ffi.Int32 Function( + ffi.Pointer rule, +); + +typedef _dart_phone_number_remove_blocking_rule = int Function( + ffi.Pointer rule, +); + +typedef _c_phone_number_get_blocking_rules = ffi.Int32 Function( + ffi.Int32 offset, + ffi.Int32 limit, + ffi.Pointer>> rules, + ffi.Pointer length, +); + +typedef _dart_phone_number_get_blocking_rules = int Function( + int offset, + int limit, + ffi.Pointer>> rules, + ffi.Pointer length, +); + +typedef _c_phone_number_get_blocking_rules_related = ffi.Int32 Function( + ffi.Pointer number, + ffi.Pointer>> rules, + ffi.Pointer length, +); + +typedef _dart_phone_number_get_blocking_rules_related = int Function( + ffi.Pointer number, + ffi.Pointer>> rules, + ffi.Pointer length, +); + +typedef _c_phone_number_check_blocking = ffi.Int32 Function( + ffi.Pointer number, + ffi.Pointer is_blocked, +); + +typedef _dart_phone_number_check_blocking = int Function( + ffi.Pointer number, + ffi.Pointer is_blocked, +); + +typedef _c_device_battery_get_percent = ffi.Int32 Function( + ffi.Pointer percent, +); + +typedef _dart_device_battery_get_percent = int Function( + ffi.Pointer percent, +); + +typedef _c_device_battery_is_charging = ffi.Int32 Function( + ffi.Pointer charging, +); + +typedef _dart_device_battery_is_charging = int Function( + ffi.Pointer charging, +); + +typedef _c_device_battery_get_level_status = ffi.Int32 Function( + ffi.Pointer status, +); + +typedef _dart_device_battery_get_level_status = int Function( + ffi.Pointer status, +); + +typedef _c_device_battery_get_health = ffi.Int32 Function( + ffi.Pointer health, +); + +typedef _dart_device_battery_get_health = int Function( + ffi.Pointer health, +); + +typedef _c_device_battery_get_power_source = ffi.Int32 Function( + ffi.Pointer source, +); + +typedef _dart_device_battery_get_power_source = int Function( + ffi.Pointer source, +); + +typedef _c_device_battery_get_property = ffi.Int32 Function( + ffi.Int32 property, + ffi.Pointer value, +); + +typedef _dart_device_battery_get_property = int Function( + int property, + ffi.Pointer value, +); + +typedef _c_device_battery_get_status = ffi.Int32 Function( + ffi.Pointer status, +); + +typedef _dart_device_battery_get_status = int Function( + ffi.Pointer status, +); + +typedef device_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_device_add_callback = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_device_add_callback = int Function( + int type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_device_remove_callback = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer> callback, +); + +typedef _dart_device_remove_callback = int Function( + int type, + ffi.Pointer> callback, +); + +typedef _c_device_display_get_numbers = ffi.Int32 Function( + ffi.Pointer device_number, +); + +typedef _dart_device_display_get_numbers = int Function( + ffi.Pointer device_number, +); + +typedef _c_device_display_get_max_brightness = ffi.Int32 Function( + ffi.Int32 display_index, + ffi.Pointer max_brightness, +); + +typedef _dart_device_display_get_max_brightness = int Function( + int display_index, + ffi.Pointer max_brightness, +); + +typedef _c_device_display_get_brightness = ffi.Int32 Function( + ffi.Int32 display_index, + ffi.Pointer brightness, +); + +typedef _dart_device_display_get_brightness = int Function( + int display_index, + ffi.Pointer brightness, +); + +typedef _c_device_display_set_brightness = ffi.Int32 Function( + ffi.Int32 display_index, + ffi.Int32 brightness, +); + +typedef _dart_device_display_set_brightness = int Function( + int display_index, + int brightness, +); + +typedef _c_device_display_get_state = ffi.Int32 Function( + ffi.Pointer state, +); + +typedef _dart_device_display_get_state = int Function( + ffi.Pointer state, +); + +typedef _c_device_display_change_state = ffi.Int32 Function( + ffi.Int32 state, +); + +typedef _dart_device_display_change_state = int Function( + int state, +); + +typedef _c_device_haptic_get_count = ffi.Int32 Function( + ffi.Pointer device_number, +); + +typedef _dart_device_haptic_get_count = int Function( + ffi.Pointer device_number, +); + +typedef _c_device_haptic_open = ffi.Int32 Function( + ffi.Int32 device_index, + ffi.Pointer> device_handle, +); + +typedef _dart_device_haptic_open = int Function( + int device_index, + ffi.Pointer> device_handle, +); + +typedef _c_device_haptic_close = ffi.Int32 Function( + ffi.Pointer device_handle, +); + +typedef _dart_device_haptic_close = int Function( + ffi.Pointer device_handle, +); + +typedef _c_device_haptic_vibrate = ffi.Int32 Function( + ffi.Pointer device_handle, + ffi.Int32 duration, + ffi.Int32 feedback, + ffi.Pointer> effect_handle, +); + +typedef _dart_device_haptic_vibrate = int Function( + ffi.Pointer device_handle, + int duration, + int feedback, + ffi.Pointer> effect_handle, +); + +typedef _c_device_haptic_stop = ffi.Int32 Function( + ffi.Pointer device_handle, + ffi.Pointer effect_handle, +); + +typedef _dart_device_haptic_stop = int Function( + ffi.Pointer device_handle, + ffi.Pointer effect_handle, +); + +typedef _c_device_flash_get_max_brightness = ffi.Int32 Function( + ffi.Pointer max_brightness, +); + +typedef _dart_device_flash_get_max_brightness = int Function( + ffi.Pointer max_brightness, +); + +typedef _c_device_flash_get_brightness = ffi.Int32 Function( + ffi.Pointer brightness, +); + +typedef _dart_device_flash_get_brightness = int Function( + ffi.Pointer brightness, +); + +typedef _c_device_flash_set_brightness = ffi.Int32 Function( + ffi.Int32 brightness, +); + +typedef _dart_device_flash_set_brightness = int Function( + int brightness, +); + +typedef _c_device_led_play_custom = ffi.Int32 Function( + ffi.Int32 on_1, + ffi.Int32 off, + ffi.Uint32 color, + ffi.Uint32 flags, +); + +typedef _dart_device_led_play_custom = int Function( + int on_1, + int off, + int color, + int flags, +); + +typedef _c_device_led_stop_custom = ffi.Int32 Function(); + +typedef _dart_device_led_stop_custom = int Function(); + +typedef _c_device_power_request_lock = ffi.Int32 Function( + ffi.Int32 type, + ffi.Int32 timeout_ms, +); + +typedef _dart_device_power_request_lock = int Function( + int type, + int timeout_ms, +); + +typedef _c_device_power_release_lock = ffi.Int32 Function( + ffi.Int32 type, +); + +typedef _dart_device_power_release_lock = int Function( + int type, +); + +typedef _c_device_power_wakeup = ffi.Int32 Function( + ffi.Uint8 dim, +); + +typedef _dart_device_power_wakeup = int Function( + int dim, +); + +typedef _c_device_power_reboot = ffi.Int32 Function( + ffi.Pointer reason, +); + +typedef _dart_device_power_reboot = int Function( + ffi.Pointer reason, +); + +typedef _c_device_ir_is_available = ffi.Int32 Function( + ffi.Pointer available, +); + +typedef _dart_device_ir_is_available = int Function( + ffi.Pointer available, +); + +typedef _c_device_ir_transmit = ffi.Int32 Function( + ffi.Int32 carrier_frequency, + ffi.Pointer pattern, + ffi.Int32 size, +); + +typedef _dart_device_ir_transmit = int Function( + int carrier_frequency, + ffi.Pointer pattern, + int size, +); + +typedef _c_dlog_print = ffi.Int32 Function( + ffi.Int32 prio, + ffi.Pointer tag, + ffi.Pointer fmt, +); + +typedef _dart_dlog_print = int Function( + int prio, + ffi.Pointer tag, + ffi.Pointer fmt, +); + +typedef _c_dlog_vprint = ffi.Int32 Function( + ffi.Int32 prio, + ffi.Pointer tag, + ffi.Pointer fmt, + ffi.Pointer ap, +); + +typedef _dart_dlog_vprint = int Function( + int prio, + ffi.Pointer tag, + ffi.Pointer fmt, + ffi.Pointer ap, +); + +typedef _c_feedback_initialize = ffi.Int32 Function(); + +typedef _dart_feedback_initialize = int Function(); + +typedef _c_feedback_deinitialize = ffi.Int32 Function(); + +typedef _dart_feedback_deinitialize = int Function(); + +typedef _c_feedback_play = ffi.Int32 Function( + ffi.Int32 pattern, +); + +typedef _dart_feedback_play = int Function( + int pattern, +); + +typedef _c_feedback_play_type = ffi.Int32 Function( + ffi.Int32 type, + ffi.Int32 pattern, +); + +typedef _dart_feedback_play_type = int Function( + int type, + int pattern, +); + +typedef _c_feedback_stop = ffi.Int32 Function(); + +typedef _dart_feedback_stop = int Function(); + +typedef _c_feedback_is_supported_pattern = ffi.Int32 Function( + ffi.Int32 type, + ffi.Int32 pattern, + ffi.Pointer status, +); + +typedef _dart_feedback_is_supported_pattern = int Function( + int type, + int pattern, + ffi.Pointer status, +); + +typedef media_key_event_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_media_key_reserve = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_media_key_reserve = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_media_key_release = ffi.Int32 Function(); + +typedef _dart_media_key_release = int Function(); + +typedef _c_runtime_info_get_value_int = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer value, +); + +typedef _dart_runtime_info_get_value_int = int Function( + int key, + ffi.Pointer value, +); + +typedef _c_runtime_info_get_value_bool = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer value, +); + +typedef _dart_runtime_info_get_value_bool = int Function( + int key, + ffi.Pointer value, +); + +typedef _c_runtime_info_get_value_double = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer value, +); + +typedef _dart_runtime_info_get_value_double = int Function( + int key, + ffi.Pointer value, +); + +typedef _c_runtime_info_get_value_string = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer> value, +); + +typedef _dart_runtime_info_get_value_string = int Function( + int key, + ffi.Pointer> value, +); + +typedef runtime_info_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_runtime_info_set_changed_cb = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_runtime_info_set_changed_cb = int Function( + int key, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_runtime_info_unset_changed_cb = ffi.Int32 Function( + ffi.Int32 key, +); + +typedef _dart_runtime_info_unset_changed_cb = int Function( + int key, +); + +typedef _c_runtime_info_get_system_memory_info = ffi.Int32 Function( + ffi.Pointer info, +); + +typedef _dart_runtime_info_get_system_memory_info = int Function( + ffi.Pointer info, +); + +typedef _c_runtime_info_get_process_memory_info = ffi.Int32 Function( + ffi.Pointer pid, + ffi.Int32 size, + ffi.Pointer> info, +); + +typedef _dart_runtime_info_get_process_memory_info = int Function( + ffi.Pointer pid, + int size, + ffi.Pointer> info, +); + +typedef _c_runtime_info_get_cpu_usage = ffi.Int32 Function( + ffi.Pointer usage, +); + +typedef _dart_runtime_info_get_cpu_usage = int Function( + ffi.Pointer usage, +); + +typedef _c_runtime_info_get_process_cpu_usage = ffi.Int32 Function( + ffi.Pointer pid, + ffi.Int32 size, + ffi.Pointer> usage, +); + +typedef _dart_runtime_info_get_process_cpu_usage = int Function( + ffi.Pointer pid, + int size, + ffi.Pointer> usage, +); + +typedef _c_runtime_info_get_processor_count = ffi.Int32 Function( + ffi.Pointer num_core, +); + +typedef _dart_runtime_info_get_processor_count = int Function( + ffi.Pointer num_core, +); + +typedef _c_runtime_info_get_processor_current_frequency = ffi.Int32 Function( + ffi.Int32 core_idx, + ffi.Pointer cpu_freq, +); + +typedef _dart_runtime_info_get_processor_current_frequency = int Function( + int core_idx, + ffi.Pointer cpu_freq, +); + +typedef _c_runtime_info_get_processor_max_frequency = ffi.Int32 Function( + ffi.Int32 core_idx, + ffi.Pointer cpu_freq, +); + +typedef _dart_runtime_info_get_processor_max_frequency = int Function( + int core_idx, + ffi.Pointer cpu_freq, +); + +typedef _c_runtime_info_get_physical_memory_size = ffi.Int32 Function( + ffi.Pointer size, +); + +typedef _dart_runtime_info_get_physical_memory_size = int Function( + ffi.Pointer size, +); + +typedef _c_runtime_info_app_usage_destroy = ffi.Int32 Function( + ffi.Pointer handle, +); + +typedef _dart_runtime_info_app_usage_destroy = int Function( + ffi.Pointer handle, +); + +typedef _c_runtime_info_app_usage_get_count = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer count, +); + +typedef _dart_runtime_info_app_usage_get_count = int Function( + ffi.Pointer handle, + ffi.Pointer count, +); + +typedef _c_runtime_info_app_usage_get_appid = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 index, + ffi.Pointer> appid, +); + +typedef _dart_runtime_info_app_usage_get_appid = int Function( + ffi.Pointer handle, + int index, + ffi.Pointer> appid, +); + +typedef _c_runtime_info_app_usage_get_usage = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 index, + ffi.Pointer usage, +); + +typedef _dart_runtime_info_app_usage_get_usage = int Function( + ffi.Pointer handle, + int index, + ffi.Pointer usage, +); + +typedef _c_runtime_info_get_all_apps_memory_usage = ffi.Int32 Function( + ffi.Pointer> usage, +); + +typedef _dart_runtime_info_get_all_apps_memory_usage = int Function( + ffi.Pointer> usage, +); + +typedef _c_runtime_info_get_all_apps_cpu_rate = ffi.Int32 Function( + ffi.Pointer> rate, +); + +typedef _dart_runtime_info_get_all_apps_cpu_rate = int Function( + ffi.Pointer> rate, +); + +typedef _c_sensor_is_supported = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer supported, +); + +typedef _dart_sensor_is_supported = int Function( + int type, + ffi.Pointer supported, +); + +typedef _c_sensor_is_supported_by_uri = ffi.Int32 Function( + ffi.Pointer uri, + ffi.Pointer supported, +); + +typedef _dart_sensor_is_supported_by_uri = int Function( + ffi.Pointer uri, + ffi.Pointer supported, +); + +typedef _c_sensor_is_wake_up = ffi.Int32 Function( + ffi.Pointer sensor, + ffi.Pointer wakeup, +); + +typedef _dart_sensor_is_wake_up = int Function( + ffi.Pointer sensor, + ffi.Pointer wakeup, +); + +typedef _c_sensor_get_default_sensor = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer> sensor, +); + +typedef _dart_sensor_get_default_sensor = int Function( + int type, + ffi.Pointer> sensor, +); + +typedef _c_sensor_get_default_sensor_by_uri = ffi.Int32 Function( + ffi.Pointer uri, + ffi.Pointer> sensor, +); + +typedef _dart_sensor_get_default_sensor_by_uri = int Function( + ffi.Pointer uri, + ffi.Pointer> sensor, +); + +typedef _c_sensor_get_sensor_list = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer>> list, + ffi.Pointer sensor_count, +); + +typedef _dart_sensor_get_sensor_list = int Function( + int type, + ffi.Pointer>> list, + ffi.Pointer sensor_count, +); + +typedef _c_sensor_get_sensor_list_by_uri = ffi.Int32 Function( + ffi.Pointer uri, + ffi.Pointer>> list, + ffi.Pointer sensor_count, +); + +typedef _dart_sensor_get_sensor_list_by_uri = int Function( + ffi.Pointer uri, + ffi.Pointer>> list, + ffi.Pointer sensor_count, +); + +typedef _c_sensor_get_uri = ffi.Int32 Function( + ffi.Pointer sensor, + ffi.Pointer> uri, +); + +typedef _dart_sensor_get_uri = int Function( + ffi.Pointer sensor, + ffi.Pointer> uri, +); + +typedef _c_sensor_get_name = ffi.Int32 Function( + ffi.Pointer sensor, + ffi.Pointer> name, +); + +typedef _dart_sensor_get_name = int Function( + ffi.Pointer sensor, + ffi.Pointer> name, +); + +typedef _c_sensor_get_vendor = ffi.Int32 Function( + ffi.Pointer sensor, + ffi.Pointer> vendor, +); + +typedef _dart_sensor_get_vendor = int Function( + ffi.Pointer sensor, + ffi.Pointer> vendor, +); + +typedef _c_sensor_get_type = ffi.Int32 Function( + ffi.Pointer sensor, + ffi.Pointer type, +); + +typedef _dart_sensor_get_type = int Function( + ffi.Pointer sensor, + ffi.Pointer type, +); + +typedef _c_sensor_get_min_range = ffi.Int32 Function( + ffi.Pointer sensor, + ffi.Pointer min_range, +); + +typedef _dart_sensor_get_min_range = int Function( + ffi.Pointer sensor, + ffi.Pointer min_range, +); + +typedef _c_sensor_get_max_range = ffi.Int32 Function( + ffi.Pointer sensor, + ffi.Pointer max_range, +); + +typedef _dart_sensor_get_max_range = int Function( + ffi.Pointer sensor, + ffi.Pointer max_range, +); + +typedef _c_sensor_get_resolution = ffi.Int32 Function( + ffi.Pointer sensor, + ffi.Pointer resolution, +); + +typedef _dart_sensor_get_resolution = int Function( + ffi.Pointer sensor, + ffi.Pointer resolution, +); + +typedef _c_sensor_get_min_interval = ffi.Int32 Function( + ffi.Pointer sensor, + ffi.Pointer min_interval, +); + +typedef _dart_sensor_get_min_interval = int Function( + ffi.Pointer sensor, + ffi.Pointer min_interval, +); + +typedef _c_sensor_get_fifo_count = ffi.Int32 Function( + ffi.Pointer sensor, + ffi.Pointer fifo_count, +); + +typedef _dart_sensor_get_fifo_count = int Function( + ffi.Pointer sensor, + ffi.Pointer fifo_count, +); + +typedef _c_sensor_get_max_batch_count = ffi.Int32 Function( + ffi.Pointer sensor, + ffi.Pointer max_batch_count, +); + +typedef _dart_sensor_get_max_batch_count = int Function( + ffi.Pointer sensor, + ffi.Pointer max_batch_count, +); + +typedef sensor_added_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_sensor_add_sensor_added_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_sensor_add_sensor_added_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_sensor_remove_sensor_added_cb = ffi.Int32 Function( + ffi.Pointer> callback, +); + +typedef _dart_sensor_remove_sensor_added_cb = int Function( + ffi.Pointer> callback, +); + +typedef sensor_removed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_sensor_add_sensor_removed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_sensor_add_sensor_removed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_sensor_remove_sensor_removed_cb = ffi.Int32 Function( + ffi.Pointer> callback, +); + +typedef _dart_sensor_remove_sensor_removed_cb = int Function( + ffi.Pointer> callback, +); + +typedef _c_sensor_create_listener = ffi.Int32 Function( + ffi.Pointer sensor, + ffi.Pointer> listener, +); + +typedef _dart_sensor_create_listener = int Function( + ffi.Pointer sensor, + ffi.Pointer> listener, +); + +typedef _c_sensor_destroy_listener = ffi.Int32 Function( + ffi.Pointer listener, +); + +typedef _dart_sensor_destroy_listener = int Function( + ffi.Pointer listener, +); + +typedef _c_sensor_listener_start = ffi.Int32 Function( + ffi.Pointer listener, +); + +typedef _dart_sensor_listener_start = int Function( + ffi.Pointer listener, +); + +typedef _c_sensor_listener_stop = ffi.Int32 Function( + ffi.Pointer listener, +); + +typedef _dart_sensor_listener_stop = int Function( + ffi.Pointer listener, +); + +typedef sensor_event_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_sensor_listener_set_event_cb = ffi.Int32 Function( + ffi.Pointer listener, + ffi.Uint32 interval_ms, + ffi.Pointer> callback, + ffi.Pointer data, +); + +typedef _dart_sensor_listener_set_event_cb = int Function( + ffi.Pointer listener, + int interval_ms, + ffi.Pointer> callback, + ffi.Pointer data, +); + +typedef _c_sensor_listener_unset_event_cb = ffi.Int32 Function( + ffi.Pointer listener, +); + +typedef _dart_sensor_listener_unset_event_cb = int Function( + ffi.Pointer listener, +); + +typedef sensor_accuracy_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Uint64, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_sensor_listener_set_accuracy_cb = ffi.Int32 Function( + ffi.Pointer listener, + ffi.Pointer> callback, + ffi.Pointer data, +); + +typedef _dart_sensor_listener_set_accuracy_cb = int Function( + ffi.Pointer listener, + ffi.Pointer> callback, + ffi.Pointer data, +); + +typedef _c_sensor_listener_unset_accuracy_cb = ffi.Int32 Function( + ffi.Pointer listener, +); + +typedef _dart_sensor_listener_unset_accuracy_cb = int Function( + ffi.Pointer listener, +); + +typedef _c_sensor_listener_read_data = ffi.Int32 Function( + ffi.Pointer listener, + ffi.Pointer event, +); + +typedef _dart_sensor_listener_read_data = int Function( + ffi.Pointer listener, + ffi.Pointer event, +); + +typedef _c_sensor_listener_set_interval = ffi.Int32 Function( + ffi.Pointer listener, + ffi.Uint32 interval_ms, +); + +typedef _dart_sensor_listener_set_interval = int Function( + ffi.Pointer listener, + int interval_ms, +); + +typedef _c_sensor_listener_set_max_batch_latency = ffi.Int32 Function( + ffi.Pointer listener, + ffi.Uint32 max_batch_latency, +); + +typedef _dart_sensor_listener_set_max_batch_latency = int Function( + ffi.Pointer listener, + int max_batch_latency, +); + +typedef _c_sensor_listener_set_attribute_int = ffi.Int32 Function( + ffi.Pointer listener, + ffi.Int32 attribute, + ffi.Int32 value, +); + +typedef _dart_sensor_listener_set_attribute_int = int Function( + ffi.Pointer listener, + int attribute, + int value, +); + +typedef _c_sensor_listener_set_option = ffi.Int32 Function( + ffi.Pointer listener, + ffi.Int32 option, +); + +typedef _dart_sensor_listener_set_option = int Function( + ffi.Pointer listener, + int option, +); + +typedef _c_sensor_create_provider = ffi.Int32 Function( + ffi.Pointer uri, + ffi.Pointer> provider, +); + +typedef _dart_sensor_create_provider = int Function( + ffi.Pointer uri, + ffi.Pointer> provider, +); + +typedef _c_sensor_add_provider = ffi.Int32 Function( + ffi.Pointer<_sensor_provider_s> provider, +); + +typedef _dart_sensor_add_provider = int Function( + ffi.Pointer<_sensor_provider_s> provider, +); + +typedef _c_sensor_remove_provider = ffi.Int32 Function( + ffi.Pointer<_sensor_provider_s> provider, +); + +typedef _dart_sensor_remove_provider = int Function( + ffi.Pointer<_sensor_provider_s> provider, +); + +typedef _c_sensor_destroy_provider = ffi.Int32 Function( + ffi.Pointer<_sensor_provider_s> provider, +); + +typedef _dart_sensor_destroy_provider = int Function( + ffi.Pointer<_sensor_provider_s> provider, +); + +typedef _c_sensor_provider_set_name = ffi.Int32 Function( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer name, +); + +typedef _dart_sensor_provider_set_name = int Function( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer name, +); + +typedef _c_sensor_provider_set_vendor = ffi.Int32 Function( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer vendor, +); + +typedef _dart_sensor_provider_set_vendor = int Function( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer vendor, +); + +typedef _c_sensor_provider_set_range = ffi.Int32 Function( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Float min_range, + ffi.Float max_range, +); + +typedef _dart_sensor_provider_set_range = int Function( + ffi.Pointer<_sensor_provider_s> provider, + double min_range, + double max_range, +); + +typedef _c_sensor_provider_set_resolution = ffi.Int32 Function( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Float resolution, +); + +typedef _dart_sensor_provider_set_resolution = int Function( + ffi.Pointer<_sensor_provider_s> provider, + double resolution, +); + +typedef sensor_provider_start_cb = ffi.Void Function( + ffi.Pointer<_sensor_provider_s>, + ffi.Pointer, +); + +typedef _c_sensor_provider_set_start_cb = ffi.Int32 Function( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_sensor_provider_set_start_cb = int Function( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef sensor_provider_stop_cb = ffi.Void Function( + ffi.Pointer<_sensor_provider_s>, + ffi.Pointer, +); + +typedef _c_sensor_provider_set_stop_cb = ffi.Int32 Function( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_sensor_provider_set_stop_cb = int Function( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef sensor_provider_interval_changed_cb = ffi.Void Function( + ffi.Pointer<_sensor_provider_s>, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_sensor_provider_set_interval_changed_cb = ffi.Int32 Function( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_sensor_provider_set_interval_changed_cb = int Function( + ffi.Pointer<_sensor_provider_s> provider, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_sensor_provider_publish = ffi.Int32 Function( + ffi.Pointer<_sensor_provider_s> provider, + sensor_event_s event, +); + +typedef _dart_sensor_provider_publish = int Function( + ffi.Pointer<_sensor_provider_s> provider, + sensor_event_s event, +); + +typedef _c_sensor_recorder_is_supported = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer supported, +); + +typedef _dart_sensor_recorder_is_supported = int Function( + int type, + ffi.Pointer supported, +); + +typedef _c_sensor_recorder_start = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer option, +); + +typedef _dart_sensor_recorder_start = int Function( + int type, + ffi.Pointer option, +); + +typedef _c_sensor_recorder_stop = ffi.Int32 Function( + ffi.Int32 type, +); + +typedef _dart_sensor_recorder_stop = int Function( + int type, +); + +typedef _c_sensor_recorder_create_option = ffi.Int32 Function( + ffi.Pointer> option, +); + +typedef _dart_sensor_recorder_create_option = int Function( + ffi.Pointer> option, +); + +typedef _c_sensor_recorder_destroy_option = ffi.Int32 Function( + ffi.Pointer option, +); + +typedef _dart_sensor_recorder_destroy_option = int Function( + ffi.Pointer option, +); + +typedef _c_sensor_recorder_option_set_int = ffi.Int32 Function( + ffi.Pointer option, + ffi.Int32 param, + ffi.Int32 value, +); + +typedef _dart_sensor_recorder_option_set_int = int Function( + ffi.Pointer option, + int param, + int value, +); + +typedef _c_sensor_recorder_create_query = ffi.Int32 Function( + ffi.Pointer> query, +); + +typedef _dart_sensor_recorder_create_query = int Function( + ffi.Pointer> query, +); + +typedef _c_sensor_recorder_destroy_query = ffi.Int32 Function( + ffi.Pointer query, +); + +typedef _dart_sensor_recorder_destroy_query = int Function( + ffi.Pointer query, +); + +typedef _c_sensor_recorder_query_set_int = ffi.Int32 Function( + ffi.Pointer query, + ffi.Int32 param, + ffi.Int32 value, +); + +typedef _dart_sensor_recorder_query_set_int = int Function( + ffi.Pointer query, + int param, + int value, +); + +typedef _c_sensor_recorder_query_set_time = ffi.Int32 Function( + ffi.Pointer query, + ffi.Int32 param, + ffi.Int64 t, +); + +typedef _dart_sensor_recorder_query_set_time = int Function( + ffi.Pointer query, + int param, + int t, +); + +typedef sensor_recorder_data_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_sensor_recorder_read = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_sensor_recorder_read = int Function( + int type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_sensor_recorder_read_sync = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_sensor_recorder_read_sync = int Function( + int type, + ffi.Pointer query, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_sensor_recorder_data_get_time = ffi.Int32 Function( + ffi.Pointer data, + ffi.Pointer start_time, + ffi.Pointer end_time, +); + +typedef _dart_sensor_recorder_data_get_time = int Function( + ffi.Pointer data, + ffi.Pointer start_time, + ffi.Pointer end_time, +); + +typedef _c_sensor_recorder_data_get_int = ffi.Int32 Function( + ffi.Pointer data, + ffi.Int32 key, + ffi.Pointer value, +); + +typedef _dart_sensor_recorder_data_get_int = int Function( + ffi.Pointer data, + int key, + ffi.Pointer value, +); + +typedef _c_sensor_recorder_data_get_double = ffi.Int32 Function( + ffi.Pointer data, + ffi.Int32 key, + ffi.Pointer value, +); + +typedef _dart_sensor_recorder_data_get_double = int Function( + ffi.Pointer data, + int key, + ffi.Pointer value, +); + +typedef _c_sensor_util_get_rotation_matrix = ffi.Int32 Function( + ffi.Float Gx, + ffi.Float Gy, + ffi.Float Gz, + ffi.Float Mx, + ffi.Float My, + ffi.Float Mz, + ffi.Pointer R, + ffi.Pointer I, +); + +typedef _dart_sensor_util_get_rotation_matrix = int Function( + double Gx, + double Gy, + double Gz, + double Mx, + double My, + double Mz, + ffi.Pointer R, + ffi.Pointer I, +); + +typedef _c_sensor_util_get_rotation_matrix_from_vector = ffi.Int32 Function( + ffi.Float Vx, + ffi.Float Vy, + ffi.Float Vz, + ffi.Pointer R, +); + +typedef _dart_sensor_util_get_rotation_matrix_from_vector = int Function( + double Vx, + double Vy, + double Vz, + ffi.Pointer R, +); + +typedef _c_sensor_util_remap_coordinate_system = ffi.Int32 Function( + ffi.Pointer inR, + ffi.Int32 x, + ffi.Int32 y, + ffi.Pointer outR, +); + +typedef _dart_sensor_util_remap_coordinate_system = int Function( + ffi.Pointer inR, + int x, + int y, + ffi.Pointer outR, +); + +typedef _c_sensor_util_get_inclination = ffi.Int32 Function( + ffi.Pointer I, + ffi.Pointer inclination, +); + +typedef _dart_sensor_util_get_inclination = int Function( + ffi.Pointer I, + ffi.Pointer inclination, +); + +typedef _c_sensor_util_get_orientation = ffi.Int32 Function( + ffi.Pointer R, + ffi.Pointer values, +); + +typedef _dart_sensor_util_get_orientation = int Function( + ffi.Pointer R, + ffi.Pointer values, +); + +typedef _c_sensor_util_get_angle_change = ffi.Int32 Function( + ffi.Pointer R, + ffi.Pointer prevR, + ffi.Pointer angleChange, +); + +typedef _dart_sensor_util_get_angle_change = int Function( + ffi.Pointer R, + ffi.Pointer prevR, + ffi.Pointer angleChange, +); + +typedef _c_sensor_util_get_declination = ffi.Int32 Function( + ffi.Float latitude, + ffi.Float longitude, + ffi.Float altitude, + ffi.Pointer declination, +); + +typedef _dart_sensor_util_get_declination = int Function( + double latitude, + double longitude, + double altitude, + ffi.Pointer declination, +); + +typedef _c_sensor_util_get_altitude = ffi.Int32 Function( + ffi.Float pressure, + ffi.Float sea_level_pressure, + ffi.Float temperature, + ffi.Pointer altitude, +); + +typedef _dart_sensor_util_get_altitude = int Function( + double pressure, + double sea_level_pressure, + double temperature, + ffi.Pointer altitude, +); + +typedef storage_device_supported_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_storage_foreach_device_supported = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_storage_foreach_device_supported = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_storage_get_root_directory = ffi.Int32 Function( + ffi.Int32 storage_id, + ffi.Pointer> path, +); + +typedef _dart_storage_get_root_directory = int Function( + int storage_id, + ffi.Pointer> path, +); + +typedef _c_storage_get_directory = ffi.Int32 Function( + ffi.Int32 storage_id, + ffi.Int32 type, + ffi.Pointer> path, +); + +typedef _dart_storage_get_directory = int Function( + int storage_id, + int type, + ffi.Pointer> path, +); + +typedef _c_storage_get_type = ffi.Int32 Function( + ffi.Int32 storage_id, + ffi.Pointer type, +); + +typedef _dart_storage_get_type = int Function( + int storage_id, + ffi.Pointer type, +); + +typedef _c_storage_get_state = ffi.Int32 Function( + ffi.Int32 storage_id, + ffi.Pointer state, +); + +typedef _dart_storage_get_state = int Function( + int storage_id, + ffi.Pointer state, +); + +typedef storage_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_storage_set_state_changed_cb = ffi.Int32 Function( + ffi.Int32 storage_id, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_storage_set_state_changed_cb = int Function( + int storage_id, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_storage_unset_state_changed_cb = ffi.Int32 Function( + ffi.Int32 storage_id, + ffi.Pointer> callback, +); + +typedef _dart_storage_unset_state_changed_cb = int Function( + int storage_id, + ffi.Pointer> callback, +); + +typedef storage_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Uint8, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_storage_set_changed_cb = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_storage_set_changed_cb = int Function( + int type, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_storage_unset_changed_cb = ffi.Int32 Function( + ffi.Int32 type, + ffi.Pointer> callback, +); + +typedef _dart_storage_unset_changed_cb = int Function( + int type, + ffi.Pointer> callback, +); + +typedef _c_storage_get_total_space = ffi.Int32 Function( + ffi.Int32 storage_id, + ffi.Pointer bytes, +); + +typedef _dart_storage_get_total_space = int Function( + int storage_id, + ffi.Pointer bytes, +); + +typedef _c_storage_get_available_space = ffi.Int32 Function( + ffi.Int32 storage_id, + ffi.Pointer bytes, +); + +typedef _dart_storage_get_available_space = int Function( + int storage_id, + ffi.Pointer bytes, +); + +typedef _c_storage_get_internal_memory_size = ffi.Int32 Function( + ffi.Pointer buf, +); + +typedef _dart_storage_get_internal_memory_size = int Function( + ffi.Pointer buf, +); + +typedef _c_storage_get_external_memory_size = ffi.Int32 Function( + ffi.Pointer buf, +); + +typedef _dart_storage_get_external_memory_size = int Function( + ffi.Pointer buf, +); + +typedef _c_system_info_get_platform_bool = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_system_info_get_platform_bool = int Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_system_info_get_platform_int = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_system_info_get_platform_int = int Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_system_info_get_platform_double = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_system_info_get_platform_double = int Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_system_info_get_platform_string = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer> value, +); + +typedef _dart_system_info_get_platform_string = int Function( + ffi.Pointer key, + ffi.Pointer> value, +); + +typedef _c_system_info_get_custom_bool = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_system_info_get_custom_bool = int Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_system_info_get_custom_int = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_system_info_get_custom_int = int Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_system_info_get_custom_double = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _dart_system_info_get_custom_double = int Function( + ffi.Pointer key, + ffi.Pointer value, +); + +typedef _c_system_info_get_custom_string = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer> value, +); + +typedef _dart_system_info_get_custom_string = int Function( + ffi.Pointer key, + ffi.Pointer> value, +); + +typedef _c_system_info_get_value_int = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer value, +); + +typedef _dart_system_info_get_value_int = int Function( + int key, + ffi.Pointer value, +); + +typedef _c_system_info_get_value_bool = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer value, +); + +typedef _dart_system_info_get_value_bool = int Function( + int key, + ffi.Pointer value, +); + +typedef _c_system_info_get_value_double = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer value, +); + +typedef _dart_system_info_get_value_double = int Function( + int key, + ffi.Pointer value, +); + +typedef _c_system_info_get_value_string = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer> value, +); + +typedef _dart_system_info_get_value_string = int Function( + int key, + ffi.Pointer> value, +); + +typedef _c_system_info_get_platform_type = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer type, +); + +typedef _dart_system_info_get_platform_type = int Function( + ffi.Pointer key, + ffi.Pointer type, +); + +typedef _c_system_info_get_custom_type = ffi.Int32 Function( + ffi.Pointer key, + ffi.Pointer type, +); + +typedef _dart_system_info_get_custom_type = int Function( + ffi.Pointer key, + ffi.Pointer type, +); + +typedef _c_system_settings_set_value_int = ffi.Int32 Function( + ffi.Int32 key, + ffi.Int32 value, +); + +typedef _dart_system_settings_set_value_int = int Function( + int key, + int value, +); + +typedef _c_system_settings_get_value_int = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer value, +); + +typedef _dart_system_settings_get_value_int = int Function( + int key, + ffi.Pointer value, +); + +typedef _c_system_settings_set_value_bool = ffi.Int32 Function( + ffi.Int32 key, + ffi.Uint8 value, +); + +typedef _dart_system_settings_set_value_bool = int Function( + int key, + int value, +); + +typedef _c_system_settings_get_value_bool = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer value, +); + +typedef _dart_system_settings_get_value_bool = int Function( + int key, + ffi.Pointer value, +); + +typedef _c_system_settings_set_value_string = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer value, +); + +typedef _dart_system_settings_set_value_string = int Function( + int key, + ffi.Pointer value, +); + +typedef _c_system_settings_get_value_string = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer> value, +); + +typedef _dart_system_settings_get_value_string = int Function( + int key, + ffi.Pointer> value, +); + +typedef system_settings_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_system_settings_set_changed_cb = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_system_settings_set_changed_cb = int Function( + int key, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_system_settings_unset_changed_cb = ffi.Int32 Function( + ffi.Int32 key, +); + +typedef _dart_system_settings_unset_changed_cb = int Function( + int key, +); + +typedef system_settings_iter_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_system_settings_foreach_value_string = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_system_settings_foreach_value_string = int Function( + int key, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_system_settings_add_value_string = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer value, +); + +typedef _dart_system_settings_add_value_string = int Function( + int key, + ffi.Pointer value, +); + +typedef _c_system_settings_delete_value_string = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer value, +); + +typedef _dart_system_settings_delete_value_string = int Function( + int key, + ffi.Pointer value, +); + +typedef _c_system_settings_add_changed_cb = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_system_settings_add_changed_cb = int Function( + int key, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_system_settings_remove_changed_cb = ffi.Int32 Function( + ffi.Int32 key, + ffi.Pointer> callback, +); + +typedef _dart_system_settings_remove_changed_cb = int Function( + int key, + ffi.Pointer> callback, +); + +typedef _c_trace_begin = ffi.Void Function( + ffi.Pointer name, +); + +typedef _dart_trace_begin = void Function( + ffi.Pointer name, +); + +typedef _c_trace_end = ffi.Void Function(); + +typedef _dart_trace_end = void Function(); + +typedef _c_trace_async_begin = ffi.Void Function( + ffi.Int32 cookie, + ffi.Pointer name, +); + +typedef _dart_trace_async_begin = void Function( + int cookie, + ffi.Pointer name, +); + +typedef _c_trace_async_end = ffi.Void Function( + ffi.Int32 cookie, + ffi.Pointer name, +); + +typedef _dart_trace_async_end = void Function( + int cookie, + ffi.Pointer name, +); + +typedef _c_trace_update_counter = ffi.Void Function( + ffi.Int32 value, + ffi.Pointer name, +); + +typedef _dart_trace_update_counter = void Function( + int value, + ffi.Pointer name, +); + +typedef telephony_noti_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_telephony_set_noti_cb = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 noti_id, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _dart_telephony_set_noti_cb = int Function( + ffi.Pointer handle, + int noti_id, + ffi.Pointer> cb, + ffi.Pointer user_data, +); + +typedef _c_telephony_unset_noti_cb = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Int32 noti_id, +); + +typedef _dart_telephony_unset_noti_cb = int Function( + ffi.Pointer handle, + int noti_id, +); + +typedef _c_telephony_init = ffi.Int32 Function( + ffi.Pointer list, +); + +typedef _dart_telephony_init = int Function( + ffi.Pointer list, +); + +typedef _c_telephony_deinit = ffi.Int32 Function( + ffi.Pointer list, +); + +typedef _dart_telephony_deinit = int Function( + ffi.Pointer list, +); + +typedef _c_telephony_get_state = ffi.Int32 Function( + ffi.Pointer state, +); + +typedef _dart_telephony_get_state = int Function( + ffi.Pointer state, +); + +typedef telephony_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_telephony_set_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_telephony_set_state_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_telephony_unset_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, +); + +typedef _dart_telephony_unset_state_changed_cb = int Function( + ffi.Pointer> callback, +); + +typedef _c_telephony_call_get_voice_call_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer call_state, +); + +typedef _dart_telephony_call_get_voice_call_state = int Function( + ffi.Pointer handle, + ffi.Pointer call_state, +); + +typedef _c_telephony_call_get_video_call_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer call_state, +); + +typedef _dart_telephony_call_get_video_call_state = int Function( + ffi.Pointer handle, + ffi.Pointer call_state, +); + +typedef _c_telephony_call_get_preferred_voice_subscription = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer call_sub, +); + +typedef _dart_telephony_call_get_preferred_voice_subscription = int Function( + ffi.Pointer handle, + ffi.Pointer call_sub, +); + +typedef _c_telephony_call_get_call_list = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer count, + ffi.Pointer>> call_list, +); + +typedef _dart_telephony_call_get_call_list = int Function( + ffi.Pointer handle, + ffi.Pointer count, + ffi.Pointer>> call_list, +); + +typedef _c_telephony_call_release_call_list = ffi.Int32 Function( + ffi.Uint32 count, + ffi.Pointer>> call_list, +); + +typedef _dart_telephony_call_release_call_list = int Function( + int count, + ffi.Pointer>> call_list, +); + +typedef _c_telephony_call_get_handle_id = ffi.Int32 Function( + ffi.Pointer call_handle, + ffi.Pointer handle_id, +); + +typedef _dart_telephony_call_get_handle_id = int Function( + ffi.Pointer call_handle, + ffi.Pointer handle_id, +); + +typedef _c_telephony_call_get_number = ffi.Int32 Function( + ffi.Pointer call_handle, + ffi.Pointer> number, +); + +typedef _dart_telephony_call_get_number = int Function( + ffi.Pointer call_handle, + ffi.Pointer> number, +); + +typedef _c_telephony_call_get_type = ffi.Int32 Function( + ffi.Pointer call_handle, + ffi.Pointer type, +); + +typedef _dart_telephony_call_get_type = int Function( + ffi.Pointer call_handle, + ffi.Pointer type, +); + +typedef _c_telephony_call_get_status = ffi.Int32 Function( + ffi.Pointer call_handle, + ffi.Pointer status, +); + +typedef _dart_telephony_call_get_status = int Function( + ffi.Pointer call_handle, + ffi.Pointer status, +); + +typedef _c_telephony_call_get_direction = ffi.Int32 Function( + ffi.Pointer call_handle, + ffi.Pointer direction, +); + +typedef _dart_telephony_call_get_direction = int Function( + ffi.Pointer call_handle, + ffi.Pointer direction, +); + +typedef _c_telephony_call_get_conference_status = ffi.Int32 Function( + ffi.Pointer call_handle, + ffi.Pointer conference_status, +); + +typedef _dart_telephony_call_get_conference_status = int Function( + ffi.Pointer call_handle, + ffi.Pointer conference_status, +); + +typedef _c_telephony_sim_get_icc_id = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> icc_id, +); + +typedef _dart_telephony_sim_get_icc_id = int Function( + ffi.Pointer handle, + ffi.Pointer> icc_id, +); + +typedef _c_telephony_sim_get_operator = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> sim_operator, +); + +typedef _dart_telephony_sim_get_operator = int Function( + ffi.Pointer handle, + ffi.Pointer> sim_operator, +); + +typedef _c_telephony_sim_get_msin = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> msin, +); + +typedef _dart_telephony_sim_get_msin = int Function( + ffi.Pointer handle, + ffi.Pointer> msin, +); + +typedef _c_telephony_sim_get_spn = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> spn, +); + +typedef _dart_telephony_sim_get_spn = int Function( + ffi.Pointer handle, + ffi.Pointer> spn, +); + +typedef _c_telephony_sim_is_changed = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer is_changed, +); + +typedef _dart_telephony_sim_is_changed = int Function( + ffi.Pointer handle, + ffi.Pointer is_changed, +); + +typedef _c_telephony_sim_get_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer sim_state, +); + +typedef _dart_telephony_sim_get_state = int Function( + ffi.Pointer handle, + ffi.Pointer sim_state, +); + +typedef _c_telephony_sim_get_application_list = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer app_list, +); + +typedef _dart_telephony_sim_get_application_list = int Function( + ffi.Pointer handle, + ffi.Pointer app_list, +); + +typedef _c_telephony_sim_get_subscriber_number = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> subscriber_number, +); + +typedef _dart_telephony_sim_get_subscriber_number = int Function( + ffi.Pointer handle, + ffi.Pointer> subscriber_number, +); + +typedef _c_telephony_sim_get_subscriber_id = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> subscriber_id, +); + +typedef _dart_telephony_sim_get_subscriber_id = int Function( + ffi.Pointer handle, + ffi.Pointer> subscriber_id, +); + +typedef _c_telephony_sim_get_lock_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer lock_state, +); + +typedef _dart_telephony_sim_get_lock_state = int Function( + ffi.Pointer handle, + ffi.Pointer lock_state, +); + +typedef _c_telephony_sim_get_group_id1 = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> gid1, +); + +typedef _dart_telephony_sim_get_group_id1 = int Function( + ffi.Pointer handle, + ffi.Pointer> gid1, +); + +typedef _c_telephony_sim_get_call_forwarding_indicator_state = ffi.Int32 + Function( + ffi.Pointer handle, + ffi.Pointer state, +); + +typedef _dart_telephony_sim_get_call_forwarding_indicator_state = int Function( + ffi.Pointer handle, + ffi.Pointer state, +); + +typedef _c_telephony_network_get_lac = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer lac, +); + +typedef _dart_telephony_network_get_lac = int Function( + ffi.Pointer handle, + ffi.Pointer lac, +); + +typedef _c_telephony_network_get_cell_id = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer cell_id, +); + +typedef _dart_telephony_network_get_cell_id = int Function( + ffi.Pointer handle, + ffi.Pointer cell_id, +); + +typedef _c_telephony_network_get_rssi = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer rssi, +); + +typedef _dart_telephony_network_get_rssi = int Function( + ffi.Pointer handle, + ffi.Pointer rssi, +); + +typedef _c_telephony_network_get_roaming_status = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer status, +); + +typedef _dart_telephony_network_get_roaming_status = int Function( + ffi.Pointer handle, + ffi.Pointer status, +); + +typedef _c_telephony_network_get_mcc = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> mcc, +); + +typedef _dart_telephony_network_get_mcc = int Function( + ffi.Pointer handle, + ffi.Pointer> mcc, +); + +typedef _c_telephony_network_get_mnc = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> mnc, +); + +typedef _dart_telephony_network_get_mnc = int Function( + ffi.Pointer handle, + ffi.Pointer> mnc, +); + +typedef _c_telephony_network_get_network_name = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> network_name, +); + +typedef _dart_telephony_network_get_network_name = int Function( + ffi.Pointer handle, + ffi.Pointer> network_name, +); + +typedef _c_telephony_network_get_type = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer network_type, +); + +typedef _dart_telephony_network_get_type = int Function( + ffi.Pointer handle, + ffi.Pointer network_type, +); + +typedef _c_telephony_network_get_ps_type = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer ps_type, +); + +typedef _dart_telephony_network_get_ps_type = int Function( + ffi.Pointer handle, + ffi.Pointer ps_type, +); + +typedef _c_telephony_network_get_network_name_option = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer network_name_option, +); + +typedef _dart_telephony_network_get_network_name_option = int Function( + ffi.Pointer handle, + ffi.Pointer network_name_option, +); + +typedef _c_telephony_network_get_service_state = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer network_service_state, +); + +typedef _dart_telephony_network_get_service_state = int Function( + ffi.Pointer handle, + ffi.Pointer network_service_state, +); + +typedef _c_telephony_network_get_default_data_subscription = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer default_sub, +); + +typedef _dart_telephony_network_get_default_data_subscription = int Function( + ffi.Pointer handle, + ffi.Pointer default_sub, +); + +typedef _c_telephony_network_get_default_subscription = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer default_sub, +); + +typedef _dart_telephony_network_get_default_subscription = int Function( + ffi.Pointer handle, + ffi.Pointer default_sub, +); + +typedef _c_telephony_network_get_selection_mode = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer mode, +); + +typedef _dart_telephony_network_get_selection_mode = int Function( + ffi.Pointer handle, + ffi.Pointer mode, +); + +typedef _c_telephony_network_get_tac = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer tac, +); + +typedef _dart_telephony_network_get_tac = int Function( + ffi.Pointer handle, + ffi.Pointer tac, +); + +typedef _c_telephony_network_get_system_id = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer sid, +); + +typedef _dart_telephony_network_get_system_id = int Function( + ffi.Pointer handle, + ffi.Pointer sid, +); + +typedef _c_telephony_network_get_network_id = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer nid, +); + +typedef _dart_telephony_network_get_network_id = int Function( + ffi.Pointer handle, + ffi.Pointer nid, +); + +typedef _c_telephony_network_get_base_station_id = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer bs_id, +); + +typedef _dart_telephony_network_get_base_station_id = int Function( + ffi.Pointer handle, + ffi.Pointer bs_id, +); + +typedef _c_telephony_network_get_base_station_latitude = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer bs_latitude, +); + +typedef _dart_telephony_network_get_base_station_latitude = int Function( + ffi.Pointer handle, + ffi.Pointer bs_latitude, +); + +typedef _c_telephony_network_get_base_station_longitude = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer bs_longitude, +); + +typedef _dart_telephony_network_get_base_station_longitude = int Function( + ffi.Pointer handle, + ffi.Pointer bs_longitude, +); + +typedef _c_telephony_network_get_signal_strength = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer dbm, +); + +typedef _dart_telephony_network_get_signal_strength = int Function( + ffi.Pointer handle, + ffi.Pointer dbm, +); + +typedef _c_telephony_modem_get_imei = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> imei, +); + +typedef _dart_telephony_modem_get_imei = int Function( + ffi.Pointer handle, + ffi.Pointer> imei, +); + +typedef _c_telephony_modem_get_power_status = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer status, +); + +typedef _dart_telephony_modem_get_power_status = int Function( + ffi.Pointer handle, + ffi.Pointer status, +); + +typedef _c_telephony_modem_get_meid = ffi.Int32 Function( + ffi.Pointer handle, + ffi.Pointer> meid, +); + +typedef _dart_telephony_modem_get_meid = int Function( + ffi.Pointer handle, + ffi.Pointer> meid, +); + +typedef ime_process_input_device_event_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_ime_event_set_process_input_device_event_cb = ffi.Int32 Function( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_process_input_device_event_cb = int Function( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, +); + +typedef _c_ime_event_unset_process_input_device_event_cb = ffi.Int32 Function(); + +typedef _dart_ime_event_unset_process_input_device_event_cb = int Function(); + +typedef _c_ime_input_device_rotary_get_direction = ffi.Int32 Function( + ffi.Pointer event_handle, + ffi.Pointer direction, +); + +typedef _dart_ime_input_device_rotary_get_direction = int Function( + ffi.Pointer event_handle, + ffi.Pointer direction, +); + +typedef _c_ime_run = ffi.Int32 Function( + ffi.Pointer basic_cb, + ffi.Pointer user_data, +); + +typedef _dart_ime_run = int Function( + ffi.Pointer basic_cb, + ffi.Pointer user_data, +); + +typedef ime_focus_in_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_ime_event_set_focus_in_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_focus_in_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_focus_out_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_ime_event_set_focus_out_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_focus_out_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_surrounding_text_updated_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_ime_event_set_surrounding_text_updated_cb = ffi.Int32 Function( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_surrounding_text_updated_cb = int Function( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, +); + +typedef ime_input_context_reset_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef _c_ime_event_set_input_context_reset_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_input_context_reset_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_cursor_position_updated_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_ime_event_set_cursor_position_updated_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_cursor_position_updated_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_language_requested_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer>, +); + +typedef _c_ime_event_set_language_requested_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_language_requested_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_language_set_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_ime_event_set_language_set_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_language_set_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_imdata_set_cb = ffi.Void Function( + ffi.Pointer, + ffi.Uint32, + ffi.Pointer, +); + +typedef _c_ime_event_set_imdata_set_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_imdata_set_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_imdata_requested_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer>, + ffi.Pointer, +); + +typedef _c_ime_event_set_imdata_requested_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_imdata_requested_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_layout_set_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_ime_event_set_layout_set_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_layout_set_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_return_key_type_set_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_ime_event_set_return_key_type_set_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_return_key_type_set_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_return_key_state_set_cb = ffi.Void Function( + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_ime_event_set_return_key_state_set_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_return_key_state_set_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_geometry_requested_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_ime_event_set_geometry_requested_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_geometry_requested_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_process_key_event_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer<_ime_device_info>, + ffi.Pointer, +); + +typedef _c_ime_event_set_process_key_event_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_process_key_event_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_display_language_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_ime_event_set_display_language_changed_cb = ffi.Int32 Function( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_display_language_changed_cb = int Function( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, +); + +typedef ime_rotation_degree_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_ime_event_set_rotation_degree_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_rotation_degree_changed_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_accessibility_state_changed_cb = ffi.Void Function( + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_ime_event_set_accessibility_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_accessibility_state_changed_cb = int Function( + ffi.Pointer> + callback_func, + ffi.Pointer user_data, +); + +typedef ime_option_window_created_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_ime_event_set_option_window_created_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_option_window_created_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_option_window_destroyed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_ime_event_set_option_window_destroyed_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_option_window_destroyed_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _c_ime_send_key_event = ffi.Int32 Function( + ffi.Int32 keycode, + ffi.Int32 keymask, + ffi.Uint8 forward_key, +); + +typedef _dart_ime_send_key_event = int Function( + int keycode, + int keymask, + int forward_key, +); + +typedef _c_ime_commit_string = ffi.Int32 Function( + ffi.Pointer str, +); + +typedef _dart_ime_commit_string = int Function( + ffi.Pointer str, +); + +typedef _c_ime_show_preedit_string = ffi.Int32 Function(); + +typedef _dart_ime_show_preedit_string = int Function(); + +typedef _c_ime_hide_preedit_string = ffi.Int32 Function(); + +typedef _dart_ime_hide_preedit_string = int Function(); + +typedef _c_ime_update_preedit_string = ffi.Int32 Function( + ffi.Pointer str, + ffi.Pointer attrs, +); + +typedef _dart_ime_update_preedit_string = int Function( + ffi.Pointer str, + ffi.Pointer attrs, +); + +typedef _c_ime_request_surrounding_text = ffi.Int32 Function( + ffi.Int32 maxlen_before, + ffi.Int32 maxlen_after, +); + +typedef _dart_ime_request_surrounding_text = int Function( + int maxlen_before, + int maxlen_after, +); + +typedef _c_ime_delete_surrounding_text = ffi.Int32 Function( + ffi.Int32 offset, + ffi.Int32 len, +); + +typedef _dart_ime_delete_surrounding_text = int Function( + int offset, + int len, +); + +typedef _c_ime_get_surrounding_text = ffi.Int32 Function( + ffi.Int32 maxlen_before, + ffi.Int32 maxlen_after, + ffi.Pointer> text, + ffi.Pointer cursor_pos, +); + +typedef _dart_ime_get_surrounding_text = int Function( + int maxlen_before, + int maxlen_after, + ffi.Pointer> text, + ffi.Pointer cursor_pos, +); + +typedef _c_ime_set_selection = ffi.Int32 Function( + ffi.Int32 start, + ffi.Int32 end, +); + +typedef _dart_ime_set_selection = int Function( + int start, + int end, +); + +typedef _c_ime_get_selected_text = ffi.Int32 Function( + ffi.Pointer> text, +); + +typedef _dart_ime_get_selected_text = int Function( + ffi.Pointer> text, +); + +typedef _c_ime_get_main_window = ffi.Pointer Function(); + +typedef _dart_ime_get_main_window = ffi.Pointer Function(); + +typedef _c_ime_set_size = ffi.Int32 Function( + ffi.Int32 portrait_width, + ffi.Int32 portrait_height, + ffi.Int32 landscape_width, + ffi.Int32 landscape_height, +); + +typedef _dart_ime_set_size = int Function( + int portrait_width, + int portrait_height, + int landscape_width, + int landscape_height, +); + +typedef _c_ime_create_option_window = ffi.Int32 Function(); + +typedef _dart_ime_create_option_window = int Function(); + +typedef _c_ime_destroy_option_window = ffi.Int32 Function( + ffi.Pointer window, +); + +typedef _dart_ime_destroy_option_window = int Function( + ffi.Pointer window, +); + +typedef _c_ime_context_get_layout = ffi.Int32 Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer layout, +); + +typedef _dart_ime_context_get_layout = int Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer layout, +); + +typedef _c_ime_context_get_layout_variation = ffi.Int32 Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer layout_variation, +); + +typedef _dart_ime_context_get_layout_variation = int Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer layout_variation, +); + +typedef _c_ime_context_get_cursor_position = ffi.Int32 Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer cursor_pos, +); + +typedef _dart_ime_context_get_cursor_position = int Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer cursor_pos, +); + +typedef _c_ime_context_get_autocapital_type = ffi.Int32 Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer autocapital_type, +); + +typedef _dart_ime_context_get_autocapital_type = int Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer autocapital_type, +); + +typedef _c_ime_context_get_return_key_type = ffi.Int32 Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer return_key_type, +); + +typedef _dart_ime_context_get_return_key_type = int Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer return_key_type, +); + +typedef _c_ime_context_get_return_key_state = ffi.Int32 Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer return_key_state, +); + +typedef _dart_ime_context_get_return_key_state = int Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer return_key_state, +); + +typedef _c_ime_context_get_prediction_mode = ffi.Int32 Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer prediction_mode, +); + +typedef _dart_ime_context_get_prediction_mode = int Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer prediction_mode, +); + +typedef _c_ime_context_get_password_mode = ffi.Int32 Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer password_mode, +); + +typedef _dart_ime_context_get_password_mode = int Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer password_mode, +); + +typedef _c_ime_context_get_input_hint = ffi.Int32 Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer input_hint, +); + +typedef _dart_ime_context_get_input_hint = int Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer input_hint, +); + +typedef _c_ime_context_get_bidi_direction = ffi.Int32 Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer bidi, +); + +typedef _dart_ime_context_get_bidi_direction = int Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer bidi, +); + +typedef _c_ime_context_get_language = ffi.Int32 Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer language, +); + +typedef _dart_ime_context_get_language = int Function( + ffi.Pointer<_ime_context> context, + ffi.Pointer language, +); + +typedef _c_ime_device_info_get_name = ffi.Int32 Function( + ffi.Pointer<_ime_device_info> dev_info, + ffi.Pointer> dev_name, +); + +typedef _dart_ime_device_info_get_name = int Function( + ffi.Pointer<_ime_device_info> dev_info, + ffi.Pointer> dev_name, +); + +typedef _c_ime_device_info_get_class = ffi.Int32 Function( + ffi.Pointer<_ime_device_info> dev_info, + ffi.Pointer dev_class, +); + +typedef _dart_ime_device_info_get_class = int Function( + ffi.Pointer<_ime_device_info> dev_info, + ffi.Pointer dev_class, +); + +typedef _c_ime_device_info_get_subclass = ffi.Int32 Function( + ffi.Pointer<_ime_device_info> dev_info, + ffi.Pointer dev_subclass, +); + +typedef _dart_ime_device_info_get_subclass = int Function( + ffi.Pointer<_ime_device_info> dev_info, + ffi.Pointer dev_subclass, +); + +typedef ime_prediction_hint_set_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_ime_event_set_prediction_hint_set_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_prediction_hint_set_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef ime_mime_type_set_request_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_ime_event_set_mime_type_set_request_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _dart_ime_event_set_mime_type_set_request_cb = int Function( + ffi.Pointer> callback_func, + ffi.Pointer user_data, +); + +typedef _c_ime_send_private_command = ffi.Int32 Function( + ffi.Pointer command, +); + +typedef _dart_ime_send_private_command = int Function( + ffi.Pointer command, +); + +typedef _c_ime_commit_content = ffi.Int32 Function( + ffi.Pointer content, + ffi.Pointer description, + ffi.Pointer mime_type, +); + +typedef _dart_ime_commit_content = int Function( + ffi.Pointer content, + ffi.Pointer description, + ffi.Pointer mime_type, +); + +typedef _c_ime_set_floating_mode = ffi.Int32 Function( + ffi.Uint8 floating_mode, +); + +typedef _dart_ime_set_floating_mode = int Function( + int floating_mode, +); + +typedef _c_ime_set_floating_drag_start = ffi.Int32 Function(); + +typedef _dart_ime_set_floating_drag_start = int Function(); + +typedef _c_ime_set_floating_drag_end = ffi.Int32 Function(); + +typedef _dart_ime_set_floating_drag_end = int Function(); + +typedef _c_ime_manager_show_ime_list = ffi.Int32 Function(); + +typedef _dart_ime_manager_show_ime_list = int Function(); + +typedef _c_ime_manager_show_ime_selector = ffi.Int32 Function(); + +typedef _dart_ime_manager_show_ime_selector = int Function(); + +typedef _c_ime_manager_is_ime_enabled = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer enabled, +); + +typedef _dart_ime_manager_is_ime_enabled = int Function( + ffi.Pointer app_id, + ffi.Pointer enabled, +); + +typedef _c_ime_manager_get_active_ime = ffi.Int32 Function( + ffi.Pointer> app_id, +); + +typedef _dart_ime_manager_get_active_ime = int Function( + ffi.Pointer> app_id, +); + +typedef _c_ime_manager_get_enabled_ime_count = ffi.Int32 Function(); + +typedef _dart_ime_manager_get_enabled_ime_count = int Function(); + +typedef _c_stt_create = ffi.Int32 Function( + ffi.Pointer> stt, +); + +typedef _dart_stt_create = int Function( + ffi.Pointer> stt, +); + +typedef _c_stt_destroy = ffi.Int32 Function( + ffi.Pointer stt, +); + +typedef _dart_stt_destroy = int Function( + ffi.Pointer stt, +); + +typedef stt_supported_engine_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_stt_foreach_supported_engines = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_stt_foreach_supported_engines = int Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_stt_get_engine = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer> engine_id, +); + +typedef _dart_stt_get_engine = int Function( + ffi.Pointer stt, + ffi.Pointer> engine_id, +); + +typedef _c_stt_set_engine = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer engine_id, +); + +typedef _dart_stt_set_engine = int Function( + ffi.Pointer stt, + ffi.Pointer engine_id, +); + +typedef _c_stt_set_credential = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer credential, +); + +typedef _dart_stt_set_credential = int Function( + ffi.Pointer stt, + ffi.Pointer credential, +); + +typedef _c_stt_set_private_data = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer key, + ffi.Pointer data, +); + +typedef _dart_stt_set_private_data = int Function( + ffi.Pointer stt, + ffi.Pointer key, + ffi.Pointer data, +); + +typedef _c_stt_get_private_data = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer key, + ffi.Pointer> data, +); + +typedef _dart_stt_get_private_data = int Function( + ffi.Pointer stt, + ffi.Pointer key, + ffi.Pointer> data, +); + +typedef _c_stt_prepare = ffi.Int32 Function( + ffi.Pointer stt, +); + +typedef _dart_stt_prepare = int Function( + ffi.Pointer stt, +); + +typedef _c_stt_unprepare = ffi.Int32 Function( + ffi.Pointer stt, +); + +typedef _dart_stt_unprepare = int Function( + ffi.Pointer stt, +); + +typedef stt_supported_language_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_stt_foreach_supported_languages = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_stt_foreach_supported_languages = int Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_stt_get_default_language = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer> language, +); + +typedef _dart_stt_get_default_language = int Function( + ffi.Pointer stt, + ffi.Pointer> language, +); + +typedef _c_stt_get_state = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer state, +); + +typedef _dart_stt_get_state = int Function( + ffi.Pointer stt, + ffi.Pointer state, +); + +typedef _c_stt_get_error_message = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer> err_msg, +); + +typedef _dart_stt_get_error_message = int Function( + ffi.Pointer stt, + ffi.Pointer> err_msg, +); + +typedef _c_stt_is_recognition_type_supported = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer type, + ffi.Pointer support, +); + +typedef _dart_stt_is_recognition_type_supported = int Function( + ffi.Pointer stt, + ffi.Pointer type, + ffi.Pointer support, +); + +typedef _c_stt_set_silence_detection = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Int32 type, +); + +typedef _dart_stt_set_silence_detection = int Function( + ffi.Pointer stt, + int type, +); + +typedef _c_stt_set_start_sound = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer filename, +); + +typedef _dart_stt_set_start_sound = int Function( + ffi.Pointer stt, + ffi.Pointer filename, +); + +typedef _c_stt_unset_start_sound = ffi.Int32 Function( + ffi.Pointer stt, +); + +typedef _dart_stt_unset_start_sound = int Function( + ffi.Pointer stt, +); + +typedef _c_stt_set_stop_sound = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer filename, +); + +typedef _dart_stt_set_stop_sound = int Function( + ffi.Pointer stt, + ffi.Pointer filename, +); + +typedef _c_stt_unset_stop_sound = ffi.Int32 Function( + ffi.Pointer stt, +); + +typedef _dart_stt_unset_stop_sound = int Function( + ffi.Pointer stt, +); + +typedef _c_stt_start = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer language, + ffi.Pointer type, +); + +typedef _dart_stt_start = int Function( + ffi.Pointer stt, + ffi.Pointer language, + ffi.Pointer type, +); + +typedef _c_stt_stop = ffi.Int32 Function( + ffi.Pointer stt, +); + +typedef _dart_stt_stop = int Function( + ffi.Pointer stt, +); + +typedef _c_stt_cancel = ffi.Int32 Function( + ffi.Pointer stt, +); + +typedef _dart_stt_cancel = int Function( + ffi.Pointer stt, +); + +typedef _c_stt_get_recording_volume = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer volume, +); + +typedef _dart_stt_get_recording_volume = int Function( + ffi.Pointer stt, + ffi.Pointer volume, +); + +typedef stt_result_time_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Int64, + ffi.Int64, + ffi.Pointer, +); + +typedef _c_stt_foreach_detailed_result = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_stt_foreach_detailed_result = int Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef stt_recognition_result_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer>, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_stt_set_recognition_result_cb = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_stt_set_recognition_result_cb = int Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_stt_unset_recognition_result_cb = ffi.Int32 Function( + ffi.Pointer stt, +); + +typedef _dart_stt_unset_recognition_result_cb = int Function( + ffi.Pointer stt, +); + +typedef stt_state_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_stt_set_state_changed_cb = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_stt_set_state_changed_cb = int Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_stt_unset_state_changed_cb = ffi.Int32 Function( + ffi.Pointer stt, +); + +typedef _dart_stt_unset_state_changed_cb = int Function( + ffi.Pointer stt, +); + +typedef stt_error_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_stt_set_error_cb = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_stt_set_error_cb = int Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_stt_unset_error_cb = ffi.Int32 Function( + ffi.Pointer stt, +); + +typedef _dart_stt_unset_error_cb = int Function( + ffi.Pointer stt, +); + +typedef stt_default_language_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_stt_set_default_language_changed_cb = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_stt_set_default_language_changed_cb = int Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_stt_unset_default_language_changed_cb = ffi.Int32 Function( + ffi.Pointer stt, +); + +typedef _dart_stt_unset_default_language_changed_cb = int Function( + ffi.Pointer stt, +); + +typedef stt_engine_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Uint8, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_stt_set_engine_changed_cb = ffi.Int32 Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_stt_set_engine_changed_cb = int Function( + ffi.Pointer stt, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_stt_unset_engine_changed_cb = ffi.Int32 Function( + ffi.Pointer stt, +); + +typedef _dart_stt_unset_engine_changed_cb = int Function( + ffi.Pointer stt, +); + +typedef _c_stte_main = ffi.Int32 Function( + ffi.Int32 argc, + ffi.Pointer> argv, + ffi.Pointer callback, +); + +typedef _dart_stte_main = int Function( + int argc, + ffi.Pointer> argv, + ffi.Pointer callback, +); + +typedef _c_stte_send_result = ffi.Int32 Function( + ffi.Int32 event, + ffi.Pointer type, + ffi.Pointer> result, + ffi.Int32 result_count, + ffi.Pointer msg, + ffi.Pointer time_info, + ffi.Pointer user_data, +); + +typedef _dart_stte_send_result = int Function( + int event, + ffi.Pointer type, + ffi.Pointer> result, + int result_count, + ffi.Pointer msg, + ffi.Pointer time_info, + ffi.Pointer user_data, +); + +typedef _c_stte_send_error = ffi.Int32 Function( + ffi.Int32 error, + ffi.Pointer msg, +); + +typedef _dart_stte_send_error = int Function( + int error, + ffi.Pointer msg, +); + +typedef _c_stte_send_speech_status = ffi.Int32 Function( + ffi.Int32 status, + ffi.Pointer user_data, +); + +typedef _dart_stte_send_speech_status = int Function( + int status, + ffi.Pointer user_data, +); + +typedef stte_private_data_set_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_stte_set_private_data_set_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, +); + +typedef _dart_stte_set_private_data_set_cb = int Function( + ffi.Pointer> callback_func, +); + +typedef stte_private_data_requested_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Pointer>, +); + +typedef _c_stte_set_private_data_requested_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, +); + +typedef _dart_stte_set_private_data_requested_cb = int Function( + ffi.Pointer> callback_func, +); + +typedef _c_tts_create = ffi.Int32 Function( + ffi.Pointer> tts, +); + +typedef _dart_tts_create = int Function( + ffi.Pointer> tts, +); + +typedef _c_tts_destroy = ffi.Int32 Function( + ffi.Pointer tts, +); + +typedef _dart_tts_destroy = int Function( + ffi.Pointer tts, +); + +typedef _c_tts_set_mode = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Int32 mode, +); + +typedef _dart_tts_set_mode = int Function( + ffi.Pointer tts, + int mode, +); + +typedef _c_tts_get_mode = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer mode, +); + +typedef _dart_tts_get_mode = int Function( + ffi.Pointer tts, + ffi.Pointer mode, +); + +typedef _c_tts_set_credential = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer credential, +); + +typedef _dart_tts_set_credential = int Function( + ffi.Pointer tts, + ffi.Pointer credential, +); + +typedef _c_tts_prepare = ffi.Int32 Function( + ffi.Pointer tts, +); + +typedef _dart_tts_prepare = int Function( + ffi.Pointer tts, +); + +typedef _c_tts_unprepare = ffi.Int32 Function( + ffi.Pointer tts, +); + +typedef _dart_tts_unprepare = int Function( + ffi.Pointer tts, +); + +typedef tts_supported_voice_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_tts_foreach_supported_voices = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_tts_foreach_supported_voices = int Function( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_tts_get_default_voice = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer> language, + ffi.Pointer voice_type, +); + +typedef _dart_tts_get_default_voice = int Function( + ffi.Pointer tts, + ffi.Pointer> language, + ffi.Pointer voice_type, +); + +typedef _c_tts_set_private_data = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer key, + ffi.Pointer data, +); + +typedef _dart_tts_set_private_data = int Function( + ffi.Pointer tts, + ffi.Pointer key, + ffi.Pointer data, +); + +typedef _c_tts_get_private_data = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer key, + ffi.Pointer> data, +); + +typedef _dart_tts_get_private_data = int Function( + ffi.Pointer tts, + ffi.Pointer key, + ffi.Pointer> data, +); + +typedef _c_tts_get_max_text_size = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer size, +); + +typedef _dart_tts_get_max_text_size = int Function( + ffi.Pointer tts, + ffi.Pointer size, +); + +typedef _c_tts_get_state = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer state, +); + +typedef _dart_tts_get_state = int Function( + ffi.Pointer tts, + ffi.Pointer state, +); + +typedef _c_tts_get_speed_range = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer min, + ffi.Pointer normal, + ffi.Pointer max, +); + +typedef _dart_tts_get_speed_range = int Function( + ffi.Pointer tts, + ffi.Pointer min, + ffi.Pointer normal, + ffi.Pointer max, +); + +typedef _c_tts_get_error_message = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer> err_msg, +); + +typedef _dart_tts_get_error_message = int Function( + ffi.Pointer tts, + ffi.Pointer> err_msg, +); + +typedef _c_tts_add_text = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer text, + ffi.Pointer language, + ffi.Int32 voice_type, + ffi.Int32 speed, + ffi.Pointer utt_id, +); + +typedef _dart_tts_add_text = int Function( + ffi.Pointer tts, + ffi.Pointer text, + ffi.Pointer language, + int voice_type, + int speed, + ffi.Pointer utt_id, +); + +typedef _c_tts_play = ffi.Int32 Function( + ffi.Pointer tts, +); + +typedef _dart_tts_play = int Function( + ffi.Pointer tts, +); + +typedef _c_tts_stop = ffi.Int32 Function( + ffi.Pointer tts, +); + +typedef _dart_tts_stop = int Function( + ffi.Pointer tts, +); + +typedef _c_tts_pause = ffi.Int32 Function( + ffi.Pointer tts, +); + +typedef _dart_tts_pause = int Function( + ffi.Pointer tts, +); + +typedef tts_state_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_tts_set_state_changed_cb = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_tts_set_state_changed_cb = int Function( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_tts_unset_state_changed_cb = ffi.Int32 Function( + ffi.Pointer tts, +); + +typedef _dart_tts_unset_state_changed_cb = int Function( + ffi.Pointer tts, +); + +typedef tts_utterance_started_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_tts_set_utterance_started_cb = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_tts_set_utterance_started_cb = int Function( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_tts_unset_utterance_started_cb = ffi.Int32 Function( + ffi.Pointer tts, +); + +typedef _dart_tts_unset_utterance_started_cb = int Function( + ffi.Pointer tts, +); + +typedef tts_utterance_completed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_tts_set_utterance_completed_cb = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_tts_set_utterance_completed_cb = int Function( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_tts_unset_utterance_completed_cb = ffi.Int32 Function( + ffi.Pointer tts, +); + +typedef _dart_tts_unset_utterance_completed_cb = int Function( + ffi.Pointer tts, +); + +typedef tts_error_cb = ffi.Void Function( + ffi.Pointer, + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_tts_set_error_cb = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_tts_set_error_cb = int Function( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_tts_unset_error_cb = ffi.Int32 Function( + ffi.Pointer tts, +); + +typedef _dart_tts_unset_error_cb = int Function( + ffi.Pointer tts, +); + +typedef tts_default_voice_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_tts_set_default_voice_changed_cb = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_tts_set_default_voice_changed_cb = int Function( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_tts_unset_default_voice_changed_cb = ffi.Int32 Function( + ffi.Pointer tts, +); + +typedef _dart_tts_unset_default_voice_changed_cb = int Function( + ffi.Pointer tts, +); + +typedef tts_engine_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int32, + ffi.Uint8, + ffi.Pointer, +); + +typedef _c_tts_set_engine_changed_cb = ffi.Int32 Function( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_tts_set_engine_changed_cb = int Function( + ffi.Pointer tts, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_tts_unset_engine_changed_cb = ffi.Int32 Function( + ffi.Pointer tts, +); + +typedef _dart_tts_unset_engine_changed_cb = int Function( + ffi.Pointer tts, +); + +typedef _c_ttse_main = ffi.Int32 Function( + ffi.Int32 argc, + ffi.Pointer> argv, + ffi.Pointer callback, +); + +typedef _dart_ttse_main = int Function( + int argc, + ffi.Pointer> argv, + ffi.Pointer callback, +); + +typedef _c_ttse_get_speed_range = ffi.Int32 Function( + ffi.Pointer min, + ffi.Pointer normal, + ffi.Pointer max, +); + +typedef _dart_ttse_get_speed_range = int Function( + ffi.Pointer min, + ffi.Pointer normal, + ffi.Pointer max, +); + +typedef _c_ttse_get_pitch_range = ffi.Int32 Function( + ffi.Pointer min, + ffi.Pointer normal, + ffi.Pointer max, +); + +typedef _dart_ttse_get_pitch_range = int Function( + ffi.Pointer min, + ffi.Pointer normal, + ffi.Pointer max, +); + +typedef _c_ttse_send_result = ffi.Int32 Function( + ffi.Int32 event, + ffi.Pointer data, + ffi.Uint32 data_size, + ffi.Int32 audio_type, + ffi.Int32 rate, + ffi.Pointer user_data, +); + +typedef _dart_ttse_send_result = int Function( + int event, + ffi.Pointer data, + int data_size, + int audio_type, + int rate, + ffi.Pointer user_data, +); + +typedef _c_ttse_send_error = ffi.Int32 Function( + ffi.Int32 error, + ffi.Pointer msg, +); + +typedef _dart_ttse_send_error = int Function( + int error, + ffi.Pointer msg, +); + +typedef ttse_private_data_set_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_ttse_set_private_data_set_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, +); + +typedef _dart_ttse_set_private_data_set_cb = int Function( + ffi.Pointer> callback_func, +); + +typedef ttse_private_data_requested_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Pointer>, +); + +typedef _c_ttse_set_private_data_requested_cb = ffi.Int32 Function( + ffi.Pointer> callback_func, +); + +typedef _dart_ttse_set_private_data_requested_cb = int Function( + ffi.Pointer> callback_func, +); + +typedef _c_vc_cmd_list_create = ffi.Int32 Function( + ffi.Pointer> vc_cmd_list, +); + +typedef _dart_vc_cmd_list_create = int Function( + ffi.Pointer> vc_cmd_list, +); + +typedef _c_vc_cmd_list_destroy = ffi.Int32 Function( + ffi.Pointer vc_cmd_list, + ffi.Uint8 free_command, +); + +typedef _dart_vc_cmd_list_destroy = int Function( + ffi.Pointer vc_cmd_list, + int free_command, +); + +typedef _c_vc_cmd_list_get_count = ffi.Int32 Function( + ffi.Pointer vc_cmd_list, + ffi.Pointer count, +); + +typedef _dart_vc_cmd_list_get_count = int Function( + ffi.Pointer vc_cmd_list, + ffi.Pointer count, +); + +typedef _c_vc_cmd_list_add = ffi.Int32 Function( + ffi.Pointer vc_cmd_list, + ffi.Pointer vc_command, +); + +typedef _dart_vc_cmd_list_add = int Function( + ffi.Pointer vc_cmd_list, + ffi.Pointer vc_command, +); + +typedef _c_vc_cmd_list_remove = ffi.Int32 Function( + ffi.Pointer vc_cmd_list, + ffi.Pointer vc_command, +); + +typedef _dart_vc_cmd_list_remove = int Function( + ffi.Pointer vc_cmd_list, + ffi.Pointer vc_command, +); + +typedef vc_cmd_list_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_vc_cmd_list_foreach_commands = ffi.Int32 Function( + ffi.Pointer vc_cmd_list, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_vc_cmd_list_foreach_commands = int Function( + ffi.Pointer vc_cmd_list, + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_vc_cmd_list_first = ffi.Int32 Function( + ffi.Pointer vc_cmd_list, +); + +typedef _dart_vc_cmd_list_first = int Function( + ffi.Pointer vc_cmd_list, +); + +typedef _c_vc_cmd_list_last = ffi.Int32 Function( + ffi.Pointer vc_cmd_list, +); + +typedef _dart_vc_cmd_list_last = int Function( + ffi.Pointer vc_cmd_list, +); + +typedef _c_vc_cmd_list_next = ffi.Int32 Function( + ffi.Pointer vc_cmd_list, +); + +typedef _dart_vc_cmd_list_next = int Function( + ffi.Pointer vc_cmd_list, +); + +typedef _c_vc_cmd_list_prev = ffi.Int32 Function( + ffi.Pointer vc_cmd_list, +); + +typedef _dart_vc_cmd_list_prev = int Function( + ffi.Pointer vc_cmd_list, +); + +typedef _c_vc_cmd_list_get_current = ffi.Int32 Function( + ffi.Pointer vc_cmd_list, + ffi.Pointer> vc_command, +); + +typedef _dart_vc_cmd_list_get_current = int Function( + ffi.Pointer vc_cmd_list, + ffi.Pointer> vc_command, +); + +typedef _c_vc_cmd_create = ffi.Int32 Function( + ffi.Pointer> vc_command, +); + +typedef _dart_vc_cmd_create = int Function( + ffi.Pointer> vc_command, +); + +typedef _c_vc_cmd_destroy = ffi.Int32 Function( + ffi.Pointer vc_command, +); + +typedef _dart_vc_cmd_destroy = int Function( + ffi.Pointer vc_command, +); + +typedef _c_vc_cmd_set_command = ffi.Int32 Function( + ffi.Pointer vc_command, + ffi.Pointer command, +); + +typedef _dart_vc_cmd_set_command = int Function( + ffi.Pointer vc_command, + ffi.Pointer command, +); + +typedef _c_vc_cmd_get_command = ffi.Int32 Function( + ffi.Pointer vc_command, + ffi.Pointer> command, +); + +typedef _dart_vc_cmd_get_command = int Function( + ffi.Pointer vc_command, + ffi.Pointer> command, +); + +typedef _c_vc_cmd_get_unfixed_command = ffi.Int32 Function( + ffi.Pointer vc_command, + ffi.Pointer> command, +); + +typedef _dart_vc_cmd_get_unfixed_command = int Function( + ffi.Pointer vc_command, + ffi.Pointer> command, +); + +typedef _c_vc_cmd_set_type = ffi.Int32 Function( + ffi.Pointer vc_command, + ffi.Int32 type, +); + +typedef _dart_vc_cmd_set_type = int Function( + ffi.Pointer vc_command, + int type, +); + +typedef _c_vc_cmd_get_type = ffi.Int32 Function( + ffi.Pointer vc_command, + ffi.Pointer type, +); + +typedef _dart_vc_cmd_get_type = int Function( + ffi.Pointer vc_command, + ffi.Pointer type, +); + +typedef _c_vc_cmd_set_format = ffi.Int32 Function( + ffi.Pointer vc_command, + ffi.Int32 format, +); + +typedef _dart_vc_cmd_set_format = int Function( + ffi.Pointer vc_command, + int format, +); + +typedef _c_vc_cmd_get_format = ffi.Int32 Function( + ffi.Pointer vc_command, + ffi.Pointer format, +); + +typedef _dart_vc_cmd_get_format = int Function( + ffi.Pointer vc_command, + ffi.Pointer format, +); + +typedef _c_vc_initialize = ffi.Int32 Function(); + +typedef _dart_vc_initialize = int Function(); + +typedef _c_vc_deinitialize = ffi.Int32 Function(); + +typedef _dart_vc_deinitialize = int Function(); + +typedef _c_vc_prepare = ffi.Int32 Function(); + +typedef _dart_vc_prepare = int Function(); + +typedef _c_vc_unprepare = ffi.Int32 Function(); + +typedef _dart_vc_unprepare = int Function(); + +typedef vc_supported_language_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_vc_foreach_supported_languages = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_vc_foreach_supported_languages = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_vc_get_current_language = ffi.Int32 Function( + ffi.Pointer> language, +); + +typedef _dart_vc_get_current_language = int Function( + ffi.Pointer> language, +); + +typedef _c_vc_get_state = ffi.Int32 Function( + ffi.Pointer state, +); + +typedef _dart_vc_get_state = int Function( + ffi.Pointer state, +); + +typedef _c_vc_get_service_state = ffi.Int32 Function( + ffi.Pointer state, +); + +typedef _dart_vc_get_service_state = int Function( + ffi.Pointer state, +); + +typedef _c_vc_get_system_command_list = ffi.Int32 Function( + ffi.Pointer> vc_sys_cmd_list, +); + +typedef _dart_vc_get_system_command_list = int Function( + ffi.Pointer> vc_sys_cmd_list, +); + +typedef _c_vc_set_invocation_name = ffi.Int32 Function( + ffi.Pointer name, +); + +typedef _dart_vc_set_invocation_name = int Function( + ffi.Pointer name, +); + +typedef _c_vc_set_server_dialog = ffi.Int32 Function( + ffi.Pointer app_id, + ffi.Pointer credential, +); + +typedef _dart_vc_set_server_dialog = int Function( + ffi.Pointer app_id, + ffi.Pointer credential, +); + +typedef _c_vc_unset_server_dialog = ffi.Int32 Function( + ffi.Pointer app_id, +); + +typedef _dart_vc_unset_server_dialog = int Function( + ffi.Pointer app_id, +); + +typedef _c_vc_request_dialog = ffi.Int32 Function( + ffi.Pointer disp_text, + ffi.Pointer utt_text, + ffi.Uint8 auto_start, +); + +typedef _dart_vc_request_dialog = int Function( + ffi.Pointer disp_text, + ffi.Pointer utt_text, + int auto_start, +); + +typedef _c_vc_set_command_list = ffi.Int32 Function( + ffi.Pointer vc_cmd_list, + ffi.Int32 type, +); + +typedef _dart_vc_set_command_list = int Function( + ffi.Pointer vc_cmd_list, + int type, +); + +typedef _c_vc_unset_command_list = ffi.Int32 Function( + ffi.Int32 type, +); + +typedef _dart_vc_unset_command_list = int Function( + int type, +); + +typedef vc_result_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_vc_get_result = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_vc_get_result = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_vc_set_result_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_vc_set_result_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_vc_unset_result_cb = ffi.Int32 Function(); + +typedef _dart_vc_unset_result_cb = int Function(); + +typedef vc_service_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_vc_set_service_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_vc_set_service_state_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_vc_unset_service_state_changed_cb = ffi.Int32 Function(); + +typedef _dart_vc_unset_service_state_changed_cb = int Function(); + +typedef vc_state_changed_cb = ffi.Void Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef _c_vc_set_state_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_vc_set_state_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_vc_unset_state_changed_cb = ffi.Int32 Function(); + +typedef _dart_vc_unset_state_changed_cb = int Function(); + +typedef vc_current_language_changed_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef _c_vc_set_current_language_changed_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_vc_set_current_language_changed_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_vc_unset_current_language_changed_cb = ffi.Int32 Function(); + +typedef _dart_vc_unset_current_language_changed_cb = int Function(); + +typedef vc_error_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef _c_vc_set_error_cb = ffi.Int32 Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _dart_vc_set_error_cb = int Function( + ffi.Pointer> callback, + ffi.Pointer user_data, +); + +typedef _c_vc_unset_error_cb = ffi.Int32 Function(); + +typedef _dart_vc_unset_error_cb = int Function(); + +typedef app_create_cb = ffi.Uint8 Function( + ffi.Pointer, +); + +typedef app_terminate_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef app_pause_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef app_resume_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef app_control_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef job_service_start_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef job_service_stop_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_sql_select_response_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_sql_insert_response_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Int64, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_sql_update_response_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_sql_delete_response_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_map_get_response_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer>, + ffi.Int32, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_map_set_response_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_map_add_response_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_map_remove_response_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Uint8, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_provider_sql_insert_request_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_provider_sql_select_request_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer>, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_provider_sql_update_request_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_provider_sql_delete_request_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_provider_map_get_value_request_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_provider_map_set_value_request_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_provider_map_add_value_request_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef data_control_provider_map_remove_value_request_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef service_app_create_cb = ffi.Uint8 Function( + ffi.Pointer, +); + +typedef service_app_terminate_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef service_app_control_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef watch_app_create_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, +); + +typedef watch_app_control_cb = ffi.Void Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef watch_app_pause_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef watch_app_resume_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef watch_app_terminate_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef watch_app_time_tick_cb = ffi.Void Function( + ffi.Pointer<_watch_time_s>, + ffi.Pointer, +); + +typedef watch_app_ambient_tick_cb = ffi.Void Function( + ffi.Pointer<_watch_time_s>, + ffi.Pointer, +); + +typedef watch_app_ambient_changed_cb = ffi.Void Function( + ffi.Uint8, + ffi.Pointer, +); + +typedef ime_create_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef ime_terminate_cb = ffi.Void Function( + ffi.Pointer, +); + +typedef ime_show_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer<_ime_context>, + ffi.Pointer, +); + +typedef ime_hide_cb = ffi.Void Function( + ffi.Int32, + ffi.Pointer, +); + +typedef stte_get_info_cb = ffi.Int32 Function( + ffi.Pointer>, + ffi.Pointer>, + ffi.Pointer>, + ffi.Pointer, +); + +typedef stte_initialize_cb = ffi.Int32 Function(); + +typedef stte_deinitialize_cb = ffi.Int32 Function(); + +typedef stte_supported_language_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef stte_foreach_supported_langs_cb = ffi.Int32 Function( + ffi.Pointer>, + ffi.Pointer, +); + +typedef stte_is_valid_language_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef stte_support_silence_detection_cb = ffi.Uint8 Function(); + +typedef stte_support_recognition_type_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef stte_get_recording_format_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef stte_result_time_cb = ffi.Uint8 Function( + ffi.Int32, + ffi.Int32, + ffi.Pointer, + ffi.Int64, + ffi.Int64, + ffi.Pointer, +); + +typedef stte_foreach_result_time_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Pointer>, + ffi.Pointer, +); + +typedef stte_set_silence_detection_cb = ffi.Int32 Function( + ffi.Uint8, +); + +typedef stte_start_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef stte_set_recording_data_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Uint32, +); + +typedef stte_stop_cb = ffi.Int32 Function(); + +typedef stte_cancel_cb = ffi.Int32 Function(); + +typedef stte_check_app_agreed_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef stte_need_app_credential_cb = ffi.Uint8 Function(); + +typedef ttse_get_info_cb = ffi.Int32 Function( + ffi.Pointer>, + ffi.Pointer>, + ffi.Pointer>, + ffi.Pointer, +); + +typedef ttse_initialize_cb = ffi.Int32 Function(); + +typedef ttse_deinitialize_cb = ffi.Int32 Function(); + +typedef ttse_supported_voice_cb = ffi.Uint8 Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef ttse_foreach_supported_voices_cb = ffi.Int32 Function( + ffi.Pointer>, + ffi.Pointer, +); + +typedef ttse_is_valid_voice_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, +); + +typedef ttse_set_pitch_cb = ffi.Int32 Function( + ffi.Int32, +); + +typedef ttse_load_voice_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Int32, +); + +typedef ttse_unload_voice_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Int32, +); + +typedef ttse_start_synthesis_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Int32, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, +); + +typedef ttse_cancel_synthesis_cb = ffi.Int32 Function(); + +typedef ttse_check_app_agreed_cb = ffi.Int32 Function( + ffi.Pointer, + ffi.Pointer, +); + +typedef ttse_need_app_credential_cb = ffi.Uint8 Function(); diff --git a/lib/src/bindings/4.0/wearable/generated_symbols.dart b/lib/src/bindings/4.0/wearable/generated_symbols.dart new file mode 100644 index 0000000..5e67254 --- /dev/null +++ b/lib/src/bindings/4.0/wearable/generated_symbols.dart @@ -0,0 +1,4276 @@ +// Copyright 2021 Samsung Electronics Co., Ltd. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// AUTO GENERATED FILE, DO NOT EDIT. +// +// Generated by `package:symgen`. + +final Map> tizen40Symbols = { + 'libaccounts-svc.so.0': [ + 'account_connect', + 'account_connect_readonly', + 'account_create', + 'account_delete_from_db_by_id', + 'account_delete_from_db_by_package_name', + 'account_delete_from_db_by_user_name', + 'account_destroy', + 'account_disconnect', + 'account_foreach_account_from_db', + 'account_get_access_token', + 'account_get_account_id', + 'account_get_auth_type', + 'account_get_capability', + 'account_get_capability_all', + 'account_get_custom', + 'account_get_custom_all', + 'account_get_display_name', + 'account_get_domain_name', + 'account_get_email_address', + 'account_get_icon_path', + 'account_get_package_name', + 'account_get_secret', + 'account_get_source', + 'account_get_sync_support', + 'account_get_total_count_from_db', + 'account_get_user_int', + 'account_get_user_name', + 'account_get_user_text', + 'account_insert_to_db', + 'account_query_account_by_account_id', + 'account_query_account_by_capability', + 'account_query_account_by_capability_type', + 'account_query_account_by_package_name', + 'account_query_account_by_user_name', + 'account_query_capability_by_account_id', + 'account_set_access_token', + 'account_set_auth_type', + 'account_set_capability', + 'account_set_custom', + 'account_set_display_name', + 'account_set_domain_name', + 'account_set_email_address', + 'account_set_icon_path', + 'account_set_package_name', + 'account_set_secret', + 'account_set_source', + 'account_set_sync_support', + 'account_set_user_int', + 'account_set_user_name', + 'account_set_user_text', + 'account_subscribe_create', + 'account_subscribe_notification', + 'account_type_create', + 'account_type_destroy', + 'account_type_foreach_account_type_from_db', + 'account_type_get_app_id', + 'account_type_get_icon_path', + 'account_type_get_label', + 'account_type_get_label_by_locale', + 'account_type_get_multiple_account_support', + 'account_type_get_provider_feature_all', + 'account_type_get_service_provider_id', + 'account_type_get_small_icon_path', + 'account_type_query_app_id_exist', + 'account_type_query_by_app_id', + 'account_type_query_by_provider_feature', + 'account_type_query_label_by_app_id', + 'account_type_query_label_by_locale', + 'account_type_query_provider_feature_by_app_id', + 'account_type_query_supported_feature', + 'account_unsubscribe_notification', + 'account_update_sync_status_by_id', + 'account_update_to_db_by_id', + 'account_update_to_db_by_id_ex', + 'account_update_to_db_by_user_name', + ], + 'libfido-client.so.0': [ + 'fido_authenticator_foreach_attestation_type', + 'fido_authenticator_get_aaid', + 'fido_authenticator_get_algorithm', + 'fido_authenticator_get_assertion_scheme', + 'fido_authenticator_get_attachment_hint', + 'fido_authenticator_get_description', + 'fido_authenticator_get_icon', + 'fido_authenticator_get_is_second_factor_only', + 'fido_authenticator_get_key_protection_method', + 'fido_authenticator_get_matcher_protection_method', + 'fido_authenticator_get_tc_discplay', + 'fido_authenticator_get_tc_display_type', + 'fido_authenticator_get_title', + 'fido_authenticator_get_verification_method', + 'fido_foreach_authenticator', + 'fido_get_client_vendor', + 'fido_get_client_version', + 'fido_uaf_get_response_message', + 'fido_uaf_is_supported', + 'fido_uaf_set_server_result', + ], + 'liboauth2.so.0': [ + 'oauth2_error_get_code', + 'oauth2_error_get_custom_data', + 'oauth2_error_get_description', + 'oauth2_error_get_uri', + 'oauth2_manager_clear_cache', + 'oauth2_manager_clear_cookies', + 'oauth2_manager_create', + 'oauth2_manager_destroy', + 'oauth2_manager_is_request_in_progress', + 'oauth2_manager_refresh_access_token', + 'oauth2_manager_request_access_token', + 'oauth2_manager_request_authorization_grant', + 'oauth2_manager_request_token', + 'oauth2_request_add_custom_data', + 'oauth2_request_create', + 'oauth2_request_destroy', + 'oauth2_request_get_auth_end_point_url', + 'oauth2_request_get_authorization_code', + 'oauth2_request_get_client_id', + 'oauth2_request_get_client_secret', + 'oauth2_request_get_custom_data', + 'oauth2_request_get_grant_type', + 'oauth2_request_get_password', + 'oauth2_request_get_redirection_url', + 'oauth2_request_get_refresh_token', + 'oauth2_request_get_refresh_token_url', + 'oauth2_request_get_response_type', + 'oauth2_request_get_scope', + 'oauth2_request_get_state', + 'oauth2_request_get_token_end_point_url', + 'oauth2_request_get_user_name', + 'oauth2_request_set_auth_end_point_url', + 'oauth2_request_set_authorization_code', + 'oauth2_request_set_client_authentication_type', + 'oauth2_request_set_client_id', + 'oauth2_request_set_client_secret', + 'oauth2_request_set_grant_type', + 'oauth2_request_set_password', + 'oauth2_request_set_redirection_url', + 'oauth2_request_set_refresh_token', + 'oauth2_request_set_refresh_token_url', + 'oauth2_request_set_response_type', + 'oauth2_request_set_scope', + 'oauth2_request_set_state', + 'oauth2_request_set_token_end_point_url', + 'oauth2_request_set_user_name', + 'oauth2_response_destroy', + 'oauth2_response_get_access_token', + 'oauth2_response_get_authorization_code', + 'oauth2_response_get_custom_data', + 'oauth2_response_get_error', + 'oauth2_response_get_expires_in', + 'oauth2_response_get_refresh_token', + 'oauth2_response_get_scope', + 'oauth2_response_get_state', + 'oauth2_response_get_token_type', + ], + 'libcore-sync-client.so.1.0': [ + 'sync_adapter_set_callbacks', + 'sync_adapter_unset_callbacks', + 'sync_manager_add_data_change_sync_job', + 'sync_manager_add_periodic_sync_job', + 'sync_manager_foreach_sync_job', + 'sync_manager_on_demand_sync_job', + 'sync_manager_remove_sync_job', + ], + 'libcapi-appfw-application.so.0': [ + 'app_get_device_orientation', + 'i18n_get_text', + 'ui_app_add_event_handler', + 'ui_app_exit', + 'ui_app_main', + 'ui_app_remove_event_handler', + ], + 'libcapi-appfw-alarm.so.0': [ + 'alarm_cancel', + 'alarm_cancel_all', + 'alarm_foreach_registered_alarm', + 'alarm_get_app_control', + 'alarm_get_current_time', + 'alarm_get_global', + 'alarm_get_notification', + 'alarm_get_scheduled_date', + 'alarm_get_scheduled_period', + 'alarm_get_scheduled_recurrence_week_flag', + 'alarm_schedule_after_delay', + 'alarm_schedule_noti_after_delay', + 'alarm_schedule_noti_once_after_delay', + 'alarm_schedule_noti_once_at_date', + 'alarm_schedule_noti_with_recurrence_week_flag', + 'alarm_schedule_once_after_delay', + 'alarm_schedule_once_at_date', + 'alarm_schedule_with_recurrence_week_flag', + 'alarm_set_global', + 'alarm_update_date', + 'alarm_update_delay', + 'alarm_update_period', + 'alarm_update_week_flag', + ], + 'libcapi-appfw-app-common.so.0': [ + 'app_event_get_device_orientation', + 'app_event_get_language', + 'app_event_get_low_battery_status', + 'app_event_get_low_memory_status', + 'app_event_get_region_format', + 'app_event_get_suspended_state', + 'app_get_cache_path', + 'app_get_data_path', + 'app_get_external_cache_path', + 'app_get_external_data_path', + 'app_get_id', + 'app_get_name', + 'app_get_resource_path', + 'app_get_shared_data_path', + 'app_get_shared_resource_path', + 'app_get_shared_trusted_path', + 'app_get_tep_resource_path', + 'app_get_version', + 'app_resource_manager_get', + 'app_resource_manager_init', + 'app_resource_manager_release', + ], + 'libcapi-appfw-app-control.so.0': [ + 'app_control_add_extra_data', + 'app_control_add_extra_data_array', + 'app_control_clone', + 'app_control_create', + 'app_control_destroy', + 'app_control_enable_app_started_result_event', + 'app_control_foreach_app_matched', + 'app_control_foreach_extra_data', + 'app_control_get_app_id', + 'app_control_get_caller', + 'app_control_get_category', + 'app_control_get_extra_data', + 'app_control_get_extra_data_array', + 'app_control_get_launch_mode', + 'app_control_get_mime', + 'app_control_get_operation', + 'app_control_get_uri', + 'app_control_is_extra_data_array', + 'app_control_is_reply_requested', + 'app_control_remove_extra_data', + 'app_control_reply_to_launch_request', + 'app_control_send_launch_request', + 'app_control_send_terminate_request', + 'app_control_set_app_id', + 'app_control_set_category', + 'app_control_set_launch_mode', + 'app_control_set_mime', + 'app_control_set_operation', + 'app_control_set_uri', + ], + 'libcapi-appfw-event.so.0': [ + 'event_add_event_handler', + 'event_keep_last_event_data', + 'event_publish_app_event', + 'event_publish_trusted_app_event', + 'event_remove_event_handler', + ], + 'libcapi-appfw-job-scheduler.so.0': [ + 'job_info_add_trigger_event', + 'job_info_clone', + 'job_info_create', + 'job_info_destroy', + 'job_info_get_job_id', + 'job_info_remove_trigger_event', + 'job_info_set_once', + 'job_info_set_periodic', + 'job_info_set_persistent', + 'job_info_set_requirement_timeout', + 'job_info_set_requires_battery_not_low', + 'job_info_set_requires_charging', + 'job_info_set_requires_wifi_connection', + 'job_scheduler_cancel', + 'job_scheduler_cancel_all', + 'job_scheduler_finish', + 'job_scheduler_foreach_job', + 'job_scheduler_init', + 'job_scheduler_schedule', + 'job_scheduler_service_add', + 'job_scheduler_service_remove', + ], + 'libcapi-appfw-preference.so.0': [ + 'preference_foreach_item', + 'preference_get_boolean', + 'preference_get_double', + 'preference_get_int', + 'preference_get_string', + 'preference_is_existing', + 'preference_remove', + 'preference_remove_all', + 'preference_set_boolean', + 'preference_set_changed_cb', + 'preference_set_double', + 'preference_set_int', + 'preference_set_string', + 'preference_unset_changed_cb', + ], + 'libcapi-appfw-app-manager.so.0': [ + 'app_context_clone', + 'app_context_destroy', + 'app_context_get_app_id', + 'app_context_get_app_state', + 'app_context_get_package_id', + 'app_context_get_pid', + 'app_context_is_equal', + 'app_context_is_sub_app', + 'app_context_is_terminated', + 'app_info_clone', + 'app_info_create', + 'app_info_destroy', + 'app_info_filter_add_bool', + 'app_info_filter_add_string', + 'app_info_filter_count_appinfo', + 'app_info_filter_create', + 'app_info_filter_destroy', + 'app_info_filter_foreach_appinfo', + 'app_info_foreach_category', + 'app_info_foreach_metadata', + 'app_info_get_app_component_type', + 'app_info_get_app_id', + 'app_info_get_exec', + 'app_info_get_icon', + 'app_info_get_label', + 'app_info_get_localed_label', + 'app_info_get_package', + 'app_info_get_type', + 'app_info_is_enabled', + 'app_info_is_equal', + 'app_info_is_nodisplay', + 'app_info_is_onboot', + 'app_info_is_preload', + 'app_info_metadata_filter_add', + 'app_info_metadata_filter_create', + 'app_info_metadata_filter_destroy', + 'app_info_metadata_filter_foreach', + 'app_manager_event_create', + 'app_manager_event_destroy', + 'app_manager_event_set_status', + 'app_manager_foreach_app_context', + 'app_manager_foreach_app_info', + 'app_manager_foreach_running_app_context', + 'app_manager_get_app_context', + 'app_manager_get_app_id', + 'app_manager_get_app_info', + 'app_manager_get_shared_data_path', + 'app_manager_get_shared_resource_path', + 'app_manager_get_shared_trusted_path', + 'app_manager_is_running', + 'app_manager_request_terminate_bg_app', + 'app_manager_resume_app', + 'app_manager_set_app_context_event_cb', + 'app_manager_set_event_cb', + 'app_manager_unset_app_context_event_cb', + 'app_manager_unset_event_cb', + ], + 'libbadge.so.0': [ + 'badge_add', + 'badge_foreach', + 'badge_get_count', + 'badge_get_display', + 'badge_register_changed_cb', + 'badge_remove', + 'badge_set_count', + 'badge_set_display', + 'badge_unregister_changed_cb', + ], + 'libbundle.so.0': [ + 'bundle_add_byte', + 'bundle_add_str', + 'bundle_add_str_array', + 'bundle_create', + 'bundle_decode', + 'bundle_del', + 'bundle_dup', + 'bundle_encode', + 'bundle_foreach', + 'bundle_free', + 'bundle_get_byte', + 'bundle_get_count', + 'bundle_get_str', + 'bundle_get_str_array', + 'bundle_get_type', + 'bundle_keyval_get_array_val', + 'bundle_keyval_get_basic_val', + 'bundle_keyval_get_type', + 'bundle_keyval_type_is_array', + ], + 'libdata-control.so.0': [ + 'data_control_add_data_change_cb', + 'data_control_bulk_data_add', + 'data_control_bulk_data_create', + 'data_control_bulk_data_destroy', + 'data_control_bulk_data_get_count', + 'data_control_bulk_data_get_data', + 'data_control_bulk_result_data_add', + 'data_control_bulk_result_data_create', + 'data_control_bulk_result_data_destroy', + 'data_control_bulk_result_data_get_count', + 'data_control_bulk_result_data_get_result_data', + 'data_control_map_add_bulk_data', + 'data_control_map_bind_add_bulk_data_response_cb', + 'data_control_map_bind_response_cb', + 'data_control_map_create', + 'data_control_map_destroy', + 'data_control_map_get_data_id', + 'data_control_map_get_handle_id', + 'data_control_map_get_provider_id', + 'data_control_map_get_with_page', + 'data_control_map_register_add_bulk_data_response_cb', + 'data_control_map_register_response_cb', + 'data_control_map_remove', + 'data_control_map_set_data_id', + 'data_control_map_set_provider_id', + 'data_control_map_unbind_add_bulk_data_response_cb', + 'data_control_map_unbind_response_cb', + 'data_control_map_unregister_add_bulk_data_response_cb', + 'data_control_map_unregister_response_cb', + 'data_control_provider_add_data_change_consumer_filter_cb', + 'data_control_provider_create_delete_statement', + 'data_control_provider_create_insert_statement', + 'data_control_provider_create_select_statement', + 'data_control_provider_create_update_statement', + 'data_control_provider_foreach_data_change_consumer', + 'data_control_provider_get_client_appid', + 'data_control_provider_map_register_add_bulk_data_request_cb', + 'data_control_provider_map_register_cb', + 'data_control_provider_map_unregister_add_bulk_data_request_cb', + 'data_control_provider_map_unregister_cb', + 'data_control_provider_match_data_id', + 'data_control_provider_match_provider_id', + 'data_control_provider_remove_data_change_consumer_filter_cb', + 'data_control_provider_send_bulk_insert_result', + 'data_control_provider_send_data_change_noti', + 'data_control_provider_send_delete_result', + 'data_control_provider_send_error', + 'data_control_provider_send_insert_result', + 'data_control_provider_send_map_bulk_add_result', + 'data_control_provider_send_map_get_value_result', + 'data_control_provider_send_map_result', + 'data_control_provider_send_select_result', + 'data_control_provider_send_update_result', + 'data_control_provider_sql_register_cb', + 'data_control_provider_sql_register_insert_bulk_data_request_cb', + 'data_control_provider_sql_unregister_cb', + 'data_control_provider_sql_unregister_insert_bulk_data_request_cb', + 'data_control_remove_data_change_cb', + 'data_control_sql_bind_insert_bulk_data_response_cb', + 'data_control_sql_bind_response_cb', + 'data_control_sql_create', + 'data_control_sql_destroy', + 'data_control_sql_get_blob_data', + 'data_control_sql_get_column_count', + 'data_control_sql_get_column_item_size', + 'data_control_sql_get_column_item_type', + 'data_control_sql_get_column_name', + 'data_control_sql_get_data_id', + 'data_control_sql_get_double_data', + 'data_control_sql_get_handle_id', + 'data_control_sql_get_int64_data', + 'data_control_sql_get_int_data', + 'data_control_sql_get_provider_id', + 'data_control_sql_get_text_data', + 'data_control_sql_insert_bulk_data', + 'data_control_sql_register_insert_bulk_data_response_cb', + 'data_control_sql_register_response_cb', + 'data_control_sql_select_with_page', + 'data_control_sql_set_data_id', + 'data_control_sql_set_provider_id', + 'data_control_sql_step_first', + 'data_control_sql_step_last', + 'data_control_sql_step_next', + 'data_control_sql_step_previous', + 'data_control_sql_unbind_insert_bulk_data_response_cb', + 'data_control_sql_unbind_response_cb', + 'data_control_sql_unregister_insert_bulk_data_response_cb', + 'data_control_sql_unregister_response_cb', + 'data_control_sql_update', + ], + 'libmessage-port.so.1': [ + 'message_port_add_registered_cb', + 'message_port_add_unregistered_cb', + 'message_port_check_remote_port', + 'message_port_check_trusted_remote_port', + 'message_port_register_local_port', + 'message_port_register_trusted_local_port', + 'message_port_remove_registration_event_cb', + 'message_port_send_message', + 'message_port_send_message_with_local_port', + 'message_port_send_trusted_message', + 'message_port_send_trusted_message_with_local_port', + 'message_port_unregister_local_port', + 'message_port_unregister_trusted_local_port', + ], + 'libnotification.so.0': [ + 'notification_add_button', + 'notification_clone', + 'notification_create', + 'notification_create_from_template', + 'notification_delete', + 'notification_delete_all', + 'notification_free', + 'notification_get_auto_remove', + 'notification_get_display_applist', + 'notification_get_event_handler', + 'notification_get_extension_image_size', + 'notification_get_image', + 'notification_get_insert_time', + 'notification_get_launch_option', + 'notification_get_layout', + 'notification_get_led', + 'notification_get_led_time_period', + 'notification_get_noti_block_state', + 'notification_get_pkgname', + 'notification_get_progress', + 'notification_get_property', + 'notification_get_size', + 'notification_get_sound', + 'notification_get_tag', + 'notification_get_text', + 'notification_get_time', + 'notification_get_time_from_text', + 'notification_get_type', + 'notification_get_vibration', + 'notification_load_by_tag', + 'notification_post', + 'notification_remove_button', + 'notification_save_as_template', + 'notification_set_auto_remove', + 'notification_set_display_applist', + 'notification_set_event_handler', + 'notification_set_extension_image_size', + 'notification_set_image', + 'notification_set_launch_option', + 'notification_set_layout', + 'notification_set_led', + 'notification_set_led_time_period', + 'notification_set_progress', + 'notification_set_property', + 'notification_set_size', + 'notification_set_sound', + 'notification_set_tag', + 'notification_set_text', + 'notification_set_text_input', + 'notification_set_time', + 'notification_set_time_to_text', + 'notification_set_vibration', + 'notification_status_message_post', + 'notification_update', + ], + 'libcapi-appfw-package-manager.so.0': [ + 'package_archive_info_create', + 'package_archive_info_destroy', + 'package_archive_info_get_api_version', + 'package_archive_info_get_author', + 'package_archive_info_get_description', + 'package_archive_info_get_icon', + 'package_archive_info_get_label', + 'package_archive_info_get_package', + 'package_archive_info_get_type', + 'package_archive_info_get_version', + 'package_info_clone', + 'package_info_create', + 'package_info_destroy', + 'package_info_foreach_app_from_package', + 'package_info_foreach_cert_info', + 'package_info_foreach_privilege_info', + 'package_info_get_icon', + 'package_info_get_installed_storage', + 'package_info_get_installed_time', + 'package_info_get_label', + 'package_info_get_main_app_id', + 'package_info_get_package', + 'package_info_get_root_path', + 'package_info_get_type', + 'package_info_get_version', + 'package_info_is_accessible', + 'package_info_is_equal', + 'package_info_is_preload_package', + 'package_info_is_removable_package', + 'package_info_is_system_package', + 'package_info_updateinfo_create', + 'package_info_updateinfo_destroy', + 'package_info_updateinfo_foreach_info', + 'package_info_updateinfo_get_pkgid', + 'package_info_updateinfo_get_type', + 'package_info_updateinfo_get_version', + 'package_manager_clear_all_cache_dir', + 'package_manager_clear_cache_dir', + 'package_manager_clear_data_dir', + 'package_manager_compare_app_cert_info', + 'package_manager_compare_package_cert_info', + 'package_manager_create', + 'package_manager_destroy', + 'package_manager_drm_decrypt_package', + 'package_manager_drm_generate_license_request', + 'package_manager_drm_register_license', + 'package_manager_filter_add_bool', + 'package_manager_filter_count', + 'package_manager_filter_create', + 'package_manager_filter_destroy', + 'package_manager_filter_foreach_package_info', + 'package_manager_foreach_package_info', + 'package_manager_get_package_id_by_app_id', + 'package_manager_get_package_info', + 'package_manager_get_package_size_info', + 'package_manager_get_permission_type', + 'package_manager_get_total_package_size_info', + 'package_manager_is_preload_package_by_app_id', + 'package_manager_request_create', + 'package_manager_request_destroy', + 'package_manager_request_install', + 'package_manager_request_install_with_cb', + 'package_manager_request_move', + 'package_manager_request_move_with_cb', + 'package_manager_request_set_event_cb', + 'package_manager_request_set_mode', + 'package_manager_request_set_tep', + 'package_manager_request_set_type', + 'package_manager_request_uninstall', + 'package_manager_request_uninstall_with_cb', + 'package_manager_request_unset_event_cb', + 'package_manager_set_event_cb', + 'package_manager_set_event_status', + 'package_manager_unset_event_cb', + 'package_manager_updateinfo_request_create', + 'package_manager_updateinfo_request_destroy', + 'package_manager_updateinfo_request_register', + 'package_manager_updateinfo_request_unregister', + 'package_manager_updateinfo_request_unregister_all', + 'package_manager_updateinfo_set_pkgid', + 'package_manager_updateinfo_set_type', + 'package_manager_updateinfo_set_version', + 'package_size_info_get_app_size', + 'package_size_info_get_cache_size', + 'package_size_info_get_data_size', + 'package_size_info_get_external_app_size', + 'package_size_info_get_external_cache_size', + 'package_size_info_get_external_data_size', + ], + 'libappcore-agent.so.1': [ + 'service_app_add_event_handler', + 'service_app_exit', + 'service_app_main', + 'service_app_remove_event_handler', + ], + 'libappcore-watch.so.1': [ + 'watch_app_add_event_handler', + 'watch_app_exit', + 'watch_app_get_ambient_tick_type', + 'watch_app_get_elm_win', + 'watch_app_get_time_tick_frequency', + 'watch_app_main', + 'watch_app_remove_event_handler', + 'watch_app_set_ambient_tick_type', + 'watch_app_set_time_tick_frequency', + 'watch_time_delete', + 'watch_time_get_current_time', + 'watch_time_get_day', + 'watch_time_get_day_of_week', + 'watch_time_get_dst_status', + 'watch_time_get_hour', + 'watch_time_get_hour24', + 'watch_time_get_millisecond', + 'watch_time_get_minute', + 'watch_time_get_month', + 'watch_time_get_second', + 'watch_time_get_time_zone', + 'watch_time_get_utc_time', + 'watch_time_get_utc_timestamp', + 'watch_time_get_year', + ], + 'libcapi-appfw-widget-application.so.1': [ + 'widget_app_add_event_handler', + 'widget_app_class_add', + 'widget_app_class_create', + 'widget_app_context_get_tag', + 'widget_app_context_set_content_info', + 'widget_app_context_set_tag', + 'widget_app_context_set_title', + 'widget_app_exit', + 'widget_app_foreach_context', + 'widget_app_get_elm_win', + 'widget_app_get_id', + 'widget_app_main', + 'widget_app_remove_event_handler', + 'widget_app_terminate_context', + ], + 'libwidget_service.so.1': [ + 'widget_service_change_period', + 'widget_service_get_app_id_of_setup_app', + 'widget_service_get_content_of_widget_instance', + 'widget_service_get_icon', + 'widget_service_get_main_app_id', + 'widget_service_get_name', + 'widget_service_get_need_of_frame', + 'widget_service_get_need_of_mouse_event', + 'widget_service_get_need_of_touch_effect', + 'widget_service_get_nodisplay', + 'widget_service_get_package_id', + 'widget_service_get_preview_image_path', + 'widget_service_get_size', + 'widget_service_get_size_type', + 'widget_service_get_supported_sizes', + 'widget_service_get_supported_size_types', + 'widget_service_get_widget_id', + 'widget_service_get_widget_instance_list', + 'widget_service_get_widget_list', + 'widget_service_get_widget_list_by_pkgid', + 'widget_service_set_lifecycle_event_cb', + 'widget_service_trigger_update', + 'widget_service_unset_lifecycle_event_cb', + ], + 'libwidget_viewer_evas.so.1': [ + 'widget_viewer_evas_activate_faulted_widget', + 'widget_viewer_evas_add_widget', + 'widget_viewer_evas_cancel_click_event', + 'widget_viewer_evas_disable_loading', + 'widget_viewer_evas_disable_overlay_text', + 'widget_viewer_evas_disable_preview', + 'widget_viewer_evas_feed_mouse_up_event', + 'widget_viewer_evas_fini', + 'widget_viewer_evas_freeze_visibility', + 'widget_viewer_evas_get_content_info', + 'widget_viewer_evas_get_period', + 'widget_viewer_evas_get_title_string', + 'widget_viewer_evas_get_widget_id', + 'widget_viewer_evas_get_widget_instance_id', + 'widget_viewer_evas_init', + 'widget_viewer_evas_is_faulted', + 'widget_viewer_evas_is_visibility_frozen', + 'widget_viewer_evas_is_widget', + 'widget_viewer_evas_notify_orientation_of_viewer', + 'widget_viewer_evas_notify_paused_status_of_viewer', + 'widget_viewer_evas_notify_resumed_status_of_viewer', + 'widget_viewer_evas_pause_widget', + 'widget_viewer_evas_resume_widget', + 'widget_viewer_evas_set_option', + 'widget_viewer_evas_set_permanent_delete', + 'widget_viewer_evas_thaw_visibility', + ], + 'libcapi-base-common.so.0': [ + 'get_error_message', + 'get_last_result', + 'set_last_result', + ], + 'libcapi-content-mime-type.so.0': [ + 'mime_type_get_file_extension', + 'mime_type_get_mime_type', + 'mime_type_get_mime_type_for_data', + 'mime_type_get_mime_type_for_file', + ], + 'libcapi-content-media-content.so.0': [ + 'audio_meta_clone', + 'audio_meta_destroy', + 'audio_meta_get_album', + 'audio_meta_get_album_artist', + 'audio_meta_get_artist', + 'audio_meta_get_bitpersample', + 'audio_meta_get_bit_rate', + 'audio_meta_get_channel', + 'audio_meta_get_composer', + 'audio_meta_get_copyright', + 'audio_meta_get_duration', + 'audio_meta_get_genre', + 'audio_meta_get_media_id', + 'audio_meta_get_recorded_date', + 'audio_meta_get_sample_rate', + 'audio_meta_get_track_num', + 'audio_meta_get_year', + 'image_meta_clone', + 'image_meta_destroy', + 'image_meta_get_date_taken', + 'image_meta_get_exposure_time', + 'image_meta_get_fnumber', + 'image_meta_get_height', + 'image_meta_get_iso', + 'image_meta_get_media_id', + 'image_meta_get_model', + 'image_meta_get_orientation', + 'image_meta_get_width', + 'media_album_clone', + 'media_album_destroy', + 'media_album_foreach_album_from_db', + 'media_album_foreach_media_from_db', + 'media_album_get_album_art', + 'media_album_get_album_count_from_db', + 'media_album_get_album_from_db', + 'media_album_get_album_id', + 'media_album_get_artist', + 'media_album_get_media_count_from_db', + 'media_album_get_name', + 'media_bookmark_clone', + 'media_bookmark_delete_from_db', + 'media_bookmark_destroy', + 'media_bookmark_foreach_bookmark_from_db', + 'media_bookmark_get_bookmark_count_from_db', + 'media_bookmark_get_bookmark_id', + 'media_bookmark_get_marked_time', + 'media_bookmark_get_name', + 'media_bookmark_get_thumbnail_path', + 'media_bookmark_insert_to_db', + 'media_bookmark_set_name', + 'media_bookmark_update_to_db', + 'media_content_add_db_updated_cb', + 'media_content_cancel_scan_folder', + 'media_content_connect', + 'media_content_disconnect', + 'media_content_remove_db_updated_cb', + 'media_content_scan_file', + 'media_content_scan_folder', + 'media_face_clone', + 'media_face_create', + 'media_face_delete_from_db', + 'media_face_destroy', + 'media_face_foreach_face_from_db', + 'media_face_get_face_count_from_db', + 'media_face_get_face_id', + 'media_face_get_face_rect', + 'media_face_get_media_id', + 'media_face_get_orientation', + 'media_face_get_tag', + 'media_face_insert_to_db', + 'media_face_set_face_rect', + 'media_face_set_orientation', + 'media_face_set_tag', + 'media_face_update_to_db', + 'media_filter_create', + 'media_filter_destroy', + 'media_filter_get_condition', + 'media_filter_get_offset', + 'media_filter_get_order', + 'media_filter_get_storage', + 'media_filter_set_condition', + 'media_filter_set_offset', + 'media_filter_set_order', + 'media_filter_set_storage', + 'media_folder_clone', + 'media_folder_destroy', + 'media_folder_foreach_folder_from_db', + 'media_folder_foreach_media_from_db', + 'media_folder_get_folder_count_from_db', + 'media_folder_get_folder_from_db', + 'media_folder_get_folder_id', + 'media_folder_get_media_count_from_db', + 'media_folder_get_name', + 'media_folder_get_path', + 'media_folder_get_storage_id', + 'media_folder_get_storage_type', + 'media_group_foreach_group_from_db', + 'media_group_foreach_media_from_db', + 'media_group_get_group_count_from_db', + 'media_group_get_media_count_from_db', + 'media_info_cancel_face_detection', + 'media_info_cancel_thumbnail', + 'media_info_clone', + 'media_info_create_thumbnail', + 'media_info_delete_from_db', + 'media_info_destroy', + 'media_info_foreach_bookmark_from_db', + 'media_info_foreach_media_from_db', + 'media_info_foreach_tag_from_db', + 'media_info_get_added_time', + 'media_info_get_altitude', + 'media_info_get_audio', + 'media_info_get_bookmark_count_from_db', + 'media_info_get_description', + 'media_info_get_display_name', + 'media_info_get_face_count_from_db', + 'media_info_get_favorite', + 'media_info_get_file_path', + 'media_info_get_image', + 'media_info_get_latitude', + 'media_info_get_longitude', + 'media_info_get_media_count_from_db', + 'media_info_get_media_from_db', + 'media_info_get_media_id', + 'media_info_get_media_type', + 'media_info_get_mime_type', + 'media_info_get_modified_time', + 'media_info_get_rating', + 'media_info_get_size', + 'media_info_get_storage_id', + 'media_info_get_storage_type', + 'media_info_get_tag_count_from_db', + 'media_info_get_thumbnail_path', + 'media_info_get_timeline', + 'media_info_get_title', + 'media_info_get_video', + 'media_info_insert_batch_to_db', + 'media_info_insert_to_db', + 'media_info_is_360_content', + 'media_info_is_drm', + 'media_info_move_to_db', + 'media_info_set_favorite', + 'media_info_start_face_detection', + 'media_info_update_to_db', + 'media_playlist_add_media', + 'media_playlist_clone', + 'media_playlist_delete_from_db', + 'media_playlist_destroy', + 'media_playlist_export_to_file', + 'media_playlist_foreach_media_from_db', + 'media_playlist_foreach_playlist_from_db', + 'media_playlist_get_media_count_from_db', + 'media_playlist_get_name', + 'media_playlist_get_playlist_count_from_db', + 'media_playlist_get_playlist_from_db', + 'media_playlist_get_playlist_id', + 'media_playlist_get_play_order', + 'media_playlist_get_thumbnail_path', + 'media_playlist_import_from_file', + 'media_playlist_insert_to_db', + 'media_playlist_remove_media', + 'media_playlist_set_name', + 'media_playlist_set_play_order', + 'media_playlist_set_thumbnail_path', + 'media_playlist_update_to_db', + 'media_storage_clone', + 'media_storage_destroy', + 'media_storage_foreach_media_from_db', + 'media_storage_foreach_storage_from_db', + 'media_storage_get_id', + 'media_storage_get_media_count_from_db', + 'media_storage_get_path', + 'media_storage_get_storage_count_from_db', + 'media_storage_get_storage_info_from_db', + 'media_storage_get_type', + 'media_tag_add_media', + 'media_tag_clone', + 'media_tag_delete_from_db', + 'media_tag_destroy', + 'media_tag_foreach_media_from_db', + 'media_tag_foreach_tag_from_db', + 'media_tag_get_media_count_from_db', + 'media_tag_get_name', + 'media_tag_get_tag_count_from_db', + 'media_tag_get_tag_from_db', + 'media_tag_get_tag_id', + 'media_tag_insert_to_db', + 'media_tag_remove_media', + 'media_tag_set_name', + 'media_tag_update_to_db', + 'video_meta_clone', + 'video_meta_destroy', + 'video_meta_get_album', + 'video_meta_get_album_artist', + 'video_meta_get_artist', + 'video_meta_get_bit_rate', + 'video_meta_get_composer', + 'video_meta_get_copyright', + 'video_meta_get_duration', + 'video_meta_get_genre', + 'video_meta_get_height', + 'video_meta_get_media_id', + 'video_meta_get_recorded_date', + 'video_meta_get_rotation', + 'video_meta_get_track_num', + 'video_meta_get_width', + 'video_meta_get_year', + ], + 'libcapi-context-motion.so.2': [ + 'activity_create', + 'activity_get_accuracy', + 'activity_is_supported', + 'activity_release', + 'activity_start_recognition', + 'activity_stop_recognition', + 'gesture_create', + 'gesture_get_event', + 'gesture_get_tilt', + 'gesture_is_supported', + 'gesture_release', + 'gesture_start_recognition', + 'gesture_stop_recognition', + ], + 'libcapi-context.so.1': [ + 'context_history_filter_set_string', + 'context_history_is_supported', + 'context_history_list_get_count', + 'context_history_record_get_double', + 'context_trigger_custom_publish', + 'context_trigger_custom_register', + 'context_trigger_custom_unregister', + 'context_trigger_enable_rule', + 'context_trigger_rule_custom_condition_create', + 'context_trigger_rule_custom_event_create', + 'context_trigger_rule_entry_add_comparison', + 'context_trigger_rule_entry_add_option', + 'context_trigger_rule_entry_add_option_int', + 'context_trigger_rule_entry_add_option_string', + ], + 'libcapi-location-manager.so.0': [ + 'gps_status_foreach_last_satellites_in_view', + 'gps_status_foreach_satellites_in_view', + 'gps_status_get_last_satellite', + 'gps_status_get_nmea', + 'gps_status_get_satellite', + 'gps_status_set_satellite_updated_cb', + 'gps_status_unset_satellite_updated_cb', + 'location_bounds_contains_coordinates', + 'location_bounds_create_circle', + 'location_bounds_create_polygon', + 'location_bounds_create_rect', + 'location_bounds_destroy', + 'location_bounds_foreach_polygon_coords', + 'location_bounds_get_circle_coords', + 'location_bounds_get_rect_coords', + 'location_bounds_get_type', + 'location_bounds_set_state_changed_cb', + 'location_bounds_unset_state_changed_cb', + 'location_manager_add_boundary', + 'location_manager_clear_mock_location', + 'location_manager_create', + 'location_manager_destroy', + 'location_manager_enable_method', + 'location_manager_enable_mock_location', + 'location_manager_foreach_boundary', + 'location_manager_foreach_location_batch', + 'location_manager_get_accuracy', + 'location_manager_get_distance', + 'location_manager_get_last_accuracy', + 'location_manager_get_last_location', + 'location_manager_get_last_position', + 'location_manager_get_last_velocity', + 'location_manager_get_location', + 'location_manager_get_method', + 'location_manager_get_position', + 'location_manager_get_velocity', + 'location_manager_is_enabled_method', + 'location_manager_is_enabled_mock_location', + 'location_manager_is_supported_method', + 'location_manager_remove_boundary', + 'location_manager_request_single_location', + 'location_manager_set_distance_based_location_changed_cb', + 'location_manager_set_fused_mode', + 'location_manager_set_location_batch_cb', + 'location_manager_set_location_changed_cb', + 'location_manager_set_mock_location', + 'location_manager_set_position_updated_cb', + 'location_manager_set_service_state_changed_cb', + 'location_manager_set_setting_changed_cb', + 'location_manager_set_velocity_updated_cb', + 'location_manager_set_zone_changed_cb', + 'location_manager_start', + 'location_manager_start_batch', + 'location_manager_stop', + 'location_manager_stop_batch', + 'location_manager_unset_distance_based_location_changed_cb', + 'location_manager_unset_location_batch_cb', + 'location_manager_unset_location_changed_cb', + 'location_manager_unset_position_updated_cb', + 'location_manager_unset_service_state_changed_cb', + 'location_manager_unset_setting_changed_cb', + 'location_manager_unset_velocity_updated_cb', + 'location_manager_unset_zone_changed_cb', + ], + 'libcapi-maps-service.so.0': [ + 'maps_address_clone', + 'maps_address_create', + 'maps_address_destroy', + 'maps_address_get_building_number', + 'maps_address_get_city', + 'maps_address_get_country', + 'maps_address_get_country_code', + 'maps_address_get_county', + 'maps_address_get_district', + 'maps_address_get_freetext', + 'maps_address_get_postal_code', + 'maps_address_get_state', + 'maps_address_get_street', + 'maps_address_list_append', + 'maps_address_list_create', + 'maps_address_list_destroy', + 'maps_address_list_foreach', + 'maps_address_list_get_length', + 'maps_address_list_remove', + 'maps_address_set_building_number', + 'maps_address_set_city', + 'maps_address_set_country', + 'maps_address_set_country_code', + 'maps_address_set_county', + 'maps_address_set_district', + 'maps_address_set_freetext', + 'maps_address_set_postal_code', + 'maps_address_set_state', + 'maps_address_set_street', + 'maps_area_clone', + 'maps_area_create_circle', + 'maps_area_create_rectangle', + 'maps_area_destroy', + 'maps_coordinates_clone', + 'maps_coordinates_create', + 'maps_coordinates_destroy', + 'maps_coordinates_get_latitude', + 'maps_coordinates_get_latitude_longitude', + 'maps_coordinates_get_longitude', + 'maps_coordinates_list_append', + 'maps_coordinates_list_create', + 'maps_coordinates_list_destroy', + 'maps_coordinates_list_foreach', + 'maps_coordinates_list_get_length', + 'maps_coordinates_list_remove', + 'maps_coordinates_set_latitude', + 'maps_coordinates_set_latitude_longitude', + 'maps_coordinates_set_longitude', + 'maps_place_attribute_clone', + 'maps_place_attribute_destroy', + 'maps_place_attribute_get_id', + 'maps_place_attribute_get_label', + 'maps_place_attribute_get_text', + 'maps_place_category_clone', + 'maps_place_category_create', + 'maps_place_category_destroy', + 'maps_place_category_get_id', + 'maps_place_category_get_name', + 'maps_place_category_get_url', + 'maps_place_category_set_id', + 'maps_place_category_set_name', + 'maps_place_category_set_url', + 'maps_place_clone', + 'maps_place_contact_clone', + 'maps_place_contact_destroy', + 'maps_place_contact_get_label', + 'maps_place_contact_get_type', + 'maps_place_contact_get_value', + 'maps_place_destroy', + 'maps_place_editorial_clone', + 'maps_place_editorial_destroy', + 'maps_place_editorial_get_description', + 'maps_place_editorial_get_language', + 'maps_place_editorial_get_media', + 'maps_place_filter_clone', + 'maps_place_filter_create', + 'maps_place_filter_destroy', + 'maps_place_filter_foreach_property', + 'maps_place_filter_get', + 'maps_place_filter_get_category', + 'maps_place_filter_get_keyword', + 'maps_place_filter_get_place_address', + 'maps_place_filter_get_place_name', + 'maps_place_filter_set', + 'maps_place_filter_set_category', + 'maps_place_filter_set_keyword', + 'maps_place_filter_set_place_address', + 'maps_place_filter_set_place_name', + 'maps_place_foreach_attribute', + 'maps_place_foreach_category', + 'maps_place_foreach_contact', + 'maps_place_foreach_editorial', + 'maps_place_foreach_image', + 'maps_place_foreach_property', + 'maps_place_foreach_review', + 'maps_place_get_address', + 'maps_place_get_distance', + 'maps_place_get_id', + 'maps_place_get_location', + 'maps_place_get_name', + 'maps_place_get_rating', + 'maps_place_get_related_link', + 'maps_place_get_supplier_link', + 'maps_place_get_uri', + 'maps_place_image_clone', + 'maps_place_image_destroy', + 'maps_place_image_get_height', + 'maps_place_image_get_id', + 'maps_place_image_get_media', + 'maps_place_image_get_url', + 'maps_place_image_get_user_link', + 'maps_place_image_get_width', + 'maps_place_link_object_clone', + 'maps_place_link_object_destroy', + 'maps_place_link_object_get_id', + 'maps_place_link_object_get_name', + 'maps_place_link_object_get_string', + 'maps_place_link_object_get_type', + 'maps_place_list_destroy', + 'maps_place_list_foreach', + 'maps_place_media_clone', + 'maps_place_media_destroy', + 'maps_place_media_get_attribution', + 'maps_place_media_get_supplier', + 'maps_place_media_get_via', + 'maps_place_rating_clone', + 'maps_place_rating_destroy', + 'maps_place_rating_get_average', + 'maps_place_rating_get_count', + 'maps_place_review_clone', + 'maps_place_review_destroy', + 'maps_place_review_get_date', + 'maps_place_review_get_description', + 'maps_place_review_get_language', + 'maps_place_review_get_media', + 'maps_place_review_get_rating', + 'maps_place_review_get_title', + 'maps_place_review_get_user_link', + 'maps_place_url_clone', + 'maps_place_url_destroy', + 'maps_place_url_get_description', + 'maps_place_url_get_path', + 'maps_preference_clone', + 'maps_preference_create', + 'maps_preference_destroy', + 'maps_preference_foreach_property', + 'maps_preference_get', + 'maps_preference_get_country_code', + 'maps_preference_get_distance_unit', + 'maps_preference_get_language', + 'maps_preference_get_max_results', + 'maps_preference_get_route_alternatives_enabled', + 'maps_preference_get_route_feature', + 'maps_preference_get_route_feature_weight', + 'maps_preference_get_route_optimization', + 'maps_preference_get_route_transport_mode', + 'maps_preference_set_country_code', + 'maps_preference_set_distance_unit', + 'maps_preference_set_language', + 'maps_preference_set_max_results', + 'maps_preference_set_property', + 'maps_preference_set_route_alternatives_enabled', + 'maps_preference_set_route_feature', + 'maps_preference_set_route_feature_weight', + 'maps_preference_set_route_optimization', + 'maps_preference_set_route_transport_mode', + 'maps_route_clone', + 'maps_route_destroy', + 'maps_route_foreach_path', + 'maps_route_foreach_property', + 'maps_route_foreach_segment', + 'maps_route_get_bounding_box', + 'maps_route_get_destination', + 'maps_route_get_distance_unit', + 'maps_route_get_origin', + 'maps_route_get_route_id', + 'maps_route_get_total_distance', + 'maps_route_get_total_duration', + 'maps_route_get_transport_mode', + 'maps_route_maneuver_clone', + 'maps_route_maneuver_destroy', + 'maps_route_maneuver_get_direction_id', + 'maps_route_maneuver_get_distance_to_next_instruction', + 'maps_route_maneuver_get_instruction_text', + 'maps_route_maneuver_get_locale', + 'maps_route_maneuver_get_position', + 'maps_route_maneuver_get_road_name', + 'maps_route_maneuver_get_time_to_next_instruction', + 'maps_route_maneuver_get_turn_type', + 'maps_route_segment_clone', + 'maps_route_segment_destroy', + 'maps_route_segment_foreach_maneuver', + 'maps_route_segment_foreach_path', + 'maps_route_segment_get_bounding_box', + 'maps_route_segment_get_destination', + 'maps_route_segment_get_distance', + 'maps_route_segment_get_duration', + 'maps_route_segment_get_origin', + 'maps_service_cancel_request', + 'maps_service_create', + 'maps_service_destroy', + 'maps_service_foreach_provider', + 'maps_service_geocode', + 'maps_service_geocode_by_structured_address', + 'maps_service_geocode_inside_area', + 'maps_service_get_place_details', + 'maps_service_get_preference', + 'maps_service_get_provider_key', + 'maps_service_multi_reverse_geocode', + 'maps_service_provider_is_data_supported', + 'maps_service_provider_is_service_supported', + 'maps_service_request_user_consent', + 'maps_service_reverse_geocode', + 'maps_service_search_place', + 'maps_service_search_place_by_address', + 'maps_service_search_place_by_area', + 'maps_service_search_place_list', + 'maps_service_search_route', + 'maps_service_search_route_waypoints', + 'maps_service_set_preference', + 'maps_service_set_provider_key', + 'maps_view_add_object', + 'maps_view_capture_snapshot', + 'maps_view_create', + 'maps_view_destroy', + 'maps_view_event_data_clone', + 'maps_view_event_data_destroy', + 'maps_view_event_data_get_action_type', + 'maps_view_event_data_get_center', + 'maps_view_event_data_get_coordinates', + 'maps_view_event_data_get_delta', + 'maps_view_event_data_get_fingers', + 'maps_view_event_data_get_gesture_type', + 'maps_view_event_data_get_object', + 'maps_view_event_data_get_position', + 'maps_view_event_data_get_rotation_angle', + 'maps_view_event_data_get_type', + 'maps_view_event_data_get_zoom_factor', + 'maps_view_foreach_object', + 'maps_view_geolocation_to_screen', + 'maps_view_get_buildings_enabled', + 'maps_view_get_center', + 'maps_view_get_gesture_enabled', + 'maps_view_get_language', + 'maps_view_get_max_zoom_level', + 'maps_view_get_min_zoom_level', + 'maps_view_get_orientation', + 'maps_view_get_public_transit_enabled', + 'maps_view_get_scalebar_enabled', + 'maps_view_get_screen_location', + 'maps_view_get_traffic_enabled', + 'maps_view_get_type', + 'maps_view_get_viewport', + 'maps_view_get_visibility', + 'maps_view_get_zoom_level', + 'maps_view_move', + 'maps_view_object_create_marker', + 'maps_view_object_create_overlay', + 'maps_view_object_create_polygon', + 'maps_view_object_create_polyline', + 'maps_view_object_destroy', + 'maps_view_object_get_type', + 'maps_view_object_get_visible', + 'maps_view_object_marker_get_coordinates', + 'maps_view_object_marker_get_image_file', + 'maps_view_object_marker_get_size', + 'maps_view_object_marker_get_type', + 'maps_view_object_marker_get_z_order', + 'maps_view_object_marker_resize', + 'maps_view_object_marker_set_coordinates', + 'maps_view_object_marker_set_image_file', + 'maps_view_object_marker_set_z_order', + 'maps_view_object_overlay_get_coordinates', + 'maps_view_object_overlay_get_max_zoom_level', + 'maps_view_object_overlay_get_min_zoom_level', + 'maps_view_object_overlay_get_object', + 'maps_view_object_overlay_set_coordinates', + 'maps_view_object_overlay_set_max_zoom_level', + 'maps_view_object_overlay_set_min_zoom_level', + 'maps_view_object_polygon_foreach_point', + 'maps_view_object_polygon_get_fill_color', + 'maps_view_object_polygon_set_fill_color', + 'maps_view_object_polygon_set_polygon', + 'maps_view_object_polyline_foreach_point', + 'maps_view_object_polyline_get_color', + 'maps_view_object_polyline_get_width', + 'maps_view_object_polyline_set_color', + 'maps_view_object_polyline_set_polyline', + 'maps_view_object_polyline_set_width', + 'maps_view_object_set_visible', + 'maps_view_remove_all_objects', + 'maps_view_remove_object', + 'maps_view_resize', + 'maps_view_screen_to_geolocation', + 'maps_view_set_buildings_enabled', + 'maps_view_set_center', + 'maps_view_set_event_cb', + 'maps_view_set_gesture_enabled', + 'maps_view_set_language', + 'maps_view_set_max_zoom_level', + 'maps_view_set_min_zoom_level', + 'maps_view_set_orientation', + 'maps_view_set_public_transit_enabled', + 'maps_view_set_scalebar_enabled', + 'maps_view_set_screen_location', + 'maps_view_set_traffic_enabled', + 'maps_view_set_type', + 'maps_view_set_visibility', + 'maps_view_set_zoom_level', + 'maps_view_unset_event_cb', + ], + 'libcapi-messaging-email.so.0': [ + 'email_add_attach', + 'email_add_recipient', + 'email_create_message', + 'email_destroy_message', + 'email_remove_all_attachments', + 'email_remove_all_recipients', + 'email_save_message', + 'email_send_message', + 'email_set_body', + 'email_set_message_sent_cb', + 'email_set_subject', + 'email_unset_message_sent_cb', + ], + 'libcapi-messaging-messages.so.0': [ + 'messages_add_address', + 'messages_add_message', + 'messages_add_sms_listening_port', + 'messages_close_service', + 'messages_create_message', + 'messages_destroy_message', + 'messages_foreach_message', + 'messages_free_message_array', + 'messages_get_address', + 'messages_get_address_count', + 'messages_get_mbox_type', + 'messages_get_message_count', + 'messages_get_message_id', + 'messages_get_message_port', + 'messages_get_message_type', + 'messages_get_sim_id', + 'messages_get_text', + 'messages_get_time', + 'messages_mms_add_attachment', + 'messages_mms_get_attachment', + 'messages_mms_get_attachment_count', + 'messages_mms_get_subject', + 'messages_mms_remove_all_attachments', + 'messages_mms_set_subject', + 'messages_open_service', + 'messages_push_add_incoming_cb', + 'messages_push_deregister', + 'messages_push_register', + 'messages_push_remove_incoming_cb', + 'messages_push_reregister', + 'messages_remove_all_addresses', + 'messages_search_message', + 'messages_search_message_by_id', + 'messages_send_message', + 'messages_set_mbox_type', + 'messages_set_message_incoming_cb', + 'messages_set_sim_id', + 'messages_set_text', + 'messages_set_time', + 'messages_unset_message_incoming_cb', + ], + 'libpush.so.0': [ + 'push_service_app_control_to_noti_data', + 'push_service_app_control_to_notification', + 'push_service_connect', + 'push_service_deregister', + 'push_service_disconnect', + 'push_service_free_notification', + 'push_service_get_notification_data', + 'push_service_get_notification_message', + 'push_service_get_notification_request_id', + 'push_service_get_notification_sender', + 'push_service_get_notification_session_info', + 'push_service_get_notification_time', + 'push_service_get_notification_type', + 'push_service_get_registration_id', + 'push_service_get_unread_notification', + 'push_service_register', + 'push_service_request_unread_notification', + ], + 'libcapi-media-audio-io.so.0': [ + 'audio_in_create', + 'audio_in_destroy', + 'audio_in_drop', + 'audio_in_flush', + 'audio_in_get_buffer_size', + 'audio_in_get_channel', + 'audio_in_get_sample_rate', + 'audio_in_get_sample_type', + 'audio_in_pause', + 'audio_in_peek', + 'audio_in_prepare', + 'audio_in_read', + 'audio_in_resume', + 'audio_in_set_sound_stream_info', + 'audio_in_set_state_changed_cb', + 'audio_in_set_stream_cb', + 'audio_in_unprepare', + 'audio_in_unset_state_changed_cb', + 'audio_in_unset_stream_cb', + 'audio_out_create_new', + 'audio_out_destroy', + 'audio_out_drain', + 'audio_out_flush', + 'audio_out_get_buffer_size', + 'audio_out_get_channel', + 'audio_out_get_sample_rate', + 'audio_out_get_sample_type', + 'audio_out_get_sound_type', + 'audio_out_pause', + 'audio_out_prepare', + 'audio_out_resume', + 'audio_out_set_sound_stream_info', + 'audio_out_set_state_changed_cb', + 'audio_out_set_stream_cb', + 'audio_out_unprepare', + 'audio_out_unset_state_changed_cb', + 'audio_out_unset_stream_cb', + 'audio_out_write', + ], + 'libcapi-media-camera.so.0': [ + 'camera_add_device_state_changed_cb', + 'camera_attr_clear_af_area', + 'camera_attr_disable_shutter_sound', + 'camera_attr_enable_anti_shake', + 'camera_attr_enable_auto_contrast', + 'camera_attr_enable_tag', + 'camera_attr_enable_video_stabilization', + 'camera_attr_foreach_supported_af_mode', + 'camera_attr_foreach_supported_effect', + 'camera_attr_foreach_supported_exposure_mode', + 'camera_attr_foreach_supported_flash_mode', + 'camera_attr_foreach_supported_fps', + 'camera_attr_foreach_supported_fps_by_resolution', + 'camera_attr_foreach_supported_iso', + 'camera_attr_foreach_supported_ptz_type', + 'camera_attr_foreach_supported_scene_mode', + 'camera_attr_foreach_supported_stream_flip', + 'camera_attr_foreach_supported_stream_rotation', + 'camera_attr_foreach_supported_theater_mode', + 'camera_attr_foreach_supported_whitebalance', + 'camera_attr_get_af_mode', + 'camera_attr_get_brightness', + 'camera_attr_get_brightness_range', + 'camera_attr_get_contrast', + 'camera_attr_get_contrast_range', + 'camera_attr_get_display_roi_area', + 'camera_attr_get_effect', + 'camera_attr_get_encoded_preview_bitrate', + 'camera_attr_get_encoded_preview_gop_interval', + 'camera_attr_get_exposure', + 'camera_attr_get_exposure_mode', + 'camera_attr_get_exposure_range', + 'camera_attr_get_flash_mode', + 'camera_attr_get_geotag', + 'camera_attr_get_hdr_mode', + 'camera_attr_get_hue', + 'camera_attr_get_hue_range', + 'camera_attr_get_image_quality', + 'camera_attr_get_iso', + 'camera_attr_get_lens_orientation', + 'camera_attr_get_pan', + 'camera_attr_get_pan_range', + 'camera_attr_get_preview_fps', + 'camera_attr_get_scene_mode', + 'camera_attr_get_stream_flip', + 'camera_attr_get_stream_rotation', + 'camera_attr_get_tag_image_description', + 'camera_attr_get_tag_orientation', + 'camera_attr_get_tag_software', + 'camera_attr_get_theater_mode', + 'camera_attr_get_tilt', + 'camera_attr_get_tilt_range', + 'camera_attr_get_whitebalance', + 'camera_attr_get_zoom', + 'camera_attr_get_zoom_range', + 'camera_attr_is_enabled_anti_shake', + 'camera_attr_is_enabled_auto_contrast', + 'camera_attr_is_enabled_tag', + 'camera_attr_is_enabled_video_stabilization', + 'camera_attr_is_supported_anti_shake', + 'camera_attr_is_supported_auto_contrast', + 'camera_attr_is_supported_hdr_capture', + 'camera_attr_is_supported_video_stabilization', + 'camera_attr_remove_geotag', + 'camera_attr_set_af_area', + 'camera_attr_set_af_mode', + 'camera_attr_set_brightness', + 'camera_attr_set_contrast', + 'camera_attr_set_display_roi_area', + 'camera_attr_set_effect', + 'camera_attr_set_encoded_preview_bitrate', + 'camera_attr_set_encoded_preview_gop_interval', + 'camera_attr_set_exposure', + 'camera_attr_set_exposure_mode', + 'camera_attr_set_flash_mode', + 'camera_attr_set_geotag', + 'camera_attr_set_hdr_capture_progress_cb', + 'camera_attr_set_hdr_mode', + 'camera_attr_set_hue', + 'camera_attr_set_image_quality', + 'camera_attr_set_iso', + 'camera_attr_set_pan', + 'camera_attr_set_preview_fps', + 'camera_attr_set_ptz_type', + 'camera_attr_set_scene_mode', + 'camera_attr_set_stream_flip', + 'camera_attr_set_stream_rotation', + 'camera_attr_set_tag_image_description', + 'camera_attr_set_tag_orientation', + 'camera_attr_set_tag_software', + 'camera_attr_set_theater_mode', + 'camera_attr_set_tilt', + 'camera_attr_set_whitebalance', + 'camera_attr_set_zoom', + 'camera_attr_unset_hdr_capture_progress_cb', + 'camera_cancel_focusing', + 'camera_change_device', + 'camera_create', + 'camera_destroy', + 'camera_foreach_supported_capture_format', + 'camera_foreach_supported_capture_resolution', + 'camera_foreach_supported_preview_format', + 'camera_foreach_supported_preview_resolution', + 'camera_get_capture_format', + 'camera_get_capture_resolution', + 'camera_get_device_count', + 'camera_get_device_state', + 'camera_get_display_flip', + 'camera_get_display_mode', + 'camera_get_display_reuse_hint', + 'camera_get_display_rotation', + 'camera_get_facing_direction', + 'camera_get_flash_state', + 'camera_get_preview_format', + 'camera_get_preview_resolution', + 'camera_get_recommended_preview_resolution', + 'camera_get_state', + 'camera_is_display_visible', + 'camera_is_supported_continuous_capture', + 'camera_is_supported_face_detection', + 'camera_is_supported_media_packet_preview_cb', + 'camera_is_supported_zero_shutter_lag', + 'camera_remove_device_state_changed_cb', + 'camera_set_capture_format', + 'camera_set_capture_resolution', + 'camera_set_display', + 'camera_set_display_flip', + 'camera_set_display_mode', + 'camera_set_display_reuse_hint', + 'camera_set_display_rotation', + 'camera_set_display_visible', + 'camera_set_error_cb', + 'camera_set_focus_changed_cb', + 'camera_set_interrupted_cb', + 'camera_set_interrupt_started_cb', + 'camera_set_media_packet_preview_cb', + 'camera_set_preview_cb', + 'camera_set_preview_format', + 'camera_set_preview_resolution', + 'camera_set_state_changed_cb', + 'camera_start_capture', + 'camera_start_continuous_capture', + 'camera_start_face_detection', + 'camera_start_focusing', + 'camera_start_preview', + 'camera_stop_continuous_capture', + 'camera_stop_face_detection', + 'camera_stop_preview', + 'camera_unset_error_cb', + 'camera_unset_focus_changed_cb', + 'camera_unset_interrupted_cb', + 'camera_unset_interrupt_started_cb', + 'camera_unset_media_packet_preview_cb', + 'camera_unset_preview_cb', + 'camera_unset_state_changed_cb', + ], + 'libcapi-media-image-util.so.0': [ + 'image_util_calculate_buffer_size', + 'image_util_decode_create', + 'image_util_decode_destroy', + 'image_util_decode_jpeg_from_memory_with_downscale', + 'image_util_decode_jpeg_with_downscale', + 'image_util_decode_run', + 'image_util_decode_run_async', + 'image_util_decode_set_colorspace', + 'image_util_decode_set_input_buffer', + 'image_util_decode_set_input_path', + 'image_util_decode_set_jpeg_downscale', + 'image_util_decode_set_output_buffer', + 'image_util_encode_create', + 'image_util_encode_destroy', + 'image_util_encode_run', + 'image_util_encode_run_async', + 'image_util_encode_set_colorspace', + 'image_util_encode_set_gif_frame_delay_time', + 'image_util_encode_set_input_buffer', + 'image_util_encode_set_output_buffer', + 'image_util_encode_set_output_path', + 'image_util_encode_set_png_compression', + 'image_util_encode_set_quality', + 'image_util_encode_set_resolution', + 'image_util_extract_color_from_memory', + 'image_util_foreach_supported_colorspace', + 'image_util_transform_create', + 'image_util_transform_destroy', + 'image_util_transform_get_colorspace', + 'image_util_transform_get_crop_area', + 'image_util_transform_get_resolution', + 'image_util_transform_get_rotation', + 'image_util_transform_run', + 'image_util_transform_set_colorspace', + 'image_util_transform_set_crop_area', + 'image_util_transform_set_hardware_acceleration', + 'image_util_transform_set_resolution', + 'image_util_transform_set_rotation', + ], + 'libcapi-media-codec.so.0': [ + 'mediacodec_configure_from_media_format', + 'mediacodec_create', + 'mediacodec_destroy', + 'mediacodec_foreach_supported_codec', + 'mediacodec_get_output', + 'mediacodec_get_packet_pool', + 'mediacodec_get_supported_type', + 'mediacodec_prepare', + 'mediacodec_process_input', + 'mediacodec_set_adec_info', + 'mediacodec_set_aenc_info', + 'mediacodec_set_buffer_status_cb', + 'mediacodec_set_codec', + 'mediacodec_set_eos_cb', + 'mediacodec_set_error_cb', + 'mediacodec_set_input_buffer_used_cb', + 'mediacodec_set_output_buffer_available_cb', + 'mediacodec_set_vdec_info', + 'mediacodec_set_venc_info', + 'mediacodec_unprepare', + 'mediacodec_unset_buffer_status_cb', + 'mediacodec_unset_eos_cb', + 'mediacodec_unset_error_cb', + 'mediacodec_unset_input_buffer_used_cb', + 'mediacodec_unset_output_buffer_available_cb', + ], + 'libcapi-media-controller.so.0': [ + 'mc_client_create', + 'mc_client_destroy', + 'mc_client_destroy_playback', + 'mc_client_foreach_server', + 'mc_client_foreach_server_playlist', + 'mc_client_foreach_server_subscribed', + 'mc_client_get_latest_server_info', + 'mc_client_get_playback_position', + 'mc_client_get_playback_state', + 'mc_client_get_playlist_item_index', + 'mc_client_get_server_metadata', + 'mc_client_get_server_playback_info', + 'mc_client_get_server_repeat_mode', + 'mc_client_get_server_shuffle_mode', + 'mc_client_send_custom_cmd', + 'mc_client_send_event_reply', + 'mc_client_send_playback_action_cmd', + 'mc_client_send_playback_position_cmd', + 'mc_client_send_playlist_cmd', + 'mc_client_send_repeat_mode_cmd', + 'mc_client_send_shuffle_mode_cmd', + 'mc_client_set_cmd_reply_received_cb', + 'mc_client_set_custom_event_received_cb', + 'mc_client_set_metadata_updated_cb', + 'mc_client_set_playback_updated_cb', + 'mc_client_set_playlist_updated_cb', + 'mc_client_set_repeat_mode_updated_cb', + 'mc_client_set_server_updated_cb', + 'mc_client_set_shuffle_mode_updated_cb', + 'mc_client_subscribe', + 'mc_client_unset_cmd_reply_received_cb', + 'mc_client_unset_custom_event_received_cb', + 'mc_client_unset_metadata_updated_cb', + 'mc_client_unset_playback_updated_cb', + 'mc_client_unset_playlist_updated_cb', + 'mc_client_unset_repeat_mode_updated_cb', + 'mc_client_unset_server_updated_cb', + 'mc_client_unset_shuffle_mode_updated_cb', + 'mc_client_unsubscribe', + 'mc_metadata_clone', + 'mc_metadata_destroy', + 'mc_metadata_get', + 'mc_playlist_clone', + 'mc_playlist_destroy', + 'mc_playlist_foreach_item', + 'mc_playlist_get_name', + 'mc_server_add_item_to_playlist', + 'mc_server_create', + 'mc_server_create_playlist', + 'mc_server_delete_playlist', + 'mc_server_destroy', + 'mc_server_foreach_client', + 'mc_server_foreach_playlist', + 'mc_server_send_cmd_reply', + 'mc_server_send_custom_event', + 'mc_server_set_custom_cmd_received_cb', + 'mc_server_set_event_reply_received_cb', + 'mc_server_set_metadata', + 'mc_server_set_playback_action_cmd_received_cb', + 'mc_server_set_playback_position', + 'mc_server_set_playback_position_cmd_received_cb', + 'mc_server_set_playback_state', + 'mc_server_set_playlist_cmd_received_cb', + 'mc_server_set_playlist_item_index', + 'mc_server_set_repeat_mode_cmd_received_cb', + 'mc_server_set_shuffle_mode_cmd_received_cb', + 'mc_server_unset_custom_cmd_received_cb', + 'mc_server_unset_event_reply_received_cb', + 'mc_server_unset_playback_action_cmd_received_cb', + 'mc_server_unset_playback_position_cmd_received_cb', + 'mc_server_unset_playlist_cmd_received_cb', + 'mc_server_unset_repeat_mode_cmd_received_cb', + 'mc_server_unset_shuffle_mode_cmd_received_cb', + 'mc_server_update_metadata', + 'mc_server_update_playback_info', + 'mc_server_update_playlist_done', + 'mc_server_update_repeat_mode', + 'mc_server_update_shuffle_mode', + ], + 'libcapi-mediademuxer.so.0': [ + 'mediademuxer_create', + 'mediademuxer_destroy', + 'mediademuxer_get_state', + 'mediademuxer_get_track_count', + 'mediademuxer_get_track_info', + 'mediademuxer_prepare', + 'mediademuxer_read_sample', + 'mediademuxer_seek', + 'mediademuxer_select_track', + 'mediademuxer_set_data_source', + 'mediademuxer_set_eos_cb', + 'mediademuxer_set_error_cb', + 'mediademuxer_start', + 'mediademuxer_stop', + 'mediademuxer_unprepare', + 'mediademuxer_unselect_track', + 'mediademuxer_unset_eos_cb', + 'mediademuxer_unset_error_cb', + ], + 'libcapi-mediamuxer.so.0': [ + 'mediamuxer_add_track', + 'mediamuxer_close_track', + 'mediamuxer_create', + 'mediamuxer_destroy', + 'mediamuxer_get_state', + 'mediamuxer_pause', + 'mediamuxer_prepare', + 'mediamuxer_resume', + 'mediamuxer_set_data_sink', + 'mediamuxer_set_eos_cb', + 'mediamuxer_set_error_cb', + 'mediamuxer_start', + 'mediamuxer_stop', + 'mediamuxer_unprepare', + 'mediamuxer_unset_eos_cb', + 'mediamuxer_unset_error_cb', + 'mediamuxer_write_sample', + ], + 'libcapi-media-streamer.so.0': [ + 'media_streamer_create', + 'media_streamer_destroy', + 'media_streamer_get_duration', + 'media_streamer_get_play_position', + 'media_streamer_get_state', + 'media_streamer_node_add', + 'media_streamer_node_create', + 'media_streamer_node_create_sink', + 'media_streamer_node_create_src', + 'media_streamer_node_destroy', + 'media_streamer_node_get_pad_format', + 'media_streamer_node_get_pad_name', + 'media_streamer_node_get_param', + 'media_streamer_node_get_params', + 'media_streamer_node_link', + 'media_streamer_node_pull_packet', + 'media_streamer_node_push_packet', + 'media_streamer_node_remove', + 'media_streamer_node_set_pad_format', + 'media_streamer_node_set_param', + 'media_streamer_node_set_params', + 'media_streamer_pause', + 'media_streamer_play', + 'media_streamer_prepare', + 'media_streamer_set_error_cb', + 'media_streamer_set_interrupted_cb', + 'media_streamer_set_play_position', + 'media_streamer_set_state_change_cb', + 'media_streamer_sink_set_data_ready_cb', + 'media_streamer_sink_set_eos_cb', + 'media_streamer_sink_unset_data_ready_cb', + 'media_streamer_sink_unset_eos_cb', + 'media_streamer_src_set_buffer_status_cb', + 'media_streamer_src_unset_buffer_status_cb', + 'media_streamer_stop', + 'media_streamer_unprepare', + 'media_streamer_unset_error_cb', + 'media_streamer_unset_interrupted_cb', + 'media_streamer_unset_state_change_cb', + ], + 'libcapi-media-tool.so.0': [ + 'media_format_create', + 'media_format_get_audio_aac_header_type', + 'media_format_get_audio_aac_type', + 'media_format_get_audio_info', + 'media_format_get_container_mime', + 'media_format_get_extra', + 'media_format_get_text_info', + 'media_format_get_type', + 'media_format_get_video_frame_rate', + 'media_format_get_video_info', + 'media_format_is_writable', + 'media_format_make_writable', + 'media_format_ref', + 'media_format_set_audio_aac_header_type', + 'media_format_set_audio_aac_type', + 'media_format_set_audio_avg_bps', + 'media_format_set_audio_bit', + 'media_format_set_audio_channel', + 'media_format_set_audio_mime', + 'media_format_set_audio_samplerate', + 'media_format_set_container_mime', + 'media_format_set_extra', + 'media_format_set_text_mime', + 'media_format_set_text_type', + 'media_format_set_video_avg_bps', + 'media_format_set_video_frame_rate', + 'media_format_set_video_height', + 'media_format_set_video_max_bps', + 'media_format_set_video_mime', + 'media_format_set_video_width', + 'media_format_unref', + 'media_packet_alloc', + 'media_packet_copy', + 'media_packet_create', + 'media_packet_create_alloc', + 'media_packet_create_from_external_memory', + 'media_packet_create_from_tbm_surface', + 'media_packet_destroy', + 'media_packet_get_buffer_data_ptr', + 'media_packet_get_buffer_size', + 'media_packet_get_codec_data', + 'media_packet_get_dts', + 'media_packet_get_duration', + 'media_packet_get_extra', + 'media_packet_get_flags', + 'media_packet_get_format', + 'media_packet_get_number_of_video_planes', + 'media_packet_get_pts', + 'media_packet_get_tbm_surface', + 'media_packet_get_video_plane_data_ptr', + 'media_packet_get_video_stride_height', + 'media_packet_get_video_stride_width', + 'media_packet_has_tbm_surface_buffer', + 'media_packet_is_audio', + 'media_packet_is_codec_config', + 'media_packet_is_encoded', + 'media_packet_is_end_of_stream', + 'media_packet_is_raw', + 'media_packet_is_sync_frame', + 'media_packet_is_text', + 'media_packet_is_video', + 'media_packet_pool_acquire_packet', + 'media_packet_pool_allocate', + 'media_packet_pool_create', + 'media_packet_pool_deallocate', + 'media_packet_pool_destroy', + 'media_packet_pool_get_size', + 'media_packet_pool_release_packet', + 'media_packet_pool_set_media_format', + 'media_packet_pool_set_size', + 'media_packet_set_buffer_size', + 'media_packet_set_dts', + 'media_packet_set_duration', + 'media_packet_set_extra', + 'media_packet_set_flags', + 'media_packet_set_format', + 'media_packet_set_pts', + 'media_packet_unset_flags', + ], + 'libcapi-media-vision.so.0': [ + 'mv_barcode_detect', + 'mv_barcode_generate_image', + 'mv_barcode_generate_source', + 'mv_create_engine_config', + 'mv_create_source', + 'mv_destroy_engine_config', + 'mv_destroy_source', + 'mv_engine_config_foreach_supported_attribute', + 'mv_engine_config_get_bool_attribute', + 'mv_engine_config_get_double_attribute', + 'mv_engine_config_get_int_attribute', + 'mv_engine_config_get_string_attribute', + 'mv_engine_config_set_bool_attribute', + 'mv_engine_config_set_double_attribute', + 'mv_engine_config_set_int_attribute', + 'mv_engine_config_set_string_attribute', + 'mv_face_detect', + 'mv_face_eye_condition_recognize', + 'mv_face_facial_expression_recognize', + 'mv_face_recognition_model_add', + 'mv_face_recognition_model_clone', + 'mv_face_recognition_model_create', + 'mv_face_recognition_model_destroy', + 'mv_face_recognition_model_learn', + 'mv_face_recognition_model_load', + 'mv_face_recognition_model_query_labels', + 'mv_face_recognition_model_reset', + 'mv_face_recognition_model_save', + 'mv_face_recognize', + 'mv_face_track', + 'mv_face_tracking_model_clone', + 'mv_face_tracking_model_create', + 'mv_face_tracking_model_destroy', + 'mv_face_tracking_model_load', + 'mv_face_tracking_model_prepare', + 'mv_face_tracking_model_save', + 'mv_image_object_clone', + 'mv_image_object_create', + 'mv_image_object_destroy', + 'mv_image_object_fill', + 'mv_image_object_get_label', + 'mv_image_object_get_recognition_rate', + 'mv_image_object_load', + 'mv_image_object_save', + 'mv_image_object_set_label', + 'mv_image_recognize', + 'mv_image_track', + 'mv_image_tracking_model_clone', + 'mv_image_tracking_model_create', + 'mv_image_tracking_model_destroy', + 'mv_image_tracking_model_load', + 'mv_image_tracking_model_refresh', + 'mv_image_tracking_model_save', + 'mv_image_tracking_model_set_target', + 'mv_source_clear', + 'mv_source_fill_by_buffer', + 'mv_source_fill_by_media_packet', + 'mv_source_get_buffer', + 'mv_source_get_colorspace', + 'mv_source_get_height', + 'mv_source_get_width', + 'mv_surveillance_event_trigger_create', + 'mv_surveillance_event_trigger_destroy', + 'mv_surveillance_foreach_event_result_name', + 'mv_surveillance_foreach_supported_event_type', + 'mv_surveillance_get_event_trigger_roi', + 'mv_surveillance_get_event_trigger_type', + 'mv_surveillance_get_result_value', + 'mv_surveillance_push_source', + 'mv_surveillance_set_event_trigger_roi', + 'mv_surveillance_subscribe_event_trigger', + 'mv_surveillance_unsubscribe_event_trigger', + ], + 'libcapi-media-metadata-editor.so': [ + 'metadata_editor_append_picture', + 'metadata_editor_create', + 'metadata_editor_destroy', + 'metadata_editor_get_metadata', + 'metadata_editor_get_picture', + 'metadata_editor_remove_picture', + 'metadata_editor_set_metadata', + 'metadata_editor_set_path', + 'metadata_editor_update_metadata', + ], + 'libcapi-media-metadata-extractor.so': [ + 'metadata_extractor_create', + 'metadata_extractor_destroy', + 'metadata_extractor_get_artwork', + 'metadata_extractor_get_frame', + 'metadata_extractor_get_frame_at_time', + 'metadata_extractor_get_metadata', + 'metadata_extractor_get_synclyrics', + 'metadata_extractor_set_buffer', + 'metadata_extractor_set_path', + ], + 'libcapi-media-player.so.0': [ + 'player_audio_effect_equalizer_clear', + 'player_audio_effect_equalizer_is_available', + 'player_audio_effect_get_equalizer_band_frequency', + 'player_audio_effect_get_equalizer_band_frequency_range', + 'player_audio_effect_get_equalizer_band_level', + 'player_audio_effect_get_equalizer_bands_count', + 'player_audio_effect_get_equalizer_level_range', + 'player_audio_effect_set_equalizer_all_bands', + 'player_audio_effect_set_equalizer_band_level', + 'player_capture_video', + 'player_create', + 'player_destroy', + 'player_foreach_adaptive_variant', + 'player_get_album_art', + 'player_get_audio_latency_mode', + 'player_get_audio_stream_info', + 'player_get_codec_info', + 'player_get_content_info', + 'player_get_current_track', + 'player_get_display_mode', + 'player_get_display_rotation', + 'player_get_duration', + 'player_get_max_adaptive_variant_limit', + 'player_get_media_stream_buffer_max_size', + 'player_get_media_stream_buffer_min_threshold', + 'player_get_play_position', + 'player_get_state', + 'player_get_streaming_buffering_time', + 'player_get_streaming_download_progress', + 'player_get_track_count', + 'player_get_track_language_code', + 'player_get_video_size', + 'player_get_video_stream_info', + 'player_get_volume', + 'player_is_audio_only', + 'player_is_display_visible', + 'player_is_looping', + 'player_is_muted', + 'player_pause', + 'player_prepare', + 'player_prepare_async', + 'player_push_media_stream', + 'player_select_track', + 'player_set_audio_latency_mode', + 'player_set_audio_only', + 'player_set_buffering_cb', + 'player_set_completed_cb', + 'player_set_display', + 'player_set_display_mode', + 'player_set_display_roi_area', + 'player_set_display_rotation', + 'player_set_display_visible', + 'player_set_error_cb', + 'player_set_interrupted_cb', + 'player_set_looping', + 'player_set_max_adaptive_variant_limit', + 'player_set_media_packet_video_frame_decoded_cb', + 'player_set_media_stream_buffer_max_size', + 'player_set_media_stream_buffer_min_threshold', + 'player_set_media_stream_buffer_status_cb', + 'player_set_media_stream_info', + 'player_set_media_stream_seek_cb', + 'player_set_memory_buffer', + 'player_set_mute', + 'player_set_playback_rate', + 'player_set_play_position', + 'player_set_sound_stream_info', + 'player_set_streaming_buffering_time', + 'player_set_streaming_cookie', + 'player_set_streaming_user_agent', + 'player_set_subtitle_path', + 'player_set_subtitle_position_offset', + 'player_set_subtitle_updated_cb', + 'player_set_uri', + 'player_set_video_stream_changed_cb', + 'player_set_volume', + 'player_start', + 'player_stop', + 'player_unprepare', + 'player_unset_buffering_cb', + 'player_unset_completed_cb', + 'player_unset_error_cb', + 'player_unset_interrupted_cb', + 'player_unset_media_packet_video_frame_decoded_cb', + 'player_unset_media_stream_buffer_status_cb', + 'player_unset_media_stream_seek_cb', + 'player_unset_subtitle_updated_cb', + 'player_unset_video_stream_changed_cb', + ], + 'libcapi-media-radio.so.0': [ + 'radio_create', + 'radio_destroy', + 'radio_get_channel_spacing', + 'radio_get_frequency', + 'radio_get_frequency_range', + 'radio_get_signal_strength', + 'radio_get_state', + 'radio_get_volume', + 'radio_is_muted', + 'radio_scan_start', + 'radio_scan_stop', + 'radio_seek_down', + 'radio_seek_up', + 'radio_set_frequency', + 'radio_set_interrupted_cb', + 'radio_set_mute', + 'radio_set_scan_completed_cb', + 'radio_set_volume', + 'radio_start', + 'radio_stop', + 'radio_unset_interrupted_cb', + 'radio_unset_scan_completed_cb', + ], + 'libcapi-media-recorder.so.0': [ + 'recorder_add_device_state_changed_cb', + 'recorder_attr_get_audio_channel', + 'recorder_attr_get_audio_device', + 'recorder_attr_get_audio_encoder_bitrate', + 'recorder_attr_get_audio_samplerate', + 'recorder_attr_get_orientation_tag', + 'recorder_attr_get_recording_motion_rate', + 'recorder_attr_get_size_limit', + 'recorder_attr_get_time_limit', + 'recorder_attr_get_video_encoder_bitrate', + 'recorder_attr_is_muted', + 'recorder_attr_set_audio_channel', + 'recorder_attr_set_audio_device', + 'recorder_attr_set_audio_encoder_bitrate', + 'recorder_attr_set_audio_samplerate', + 'recorder_attr_set_mute', + 'recorder_attr_set_orientation_tag', + 'recorder_attr_set_recording_motion_rate', + 'recorder_attr_set_size_limit', + 'recorder_attr_set_time_limit', + 'recorder_attr_set_video_encoder_bitrate', + 'recorder_cancel', + 'recorder_commit', + 'recorder_create_audiorecorder', + 'recorder_create_videorecorder', + 'recorder_destroy', + 'recorder_foreach_supported_audio_encoder', + 'recorder_foreach_supported_file_format', + 'recorder_foreach_supported_video_encoder', + 'recorder_foreach_supported_video_resolution', + 'recorder_get_audio_encoder', + 'recorder_get_audio_level', + 'recorder_get_device_state', + 'recorder_get_file_format', + 'recorder_get_filename', + 'recorder_get_state', + 'recorder_get_video_encoder', + 'recorder_get_video_resolution', + 'recorder_pause', + 'recorder_prepare', + 'recorder_remove_device_state_changed_cb', + 'recorder_set_audio_encoder', + 'recorder_set_audio_stream_cb', + 'recorder_set_error_cb', + 'recorder_set_file_format', + 'recorder_set_filename', + 'recorder_set_interrupted_cb', + 'recorder_set_interrupt_started_cb', + 'recorder_set_muxed_stream_cb', + 'recorder_set_recording_limit_reached_cb', + 'recorder_set_recording_status_cb', + 'recorder_set_sound_stream_info', + 'recorder_set_state_changed_cb', + 'recorder_set_video_encoder', + 'recorder_set_video_resolution', + 'recorder_start', + 'recorder_unprepare', + 'recorder_unset_audio_stream_cb', + 'recorder_unset_error_cb', + 'recorder_unset_interrupted_cb', + 'recorder_unset_interrupt_started_cb', + 'recorder_unset_muxed_stream_cb', + 'recorder_unset_recording_limit_reached_cb', + 'recorder_unset_recording_status_cb', + 'recorder_unset_state_changed_cb', + ], + 'libcapi-media-sound-manager.so.0': [ + 'sound_manager_acquire_focus', + 'sound_manager_acquire_focus_all', + 'sound_manager_add_device_connection_changed_cb', + 'sound_manager_add_device_for_stream_routing', + 'sound_manager_add_focus_state_watch_cb', + 'sound_manager_add_volume_changed_cb', + 'sound_manager_apply_stream_routing', + 'sound_manager_create_stream_information', + 'sound_manager_deliver_focus', + 'sound_manager_destroy_stream_information', + 'sound_manager_free_device_list', + 'sound_manager_get_current_media_playback_device_type', + 'sound_manager_get_current_playback_focus', + 'sound_manager_get_current_recording_focus', + 'sound_manager_get_current_sound_type', + 'sound_manager_get_device_id', + 'sound_manager_get_device_io_direction', + 'sound_manager_get_device_list', + 'sound_manager_get_device_name', + 'sound_manager_get_device_type', + 'sound_manager_get_focus_reacquisition', + 'sound_manager_get_focus_state', + 'sound_manager_get_max_volume', + 'sound_manager_get_next_device', + 'sound_manager_get_prev_device', + 'sound_manager_get_sound_type', + 'sound_manager_get_volume', + 'sound_manager_is_stream_on_device', + 'sound_manager_release_focus', + 'sound_manager_release_focus_all', + 'sound_manager_remove_all_devices_for_stream_routing', + 'sound_manager_remove_device_connection_changed_cb', + 'sound_manager_remove_device_for_stream_routing', + 'sound_manager_remove_focus_state_watch_cb', + 'sound_manager_remove_volume_changed_cb', + 'sound_manager_set_focus_reacquisition', + 'sound_manager_set_volume', + ], + 'libcapi-media-sound-pool.so.0': [ + 'sound_pool_activate', + 'sound_pool_create', + 'sound_pool_deactivate', + 'sound_pool_destroy', + 'sound_pool_get_state', + 'sound_pool_get_volume', + 'sound_pool_load_source_from_file', + 'sound_pool_set_state_changed_cb', + 'sound_pool_set_volume', + 'sound_pool_stream_get_priority', + 'sound_pool_stream_get_state', + 'sound_pool_stream_get_volume', + 'sound_pool_stream_pause', + 'sound_pool_stream_play', + 'sound_pool_stream_resume', + 'sound_pool_stream_set_priority', + 'sound_pool_stream_set_volume', + 'sound_pool_stream_stop', + 'sound_pool_unload_source', + 'sound_pool_unset_state_changed_cb', + ], + 'libcapi-media-streamrecorder.so.0': [ + 'streamrecorder_cancel', + 'streamrecorder_commit', + 'streamrecorder_create', + 'streamrecorder_destroy', + 'streamrecorder_enable_source_buffer', + 'streamrecorder_foreach_supported_audio_encoder', + 'streamrecorder_foreach_supported_file_format', + 'streamrecorder_foreach_supported_video_encoder', + 'streamrecorder_foreach_supported_video_resolution', + 'streamrecorder_get_audio_channel', + 'streamrecorder_get_audio_encoder', + 'streamrecorder_get_audio_encoder_bitrate', + 'streamrecorder_get_audio_samplerate', + 'streamrecorder_get_file_format', + 'streamrecorder_get_filename', + 'streamrecorder_get_recording_limit', + 'streamrecorder_get_state', + 'streamrecorder_get_video_encoder', + 'streamrecorder_get_video_encoder_bitrate', + 'streamrecorder_get_video_framerate', + 'streamrecorder_get_video_resolution', + 'streamrecorder_get_video_source_format', + 'streamrecorder_pause', + 'streamrecorder_prepare', + 'streamrecorder_push_stream_buffer', + 'streamrecorder_set_audio_channel', + 'streamrecorder_set_audio_encoder', + 'streamrecorder_set_audio_encoder_bitrate', + 'streamrecorder_set_audio_samplerate', + 'streamrecorder_set_buffer_consume_completed_cb', + 'streamrecorder_set_error_cb', + 'streamrecorder_set_file_format', + 'streamrecorder_set_filename', + 'streamrecorder_set_notify_cb', + 'streamrecorder_set_recording_limit', + 'streamrecorder_set_recording_limit_reached_cb', + 'streamrecorder_set_recording_status_cb', + 'streamrecorder_set_video_encoder', + 'streamrecorder_set_video_encoder_bitrate', + 'streamrecorder_set_video_framerate', + 'streamrecorder_set_video_resolution', + 'streamrecorder_set_video_source_format', + 'streamrecorder_start', + 'streamrecorder_unprepare', + 'streamrecorder_unset_buffer_consume_completed_cb', + 'streamrecorder_unset_error_cb', + 'streamrecorder_unset_notify_cb', + 'streamrecorder_unset_recording_limit_reached_cb', + 'streamrecorder_unset_recording_status_cb', + ], + 'libcapi-media-thumbnail-util.so': [ + 'thumbnail_util_cancel', + 'thumbnail_util_create', + 'thumbnail_util_destroy', + 'thumbnail_util_extract', + 'thumbnail_util_set_path', + 'thumbnail_util_set_size', + ], + 'libcapi-media-tone-player.so.0': [ + 'tone_player_start_new', + 'tone_player_stop', + ], + 'libcapi-media-wav-player.so.0': [ + 'wav_player_start_new', + 'wav_player_stop', + ], + 'libasp.so.0': [ + 'asp_advert_add_info', + 'asp_advert_change_service_status', + 'asp_advert_create', + 'asp_advert_destroy', + 'asp_advert_get_info', + 'asp_advert_get_p2p_config_method', + 'asp_advert_get_p2p_role_scheme', + 'asp_advert_remove_info', + 'asp_advert_set_auto_accept', + 'asp_advert_set_discovery_tech', + 'asp_advert_set_p2p_config_method', + 'asp_advert_set_p2p_response', + 'asp_advert_set_p2p_role_scheme', + 'asp_advert_set_preferred_connection', + 'asp_advert_set_service_type', + 'asp_advert_set_status', + 'asp_advert_set_status_changed_cb', + 'asp_advert_start_advertising', + 'asp_advert_stop_advertising', + 'asp_advert_unset_status_changed_cb', + 'asp_deinitialize', + 'asp_initialize', + 'asp_seek_add_info', + 'asp_seek_create', + 'asp_seek_destroy', + 'asp_seek_remove_info', + 'asp_seek_set_discovery_tech', + 'asp_seek_set_preferred_connection', + 'asp_seek_set_search_result_cb', + 'asp_seek_start', + 'asp_seek_stop', + 'asp_seek_unset_search_result_cb', + 'asp_session_bind_port', + 'asp_session_close', + 'asp_session_confirm', + 'asp_session_connect', + 'asp_session_create', + 'asp_session_destroy', + 'asp_session_get_close_status', + 'asp_session_get_handle', + 'asp_session_get_id', + 'asp_session_get_info', + 'asp_session_get_mac', + 'asp_session_get_p2p_config_method', + 'asp_session_get_p2p_role_scheme', + 'asp_session_release_port', + 'asp_session_set_config_request_cb', + 'asp_session_set_connect_status_cb', + 'asp_session_set_info', + 'asp_session_set_p2p_config_method', + 'asp_session_set_p2p_role_scheme', + 'asp_session_set_port_status_cb', + 'asp_session_set_request_cb', + 'asp_session_set_state_ready', + 'asp_session_set_status_cb', + 'asp_session_unset_config_request_cb', + 'asp_session_unset_connect_status_cb', + 'asp_session_unset_port_status_cb', + 'asp_session_unset_request_cb', + 'asp_session_unset_status_cb', + ], + 'libcapi-network-bluetooth.so.0': [ + 'bt_adapter_foreach_bonded_device', + 'bt_adapter_free_device_info', + 'bt_adapter_get_address', + 'bt_adapter_get_bonded_device_info', + 'bt_adapter_get_local_oob_data', + 'bt_adapter_get_local_oob_ext_data', + 'bt_adapter_get_name', + 'bt_adapter_get_state', + 'bt_adapter_get_visibility', + 'bt_adapter_is_discovering', + 'bt_adapter_is_service_used', + 'bt_adapter_le_add_advertising_data', + 'bt_adapter_le_add_advertising_manufacturer_data', + 'bt_adapter_le_add_advertising_service_data', + 'bt_adapter_le_add_advertising_service_solicitation_uuid', + 'bt_adapter_le_add_advertising_service_uuid', + 'bt_adapter_le_clear_advertising_data', + 'bt_adapter_le_create_advertiser', + 'bt_adapter_le_destroy_advertiser', + 'bt_adapter_le_free_ibeacon_report', + 'bt_adapter_le_free_service_data_list', + 'bt_adapter_le_get_scan_result_appearance', + 'bt_adapter_le_get_scan_result_device_name', + 'bt_adapter_le_get_scan_result_ibeacon_report', + 'bt_adapter_le_get_scan_result_manufacturer_data', + 'bt_adapter_le_get_scan_result_service_data_list', + 'bt_adapter_le_get_scan_result_service_solicitation_uuids', + 'bt_adapter_le_get_scan_result_service_uuids', + 'bt_adapter_le_get_scan_result_tx_power_level', + 'bt_adapter_le_is_discovering', + 'bt_adapter_le_remove_advertising_data', + 'bt_adapter_le_scan_filter_create', + 'bt_adapter_le_scan_filter_destroy', + 'bt_adapter_le_scan_filter_register', + 'bt_adapter_le_scan_filter_set_device_address', + 'bt_adapter_le_scan_filter_set_device_name', + 'bt_adapter_le_scan_filter_set_manufacturer_data', + 'bt_adapter_le_scan_filter_set_manufacturer_data_with_mask', + 'bt_adapter_le_scan_filter_set_service_data', + 'bt_adapter_le_scan_filter_set_service_data_with_mask', + 'bt_adapter_le_scan_filter_set_service_solicitation_uuid', + 'bt_adapter_le_scan_filter_set_service_solicitation_uuid_with_mask', + 'bt_adapter_le_scan_filter_set_service_uuid', + 'bt_adapter_le_scan_filter_set_service_uuid_with_mask', + 'bt_adapter_le_scan_filter_set_type', + 'bt_adapter_le_scan_filter_unregister', + 'bt_adapter_le_scan_filter_unregister_all', + 'bt_adapter_le_set_advertising_appearance', + 'bt_adapter_le_set_advertising_connectable', + 'bt_adapter_le_set_advertising_device_name', + 'bt_adapter_le_set_advertising_mode', + 'bt_adapter_le_set_advertising_tx_power_level', + 'bt_adapter_le_set_device_discovery_state_changed_cb', + 'bt_adapter_le_set_scan_mode', + 'bt_adapter_le_start_advertising', + 'bt_adapter_le_start_advertising_new', + 'bt_adapter_le_start_device_discovery', + 'bt_adapter_le_start_scan', + 'bt_adapter_le_stop_advertising', + 'bt_adapter_le_stop_device_discovery', + 'bt_adapter_le_stop_scan', + 'bt_adapter_le_unset_device_discovery_state_changed_cb', + 'bt_adapter_remove_remote_oob_data', + 'bt_adapter_set_device_discovery_state_changed_cb', + 'bt_adapter_set_name', + 'bt_adapter_set_name_changed_cb', + 'bt_adapter_set_remote_oob_data', + 'bt_adapter_set_remote_oob_ext_data', + 'bt_adapter_set_state_changed_cb', + 'bt_adapter_set_visibility_duration_changed_cb', + 'bt_adapter_set_visibility_mode_changed_cb', + 'bt_adapter_start_device_discovery', + 'bt_adapter_stop_device_discovery', + 'bt_adapter_unset_device_discovery_state_changed_cb', + 'bt_adapter_unset_name_changed_cb', + 'bt_adapter_unset_state_changed_cb', + 'bt_adapter_unset_visibility_duration_changed_cb', + 'bt_adapter_unset_visibility_mode_changed_cb', + 'bt_audio_connect', + 'bt_audio_deinitialize', + 'bt_audio_disconnect', + 'bt_audio_initialize', + 'bt_audio_set_connection_state_changed_cb', + 'bt_audio_unset_connection_state_changed_cb', + 'bt_avrcp_control_connect', + 'bt_avrcp_control_deinitialize', + 'bt_avrcp_control_disconnect', + 'bt_avrcp_control_free_track_info', + 'bt_avrcp_control_get_equalizer_state', + 'bt_avrcp_control_get_play_status', + 'bt_avrcp_control_get_position', + 'bt_avrcp_control_get_repeat_mode', + 'bt_avrcp_control_get_scan_mode', + 'bt_avrcp_control_get_shuffle_mode', + 'bt_avrcp_control_get_track_info', + 'bt_avrcp_control_initialize', + 'bt_avrcp_control_send_player_command', + 'bt_avrcp_control_set_equalizer_state', + 'bt_avrcp_control_set_repeat_mode', + 'bt_avrcp_control_set_scan_mode', + 'bt_avrcp_control_set_shuffle_mode', + 'bt_avrcp_set_equalizer_state_changed_cb', + 'bt_avrcp_set_play_status_changed_cb', + 'bt_avrcp_set_position_changed_cb', + 'bt_avrcp_set_repeat_mode_changed_cb', + 'bt_avrcp_set_scan_mode_changed_cb', + 'bt_avrcp_set_shuffle_mode_changed_cb', + 'bt_avrcp_set_track_info_changed_cb', + 'bt_avrcp_target_deinitialize', + 'bt_avrcp_target_initialize', + 'bt_avrcp_target_notify_equalizer_state', + 'bt_avrcp_target_notify_player_state', + 'bt_avrcp_target_notify_position', + 'bt_avrcp_target_notify_repeat_mode', + 'bt_avrcp_target_notify_scan_mode', + 'bt_avrcp_target_notify_shuffle_mode', + 'bt_avrcp_target_notify_track', + 'bt_avrcp_unset_equalizer_state_changed_cb', + 'bt_avrcp_unset_play_status_changed_cb', + 'bt_avrcp_unset_position_changed_cb', + 'bt_avrcp_unset_repeat_mode_changed_cb', + 'bt_avrcp_unset_scan_mode_changed_cb', + 'bt_avrcp_unset_shuffle_mode_changed_cb', + 'bt_avrcp_unset_track_info_changed_cb', + 'bt_deinitialize', + 'bt_device_cancel_bonding', + 'bt_device_create_bond', + 'bt_device_destroy_bond', + 'bt_device_foreach_connected_profiles', + 'bt_device_get_service_mask_from_uuid_list', + 'bt_device_is_profile_connected', + 'bt_device_set_alias', + 'bt_device_set_authorization', + 'bt_device_set_authorization_changed_cb', + 'bt_device_set_bond_created_cb', + 'bt_device_set_bond_destroyed_cb', + 'bt_device_set_connection_state_changed_cb', + 'bt_device_set_service_searched_cb', + 'bt_device_start_service_search', + 'bt_device_unset_authorization_changed_cb', + 'bt_device_unset_bond_created_cb', + 'bt_device_unset_bond_destroyed_cb', + 'bt_device_unset_connection_state_changed_cb', + 'bt_device_unset_service_searched_cb', + 'bt_device_update_le_connection_mode', + 'bt_gatt_characteristic_add_descriptor', + 'bt_gatt_characteristic_create', + 'bt_gatt_characteristic_destroy', + 'bt_gatt_characteristic_foreach_descriptors', + 'bt_gatt_characteristic_get_descriptor', + 'bt_gatt_characteristic_get_permissions', + 'bt_gatt_characteristic_get_properties', + 'bt_gatt_characteristic_get_service', + 'bt_gatt_characteristic_get_write_type', + 'bt_gatt_characteristic_set_write_type', + 'bt_gatt_client_create', + 'bt_gatt_client_destroy', + 'bt_gatt_client_foreach_services', + 'bt_gatt_client_get_att_mtu', + 'bt_gatt_client_get_remote_address', + 'bt_gatt_client_get_service', + 'bt_gatt_client_read_value', + 'bt_gatt_client_request_att_mtu_change', + 'bt_gatt_client_set_att_mtu_changed_cb', + 'bt_gatt_client_set_characteristic_value_changed_cb', + 'bt_gatt_client_set_service_changed_cb', + 'bt_gatt_client_unset_att_mtu_changed_cb', + 'bt_gatt_client_unset_characteristic_value_changed_cb', + 'bt_gatt_client_unset_service_changed_cb', + 'bt_gatt_client_write_value', + 'bt_gatt_clone_attribute_handle', + 'bt_gatt_connect', + 'bt_gatt_descriptor_create', + 'bt_gatt_descriptor_destroy', + 'bt_gatt_descriptor_get_characteristic', + 'bt_gatt_descriptor_get_permissions', + 'bt_gatt_destroy_attribute_handle', + 'bt_gatt_disconnect', + 'bt_gatt_discover_characteristic_descriptor', + 'bt_gatt_discover_characteristics', + 'bt_gatt_foreach_included_services', + 'bt_gatt_foreach_primary_services', + 'bt_gatt_get_characteristic_declaration', + 'bt_gatt_get_float_value', + 'bt_gatt_get_int_value', + 'bt_gatt_get_service_uuid', + 'bt_gatt_get_type', + 'bt_gatt_get_uuid', + 'bt_gatt_get_value', + 'bt_gatt_read_characteristic_value', + 'bt_gatt_server_create', + 'bt_gatt_server_deinitialize', + 'bt_gatt_server_destroy', + 'bt_gatt_server_foreach_services', + 'bt_gatt_server_get_service', + 'bt_gatt_server_initialize', + 'bt_gatt_server_notify_characteristic_changed_value', + 'bt_gatt_server_register_service', + 'bt_gatt_server_send_response', + 'bt_gatt_server_set_characteristic_notification_state_change_cb', + 'bt_gatt_server_set_read_value_requested_cb', + 'bt_gatt_server_set_write_value_requested_cb', + 'bt_gatt_server_start', + 'bt_gatt_server_unregister_all_services', + 'bt_gatt_server_unregister_service', + 'bt_gatt_service_add_characteristic', + 'bt_gatt_service_add_included_service', + 'bt_gatt_service_create', + 'bt_gatt_service_destroy', + 'bt_gatt_service_foreach_characteristics', + 'bt_gatt_service_foreach_included_services', + 'bt_gatt_service_get_characteristic', + 'bt_gatt_service_get_client', + 'bt_gatt_service_get_included_service', + 'bt_gatt_service_get_server', + 'bt_gatt_set_characteristic_changed_cb', + 'bt_gatt_set_characteristic_value', + 'bt_gatt_set_characteristic_value_request', + 'bt_gatt_set_connection_state_changed_cb', + 'bt_gatt_set_float_value', + 'bt_gatt_set_int_value', + 'bt_gatt_set_value', + 'bt_gatt_unset_characteristic_changed_cb', + 'bt_gatt_unset_connection_state_changed_cb', + 'bt_gatt_unwatch_characteristic_changes', + 'bt_gatt_watch_characteristic_changes', + 'bt_get_uuid_name', + 'bt_hdp_connect_to_source', + 'bt_hdp_disconnect', + 'bt_hdp_register_sink_app', + 'bt_hdp_send_data', + 'bt_hdp_set_connection_state_changed_cb', + 'bt_hdp_set_data_received_cb', + 'bt_hdp_unregister_sink_app', + 'bt_hdp_unset_connection_state_changed_cb', + 'bt_hdp_unset_data_received_cb', + 'bt_hid_device_activate', + 'bt_hid_device_connect', + 'bt_hid_device_deactivate', + 'bt_hid_device_disconnect', + 'bt_hid_device_reply_to_report', + 'bt_hid_device_send_key_event', + 'bt_hid_device_send_mouse_event', + 'bt_hid_device_set_data_received_cb', + 'bt_hid_device_unset_data_received_cb', + 'bt_hid_host_connect', + 'bt_hid_host_deinitialize', + 'bt_hid_host_disconnect', + 'bt_hid_host_initialize', + 'bt_initialize', + 'bt_ipsp_connect', + 'bt_ipsp_deinitialize', + 'bt_ipsp_disconnect', + 'bt_ipsp_initialize', + 'bt_ipsp_set_connection_state_changed_cb', + 'bt_ipsp_unset_connection_state_changed_cb', + 'bt_opp_client_add_file', + 'bt_opp_client_cancel_push', + 'bt_opp_client_clear_files', + 'bt_opp_client_deinitialize', + 'bt_opp_client_initialize', + 'bt_opp_client_push_files', + 'bt_opp_server_accept', + 'bt_opp_server_cancel_transfer', + 'bt_opp_server_deinitialize', + 'bt_opp_server_initialize_by_connection_request', + 'bt_opp_server_reject', + 'bt_opp_server_set_destination', + 'bt_pbap_client_connect', + 'bt_pbap_client_deinitialize', + 'bt_pbap_client_disconnect', + 'bt_pbap_client_get_list', + 'bt_pbap_client_get_phone_book', + 'bt_pbap_client_get_phone_book_size', + 'bt_pbap_client_initialize', + 'bt_pbap_client_pull_vcard', + 'bt_pbap_client_search_phone_book', + 'bt_pbap_client_set_connection_state_changed_cb', + 'bt_pbap_client_unset_connection_state_changed_cb', + 'bt_socket_connect_rfcomm', + 'bt_socket_create_rfcomm', + 'bt_socket_destroy_rfcomm', + 'bt_socket_disconnect_rfcomm', + 'bt_socket_listen_and_accept_rfcomm', + 'bt_socket_send_data', + 'bt_socket_set_connection_requested_cb', + 'bt_socket_set_connection_state_changed_cb', + 'bt_socket_set_data_received_cb', + 'bt_socket_unset_connection_requested_cb', + 'bt_socket_unset_connection_state_changed_cb', + 'bt_socket_unset_data_received_cb', + ], + 'libcapi-network-connection.so.1': [ + 'connection_add_profile', + 'connection_add_route', + 'connection_add_route_entry', + 'connection_add_route_ipv6', + 'connection_close_profile', + 'connection_create', + 'connection_destroy', + 'connection_destroy_profile_iterator', + 'connection_foreach_ipv6_address', + 'connection_get_bt_state', + 'connection_get_cellular_state', + 'connection_get_current_profile', + 'connection_get_default_cellular_service_profile', + 'connection_get_ethernet_cable_state', + 'connection_get_ethernet_state', + 'connection_get_ip_address', + 'connection_get_mac_address', + 'connection_get_profile_iterator', + 'connection_get_proxy', + 'connection_get_statistics', + 'connection_get_type', + 'connection_get_wifi_state', + 'connection_is_metered_network', + 'connection_open_profile', + 'connection_profile_clone', + 'connection_profile_create', + 'connection_profile_destroy', + 'connection_profile_get_cellular_apn', + 'connection_profile_get_cellular_auth_info', + 'connection_profile_get_cellular_home_url', + 'connection_profile_get_cellular_pdn_type', + 'connection_profile_get_cellular_roam_pdn_type', + 'connection_profile_get_cellular_service_type', + 'connection_profile_get_dhcp_lease_duration', + 'connection_profile_get_dhcp_server_address', + 'connection_profile_get_dns_address', + 'connection_profile_get_dns_config_type', + 'connection_profile_get_gateway_address', + 'connection_profile_get_id', + 'connection_profile_get_ip_address', + 'connection_profile_get_ip_config_type', + 'connection_profile_get_ipv6_state', + 'connection_profile_get_name', + 'connection_profile_get_network_interface_name', + 'connection_profile_get_prefix_length', + 'connection_profile_get_proxy_address', + 'connection_profile_get_proxy_type', + 'connection_profile_get_state', + 'connection_profile_get_subnet_mask', + 'connection_profile_get_type', + 'connection_profile_get_wifi_bssid', + 'connection_profile_get_wifi_encryption_type', + 'connection_profile_get_wifi_essid', + 'connection_profile_get_wifi_frequency', + 'connection_profile_get_wifi_max_speed', + 'connection_profile_get_wifi_rssi', + 'connection_profile_get_wifi_security_type', + 'connection_profile_is_cellular_default', + 'connection_profile_is_cellular_editable', + 'connection_profile_is_cellular_hidden', + 'connection_profile_is_cellular_roaming', + 'connection_profile_is_wifi_passphrase_required', + 'connection_profile_is_wifi_wps_supported', + 'connection_profile_iterator_has_next', + 'connection_profile_iterator_next', + 'connection_profile_refresh', + 'connection_profile_set_cellular_apn', + 'connection_profile_set_cellular_auth_info', + 'connection_profile_set_cellular_home_url', + 'connection_profile_set_cellular_pdn_type', + 'connection_profile_set_cellular_roam_pdn_type', + 'connection_profile_set_cellular_service_type', + 'connection_profile_set_dns_address', + 'connection_profile_set_dns_config_type', + 'connection_profile_set_gateway_address', + 'connection_profile_set_ip_address', + 'connection_profile_set_ip_config_type', + 'connection_profile_set_prefix_length', + 'connection_profile_set_proxy_address', + 'connection_profile_set_proxy_type', + 'connection_profile_set_state_changed_cb', + 'connection_profile_set_subnet_mask', + 'connection_profile_set_wifi_passphrase', + 'connection_profile_unset_state_changed_cb', + 'connection_remove_profile', + 'connection_remove_route', + 'connection_remove_route_entry', + 'connection_remove_route_ipv6', + 'connection_reset_profile', + 'connection_reset_statistics', + 'connection_set_default_cellular_service_profile', + 'connection_set_default_cellular_service_profile_async', + 'connection_set_ethernet_cable_state_changed_cb', + 'connection_set_ip_address_changed_cb', + 'connection_set_proxy_address_changed_cb', + 'connection_set_type_changed_cb', + 'connection_unset_ethernet_cable_state_changed_cb', + 'connection_unset_ip_address_changed_cb', + 'connection_unset_proxy_address_changed_cb', + 'connection_unset_type_changed_cb', + 'connection_update_profile', + ], + 'libnsd-dns-sd.so.0': [ + 'dnssd_create_local_service', + 'dnssd_deinitialize', + 'dnssd_deregister_local_service', + 'dnssd_destroy_local_service', + 'dnssd_initialize', + 'dnssd_register_local_service', + 'dnssd_service_add_txt_record', + 'dnssd_service_get_all_txt_record', + 'dnssd_service_get_ip', + 'dnssd_service_get_name', + 'dnssd_service_get_port', + 'dnssd_service_get_type', + 'dnssd_service_remove_txt_record', + 'dnssd_service_set_name', + 'dnssd_service_set_port', + 'dnssd_service_set_record', + 'dnssd_service_unset_record', + 'dnssd_start_browsing_service', + 'dnssd_stop_browsing_service', + ], + 'libcapi-network-http.so.0.1.0': [ + 'http_deinit', + 'http_init', + 'http_session_create', + 'http_session_destroy', + 'http_session_destroy_all_transactions', + 'http_session_get_active_transaction_count', + 'http_session_get_auto_redirection', + 'http_session_get_max_transaction_count', + 'http_session_open_transaction', + 'http_session_set_auto_redirection', + 'http_transaction_cancel', + 'http_transaction_destroy', + 'http_transaction_get_credentials', + 'http_transaction_get_http_auth_scheme', + 'http_transaction_get_interface_name', + 'http_transaction_get_realm', + 'http_transaction_get_server_certificate_verification', + 'http_transaction_get_timeout', + 'http_transaction_header_add_field', + 'http_transaction_header_get_field_value', + 'http_transaction_header_remove_field', + 'http_transaction_open_authentication', + 'http_transaction_pause', + 'http_transaction_request_get_accept_encoding', + 'http_transaction_request_get_cookie', + 'http_transaction_request_get_method', + 'http_transaction_request_get_uri', + 'http_transaction_request_get_version', + 'http_transaction_request_set_accept_encoding', + 'http_transaction_request_set_cookie', + 'http_transaction_request_set_method', + 'http_transaction_request_set_upload_file', + 'http_transaction_request_set_uri', + 'http_transaction_request_set_version', + 'http_transaction_request_write_body', + 'http_transaction_response_get_status_code', + 'http_transaction_response_get_status_text', + 'http_transaction_response_get_version', + 'http_transaction_resume', + 'http_transaction_set_aborted_cb', + 'http_transaction_set_completed_cb', + 'http_transaction_set_credentials', + 'http_transaction_set_http_auth_scheme', + 'http_transaction_set_interface_name', + 'http_transaction_set_progress_cb', + 'http_transaction_set_ready_to_write', + 'http_transaction_set_received_body_cb', + 'http_transaction_set_received_header_cb', + 'http_transaction_set_server_certificate_verification', + 'http_transaction_set_timeout', + 'http_transaction_set_uploaded_cb', + 'http_transaction_submit', + ], + 'libiotcon.so.0': [ + 'iotcon_add_generated_pin_cb', + 'iotcon_add_presence_cb', + 'iotcon_attributes_add_attributes', + 'iotcon_attributes_add_bool', + 'iotcon_attributes_add_byte_str', + 'iotcon_attributes_add_double', + 'iotcon_attributes_add_int', + 'iotcon_attributes_add_list', + 'iotcon_attributes_add_null', + 'iotcon_attributes_add_str', + 'iotcon_attributes_clone', + 'iotcon_attributes_create', + 'iotcon_attributes_destroy', + 'iotcon_attributes_foreach', + 'iotcon_attributes_get_attributes', + 'iotcon_attributes_get_bool', + 'iotcon_attributes_get_byte_str', + 'iotcon_attributes_get_double', + 'iotcon_attributes_get_int', + 'iotcon_attributes_get_keys_count', + 'iotcon_attributes_get_list', + 'iotcon_attributes_get_str', + 'iotcon_attributes_get_type', + 'iotcon_attributes_is_null', + 'iotcon_attributes_remove', + 'iotcon_deinitialize', + 'iotcon_device_info_get_property', + 'iotcon_find_device_info', + 'iotcon_find_platform_info', + 'iotcon_find_resource', + 'iotcon_get_timeout', + 'iotcon_initialize', + 'iotcon_list_add_attributes', + 'iotcon_list_add_bool', + 'iotcon_list_add_byte_str', + 'iotcon_list_add_double', + 'iotcon_list_add_int', + 'iotcon_list_add_list', + 'iotcon_list_add_str', + 'iotcon_list_create', + 'iotcon_list_destroy', + 'iotcon_list_foreach_attributes', + 'iotcon_list_foreach_bool', + 'iotcon_list_foreach_byte_str', + 'iotcon_list_foreach_double', + 'iotcon_list_foreach_int', + 'iotcon_list_foreach_list', + 'iotcon_list_foreach_str', + 'iotcon_list_get_length', + 'iotcon_list_get_nth_attributes', + 'iotcon_list_get_nth_bool', + 'iotcon_list_get_nth_byte_str', + 'iotcon_list_get_nth_double', + 'iotcon_list_get_nth_int', + 'iotcon_list_get_nth_list', + 'iotcon_list_get_nth_str', + 'iotcon_list_get_type', + 'iotcon_list_remove_nth', + 'iotcon_lite_resource_create', + 'iotcon_lite_resource_destroy', + 'iotcon_lite_resource_get_attributes', + 'iotcon_lite_resource_update_attributes', + 'iotcon_observers_add', + 'iotcon_observers_create', + 'iotcon_observers_destroy', + 'iotcon_observers_remove', + 'iotcon_options_add', + 'iotcon_options_create', + 'iotcon_options_destroy', + 'iotcon_options_foreach', + 'iotcon_options_lookup', + 'iotcon_options_remove', + 'iotcon_platform_info_get_property', + 'iotcon_polling_get_interval', + 'iotcon_polling_invoke', + 'iotcon_polling_set_interval', + 'iotcon_presence_get_connectivity_type', + 'iotcon_presence_get_resource_type', + 'iotcon_presence_response_get_connectivity_type', + 'iotcon_presence_response_get_host_address', + 'iotcon_presence_response_get_resource_type', + 'iotcon_presence_response_get_result', + 'iotcon_presence_response_get_trigger', + 'iotcon_query_add', + 'iotcon_query_create', + 'iotcon_query_destroy', + 'iotcon_query_foreach', + 'iotcon_query_get_interface', + 'iotcon_query_get_resource_type', + 'iotcon_query_lookup', + 'iotcon_query_remove', + 'iotcon_query_set_interface', + 'iotcon_query_set_resource_type', + 'iotcon_remote_resource_clone', + 'iotcon_remote_resource_create', + 'iotcon_remote_resource_delete', + 'iotcon_remote_resource_destroy', + 'iotcon_remote_resource_get', + 'iotcon_remote_resource_get_cached_representation', + 'iotcon_remote_resource_get_checking_interval', + 'iotcon_remote_resource_get_connectivity_type', + 'iotcon_remote_resource_get_device_id', + 'iotcon_remote_resource_get_device_name', + 'iotcon_remote_resource_get_host_address', + 'iotcon_remote_resource_get_interfaces', + 'iotcon_remote_resource_get_options', + 'iotcon_remote_resource_get_policies', + 'iotcon_remote_resource_get_types', + 'iotcon_remote_resource_get_uri_path', + 'iotcon_remote_resource_observe_deregister', + 'iotcon_remote_resource_observe_register', + 'iotcon_remote_resource_post', + 'iotcon_remote_resource_put', + 'iotcon_remote_resource_set_checking_interval', + 'iotcon_remote_resource_set_options', + 'iotcon_remote_resource_start_caching', + 'iotcon_remote_resource_start_monitoring', + 'iotcon_remote_resource_stop_caching', + 'iotcon_remote_resource_stop_monitoring', + 'iotcon_remove_generated_pin_cb', + 'iotcon_remove_presence_cb', + 'iotcon_representation_add_child', + 'iotcon_representation_clone', + 'iotcon_representation_create', + 'iotcon_representation_destroy', + 'iotcon_representation_foreach_children', + 'iotcon_representation_get_attributes', + 'iotcon_representation_get_child_count', + 'iotcon_representation_get_nth_child', + 'iotcon_representation_get_resource_interfaces', + 'iotcon_representation_get_resource_types', + 'iotcon_representation_get_uri_path', + 'iotcon_representation_remove_child', + 'iotcon_representation_set_attributes', + 'iotcon_representation_set_resource_interfaces', + 'iotcon_representation_set_resource_types', + 'iotcon_representation_set_uri_path', + 'iotcon_request_get_connectivity_type', + 'iotcon_request_get_host_address', + 'iotcon_request_get_observe_id', + 'iotcon_request_get_observe_type', + 'iotcon_request_get_options', + 'iotcon_request_get_query', + 'iotcon_request_get_representation', + 'iotcon_request_get_request_type', + 'iotcon_resource_bind_child_resource', + 'iotcon_resource_bind_interface', + 'iotcon_resource_bind_type', + 'iotcon_resource_create', + 'iotcon_resource_destroy', + 'iotcon_resource_get_child_count', + 'iotcon_resource_get_interfaces', + 'iotcon_resource_get_nth_child', + 'iotcon_resource_get_policies', + 'iotcon_resource_get_types', + 'iotcon_resource_get_uri_path', + 'iotcon_resource_interfaces_add', + 'iotcon_resource_interfaces_clone', + 'iotcon_resource_interfaces_create', + 'iotcon_resource_interfaces_destroy', + 'iotcon_resource_interfaces_foreach', + 'iotcon_resource_interfaces_remove', + 'iotcon_resource_notify', + 'iotcon_resource_set_request_handler', + 'iotcon_resource_types_add', + 'iotcon_resource_types_clone', + 'iotcon_resource_types_create', + 'iotcon_resource_types_destroy', + 'iotcon_resource_types_foreach', + 'iotcon_resource_types_remove', + 'iotcon_resource_unbind_child_resource', + 'iotcon_response_create', + 'iotcon_response_destroy', + 'iotcon_response_get_options', + 'iotcon_response_get_representation', + 'iotcon_response_get_result', + 'iotcon_response_send', + 'iotcon_response_set_options', + 'iotcon_response_set_representation', + 'iotcon_response_set_result', + 'iotcon_set_device_name', + 'iotcon_set_timeout', + 'iotcon_start_presence', + 'iotcon_stop_presence', + ], + 'libcapi-network-nfc.so.0': [ + 'nfc_hce_send_apdu_response', + 'nfc_manager_deinitialize', + 'nfc_manager_disable_transaction_fg_dispatch', + 'nfc_manager_enable_transaction_fg_dispatch', + 'nfc_manager_get_cached_message', + 'nfc_manager_get_connected_tag', + 'nfc_manager_get_connected_target', + 'nfc_manager_get_se_type', + 'nfc_manager_get_tag_filter', + 'nfc_manager_initialize', + 'nfc_manager_is_activated', + 'nfc_manager_is_supported', + 'nfc_manager_is_system_handler_enabled', + 'nfc_manager_set_activation', + 'nfc_manager_set_activation_changed_cb', + 'nfc_manager_set_hce_event_cb', + 'nfc_manager_set_ndef_discovered_cb', + 'nfc_manager_set_p2p_target_discovered_cb', + 'nfc_manager_set_se_event_cb', + 'nfc_manager_set_se_transaction_event_cb', + 'nfc_manager_set_se_type', + 'nfc_manager_set_system_handler_enable', + 'nfc_manager_set_tag_discovered_cb', + 'nfc_manager_set_tag_filter', + 'nfc_manager_unset_activation_changed_cb', + 'nfc_manager_unset_hce_event_cb', + 'nfc_manager_unset_ndef_discovered_cb', + 'nfc_manager_unset_p2p_target_discovered_cb', + 'nfc_manager_unset_se_event_cb', + 'nfc_manager_unset_se_transaction_event_cb', + 'nfc_manager_unset_tag_discovered_cb', + 'nfc_mifare_authenticate_with_keyA', + 'nfc_mifare_authenticate_with_keyB', + 'nfc_mifare_decrement', + 'nfc_mifare_increment', + 'nfc_mifare_read_block', + 'nfc_mifare_read_page', + 'nfc_mifare_restore', + 'nfc_mifare_transfer', + 'nfc_mifare_write_block', + 'nfc_mifare_write_page', + 'nfc_ndef_message_append_record', + 'nfc_ndef_message_create', + 'nfc_ndef_message_create_from_rawdata', + 'nfc_ndef_message_destroy', + 'nfc_ndef_message_get_rawdata', + 'nfc_ndef_message_get_record', + 'nfc_ndef_message_get_record_count', + 'nfc_ndef_message_insert_record', + 'nfc_ndef_message_remove_record', + 'nfc_ndef_record_create', + 'nfc_ndef_record_create_mime', + 'nfc_ndef_record_create_text', + 'nfc_ndef_record_create_uri', + 'nfc_ndef_record_destroy', + 'nfc_ndef_record_get_encode_type', + 'nfc_ndef_record_get_id', + 'nfc_ndef_record_get_langcode', + 'nfc_ndef_record_get_mime_type', + 'nfc_ndef_record_get_payload', + 'nfc_ndef_record_get_text', + 'nfc_ndef_record_get_tnf', + 'nfc_ndef_record_get_type', + 'nfc_ndef_record_get_uri', + 'nfc_ndef_record_set_id', + 'nfc_p2p_send', + 'nfc_p2p_set_data_received_cb', + 'nfc_p2p_unset_data_received_cb', + 'nfc_se_disable_card_emulation', + 'nfc_se_enable_card_emulation', + 'nfc_se_foreach_registered_aids', + 'nfc_se_get_card_emulation_mode', + 'nfc_se_is_activated_handler_for_aid', + 'nfc_se_is_activated_handler_for_category', + 'nfc_se_register_aid', + 'nfc_se_set_default_route', + 'nfc_se_set_preferred_handler', + 'nfc_se_unregister_aid', + 'nfc_se_unset_preferred_handler', + 'nfc_snep_register_server', + 'nfc_snep_send_client_request', + 'nfc_snep_start_client', + 'nfc_snep_start_server', + 'nfc_snep_stop_service', + 'nfc_snep_unregister_server', + 'nfc_tag_foreach_information', + 'nfc_tag_format_ndef', + 'nfc_tag_get_maximum_ndef_size', + 'nfc_tag_get_ndef_size', + 'nfc_tag_get_type', + 'nfc_tag_is_support_ndef', + 'nfc_tag_read_ndef', + 'nfc_tag_transceive', + 'nfc_tag_write_ndef', + ], + 'libnsd-ssdp.so.0': [ + 'ssdp_create_local_service', + 'ssdp_deinitialize', + 'ssdp_deregister_local_service', + 'ssdp_destroy_local_service', + 'ssdp_initialize', + 'ssdp_register_local_service', + 'ssdp_service_get_target', + 'ssdp_service_get_url', + 'ssdp_service_get_usn', + 'ssdp_service_set_url', + 'ssdp_service_set_usn', + 'ssdp_start_browsing_service', + 'ssdp_stop_browsing_service', + ], + 'libcapi-network-stc.so.0': [ + 'stc_deinitialize', + 'stc_foreach_stats', + 'stc_get_stats', + 'stc_get_total_stats', + 'stc_initialize', + 'stc_stats_info_get_app_id', + 'stc_stats_info_get_counter', + 'stc_stats_info_get_iface_name', + 'stc_stats_info_get_iface_type', + 'stc_stats_info_get_process_state', + 'stc_stats_info_get_protocol_type', + 'stc_stats_info_get_roaming_type', + 'stc_stats_info_get_time_interval', + 'stc_stats_rule_create', + 'stc_stats_rule_destroy', + 'stc_stats_rule_get_app_id', + 'stc_stats_rule_get_iface_type', + 'stc_stats_rule_get_time_interval', + 'stc_stats_rule_get_time_period', + 'stc_stats_rule_set_app_id', + 'stc_stats_rule_set_iface_type', + 'stc_stats_rule_set_time_interval', + 'stc_stats_rule_set_time_period', + ], + 'libcapi-network-smartcard.so.0': [ + 'smartcard_channel_close', + 'smartcard_channel_get_select_response', + 'smartcard_channel_get_session', + 'smartcard_channel_is_basic_channel', + 'smartcard_channel_is_closed', + 'smartcard_channel_select_next', + 'smartcard_channel_transmit', + 'smartcard_channel_transmit_retrieve_response', + 'smartcard_deinitialize', + 'smartcard_get_readers', + 'smartcard_get_version', + 'smartcard_initialize', + 'smartcard_reader_close_sessions', + 'smartcard_reader_get_name', + 'smartcard_reader_is_secure_element_present', + 'smartcard_reader_open_session', + 'smartcard_reader_set_event_cb', + 'smartcard_reader_unset_event_cb', + 'smartcard_session_close', + 'smartcard_session_close_channels', + 'smartcard_session_get_atr', + 'smartcard_session_get_reader', + 'smartcard_session_is_closed', + 'smartcard_session_open_basic_channel', + 'smartcard_session_open_logical_channel', + ], + 'libcapi-network-wifi-manager.so.1': [ + 'wifi_manager_activate', + 'wifi_manager_activate_with_wifi_picker_tested', + 'wifi_manager_ap_clone', + 'wifi_manager_ap_create', + 'wifi_manager_ap_destroy', + 'wifi_manager_ap_foreach_ipv6_address', + 'wifi_manager_ap_get_bssid', + 'wifi_manager_ap_get_connection_state', + 'wifi_manager_ap_get_dhcp_lease_duration', + 'wifi_manager_ap_get_dhcp_server_address', + 'wifi_manager_ap_get_disconnect_reason', + 'wifi_manager_ap_get_dns_address', + 'wifi_manager_ap_get_dns_config_type', + 'wifi_manager_ap_get_eap_auth_type', + 'wifi_manager_ap_get_eap_ca_cert_file', + 'wifi_manager_ap_get_eap_client_cert_file', + 'wifi_manager_ap_get_eap_passphrase', + 'wifi_manager_ap_get_eap_private_key_file', + 'wifi_manager_ap_get_eap_type', + 'wifi_manager_ap_get_encryption_type', + 'wifi_manager_ap_get_error_state', + 'wifi_manager_ap_get_essid', + 'wifi_manager_ap_get_frequency', + 'wifi_manager_ap_get_gateway_address', + 'wifi_manager_ap_get_ip_address', + 'wifi_manager_ap_get_ip_config_type', + 'wifi_manager_ap_get_max_speed', + 'wifi_manager_ap_get_prefix_length', + 'wifi_manager_ap_get_proxy_address', + 'wifi_manager_ap_get_proxy_type', + 'wifi_manager_ap_get_raw_ssid', + 'wifi_manager_ap_get_rssi', + 'wifi_manager_ap_get_rssi_level', + 'wifi_manager_ap_get_security_type', + 'wifi_manager_ap_get_subnet_mask', + 'wifi_manager_ap_hidden_create', + 'wifi_manager_ap_is_favorite', + 'wifi_manager_ap_is_passphrase_required', + 'wifi_manager_ap_is_passpoint', + 'wifi_manager_ap_is_wps_supported', + 'wifi_manager_ap_refresh', + 'wifi_manager_ap_set_dns_address', + 'wifi_manager_ap_set_dns_config_type', + 'wifi_manager_ap_set_eap_auth_type', + 'wifi_manager_ap_set_eap_ca_cert_file', + 'wifi_manager_ap_set_eap_client_cert_file', + 'wifi_manager_ap_set_eap_passphrase', + 'wifi_manager_ap_set_eap_private_key_info', + 'wifi_manager_ap_set_eap_type', + 'wifi_manager_ap_set_encryption_type', + 'wifi_manager_ap_set_gateway_address', + 'wifi_manager_ap_set_ip_address', + 'wifi_manager_ap_set_ip_config_type', + 'wifi_manager_ap_set_passphrase', + 'wifi_manager_ap_set_prefix_length', + 'wifi_manager_ap_set_proxy_address', + 'wifi_manager_ap_set_proxy_type', + 'wifi_manager_ap_set_security_type', + 'wifi_manager_ap_set_subnet_mask', + 'wifi_manager_bssid_scan', + 'wifi_manager_cancel_wps', + 'wifi_manager_config_clone', + 'wifi_manager_config_create', + 'wifi_manager_config_destroy', + 'wifi_manager_config_foreach_configuration', + 'wifi_manager_config_get_eap_anonymous_identity', + 'wifi_manager_config_get_eap_auth_type', + 'wifi_manager_config_get_eap_ca_cert_file', + 'wifi_manager_config_get_eap_client_cert_file', + 'wifi_manager_config_get_eap_identity', + 'wifi_manager_config_get_eap_subject_match', + 'wifi_manager_config_get_eap_type', + 'wifi_manager_config_get_hidden_ap_property', + 'wifi_manager_config_get_name', + 'wifi_manager_config_get_proxy_address', + 'wifi_manager_config_get_security_type', + 'wifi_manager_config_remove', + 'wifi_manager_config_save', + 'wifi_manager_config_set_eap_anonymous_identity', + 'wifi_manager_config_set_eap_auth_type', + 'wifi_manager_config_set_eap_ca_cert_file', + 'wifi_manager_config_set_eap_client_cert_file', + 'wifi_manager_config_set_eap_identity', + 'wifi_manager_config_set_eap_subject_match', + 'wifi_manager_config_set_eap_type', + 'wifi_manager_config_set_hidden_ap_property', + 'wifi_manager_config_set_proxy_address', + 'wifi_manager_connect', + 'wifi_manager_connect_by_wps_pbc', + 'wifi_manager_connect_by_wps_pbc_without_ssid', + 'wifi_manager_connect_by_wps_pin', + 'wifi_manager_connect_by_wps_pin_without_ssid', + 'wifi_manager_connect_hidden_ap', + 'wifi_manager_deactivate', + 'wifi_manager_deinitialize', + 'wifi_manager_disconnect', + 'wifi_manager_foreach_found_ap', + 'wifi_manager_foreach_found_bssid_ap', + 'wifi_manager_foreach_found_specific_ap', + 'wifi_manager_forget_ap', + 'wifi_manager_get_connected_ap', + 'wifi_manager_get_connection_state', + 'wifi_manager_get_mac_address', + 'wifi_manager_get_module_state', + 'wifi_manager_get_network_interface_name', + 'wifi_manager_get_scan_state', + 'wifi_manager_initialize', + 'wifi_manager_is_activated', + 'wifi_manager_scan', + 'wifi_manager_scan_specific_ap', + 'wifi_manager_set_background_scan_cb', + 'wifi_manager_set_connection_state_changed_cb', + 'wifi_manager_set_device_state_changed_cb', + 'wifi_manager_set_module_state_changed_cb', + 'wifi_manager_set_rssi_level_changed_cb', + 'wifi_manager_set_scan_state_changed_cb', + 'wifi_manager_specific_ap_start_multi_scan', + 'wifi_manager_specific_scan_create', + 'wifi_manager_specific_scan_destroy', + 'wifi_manager_specific_scan_set_freq', + 'wifi_manager_specific_scan_set_ssid', + 'wifi_manager_tdls_connect', + 'wifi_manager_tdls_disable_channel_switching', + 'wifi_manager_tdls_disconnect', + 'wifi_manager_tdls_enable_channel_switching', + 'wifi_manager_tdls_get_connected_peer', + 'wifi_manager_tdls_set_discovered_cb', + 'wifi_manager_tdls_set_state_changed_cb', + 'wifi_manager_tdls_start_discovery', + 'wifi_manager_tdls_unset_discovered_cb', + 'wifi_manager_tdls_unset_state_changed_cb', + 'wifi_manager_unset_background_scan_cb', + 'wifi_manager_unset_connection_state_changed_cb', + 'wifi_manager_unset_device_state_changed_cb', + 'wifi_manager_unset_module_state_changed_cb', + 'wifi_manager_unset_rssi_level_changed_cb', + 'wifi_manager_unset_scan_state_changed_cb', + 'wifi_manager_update_ap', + ], + 'libcsr-client.so.2': [ + 'csr_cs_cancel_scanning', + 'csr_cs_context_create', + 'csr_cs_context_destroy', + 'csr_cs_get_detected_malware', + 'csr_cs_get_detected_malwares', + 'csr_cs_get_ignored_malware', + 'csr_cs_get_ignored_malwares', + 'csr_cs_judge_detected_malware', + 'csr_cs_malware_get_detailed_url', + 'csr_cs_malware_get_file_name', + 'csr_cs_malware_get_name', + 'csr_cs_malware_get_pkg_id', + 'csr_cs_malware_get_severity', + 'csr_cs_malware_get_timestamp', + 'csr_cs_malware_get_user_response', + 'csr_cs_malware_is_app', + 'csr_cs_malware_list_get_malware', + 'csr_cs_scan_data', + 'csr_cs_scan_dir_async', + 'csr_cs_scan_dirs_async', + 'csr_cs_scan_file', + 'csr_cs_scan_files_async', + 'csr_cs_set_ask_user', + 'csr_cs_set_cancelled_cb', + 'csr_cs_set_completed_cb', + 'csr_cs_set_core_usage', + 'csr_cs_set_detected_cb', + 'csr_cs_set_error_cb', + 'csr_cs_set_file_scanned_cb', + 'csr_cs_set_popup_message', + 'csr_cs_set_scan_on_cloud', + 'csr_engine_destroy', + 'csr_engine_get_activated', + 'csr_engine_get_data_version', + 'csr_engine_get_latest_update_time', + 'csr_engine_get_name', + 'csr_engine_get_state', + 'csr_engine_get_vendor', + 'csr_engine_get_version', + 'csr_engine_set_state', + 'csr_get_current_engine', + 'csr_wp_check_url', + 'csr_wp_context_create', + 'csr_wp_context_destroy', + 'csr_wp_result_get_detailed_url', + 'csr_wp_result_get_risk_level', + 'csr_wp_result_get_user_response', + 'csr_wp_set_ask_user', + 'csr_wp_set_popup_message', + ], + 'libdpm.so.0': [ + 'dpm_add_policy_changed_cb', + 'dpm_add_signal_cb', + 'dpm_manager_create', + 'dpm_manager_destroy', + 'dpm_password_create_iterator', + 'dpm_password_delete_pattern', + 'dpm_password_destroy_iterator', + 'dpm_password_enforce_change', + 'dpm_password_get_expires', + 'dpm_password_get_history', + 'dpm_password_get_maximum_character_occurrences', + 'dpm_password_get_maximum_failed_attempts_for_wipe', + 'dpm_password_get_maximum_numeric_sequence_length', + 'dpm_password_get_max_inactivity_time_device_lock', + 'dpm_password_get_min_complex_chars', + 'dpm_password_get_minimum_length', + 'dpm_password_get_pattern', + 'dpm_password_get_quality', + 'dpm_password_get_status', + 'dpm_password_iterator_next', + 'dpm_password_reset', + 'dpm_password_set_expires', + 'dpm_password_set_forbidden_strings', + 'dpm_password_set_history', + 'dpm_password_set_maximum_character_occurrences', + 'dpm_password_set_maximum_failed_attempts_for_wipe', + 'dpm_password_set_maximum_numeric_sequence_length', + 'dpm_password_set_max_inactivity_time_device_lock', + 'dpm_password_set_min_complex_chars', + 'dpm_password_set_minimum_length', + 'dpm_password_set_pattern', + 'dpm_password_set_quality', + 'dpm_password_set_status', + 'dpm_remove_policy_changed_cb', + 'dpm_remove_signal_cb', + 'dpm_restriction_get_bluetooth_desktop_connectivity_state', + 'dpm_restriction_get_bluetooth_mode_change_state', + 'dpm_restriction_get_bluetooth_pairing_state', + 'dpm_restriction_get_bluetooth_tethering_state', + 'dpm_restriction_get_browser_state', + 'dpm_restriction_get_camera_state', + 'dpm_restriction_get_clipboard_state', + 'dpm_restriction_get_external_storage_state', + 'dpm_restriction_get_location_state', + 'dpm_restriction_get_messaging_state', + 'dpm_restriction_get_microphone_state', + 'dpm_restriction_get_popimap_email_state', + 'dpm_restriction_get_usb_debugging_state', + 'dpm_restriction_get_usb_tethering_state', + 'dpm_restriction_get_wifi_hotspot_state', + 'dpm_restriction_get_wifi_state', + 'dpm_restriction_set_bluetooth_desktop_connectivity_state', + 'dpm_restriction_set_bluetooth_mode_change_state', + 'dpm_restriction_set_bluetooth_pairing_state', + 'dpm_restriction_set_bluetooth_tethering_state', + 'dpm_restriction_set_browser_state', + 'dpm_restriction_set_camera_state', + 'dpm_restriction_set_clipboard_state', + 'dpm_restriction_set_external_storage_state', + 'dpm_restriction_set_location_state', + 'dpm_restriction_set_messaging_state', + 'dpm_restriction_set_microphone_state', + 'dpm_restriction_set_popimap_email_state', + 'dpm_restriction_set_usb_debugging_state', + 'dpm_restriction_set_usb_tethering_state', + 'dpm_restriction_set_wifi_hotspot_state', + 'dpm_restriction_set_wifi_state', + 'dpm_security_is_external_storage_encrypted', + 'dpm_security_is_internal_storage_encrypted', + 'dpm_security_lockout_screen', + 'dpm_security_set_external_storage_encryption', + 'dpm_security_set_internal_storage_encryption', + 'dpm_security_wipe_data', + 'dpm_zone_create', + 'dpm_zone_destroy', + 'dpm_zone_foreach_name', + 'dpm_zone_get_state', + ], + 'libkey-manager-client.so.1': [ + 'ckmc_alias_list_add', + 'ckmc_alias_list_all_free', + 'ckmc_alias_list_free', + 'ckmc_alias_list_new', + 'ckmc_alias_new', + 'ckmc_buffer_free', + 'ckmc_buffer_new', + 'ckmc_cert_free', + 'ckmc_cert_list_add', + 'ckmc_cert_list_all_free', + 'ckmc_cert_list_free', + 'ckmc_cert_list_new', + 'ckmc_cert_new', + 'ckmc_create_key_aes', + 'ckmc_create_key_pair_dsa', + 'ckmc_create_key_pair_ecdsa', + 'ckmc_create_key_pair_rsa', + 'ckmc_create_signature', + 'ckmc_decrypt_data', + 'ckmc_encrypt_data', + 'ckmc_generate_new_params', + 'ckmc_get_cert', + 'ckmc_get_cert_alias_list', + 'ckmc_get_cert_chain', + 'ckmc_get_cert_chain_with_trustedcert', + 'ckmc_get_data', + 'ckmc_get_data_alias_list', + 'ckmc_get_key', + 'ckmc_get_key_alias_list', + 'ckmc_get_pkcs12', + 'ckmc_key_free', + 'ckmc_key_new', + 'ckmc_load_cert_from_file', + 'ckmc_ocsp_check', + 'ckmc_param_list_free', + 'ckmc_param_list_get_buffer', + 'ckmc_param_list_get_integer', + 'ckmc_param_list_new', + 'ckmc_param_list_set_buffer', + 'ckmc_param_list_set_integer', + 'ckmc_pkcs12_free', + 'ckmc_pkcs12_load', + 'ckmc_pkcs12_new', + 'ckmc_remove_alias', + 'ckmc_save_cert', + 'ckmc_save_data', + 'ckmc_save_key', + 'ckmc_save_pkcs12', + 'ckmc_set_permission', + 'ckmc_verify_signature', + ], + 'libcapi-privacy-privilege-manager.so.0': [ + 'ppm_check_permission', + 'ppm_request_permission', + ], + 'libprivilege-info.so.1': [ + 'privilege_info_get_description', + 'privilege_info_get_description_by_pkgtype', + 'privilege_info_get_display_name', + 'privilege_info_get_display_name_by_pkgtype', + 'privilege_info_get_privacy_display_name', + 'privilege_info_get_privacy_privilege_status', + ], + 'libyaca.so.0': [ + 'yaca_cleanup', + 'yaca_context_destroy', + 'yaca_context_get_output_length', + 'yaca_context_get_property', + 'yaca_context_set_property', + 'yaca_decrypt_finalize', + 'yaca_decrypt_initialize', + 'yaca_decrypt_update', + 'yaca_digest_finalize', + 'yaca_digest_initialize', + 'yaca_digest_update', + 'yaca_encrypt_finalize', + 'yaca_encrypt_get_iv_bit_length', + 'yaca_encrypt_initialize', + 'yaca_encrypt_update', + 'yaca_free', + 'yaca_initialize', + 'yaca_key_derive_dh', + 'yaca_key_derive_kdf', + 'yaca_key_derive_pbkdf2', + 'yaca_key_destroy', + 'yaca_key_export', + 'yaca_key_extract_parameters', + 'yaca_key_extract_public', + 'yaca_key_generate', + 'yaca_key_generate_from_parameters', + 'yaca_key_get_bit_length', + 'yaca_key_get_type', + 'yaca_key_import', + 'yaca_malloc', + 'yaca_memcmp', + 'yaca_open_finalize', + 'yaca_open_initialize', + 'yaca_open_update', + 'yaca_randomize_bytes', + 'yaca_realloc', + 'yaca_rsa_private_decrypt', + 'yaca_rsa_private_encrypt', + 'yaca_rsa_public_decrypt', + 'yaca_rsa_public_encrypt', + 'yaca_seal_finalize', + 'yaca_seal_initialize', + 'yaca_seal_update', + 'yaca_sign_finalize', + 'yaca_sign_initialize', + 'yaca_sign_initialize_cmac', + 'yaca_sign_initialize_hmac', + 'yaca_sign_update', + 'yaca_simple_calculate_cmac', + 'yaca_simple_calculate_digest', + 'yaca_simple_calculate_hmac', + 'yaca_simple_calculate_signature', + 'yaca_simple_decrypt', + 'yaca_simple_encrypt', + 'yaca_simple_verify_signature', + 'yaca_verify_finalize', + 'yaca_verify_initialize', + 'yaca_verify_update', + 'yaca_zalloc', + ], + 'libcalendar-service2.so.0': [ + 'calendar_connect', + 'calendar_connect_on_thread', + 'calendar_connect_with_flags', + 'calendar_db_add_changed_cb', + 'calendar_db_clean_after_sync', + 'calendar_db_delete_record', + 'calendar_db_delete_records', + 'calendar_db_get_all_records', + 'calendar_db_get_changes_by_version', + 'calendar_db_get_changes_exception_by_version', + 'calendar_db_get_count', + 'calendar_db_get_count_with_query', + 'calendar_db_get_current_version', + 'calendar_db_get_last_change_version', + 'calendar_db_get_record', + 'calendar_db_get_records_with_query', + 'calendar_db_insert_record', + 'calendar_db_insert_records', + 'calendar_db_insert_vcalendars', + 'calendar_db_link_record', + 'calendar_db_remove_changed_cb', + 'calendar_db_replace_record', + 'calendar_db_replace_records', + 'calendar_db_replace_vcalendars', + 'calendar_db_unlink_record', + 'calendar_db_update_record', + 'calendar_db_update_records', + 'calendar_disconnect', + 'calendar_disconnect_on_thread', + 'calendar_filter_add_caltime', + 'calendar_filter_add_double', + 'calendar_filter_add_filter', + 'calendar_filter_add_int', + 'calendar_filter_add_lli', + 'calendar_filter_add_operator', + 'calendar_filter_add_str', + 'calendar_filter_create', + 'calendar_filter_destroy', + 'calendar_list_add', + 'calendar_list_create', + 'calendar_list_destroy', + 'calendar_list_first', + 'calendar_list_get_count', + 'calendar_list_get_current_record_p', + 'calendar_list_last', + 'calendar_list_next', + 'calendar_list_prev', + 'calendar_list_remove', + 'calendar_query_create', + 'calendar_query_destroy', + 'calendar_query_set_distinct', + 'calendar_query_set_filter', + 'calendar_query_set_projection', + 'calendar_query_set_sort', + 'calendar_record_add_child_record', + 'calendar_record_clone', + 'calendar_record_clone_child_record_list', + 'calendar_record_create', + 'calendar_record_destroy', + 'calendar_record_get_caltime', + 'calendar_record_get_child_record_at_p', + 'calendar_record_get_child_record_count', + 'calendar_record_get_double', + 'calendar_record_get_int', + 'calendar_record_get_lli', + 'calendar_record_get_str', + 'calendar_record_get_str_p', + 'calendar_record_get_uri_p', + 'calendar_record_remove_child_record', + 'calendar_record_set_caltime', + 'calendar_record_set_double', + 'calendar_record_set_int', + 'calendar_record_set_lli', + 'calendar_record_set_str', + 'calendar_reminder_add_cb', + 'calendar_reminder_remove_cb', + 'calendar_vcalendar_make_from_records', + 'calendar_vcalendar_parse_to_calendar', + 'calendar_vcalendar_parse_to_calendar_foreach', + ], + 'libcontacts-service2.so.0': [ + 'contacts_activity_delete_by_account_id', + 'contacts_activity_delete_by_contact_id', + 'contacts_connect', + 'contacts_connect_on_thread', + 'contacts_connect_with_flags', + 'contacts_db_add_changed_cb', + 'contacts_db_delete_record', + 'contacts_db_delete_records', + 'contacts_db_get_all_records', + 'contacts_db_get_changes_by_version', + 'contacts_db_get_count', + 'contacts_db_get_count_with_query', + 'contacts_db_get_current_version', + 'contacts_db_get_last_change_version', + 'contacts_db_get_record', + 'contacts_db_get_records_with_query', + 'contacts_db_get_status', + 'contacts_db_insert_record', + 'contacts_db_insert_records', + 'contacts_db_remove_changed_cb', + 'contacts_db_replace_record', + 'contacts_db_replace_records', + 'contacts_db_search_records', + 'contacts_db_search_records_for_snippet', + 'contacts_db_search_records_with_query', + 'contacts_db_search_records_with_query_for_snippet', + 'contacts_db_search_records_with_range', + 'contacts_db_search_records_with_range_for_snippet', + 'contacts_db_update_record', + 'contacts_db_update_records', + 'contacts_disconnect', + 'contacts_disconnect_on_thread', + 'contacts_filter_add_bool', + 'contacts_filter_add_double', + 'contacts_filter_add_filter', + 'contacts_filter_add_int', + 'contacts_filter_add_lli', + 'contacts_filter_add_operator', + 'contacts_filter_add_str', + 'contacts_filter_create', + 'contacts_filter_destroy', + 'contacts_group_add_contact', + 'contacts_group_remove_contact', + 'contacts_group_set_group_order', + 'contacts_list_add', + 'contacts_list_create', + 'contacts_list_destroy', + 'contacts_list_first', + 'contacts_list_get_count', + 'contacts_list_get_current_record_p', + 'contacts_list_last', + 'contacts_list_next', + 'contacts_list_prev', + 'contacts_list_remove', + 'contacts_person_get_aggregation_suggestions', + 'contacts_person_get_default_property', + 'contacts_person_link_person', + 'contacts_person_reset_usage', + 'contacts_person_set_default_property', + 'contacts_person_set_favorite_order', + 'contacts_person_unlink_contact', + 'contacts_phone_log_reset_statistics', + 'contacts_phone_log_reset_statistics_by_sim', + 'contacts_query_create', + 'contacts_query_destroy', + 'contacts_query_set_distinct', + 'contacts_query_set_filter', + 'contacts_query_set_projection', + 'contacts_query_set_sort', + 'contacts_record_add_child_record', + 'contacts_record_clone', + 'contacts_record_clone_child_record_list', + 'contacts_record_create', + 'contacts_record_destroy', + 'contacts_record_get_bool', + 'contacts_record_get_child_record_at_p', + 'contacts_record_get_child_record_count', + 'contacts_record_get_double', + 'contacts_record_get_int', + 'contacts_record_get_lli', + 'contacts_record_get_str', + 'contacts_record_get_str_p', + 'contacts_record_get_uri_p', + 'contacts_record_remove_child_record', + 'contacts_record_set_bool', + 'contacts_record_set_double', + 'contacts_record_set_int', + 'contacts_record_set_lli', + 'contacts_record_set_str', + 'contacts_setting_add_name_display_order_changed_cb', + 'contacts_setting_add_name_sorting_order_changed_cb', + 'contacts_setting_get_name_display_order', + 'contacts_setting_get_name_sorting_order', + 'contacts_setting_remove_name_display_order_changed_cb', + 'contacts_setting_remove_name_sorting_order_changed_cb', + 'contacts_setting_set_name_display_order', + 'contacts_setting_set_name_sorting_order', + 'contacts_sim_get_initialization_status', + 'contacts_sim_get_initialization_status_by_sim_slot_no', + 'contacts_sim_import_all_contacts', + 'contacts_sim_import_all_contacts_by_sim_slot_no', + 'contacts_vcard_get_entity_count', + 'contacts_vcard_get_limit_size_of_photo', + 'contacts_vcard_make_from_contact', + 'contacts_vcard_make_from_my_profile', + 'contacts_vcard_make_from_person', + 'contacts_vcard_parse_to_contact_foreach', + 'contacts_vcard_parse_to_contacts', + 'contacts_vcard_set_limit_size_of_photo', + ], + 'libphonenumber-utils.so.0': [ + 'phone_number_add_blocking_rule', + 'phone_number_blocking_rule_create', + 'phone_number_blocking_rule_destroy', + 'phone_number_blocking_rule_get_match_type', + 'phone_number_blocking_rule_get_number', + 'phone_number_blocking_rule_set_match_type', + 'phone_number_blocking_rule_set_number', + 'phone_number_check_blocking', + 'phone_number_connect', + 'phone_number_disconnect', + 'phone_number_get_blocking_rules', + 'phone_number_get_blocking_rules_related', + 'phone_number_get_formatted_number', + 'phone_number_get_location_from_number', + 'phone_number_get_normalized_number', + 'phone_number_remove_blocking_rule', + ], + 'libcapi-system-device.so.0': [ + 'device_battery_get_health', + 'device_battery_get_level_status', + 'device_battery_get_percent', + 'device_battery_get_power_source', + 'device_battery_get_property', + 'device_battery_get_status', + 'device_battery_is_charging', + 'device_display_change_state', + 'device_display_get_state', + 'device_ir_is_available', + 'device_ir_transmit', + 'device_power_reboot', + ], + 'libdlog.so.0': [ + 'dlog_print', + 'dlog_vprint', + ], + 'libfeedback.so.0': [ + 'feedback_deinitialize', + 'feedback_initialize', + 'feedback_is_supported_pattern', + 'feedback_play', + 'feedback_play_type', + 'feedback_stop', + ], + 'libcapi-system-media-key.so.0': [ + 'media_key_release', + 'media_key_reserve', + ], + 'libcapi-system-runtime-info.so.0': [ + 'runtime_info_app_usage_destroy', + 'runtime_info_app_usage_get_appid', + 'runtime_info_app_usage_get_count', + 'runtime_info_app_usage_get_usage', + 'runtime_info_get_all_apps_cpu_rate', + 'runtime_info_get_all_apps_memory_usage', + 'runtime_info_get_cpu_usage', + 'runtime_info_get_physical_memory_size', + 'runtime_info_get_process_cpu_usage', + 'runtime_info_get_process_memory_info', + 'runtime_info_get_processor_count', + 'runtime_info_get_processor_current_frequency', + 'runtime_info_get_processor_max_frequency', + 'runtime_info_get_system_memory_info', + 'runtime_info_get_value_bool', + 'runtime_info_get_value_double', + 'runtime_info_get_value_int', + 'runtime_info_get_value_string', + 'runtime_info_set_changed_cb', + 'runtime_info_unset_changed_cb', + ], + 'libcapi-system-sensor.so.0': [ + 'sensor_add_provider', + 'sensor_add_sensor_added_cb', + 'sensor_add_sensor_removed_cb', + 'sensor_create_listener', + 'sensor_create_provider', + 'sensor_destroy_listener', + 'sensor_destroy_provider', + 'sensor_get_default_sensor', + 'sensor_get_default_sensor_by_uri', + 'sensor_get_fifo_count', + 'sensor_get_max_batch_count', + 'sensor_get_max_range', + 'sensor_get_min_interval', + 'sensor_get_min_range', + 'sensor_get_name', + 'sensor_get_resolution', + 'sensor_get_sensor_list', + 'sensor_get_sensor_list_by_uri', + 'sensor_get_type', + 'sensor_get_uri', + 'sensor_get_vendor', + 'sensor_is_supported', + 'sensor_is_supported_by_uri', + 'sensor_is_wake_up', + 'sensor_listener_read_data', + 'sensor_listener_set_accuracy_cb', + 'sensor_listener_set_attribute_int', + 'sensor_listener_set_event_cb', + 'sensor_listener_set_interval', + 'sensor_listener_set_max_batch_latency', + 'sensor_listener_set_option', + 'sensor_listener_start', + 'sensor_listener_stop', + 'sensor_listener_unset_accuracy_cb', + 'sensor_listener_unset_event_cb', + 'sensor_provider_publish', + 'sensor_provider_set_interval_changed_cb', + 'sensor_provider_set_name', + 'sensor_provider_set_range', + 'sensor_provider_set_resolution', + 'sensor_provider_set_start_cb', + 'sensor_provider_set_stop_cb', + 'sensor_provider_set_vendor', + 'sensor_recorder_create_option', + 'sensor_recorder_create_query', + 'sensor_recorder_data_get_double', + 'sensor_recorder_data_get_int', + 'sensor_recorder_data_get_time', + 'sensor_recorder_destroy_option', + 'sensor_recorder_destroy_query', + 'sensor_recorder_is_supported', + 'sensor_recorder_option_set_int', + 'sensor_recorder_query_set_int', + 'sensor_recorder_query_set_time', + 'sensor_recorder_read', + 'sensor_recorder_read_sync', + 'sensor_recorder_start', + 'sensor_recorder_stop', + 'sensor_remove_provider', + 'sensor_remove_sensor_added_cb', + 'sensor_remove_sensor_removed_cb', + 'sensor_util_get_altitude', + 'sensor_util_get_angle_change', + 'sensor_util_get_declination', + 'sensor_util_get_inclination', + 'sensor_util_get_orientation', + 'sensor_util_get_rotation_matrix', + 'sensor_util_get_rotation_matrix_from_vector', + 'sensor_util_remap_coordinate_system', + ], + 'libstorage.so.0.1': [ + 'storage_foreach_device_supported', + 'storage_get_available_space', + 'storage_get_directory', + 'storage_get_external_memory_size', + 'storage_get_external_memory_size64', + 'storage_get_internal_memory_size', + 'storage_get_internal_memory_size64', + 'storage_get_root_directory', + 'storage_get_state', + 'storage_get_total_space', + 'storage_get_type', + 'storage_set_changed_cb', + 'storage_set_state_changed_cb', + 'storage_unset_changed_cb', + 'storage_unset_state_changed_cb', + ], + 'libcapi-system-info.so.0': [ + 'system_info_get_custom_bool', + 'system_info_get_custom_double', + 'system_info_get_custom_int', + 'system_info_get_custom_string', + 'system_info_get_platform_bool', + 'system_info_get_platform_double', + 'system_info_get_platform_int', + 'system_info_get_platform_string', + ], + 'libcapi-system-system-settings.so.0': [ + 'system_settings_add_changed_cb', + 'system_settings_add_value_string', + 'system_settings_delete_value_string', + 'system_settings_foreach_value_string', + 'system_settings_get_value_bool', + 'system_settings_get_value_int', + 'system_settings_get_value_string', + 'system_settings_remove_changed_cb', + 'system_settings_set_changed_cb', + 'system_settings_set_value_bool', + 'system_settings_set_value_int', + 'system_settings_set_value_string', + 'system_settings_unset_changed_cb', + ], + 'libttrace.so.1': [ + 'trace_async_begin', + 'trace_async_end', + 'trace_begin', + 'trace_end', + 'trace_update_counter', + ], + 'libcapi-telephony.so.0': [ + 'telephony_call_get_call_list', + 'telephony_call_get_conference_status', + 'telephony_call_get_direction', + 'telephony_call_get_handle_id', + 'telephony_call_get_preferred_voice_subscription', + 'telephony_call_get_status', + 'telephony_call_get_type', + 'telephony_call_release_call_list', + 'telephony_deinit', + 'telephony_get_state', + 'telephony_init', + 'telephony_modem_get_imei', + 'telephony_modem_get_meid', + 'telephony_modem_get_power_status', + 'telephony_network_get_base_station_id', + 'telephony_network_get_base_station_latitude', + 'telephony_network_get_base_station_longitude', + 'telephony_network_get_cell_id', + 'telephony_network_get_default_data_subscription', + 'telephony_network_get_default_subscription', + 'telephony_network_get_lac', + 'telephony_network_get_mcc', + 'telephony_network_get_mnc', + 'telephony_network_get_network_id', + 'telephony_network_get_network_name', + 'telephony_network_get_network_name_option', + 'telephony_network_get_ps_type', + 'telephony_network_get_roaming_status', + 'telephony_network_get_rssi', + 'telephony_network_get_selection_mode', + 'telephony_network_get_service_state', + 'telephony_network_get_signal_strength', + 'telephony_network_get_system_id', + 'telephony_network_get_tac', + 'telephony_network_get_type', + 'telephony_set_noti_cb', + 'telephony_set_state_changed_cb', + 'telephony_sim_get_application_list', + 'telephony_sim_get_call_forwarding_indicator_state', + 'telephony_sim_get_group_id1', + 'telephony_sim_get_icc_id', + 'telephony_sim_get_lock_state', + 'telephony_sim_get_msin', + 'telephony_sim_get_operator', + 'telephony_sim_get_spn', + 'telephony_sim_get_state', + 'telephony_sim_get_subscriber_id', + 'telephony_sim_get_subscriber_number', + 'telephony_sim_is_changed', + 'telephony_unset_noti_cb', + 'telephony_unset_state_changed_cb', + ], + 'libcapi-ui-inputmethod.so.0': [ + 'ime_commit_content', + 'ime_commit_string', + 'ime_context_get_autocapital_type', + 'ime_context_get_bidi_direction', + 'ime_context_get_cursor_position', + 'ime_context_get_input_hint', + 'ime_context_get_language', + 'ime_context_get_layout', + 'ime_context_get_layout_variation', + 'ime_context_get_password_mode', + 'ime_context_get_prediction_mode', + 'ime_context_get_return_key_state', + 'ime_context_get_return_key_type', + 'ime_create_option_window', + 'ime_delete_surrounding_text', + 'ime_destroy_option_window', + 'ime_device_info_get_class', + 'ime_device_info_get_name', + 'ime_device_info_get_subclass', + 'ime_event_set_accessibility_state_changed_cb', + 'ime_event_set_cursor_position_updated_cb', + 'ime_event_set_display_language_changed_cb', + 'ime_event_set_focus_in_cb', + 'ime_event_set_focus_out_cb', + 'ime_event_set_geometry_requested_cb', + 'ime_event_set_imdata_requested_cb', + 'ime_event_set_imdata_set_cb', + 'ime_event_set_input_context_reset_cb', + 'ime_event_set_language_requested_cb', + 'ime_event_set_language_set_cb', + 'ime_event_set_layout_set_cb', + 'ime_event_set_mime_type_set_request_cb', + 'ime_event_set_option_window_created_cb', + 'ime_event_set_option_window_destroyed_cb', + 'ime_event_set_prediction_hint_set_cb', + 'ime_event_set_process_input_device_event_cb', + 'ime_event_set_process_key_event_cb', + 'ime_event_set_return_key_state_set_cb', + 'ime_event_set_return_key_type_set_cb', + 'ime_event_set_rotation_degree_changed_cb', + 'ime_event_set_surrounding_text_updated_cb', + 'ime_event_unset_process_input_device_event_cb', + 'ime_get_main_window', + 'ime_get_selected_text', + 'ime_get_surrounding_text', + 'ime_hide_preedit_string', + 'ime_input_device_rotary_get_direction', + 'ime_request_surrounding_text', + 'ime_run', + 'ime_send_key_event', + 'ime_send_private_command', + 'ime_set_floating_drag_end', + 'ime_set_floating_drag_start', + 'ime_set_floating_mode', + 'ime_set_selection', + 'ime_set_size', + 'ime_show_preedit_string', + 'ime_update_preedit_string', + ], + 'libcapi-ui-inputmethod-manager.so.0': [ + 'ime_manager_get_active_ime', + 'ime_manager_get_enabled_ime_count', + 'ime_manager_is_ime_enabled', + 'ime_manager_show_ime_list', + 'ime_manager_show_ime_selector', + ], + 'libstt.so': [ + 'stt_cancel', + 'stt_create', + 'stt_destroy', + 'stt_foreach_detailed_result', + 'stt_foreach_supported_engines', + 'stt_foreach_supported_languages', + 'stt_get_default_language', + 'stt_get_engine', + 'stt_get_error_message', + 'stt_get_private_data', + 'stt_get_recording_volume', + 'stt_get_state', + 'stt_is_recognition_type_supported', + 'stt_prepare', + 'stt_set_credential', + 'stt_set_default_language_changed_cb', + 'stt_set_engine', + 'stt_set_engine_changed_cb', + 'stt_set_error_cb', + 'stt_set_private_data', + 'stt_set_recognition_result_cb', + 'stt_set_silence_detection', + 'stt_set_start_sound', + 'stt_set_state_changed_cb', + 'stt_set_stop_sound', + 'stt_start', + 'stt_stop', + 'stt_unprepare', + 'stt_unset_default_language_changed_cb', + 'stt_unset_engine_changed_cb', + 'stt_unset_error_cb', + 'stt_unset_recognition_result_cb', + 'stt_unset_start_sound', + 'stt_unset_state_changed_cb', + 'stt_unset_stop_sound', + ], + 'libstt_engine.so': [ + 'stte_main', + 'stte_send_error', + 'stte_send_result', + 'stte_send_speech_status', + 'stte_set_private_data_requested_cb', + 'stte_set_private_data_set_cb', + ], + 'libtts.so': [ + 'tts_add_text', + 'tts_create', + 'tts_destroy', + 'tts_foreach_supported_voices', + 'tts_get_default_voice', + 'tts_get_error_message', + 'tts_get_max_text_size', + 'tts_get_mode', + 'tts_get_private_data', + 'tts_get_speed_range', + 'tts_get_state', + 'tts_pause', + 'tts_play', + 'tts_prepare', + 'tts_set_credential', + 'tts_set_default_voice_changed_cb', + 'tts_set_engine_changed_cb', + 'tts_set_error_cb', + 'tts_set_mode', + 'tts_set_private_data', + 'tts_set_state_changed_cb', + 'tts_set_utterance_completed_cb', + 'tts_set_utterance_started_cb', + 'tts_stop', + 'tts_unprepare', + 'tts_unset_default_voice_changed_cb', + 'tts_unset_engine_changed_cb', + 'tts_unset_error_cb', + 'tts_unset_state_changed_cb', + 'tts_unset_utterance_completed_cb', + 'tts_unset_utterance_started_cb', + ], + 'libtts_engine.so': [ + 'ttse_get_pitch_range', + 'ttse_get_speed_range', + 'ttse_main', + 'ttse_send_error', + 'ttse_send_result', + 'ttse_set_private_data_requested_cb', + 'ttse_set_private_data_set_cb', + ], + 'libvc.so': [ + 'vc_cmd_create', + 'vc_cmd_destroy', + 'vc_cmd_get_command', + 'vc_cmd_get_format', + 'vc_cmd_get_type', + 'vc_cmd_get_unfixed_command', + 'vc_cmd_list_add', + 'vc_cmd_list_create', + 'vc_cmd_list_destroy', + 'vc_cmd_list_first', + 'vc_cmd_list_foreach_commands', + 'vc_cmd_list_get_count', + 'vc_cmd_list_get_current', + 'vc_cmd_list_last', + 'vc_cmd_list_next', + 'vc_cmd_list_prev', + 'vc_cmd_list_remove', + 'vc_cmd_set_command', + 'vc_cmd_set_format', + 'vc_cmd_set_type', + 'vc_deinitialize', + 'vc_foreach_supported_languages', + 'vc_get_current_language', + 'vc_get_result', + 'vc_get_service_state', + 'vc_get_state', + 'vc_get_system_command_list', + 'vc_initialize', + 'vc_prepare', + 'vc_request_dialog', + 'vc_set_command_list', + 'vc_set_current_language_changed_cb', + 'vc_set_error_cb', + 'vc_set_invocation_name', + 'vc_set_result_cb', + 'vc_set_service_state_changed_cb', + 'vc_set_state_changed_cb', + 'vc_unprepare', + 'vc_unset_command_list', + 'vc_unset_current_language_changed_cb', + 'vc_unset_error_cb', + 'vc_unset_result_cb', + 'vc_unset_service_state_changed_cb', + 'vc_unset_state_changed_cb', + ], +}; diff --git a/lib/src/extensions.dart b/lib/src/extensions.dart new file mode 100644 index 0000000..21c9bf7 --- /dev/null +++ b/lib/src/extensions.dart @@ -0,0 +1,16 @@ +import 'dart:ffi'; +import 'package:ffi/ffi.dart'; + +extension Int8Pointer on Pointer { + int get length => cast().length; + + String toDartString({int? length}) { + return cast().toDartString(length: length); + } +} + +extension StringInt8Pointer on String { + Pointer toNativeInt8({Allocator allocator = malloc}) { + return toNativeUtf8(allocator: allocator).cast(); + } +} diff --git a/packages/symgen/.gitignore b/packages/symgen/.gitignore new file mode 100644 index 0000000..3c8a157 --- /dev/null +++ b/packages/symgen/.gitignore @@ -0,0 +1,6 @@ +# Files and directories created by pub. +.dart_tool/ +.packages + +# Conventional directory for build output. +build/ diff --git a/packages/symgen/README.md b/packages/symgen/README.md new file mode 100644 index 0000000..4ebb1c6 --- /dev/null +++ b/packages/symgen/README.md @@ -0,0 +1,3 @@ +# symgen + +Symbol mapping generator for shared libraries. diff --git a/packages/symgen/analysis_options.yaml b/packages/symgen/analysis_options.yaml new file mode 100644 index 0000000..18b40b8 --- /dev/null +++ b/packages/symgen/analysis_options.yaml @@ -0,0 +1,16 @@ +# Defines a default set of lint rules enforced for projects at Google. For +# details and rationale, see +# https://github.com/dart-lang/pedantic#enabled-lints. + +include: package:pedantic/analysis_options.yaml + +# For lint rules and documentation, see http://dart-lang.github.io/linter/lints. + +# Uncomment to specify additional rules. +# linter: +# rules: +# - camel_case_types + +# analyzer: +# exclude: +# - path/to/excluded/files/** diff --git a/packages/symgen/bin/symgen.dart b/packages/symgen/bin/symgen.dart new file mode 100644 index 0000000..7b3982c --- /dev/null +++ b/packages/symgen/bin/symgen.dart @@ -0,0 +1,5 @@ +// Copyright 2021 Samsung Electronics Co., Ltd. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +export 'package:symgen/src/executable.dart'; diff --git a/packages/symgen/lib/src/config.dart b/packages/symgen/lib/src/config.dart new file mode 100644 index 0000000..f849617 --- /dev/null +++ b/packages/symgen/lib/src/config.dart @@ -0,0 +1,103 @@ +// Copyright 2021 Samsung Electronics Co., Ltd. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +import 'dart:io' show Platform; +import 'package:args/args.dart'; +import 'package:file/file.dart'; +import 'package:file/local.dart'; +import 'package:yaml/yaml.dart'; + +class Config { + String get name => _name; + late String _name; + + String get output => _output; + late String _output; + + List get allowlist => _allowlist; + late final List _allowlist = []; + + String get libraryPath => _libraryPath; + late String _libraryPath; + + List get targetLibraries => _targetLibraries; + late List _targetLibraries; + + String get preamble => _preamble; + late String _preamble; + + Config._(); + + factory Config.fromYaml(String yaml, {ArgResults? argResults}) { + return Config.fromYamlMap( + loadYaml(yaml) as YamlMap, + argResults: argResults, + ); + } + + factory Config.fromYamlMap(YamlMap map, {ArgResults? argResults}) { + final config = Config._(); + + config._name = map.getValue('name'); + + config._output = argResults?['output'] ?? + _mapEnvironmentVariables(map.getValue('output')); + + config._libraryPath = argResults?['library-path'] ?? + _mapEnvironmentVariables(map.getValue('library-path')); + + config._allowlist.addAll( + _readAllowlistFile( + argResults?['allowlist'] ?? + map.getValue( + 'allowlist', + mandatory: false, + ), + ), + ); + + config._targetLibraries = + List.unmodifiable(map.getValue('target-libraries')); + + config._preamble = + map.getValue('preamble', mandatory: false, defaultValue: ''); + + return config; + } + + static String? _mapEnvironmentVariables(String? value) { + if (value == null || !value.contains('\$\{')) { + return value; + } + for (var key in Platform.environment.keys) { + value = value!.replaceAll('\$\{$key\}', Platform.environment[key]!); + } + return value; + } + + static List _readAllowlistFile(String? path) { + if (path == null) { + return []; + } + final file = LocalFileSystem().file(path); + if (!file.existsSync()) { + throw FileSystemException('Could not find the allowlist file', path); + } + return file.readAsLinesSync(); + } +} + +extension _YamlMapExtensions on YamlMap { + dynamic getValue(String key, {dynamic defaultValue, bool mandatory = true}) { + dynamic value = this[key]; + if (value == null) { + if (defaultValue == null && mandatory) { + throw StateError('$key not found'); + } + value = defaultValue; + } + + return value; + } +} diff --git a/packages/symgen/lib/src/executable.dart b/packages/symgen/lib/src/executable.dart new file mode 100644 index 0000000..7aff43e --- /dev/null +++ b/packages/symgen/lib/src/executable.dart @@ -0,0 +1,81 @@ +// Copyright 2021 Samsung Electronics Co., Ltd. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// Executable script to generate symbol mapping for shared libraries. + +import 'dart:io'; +import 'package:args/args.dart'; + +import 'config.dart'; +import 'generator.dart'; + +void main(List args) { + final argResults = _parseArguments(args); + + final configFile = File(argResults['config']); + if (!configFile.existsSync()) { + print('Error: $configFile not found.'); + exit(1); + } + + Config config; + try { + config = Config.fromYaml( + configFile.readAsStringSync(), + argResults: argResults, + ); + } catch (e) { + print(e); + print('Error: Please fix configuration errors and re-run the tool.'); + exit(1); + } + + final generator = CodeGenerator(config); + generator.generate(); +} + +ArgResults _parseArguments(List args) { + final parser = ArgParser(allowTrailingOptions: true) + ..addFlag( + 'help', + abbr: 'h', + help: 'Print this usage.', + negatable: false, + ) + ..addOption( + 'config', + help: 'Path to Yaml file containing configurations.', + mandatory: true, + ) + ..addOption( + 'output', + help: 'Override the output value set in configrations.', + mandatory: false, + ) + ..addOption( + 'library-path', + help: 'Override the library-path value set in configrations.', + mandatory: false, + ) + ..addOption( + 'allowlist', + help: 'Override the allow value set in configrations.', + mandatory: false, + ); + + ArgResults results; + try { + results = parser.parse(args); + if (results.wasParsed('help')) { + print(parser.usage); + exit(0); + } + } catch (e) { + print(e); + print(parser.usage); + exit(1); + } + + return results; +} diff --git a/packages/symgen/lib/src/generator.dart b/packages/symgen/lib/src/generator.dart new file mode 100644 index 0000000..d66bccd --- /dev/null +++ b/packages/symgen/lib/src/generator.dart @@ -0,0 +1,58 @@ +// Copyright 2021 Samsung Electronics Co., Ltd. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +import 'dart:convert'; +import 'dart:io'; +import 'package:file/file.dart'; +import 'package:file/local.dart'; + +import 'config.dart'; + +class CodeGenerator { + final Config _config; + + CodeGenerator(Config config) : _config = config; + + void generate() { + var fs = const LocalFileSystem(); + final libraryPath = fs.directory(_config.libraryPath); + if (!libraryPath.existsSync()) { + throw FileSystemException('$libraryPath is not found.'); + } + + var contents = ''' +${_config.preamble} +// AUTO GENERATED FILE, DO NOT EDIT. +// +// Generated by `package:symgen`. + +final Map> ${_config.name} = { +'''; + for (var library in _config.targetLibraries) { + contents += ' \'$library\': [\n'; + for (var symbol in _getSymbols(libraryPath.childFile(library))) { + if (_config.allowlist.isEmpty || _config.allowlist.contains(symbol)) { + contents += ' \'$symbol\',\n'; + } + } + contents += ' ],\n'; + } + contents += '};\n'; + + final outputFile = fs.file(_config.output); + outputFile.parent.createSync(recursive: true); + outputFile.writeAsStringSync(contents); + } + + Iterable _getSymbols(File libraryFile) sync* { + var result = Process.runSync('nm', ['-D', libraryFile.absolute.path]); + final exp = RegExp(r'[0-9a-f]+ T ([a-zA-Z].+)'); + for (var line in LineSplitter.split(result.stdout)) { + final match = exp.firstMatch(line); + if (match != null) { + yield match.group(1)!; + } + } + } +} diff --git a/packages/symgen/pubspec.yaml b/packages/symgen/pubspec.yaml new file mode 100644 index 0000000..bbb9c29 --- /dev/null +++ b/packages/symgen/pubspec.yaml @@ -0,0 +1,14 @@ +name: symgen +description: Symbol mapping generator for shared libraries. +version: 1.0.0 + +environment: + sdk: '>=2.12.0 <3.0.0' + +dependencies: + args: ^2.1.1 + file: ^6.1.2 + yaml: ^3.1.0 + +dev_dependencies: + pedantic: ^1.10.0 diff --git a/pubspec.yaml b/pubspec.yaml new file mode 100644 index 0000000..5d21d91 --- /dev/null +++ b/pubspec.yaml @@ -0,0 +1,17 @@ +name: tizen_interop +description: Provides Dart bindings and utility functions for Tizen native APIs. +version: 0.0.1 +homepage: https://github.com/flutter-tizen/tizen_interop + +environment: + sdk: ">=2.12.0 <3.0.0" + +dependencies: + ffi: ^1.1.2 + path: ^1.8.0 + yaml: ^3.1.0 + +dev_dependencies: + ffigen: ^3.0.0 + symgen: + path: packages/symgen