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

Class MetaDataTypes

Inheritance
System.Object
MetaDataTypes
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.MetaDataPlus.Configurator
Assembly: Mediachase.MetaDataPlus.dll
Version: 13.30.0
Syntax
public static class MetaDataTypes

Methods

ClearCache()

Clear meta keys in the cache.

Declaration
public static void ClearCache()

GetApplicationValue(MetaDataContext, MetaField, Object)

Formats a value from the database to a value for use in the application. This may access and modify the database for complex data types.

Declaration
public static object GetApplicationValue(MetaDataContext context, MetaField metaField, object value)
Parameters
Type Name Description
MetaDataContext context

The meta data context.

MetaField metaField

The meta field that the value is an instance of.

System.Object value

The meta field value, as represented in the result of a database call.

Returns
Type Description
System.Object

The meta field value, as represented in the database.

GetColumnName(MetaDataType)

Gets the appropriated property column name, based on the input type.

Declaration
public static string GetColumnName(MetaDataType type)
Parameters
Type Name Description
MetaDataType type

The meta data type to get the appropriated column name.

Returns
Type Description
System.String

The property type name of the MetaDataType.

Exceptions
Type Condition
System.NotSupportedException

GetComplexValueType(MetaDataType)

Declaration
public static Type GetComplexValueType(MetaDataType type)
Parameters
Type Name Description
MetaDataType type
Returns
Type Description
System.Type

GetDatabaseValue(MetaDataContext, MetaObject, MetaField, Object)

Formats a value from the application to a value suitable for use in a stored procedure parameter. This may access and modify the database for complex data types.

Declaration
public static object GetDatabaseValue(MetaDataContext context, MetaObject metaObject, MetaField metaField, object value)
Parameters
Type Name Description
MetaDataContext context

The meta data context.

MetaObject metaObject

The meta object that the value is contained in.

MetaField metaField

The meta field that the value is an instance of.

System.Object value

The value, as represented in the application domain.

Returns
Type Description
System.Object

The value formatted for use in a database call.

GetDatabaseValue(MetaDataContext, MetaObject, Nullable<Int32>, MetaField, Object)

Formats a value from the application to a value suitable for use in a stored procedure parameter. This may access and modify the database for complex data types.

Declaration
public static object GetDatabaseValue(MetaDataContext context, MetaObject metaObject, int? workId, MetaField metaField, object value)
Parameters
Type Name Description
MetaDataContext context

The meta data context.

MetaObject metaObject

The meta object that the value is contained in.

System.Nullable<System.Int32> workId

The content work Id.

MetaField metaField

The meta field that the value is an instance of.

System.Object value

The value, as represented in the application domain.

Returns
Type Description
System.Object

The value formatted for use in a database call.

GetDataParameterType(MetaField, Boolean)

Declaration
public static DataParameterType? GetDataParameterType(MetaField metaField, bool isNullValue)
Parameters
Type Name Description
MetaField metaField
System.Boolean isNullValue
Returns
Type Description
System.Nullable<DataParameterType>

GetDefaultValue(MetaDataType)

Declaration
public static object GetDefaultValue(MetaDataType type)
Parameters
Type Name Description
MetaDataType type
Returns
Type Description
System.Object

GetMetaFieldSerializationValue(MetaDataContext, MetaField, Object)

Gets the serialization value for the meta field.

Declaration
public static string GetMetaFieldSerializationValue(MetaDataContext context, MetaField metaField, object value)
Parameters
Type Name Description
MetaDataContext context

The context.

MetaField metaField

The meta field.

System.Object value

The value.

Returns
Type Description
System.String
Exceptions
Type Condition
System.NotSupportedException

MetaDataType File is not supported in seralization

InvalidateCache(Int32, MetaField)

Clear a specific meta key in the cache.

Declaration
public static void InvalidateCache(int metaKey, MetaField metaField)
Parameters
Type Name Description
System.Int32 metaKey

The meta key.

MetaField metaField

The meta field.

IsComplexType(MetaDataType)

Declaration
public static bool IsComplexType(MetaDataType type)
Parameters
Type Name Description
MetaDataType type
Returns
Type Description
System.Boolean

IsElementaryType(MetaDataType)

Declaration
public static bool IsElementaryType(MetaDataType type)
Parameters
Type Name Description
MetaDataType type
Returns
Type Description
System.Boolean

ParseSimpleMetaFieldValue(MetaDataContext, MetaField, String)

Parses the simple meta field value.

Declaration
public static object ParseSimpleMetaFieldValue(MetaDataContext metaDataContext, MetaField metaField, string value)
Parameters
Type Name Description
MetaDataContext metaDataContext

The meta data context.

MetaField metaField

The meta field.

System.String value

The value.

Returns
Type Description
System.Object
Exceptions
Type Condition
System.FormatException

ParseToUtc(String)

Declaration
public static DateTime ParseToUtc(string stringValue)
Parameters
Type Name Description
System.String stringValue
Returns
Type Description
System.DateTime