Documentation ¶
Index ¶
- func ConvertEntTypeToGotype(prop string) string
- func ConvertEntTypeToGotypeInSingleApi(prop string) string
- func ConvertEntTypeToProtoType(typeName string) string
- func ConvertIDType(useUUID bool) string
- func ConvertOnlyEntTypeToGoType(t string) string
- func ConvertProtoTypeToGoType(typeName string) string
- func ConvertSpecificNounToUpper(str string) string
- func IsBaseProperty(prop string) bool
- func IsGoTypeNotPrototype(prop string) bool
- func IsOnlyEntType(t string) bool
- func IsPageProperty(prop string) bool
- func IsTimeProperty(prop string) bool
- func IsUUIDType(prop string) bool
- func IsUpperProperty(prop string) bool
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConvertEntTypeToGotype ¶
ConvertEntTypeToGotype returns go type from ent type
func ConvertEntTypeToGotypeInSingleApi ¶
ConvertEntTypeToGotypeInSingleApi returns go type from ent type in single API service
func ConvertEntTypeToProtoType ¶
ConvertEntTypeToProtoType returns prototype from ent type
func ConvertIDType ¶
ConvertIDType returns uuid type by uuid flag
func ConvertOnlyEntTypeToGoType ¶
ConvertOnlyEntTypeToGoType converts the type that only ent has to go type.
func ConvertProtoTypeToGoType ¶
ConvertProtoTypeToGoType returns go type from proto type
func ConvertSpecificNounToUpper ¶
ConvertSpecificNounToUpper is used to convert snack format to Ent format
func IsBaseProperty ¶
IsBaseProperty returns true when prop name is id, created_at, updated_at, deleted_at
func IsGoTypeNotPrototype ¶
IsGoTypeNotPrototype returns true when property type is prototype but not go type
func IsOnlyEntType ¶
IsOnlyEntType returns true when the type is only in ent schema. e.g. uint8
func IsPageProperty ¶ added in v1.6.23
IsPageProperty returns true when prop name is pageNo, pageSize
func IsTimeProperty ¶
IsTimeProperty returns true when the string contains time suffix
func IsUUIDType ¶
IsUUIDType returns true when prop is Ent's UUID type
func IsUpperProperty ¶
IsUpperProperty returns true when the string contains Ent upper string such as uuid, api and id
Types ¶
This section is empty.