2017-01-24 15:09:23 +00:00
|
|
|
package debugger
|
|
|
|
|
|
|
|
// AUTOGENERATED. DO NOT EDIT.
|
|
|
|
|
|
|
|
import (
|
2017-01-26 07:28:34 +00:00
|
|
|
cdp "github.com/knq/chromedp/cdp"
|
2017-01-24 15:09:23 +00:00
|
|
|
"github.com/knq/chromedp/cdp/runtime"
|
|
|
|
"github.com/mailru/easyjson"
|
|
|
|
)
|
|
|
|
|
|
|
|
// EventScriptParsed fired when virtual machine parses script. This event is
|
|
|
|
// also fired for all known and uncollected scripts upon enabling debugger.
|
|
|
|
type EventScriptParsed struct {
|
2017-07-02 11:44:34 +00:00
|
|
|
ScriptID runtime.ScriptID `json:"scriptId"` // Identifier of the script parsed.
|
|
|
|
URL string `json:"url"` // URL or name of the script parsed (if any).
|
|
|
|
StartLine int64 `json:"startLine"` // Line offset of the script within the resource with given URL (for script tags).
|
|
|
|
StartColumn int64 `json:"startColumn"` // Column offset of the script within the resource with given URL.
|
|
|
|
EndLine int64 `json:"endLine"` // Last line of the script.
|
|
|
|
EndColumn int64 `json:"endColumn"` // Length of the last line of the script.
|
|
|
|
ExecutionContextID runtime.ExecutionContextID `json:"executionContextId"` // Specifies script creation context.
|
|
|
|
Hash string `json:"hash"` // Content hash of the script.
|
2017-01-24 15:09:23 +00:00
|
|
|
ExecutionContextAuxData easyjson.RawMessage `json:"executionContextAuxData,omitempty"`
|
|
|
|
IsLiveEdit bool `json:"isLiveEdit,omitempty"` // True, if this script is generated as a result of the live edit operation.
|
|
|
|
SourceMapURL string `json:"sourceMapURL,omitempty"` // URL of source map associated with script (if any).
|
|
|
|
HasSourceURL bool `json:"hasSourceURL,omitempty"` // True, if this script has sourceURL.
|
2017-01-29 03:37:56 +00:00
|
|
|
IsModule bool `json:"isModule,omitempty"` // True, if this script is ES6 module.
|
2017-03-13 02:29:26 +00:00
|
|
|
Length int64 `json:"length,omitempty"` // This script length.
|
2017-03-18 16:48:19 +00:00
|
|
|
StackTrace *runtime.StackTrace `json:"stackTrace,omitempty"` // JavaScript top stack frame of where the script parsed event was triggered if available.
|
2017-01-24 15:09:23 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
// EventScriptFailedToParse fired when virtual machine fails to parse the
|
|
|
|
// script.
|
|
|
|
type EventScriptFailedToParse struct {
|
2017-07-02 11:44:34 +00:00
|
|
|
ScriptID runtime.ScriptID `json:"scriptId"` // Identifier of the script parsed.
|
|
|
|
URL string `json:"url"` // URL or name of the script parsed (if any).
|
|
|
|
StartLine int64 `json:"startLine"` // Line offset of the script within the resource with given URL (for script tags).
|
|
|
|
StartColumn int64 `json:"startColumn"` // Column offset of the script within the resource with given URL.
|
|
|
|
EndLine int64 `json:"endLine"` // Last line of the script.
|
|
|
|
EndColumn int64 `json:"endColumn"` // Length of the last line of the script.
|
|
|
|
ExecutionContextID runtime.ExecutionContextID `json:"executionContextId"` // Specifies script creation context.
|
|
|
|
Hash string `json:"hash"` // Content hash of the script.
|
2017-01-24 15:09:23 +00:00
|
|
|
ExecutionContextAuxData easyjson.RawMessage `json:"executionContextAuxData,omitempty"`
|
|
|
|
SourceMapURL string `json:"sourceMapURL,omitempty"` // URL of source map associated with script (if any).
|
|
|
|
HasSourceURL bool `json:"hasSourceURL,omitempty"` // True, if this script has sourceURL.
|
2017-01-29 03:37:56 +00:00
|
|
|
IsModule bool `json:"isModule,omitempty"` // True, if this script is ES6 module.
|
2017-03-13 02:29:26 +00:00
|
|
|
Length int64 `json:"length,omitempty"` // This script length.
|
2017-03-18 16:48:19 +00:00
|
|
|
StackTrace *runtime.StackTrace `json:"stackTrace,omitempty"` // JavaScript top stack frame of where the script parsed event was triggered if available.
|
2017-01-24 15:09:23 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
// EventBreakpointResolved fired when breakpoint is resolved to an actual
|
|
|
|
// script and location.
|
|
|
|
type EventBreakpointResolved struct {
|
2017-07-02 11:44:34 +00:00
|
|
|
BreakpointID BreakpointID `json:"breakpointId"` // Breakpoint unique identifier.
|
|
|
|
Location *Location `json:"location"` // Actual breakpoint location.
|
2017-01-24 15:09:23 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
// EventPaused fired when the virtual machine stopped on breakpoint or
|
|
|
|
// exception or any other stop criteria.
|
|
|
|
type EventPaused struct {
|
2017-07-02 11:44:34 +00:00
|
|
|
CallFrames []*CallFrame `json:"callFrames"` // Call stack the virtual machine stopped on.
|
|
|
|
Reason PausedReason `json:"reason"` // Pause reason.
|
2017-01-24 15:09:23 +00:00
|
|
|
Data easyjson.RawMessage `json:"data,omitempty"`
|
|
|
|
HitBreakpoints []string `json:"hitBreakpoints,omitempty"` // Hit breakpoints IDs
|
|
|
|
AsyncStackTrace *runtime.StackTrace `json:"asyncStackTrace,omitempty"` // Async stack trace, if any.
|
|
|
|
}
|
|
|
|
|
|
|
|
// EventResumed fired when the virtual machine resumed execution.
|
|
|
|
type EventResumed struct{}
|
|
|
|
|
2017-01-26 07:28:34 +00:00
|
|
|
// EventTypes all event types in the domain.
|
|
|
|
var EventTypes = []cdp.MethodType{
|
|
|
|
cdp.EventDebuggerScriptParsed,
|
|
|
|
cdp.EventDebuggerScriptFailedToParse,
|
|
|
|
cdp.EventDebuggerBreakpointResolved,
|
|
|
|
cdp.EventDebuggerPaused,
|
|
|
|
cdp.EventDebuggerResumed,
|
2017-01-24 15:09:23 +00:00
|
|
|
}
|