v1

package
v1.48.7-circular Latest Latest
Warning

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

Go to latest
Published: Jun 30, 2025 License: MPL-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Builtin_name = map[int32]string{
		0:  "ANY",
		1:  "BOOL",
		2:  "INT8",
		3:  "INT16",
		4:  "INT32",
		5:  "INT64",
		6:  "UINT8",
		7:  "UINT16",
		8:  "UINT32",
		9:  "UINT64",
		10: "FLOAT32",
		11: "FLOAT64",
		12: "STRING",
		13: "BYTES",
		14: "TIME",
		15: "UUID",
		16: "JSON",
		17: "USER_ID",
		18: "INT",
		19: "UINT",
	}
	Builtin_value = map[string]int32{
		"ANY":     0,
		"BOOL":    1,
		"INT8":    2,
		"INT16":   3,
		"INT32":   4,
		"INT64":   5,
		"UINT8":   6,
		"UINT16":  7,
		"UINT32":  8,
		"UINT64":  9,
		"FLOAT32": 10,
		"FLOAT64": 11,
		"STRING":  12,
		"BYTES":   13,
		"TIME":    14,
		"UUID":    15,
		"JSON":    16,
		"USER_ID": 17,
		"INT":     18,
		"UINT":    19,
	}
)

Enum value maps for Builtin.

View Source
var (
	ValidationRule_Is_name = map[int32]string{
		0: "UNKNOWN",
		1: "EMAIL",
		2: "URL",
	}
	ValidationRule_Is_value = map[string]int32{
		"UNKNOWN": 0,
		"EMAIL":   1,
		"URL":     2,
	}
)

Enum value maps for ValidationRule_Is.

View Source
var File_encore_parser_schema_v1_schema_proto protoreflect.FileDescriptor

Functions

func Walk

func Walk(decls []*Decl, node any, visitor func(node any) error) error

Walk will perform a depth first walk of all schema nodes starting at node, calling visitor for each schema type found.

If visitor returns false, the walk will be aborted.

Types

type Builtin

type Builtin int32

Builtin represents a type which Encore (and Go) have inbuilt support for and so can be represented by Encore's tooling directly, rather than needing to understand the full implementation details of how the type is structured.

const (
	// Inbuilt Go Types
	Builtin_ANY     Builtin = 0
	Builtin_BOOL    Builtin = 1
	Builtin_INT8    Builtin = 2
	Builtin_INT16   Builtin = 3
	Builtin_INT32   Builtin = 4
	Builtin_INT64   Builtin = 5
	Builtin_UINT8   Builtin = 6
	Builtin_UINT16  Builtin = 7
	Builtin_UINT32  Builtin = 8
	Builtin_UINT64  Builtin = 9
	Builtin_FLOAT32 Builtin = 10
	Builtin_FLOAT64 Builtin = 11
	Builtin_STRING  Builtin = 12
	Builtin_BYTES   Builtin = 13
	// Additional Encore Types
	Builtin_TIME    Builtin = 14
	Builtin_UUID    Builtin = 15
	Builtin_JSON    Builtin = 16
	Builtin_USER_ID Builtin = 17
	Builtin_INT     Builtin = 18
	Builtin_UINT    Builtin = 19
)

func (Builtin) Descriptor

func (Builtin) Descriptor() protoreflect.EnumDescriptor

func (Builtin) Enum

func (x Builtin) Enum() *Builtin

func (Builtin) EnumDescriptor deprecated

func (Builtin) EnumDescriptor() ([]byte, []int)

Deprecated: Use Builtin.Descriptor instead.

func (Builtin) Number

func (x Builtin) Number() protoreflect.EnumNumber

func (Builtin) String

func (x Builtin) String() string

func (Builtin) Type

func (Builtin) Type() protoreflect.EnumType

type ConfigValue

type ConfigValue struct {
	Elem         *Type `protobuf:"bytes,1,opt,name=elem,proto3" json:"elem,omitempty"`                  // The type of the config value
	IsValuesList bool  `protobuf:"varint,2,opt,name=IsValuesList,proto3" json:"IsValuesList,omitempty"` // Does this config value represent the type to `config.Values[T]`. If false it represents `config.Value[T]`
	// contains filtered or unexported fields
}

ConfigValue represents a config value wrapper.

func (*ConfigValue) Descriptor deprecated

func (*ConfigValue) Descriptor() ([]byte, []int)

Deprecated: Use ConfigValue.ProtoReflect.Descriptor instead.

func (*ConfigValue) GetElem

func (x *ConfigValue) GetElem() *Type

func (*ConfigValue) GetIsValuesList

func (x *ConfigValue) GetIsValuesList() bool

func (*ConfigValue) ProtoMessage

func (*ConfigValue) ProtoMessage()

func (*ConfigValue) ProtoReflect

func (x *ConfigValue) ProtoReflect() protoreflect.Message

func (*ConfigValue) Reset

func (x *ConfigValue) Reset()

func (*ConfigValue) String

func (x *ConfigValue) String() string

type Decl

