WithUser tells the query-builder to eager-load the nodes that are connected to the "user" edge. The optional arguments are used to configure the query builder of the edge.
(opts ...func(*UserQuery))
| 309 | // WithUser tells the query-builder to eager-load the nodes that are connected to |
| 310 | // the "user" edge. The optional arguments are used to configure the query builder of the edge. |
| 311 | func (sq *ShareQuery) WithUser(opts ...func(*UserQuery)) *ShareQuery { |
| 312 | query := (&UserClient{config: sq.config}).Query() |
| 313 | for _, opt := range opts { |
| 314 | opt(query) |
| 315 | } |
| 316 | sq.withUser = query |
| 317 | return sq |
| 318 | } |
| 319 | |
| 320 | // WithFile tells the query-builder to eager-load the nodes that are connected to |
| 321 | // the "file" edge. The optional arguments are used to configure the query builder of the edge. |