_id stringlengths 2 7 | title stringclasses 1
value | partition stringclasses 3
values | text stringlengths 6 2.61k | language stringclasses 1
value | meta_information dict |
|---|---|---|---|---|---|
c13900 | train | // Reset removes all of functions.
// Both from the worker and job servers. | {
"resource": ""
} | ||
c13901 | train | // Set the worker's unique id. | {
"resource": ""
} | ||
c13902 | train | // inner job executing | {
"resource": ""
} | ||
c13903 | train | // Which server was this for? | {
"resource": ""
} | ||
c13904 | train | // Extract the Response's result.
// if data == nil, err != nil, then worker failing to execute job
// if data != nil, err != nil, then worker has a exception
// if data != nil, err == nil, then worker complate job
// after calling this method, the Response.Handle will be filled | {
"resource": ""
} | ||
c13905 | train | // Extract the job's update | {
"resource": ""
} | ||
c13906 | train | // Decode a job from byte slice | {
"resource": ""
} | ||
c13907 | train | // Send some datas to client.
// Using this in a job's executing. | {
"resource": ""
} | ||
c13908 | train | // Update status.
// Tall client how many percent job has been executed. | {
"resource": ""
} | ||
c13909 | train | // Decode job from byte slice | {
"resource": ""
} | ||
c13910 | train | // Get the secondary cache for a given primary key. This operation will
// never return nil. In the case where the primary key does not exist, a
// new, underlying, empty bucket will be created and returned. | {
"resource": ""
} | ||
c13911 | train | // Replace the value if it exists, does not set if it doesn't.
// Returns true if the item existed an was replaced, false otherwise.
// Replace does not reset item's TTL nor does it alter its position in the LRU | {
"resource": ""
} | ||
c13912 | train | // Attempts to get the value from the cache and calles fetch on a miss.
// If fetch returns an error, no value is cached and the error is returned back
// to the caller. | {
"resource": ""
} | ||
c13913 | train | // Deletes all items that share the same primary key | {
"resource": ""
} | ||
c13914 | train | //this isn't thread safe. It's meant to be called from non-concurrent tests | {
"resource": ""
} | ||
c13915 | train | // Replace the value if it exists, does not set if it doesn't.
// Returns true if the item existed an was replaced, false otherwise.
// Replace does not reset item's TTL | {
"resource": ""
} | ||
c13916 | train | // Get the secondary key.
// The semantics are the same as for LayeredCache.Get | {
"resource": ""
} | ||
c13917 | train | // Set the secondary key to a value.
// The semantics are the same as for LayeredCache.Set | {
"resource": ""
} | ||
c13918 | train | // Fetch or set a secondary key.
// The semantics are the same as for LayeredCache.Fetch | {
"resource": ""
} | ||
c13919 | train | // Delete a secondary key.
// The semantics are the same as for LayeredCache.Delete | {
"resource": ""
} | ||
c13920 | train | // Replace a secondary key.
// The semantics are the same as for LayeredCache.Replace | {
"resource": ""
} | ||
c13921 | train | // Track a secondary key.
// The semantics are the same as for LayeredCache.TrackingGet | {
"resource": ""
} | ||
c13922 | train | // Parse decodes a DER encoded PKCS7 package | {
"resource": ""
} | ||
c13923 | train | // GetOnlySigner returns an x509.Certificate for the first signer of the signed
// data payload. If there are more or less than one signer, nil is returned | {
"resource": ""
} | ||
c13924 | train | // Decrypt decrypts encrypted content info for recipient cert and private key | {
"resource": ""
} | ||
c13925 | train | // AddSigner signs attributes about the content and adds certificate to payload | {
"resource": ""
} | ||
c13926 | train | // AddCertificate adds the certificate to the payload. Useful for parent certificates | {
"resource": ""
} | ||
c13927 | train | // complexity calculates the cyclomatic complexity of a function. | {
"resource": ""
} | ||
c13928 | train | // GenerateFixtures generates fixtures for the current contents of a database, and saves
// them to the specified directory | {
"resource": ""
} | ||
c13929 | train | // NewSelectQuery creates a new SelectQuery instance. | {
"resource": ""
} | ||
c13930 | train | // Select specifies the columns to be selected.
// Column names will be automatically quoted. | {
"resource": ""
} | ||
c13931 | train | // AndSelect adds additional columns to be selected.
// Column names will be automatically quoted. | {
"resource": ""
} | ||
c13932 | train | // Distinct specifies whether to select columns distinctively.
// By default, distinct is false. | {
"resource": ""
} | ||
c13933 | train | // SelectOption specifies additional option that should be append to "SELECT". | {
"resource": ""
} | ||
c13934 | train | // From specifies which tables to select from.
// Table names will be automatically quoted. | {
"resource": ""
} | ||
c13935 | train | // Where specifies the WHERE condition. | {
"resource": ""
} | ||
c13936 | train | // InnerJoin specifies an INNER JOIN clause.
// This is a shortcut method for Join. | {
"resource": ""
} | ||
c13937 | train | // LeftJoin specifies a LEFT JOIN clause.
// This is a shortcut method for Join. | {
"resource": ""
} | ||
c13938 | train | // RightJoin specifies a RIGHT JOIN clause.
// This is a shortcut method for Join. | {
"resource": ""
} | ||
c13939 | train | // OrderBy specifies the ORDER BY clause.
// Column names will be properly quoted. A column name can contain "ASC" or "DESC" to indicate its ordering direction. | {
"resource": ""
} | ||
c13940 | train | // AndOrderBy appends additional columns to the existing ORDER BY clause.
// Column names will be properly quoted. A column name can contain "ASC" or "DESC" to indicate its ordering direction. | {
"resource": ""
} | ||
c13941 | train | // GroupBy specifies the GROUP BY clause.
// Column names will be properly quoted. | {
"resource": ""
} | ||
c13942 | train | // AndGroupBy appends additional columns to the existing GROUP BY clause.
// Column names will be properly quoted. | {
"resource": ""
} | ||
c13943 | train | // Having specifies the HAVING clause. | {
"resource": ""
} | ||
c13944 | train | // Union specifies a UNION clause. | {
"resource": ""
} | ||
c13945 | train | // UnionAll specifies a UNION ALL clause. | {
"resource": ""
} | ||
c13946 | train | // Limit specifies the LIMIT clause.
// A negative limit means no limit. | {
"resource": ""
} | ||
c13947 | train | // Offset specifies the OFFSET clause.
// A negative offset means no offset. | {
"resource": ""
} | ||
c13948 | train | // Bind specifies the parameter values to be bound to the query. | {
"resource": ""
} | ||
c13949 | train | // AndBind appends additional parameters to be bound to the query. | {
"resource": ""
} | ||
c13950 | train | // Build builds the SELECT query and returns an executable Query object. | {
"resource": ""
} | ||
c13951 | train | // NewPgsqlBuilder creates a new PgsqlBuilder instance. | {
"resource": ""
} | ||
c13952 | train | // BuildSelect generates a SELECT clause from the given selected column names. | {
"resource": ""
} | ||
c13953 | train | // BuildFrom generates a FROM clause from the given tables. | {
"resource": ""
} | ||
c13954 | train | // BuildJoin generates a JOIN clause from the given join information. | {
"resource": ""
} | ||
c13955 | train | // BuildWhere generates a WHERE clause from the given expression. | {
"resource": ""
} | ||
c13956 | train | // BuildGroupBy generates a GROUP BY clause from the given group-by columns. | {
"resource": ""
} | ||
c13957 | train | // BuildUnion generates a UNION clause from the given union information. | {
"resource": ""
} | ||
c13958 | train | // BuildOrderBy generates the ORDER BY clause. | {
"resource": ""
} | ||
c13959 | train | // BuildLimit generates the LIMIT clause. | {
"resource": ""
} | ||
c13960 | train | // ScanMap populates the current row of data into a NullStringMap.
// Note that the NullStringMap must not be nil, or it will panic.
// The NullStringMap will be populated using column names as keys and their values as
// the corresponding element values. | {
"resource": ""
} | ||
c13961 | train | // all populates all rows of query result into a slice of struct or NullStringMap.
// Note that the slice must be given as a pointer. | {
"resource": ""
} | ||
c13962 | train | // column populates the given slice with the first column of the query result.
// Note that the slice must be given as a pointer. | {
"resource": ""
} | ||
c13963 | train | // one populates a single row of query result into a struct or a NullStringMap.
// Note that if a struct is given, it should be a pointer. | {
"resource": ""
} | ||
c13964 | train | // row populates a single row of query result into a list of variables. | {
"resource": ""
} | ||
c13965 | train | // NewQuery creates a new Query with the given SQL statement. | {
"resource": ""
} | ||
c13966 | train | // logSQL returns the SQL statement with parameters being replaced with the actual values.
// The result is only for logging purpose and should not be used to execute. | {
"resource": ""
} | ||
c13967 | train | // log logs a message for the currently executed SQL statement. | {
"resource": ""
} | ||
c13968 | train | // Close closes the underlying prepared statement.
// Close does nothing if the query has not been prepared before. | {
"resource": ""
} | ||
c13969 | train | // Execute executes the SQL statement without retrieving data. | {
"resource": ""
} | ||
c13970 | train | // Row executes the SQL statement and populates the first row of the result into a list of variables.
// Note that the number of the variables should match to that of the columns in the query result.
// Note that when the query has no rows in the result set, an sql.ErrNoRows will be returned. | {
"resource": ""
} | ||
c13971 | train | // Column executes the SQL statement and populates the first column of the result into a slice.
// Note that the parameter must be a pointer to a slice. | {
"resource": ""
} | ||
c13972 | train | // Rows executes the SQL statement and returns a Rows object to allow retrieving data row by row. | {
"resource": ""
} | ||
c13973 | train | // replacePlaceholders converts a list of named parameters into a list of anonymous parameters. | {
"resource": ""
} | ||
c13974 | train | // NewOciBuilder creates a new OciBuilder instance. | {
"resource": ""
} | ||
c13975 | train | // NewQuery creates a new Query object with the given SQL statement.
// The SQL statement may contain parameter placeholders which can be bound with actual parameter
// values before the statement is executed. | {
"resource": ""
} | ||
c13976 | train | // Insert creates a Query that represents an INSERT SQL statement.
// The keys of cols are the column names, while the values of cols are the corresponding column
// values to be inserted. | {
"resource": ""
} | ||
c13977 | train | // CreateTable creates a Query that represents a CREATE TABLE SQL statement.
// The keys of cols are the column names, while the values of cols are the corresponding column types.
// The optional "options" parameters will be appended to the generated SQL statement. | {
"resource": ""
} | ||
c13978 | train | // TruncateTable creates a Query that can be used to truncate a table. | {
"resource": ""
} | ||
c13979 | train | // AddColumn creates a Query that can be used to add a column to a table. | {
"resource": ""
} | ||
c13980 | train | // CreateIndex creates a Query that can be used to create an index for a table. | {
"resource": ""
} | ||
c13981 | train | // quoteColumns quotes a list of columns and concatenates them with commas. | {
"resource": ""
} | ||
c13982 | train | // NewMssqlBuilder creates a new MssqlBuilder instance. | {
"resource": ""
} | ||
c13983 | train | // NewMysqlBuilder creates a new MysqlBuilder instance. | {
"resource": ""
} | ||
c13984 | train | // DropForeignKey creates a Query that can be used to remove the named foreign key constraint from a table. | {
"resource": ""
} | ||
c13985 | train | // NewFromDB encapsulates an existing database connection. | {
"resource": ""
} | ||
c13986 | train | // Clone makes a shallow copy of DB. | {
"resource": ""
} | ||
c13987 | train | // BeginTx starts a transaction with the given context and transaction options. | {
"resource": ""
} | ||
c13988 | train | // Wrap encapsulates an existing transaction. | {
"resource": ""
} | ||
c13989 | train | // Transactional starts a transaction and executes the given function.
// If the function returns an error, the transaction will be rolled back.
// Otherwise, the transaction will be committed. | {
"resource": ""
} | ||
c13990 | train | // TransactionalContext starts a transaction and executes the given function with the given context and transaction options.
// If the function returns an error, the transaction will be rolled back.
// Otherwise, the transaction will be committed. | {
"resource": ""
} | ||
c13991 | train | // QuoteTableName quotes the given table name appropriately.
// If the table name contains DB schema prefix, it will be handled accordingly.
// This method will do nothing if the table name is already quoted or if it contains parenthesis. | {
"resource": ""
} | ||
c13992 | train | // QuoteColumnName quotes the given column name appropriately.
// If the table name contains table name prefix, it will be handled accordingly.
// This method will do nothing if the column name is already quoted or if it contains parenthesis. | {
"resource": ""
} | ||
c13993 | train | // newBuilder creates a query builder based on the current driver name. | {
"resource": ""
} | ||
c13994 | train | // Delete deletes a row in the table using the primary key specified by the struct model associated with this query. | {
"resource": ""
} | ||
c13995 | train | // NewStandardBuilder creates a new StandardBuilder instance. | {
"resource": ""
} | ||
c13996 | train | // NewSqliteBuilder creates a new SqliteBuilder instance. | {
"resource": ""
} | ||
c13997 | train | // DropColumn creates a Query that can be used to drop a column from a table. | {
"resource": ""
} | ||
c13998 | train | // AlterColumn creates a Query that can be used to change the definition of a table column. | {
"resource": ""
} | ||
c13999 | train | // DropPrimaryKey creates a Query that can be used to remove the named primary key constraint from a table. | {
"resource": ""
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.