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

Method GetParentFile

inventory/file.go:998–1005  ·  view source on GitHub ↗
(ctx context.Context, root *ent.File, eagerLoading bool)

Source from the content-addressed store, hash-verified

996}
997
998func (f *fileClient) GetParentFile(ctx context.Context, root *ent.File, eagerLoading bool) (*ent.File, error) {
999 query := f.client.File.QueryParent(root)
1000 if eagerLoading {
1001 query = withFileEagerLoading(ctx, query)
1002 }
1003
1004 return query.First(ctx)
1005}
1006
1007func (f *fileClient) QueryMetadata(ctx context.Context, root *ent.File) error {
1008 metadata, err := f.client.File.QueryMetadata(root).All(ctx)

Callers

nothing calls this directly

Calls 3

withFileEagerLoadingFunction · 0.85
QueryParentMethod · 0.45
FirstMethod · 0.45

Tested by

no test coverage detected