(ctx context.Context)
| 481 | _u.mutation.ClearSonames() |
| 482 | return _u |
| 483 | } |
| 484 | |
| 485 | // SetBuildDuration sets the "build_duration" field. |
| 486 | func (_u *DBPackageUpdate) SetBuildDuration(v int64) *DBPackageUpdate { |
| 487 | _u.mutation.ResetBuildDuration() |
| 488 | _u.mutation.SetBuildDuration(v) |
| 489 | return _u |
| 490 | } |
| 491 | |
| 492 | // SetNillableBuildDuration sets the "build_duration" field if the given value is not nil. |
| 493 | func (_u *DBPackageUpdate) SetNillableBuildDuration(v *int64) *DBPackageUpdate { |
| 494 | if v != nil { |
| 495 | _u.SetBuildDuration(*v) |
| 496 | } |
| 497 | return _u |
| 498 | } |
| 499 | |
| 500 | // AddBuildDuration adds value to the "build_duration" field. |
| 501 | func (_u *DBPackageUpdate) AddBuildDuration(v int64) *DBPackageUpdate { |
| 502 | _u.mutation.AddBuildDuration(v) |
| 503 | return _u |
| 504 | } |
| 505 | |
| 506 | // ClearBuildDuration clears the value of the "build_duration" field. |
| 507 | func (_u *DBPackageUpdate) ClearBuildDuration() *DBPackageUpdate { |
| 508 | _u.mutation.ClearBuildDuration() |
| 509 | return _u |
| 510 | } |
| 511 | |
| 512 | // Mutation returns the DBPackageMutation object of the builder. |
| 513 | func (_u *DBPackageUpdate) Mutation() *DBPackageMutation { |
| 514 | return _u.mutation |
| 515 | } |
| 516 | |
| 517 | // Save executes the query and returns the number of nodes affected by the update operation. |
| 518 | func (_u *DBPackageUpdate) Save(ctx context.Context) (int, error) { |
| 519 | return withHooks(ctx, _u.sqlSave, _u.mutation, _u.hooks) |
| 520 | } |
| 521 | |
| 522 | // SaveX is like Save, but panics if an error occurs. |
| 523 | func (_u *DBPackageUpdate) SaveX(ctx context.Context) int { |
| 524 | affected, err := _u.Save(ctx) |
| 525 | if err != nil { |
| 526 | panic(err) |
| 527 | } |
| 528 | return affected |
| 529 | } |
| 530 | |
| 531 | // Exec executes the query. |
| 532 | func (_u *DBPackageUpdate) Exec(ctx context.Context) error { |
| 533 | _, err := _u.Save(ctx) |
| 534 | return err |
| 535 | } |
| 536 | |
| 537 | // ExecX is like Exec, but panics if an error occurs. |
| 538 | func (_u *DBPackageUpdate) ExecX(ctx context.Context) { |
| 539 | if err := _u.Exec(ctx); err != nil { |
| 540 | panic(err) |
nothing calls this directly
no test coverage detected