v1

package
v1.0.0-preview-2 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2024 License: MIT Imports: 12 Imported by: 1

Documentation

Index

Constants

View Source
const PrimaryResultKind = "QueryResult"

Variables

This section is empty.

Functions

func NewTable

func NewTable(d query.BaseDataset, dt *RawTable, index *TableIndexRow) (query.Table, error)

Types

type Dataset

type Dataset interface {
	query.Dataset
	Index() []TableIndexRow
	Status() []QueryStatus
	Info() []QueryProperties
}

func NewDataset

func NewDataset(ctx context.Context, op errors.Op, v1 V1) (Dataset, error)

func NewDatasetFromReader

func NewDatasetFromReader(ctx context.Context, op errors.Op, reader io.ReadCloser) (Dataset, error)

type QueryProperties

type QueryProperties struct {
	Value string
}

type QueryStatus

type QueryStatus struct {
	Timestamp         time.Time
	Severity          int32
	SeverityName      string
	StatusCode        int32
	StatusDescription string
	Count             int32
	RequestId         uuid.UUID
	ActivityId        uuid.UUID
	SubActivityId     uuid.UUID
	ClientActivityId  string
}

type RawColumn

type RawColumn struct {
	ColumnName string `json:"ColumnName"`
	DataType   string `json:"DataType"`
	ColumnType string `json:"ColumnType"`
}

type RawRow

type RawRow struct {
	Row    []interface{}
	Errors []string
}

func (*RawRow) UnmarshalJSON

func (r *RawRow) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaler interface, to decode a RawRow from JSON. It needs special handling, because the field may be a Row or a list of Errors.

type RawTable

type RawTable struct {
	TableName string      `json:"TableName"`
	Columns   []RawColumn `json:"Columns"`
	Rows      []RawRow    `json:"Rows"`
}

type TableIndexRow

type TableIndexRow struct {
	Ordinal    int64
	Kind       string
	Name       string
	Id         string
	PrettyName string
}

type V1

type V1 struct {
	Tables     []RawTable `json:"Tables"`
	Exceptions []string   `json:"Exceptions"`
}

Jump to

Keyboard shortcuts

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