type Decl struct {
	Id         uint32           `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`                                  // A internal ID which we can refer to this declaration by
	Name       string           `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`                               // The name of the type as assigned in the code
	Type       *Type            `protobuf:"bytes,3,opt,name=type,proto3" json:"type,omitempty"`                               // The underlying type of this declaration
	TypeParams []*TypeParameter `protobuf:"bytes,6,rep,name=type_params,json=typeParams,proto3" json:"type_params,omitempty"` // Any type parameters on this declaration (note; instantiated types used within this declaration would not be captured here)
	Doc        string           `protobuf:"bytes,4,opt,name=doc,proto3" json:"doc,omitempty"`                                 // The comment block on the type
	Loc        *Loc             `protobuf:"bytes,5,opt,name=loc,proto3" json:"loc,omitempty"`                                 // The location of the declaration within the project
	// contains filtered or unexported fields
}

Decl represents the declaration of a type within the Go code which is either concrete or _parameterized_. The type is concrete when there are zero type parameters assigned.

For example the Go Code: ```go // Set[A] represents our set type type Set[A any] = map[A]struct{} ```

Would become: ```go

_ = &Decl{
    id: 1,
    name: "Set",
    type: &Type{
        typ_map: &Map{
            key: &Type { typ_type_parameter: ... reference to "A" type parameter below ... },
            value: &Type { typ_struct: ... empty struct type ... },
        },
    },
    typeParameters: []*TypeParameter{ { name: "A" } },
    doc: "Set[A] represents our set type",
    loc: &Loc { ... },
}

```

func (*Decl) Descriptor deprecated

func (*Decl) Descriptor() ([]byte, []int)

Deprecated: Use Decl.ProtoReflect.Descriptor instead.

func (*Decl) GetDoc

func (x *Decl) GetDoc() string

func (*Decl) GetId

func (x *Decl) GetId() uint32

func (*Decl) GetLoc

func (x *Decl) GetLoc() *Loc

func (*Decl) GetName

func (x *Decl) GetName() string

func (*Decl) GetType

func (x *Decl) GetType() *Type

func (*Decl) GetTypeParams

func (x *Decl) GetTypeParams() []*TypeParameter

func (*Decl) ProtoMessage

func (*Decl) ProtoMessage()

func (*Decl) ProtoReflect

func (x *Decl) ProtoReflect() protoreflect.Message

func (*Decl) Reset

func (x *Decl) Reset()

func (*Decl) String

func (x *Decl) String() string

type Field

type Field struct {
	Typ             *Type     `protobuf:"bytes,1,opt,name=typ,proto3" json:"typ,omitempty"`                                                  // The type of the field
	Name            string    `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`                                                // The name of the field
	Doc             string    `protobuf:"bytes,3,opt,name=doc,proto3" json:"doc,omitempty"`                                                  // The comment for the field
	JsonName        string    `protobuf:"bytes,4,opt,name=json_name,json=jsonName,proto3" json:"json_name,omitempty"`                        // The optional json name if it's different from the field name. (The value "-" indicates to omit the field.)
	Optional        bool      `protobuf:"varint,5,opt,name=optional,proto3" json:"optional,omitempty"`                                       // Whether the field is optional.
	QueryStringName string    `protobuf:"bytes,6,opt,name=query_string_name,json=queryStringName,proto3" json:"query_string_name,omitempty"` // The query string name to use in GET/HEAD/DELETE requests. (The value "-" indicates to omit the field.)
	RawTag          string    `protobuf:"bytes,7,opt,name=raw_tag,json=rawTag,proto3" json:"raw_tag,omitempty"`                              // The original Go struct tag; should not be parsed individually
	Tags            []*Tag    `protobuf:"bytes,8,rep,name=tags,proto3" json:"tags,omitempty"`                                                // Parsed go struct tags. Used for marshalling hints
	Wire            *WireSpec `protobuf:"bytes,9,opt,name=wire,proto3,oneof" json:"wire,omitempty"`                                          // The explicitly set wire location of the field.
	// contains filtered or unexported fields
}

Field represents a field within a struct

func (*Field) Descriptor deprecated

func (*Field) Descriptor() ([]byte, []int)

Deprecated: Use Field.ProtoReflect.Descriptor instead.

func (*Field) GetDoc

func (x *Field) GetDoc() string

func (*Field) GetJsonName

func (x *Field) GetJsonName() string

func (*Field) GetName

func (x *Field) GetName() string

func (*Field) GetOptional

func (x *Field) GetOptional() bool

func (*Field) GetQueryStringName

func (x *Field) GetQueryStringName() string

func (*Field) GetRawTag

func (x *Field) GetRawTag() string

func (*Field) GetTags

func (x *Field) GetTags() []*Tag

func (*Field) GetTyp

func (x *Field) GetTyp() *Type

func (*Field) GetWire

func (x *Field) GetWire() *WireSpec

func (*Field) ProtoMessage

func (*Field) ProtoMessage()

func (*Field) ProtoReflect

func (x *Field) ProtoReflect() protoreflect.Message

func (*Field) Reset

func (x *Field) Reset()

func (*Field) String

