C# Class Rock.Data.DbMetadataExtensions

from https://github.com/divega/UdfCodeFirstSample
Afficher le fichier Open project: NewSpring/Rock

Méthodes publiques

Méthode Description
CreateAndAddFunction ( this item, string name, IList parameters, IList returnValues, string body = null ) : EdmFunction

Creates the and add function.

GetDefaultNamespace ( this layerModel ) : string

Obtain the namespace name from existing model defined types.

Only one namespace is allowed. Throws if there are multiple namespaces or if there aren't any types defined in the model.

GetDefaultSchema ( this layerModel ) : string

Obtains the default schema from existing entity sets in the model.

Throws if more than one schema is used or if the model contains no entity sets.

GetStorePrimitiveType ( this model, PrimitiveTypeKind typeKind ) : System.Data.Entity.Core.Metadata.Edm.EdmType

Translate a conceptual primitive type to an adequate store specific primitive type according to the provider configuration of the model.

Method Details

CreateAndAddFunction() public static méthode

Creates the and add function.
public static CreateAndAddFunction ( this item, string name, IList parameters, IList returnValues, string body = null ) : EdmFunction
item this The item.
name string The name.
parameters IList The parameters.
returnValues IList The return values.
body string The body.
Résultat EdmFunction

GetDefaultNamespace() public static méthode

Obtain the namespace name from existing model defined types.
Only one namespace is allowed. Throws if there are multiple namespaces or if there aren't any types defined in the model.
public static GetDefaultNamespace ( this layerModel ) : string
layerModel this An EdmModel instance representing conceptual or store model.
Résultat string

GetDefaultSchema() public static méthode

Obtains the default schema from existing entity sets in the model.
Throws if more than one schema is used or if the model contains no entity sets.
public static GetDefaultSchema ( this layerModel ) : string
layerModel this An instance of EdmModel representing either the conceptual or the store model.
Résultat string

GetStorePrimitiveType() public static méthode

Translate a conceptual primitive type to an adequate store specific primitive type according to the provider configuration of the model.
public static GetStorePrimitiveType ( this model, PrimitiveTypeKind typeKind ) : System.Data.Entity.Core.Metadata.Edm.EdmType
model this A DbModel instance with provider information
typeKind PrimitiveTypeKind A PrimitiveTypeKind instance representing the conceptual primitive type to be translated
Résultat System.Data.Entity.Core.Metadata.Edm.EdmType