text
stringlengths
3.08k
10.4k
package protocol // //Copyright 2018 Telenor Digital AS // //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...
// Copyright (c) 2015, <NAME> | MIT licensed package srapi import "net/url" // Category is a structure representing a game category, either per-game or per-level. type Category struct { // unique category ID ID string // category name, for example "Any%" Name string // link to this category on speedrun.com W...
package sec import ( "bytes" "crypto" "crypto/rand" "crypto/rsa" "crypto/x509" "encoding/base64" "encoding/pem" "errors" "log" "strings" ) type RSAType int const ( // 私钥类型 RSAPKCS1 RSAType = iota RSAPKCS8 ) // base64编码 func ToBase64(src []byte) string { return base64.StdEncoding.EncodeToString(src) } ...
package apimodels import ( "context" "encoding/json" "fmt" "io" "time" "github.com/evergreen-ci/timber" "github.com/evergreen-ci/timber/testresults" "github.com/pkg/errors" ) // Valid sort by keys. const ( CedarTestResultsSortByStart = testresults.SortByStart CedarTestResultsSortByDuration = testres...
package main import ( "encoding/csv" "fmt" "log" "math" "os" "os/exec" "regexp" "runtime" "strconv" "time" ) // Driver absolute paths to driver. const ( scyllaGoPath = "" gocqlPath = "" scyllaRustPath = "" ) var ( addr = "192.168.100.100:9042" runs = 5 workloads ...
// Package ternary is a Go library to calculate three-valued logic. // // This package is based on Kleene's strong logic of indeterminacy. // Ternary has three truth values, TRUE, FALSE and UNKNOWN. // // Numeric representation of truth values /* FALSE: -1 UNKNOWN: 0 TRUE: 1 */ // // Truth tables /* NOT(...
package main import ( "fmt" "math/rand" "strconv" "tesou.io/platform/brush-parent/brush-api/common/base" "tesou.io/platform/brush-parent/brush-core/module/spider/constants" "time" ) func abort(funcname string, err string) { panic(funcname + " failed: " + err) } func print_version(v uint32) { major := byte(v)...
package ghapi import ( "encoding/json" "fmt" "io/ioutil" "net/http" "time" database "github.com/ad/go-githublistener/db" ) // OAuthAccessResponse ... type OAuthAccessResponse struct { AccessToken string `json:"access_token"` } // UserResponse ... type UserResponse struct { Name string `json:"name"` Use...
// Zigbee Network Processor. UNP is abstraction for Zigbee/Bluetooth, ZNP is concrete Zigbee+UNP package znp import ( "context" "errors" "fmt" "log" "time" "github.com/function61/gokit/log/logex" "github.com/function61/gokit/sync/taskrunner" "github.com/function61/hautomo/pkg/ezstack/binstruct" "github.com/f...
/* 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...
// Copyright © 2020 The Knative 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 agr...
// *** WARNING: this file was generated by the Pulumi SDK Generator. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** package v20200901 import ( "context" "reflect" "github.com/pkg/errors" "github.com/pulumi/pulumi/sdk/v3/go/pulumi" ) type AFDOriginGroup struct { pulumi.Cus...
// // (C) Copyright 2019 Intel Corporation. // // 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 ...
package greenbay import ( "encoding/json" "runtime" "sync" "github.com/mongodb/amboy" "github.com/mongodb/grip" "github.com/pkg/errors" ) // Configuration defines the structure for a single greenbay test // run, including execution behavior (options) and check definitions. type Configuration struct { Options ...
// Code generated by protoc-gen-go. DO NOT EDIT. // source: infra/libs/fleet/protos/asset.proto package fleet import ( fmt "fmt" proto "github.com/golang/protobuf/proto" _go "infra/libs/fleet/protos/go" math "math" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal va...
package main import ( "fmt" "math" ) type moon struct { xp int yp int zp int xv int yv int zv int } type pair struct { p int v int } func main() { //input moons := []moon{ moon{14, 4, 5, 0, 0, 0}, moon{12, 10, 8, 0, 0, 0}, moon{1, 7, -10, 0, 0, 0}, moon{16, -5, 3, 0, 0, 0}, } for i := 0; i <...
package emails_test import ( "net/mail" "net/url" "os" "testing" "github.com/joho/godotenv" "github.com/kelseyhightower/envconfig" "github.com/stretchr/testify/require" "github.com/trisacrypto/directory/pkg/gds/config" "github.com/trisacrypto/directory/pkg/gds/emails" ) func TestEmailBuilders(t *testing.T) ...
package jsFunction import ( "fmt" "r3/db" "r3/schema" "r3/schema/caption" "r3/tools" "r3/types" "regexp" "github.com/gofrs/uuid" "github.com/jackc/pgtype" "github.com/jackc/pgx/v4" ) var ( rxPrefix = "app" // JS function prefix rxUuid = `[a-z0-9\-]{36}` // naive regex for UUIDv4 format ) fu...
package components import ( "os" "plugin" "strings" "sync" "github.com/webability-go/xcore/v2" "github.com/webability-go/xamboo/compiler" "github.com/webability-go/xamboo/components/auth" "github.com/webability-go/xamboo/components/cms" "github.com/webability-go/xamboo/components/compress" "github.com/weba...
/* Copyright <NAME> Fintech Research Institute 2017 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 la...
package platformclientv2 import ( "time" "encoding/json" "strconv" "strings" ) // Domainlogicalinterface type Domainlogicalinterface struct { // Id - The globally unique identifier for the object. Id *string `json:"id,omitempty"` // Name - The name of the entity. Name *string `json:"name,omitempty"` // D...
package yaml import ( "regexp" "strconv" "github.com/sirupsen/logrus" "gopkg.in/yaml.v3" ) var ( yamlIdent int = 2 ) // Yaml stores configuration about the file and the key value which needs to be updated. type Yaml struct { File string Key string Path string Value string } // isPositionKey checks if...
package memviz import ( "fmt" "reflect" "unsafe" ) const ( inlinable = true ignoredValue = "***" ) func (m *mapper) mapStruct(structVal reflect.Value) (nodeID, string) { uType := structVal.Type() id := m.getNodeID(structVal) key := getNodeKey(structVal) m.nodeSummaries[key] = escapeString(uType.String())...
/////////////////////////////////////////////////////////////////////// // Copyright (c) 2017 VMware, Inc. All Rights Reserved. // SPDX-License-Identifier: Apache-2.0 /////////////////////////////////////////////////////////////////////// package eventmanager import ( "fmt" "net/http" "github.com/go-openapi/runti...
package main import ( "fmt" hyperclient "github.com/Cloud-Foundations/Dominator/hypervisor/client" "github.com/Cloud-Foundations/Dominator/lib/errors" "github.com/Cloud-Foundations/Dominator/lib/log" "github.com/Cloud-Foundations/Dominator/lib/srpc" fm_proto "github.com/Cloud-Foundations/Dominator/proto/fleetma...
package types import ( "io" "time" ) type VolumeState string const ( VolumeStateNone = VolumeState("") VolumeStateCreated = VolumeState("created") VolumeStateDetached = VolumeState("detached") VolumeStateFaulted = VolumeState("faulted") VolumeStateHealthy = VolumeState("healthy") VolumeStateDegraded =...
package mailyak import ( "bytes" "crypto/rand" "encoding/hex" "fmt" "github.com/valyala/bytebufferpool" "io" "mime/multipart" "mime/quotedprintable" "net/textproto" "strings" ) func (m *Mail) buildMime(w io.Writer) error { mb, err := randomBoundary() if err != nil { return err } ab, err := randomBoun...
package entity const ( positioningModuleFailureMask byte = 0x80 // 1000 0000 serialCommunicationFailureMask byte = 0x40 // 0100 0000 communicationModuleFailureMask byte = 0x20 // 0010 0000 powerSupplyFailureMask byte = 0x10 // 0001 0000 batteryChargingFailureMask byte = 0x08 // 0000 1000 clockModul...
package nessus import ( "fmt" "net/http" "net/url" "path" "reflect" "regexp" "github.com/sirupsen/logrus" "github.com/fringeproject/fringe-runner/common" ) type NessusAPI struct { Endpoint string APIToken string UserToken string Context *common.ModuleContext } type NessusAPIError struct { Error st...
package payment import ( "context" "errors" "fmt" "math/big" "time" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/vipnode/vipnode-contract/go/vipnodepool" "github.com/vipnode/vipnode/v2/pool/store" ) // AddressMismatchError is used when we require a...
package main import ( "errors" "strconv" "strings" "golang.org/x/net/html" ) func colToInt(col string) int { col = strings.ToUpper(col) ans := 0 for _, c := range col { ans *= 26 ans += int(c) - 'A' + 1 } return ans } func getAttr(node *html.Node, arg string) string { for _, v := range node.Attr { i...
package mat import ( "math" ) const TriThreshold = 0.00000000001 func DefaultSmoothTriangle() *SmoothTriangle { return NewSmoothTriangle( NewPoint(0, 1, 0), NewPoint(-1, 0, 0), NewPoint(1, 0, 0), NewVector(0, 1, 0), NewVector(-1, 0, 0), NewVector(1, 0, 0)) } func NewSmoothTriangle(p1 Tuple4, p2 Tuple4...
package attr import ( "strings" "github.com/antchfx/xmlquery" "github.com/beevik/etree" ) const xmlns = "xmlns" type space string type prefix string type NameProvider struct { originPrefixes map[prefix]space targetPrefixes map[prefix]prefix } func NewNameProvider(attrs []xmlquery.Attr) (*NameProvider, error...
// 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...
// © <NAME> https://github.com/bengarrett/dupers // Package dupers is the blazing-fast file duplicate checker and filename search. package dupe import ( "bytes" "fmt" "path/filepath" "regexp" "sort" "strings" "time" "github.com/bengarrett/dupers/database" "github.com/bengarrett/dupers/out" "github.com/gook...
/* * * k6 - a next-generation load testing tool * Copyright (C) 2016 Load Impact * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as * published by the Free Software Foundation, either version 3 of the * License, or (at your o...
package main import ( "bufio" "encoding/json" "fmt" "io" "io/ioutil" "net" "net/http" "os" "os/exec" "shadowsocks_helper/config" "shadowsocks_helper/library/slog" "shadowsocks_helper/logic" "strconv" "strings" "syscall" "time" ) func main() { // 解析命令行参数 ip, port := getServerIpAndPort() if ip == "" ...
package ccunits import "regexp" type Measure int const ( InvalidMeasure Measure = iota Bytes Flops Percentage TemperatureC TemperatureF Rotation Hertz Time Watt Joule Cycles Requests Packets Events ) func (m *Measure) String() string { switch *m { case Bytes: return "byte" case Flops: return "...
package completion import ( "bytes" "errors" "fmt" "os" "strings" "unicode" "../conio" "../interpreter" "../lua" /* dbg "github.com/zetamatta/goutputdebugstring" */) type CompletionList struct { AllLine string List []string RawWord string // have quotation Word string Pos int } var Hook lua...
/** * go-mapbox Maps Module * Wraps the mapbox geocoding API for server side use * See https://www.mapbox.com/api-documentation/#maps for API information * * https://github.com/JayBusch/go-mapbox * Copyright 2017 <NAME> */ package maps import ( "bytes" "fmt" "image" _ "image/jpeg" _ "image/png" "io/iouti...
// Copyright 2019-present Open Networking Foundation. // // 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 calcium import ( "fmt" "io" "io/ioutil" "os" "strings" "github.com/projecteru2/core/engine" enginetypes "github.com/projecteru2/core/engine/types" "github.com/projecteru2/core/types" "github.com/projecteru2/core/utils" log "github.com/sirupsen/logrus" "golang.org/x/net/context" ) // As the name sa...
package forum import ( "database/sql" "fmt" "log" "time" ) /*uid, pid, forum, title, description, topics, topic_count, post_count," + "last_topic, last_post, tstamp, crdate, deleted, hidden from tx_typo3forum_domain_model_fo*/ type forumModel struct { uid int pid int parentForumID ...
/* Copyright 2018 DigitalOcean 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...
// Copyright 2022 Dolthub, Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to i...
/* * Copyright 2021 liyiligang. * * 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 hsm contains the API to talk to the BitBoxBase HSM. The HSM is a platform+edition flavor // of the BitBox02 firmware. There is an HSM bootloader and firmware; communication happens with // usart framing over a serial port. package hsm import ( "io" "time" bb02bootloader "github.com/digitalbitbox/bitbox0...
// Package errors helps in wrapping errors with custom type as well as a user friendly message. This is particularly useful when responding to APIs package errors import ( "fmt" "io" "net/http" "runtime" "strings" ) type errType int func (e errType) Int() int { return int(e) } // While adding a new Type, the ...
// // @Author: <NAME> <<EMAIL>> // package main import ( "net/http" "github.com/gorilla/mux" "encoding/json" ) type ResponseController struct { DB *SQL } type ResponseSingleAnswer struct { Response Response `json:"Response"` } type ResponseCreateRequest struct { Description *string `json:"description"` C...
package main import ( "path/filepath" "strconv" "strings" "github.com/yeqown/go-qrcode/v2" "github.com/yeqown/go-qrcode/writer/standard" "github.com/yeqown/go-qrcode/writer/terminal" "github.com/pkg/errors" "github.com/urfave/cli/v2" ) var copyright = `Copyright (c) 2018 yeqown Permission is hereby granted...
package gzipped import ( "fmt" "net/http" "os" "path" "sort" "strings" "github.com/golang/gddo/httputil/header" ) // Encoding represents an Accept-Encoding. All of these fields are pre-populated // in the supportedEncodings variable, except the clientPreference which is updated // (by copying a value from sup...
/* * Copyright 2020 F5 Networks * * 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...
package ga import ( "math" ) // Function to actually perform the mapping operation described in SinglePointPMX() func pmxInternal(gene Genome, bitstring Bitstring) Genome { // Copy, so as not to corrupt existing gene geneCopy := gene.Copy() // The bitstring to contain the end result, initialised to empty size of...
package rest import ( "context" "fmt" "net/http" "sync" restfulspec "github.com/emicklei/go-restful-openapi/v2" restful "github.com/emicklei/go-restful/v3" "github.com/metal-stack/metal-lib/httperrors" "go.uber.org/zap" "golang.org/x/sync/errgroup" ) // HealthStatus indicates the health of a service. type H...
package main import ( "bufio" "crypto/tls" "fmt" "net/http" "strconv" "strings" "time" ) /* stream = [ bom ] *event event = *( comment / field ) end-of-line comment = colon *any-char end-of-line field = 1*name-char [ colon [ space ] *any-char ] end-of-line end-of-line = ( cr...
// Copyright 2014,2015,2016,2017,2018,2019,2020,2021 <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 a...
package worker import ( "fmt" ) //Overseer overseet interface type Overseer interface { //Team overseer team Team() string //Introduction overseer introduction. Introduction() string //Train init given workers Train(workers []*Worker) error //Muted is overseer muted. Muted() bool //Evaluate evaluate given w...
package main import ( "fmt" "math" "math/rand" "strings" "github.com/gonum/stat" ) const ( numTenants = 1000 numReplicas = 100 replicationFactor = 3 function = "linear" ) var ( // Must be sorted by increasing avgSeries. tenantsDistribution = []struct { name string percenta...
package server import ( "crypto/tls" "embed" "encoding/base64" "errors" "fmt" "io/ioutil" "log" "net/http" "pair-ls/auth" "pair-ls/state" "strings" "text/template" _ "embed" "github.com/sourcegraph/jsonrpc2" "github.com/vearutop/statigz" ) //go:embed dist/* var static embed.FS //go:embed index.html ...
package git import ( "fmt" "io/ioutil" "os" "path/filepath" "strings" "github.com/ActiveState/cli/internal/analytics" "gopkg.in/src-d/go-git.v4" anaConsts "github.com/ActiveState/cli/internal/analytics/constants" "github.com/ActiveState/cli/internal/constants" "github.com/ActiveState/cli/internal/errs" "g...
// *** WARNING: this file was generated by the Pulumi SDK Generator. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** package ssm import ( "context" "reflect" "github.com/pkg/errors" "github.com/pulumi/pulumi/sdk/v3/go/pulumi" ) // Resource Type definition for AWS::SSM::Main...
// Copyright (c) 2021 Circonus, Inc. <<EMAIL>> // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. // package trapcheck import ( "crypto/tls" "fmt" "io/ioutil" "log" "net/http" "net/http/httptest" "net/url" "reflect" "strconv" "testing" "github.com/circo...
package server import ( "cakcuk/config" "cakcuk/domain/handler" "cakcuk/domain/model" "cakcuk/domain/repository" "cakcuk/external" jsonLib "cakcuk/utils/json" "cakcuk/utils/logging" stringLib "cakcuk/utils/string" "context" "fmt" "os" "strings" "github.com/facebookgo/inject" "github.com/jmoiron/sqlx" "...
package srvr import ( "bytes" "encoding/base64" "encoding/json" "fmt" "net/http" "net/http/httptest" "testing" ) //TestGetAll Fetches all entries func TestGetAll(t *testing.T) { fmt.Println("Testing GetAll") // Create a request to serveHTTP. We don't have any query parameters for now, so we'll // pass 'nil'...
package reporter import ( "errors" "testing" "fmt" kafka "github.com/ONSdigital/dp-kafka/v2" "github.com/ONSdigital/dp-kafka/v2/kafkatest" "github.com/ONSdigital/dp-reporter-client/model" "github.com/ONSdigital/dp-reporter-client/schema" . "github.com/smartystreets/goconvey/convey" ) var ( testInstanceID ...
package ssh import ( "errors" "fmt" "io" "net" "os" "os/user" "strings" "syscall" "golang.org/x/crypto/ssh" "golang.org/x/crypto/ssh/agent" "golang.org/x/crypto/ssh/terminal" ) type Client struct { client *ssh.Client Stderr io.Writer password string } // NewClient wraps up some of the complexity o...
package types import "github.com/antihax/optional" type Baselines struct { // The average daily amount of continuous logs this child org is expected to ingest, in GB. ContinuousIngest int64 `json:"continuousIngest,omitempty"` // The average daily amount of frequent logs this child org is expected to ingest, in GB....
// Copyright 2016 The Sandpass Authors // Copyright 2022 <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 required ...
package influxdbiox import ( "bytes" "context" "crypto/tls" "crypto/x509" "encoding/json" "fmt" "io/ioutil" "net" "strings" "google.golang.org/grpc" "google.golang.org/grpc/credentials" ) // ClientConfig contains all the options used to establish a connection. type ClientConfig struct { // Address string...
package zngio import ( "errors" "io" "os" "sync" "github.com/brimsec/zq/pkg/nano" "github.com/brimsec/zq/zbuf" "github.com/brimsec/zq/zng" "github.com/brimsec/zq/zng/resolver" ) type Ordering int const ( OrderUnknown Ordering = iota OrderAscending OrderDescending OrderUnsorted ) type TimeIndex struct {...
/* * Onshape REST API * * The Onshape REST API consumed by all clients. * * API version: 1.113 * Contact: <EMAIL> * Generated by: OpenAPI Generator (https://openapi-generator.tech) */ package onshape import ( "encoding/json" ) // BTExportTessellatedEdgesBody890AllOf struct for BTExportTessellatedEdgesBody89...
// // Code generated by go-jet DO NOT EDIT. // // WARNING: Changes to this file may cause incorrect behavior // and will be lost if the code is regenerated // package table import ( "github.com/go-jet/jet/v2/postgres" ) var PgAggregate = newPgAggregateTable() type pgAggregateTable struct { postgres.Table //Colu...
package v1 import ( "encoding/xml" ) const ( DiskFormatVMDKStreamOptimized = "http://www.vmware.com/interfaces/specifications/vmdk.html#streamOptimized" DiskFormatVMDKSparse = "http://www.vmware.com/interfaces/specifications/vmdk.html#sparse" DiskFormatISO = "http://www.ecma-international...
// https://www.willusher.io/pages/sdl2/ // https://github.com/Twinklebear/TwinklebearDev-Lessons/tree/master/Lesson6 package main import ( "fmt" "io" "os" "runtime" "winterdrache.de/bindings/sdl" "winterdrache.de/bindings/sdlutil" "winterdrache.de/bindings/ttf" ) /* * Lesson 6: True Typ...
// Copyright 2017 Pilosa Corp. // // 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...
/* A simple game where a lizard walks around a board and tries to find crickets to eat: https://www.youtube.com/watch?v=qhRNvCVVJaA */ package deeplizard import ( "fmt" "strconv" "github.com/lukemassa/go-coach/pkg/coach" ) type TileType int type Tile int type Direction int const dimension = 3 const tials = 9 ...
package main import ( "bufio" "bytes" "crypto/aes" "crypto/cipher" "encoding/json" "fmt" "io" "net/http" "os" "strconv" "strings" ) type configuration struct { Url string Outf string M3u8f string Keystr string } func main() { //copy /b F:\f\*.ts E:\f\new.ts file, err := os.Open("config.json") ...
// Peripheral: SCB_Periph System Control Block // Instances: // SCB 0xE000ED00 // Registers: // 0x00 32 CPUID CPUID Base Register // 0x04 32 ICSR Interrupt Control and State Register // 0x08 32 VTOR Vector Table Offset Register // 0x0C 32 AIRCR Application Interrupt and Reset Control Register // 0x10 32 ...
// Package main (projectupdater.go) : // These methods are for updating project. package main import ( "encoding/json" "fmt" "os" "path/filepath" "strings" "github.com/tanaikech/ggsrun/utl" "github.com/urfave/cli" ) // projectUpdateControl : Main method for updating project. func (e *Execution...
package corpustest import ( "bufio" "io/ioutil" "os" "path/filepath" "strings" "testing" "time" "github.com/kiteco/kiteco/kite-go/client/datadeps" "github.com/kiteco/kiteco/kite-go/lang" "github.com/kiteco/kiteco/kite-go/lang/lexical/lexicalcomplete/api" "github.com/kiteco/kiteco/kite-go/lang/lexical/lexic...
package freedns import ( "strings" "time" "github.com/miekg/dns" "github.com/sirupsen/logrus" "github.com/xiangyu123/cosp_dns/whitedomain" ) // spoofingProofResolver can resolve the DNS request with 100% confidence. type spoofingProofResolver struct { fastUpstreamProvider upstreamProvider cleanUpstreamProvi...
// primeiro package main // segundo momento import ( "encoding/json" "log" "net/http" "strings" "time" ) const ( _ = 1 << (iota * 10) KB MB ) type ZeroHero struct { Name string `json:"name"` ID string `json:"id"` Appearance Appearance `json:"appearance"` Biography ...
package bittrex import ( "encoding/json" "fmt" "time" "github.com/shopspring/decimal" ) type response struct { Success bool `json:"success,required"` Message string `json:"message,omitempty"` Result *json.RawMessage `json:"result,required"` } type pingResponse struct { Response string...
// Package tollbooth provides rate-limiting logic to HTTP request handler. package tollbooth import ( "net/http" "strconv" "strings" "time" "github.com/didip/tollbooth/config" "github.com/didip/tollbooth/errors" "github.com/didip/tollbooth/libstring" ) // NewLimiter is a convenience function to config.NewLimi...
// Copyright 2018 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 ...
// Diode Network Client // Copyright 2021 Diode // Licensed under the Diode License, Version 1.1 package rpc import ( "fmt" "io" "net" "strings" "sync" "time" "github.com/diodechain/diode_client/config" "github.com/diodechain/openssl" ) // E2EServer represents a proxy server that port ssl connection to local...
package crawler import ( "net/http" "net/url" "regexp" "strings" "sync" "github.com/PuerkitoBio/goquery" "github.com/Sirupsen/logrus" ) type CrawlItem struct { Url string Retries int Result Result } type Result struct { // The final (possibly redirected) url. Url string Error error CanRetry b...
package main import ( "bufio" "bytes" "flag" "fmt" "io" "io/ioutil" "log" "os" "path/filepath" "runtime/pprof" "sort" "github.com/p-id/regrep/internal/index" "github.com/p-id/regrep/internal/regexp" ) var usageMessage = `usage: regrep regexp [target-file-search] [-o target-result-output|stdout] Regrep ...
package mapping import ( "fmt" "strconv" "strings" "time" ) // Field contains name and format of every data item type Field struct { Topic string Name string Type string Format string } // Cursor contains current pointer to document type Cursor struct { ID string AT string } // Decode updates pointer...
package ratelimit import ( "context" "encoding/json" "fmt" "io" "net/http" "strconv" "time" "github.com/consensys/orchestrate/pkg/toolkit/app/http/config/dynamic" "github.com/consensys/orchestrate/pkg/toolkit/app/http/httputil" "github.com/traefik/traefik/v2/pkg/log" "golang.org/x/time/rate" ) type Builde...
package memdb import ( "sort" "github.com/lindb/lindb/pkg/lockers" "github.com/lindb/lindb/pkg/timeutil" pb "github.com/lindb/lindb/rpc/proto/field" "github.com/lindb/lindb/tsdb/field" "github.com/lindb/lindb/tsdb/tblstore" ) //go:generate mockgen -source ./timeseries_store.go -destination=./timeseries_store_m...
// Code generated by go-swagger; DO NOT EDIT. package client // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command import ( "github.com/go-openapi/runtime" httptransport "github.com/go-openapi/runtime/client" strfmt "github.com/go-ope...
package main import ( "context" "encoding/json" "fmt" "net/url" "strconv" "strings" "time" "github.com/caarlos0/env/v6" "github.com/gin-gonic/gin" "github.com/gorilla/securecookie" "github.com/pkg/errors" "github.com/sirupsen/logrus" "gopkg.in/square/go-jose.v2" acpclient "github.com/cloudentity/acp-cl...
package zerolog import ( "bytes" "encoding/json" "fmt" "github.com/getsentry/sentry-go" "github.com/rs/zerolog" "github.com/secureworks/logger/internal/common" "github.com/secureworks/logger/log" ) // An unfortunate but necessary type, as Zerolog's hook interface is // not conducive to data extraction. Older...
// Copyright © 2021 <NAME> <<EMAIL>> // SPDX-License-Identifier: Apache-2.0 // // 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 // // Unle...
package util import ( "context" "fmt" "github.com/lzbj/FileServer/util/lock" "github.com/minio/minio/cmd/logger" "github.com/spf13/afero" "os" "sync" "time" ) // FSLayer implements primitives for FS Layer. type FSStorage interface { CreateDir(ctx context.Context, network string) error CreateDirNew(ctx conte...
package main import ( "bufio" "flag" "fmt" "io" "io/ioutil" "net/http" "os" "strings" ) var ( path = "/pages/doenterpagevariables.action" poc_flag = "aaa{class java.lang.String=null}bbb" exp_flag = "kkk{Process" i_url string //url i_file string //file i_cmd string //cmd banner = ` ...
package unbrokenwing import ( "bufio" "fmt" "io" "log" "regexp" "testing" "github.com/dekelund/stdres" ) var buffer stdres.Buffer func init() { buffer = stdres.Buffer{} } var featureRegexp = regexp.MustCompile("^Feature: (?P<name>.+)$") var descriptionRegexp = regexp.MustCompile("^ ((?P<text>.+))?$") var ...
/* Copyright 2020 The cert-manager 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...
// +build windows package main import ( "context" "fmt" "os" "time" "github.com/go-kit/kit/log" "github.com/go-kit/kit/log/level" "github.com/kolide/kit/logutil" "github.com/kolide/launcher/pkg/log/eventlog" "github.com/pkg/errors" "golang.org/x/sys/windows/svc" "golang.org/x/sys/windows/svc/debug" "gola...