Documentation
¶
Overview ¶
Package genmodels contains all entities and must also have a struct which implements entitymodel.EntityFactory.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EntityFactoryImpl ¶
type EntityFactoryImpl struct{}
func NewEntityFactoryImpl ¶ added in v0.1.7
func NewEntityFactoryImpl() EntityFactoryImpl
func (EntityFactoryImpl) DoWithAllEntities ¶ added in v0.1.7
func (ef EntityFactoryImpl) DoWithAllEntities(entityList interface{}, entityFunc entitymodel.DoWithEntityFunc, params ...interface{})
DoWithAllEntities
Method ranges over entities and calls entityFunc with each entity. You can serve parameters with each call to entityFunc.
Attention! Maybe params should be pointers to change things outside entityFunc.
func (EntityFactoryImpl) GetEntity ¶ added in v0.1.7
func (ef EntityFactoryImpl) GetEntity(entityName string) (interface{}, error)
GetEntity return entity struct by name
func (EntityFactoryImpl) GetEntitySlice ¶ added in v0.1.7
func (ef EntityFactoryImpl) GetEntitySlice(entityName string) (interface{}, error)
GetEntitySlice return slice of entity struct by name
type EntityType ¶
type EntityType int
EntityType type of entity
const ( EntityTypeUndefined EntityType = iota EntityTypeAccount EntityTypeContact EntityTypeContactAddress EntityTypeMaxi EntityTypeUser )
func (EntityType) EntityName ¶ added in v0.1.6
func (et EntityType) EntityName() string
EntityName the value used in html template
Click to show internal directories.
Click to hide internal directories.