Documentation
¶
Overview ¶
Package models contains domain models for entities
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DbPropToModel ¶ added in v0.0.63
func DbPropToModel(dbProp db.Property) (*properties.Property, error)
DbPropToModel converts a single db.Property to a properties.Property instance.
func DbPropsToModel ¶ added in v0.0.63
func DbPropsToModel(dbProps []db.Property) (*properties.Properties, error)
DbPropsToModel converts a slice of db.Property to a properties.Properties instance.
Types ¶
type EntityInstance ¶
type EntityInstance struct {
ID uuid.UUID
Type minderv1.Entity
Name string
ProviderID uuid.UUID
ProjectID uuid.UUID
}
EntityInstance represents an entity instance
type EntityWithProperties ¶
type EntityWithProperties struct {
Entity EntityInstance
Properties *properties.Properties
}
EntityWithProperties represents an entity instance with properties
func NewEntityWithProperties ¶
func NewEntityWithProperties(dbEntity db.EntityInstance, props *properties.Properties) *EntityWithProperties
NewEntityWithProperties creates a new EntityWithProperties instance
func NewEntityWithPropertiesFromInstance ¶ added in v0.0.63
func NewEntityWithPropertiesFromInstance(entity EntityInstance, props *properties.Properties) *EntityWithProperties
NewEntityWithPropertiesFromInstance creates a new EntityWithProperties instance from an existing entity instance
func (*EntityWithProperties) UpdateProperties ¶ added in v0.0.63
func (e *EntityWithProperties) UpdateProperties(props *properties.Properties)
UpdateProperties updates the properties for the "entity for properties" instance
Click to show internal directories.
Click to hide internal directories.