Documentation
¶
Index ¶
- Constants
- Variables
- func GetIdsFromRecordList(records []DomainObjectInterface) []string
- type AggregateDefinition
- func (a *AggregateDefinition) GetCommandByName(name string) *CustomRequest
- func (a *AggregateDefinition) GetCustomRequests() []*CustomRequest
- func (a *AggregateDefinition) GetEntities() []*OldEntityDefinition
- func (a *AggregateDefinition) GetEntityByName(name string) *OldEntityDefinition
- func (a *AggregateDefinition) GetTables() []TableInterface
- func (a *AggregateDefinition) GetValueObjectByName(name string) *ValueObjectDefinition
- type AggregateInterface
- type AggregateRootInterface
- type ArgsInterface
- type ArgumentDefinition
- func NewArgumentDefinition(argument libdomain.ArgumentDefinition, position int, positionLoaded int, ...) *ArgumentDefinition
- func NewEnumArgumentDefinition(argument libdomain.ArgumentDefinition, enumTitle string, ...) *ArgumentDefinition
- func NewTranslatableArgumentDefinition(argument libdomain.ArgumentDefinition, position int, positionLoaded int, ...) *ArgumentDefinition
- func (p *ArgumentDefinition) Definition() libdomain.ArgumentDefinition
- func (p *ArgumentDefinition) EnumDomainDefinition() *libdomain.EnumDefinition
- func (p *ArgumentDefinition) EnumTitle() string
- func (p *ArgumentDefinition) InInput() bool
- func (p *ArgumentDefinition) Options() *PropertyOptions
- func (p *ArgumentDefinition) Position() int
- func (p *ArgumentDefinition) PositionLoaded() int
- func (p *ArgumentDefinition) PositionTranslations() int
- func (p *ArgumentDefinition) PositionTranslationsLoaded() int
- type Collection
- type CustomRequest
- type DBType
- type Definitions
- type DomainObjectInterface
- type EntityCommandsDefinition
- type EntityQueriesDefinition
- type EnumDefinition
- type EnumValue
- type Event
- type EventDispatchClient
- type EventStoreClient
- type ExternalData
- type Factory
- type FactoryInterface
- type FilterInterface
- type JWTClaims
- type ListQueryInterface
- type Model
- type ModelInterface
- type ObjectDefinition
- type ObjectDefinitionInterface
- type OldEntityDefinition
- func (t *OldEntityDefinition) AggregateDefinition() *AggregateDefinition
- func (t *OldEntityDefinition) DomainPath() string
- func (t *OldEntityDefinition) GetAbstract() bool
- func (t *OldEntityDefinition) GetCommands() *EntityCommandsDefinition
- func (t *OldEntityDefinition) GetDisableDatabaseStore() bool
- func (t *OldEntityDefinition) GetDisableDatetime() bool
- func (t *OldEntityDefinition) GetDisableID() bool
- func (t *OldEntityDefinition) GetKeys() []Property
- func (t *OldEntityDefinition) GetName() string
- func (t *OldEntityDefinition) GetNoCache() bool
- func (t *OldEntityDefinition) GetType() string
- func (t *OldEntityDefinition) GetUseOneOf() bool
- func (t *OldEntityDefinition) HasTranslatable() bool
- func (t *OldEntityDefinition) IsAggregateRoot() bool
- func (t *OldEntityDefinition) IsEntity() bool
- func (t *OldEntityDefinition) NestedProperties() []Property
- func (t *OldEntityDefinition) Snake() string
- func (t *OldEntityDefinition) StoredProperties() []Property
- func (t *OldEntityDefinition) Title() string
- func (f *OldEntityDefinition) Upper() string
- func (t *OldEntityDefinition) UseTenants() bool
- type OnDeleteValue
- type Property
- type PropertyDefinition
- func NewEnumPropertyDefinition(property libdomain.PropertyDefinition, enumTitle string, ...) *PropertyDefinition
- func NewPropertyDefinition(property libdomain.PropertyDefinition, inInput bool, position int, ...) *PropertyDefinition
- func NewTranslatablePropertyDefinition(property libdomain.PropertyDefinition, inInput bool, position int, ...) *PropertyDefinition
- func (p *PropertyDefinition) Definition() libdomain.PropertyDefinition
- func (p *PropertyDefinition) EnumDomainDefinition() *libdomain.EnumDefinition
- func (p *PropertyDefinition) EnumTitle() string
- func (p *PropertyDefinition) InInput() bool
- func (p *PropertyDefinition) Options() *PropertyOptions
- func (p *PropertyDefinition) Position() int
- func (p *PropertyDefinition) PositionLoaded() int
- func (p *PropertyDefinition) PositionTranslations() int
- func (p *PropertyDefinition) PositionTranslationsLoaded() int
- type PropertyOptions
- type PropertyType
- type RepeatedProperty
- func (r *RepeatedProperty) DBType() *DBType
- func (r *RepeatedProperty) GetInverseProperty() string
- func (r *RepeatedProperty) GetLoadedPosition() int
- func (r *RepeatedProperty) GetLoadedPositionMany2one() int
- func (r *RepeatedProperty) GetName() string
- func (r *RepeatedProperty) GetPosition() int
- func (r *RepeatedProperty) GetPositionMany2one() int
- func (r *RepeatedProperty) GetPrimaryKey() bool
- func (r *RepeatedProperty) GetReference() TableInterface
- func (r *RepeatedProperty) GetReferenceName() string
- func (r *RepeatedProperty) GetRequired() bool
- func (r *RepeatedProperty) GetReturnDetailsInTests() bool
- func (r *RepeatedProperty) GoNil() string
- func (r *RepeatedProperty) GoType() string
- func (r *RepeatedProperty) GoTypeID() string
- func (r *RepeatedProperty) GraphqlSchemaType() string
- func (r *RepeatedProperty) GraphqlType() string
- func (r *RepeatedProperty) IsNested() bool
- func (r *RepeatedProperty) IsRepeated() bool
- func (r *RepeatedProperty) IsStored() bool
- func (r *RepeatedProperty) IsTranslatable() bool
- func (r *RepeatedProperty) JSONType() string
- func (r *RepeatedProperty) LoadedPosition() int
- func (r *RepeatedProperty) LoadedPositionMany2one() int
- func (r *RepeatedProperty) NameWithoutID() string
- func (r *RepeatedProperty) Position() int
- func (r *RepeatedProperty) PositionMany2one() int
- func (r *RepeatedProperty) ProtoType() string
- func (r *RepeatedProperty) ProtoTypeArg() string
- func (r *RepeatedProperty) ProtoTypeOptional() string
- func (r *RepeatedProperty) SetPosition(position int)
- func (r *RepeatedProperty) SetReference(e TableInterface)
- func (r *RepeatedProperty) Snake() string
- func (r *RepeatedProperty) Title() string
- func (r *RepeatedProperty) TitleWithoutID() string
- func (r *RepeatedProperty) Type() PropertyType
- func (r *RepeatedProperty) Upper() string
- type RepositoryInterface
- type RequestConfig
- type RequestDefinition
- type RequestDefinitionInterface
- type ServiceDefinition
- func (s *ServiceDefinition) Commands() []*RequestDefinition
- func (s *ServiceDefinition) Definition() *libapplication.ServiceDefinition
- func (s *ServiceDefinition) Enums() []*EnumDefinition
- func (s *ServiceDefinition) Objects() []*ObjectDefinition
- func (s *ServiceDefinition) Queries() []*RequestDefinition
- func (s *ServiceDefinition) RegisterCommand(r *RequestDefinition)
- func (s *ServiceDefinition) RegisterEnum(e *EnumDefinition)
- func (s *ServiceDefinition) RegisterObject(e *ObjectDefinition)
- func (s *ServiceDefinition) RegisterQuery(r *RequestDefinition)
- func (s *ServiceDefinition) Requests() []*RequestDefinition
- type TableInterface
- type ValueObjectDefinition
- func (t *ValueObjectDefinition) AggregateDefinition() *AggregateDefinition
- func (t *ValueObjectDefinition) DomainPath() string
- func (t *ValueObjectDefinition) GetAbstract() bool
- func (t *ValueObjectDefinition) GetCommands() *EntityCommandsDefinition
- func (t *ValueObjectDefinition) GetDisableDatabaseStore() bool
- func (t *ValueObjectDefinition) GetDisableDatetime() bool
- func (t *ValueObjectDefinition) GetDisableID() bool
- func (t *ValueObjectDefinition) GetKeys() []Property
- func (t *ValueObjectDefinition) GetName() string
- func (t *ValueObjectDefinition) GetNoCache() bool
- func (t *ValueObjectDefinition) GetType() string
- func (t *ValueObjectDefinition) GetUseOneOf() bool
- func (t *ValueObjectDefinition) HasTranslatable() bool
- func (t *ValueObjectDefinition) IsAggregateRoot() bool
- func (t *ValueObjectDefinition) IsEntity() bool
- func (t *ValueObjectDefinition) NestedProperties() []Property
- func (t *ValueObjectDefinition) Snake() string
- func (t *ValueObjectDefinition) StoredProperties() []Property
- func (t *ValueObjectDefinition) Title() string
- func (f *ValueObjectDefinition) Upper() string
- func (t *ValueObjectDefinition) UseTenants() bool
- type Workflow
- type WorkflowInterface
Constants ¶
const OnDeleteCascade = OnDeleteValue("CASCADE")
const OnDeleteProtect = OnDeleteValue("PROTECT")
const OnDeleteSetNull = OnDeleteValue("SET NULL")
const RepeatedPropertyType = PropertyType("RepeatedPropertyType")
const STRING = "string"
STRING is a contains reprensenting the widely used string type.
Variables ¶
var ExternalIDProperty = &basepb.BaseProperty{Snake: "external_id"}
var ExternalModuleProperty = &basepb.BaseProperty{Snake: "external_module"}
var IDProperty = &basepb.BaseProperty{Snake: "id"}
var SetAggregateIDProperty func(string) Property
var TenantIDProperty = &basepb.BaseProperty{Snake: "tenant_id"}
Functions ¶
func GetIdsFromRecordList ¶
func GetIdsFromRecordList(records []DomainObjectInterface) []string
GetIdsFromRecordList will return the id from a list of records.
Types ¶
type AggregateDefinition ¶
type AggregateDefinition struct { AggregateRoot *OldEntityDefinition Children []*OldEntityDefinition UseTenants bool ValueObjects []*ValueObjectDefinition Enums []*EnumDefinition Queries []*CustomRequest Commands []*CustomRequest EventStoreClient EventStoreClient EventDispatchClient EventDispatchClient ExternalData []*ExternalData // contains filtered or unexported fields }
Definition is used to declare the information of a model, so it can generate its code.
func (*AggregateDefinition) GetCommandByName ¶
func (a *AggregateDefinition) GetCommandByName(name string) *CustomRequest
func (*AggregateDefinition) GetCustomRequests ¶
func (a *AggregateDefinition) GetCustomRequests() []*CustomRequest
func (*AggregateDefinition) GetEntities ¶
func (a *AggregateDefinition) GetEntities() []*OldEntityDefinition
func (*AggregateDefinition) GetEntityByName ¶
func (a *AggregateDefinition) GetEntityByName(name string) *OldEntityDefinition
func (*AggregateDefinition) GetTables ¶
func (a *AggregateDefinition) GetTables() []TableInterface
func (*AggregateDefinition) GetValueObjectByName ¶
func (a *AggregateDefinition) GetValueObjectByName(name string) *ValueObjectDefinition
type AggregateInterface ¶
type AggregateInterface interface { Definition() *AggregateDefinition RepositoryInterface() RepositoryInterface // SetRepository(RepositoryInterface) AggregateRootInterface() AggregateRootInterface }
Definition is used to declare the information of a model, so it can generate its code.
type AggregateRootInterface ¶
type ArgsInterface ¶
type ArgsInterface interface { GetName() string Title() string ProtoType() string GoType() string GoNil() string GraphqlSchemaType() string GetReferenceName() string GetReference() TableInterface SetReference(e TableInterface) Type() PropertyType IsRepeated() bool }
type ArgumentDefinition ¶
type ArgumentDefinition struct {
// contains filtered or unexported fields
}
func NewArgumentDefinition ¶
func NewArgumentDefinition(argument libdomain.ArgumentDefinition, position int, positionLoaded int, options *PropertyOptions) *ArgumentDefinition
func NewEnumArgumentDefinition ¶
func NewEnumArgumentDefinition(argument libdomain.ArgumentDefinition, enumTitle string, enumDomainDefinition *libdomain.EnumDefinition, position int, positionLoaded int, options *PropertyOptions) *ArgumentDefinition
func NewTranslatableArgumentDefinition ¶
func NewTranslatableArgumentDefinition(argument libdomain.ArgumentDefinition, position int, positionLoaded int, positionTranslations int, positionTranslationsLoaded int, options *PropertyOptions) *ArgumentDefinition
func (*ArgumentDefinition) Definition ¶
func (p *ArgumentDefinition) Definition() libdomain.ArgumentDefinition
func (*ArgumentDefinition) EnumDomainDefinition ¶
func (p *ArgumentDefinition) EnumDomainDefinition() *libdomain.EnumDefinition
func (*ArgumentDefinition) EnumTitle ¶
func (p *ArgumentDefinition) EnumTitle() string
func (*ArgumentDefinition) InInput ¶
func (p *ArgumentDefinition) InInput() bool
func (*ArgumentDefinition) Options ¶
func (p *ArgumentDefinition) Options() *PropertyOptions
func (*ArgumentDefinition) Position ¶
func (p *ArgumentDefinition) Position() int
func (*ArgumentDefinition) PositionLoaded ¶
func (p *ArgumentDefinition) PositionLoaded() int
func (*ArgumentDefinition) PositionTranslations ¶
func (p *ArgumentDefinition) PositionTranslations() int
func (*ArgumentDefinition) PositionTranslationsLoaded ¶
func (p *ArgumentDefinition) PositionTranslationsLoaded() int
type Collection ¶
type Collection struct { Aggregate AggregateInterface Workflow context.Context Update func(interface{}) ([]DomainObjectInterface, error) Delete func() error // contains filtered or unexported fields }
Collection contains several objects of a same model.
func (*Collection) GetByID ¶
func (c *Collection) GetByID(id string) interface{}
GetByID will return the specified record in the collection, by ID.
func (*Collection) GetKeys ¶
func (c *Collection) GetKeys() []string
GetByID will return the specified record in the collection, by ID.
func (*Collection) Init ¶
func (c *Collection) Init(records []DomainObjectInterface)
Init will initialize the collection with the specified records.
func (*Collection) Slice ¶
func (c *Collection) Slice() []DomainObjectInterface
Slice will return the records in the collection, as a slice.
type CustomRequest ¶
type CustomRequest struct { Name string Event string OnFactory bool Repository bool Args []ArgsInterface Results []ArgsInterface // contains filtered or unexported fields }
func (*CustomRequest) IsCommand ¶
func (f *CustomRequest) IsCommand() bool
func (*CustomRequest) Title ¶
func (f *CustomRequest) Title() string
type Definitions ¶
type Definitions struct { Repository string // contains filtered or unexported fields }
func (*Definitions) GetByID ¶
func (ds *Definitions) GetByID(id string) *ServiceDefinition
GetByID return the specified definition by its ID.
func (*Definitions) Register ¶
func (ds *Definitions) Register(a *ServiceDefinition)
func (*Definitions) Slice ¶
func (ds *Definitions) Slice() []*ServiceDefinition
Slice return the definitions as a slice.
type DomainObjectInterface ¶
type DomainObjectInterface interface {
GetID() string
}
type EntityCommandsDefinition ¶
type EntityCommandsDefinition struct { Create *RequestConfig Update *RequestConfig Delete *RequestConfig CustomCommands []*CustomRequest }
type EntityQueriesDefinition ¶
type EntityQueriesDefinition struct { Get *RequestConfig List *RequestConfig GetFromEvents *RequestConfig CustomCommands []*CustomRequest }
type EnumDefinition ¶
func (*EnumDefinition) Title ¶
func (e *EnumDefinition) Title() string
type Event ¶
type Event struct { ID string Aggregate AggregateInterface AggregateID string Name string Payload map[string]interface{} }
type EventDispatchClient ¶
type EventStoreClient ¶
type EventStoreClient interface { RegisterEvents(WorkflowInterface, AggregateInterface, []*Event) error MarkDispatchedEvent(WorkflowInterface, *Event) error GetAggregateEvents(WorkflowInterface, AggregateInterface, string) ([]*Event, error) }
type ExternalData ¶
type ExternalData struct { Aggregate AggregateInterface TenantID string Module string Data []map[string]string }
type Factory ¶
type Factory struct { Aggregate AggregateInterface Workflow context.Context New func() DomainObjectInterface Scan func(interface{}, *Collection) ([]DomainObjectInterface, error) CheckExternalForeignKeys func([]DomainObjectInterface) error Select func( filters []FilterInterface, with []string, offset *uint, limit *uint, orderByArg *string, ) ([]DomainObjectInterface, error) Create func(records interface{}) ([]DomainObjectInterface, error) PostCreate func(records *Collection) error PostCreateSelectFilters func([]FilterInterface, []DomainObjectInterface) []FilterInterface Upsert func([]FilterInterface, interface{}, bool) (interface{}, bool, error) }
Pool represent a Model within the current environnement, so we can easily make operation on it.
type FactoryInterface ¶
type FactoryInterface interface { }
type FilterInterface ¶
type FilterInterface interface{}
type JWTClaims ¶
type JWTClaims struct { *jwt.StandardClaims TenantID string UserID string UserEmail string Groups []*basepb.GetByExternalIDQuery }
type ListQueryInterface ¶
type ListQueryInterface interface {
GetOptions() *basepb.OptionsListQuery
}
type ModelInterface ¶
type ModelInterface interface { // Select( // *WorkflowInterface, []*libdata.Filter, // []string, *uint, *string, *string, // ) (*Collection, error) // Create(*WorkflowInterface, []interface{}) (*Collection, error) // Delete( // *WorkflowInterface, []*libdata.Filter, []string, // ) (*Collection, error) // SetStore(interface{}) error // SetNew(func() interface{}) error GetID() string }
ModelInterface force to define the function relative to Model.
type ObjectDefinition ¶
type ObjectDefinition struct { Definition ObjectDefinitionInterface Properties []*PropertyDefinition }
type OldEntityDefinition ¶
type OldEntityDefinition struct { Aggregate AggregateInterface Name string Keys []Property Properties []Property DisableID bool DisableDatetime bool Queries *EntityQueriesDefinition Commands *EntityCommandsDefinition UseOneOf bool // useTenants bool DisableDatabaseStore bool SafeDelete bool Abstract bool NoCache bool // contains filtered or unexported fields }
func (*OldEntityDefinition) AggregateDefinition ¶
func (t *OldEntityDefinition) AggregateDefinition() *AggregateDefinition
func (*OldEntityDefinition) DomainPath ¶
func (t *OldEntityDefinition) DomainPath() string
func (*OldEntityDefinition) GetAbstract ¶
func (t *OldEntityDefinition) GetAbstract() bool
func (*OldEntityDefinition) GetCommands ¶
func (t *OldEntityDefinition) GetCommands() *EntityCommandsDefinition
func (*OldEntityDefinition) GetDisableDatabaseStore ¶
func (t *OldEntityDefinition) GetDisableDatabaseStore() bool
func (*OldEntityDefinition) GetDisableDatetime ¶
func (t *OldEntityDefinition) GetDisableDatetime() bool
func (*OldEntityDefinition) GetDisableID ¶
func (t *OldEntityDefinition) GetDisableID() bool
func (*OldEntityDefinition) GetKeys ¶
func (t *OldEntityDefinition) GetKeys() []Property
func (*OldEntityDefinition) GetName ¶
func (t *OldEntityDefinition) GetName() string
func (*OldEntityDefinition) GetNoCache ¶
func (t *OldEntityDefinition) GetNoCache() bool
func (*OldEntityDefinition) GetType ¶
func (t *OldEntityDefinition) GetType() string
func (*OldEntityDefinition) GetUseOneOf ¶
func (t *OldEntityDefinition) GetUseOneOf() bool
func (*OldEntityDefinition) HasTranslatable ¶
func (t *OldEntityDefinition) HasTranslatable() bool
func (*OldEntityDefinition) IsAggregateRoot ¶
func (t *OldEntityDefinition) IsAggregateRoot() bool
func (*OldEntityDefinition) IsEntity ¶
func (t *OldEntityDefinition) IsEntity() bool
func (*OldEntityDefinition) NestedProperties ¶
func (t *OldEntityDefinition) NestedProperties() []Property
func (*OldEntityDefinition) Snake ¶
func (t *OldEntityDefinition) Snake() string
func (*OldEntityDefinition) StoredProperties ¶
func (t *OldEntityDefinition) StoredProperties() []Property
func (t *EntityDefinition) setUseTenants(useTenants bool) { t.useTenants = useTenants }
func (*OldEntityDefinition) Title ¶
func (t *OldEntityDefinition) Title() string
func (*OldEntityDefinition) Upper ¶
func (f *OldEntityDefinition) Upper() string
func (*OldEntityDefinition) UseTenants ¶
func (t *OldEntityDefinition) UseTenants() bool
type OnDeleteValue ¶
type OnDeleteValue string
type Property ¶
type Property interface { GetName() string NameWithoutID() string Title() string TitleWithoutID() string Snake() string Upper() string Type() PropertyType GoType() string GoTypeID() string GoNil() string JSONType() string ProtoType() string ProtoTypeArg() string ProtoTypeOptional() string DBType() *DBType GraphqlType() string GraphqlSchemaType() string GetReferenceName() string GetReference() TableInterface // GetReferenceDefinition() *ModelDefinition SetReference(TableInterface) GetInverseProperty() string GetRequired() bool GetPrimaryKey() bool // GetFieldData() *FieldData IsStored() bool IsNested() bool SetPosition(int) GetPosition() int IsRepeated() bool IsTranslatable() bool GetReturnDetailsInTests() bool GetLoadedPosition() int GetLoadedPositionMany2one() int GetPositionMany2one() int }
Field is an interface to get the data from the field.
type PropertyDefinition ¶
type PropertyDefinition struct {
// contains filtered or unexported fields
}
func NewEnumPropertyDefinition ¶
func NewEnumPropertyDefinition(property libdomain.PropertyDefinition, enumTitle string, enumDomainDefinition *libdomain.EnumDefinition, inInput bool, position int, positionLoaded int, options *PropertyOptions) *PropertyDefinition
func NewPropertyDefinition ¶
func NewPropertyDefinition(property libdomain.PropertyDefinition, inInput bool, position int, positionLoaded int, options *PropertyOptions) *PropertyDefinition
func NewTranslatablePropertyDefinition ¶
func NewTranslatablePropertyDefinition(property libdomain.PropertyDefinition, inInput bool, position int, positionLoaded int, positionTranslations int, positionTranslationsLoaded int, options *PropertyOptions) *PropertyDefinition
func (*PropertyDefinition) Definition ¶
func (p *PropertyDefinition) Definition() libdomain.PropertyDefinition
func (*PropertyDefinition) EnumDomainDefinition ¶
func (p *PropertyDefinition) EnumDomainDefinition() *libdomain.EnumDefinition
func (*PropertyDefinition) EnumTitle ¶
func (p *PropertyDefinition) EnumTitle() string
func (*PropertyDefinition) InInput ¶
func (p *PropertyDefinition) InInput() bool
func (*PropertyDefinition) Options ¶
func (p *PropertyDefinition) Options() *PropertyOptions
func (*PropertyDefinition) Position ¶
func (p *PropertyDefinition) Position() int
func (*PropertyDefinition) PositionLoaded ¶
func (p *PropertyDefinition) PositionLoaded() int
func (*PropertyDefinition) PositionTranslations ¶
func (p *PropertyDefinition) PositionTranslations() int
func (*PropertyDefinition) PositionTranslationsLoaded ¶
func (p *PropertyDefinition) PositionTranslationsLoaded() int
type PropertyOptions ¶
type RepeatedProperty ¶
type RepeatedProperty struct {
Property Property
}
func (*RepeatedProperty) DBType ¶
func (r *RepeatedProperty) DBType() *DBType
func (*RepeatedProperty) GetInverseProperty ¶
func (r *RepeatedProperty) GetInverseProperty() string
func (*RepeatedProperty) GetLoadedPosition ¶
func (r *RepeatedProperty) GetLoadedPosition() int
func (*RepeatedProperty) GetLoadedPositionMany2one ¶
func (r *RepeatedProperty) GetLoadedPositionMany2one() int
func (*RepeatedProperty) GetName ¶
func (r *RepeatedProperty) GetName() string
func (*RepeatedProperty) GetPosition ¶
func (r *RepeatedProperty) GetPosition() int
func (*RepeatedProperty) GetPositionMany2one ¶
func (r *RepeatedProperty) GetPositionMany2one() int
func (*RepeatedProperty) GetPrimaryKey ¶
func (r *RepeatedProperty) GetPrimaryKey() bool
func (*RepeatedProperty) GetReference ¶
func (r *RepeatedProperty) GetReference() TableInterface
func (*RepeatedProperty) GetReferenceName ¶
func (r *RepeatedProperty) GetReferenceName() string
func (*RepeatedProperty) GetRequired ¶
func (r *RepeatedProperty) GetRequired() bool
func (*RepeatedProperty) GetReturnDetailsInTests ¶
func (r *RepeatedProperty) GetReturnDetailsInTests() bool
func (*RepeatedProperty) GoNil ¶
func (r *RepeatedProperty) GoNil() string
func (*RepeatedProperty) GoType ¶
func (r *RepeatedProperty) GoType() string
func (*RepeatedProperty) GoTypeID ¶
func (r *RepeatedProperty) GoTypeID() string
func (*RepeatedProperty) GraphqlSchemaType ¶
func (r *RepeatedProperty) GraphqlSchemaType() string
func (*RepeatedProperty) GraphqlType ¶
func (r *RepeatedProperty) GraphqlType() string
func (*RepeatedProperty) IsNested ¶
func (r *RepeatedProperty) IsNested() bool
func (*RepeatedProperty) IsRepeated ¶
func (r *RepeatedProperty) IsRepeated() bool
func (*RepeatedProperty) IsStored ¶
func (r *RepeatedProperty) IsStored() bool
func (*RepeatedProperty) IsTranslatable ¶
func (r *RepeatedProperty) IsTranslatable() bool
func (*RepeatedProperty) JSONType ¶
func (r *RepeatedProperty) JSONType() string
func (*RepeatedProperty) LoadedPosition ¶
func (r *RepeatedProperty) LoadedPosition() int
func (*RepeatedProperty) LoadedPositionMany2one ¶
func (r *RepeatedProperty) LoadedPositionMany2one() int
func (*RepeatedProperty) NameWithoutID ¶
func (r *RepeatedProperty) NameWithoutID() string
func (*RepeatedProperty) Position ¶
func (r *RepeatedProperty) Position() int
func (*RepeatedProperty) PositionMany2one ¶
func (r *RepeatedProperty) PositionMany2one() int
func (*RepeatedProperty) ProtoType ¶
func (r *RepeatedProperty) ProtoType() string
func (*RepeatedProperty) ProtoTypeArg ¶
func (r *RepeatedProperty) ProtoTypeArg() string
func (*RepeatedProperty) ProtoTypeOptional ¶
func (r *RepeatedProperty) ProtoTypeOptional() string
func (*RepeatedProperty) SetPosition ¶
func (r *RepeatedProperty) SetPosition(position int)
func (*RepeatedProperty) SetReference ¶
func (r *RepeatedProperty) SetReference(e TableInterface)
func (*RepeatedProperty) Snake ¶
func (r *RepeatedProperty) Snake() string
func (*RepeatedProperty) Title ¶
func (r *RepeatedProperty) Title() string
func (*RepeatedProperty) TitleWithoutID ¶
func (r *RepeatedProperty) TitleWithoutID() string
func (*RepeatedProperty) Type ¶
func (r *RepeatedProperty) Type() PropertyType
func (*RepeatedProperty) Upper ¶
func (r *RepeatedProperty) Upper() string
type RepositoryInterface ¶
type RepositoryInterface interface { // Insert(WorkflowInterface, interface{}) ([]DomainObjectInterface, error) // // Select(TableInterface, WorkflowInterface, *basepb.ListQuery) ([]DomainObjectInterface, error) // Update(*AggregateDefinition, WorkflowInterface, []FilterInterface, interface{}) ([]DomainObjectInterface, error) // Delete(*AggregateDefinition, WorkflowInterface, []FilterInterface) error GetCache(string) ([]byte, error) SetCache(string, []byte) error GetRecordCache(string, string) ([]byte, error) SetRecordCache(string, string, []byte) error InvalidateRecordCache(string, string) DefinitionInterface() interface{} }
type RequestConfig ¶
type RequestConfig struct {
Groups *[]*basepb.GetByExternalIDQuery
}
type RequestDefinition ¶
type RequestDefinition struct { Definition RequestDefinitionInterface Args []*ArgumentDefinition Results []*ArgumentDefinition ResultsQueries []*RequestDefinition }
func (*RequestDefinition) GetResults ¶
func (r *RequestDefinition) GetResults() []*ArgumentDefinition
type ServiceDefinition ¶
type ServiceDefinition struct {
// contains filtered or unexported fields
}
func NewServiceDefinition ¶
func NewServiceDefinition(definition *libapplication.ServiceDefinition) *ServiceDefinition
func (*ServiceDefinition) Commands ¶
func (s *ServiceDefinition) Commands() []*RequestDefinition
func (*ServiceDefinition) Definition ¶
func (s *ServiceDefinition) Definition() *libapplication.ServiceDefinition
func (*ServiceDefinition) Enums ¶
func (s *ServiceDefinition) Enums() []*EnumDefinition
func (*ServiceDefinition) Objects ¶
func (s *ServiceDefinition) Objects() []*ObjectDefinition
func (*ServiceDefinition) Queries ¶
func (s *ServiceDefinition) Queries() []*RequestDefinition
func (*ServiceDefinition) RegisterCommand ¶
func (s *ServiceDefinition) RegisterCommand(r *RequestDefinition)
func (*ServiceDefinition) RegisterEnum ¶
func (s *ServiceDefinition) RegisterEnum(e *EnumDefinition)
func (*ServiceDefinition) RegisterObject ¶
func (s *ServiceDefinition) RegisterObject(e *ObjectDefinition)
func (*ServiceDefinition) RegisterQuery ¶
func (s *ServiceDefinition) RegisterQuery(r *RequestDefinition)
func (*ServiceDefinition) Requests ¶
func (s *ServiceDefinition) Requests() []*RequestDefinition
type TableInterface ¶
type TableInterface interface { GetName() string Title() string Snake() string Upper() string GetType() string IsEntity() bool UseTenants() bool GetDisableID() bool GetDisableDatetime() bool GetDisableDatabaseStore() bool GetUseOneOf() bool StoredProperties() []Property NestedProperties() []Property GetCommands() *EntityCommandsDefinition GetKeys() []Property IsAggregateRoot() bool HasTranslatable() bool GetAbstract() bool GetNoCache() bool DomainPath() string }
type ValueObjectDefinition ¶
type ValueObjectDefinition struct { Aggregate AggregateInterface Name string Keys []Property Properties []Property Abstract bool // contains filtered or unexported fields }
func (*ValueObjectDefinition) AggregateDefinition ¶
func (t *ValueObjectDefinition) AggregateDefinition() *AggregateDefinition
func (*ValueObjectDefinition) DomainPath ¶
func (t *ValueObjectDefinition) DomainPath() string
func (*ValueObjectDefinition) GetAbstract ¶
func (t *ValueObjectDefinition) GetAbstract() bool
func (*ValueObjectDefinition) GetCommands ¶
func (t *ValueObjectDefinition) GetCommands() *EntityCommandsDefinition
func (*ValueObjectDefinition) GetDisableDatabaseStore ¶
func (t *ValueObjectDefinition) GetDisableDatabaseStore() bool
func (*ValueObjectDefinition) GetDisableDatetime ¶
func (t *ValueObjectDefinition) GetDisableDatetime() bool
func (*ValueObjectDefinition) GetDisableID ¶
func (t *ValueObjectDefinition) GetDisableID() bool
func (*ValueObjectDefinition) GetKeys ¶
func (t *ValueObjectDefinition) GetKeys() []Property
func (*ValueObjectDefinition) GetName ¶
func (t *ValueObjectDefinition) GetName() string
func (*ValueObjectDefinition) GetNoCache ¶
func (t *ValueObjectDefinition) GetNoCache() bool
func (*ValueObjectDefinition) GetType ¶
func (t *ValueObjectDefinition) GetType() string
func (*ValueObjectDefinition) GetUseOneOf ¶
func (t *ValueObjectDefinition) GetUseOneOf() bool
func (*ValueObjectDefinition) HasTranslatable ¶
func (t *ValueObjectDefinition) HasTranslatable() bool
func (*ValueObjectDefinition) IsAggregateRoot ¶
func (t *ValueObjectDefinition) IsAggregateRoot() bool
func (*ValueObjectDefinition) IsEntity ¶
func (t *ValueObjectDefinition) IsEntity() bool
func (*ValueObjectDefinition) NestedProperties ¶
func (t *ValueObjectDefinition) NestedProperties() []Property
func (*ValueObjectDefinition) Snake ¶
func (t *ValueObjectDefinition) Snake() string
func (*ValueObjectDefinition) StoredProperties ¶
func (t *ValueObjectDefinition) StoredProperties() []Property
func (*ValueObjectDefinition) Title ¶
func (t *ValueObjectDefinition) Title() string
func (*ValueObjectDefinition) Upper ¶
func (f *ValueObjectDefinition) Upper() string
func (*ValueObjectDefinition) UseTenants ¶
func (t *ValueObjectDefinition) UseTenants() bool