github.com/goplus/igop@v0.17.0/pkg/net/http/go119_export.go (about)

     1  // export by github.com/goplus/igop/cmd/qexp
     2  
     3  //go:build go1.19 && !go1.20
     4  // +build go1.19,!go1.20
     5  
     6  package http
     7  
     8  import (
     9  	q "net/http"
    10  
    11  	"go/constant"
    12  	"reflect"
    13  
    14  	"github.com/goplus/igop"
    15  )
    16  
    17  func init() {
    18  	igop.RegisterPackage(&igop.Package{
    19  		Name: "http",
    20  		Path: "net/http",
    21  		Deps: map[string]string{
    22  			"bufio":                                  "bufio",
    23  			"bytes":                                  "bytes",
    24  			"compress/gzip":                          "gzip",
    25  			"container/list":                         "list",
    26  			"context":                                "context",
    27  			"crypto/rand":                            "rand",
    28  			"crypto/tls":                             "tls",
    29  			"encoding/base64":                        "base64",
    30  			"encoding/binary":                        "binary",
    31  			"errors":                                 "errors",
    32  			"fmt":                                    "fmt",
    33  			"internal/godebug":                       "godebug",
    34  			"internal/safefilepath":                  "safefilepath",
    35  			"io":                                     "io",
    36  			"io/fs":                                  "fs",
    37  			"log":                                    "log",
    38  			"math":                                   "math",
    39  			"math/rand":                              "rand",
    40  			"mime":                                   "mime",
    41  			"mime/multipart":                         "multipart",
    42  			"net":                                    "net",
    43  			"net/http/httptrace":                     "httptrace",
    44  			"net/http/internal":                      "internal",
    45  			"net/http/internal/ascii":                "ascii",
    46  			"net/textproto":                          "textproto",
    47  			"net/url":                                "url",
    48  			"os":                                     "os",
    49  			"path":                                   "path",
    50  			"path/filepath":                          "filepath",
    51  			"reflect":                                "reflect",
    52  			"runtime":                                "runtime",
    53  			"sort":                                   "sort",
    54  			"strconv":                                "strconv",
    55  			"strings":                                "strings",
    56  			"sync":                                   "sync",
    57  			"sync/atomic":                            "atomic",
    58  			"time":                                   "time",
    59  			"unicode/utf8":                           "utf8",
    60  			"vendor/golang.org/x/net/http/httpguts":  "httpguts",
    61  			"vendor/golang.org/x/net/http/httpproxy": "httpproxy",
    62  			"vendor/golang.org/x/net/http2/hpack":    "hpack",
    63  			"vendor/golang.org/x/net/idna":           "idna",
    64  		},
    65  		Interfaces: map[string]reflect.Type{
    66  			"CloseNotifier":  reflect.TypeOf((*q.CloseNotifier)(nil)).Elem(),
    67  			"CookieJar":      reflect.TypeOf((*q.CookieJar)(nil)).Elem(),
    68  			"File":           reflect.TypeOf((*q.File)(nil)).Elem(),
    69  			"FileSystem":     reflect.TypeOf((*q.FileSystem)(nil)).Elem(),
    70  			"Flusher":        reflect.TypeOf((*q.Flusher)(nil)).Elem(),
    71  			"Handler":        reflect.TypeOf((*q.Handler)(nil)).Elem(),
    72  			"Hijacker":       reflect.TypeOf((*q.Hijacker)(nil)).Elem(),
    73  			"Pusher":         reflect.TypeOf((*q.Pusher)(nil)).Elem(),
    74  			"ResponseWriter": reflect.TypeOf((*q.ResponseWriter)(nil)).Elem(),
    75  			"RoundTripper":   reflect.TypeOf((*q.RoundTripper)(nil)).Elem(),
    76  		},
    77  		NamedTypes: map[string]reflect.Type{
    78  			"Client":        reflect.TypeOf((*q.Client)(nil)).Elem(),
    79  			"ConnState":     reflect.TypeOf((*q.ConnState)(nil)).Elem(),
    80  			"Cookie":        reflect.TypeOf((*q.Cookie)(nil)).Elem(),
    81  			"Dir":           reflect.TypeOf((*q.Dir)(nil)).Elem(),
    82  			"HandlerFunc":   reflect.TypeOf((*q.HandlerFunc)(nil)).Elem(),
    83  			"Header":        reflect.TypeOf((*q.Header)(nil)).Elem(),
    84  			"MaxBytesError": reflect.TypeOf((*q.MaxBytesError)(nil)).Elem(),
    85  			"ProtocolError": reflect.TypeOf((*q.ProtocolError)(nil)).Elem(),
    86  			"PushOptions":   reflect.TypeOf((*q.PushOptions)(nil)).Elem(),
    87  			"Request":       reflect.TypeOf((*q.Request)(nil)).Elem(),
    88  			"Response":      reflect.TypeOf((*q.Response)(nil)).Elem(),
    89  			"SameSite":      reflect.TypeOf((*q.SameSite)(nil)).Elem(),
    90  			"ServeMux":      reflect.TypeOf((*q.ServeMux)(nil)).Elem(),
    91  			"Server":        reflect.TypeOf((*q.Server)(nil)).Elem(),
    92  			"Transport":     reflect.TypeOf((*q.Transport)(nil)).Elem(),
    93  		},
    94  		AliasTypes: map[string]reflect.Type{},
    95  		Vars: map[string]reflect.Value{
    96  			"DefaultClient":           reflect.ValueOf(&q.DefaultClient),
    97  			"DefaultServeMux":         reflect.ValueOf(&q.DefaultServeMux),
    98  			"DefaultTransport":        reflect.ValueOf(&q.DefaultTransport),
    99  			"ErrAbortHandler":         reflect.ValueOf(&q.ErrAbortHandler),
   100  			"ErrBodyNotAllowed":       reflect.ValueOf(&q.ErrBodyNotAllowed),
   101  			"ErrBodyReadAfterClose":   reflect.ValueOf(&q.ErrBodyReadAfterClose),
   102  			"ErrContentLength":        reflect.ValueOf(&q.ErrContentLength),
   103  			"ErrHandlerTimeout":       reflect.ValueOf(&q.ErrHandlerTimeout),
   104  			"ErrHeaderTooLong":        reflect.ValueOf(&q.ErrHeaderTooLong),
   105  			"ErrHijacked":             reflect.ValueOf(&q.ErrHijacked),
   106  			"ErrLineTooLong":          reflect.ValueOf(&q.ErrLineTooLong),
   107  			"ErrMissingBoundary":      reflect.ValueOf(&q.ErrMissingBoundary),
   108  			"ErrMissingContentLength": reflect.ValueOf(&q.ErrMissingContentLength),
   109  			"ErrMissingFile":          reflect.ValueOf(&q.ErrMissingFile),
   110  			"ErrNoCookie":             reflect.ValueOf(&q.ErrNoCookie),
   111  			"ErrNoLocation":           reflect.ValueOf(&q.ErrNoLocation),
   112  			"ErrNotMultipart":         reflect.ValueOf(&q.ErrNotMultipart),
   113  			"ErrNotSupported":         reflect.ValueOf(&q.ErrNotSupported),
   114  			"ErrServerClosed":         reflect.ValueOf(&q.ErrServerClosed),
   115  			"ErrShortBody":            reflect.ValueOf(&q.ErrShortBody),
   116  			"ErrSkipAltProtocol":      reflect.ValueOf(&q.ErrSkipAltProtocol),
   117  			"ErrUnexpectedTrailer":    reflect.ValueOf(&q.ErrUnexpectedTrailer),
   118  			"ErrUseLastResponse":      reflect.ValueOf(&q.ErrUseLastResponse),
   119  			"ErrWriteAfterFlush":      reflect.ValueOf(&q.ErrWriteAfterFlush),
   120  			"LocalAddrContextKey":     reflect.ValueOf(&q.LocalAddrContextKey),
   121  			"NoBody":                  reflect.ValueOf(&q.NoBody),
   122  			"ServerContextKey":        reflect.ValueOf(&q.ServerContextKey),
   123  		},
   124  		Funcs: map[string]reflect.Value{
   125  			"AllowQuerySemicolons":  reflect.ValueOf(q.AllowQuerySemicolons),
   126  			"CanonicalHeaderKey":    reflect.ValueOf(q.CanonicalHeaderKey),
   127  			"DetectContentType":     reflect.ValueOf(q.DetectContentType),
   128  			"Error":                 reflect.ValueOf(q.Error),
   129  			"FS":                    reflect.ValueOf(q.FS),
   130  			"FileServer":            reflect.ValueOf(q.FileServer),
   131  			"Get":                   reflect.ValueOf(q.Get),
   132  			"Handle":                reflect.ValueOf(q.Handle),
   133  			"HandleFunc":            reflect.ValueOf(q.HandleFunc),
   134  			"Head":                  reflect.ValueOf(q.Head),
   135  			"ListenAndServe":        reflect.ValueOf(q.ListenAndServe),
   136  			"ListenAndServeTLS":     reflect.ValueOf(q.ListenAndServeTLS),
   137  			"MaxBytesHandler":       reflect.ValueOf(q.MaxBytesHandler),
   138  			"MaxBytesReader":        reflect.ValueOf(q.MaxBytesReader),
   139  			"NewFileTransport":      reflect.ValueOf(q.NewFileTransport),
   140  			"NewRequest":            reflect.ValueOf(q.NewRequest),
   141  			"NewRequestWithContext": reflect.ValueOf(q.NewRequestWithContext),
   142  			"NewServeMux":           reflect.ValueOf(q.NewServeMux),
   143  			"NotFound":              reflect.ValueOf(q.NotFound),
   144  			"NotFoundHandler":       reflect.ValueOf(q.NotFoundHandler),
   145  			"ParseHTTPVersion":      reflect.ValueOf(q.ParseHTTPVersion),
   146  			"ParseTime":             reflect.ValueOf(q.ParseTime),
   147  			"Post":                  reflect.ValueOf(q.Post),
   148  			"PostForm":              reflect.ValueOf(q.PostForm),
   149  			"ProxyFromEnvironment":  reflect.ValueOf(q.ProxyFromEnvironment),
   150  			"ProxyURL":              reflect.ValueOf(q.ProxyURL),
   151  			"ReadRequest":           reflect.ValueOf(q.ReadRequest),
   152  			"ReadResponse":          reflect.ValueOf(q.ReadResponse),
   153  			"Redirect":              reflect.ValueOf(q.Redirect),
   154  			"RedirectHandler":       reflect.ValueOf(q.RedirectHandler),
   155  			"Serve":                 reflect.ValueOf(q.Serve),
   156  			"ServeContent":          reflect.ValueOf(q.ServeContent),
   157  			"ServeFile":             reflect.ValueOf(q.ServeFile),
   158  			"ServeTLS":              reflect.ValueOf(q.ServeTLS),
   159  			"SetCookie":             reflect.ValueOf(q.SetCookie),
   160  			"StatusText":            reflect.ValueOf(q.StatusText),
   161  			"StripPrefix":           reflect.ValueOf(q.StripPrefix),
   162  			"TimeoutHandler":        reflect.ValueOf(q.TimeoutHandler),
   163  		},
   164  		TypedConsts: map[string]igop.TypedConst{
   165  			"SameSiteDefaultMode": {reflect.TypeOf(q.SameSiteDefaultMode), constant.MakeInt64(int64(q.SameSiteDefaultMode))},
   166  			"SameSiteLaxMode":     {reflect.TypeOf(q.SameSiteLaxMode), constant.MakeInt64(int64(q.SameSiteLaxMode))},
   167  			"SameSiteNoneMode":    {reflect.TypeOf(q.SameSiteNoneMode), constant.MakeInt64(int64(q.SameSiteNoneMode))},
   168  			"SameSiteStrictMode":  {reflect.TypeOf(q.SameSiteStrictMode), constant.MakeInt64(int64(q.SameSiteStrictMode))},
   169  			"StateActive":         {reflect.TypeOf(q.StateActive), constant.MakeInt64(int64(q.StateActive))},
   170  			"StateClosed":         {reflect.TypeOf(q.StateClosed), constant.MakeInt64(int64(q.StateClosed))},
   171  			"StateHijacked":       {reflect.TypeOf(q.StateHijacked), constant.MakeInt64(int64(q.StateHijacked))},
   172  			"StateIdle":           {reflect.TypeOf(q.StateIdle), constant.MakeInt64(int64(q.StateIdle))},
   173  			"StateNew":            {reflect.TypeOf(q.StateNew), constant.MakeInt64(int64(q.StateNew))},
   174  		},
   175  		UntypedConsts: map[string]igop.UntypedConst{
   176  			"DefaultMaxHeaderBytes":               {"untyped int", constant.MakeInt64(int64(q.DefaultMaxHeaderBytes))},
   177  			"DefaultMaxIdleConnsPerHost":          {"untyped int", constant.MakeInt64(int64(q.DefaultMaxIdleConnsPerHost))},
   178  			"MethodConnect":                       {"untyped string", constant.MakeString(string(q.MethodConnect))},
   179  			"MethodDelete":                        {"untyped string", constant.MakeString(string(q.MethodDelete))},
   180  			"MethodGet":                           {"untyped string", constant.MakeString(string(q.MethodGet))},
   181  			"MethodHead":                          {"untyped string", constant.MakeString(string(q.MethodHead))},
   182  			"MethodOptions":                       {"untyped string", constant.MakeString(string(q.MethodOptions))},
   183  			"MethodPatch":                         {"untyped string", constant.MakeString(string(q.MethodPatch))},
   184  			"MethodPost":                          {"untyped string", constant.MakeString(string(q.MethodPost))},
   185  			"MethodPut":                           {"untyped string", constant.MakeString(string(q.MethodPut))},
   186  			"MethodTrace":                         {"untyped string", constant.MakeString(string(q.MethodTrace))},
   187  			"StatusAccepted":                      {"untyped int", constant.MakeInt64(int64(q.StatusAccepted))},
   188  			"StatusAlreadyReported":               {"untyped int", constant.MakeInt64(int64(q.StatusAlreadyReported))},
   189  			"StatusBadGateway":                    {"untyped int", constant.MakeInt64(int64(q.StatusBadGateway))},
   190  			"StatusBadRequest":                    {"untyped int", constant.MakeInt64(int64(q.StatusBadRequest))},
   191  			"StatusConflict":                      {"untyped int", constant.MakeInt64(int64(q.StatusConflict))},
   192  			"StatusContinue":                      {"untyped int", constant.MakeInt64(int64(q.StatusContinue))},
   193  			"StatusCreated":                       {"untyped int", constant.MakeInt64(int64(q.StatusCreated))},
   194  			"StatusEarlyHints":                    {"untyped int", constant.MakeInt64(int64(q.StatusEarlyHints))},
   195  			"StatusExpectationFailed":             {"untyped int", constant.MakeInt64(int64(q.StatusExpectationFailed))},
   196  			"StatusFailedDependency":              {"untyped int", constant.MakeInt64(int64(q.StatusFailedDependency))},
   197  			"StatusForbidden":                     {"untyped int", constant.MakeInt64(int64(q.StatusForbidden))},
   198  			"StatusFound":                         {"untyped int", constant.MakeInt64(int64(q.StatusFound))},
   199  			"StatusGatewayTimeout":                {"untyped int", constant.MakeInt64(int64(q.StatusGatewayTimeout))},
   200  			"StatusGone":                          {"untyped int", constant.MakeInt64(int64(q.StatusGone))},
   201  			"StatusHTTPVersionNotSupported":       {"untyped int", constant.MakeInt64(int64(q.StatusHTTPVersionNotSupported))},
   202  			"StatusIMUsed":                        {"untyped int", constant.MakeInt64(int64(q.StatusIMUsed))},
   203  			"StatusInsufficientStorage":           {"untyped int", constant.MakeInt64(int64(q.StatusInsufficientStorage))},
   204  			"StatusInternalServerError":           {"untyped int", constant.MakeInt64(int64(q.StatusInternalServerError))},
   205  			"StatusLengthRequired":                {"untyped int", constant.MakeInt64(int64(q.StatusLengthRequired))},
   206  			"StatusLocked":                        {"untyped int", constant.MakeInt64(int64(q.StatusLocked))},
   207  			"StatusLoopDetected":                  {"untyped int", constant.MakeInt64(int64(q.StatusLoopDetected))},
   208  			"StatusMethodNotAllowed":              {"untyped int", constant.MakeInt64(int64(q.StatusMethodNotAllowed))},
   209  			"StatusMisdirectedRequest":            {"untyped int", constant.MakeInt64(int64(q.StatusMisdirectedRequest))},
   210  			"StatusMovedPermanently":              {"untyped int", constant.MakeInt64(int64(q.StatusMovedPermanently))},
   211  			"StatusMultiStatus":                   {"untyped int", constant.MakeInt64(int64(q.StatusMultiStatus))},
   212  			"StatusMultipleChoices":               {"untyped int", constant.MakeInt64(int64(q.StatusMultipleChoices))},
   213  			"StatusNetworkAuthenticationRequired": {"untyped int", constant.MakeInt64(int64(q.StatusNetworkAuthenticationRequired))},
   214  			"StatusNoContent":                     {"untyped int", constant.MakeInt64(int64(q.StatusNoContent))},
   215  			"StatusNonAuthoritativeInfo":          {"untyped int", constant.MakeInt64(int64(q.StatusNonAuthoritativeInfo))},
   216  			"StatusNotAcceptable":                 {"untyped int", constant.MakeInt64(int64(q.StatusNotAcceptable))},
   217  			"StatusNotExtended":                   {"untyped int", constant.MakeInt64(int64(q.StatusNotExtended))},
   218  			"StatusNotFound":                      {"untyped int", constant.MakeInt64(int64(q.StatusNotFound))},
   219  			"StatusNotImplemented":                {"untyped int", constant.MakeInt64(int64(q.StatusNotImplemented))},
   220  			"StatusNotModified":                   {"untyped int", constant.MakeInt64(int64(q.StatusNotModified))},
   221  			"StatusOK":                            {"untyped int", constant.MakeInt64(int64(q.StatusOK))},
   222  			"StatusPartialContent":                {"untyped int", constant.MakeInt64(int64(q.StatusPartialContent))},
   223  			"StatusPaymentRequired":               {"untyped int", constant.MakeInt64(int64(q.StatusPaymentRequired))},
   224  			"StatusPermanentRedirect":             {"untyped int", constant.MakeInt64(int64(q.StatusPermanentRedirect))},
   225  			"StatusPreconditionFailed":            {"untyped int", constant.MakeInt64(int64(q.StatusPreconditionFailed))},
   226  			"StatusPreconditionRequired":          {"untyped int", constant.MakeInt64(int64(q.StatusPreconditionRequired))},
   227  			"StatusProcessing":                    {"untyped int", constant.MakeInt64(int64(q.StatusProcessing))},
   228  			"StatusProxyAuthRequired":             {"untyped int", constant.MakeInt64(int64(q.StatusProxyAuthRequired))},
   229  			"StatusRequestEntityTooLarge":         {"untyped int", constant.MakeInt64(int64(q.StatusRequestEntityTooLarge))},
   230  			"StatusRequestHeaderFieldsTooLarge":   {"untyped int", constant.MakeInt64(int64(q.StatusRequestHeaderFieldsTooLarge))},
   231  			"StatusRequestTimeout":                {"untyped int", constant.MakeInt64(int64(q.StatusRequestTimeout))},
   232  			"StatusRequestURITooLong":             {"untyped int", constant.MakeInt64(int64(q.StatusRequestURITooLong))},
   233  			"StatusRequestedRangeNotSatisfiable":  {"untyped int", constant.MakeInt64(int64(q.StatusRequestedRangeNotSatisfiable))},
   234  			"StatusResetContent":                  {"untyped int", constant.MakeInt64(int64(q.StatusResetContent))},
   235  			"StatusSeeOther":                      {"untyped int", constant.MakeInt64(int64(q.StatusSeeOther))},
   236  			"StatusServiceUnavailable":            {"untyped int", constant.MakeInt64(int64(q.StatusServiceUnavailable))},
   237  			"StatusSwitchingProtocols":            {"untyped int", constant.MakeInt64(int64(q.StatusSwitchingProtocols))},
   238  			"StatusTeapot":                        {"untyped int", constant.MakeInt64(int64(q.StatusTeapot))},
   239  			"StatusTemporaryRedirect":             {"untyped int", constant.MakeInt64(int64(q.StatusTemporaryRedirect))},
   240  			"StatusTooEarly":                      {"untyped int", constant.MakeInt64(int64(q.StatusTooEarly))},
   241  			"StatusTooManyRequests":               {"untyped int", constant.MakeInt64(int64(q.StatusTooManyRequests))},
   242  			"StatusUnauthorized":                  {"untyped int", constant.MakeInt64(int64(q.StatusUnauthorized))},
   243  			"StatusUnavailableForLegalReasons":    {"untyped int", constant.MakeInt64(int64(q.StatusUnavailableForLegalReasons))},
   244  			"StatusUnprocessableEntity":           {"untyped int", constant.MakeInt64(int64(q.StatusUnprocessableEntity))},
   245  			"StatusUnsupportedMediaType":          {"untyped int", constant.MakeInt64(int64(q.StatusUnsupportedMediaType))},
   246  			"StatusUpgradeRequired":               {"untyped int", constant.MakeInt64(int64(q.StatusUpgradeRequired))},
   247  			"StatusUseProxy":                      {"untyped int", constant.MakeInt64(int64(q.StatusUseProxy))},
   248  			"StatusVariantAlsoNegotiates":         {"untyped int", constant.MakeInt64(int64(q.StatusVariantAlsoNegotiates))},
   249  			"TimeFormat":                          {"untyped string", constant.MakeString(string(q.TimeFormat))},
   250  			"TrailerPrefix":                       {"untyped string", constant.MakeString(string(q.TrailerPrefix))},
   251  		},
   252  	})
   253  }