From e85ce422c72fff1bcbcc0a70df98bd70c4c90796 Mon Sep 17 00:00:00 2001 From: John Mai Date: Thu, 4 May 2023 22:06:52 +0800 Subject: [PATCH] remove Catalog() & Engine() methods. --- migrator.go | 2 -- migrator/table_type.go | 10 ---------- 2 files changed, 12 deletions(-) diff --git a/migrator.go b/migrator.go index 8f359432..0e01f567 100644 --- a/migrator.go +++ b/migrator.go @@ -58,11 +58,9 @@ type Index interface { // TableType table type interface type TableType interface { - Catalog() string Schema() string Name() string Type() string - Engine() (engine string, ok bool) Comment() (comment string, ok bool) } diff --git a/migrator/table_type.go b/migrator/table_type.go index 84fa3bca..360e36a4 100644 --- a/migrator/table_type.go +++ b/migrator/table_type.go @@ -14,11 +14,6 @@ type TableType struct { CommentValue sql.NullString } -// Catalog returns the catalog of the table. -func (ct TableType) Catalog() string { - return ct.CatalogValue -} - // Schema returns the schema of the table. func (ct TableType) Schema() string { return ct.SchemaValue @@ -34,11 +29,6 @@ func (ct TableType) Type() string { return ct.TypeValue } -// Engine returns the engine of current table. -func (ct TableType) Engine() (engine string, ok bool) { - return ct.EngineValue.String, ct.EngineValue.Valid -} - // Comment returns the comment of current table. func (ct TableType) Comment() (comment string, ok bool) { return ct.CommentValue.String, ct.CommentValue.Valid