November Happy Hour will be moved to Thursday December 5th.

Class MetaHelper

Implements operations for the meta helper.

Inheritance
System.Object
MetaHelper
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.Storage
Assembly: Mediachase.Commerce.dll
Version: 13.30.0
Syntax
public static class MetaHelper

Methods

Deserialize(Byte[])

Deserializes the specified serialized data.

Declaration
public static MetaObjectSerialized Deserialize(byte[] serializedData)
Parameters
Type Name Description
System.Byte[] serializedData

The serialized data.

Returns
Type Description
MetaObjectSerialized

The deserialized object, or null if the input was null or contained errors.

GetMetaFieldValue(MetaField, Object)

Gets the meta field value.

Declaration
public static object GetMetaFieldValue(MetaField mf, object value)
Parameters
Type Name Description
MetaField mf

The mf.

System.Object value

The value.

Returns
Type Description
System.Object

SetMetaFieldValue(MetaDataContext, MetaObject, String, Object[])

Sets values for the meta object's meta field. Doesn't set file and image values.

Declaration
public static bool SetMetaFieldValue(MetaDataContext context, MetaObject obj, string fieldName, object[] values)
Parameters
Type Name Description
MetaDataContext context

The context.

MetaObject obj

The obj.

System.String fieldName

Name of the field.

System.Object[] values

The values.

Returns
Type Description
System.Boolean

True, if value was set successfully.

SetMetaFile(MetaDataContext, MetaObject, String, String, String, Byte[])

Sets MetaFile and Image values

Declaration
public static bool SetMetaFile(MetaDataContext context, MetaObject obj, string fieldName, string name, string contentType, byte[] fileContents)
Parameters
Type Name Description
MetaDataContext context

The context.

MetaObject obj

The obj.

System.String fieldName

Name of the field.

System.String name

The name.

System.String contentType

Type of the content.

System.Byte[] fileContents

The file contents.

Returns
Type Description
System.Boolean