newLockMutation creates new mutation for the Lock entity.
(c config, op Op, opts ...lockOption)
| 8384 | |
| 8385 | // newLockMutation creates new mutation for the Lock entity. |
| 8386 | func newLockMutation(c config, op Op, opts ...lockOption) *LockMutation { |
| 8387 | m := &LockMutation{ |
| 8388 | config: c, |
| 8389 | op: op, |
| 8390 | typ: TypeLock, |
| 8391 | clearedFields: make(map[string]struct{}), |
| 8392 | } |
| 8393 | for _, opt := range opts { |
| 8394 | opt(m) |
| 8395 | } |
| 8396 | return m |
| 8397 | } |
| 8398 | |
| 8399 | // withLockID sets the ID field of the mutation. |
| 8400 | func withLockID(id int) lockOption { |
no outgoing calls
no test coverage detected
searching dependent graphs…