func (x *Field) String() string

type List

type List struct {
	Elem *Type `protobuf:"bytes,1,opt,name=elem,proto3" json:"elem,omitempty"` // The type of the elements in the list
	// contains filtered or unexported fields
}

List represents a list type (array or slice)

func (*List) Descriptor deprecated

func (*List) Descriptor() ([]byte, []int)

Deprecated: Use List.ProtoReflect.Descriptor instead.

func (*List) GetElem

func (x *List) GetElem() *Type

func (*List) ProtoMessage

func (*List) ProtoMessage()

func (*List) ProtoReflect

func (x *List) ProtoReflect() protoreflect.Message

func (*List) Reset

func (x *List) Reset()

func (*List) String

func (x *List) String() string

type Literal

type Literal struct {

	// Types that are assignable to Value:
	//
	//	*Literal_Str
	//	*Literal_Boolean
	//	*Literal_Int
	//	*Literal_Float
	//	*Literal_Null
	Value isLiteral_Value `protobuf_oneof:"value"`
	// contains filtered or unexported fields
}

Literal represents a literal value.

func (*Literal) Descriptor deprecated

func (*Literal) Descriptor() ([]byte, []int)

Deprecated: Use Literal.ProtoReflect.Descriptor instead.

func (*Literal) GetBoolean

func (x *Literal) GetBoolean() bool

func (*Literal) GetFloat

func (x *Literal) GetFloat() float64

func (*Literal) GetInt

func (x *Literal) GetInt() int64

func (*Literal) GetNull

func (x *Literal) GetNull() bool

func (*Literal) GetStr

func (x *Literal) GetStr() string

func (*Literal) GetValue

func (m *Literal) GetValue() isLiteral_Value

func (*Literal) ProtoMessage

func (*Literal) ProtoMessage()

func (*Literal) ProtoReflect

func (x *Literal) ProtoReflect() protoreflect.Message

func (*Literal) Reset

func (x *Literal) Reset()

func (*Literal) String

func (x *Literal) String() string

type Literal_Boolean

type Literal_Boolean struct {
	Boolean bool `protobuf:"varint,2,opt,name=boolean,proto3,oneof"`
}

type Literal_Float

type Literal_Float struct {
	Float float64 `protobuf:"fixed64,4,opt,name=float,proto3,oneof"`
}

type Literal_Int

type Literal_Int struct {
	Int int64 `protobuf:"varint,3,opt,name=int,proto3,oneof"`
}

type Literal_Null

type Literal_Null struct {
	Null bool `protobuf:"varint,5,opt,name=null,proto3,oneof"`
}

type Literal_Str

type Literal_Str struct {
	Str string `protobuf:"bytes,1,opt,name=str,proto3,oneof"`
}

type Loc

type Loc struct {
	PkgPath      string `protobuf:"bytes,1,opt,name=pkg_path,json=pkgPath,proto3" json:"pkg_path,omitempty"`                   // The package path within the repo (i.e. `users/signup`)
	PkgName      string `protobuf:"bytes,2,opt,name=pkg_name,json=pkgName,proto3" json:"pkg_name,omitempty"`                   // The package name (i.e. `signup`)
	Filename     string `protobuf:"bytes,3,opt,name=filename,proto3" json:"filename,omitempty"`                                // The file name (i.e. `signup.go`)
	StartPos     int32  `protobuf:"varint,4,opt,name=start_pos,json=startPos,proto3" json:"start_pos,omitempty"`               // The starting index within the file for this node
	EndPos       int32  `protobuf:"varint,5,opt,name=end_pos,json=endPos,proto3" json:"end_pos,omitempty"`                     // The ending index within the file for this node
	SrcLineStart int32  `protobuf:"varint,6,opt,name=src_line_start,json=srcLineStart,proto3" json:"src_line_start,omitempty"` // The starting line within the file for this node
	SrcLineEnd   int32  `protobuf:"varint,7,opt,name=src_line_end,json=srcLineEnd,proto3" json:"src_line_end,omitempty"`       // The ending line within the file for this node
	SrcColStart  int32  `protobuf:"varint,8,opt,name=src_col_start,json=srcColStart,proto3" json:"src_col_start,omitempty"`    // The starting column on the starting line for this node
	SrcColEnd    int32  `protobuf:"varint,9,opt,name=src_col_end,json=srcColEnd,proto3" json:"src_col_end,omitempty"`          // The ending column on the ending line for this node
	// contains filtered or unexported fields
}

Loc is the location of a declaration within the code base

func (*Loc) Descriptor deprecated

func (*Loc) Descriptor() ([]byte, []int)

Deprecated: Use Loc.ProtoReflect.Descriptor instead.

func (*Loc) GetEndPos

func (x *Loc) GetEndPos() int32

func (*Loc) GetFilename

func (x *Loc) GetFilename() string

func (*Loc) GetPkgName

func (x *Loc) GetPkgName() string

func (*Loc) GetPkgPath

func (x *Loc) GetPkgPath() string

func (*Loc) GetSrcColEnd

func (x *Loc) GetSrcColEnd() int32

