Updating to latest protocol.json
This commit is contained in:
parent
4e57103faa
commit
89b40f20af
|
@ -1,7 +1,7 @@
|
||||||
language: go
|
language: go
|
||||||
go:
|
go:
|
||||||
- 1.7
|
|
||||||
- 1.8
|
- 1.8
|
||||||
|
- 1.9
|
||||||
- tip
|
- tip
|
||||||
addons:
|
addons:
|
||||||
apt:
|
apt:
|
||||||
|
|
|
@ -559,7 +559,82 @@ func (v *RequestCacheNamesParams) UnmarshalJSON(data []byte) error {
|
||||||
func (v *RequestCacheNamesParams) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
func (v *RequestCacheNamesParams) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage5(l, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage5(l, v)
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage6(in *jlexer.Lexer, out *DeleteEntryParams) {
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage6(in *jlexer.Lexer, out *Header) {
|
||||||
|
isTopLevel := in.IsStart()
|
||||||
|
if in.IsNull() {
|
||||||
|
if isTopLevel {
|
||||||
|
in.Consumed()
|
||||||
|
}
|
||||||
|
in.Skip()
|
||||||
|
return
|
||||||
|
}
|
||||||
|
in.Delim('{')
|
||||||
|
for !in.IsDelim('}') {
|
||||||
|
key := in.UnsafeString()
|
||||||
|
in.WantColon()
|
||||||
|
if in.IsNull() {
|
||||||
|
in.Skip()
|
||||||
|
in.WantComma()
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
switch key {
|
||||||
|
case "name":
|
||||||
|
out.Name = string(in.String())
|
||||||
|
case "value":
|
||||||
|
out.Value = string(in.String())
|
||||||
|
default:
|
||||||
|
in.SkipRecursive()
|
||||||
|
}
|
||||||
|
in.WantComma()
|
||||||
|
}
|
||||||
|
in.Delim('}')
|
||||||
|
if isTopLevel {
|
||||||
|
in.Consumed()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage6(out *jwriter.Writer, in Header) {
|
||||||
|
out.RawByte('{')
|
||||||
|
first := true
|
||||||
|
_ = first
|
||||||
|
if !first {
|
||||||
|
out.RawByte(',')
|
||||||
|
}
|
||||||
|
first = false
|
||||||
|
out.RawString("\"name\":")
|
||||||
|
out.String(string(in.Name))
|
||||||
|
if !first {
|
||||||
|
out.RawByte(',')
|
||||||
|
}
|
||||||
|
first = false
|
||||||
|
out.RawString("\"value\":")
|
||||||
|
out.String(string(in.Value))
|
||||||
|
out.RawByte('}')
|
||||||
|
}
|
||||||
|
|
||||||
|
// MarshalJSON supports json.Marshaler interface
|
||||||
|
func (v Header) MarshalJSON() ([]byte, error) {
|
||||||
|
w := jwriter.Writer{}
|
||||||
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage6(&w, v)
|
||||||
|
return w.Buffer.BuildBytes(), w.Error
|
||||||
|
}
|
||||||
|
|
||||||
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
||||||
|
func (v Header) MarshalEasyJSON(w *jwriter.Writer) {
|
||||||
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage6(w, v)
|
||||||
|
}
|
||||||
|
|
||||||
|
// UnmarshalJSON supports json.Unmarshaler interface
|
||||||
|
func (v *Header) UnmarshalJSON(data []byte) error {
|
||||||
|
r := jlexer.Lexer{Data: data}
|
||||||
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage6(&r, v)
|
||||||
|
return r.Error()
|
||||||
|
}
|
||||||
|
|
||||||
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
||||||
|
func (v *Header) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
||||||
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage6(l, v)
|
||||||
|
}
|
||||||
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage7(in *jlexer.Lexer, out *DeleteEntryParams) {
|
||||||
isTopLevel := in.IsStart()
|
isTopLevel := in.IsStart()
|
||||||
if in.IsNull() {
|
if in.IsNull() {
|
||||||
if isTopLevel {
|
if isTopLevel {
|
||||||
|
@ -592,7 +667,7 @@ func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage6(in *jlexer.Lexer
|
||||||
in.Consumed()
|
in.Consumed()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage6(out *jwriter.Writer, in DeleteEntryParams) {
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage7(out *jwriter.Writer, in DeleteEntryParams) {
|
||||||
out.RawByte('{')
|
out.RawByte('{')
|
||||||
first := true
|
first := true
|
||||||
_ = first
|
_ = first
|
||||||
|
@ -614,27 +689,27 @@ func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage6(out *jwriter.Wri
|
||||||
// MarshalJSON supports json.Marshaler interface
|
// MarshalJSON supports json.Marshaler interface
|
||||||
func (v DeleteEntryParams) MarshalJSON() ([]byte, error) {
|
func (v DeleteEntryParams) MarshalJSON() ([]byte, error) {
|
||||||
w := jwriter.Writer{}
|
w := jwriter.Writer{}
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage6(&w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage7(&w, v)
|
||||||
return w.Buffer.BuildBytes(), w.Error
|
return w.Buffer.BuildBytes(), w.Error
|
||||||
}
|
}
|
||||||
|
|
||||||
// MarshalEasyJSON supports easyjson.Marshaler interface
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
||||||
func (v DeleteEntryParams) MarshalEasyJSON(w *jwriter.Writer) {
|
func (v DeleteEntryParams) MarshalEasyJSON(w *jwriter.Writer) {
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage6(w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage7(w, v)
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalJSON supports json.Unmarshaler interface
|
// UnmarshalJSON supports json.Unmarshaler interface
|
||||||
func (v *DeleteEntryParams) UnmarshalJSON(data []byte) error {
|
func (v *DeleteEntryParams) UnmarshalJSON(data []byte) error {
|
||||||
r := jlexer.Lexer{Data: data}
|
r := jlexer.Lexer{Data: data}
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage6(&r, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage7(&r, v)
|
||||||
return r.Error()
|
return r.Error()
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
||||||
func (v *DeleteEntryParams) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
func (v *DeleteEntryParams) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage6(l, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage7(l, v)
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage7(in *jlexer.Lexer, out *DeleteCacheParams) {
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage8(in *jlexer.Lexer, out *DeleteCacheParams) {
|
||||||
isTopLevel := in.IsStart()
|
isTopLevel := in.IsStart()
|
||||||
if in.IsNull() {
|
if in.IsNull() {
|
||||||
if isTopLevel {
|
if isTopLevel {
|
||||||
|
@ -665,7 +740,7 @@ func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage7(in *jlexer.Lexer
|
||||||
in.Consumed()
|
in.Consumed()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage7(out *jwriter.Writer, in DeleteCacheParams) {
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage8(out *jwriter.Writer, in DeleteCacheParams) {
|
||||||
out.RawByte('{')
|
out.RawByte('{')
|
||||||
first := true
|
first := true
|
||||||
_ = first
|
_ = first
|
||||||
|
@ -681,27 +756,27 @@ func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage7(out *jwriter.Wri
|
||||||
// MarshalJSON supports json.Marshaler interface
|
// MarshalJSON supports json.Marshaler interface
|
||||||
func (v DeleteCacheParams) MarshalJSON() ([]byte, error) {
|
func (v DeleteCacheParams) MarshalJSON() ([]byte, error) {
|
||||||
w := jwriter.Writer{}
|
w := jwriter.Writer{}
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage7(&w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage8(&w, v)
|
||||||
return w.Buffer.BuildBytes(), w.Error
|
return w.Buffer.BuildBytes(), w.Error
|
||||||
}
|
}
|
||||||
|
|
||||||
// MarshalEasyJSON supports easyjson.Marshaler interface
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
||||||
func (v DeleteCacheParams) MarshalEasyJSON(w *jwriter.Writer) {
|
func (v DeleteCacheParams) MarshalEasyJSON(w *jwriter.Writer) {
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage7(w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage8(w, v)
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalJSON supports json.Unmarshaler interface
|
// UnmarshalJSON supports json.Unmarshaler interface
|
||||||
func (v *DeleteCacheParams) UnmarshalJSON(data []byte) error {
|
func (v *DeleteCacheParams) UnmarshalJSON(data []byte) error {
|
||||||
r := jlexer.Lexer{Data: data}
|
r := jlexer.Lexer{Data: data}
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage7(&r, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage8(&r, v)
|
||||||
return r.Error()
|
return r.Error()
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
||||||
func (v *DeleteCacheParams) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
func (v *DeleteCacheParams) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage7(l, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage8(l, v)
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage8(in *jlexer.Lexer, out *DataEntry) {
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage9(in *jlexer.Lexer, out *DataEntry) {
|
||||||
isTopLevel := in.IsStart()
|
isTopLevel := in.IsStart()
|
||||||
if in.IsNull() {
|
if in.IsNull() {
|
||||||
if isTopLevel {
|
if isTopLevel {
|
||||||
|
@ -720,12 +795,78 @@ func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage8(in *jlexer.Lexer
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
switch key {
|
switch key {
|
||||||
case "request":
|
case "requestURL":
|
||||||
out.Request = string(in.String())
|
out.RequestURL = string(in.String())
|
||||||
case "response":
|
case "requestMethod":
|
||||||
out.Response = string(in.String())
|
out.RequestMethod = string(in.String())
|
||||||
|
case "requestHeaders":
|
||||||
|
if in.IsNull() {
|
||||||
|
in.Skip()
|
||||||
|
out.RequestHeaders = nil
|
||||||
|
} else {
|
||||||
|
in.Delim('[')
|
||||||
|
if out.RequestHeaders == nil {
|
||||||
|
if !in.IsDelim(']') {
|
||||||
|
out.RequestHeaders = make([]*Header, 0, 8)
|
||||||
|
} else {
|
||||||
|
out.RequestHeaders = []*Header{}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
out.RequestHeaders = (out.RequestHeaders)[:0]
|
||||||
|
}
|
||||||
|
for !in.IsDelim(']') {
|
||||||
|
var v7 *Header
|
||||||
|
if in.IsNull() {
|
||||||
|
in.Skip()
|
||||||
|
v7 = nil
|
||||||
|
} else {
|
||||||
|
if v7 == nil {
|
||||||
|
v7 = new(Header)
|
||||||
|
}
|
||||||
|
(*v7).UnmarshalEasyJSON(in)
|
||||||
|
}
|
||||||
|
out.RequestHeaders = append(out.RequestHeaders, v7)
|
||||||
|
in.WantComma()
|
||||||
|
}
|
||||||
|
in.Delim(']')
|
||||||
|
}
|
||||||
case "responseTime":
|
case "responseTime":
|
||||||
out.ResponseTime = float64(in.Float64())
|
out.ResponseTime = float64(in.Float64())
|
||||||
|
case "responseStatus":
|
||||||
|
out.ResponseStatus = int64(in.Int64())
|
||||||
|
case "responseStatusText":
|
||||||
|
out.ResponseStatusText = string(in.String())
|
||||||
|
case "responseHeaders":
|
||||||
|
if in.IsNull() {
|
||||||
|
in.Skip()
|
||||||
|
out.ResponseHeaders = nil
|
||||||
|
} else {
|
||||||
|
in.Delim('[')
|
||||||
|
if out.ResponseHeaders == nil {
|
||||||
|
if !in.IsDelim(']') {
|
||||||
|
out.ResponseHeaders = make([]*Header, 0, 8)
|
||||||
|
} else {
|
||||||
|
out.ResponseHeaders = []*Header{}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
out.ResponseHeaders = (out.ResponseHeaders)[:0]
|
||||||
|
}
|
||||||
|
for !in.IsDelim(']') {
|
||||||
|
var v8 *Header
|
||||||
|
if in.IsNull() {
|
||||||
|
in.Skip()
|
||||||
|
v8 = nil
|
||||||
|
} else {
|
||||||
|
if v8 == nil {
|
||||||
|
v8 = new(Header)
|
||||||
|
}
|
||||||
|
(*v8).UnmarshalEasyJSON(in)
|
||||||
|
}
|
||||||
|
out.ResponseHeaders = append(out.ResponseHeaders, v8)
|
||||||
|
in.WantComma()
|
||||||
|
}
|
||||||
|
in.Delim(']')
|
||||||
|
}
|
||||||
default:
|
default:
|
||||||
in.SkipRecursive()
|
in.SkipRecursive()
|
||||||
}
|
}
|
||||||
|
@ -736,7 +877,7 @@ func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage8(in *jlexer.Lexer
|
||||||
in.Consumed()
|
in.Consumed()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage8(out *jwriter.Writer, in DataEntry) {
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage9(out *jwriter.Writer, in DataEntry) {
|
||||||
out.RawByte('{')
|
out.RawByte('{')
|
||||||
first := true
|
first := true
|
||||||
_ = first
|
_ = first
|
||||||
|
@ -744,47 +885,101 @@ func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage8(out *jwriter.Wri
|
||||||
out.RawByte(',')
|
out.RawByte(',')
|
||||||
}
|
}
|
||||||
first = false
|
first = false
|
||||||
out.RawString("\"request\":")
|
out.RawString("\"requestURL\":")
|
||||||
out.String(string(in.Request))
|
out.String(string(in.RequestURL))
|
||||||
if !first {
|
if !first {
|
||||||
out.RawByte(',')
|
out.RawByte(',')
|
||||||
}
|
}
|
||||||
first = false
|
first = false
|
||||||
out.RawString("\"response\":")
|
out.RawString("\"requestMethod\":")
|
||||||
out.String(string(in.Response))
|
out.String(string(in.RequestMethod))
|
||||||
|
if !first {
|
||||||
|
out.RawByte(',')
|
||||||
|
}
|
||||||
|
first = false
|
||||||
|
out.RawString("\"requestHeaders\":")
|
||||||
|
if in.RequestHeaders == nil && (out.Flags&jwriter.NilSliceAsEmpty) == 0 {
|
||||||
|
out.RawString("null")
|
||||||
|
} else {
|
||||||
|
out.RawByte('[')
|
||||||
|
for v9, v10 := range in.RequestHeaders {
|
||||||
|
if v9 > 0 {
|
||||||
|
out.RawByte(',')
|
||||||
|
}
|
||||||
|
if v10 == nil {
|
||||||
|
out.RawString("null")
|
||||||
|
} else {
|
||||||
|
(*v10).MarshalEasyJSON(out)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
out.RawByte(']')
|
||||||
|
}
|
||||||
if !first {
|
if !first {
|
||||||
out.RawByte(',')
|
out.RawByte(',')
|
||||||
}
|
}
|
||||||
first = false
|
first = false
|
||||||
out.RawString("\"responseTime\":")
|
out.RawString("\"responseTime\":")
|
||||||
out.Float64(float64(in.ResponseTime))
|
out.Float64(float64(in.ResponseTime))
|
||||||
|
if !first {
|
||||||
|
out.RawByte(',')
|
||||||
|
}
|
||||||
|
first = false
|
||||||
|
out.RawString("\"responseStatus\":")
|
||||||
|
out.Int64(int64(in.ResponseStatus))
|
||||||
|
if !first {
|
||||||
|
out.RawByte(',')
|
||||||
|
}
|
||||||
|
first = false
|
||||||
|
out.RawString("\"responseStatusText\":")
|
||||||
|
out.String(string(in.ResponseStatusText))
|
||||||
|
if !first {
|
||||||
|
out.RawByte(',')
|
||||||
|
}
|
||||||
|
first = false
|
||||||
|
out.RawString("\"responseHeaders\":")
|
||||||
|
if in.ResponseHeaders == nil && (out.Flags&jwriter.NilSliceAsEmpty) == 0 {
|
||||||
|
out.RawString("null")
|
||||||
|
} else {
|
||||||
|
out.RawByte('[')
|
||||||
|
for v11, v12 := range in.ResponseHeaders {
|
||||||
|
if v11 > 0 {
|
||||||
|
out.RawByte(',')
|
||||||
|
}
|
||||||
|
if v12 == nil {
|
||||||
|
out.RawString("null")
|
||||||
|
} else {
|
||||||
|
(*v12).MarshalEasyJSON(out)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
out.RawByte(']')
|
||||||
|
}
|
||||||
out.RawByte('}')
|
out.RawByte('}')
|
||||||
}
|
}
|
||||||
|
|
||||||
// MarshalJSON supports json.Marshaler interface
|
// MarshalJSON supports json.Marshaler interface
|
||||||
func (v DataEntry) MarshalJSON() ([]byte, error) {
|
func (v DataEntry) MarshalJSON() ([]byte, error) {
|
||||||
w := jwriter.Writer{}
|
w := jwriter.Writer{}
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage8(&w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage9(&w, v)
|
||||||
return w.Buffer.BuildBytes(), w.Error
|
return w.Buffer.BuildBytes(), w.Error
|
||||||
}
|
}
|
||||||
|
|
||||||
// MarshalEasyJSON supports easyjson.Marshaler interface
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
||||||
func (v DataEntry) MarshalEasyJSON(w *jwriter.Writer) {
|
func (v DataEntry) MarshalEasyJSON(w *jwriter.Writer) {
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage8(w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage9(w, v)
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalJSON supports json.Unmarshaler interface
|
// UnmarshalJSON supports json.Unmarshaler interface
|
||||||
func (v *DataEntry) UnmarshalJSON(data []byte) error {
|
func (v *DataEntry) UnmarshalJSON(data []byte) error {
|
||||||
r := jlexer.Lexer{Data: data}
|
r := jlexer.Lexer{Data: data}
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage8(&r, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage9(&r, v)
|
||||||
return r.Error()
|
return r.Error()
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
||||||
func (v *DataEntry) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
func (v *DataEntry) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage8(l, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage9(l, v)
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage9(in *jlexer.Lexer, out *CachedResponse) {
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage10(in *jlexer.Lexer, out *CachedResponse) {
|
||||||
isTopLevel := in.IsStart()
|
isTopLevel := in.IsStart()
|
||||||
if in.IsNull() {
|
if in.IsNull() {
|
||||||
if isTopLevel {
|
if isTopLevel {
|
||||||
|
@ -803,8 +998,6 @@ func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage9(in *jlexer.Lexer
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
switch key {
|
switch key {
|
||||||
case "headers":
|
|
||||||
(out.Headers).UnmarshalEasyJSON(in)
|
|
||||||
case "body":
|
case "body":
|
||||||
out.Body = string(in.String())
|
out.Body = string(in.String())
|
||||||
default:
|
default:
|
||||||
|
@ -817,7 +1010,7 @@ func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage9(in *jlexer.Lexer
|
||||||
in.Consumed()
|
in.Consumed()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage9(out *jwriter.Writer, in CachedResponse) {
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage10(out *jwriter.Writer, in CachedResponse) {
|
||||||
out.RawByte('{')
|
out.RawByte('{')
|
||||||
first := true
|
first := true
|
||||||
_ = first
|
_ = first
|
||||||
|
@ -825,12 +1018,6 @@ func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage9(out *jwriter.Wri
|
||||||
out.RawByte(',')
|
out.RawByte(',')
|
||||||
}
|
}
|
||||||
first = false
|
first = false
|
||||||
out.RawString("\"headers\":")
|
|
||||||
(in.Headers).MarshalEasyJSON(out)
|
|
||||||
if !first {
|
|
||||||
out.RawByte(',')
|
|
||||||
}
|
|
||||||
first = false
|
|
||||||
out.RawString("\"body\":")
|
out.RawString("\"body\":")
|
||||||
out.String(string(in.Body))
|
out.String(string(in.Body))
|
||||||
out.RawByte('}')
|
out.RawByte('}')
|
||||||
|
@ -839,27 +1026,27 @@ func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage9(out *jwriter.Wri
|
||||||
// MarshalJSON supports json.Marshaler interface
|
// MarshalJSON supports json.Marshaler interface
|
||||||
func (v CachedResponse) MarshalJSON() ([]byte, error) {
|
func (v CachedResponse) MarshalJSON() ([]byte, error) {
|
||||||
w := jwriter.Writer{}
|
w := jwriter.Writer{}
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage9(&w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage10(&w, v)
|
||||||
return w.Buffer.BuildBytes(), w.Error
|
return w.Buffer.BuildBytes(), w.Error
|
||||||
}
|
}
|
||||||
|
|
||||||
// MarshalEasyJSON supports easyjson.Marshaler interface
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
||||||
func (v CachedResponse) MarshalEasyJSON(w *jwriter.Writer) {
|
func (v CachedResponse) MarshalEasyJSON(w *jwriter.Writer) {
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage9(w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage10(w, v)
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalJSON supports json.Unmarshaler interface
|
// UnmarshalJSON supports json.Unmarshaler interface
|
||||||
func (v *CachedResponse) UnmarshalJSON(data []byte) error {
|
func (v *CachedResponse) UnmarshalJSON(data []byte) error {
|
||||||
r := jlexer.Lexer{Data: data}
|
r := jlexer.Lexer{Data: data}
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage9(&r, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage10(&r, v)
|
||||||
return r.Error()
|
return r.Error()
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
||||||
func (v *CachedResponse) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
func (v *CachedResponse) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage9(l, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage10(l, v)
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage10(in *jlexer.Lexer, out *Cache) {
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage11(in *jlexer.Lexer, out *Cache) {
|
||||||
isTopLevel := in.IsStart()
|
isTopLevel := in.IsStart()
|
||||||
if in.IsNull() {
|
if in.IsNull() {
|
||||||
if isTopLevel {
|
if isTopLevel {
|
||||||
|
@ -894,7 +1081,7 @@ func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage10(in *jlexer.Lexe
|
||||||
in.Consumed()
|
in.Consumed()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage10(out *jwriter.Writer, in Cache) {
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage11(out *jwriter.Writer, in Cache) {
|
||||||
out.RawByte('{')
|
out.RawByte('{')
|
||||||
first := true
|
first := true
|
||||||
_ = first
|
_ = first
|
||||||
|
@ -922,23 +1109,23 @@ func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage10(out *jwriter.Wr
|
||||||
// MarshalJSON supports json.Marshaler interface
|
// MarshalJSON supports json.Marshaler interface
|
||||||
func (v Cache) MarshalJSON() ([]byte, error) {
|
func (v Cache) MarshalJSON() ([]byte, error) {
|
||||||
w := jwriter.Writer{}
|
w := jwriter.Writer{}
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage10(&w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage11(&w, v)
|
||||||
return w.Buffer.BuildBytes(), w.Error
|
return w.Buffer.BuildBytes(), w.Error
|
||||||
}
|
}
|
||||||
|
|
||||||
// MarshalEasyJSON supports easyjson.Marshaler interface
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
||||||
func (v Cache) MarshalEasyJSON(w *jwriter.Writer) {
|
func (v Cache) MarshalEasyJSON(w *jwriter.Writer) {
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage10(w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpCachestorage11(w, v)
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalJSON supports json.Unmarshaler interface
|
// UnmarshalJSON supports json.Unmarshaler interface
|
||||||
func (v *Cache) UnmarshalJSON(data []byte) error {
|
func (v *Cache) UnmarshalJSON(data []byte) error {
|
||||||
r := jlexer.Lexer{Data: data}
|
r := jlexer.Lexer{Data: data}
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage10(&r, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage11(&r, v)
|
||||||
return r.Error()
|
return r.Error()
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
||||||
func (v *Cache) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
func (v *Cache) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage10(l, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpCachestorage11(l, v)
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
package cachestorage
|
package cachestorage
|
||||||
|
|
||||||
import "github.com/mailru/easyjson"
|
|
||||||
|
|
||||||
// Code generated by chromedp-gen. DO NOT EDIT.
|
// Code generated by chromedp-gen. DO NOT EDIT.
|
||||||
|
|
||||||
// CacheID unique identifier of the Cache object.
|
// CacheID unique identifier of the Cache object.
|
||||||
|
@ -14,9 +12,13 @@ func (t CacheID) String() string {
|
||||||
|
|
||||||
// DataEntry data entry.
|
// DataEntry data entry.
|
||||||
type DataEntry struct {
|
type DataEntry struct {
|
||||||
Request string `json:"request"` // Request url spec.
|
RequestURL string `json:"requestURL"` // Request URL.
|
||||||
Response string `json:"response"` // Response status text.
|
RequestMethod string `json:"requestMethod"` // Request method.
|
||||||
|
RequestHeaders []*Header `json:"requestHeaders"` // Request headers
|
||||||
ResponseTime float64 `json:"responseTime"` // Number of seconds since epoch.
|
ResponseTime float64 `json:"responseTime"` // Number of seconds since epoch.
|
||||||
|
ResponseStatus int64 `json:"responseStatus"` // HTTP response status code.
|
||||||
|
ResponseStatusText string `json:"responseStatusText"` // HTTP response status text.
|
||||||
|
ResponseHeaders []*Header `json:"responseHeaders"` // Response headers
|
||||||
}
|
}
|
||||||
|
|
||||||
// Cache cache identifier.
|
// Cache cache identifier.
|
||||||
|
@ -26,8 +28,13 @@ type Cache struct {
|
||||||
CacheName string `json:"cacheName"` // The name of the cache.
|
CacheName string `json:"cacheName"` // The name of the cache.
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Header [no description].
|
||||||
|
type Header struct {
|
||||||
|
Name string `json:"name"`
|
||||||
|
Value string `json:"value"`
|
||||||
|
}
|
||||||
|
|
||||||
// CachedResponse cached response.
|
// CachedResponse cached response.
|
||||||
type CachedResponse struct {
|
type CachedResponse struct {
|
||||||
Headers easyjson.RawMessage `json:"headers"`
|
|
||||||
Body string `json:"body"` // Entry content, base64-encoded.
|
Body string `json:"body"` // Entry content, base64-encoded.
|
||||||
}
|
}
|
||||||
|
|
|
@ -125,6 +125,7 @@ const (
|
||||||
CommandOverlayHideHighlight MethodType = "Overlay.hideHighlight"
|
CommandOverlayHideHighlight MethodType = "Overlay.hideHighlight"
|
||||||
CommandOverlayGetHighlightObjectForTest MethodType = "Overlay.getHighlightObjectForTest"
|
CommandOverlayGetHighlightObjectForTest MethodType = "Overlay.getHighlightObjectForTest"
|
||||||
EventEmulationVirtualTimeBudgetExpired MethodType = "Emulation.virtualTimeBudgetExpired"
|
EventEmulationVirtualTimeBudgetExpired MethodType = "Emulation.virtualTimeBudgetExpired"
|
||||||
|
EventEmulationVirtualTimePaused MethodType = "Emulation.virtualTimePaused"
|
||||||
CommandEmulationSetDeviceMetricsOverride MethodType = "Emulation.setDeviceMetricsOverride"
|
CommandEmulationSetDeviceMetricsOverride MethodType = "Emulation.setDeviceMetricsOverride"
|
||||||
CommandEmulationClearDeviceMetricsOverride MethodType = "Emulation.clearDeviceMetricsOverride"
|
CommandEmulationClearDeviceMetricsOverride MethodType = "Emulation.clearDeviceMetricsOverride"
|
||||||
CommandEmulationResetPageScaleFactor MethodType = "Emulation.resetPageScaleFactor"
|
CommandEmulationResetPageScaleFactor MethodType = "Emulation.resetPageScaleFactor"
|
||||||
|
@ -652,6 +653,8 @@ func (t *MethodType) UnmarshalEasyJSON(in *jlexer.Lexer) {
|
||||||
*t = CommandOverlayGetHighlightObjectForTest
|
*t = CommandOverlayGetHighlightObjectForTest
|
||||||
case EventEmulationVirtualTimeBudgetExpired:
|
case EventEmulationVirtualTimeBudgetExpired:
|
||||||
*t = EventEmulationVirtualTimeBudgetExpired
|
*t = EventEmulationVirtualTimeBudgetExpired
|
||||||
|
case EventEmulationVirtualTimePaused:
|
||||||
|
*t = EventEmulationVirtualTimePaused
|
||||||
case CommandEmulationSetDeviceMetricsOverride:
|
case CommandEmulationSetDeviceMetricsOverride:
|
||||||
*t = CommandEmulationSetDeviceMetricsOverride
|
*t = CommandEmulationSetDeviceMetricsOverride
|
||||||
case CommandEmulationClearDeviceMetricsOverride:
|
case CommandEmulationClearDeviceMetricsOverride:
|
||||||
|
|
|
@ -322,6 +322,9 @@ func UnmarshalMessage(msg *cdp.Message) (interface{}, error) {
|
||||||
case cdp.EventEmulationVirtualTimeBudgetExpired:
|
case cdp.EventEmulationVirtualTimeBudgetExpired:
|
||||||
v = new(emulation.EventVirtualTimeBudgetExpired)
|
v = new(emulation.EventVirtualTimeBudgetExpired)
|
||||||
|
|
||||||
|
case cdp.EventEmulationVirtualTimePaused:
|
||||||
|
v = new(emulation.EventVirtualTimePaused)
|
||||||
|
|
||||||
case cdp.CommandSecurityEnable:
|
case cdp.CommandSecurityEnable:
|
||||||
return emptyVal, nil
|
return emptyVal, nil
|
||||||
|
|
||||||
|
|
|
@ -994,7 +994,74 @@ func (v *ResetPageScaleFactorParams) UnmarshalJSON(data []byte) error {
|
||||||
func (v *ResetPageScaleFactorParams) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
func (v *ResetPageScaleFactorParams) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation11(l, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation11(l, v)
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation12(in *jlexer.Lexer, out *EventVirtualTimeBudgetExpired) {
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation12(in *jlexer.Lexer, out *EventVirtualTimePaused) {
|
||||||
|
isTopLevel := in.IsStart()
|
||||||
|
if in.IsNull() {
|
||||||
|
if isTopLevel {
|
||||||
|
in.Consumed()
|
||||||
|
}
|
||||||
|
in.Skip()
|
||||||
|
return
|
||||||
|
}
|
||||||
|
in.Delim('{')
|
||||||
|
for !in.IsDelim('}') {
|
||||||
|
key := in.UnsafeString()
|
||||||
|
in.WantColon()
|
||||||
|
if in.IsNull() {
|
||||||
|
in.Skip()
|
||||||
|
in.WantComma()
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
switch key {
|
||||||
|
case "virtualTimeElapsed":
|
||||||
|
out.VirtualTimeElapsed = int64(in.Int64())
|
||||||
|
default:
|
||||||
|
in.SkipRecursive()
|
||||||
|
}
|
||||||
|
in.WantComma()
|
||||||
|
}
|
||||||
|
in.Delim('}')
|
||||||
|
if isTopLevel {
|
||||||
|
in.Consumed()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation12(out *jwriter.Writer, in EventVirtualTimePaused) {
|
||||||
|
out.RawByte('{')
|
||||||
|
first := true
|
||||||
|
_ = first
|
||||||
|
if !first {
|
||||||
|
out.RawByte(',')
|
||||||
|
}
|
||||||
|
first = false
|
||||||
|
out.RawString("\"virtualTimeElapsed\":")
|
||||||
|
out.Int64(int64(in.VirtualTimeElapsed))
|
||||||
|
out.RawByte('}')
|
||||||
|
}
|
||||||
|
|
||||||
|
// MarshalJSON supports json.Marshaler interface
|
||||||
|
func (v EventVirtualTimePaused) MarshalJSON() ([]byte, error) {
|
||||||
|
w := jwriter.Writer{}
|
||||||
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation12(&w, v)
|
||||||
|
return w.Buffer.BuildBytes(), w.Error
|
||||||
|
}
|
||||||
|
|
||||||
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
||||||
|
func (v EventVirtualTimePaused) MarshalEasyJSON(w *jwriter.Writer) {
|
||||||
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation12(w, v)
|
||||||
|
}
|
||||||
|
|
||||||
|
// UnmarshalJSON supports json.Unmarshaler interface
|
||||||
|
func (v *EventVirtualTimePaused) UnmarshalJSON(data []byte) error {
|
||||||
|
r := jlexer.Lexer{Data: data}
|
||||||
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation12(&r, v)
|
||||||
|
return r.Error()
|
||||||
|
}
|
||||||
|
|
||||||
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
||||||
|
func (v *EventVirtualTimePaused) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
||||||
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation12(l, v)
|
||||||
|
}
|
||||||
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation13(in *jlexer.Lexer, out *EventVirtualTimeBudgetExpired) {
|
||||||
isTopLevel := in.IsStart()
|
isTopLevel := in.IsStart()
|
||||||
if in.IsNull() {
|
if in.IsNull() {
|
||||||
if isTopLevel {
|
if isTopLevel {
|
||||||
|
@ -1023,7 +1090,7 @@ func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation12(in *jlexer.Lexer,
|
||||||
in.Consumed()
|
in.Consumed()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation12(out *jwriter.Writer, in EventVirtualTimeBudgetExpired) {
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation13(out *jwriter.Writer, in EventVirtualTimeBudgetExpired) {
|
||||||
out.RawByte('{')
|
out.RawByte('{')
|
||||||
first := true
|
first := true
|
||||||
_ = first
|
_ = first
|
||||||
|
@ -1033,27 +1100,27 @@ func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation12(out *jwriter.Write
|
||||||
// MarshalJSON supports json.Marshaler interface
|
// MarshalJSON supports json.Marshaler interface
|
||||||
func (v EventVirtualTimeBudgetExpired) MarshalJSON() ([]byte, error) {
|
func (v EventVirtualTimeBudgetExpired) MarshalJSON() ([]byte, error) {
|
||||||
w := jwriter.Writer{}
|
w := jwriter.Writer{}
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation12(&w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation13(&w, v)
|
||||||
return w.Buffer.BuildBytes(), w.Error
|
return w.Buffer.BuildBytes(), w.Error
|
||||||
}
|
}
|
||||||
|
|
||||||
// MarshalEasyJSON supports easyjson.Marshaler interface
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
||||||
func (v EventVirtualTimeBudgetExpired) MarshalEasyJSON(w *jwriter.Writer) {
|
func (v EventVirtualTimeBudgetExpired) MarshalEasyJSON(w *jwriter.Writer) {
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation12(w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation13(w, v)
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalJSON supports json.Unmarshaler interface
|
// UnmarshalJSON supports json.Unmarshaler interface
|
||||||
func (v *EventVirtualTimeBudgetExpired) UnmarshalJSON(data []byte) error {
|
func (v *EventVirtualTimeBudgetExpired) UnmarshalJSON(data []byte) error {
|
||||||
r := jlexer.Lexer{Data: data}
|
r := jlexer.Lexer{Data: data}
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation12(&r, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation13(&r, v)
|
||||||
return r.Error()
|
return r.Error()
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
||||||
func (v *EventVirtualTimeBudgetExpired) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
func (v *EventVirtualTimeBudgetExpired) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation12(l, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation13(l, v)
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation13(in *jlexer.Lexer, out *ClearGeolocationOverrideParams) {
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation14(in *jlexer.Lexer, out *ClearGeolocationOverrideParams) {
|
||||||
isTopLevel := in.IsStart()
|
isTopLevel := in.IsStart()
|
||||||
if in.IsNull() {
|
if in.IsNull() {
|
||||||
if isTopLevel {
|
if isTopLevel {
|
||||||
|
@ -1082,7 +1149,7 @@ func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation13(in *jlexer.Lexer,
|
||||||
in.Consumed()
|
in.Consumed()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation13(out *jwriter.Writer, in ClearGeolocationOverrideParams) {
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation14(out *jwriter.Writer, in ClearGeolocationOverrideParams) {
|
||||||
out.RawByte('{')
|
out.RawByte('{')
|
||||||
first := true
|
first := true
|
||||||
_ = first
|
_ = first
|
||||||
|
@ -1092,27 +1159,27 @@ func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation13(out *jwriter.Write
|
||||||
// MarshalJSON supports json.Marshaler interface
|
// MarshalJSON supports json.Marshaler interface
|
||||||
func (v ClearGeolocationOverrideParams) MarshalJSON() ([]byte, error) {
|
func (v ClearGeolocationOverrideParams) MarshalJSON() ([]byte, error) {
|
||||||
w := jwriter.Writer{}
|
w := jwriter.Writer{}
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation13(&w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation14(&w, v)
|
||||||
return w.Buffer.BuildBytes(), w.Error
|
return w.Buffer.BuildBytes(), w.Error
|
||||||
}
|
}
|
||||||
|
|
||||||
// MarshalEasyJSON supports easyjson.Marshaler interface
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
||||||
func (v ClearGeolocationOverrideParams) MarshalEasyJSON(w *jwriter.Writer) {
|
func (v ClearGeolocationOverrideParams) MarshalEasyJSON(w *jwriter.Writer) {
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation13(w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation14(w, v)
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalJSON supports json.Unmarshaler interface
|
// UnmarshalJSON supports json.Unmarshaler interface
|
||||||
func (v *ClearGeolocationOverrideParams) UnmarshalJSON(data []byte) error {
|
func (v *ClearGeolocationOverrideParams) UnmarshalJSON(data []byte) error {
|
||||||
r := jlexer.Lexer{Data: data}
|
r := jlexer.Lexer{Data: data}
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation13(&r, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation14(&r, v)
|
||||||
return r.Error()
|
return r.Error()
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
||||||
func (v *ClearGeolocationOverrideParams) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
func (v *ClearGeolocationOverrideParams) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation13(l, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation14(l, v)
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation14(in *jlexer.Lexer, out *ClearDeviceMetricsOverrideParams) {
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation15(in *jlexer.Lexer, out *ClearDeviceMetricsOverrideParams) {
|
||||||
isTopLevel := in.IsStart()
|
isTopLevel := in.IsStart()
|
||||||
if in.IsNull() {
|
if in.IsNull() {
|
||||||
if isTopLevel {
|
if isTopLevel {
|
||||||
|
@ -1141,7 +1208,7 @@ func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation14(in *jlexer.Lexer,
|
||||||
in.Consumed()
|
in.Consumed()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation14(out *jwriter.Writer, in ClearDeviceMetricsOverrideParams) {
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation15(out *jwriter.Writer, in ClearDeviceMetricsOverrideParams) {
|
||||||
out.RawByte('{')
|
out.RawByte('{')
|
||||||
first := true
|
first := true
|
||||||
_ = first
|
_ = first
|
||||||
|
@ -1151,27 +1218,27 @@ func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation14(out *jwriter.Write
|
||||||
// MarshalJSON supports json.Marshaler interface
|
// MarshalJSON supports json.Marshaler interface
|
||||||
func (v ClearDeviceMetricsOverrideParams) MarshalJSON() ([]byte, error) {
|
func (v ClearDeviceMetricsOverrideParams) MarshalJSON() ([]byte, error) {
|
||||||
w := jwriter.Writer{}
|
w := jwriter.Writer{}
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation14(&w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation15(&w, v)
|
||||||
return w.Buffer.BuildBytes(), w.Error
|
return w.Buffer.BuildBytes(), w.Error
|
||||||
}
|
}
|
||||||
|
|
||||||
// MarshalEasyJSON supports easyjson.Marshaler interface
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
||||||
func (v ClearDeviceMetricsOverrideParams) MarshalEasyJSON(w *jwriter.Writer) {
|
func (v ClearDeviceMetricsOverrideParams) MarshalEasyJSON(w *jwriter.Writer) {
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation14(w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation15(w, v)
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalJSON supports json.Unmarshaler interface
|
// UnmarshalJSON supports json.Unmarshaler interface
|
||||||
func (v *ClearDeviceMetricsOverrideParams) UnmarshalJSON(data []byte) error {
|
func (v *ClearDeviceMetricsOverrideParams) UnmarshalJSON(data []byte) error {
|
||||||
r := jlexer.Lexer{Data: data}
|
r := jlexer.Lexer{Data: data}
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation14(&r, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation15(&r, v)
|
||||||
return r.Error()
|
return r.Error()
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
||||||
func (v *ClearDeviceMetricsOverrideParams) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
func (v *ClearDeviceMetricsOverrideParams) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation14(l, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation15(l, v)
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation15(in *jlexer.Lexer, out *CanEmulateReturns) {
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation16(in *jlexer.Lexer, out *CanEmulateReturns) {
|
||||||
isTopLevel := in.IsStart()
|
isTopLevel := in.IsStart()
|
||||||
if in.IsNull() {
|
if in.IsNull() {
|
||||||
if isTopLevel {
|
if isTopLevel {
|
||||||
|
@ -1202,7 +1269,7 @@ func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation15(in *jlexer.Lexer,
|
||||||
in.Consumed()
|
in.Consumed()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation15(out *jwriter.Writer, in CanEmulateReturns) {
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation16(out *jwriter.Writer, in CanEmulateReturns) {
|
||||||
out.RawByte('{')
|
out.RawByte('{')
|
||||||
first := true
|
first := true
|
||||||
_ = first
|
_ = first
|
||||||
|
@ -1220,27 +1287,27 @@ func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation15(out *jwriter.Write
|
||||||
// MarshalJSON supports json.Marshaler interface
|
// MarshalJSON supports json.Marshaler interface
|
||||||
func (v CanEmulateReturns) MarshalJSON() ([]byte, error) {
|
func (v CanEmulateReturns) MarshalJSON() ([]byte, error) {
|
||||||
w := jwriter.Writer{}
|
w := jwriter.Writer{}
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation15(&w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation16(&w, v)
|
||||||
return w.Buffer.BuildBytes(), w.Error
|
return w.Buffer.BuildBytes(), w.Error
|
||||||
}
|
}
|
||||||
|
|
||||||
// MarshalEasyJSON supports easyjson.Marshaler interface
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
||||||
func (v CanEmulateReturns) MarshalEasyJSON(w *jwriter.Writer) {
|
func (v CanEmulateReturns) MarshalEasyJSON(w *jwriter.Writer) {
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation15(w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation16(w, v)
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalJSON supports json.Unmarshaler interface
|
// UnmarshalJSON supports json.Unmarshaler interface
|
||||||
func (v *CanEmulateReturns) UnmarshalJSON(data []byte) error {
|
func (v *CanEmulateReturns) UnmarshalJSON(data []byte) error {
|
||||||
r := jlexer.Lexer{Data: data}
|
r := jlexer.Lexer{Data: data}
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation15(&r, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation16(&r, v)
|
||||||
return r.Error()
|
return r.Error()
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
||||||
func (v *CanEmulateReturns) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
func (v *CanEmulateReturns) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation15(l, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation16(l, v)
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation16(in *jlexer.Lexer, out *CanEmulateParams) {
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation17(in *jlexer.Lexer, out *CanEmulateParams) {
|
||||||
isTopLevel := in.IsStart()
|
isTopLevel := in.IsStart()
|
||||||
if in.IsNull() {
|
if in.IsNull() {
|
||||||
if isTopLevel {
|
if isTopLevel {
|
||||||
|
@ -1269,7 +1336,7 @@ func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation16(in *jlexer.Lexer,
|
||||||
in.Consumed()
|
in.Consumed()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation16(out *jwriter.Writer, in CanEmulateParams) {
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation17(out *jwriter.Writer, in CanEmulateParams) {
|
||||||
out.RawByte('{')
|
out.RawByte('{')
|
||||||
first := true
|
first := true
|
||||||
_ = first
|
_ = first
|
||||||
|
@ -1279,23 +1346,23 @@ func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation16(out *jwriter.Write
|
||||||
// MarshalJSON supports json.Marshaler interface
|
// MarshalJSON supports json.Marshaler interface
|
||||||
func (v CanEmulateParams) MarshalJSON() ([]byte, error) {
|
func (v CanEmulateParams) MarshalJSON() ([]byte, error) {
|
||||||
w := jwriter.Writer{}
|
w := jwriter.Writer{}
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation16(&w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation17(&w, v)
|
||||||
return w.Buffer.BuildBytes(), w.Error
|
return w.Buffer.BuildBytes(), w.Error
|
||||||
}
|
}
|
||||||
|
|
||||||
// MarshalEasyJSON supports easyjson.Marshaler interface
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
||||||
func (v CanEmulateParams) MarshalEasyJSON(w *jwriter.Writer) {
|
func (v CanEmulateParams) MarshalEasyJSON(w *jwriter.Writer) {
|
||||||
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation16(w, v)
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpEmulation17(w, v)
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalJSON supports json.Unmarshaler interface
|
// UnmarshalJSON supports json.Unmarshaler interface
|
||||||
func (v *CanEmulateParams) UnmarshalJSON(data []byte) error {
|
func (v *CanEmulateParams) UnmarshalJSON(data []byte) error {
|
||||||
r := jlexer.Lexer{Data: data}
|
r := jlexer.Lexer{Data: data}
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation16(&r, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation17(&r, v)
|
||||||
return r.Error()
|
return r.Error()
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
||||||
func (v *CanEmulateParams) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
func (v *CanEmulateParams) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
||||||
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation16(l, v)
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpEmulation17(l, v)
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,11 +6,18 @@ import (
|
||||||
cdp "github.com/knq/chromedp/cdp"
|
cdp "github.com/knq/chromedp/cdp"
|
||||||
)
|
)
|
||||||
|
|
||||||
// EventVirtualTimeBudgetExpired notification sent after the virual time
|
// EventVirtualTimeBudgetExpired notification sent after the virtual time
|
||||||
// budget for the current VirtualTimePolicy has run out.
|
// budget for the current VirtualTimePolicy has run out.
|
||||||
type EventVirtualTimeBudgetExpired struct{}
|
type EventVirtualTimeBudgetExpired struct{}
|
||||||
|
|
||||||
|
// EventVirtualTimePaused notification sent after the virtual time has
|
||||||
|
// paused.
|
||||||
|
type EventVirtualTimePaused struct {
|
||||||
|
VirtualTimeElapsed int64 `json:"virtualTimeElapsed"` // The amount of virtual time that has elapsed in milliseconds since virtual time was first enabled.
|
||||||
|
}
|
||||||
|
|
||||||
// EventTypes all event types in the domain.
|
// EventTypes all event types in the domain.
|
||||||
var EventTypes = []cdp.MethodType{
|
var EventTypes = []cdp.MethodType{
|
||||||
cdp.EventEmulationVirtualTimeBudgetExpired,
|
cdp.EventEmulationVirtualTimeBudgetExpired,
|
||||||
|
cdp.EventEmulationVirtualTimePaused,
|
||||||
}
|
}
|
||||||
|
|
|
@ -3733,10 +3733,10 @@ func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpRuntime35(in *jlexer.Lexer, ou
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
switch key {
|
switch key {
|
||||||
case "objectId":
|
|
||||||
out.ObjectID = RemoteObjectID(in.String())
|
|
||||||
case "functionDeclaration":
|
case "functionDeclaration":
|
||||||
out.FunctionDeclaration = string(in.String())
|
out.FunctionDeclaration = string(in.String())
|
||||||
|
case "objectId":
|
||||||
|
out.ObjectID = RemoteObjectID(in.String())
|
||||||
case "arguments":
|
case "arguments":
|
||||||
if in.IsNull() {
|
if in.IsNull() {
|
||||||
in.Skip()
|
in.Skip()
|
||||||
|
@ -3778,6 +3778,10 @@ func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpRuntime35(in *jlexer.Lexer, ou
|
||||||
out.UserGesture = bool(in.Bool())
|
out.UserGesture = bool(in.Bool())
|
||||||
case "awaitPromise":
|
case "awaitPromise":
|
||||||
out.AwaitPromise = bool(in.Bool())
|
out.AwaitPromise = bool(in.Bool())
|
||||||
|
case "executionContextId":
|
||||||
|
out.ExecutionContextID = ExecutionContextID(in.Int64())
|
||||||
|
case "objectGroup":
|
||||||
|
out.ObjectGroup = string(in.String())
|
||||||
default:
|
default:
|
||||||
in.SkipRecursive()
|
in.SkipRecursive()
|
||||||
}
|
}
|
||||||
|
@ -3796,14 +3800,16 @@ func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpRuntime35(out *jwriter.Writer,
|
||||||
out.RawByte(',')
|
out.RawByte(',')
|
||||||
}
|
}
|
||||||
first = false
|
first = false
|
||||||
out.RawString("\"objectId\":")
|
out.RawString("\"functionDeclaration\":")
|
||||||
out.String(string(in.ObjectID))
|
out.String(string(in.FunctionDeclaration))
|
||||||
|
if in.ObjectID != "" {
|
||||||
if !first {
|
if !first {
|
||||||
out.RawByte(',')
|
out.RawByte(',')
|
||||||
}
|
}
|
||||||
first = false
|
first = false
|
||||||
out.RawString("\"functionDeclaration\":")
|
out.RawString("\"objectId\":")
|
||||||
out.String(string(in.FunctionDeclaration))
|
out.String(string(in.ObjectID))
|
||||||
|
}
|
||||||
if len(in.Arguments) != 0 {
|
if len(in.Arguments) != 0 {
|
||||||
if !first {
|
if !first {
|
||||||
out.RawByte(',')
|
out.RawByte(',')
|
||||||
|
@ -3867,6 +3873,22 @@ func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpRuntime35(out *jwriter.Writer,
|
||||||
out.RawString("\"awaitPromise\":")
|
out.RawString("\"awaitPromise\":")
|
||||||
out.Bool(bool(in.AwaitPromise))
|
out.Bool(bool(in.AwaitPromise))
|
||||||
}
|
}
|
||||||
|
if in.ExecutionContextID != 0 {
|
||||||
|
if !first {
|
||||||
|
out.RawByte(',')
|
||||||
|
}
|
||||||
|
first = false
|
||||||
|
out.RawString("\"executionContextId\":")
|
||||||
|
out.Int64(int64(in.ExecutionContextID))
|
||||||
|
}
|
||||||
|
if in.ObjectGroup != "" {
|
||||||
|
if !first {
|
||||||
|
out.RawByte(',')
|
||||||
|
}
|
||||||
|
first = false
|
||||||
|
out.RawString("\"objectGroup\":")
|
||||||
|
out.String(string(in.ObjectGroup))
|
||||||
|
}
|
||||||
out.RawByte('}')
|
out.RawByte('}')
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -177,29 +177,36 @@ func (p *AwaitPromiseParams) Do(ctxt context.Context, h cdp.Handler) (result *Re
|
||||||
// CallFunctionOnParams calls function with given declaration on the given
|
// CallFunctionOnParams calls function with given declaration on the given
|
||||||
// object. Object group of the result is inherited from the target object.
|
// object. Object group of the result is inherited from the target object.
|
||||||
type CallFunctionOnParams struct {
|
type CallFunctionOnParams struct {
|
||||||
ObjectID RemoteObjectID `json:"objectId"` // Identifier of the object to call function on.
|
|
||||||
FunctionDeclaration string `json:"functionDeclaration"` // Declaration of the function to call.
|
FunctionDeclaration string `json:"functionDeclaration"` // Declaration of the function to call.
|
||||||
|
ObjectID RemoteObjectID `json:"objectId,omitempty"` // Identifier of the object to call function on. Either objectId or executionContextId should be specified.
|
||||||
Arguments []*CallArgument `json:"arguments,omitempty"` // Call arguments. All call arguments must belong to the same JavaScript world as the target object.
|
Arguments []*CallArgument `json:"arguments,omitempty"` // Call arguments. All call arguments must belong to the same JavaScript world as the target object.
|
||||||
Silent bool `json:"silent,omitempty"` // In silent mode exceptions thrown during evaluation are not reported and do not pause execution. Overrides setPauseOnException state.
|
Silent bool `json:"silent,omitempty"` // In silent mode exceptions thrown during evaluation are not reported and do not pause execution. Overrides setPauseOnException state.
|
||||||
ReturnByValue bool `json:"returnByValue,omitempty"` // Whether the result is expected to be a JSON object which should be sent by value.
|
ReturnByValue bool `json:"returnByValue,omitempty"` // Whether the result is expected to be a JSON object which should be sent by value.
|
||||||
GeneratePreview bool `json:"generatePreview,omitempty"` // Whether preview should be generated for the result.
|
GeneratePreview bool `json:"generatePreview,omitempty"` // Whether preview should be generated for the result.
|
||||||
UserGesture bool `json:"userGesture,omitempty"` // Whether execution should be treated as initiated by user in the UI.
|
UserGesture bool `json:"userGesture,omitempty"` // Whether execution should be treated as initiated by user in the UI.
|
||||||
AwaitPromise bool `json:"awaitPromise,omitempty"` // Whether execution should await for resulting value and return once awaited promise is resolved.
|
AwaitPromise bool `json:"awaitPromise,omitempty"` // Whether execution should await for resulting value and return once awaited promise is resolved.
|
||||||
|
ExecutionContextID ExecutionContextID `json:"executionContextId,omitempty"` // Specifies execution context which global object will be used to call function on. Either executionContextId or objectId should be specified.
|
||||||
|
ObjectGroup string `json:"objectGroup,omitempty"` // Symbolic group name that can be used to release multiple objects. If objectGroup is not specified and objectId is, objectGroup will be inherited from object.
|
||||||
}
|
}
|
||||||
|
|
||||||
// CallFunctionOn calls function with given declaration on the given object.
|
// CallFunctionOn calls function with given declaration on the given object.
|
||||||
// Object group of the result is inherited from the target object.
|
// Object group of the result is inherited from the target object.
|
||||||
//
|
//
|
||||||
// parameters:
|
// parameters:
|
||||||
// objectID - Identifier of the object to call function on.
|
|
||||||
// functionDeclaration - Declaration of the function to call.
|
// functionDeclaration - Declaration of the function to call.
|
||||||
func CallFunctionOn(objectID RemoteObjectID, functionDeclaration string) *CallFunctionOnParams {
|
func CallFunctionOn(functionDeclaration string) *CallFunctionOnParams {
|
||||||
return &CallFunctionOnParams{
|
return &CallFunctionOnParams{
|
||||||
ObjectID: objectID,
|
|
||||||
FunctionDeclaration: functionDeclaration,
|
FunctionDeclaration: functionDeclaration,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// WithObjectID identifier of the object to call function on. Either objectId
|
||||||
|
// or executionContextId should be specified.
|
||||||
|
func (p CallFunctionOnParams) WithObjectID(objectID RemoteObjectID) *CallFunctionOnParams {
|
||||||
|
p.ObjectID = objectID
|
||||||
|
return &p
|
||||||
|
}
|
||||||
|
|
||||||
// WithArguments call arguments. All call arguments must belong to the same
|
// WithArguments call arguments. All call arguments must belong to the same
|
||||||
// JavaScript world as the target object.
|
// JavaScript world as the target object.
|
||||||
func (p CallFunctionOnParams) WithArguments(arguments []*CallArgument) *CallFunctionOnParams {
|
func (p CallFunctionOnParams) WithArguments(arguments []*CallArgument) *CallFunctionOnParams {
|
||||||
|
@ -241,6 +248,22 @@ func (p CallFunctionOnParams) WithAwaitPromise(awaitPromise bool) *CallFunctionO
|
||||||
return &p
|
return &p
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// WithExecutionContextID specifies execution context which global object
|
||||||
|
// will be used to call function on. Either executionContextId or objectId
|
||||||
|
// should be specified.
|
||||||
|
func (p CallFunctionOnParams) WithExecutionContextID(executionContextID ExecutionContextID) *CallFunctionOnParams {
|
||||||
|
p.ExecutionContextID = executionContextID
|
||||||
|
return &p
|
||||||
|
}
|
||||||
|
|
||||||
|
// WithObjectGroup symbolic group name that can be used to release multiple
|
||||||
|
// objects. If objectGroup is not specified and objectId is, objectGroup will be
|
||||||
|
// inherited from object.
|
||||||
|
func (p CallFunctionOnParams) WithObjectGroup(objectGroup string) *CallFunctionOnParams {
|
||||||
|
p.ObjectGroup = objectGroup
|
||||||
|
return &p
|
||||||
|
}
|
||||||
|
|
||||||
// CallFunctionOnReturns return values.
|
// CallFunctionOnReturns return values.
|
||||||
type CallFunctionOnReturns struct {
|
type CallFunctionOnReturns struct {
|
||||||
Result *RemoteObject `json:"result,omitempty"` // Call result.
|
Result *RemoteObject `json:"result,omitempty"` // Call result.
|
||||||
|
|
|
@ -2304,7 +2304,19 @@
|
||||||
{
|
{
|
||||||
"name": "virtualTimeBudgetExpired",
|
"name": "virtualTimeBudgetExpired",
|
||||||
"experimental": true,
|
"experimental": true,
|
||||||
"description": "Notification sent after the virual time budget for the current VirtualTimePolicy has run out."
|
"description": "Notification sent after the virtual time budget for the current VirtualTimePolicy has run out."
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "virtualTimePaused",
|
||||||
|
"experimental": true,
|
||||||
|
"parameters": [
|
||||||
|
{
|
||||||
|
"name": "virtualTimeElapsed",
|
||||||
|
"type": "integer",
|
||||||
|
"description": "The amount of virtual time that has elapsed in milliseconds since virtual time was first enabled."
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"description": "Notification sent after the virtual time has paused."
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
@ -4839,19 +4851,45 @@
|
||||||
"description": "Data entry.",
|
"description": "Data entry.",
|
||||||
"properties": [
|
"properties": [
|
||||||
{
|
{
|
||||||
"name": "request",
|
"name": "requestURL",
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"description": "Request url spec."
|
"description": "Request URL."
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "response",
|
"name": "requestMethod",
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"description": "Response status text."
|
"description": "Request method."
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "requestHeaders",
|
||||||
|
"type": "array",
|
||||||
|
"items": {
|
||||||
|
"$ref": "Header"
|
||||||
|
},
|
||||||
|
"description": "Request headers"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "responseTime",
|
"name": "responseTime",
|
||||||
"type": "number",
|
"type": "number",
|
||||||
"description": "Number of seconds since epoch."
|
"description": "Number of seconds since epoch."
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "responseStatus",
|
||||||
|
"type": "integer",
|
||||||
|
"description": "HTTP response status code."
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "responseStatusText",
|
||||||
|
"type": "string",
|
||||||
|
"description": "HTTP response status text."
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "responseHeaders",
|
||||||
|
"type": "array",
|
||||||
|
"items": {
|
||||||
|
"$ref": "Header"
|
||||||
|
},
|
||||||
|
"description": "Response headers"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
@ -4877,16 +4915,25 @@
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"id": "Header",
|
||||||
|
"type": "object",
|
||||||
|
"properties": [
|
||||||
|
{
|
||||||
|
"name": "name",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "value",
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"id": "CachedResponse",
|
"id": "CachedResponse",
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"description": "Cached response",
|
"description": "Cached response",
|
||||||
"properties": [
|
"properties": [
|
||||||
{
|
|
||||||
"name": "headers",
|
|
||||||
"type": "object",
|
|
||||||
"description": "Response headers"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"name": "body",
|
"name": "body",
|
||||||
"type": "string",
|
"type": "string",
|
||||||
|
@ -12374,16 +12421,17 @@
|
||||||
{
|
{
|
||||||
"name": "callFunctionOn",
|
"name": "callFunctionOn",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
|
||||||
"name": "objectId",
|
|
||||||
"$ref": "RemoteObjectId",
|
|
||||||
"description": "Identifier of the object to call function on."
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"name": "functionDeclaration",
|
"name": "functionDeclaration",
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"description": "Declaration of the function to call."
|
"description": "Declaration of the function to call."
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "objectId",
|
||||||
|
"$ref": "RemoteObjectId",
|
||||||
|
"optional": true,
|
||||||
|
"description": "Identifier of the object to call function on. Either objectId or executionContextId should be specified."
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "arguments",
|
"name": "arguments",
|
||||||
"type": "array",
|
"type": "array",
|
||||||
|
@ -12425,6 +12473,18 @@
|
||||||
"type": "boolean",
|
"type": "boolean",
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"description": "Whether execution should <code>await</code> for resulting value and return once awaited promise is resolved."
|
"description": "Whether execution should <code>await</code> for resulting value and return once awaited promise is resolved."
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "executionContextId",
|
||||||
|
"$ref": "ExecutionContextId",
|
||||||
|
"optional": true,
|
||||||
|
"description": "Specifies execution context which global object will be used to call function on. Either executionContextId or objectId should be specified."
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "objectGroup",
|
||||||
|
"type": "string",
|
||||||
|
"optional": true,
|
||||||
|
"description": "Symbolic group name that can be used to release multiple objects. If objectGroup is not specified and objectId is, objectGroup will be inherited from object."
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"returns": [
|
"returns": [
|
||||||
|
|
Loading…
Reference in New Issue
Block a user