Query calls f(ctx, q).
(ctx context.Context, q ent.Query)
| 277 | |
| 278 | // Query calls f(ctx, q). |
| 279 | func (f NodeFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error) { |
| 280 | if q, ok := q.(*ent.NodeQuery); ok { |
| 281 | return f(ctx, q) |
| 282 | } |
| 283 | return nil, fmt.Errorf("unexpected query type %T. expect *ent.NodeQuery", q) |
| 284 | } |
| 285 | |
| 286 | // The TraverseNode type is an adapter to allow the use of ordinary function as Traverser. |
| 287 | type TraverseNode func(context.Context, *ent.NodeQuery) error |
nothing calls this directly
no outgoing calls
no test coverage detected