Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewRepository ¶
func NewRepository(conv EntityConverter) *pgRepository
NewRepository missing godoc
func NewService ¶
func NewService(pkgRepo PackageRepository, uidService UIDService) *service
NewService missing godoc
Types ¶
type Entity ¶
type Entity struct { ID string `db:"id"` ApplicationID sql.NullString `db:"app_id"` ApplicationTemplateVersionID sql.NullString `db:"app_template_version_id"` OrdID string `db:"ord_id"` Vendor sql.NullString `db:"vendor"` Title string `db:"title"` ShortDescription string `db:"short_description"` Description string `db:"description"` Version string `db:"version"` PackageLinks sql.NullString `db:"package_links"` Links sql.NullString `db:"links"` LicenseType sql.NullString `db:"licence_type"` SupportInfo sql.NullString `db:"support_info"` RuntimeRestriction sql.NullString `db:"runtime_restriction"` Tags sql.NullString `db:"tags"` Countries sql.NullString `db:"countries"` Labels sql.NullString `db:"labels"` PolicyLevel sql.NullString `db:"policy_level"` CustomPolicyLevel sql.NullString `db:"custom_policy_level"` PartOfProducts sql.NullString `db:"part_of_products"` LineOfBusiness sql.NullString `db:"line_of_business"` Industry sql.NullString `db:"industry"` ResourceHash sql.NullString `db:"resource_hash"` DocumentationLabels sql.NullString `db:"documentation_labels"` }
Entity represents the ORD package entity.
func (*Entity) DecorateWithTenantID ¶
DecorateWithTenantID decorates the entity with the given tenant ID.
type EntityConverter ¶
type EntityConverter interface { ToEntity(in *model.Package) *Entity FromEntity(entity *Entity) (*model.Package, error) }
EntityConverter missing godoc
type PackageRepository ¶
type PackageRepository interface { Create(ctx context.Context, tenant string, item *model.Package) error CreateGlobal(ctx context.Context, model *model.Package) error Update(ctx context.Context, tenant string, item *model.Package) error UpdateGlobal(ctx context.Context, model *model.Package) error Delete(ctx context.Context, tenant, id string) error DeleteGlobal(ctx context.Context, id string) error Exists(ctx context.Context, tenant, id string) (bool, error) GetByID(ctx context.Context, tenant, id string) (*model.Package, error) GetByIDGlobal(ctx context.Context, id string) (*model.Package, error) ListByResourceID(ctx context.Context, tenantID, resourceID string, resourceType resource.Type) ([]*model.Package, error) }
PackageRepository missing godoc
Click to show internal directories.
Click to hide internal directories.