Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddNewEntityOption ¶
func AddNewEntityOption(entity Entity, params ...interface{})
AddNewEntityOption
Creates a new entity option and adds it to the given entityOptionList
Types ¶
type DoWithEntityFunc ¶
type DoWithEntityFunc func(Entity, ...interface{})
type Entity ¶
type Entity interface { EntityID() uint EntityDesc() string EntityOption() entitydto.EntityOption MustEmbed() []string }
Entity ...
type EntityFactory ¶
type EntityFactory interface { GetEntity(entityName string) (interface{}, error) GetEntitySlice(entityName string) (interface{}, error) DoWithAllEntities(entityList interface{}, entityFunc DoWithEntityFunc, params ...interface{}) }
type EntityOptionBuilder ¶
type EntityOptionBuilder interface {
BuildEntityOption() entitydto.EntityOption
}
EntityOptionBuilder struct that can build entity options
type GormEntity ¶ added in v0.1.6
func (GormEntity) EntityDesc ¶ added in v0.1.6
func (e GormEntity) EntityDesc() string
EntityDesc the description of the entity
func (GormEntity) EntityID ¶ added in v0.1.6
func (e GormEntity) EntityID() uint
EntityID the ID of the entity
func (GormEntity) EntityOption ¶ added in v0.1.6
func (e GormEntity) EntityOption() entitydto.EntityOption
EntityOption ...
func (*GormEntity) LoadRelatedEntities ¶ added in v0.1.6
func (e *GormEntity) LoadRelatedEntities(db *gorm.DB) error
LoadRelatedEntities implement this method in concrete entity
func (GormEntity) MustEmbed ¶ added in v0.1.6
func (e GormEntity) MustEmbed() []string
Click to show internal directories.
Click to hide internal directories.