forked from tarantool/go-tarantool
-
Notifications
You must be signed in to change notification settings - Fork 0
/
connector.go
52 lines (45 loc) · 2.82 KB
/
connector.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
package tarantool
import "time"
type Connector interface {
ConnectedNow() bool
Close() error
Ping() (resp *Response, err error)
ConfiguredTimeout() time.Duration
Select(space, index interface{}, offset, limit, iterator uint32, key interface{}) (resp *Response, err error)
Insert(space interface{}, tuple interface{}) (resp *Response, err error)
Replace(space interface{}, tuple interface{}) (resp *Response, err error)
Delete(space, index interface{}, key interface{}) (resp *Response, err error)
Update(space, index interface{}, key, ops interface{}) (resp *Response, err error)
Upsert(space interface{}, tuple, ops interface{}) (resp *Response, err error)
Call(functionName string, args interface{}) (resp *Response, err error)
Call16(functionName string, args interface{}) (resp *Response, err error)
Call17(functionName string, args interface{}) (resp *Response, err error)
Eval(expr string, args interface{}) (resp *Response, err error)
Execute(expr string, args interface{}) (resp *Response, err error)
GetTyped(space, index interface{}, key interface{}, result interface{}) (err error)
SelectTyped(space, index interface{}, offset, limit, iterator uint32, key interface{}, result interface{}) (err error)
InsertTyped(space interface{}, tuple interface{}, result interface{}) (err error)
ReplaceTyped(space interface{}, tuple interface{}, result interface{}) (err error)
DeleteTyped(space, index interface{}, key interface{}, result interface{}) (err error)
UpdateTyped(space, index interface{}, key, ops interface{}, result interface{}) (err error)
CallTyped(functionName string, args interface{}, result interface{}) (err error)
Call16Typed(functionName string, args interface{}, result interface{}) (err error)
Call17Typed(functionName string, args interface{}, result interface{}) (err error)
EvalTyped(expr string, args interface{}, result interface{}) (err error)
ExecuteTyped(expr string, args interface{}, result interface{}) (SQLInfo, []ColumnMetaData, error)
SelectAsync(space, index interface{}, offset, limit, iterator uint32, key interface{}) *Future
InsertAsync(space interface{}, tuple interface{}) *Future
ReplaceAsync(space interface{}, tuple interface{}) *Future
DeleteAsync(space, index interface{}, key interface{}) *Future
UpdateAsync(space, index interface{}, key, ops interface{}) *Future
UpsertAsync(space interface{}, tuple interface{}, ops interface{}) *Future
CallAsync(functionName string, args interface{}) *Future
Call16Async(functionName string, args interface{}) *Future
Call17Async(functionName string, args interface{}) *Future
EvalAsync(expr string, args interface{}) *Future
ExecuteAsync(expr string, args interface{}) *Future
NewPrepared(expr string) (*Prepared, error)
NewStream() (*Stream, error)
NewWatcher(key string, callback WatchCallback) (Watcher, error)
Do(req Request) (fut *Future)
}