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

Side by Side Diff: impl/dummy/dummy.go

Issue 2007123002: datastore: Update AllocateIDs to take keys. (Closed) Base URL: https://chromium.googlesource.com/external/github.com/luci/gae@master
Patch Set: Created 4 years, 6 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 unified diff | Download patch
« no previous file with comments | « filter/txnBuf/txnbuf_test.go ('k') | impl/memory/datastore.go » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 package dummy 5 package dummy
6 6
7 import ( 7 import (
8 "fmt" 8 "fmt"
9 "runtime" 9 "runtime"
10 "strings" 10 "strings"
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 } 66 }
67 } 67 }
68 68
69 return fmt.Errorf(niFmtStr, iface, funcName) 69 return fmt.Errorf(niFmtStr, iface, funcName)
70 } 70 }
71 71
72 /////////////////////////////////// ds //////////////////////////////////// 72 /////////////////////////////////// ds ////////////////////////////////////
73 73
74 type ds struct{} 74 type ds struct{}
75 75
76 func (ds) AllocateIDs(*datastore.Key, int) (int64, error) { 76 func (ds) AllocateIDs([]*datastore.Key) error {
77 panic(ni()) 77 panic(ni())
78 } 78 }
79 func (ds) PutMulti([]*datastore.Key, []datastore.PropertyMap, datastore.PutMulti CB) error { 79 func (ds) PutMulti([]*datastore.Key, []datastore.PropertyMap, datastore.PutMulti CB) error {
80 panic(ni()) 80 panic(ni())
81 } 81 }
82 func (ds) GetMulti([]*datastore.Key, datastore.MultiMetaGetter, datastore.GetMul tiCB) error { 82 func (ds) GetMulti([]*datastore.Key, datastore.MultiMetaGetter, datastore.GetMul tiCB) error {
83 panic(ni()) 83 panic(ni())
84 } 84 }
85 func (ds) DeleteMulti([]*datastore.Key, datastore.DeleteMultiCB) error { panic(n i()) } 85 func (ds) DeleteMulti([]*datastore.Key, datastore.DeleteMultiCB) error { panic(n i()) }
86 func (ds) NewQuery(string) datastore.Query { panic(n i()) }
dnj (Google) 2016/05/24 17:57:44 (This isn't an interface method, so isn't used. go
87 func (ds) DecodeCursor(string) (datastore.Cursor, error) { panic(n i()) } 86 func (ds) DecodeCursor(string) (datastore.Cursor, error) { panic(n i()) }
88 func (ds) Count(*datastore.FinalizedQuery) (int64, error) { panic(n i()) } 87 func (ds) Count(*datastore.FinalizedQuery) (int64, error) { panic(n i()) }
89 func (ds) Run(*datastore.FinalizedQuery, datastore.RawRunCB) error { panic(n i()) } 88 func (ds) Run(*datastore.FinalizedQuery, datastore.RawRunCB) error { panic(n i()) }
90 func (ds) RunInTransaction(func(context.Context) error, *datastore.TransactionOp tions) error { 89 func (ds) RunInTransaction(func(context.Context) error, *datastore.TransactionOp tions) error {
91 panic(ni()) 90 panic(ni())
92 } 91 }
93 func (ds) Testable() datastore.Testable { return nil } 92 func (ds) Testable() datastore.Testable { return nil }
94 93
95 var dummyDSInst = ds{} 94 var dummyDSInst = ds{}
96 95
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 func (mod) DefaultVersion(module string) (string, error) { panic( ni()) } 216 func (mod) DefaultVersion(module string) (string, error) { panic( ni()) }
218 func (mod) Start(module, version string) error { panic( ni()) } 217 func (mod) Start(module, version string) error { panic( ni()) }
219 func (mod) Stop(module, version string) error { panic( ni()) } 218 func (mod) Stop(module, version string) error { panic( ni()) }
220 219
221 var dummyModuleInst = mod{} 220 var dummyModuleInst = mod{}
222 221
223 // Module returns a dummy module.Interface implementation suitable for 222 // Module returns a dummy module.Interface implementation suitable for
224 // embedding. Every method panics with a message containing the name of the 223 // embedding. Every method panics with a message containing the name of the
225 // method which was unimplemented. 224 // method which was unimplemented.
226 func Module() module.Interface { return dummyModuleInst } 225 func Module() module.Interface { return dummyModuleInst }
OLDNEW
« no previous file with comments | « filter/txnBuf/txnbuf_test.go ('k') | impl/memory/datastore.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698