entity

package
v0.4.1 Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Clone added in v0.3.0

func Clone(from interface{}, to interface{}) (err error)

func FieldNameToCode added in v0.3.0

func FieldNameToCode(name string) string

FieldNameToCode given a field name returns the coded attribute field name. Used to map a field name to its attribute in DMO, DTO and QRO objects.

func From added in v0.3.0

func From(from interface{}, entity interface{}) (err error)

func TRN

func TRN(name string, id string) *trn.TRN

TRN returns a TRN of entity kind

func To added in v0.3.0

func To(entity interface{}, to interface{}, field ...string) (err error)

Types

type FieldMap

type FieldMap map[string]string

func ToFieldMap added in v0.3.0

func ToFieldMap(ety interface{}, skip ...string) FieldMap

func (FieldMap) Add added in v0.3.0

func (fm FieldMap) Add(name string, kind string)

func (FieldMap) FieldType

func (fm FieldMap) FieldType(name string) (string, bool)

func (FieldMap) HasField

func (fm FieldMap) HasField(name string) bool

Jump to

Keyboard shortcuts

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