forked from ravendb/ravendb-go-client
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathraw_document_query.go
91 lines (72 loc) · 2.13 KB
/
raw_document_query.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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
package ravendb
import (
"time"
)
// Note: Java's IRawDocumentQuery is RawDocumentQuery
type RawDocumentQuery struct {
*abstractDocumentQuery
}
func (q *RawDocumentQuery) Skip(count int) *RawDocumentQuery {
q.skip(count)
return q
}
func (q *RawDocumentQuery) Take(count int) *RawDocumentQuery {
q.take(count)
return q
}
func (q *RawDocumentQuery) WaitForNonStaleResults() *RawDocumentQuery {
q.waitForNonStaleResults(0)
return q
}
func (q *RawDocumentQuery) WaitForNonStaleResultsWithTimeout(waitTimeout time.Duration) *RawDocumentQuery {
q.waitForNonStaleResults(waitTimeout)
return q
}
//TBD 4.1 RawDocumentQuery<T> showTimings() {
func (q *RawDocumentQuery) NoTracking() *RawDocumentQuery {
q.noTracking()
return q
}
func (q *RawDocumentQuery) NoCaching() *RawDocumentQuery {
q.noCaching()
return q
}
func (q *RawDocumentQuery) UsingDefaultOperator(queryOperator QueryOperator) *RawDocumentQuery {
if q.err != nil {
return q
}
q.err = q.usingDefaultOperator(queryOperator)
return q
}
func (q *RawDocumentQuery) Statistics(stats **QueryStatistics) *RawDocumentQuery {
q.statistics(stats)
return q
}
func (q *RawDocumentQuery) RemoveAfterQueryExecutedListener(idx int) *RawDocumentQuery {
q.removeAfterQueryExecutedListener(idx)
return q
}
func (q *RawDocumentQuery) AddAfterQueryExecutedListener(action func(*QueryResult)) int {
return q.addAfterQueryExecutedListener(action)
}
func (q *RawDocumentQuery) AddBeforeQueryExecutedListener(action func(*IndexQuery)) int {
return q.addBeforeQueryExecutedListener(action)
}
func (q *RawDocumentQuery) RemoveBeforeQueryExecutedListener(idx int) *RawDocumentQuery {
q.removeBeforeQueryExecutedListener(idx)
return q
}
func (q *RawDocumentQuery) AddAfterStreamExecutedListener(action func(map[string]interface{})) int {
return q.addAfterStreamExecutedListener(action)
}
func (q *RawDocumentQuery) RemoveAfterStreamExecutedListener(idx int) *RawDocumentQuery {
q.removeAfterStreamExecutedListener(idx)
return q
}
func (q *RawDocumentQuery) AddParameter(name string, value interface{}) *RawDocumentQuery {
if q.err != nil {
return q
}
q.err = q.addParameter(name, value)
return q
}