public Table(string Name, Collates Collate = Collates.Defualt, Engines Engine = Engines.InnoDB) { this.Name = Name; this.Collate = Collate; this.Engine = Engine; columns = new List <Column>(); }
private static void GenerateCollate(Collates Collate, StringBuilder Builder) { Builder.Append("DEFAULT CHARACTER SET ="); switch (Collate) { case Collates.Defualt: Builder.Append("utf8"); break; case Collates.UTF8: Builder.Append("utf8mb4"); break; case Collates.ASCII: Builder.Append("utf8"); break; } Builder.Append(" COLLATE ="); switch (Collate) { case Collates.Defualt: Builder.Append("utf8_general_ci"); break; case Collates.UTF8: Builder.Append("utf8mb4_general_ci"); break; case Collates.ASCII: Builder.Append("utf8_general_ci"); break; } }
public Table(string Name, Collates Collate, Engines Engine, IndexGroup IndexGroup, params Column[] Columns) : this(Name, Collate, Engine) { columns.AddRange(Columns); this.IndexGroup = IndexGroup; }
public Table(string Name, Collates Collate, Engines Engine, params Column[] Columns) : this(Name, Collate, Engine) { columns.AddRange(Columns); }