MCPcopy Index your code
hub / github.com/cloudreve/cloudreve / WithOwner

Method WithOwner

ent/file_query.go:459–466  ·  view source on GitHub ↗

WithOwner tells the query-builder to eager-load the nodes that are connected to the "owner" edge. The optional arguments are used to configure the query builder of the edge.

(opts ...func(*UserQuery))

Source from the content-addressed store, hash-verified

457// WithOwner tells the query-builder to eager-load the nodes that are connected to
458// the "owner" edge. The optional arguments are used to configure the query builder of the edge.
459func (fq *FileQuery) WithOwner(opts ...func(*UserQuery)) *FileQuery {
460 query := (&UserClient{config: fq.config}).Query()
461 for _, opt := range opts {
462 opt(query)
463 }
464 fq.withOwner = query
465 return fq
466}
467
468// WithStoragePolicies tells the query-builder to eager-load the nodes that are connected to
469// the "storage_policies" edge. The optional arguments are used to configure the query builder of the edge.

Callers 1

withFileEagerLoadingFunction · 0.45

Calls 1

QueryMethod · 0.45

Tested by

no test coverage detected