浏览代码

Remove unused method

xormplus 9 年之前
父节点
当前提交
f43e4450cd
共有 2 个文件被更改,包括 1 次插入12 次删除
  1. 0 11
      engine.go
  2. 1 1
      session.go

+ 0 - 11
engine.go

@@ -1186,17 +1186,6 @@ func (engine *Engine) mapType(v reflect.Value) *core.Table {
 	return table
 }
 
-// Map a struct to a table
-func (engine *Engine) mapping(beans ...interface{}) (e error) {
-	engine.mutex.Lock()
-	defer engine.mutex.Unlock()
-	for _, bean := range beans {
-		v := rValue(bean)
-		engine.Tables[v.Type()] = engine.mapType(v)
-	}
-	return
-}
-
 // IsTableEmpty if a table has any reocrd
 func (engine *Engine) IsTableEmpty(bean interface{}) (bool, error) {
 	session := engine.NewSession()

+ 1 - 1
session.go

@@ -19,7 +19,7 @@ import (
 	"github.com/xormplus/core"
 )
 
-// Struct Session keep a pointer to sql.DB and provides all execution of all
+// Session keep a pointer to sql.DB and provides all execution of all
 // kind of database operations.
 type Session struct {
 	db                     *core.DB