语言

MediaFormat.GetInteger 方法

定义

重载

名称 说明
GetInteger(String, Int32)

返回整数键的值;如果缺少键,则返回默认值。

GetInteger(String)

返回整数键的值。

GetInteger(String, Int32)

返回整数键的值;如果缺少键,则返回默认值。

[Android.Runtime.Register("getInteger", "(Ljava/lang/String;I)I", "", ApiSince=29)]
public int GetInteger(string name, int defaultValue);
[<Android.Runtime.Register("getInteger", "(Ljava/lang/String;I)I", "", ApiSince=29)>]
member this.GetInteger : string * int -> int

参数

name
String

请求其整数值的格式输入键。

defaultValue
Int32

当键不存在或其存储值为 null时返回的值。

返回

如果键不存在或密钥的存储值为 null,则 defaultValue

特性

注解

返回整数键的值;如果缺少键,则返回默认值。

Java文档android.media.MediaFormat.getInteger(java.lang.String, int)。

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

适用于

GetInteger(String)

返回整数键的值。

[Android.Runtime.Register("getInteger", "(Ljava/lang/String;)I", "")]
public int GetInteger(string name);
[<Android.Runtime.Register("getInteger", "(Ljava/lang/String;)I", "")>]
member this.GetInteger : string -> int

参数

name
String

请求其整数值的格式输入键。

返回

存储的 32 位整数值;不会转换其他数值类型。

特性

注解

返回整数键的值。

Java文档android.media.MediaFormat.getInteger(java.lang.String)。

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

适用于