You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

lock.go 273 B

1234567891011121314151617
  1. package lock
  2. import (
  3. "code.gitea.io/gitea/models"
  4. )
  5. type LockContext struct {
  6. Repo *models.Repository
  7. Task *models.Cloudbrain
  8. User *models.User
  9. }
  10. type Lock interface {
  11. IsMatch(ctx *LockContext) bool
  12. Lock(ctx *LockContext) string
  13. Unlock(ctx *LockContext) error
  14. }