cdproto: github.com/chromedp/cdproto/log Index | Files

package log

import "github.com/chromedp/cdproto/log"

Package log provides the Chrome DevTools Protocol commands, types, and events for the Log domain.

Provides access to log entries.

Generated by the cdproto-gen command.

Index

Package Files

easyjson.go events.go log.go types.go

Constants

const (
    CommandClear                 = "Log.clear"
    CommandDisable               = "Log.disable"
    CommandEnable                = "Log.enable"
    CommandStartViolationsReport = "Log.startViolationsReport"
    CommandStopViolationsReport  = "Log.stopViolationsReport"
)

Command names.

type ClearParams Uses

type ClearParams struct{}

ClearParams clears the log.

func Clear Uses

func Clear() *ClearParams

Clear clears the log.

See: https://chromedevtools.github.io/devtools-protocol/tot/Log#method-clear

func (*ClearParams) Do Uses

func (p *ClearParams) Do(ctx context.Context) (err error)

Do executes Log.clear against the provided context.

func (ClearParams) MarshalEasyJSON Uses

func (v ClearParams) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (ClearParams) MarshalJSON Uses

func (v ClearParams) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*ClearParams) UnmarshalEasyJSON Uses

func (v *ClearParams) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*ClearParams) UnmarshalJSON Uses

func (v *ClearParams) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

type DisableParams Uses

type DisableParams struct{}

DisableParams disables log domain, prevents further log entries from being reported to the client.

func Disable Uses

func Disable() *DisableParams

Disable disables log domain, prevents further log entries from being reported to the client.

See: https://chromedevtools.github.io/devtools-protocol/tot/Log#method-disable

func (*DisableParams) Do Uses

func (p *DisableParams) Do(ctx context.Context) (err error)

Do executes Log.disable against the provided context.

func (DisableParams) MarshalEasyJSON Uses

func (v DisableParams) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (DisableParams) MarshalJSON Uses

func (v DisableParams) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*DisableParams) UnmarshalEasyJSON Uses

func (v *DisableParams) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*DisableParams) UnmarshalJSON Uses

func (v *DisableParams) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

type EnableParams Uses

type EnableParams struct{}

EnableParams enables log domain, sends the entries collected so far to the client by means of the entryAdded notification.

func Enable Uses

func Enable() *EnableParams

Enable enables log domain, sends the entries collected so far to the client by means of the entryAdded notification.

See: https://chromedevtools.github.io/devtools-protocol/tot/Log#method-enable

func (*EnableParams) Do Uses

func (p *EnableParams) Do(ctx context.Context) (err error)

Do executes Log.enable against the provided context.

func (EnableParams) MarshalEasyJSON Uses

func (v EnableParams) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (EnableParams) MarshalJSON Uses

func (v EnableParams) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*EnableParams) UnmarshalEasyJSON Uses

func (v *EnableParams) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*EnableParams) UnmarshalJSON Uses

func (v *EnableParams) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

type Entry Uses

type Entry struct {
    Source           Source                  `json:"source"`                     // Log entry source.
    Level            Level                   `json:"level"`                      // Log entry severity.
    Text             string                  `json:"text"`                       // Logged text.
    Timestamp        *runtime.Timestamp      `json:"timestamp"`                  // Timestamp when this entry was added.
    URL              string                  `json:"url,omitempty"`              // URL of the resource if known.
    LineNumber       int64                   `json:"lineNumber,omitempty"`       // Line number in the resource.
    StackTrace       *runtime.StackTrace     `json:"stackTrace,omitempty"`       // JavaScript stack trace.
    NetworkRequestID network.RequestID       `json:"networkRequestId,omitempty"` // Identifier of the network request associated with this entry.
    WorkerID         string                  `json:"workerId,omitempty"`         // Identifier of the worker associated with this entry.
    Args             []*runtime.RemoteObject `json:"args,omitempty"`             // Call arguments.
}

Entry log entry.