func (*Loc) GetSrcColStart

func (x *Loc) GetSrcColStart() int32

func (*Loc) GetSrcLineEnd

func (x *Loc) GetSrcLineEnd() int32

func (*Loc) GetSrcLineStart

func (x *Loc) GetSrcLineStart() int32

func (*Loc) GetStartPos

func (x *Loc) GetStartPos() int32

func (*Loc) ProtoMessage

func (*Loc) ProtoMessage()

func (*Loc) ProtoReflect

func (x *Loc) ProtoReflect() protoreflect.Message

func (*Loc) Reset

func (x *Loc) Reset()

func (*Loc) String

func (x *Loc) String() string

type Map

type Map struct {
	Key   *Type `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`     // The type of the key for this map
	Value *Type `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` // The type of the value of this map
	// contains filtered or unexported fields
}

Map represents a map Type

func (*Map) Descriptor deprecated

func (*Map) Descriptor() ([]byte, []int)

Deprecated: Use Map.ProtoReflect.Descriptor instead.

func (*Map) GetKey

func (x *Map) GetKey() *Type

func (*Map) GetValue

func (x *Map) GetValue() *Type

func (*Map) ProtoMessage

func (*Map) ProtoMessage()

func (*Map) ProtoReflect

func (x *Map) ProtoReflect() protoreflect.Message

func (*Map) Reset

func (x *Map) Reset()

func (*Map) String

func (x *Map) String() string

type Named

type Named struct {
	Id            uint32  `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`                                           // The `Decl.id` this name refers to
	TypeArguments []*Type `protobuf:"bytes,2,rep,name=type_arguments,json=typeArguments,proto3" json:"type_arguments,omitempty"` // The type arguments used to instantiate this parameterised declaration
	// contains filtered or unexported fields
}

Named references declaration block by name

func (*Named) Descriptor deprecated

func (*Named) Descriptor() ([]byte, []int)

Deprecated: Use Named.ProtoReflect.Descriptor instead.

func (*Named) GetId

func (x *Named) GetId() uint32

func (*Named) GetTypeArguments

func (x *Named) GetTypeArguments() []*Type

func (*Named) ProtoMessage

func (*Named) ProtoMessage()

func (*Named) ProtoReflect

func (x *Named) ProtoReflect() protoreflect.Message

func (*Named) Reset

func (x *Named) Reset()

func (*Named) String

func (x *Named) String() string

type Pointer

type Pointer struct {
	Base *Type `protobuf:"bytes,1,opt,name=base,proto3" json:"base,omitempty"` // The type of the pointer
	// contains filtered or unexported fields
}

Pointer represents a pointer to a base type

func (*Pointer) Descriptor deprecated

func (*Pointer) Descriptor() ([]byte, []int)

Deprecated: Use Pointer.ProtoReflect.Descriptor instead.

func (*Pointer) GetBase

func (x *Pointer) GetBase() *Type

func (*Pointer) ProtoMessage

func (*Pointer) ProtoMessage()

func (*Pointer) ProtoReflect

func (x *Pointer) ProtoReflect() protoreflect.Message

func (*Pointer) Reset

func (x *Pointer) Reset()

func (*Pointer) String

func (x *Pointer) String() string

type Struct

type Struct struct {
	Fields []*Field `protobuf:"bytes,1,rep,name=fields,proto3" json:"fields,omitempty"`
	// contains filtered or unexported fields
}

Struct contains a list of fields which make up the struct

func (*Struct) Descriptor deprecated

func (*Struct) Descriptor() ([]byte, []int)

Deprecated: Use Struct.ProtoReflect.Descriptor instead.

func (*Struct) GetFields

func (x *Struct) GetFields() []*Field

func (*Struct) ProtoMessage

func (*Struct) ProtoMessage()

func (*Struct) ProtoReflect

func (x *Struct) ProtoReflect() protoreflect.Message

func (*Struct) Reset

func (x *Struct) Reset()

func (*Struct) String

func (x *Struct) String() string

type Tag

type Tag struct {
	Key     string   `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`         // The tag key (e.g. json, query, header ...)
	Name    string   `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`       // The tag name (e.g. first_name, firstName, ...)
	Options []string `protobuf:"bytes,3,rep,name=options,proto3" json:"options,omitempty"` // Key Options (e.g. omitempty, optional ...)
	// contains filtered or unexported fields
}

func (*Tag) Descriptor deprecated

func (*Tag) Descriptor() ([]byte, []int)

Deprecated: Use Tag.ProtoReflect.Descriptor instead.

func (*Tag) GetKey

func (x *Tag) GetKey() string

func (*Tag) GetName

func (x *Tag) GetName() string

func (*Tag) GetOptions

func (x *Tag) GetOptions() []string

func (*Tag) ProtoMessage

func (*Tag) ProtoMessage()

func (*Tag) ProtoReflect

func (x *Tag) ProtoReflect() protoreflect.Message

func (*Tag) Reset

func (x *Tag) Reset()

func (*Tag) String

func (x *Tag) String() string

type Type

