2522 lines
53 KiB
Go
2522 lines
53 KiB
Go
// Code generated by easyjson for marshaling/unmarshaling. DO NOT EDIT.
|
|
|
|
package har
|
|
|
|
import (
|
|
json "encoding/json"
|
|
easyjson "github.com/mailru/easyjson"
|
|
jlexer "github.com/mailru/easyjson/jlexer"
|
|
jwriter "github.com/mailru/easyjson/jwriter"
|
|
)
|
|
|
|
// suppress unused package warning
|
|
var (
|
|
_ *json.RawMessage
|
|
_ *jlexer.Lexer
|
|
_ *jwriter.Writer
|
|
_ easyjson.Marshaler
|
|
)
|
|
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar(in *jlexer.Lexer, out *Timings) {
|
|
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 "blocked":
|
|
out.Blocked = float64(in.Float64())
|
|
case "dns":
|
|
out.DNS = float64(in.Float64())
|
|
case "connect":
|
|
out.Connect = float64(in.Float64())
|
|
case "send":
|
|
out.Send = float64(in.Float64())
|
|
case "wait":
|
|
out.Wait = float64(in.Float64())
|
|
case "receive":
|
|
out.Receive = float64(in.Float64())
|
|
case "ssl":
|
|
out.Ssl = float64(in.Float64())
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar(out *jwriter.Writer, in Timings) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
if in.Blocked != 0 {
|
|
const prefix string = ",\"blocked\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Float64(float64(in.Blocked))
|
|
}
|
|
if in.DNS != 0 {
|
|
const prefix string = ",\"dns\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Float64(float64(in.DNS))
|
|
}
|
|
if in.Connect != 0 {
|
|
const prefix string = ",\"connect\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Float64(float64(in.Connect))
|
|
}
|
|
{
|
|
const prefix string = ",\"send\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Float64(float64(in.Send))
|
|
}
|
|
{
|
|
const prefix string = ",\"wait\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Float64(float64(in.Wait))
|
|
}
|
|
{
|
|
const prefix string = ",\"receive\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Float64(float64(in.Receive))
|
|
}
|
|
if in.Ssl != 0 {
|
|
const prefix string = ",\"ssl\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Float64(float64(in.Ssl))
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v Timings) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v Timings) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *Timings) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *Timings) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar1(in *jlexer.Lexer, out *Response) {
|
|
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 "status":
|
|
out.Status = int64(in.Int64())
|
|
case "statusText":
|
|
out.StatusText = string(in.String())
|
|
case "httpVersion":
|
|
out.HTTPVersion = string(in.String())
|
|
case "cookies":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Cookies = nil
|
|
} else {
|
|
in.Delim('[')
|
|
if out.Cookies == nil {
|
|
if !in.IsDelim(']') {
|
|
out.Cookies = make([]*Cookie, 0, 8)
|
|
} else {
|
|
out.Cookies = []*Cookie{}
|
|
}
|
|
} else {
|
|
out.Cookies = (out.Cookies)[:0]
|
|
}
|
|
for !in.IsDelim(']') {
|
|
var v1 *Cookie
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
v1 = nil
|
|
} else {
|
|
if v1 == nil {
|
|
v1 = new(Cookie)
|
|
}
|
|
(*v1).UnmarshalEasyJSON(in)
|
|
}
|
|
out.Cookies = append(out.Cookies, v1)
|
|
in.WantComma()
|
|
}
|
|
in.Delim(']')
|
|
}
|
|
case "headers":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Headers = nil
|
|
} else {
|
|
in.Delim('[')
|
|
if out.Headers == nil {
|
|
if !in.IsDelim(']') {
|
|
out.Headers = make([]*NameValuePair, 0, 8)
|
|
} else {
|
|
out.Headers = []*NameValuePair{}
|
|
}
|
|
} else {
|
|
out.Headers = (out.Headers)[:0]
|
|
}
|
|
for !in.IsDelim(']') {
|
|
var v2 *NameValuePair
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
v2 = nil
|
|
} else {
|
|
if v2 == nil {
|
|
v2 = new(NameValuePair)
|
|
}
|
|
(*v2).UnmarshalEasyJSON(in)
|
|
}
|
|
out.Headers = append(out.Headers, v2)
|
|
in.WantComma()
|
|
}
|
|
in.Delim(']')
|
|
}
|
|
case "content":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Content = nil
|
|
} else {
|
|
if out.Content == nil {
|
|
out.Content = new(Content)
|
|
}
|
|
(*out.Content).UnmarshalEasyJSON(in)
|
|
}
|
|
case "redirectURL":
|
|
out.RedirectURL = string(in.String())
|
|
case "headersSize":
|
|
out.HeadersSize = int64(in.Int64())
|
|
case "bodySize":
|
|
out.BodySize = int64(in.Int64())
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar1(out *jwriter.Writer, in Response) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
{
|
|
const prefix string = ",\"status\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Int64(int64(in.Status))
|
|
}
|
|
{
|
|
const prefix string = ",\"statusText\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.StatusText))
|
|
}
|
|
{
|
|
const prefix string = ",\"httpVersion\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.HTTPVersion))
|
|
}
|
|
{
|
|
const prefix string = ",\"cookies\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.Cookies == nil && (out.Flags&jwriter.NilSliceAsEmpty) == 0 {
|
|
out.RawString("null")
|
|
} else {
|
|
out.RawByte('[')
|
|
for v3, v4 := range in.Cookies {
|
|
if v3 > 0 {
|
|
out.RawByte(',')
|
|
}
|
|
if v4 == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*v4).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
out.RawByte(']')
|
|
}
|
|
}
|
|
{
|
|
const prefix string = ",\"headers\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.Headers == nil && (out.Flags&jwriter.NilSliceAsEmpty) == 0 {
|
|
out.RawString("null")
|
|
} else {
|
|
out.RawByte('[')
|
|
for v5, v6 := range in.Headers {
|
|
if v5 > 0 {
|
|
out.RawByte(',')
|
|
}
|
|
if v6 == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*v6).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
out.RawByte(']')
|
|
}
|
|
}
|
|
{
|
|
const prefix string = ",\"content\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.Content == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*in.Content).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
{
|
|
const prefix string = ",\"redirectURL\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.RedirectURL))
|
|
}
|
|
{
|
|
const prefix string = ",\"headersSize\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Int64(int64(in.HeadersSize))
|
|
}
|
|
{
|
|
const prefix string = ",\"bodySize\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Int64(int64(in.BodySize))
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v Response) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar1(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v Response) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar1(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *Response) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar1(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *Response) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar1(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar2(in *jlexer.Lexer, out *Request) {
|
|
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 "method":
|
|
out.Method = string(in.String())
|
|
case "url":
|
|
out.URL = string(in.String())
|
|
case "httpVersion":
|
|
out.HTTPVersion = string(in.String())
|
|
case "cookies":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Cookies = nil
|
|
} else {
|
|
in.Delim('[')
|
|
if out.Cookies == nil {
|
|
if !in.IsDelim(']') {
|
|
out.Cookies = make([]*Cookie, 0, 8)
|
|
} else {
|
|
out.Cookies = []*Cookie{}
|
|
}
|
|
} else {
|
|
out.Cookies = (out.Cookies)[:0]
|
|
}
|
|
for !in.IsDelim(']') {
|
|
var v7 *Cookie
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
v7 = nil
|
|
} else {
|
|
if v7 == nil {
|
|
v7 = new(Cookie)
|
|
}
|
|
(*v7).UnmarshalEasyJSON(in)
|
|
}
|
|
out.Cookies = append(out.Cookies, v7)
|
|
in.WantComma()
|
|
}
|
|
in.Delim(']')
|
|
}
|
|
case "headers":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Headers = nil
|
|
} else {
|
|
in.Delim('[')
|
|
if out.Headers == nil {
|
|
if !in.IsDelim(']') {
|
|
out.Headers = make([]*NameValuePair, 0, 8)
|
|
} else {
|
|
out.Headers = []*NameValuePair{}
|
|
}
|
|
} else {
|
|
out.Headers = (out.Headers)[:0]
|
|
}
|
|
for !in.IsDelim(']') {
|
|
var v8 *NameValuePair
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
v8 = nil
|
|
} else {
|
|
if v8 == nil {
|
|
v8 = new(NameValuePair)
|
|
}
|
|
(*v8).UnmarshalEasyJSON(in)
|
|
}
|
|
out.Headers = append(out.Headers, v8)
|
|
in.WantComma()
|
|
}
|
|
in.Delim(']')
|
|
}
|
|
case "queryString":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.QueryString = nil
|
|
} else {
|
|
in.Delim('[')
|
|
if out.QueryString == nil {
|
|
if !in.IsDelim(']') {
|
|
out.QueryString = make([]*NameValuePair, 0, 8)
|
|
} else {
|
|
out.QueryString = []*NameValuePair{}
|
|
}
|
|
} else {
|
|
out.QueryString = (out.QueryString)[:0]
|
|
}
|
|
for !in.IsDelim(']') {
|
|
var v9 *NameValuePair
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
v9 = nil
|
|
} else {
|
|
if v9 == nil {
|
|
v9 = new(NameValuePair)
|
|
}
|
|
(*v9).UnmarshalEasyJSON(in)
|
|
}
|
|
out.QueryString = append(out.QueryString, v9)
|
|
in.WantComma()
|
|
}
|
|
in.Delim(']')
|
|
}
|
|
case "postData":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.PostData = nil
|
|
} else {
|
|
if out.PostData == nil {
|
|
out.PostData = new(PostData)
|
|
}
|
|
(*out.PostData).UnmarshalEasyJSON(in)
|
|
}
|
|
case "headersSize":
|
|
out.HeadersSize = int64(in.Int64())
|
|
case "bodySize":
|
|
out.BodySize = int64(in.Int64())
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar2(out *jwriter.Writer, in Request) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
{
|
|
const prefix string = ",\"method\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Method))
|
|
}
|
|
{
|
|
const prefix string = ",\"url\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.URL))
|
|
}
|
|
{
|
|
const prefix string = ",\"httpVersion\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.HTTPVersion))
|
|
}
|
|
{
|
|
const prefix string = ",\"cookies\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.Cookies == nil && (out.Flags&jwriter.NilSliceAsEmpty) == 0 {
|
|
out.RawString("null")
|
|
} else {
|
|
out.RawByte('[')
|
|
for v10, v11 := range in.Cookies {
|
|
if v10 > 0 {
|
|
out.RawByte(',')
|
|
}
|
|
if v11 == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*v11).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
out.RawByte(']')
|
|
}
|
|
}
|
|
{
|
|
const prefix string = ",\"headers\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.Headers == nil && (out.Flags&jwriter.NilSliceAsEmpty) == 0 {
|
|
out.RawString("null")
|
|
} else {
|
|
out.RawByte('[')
|
|
for v12, v13 := range in.Headers {
|
|
if v12 > 0 {
|
|
out.RawByte(',')
|
|
}
|
|
if v13 == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*v13).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
out.RawByte(']')
|
|
}
|
|
}
|
|
{
|
|
const prefix string = ",\"queryString\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.QueryString == nil && (out.Flags&jwriter.NilSliceAsEmpty) == 0 {
|
|
out.RawString("null")
|
|
} else {
|
|
out.RawByte('[')
|
|
for v14, v15 := range in.QueryString {
|
|
if v14 > 0 {
|
|
out.RawByte(',')
|
|
}
|
|
if v15 == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*v15).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
out.RawByte(']')
|
|
}
|
|
}
|
|
if in.PostData != nil {
|
|
const prefix string = ",\"postData\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
(*in.PostData).MarshalEasyJSON(out)
|
|
}
|
|
{
|
|
const prefix string = ",\"headersSize\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Int64(int64(in.HeadersSize))
|
|
}
|
|
{
|
|
const prefix string = ",\"bodySize\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Int64(int64(in.BodySize))
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v Request) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar2(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v Request) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar2(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *Request) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar2(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *Request) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar2(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar3(in *jlexer.Lexer, out *PostData) {
|
|
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 "mimeType":
|
|
out.MimeType = string(in.String())
|
|
case "params":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Params = nil
|
|
} else {
|
|
in.Delim('[')
|
|
if out.Params == nil {
|
|
if !in.IsDelim(']') {
|
|
out.Params = make([]*Param, 0, 8)
|
|
} else {
|
|
out.Params = []*Param{}
|
|
}
|
|
} else {
|
|
out.Params = (out.Params)[:0]
|
|
}
|
|
for !in.IsDelim(']') {
|
|
var v16 *Param
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
v16 = nil
|
|
} else {
|
|
if v16 == nil {
|
|
v16 = new(Param)
|
|
}
|
|
(*v16).UnmarshalEasyJSON(in)
|
|
}
|
|
out.Params = append(out.Params, v16)
|
|
in.WantComma()
|
|
}
|
|
in.Delim(']')
|
|
}
|
|
case "text":
|
|
out.Text = string(in.String())
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar3(out *jwriter.Writer, in PostData) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
{
|
|
const prefix string = ",\"mimeType\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.MimeType))
|
|
}
|
|
{
|
|
const prefix string = ",\"params\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.Params == nil && (out.Flags&jwriter.NilSliceAsEmpty) == 0 {
|
|
out.RawString("null")
|
|
} else {
|
|
out.RawByte('[')
|
|
for v17, v18 := range in.Params {
|
|
if v17 > 0 {
|
|
out.RawByte(',')
|
|
}
|
|
if v18 == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*v18).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
out.RawByte(']')
|
|
}
|
|
}
|
|
{
|
|
const prefix string = ",\"text\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Text))
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v PostData) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar3(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v PostData) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar3(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *PostData) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar3(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *PostData) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar3(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar4(in *jlexer.Lexer, out *Param) {
|
|
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())
|
|
case "fileName":
|
|
out.FileName = string(in.String())
|
|
case "contentType":
|
|
out.ContentType = string(in.String())
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar4(out *jwriter.Writer, in Param) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
{
|
|
const prefix string = ",\"name\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Name))
|
|
}
|
|
if in.Value != "" {
|
|
const prefix string = ",\"value\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Value))
|
|
}
|
|
if in.FileName != "" {
|
|
const prefix string = ",\"fileName\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.FileName))
|
|
}
|
|
if in.ContentType != "" {
|
|
const prefix string = ",\"contentType\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.ContentType))
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v Param) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar4(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v Param) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar4(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *Param) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar4(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *Param) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar4(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar5(in *jlexer.Lexer, out *PageTimings) {
|
|
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 "onContentLoad":
|
|
out.OnContentLoad = float64(in.Float64())
|
|
case "onLoad":
|
|
out.OnLoad = float64(in.Float64())
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar5(out *jwriter.Writer, in PageTimings) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
if in.OnContentLoad != 0 {
|
|
const prefix string = ",\"onContentLoad\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Float64(float64(in.OnContentLoad))
|
|
}
|
|
if in.OnLoad != 0 {
|
|
const prefix string = ",\"onLoad\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Float64(float64(in.OnLoad))
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v PageTimings) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar5(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v PageTimings) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar5(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *PageTimings) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar5(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *PageTimings) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar5(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar6(in *jlexer.Lexer, out *Page) {
|
|
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 "startedDateTime":
|
|
out.StartedDateTime = string(in.String())
|
|
case "id":
|
|
out.ID = string(in.String())
|
|
case "title":
|
|
out.Title = string(in.String())
|
|
case "pageTimings":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.PageTimings = nil
|
|
} else {
|
|
if out.PageTimings == nil {
|
|
out.PageTimings = new(PageTimings)
|
|
}
|
|
(*out.PageTimings).UnmarshalEasyJSON(in)
|
|
}
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar6(out *jwriter.Writer, in Page) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
{
|
|
const prefix string = ",\"startedDateTime\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.StartedDateTime))
|
|
}
|
|
{
|
|
const prefix string = ",\"id\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.ID))
|
|
}
|
|
{
|
|
const prefix string = ",\"title\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Title))
|
|
}
|
|
{
|
|
const prefix string = ",\"pageTimings\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.PageTimings == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*in.PageTimings).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v Page) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar6(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v Page) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar6(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *Page) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar6(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *Page) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar6(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar7(in *jlexer.Lexer, out *NameValuePair) {
|
|
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())
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar7(out *jwriter.Writer, in NameValuePair) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
{
|
|
const prefix string = ",\"name\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Name))
|
|
}
|
|
{
|
|
const prefix string = ",\"value\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Value))
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v NameValuePair) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar7(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v NameValuePair) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar7(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *NameValuePair) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar7(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *NameValuePair) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar7(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar8(in *jlexer.Lexer, out *Log) {
|
|
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 "version":
|
|
out.Version = string(in.String())
|
|
case "creator":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Creator = nil
|
|
} else {
|
|
if out.Creator == nil {
|
|
out.Creator = new(Creator)
|
|
}
|
|
(*out.Creator).UnmarshalEasyJSON(in)
|
|
}
|
|
case "browser":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Browser = nil
|
|
} else {
|
|
if out.Browser == nil {
|
|
out.Browser = new(Creator)
|
|
}
|
|
(*out.Browser).UnmarshalEasyJSON(in)
|
|
}
|
|
case "pages":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Pages = nil
|
|
} else {
|
|
in.Delim('[')
|
|
if out.Pages == nil {
|
|
if !in.IsDelim(']') {
|
|
out.Pages = make([]*Page, 0, 8)
|
|
} else {
|
|
out.Pages = []*Page{}
|
|
}
|
|
} else {
|
|
out.Pages = (out.Pages)[:0]
|
|
}
|
|
for !in.IsDelim(']') {
|
|
var v19 *Page
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
v19 = nil
|
|
} else {
|
|
if v19 == nil {
|
|
v19 = new(Page)
|
|
}
|
|
(*v19).UnmarshalEasyJSON(in)
|
|
}
|
|
out.Pages = append(out.Pages, v19)
|
|
in.WantComma()
|
|
}
|
|
in.Delim(']')
|
|
}
|
|
case "entries":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Entries = nil
|
|
} else {
|
|
in.Delim('[')
|
|
if out.Entries == nil {
|
|
if !in.IsDelim(']') {
|
|
out.Entries = make([]*Entry, 0, 8)
|
|
} else {
|
|
out.Entries = []*Entry{}
|
|
}
|
|
} else {
|
|
out.Entries = (out.Entries)[:0]
|
|
}
|
|
for !in.IsDelim(']') {
|
|
var v20 *Entry
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
v20 = nil
|
|
} else {
|
|
if v20 == nil {
|
|
v20 = new(Entry)
|
|
}
|
|
(*v20).UnmarshalEasyJSON(in)
|
|
}
|
|
out.Entries = append(out.Entries, v20)
|
|
in.WantComma()
|
|
}
|
|
in.Delim(']')
|
|
}
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar8(out *jwriter.Writer, in Log) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
{
|
|
const prefix string = ",\"version\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Version))
|
|
}
|
|
{
|
|
const prefix string = ",\"creator\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.Creator == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*in.Creator).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
if in.Browser != nil {
|
|
const prefix string = ",\"browser\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
(*in.Browser).MarshalEasyJSON(out)
|
|
}
|
|
if len(in.Pages) != 0 {
|
|
const prefix string = ",\"pages\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
{
|
|
out.RawByte('[')
|
|
for v21, v22 := range in.Pages {
|
|
if v21 > 0 {
|
|
out.RawByte(',')
|
|
}
|
|
if v22 == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*v22).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
out.RawByte(']')
|
|
}
|
|
}
|
|
{
|
|
const prefix string = ",\"entries\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.Entries == nil && (out.Flags&jwriter.NilSliceAsEmpty) == 0 {
|
|
out.RawString("null")
|
|
} else {
|
|
out.RawByte('[')
|
|
for v23, v24 := range in.Entries {
|
|
if v23 > 0 {
|
|
out.RawByte(',')
|
|
}
|
|
if v24 == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*v24).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
out.RawByte(']')
|
|
}
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v Log) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar8(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v Log) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar8(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *Log) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar8(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *Log) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar8(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar9(in *jlexer.Lexer, out *HAR) {
|
|
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 "log":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Log = nil
|
|
} else {
|
|
if out.Log == nil {
|
|
out.Log = new(Log)
|
|
}
|
|
(*out.Log).UnmarshalEasyJSON(in)
|
|
}
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar9(out *jwriter.Writer, in HAR) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
{
|
|
const prefix string = ",\"log\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.Log == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*in.Log).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v HAR) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar9(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v HAR) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar9(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *HAR) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar9(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *HAR) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar9(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar10(in *jlexer.Lexer, out *Entry) {
|
|
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 "pageref":
|
|
out.Pageref = string(in.String())
|
|
case "startedDateTime":
|
|
out.StartedDateTime = string(in.String())
|
|
case "time":
|
|
out.Time = float64(in.Float64())
|
|
case "request":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Request = nil
|
|
} else {
|
|
if out.Request == nil {
|
|
out.Request = new(Request)
|
|
}
|
|
(*out.Request).UnmarshalEasyJSON(in)
|
|
}
|
|
case "response":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Response = nil
|
|
} else {
|
|
if out.Response == nil {
|
|
out.Response = new(Response)
|
|
}
|
|
(*out.Response).UnmarshalEasyJSON(in)
|
|
}
|
|
case "cache":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Cache = nil
|
|
} else {
|
|
if out.Cache == nil {
|
|
out.Cache = new(Cache)
|
|
}
|
|
(*out.Cache).UnmarshalEasyJSON(in)
|
|
}
|
|
case "timings":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.Timings = nil
|
|
} else {
|
|
if out.Timings == nil {
|
|
out.Timings = new(Timings)
|
|
}
|
|
(*out.Timings).UnmarshalEasyJSON(in)
|
|
}
|
|
case "serverIPAddress":
|
|
out.ServerIPAddress = string(in.String())
|
|
case "connection":
|
|
out.Connection = string(in.String())
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar10(out *jwriter.Writer, in Entry) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
if in.Pageref != "" {
|
|
const prefix string = ",\"pageref\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Pageref))
|
|
}
|
|
{
|
|
const prefix string = ",\"startedDateTime\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.StartedDateTime))
|
|
}
|
|
{
|
|
const prefix string = ",\"time\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Float64(float64(in.Time))
|
|
}
|
|
{
|
|
const prefix string = ",\"request\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.Request == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*in.Request).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
{
|
|
const prefix string = ",\"response\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.Response == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*in.Response).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
{
|
|
const prefix string = ",\"cache\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.Cache == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*in.Cache).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
{
|
|
const prefix string = ",\"timings\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
if in.Timings == nil {
|
|
out.RawString("null")
|
|
} else {
|
|
(*in.Timings).MarshalEasyJSON(out)
|
|
}
|
|
}
|
|
if in.ServerIPAddress != "" {
|
|
const prefix string = ",\"serverIPAddress\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.ServerIPAddress))
|
|
}
|
|
if in.Connection != "" {
|
|
const prefix string = ",\"connection\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Connection))
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v Entry) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar10(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v Entry) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar10(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *Entry) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar10(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *Entry) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar10(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar11(in *jlexer.Lexer, out *Creator) {
|
|
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 "version":
|
|
out.Version = string(in.String())
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar11(out *jwriter.Writer, in Creator) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
{
|
|
const prefix string = ",\"name\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Name))
|
|
}
|
|
{
|
|
const prefix string = ",\"version\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Version))
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v Creator) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar11(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v Creator) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar11(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *Creator) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar11(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *Creator) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar11(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar12(in *jlexer.Lexer, out *Cookie) {
|
|
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())
|
|
case "path":
|
|
out.Path = string(in.String())
|
|
case "domain":
|
|
out.Domain = string(in.String())
|
|
case "expires":
|
|
out.Expires = string(in.String())
|
|
case "httpOnly":
|
|
out.HTTPOnly = bool(in.Bool())
|
|
case "secure":
|
|
out.Secure = bool(in.Bool())
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar12(out *jwriter.Writer, in Cookie) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
{
|
|
const prefix string = ",\"name\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Name))
|
|
}
|
|
{
|
|
const prefix string = ",\"value\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Value))
|
|
}
|
|
if in.Path != "" {
|
|
const prefix string = ",\"path\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Path))
|
|
}
|
|
if in.Domain != "" {
|
|
const prefix string = ",\"domain\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Domain))
|
|
}
|
|
if in.Expires != "" {
|
|
const prefix string = ",\"expires\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Expires))
|
|
}
|
|
if in.HTTPOnly {
|
|
const prefix string = ",\"httpOnly\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Bool(bool(in.HTTPOnly))
|
|
}
|
|
if in.Secure {
|
|
const prefix string = ",\"secure\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Bool(bool(in.Secure))
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v Cookie) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar12(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v Cookie) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar12(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *Cookie) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar12(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *Cookie) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar12(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar13(in *jlexer.Lexer, out *Content) {
|
|
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 "size":
|
|
out.Size = int64(in.Int64())
|
|
case "compression":
|
|
out.Compression = int64(in.Int64())
|
|
case "mimeType":
|
|
out.MimeType = string(in.String())
|
|
case "text":
|
|
out.Text = string(in.String())
|
|
case "encoding":
|
|
out.Encoding = string(in.String())
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar13(out *jwriter.Writer, in Content) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
{
|
|
const prefix string = ",\"size\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Int64(int64(in.Size))
|
|
}
|
|
if in.Compression != 0 {
|
|
const prefix string = ",\"compression\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Int64(int64(in.Compression))
|
|
}
|
|
{
|
|
const prefix string = ",\"mimeType\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.MimeType))
|
|
}
|
|
if in.Text != "" {
|
|
const prefix string = ",\"text\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Text))
|
|
}
|
|
if in.Encoding != "" {
|
|
const prefix string = ",\"encoding\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Encoding))
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v Content) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar13(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v Content) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar13(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *Content) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar13(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *Content) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar13(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar14(in *jlexer.Lexer, out *CacheData) {
|
|
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 "expires":
|
|
out.Expires = string(in.String())
|
|
case "lastAccess":
|
|
out.LastAccess = string(in.String())
|
|
case "eTag":
|
|
out.ETag = string(in.String())
|
|
case "hitCount":
|
|
out.HitCount = int64(in.Int64())
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar14(out *jwriter.Writer, in CacheData) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
if in.Expires != "" {
|
|
const prefix string = ",\"expires\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Expires))
|
|
}
|
|
{
|
|
const prefix string = ",\"lastAccess\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.LastAccess))
|
|
}
|
|
{
|
|
const prefix string = ",\"eTag\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.ETag))
|
|
}
|
|
{
|
|
const prefix string = ",\"hitCount\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.Int64(int64(in.HitCount))
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v CacheData) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar14(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v CacheData) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar14(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *CacheData) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar14(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *CacheData) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar14(l, v)
|
|
}
|
|
func easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar15(in *jlexer.Lexer, out *Cache) {
|
|
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 "beforeRequest":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.BeforeRequest = nil
|
|
} else {
|
|
if out.BeforeRequest == nil {
|
|
out.BeforeRequest = new(CacheData)
|
|
}
|
|
(*out.BeforeRequest).UnmarshalEasyJSON(in)
|
|
}
|
|
case "afterRequest":
|
|
if in.IsNull() {
|
|
in.Skip()
|
|
out.AfterRequest = nil
|
|
} else {
|
|
if out.AfterRequest == nil {
|
|
out.AfterRequest = new(CacheData)
|
|
}
|
|
(*out.AfterRequest).UnmarshalEasyJSON(in)
|
|
}
|
|
case "comment":
|
|
out.Comment = string(in.String())
|
|
default:
|
|
in.SkipRecursive()
|
|
}
|
|
in.WantComma()
|
|
}
|
|
in.Delim('}')
|
|
if isTopLevel {
|
|
in.Consumed()
|
|
}
|
|
}
|
|
func easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar15(out *jwriter.Writer, in Cache) {
|
|
out.RawByte('{')
|
|
first := true
|
|
_ = first
|
|
if in.BeforeRequest != nil {
|
|
const prefix string = ",\"beforeRequest\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
(*in.BeforeRequest).MarshalEasyJSON(out)
|
|
}
|
|
if in.AfterRequest != nil {
|
|
const prefix string = ",\"afterRequest\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
(*in.AfterRequest).MarshalEasyJSON(out)
|
|
}
|
|
if in.Comment != "" {
|
|
const prefix string = ",\"comment\":"
|
|
if first {
|
|
first = false
|
|
out.RawString(prefix[1:])
|
|
} else {
|
|
out.RawString(prefix)
|
|
}
|
|
out.String(string(in.Comment))
|
|
}
|
|
out.RawByte('}')
|
|
}
|
|
|
|
// MarshalJSON supports json.Marshaler interface
|
|
func (v Cache) MarshalJSON() ([]byte, error) {
|
|
w := jwriter.Writer{}
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar15(&w, v)
|
|
return w.Buffer.BuildBytes(), w.Error
|
|
}
|
|
|
|
// MarshalEasyJSON supports easyjson.Marshaler interface
|
|
func (v Cache) MarshalEasyJSON(w *jwriter.Writer) {
|
|
easyjsonC5a4559bEncodeGithubComKnqChromedpCdpHar15(w, v)
|
|
}
|
|
|
|
// UnmarshalJSON supports json.Unmarshaler interface
|
|
func (v *Cache) UnmarshalJSON(data []byte) error {
|
|
r := jlexer.Lexer{Data: data}
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar15(&r, v)
|
|
return r.Error()
|
|
}
|
|
|
|
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
|
|
func (v *Cache) UnmarshalEasyJSON(l *jlexer.Lexer) {
|
|
easyjsonC5a4559bDecodeGithubComKnqChromedpCdpHar15(l, v)
|
|
}
|