private VBDocument Create(DataTable dataTable, string namespaceName, string projectName) { VBNamespace ns = new VBNamespace(namespaceName); VBDocument document = new VBDocument(dataTable.TableName, projectName); ns.Classes.Add(new ModelClass(dataTable)); document.Namespaces.Add(ns); return(document); }
public VBDocument Create(DataSet dataset, string dbContextName, string defaultNamespaceName, string projectName) { DbClass cls = new DbClass(dataset, dbContextName); VBDocument document = new VBDocument(dbContextName, projectName); VBNamespace ns = CreateNamespace(defaultNamespaceName, GetUsingList(defaultNamespaceName, projectName), cls); document.Namespaces.Add(ns); return(document); }
private VBDocument Create(DataTable dataTable, string namespaceName, string projectName) { InsertClass cls = new InsertClass(dataTable); VBDocument document = new VBDocument(dataTable.TableName, projectName); VBNamespace ns = CreateNamespace(CreateNamespaceName(namespaceName, dataTable.TableName), GetUsingList(), cls); document.Namespaces.Add(ns); return(document); }