napcontext

package
v0.4.8 Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Copyright © 2021 Bold City Software

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

context.go - this data represents a runnable context with its own set of environment variables and javascript context

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

scriptcontext.go - this data represents a runnable javascript context

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Context

type Context struct {
	Environments         []string
	EnvironmentVariables map[string]string
	WorkingDirectory     string
	ScriptContext        *ScriptContext
	Cookies              []*http.Cookie
	// contains filtered or unexported fields
}

func New

func New(workingDirectory string, environments []string, environmentVariables map[string]string, wg *sync.WaitGroup, quiet bool) *Context

func (*Context) Clone

func (old *Context) Clone(workingDirectory string) *Context

func (*Context) Complete added in v0.4.0

func (ctx *Context) Complete()

func (*Context) ProgressCancel added in v0.4.8

func (ctx *Context) ProgressCancel(progress *Progress)

func (*Context) ProgressIncrement added in v0.4.0

func (ctx *Context) ProgressIncrement(progress *Progress)

func (*Context) ProgressStart added in v0.4.0

func (ctx *Context) ProgressStart(name string, steps int64) *Progress

type Progress added in v0.4.0

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

type ScriptContext added in v0.4.0

type ScriptContext struct {
	Error  error
	Output []string

	Vm *otto.Otto
}

Jump to

Keyboard shortcuts

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