text stringlengths 5.51k 28.1k |
|---|
// Copyright 2021 The Cockroach 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 ... |
package main
import (
"eaciit/gdrj/model"
"eaciit/gdrj/modules"
"os"
//"runtime"
"strings"
"sync"
"time"
"github.com/eaciit/dbox"
"github.com/eaciit/orm/v1"
"github.com/eaciit/toolkit"
"flag"
)
var mutex = new(sync.Mutex)
var conn dbox.IConnection
var (
compute string
periodFrom, periodTo... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.25.0-devel
// protoc v3.17.3
// source: protos/domain/application_status_change.grpc.proto
package domain
import (
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/p... |
package main
import (
"encoding/json"
"errors"
"fmt"
"html/template"
"io/ioutil"
"math"
"math/rand"
"net/http"
"sort"
"strconv"
"strings"
"time"
"github.com/dustin/go-humanize"
"github.com/gin-gonic/gin"
"github.com/jmoiron/sqlx"
"github.com/russross/blackfriday"
"github.com/thehowl/qsql"
"golang.or... |
package transaction
import (
"bytes"
"encoding/hex"
"fmt"
"strings"
"time"
"github.com/GenesisCommunity/go-genesis/packages/consts"
"github.com/GenesisCommunity/go-genesis/packages/converter"
"github.com/GenesisCommunity/go-genesis/packages/crypto"
"github.com/GenesisCommunity/go-genesis/packages/model"
"gi... |
package localrepo
import (
"bytes"
"context"
"errors"
"fmt"
"os"
"path/filepath"
"testing"
"github.com/stretchr/testify/require"
"gitlab.com/gitlab-org/gitaly/v14/internal/git"
"gitlab.com/gitlab-org/gitaly/v14/internal/git/catfile"
"gitlab.com/gitlab-org/gitaly/v14/internal/git/gittest"
"gitlab.com/gitla... |
package main
import (
"fmt"
"io/ioutil"
"math"
"net/http"
"strconv"
"strings"
"time"
"github.com/grobie/gomemcache/memcache"
"github.com/prometheus/client_golang/prometheus"
"github.com/prometheus/client_golang/prometheus/promhttp"
"github.com/prometheus/common/log"
"github.com/prometheus/common/version"
... |
package check
import (
"luahelper-lsp/langserver/check/annotation/annotateast"
"luahelper-lsp/langserver/check/annotation/annotatelexer"
"luahelper-lsp/langserver/check/annotation/annotateparser"
"luahelper-lsp/langserver/check/common"
"luahelper-lsp/langserver/check/compiler/lexer"
"luahelper-lsp/langserver/che... |
// 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 2017 The Cockroach 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 ag... |
package httprequest
import (
"strings"
gc "gopkg.in/check.v1"
)
type checkIsJSONSuite struct{}
var _ = gc.Suite(&checkIsJSONSuite{})
var fancyDecodeErrorTests = []struct {
about string
contentType string
body string
expectError string
}{{
about: "plain text",
contentType: "text/plain; ch... |
package structs
import "github.com/ngld/fso-table-parser/pkg/parser"
const maxFireballTypes = 32
func NewShipParticleEffect(name string) parser.ContainerItem {
return Section(name,
IntegerValue("+Max particles"),
IntegerValue("+Min particles"),
FloatValue("+Max Radius"),
FloatValue("+Min Radius"),
FloatVa... |
package execution
import (
"context"
"github.com/golang/protobuf/proto"
"github.com/pkg/errors"
"github.com/cube2222/octosql"
"github.com/cube2222/octosql/storage"
)
type JoinType int
const (
INNER_JOIN JoinType = 0
LEFT_JOIN JoinType = 1
OUTER_JOIN JoinType = 2
)
func (j JoinType) String() string {
swi... |
// Copyright 2021 The gVisor 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 agree... |
/*
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... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/ads/googleads/v0/enums/criterion_type.proto
package enums // import "google.golang.org/genproto/googleapis/ads/googleads/v0/enums"
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
// Reference imports to suppress er... |
/*
Package revocation implements the RSA-B accumulator and associated zero knowledge proofs, introduced
in "Dynamic Accumulators and Application to Efficient Revocation of Anonymous Credentials",
<NAME> and <NAME>, CRYPTO 2002, DOI https://doi.org/10.1007/3-540-45708-9_5,
http://static.cs.brown.edu/people/alysyans/pape... |
// Copyright (c) 2021 Terminus, 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 agree... |
package main
import (
"archive/zip"
"bufio"
"flag"
"fmt"
"io"
"log"
"os"
"path/filepath"
"regexp"
"sort"
"strings"
"time"
)
type Entry struct {
sortName string
filename string
value string
fullPath string
modified time.Time
chosen bool
macroName string
}
const MACOS_PREFIX = "__MACOSX"
... |
package tektonlog
import (
"bufio"
"context"
"fmt"
"io"
"sort"
"strings"
"time"
"github.com/fatih/color"
"github.com/jenkins-x-plugins/jx-pipeline/pkg/cloud/buckets"
"github.com/jenkins-x-plugins/jx-pipeline/pkg/pipelines"
v1 "github.com/jenkins-x/jx-api/v4/pkg/apis/jenkins.io/v1"
"github.com/jenkins-x/jx... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: tensorflow/core/example/feature.proto
package example
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 _ = math.... |
package layout
import (
"bytes"
"fmt"
"github.com/npillmayer/gotype/engine/dom"
"github.com/npillmayer/gotype/engine/dom/w3cdom"
"github.com/npillmayer/gotype/engine/frame/box"
"github.com/npillmayer/gotype/engine/tree"
)
// DisplayMode is a type for CSS property "display".
type DisplayMode uint16
// Flags fo... |
package transcoder
import (
"bufio"
"bytes"
"context"
"encoding/json"
"fmt"
"io"
"os/exec"
"path/filepath"
"regexp"
"strconv"
"strings"
"github.com/pkg/errors"
"github.com/sirupsen/logrus"
"github.com/wailorman/fftb/pkg/ctxlog"
"github.com/wailorman/fftb/pkg/goffmpeg/ffmpeg"
"github.com/wailorman/fftb... |
package cmd
import (
"bytes"
"context"
"fmt"
"os"
"os/signal"
"path/filepath"
"runtime"
"strings"
"syscall"
"time"
"github.com/cockroachdb/errors"
"github.com/cockroachdb/logtags"
"github.com/knz/shakespeare/pkg/crdb/log"
"github.com/knz/shakespeare/pkg/crdb/log/logflags"
"github.com/knz/shakespeare/pk... |
// Copyright (c) 2012 The gocql 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 gocql
import (
"bufio"
"errors"
"fmt"
"net"
"sync"
"sync/atomic"
"time"
)
const defaultFrameSize = 4096
const flagResponse = 0x80
const ... |
// Copyright © 2020 <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 or agreed... |
package transport
import (
"bytes"
"compress/gzip"
"context"
"encoding/base64"
"io"
"net/http"
"net/url"
"strings"
"time"
"github.com/hashicorp/hcl/v2"
"github.com/sirupsen/logrus"
"github.com/zclconf/go-cty/cty"
"go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/metric"
"go.opentelemetry.i... |
package l1
import (
"bufio"
"compress/gzip"
"fmt"
"io"
"os"
"sort"
"strings"
"strconv"
"adscodex/oligo"
"adscodex/oligo/long"
"adscodex/l0"
)
type Eentry struct {
prob float64 // probability for the error to occur
lendiff int // how does the entry change the length of the oligo
ops []Eop // ac... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/ads/googleads/v3/enums/ad_group_type.proto
package enums
import (
fmt "fmt"
math "math"
proto "github.com/golang/protobuf/proto"
_ "google.golang.org/genproto/googleapis/api/annotations"
)
// Reference imports to suppress errors if they are not ... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.27.1
// protoc v3.19.0
// source: external/iam/v2/response/introspect.proto
package response
import (
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
re... |
package tachart
import (
"errors"
"fmt"
"html/template"
"os"
"strings"
"github.com/iamjinlei/go-tachart/charts"
"github.com/iamjinlei/go-tachart/components"
"github.com/iamjinlei/go-tachart/opts"
)
const (
tooltipPositionFunc = `
function(pos, params, el, elRect, size) {
var obj = {top: 10};
if (pos... |
/*
A simple reverse proxy and load balancer
supported balancing strategies:
- Round Robin
- Random
- Least Connected
Example of a json config:
{
"servers": [
{
"name": "server1",
"port": 7777,
"services": [
{
"route_prefix": "/microservice/",
"... |
/*
Copyright 2020 Elotl 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, software
dist... |
// Copyright 2014 The Prometheus 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... |
package cni
import (
"encoding/json"
"errors"
"net"
"testing"
"github.com/containernetworking/cni/pkg/skel"
"github.com/kelda/kelda/minion/ipdef"
"github.com/kelda/kelda/minion/network/openflow"
"github.com/kelda/kelda/minion/nl"
"github.com/kelda/kelda/minion/nl/nlmock"
"github.com/stretchr/testify/assert... |
// Copyright © 2019 Alibaba Co. Ltd.
//
// 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... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: replay.proto
package events
import (
fmt "fmt"
destinations "github.com/batchcorp/schemas/build/go/events/destinations"
proto "github.com/golang/protobuf/proto"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ ... |
/*
* Minio Cloud Storage, (C) 2015, 2016 Minio, 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 applica... |
/*
* Copyright © 2017 <NAME> <<EMAIL>>.
* Use of this source code is governed by an MIT-style
* license that can be found in the LICENSE file.
*/
package turbo
import (
"bytes"
"fmt"
"os"
"os/exec"
"strings"
"text/template"
)
// Generator generates proto/thrift code
type Generator struct {
RpcType s... |
// Package vanilla_actr provides functions to output the internal actr data structures in Lisp
// suitable for running using the ACT-R code, and to run those models on the Clozure Common Lisp compiler.
package vanilla_actr
import (
"fmt"
"os"
"regexp"
"runtime"
"strings"
"github.com/urfave/cli/v2"
"github.com... |
package task
import (
"context"
"fmt"
"log"
"net/url"
"os"
"sync"
"sync/atomic"
"time"
"github.com/pcelvng/task/bus"
"github.com/pcelvng/task/bus/info"
)
const (
truncTime = 10 * time.Millisecond
)
var (
defaultWorkerKillTime = time.Second * 10
defaultDoneTopic = "done"
defaultMaxInProg... |
// Copyright 2015 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.
// Command memanim creates an animation of memory accesses over time
// from a "perf mem record" profile. In the animation, the address
// space is compacted to... |
package common
import (
"embed"
"flag"
"fmt"
"github.com/kardianos/service"
"os"
"os/signal"
"path/filepath"
"strconv"
"strings"
"sync"
"syscall"
"time"
"unicode"
)
const (
APACHE string = "https://www.apache.org/licenses/LICENSE-2.0.html"
GPL2 string = "https://www.gnu.org/licenses/old-licenses/gpl-... |
// Copyright 2019 eBay Inc.
// Primary authors: <NAME>, <NAME>,
// <NAME>, and <NAME>.
//
// 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/... |
// Copyright (c) 2019 Uber 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 o... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/cloud/datalabeling/v1beta1/instruction.proto
package datalabeling
import (
fmt "fmt"
math "math"
proto "github.com/golang/protobuf/proto"
timestamp "github.com/golang/protobuf/ptypes/timestamp"
_ "google.golang.org/genproto/googleapis/api/annota... |
package bgp
import (
"encoding/binary"
"fmt"
"math"
"net"
"github.com/golang/glog"
"github.com/sbezverk/gobmp/pkg/tools"
)
// ExtCommunity defines BGP Extended Commuity
type ExtCommunity struct {
Type uint8
SubType *uint8
Value []byte
}
// IsRouteTarget return true is a specific extended community of ... |
// SPDX-FileCopyrightText: 2021 The Go-SSB Authors
//
// SPDX-License-Identifier: MIT
package sbot
import (
"context"
"crypto/rand"
"fmt"
"os"
"path/filepath"
"strconv"
"testing"
"time"
"github.com/VividCortex/gohistogram"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
"go.cry... |
package pixelproxy
import (
"context"
"fmt"
"path/filepath"
"sort"
"strings"
"sync"
"time"
"github.com/danjacques/pixelproxy/applications/pixelproxy/storage"
"github.com/danjacques/pixelproxy/applications/pixelproxy/web"
"github.com/danjacques/pixelproxy/util/logging"
"github.com/danjacques/gopushpixels/d... |
package main
import (
"fmt"
"github.com/rach/pome/Godeps/_workspace/src/github.com/jmoiron/sqlx"
_ "github.com/rach/pome/Godeps/_workspace/src/github.com/lib/pq"
"log"
nurl "net/url"
"strconv"
"strings"
)
func parseURL(url string) map[string]string {
var kvs = make(map[string]string)
u, err := nurl.Parse(url... |
/*
Package testutils implements tests for the Power-Go-Client:
Files
- integration_utils.go: Defines commonly used test functions
- integration_variables.go: Lists default values for all test variables
- example.env: An example .env which is used when overriding default test variables
- launch.json: An ... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: flyteidl/admin/schedule.proto
package admin
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 _ = math.Inf
// Th... |
package service
import (
"context"
"encoding/json"
"errors"
"fmt"
"io/ioutil"
"log"
"os"
fp "path/filepath"
"regexp"
"strconv"
"strings"
"go.mongodb.org/mongo-driver/bson/primitive"
assetFindOne "server/db/pkg/handler/asset/find_one"
buildFindOne "server/db/pkg/handler/build/find_one"
cvatTaskFind "se... |
package asset
import (
"bufio"
"context"
"fmt"
"io"
"os"
"strings"
"github.com/maruel/subcommands"
"go.chromium.org/luci/auth/client/authcli"
"go.chromium.org/luci/common/cli"
"go.chromium.org/luci/common/flag"
"go.chromium.org/luci/grpc/prpc"
"infra/cmd/shivas/cmdhelp"
"infra/cmd/shivas/site"
"infra/c... |
// Copyright 2020 WHTCORPS INC, 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... |
package main
import (
"crypto/tls"
"encoding/json"
"fmt"
"github.com/golang/glog"
"gotest.tools/assert"
"io/ioutil"
admissionv1 "k8s.io/api/admission/v1"
corev1 "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"net/http"
"net/http/httptest"
"strings"
"testing"
)
func NewWebhookServer() ... |
// home is <NAME>'s personal website.
package main
import (
"context"
"flag"
"fmt"
"html/template"
"io"
"io/ioutil"
"log"
"mime"
"net/http"
"os"
"os/signal"
"path"
"path/filepath"
"runtime"
"strings"
"sync"
"time"
"github.com/shurcooL/home/assets"
"github.com/shurcooL/home/component"
"github.com/s... |
package mutator
import (
"encoding/json"
"fmt"
"net/http"
"github.com/golang/glog"
"github.com/gorilla/mux"
"k8s.io/api/core/v1"
"k8s.io/api/extensions/v1beta1"
apierrors "k8s.io/apimachinery/pkg/api/errors"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachine... |
package jsonlogic
import (
"bytes"
"encoding/json"
"fmt"
"reflect"
"strconv"
"strings"
"github.com/dariubs/percent"
"github.com/spf13/cast"
"github.com/buger/jsonparser"
)
// Errors
var (
ErrInvalidOperation = "invalid operation: %s"
)
// Operators holds any operators
var Operators = make(map[string]func... |
// Copyright 2017 <NAME>
// Licensed under the MIT License, see LICENCE file for details.
package merkletree
import (
"bytes"
"crypto/sha256"
"encoding/json"
"errors"
"fmt"
"hash"
)
// newContent is used for the unified marshalling/unmarshalling of data
// types implementing the Content interface.
var newConte... |
package salesinvoice
import (
"encoding/json"
"errors"
"github.com/tim-online/go-exactonline/edm"
"github.com/tim-online/go-exactonline/utils"
)
type SalesInvoices []SalesInvoice
type SalesInvoice struct {
InvoiceID edm.GUID `json:"InvoiceID"` // P... |
// Copyright 2021 logmesh.io
//
// 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... |
package loadtest
import (
"fmt"
"html/template"
"sort"
"strings"
"time"
"github.com/tendermint/networks/pkg/loadtest/messages"
)
// SingleTestSummaryPlot is an HTML page template that facilitates plotting the
// summary results (using plotly.js) of a single load test.
const SingleTestSummaryPlot = `<!DOCTYPE h... |
package gizmo
import (
"fmt"
"strconv"
"strings"
)
// Step - implements Traversal
type step struct {
name string
params []interface{}
open string
close string
head *step
next *step
tail *step
}
func (s *step) String() string {
// this is the complete representation of the Step
var myValue str... |
package client
import (
"context"
"encoding/hex"
"encoding/json"
"strings"
"sync"
"sync/atomic"
"time"
"github.com/cosmos/cosmos-sdk/client"
"github.com/cosmos/cosmos-sdk/client/tx"
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/pkg/errors"
log "github.com/xlab/suplog"
"google.golang.org/grpc"
ct... |
package main
import (
"bytes"
"fmt"
"image"
"image/color"
"image/jpeg"
"log"
"math/rand"
"os"
"os/exec"
"strings"
"time"
"github.com/anthonynsimon/bild/adjust"
"github.com/disintegration/imaging"
"github.com/anthonynsimon/bild/blend"
"github.com/anthonynsimon/bild/imgio"
"github.com/anthonynsimon/bi... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: subscribe.proto
/*
Package proto is a generated protocol buffer package.
It is generated from these files:
subscribe.proto
It has these top-level messages:
SubscribeMessage
NotificationMessage
*/
package proto
import proto1 "github.com/golang/protobuf/p... |
package gfx
import (
"fmt"
"math"
"time"
"github.com/brandonnelson3/GoRender/input"
"github.com/brandonnelson3/GoRender/messagebus"
"github.com/go-gl/gl/v4.5-core/gl"
"github.com/go-gl/glfw/v3.1/glfw"
"github.com/go-gl/mathgl/mgl32"
)
const (
pi2 = math.Pi / 2.0
pi4 = math.Pi / 4.0
)
var (
// FirstPerso... |
// Copyright © 2018 Playground Global, 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 ... |
// Copyright (c) 2020 Tailscale Inc & 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 main
import (
"log"
"sort"
"strings"
"sync"
"time"
"gioui.org/app"
"gioui.org/io/system"
"gioui.org/layout"
"gioui.org/op"
"git... |
package timehelper
import (
"errors"
"github.com/apaxa-io/mathhelper"
"github.com/apaxa-io/strconvhelper"
"github.com/apaxa-io/stringshelper"
"regexp"
"strconv"
"strings"
"time"
)
const (
SecondPrecision = 0
MillisecondPrecision = 3
MicrosecondPrecision = 6
NanosecondPrecision = 9
PicosecondPrecisi... |
/*
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, ... |
// Copyright 2011 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.
package websocket
// This file implements a protocol of hybi draft.
// http://tools.ietf.org/html/draft-ietf-hybi-thewebsocketprotocol-17
import (
"bufio"
"... |
// Copyright 2019 Yunion
//
// 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 writi... |
package main
import (
"context"
"encoding/json"
"fmt"
"io/ioutil"
"net"
"net/http"
"os"
"path/filepath"
"strings"
"time"
"github.com/google/uuid"
"github.com/gorilla/mux"
"github.com/ipfs/go-datastore/namespace"
logging "github.com/ipfs/go-log/v2"
manet "github.com/multiformats/go-multiaddr/net"
"gith... |
// Copyright 2015 The go-ethereum Authors
// This file is part of the go-ethereum library.
//
// The go-ethereum library is free software: you can redistribute it and/or modify
// it under the terms of the GNU Lesser General Public License as published by
// the Free Software Foundation, either version 3 of the License... |
/*
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 daemon
import (
"fmt"
"io/ioutil"
"os"
"os/user"
"path/filepath"
"reflect"
"strconv"
"time"
ignv2_2types "github.com/coreos/ignition/config/v2_2/types"
"github.com/golang/glog"
drain "github.com/openshift/kubernetes-drain"
mcfgv1 "github.com/openshift/machine-config-operator/pkg/apis/machineconfig... |
package control
import (
"context"
"math/rand"
"net"
"os"
"path/filepath"
"strconv"
"strings"
"time"
"github.com/pkg/errors"
"github.com/rancher/k3s/pkg/cluster"
"github.com/rancher/k3s/pkg/daemons/config"
"github.com/rancher/k3s/pkg/daemons/control/deps"
"github.com/rancher/k3s/pkg/daemons/executor"
"g... |
package model
import (
"html/template"
"strconv"
"time"
arcmdl "go-common/app/service/main/archive/api"
"go-common/app/service/main/archive/model/archive"
)
var encodeTbl = []int64{
0xf3a97cb, 0x8aed379, 0xedf369a, 0x5c82647, 0xcaf6987, 0xad28536, 0xe5f2a7b, 0x72e85df,
0xac3d972, 0xca97fe5, 0xbcf5473, 0x85ad7... |
/*
Copyright (c) 2015, Alcatel-Lucent Inc
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright
notice, this list of condi... |
// Copyright 2022 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
//
// https://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in ... |
package testcommon
import (
"crypto/tls"
"github.com/docker/docker/pkg/homedir"
"github.com/drud/ddev/pkg/ddevapp"
"github.com/drud/ddev/pkg/globalconfig"
"github.com/drud/ddev/pkg/output"
"io"
"os"
"os/exec"
"path/filepath"
"runtime"
"time"
log "github.com/sirupsen/logrus"
"path"
"fmt"
"github.com/... |
// This set of code handles all functions required to configure networking
// on an openstack_compute_instance_v2 resource.
//
// This is a complicated task because it's not possible to obtain all
// information in a single API call. In fact, it even traverses multiple
// OpenStack services.
//
// The end result, from ... |
/*
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 goanalysis
import (
"context"
"flag"
"fmt"
"go/token"
"runtime"
"sort"
"strings"
"sync"
"sync/atomic"
"time"
"github.com/pkg/errors"
"golang.org/x/tools/go/analysis"
"golang.org/x/tools/go/packages"
"github.com/golangci/golangci-lint/internal/pkgcache"
"github.com/golangci/golangci-lint/pkg/li... |
package p2p
import (
"fmt"
"net"
"time"
"github.com/go-kit/kit/metrics"
"github.com/okex/exchain/libs/tendermint/libs/cmap"
"github.com/okex/exchain/libs/tendermint/libs/log"
"github.com/okex/exchain/libs/tendermint/libs/service"
tmconn "github.com/okex/exchain/libs/tendermint/p2p/conn"
)
const metricsTick... |
// Copyright (c) 2020 VMware, Inc. All Rights Reserved.
// SPDX-License-Identifier: Apache-2.0
package v1alpha1
import (
corev1 "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/util/intstr"
)
type VirtualMachinePowerState string
// See govmomi.vim25.types.VirtualMachine... |
// +build !js
// Package leveldb implements the key-value database layer based on LevelDB.
package leveldb
import (
"bytes"
"fmt"
"github.com/entropyio/go-entropy/common"
"github.com/entropyio/go-entropy/database"
"github.com/entropyio/go-entropy/logger"
"github.com/entropyio/go-entropy/metrics"
"github.com/op... |
package prombench
import (
"context"
"fmt"
"github.com/ncabatoff/prombench/harness"
"github.com/ncabatoff/prombench/loadgen"
api "github.com/prometheus/client_golang/api/prometheus"
"github.com/prometheus/client_golang/prometheus"
"github.com/prometheus/common/model"
"log"
"net"
"os/exec"
"strconv"
"string... |
// Copyright 2020 Nokia
// Licensed under the BSD 3-Clause License.
// SPDX-License-Identifier: BSD-3-Clause
package controllers
import (
"context"
"encoding/json"
"github.com/pkg/errors"
"k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
"k8s.io/apimachinery/pkg/runtime/schema"
"k8s.io/client-go/dynamic"
"k8... |
package lineage
import (
"fmt"
"sort"
"strings"
"time"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
unstructuredv1 "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/types"
"k8s.io/apimachinery/pkg/util/duration"
"k8s.io/client-go/util/jsonpath"
... |
/*
Copyright © 2021 NAME HERE <EMAIL ADDRESS>
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 writi... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: envoy/service/trace/v3alpha/trace_service.proto
package envoy_service_trace_v3alpha
import (
context "context"
fmt "fmt"
v1 "github.com/census-instrumentation/opencensus-proto/gen-go/trace/v1"
_ "github.com/cncf/udpa/go/udpa/annotations"
v3alpha "github... |
// Copyright The OpenTelemetry 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 ag... |
// Copyright 2015 Light Code Labs, 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 agre... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.25.0
// protoc v3.13.0
// source: inventory.proto
package types
import (
proto "github.com/golang/protobuf/proto"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/p... |
package main
import (
"fmt"
"log"
"os"
"strconv"
"strings"
"unicode"
)
var (
input_file string
buf string
filename string
keywords *Map
ctx *Context
symbols = []Keyword{
{name: "<<=", ty: TK_SHL_EQ},
{name: ">>=", ty: TK_SHR_EQ},
{name: "!=", ty: TK_NE},
{name: "&&", ty: TK_LO... |
/* types.go - Defines core interface types
*
* Author: <NAME> <<EMAIL>>
*
* This software is open source software available under the BSD-3 license.
* Copyright (c) 2018, Triad National Security, LLC
* See LICENSE file for details.
*/
package types
import (
"reflect"
"time"
proto "github.com/gogo/protobuf/... |
/*
Package statesync implements module for the P2P state synchronisation process. The
module manages state synchronisation for non-archival nodes which are joining the
network and don't have the ability to resync from the genesis block.
Given the currently available state synchronisation point P, sate sync process
inc... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.