option

package
v0.29.1 Latest Latest
Warning

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

Go to latest
Published: Jan 1, 2025 License: Apache-2.0 Imports: 0 Imported by: 8

Documentation

Index

Constants

View Source
const SortDirectionAscending = "ASC"

SortDirectionAscending is the token that designates that records should be sorted lowest to highest

View Source
const SortDirectionDescending = "DESC"

SortDirectionDescending is the token that designates that records should be sorted highest to lowest

View Source
const TypeCaseSensitive = "CASESENSITIVE"

TypeCaseSensitive is the token that designates case sensitivity of search results

View Source
const TypeFields = "FIELDS"

TypeFields is the token that designates the fields to be returned

View Source
const TypeFirstRow = "FIRSTROW"

TypeFirstRow is the token that designates the "row number" to begin results.

View Source
const TypeMaxRows = "MAXROWS"

TypeMaxRows is the token that designates the maximum number of records to be returned

View Source
const TypeSort = "SORT"

TypeSort is the token that designates a Sort order

Variables

This section is empty.

Functions

This section is empty.

Types

type CaseSensitiveOption added in v0.29.0

type CaseSensitiveOption bool

CaseSensitiveOption is a query option that designates case sensitivity of search results.

func (CaseSensitiveOption) CaseSensitive added in v0.29.0

func (option CaseSensitiveOption) CaseSensitive() bool

CaseSensitive returns TRUE if the results should consider letter case

func (CaseSensitiveOption) OptionType added in v0.29.0

func (option CaseSensitiveOption) OptionType() string

OptionType identifies this object as a query option

type FieldsOption added in v0.29.0

type FieldsOption []string

FieldsOption is a query option that limits the number of rows to be included in a dataset

func (FieldsOption) Fields added in v0.29.0

func (option FieldsOption) Fields() []string

Fields returns the maximum number of rows to include in a dataset

func (FieldsOption) OptionType added in v0.29.0

func (option FieldsOption) OptionType() string

OptionType identifies this object as a query option

type FirstRowOption added in v0.29.0

type FirstRowOption struct{}

FirstRowOption is a query option that sets the first row to be returned in a dataset

func (FirstRowOption) OptionType added in v0.29.0

func (option FirstRowOption) OptionType() string

OptionType identifies this object as a query option

type MaxRowsOption added in v0.29.0

type MaxRowsOption int64

MaxRowsOption is a query option that limits the number of rows to be included in a dataset

func (MaxRowsOption) MaxRows added in v0.29.0

func (option MaxRowsOption) MaxRows() int64

MaxRows returns the maximum number of rows to include in a dataset

func (MaxRowsOption) OptionType added in v0.29.0

func (option MaxRowsOption) OptionType() string

OptionType identifies this object as a query option

type Option

type Option interface {
	OptionType() string
}

Option is an interface that wraps all of the query options that can be used to modify a database query.

func CaseSensitive added in v0.29.0

func CaseSensitive(caseSensitive bool) Option

CaseSensitive returns a query option that will designate the case sensitivity of search results

func Fields added in v0.22.0

func Fields(fields ...string) Option

Fields returns a query option that will limit the query results to a certain number of rows

func FirstRow

func FirstRow() Option

FirstRow returns a query option that will limit the query results to a certain number of rows

func MaxRows

func MaxRows(maxRows int64) Option

MaxRows returns a query option that will limit the query results to a certain number of rows

func SortAsc

func SortAsc(fieldName string) Option

SortAsc returns a query option that will sort the query results in ASCENDING order

func SortDesc

func SortDesc(fieldName string) Option

SortDesc returns a query option that will sort the query results in DESCENDING order

type SortOption added in v0.29.0

type SortOption struct {
	FieldName string
	Direction string
}

SortOption identifies the field and direction to use when sorting a dataset

func (SortOption) OptionType added in v0.29.0

func (sortConfig SortOption) OptionType() string

OptionType identifies this object as a query option

Jump to

Keyboard shortcuts

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