text stringlengths 5.51k 28.1k |
|---|
package xray
import (
"context"
"fmt"
"reflect"
"testing"
"time"
"github.com/stretchr/testify/assert"
)
const (
scaleLimit = 1e4
)
var (
bigStrMap map[string]string
bigStrList []string
)
func TestDefaultTypeIdGenerator(t *testing.T) {
assert.Equal(t, "//*context.emptyCtx", getTypeID(reflect.TypeOf(conte... |
/*
Copyright © 2020-2022 The k3d Author(s)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distri... |
// Copyright (c) 2021 <NAME>. All rights reserved.
// Use of this source code is governed by the MIT license that can be found in
// the LICENSE file.
package bitarray_test
import (
"math/rand"
"strings"
"testing"
"time"
"github.com/tunabay/go-bitarray"
)
func TestNewBuffer(t *testing.T) {
for i := 0; i < 64*... |
// Copyright © 2017 Zenly <<EMAIL>>.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed t... |
package asn1
// T-REC-X.690-200811 (BER, DER, CER)
// https://www.itu.int/ITU-T/studygroups/com10/languages/X.690_1297.pdf
// https://cdn.standards.iteh.ai/samples/12285/039296509e8b40f3b25ba025de60365d/ISO-6093-1985.pdf
// https://en.wikipedia.org/wiki/X.690
// https://letsencrypt.org/docs/a-warm-welcome-to-asn1-and-... |
// Go clone of http(1)
package main
import (
"bytes"
"crypto/tls"
"encoding/base64"
"encoding/json"
"errors"
"fmt"
"io"
"io/ioutil"
"mime"
"net/http"
"net/url"
"os"
"sort"
"strings"
"unicode"
"github.com/juju/loggo"
"github.com/juju/persistent-cookiejar"
"github.com/rogpeppe/rjson"
"gopkg.in/macaro... |
package database
import (
"context"
"database/sql"
"fmt"
"strings"
"github.com/jinzhu/gorm"
"github.com/juju/errors"
"github.com/ltick/tick-framework/config"
"github.com/tsuna/gohbase/hrpc"
)
var (
errPrepare = "database: prepare '%s' error"
errInitiate = "database: initiate '%s' error"
errStar... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.26.0
// protoc v3.6.1
// source: yandex/cloud/compute/v1/zone.proto
package compute
import (
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
reflect "re... |
/*
Copyright 2019 Cisco Systems
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
d... |
/*
* Tencent is pleased to support the open source community by making Blueking Container Service available.,
* Copyright (C) 2019 THL A29 Limited, a Tencent company. All rights reserved.
* Licensed under the MIT License (the "License"); you may not use this file except
* in compliance with the License. You may obt... |
//
// Copyright (C) 2019-2022 vdaas.org vald team <<EMAIL>>
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// https://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by a... |
// Copyright 2019 Dolthub, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to i... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: yandex/cloud/compute/v1/snapshot.proto
package compute // import "github.com/yandex-cloud/go-genproto/yandex/cloud/compute/v1"
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import timestamp "github.com/golang/protobuf/pt... |
// Copyright 2021-2022 the Kubeapps contributors.
// SPDX-License-Identifier: Apache-2.0
package main
import (
"bufio"
"context"
"fmt"
"reflect"
"regexp"
"sort"
"strings"
"time"
"github.com/Masterminds/semver/v3"
kappcmdcore "github.com/k14s/kapp/pkg/kapp/cmd/core"
corev1 "github.com/kubeapps/kubeapps/cmd... |
package consensus
// This is to implement Expected Consensus protocol
// See: https://github.com/filecoin-project/specs/blob/master/expected-consensus.md
import (
"bytes"
"context"
"math/big"
"strings"
"time"
"github.com/ipfs/go-cid"
"github.com/ipfs/go-hamt-ipld"
"github.com/ipfs/go-ipfs-blockstore"
loggin... |
package network
import (
"bufio"
"bytes"
"encoding/binary"
"fmt"
"io"
"net"
"runtime"
"strconv"
"sync"
"time"
"github.com/looplab/fsm"
"github.com/prometheus/client_golang/prometheus"
dto "github.com/prometheus/client_model/go"
"github.com/inconshreveable/log15"
"github.com/stephane-martin/skewer/conf... |
// Copyright 2020 Google Inc. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by appl... |
/*
Copyright 2019 Cisco Systems
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
d... |
// Copyright 2020. Akamai Technologies, Inc
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// http://www.apache.org/licenses/LICENSE-2.0
// Unless required by applicable law or agreed t... |
// Package common provides routines common to all handlers in the ledger
// webapp.
package common
import (
"errors"
"flag"
"fmt"
"github.com/gorilla/sessions"
"github.com/keep94/finances/fin"
"github.com/keep94/finances/fin/autoimport"
"github.com/keep94/finances/fin/categories"
"github.com/keep94/finances/fi... |
// Package darwinamd64 contains code to generate a x86_64 architecture
// that is running on darwin. The difference between this package and
// amd64 is that darwin loads things relative to the rip register.
package darwinamd64
import (
"fmt"
"io"
"subc/compile/arch"
"subc/types"
)
type Emitter struct {
*arch.E... |
// Copyright 2013 <NAME>. All rights reserved.
// Use of this source code is governed by a MIT-style
// license that can be found in the LICENSE file.
//go:generate autoreadme -f -template=README.md.template
/*
Package rez provides image resizing in pure Go and SIMD.
Featuring:
- YCbCr, RGBA, NRGBA & Gray resizes
... |
// Code generated by go-swagger; DO NOT EDIT.
package dynatrace
// This file was generated by the swagger tool.
// Editing this file might prove futile when you re-run the swagger generate command
import (
"bytes"
"encoding/json"
"io"
"io/ioutil"
"github.com/go-openapi/errors"
"github.com/go-openapi/runtime"
... |
/*
Copyright 2016 The Kubernetes Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, ... |
package utils
import (
"fmt"
"time"
"encoding/json"
"math/rand"
)
// RGB is a simple wrapper around RGB integers
type RGB struct {
Red int
Green int
Blue int
}
func NewRGB(red int, green int, blue int) RGB {
return RGB{red, green, blue}
}
func (r RGB) String() string {
return fmt.Sprintf("rgb(%v,%v,%v)... |
// Copyright (c) 2022, <NAME> and the Choria Project contributors
//
// SPDX-License-Identifier: Apache-2.0
package replicator
import (
"context"
"encoding/json"
"fmt"
"strings"
"sync"
"sync/atomic"
"time"
"github.com/choria-io/stream-replicator/advisor"
"github.com/choria-io/stream-replicator/backoff"
"gi... |
package main
import (
"fmt"
"strings"
)
func main() {
var b strings.Builder
b.WriteString("const (\n")
for _, line := range strings.Split(s, "\n") {
if len(line) <= 0 {
continue
}
if strings.HasPrefix(line, "const") {
continue
}
if strings.HasPrefix(line, ")") {
continue
}
f := strings.Fie... |
package main
import (
"flag"
"fmt"
"net"
"os"
"os/signal"
"path"
"path/filepath"
"runtime"
"strings"
"syscall"
"time"
"github.com/Sirupsen/logrus"
"github.com/blang/semver"
"github.com/cloudfoundry/gunk/command_runner"
"github.com/docker/docker/daemon/graphdriver"
"github.com/docker/docker/graph"
_ "... |
package farmhash
// Based on the original C++ farmhashcc.cc
// This file provides a 32-bit hash equivalent to CityHash32 (v1.1.1)
// and a 128-bit hash equivalent to CityHash128 (v1.1.1). It also provides
// a seeded 32-bit hash function similar to CityHash32.
func hash32Len13to24(s []byte) uint32 {
len := uint64(... |
package store
import (
"fmt"
ics23 "github.com/confio/ics23/go"
"github.com/cosmos/iavl"
"github.com/pkg/errors"
"github.com/spf13/viper"
tmcrypto "github.com/tendermint/tendermint/proto/tendermint/crypto"
"io"
"reflect"
"sync"
sdk "github.com/ci123chain/ci123chain/pkg/abci/types"
"github.com/ci123chain/ci... |
package quic
import (
proto "github.com/golang/protobuf/proto"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
reflect "reflect"
sync "sync"
protocol "v2ray.com/core/common/protocol"
serial "v2ray.com/core/common/serial"
)
const (
// Veri... |
package rlwe
import (
"encoding/json"
"fmt"
"math"
"math/big"
"math/bits"
"github.com/ldsec/lattigo/v2/ring"
"github.com/ldsec/lattigo/v2/utils"
)
// MaxLogN is the log2 of the largest supported polynomial modulus degree.
const MaxLogN = 16
// MinLogN is the log2 of the smallest supported polynomial modulus ... |
// Copyright (c) 2020 Cisco and/or its affiliates.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at:
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by app... |
/*
Package crossword provides functions to read crossword puzzles
in the AcrossLite PUZ file format and render them as PDF files.
*/
package crossword
import (
"bufio"
"bytes"
"fmt"
"io"
"io/ioutil"
"math/bits"
"strings"
"golang.org/x/text/encoding/charmap"
)
type (
Puzzle struct {
Header []byte
Check... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: ligato/kvscheduler/value_status.proto
package kvscheduler
import (
fmt "fmt"
proto "github.com/golang/protobuf/proto"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = m... |
/*
Copyright SecureKey Technologies Inc. All Rights Reserved.
SPDX-License-Identifier: Apache-2.0
*/
package msp
import (
"strconv"
"strings"
"github.com/pkg/errors"
"regexp"
"io/ioutil"
"github.com/aiguo186/fabric-sdk-go-gm/pkg/common/providers/core"
"github.com/aiguo186/fabric-sdk-go-... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: envoy/config/trace/v3/opencensus.proto
package envoy_config_trace_v3
import (
fmt "fmt"
v1 "github.com/census-instrumentation/opencensus-proto/gen-go/trace/v1"
_ "github.com/cncf/udpa/go/udpa/annotations"
v3 "github.com/envoyproxy/go-control-plane/envoy/... |
/*
* The MIT License (MIT)
*
* Copyright (c) 2019 HereweTech Co.LTD
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
*... |
// Copyright 2016 Prometheus Team
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in wri... |
// Package dfc is a scalable object-storage based caching system with Amazon and Google Cloud backends.
/*
* Copyright (c) 2018, NVIDIA CORPORATION. All rights reserved.
*
*/
package dfc
import (
"flag"
"fmt"
"os"
"strings"
"time"
"github.com/NVIDIA/dfcpub/3rdparty/glog"
)
const (
KiB = 1024
MiB = 1024 * ... |
package plugins
import (
"fmt"
"log"
"math"
"reflect"
"time"
"math/rand"
"github.com/stellar/go/build"
"github.com/stellar/go/clients/horizon"
hProtocol "github.com/stellar/go/protocols/horizon"
"github.com/stellar/go/xdr"
"github.com/stellar/kelp/api"
"github.com/stellar/kelp/model"
"github.com/stellar... |
package deployment
import (
"fmt"
"github.com/golang/glog"
kapi "k8s.io/kubernetes/pkg/api"
kerrors "k8s.io/kubernetes/pkg/api/errors"
"k8s.io/kubernetes/pkg/client/record"
utilruntime "k8s.io/kubernetes/pkg/util/runtime"
deployapi "github.com/openshift/origin/pkg/deploy/api"
deployutil "github.com/openshif... |
package registry
import (
"encoding/json"
"fmt"
"github.com/hako/durafmt"
"github.com/hashicorp/logutils"
"github.com/pkg/errors"
"github.com/sirupsen/logrus"
"github.com/unionj-cloud/cast"
"github.com/unionj-cloud/go-doudou/constants"
"github.com/unionj-cloud/go-doudou/stringutils"
"github.com/unionj-cloud/... |
package atscfg
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* ... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/monitoring/v3/metric.proto
package monitoring
import (
fmt "fmt"
proto "github.com/golang/protobuf/proto"
_ "google.golang.org/genproto/googleapis/api/annotations"
_ "google.golang.org/genproto/googleapis/api/label"
metric "google.golang.org/genp... |
package server
import (
"context"
"crypto/tls"
"crypto/x509"
"encoding/json"
"fmt"
"io/ioutil"
"net"
"net/http"
"os"
"path/filepath"
"runtime/debug"
"strconv"
"strings"
"sync"
"time"
"github.com/containers/storage/pkg/idtools"
"github.com/cri-o/ocicni/pkg/ocicni"
"github.com/fsnotify/fsnotify"
"git... |
package timestream
import (
"context"
"errors"
"fmt"
"reflect"
"strconv"
"sync"
"time"
"github.com/aws/aws-sdk-go-v2/aws"
"github.com/aws/aws-sdk-go-v2/service/timestreamwrite"
"github.com/aws/aws-sdk-go-v2/service/timestreamwrite/types"
"github.com/aws/smithy-go"
"github.com/influxdata/telegraf"
intern... |
package lxd
import (
"io"
"net/http"
"github.com/gorilla/websocket"
"github.com/lxc/lxd/shared/api"
"github.com/lxc/lxd/shared/cancel"
"github.com/lxc/lxd/shared/ioprogress"
)
// The Operation type represents a currently running operation.
type Operation interface {
AddHandler(function func(api.Operation)) (... |
// Package graphql provides a low level GraphQL client.
//
// // create a client (safe to share across requests)
// client := graphql.NewClient("https://machinebox.io/graphql")
//
// // make a request
// req := graphql.NewRequest(`
// query ($key: String!) {
// items (id:$key) {
// field1... |
/*
* Copyright © 2015-2018 <NAME> <<EMAIL>>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law o... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: connect.proto
package deviced
import (
fmt "fmt"
_ "github.com/envoyproxy/protoc-gen-validate/validate"
proto "github.com/golang/protobuf/proto"
wrappers "github.com/golang/protobuf/ptypes/wrappers"
math "math"
)
// Reference imports to suppress errors... |
package main
import (
"bytes"
"fmt"
"io"
"io/ioutil"
"log"
"net/http"
_ "net/http/pprof"
"os"
"path/filepath"
"plugin"
"regexp"
"runtime/pprof"
"strings"
"text/template"
"unicode"
"github.com/Masterminds/sprig"
"github.com/gogo/protobuf/proto"
"github.com/mitchellh/go-homedir"
"github.com/spf13/cob... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: phonenumber.proto
package phonenumbers
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// ... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: envoy/service/load_stats/v2/lrs.proto
/*
Package v2 is a generated protocol buffer package.
It is generated from these files:
envoy/service/load_stats/v2/lrs.proto
It has these top-level messages:
LoadStatsRequest
LoadStatsResponse
*/
package v2
import ... |
// Package rbm provides support for Restricted Boltzmann Machines.
package rbm
import (
"encoding/json"
"github.com/r9y9/nnet" // sigmoid, matrix
"math"
"math/rand"
"os"
"time"
)
// References:
// [1] <NAME>, "A Practical Guide to Training Restricted Boltzmann Machines",
// UTML TR 2010-003.
// url: http://www.... |
/*
Copyright 2017 The Kubernetes Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, ... |
package github
import (
"context"
"encoding/json"
"fmt"
"net/http"
"net/url"
"strconv"
"strings"
"time"
"github.com/cockroachdb/errors"
"golang.org/x/time/rate"
"github.com/sourcegraph/sourcegraph/internal/extsvc/auth"
"github.com/sourcegraph/sourcegraph/internal/httpcli"
"github.com/sourcegraph/sourceg... |
package audio
import (
"math"
"math/rand"
"github.com/wdevore/Ranger-Go-IGE/api"
"github.com/wdevore/Ranger-Go-IGE/engine/maths"
)
const (
noiseBufferSize = 32
flangerBufferSize = 1024
)
type generator struct {
elapsedSinceRepeat int
period float64
periodMax float64
enableFre... |
package nl
import (
"unsafe"
)
// LinkLayer
const (
LINKLAYER_UNSPEC = iota
LINKLAYER_ETHERNET
LINKLAYER_ATM
)
// ATM
const (
ATM_CELL_PAYLOAD = 48
ATM_CELL_SIZE = 53
)
const TC_LINKLAYER_MASK = 0x0F
// Police
const (
TCA_POLICE_UNSPEC = iota
TCA_POLICE_TBF
TCA_POLICE_RATE
TCA_POLICE_PEAKRATE
TCA_POL... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.25.0
// protoc v3.13.0
// source: artifact/bitbucket.proto
package artifact
import (
proto "github.com/golang/protobuf/proto"
wrappers "github.com/golang/protobuf/ptypes/wrappers"
protoreflect "google.golang.org/protobuf/ref... |
package plugin
import (
"bufio"
"encoding/json"
"fmt"
"go-cms/global"
"go-cms/model/business"
"go-cms/myError"
bizSev "go-cms/service/business"
"go-cms/utils"
"io"
"os"
"strings"
"time"
"github.com/gogf/gf/util/gconv"
"github.com/idoubi/goz"
"github.com/tencentyun/tls-sig-api-v2-golang/tencentyun"
"mv... |
// Licensed to Elasticsearch B.V. under one or more contributor
// license agreements. See the NOTICE file distributed with
// this work for additional information regarding copyright
// ownership. Elasticsearch B.V. licenses this file to you under
// the Apache License, Version 2.0 (the "License"); you may
// not use ... |
/*
* Cadence - The resource-oriented smart contract programming language
*
* Copyright 2019-2020 <NAME>, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/cloud/datacatalog/v1/search.proto
package datacatalog
import (
fmt "fmt"
math "math"
proto "github.com/golang/protobuf/proto"
_ "github.com/golang/protobuf/ptypes/timestamp"
_ "google.golang.org/genproto/googleapis/api/annotations"
)
// Referen... |
// 制約条件のテキストを golang のコードに変換するプログラム
package main
import (
"fmt"
"go/ast"
"go/format"
"go/parser"
"go/token"
"io/ioutil"
"os"
"strconv"
"strings"
)
func main() {
os.Exit(run())
}
func run() int {
if len(os.Args) < 3 {
fmt.Fprintf(os.Stderr, "Usage %s src.txt dst.go\n", os.Args[0])
... |
package generator
import (
"fmt"
"regexp"
"strconv"
"strings"
"github.com/iotaledger/wasp/packages/iscp"
"github.com/iotaledger/wasp/tools/schema/model"
)
const enableLog = false
const (
KeyArray = "array"
KeyBaseType = "basetype"
KeyCore = "core"
KeyEvent = "event"
KeyEvents = "events"
... |
// Copyright 2021 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in w... |
// Copyright 2014 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// Support for testing against external disassembler program.
// Copied and simplified from ../../x86/x86asm/ext_test.go.
package armasm
import (
"bufio"
"... |
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// Constants
package dwarf
import "strconv"
// An Attr identifies the attribute type in a DWARF Entry's Field.
type Attr uint32
const (
AttrSibling Attr ... |
package lua
import (
"bufio"
"fmt"
"io"
"os"
"strings"
)
func functionName(l *State, d Debug) string {
switch {
case d.NameKind != "":
return fmt.Sprintf("function '%s'", d.Name)
case d.What == "main":
return "main chunk"
case d.What == "Go":
if pushGlobalFunctionName(l, d.callInfo) {
s, _ := l.ToSt... |
/*
Copyright 2017-2019 Gravitational, Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,... |
package endpointlinker
import (
"context"
"database/sql"
"encoding/json"
"fmt"
"io/ioutil"
"math"
"os"
"regexp"
"strconv"
"strings"
"github.com/gonum/stat"
"github.com/onc-healthit/lantern-back-end/endpointmanager/pkg/helpers"
"github.com/onc-healthit/lantern-back-end/endpointmanager/pkg/endpointmanager... |
// Copyright 2015 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in w... |
// Copyright 2018 Google Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in ... |
/*
Copyright 2021 The Alibaba Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, sof... |
// Copyright 2020 Antrea Authors
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to ... |
//
//Copyright © 2021 Yugabyte Support
//
//Licensed under the Apache License, Version 2.0 (the "License");
//you may not use this file except in compliance with the License.
//You may obtain a copy of the License at
//
//http://www.apache.org/licenses/LICENSE-2.0
//
//Unless required by applicable law or agreed to in ... |
// Copyright 2016 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
package node
import (
"sync"
"time"
"go.fuchsia.dev/fuchsia/src/lib/thinfs/fs"
"go.fuchsia.dev/fuchsia/src/lib/thinfs/fs/msdosfs/bootrecord"
"go.fuc... |
// Copyright 2020 The Kubeflow Authors
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// https://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed ... |
package httpclient_test
import (
"context"
"errors"
"io"
"net"
"net/http"
"net/http/httptest"
"net/url"
"os"
"path/filepath"
"regexp"
"strings"
"sync"
"sync/atomic"
"testing"
"time"
"github.com/gin-gonic/gin"
"github.com/honeycombio/beeline-go/propagation"
"golang.org/x/net/http/httpproxy"
"golang.... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/ads/googleads/v0/errors/resource_count_limit_exceeded_error.proto
package errors // import "google.golang.org/genproto/googleapis/ads/googleads/v0/errors"
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
// Referenc... |
/*
Copyright 2021 Antrea Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software... |
// Package p contains an HTTP Cloud Function.
package p
import (
// "bytes"
"context"
// "encoding/binary"
"encoding/json"
"fmt"
"io"
"log"
"net/http"
"sort"
"strconv"
"sync"
"time"
"cloud.google.com/go/bigtable"
)
type cumulativeResult struct {
AllTime map[string]map[string]float64
AllTim... |
/*
Copyright 2021.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed un... |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may ... |
// Copyright (c) 2021 SAP SE or an SAP affiliate company. All rights reserved. This file is licensed under the Apache Software License, v. 2 except as noted otherwise in the LICENSE file
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the Lice... |
/*
Copyright 2019 The Kubernetes Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, ... |
package blaster
import (
"bytes"
"compress/gzip"
"context"
"encoding/json"
"errors"
"fmt"
"io"
"io/ioutil"
"net"
"net/http"
"net/url"
"strings"
"syscall"
"time"
"github.com/InVisionApp/go-logger"
"github.com/opentracing/opentracing-go"
)
const (
requestIDHeader = "Request-ID"
requestSourceHead... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/ads/googleads/v1/enums/custom_placeholder_field.proto
package enums // import "google.golang.org/genproto/googleapis/ads/googleads/v1/enums"
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import _ "google.golang.or... |
package gateway
import (
"context"
"errors"
"fmt"
"math"
"sync"
"time"
"github.com/TheRockettek/Sandwich-Producer/client"
"github.com/TheRockettek/Sandwich-Producer/events"
"github.com/go-redis/redis/v8"
"github.com/nats-io/nats.go"
"github.com/nats-io/stan.go"
"github.com/rs/zerolog"
)
// ErrNoTokenProv... |
package openapi
// schema的生成器,参考项目:https://github.com/alecthomas/jsonschema
// Package jsonschema uses reflection to generate JSON Schemas from Go types [1].
//
// If json tags are present on struct fields, they will be used to infer
// property names and if a property is required (omitempty is present).
//
// [1] htt... |
package uadmin
import (
"fmt"
"net/http"
"net/url"
"os"
"reflect"
"regexp"
"strings"
"time"
// import upportd image formats to allow exporting
// images to excel
_ "image/gif"
_ "image/jpeg"
_ "image/png"
"github.com/360EntSecGroup-Skylar/excelize/v2"
"github.com/jinzhu/gorm"
)
func getFilter(r *http... |
package calcium
import (
"context"
"encoding/json"
"fmt"
"sync"
"time"
"github.com/pkg/errors"
"github.com/sanity-io/litter"
"github.com/projecteru2/core/cluster"
enginetypes "github.com/projecteru2/core/engine/types"
"github.com/projecteru2/core/log"
"github.com/projecteru2/core/metrics"
resourcetypes "... |
package room
import (
"context"
"encoding/json"
"fmt"
"os"
"path"
"path/filepath"
"strings"
dockerTypes "github.com/docker/docker/api/types"
"github.com/docker/docker/api/types/container"
dockerMount "github.com/docker/docker/api/types/mount"
network "github.com/docker/docker/api/types/network"
"github.co... |
package storsimple
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenera... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/bigtable/admin/v2/instance.proto
package admin
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import _ "google.golang.org/genproto/googleapis/api/annotations"
// Reference imports to suppress errors if they are no... |
package pgmodels
import (
"regexp"
"strings"
"time"
"github.com/APTrust/registry/common"
"github.com/APTrust/registry/constants"
v "github.com/asaskevich/govalidator"
)
// Phone: +1234567890 (10 digits)
var rePhone = regexp.MustCompile("^\\+[0-9]{11}$")
var reNumeric = regexp.MustCompile("[^0-9]+")
const (
E... |
package db
import (
"context"
"fmt"
"path/filepath"
"strings"
"time"
"github.com/jmoiron/sqlx"
"github.com/k1LoW/harvest/config"
"github.com/k1LoW/harvest/parser"
"github.com/k1LoW/harvest/version"
"github.com/pkg/errors"
"go.uber.org/zap"
)
// DB ...
type DB struct {
ctx context.Context
db *sq... |
/*
Copyright 2019 Google LLC
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
dist... |
/*
Copyright 2019 Cisco Systems
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
d... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.