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

Method Get

ent/client.go:1645–1647  ·  view source on GitHub ↗

Get returns a Node entity by its id.

(ctx context.Context, id int)

Source from the content-addressed store, hash-verified

1643
1644// Get returns a Node entity by its id.
1645func (c *NodeClient) Get(ctx context.Context, id int) (*Node, error) {
1646 return c.Query().Where(node.ID(id)).Only(ctx)
1647}
1648
1649// GetX is like Get, but panics if an error occurs.
1650func (c *NodeClient) GetX(ctx context.Context, id int) *Node {

Callers 1

GetXMethod · 0.95

Calls 4

QueryMethod · 0.95
IDFunction · 0.92
OnlyMethod · 0.45
WhereMethod · 0.45

Tested by

no test coverage detected