type Type struct {

	// Types that are assignable to Typ:
	//
	//	*Type_Named
	//	*Type_Struct
	//	*Type_Map
	//	*Type_List
	//	*Type_Builtin
	//	*Type_Pointer
	//	*Type_Union
	//	*Type_Literal
	//	*Type_TypeParameter
	//	*Type_Config
	Typ        isType_Typ      `protobuf_oneof:"typ"`
	Validation *ValidationExpr `protobuf:"bytes,15,opt,name=validation,proto3,oneof" json:"validation,omitempty"` // The validation expression for this type
	// contains filtered or unexported fields
}

Type represents the base of our schema on which everything else is built on-top of. It has to be one, and only one, thing from our list of meta types.

A type may be concrete or abstract, however to determine if a type is abstract you need to recursive through the structures looking for any uses of the TypeParameterPtr type

func (*Type) Descriptor deprecated

func (*Type) Descriptor() ([]byte, []int)

Deprecated: Use Type.ProtoReflect.Descriptor instead.

func (*Type) GetBuiltin

func (x *Type) GetBuiltin() Builtin

func (*Type) GetConfig

func (x *Type) GetConfig() *ConfigValue

func (*Type) GetList

func (x *Type) GetList() *List

func (*Type) GetLiteral

func (x *Type) GetLiteral() *Literal

func (*Type) GetMap

func (x *Type) GetMap() *Map

func (*Type) GetNamed

func (x *Type) GetNamed() *Named

func (*Type) GetPointer

func (x *Type) GetPointer() *Pointer

func (*Type) GetStruct

func (x *Type) GetStruct() *Struct

func (*Type) GetTyp

func (m *Type) GetTyp() isType_Typ

func (*Type) GetTypeParameter

func (x *Type) GetTypeParameter() *TypeParameterRef

func (*Type) GetUnion

func (x *Type) GetUnion() *Union

func (*Type) GetValidation

func (x *Type) GetValidation() *ValidationExpr

func (*Type) ProtoMessage

func (*Type) ProtoMessage()

func (*Type) ProtoReflect

func (x *Type) ProtoReflect() protoreflect.Message

func (*Type) Reset

func (x *Type) Reset()

func (*Type) String

func (x *Type) String() string

type TypeParameter

type TypeParameter struct {
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // The identifier given to the type parameter
	// contains filtered or unexported fields
}

TypeParameter acts as a place holder for an (as of yet) unknown type in the declaration; the type parameter is replaced with a type argument upon instantiation of the parameterized function or type.

func (*TypeParameter) Descriptor deprecated

func (*TypeParameter) Descriptor() ([]byte, []int)

Deprecated: Use TypeParameter.ProtoReflect.Descriptor instead.

func (*TypeParameter) GetName

func (x *TypeParameter) GetName() string

func (*TypeParameter) ProtoMessage

func (*TypeParameter) ProtoMessage()

func (*TypeParameter) ProtoReflect

func (x *TypeParameter) ProtoReflect() protoreflect.Message

func (*TypeParameter) Reset

func (x *TypeParameter) Reset()

func (*TypeParameter) String

func (x *TypeParameter) String() string

type TypeParameterRef

type TypeParameterRef struct {
	DeclId   uint32 `protobuf:"varint,1,opt,name=decl_id,json=declId,proto3" json:"decl_id,omitempty"`       // The ID of the declaration block
	ParamIdx uint32 `protobuf:"varint,2,opt,name=param_idx,json=paramIdx,proto3" json:"param_idx,omitempty"` // The index of the type parameter within the declaration block
	// contains filtered or unexported fields
}

TypeParameterRef is a reference to a `TypeParameter` within a declaration block

func (*TypeParameterRef) Descriptor deprecated

func (*TypeParameterRef) Descriptor() ([]byte, []int)

Deprecated: Use TypeParameterRef.ProtoReflect.Descriptor instead.

func (*TypeParameterRef) GetDeclId

func (x *TypeParameterRef) GetDeclId() uint32

func (*TypeParameterRef) GetParamIdx

func (x *TypeParameterRef) GetParamIdx() uint32

func (*TypeParameterRef) ProtoMessage

func (*TypeParameterRef) ProtoMessage()

func (*TypeParameterRef) ProtoReflect

func (x *TypeParameterRef) ProtoReflect() protoreflect.Message

func (*TypeParameterRef) Reset

func (x *TypeParameterRef) Reset()

func (*TypeParameterRef) String

func (x *TypeParameterRef) String() string

type Type_Builtin

type Type_Builtin struct {
	Builtin Builtin `protobuf:"varint,5,opt,name=builtin,proto3,enum=encore.parser.schema.v1.Builtin,oneof"` // The type is one of the base built in types within Go
}

type Type_Config

type Type_Config struct {
	// Encore Special Types
	Config *ConfigValue `protobuf:"bytes,7,opt,name=config,proto3,oneof"` // This value is a config value
}

type Type_List

type Type_List struct {
	List *List `protobuf:"bytes,4,opt,name=list,proto3,oneof"` // The type is a slice
}

type Type_Literal