See: https://chromedevtools.github.io/devtools-protocol/tot/Log#type-LogEntry

func (Entry) MarshalEasyJSON Uses

func (v Entry) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (Entry) MarshalJSON Uses

func (v Entry) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*Entry) UnmarshalEasyJSON Uses

func (v *Entry) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*Entry) UnmarshalJSON Uses

func (v *Entry) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

type EventEntryAdded Uses

type EventEntryAdded struct {
    Entry *Entry `json:"entry"` // The entry.
}

EventEntryAdded issued when new message was logged.

See: https://chromedevtools.github.io/devtools-protocol/tot/Log#event-entryAdded

func (EventEntryAdded) MarshalEasyJSON Uses

func (v EventEntryAdded) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (EventEntryAdded) MarshalJSON Uses

func (v EventEntryAdded) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*EventEntryAdded) UnmarshalEasyJSON Uses

func (v *EventEntryAdded) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*EventEntryAdded) UnmarshalJSON Uses

func (v *EventEntryAdded) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

type Level Uses

type Level string

Level log entry severity.

See: https://chromedevtools.github.io/devtools-protocol/tot/Log#type-LogEntry

const (
    LevelVerbose Level = "verbose"
    LevelInfo    Level = "info"
    LevelWarning Level = "warning"
    LevelError   Level = "error"
)

Level values.

func (Level) MarshalEasyJSON Uses

func (t Level) MarshalEasyJSON(out *jwriter.Writer)

MarshalEasyJSON satisfies easyjson.Marshaler.

func (Level) MarshalJSON Uses

func (t Level) MarshalJSON() ([]byte, error)

MarshalJSON satisfies json.Marshaler.

func (Level) String Uses

func (t Level) String() string

String returns the Level as string value.

func (*Level) UnmarshalEasyJSON Uses

func (t *Level) UnmarshalEasyJSON(in *jlexer.Lexer)

UnmarshalEasyJSON satisfies easyjson.Unmarshaler.

func (*Level) UnmarshalJSON Uses

func (t *Level) UnmarshalJSON(buf []byte) error

UnmarshalJSON satisfies json.Unmarshaler.

type Source Uses

type Source string

Source log entry source.

See: https://chromedevtools.github.io/devtools-protocol/tot/Log#type-LogEntry

const (
    SourceXML            Source = "xml"
    SourceJavascript     Source = "javascript"
    SourceNetwork        Source = "network"
    SourceStorage        Source = "storage"
    SourceAppcache       Source = "appcache"
    SourceRendering      Source = "rendering"
    SourceSecurity       Source = "security"
    SourceDeprecation    Source = "deprecation"
    SourceWorker         Source = "worker"
    SourceViolation      Source = "violation"
    SourceIntervention   Source = "intervention"
    SourceRecommendation Source = "recommendation"
    SourceOther          Source = "other"
)

Source values.

func (Source) MarshalEasyJSON Uses

func (t Source) MarshalEasyJSON(out *jwriter.Writer)

MarshalEasyJSON satisfies easyjson.Marshaler.

func (Source) MarshalJSON Uses

func (t Source) MarshalJSON() ([]byte, error)

MarshalJSON satisfies json.Marshaler.

func (Source) String Uses

func (t Source) String() string

String returns the Source as string value.

func (*Source) UnmarshalEasyJSON Uses

func (t *Source) UnmarshalEasyJSON(in *jlexer.Lexer)

UnmarshalEasyJSON satisfies easyjson.Unmarshaler.

func (*Source) UnmarshalJSON Uses

func (t *Source) UnmarshalJSON(buf []byte) error

UnmarshalJSON satisfies json.Unmarshaler.

type StartViolationsReportParams Uses

type StartViolationsReportParams struct {
    Config []*ViolationSetting `json:"config"` // Configuration for violations.
}

StartViolationsReportParams start violation reporting.

func StartViolationsReport Uses

func StartViolationsReport(config []*ViolationSetting) *StartViolationsReportParams

StartViolationsReport start violation reporting.

