// WARNING: This file was autogenerated by jni-bindgen. Any changes to this file may be lost!!!
#[cfg(any(feature = "all", feature = "android-app-DownloadManager"))]
__jni_bindgen! {
/// public class [DownloadManager](https://developer.android.com/reference/android/app/DownloadManager.html)
///
/// Required feature: "android-app-DownloadManager"
public class DownloadManager ("android/app/DownloadManager") extends crate::java::lang::Object {
/// [enqueue](https://developer.android.com/reference/android/app/DownloadManager.html#enqueue(android.app.DownloadManager.Request))
///
/// Required features: "android-app-DownloadManager_Request"
#[cfg(any(feature = "all", all(feature = "android-app-DownloadManager_Request")))]
pub fn enqueue<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::app::DownloadManager_Request>>) -> __jni_bindgen::std::result::Result<i64, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/app/DownloadManager", java.flags == PUBLIC, .name == "enqueue", .descriptor == "(Landroid/app/DownloadManager$Request;)J"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into())];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/app/DownloadManager\0", "enqueue\0", "(Landroid/app/DownloadManager$Request;)J\0");
__jni_env.call_long_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// [remove](https://developer.android.com/reference/android/app/DownloadManager.html#remove(long...))
pub fn remove<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env __jni_bindgen::LongArray>>) -> __jni_bindgen::std::result::Result<i32, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/app/DownloadManager", java.flags == PUBLIC | VARARGS, .name == "remove", .descriptor == "([J)I"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into())];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/app/DownloadManager\0", "remove\0", "([J)I\0");
__jni_env.call_int_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// [query](https://developer.android.com/reference/android/app/DownloadManager.html#query(android.app.DownloadManager.Query))
///
/// Required features: "android-app-DownloadManager_Query", "android-database-Cursor"
#[cfg(any(feature = "all", all(feature = "android-app-DownloadManager_Query", feature = "android-database-Cursor")))]
pub fn query<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::app::DownloadManager_Query>>) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::android::database::Cursor>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/app/DownloadManager", java.flags == PUBLIC, .name == "query", .descriptor == "(Landroid/app/DownloadManager$Query;)Landroid/database/Cursor;"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into())];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/app/DownloadManager\0", "query\0", "(Landroid/app/DownloadManager$Query;)Landroid/database/Cursor;\0");
__jni_env.call_object_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// [openDownloadedFile](https://developer.android.com/reference/android/app/DownloadManager.html#openDownloadedFile(long))
///
/// Required features: "android-os-ParcelFileDescriptor"
#[cfg(any(feature = "all", all(feature = "android-os-ParcelFileDescriptor")))]
pub fn openDownloadedFile<'env>(&'env self, arg0: i64) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::android::os::ParcelFileDescriptor>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/app/DownloadManager", java.flags == PUBLIC, .name == "openDownloadedFile", .descriptor == "(J)Landroid/os/ParcelFileDescriptor;"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0)];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/app/DownloadManager\0", "openDownloadedFile\0", "(J)Landroid/os/ParcelFileDescriptor;\0");
__jni_env.call_object_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// [getUriForDownloadedFile](https://developer.android.com/reference/android/app/DownloadManager.html#getUriForDownloadedFile(long))
///
/// Required features: "android-net-Uri"
#[cfg(any(feature = "all", all(feature = "android-net-Uri")))]
pub fn getUriForDownloadedFile<'env>(&'env self, arg0: i64) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::android::net::Uri>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/app/DownloadManager", java.flags == PUBLIC, .name == "getUriForDownloadedFile", .descriptor == "(J)Landroid/net/Uri;"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0)];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/app/DownloadManager\0", "getUriForDownloadedFile\0", "(J)Landroid/net/Uri;\0");
__jni_env.call_object_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// [getMimeTypeForDownloadedFile](https://developer.android.com/reference/android/app/DownloadManager.html#getMimeTypeForDownloadedFile(long))
///
/// Required features: "java-lang-String"
#[cfg(any(feature = "all", all(feature = "java-lang-String")))]
pub fn getMimeTypeForDownloadedFile<'env>(&'env self, arg0: i64) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::java::lang::String>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/app/DownloadManager", java.flags == PUBLIC, .name == "getMimeTypeForDownloadedFile", .descriptor == "(J)Ljava/lang/String;"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0)];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/app/DownloadManager\0", "getMimeTypeForDownloadedFile\0", "(J)Ljava/lang/String;\0");
__jni_env.call_object_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// [getMaxBytesOverMobile](https://developer.android.com/reference/android/app/DownloadManager.html#getMaxBytesOverMobile(android.content.Context))
///
/// Required features: "android-content-Context", "java-lang-Long"
#[cfg(any(feature = "all", all(feature = "android-content-Context", feature = "java-lang-Long")))]
pub fn getMaxBytesOverMobile<'env>(__jni_env: &'env __jni_bindgen::Env, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::content::Context>>) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::java::lang::Long>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/app/DownloadManager", java.flags == PUBLIC | STATIC, .name == "getMaxBytesOverMobile", .descriptor == "(Landroid/content/Context;)Ljava/lang/Long;"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into())];
let (__jni_class, __jni_method) = __jni_env.require_class_static_method("android/app/DownloadManager\0", "getMaxBytesOverMobile\0", "(Landroid/content/Context;)Ljava/lang/Long;\0");
__jni_env.call_static_object_method_a(__jni_class, __jni_method, __jni_args.as_ptr())
}
}
/// [getRecommendedMaxBytesOverMobile](https://developer.android.com/reference/android/app/DownloadManager.html#getRecommendedMaxBytesOverMobile(android.content.Context))
///
/// Required features: "android-content-Context", "java-lang-Long"
#[cfg(any(feature = "all", all(feature = "android-content-Context", feature = "java-lang-Long")))]
pub fn getRecommendedMaxBytesOverMobile<'env>(__jni_env: &'env __jni_bindgen::Env, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::content::Context>>) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::java::lang::Long>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/app/DownloadManager", java.flags == PUBLIC | STATIC, .name == "getRecommendedMaxBytesOverMobile", .descriptor == "(Landroid/content/Context;)Ljava/lang/Long;"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into())];
let (__jni_class, __jni_method) = __jni_env.require_class_static_method("android/app/DownloadManager\0", "getRecommendedMaxBytesOverMobile\0", "(Landroid/content/Context;)Ljava/lang/Long;\0");
__jni_env.call_static_object_method_a(__jni_class, __jni_method, __jni_args.as_ptr())
}
}
/// [addCompletedDownload](https://developer.android.com/reference/android/app/DownloadManager.html#addCompletedDownload(java.lang.String,%20java.lang.String,%20boolean,%20java.lang.String,%20java.lang.String,%20long,%20boolean))
///
/// Required features: "java-lang-String"
#[cfg(any(feature = "all", all(feature = "java-lang-String")))]
pub fn addCompletedDownload<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::java::lang::String>>, arg1: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::java::lang::String>>, arg2: bool, arg3: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::java::lang::String>>, arg4: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::java::lang::String>>, arg5: i64, arg6: bool) -> __jni_bindgen::std::result::Result<i64, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/app/DownloadManager", java.flags == PUBLIC, .name == "addCompletedDownload", .descriptor == "(Ljava/lang/String;Ljava/lang/String;ZLjava/lang/String;Ljava/lang/String;JZ)J"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into()), __jni_bindgen::AsJValue::as_jvalue(&arg1.into()), __jni_bindgen::AsJValue::as_jvalue(&arg2), __jni_bindgen::AsJValue::as_jvalue(&arg3.into()), __jni_bindgen::AsJValue::as_jvalue(&arg4.into()), __jni_bindgen::AsJValue::as_jvalue(&arg5), __jni_bindgen::AsJValue::as_jvalue(&arg6)];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/app/DownloadManager\0", "addCompletedDownload\0", "(Ljava/lang/String;Ljava/lang/String;ZLjava/lang/String;Ljava/lang/String;JZ)J\0");
__jni_env.call_long_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// public static final [ACTION_DOWNLOAD_COMPLETE](https://developer.android.com/reference/android/app/DownloadManager.html#ACTION_DOWNLOAD_COMPLETE)
pub const ACTION_DOWNLOAD_COMPLETE : &'static str = "android.intent.action.DOWNLOAD_COMPLETE";
/// public static final [ACTION_NOTIFICATION_CLICKED](https://developer.android.com/reference/android/app/DownloadManager.html#ACTION_NOTIFICATION_CLICKED)
pub const ACTION_NOTIFICATION_CLICKED : &'static str = "android.intent.action.DOWNLOAD_NOTIFICATION_CLICKED";
/// public static final [ACTION_VIEW_DOWNLOADS](https://developer.android.com/reference/android/app/DownloadManager.html#ACTION_VIEW_DOWNLOADS)
pub const ACTION_VIEW_DOWNLOADS : &'static str = "android.intent.action.VIEW_DOWNLOADS";
/// public static final [COLUMN_BYTES_DOWNLOADED_SO_FAR](https://developer.android.com/reference/android/app/DownloadManager.html#COLUMN_BYTES_DOWNLOADED_SO_FAR)
pub const COLUMN_BYTES_DOWNLOADED_SO_FAR : &'static str = "bytes_so_far";
/// public static final [COLUMN_DESCRIPTION](https://developer.android.com/reference/android/app/DownloadManager.html#COLUMN_DESCRIPTION)
pub const COLUMN_DESCRIPTION : &'static str = "description";
/// public static final [COLUMN_ID](https://developer.android.com/reference/android/app/DownloadManager.html#COLUMN_ID)
pub const COLUMN_ID : &'static str = "_id";
/// public static final [COLUMN_LAST_MODIFIED_TIMESTAMP](https://developer.android.com/reference/android/app/DownloadManager.html#COLUMN_LAST_MODIFIED_TIMESTAMP)
pub const COLUMN_LAST_MODIFIED_TIMESTAMP : &'static str = "last_modified_timestamp";
/// public static final [COLUMN_LOCAL_FILENAME](https://developer.android.com/reference/android/app/DownloadManager.html#COLUMN_LOCAL_FILENAME)
pub const COLUMN_LOCAL_FILENAME : &'static str = "local_filename";
/// public static final [COLUMN_LOCAL_URI](https://developer.android.com/reference/android/app/DownloadManager.html#COLUMN_LOCAL_URI)
pub const COLUMN_LOCAL_URI : &'static str = "local_uri";
/// public static final [COLUMN_MEDIAPROVIDER_URI](https://developer.android.com/reference/android/app/DownloadManager.html#COLUMN_MEDIAPROVIDER_URI)
pub const COLUMN_MEDIAPROVIDER_URI : &'static str = "mediaprovider_uri";
/// public static final [COLUMN_MEDIA_TYPE](https://developer.android.com/reference/android/app/DownloadManager.html#COLUMN_MEDIA_TYPE)
pub const COLUMN_MEDIA_TYPE : &'static str = "media_type";
/// public static final [COLUMN_REASON](https://developer.android.com/reference/android/app/DownloadManager.html#COLUMN_REASON)
pub const COLUMN_REASON : &'static str = "reason";
/// public static final [COLUMN_STATUS](https://developer.android.com/reference/android/app/DownloadManager.html#COLUMN_STATUS)
pub const COLUMN_STATUS : &'static str = "status";
/// public static final [COLUMN_TITLE](https://developer.android.com/reference/android/app/DownloadManager.html#COLUMN_TITLE)
pub const COLUMN_TITLE : &'static str = "title";
/// public static final [COLUMN_TOTAL_SIZE_BYTES](https://developer.android.com/reference/android/app/DownloadManager.html#COLUMN_TOTAL_SIZE_BYTES)
pub const COLUMN_TOTAL_SIZE_BYTES : &'static str = "total_size";
/// public static final [COLUMN_URI](https://developer.android.com/reference/android/app/DownloadManager.html#COLUMN_URI)
pub const COLUMN_URI : &'static str = "uri";
/// public static final [ERROR_CANNOT_RESUME](https://developer.android.com/reference/android/app/DownloadManager.html#ERROR_CANNOT_RESUME)
pub const ERROR_CANNOT_RESUME : i32 = 1008;
/// public static final [ERROR_DEVICE_NOT_FOUND](https://developer.android.com/reference/android/app/DownloadManager.html#ERROR_DEVICE_NOT_FOUND)
pub const ERROR_DEVICE_NOT_FOUND : i32 = 1007;
/// public static final [ERROR_FILE_ALREADY_EXISTS](https://developer.android.com/reference/android/app/DownloadManager.html#ERROR_FILE_ALREADY_EXISTS)
pub const ERROR_FILE_ALREADY_EXISTS : i32 = 1009;
/// public static final [ERROR_FILE_ERROR](https://developer.android.com/reference/android/app/DownloadManager.html#ERROR_FILE_ERROR)
pub const ERROR_FILE_ERROR : i32 = 1001;
/// public static final [ERROR_HTTP_DATA_ERROR](https://developer.android.com/reference/android/app/DownloadManager.html#ERROR_HTTP_DATA_ERROR)
pub const ERROR_HTTP_DATA_ERROR : i32 = 1004;
/// public static final [ERROR_INSUFFICIENT_SPACE](https://developer.android.com/reference/android/app/DownloadManager.html#ERROR_INSUFFICIENT_SPACE)
pub const ERROR_INSUFFICIENT_SPACE : i32 = 1006;
/// public static final [ERROR_TOO_MANY_REDIRECTS](https://developer.android.com/reference/android/app/DownloadManager.html#ERROR_TOO_MANY_REDIRECTS)
pub const ERROR_TOO_MANY_REDIRECTS : i32 = 1005;
/// public static final [ERROR_UNHANDLED_HTTP_CODE](https://developer.android.com/reference/android/app/DownloadManager.html#ERROR_UNHANDLED_HTTP_CODE)
pub const ERROR_UNHANDLED_HTTP_CODE : i32 = 1002;
/// public static final [ERROR_UNKNOWN](https://developer.android.com/reference/android/app/DownloadManager.html#ERROR_UNKNOWN)
pub const ERROR_UNKNOWN : i32 = 1000;
/// public static final [EXTRA_DOWNLOAD_ID](https://developer.android.com/reference/android/app/DownloadManager.html#EXTRA_DOWNLOAD_ID)
pub const EXTRA_DOWNLOAD_ID : &'static str = "extra_download_id";
/// public static final [EXTRA_NOTIFICATION_CLICK_DOWNLOAD_IDS](https://developer.android.com/reference/android/app/DownloadManager.html#EXTRA_NOTIFICATION_CLICK_DOWNLOAD_IDS)
pub const EXTRA_NOTIFICATION_CLICK_DOWNLOAD_IDS : &'static str = "extra_click_download_ids";
/// public static final [INTENT_EXTRAS_SORT_BY_SIZE](https://developer.android.com/reference/android/app/DownloadManager.html#INTENT_EXTRAS_SORT_BY_SIZE)
pub const INTENT_EXTRAS_SORT_BY_SIZE : &'static str = "android.app.DownloadManager.extra_sortBySize";
/// public static final [PAUSED_QUEUED_FOR_WIFI](https://developer.android.com/reference/android/app/DownloadManager.html#PAUSED_QUEUED_FOR_WIFI)
pub const PAUSED_QUEUED_FOR_WIFI : i32 = 3;
/// public static final [PAUSED_UNKNOWN](https://developer.android.com/reference/android/app/DownloadManager.html#PAUSED_UNKNOWN)
pub const PAUSED_UNKNOWN : i32 = 4;
/// public static final [PAUSED_WAITING_FOR_NETWORK](https://developer.android.com/reference/android/app/DownloadManager.html#PAUSED_WAITING_FOR_NETWORK)
pub const PAUSED_WAITING_FOR_NETWORK : i32 = 2;
/// public static final [PAUSED_WAITING_TO_RETRY](https://developer.android.com/reference/android/app/DownloadManager.html#PAUSED_WAITING_TO_RETRY)
pub const PAUSED_WAITING_TO_RETRY : i32 = 1;
/// public static final [STATUS_FAILED](https://developer.android.com/reference/android/app/DownloadManager.html#STATUS_FAILED)
pub const STATUS_FAILED : i32 = 16;
/// public static final [STATUS_PAUSED](https://developer.android.com/reference/android/app/DownloadManager.html#STATUS_PAUSED)
pub const STATUS_PAUSED : i32 = 4;
/// public static final [STATUS_PENDING](https://developer.android.com/reference/android/app/DownloadManager.html#STATUS_PENDING)
pub const STATUS_PENDING : i32 = 1;
/// public static final [STATUS_RUNNING](https://developer.android.com/reference/android/app/DownloadManager.html#STATUS_RUNNING)
pub const STATUS_RUNNING : i32 = 2;
/// public static final [STATUS_SUCCESSFUL](https://developer.android.com/reference/android/app/DownloadManager.html#STATUS_SUCCESSFUL)
pub const STATUS_SUCCESSFUL : i32 = 8;
}
}