MCPcopy Create free account
hub / github.com/efectn/go-orm-benchmarks / Limit

Method Limit

bench/ent/model_query.go:36–39  ·  view source on GitHub ↗

Limit the number of records to be returned by this query.

(limit int)

Source from the content-addressed store, hash-verified

34
35// Limit the number of records to be returned by this query.
36func (mq *ModelQuery) Limit(limit int) *ModelQuery {
37 mq.ctx.Limit = &limit
38 return mq
39}
40
41// Offset to start from.
42func (mq *ModelQuery) Offset(offset int) *ModelQuery {

Callers 15

FirstMethod · 0.95
FirstIDMethod · 0.95
OnlyMethod · 0.95
OnlyIDMethod · 0.95
ReadSliceMethod · 0.80
ReadSliceMethod · 0.80
ReadSliceMethod · 0.80
ReadSliceMethod · 0.80
ReadSliceMethod · 0.80
ReadSliceMethod · 0.80
ReadSliceMethod · 0.80
ReadSliceMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected