Class OperationKeySerializer

Serializes an operation to reference an operation for future complete, cancel, or split operations; or other operations in custom providers.

Inheritance
System.Object
OperationKeySerializer
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Mediachase.Commerce.InventoryService.BusinessLogic
Assembly: Mediachase.Commerce.dll
Version: 10.8.0
Syntax
public class OperationKeySerializer

Constructors

OperationKeySerializer()

Declaration
public OperationKeySerializer()

Fields

MaxOperationKeyLength

Declaration
public static readonly int MaxOperationKeyLength
Field Value
Type Description
System.Int32

Properties

OperationKeyVersion

Gets the operation key version. Override to indicate custom serialization/deserialization other than the default ones.

Declaration
public virtual byte OperationKeyVersion { get; }
Property Value
Type Description
System.Byte

The operation key version.

ProviderKey

Declaration
[Obsolete("ProviderKey is no longer used, use OperationKeyVersion instead. This property will be removed in version 10.")]
public virtual Guid ProviderKey { get; }
Property Value
Type Description
System.Guid

Methods

Serialize(InventoryRequestType, InventoryChange)

Declaration
public virtual string Serialize(InventoryRequestType requestType, InventoryChange change)
Parameters
Type Name Description
InventoryRequestType requestType
InventoryChange change
Returns
Type Description
System.String

TryDeserialize(Guid, String, out InventoryRequestType, out InventoryChange)

Declaration
[Obsolete("ProviderKey is no longer used, override OperationKeyVersion to set the version of OperationKey. This method will be removed in version 10.")]
public virtual bool TryDeserialize(Guid providerKey, string value, out InventoryRequestType requestType, out InventoryChange change)
Parameters
Type Name Description
System.Guid providerKey
System.String value
InventoryRequestType requestType
InventoryChange change
Returns
Type Description
System.Boolean

TryDeserialize(String, out InventoryRequestType, out InventoryChange)

Tries to deserialize the string value to InventoryRequestType and InventoryChange.

Declaration
public virtual bool TryDeserialize(string value, out InventoryRequestType requestType, out InventoryChange change)
Parameters
Type Name Description
System.String value

String value to deserialize.

InventoryRequestType requestType

Output InventoryRequestType.

InventoryChange change

Output InventoryChange.

Returns
Type Description
System.Boolean

true if the deserialize process is completed. Otherwise false.