type Type_Literal struct {
	Literal *Literal `protobuf:"bytes,10,opt,name=literal,proto3,oneof"` // The type is a literal
}

type Type_Map

type Type_Map struct {
	Map *Map `protobuf:"bytes,3,opt,name=map,proto3,oneof"` // The type is a map
}

type Type_Named

type Type_Named struct {
	// Concrete / non-parameterized Types
	Named *Named `protobuf:"bytes,1,opt,name=named,proto3,oneof"` // A "named" type (https://tip.golang.org/ref/spec#Types)
}

type Type_Pointer

type Type_Pointer struct {
	Pointer *Pointer `protobuf:"bytes,8,opt,name=pointer,proto3,oneof"` // The type is a pointer
}

type Type_Struct

type Type_Struct struct {
	Struct *Struct `protobuf:"bytes,2,opt,name=struct,proto3,oneof"` // The type is a struct definition
}

type Type_TypeParameter

type Type_TypeParameter struct {
	// Abstract Types
	TypeParameter *TypeParameterRef `protobuf:"bytes,6,opt,name=type_parameter,json=typeParameter,proto3,oneof"` // This is placeholder for a unknown type within the declaration block
}

type Type_Union

type Type_Union struct {
	Union *Union `protobuf:"bytes,9,opt,name=union,proto3,oneof"` // The type is a union
}

type Union

type Union struct {
	Types []*Type `protobuf:"bytes,1,rep,name=types,proto3" json:"types,omitempty"` // The types that make up the union
	// contains filtered or unexported fields
}

Union represents a union type.

func (*Union) Descriptor deprecated

func (*Union) Descriptor() ([]byte, []int)

Deprecated: Use Union.ProtoReflect.Descriptor instead.

func (*Union) GetTypes

func (x *Union) GetTypes() []*Type

func (*Union) ProtoMessage

func (*Union) ProtoMessage()

func (*Union) ProtoReflect

func (x *Union) ProtoReflect() protoreflect.Message

func (*Union) Reset

func (x *Union) Reset()

func (*Union) String

func (x *Union) String() string

type ValidationExpr

type ValidationExpr struct {

	// Types that are assignable to Expr:
	//
	//	*ValidationExpr_Rule
	//	*ValidationExpr_And_
	//	*ValidationExpr_Or_
	Expr isValidationExpr_Expr `protobuf_oneof:"expr"`
	// contains filtered or unexported fields
}

func (*ValidationExpr) Descriptor deprecated

func (*ValidationExpr) Descriptor() ([]byte, []int)

Deprecated: Use ValidationExpr.ProtoReflect.Descriptor instead.

func (*ValidationExpr) GetAnd

func (x *ValidationExpr) GetAnd() *ValidationExpr_And

func (*ValidationExpr) GetExpr

func (m *ValidationExpr) GetExpr() isValidationExpr_Expr

func (*ValidationExpr) GetOr

func (x *ValidationExpr) GetOr() *ValidationExpr_Or

func (*ValidationExpr) GetRule

func (x *ValidationExpr) GetRule() *ValidationRule

func (*ValidationExpr) ProtoMessage

func (*ValidationExpr) ProtoMessage()

func (*ValidationExpr) ProtoReflect

func (x *ValidationExpr) ProtoReflect() protoreflect.Message

func (*ValidationExpr) Reset

func (x *ValidationExpr) Reset()

func (*ValidationExpr) String

func (x *ValidationExpr) String() string

type ValidationExpr_And

type ValidationExpr_And struct {
	Exprs []*ValidationExpr `protobuf:"bytes,1,rep,name=exprs,proto3" json:"exprs,omitempty"`
	// contains filtered or unexported fields
}

func (*ValidationExpr_And) Descriptor deprecated

func (*ValidationExpr_And) Descriptor() ([]byte, []int)

Deprecated: Use ValidationExpr_And.ProtoReflect.Descriptor instead.

func (*ValidationExpr_And) GetExprs

func (x *ValidationExpr_And) GetExprs() []*ValidationExpr

func (*ValidationExpr_And) ProtoMessage

func (*ValidationExpr_And) ProtoMessage()

func (*ValidationExpr_And) ProtoReflect

func (x *ValidationExpr_And) ProtoReflect() protoreflect.Message

func (*ValidationExpr_And) Reset

func (x *ValidationExpr_And) Reset()

func (*ValidationExpr_And) String

func (x *ValidationExpr_And) String() string

type ValidationExpr_And_

type ValidationExpr_And_ struct {
	And *ValidationExpr_And `protobuf:"bytes,2,opt,name=and,proto3,oneof"`
}

type ValidationExpr_Or

type ValidationExpr_Or struct {
	Exprs []*ValidationExpr `protobuf:"bytes,1,rep,name=exprs,proto3" json:"exprs,omitempty"`
	// contains filtered or unexported fields
}

func (*ValidationExpr_Or) Descriptor deprecated

func (*ValidationExpr_Or) Descriptor() ([]byte, []int)

Deprecated: Use ValidationExpr_Or.ProtoReflect.Descriptor instead.

func (*ValidationExpr_Or) GetExprs

