Versions in this module Expand all Collapse all v1 v1.1.0 Feb 21, 2025 Changes in this version + type ConcreteField struct + Readable bool + Writable bool + func (s *ConcreteField[Model]) IsReadable() bool + func (s *ConcreteField[Model]) IsWritable() bool + func (s *ConcreteField[Model]) Name() string + func (s *ConcreteField[Model]) ToInternalValue(reprModel map[string]any, ctx *gin.Context) (any, error) + func (s *ConcreteField[Model]) ToRepresentation(intVal models.InternalValue, ctx *gin.Context) (any, error) + func (s *ConcreteField[Model]) WithInternalValueFunc(f InternalValueFunc) Field + func (s *ConcreteField[Model]) WithReadOnly() Field + func (s *ConcreteField[Model]) WithReadWrite() Field + func (s *ConcreteField[Model]) WithRepresentationFunc(f RepresentationFunc) Field + func (s *ConcreteField[Model]) WithWriteOnly() Field type Field + IsReadable func() bool + IsWritable func() bool + WithReadOnly func() Field + WithReadWrite func() Field + WithWriteOnly func() Field v1.0.0 Mar 4, 2024 Changes in this version + func StaticValue[Model any](v any) func(oldField *Field[Model]) + type ErrorFieldIsNotPresentInPayload struct + func NewErrorFieldIsNotPresentInPayload(name string) ErrorFieldIsNotPresentInPayload + func (e ErrorFieldIsNotPresentInPayload) Error() string + type Field struct + Readable bool + Writable bool + func NewField[Model any](name string) *Field[Model] + func (s *Field[Model]) Name() string + func (s *Field[Model]) ReadOnly() *Field[Model] + func (s *Field[Model]) ReadWrite() *Field[Model] + func (s *Field[Model]) ToInternalValue(reprModel map[string]any, ctx *gin.Context) (any, error) + func (s *Field[Model]) ToRepresentation(intVal models.InternalValue, ctx *gin.Context) (any, error) + func (s *Field[Model]) WithInternalValueFunc(f InternalValueFunc) *Field[Model] + func (s *Field[Model]) WithRepresentationFunc(f RepresentationFunc) *Field[Model] + func (s *Field[Model]) WriteOnly() *Field[Model] + type GRFParsable interface + FromRepresentation func(any) error + type GRFRepresentable interface + ToRepresentation func() (any, error) + type InternalValueFunc func(map[string]any, string, *gin.Context) (any, error) + type RepresentationFunc func(models.InternalValue, string, *gin.Context) (any, error)