Documentation ¶
Index ¶
- type EntityAttrDescrNote
- type EntityDescrNote
- type EntityGroupDescrNote
- type GroupDescrNote
- type ModelMetaEncoder
- type ModelMetaUnpack
- type ParamDescrNote
- type ParamDimsDescrNote
- type TableAccDescrNote
- type TableDescrNote
- type TableDimsDescrNote
- type TableExprDescrNote
- type TypeDescrNote
- type TypeMetaUnpack
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EntityAttrDescrNote ¶
type EntityAttrDescrNote struct { Attr *db.EntityAttrRow // entity attribute row: entity_attr join to model_entity_dic table DescrNote aDescrNote // from entity_attr_txt }
EntityAttrDescrNote is join of entity_attr, model_entity_dic, entity_attr_txt
type EntityDescrNote ¶
type EntityDescrNote struct { Entity *db.EntityDicRow // entity row: entity_dic join to model_entity_dic DescrNote aDescrNote // from entity_dic_txt EntityAttrTxt []EntityAttrDescrNote // entity attribute text rows: entity_attr, model_entity_dic, entity_attr_txt }
EntityDescrNote is join of entity_dic, model_entity_dic, entity_dic_txt, entity_attr_txt
type EntityGroupDescrNote ¶
type EntityGroupDescrNote struct { Group *db.EntityGroupMeta // parameters or output tables group rows: entity_group_lst join to entity_group_pc DescrNote aDescrNote // from entity_group_txt }
EntityGroupDescrNote is join of entity_group_lst, entity_group_pc and entity_group_txt
type GroupDescrNote ¶
type GroupDescrNote struct { Group *db.GroupMeta // parameters or output tables group rows: group_lst join to group_pc DescrNote aDescrNote // from group_txt }
GroupDescrNote is join of group_lst, group_pc and group_txt
type ModelMetaEncoder ¶
type ModelMetaEncoder struct { MetaDescrNote modelMetaDescrNote // model metadata, including description and notes // contains filtered or unexported fields }
model metadata encoder into json.
model metadata db rows with language-specific description and notes. It is sliced by one single language, but it can be different single language for each row. It is either user preferred language, model default language, first of the row or empty "" language.
func (*ModelMetaEncoder) DoEncode ¶
func (me *ModelMetaEncoder) DoEncode(isPack bool, je *json.Encoder) error
encode model metadata into json. If isPack is true then range types are packed. if isIndent is true then json output indented.
func (*ModelMetaEncoder) IsInit ¶
func (me *ModelMetaEncoder) IsInit() bool
retrun true if ModelMetaEncoder initialized
func (*ModelMetaEncoder) New ¶
func (me *ModelMetaEncoder) New(meta *db.ModelMeta, txtMeta *db.ModelTxtMeta, lc string, lcd string) error
return language-specific model metadata by model digest or name language. It can be `lc` prefered language or `lcd` default model language or empty if no model text db rows exist.
type ModelMetaUnpack ¶
type ModelMetaUnpack struct { Model *db.ModelDicRow // model_dic table row Type []TypeMetaUnpack // types metadata: type name and enums Param []db.ParamMeta // parameters metadata: parameter name, type, dimensions Table []db.TableMeta // output tables metadata: table name, dimensions, accumulators, expressions Entity []db.EntityMeta // model entities and attributes Group []db.GroupMeta // groups of parameters or output tables EntityGroup []db.EntityGroupMeta // groups of entity attributes }
copy of ModelMeta, using alias for TypeMeta to do a special range type marshaling
func CopyModelMetaToUnpack ¶
func CopyModelMetaToUnpack(meta *db.ModelMeta) *ModelMetaUnpack
type ParamDescrNote ¶
type ParamDescrNote struct { Param *db.ParamDicRow // parameter row: parameter_dic join to model_parameter_dic table DescrNote aDescrNote // from parameter_dic_txt ParamDimsTxt []ParamDimsDescrNote // parameter dimension text rows: parameter_dims_txt join to model_parameter_dic }
ParamDescrNote is join of parameter_dic, model_parameter_dic, parameter_dic_txt, parameter_dims_txt
type ParamDimsDescrNote ¶
type ParamDimsDescrNote struct { Dim *db.ParamDimsRow // parameter dimension row: parameter_dims join to model_parameter_dic table DescrNote aDescrNote // from parameter_dims_txt }
ParamDimsDescrNote is join of parameter_dims, model_parameter_dic, parameter_dims_txt
type TableAccDescrNote ¶
type TableAccDescrNote struct { Acc *db.TableAccRow // output table accumulator row: table_acc join to model_table_dic DescrNote aDescrNote // from table_acc_txt }
TableAccDescrNote is join of table_acc, model_table_dic, table_acc_txt
type TableDescrNote ¶
type TableDescrNote struct { Table *db.TableDicRow // output table row: table_dic join to model_table_dic LangCode *string // table_dic_txt.lang_code TableDescr *string // table_dic_txt.descr TableNote *string // table_dic_txt.note ExprDescr *string // table_dic_txt.expr_descr ExprNote *string // table_dic_txt.expr_note TableDimsTxt []TableDimsDescrNote // output table dimension text rows: table_dims_txt join to model_table_dic TableAccTxt []TableAccDescrNote // output table accumulator text rows: table_acc_txt join to model_table_dic TableExprTxt []TableExprDescrNote // output table expression text rows: table_expr_txt join to model_table_dic }
TableDescrNote is join of table_dic, model_table_dic, table_dic_txt, table_dims_txt, table_acc_txt, table_expr_txt
type TableDimsDescrNote ¶
type TableDimsDescrNote struct { Dim *db.TableDimsRow // parameter dimension row: table_dims join to model_table_dic table DescrNote aDescrNote // from table_dims_txt }
TableDimsDescrNote is join of table_dims, model_table_dic, table_dims_txt
type TableExprDescrNote ¶
type TableExprDescrNote struct { Expr *db.TableExprRow // output table expression row: table_expr join to model_table_dic DescrNote aDescrNote // from table_expr_txt }
TableExprDescrNote is join of table_expr, model_table_dic, table_expr_txt
type TypeDescrNote ¶
type TypeDescrNote struct { Type *db.TypeDicRow // model type row: type_dic join to model_type_dic DescrNote aDescrNote // from type_dic_txt TypeEnumTxt []typeEnumDescrNote // type enum text rows: type_enum_txt join to model_type_dic }
TypeDescrNote is join of type_dic_txt, model_type_dic, type_dic_txt
type TypeMetaUnpack ¶
type TypeMetaUnpack struct { TypeDicRow *db.TypeDicRow // model type rows: type_dic join to model_type_dic Enum []db.TypeEnumRow // type enum rows: type_enum_lst join to model_type_dic }
model type metadata, "unpacked" during marshaled to json (range enums restored)
func (*TypeMetaUnpack) MarshalJSON ¶
func (src *TypeMetaUnpack) MarshalJSON() ([]byte, error)
marshal type row and type enums[] to json, "unpack" range enums which may be not loaded from database
Directories ¶
Path | Synopsis |
---|---|
Package config to merge run options: command line arguments and ini-file content.
|
Package config to merge run options: command line arguments and ini-file content. |
Package db to support openM++ model database operations.
|
Package db to support openM++ model database operations. |
Package helper is a set common helper functions
|
Package helper is a set common helper functions |
Package omppLog to println messages to standard output and log file.
|
Package omppLog to println messages to standard output and log file. |