Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Unified Diff: impl/dummy/dummy.go

Issue 1355783002: Refactor keys and queries in datastore service and implementation. (Closed) Base URL: https://github.com/luci/gae.git@master
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: impl/dummy/dummy.go
diff --git a/impl/dummy/dummy.go b/impl/dummy/dummy.go
index 462ce3113420ecf4f9372e93c63247f7accb84c8..b559a479ab7fd22ceb0d967692064bdb646a1efb 100644
--- a/impl/dummy/dummy.go
+++ b/impl/dummy/dummy.go
@@ -11,7 +11,6 @@ import (
"time"
"github.com/luci/gae/service/datastore"
- "github.com/luci/gae/service/datastore/dskey"
"github.com/luci/gae/service/info"
"github.com/luci/gae/service/memcache"
"github.com/luci/gae/service/taskqueue"
@@ -65,20 +64,16 @@ func ni() error {
type ds struct{}
-func (ds) NewKey(kind string, sid string, iid int64, par datastore.Key) datastore.Key {
- return dskey.New("dummy~appid", "", kind, sid, iid, par)
-}
-func (ds) DecodeKey(string) (datastore.Key, error) { panic(ni()) }
-func (ds) PutMulti([]datastore.Key, []datastore.PropertyMap, datastore.PutMultiCB) error {
+func (ds) PutMulti([]*datastore.Key, []datastore.PropertyMap, datastore.PutMultiCB) error {
panic(ni())
}
-func (ds) GetMulti([]datastore.Key, datastore.MultiMetaGetter, datastore.GetMultiCB) error {
+func (ds) GetMulti([]*datastore.Key, datastore.MultiMetaGetter, datastore.GetMultiCB) error {
panic(ni())
}
-func (ds) DeleteMulti([]datastore.Key, datastore.DeleteMultiCB) error { panic(ni()) }
-func (ds) NewQuery(string) datastore.Query { panic(ni()) }
-func (ds) DecodeCursor(string) (datastore.Cursor, error) { panic(ni()) }
-func (ds) Run(datastore.Query, datastore.RawRunCB) error { panic(ni()) }
+func (ds) DeleteMulti([]*datastore.Key, datastore.DeleteMultiCB) error { panic(ni()) }
+func (ds) NewQuery(string) datastore.Query { panic(ni()) }
+func (ds) DecodeCursor(string) (datastore.Cursor, error) { panic(ni()) }
+func (ds) Run(*datastore.FinalizedQuery, datastore.RawRunCB) error { panic(ni()) }
func (ds) RunInTransaction(func(context.Context) error, *datastore.TransactionOptions) error {
panic(ni())
}

Powered by Google App Engine
This is Rietveld 408576698