func (x *ValidationExpr_Or) GetExprs() []*ValidationExpr

func (*ValidationExpr_Or) ProtoMessage

func (*ValidationExpr_Or) ProtoMessage()

func (*ValidationExpr_Or) ProtoReflect

func (x *ValidationExpr_Or) ProtoReflect() protoreflect.Message

func (*ValidationExpr_Or) Reset

func (x *ValidationExpr_Or) Reset()

func (*ValidationExpr_Or) String

func (x *ValidationExpr_Or) String() string

type ValidationExpr_Or_

type ValidationExpr_Or_ struct {
	Or *ValidationExpr_Or `protobuf:"bytes,3,opt,name=or,proto3,oneof"`
}

type ValidationExpr_Rule

type ValidationExpr_Rule struct {
	Rule *ValidationRule `protobuf:"bytes,1,opt,name=rule,proto3,oneof"`
}

type ValidationRule

type ValidationRule struct {

	// Types that are assignable to Rule:
	//
	//	*ValidationRule_MinLen
	//	*ValidationRule_MaxLen
	//	*ValidationRule_MinVal
	//	*ValidationRule_MaxVal
	//	*ValidationRule_StartsWith
	//	*ValidationRule_EndsWith
	//	*ValidationRule_MatchesRegexp
	//	*ValidationRule_Is_
	Rule isValidationRule_Rule `protobuf_oneof:"rule"`
	// contains filtered or unexported fields
}

func (*ValidationRule) Descriptor deprecated

func (*ValidationRule) Descriptor() ([]byte, []int)

Deprecated: Use ValidationRule.ProtoReflect.Descriptor instead.

func (*ValidationRule) GetEndsWith

func (x *ValidationRule) GetEndsWith() string

func (*ValidationRule) GetIs

func (x *ValidationRule) GetIs() ValidationRule_Is

func (*ValidationRule) GetMatchesRegexp

func (x *ValidationRule) GetMatchesRegexp() string

func (*ValidationRule) GetMaxLen

func (x *ValidationRule) GetMaxLen() uint64

func (*ValidationRule) GetMaxVal

func (x *ValidationRule) GetMaxVal() float64

func (*ValidationRule) GetMinLen

func (x *ValidationRule) GetMinLen() uint64

func (*ValidationRule) GetMinVal

func (x *ValidationRule) GetMinVal() float64

func (*ValidationRule) GetRule

func (m *ValidationRule) GetRule() isValidationRule_Rule

func (*ValidationRule) GetStartsWith

func (x *ValidationRule) GetStartsWith() string

func (*ValidationRule) ProtoMessage

func (*ValidationRule) ProtoMessage()

func (*ValidationRule) ProtoReflect

func (x *ValidationRule) ProtoReflect() protoreflect.Message

func (*ValidationRule) Reset

func (x *ValidationRule) Reset()

func (*ValidationRule) String

func (x *ValidationRule) String() string

type ValidationRule_EndsWith

type ValidationRule_EndsWith struct {
	EndsWith string `protobuf:"bytes,6,opt,name=ends_with,json=endsWith,proto3,oneof"`
}

type ValidationRule_Is

type ValidationRule_Is int32
const (
	ValidationRule_UNKNOWN ValidationRule_Is = 0
	ValidationRule_EMAIL   ValidationRule_Is = 1
	ValidationRule_URL     ValidationRule_Is = 2
)

func (ValidationRule_Is) Descriptor

func (ValidationRule_Is) Enum

func (ValidationRule_Is) EnumDescriptor deprecated

func (ValidationRule_Is) EnumDescriptor() ([]byte, []int)

Deprecated: Use ValidationRule_Is.Descriptor instead.

func (ValidationRule_Is) Number

func (ValidationRule_Is) String

func (x ValidationRule_Is) String() string

func (ValidationRule_Is) Type

type ValidationRule_Is_

type ValidationRule_Is_ struct {
	Is ValidationRule_Is `protobuf:"varint,8,opt,name=is,proto3,enum=encore.parser.schema.v1.ValidationRule_Is,oneof"`
}

type ValidationRule_MatchesRegexp

type ValidationRule_MatchesRegexp struct {
	MatchesRegexp string `protobuf:"bytes,7,opt,name=matches_regexp,json=matchesRegexp,proto3,oneof"`
}

type ValidationRule_MaxLen

type ValidationRule_MaxLen struct {
	MaxLen uint64 `protobuf:"varint,2,opt,name=max_len,json=maxLen,proto3,oneof"`
}

type ValidationRule_MaxVal

type ValidationRule_MaxVal struct {
	MaxVal float64 `protobuf:"fixed64,4,opt,name=max_val,json=maxVal,proto3,oneof"`
}

type ValidationRule_MinLen

type ValidationRule_MinLen struct {
	MinLen uint64 `protobuf:"varint,1,opt,name=min_len,json=minLen,proto3,oneof"`
}

type ValidationRule_MinVal

type ValidationRule_MinVal struct {
	MinVal float64 `protobuf:"fixed64,3,opt,name=min_val,json=minVal,proto3,oneof"`
}

