query

package
v0.0.0-...-d4b3ac2 Latest Latest
Warning

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

Go to latest
Published: Mar 10, 2021 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Overview

Package query provides objects for specifying a query against stenographer.

Index

Constants

View Source
const AFTER = 57357
View Source
const AGO = 57359
View Source
const AND = 57349
View Source
const BEFORE = 57356
View Source
const DURATION = 57364
View Source
const HOST = 57346
View Source
const ICMP = 57355
View Source
const IP = 57362
View Source
const IPP = 57358
View Source
const MASK = 57352
View Source
const MPLS = 57361
View Source
const NET = 57351
View Source
const NUM = 57363
View Source
const OR = 57350
View Source
const PORT = 57347
View Source
const PROTO = 57348
View Source
const TCP = 57353
View Source
const TIME = 57365
View Source
const UDP = 57354
View Source
const VLAN = 57360

Variables

This section is empty.

Functions

This section is empty.

Types

type Query

type Query interface {
	// LookupIn finds the set of packet positions for all packets that match the
	// query from an index file.  Users shouldn't call this directly, and should
	// instead pass the query into BlockFile's Lookup() to get back actual
	// packets.
	LookupIn(context.Context, *indexfile.IndexFile) (base.Positions, error)
	// String returns a human readable string for this query.
	String() string
	// contains filtered or unexported methods
}

Query encodes the set of packets a requester wants to get from stenographer.

func NewQuery

func NewQuery(query string) (Query, error)

NewQuery parses the given query arg and returns a query object. This query can then be passed into a blockfile to get out the set of packets which match it.

Currently, we support one simple method of parsing a query, detailed in the README.md file. Returns an error if the query string is invalid.

Jump to

Keyboard shortcuts

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