SerializationInfo.GetUInt64(String) 方法
定义
重要
此 API 不符合 CLS。
从 SerializationInfo 存储中检索一个 64 位无符号整数值。Retrieves a 64-bit unsigned integer value from the SerializationInfo store.
public:
System::UInt64 GetUInt64(System::String ^ name);
[System.CLSCompliant(false)]
public ulong GetUInt64 (string name);
[<System.CLSCompliant(false)>]
member this.GetUInt64 : string -> uint64
Public Function GetUInt64 (name As String) As ULong
参数
- name
- String
与要检索的值关联的名称。The name associated with the value to retrieve.
返回
与 name 关联的 64 位无符号整数。The 64-bit unsigned integer associated with name.
- 属性
例外
name 为 null。name is null.
与 name 关联的值不能转换为 64 位无符号整数。The value associated with name cannot be converted to a 64-bit unsigned integer.
当前实例中没有找到具有指定名称的元素。An element with the specified name is not found in the current instance.
注解
如果该值为64位无符号整数,或可以转换为一个值,则返回该值;否则, InvalidCastException 将引发。If the value is a 64-bit unsigned integer, or can be converted to one, that value is returned; otherwise, a InvalidCastException is thrown. 所有转换都是通过与此关联的来完成的 IFormatterConverter SerializationInfo 。All conversions are done by the IFormatterConverter associated with this SerializationInfo.