transform

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: May 1, 2022 License: MIT Imports: 11 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Browser

type Browser struct {
	Name          string `json:"name"`
	Version       string `json:"version"`
	Engine        string `json:"engine"`
	EngineVersion string `json:"engineVersion"`
}

type OperatingSystem

type OperatingSystem struct {
	Name     string `json:"name"`
	FullName string `json:"fullName"`
	Version  string `json:"version"`
}

type Transformer

type Transformer struct {
	// contains filtered or unexported fields
}

Default Transformer implementation (stateless, immutable). This is currently the only implementation and supports all transformation types available in a GEIST spec. Future custom transformer implementations are easily added through this mechanism.

func NewTransformer

func NewTransformer(spec *model.Spec) *Transformer

func (*Transformer) Transform

func (t *Transformer) Transform(
	ctx context.Context,
	event []byte,
	retryable *bool) ([]*model.Transformed, error)

Transform in current implementation cannot have an error, but keep for future transformations.

type UserAgent

type UserAgent struct {
	Platform        string          `json:"platform"`
	OperatingSystem OperatingSystem `json:"operatingSystem"`
	Localization    string          `json:"localization"`
	Browser         Browser         `json:"browser"`
	Bot             bool            `json:"bot"`
	Mobile          bool            `json:"mobile"`
}

func NewUserAgent

func NewUserAgent(uaString string) (UserAgent, error)

func (UserAgent) String

func (u UserAgent) String() string

Jump to

Keyboard shortcuts

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