_id
stringlengths
2
7
title
stringclasses
1 value
partition
stringclasses
3 values
text
stringlengths
6
2.61k
language
stringclasses
1 value
meta_information
dict
c181100
test
// parseInt treats the given bytes as a big-endian, signed integer and returns // the result.
{ "resource": "" }
c181101
test
// parseBigInt treats the given bytes as a big-endian, signed integer and returns // the result.
{ "resource": "" }
c181102
test
// BIT STRING // parseBitString parses an ASN.1 bit string from the given byte slice and returns it.
{ "resource": "" }
c181103
test
// OBJECT IDENTIFIER // parseObjectIdentifier parses an OBJECT IDENTIFIER from the given bytes and // returns it. An object identifier is a sequence of variable length integers // that are assigned in a hierarchy.
{ "resource": "" }
c181104
test
// parseBase128Int parses a base-128 encoded int from the given offset in the // given byte slice. It returns the value and the new offset.
{ "resource": "" }
c181105
test
// parseGeneralizedTime parses the GeneralizedTime from the given byte slice // and returns the resulting time.
{ "resource": "" }
c181106
test
// PrintableString // parsePrintableString parses a ASN.1 PrintableString from the given byte // array and returns it.
{ "resource": "" }
c181107
test
// isPrintable reports whether the given b is in the ASN.1 PrintableString set.
{ "resource": "" }
c181108
test
// parseSequenceOf is used for SEQUENCE OF and SET OF values. It tries to parse // a number of ASN.1 values from the given byte slice and returns them as a // slice of Go values of the given type.
{ "resource": "" }
c181109
test
// invalidLength returns true iff offset + length > sliceLength, or if the // addition would overflow.
{ "resource": "" }
c181110
test
// setDefaultValue is used to install a default value, from a tag string, into // a Value. It is successful if the field was optional, even if a default value // wasn't provided or it failed to install it into the Value.
{ "resource": "" }
c181111
test
// UnmarshalWithParams allows field parameters to be specified for the // top-level element. The form of the params is the same as the field tags.
{ "resource": "" }
c181112
test
// Given a tag string with the format specified in the package comment, // parseFieldParameters will parse it into a fieldParameters structure, // ignoring unknown parts of the string.
{ "resource": "" }
c181113
test
// Given a reflected Go type, getUniversalType returns the default tag number // and expected compound flag.
{ "resource": "" }
c181114
test
// DecodeString decodes the given base32 encodeed bytes
{ "resource": "" }
c181115
test
// User returns the Mail notifier.
{ "resource": "" }
c181116
test
// Save mail notifier adds a new mail notifier, it replaces the existing one if there // is already a notifier available.
{ "resource": "" }
c181117
test
// RegisterPlugin registers a plugin by name. This // is expected to happen during app startup.
{ "resource": "" }
c181118
test
//Set up the indexes for the Db //Can be called during the initialization
{ "resource": "" }
c181119
test
// Until loops until stop channel is closed, running f every period. // Catches any panics, and keeps going. f may not be invoked if // stop channel is already closed.
{ "resource": "" }
c181120
test
// logPanic logs the caller tree when a panic occurs.
{ "resource": "" }
c181121
test
// User returns the user with the given username. Error is set to // ErrMissingUser if user is not found.
{ "resource": "" }
c181122
test
// Users returns a slice of all users.
{ "resource": "" }
c181123
test
// LoadCACertFile reads in a CA cert file that may contain multiple certs // and gives you back a proper x509.CertPool for your fun and proffit
{ "resource": "" }
c181124
test
// NewAuth returns an auth
{ "resource": "" }
c181125
test
// ValidateRequest perfomrs verification on the TLS certs and chain
{ "resource": "" }
c181126
test
// Process is the main Entrypoint
{ "resource": "" }
c181127
test
// ValidateCN checks the CN of a verified peer cert and raises a 403 if the CN doesn't match any CN in the AllowedCNs list.
{ "resource": "" }
c181128
test
// ValidateOU checks the OU of a verified peer cert and raises 403 if the OU doesn't match any OU in the AllowedOUs list.
{ "resource": "" }
c181129
test
// KeyLen returns the minimum number of bytes required to represent x; the result is 1 for x == 0. // Returns 1-8.
{ "resource": "" }
c181130
test
// DefaultConfig provides a default configuration to create a certificate // signer.
{ "resource": "" }
c181131
test
// New creates a new configured certificate signer.
{ "resource": "" }
c181132
test
// New creates a new configured Vault factory.
{ "resource": "" }
c181133
test
// DefaultServiceConfig provides a default configuration to create a PKI controller.
{ "resource": "" }
c181134
test
// NewService creates a new configured PKI controller.
{ "resource": "" }
c181135
test
// PKI management.
{ "resource": "" }
c181136
test
// IsNoVaultHandlerDefined asserts a dirty string matching against the error // message provided by err. This is necessary due to the poor error handling // design of the Vault library we are using.
{ "resource": "" }
c181137
test
// New takes a configuration and returns a configured service.
{ "resource": "" }
c181138
test
// Create creates a role if it doesn't exist yet. Creating roles is idempotent // in the vault api, so no need to check if it already exists.
{ "resource": "" }
c181139
test
// CreateJob creates a basic empty configuration with some defaults.
{ "resource": "" }
c181140
test
// Run starts the job
{ "resource": "" }
c181141
test
// newWatcher is the internal function for properly setting up a new watcher.
{ "resource": "" }
c181142
test
// Start begins watching the files, sending notifications when files change. // It returns a channel that notifications are sent on.
{ "resource": "" }
c181143
test
// Stop listening for changes to the files.
{ "resource": "" }
c181144
test
// Returns true if the Watcher is actively looking for changes.
{ "resource": "" }
c181145
test
// The Add method takes a variable number of string arguments and adds those // files to the watch list, returning the number of files added.
{ "resource": "" }
c181146
test
// goroutine that cycles through the list of paths and checks for updates.
{ "resource": "" }
c181147
test
// Watching returns a list of the files being watched.
{ "resource": "" }
c181148
test
// State returns a slice of Notifications representing the files being watched // and their last event.
{ "resource": "" }
c181149
test
// Store stores an error into the request's context. It panics if the request // was not configured to store errors.
{ "resource": "" }
c181150
test
// Get retrieves an error from the request's context. It returns nil if the // request was not configured to store errors.
{ "resource": "" }
c181151
test
// Catch creates middleware that processes errors stored while serving a // request. Errors are passed to the callback, which should write them to the // response in an appropriate format. This is usually the outermost middleware // in a chain.
{ "resource": "" }
c181152
test
// Try converts a handler to a standard http.Handler, storing any error in the // request's context.
{ "resource": "" }
c181153
test
// Recover creates middleware that can recover from a panic in a handler, // storing a PanicError for future handling.
{ "resource": "" }
c181154
test
//go client for performance testing
{ "resource": "" }
c181155
test
//SyncHandler is a small wrapper around Sync which simply synchronises //all incoming connections. Use Sync if you wish to implement user authentication //or any other request-time checks.
{ "resource": "" }
c181156
test
//connect using the provided transport //and block until connection is ready
{ "resource": "" }
c181157
test
//send to connection, ensure only 1 concurrent sender
{ "resource": "" }
c181158
test
//NumConnections currently active
{ "resource": "" }
c181159
test
//Push the changes from this object to all connected clients. //Push is thread-safe and is throttled so it can be called //with abandon. Returns false if a Push is already in progress.
{ "resource": "" }
c181160
test
//non-blocking push
{ "resource": "" }
c181161
test
// OutForward ... recieve FluentRecordSet from channel, and send it to passed loggers until success.
{ "resource": "" }
c181162
test
// InTail follow the tail of file and post BulkMessage to channel.
{ "resource": "" }
c181163
test
// New creates a new Logger.
{ "resource": "" }
c181164
test
// IsReconnecting return true if a reconnecting process in progress.
{ "resource": "" }
c181165
test
// Notification is the builder
{ "resource": "" }
c181166
test
// NullNotification is the builder for tests where no side effects are desired
{ "resource": "" }
c181167
test
// New creates a new CA.
{ "resource": "" }
c181168
test
// Issue issues a new Identity with this one as its parent.
{ "resource": "" }
c181169
test
// Subject is an Option that sets a identity's subject field.
{ "resource": "" }
c181170
test
// PrivateKey is an Option for setting the identity's private key.
{ "resource": "" }
c181171
test
// NotBefore is an Option for setting the identity's certificate's NotBefore.
{ "resource": "" }
c181172
test
// NotAfter is an Option for setting the identity's certificate's NotAfter.
{ "resource": "" }
c181173
test
// IssuingCertificateURL is an Option for setting the identity's certificate's // IssuingCertificateURL.
{ "resource": "" }
c181174
test
// OCSPServer is an Option for setting the identity's certificate's OCSPServer.
{ "resource": "" }
c181175
test
// New creates a new API Client for a Telegram bot using the apiKey // provided. // It will call the GetMe method to retrieve the bots id, name and // username. // // This bot uses long polling to retrieve its updates. If a webhook was set // for the given apiKey, this will remove it.
{ "resource": "" }
c181176
test
// NewWithWebhook creates a new API client for a Telegram bot using the apiKey // provided. It will call the GetMe method to retrieve the bots id, name and // username. // In addition to the API client, a http.HandlerFunc will be returned. This // handler func reacts to webhook requests and will put updates into the // Updates channel.
{ "resource": "" }
c181177
test
// Close shuts down this client. // Until Close returns, new updates and errors will be put into the // respective channels. // Note that, if no updates are received, this function may block for up to // one minute, which is the time interval // for long polling.
{ "resource": "" }
c181178
test
// GetMe returns basic information about the bot in form of a UserResponse.
{ "resource": "" }
c181179
test
// RunBot runs a bot. // It will block until either something very bad happens or closing is closed.
{ "resource": "" }
c181180
test
// RunBotOnWebhook runs the given BotFunc with a webhook.
{ "resource": "" }
c181181
test
// NewOutgoingMessage creates a new outgoing message.
{ "resource": "" }
c181182
test
// NewOutgoingLocation creates a new outgoing location.
{ "resource": "" }
c181183
test
// NewOutgoingVenue creates a new outgoing location.
{ "resource": "" }
c181184
test
// NewOutgoingVideo creates a new outgoing video file.
{ "resource": "" }
c181185
test
// NewOutgoingVideoResend creates a new outgoing video file for re-sending.
{ "resource": "" }
c181186
test
// NewOutgoingPhoto creates a new outgoing photo.
{ "resource": "" }
c181187
test
// NewOutgoingPhotoResend creates a new outgoing photo for re-sending.
{ "resource": "" }
c181188
test
// NewOutgoingSticker creates a new outgoing sticker message.
{ "resource": "" }
c181189
test
// NewOutgoingStickerResend creates a new outgoing sticker message for // re-sending.
{ "resource": "" }
c181190
test
// NewOutgoingVoice creates a new outgoing voice note.
{ "resource": "" }
c181191
test
// NewOutgoingVoiceResend creates a new outgoing voice note for re-sending.
{ "resource": "" }
c181192
test
// NewOutgoingAudio creates a new outgoing audio file.
{ "resource": "" }
c181193
test
// NewOutgoingAudioResend creates a new outgoing audio file for re-sending.
{ "resource": "" }
c181194
test
// NewOutgoingDocument creates a new outgoing file.
{ "resource": "" }
c181195
test
// NewOutgoingDocumentResend creates a new outgoing file for re-sending.
{ "resource": "" }
c181196
test
// NewOutgoingForward creates a new outgoing, forwarded message.
{ "resource": "" }
c181197
test
// NewOutgoingChatAction creates a new outgoing chat action.
{ "resource": "" }
c181198
test
// NewOutgoingUserProfilePhotosRequest creates a new request for a users // profile photos.
{ "resource": "" }
c181199
test
// NewOutgoingKickChatMember creates a request to kick a member from a // group chat or channel.
{ "resource": "" }