_id
stringlengths
2
7
title
stringclasses
1 value
partition
stringclasses
3 values
text
stringlengths
6
2.61k
language
stringclasses
1 value
meta_information
dict
c16800
train
// UnmarshalJSON implements the Unmarshaller interface // as defined by the standard JSON package.
{ "resource": "" }
c16801
train
// get issues a GET request
{ "resource": "" }
c16802
train
// put issues a PUT request
{ "resource": "" }
c16803
train
// buildValues builds a url.Values map according to the given value and ttl
{ "resource": "" }
c16804
train
// Encode to Latin1.
{ "resource": "" }
c16805
train
// Decode from Latin1.
{ "resource": "" }
c16806
train
// New parses the given binary data and returns a Data object, // or nil if the field Name is unknown.
{ "resource": "" }
c16807
train
// f is only set on transceiver.
{ "resource": "" }
c16808
train
// newUnsucessDest returns a new UnsucessDest constructed from a UnSme struct
{ "resource": "" }
c16809
train
// Resp returns the response PDU, or nil if not set.
{ "resource": "" }
c16810
train
// Submit sends a short message and returns and updates the given // sm with the response status. It returns the same sm object.
{ "resource": "" }
c16811
train
// DecodeTLV scans the given byte slice to build a Map from binary data.
{ "resource": "" }
c16812
train
// Bind starts the Receiver. It creates a persistent connection // to the server, update its status via the returned channel, // and calls the registered Handler when new PDU arrives. // // Bind implements the ClientConn interface.
{ "resource": "" }
c16813
train
// DecodeHeader decodes binary PDU header data.
{ "resource": "" }
c16814
train
// SerializeTo serializes the Header to its binary form to the given writer.
{ "resource": "" }
c16815
train
// NewGenericNACK creates and initializes a GenericNACK PDU.
{ "resource": "" }
c16816
train
// NewBindReceiver creates a new Bind PDU.
{ "resource": "" }
c16817
train
// NewBindTransceiver creates a new Bind PDU.
{ "resource": "" }
c16818
train
// NewBindTransmitter creates a new Bind PDU.
{ "resource": "" }
c16819
train
// NewBindReceiverResp creates and initializes a new BindResp PDU.
{ "resource": "" }
c16820
train
// NewBindTransceiverResp creates and initializes a new BindResp PDU.
{ "resource": "" }
c16821
train
// NewBindTransmitterResp creates and initializes a new BindResp PDU.
{ "resource": "" }
c16822
train
// NewQuerySM creates and initializes a new QuerySM PDU.
{ "resource": "" }
c16823
train
// NewQuerySMResp creates and initializes a new QuerySMResp PDU.
{ "resource": "" }
c16824
train
// NewSubmitSM creates and initializes a new SubmitSM PDU.
{ "resource": "" }
c16825
train
// NewSubmitSMResp creates and initializes a new SubmitSMResp PDU.
{ "resource": "" }
c16826
train
// NewSubmitMulti creates and initializes a new SubmitMulti PDU.
{ "resource": "" }
c16827
train
// NewSubmitMultiResp creates and initializes a new SubmitMultiResp PDU.
{ "resource": "" }
c16828
train
// NewDeliverSM creates and initializes a new DeliverSM PDU.
{ "resource": "" }
c16829
train
// NewDeliverSMResp creates and initializes a new DeliverSMResp PDU.
{ "resource": "" }
c16830
train
// NewDeliverSMRespSeq creates and initializes a new DeliverSMResp PDU for a specific seq.
{ "resource": "" }
c16831
train
// NewUnbind creates and initializes a Unbind PDU.
{ "resource": "" }
c16832
train
// NewUnbindResp creates and initializes a UnbindResp PDU.
{ "resource": "" }
c16833
train
// NewEnquireLink creates and initializes a EnquireLink PDU.
{ "resource": "" }
c16834
train
// NewEnquireLinkResp creates and initializes a EnquireLinkResp PDU.
{ "resource": "" }
c16835
train
// NewEnquireLinkRespSeq creates and initializes a EnquireLinkResp PDU for a specific seq.
{ "resource": "" }
c16836
train
// NewTLV parses the given binary data and returns a Data object, // or nil if the field Name is unknown.
{ "resource": "" }
c16837
train
// Dial dials to the SMPP server and returns a Conn, or error. // TLS is only used if provided.
{ "resource": "" }
c16838
train
// Set sets the underlying Conn with the given one. // If we hold a Conn already, it will be closed before switching over.
{ "resource": "" }
c16839
train
// Close implements the Conn interface.
{ "resource": "" }
c16840
train
// Bind implements the ClientConn interface.
{ "resource": "" }
c16841
train
// init initializes the codec's list and maps and sets the header // sequence number.
{ "resource": "" }
c16842
train
// setup replaces the codec's current maps with the given ones.
{ "resource": "" }
c16843
train
// Len implements the PDU interface.
{ "resource": "" }
c16844
train
// SerializeTo implements the PDU interface.
{ "resource": "" }
c16845
train
// Encode to ISO88595.
{ "resource": "" }
c16846
train
// Decode from ISO88595.
{ "resource": "" }
c16847
train
// Hex returns hexadecimal representation of tag
{ "resource": "" }
c16848
train
// Encode to UCS2.
{ "resource": "" }
c16849
train
// Decode from UCS2.
{ "resource": "" }
c16850
train
// Returns the characters, in the given text, that can not be represented in GSM 7-bit encoding.
{ "resource": "" }
c16851
train
// Returns the bytes, in the given buffer, that are outside of the GSM 7-bit encoding range.
{ "resource": "" }
c16852
train
// Bind starts the connection manager and blocks until Close is called. // It must be called in a goroutine.
{ "resource": "" }
c16853
train
// Read reads PDU binary data off the wire and returns it.
{ "resource": "" }
c16854
train
// Write serializes the given PDU and writes to the connection.
{ "resource": "" }
c16855
train
// Close terminates the current connection and stop any further attempts.
{ "resource": "" }
c16856
train
// trysleep for the given duration, or return if Close is called.
{ "resource": "" }
c16857
train
// respTimeout returns a channel that fires based on the configured // response timeout, or the default 1s.
{ "resource": "" }
c16858
train
// bind attempts to bind the connection.
{ "resource": "" }
c16859
train
// Encode a Go struct into protocol buffer format. // The caller must pass a pointer to the struct to encode.
{ "resource": "" }
c16860
train
// GenerateProtobufDefinition generates a .proto file from a list of structs via reflection. // fieldNamer is a function that maps ProtoField types to generated protobuf field names.
{ "resource": "" }
c16861
train
// String returns an easy way to visualize what you have in your constructors.
{ "resource": "" }
c16862
train
// DecodeWithConstructors is like Decode, but you can pass a map of // constructors with which to instantiate interface types.
{ "resource": "" }
c16863
train
// Decode a Protocol Buffers message into a Go struct. // The Kind of the passed value v must be Struct.
{ "resource": "" }
c16864
train
// Pull a value from the buffer and put it into a reflective Value.
{ "resource": "" }
c16865
train
// Instantiate an arbitrary type, handling dynamic interface types. // Returns a Ptr value.
{ "resource": "" }
c16866
train
// Handle decoding of slices
{ "resource": "" }
c16867
train
// register gets the type tag and map it to the generator function
{ "resource": "" }
c16868
train
// get returns the generator associated with the tag
{ "resource": "" }
c16869
train
// WriteFile writes given endecoded file to the filesystem
{ "resource": "" }
c16870
train
// Add the provide SSH public key to the core user's list of // authorized keys
{ "resource": "" }
c16871
train
// Error adds an error entry to the report.
{ "resource": "" }
c16872
train
// Warning adds a warning entry to the report.
{ "resource": "" }
c16873
train
// Info adds an info entry to the report.
{ "resource": "" }
c16874
train
// String returns a human-readable representation of the entry.
{ "resource": "" }
c16875
train
// MarshalJSON satisfies the json.Marshaler interface, returning the entry // encoded as a JSON object.
{ "resource": "" }
c16876
train
// PlaceUnit writes a unit file at its desired destination, creating parent // directories as necessary.
{ "resource": "" }
c16877
train
// PlaceUnitDropIn writes a unit drop-in file at its desired destination, // creating parent directories as necessary.
{ "resource": "" }
c16878
train
// Child attempts to find the child with the given name in the node's list of // children. If no such child is found, an invalid node is returned.
{ "resource": "" }
c16879
train
// HumanType returns the human-consumable string representation of the type of // the node.
{ "resource": "" }
c16880
train
// NewNode returns the node representation of the given value. The context // will be used in an attempt to determine line numbers for the given value.
{ "resource": "" }
c16881
train
// findKey attempts to find the requested key within the provided context. // A modified copy of the context is returned with every line up to the key // incremented past. A boolean, true if the key was found, is also returned.
{ "resource": "" }
c16882
train
// WriteEnvFile updates an existing env `KEY=value` formated file with // new values provided in EnvFile.Vars; File.Content is ignored. // Existing ordering and any unknown formatting such as comments are // preserved. If no changes are required the file is untouched.
{ "resource": "" }
c16883
train
// keys returns the keys of a map in sorted order
{ "resource": "" }
c16884
train
// Units generates a Unit file drop-in for fleet, if any fleet options were // configured in cloud-config
{ "resource": "" }
c16885
train
// serviceContents generates the contents for a drop-in unit given the config. // The argument must be a struct from the 'config' package.
{ "resource": "" }
c16886
train
// Units creates a Unit file drop-in for etcd, using any configured options.
{ "resource": "" }
c16887
train
// GetRetry fetches a given URL with support for exponential backoff and maximum retries
{ "resource": "" }
c16888
train
// Apply goes through the map of substitutions and replaces all instances of // the keys with their respective values. It supports escaping substitutions // with a leading '\'.
{ "resource": "" }
c16889
train
// checkDiscoveryUrl verifies that the string is a valid url.
{ "resource": "" }
c16890
train
// checkEncoding validates that, for each file under 'write_files', the // content can be decoded given the specified encoding.
{ "resource": "" }
c16891
train
// checkStructure compares the provided config to the empty config.CloudConfig // structure. Each node is checked to make sure that it exists in the known // structure and that its type is compatible.
{ "resource": "" }
c16892
train
// isCompatible determines if the type of kind n can be converted to the type // of kind g in the context of YAML. This is not an exhaustive list, but its // enough for the purposes of cloud-config validation.
{ "resource": "" }
c16893
train
// getDatasources creates a slice of possible Datasources for cloudinit based // on the different source command-line flags.
{ "resource": "" }
c16894
train
// selectDatasource attempts to choose a valid Datasource to use based on its // current availability. The first Datasource to report to be available is // returned. Datasources will be retried if possible if they are not // immediately available. If all Datasources are permanently unavailable or // datasourceTimeout i...
{ "resource": "" }
c16895
train
// Decode decodes the content of cloud config. Currently only WriteFiles section // supports several types of encoding and all of them are supported. After // decode operation, Encoding type is unset.
{ "resource": "" }
c16896
train
// AssertStructValid checks the fields in the structure and makes sure that // they contain valid values as specified by the 'valid' flag. Empty fields are // implicitly valid.
{ "resource": "" }
c16897
train
// AssertValid checks to make sure that the given value is in the list of // valid values. Zero values are implicitly valid.
{ "resource": "" }
c16898
train
// Validate runs a series of validation tests against the given userdata and // returns a report detailing all of the issues. Presently, only cloud-configs // can be validated.
{ "resource": "" }
c16899
train
// validateCloudConfig runs all of the validation rules in Rules and returns // the resulting report and any errors encountered.
{ "resource": "" }