text stringlengths 8.57k 38.1k |
|---|
package attachments
import (
"fmt"
"io"
"io/ioutil"
"os"
"path/filepath"
"sync"
disklru "github.com/keybase/client/go/lru"
"github.com/keybase/client/go/encrypteddb"
"github.com/keybase/client/go/chat/globals"
"github.com/keybase/client/go/chat/s3"
"github.com/keybase/client/go/chat/storage"
"github.com... |
/*
* Copyright (C) 2018 The DNA Authors
* This file is part of The DNA library.
*
* The DNA 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, or
* (at your option) ... |
package main
import (
"fmt"
"strings"
"time"
"github.com/nsf/termbox-go"
)
var modes = map[rune]CursorMode{
'i': IntegerMode,
't': StringMode,
'f': FloatingPointMode,
'p': BitPatternMode,
}
const (
EditingOffset EditMode = iota + 1
EditingSearch
EditingEpoch
EditingContent
)
type EditMode int
type Dat... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.25.0
// protoc v3.13.0
// source: wso2/discovery/config/enforcer/binary_publisher.proto
package enforcer
import (
proto "github.com/golang/protobuf/proto"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoi... |
// Copyright (c) 2020 Tigera, 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 appli... |
package io
import (
"math"
"os"
"path/filepath"
"reflect"
"testing"
"time"
"unsafe"
"github.com/alpacahq/marketstore/utils"
. "gopkg.in/check.v1"
)
// Hook up gocheck into the "go test" runner.
func Test(t *testing.T) { TestingT(t) }
type TestSuite struct{}
var _ = Suite(&TestSuite{})
type ohlc struct {
... |
package httpbp
import (
"fmt"
"html/template"
"io"
"net/http"
"strconv"
"strings"
"time"
"github.com/reddit/baseplate.go/errorsbp"
)
const (
// RetryAfterHeader is the standard "Retry-After" header key defined in RFC2616.
//
// https://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html
RetryAfterHeader = "R... |
package allocrunner
import (
"context"
"fmt"
"path/filepath"
"sync"
"time"
log "github.com/hashicorp/go-hclog"
"github.com/hashicorp/nomad/client/allocdir"
"github.com/hashicorp/nomad/client/allocrunner/interfaces"
"github.com/hashicorp/nomad/client/allocrunner/state"
"github.com/hashicorp/nomad/client/allo... |
package main
import (
"bufio"
"crypto/tls"
"flag"
"fmt"
"io"
"io/ioutil"
"log"
"math/rand"
"os"
"strings"
"time"
"github.com/fatih/color"
"gopkg.in/jcmturner/gokrb5.v7/client"
"gopkg.in/jcmturner/gokrb5.v7/config"
"gopkg.in/jcmturner/gokrb5.v7/iana/etypeID"
"gopkg.in/ldap.v2"
)
var (
debugging boo... |
/*
* 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 obta... |
/*
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, sof... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: tensorflow/core/framework/function.proto
package framework
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 _ = ... |
// elasticache-redis-cost suggests AWS ElastiCache instance types that can fit
// existing Redis instances
package main
import (
"bufio"
"bytes"
"context"
"encoding/csv"
"errors"
"flag"
"fmt"
"html/template"
"io"
"io/ioutil"
"log"
"net"
"os"
"path/filepath"
"sort"
"strconv"
"strings"
"text/tabwriter"... |
// Copyright (c) 2020-2021 The Decred developers
// Use of this source code is governed by an ISC
// license that can be found in the LICENSE file.
// Package ticketvote provides a plugin for running votes that require decred
// tickets to participate.
package ticketvote
const (
// PluginID is the unique identifier ... |
package poloniex
import (
"errors"
"fmt"
"log"
"net/http"
"net/url"
"strconv"
"time"
"github.com/gorilla/websocket"
"github.com/thrasher-/gocryptotrader/common"
"github.com/thrasher-/gocryptotrader/currency/pair"
"github.com/thrasher-/gocryptotrader/exchanges"
"github.com/thrasher-/gocryptotrader/exchange... |
package main
import (
"bufio"
"bytes"
"context"
"encoding/json"
"errors"
"fmt"
"io"
"math"
"net"
"net/http"
"net/mail"
"net/textproto"
"os"
"os/exec"
"strings"
"time"
msgproto "github.com/emersion/go-message/textproto"
)
type MessageMods interface {
Transform(m *MailContent) error
}
func mailMessa... |
package distsys
import (
"errors"
"fmt"
"github.com/UBC-NSS/pgo/distsys/trace"
"reflect"
"sync"
"github.com/UBC-NSS/pgo/distsys/tla"
"go.uber.org/multierr"
)
// ErrAssertionFailed will be returned by an archetype function in the
// generated code if an assertion fails.
var ErrAssertionFailed = errors.New("as... |
package idanalyzer
import (
"bytes"
"encoding/json"
"errors"
"fmt"
"io"
"net"
"net/http"
"net/url"
"regexp"
"strconv"
"strings"
"time"
)
type DocuPassAPI struct {
apiKey string
apiEndpoint string
companyName string
config docuPassConfig
}
type DocuPassIdentityResponse struct {
Error *A... |
package web
import (
"fmt"
"github.com/hawkwithwind/chat-bot-hub/server/rpc"
"google.golang.org/grpc"
"google.golang.org/grpc/reflection"
"log"
"net"
"os/signal"
"sync"
//"io"
"context"
"encoding/json"
"net/http"
"net/url"
"os"
"sync/atomic"
"time"
"github.com/fluent/fluent-logger-golang/fluent"
"g... |
/*
Copyright 2018 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 mapper
import (
"encoding/csv"
"fmt"
"io"
"log"
"strings"
)
var zoneMap map[string]string
func init() {
zoneMap = make(map[string]string)
csvReader := csv.NewReader(strings.NewReader(mapping))
for {
record, err := csvReader.Read()
if err == io.EOF {
break
}
if err != nil {
log.Println... |
package brian
import (
"context"
"fmt"
"github.com/BurntSushi/toml"
"github.com/brian-god/brian-go/pkg/client/xgrpc_client"
"github.com/brian-god/brian-go/pkg/client/xnacos_client"
"github.com/brian-god/brian-go/pkg/conf"
file_datasource "github.com/brian-god/brian-go/pkg/datasource/file"
http_datasource "gith... |
//
package inflect
import (
"regexp"
"strconv"
"strings"
"unicode"
)
// Rule for transforming a single word.
type Rule struct {
match, sub string
exact bool
}
// Ruleset of multiple word transformations..
type Ruleset struct {
plurals, singulars, humans, acronyms, uncountables []Rule
}
// Rules - a defa... |
package core
import (
"context"
"errors"
"fmt"
"io"
"os"
"path"
"path/filepath"
"strings"
"sync"
"time"
utilmain "gx/ipfs/QmPDEJTb3WBHmvubsLXCaqRPC8dRgvFz7A4p96dxZbJuWL/go-ipfs/cmd/ipfs/util"
oldcmds "gx/ipfs/QmPDEJTb3WBHmvubsLXCaqRPC8dRgvFz7A4p96dxZbJuWL/go-ipfs/commands"
"gx/ipfs/QmPDEJTb3WBHmvubsLXCaq... |
package kgo
import (
"bytes"
"encoding/binary"
"errors"
"fmt"
"io"
"io/ioutil"
"net"
"net/http"
"os"
"os/exec"
"os/user"
"path/filepath"
"runtime"
"runtime/debug"
"strconv"
"strings"
"syscall"
"unicode"
)
// SystemInfo 系统信息
type SystemInfo struct {
ServerName string `json:"server_name"` //服务器... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.25.0-devel
// protoc v3.17.3
// source: protos/domain/JobInterviewRequest.proto
package domain
import (
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
... |
package main
import (
"fmt"
"reflect"
"sort"
"strings"
"time"
"github.com/icza/gowut/gwu"
//"github.com/willauld/gowut/gwu"
)
/*
func getAptListOld(ji *jawaInfo) []string {
return *ji.CI.Apartments
}
*/
func strIndex(vs []string, t string) int {
for i, v := range vs {
if v == t {
return i
}
}
retur... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: operator/v1alpha1/operator.proto
package v1alpha1
import (
fmt "fmt"
proto "github.com/golang/protobuf/proto"
v1alpha1 "istio.io/api/mesh/v1alpha1"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marsh... |
// Copyright 2015 syzkaller project authors. All rights reserved.
// Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file.
package ipc
import (
"bytes"
"flag"
"fmt"
"io"
"io/ioutil"
"os"
"os/exec"
"path/filepath"
"runtime"
"strings"
"sync"
"sync/atomic"
"time"
"u... |
// Copyright 2015 The LUCI Authors. All rights reserved.
// Use of this source code is governed under the Apache License, Version 2.0
// that can be found in the LICENSE file.
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.26.0
// protoc v3.12.1
// source: go.chromium.org/lu... |
package baseapp
import (
"fmt"
"io"
"runtime/debug"
"strings"
"github.com/pkg/errors"
abci "github.com/tendermint/tendermint/abci/types"
"github.com/tendermint/tendermint/crypto/tmhash"
cmn "github.com/tendermint/tendermint/libs/common"
dbm "github.com/tendermint/tendermint/libs/db"
"github.com/tendermint/... |
package kubernetes
import (
"fmt"
"io"
"io/ioutil"
"log"
"os"
"path"
"path/filepath"
"regexp"
"strconv"
"strings"
"time"
"github.com/docker/distribution/reference"
"github.com/hashicorp/go-multierror"
"github.com/opencontainers/go-digest"
"github.com/pkg/errors"
batchv1 "k8s.io/api/batch/v1"
v1 "k8s.... |
package pac
import (
"encoding/hex"
"testing"
"time"
"github.com/braams/gokrb5/test/testdata"
"github.com/stretchr/testify/assert"
"gopkg.in/jcmturner/rpc.v1/mstypes"
)
func TestKerbValidationInfo_Unmarshal(t *testing.T) {
t.Parallel()
b, err := hex.DecodeString(testdata.MarshaledPAC_Kerb_Validation_Info_MS)... |
// SPDX-License-Identifier: Unlicense OR MIT
package app
import (
"errors"
"fmt"
"image"
"reflect"
"runtime"
"sort"
"strings"
"sync"
"time"
"unicode"
"unsafe"
syscall "golang.org/x/sys/windows"
"gioui.org/app/internal/windows"
"gioui.org/unit"
gowindows "golang.org/x/sys/windows"
"gioui.org/f32"
"... |
/*
* 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 obta... |
package http_test
import (
"bytes"
"fmt"
"github.com/gocarina/gocsv"
"github.com/pierrec/lz4"
"io"
"math/rand"
"net/http"
"net/http/httptest"
"net/url"
"testing"
)
type TestDataStrings struct {
Foo string
Bar string
Baz string
Qux int
}
type TestDataInts struct {
Foo int
Bar int
Baz int
Qux int
}
... |
// Copyright 2020-2021 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... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.25.0
// protoc v3.16.0
// source: envoy/config/filter/http/ip_tagging/v2/ip_tagging.proto
package envoy_config_filter_http_ip_tagging_v2
import (
_ "github.com/cncf/xds/go/udpa/annotations"
core "github.com/envoyproxy/go-cont... |
// Package migrate provides tooling to migrate data from InfluxDB 1.x to 2.x
package migrate
import (
"bytes"
"context"
"encoding/binary"
"errors"
"fmt"
"io"
"io/ioutil"
"os"
"path/filepath"
"sort"
"strconv"
"strings"
"time"
"github.com/influxdata/influxdb"
"github.com/influxdata/influxdb/bolt"
"githu... |
// 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.
// Code to parse a template.
package template
import (
"fmt"
"io"
"io/ioutil"
"reflect"
"strconv"
"strings"
"unicode"
"unicode/utf8"
)
// Errors retu... |
package main
import (
"encoding/base64"
"encoding/json"
"fmt"
"net/http"
"net/url"
"regexp"
"sort"
"strings"
"time"
"github.com/lestrrat-go/jsval"
"github.com/stripe/stripe-mock/param"
"github.com/stripe/stripe-mock/param/coercer"
"github.com/stripe/stripe-mock/spec"
)
//
// Public types
//
// DoubleSl... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: envoy/type/http_status.proto
package envoy_type
import (
fmt "fmt"
_ "github.com/cncf/udpa/go/udpa/annotations"
_ "github.com/envoyproxy/protoc-gen-validate/validate"
proto "github.com/golang/protobuf/proto"
math "math"
)
// Reference imports to suppre... |
package operator
import (
"context"
"fmt"
"sort"
"strconv"
"strings"
"time"
"k8s.io/apimachinery/pkg/runtime"
"github.com/cenk/backoff"
log "github.com/sirupsen/logrus"
"github.com/zalando-incubator/es-operator/pkg/clientset"
appsv1 "k8s.io/api/apps/v1"
v1 "k8s.io/api/core/v1"
"k8s.io/apimachinery/pkg/a... |
// 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.
package unicode_test
import (
"flag"
"fmt"
"runtime"
"sort"
"strings"
"testing"
. "unicode"
)
var upperTest = []rune{
0x41,
0xc0,
0xd8,
0x100,
0x1... |
// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package autoscaling
import (
"github.com/pkg/errors"
"github.com/pulumi/pulumi/sdk/go/pulumi"
)
// Provides an AutoScaling Group resource.
//
/... |
package financialtransaction
import (
"encoding/json"
"github.com/tim-online/go-exactonline/edm"
"github.com/tim-online/go-exactonline/rest"
"github.com/tim-online/go-exactonline/utils"
)
func NewService(rest *rest.Client) *Service {
return &Service{rest: rest}
}
type Service struct {
rest *rest.Client
}
typ... |
package v1
import (
"encoding/json"
"net/http"
"time"
)
const (
ChannelTypeTelegram string = "telegram"
ChannelTypeFacebook string = "fbmessenger"
ChannelTypeViber string = "viber"
ChannelTypeWhatsapp string = "whatsapp"
ChannelTypeSkype string = "skype"
ChannelTypeVk string = "vk"
C... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: envoy/service/auth/v3alpha/external_auth.proto
package envoy_service_auth_v3alpha
import (
context "context"
fmt "fmt"
core "github.com/altipla-consulting/envoy-api/envoy/api/v3alpha/core"
v3alpha "github.com/altipla-consulting/envoy-api/envoy/type/v3alp... |
/*
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... |
package dynamic
import (
"bytes"
"fmt"
"sort"
"strconv"
"strings"
"text/template"
"github.com/caos/orbos/internal/secret"
"github.com/caos/orbos/internal/operator/nodeagent/dep/sysctl"
"github.com/caos/orbos/internal/tree"
"github.com/caos/orbos/internal/helpers"
"github.com/prometheus/client_golang/pro... |
package main
import (
"crypto/tls"
"database/sql"
"fmt"
u "github.com/araddon/gou"
"github.com/araddon/qlbridge/expr"
"github.com/araddon/qlbridge/expr/builtins"
"github.com/araddon/qlbridge/lex"
_ "github.com/araddon/qlbridge/qlbdriver"
"github.com/araddon/qlbridge/schema"
"github.com/aws/aws-sdk-go/aws"
"... |
// Code generated from tnsnamesParser.g4 by ANTLR 4.7.2. DO NOT EDIT.
package tnsnames // tnsnamesParser
import "github.com/antlr/antlr4/runtime/Go/antlr"
// BasetnsnamesParserListener is a complete listener for a parse tree produced by tnsnamesParser.
type BasetnsnamesParserListener struct{}
var _ tnsnamesParserLis... |
// Copyright 2016 <NAME>. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package suite
import (
"bytes"
"encoding/xml"
"errors"
"fmt"
htmltemplate "html/template"
"io"
"io/ioutil"
"mime"
"os"
"path"
"strings"
"text/template"
"... |
package z80asm
import (
"fmt"
"log"
)
func b(x ...byte) []byte {
return x
}
type arg int
func arg2(arg1, arg2 arg) arg {
return 1024*arg1 + arg2
}
type argumentType int
const (
argTypeVoid = iota
argTypeReg
argTypeCC
argTypeIndReg
argTypeIndAddress
argTypeAddress
argTypeIndRegPlusInt // (ix+*)
argType... |
package secp256k1
// #include <stdlib.h>
// #include "c-secp256k1/include/secp256k1.h"
// #include "c-secp256k1/include/secp256k1_ecdh.h"
// #include "c-secp256k1/include/secp256k1_recovery.h"
/*
// https://groups.google.com/forum/#!topic/golang-nuts/pQueMFdY0mk
// for secp256k1_pubkey**
static secp256k1_pubkey** make... |
// replica.go
//
// Copyright (c) 2016, <NAME>
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
//
// 1. Redistributions of source code must retain the above copyright
// notice, this lis... |
// Copyright Suneido Software Corp. All rights reserved.
// Governed by the MIT license found in the LICENSE file.
/*
Package dnum implements decimal floating point numbers.
Uses uint64 to hold the coefficient and int8 for exponent.
Only uses 16 decimal digits.
Value is sign * .coef * 10^exp, i.e. assumed decimal to... |
// Code generated by goa v3.0.6, DO NOT EDIT.
//
// user service
//
// Command:
// $ goa gen github.com/anshap1719/go-authentication/design
package user
import (
"context"
userviews "github.com/anshap1719/go-authentication/gen/user/views"
goa "goa.design/goa/v3/pkg"
"goa.design/goa/v3/security"
)
// Service is ... |
// Copyright 2020 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 ... |
// Copyright 2021 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 codecapi is used by the codec package and by code generated by
// codec.GenerateFile. It should NOT be used directly.
package codecapi
import (
"by... |
package piazza
import (
"bytes"
"encoding/json"
"fmt"
"io/ioutil"
"net/http"
"strings"
"github.com/PuerkitoBio/goquery"
"github.com/headzoo/surf"
"github.com/headzoo/surf/browser"
"github.com/pkg/errors"
)
// LoginURL is the URL you need to login.
const LoginURL = `https://piazza.com/account/login`
// Cli... |
package ui
import (
"fmt"
"image"
"image/color"
"gioui.org/gesture"
"gioui.org/io/event"
"gioui.org/io/pointer"
"gioui.org/layout"
"gioui.org/widget"
"github.com/planetdecred/dcrlibwallet"
"github.com/planetdecred/godcr/ui/decredmaterial"
"github.com/planetdecred/godcr/ui/values"
"github.com/planetdecred... |
// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: policy/v1beta1/cfg.proto
/*
Package v1beta1 is a generated protocol buffer package.
Describes the rules used to configure Mixer's policy and telemetry features.
It is generated from these files:
policy/v1beta1/cfg.proto
It has these top-level messages:
... |
package ads126x
//Opcodes - Commands are used to access the configuration and data registers and also to control the ADC. Many of the ADC commands are stand-alone (that is, single-byte). The register write and register read commands, however, are multibyte, consisting of two opcode bytes plus the register data byte or... |
package spvwallet
import (
"github.com/btcsuite/btcd/chaincfg"
"github.com/btcsuite/btcd/chaincfg/chainhash"
peerpkg "github.com/btcsuite/btcd/peer"
"github.com/btcsuite/btcd/wire"
"net"
"time"
)
const (
maxRequestedTxns = wire.MaxInvPerMsg
maxFalsePositives = 7
)
// newPeerMsg signifies a newly connected p... |
/*
Copyright 2019 The Vitess 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, soft... |
package integration
import (
"fmt"
"io/ioutil"
"math/rand"
"os"
"os/exec"
"path/filepath"
"sort"
"strconv"
"strings"
"testing"
"time"
"github.com/containers/podman/v2/libpod/define"
"github.com/containers/podman/v2/pkg/cgroups"
"github.com/containers/podman/v2/pkg/inspect"
"github.com/containers/podman... |
// Copyright 2018 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... |
package common
import (
"encoding/json"
"fmt"
"github.com/ngaut/log"
"github.com/pkg/errors"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"regexp"
"strings"
"time"
)
type WorkMode string
const (
PLUGIN_TOPOLOGY_EVENT string = "PluginTopologyEvent"
)
const (
DUPLICATE_OBJECT_ERROR string = "42710"
)
cons... |
/*
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, ... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.27.1
// protoc (unknown)
// source: einride/example/freight/v1/shipper.proto
package freightv1
import (
_ "google.golang.org/genproto/googleapis/api/annotations"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
... |
// Copyright (c) 2020 DistAlchemist
//
// This software is released under the MIT License.
// https://opensource.org/licenses/MIT
package db
import (
"encoding/binary"
"log"
"os"
"sort"
"strings"
"github.com/willf/bitset"
"github.com/DistAlchemist/Mongongo/config"
"github.com/DistAlchemist/Mongongo/dht"
"g... |
// Copyright 2015, <NAME>. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE.md file.
package brotli
import (
"io"
"io/ioutil"
"github.com/dsnet/compress/internal"
"github.com/dsnet/compress/internal/errors"
)
type Reader struct {
InputOffset... |
package bilicoin
import (
"encoding/json"
"errors"
"fmt"
"github.com/r3inbowari/common"
. "github.com/r3inbowari/zlog"
"github.com/robfig/cron"
"github.com/sirupsen/logrus"
"math/rand"
"net/http"
"os"
"regexp"
"strconv"
"strings"
"sync"
"time"
)
type BiliQRCode struct {
Data QRCodeData `json:"dat... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: common.proto
package common
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
// This is a compile-... |
package txpool
import (
"context"
"errors"
"fmt"
"sync"
"time"
"github.com/eapache/channels"
beacon "github.com/oasisprotocol/oasis-core/go/beacon/api"
"github.com/oasisprotocol/oasis-core/go/common"
"github.com/oasisprotocol/oasis-core/go/common/cache/lru"
"github.com/oasisprotocol/oasis-core/go/common/cr... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: container.proto
package storage
import (
context "context"
fmt "fmt"
proto "github.com/golang/protobuf/proto"
empty "github.com/golang/protobuf/ptypes/empty"
wrappers "github.com/golang/protobuf/ptypes/wrappers"
common "github.com/microsoft/moc/rpc/com... |
// (c) 2021 <NAME>. MIT license.
/* Package here provides three debug printer functions: Dump, Printf, and If.
When used direct these write to the os.Stderr. If guarded by the Verbose
function, they can write to any io.StringWriter provided, or be turned off
(substituted with a noop versions). It is possible to simult... |
// Copyright 2017 <NAME>. 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 (
"github.com/g3n/engine/app"
"github.com/g3n/engine/audio"
"github.com/g3n/engine/camera"
"github.com/g3n/engine/core"
"github.com/g3n/engine... |
//
// Copyright (c) 2014-2019 Cesanta Software Limited
// 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
//
// Un... |
/*
* Copyright (C) linvon
* Date 2021/2/18 10:29
*/
package cuckoo
import (
"bytes"
"encoding/binary"
"fmt"
"io"
"math/rand"
)
// PackedTable using Permutation encoding to save 1 bit per tag
type PackedTable struct {
kDirBitsPerTag uint
kBitsPerBucket uint
kBytesPerBucket uint
kDirBitsMask uint32
... |
// Copyright (C) 2022 <NAME>. All Rights Reserved.
// Package scanner implements a lexical scanner for TOML, as defined by the
// TOML v1 specification https://toml.io/en/v1.0.0.
package scanner
import (
"bufio"
"bytes"
"fmt"
"io"
"regexp"
"strconv"
"strings"
"unicode"
)
// Token is the type of a lexical tok... |
package api
import (
"fmt"
"path"
"path/filepath"
"strings"
"time"
"github.com/hashicorp/nomad/helper"
"github.com/hashicorp/nomad/nomad/structs"
)
// MemoryStats holds memory usage related stats
type MemoryStats struct {
RSS uint64
Cache uint64
Swap uint64
MaxUsage uin... |
/*
Copyright 2021 The Crossplane 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, ... |
// Code generated by protoc-gen-go.
// source: ledger/rwset/kvrwset/kv_rwset.proto
// DO NOT EDIT!
/*
Package kvrwset is a generated protocol buffer package.
It is generated from these files:
ledger/rwset/kvrwset/kv_rwset.proto
It has these top-level messages:
KVRWSet
KVRead
KVWrite
Version
RangeQueryInfo
Que... |
// Package api provides primitives to interact with the openapi HTTP API.
//
// Code generated by github.com/deepmap/oapi-codegen version v1.9.0 DO NOT EDIT.
package api
import (
"encoding/json"
"fmt"
)
const (
Api_key_headerScopes = "api_key_header.Scopes"
)
// Defines values for SearchOverrideRuleMatch.
const (... |
// © 2013 the CatBase Authors under the WTFPL. See AUTHORS for the list of authors.
package fact
import (
"database/sql"
"embed"
"encoding/json"
"fmt"
"html/template"
"math/rand"
"net/http"
"net/url"
"regexp"
"strings"
"time"
"github.com/go-chi/chi/v5"
"github.com/rs/zerolog/log"
"github.com/jmoiron/s... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.27.1
// protoc v3.6.1
// source: log.proto
package models
import (
_ "github.com/infobloxopen/protoc-gen-gorm/options"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runt... |
package server
import (
"errors"
"fmt"
"math/rand"
"net"
"strings"
"sync"
"sync/atomic"
"time"
"unsafe"
pb "github.com/moooofly/dms-elector/proto"
"github.com/sirupsen/logrus"
"golang.org/x/net/context"
"google.golang.org/grpc"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/keepalive"
"google... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.25.0
// protoc v3.13.0
// source: as/external/api/frameLog.proto
package api
import (
proto "github.com/golang/protobuf/proto"
_ "github.com/golang/protobuf/ptypes/duration"
_ "github.com/golang/protobuf/ptypes/timestamp"
_... |
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: api/config/teams/config_request.proto
package teams
import (
fmt "fmt"
shared "github.com/chef/automate/api/config/shared"
_ "github.com/chef/automate/components/automate-grpc/protoc-gen-a2-config/api/a2conf"
proto "github.com/golang/protobuf/proto"
wra... |
package metrics
import (
"runtime"
"github.com/prometheus/client_golang/prometheus"
"github.com/grafana/grafana/pkg/setting"
)
// ExporterName is used as namespace for exposing prometheus metrics
const ExporterName = "grafana"
var (
// MInstanceStart is a metric counter for started instances
MInstanceStart pr... |
package cli
import (
"errors"
"fmt"
"io"
"math/rand"
"os"
"path"
"sort"
"strconv"
"strings"
"time"
"github.com/aws/aws-sdk-go/aws"
"github.com/aws/aws-sdk-go/service/rds"
"github.com/honeycombio/honeytail/parsers"
"github.com/honeycombio/honeytail/parsers/csv"
"github.com/honeycombio/honeytail/parsers/... |
// Copyright (C) 2019 The Android Open Source Project
//
// 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... |
// Package stress implements stress tester using "Pod" objects.
// Do not parallelize locally, instead parallelize by distributing workers across nodes.
// It uses "Update" for stressing writes, and "List" for stressing reads.
// Both Kubernetes "Create" and "Update" are same for etcd, as they are etcd mutable transact... |
// Copyright 2018 Microsoft. All rights reserved.
// MIT License
package controllers
import (
"encoding/json"
"fmt"
"reflect"
"sync"
"time"
"github.com/Azure/azure-container-networking/npm/ipsm"
"github.com/Azure/azure-container-networking/npm/metrics"
"github.com/Azure/azure-container-networking/npm/util"
... |
// Copyright 2020 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 2020 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... |
package keepalived
import (
"context"
"fmt"
"path"
"strings"
"sync"
"time"
"github.com/google/uuid"
"github.com/sensu/sensu-go/agent"
corev2 "github.com/sensu/sensu-go/api/core/v2"
corev3 "github.com/sensu/sensu-go/api/core/v3"
"github.com/sensu/sensu-go/backend/liveness"
"github.com/sensu/sensu-go/backen... |
package snowflake
import (
"database/sql"
"fmt"
"log"
"sort"
"strconv"
"strings"
"github.com/jmoiron/sqlx"
"github.com/pkg/errors"
)
// PrimaryKey structure that represents a tables primary key
type PrimaryKey struct {
name string
keys []string
}
// WithName set the primary key name
func (pk *PrimaryKey) ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.