package
0.0.0-20240819013456-0d062cb8a7db
Repository: https://github.com/cosys-io/cosys.git
Documentation: pkg.go.dev

# Functions

Default specifies that an attribute has the given default value.
Enum specifies that an attribute is can only take the given values.
Max specifies that the attribute has the given maximum value.
MaxLength specifies that the attribute has the given maximum length.
Min specifies that the attribute has the given minimum value.
MinLength specifies that the attribute has the given minimum length.
NewAttrSchema returns a new AttributeSchema from the given names, types and configurations.
NewModelSchema returns a new ModelSchema from the given names, descriptions and attribute schemas.
ParseSchema parses json from a reader and scans it into a ModelSchema.
ToAttrSerializable returns a serializable attribute schema from the given schema.
ToModelSerializable returns a serializable model schema from the given schema.

# Variables

HideInTable specifies that the attribute is hidden in the table.
IdSchema is the schema for the id attribute.
NotEditable specifies that the attribute is not editable.
NotNullable specifies that an attribute is cannot be null.
Private specifies that the attribute is private.
Required specifies that the attribute is required.
Unique specifies that an attribute is unique.
UuidSchema is the schema for the uuid attribute.

# Structs

AttributeSchema is an implementation of the AttributeSchema common interface, with the added getter method for whether the attribute is shown in table.
AttrSerializable is used to serialize attribute schema into json.
ModelSchema is an implementation of the ModelSchema common interface, with added getter methods for display name and description.
ModelSerializable is used to serialize model schema into json.

# Type aliases

AttrOption is a configuration for an attribute schema.