tokens

package
v0.0.0-...-b19370d Latest Latest
Warning

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

Go to latest
Published: Jan 3, 2025 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var InvalidToken = Token{
	Type: TokenTypeInvalid,
}

Functions

This section is empty.

Types

type Token

type Token struct {
	Type   TokenType
	Offset int
	Text   string
}

func NewToken

func NewToken(tokenType TokenType, offset int, text string) Token

type TokenType

type TokenType int
const (
	TokenTypeInvalid TokenType = iota
	TokenTypeEOF
	TokenTypeKeyword
	TokenTypeWhitespace
	TokenTypeIdent
	TokenTypeNumber
	TokenTypeString

	TokenTypeAdd
	TokenTypeAll
	TokenTypeAlter
	TokenTypeAnd
	TokenTypeAs
	TokenTypeAscending
	TokenTypeBetween
	TokenTypeBy
	TokenTypeCheck
	TokenTypeConstraint
	TokenTypeCreate
	TokenTypeDefault
	TokenTypeDelete
	TokenTypeDescending
	TokenTypeDistinct
	TokenTypeExcept
	TokenTypeExplain
	TokenTypeFalse
	TokenTypeForeign
	TokenTypeFrom
	TokenTypeGroup
	TokenTypeILike
	TokenTypeIndex
	TokenTypeInsert
	TokenTypeIntersect
	TokenTypeInto
	TokenTypeIs
	TokenTypeJoin
	TokenTypeKey
	TokenTypeKwUnknown
	TokenTypeLike
	TokenTypeLimit
	TokenTypeNot
	TokenTypeNull
	TokenTypeOffset
	TokenTypeOn
	TokenTypeOr
	TokenTypeOrder
	TokenTypePrimary
	TokenTypeReferences
	TokenTypeReturning
	TokenTypeSelect
	TokenTypeSequence
	TokenTypeSet
	TokenTypeSymmetric
	TokenTypeTable
	TokenTypeTrue
	TokenTypeUnion
	TokenTypeUnique
	TokenTypeUpdate
	TokenTypeUsing
	TokenTypeValues
	TokenTypeWhere

	TokenTypeMinus
	TokenTypeComma
	TokenTypeSemicolon
	TokenTypeDot
	TokenTypeLeftParen
	TokenTypeRightParen
	TokenTypeAsterisk
	TokenTypeSlash
	TokenTypePlus
	TokenTypeLessThan
	TokenTypeEquals
	TokenTypeGreaterThan

	TokenTypeLessThanOrEqual
	TokenTypeNotEquals
	TokenTypeGreaterThanOrEqual
	TokenTypeConcat

	TokenTypeBetweenSymmetric
	TokenTypeForeignKey
	TokenTypeIsDistinctFrom
	TokenTypeIsFalse
	TokenTypeIsNotDistinctFrom
	TokenTypeIsNotFalse
	TokenTypeIsNotNull
	TokenTypeIsNotTrue
	TokenTypeIsNotUnknown
	TokenTypeIsNull
	TokenTypeIsTrue
	TokenTypeIsUnknown
	TokenTypeNotBetween
	TokenTypeNotBetweenSymmetric
	TokenTypeNotILike
	TokenTypeNotLike
	TokenTypeNotNull
	TokenTypePrimaryKey

	TokenTypeUnknown
)

Jump to

Keyboard shortcuts

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