type ValidationRule_StartsWith

type ValidationRule_StartsWith struct {
	StartsWith string `protobuf:"bytes,5,opt,name=starts_with,json=startsWith,proto3,oneof"`
}

type WireSpec

type WireSpec struct {

	// Types that are assignable to Location:
	//
	//	*WireSpec_Header_
	//	*WireSpec_Query_
	//	*WireSpec_Cookie_
	Location isWireSpec_Location `protobuf_oneof:"location"`
	// contains filtered or unexported fields
}

WireLocation provides information about how a field should be encoded on the wire.

func (*WireSpec) Descriptor deprecated

func (*WireSpec) Descriptor() ([]byte, []int)

Deprecated: Use WireSpec.ProtoReflect.Descriptor instead.

func (*WireSpec) GetCookie

func (x *WireSpec) GetCookie() *WireSpec_Cookie

func (*WireSpec) GetHeader

func (x *WireSpec) GetHeader() *WireSpec_Header

func (*WireSpec) GetLocation

func (m *WireSpec) GetLocation() isWireSpec_Location

func (*WireSpec) GetQuery

func (x *WireSpec) GetQuery() *WireSpec_Query

func (*WireSpec) ProtoMessage

func (*WireSpec) ProtoMessage()

func (*WireSpec) ProtoReflect

func (x *WireSpec) ProtoReflect() protoreflect.Message

func (*WireSpec) Reset

func (x *WireSpec) Reset()

func (*WireSpec) String

func (x *WireSpec) String() string
type WireSpec_Cookie struct {

	// The explicitly specified cookie string name.
	// If empty, the name of the field is used.
	Name *string `protobuf:"bytes,1,opt,name=name,proto3,oneof" json:"name,omitempty"`
	// contains filtered or unexported fields
}

func (*WireSpec_Cookie) Descriptor deprecated

func (*WireSpec_Cookie) Descriptor() ([]byte, []int)

Deprecated: Use WireSpec_Cookie.ProtoReflect.Descriptor instead.

func (*WireSpec_Cookie) GetName

func (x *WireSpec_Cookie) GetName() string

func (*WireSpec_Cookie) ProtoMessage

func (*WireSpec_Cookie) ProtoMessage()

func (*WireSpec_Cookie) ProtoReflect

func (x *WireSpec_Cookie) ProtoReflect() protoreflect.Message

func (*WireSpec_Cookie) Reset

func (x *WireSpec_Cookie) Reset()

func (*WireSpec_Cookie) String

func (x *WireSpec_Cookie) String() string
type WireSpec_Cookie_ struct {
	Cookie *WireSpec_Cookie `protobuf:"bytes,3,opt,name=cookie,proto3,oneof"`
}

type WireSpec_Header

type WireSpec_Header struct {

	// The explicitly specified header name.
	// If empty, the name of the field is used.
	Name *string `protobuf:"bytes,1,opt,name=name,proto3,oneof" json:"name,omitempty"`
	// contains filtered or unexported fields
}

func (*WireSpec_Header) Descriptor deprecated

func (*WireSpec_Header) Descriptor() ([]byte, []int)

Deprecated: Use WireSpec_Header.ProtoReflect.Descriptor instead.

func (*WireSpec_Header) GetName

func (x *WireSpec_Header) GetName() string

func (*WireSpec_Header) ProtoMessage

func (*WireSpec_Header) ProtoMessage()

func (*WireSpec_Header) ProtoReflect

func (x *WireSpec_Header) ProtoReflect() protoreflect.Message

func (*WireSpec_Header) Reset

func (x *WireSpec_Header) Reset()

func (*WireSpec_Header) String

func (x *WireSpec_Header) String() string

type WireSpec_Header_

type WireSpec_Header_ struct {
	Header *WireSpec_Header `protobuf:"bytes,1,opt,name=header,proto3,oneof"`
}

type WireSpec_Query

type WireSpec_Query struct {

	// The explicitly specified query string name.
	// If empty, the name of the field is used.
	Name *string `protobuf:"bytes,1,opt,name=name,proto3,oneof" json:"name,omitempty"`
	// contains filtered or unexported fields
}

func (*WireSpec_Query) Descriptor deprecated

func (*WireSpec_Query) Descriptor() ([]byte, []int)

Deprecated: Use WireSpec_Query.ProtoReflect.Descriptor instead.

func (*WireSpec_Query) GetName

func (x *WireSpec_Query) GetName() string

func (*WireSpec_Query) ProtoMessage

func (*WireSpec_Query) ProtoMessage()

func (*WireSpec_Query) ProtoReflect

func (x *WireSpec_Query) ProtoReflect() protoreflect.Message

func (*WireSpec_Query) Reset

func (x *WireSpec_Query) Reset()

func (*WireSpec_Query) String

func (x *WireSpec_Query) String() string

type WireSpec_Query_

type WireSpec_Query_ struct {
	Query *WireSpec_Query `protobuf:"bytes,2,opt,name=query,proto3,oneof"`
}

Jump to

Keyboard shortcuts

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