package repository import ( "context" "github.com/ocdp/cluster-service/internal/domain/entity" ) // ChartReferenceRepository Chart 引用仓储接口 type ChartReferenceRepository interface { // Create 创建 Chart 引用 Create(ctx context.Context, chartRef *entity.ChartReference) error // GetByID 根据 ID 获取 Chart 引用 GetByID(ctx context.Context, id string) (*entity.ChartReference, error) // GetByWorkspace 获取 workspace 的所有 Chart 引用 GetByWorkspace(ctx context.Context, workspaceID string) ([]*entity.ChartReference, error) // GetByRegistry 获取 registry 的所有 Chart 引用 GetByRegistry(ctx context.Context, registryID string) ([]*entity.ChartReference, error) // GetByName 根据名称获取 Chart 引用 GetByName(ctx context.Context, workspaceID, chartName string) (*entity.ChartReference, error) // Update 更新 Chart 引用 Update(ctx context.Context, chartRef *entity.ChartReference) error // Delete 删除 Chart 引用 Delete(ctx context.Context, id string) error // List 列出所有 Chart 引用(管理员用) List(ctx context.Context) ([]*entity.ChartReference, error) }