config

package
v0.0.0-...-4f702ff Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 31, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const DBClusterDefaultSysname = "default"

Variables

This section is empty.

Functions

This section is empty.

Types

type Configuration

type Configuration struct {
	Infrastructure *Infrastructure
	Metadata       *Metadata
}

type DBCluster

type DBCluster struct {
	Capacity    uint
	EntityTypes []string
	Items       []minipkg_gorm.Config
}

type EntityType

type EntityType struct {
	Sysname    string
	Texts      map[string]NameAndDescriptionText
	Properties Properties
}

type EntityTypes

type EntityTypes []EntityType

type Infrastructure

type Infrastructure struct {
	Log           log.Config
	ReferenceDB   minipkg_gorm.Config
	DataSharding  Sharding
	SearchDB      minipkg_gorm.Config
	Redis         redis.Config
	CacheLifeTime uint
}

type Language

type Language struct {
	Code    string
	Name    string
	Cfgname string
}

type Languages

type Languages []Language

type Metadata

type Metadata struct {
	IsAutomigrate bool
	Languages     Languages
	PropertyUnits PropertyUnits
	EntityTypes   EntityTypes
	Relations     Relations
}

type NameAndDescriptionText

type NameAndDescriptionText struct {
	Name        string
	Description string
}

type Properties

type Properties []Property

type Property

type Property struct {
	Sysname          string
	PropertyType     string
	PropertyUnit     string
	PropertyViewType string
	PropertyGroup    string
	IsSpecific       bool
	IsRange          bool
	IsMultiple       bool
	SortOrder        uint
	Options          []map[string]interface{}
	Texts            map[string]NameAndDescriptionText
}

type PropertyUnit

type PropertyUnit struct {
	Sysname string
	Texts   map[string]NameAndDescriptionText
}

type PropertyUnits

type PropertyUnits []PropertyUnit

type Relation

type Relation struct {
	Sysname              string
	PropertyViewType     string
	PropertyGroup        string
	IsSpecific           bool
	IsMultiple           bool
	SortOrder            uint
	Options              []map[string]interface{}
	Texts                map[string]NameAndDescriptionText
	UndependedEntityType string
	DependedEntityType   string
}

type Relations

type Relations []Relation

type Sharding

type Sharding struct {
	IsAutoMigrate bool
	Default       DBCluster
	BySysnames    map[string]DBCluster
}

func (*Sharding) GetEntityTypesByClusterSysnames

func (s *Sharding) GetEntityTypesByClusterSysnames() map[string][]string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL