SerializationInfoExtensionsTryGetValue(SerializationInfo, String, Object) Method

Tries the get value from the SerializationInfo associated with the specified name.

Definition

Namespace: KGySoft.Serialization.Binary
Assembly: KGySoft.CoreLibraries (in KGySoft.CoreLibraries.dll) Version: 8.1.0
C#
public static bool TryGetValue(
	this SerializationInfo info,
	string name,
	out Object?? value
)

Parameters

info  SerializationInfo
The SerializationInfo to retrieve the value from.
name  String
The name of the value to be retrieved.
value  Object
When this method returns, the value associated with the specified name, if the name is found; otherwise, . This parameter is passed uninitialized.

Return Value

Boolean
, if SerializationInfo contains an element with the specified name; otherwise, .

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type SerializationInfo. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).

See Also