See: https://chromedevtools.github.io/devtools-protocol/tot/Log#method-startViolationsReport

parameters:

config - Configuration for violations.

func (*StartViolationsReportParams) Do Uses

func (p *StartViolationsReportParams) Do(ctx context.Context) (err error)

Do executes Log.startViolationsReport against the provided context.

func (StartViolationsReportParams) MarshalEasyJSON Uses

func (v StartViolationsReportParams) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (StartViolationsReportParams) MarshalJSON Uses

func (v StartViolationsReportParams) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*StartViolationsReportParams) UnmarshalEasyJSON Uses

func (v *StartViolationsReportParams) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*StartViolationsReportParams) UnmarshalJSON Uses

func (v *StartViolationsReportParams) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

type StopViolationsReportParams Uses

type StopViolationsReportParams struct{}

StopViolationsReportParams stop violation reporting.

func StopViolationsReport Uses

func StopViolationsReport() *StopViolationsReportParams

StopViolationsReport stop violation reporting.

See: https://chromedevtools.github.io/devtools-protocol/tot/Log#method-stopViolationsReport

func (*StopViolationsReportParams) Do Uses

func (p *StopViolationsReportParams) Do(ctx context.Context) (err error)

Do executes Log.stopViolationsReport against the provided context.

func (StopViolationsReportParams) MarshalEasyJSON Uses

func (v StopViolationsReportParams) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (StopViolationsReportParams) MarshalJSON Uses

func (v StopViolationsReportParams) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*StopViolationsReportParams) UnmarshalEasyJSON Uses

func (v *StopViolationsReportParams) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*StopViolationsReportParams) UnmarshalJSON Uses

func (v *StopViolationsReportParams) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

type Violation Uses

type Violation string

Violation violation type.

See: https://chromedevtools.github.io/devtools-protocol/tot/Log#type-ViolationSetting

const (
    ViolationLongTask          Violation = "longTask"
    ViolationLongLayout        Violation = "longLayout"
    ViolationBlockedEvent      Violation = "blockedEvent"
    ViolationBlockedParser     Violation = "blockedParser"
    ViolationDiscouragedAPIUse Violation = "discouragedAPIUse"
    ViolationHandler           Violation = "handler"
    ViolationRecurringHandler  Violation = "recurringHandler"
)

Violation values.

func (Violation) MarshalEasyJSON Uses

func (t Violation) MarshalEasyJSON(out *jwriter.Writer)

MarshalEasyJSON satisfies easyjson.Marshaler.

func (Violation) MarshalJSON Uses

func (t Violation) MarshalJSON() ([]byte, error)

MarshalJSON satisfies json.Marshaler.

func (Violation) String Uses

func (t Violation) String() string

String returns the Violation as string value.

func (*Violation) UnmarshalEasyJSON Uses

func (t *Violation) UnmarshalEasyJSON(in *jlexer.Lexer)

UnmarshalEasyJSON satisfies easyjson.Unmarshaler.

func (*Violation) UnmarshalJSON Uses

func (t *Violation) UnmarshalJSON(buf []byte) error

UnmarshalJSON satisfies json.Unmarshaler.

type ViolationSetting Uses

type ViolationSetting struct {
    Name      Violation `json:"name"`      // Violation type.
    Threshold float64   `json:"threshold"` // Time threshold to trigger upon.
}

ViolationSetting violation configuration setting.

See: https://chromedevtools.github.io/devtools-protocol/tot/Log#type-ViolationSetting

func (ViolationSetting) MarshalEasyJSON Uses

func (v ViolationSetting) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (ViolationSetting) MarshalJSON Uses

func (v ViolationSetting) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*ViolationSetting) UnmarshalEasyJSON Uses

func (v *ViolationSetting) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*ViolationSetting) UnmarshalJSON Uses

func (v *ViolationSetting) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

Package log imports 9 packages (graph) and is imported by 18 packages. Updated 2021-01-10. Refresh now. Tools for package owners.