/// <summary> /// Loads metadata and mapping information from the given path into an <see cref="Edmx"/> instance. /// </summary> /// <param name="edmx">The <see cref="Edmx"/> instance in which to load metadata from the given path.</param> /// <param name="splitPath">An non-delimited, i.e. split, path from which to load metadata.</param> /// <returns>An edmx instance loaded with metadata from the given <paramref name="splitPath"/>.</returns> private static Edmx Load(Edmx edmx, string splitPath) { if (splitPath.StartsWith(ResourceSchemeString)) { return(LoadFromEmbeddedResource(edmx, splitPath)); } if (MapToMetadataFileType(splitPath) == MetadataFileType.ConceptualModel) { edmx.Runtimes.First().ConceptualModels.ConceptualSchema = ConceptualSchema.Load(splitPath); return(edmx); } if (MapToMetadataFileType(splitPath) == MetadataFileType.StorageModel) { edmx.Runtimes.First().StorageModels.StorageSchema = StorageSchema.Load(splitPath); return(edmx); } if (MapToMetadataFileType(splitPath) == MetadataFileType.Mapping) { edmx.Runtimes.First().Mappings.Mapping = Mapping.Load(splitPath); return(edmx); } if (MapToMetadataFileType(splitPath) == MetadataFileType.Edmx) { return(XTypedServices.Load <Edmx, TEdmx>(splitPath, LinqToXsdTypeManager.Instance)); } throw new ArgumentException(String.Format("The path argument '{0}' must represent a path to an edmx, csdl, ssdl or msl file.", splitPath)); }
public static Mapping Load(Stream xmlStream) { using (xmlStream) { return(XTypedServices.Load <Mapping, TMapping>(xmlStream, LinqToXsdTypeManager.Instance)); } }
public static StorageSchema Load(Stream xmlStream) { using (xmlStream) { return(XTypedServices.Load <StorageSchema, TSchema>(xmlStream, LinqToXsdTypeManager.Instance)); } }
public static Edmx Load(Stream xmlStream) { using (xmlStream) { return(XTypedServices.Load <Edmx, TEdmx>(xmlStream, LinqToXsdTypeManager.Instance)); } }
/// <summary> /// Loads a new <see cref="schema"/> from an existing <see cref="System.IO.FileInfo"/>. /// <para>The given <see cref="System.IO.FileInfo"/> is saved in the <see cref="FileInfo"/> property.</para> /// </summary> /// <param name="fileInfo"></param> /// <returns></returns> public static schema Load(FileInfo fileInfo) { var schema = XTypedServices.Load <schema>(fileInfo.FullName); schema.FileInfo = fileInfo; return(schema); }
public static siteMap Load(string xmlFile) { return(XTypedServices.Load <siteMap, siteMapType>(xmlFile, LinqToXsdTypeManager.Instance)); }
public static siteMap Load(System.IO.TextReader xmlFile) { return(XTypedServices.Load <siteMap, siteMapType>(xmlFile, LinqToXsdTypeManager.Instance)); }
public static NewDataSet Load(System.IO.TextReader xmlFile) { return(XTypedServices.Load <NewDataSet>(xmlFile)); }
public static request Load(System.IO.TextReader xmlFile) { return(XTypedServices.Load <request>(xmlFile)); }
public static StorageSchema Load(string xmlFile) { return(XTypedServices.Load <StorageSchema, TSchema>(xmlFile, LinqToXsdTypeManager.Instance)); }
public static Mapping Load(string xmlFile) { return(XTypedServices.Load <Mapping, TMapping>(xmlFile, LinqToXsdTypeManager.Instance)); }
public static xdoc Load(string xmlFile) { return(XTypedServices.Load <xdoc>(xmlFile)); }
public static EntityContainer Load(string xmlFile) { return(XTypedServices.Load <EntityContainer>(xmlFile)); }
public static beans Load(System.IO.TextReader xmlFile) { return(XTypedServices.Load <beans>(xmlFile)); }
public static response Load(string xmlFile) { return(XTypedServices.Load <response>(xmlFile)); }
public static beans Load(string xmlFile) { return(XTypedServices.Load <beans>(xmlFile)); }
public static Action Load(System.IO.TextReader xmlFile) { return(XTypedServices.Load <Action>(xmlFile)); }
public static Action Load(string xmlFile) { return(XTypedServices.Load <Action>(xmlFile)); }
public static TM_PeriodDuration Load(string xmlFile) { return(XTypedServices.Load <TM_PeriodDuration>(xmlFile)); }
public static xdoc Load(System.IO.TextReader xmlFile) { return(XTypedServices.Load <xdoc>(xmlFile)); }
public static TM_PeriodDuration Load(System.IO.TextReader xmlFile) { return(XTypedServices.Load <TM_PeriodDuration>(xmlFile)); }
public static MediaContainer Load(System.IO.TextReader xmlFile) { return(XTypedServices.Load <MediaContainer, MediaContainerType>(xmlFile, LinqToXsdTypeManager.Instance)); }
/// <summary>Binds the model to a value by using the specified controller context and binding context.</summary> /// <param name="controllerContext">The controller context.</param> /// <param name="bindingContext">The binding context.</param> /// <returns>The bound value.</returns> public TXTypedElement BindModel(ControllerContext controllerContext, ModelBindingContext bindingContext) { using (var reader = new StreamReader(controllerContext.HttpContext.Request.InputStream)) return(XTypedServices.Load <TXTypedElement>(reader)); }
public static guidanceItem Load(string xmlFile) { return(XTypedServices.Load <guidanceItem>(xmlFile)); }
public static guidanceItem Load(System.IO.TextReader xmlFile) { return(XTypedServices.Load <guidanceItem>(xmlFile)); }
public static request Load(string xmlFile) { return(XTypedServices.Load <request>(xmlFile)); }
public static MediaContainer Load(string xmlFile) { return(XTypedServices.Load <MediaContainer, MediaContainerType>(xmlFile, LinqToXsdTypeManager.Instance)); }
public static NewDataSet Load(string xmlFile) { return(XTypedServices.Load <NewDataSet>(xmlFile)); }