Click or drag to resize

HpsvContextTryGetDeserializedValueT Method

Tries to re-serialize stored value. This is useful when you need to pass object between multiple service operations or multiple services. If such object is defined within a shared script then it is internally a distinct .NET type for each service operation. This method tries to overcome that via binary serialization/deserialization

Namespace:  HP.SV.DotNetRuleApi
Assembly:  HP.SV.DotNetRuleApi (in HP.SV.DotNetRuleApi.dll) Version: 5.3.0.9999-localBuild
Syntax
C#
public bool TryGetDeserializedValue<T>(
	string key,
	out T value
)

Parameters

key
Type: SystemString
The key of the value to get.
value
Type: T
The value of the specified key. If the value is not present or the re-serialization fails then the value is set to default(T).

Type Parameters

T

Return Value

Type: Boolean
True if the value was present in the context, the re-serialization succeeded and the casting succeeded, false otherwise.
See Also