Documentation ¶
Index ¶
- func BuildModel(openapi *openapi3.T) map[string]RestType
- func FirstCharToLower(input string) string
- func FirstCharToUpper(input string) string
- func NewRestClassType(realSuperClass RestType, superClass RestType, name string, ...) *restClassType
- func RecurseCutOff(restType RestType) string
- func StripLowercasePrefix(name string) string
- type RestProperty
- func (p *RestProperty) DS() *RestProperty
- func (p *RestProperty) GoName() string
- func (p *RestProperty) IsDTypeRequired() bool
- func (p *RestProperty) IsNotComputed() bool
- func (p *RestProperty) IsRequired() bool
- func (p *RestProperty) TFAttrType(inAdditionalObjects bool) string
- func (p *RestProperty) TFName() string
- func (p *RestProperty) TFToTKH() string
- func (p *RestProperty) TFType() string
- func (p *RestProperty) TKHSetter() string
- func (p *RestProperty) TKHToTF() string
- type RestPropertyType
- func NewAdditionalType(names []string) RestPropertyType
- func NewEnumPropertyType(enumType RestType, rsSchemaTemplateBase map[string]any) RestPropertyType
- func NewFindBaseByUUIDObjectType(baseType *restFindByUUIDClassType) RestPropertyType
- func NewFindByUUIDObjectType(nestedType RestPropertyType, rsSchemaTemplateBase map[string]any) RestPropertyType
- func NewFindParentByUUIDObjectType() RestPropertyType
- func NewNestedObjectType(property *RestProperty, nestedType RestType, ...) RestPropertyType
- func NewPolymorphicSubtype(property *RestProperty, superType RestType, nestedType RestType) RestPropertyType
- func NewRestArrayType(itemType RestPropertyType, setCollection bool, ...) RestPropertyType
- func NewRestMapType(name string, itemType RestPropertyType, rsSchemaTemplateBase map[string]any) RestPropertyType
- func NewRestSimpleType(property *RestProperty, schema *openapi3.Schema, ...) RestPropertyType
- type RestType
- func NewRestEnumType(name string, values []any) RestType
- func NewRestFindByUUIDClassType(superClass RestType, name string, nestedType *restClassType) RestType
- func NewRestPolymorphicBaseClassType(nestedType RestType) RestType
- func NewRestSubresourceClassType(name string, prefix string, nestedType RestType) RestType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FirstCharToLower ¶
func FirstCharToUpper ¶
func NewRestClassType ¶
func RecurseCutOff ¶
func StripLowercasePrefix ¶
Types ¶
type RestProperty ¶
type RestProperty struct { Parent RestType Name string Type RestPropertyType Required bool WriteOnly bool Deprecated bool // contains filtered or unexported fields }
func AdditionalObjectsProperties ¶
func AdditionalObjectsProperties(restType RestType) []*RestProperty
func AllDirectProperties ¶
func AllDirectProperties(restType RestType) []*RestProperty
func IdentifyingProperties ¶ added in v1.0.12
func IdentifyingProperties(restType RestType) []*RestProperty
func (*RestProperty) DS ¶
func (p *RestProperty) DS() *RestProperty
func (*RestProperty) GoName ¶
func (p *RestProperty) GoName() string
func (*RestProperty) IsDTypeRequired ¶
func (p *RestProperty) IsDTypeRequired() bool
func (*RestProperty) IsNotComputed ¶ added in v1.0.12
func (p *RestProperty) IsNotComputed() bool
func (*RestProperty) IsRequired ¶ added in v1.0.12
func (p *RestProperty) IsRequired() bool
func (*RestProperty) TFAttrType ¶
func (p *RestProperty) TFAttrType(inAdditionalObjects bool) string
func (*RestProperty) TFName ¶
func (p *RestProperty) TFName() string
func (*RestProperty) TFToTKH ¶
func (p *RestProperty) TFToTKH() string
func (*RestProperty) TFType ¶
func (p *RestProperty) TFType() string
func (*RestProperty) TKHSetter ¶
func (p *RestProperty) TKHSetter() string
func (*RestProperty) TKHToTF ¶
func (p *RestProperty) TKHToTF() string
type RestPropertyType ¶
type RestPropertyType interface { MarkReachable() PropertyNameSuffix() string FlattenMode() string OrderMode() string TFName() string TFValueType() string TFAttrType(inAdditionalObjects bool) string TFValidatorType() string TFValidators() []string ToTFAttrWithDiag() bool ToTKHAttrWithDiag() bool ToTKHCustomCode() string TFAttrNeeded() bool Complex() bool RequiresReplace() bool NestedType() RestType TKHToTF(value string, listItem bool) string TFToTKH(value string, listItem bool) string TKHToTFGuard() string TFToTKHGuard() string TKHGetter(propertyName string) string SDKTypeName(listItem bool) string SDKTypeConstructor() string DSSchemaTemplate() string DSSchemaTemplateData() map[string]any RSSchemaTemplate() string RSSchemaTemplateData() map[string]any DS() RestPropertyType }
func NewAdditionalType ¶
func NewAdditionalType(names []string) RestPropertyType
func NewEnumPropertyType ¶
func NewEnumPropertyType(enumType RestType, rsSchemaTemplateBase map[string]any) RestPropertyType
func NewFindBaseByUUIDObjectType ¶
func NewFindBaseByUUIDObjectType(baseType *restFindByUUIDClassType) RestPropertyType
func NewFindByUUIDObjectType ¶
func NewFindByUUIDObjectType(nestedType RestPropertyType, rsSchemaTemplateBase map[string]any) RestPropertyType
func NewFindParentByUUIDObjectType ¶
func NewFindParentByUUIDObjectType() RestPropertyType
func NewNestedObjectType ¶
func NewNestedObjectType(property *RestProperty, nestedType RestType, rsSchemaTemplateBase map[string]any) RestPropertyType
func NewPolymorphicSubtype ¶
func NewPolymorphicSubtype(property *RestProperty, superType RestType, nestedType RestType) RestPropertyType
func NewRestArrayType ¶
func NewRestArrayType(itemType RestPropertyType, setCollection bool, rsSchemaTemplateBase map[string]any) RestPropertyType
func NewRestMapType ¶
func NewRestMapType(name string, itemType RestPropertyType, rsSchemaTemplateBase map[string]any) RestPropertyType
func NewRestSimpleType ¶
func NewRestSimpleType(property *RestProperty, schema *openapi3.Schema, rsSchemaTemplateBase map[string]any) RestPropertyType
type RestType ¶
type RestType interface { Reachable() bool MarkReachable() Extends(typeName string) bool IsObject() bool ObjectAttrTypesName() string DataStructName() string APITypeName() string APIDiscriminator() string GoTypeName() string SDKTypeName() string SDKTypeConstructor() string AllProperties() []*RestProperty HasDirectUUIDProperty() bool Suffix() string DS() RestType }
func NewRestEnumType ¶
Source Files ¶
- modelbuilder.go
- property.go
- property_type_additional.go
- property_type_array.go
- property_type_enumproperty.go
- property_type_findbasebyuuid.go
- property_type_findbyuuid.go
- property_type_findparentbyuuid.go
- property_type_map.go
- property_type_nestedobject.go
- property_type_polymorphic_subtype.go
- property_type_simple.go
- rest_type.go
- rest_type_class.go
- rest_type_enum.go
- rest_type_findbyuuid.go
- rest_type_polymorphic_base.go
- rest_type_subresource.go
Click to show internal directories.
Click to hide internal directories.