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

Class MetaModelSync

Provides meta model compare and synchronization commands.

Inheritance
System.Object
MetaModelSync
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.BusinessFoundation.Data.Meta.Schema
Assembly: Mediachase.BusinessFoundation.Data.dll
Version: 12.17.2
Syntax
public static class MetaModelSync
Remarks

Use FindModifications(SchemaDocument, XmlNode) to compare meta model. Use Execute(SchemaDocument, SyncCommand[]) to execute synchronization commands.

Methods

CreateEmptyMetaModel()

Creates the empty meta model.

Declaration
public static XmlDocument CreateEmptyMetaModel()
Returns
Type Description
System.Xml.XmlDocument

Execute(SchemaDocument, SyncCommand[])

Executes the specified commands.

Declaration
public static void Execute(SchemaDocument schema, params SyncCommand[] commands)
Parameters
Type Name Description
SchemaDocument schema

The schema.

SyncCommand[] commands

The commands.

FindModifications(SchemaDocument, XmlNode)

Finds the modifications.

Declaration
public static SyncCommand[] FindModifications(SchemaDocument schema, XmlNode updatedMetaModel)
Parameters
Type Name Description
SchemaDocument schema

The schema.

System.Xml.XmlNode updatedMetaModel

The updated meta model.

Returns
Type Description
SyncCommand[]

FindModifications(SchemaDocument, XmlNode, XmlNode)

Finds the modifications.

Declaration
public static SyncCommand[] FindModifications(SchemaDocument schema, XmlNode updatedMetaModel, XmlNode originalMetaModel)
Parameters
Type Name Description
SchemaDocument schema

The schema.

System.Xml.XmlNode updatedMetaModel

The updated meta model.

System.Xml.XmlNode originalMetaModel

The original meta model.

Returns
Type Description
SyncCommand[]

FindModifications(String, String, String)

Finds the modifications.

Declaration
public static SyncCommand[] FindModifications(string schemaFile, string updatedMetaModelFile, string originalMetaModelPath)
Parameters
Type Name Description
System.String schemaFile

The schema file.

System.String updatedMetaModelFile

The updated meta model file.

System.String originalMetaModelPath

The original meta model path.

Returns
Type Description
SyncCommand[]

FindNotDeffinedElements(SchemaDocument, XmlNode)

Finds the not deffined elements with Empty Keys

Declaration
public static MetaModelElement[] FindNotDeffinedElements(SchemaDocument schema, XmlNode updatedMetaModel)
Parameters
Type Name Description
SchemaDocument schema

The schema.

System.Xml.XmlNode updatedMetaModel

The updated meta model.

Returns
Type Description
MetaModelElement[]

GenerateMetaModel(SchemaDocument, MetaModelElement[])

Generates the current meta model.

Declaration
public static XmlDocument GenerateMetaModel(SchemaDocument schema, params MetaModelElement[] selectedElements)
Parameters
Type Name Description
SchemaDocument schema

The schema.

MetaModelElement[] selectedElements

The selected elements. The item should be formated /Path/[ContainerName]::[Name]. If selectedElements is empty collection, returns all elements.

Returns
Type Description
System.Xml.XmlDocument