text
stringlengths
5.51k
28.1k
package smf import ( "bytes" "reflect" "testing" . "gitlab.com/gomidi/midi/v2" ) // SpecSMF0 is an example from SMF spec for SMF type 0 var SpecSMF0 = []byte{ // header chunk 0x4D, 0x54, 0x68, 0x64, // MThd 0x00, 0x00, 0x00, 0x06, // chunk length 0x00, 0x00, // format 0 0x00, 0x01, // one track 0x00, 0x60,...
// Package binrpc implements the BINRPC protocol of Kamailio for invoking RPC functions. // This package lets you talk to a Kamailio instance from Go code. // // The ctl module must be loaded: https://www.kamailio.org/docs/modules/stable/modules/ctl.html // // The BINRPC protocol is described in "src/modules/ctl/binrpc...
package hls import ( "bytes" "compress/gzip" "context" "encoding/json" "fmt" "io" "io/ioutil" "log" "net/http" "os" "path/filepath" "strconv" "strings" "sync" "time" "github.com/Monibuca/utils/v3/codec/mpegts" . "github.com/Monibuca/engine/v3" . "github.com/Monibuca/plugin-ts/v3" . "github.com/Mon...
// 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 web import ( "os" "time" ice "github.com/shylinux/icebergs" "github.com/shylinux/icebergs/base/mdb" "github.com/shylinux/icebergs/base/nfs" kit "github.com/shylinux/toolkits" ) func _story_list(m *ice.Message, name string, key string) { if name == "" { m.Richs(STORY, HEAD, kit.MDB_FOREACH, func(key ...
package dnsresolver import ( "context" "errors" "fmt" "net" "strings" "sync" "time" "github.com/classmarkets/go-dns-resolver/cache" "github.com/miekg/dns" "golang.org/x/net/publicsuffix" ) // Resolver resolves DNS queries recursively. // // Concurrent calls to all methods are safe, but exported fields of t...
// Code generated by protoc-gen-gogo. DO NOT EDIT. // source: get_archive_diff_size.proto package archive import ( fmt "fmt" _ "github.com/gogo/protobuf/gogoproto" proto "github.com/gogo/protobuf/proto" _ "github.com/mwitkow/go-proto-validators" math "math" ) // Reference imports to suppress errors if they are ...
// DBDeployer - The MySQL Sandbox // Copyright © 2006-2018 <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 // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless require...
// Copyright ©2015 The bíogo 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 gene contains the types and methods to handle the definition of a // gene. A gene is a union of genomic sequences encoding a coherent set of // p...
package liblinear import ( "bufio" "fmt" "io/ioutil" "os" "testing" "github.com/stretchr/testify/assert" ) var tempDir, _ = ioutil.TempDir("", "temp") func TestTrainPredict(t *testing.T) { var x = make([][]Feature, 4) x[0] = make([]Feature, 2) x[1] = make([]Feature, 1) x[2] = make([]Feature, 1) x[3] = m...
// Code generated by github.com/99designs/gqlgen, DO NOT EDIT. package models import ( "fmt" "io" "strconv" ) type DPool struct { UserIDs []string `json:"userIds"` DepositIDs []string `json:"depositIds"` FunderIDs []string `json:"funderIds"` FundingIDs []string `json:"fundingIds"` ...
// Copyright (C) 2017 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 t...
package main import ( "encoding/json" "fmt" "io/ioutil" "net/http" "os" "strings" "github.com/golang/glog" "k8s.io/api/admission/v1beta1" admissionregistrationv1beta1 "k8s.io/api/admissionregistration/v1beta1" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/met...
package ifacepropagate import ( "bytes" "fmt" "go/ast" "go/format" "go/parser" "go/token" "go/types" "strings" "golang.org/x/tools/go/ast/astutil" "golang.org/x/tools/go/packages" ) const generatedPrefix = "// Code generated by github.com/euank/ifacepropagate" // PropogateInterfaces wraps the given interf...
package identity import ( "bytes" "fmt" "math/big" "sort" "time" "github.com/btcsuite/btcd/chaincfg" "github.com/btcsuite/btcutil" "github.com/pkg/errors" "github.com/tendermint/tendermint/abci/types" "github.com/tendermint/tendermint/libs/kv" "github.com/Oneledger/protocol/data/balance" "github.com/Onel...
// Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.26.0 // protoc v3.12.4 // source: freqsim.proto package pb import ( empty "github.com/golang/protobuf/ptypes/empty" timestamp "github.com/golang/protobuf/ptypes/timestamp" protoreflect "google.golang.org/protobuf/reflect/pro...
// Copyright (c) 2018 <NAME> // Use of this source code is governed by a MIT-style // license that can be found in the LICENSE file. package main import ( "errors" "fmt" "io" "os" "path/filepath" "strconv" "strings" "text/scanner" ) type SbtParserOptions struct { FilenameBase string } // ParseSbtScene pars...
// Copyright (c) 2020 - <NAME> package mongoextjson_test import ( "bytes" "fmt" "io" "os" "os/exec" "reflect" "strconv" "strings" "testing" "time" "github.com/feliixx/mongoextjson" "go.mongodb.org/mongo-driver/bson" "go.mongodb.org/mongo-driver/bson/primitive" ) var objectID primitive.ObjectID func in...
package tengo import ( "errors" "fmt" "regexp" "strings" ) // Table represents a single database table. type Table struct { Name string `json:"name"` Engine string `json:"storageEngine"` CharSet string `json:"defaultCharSet"` Collation ...
package start import ( "errors" "fmt" "io" "os" "os/exec" "path/filepath" "strings" "syscall" "github.com/coreos/go-systemd/daemon" "github.com/golang/glog" "github.com/spf13/cobra" kerrors "k8s.io/apimachinery/pkg/api/errors" utilruntime "k8s.io/apimachinery/pkg/util/runtime" "k8s.io/apimachinery/pkg/...
package exec import ( "context" "fmt" "os" "path/filepath" "runtime" "sync" "time" "github.com/hashicorp/consul-template/signals" hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/nomad/client/fingerprint" "github.com/hashicorp/nomad/drivers/shared/eventer" "github.com/hashicorp/nomad/drivers/sh...
// Copyright 2020 PingCAP, 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...
// 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 ...
/* Copyright IBM Corp. All Rights Reserved. SPDX-License-Identifier: Apache-2.0 */ package lifecycle import ( "bytes" "fmt" cb "github.com/mcc-github/blockchain-protos-go/common" pb "github.com/mcc-github/blockchain-protos-go/peer" lb "github.com/mcc-github/blockchain-protos-go/peer/lifecycle" "github.com/mcc...
/* 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 not use this f...
// Copyright 2015 - 2017 <NAME> // Copyright 2021 Yandex 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 ...
package api import ( "context" "errors" "fmt" "strings" "time" "github.com/oasisprotocol/oasis-core/go/common" "github.com/oasisprotocol/oasis-core/go/common/cbor" "github.com/oasisprotocol/oasis-core/go/common/crypto/hash" "github.com/oasisprotocol/oasis-core/go/common/crypto/signature" "github.com/oasispr...
// ------------------------------------------------------------ // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. // ------------------------------------------------------------ package config import ( "context" "encoding/asn1" "encoding/json" "fmt" "io/ioutil" "os" "sort" "strings" ...
package main import ( "bytes" "crypto/sha256" _ "embed" "encoding/base64" "encoding/hex" "encoding/json" "fmt" "math" "math/rand" "os" "strings" "text/tabwriter" "time" goaway "github.com/TwiN/go-away" "github.com/acarl005/stripansi" markdown "github.com/quackduck/go-term-markdown" ) var ( Art = ge...
/* * 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 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 jpeg implements a JPEG image decoder and encoder. // // JPEG is defined in ITU-T T.81: http://www.w3.org/Graphics/JPEG/itu-t81.pdf. package steganogo...
package rendertest import ( "image" "image/color" "math" "testing" "golang.org/x/image/colornames" "gioui.org/f32" "gioui.org/internal/f32color" "gioui.org/op" "gioui.org/op/clip" "gioui.org/op/paint" ) func TestTransformMacro(t *testing.T) { // testcase resulting from original bug when rendering layout....
// Copyright 2020 MatrixOrigin. // // 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...
package math_test import ( "fmt" "math" "math/big" "math/rand" "testing" sdkmath "github.com/cosmos/cosmos-sdk/math" "github.com/stretchr/testify/suite" ) type uintTestSuite struct { suite.Suite } func TestUnitTestSuite(t *testing.T) { suite.Run(t, new(uintTestSuite)) } func (s *uintTestSuite) SetupSuite(...
// // server.go // // Copyright (c) 2018 <NAME> // // All rights reserved. // package wef import ( "crypto/tls" "encoding/binary" "encoding/hex" "encoding/xml" "fmt" "io" "io/ioutil" "log" "net/http" "net/http/httputil" "regexp" "text/template" "unicode/utf16" "github.com/markkurossi/datalog" "github....
// 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...
package iperf import ( "context" "fmt" "math" "time" iperfv1alpha1 "github.com/jharrington22/iperf-operator/pkg/apis/iperf/v1alpha1" corev1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/types" "sigs.k8s.io/controller-runtime/pkg/client" ...
// Copyright (c) 2016 Uber Technologies, Inc. // // 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...
// Copyright 2019 The LUCI 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 ( "bytes" "encoding/json" "errors" "fmt" "io" "io/ioutil" "net/http" "net/url" "path" "strings" "time" "github.com/labstack/echo" log "github.com/sirupsen/logrus" "github.com/cloudfoundry-incubator/stratos/src/jetstream/repository/interfaces" ) // API Host Prefix to replace if the ...
package lib import ( "bytes" "fmt" "math/rand" "os" "os/exec" "path" "strconv" "strings" "sync" "time" "github.com/drand/drand/common/scheme" json "github.com/nikkolasg/hexjson" "github.com/drand/drand/chain" "github.com/drand/drand/demo/node" "github.com/drand/drand/key" "github.com/drand/drand/pro...
// Code generated by protoc-gen-go. DO NOT EDIT. // source: jarvistask.proto package jarviscorepb import proto "github.com/golang/protobuf/proto" import fmt "fmt" import math "math" import ( context "golang.org/x/net/context" grpc "google.golang.org/grpc" ) // 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.15.7 // source: blob.proto package blobpb import ( protoreflect "google.golang.org/protobuf/reflect/protoreflect" protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" ) c...
package golog import ( "fmt" "io" "os" "strings" "sync" "time" "github.com/kataras/pio" ) // Handler is the signature type for logger's handler. // // A Handler can be used to intercept the message between a log value // and the actual print operation, it's called // when one of the print functions called. //...
package git import ( "fmt" "io" "log" "net/http" "strings" ) // A smartHTTPConn implements the RemoteConn interface over the smart http // protocol. It keeps track of state such as "what protocol version did the // server initially send" and "what info have we already determined from previous // requests" type s...
package tunnel import ( "crypto/sha256" "errors" "fmt" "sync" "time" "github.com/google/uuid" "github.com/micro/go-micro/transport" "github.com/micro/go-micro/util/log" ) var ( // KeepAliveTime defines time interval we send keepalive messages to outbound links KeepAliveTime = 30 * time.Second // Reconnect...
package main import ( "flag" "fmt" "net/http" _ "net/http/pprof" "os" "os/signal" "runtime" "strings" "syscall" "time" "github.com/coreos/etcd/clientv3" "github.com/fagongzi/log" "github.com/infinivision/prophet" "github.com/infinivision/taas/pkg/cedis" "github.com/infinivision/taas/pkg/core" "github....
// +build gotask package gotasks import ( "archive/zip" "bytes" "encoding/xml" "fmt" "io" "io/ioutil" "log" "os" "path" "path/filepath" "regexp" "strings" "text/template" "github.com/huin/goutil/codegen" "github.com/ipfs/go-ipfs/Godeps/_workspace/src/github.com/huin/goupnp" "github.com/ipfs/go-ipfs/G...
package hashmonitor import ( "bufio" "context" "fmt" "github.com/SkyrisBactera/pkill" pr "github.com/shirou/gopsutil/process" "io" "os" "os/exec" "runtime" "strconv" "strings" "sync" "time" "github.com/spf13/viper" ) var DebugRaw bool // var algos = []string{ // "aeon7", // "bbscoin", // "bittube",...
// Copyright 2016 Keybase Inc. All rights reserved. // Use of this source code is governed by a BSD // license that can be found in the LICENSE file. package libkbfs import ( "os" "runtime" "sync" "time" "github.com/keybase/client/go/libkb" "github.com/keybase/client/go/logger" "github.com/keybase/client/go/p...
package host import ( "bytes" "encoding/hex" "io" "sync" "time" "gitlab.com/NebulousLabs/Sia/modules" "gitlab.com/NebulousLabs/Sia/types" "gitlab.com/NebulousLabs/errors" "gitlab.com/NebulousLabs/fastrand" "gitlab.com/NebulousLabs/siamux" ) type ( // registrySubscriptions is a helper type that holds all c...
package main import ( "errors" "fmt" "sync" // zmq "github.com/pebbe/zmq4" "io/ioutil" "log" "net/http" "net/http/httptest" // "regexp" "flag" "github.com/BenLubar/memoize" "github.com/newsworthy39/golang-https-loadbalancer/util" sdk "github.com/newsworthy39/golang-clouddom-sdk" "net" "net/url" "string...
// Copyright 2019 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 ...
package synapse import ( "context" "fmt" "log" "time" "github.com/Azure/azure-sdk-for-go/services/synapse/mgmt/2021-03-01/synapse" "github.com/Azure/go-autorest/autorest/date" "github.com/hashicorp/terraform-provider-azurerm/helpers/tf" "github.com/hashicorp/terraform-provider-azurerm/internal/clients" mssql...
package storage import ( "fmt" "math" "sync" "sync/atomic" "github.com/VictoriaMetrics/VictoriaMetrics/lib/decimal" "github.com/VictoriaMetrics/VictoriaMetrics/lib/encoding" "github.com/VictoriaMetrics/VictoriaMetrics/lib/logger" ) const ( // The maximum number of rows per block. maxRowsPerBlock = 8 * 1024 ...
/* Copyright 2020 The OpenEBS 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 2021, 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...
package core import ( "strconv" "strings" "sync" "time" "errors" "github.com/Loopring/motan-go/log" ) //-----------interface------------- // Name is a interface can get and set name. especially for extension implements type Name interface { GetName() string } // Identity : get id type Identity interface { ...
// Package terminfo implements reading terminfo files in pure go. package terminfo import ( "io" "io/ioutil" "path" "strconv" "strings" ) // Error is a terminfo error. type Error string // Error satisfies the error interface. func (err Error) Error() string { return string(err) } const ( // ErrInvalidFileSiz...
package benchmarkbbs_test import ( "context" "fmt" "math/rand" "os" "sync" "sync/atomic" "time" "code.cloudfoundry.org/bbs/models" "code.cloudfoundry.org/benchmarkbbs/reporter" "code.cloudfoundry.org/clock" "code.cloudfoundry.org/lager" "code.cloudfoundry.org/locket" "code.cloudfoundry.org/locket/lock" ...
/* 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 bytecat import ( "errors" "io" "strings" ) // emptyString is a String with an empty byte array. var emptyString = &String{bytes: make([]byte, 0)} // String is an immutable rope-like sequence of bytes that allows // for fast concatenation without the copying overhead. type String struct { bytes []byte } ...
package dell import ( "encoding/json" "reflect" "sort" "strconv" "strings" "github.com/bmc-toolbox/bmclib/devices" ) const ( // VendorID represents the id of the vendor across all packages VendorID = devices.Dell ) // CMC is the entry of the json exposed by dell // We don't need to use an maps[string] with ...
/* Copyright 2011 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 applicable law or agreed to in wr...
//////////////////////////////////////////////////////////////////////////////// // // // Copyright 2020 Broadcom. The term Broadcom refers to Broadcom Inc. and/or // // its subsidiaries. ...
package oidcdiscoveryendpoint import ( "bytes" "context" "crypto" "crypto/rsa" "crypto/x509" "encoding/base64" "encoding/json" "encoding/pem" "fmt" "strings" "time" "github.com/pkg/errors" log "github.com/sirupsen/logrus" jose "gopkg.in/square/go-jose.v2" awssdk "github.com/aws/aws-sdk-go/aws" "githu...
package helper import ( "encoding/json" "errors" "flag" "fmt" "io/ioutil" "os" "path/filepath" "strconv" "strings" "time" "github.com/0xPolygon/polygon-edge/chain" "github.com/0xPolygon/polygon-edge/contracts/staking" "github.com/0xPolygon/polygon-edge/helper/common" helperFlags "github.com/0xPolygon/po...
package service import ( "reflect" "sort" "strings" "github.com/lyraproj/issue/issue" "github.com/lyraproj/puppet-evaluator/eval" "github.com/lyraproj/puppet-evaluator/types" "github.com/lyraproj/servicesdk/condition" "github.com/lyraproj/servicesdk/serviceapi" "github.com/lyraproj/servicesdk/wfapi" ) type ...
package xsync import ( "fmt" "math" "sync" "sync/atomic" "unsafe" ) type mapResizeHint int const ( mapGrowHint mapResizeHint = 0 mapShrinkHint mapResizeHint = 1 ) const ( // number of entries per bucket; 3 entries lead to size of 64B // (cache line) on 64-bit machines entriesPerMapBucket = 3 // thresho...
package main import ( "fmt" GCD "github.com/vincehow/learning-go/homework/00" "math" "math/rand" "time" ) func main() { //ComputeHouseEdge(10000) //PlayCrapsOnce() // create random seed //rand.Seed(time.Now().UnixNano()) //// read in electoral votes data //testPolls := map[string]float64{"A":0.55, "B":0.49...
// Copyright 2018 PingCAP, 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...
package main import ( "encoding/json" "flag" "fmt" "io/ioutil" "log" "net/http" "os" "os/exec" "regexp" "strconv" "strings" "time" "github.com/aws/aws-sdk-go/aws" "github.com/pkg/browser" "github.com/jkueh/roo/cachedcredsprovider" "github.com/jkueh/roo/config" "github.com/aws/aws-sdk-go/aws/creden...
package web import ( "encoding/json" "errors" "fmt" "html/template" "io/ioutil" "log" "net/http" "os" "strconv" "context" pb "github.com/buoyantio/emojivoto/emojivoto-web/gen/proto" "google.golang.org/grpc/metadata" "go.opencensus.io/plugin/ochttp" ) type WebApp struct { emojiServiceClient pb.EmojiSer...
package accessibility // Code generated by cdproto-gen. DO NOT EDIT. import ( "errors" "github.com/chromedp/cdproto/cdp" "github.com/mailru/easyjson" "github.com/mailru/easyjson/jlexer" "github.com/mailru/easyjson/jwriter" ) // AXNodeID unique accessibility node identifier. type AXNodeID string // String retu...
package onvakv import ( "fmt" "testing" "os" "github.com/stretchr/testify/assert" ) type TestOp struct { isDel bool ignore bool key []byte value []byte } func getListAdd() []TestOp { return []TestOp{ {isDel: false, ignore: false, key: []byte("43210"), value: []byte("00")}, {isDel: false, ignore: ...
// Copyright (c) 2021 <NAME>. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. //go:build generate // +build generate package main //go:generate go run make.go generate import ( "fmt" "io" "io/ioutil" "os" "os/exec" "strconv" "string...
// Code generated by protoc-gen-go. DO NOT EDIT. // source: google/cloud/securitycenter/v1beta1/asset.proto package securitycenter import ( fmt "fmt" math "math" proto "github.com/golang/protobuf/proto" _struct "github.com/golang/protobuf/ptypes/struct" timestamp "github.com/golang/protobuf/ptypes/timestamp" _...
// Copyright 2019 ETH Zurich // // 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...
// This code is available on the terms of the project LICENSE.md file, // also available online at https://blueoakcouncil.org/license/1.0.0. package market import ( "context" "fmt" "sync" "time" "decred.org/dcrdex/dex" "decred.org/dcrdex/dex/msgjson" "decred.org/dcrdex/dex/order" "decred.org/dcrdex/server/ac...
// Code generated by protoc-gen-go. DO NOT EDIT. // source: sessions.proto package api_pb // import "github.com/gedorinku/tsugidoko-server/api" import proto "github.com/golang/protobuf/proto" import fmt "fmt" import math "math" import empty "github.com/golang/protobuf/ptypes/empty" import _ "google.golang.org/genprot...
package croupier import ( "fmt" "math" "math/rand" "os" "strconv" "strings" "time" ws "github.com/7onn/croupier/pkg/websocket" ) func ExpoFunction(odds float64, index float64) float64 { return math.Exp(index * (odds - 1.0)) } func RaiseExpo(x float64) float64 { return (1.5 - 0.5*x) * math.Exp(x-1.0) } fu...
// Copyright 2012 Google, Inc. All rights reserved. // // Use of this source code is governed by a BSD-style license // that can be found in the LICENSE file in the root of the source // tree. // The pcapdump binary implements a tcpdump-like command line tool with gopacket // using pcap as a backend data collection me...
// Copyright 2021 The Chromium 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 updater import ( "context" "encoding/hex" "errors" "fmt" "testing" "time" "infra/appengine/weetbix/internal/analysis" "infra/appengine/w...
package fastdns // Rcode denotes a 4bit field that specifies the response // code for a query. type Rcode byte // Message Response Codes, see https://www.iana.org/assignments/dns-parameters/dns-parameters.xhtml const ( RcodeNoError Rcode = 0 // No Error [DNS] RcodeFormErr Rcode = 1 //...
/* 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 transpiler. DO NOT EDIT. /** * Go Video Downloader * * Copyright 2019 Tenta, 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.or...
package cloudstorage import ( "bufio" "fmt" "io" "math" "math/rand" "os" "path" "strings" "time" "github.com/lytics/cloudstorage/logging" "github.com/pborman/uuid" "golang.org/x/net/context" "google.golang.org/cloud/storage" ) const GCSFSStorageSource = "gcsFS" var GCSRetries int = 55 //GcsFS Simple w...
// Code generated by protoc-gen-go. DO NOT EDIT. // source: google/cloud/automl/v1beta1/column_spec.proto package automl 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 oth...
// Code generated by protoc-gen-go. DO NOT EDIT. // source: google/ads/googleads/v2/resources/keyword_plan.proto package resources import ( fmt "fmt" math "math" proto "github.com/golang/protobuf/proto" wrappers "github.com/golang/protobuf/ptypes/wrappers" common "google.golang.org/genproto/googleapis/ads/googl...
package TERMINUS import ( "path/filepath" "fmt" "encoding/json" "time" "net/http" "bytes" "io/ioutil" log "github.com/sirupsen/logrus" "strconv" "strings" ) func createAllScriptFiles(params KopsConfig){ var initClusterScript = makeStartScript(params.AwsAccessKeyId, params.AwsSecretAccessKey, params.Regio...
package main import ( "bufio" "encoding/json" "fmt" "io/ioutil" "net" "os" "os/exec" "path/filepath" "regexp" goruntime "runtime" "sort" "strconv" "strings" "syscall" "time" "github.com/opencontainers/runtime-spec/specs-go" "github.com/sirupsen/logrus" "github.com/urfave/cli" ) const ( exactArgs =...
package tx import ( "context" "crypto/ecdsa" "fmt" "math/big" "time" ethereum "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" stderr "github.com/pkg/errors" callback "github.com/oasislabs/oasis-gateway/callback/client" "github.com/oas...
// Copyright 2020 DataStax // // 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 wr...
package tiny import ( "context" "embed" "encoding/json" "fmt" "html/template" "log" "net/http" "os" "path" "sync" "time" "github.com/gorilla/mux" "github.com/pthethanh/tiny/funcs" "gopkg.in/yaml.v3" ) var ( //go:embed templates defaultTemplates embed.FS ) const ( PageNotFound = "not_found" Page...
/* Copyright IBM Corporation 2020 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 di...
// Code generated by protofix; DO NOT EDIT. // 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 fix50derivativesecuritylistrequest is a format of the FIX.5.0 DerivativeSecurityListRequest message. pack...
// +build !nosound package aplay /* #cgo windows LDFLAGS: -lOpenAL32 #cgo darwin LDFLAGS: -framework OpenAL #cgo linux freebsd LDFLAGS: -lopenal #ifdef __APPLE__ # include <OpenAL/al.h> # include <OpenAL/alc.h> #else # include <AL/al.h> # include <AL/alc.h> #endif */ import "C" import ( "fmt" "io" "runtime" "sync...
package jwt import ( "crypto" "encoding/json" "errors" "os" "strings" "time" "github.com/kataras/iris/v12/context" "github.com/square/go-jose/v3" "github.com/square/go-jose/v3/jwt" ) func init() { context.SetHandlerName("iris/middleware/jwt.*", "iris.jwt") } // TokenExtractor is a function that takes a c...
package model import "fmt" // // Notice // type Notice struct { Decoding string `xml:"decoding,attr"` Type string `xml:"type,attr"` Work *Work `xml:"WORK"` Inverse []*Inverse `xml:"INVERSE"` Expression []*Expression `xml:"EXPRESSION"` Mani...
// Code generated by protoc-gen-go. DO NOT EDIT. // source: api/evaluator.proto package pb import ( context "context" fmt "fmt" proto "github.com/golang/protobuf/proto" _ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.go...