语言

VibrationAttributes.CreateForUsage(Int32) 方法

定义

创建具有给定用法的新 VibrationAttributes 实例。

[Android.Runtime.Register("createForUsage", "(I)Landroid/os/VibrationAttributes;", "", ApiSince=33)]
public static Android.OS.VibrationAttributes CreateForUsage(int usage);
[<Android.Runtime.Register("createForUsage", "(I)Landroid/os/VibrationAttributes;", "", ApiSince=33)>]
static member CreateForUsage : int -> Android.OS.VibrationAttributes

参数

usage
Int32

值为以下值之一:USAGE_UNKNOWN USAGE_ACCESSIBILITY USAGE_ALARM USAGE_COMMUNICATION_REQUEST USAGE_HARDWARE_FEEDBACK USAGE_MEDIA USAGE_NOTIFICATION USAGE_PHYSICAL_EMULATION USAGE_RINGTONE USAGE_TOUCH USAGE_GESTURE_INPUT

返回

返回的值为非 null。

特性

注解

创建具有给定用法的新 VibrationAttributes 实例。

Java文档android.os.VibrationAttributes.createForUsage(int)。

本页的某些部分是根据 创建和共享的工作进行的修改,并根据 许可证中所述的条款使用。

适用于