deleter

package
v0.21.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 9, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DisableDeleteIfBilled = true
)

Variables

View Source
var (
	ErrDeleteNotAllowed = fmt.Errorf("deletion not allowed for billed accounts")
)

Functions

This section is empty.

Types

type CustomerService added in v0.8.35

type CustomerService interface {
	Delete(ctx context.Context, id string) error
	List(ctx context.Context, filter customer.Filter) ([]customer.Customer, error)
}

type GroupService

type GroupService interface {
	List(ctx context.Context, flt group.Filter) ([]group.Group, error)
	Delete(ctx context.Context, id string) error
	RemoveUsers(ctx context.Context, groupID string, userIDs []string) error
}

type InvitationService

type InvitationService interface {
	List(ctx context.Context, flt invitation.Filter) ([]invitation.Invitation, error)
	Delete(ctx context.Context, id uuid.UUID) error
}

type InvoiceService added in v0.8.35

type InvoiceService interface {
	List(ctx context.Context, flt invoice.Filter) ([]invoice.Invoice, error)
	DeleteByCustomer(ctx context.Context, customr customer.Customer) error
}

type OrganizationService

type OrganizationService interface {
	Get(ctx context.Context, id string) (organization.Organization, error)
	DeleteModel(ctx context.Context, id string) error
	RemoveUsers(ctx context.Context, orgID string, userIDs []string) error
	ListByUser(ctx context.Context, userID string, f organization.Filter) ([]organization.Organization, error)
}

type PolicyService

type PolicyService interface {
	List(ctx context.Context, flt policy.Filter) ([]policy.Policy, error)
	Delete(ctx context.Context, id string) error
}

type ProjectService

type ProjectService interface {
	List(ctx context.Context, flt project.Filter) ([]project.Project, error)
	DeleteModel(ctx context.Context, id string) error
}

type ResourceService

type ResourceService interface {
	List(ctx context.Context, flt resource.Filter) ([]resource.Resource, error)
	Delete(ctx context.Context, namespaceID, id string) error
	Get(ctx context.Context, id string) (resource.Resource, error)
}

type RoleService

type RoleService interface {
	List(ctx context.Context, flt role.Filter) ([]role.Role, error)
	Delete(ctx context.Context, id string) error
}

type Service

type Service struct {
	// contains filtered or unexported fields
}

func NewCascadeDeleter

func NewCascadeDeleter(orgService OrganizationService, projService ProjectService,
	resService ResourceService, groupService GroupService,
	policyService PolicyService, roleService RoleService,
	invitationService InvitationService, userService UserService,
	customerService CustomerService, subService SubscriptionService,
	invoiceService InvoiceService) *Service

func (Service) DeleteCustomers added in v0.8.35

func (d Service) DeleteCustomers(ctx context.Context, id string) error

func (Service) DeleteOrganization

func (d Service) DeleteOrganization(ctx context.Context, id string) error

func (Service) DeleteProject

func (d Service) DeleteProject(ctx context.Context, id string) error

func (Service) DeleteUser added in v0.7.6

func (d Service) DeleteUser(ctx context.Context, userID string) error

func (Service) RemoveUsersFromOrg added in v0.7.5

func (d Service) RemoveUsersFromOrg(ctx context.Context, orgID string, userIDs []string) error

RemoveUsersFromOrg removes users from an organization as members

type SubscriptionService added in v0.8.35

type SubscriptionService interface {
	DeleteByCustomer(ctx context.Context, customr customer.Customer) error
}

type UserService added in v0.7.6

type UserService interface {
	Delete(ctx context.Context, id string) error
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL