id
int32
0
25.3k
idx
stringlengths
5
9
nl_tokens
listlengths
1
418
pl_tokens
listlengths
22
4.98k
6,700
all-6701
[ "SetConsoleCursorInfo", "sets", "the", "size", "and", "visiblity", "of", "the", "console", "cursor", ".", "See", "https", ":", "//", "msdn", ".", "microsoft", ".", "com", "/", "en", "-", "us", "/", "library", "/", "windows", "/", "desktop", "/", "ms68601...
[ "func", "SetConsoleCursorInfo", "(", "<mask>", "uintptr", ",", "cursorInfo", "*", "CONSOLE_CURSOR_INFO", ")", "error", "{", "r1", ",", "r2", ",", "err", ":=", "setConsoleCursorInfoProc", ".", "Call", "(", "handle", ",", "uintptr", "(", "unsafe", ".", "Pointer"...
6,701
all-6702
[ "markObjects", "finds", "all", "the", "live", "objects", "in", "the", "heap", "and", "marks", "them", "in", "the", "p", ".", "heapInfo", "mark", "fields", "." ]
[ "func", "(", "p", "*", "Process", ")", "markObjects", "(", ")", "{", "ptrSize", ":=", "p", ".", "proc", ".", "PtrSize", "(", ")", "\n\n", "// number of live objects found so far", "n", ":=", "0", "\n", "// total size of live objects", "var", "live", "int64", ...
6,702
all-6703
[ "SetOperator", "is", "a", "wrapper", "around", "cairo_set_operator", "()", "." ]
[ "func", "(", "v", "*", "<mask>", ")", "SetOperator", "(", "op", "Operator", ")", "{", "C", ".", "cairo_set_operator", "(", "v", ".", "native", "(", ")", ",", "C", ".", "cairo_operator_t", "(", "op", ")", ")", "\n", "}" ]
6,703
all-6704
[ "WithContext", "constructs", "and", "returns", "a", "Process", "that", "respects", "given", "context", ".", "It", "is", "the", "equivalent", "of", ":", "func", "ProcessWithContext", "(", "ctx", "context", ".", "Context", ")", "goprocess", ".", "Process", "{", ...
[ "func", "WithContext", "(", "ctx", "<mask>", ".", "Context", ")", "goprocess", ".", "Process", "{", "p", ":=", "goprocess", ".", "WithParent", "(", "goprocess", ".", "Background", "(", ")", ")", "\n", "CloseAfterContext", "(", "p", ",", "ctx", ")", "\n",...
6,704
all-6705
[ "DataWapper", "sets", "wrap", "functions", "which", "is", "called", "during", "NthDataWrapped", "()", "and", "DataWrapped", "()", ".", "It", "s", "used", "to", "cast", "raw", "C", "data", "into", "appropriate", "Go", "structures", "and", "types", "every", "t...
[ "func", "(", "v", "*", "<mask>", ")", "DataWrapper", "(", "fn", "func", "(", "unsafe", ".", "Pointer", ")", "interface", "{", "}", ")", "{", "if", "v", "==", "nil", "{", "return", "\n", "}", "\n", "v", ".", "dataWrap", "=", "fn", "\n", "}" ]
6,705
all-6706
[ "native", "returns", "a", "pointer", "to", "the", "underlying", "GtkRecentFilter", "." ]
[ "func", "(", "v", "*", "RecentFilter", ")", "native", "(", ")", "*", "C", ".", "GtkRecentFilter", "{", "if", "v", "==", "nil", "||", "v", ".", "<mask>", "==", "nil", "{", "return", "nil", "\n", "}", "\n", "p", ":=", "unsafe", ".", "Pointer", "(",...
6,706
all-6707
[ "UnmarshalJSON", "supports", "json", ".", "Unmarshaler", "interface" ]
[ "func", "(", "v", "*", "SetRuleSelectorReturns", ")", "UnmarshalJSON", "(", "data", "[", "]", "byte", ")", "error", "{", "r", ":=", "jlexer", ".", "Lexer", "{", "Data", ":", "data", "}", "\n", "easyjsonC5a4559bDecodeGithubComChromedpCdprotoCss15", "(", "&", ...
6,707
all-6708
[ "MiddlewareFunc", "makes", "RecoverMiddleware", "implement", "the", "Middleware", "interface", "." ]
[ "func", "(", "mw", "*", "RecoverMiddleware", ")", "MiddlewareFunc", "(", "h", "HandlerFunc", ")", "HandlerFunc", "{", "// set the default Logger", "if", "mw", ".", "Logger", "==", "nil", "{", "mw", ".", "Logger", "=", "log", ".", "New", "(", "os", ".", "...
6,708
all-6709
[ "UnmarshalJSON", "supports", "json", ".", "Unmarshaler", "interface" ]
[ "func", "(", "v", "*", "EventAddDatabase", ")", "UnmarshalJSON", "(", "data", "[", "]", "<mask>", ")", "error", "{", "r", ":=", "jlexer", ".", "Lexer", "{", "Data", ":", "data", "}", "\n", "easyjsonC5a4559bDecodeGithubComChromedpCdprotoDatabase4", "(", "&", ...
6,709
all-6710
[ "Parameter", "image", "has", "type", "C", ".", "GLeglImageOES", "." ]
[ "func", "EGLImageTargetTexStorageEXT", "(", "<mask>", "uint32", ",", "image", "unsafe", ".", "Pointer", ",", "attrib_list", "*", "int32", ")", "{", "C", ".", "glowEGLImageTargetTexStorageEXT", "(", "gpEGLImageTargetTexStorageEXT", ",", "(", "C", ".", "GLenum", ")"...
6,710
all-6711
[ "BuildAndRunDirWithGoBuildTags", "builds", "the", "given", "director", "s", "features", "into", "Go", "Code", "using", "the", "filters", "provided", ".", "Also", "takes", "a", "string", "for", "the", "build", "tags", "to", "be", "passed", "to", "the", "go", ...
[ "func", "BuildAndRunDirWithGoBuildTags", "(", "dir", "string", ",", "filters", "[", "]", "string", ",", "goBuildTags", "string", ")", "<mask>", "{", "return", "buildAndRunDir", "(", "dir", ",", "filters", ",", "goBuildTags", ")", "\n", "}" ]
6,711
all-6712
[ "StopServer", "stops", "a", "remote", "Pact", "Mock", "Server", "." ]
[ "func", "(", "p", "*", "PactClient", ")", "StopServer", "(", "server", "*", "<mask>", ".", "MockServer", ")", "(", "*", "types", ".", "MockServer", ",", "error", ")", "{", "log", ".", "Println", "(", "\"", "\"", ")", "\n\n", "// TODO: Need to be able to ...
6,712
all-6713
[ "UnmarshalYAML", "implements", "yaml", ".", "Unamrshaler", "interface", ".", "It", "parses", "time", ".", "Duration", "as", "strings", "." ]
[ "func", "(", "o", "*", "Options", ")", "UnmarshalYAML", "(", "unmarshal", "func", "(", "<mask>", "{", "}", ")", "error", ")", "error", "{", "v", ":=", "&", "optionsJSON", "{", "}", "\n", "if", "err", ":=", "unmarshal", "(", "v", ")", ";", "err", ...
6,713
all-6714
[ "GetWebsiteLabel", "is", "a", "wrapper", "around", "gtk_about_dialog_get_website_label", "()", "." ]
[ "func", "(", "v", "*", "AboutDialog", ")", "GetWebsiteLabel", "(", ")", "string", "{", "c", ":=", "C", ".", "gtk_about_dialog_get_website_label", "(", "v", ".", "native", "(", ")", ")", "\n", "return", "C", ".", "GoString", "(", "(", "*", "C", ".", "...
6,714
all-6715
[ "name", "returns", "the", "import", "path", "qualified", "name", "of", "the", "function", "containing", "the", "call", "." ]
[ "func", "(", "pc", "Call", ")", "name", "(", ")", "string", "{", "pcFix", ":=", "uintptr", "(", "<mask>", ")", "-", "1", "// work around for go issue #7690", "\n", "fn", ":=", "runtime", ".", "FuncForPC", "(", "pcFix", ")", "\n", "if", "fn", "==", "nil...
6,715
all-6716
[ "ToWriter", "downloads", "the", "specified", "src", "URL", "to", "w", "writer", "using", "the", "specified", "Options", "." ]
[ "func", "ToWriter", "(", "src", "string", ",", "w", "<mask>", ".", "Writer", ",", "options", "Options", ")", "error", "{", "u", ",", "err", ":=", "url", ".", "Parse", "(", "src", ")", "\n", "if", "err", "!=", "nil", "{", "return", "errors", ".", ...
6,716
all-6717
[ "Info", "indicates", "an", "expected", "call", "of", "Info" ]
[ "func", "(", "mr", "*", "MockInfoLoggerMockRecorder", ")", "Info", "(", "arg0", "...", "<mask>", "{", "}", ")", "*", "gomock", ".", "Call", "{", "return", "mr", ".", "mock", ".", "ctrl", ".", "RecordCallWithMethodType", "(", "mr", ".", "mock", ",", "\"...
6,717
all-6718
[ "DeProvisionHost", "-", "make", "a", "deprovision", "call", "to", "innkeeper", "for", "a", "given", "requestID" ]
[ "func", "(", "s", "*", "IKClient", ")", "DeProvisionHost", "(", "requestID", "string", ")", "(", "resp", "*", "innkeeperclient", ".", "GetStatusResponse", ",", "err", "error", ")", "{", "s", ".", "SpyRequestID", "=", "requestID", "\n", "return", "nil", ","...
6,718
all-6719
[ "Open", "the", "node", "-", "local", "database", "object", "." ]
[ "func", "Open", "(", "dir", "string", ")", "(", "*", "sql", ".", "DB", ",", "error", ")", "{", "<mask>", ":=", "filepath", ".", "Join", "(", "dir", ",", "\"", "\"", ")", "\n", "db", ",", "err", ":=", "sqliteOpen", "(", "path", ")", "\n", "if", ...
6,719
all-6720
[ "GetStatus", "--" ]
[ "func", "(", "s", "*", "IKClient", ")", "GetStatus", "(", "requestID", "string", ")", "(", "resp", "*", "innkeeperclient", ".", "GetStatusResponse", ",", "err", "error", ")", "{", "resp", "=", "<mask>", "(", "innkeeperclient", ".", "GetStatusResponse", ")", ...
6,720
all-6721
[ "Update", "an", "article" ]
[ "func", "Update", "(", "c", "*", "gin", ".", "Context", ")", "{", "db", ":=", "c", ".", "MustGet", "(", "\"", "\"", ")", ".", "(", "*", "mgo", ".", "Database", ")", "\n\n", "article", ":=", "models", ".", "Article", "{", "}", "\n", "err", ":=",...
6,721
all-6722
[ "FetchOutlierReports", "retrieves", "all", "outlier", "reports", "available", "to", "API", "Token", "." ]
[ "func", "(", "a", "*", "API", ")", "FetchOutlierReports", "(", ")", "(", "*", "[", "]", "OutlierReport", ",", "error", ")", "{", "result", ",", "err", ":=", "a", ".", "Get", "(", "config", ".", "OutlierReportPrefix", ")", "\n", "if", "err", "!=", "...
6,722
all-6723
[ "contains", "code", "taken", "from", "go1", ".", "8", "for", "purposes", "of", "backwards", "compatability", "with", "older", "go", "versions", ".", "hostname", "returns", "u", ".", "Host", "without", "any", "port", "number", ".", "If", "Host", "is", "an",...
[ "func", "hostname", "(", "hostport", "string", ")", "<mask>", "{", "colon", ":=", "strings", ".", "IndexByte", "(", "hostport", ",", "':'", ")", "\n", "if", "colon", "==", "-", "1", "{", "return", "hostport", "\n", "}", "\n", "if", "i", ":=", "string...
6,723
all-6724
[ "setJitterSeed", "calculates", "a", "global", "jitterSeed", "per", "server", "relying", "on", "extra", "label", "set", "." ]
[ "func", "(", "m", "*", "<mask>", ")", "setJitterSeed", "(", "labels", "labels", ".", "Labels", ")", "error", "{", "h", ":=", "fnv", ".", "New64a", "(", ")", "\n", "hostname", ",", "err", ":=", "getFqdn", "(", ")", "\n", "if", "err", "!=", "nil", ...
6,724
all-6725
[ "Add", "appends", "a", "new", "Problem", "to", "the", "slice", "for", "the", "specified", "metric", "with", "the", "specified", "issue", "text", "." ]
[ "func", "(", "p", "*", "problems", ")", "Add", "(", "mf", "dto", ".", "MetricFamily", ",", "text", "string", ")", "{", "*", "p", "=", "append", "(", "*", "p", ",", "Problem", "{", "Metric", ":", "mf", ".", "GetName", "(", ")", ",", "Text", ":",...
6,725
all-6726
[ "Length", "returns", "the", "number", "of", "elements", "in", "the", "List", "." ]
[ "func", "(", "l", "*", "List", ")", "Length", "(", ")", "uint", "{", "l", ".", "key", ".", "RLock", "(", ")", "\n", "defer", "l", ".", "<mask>", ".", "RUnlock", "(", ")", "\n", "return", "uint", "(", "len", "(", "l", ".", "underlyer", ")", ")...
6,726
all-6727
[ "ToPirateSpeak", "will", "format", "the", "provided", "string", "in", "Pirate", "Speak", "." ]
[ "func", "ToPirateSpeak", "(", "theString", "string", ")", "(", "string", ",", "error", ")", "{", "f", ":=", "New", "(", "theString", ")", "\n\n", "if", "f", ".", "length", "<", "1", "{", "return", "\"", "\"", ",", "errors", ".", "New", "(", "length...
6,727
all-6728
[ "Arc", "is", "a", "wrapper", "around", "cairo_arc", "()", "." ]
[ "func", "(", "v", "*", "<mask>", ")", "Arc", "(", "xc", ",", "yc", ",", "radius", ",", "angle1", ",", "angle2", "float64", ")", "{", "C", ".", "cairo_arc", "(", "v", ".", "native", "(", ")", ",", "C", ".", "double", "(", "xc", ")", ",", "C", ...
6,728
all-6729
[ "Clone", "creates", "a", "copy", "of", "the", "set", "where", "the", "values", "in", "clone", "set", "point", "to", "the", "same", "underlying", "reference", "as", "the", "original", "set" ]
[ "func", "(", "set", "basicSet", ")", "Clone", "(", ")", "set", "{", "clone", ":=", "basicSet", "(", "<mask>", "(", "map", "[", "string", "]", "interface", "{", "}", ")", ")", "\n", "for", "k", ",", "v", ":=", "range", "set", "{", "clone", "[", ...
6,729
all-6730
[ "GetCaps", "extracts", "the", "list", "of", "capabilities", "effective", "on", "the", "file" ]
[ "func", "GetCaps", "(", "path", "string", ")", "(", "[", "]", "byte", ",", "error", ")", "{", "xattrs", ",", "err", ":=", "shared", ".", "GetAllXattr", "(", "path", ")", "\n", "if", "err", "!=", "nil", "{", "return", "nil", ",", "err", "\n", "}",...
6,730
all-6731
[ "return", "the", "pointer", "to", "a", "mapped", "buffer", "object", "s", "data", "store" ]
[ "func", "GetBufferPointerv", "(", "<mask>", "uint32", ",", "pname", "uint32", ",", "params", "*", "unsafe", ".", "Pointer", ")", "{", "C", ".", "glowGetBufferPointerv", "(", "gpGetBufferPointerv", ",", "(", "C", ".", "GLenum", ")", "(", "target", ")", ",",...
6,731
all-6732
[ "GetNoMetricHosts", "returns", "the", "NoMetricHosts", "field", "if", "non", "-", "nil", "zero", "value", "otherwise", "." ]
[ "func", "(", "t", "*", "TileDef", ")", "GetNoMetricHosts", "(", ")", "bool", "{", "if", "t", "==", "nil", "||", "t", ".", "NoMetricHosts", "==", "nil", "{", "return", "<mask>", "\n", "}", "\n", "return", "*", "t", ".", "NoMetricHosts", "\n", "}" ]
6,732
all-6733
[ "Start", "returns", "a", "derivative", "query", "with", "the", "given", "start", "point", "." ]
[ "func", "(", "q", "*", "Query", ")", "Start", "(", "c", "Cursor", ")", "*", "<mask>", "{", "q", "=", "q", ".", "clone", "(", ")", "\n", "if", "c", ".", "cc", "==", "nil", "{", "q", ".", "err", "=", "errors", ".", "New", "(", "\"", "\"", "...
6,733
all-6734
[ "SetCursor", "is", "a", "wrapper", "around", "gtk_icon_view_set_selection_mode", "()", "." ]
[ "func", "(", "v", "*", "IconView", ")", "SetCursor", "(", "path", "*", "TreePath", ",", "<mask>", "*", "CellRenderer", ",", "startEditing", "bool", ")", "{", "C", ".", "gtk_icon_view_set_cursor", "(", "v", ".", "native", "(", ")", ",", "path", ".", "na...
6,734
all-6735
[ "Add", "creates", "a", "Job", "from", "the", "given", "function", "and", "args", "and", "adds", "it", "to", "the", "Pool", "." ]
[ "func", "(", "pool", "*", "Pool", ")", "Add", "(", "f", "func", "(", "...", "interface", "{", "}", ")", "interface", "{", "}", ",", "args", "...", "interface", "{", "}", ")", "{", "job", ":=", "&", "Job", "{", "f", ",", "args", ",", "nil", ",...
6,735
all-6736
[ "LabelsAndAnnotationsForJob", "returns", "a", "standard", "set", "of", "labels", "to", "add", "to", "pod", "/", "build", "/", "etc", "resources", "." ]
[ "func", "LabelsAndAnnotationsForJob", "(", "pj", "prowapi", ".", "ProwJob", ")", "(", "map", "[", "string", "]", "string", ",", "map", "[", "string", "]", "string", ")", "{", "var", "extraLabels", "map", "[", "string", "]", "string", "\n", "if", "extraLa...
6,736
all-6737
[ "Core", "takes", "a", "loaded", "core", "file", "and", "extracts", "Go", "information", "from", "it", "." ]
[ "func", "Core", "(", "proc", "*", "core", ".", "Process", ")", "(", "p", "*", "Process", ",", "err", "error", ")", "{", "// Make sure we have DWARF info.", "if", "_", ",", "err", ":=", "proc", ".", "DWARF", "(", ")", ";", "err", "!=", "nil", "{", "...
6,737
all-6738
[ "Delete", "executes", "DELETE", "request", "to", "the", "endpoint", "with", "no", "body", "re", "err", ":", "=", "c", ".", "Delete", "(", "c", ".", "Endpoint", "(", "users", "id1", "))" ]
[ "func", "(", "c", "*", "<mask>", ")", "Delete", "(", "ctx", "context", ".", "Context", ",", "endpoint", "string", ")", "(", "*", "Response", ",", "error", ")", "{", "// If the sanitizer is enabled, make sure the requested path is safe.", "if", "c", ".", "sanitiz...
6,738
all-6739
[ "fuzzInterval", "returns", "a", "fuzzed", "version", "of", "the", "interval", "based", "on", "FullJitter", "as", "described", "here", ":", "http", ":", "//", "www", ".", "awsarchitectureblog", ".", "com", "/", "2015", "/", "03", "/", "backoff", ".", "html"...
[ "func", "fuzzInterval", "(", "interval", "<mask>", ".", "Duration", ")", "time", ".", "Duration", "{", "return", "time", ".", "Duration", "(", "rand", ".", "Int63n", "(", "int64", "(", "interval", ")", ")", ")", "\n", "}" ]
6,739
all-6740
[ "ReplaceConfigMap", "puts", "the", "configmap", "into", "name", ".", "Analogous", "to", "kubectl", "replace", "configmap", "If", "config", ".", "Namespace", "is", "empty", "the", "client", "s", "specified", "namespace", "is", "used", ".", "Returns", "the", "co...
[ "func", "(", "c", "*", "Client", ")", "ReplaceConfigMap", "(", "name", "string", ",", "config", "ConfigMap", ")", "(", "ConfigMap", ",", "error", ")", "{", "c", ".", "log", "(", "\"", "\"", ",", "name", ")", "\n", "namespace", ":=", "c", ".", "name...
6,740
all-6741
[ "RemoveCounter", "removes", "the", "named", "counter" ]
[ "func", "(", "m", "*", "CirconusMetrics", ")", "RemoveCounter", "(", "metric", "string", ")", "{", "m", ".", "cm", ".", "Lock", "(", ")", "\n", "defer", "m", ".", "cm", ".", "Unlock", "(", ")", "\n", "<mask>", "(", "m", ".", "counters", ",", "met...
6,741
all-6742
[ "Names", "returns", "the", "names", "of", "the", "configured", "providers", "." ]
[ "func", "(", "d", "*", "Discover", ")", "Names", "(", ")", "[", "]", "string", "{", "d", ".", "once", ".", "Do", "(", "d", ".", "initProviders", ")", "\n\n", "var", "names", "[", "]", "string", "\n", "for", "n", ":=", "range", "d", ".", "Provid...
6,742
all-6743
[ "Transaction", "creates", "a", "new", "ClusterTx", "object", "and", "transactionally", "executes", "the", "cluster", "database", "interactions", "invoked", "by", "the", "given", "function", ".", "If", "the", "function", "returns", "no", "error", "all", "database",...
[ "func", "(", "c", "*", "Cluster", ")", "<mask>", "(", "f", "func", "(", "*", "ClusterTx", ")", "error", ")", "error", "{", "c", ".", "mu", ".", "RLock", "(", ")", "\n", "defer", "c", ".", "mu", ".", "RUnlock", "(", ")", "\n", "return", "c", "...
6,743
all-6744
[ "NewASMClient", "mocks", "base", "method" ]
[ "func", "(", "m", "*", "MockClientCreator", ")", "NewASMClient", "(", "arg0", "string", ",", "arg1", "credentials", ".", "IAMRoleCredentials", ")", "secretsmanageriface", ".", "SecretsManagerAPI", "{", "ret", ":=", "m", ".", "ctrl", ".", "Call", "(", "m", ",...
6,744
all-6745
[ "create", "creates", "a", "new", "log", "file", "and", "returns", "the", "file", "and", "its", "filename", "which", "contains", "tag", "(", "INFO", "FATAL", "etc", ".", ")", "and", "t", ".", "If", "the", "file", "is", "created", "successfully", "create",...
[ "func", "(", "l", "*", "Log", ")", "create", "(", "<mask>", "string", ",", "t", "time", ".", "Time", ")", "(", "f", "*", "os", ".", "File", ",", "filename", "string", ",", "err", "error", ")", "{", "if", "len", "(", "l", ".", "logDirs", ")", ...
6,745
all-6746
[ "next", "advances", "the", "openMetricsLexer", "to", "the", "next", "character", "." ]
[ "func", "(", "l", "*", "openMetricsLexer", ")", "<mask>", "(", ")", "byte", "{", "l", ".", "i", "++", "\n", "if", "l", ".", "i", ">=", "len", "(", "l", ".", "b", ")", "{", "l", ".", "err", "=", "io", ".", "EOF", "\n", "return", "byte", "(",...
6,746
all-6747
[ "NewQuery", "creates", "a", "new", "Livestatus", "query", "instance", "." ]
[ "func", "NewQuery", "(", "table", "string", ")", "*", "Query", "{", "return", "&", "Query", "{", "table", ":", "<mask>", ",", "headers", ":", "[", "]", "string", "{", "}", ",", "columns", ":", "[", "]", "string", "{", "}", ",", "}", "\n", "}" ]
6,747
all-6748
[ "LintRedundantNilCheckWithLen", "checks", "for", "the", "following", "reduntant", "nil", "-", "checks", ":", "if", "x", "==", "nil", "||", "len", "(", "x", ")", "==", "0", "{}", "if", "x", "!", "=", "nil", "&&", "len", "(", "x", ")", "!", "=", "0",...
[ "func", "(", "c", "*", "Checker", ")", "LintRedundantNilCheckWithLen", "(", "j", "*", "lint", ".", "Job", ")", "{", "isConstZero", ":=", "func", "(", "expr", "ast", ".", "Expr", ")", "(", "isConst", "bool", ",", "isZero", "bool", ")", "{", "_", ",", ...
6,748
all-6749
[ "UnmarshalJSON", "supports", "json", ".", "Unmarshaler", "interface" ]
[ "func", "(", "v", "*", "EventExecutionContextCreated", ")", "UnmarshalJSON", "(", "data", "[", "]", "byte", ")", "error", "{", "r", ":=", "jlexer", ".", "Lexer", "{", "Data", ":", "data", "}", "\n", "easyjsonC5a4559bDecodeGithubComChromedpCdprotoRuntime32", "(",...
6,749
all-6750
[ "ContainerSetState", "sets", "the", "the", "power", "state", "of", "the", "container", "with", "the", "given", "ID", "." ]
[ "func", "(", "c", "*", "Cluster", ")", "ContainerSetState", "(", "id", "int", ",", "state", "string", ")", "error", "{", "err", ":=", "c", ".", "Transaction", "(", "func", "(", "tx", "*", "ClusterTx", ")", "error", "{", "// Set the new value", "str", "...
6,750
all-6751
[ "GetAuthentication", "returns", "the", "registry", "credentials", "stored", "in", "either", "auth", ".", "json", "file", "or", ".", "docker", "/", "config", ".", "json", "If", "an", "entry", "is", "not", "found", "empty", "strings", "are", "returned", "for",...
[ "func", "GetAuthentication", "(", "sys", "*", "types", ".", "SystemContext", ",", "registry", "string", ")", "(", "string", ",", "string", ",", "error", ")", "{", "if", "sys", "!=", "nil", "&&", "sys", ".", "DockerAuthConfig", "!=", "nil", "{", "return",...
6,751
all-6752
[ "NewAccessTokenContext", "returns", "a", "new", "Context", "that", "carries", "token", "value", "." ]
[ "func", "NewAccessTokenContext", "(", "ctx", "context", ".", "Context", ",", "<mask>", "string", ")", "context", ".", "Context", "{", "return", "context", ".", "WithValue", "(", "ctx", ",", "accessTokenContextKey", ",", "at", ")", "\n", "}" ]
6,752
all-6753
[ "FromJSON", "loads", "service", "account", "credentials", "from", "the", "JSON", "encoded", "buf", "." ]
[ "func", "FromJSON", "(", "buf", "[", "]", "byte", ",", "opts", "...", "Option", ")", "(", "*", "GServiceAccount", ",", "error", ")", "{", "var", "err", "error", "\n\n", "// unmarshal", "gsa", ":=", "new", "(", "GServiceAccount", ")", "\n", "if", "err",...
6,753
all-6754
[ "Curls", "an", "app", "s", "endpoint", "and", "exit", "successfully", "before", "the", "specified", "timeout" ]
[ "func", "CurlAppWithTimeout", "(", "cfg", "helpersinternal", ".", "CurlConfig", ",", "appName", ",", "path", "string", ",", "timeout", "<mask>", ".", "Duration", ",", "args", "...", "string", ")", "string", "{", "appCurler", ":=", "helpersinternal", ".", "NewA...
6,754
all-6755
[ "Commit", "commits", "the", "transaction", "following", "these", "steps", ":", "1", ".", "If", "there", "are", "no", "writes", "return", "immediately", ".", "2", ".", "Check", "if", "read", "rows", "were", "updated", "since", "txn", "started", ".", "If", ...
[ "func", "(", "txn", "*", "Txn", ")", "Commit", "(", ")", "<mask>", "{", "txn", ".", "commitPrecheck", "(", ")", "// Precheck before discarding txn.", "\n", "defer", "txn", ".", "Discard", "(", ")", "\n\n", "if", "len", "(", "txn", ".", "writes", ")", "...
6,755
all-6756
[ "runFSM", "is", "a", "long", "running", "goroutine", "responsible", "for", "applying", "logs", "to", "the", "FSM", ".", "This", "is", "done", "async", "of", "other", "logs", "since", "we", "don", "t", "want", "the", "FSM", "to", "block", "our", "internal...
[ "func", "(", "r", "*", "Raft", ")", "runFSM", "(", ")", "{", "var", "lastIndex", ",", "lastTerm", "uint64", "\n\n", "commit", ":=", "func", "(", "req", "*", "commitTuple", ")", "{", "// Apply the log if a command", "var", "resp", "interface", "{", "}", "...
6,756
all-6757
[ "MustOperations", "retrieves", "the", "Operations", "value", "from", "the", "union", "panicing", "if", "the", "value", "is", "not", "set", "." ]
[ "func", "(", "u", "TransactionMeta", ")", "MustOperations", "(", ")", "[", "]", "OperationMeta", "{", "val", ",", "<mask>", ":=", "u", ".", "GetOperations", "(", ")", "\n\n", "if", "!", "ok", "{", "panic", "(", "\"", "\"", ")", "\n", "}", "\n\n", "...
6,757
all-6758
[ "NewCatalog", "will", "create", "a", "new", "catalog", "." ]
[ "func", "NewCatalog", "(", "models", "...", "Model", ")", "*", "Catalog", "{", "// create catalog", "c", ":=", "&", "Catalog", "{", "models", ":", "<mask>", "(", "map", "[", "string", "]", "Model", ")", ",", "}", "\n\n", "// add models", "c", ".", "Add...
6,758
all-6759
[ "Insert", "a", "row", "in", "one", "of", "the", "nodes", "association", "tables", "(", "storage_pools_nodes", "networks_nodes", "images_nodes", ")", "." ]
[ "func", "importNodeAssociation", "(", "entity", "string", ",", "columns", "[", "]", "string", ",", "row", "[", "]", "interface", "{", "}", ",", "tx", "*", "sql", ".", "Tx", ")", "error", "{", "stmt", ":=", "fmt", ".", "Sprintf", "(", "\"", "\"", ",...
6,759
all-6760
[ "Returns", "a", "random", "base64", "encoded", "string", "from", "crypto", "/", "rand", "." ]
[ "func", "RandomCryptoString", "(", ")", "(", "string", ",", "error", ")", "{", "buf", ":=", "make", "(", "[", "]", "byte", ",", "32", ")", "\n", "n", ",", "err", ":=", "rand", ".", "Read", "(", "buf", ")", "\n", "if", "err", "!=", "nil", "{", ...
6,760
all-6761
[ "Helpers", "--------------------------------------------------------------------", "gorillaPattern", "transforms", "a", "gorilla", "pattern", "into", "a", "regexp", "pattern", "." ]
[ "func", "gorillaPattern", "(", "tpl", "string", ",", "matchHost", ",", "prefixMatch", ",", "strictSlash", "bool", ")", "(", "string", ",", "error", ")", "{", "// Check if it is well-formed.", "idxs", ",", "err", ":=", "braceIndices", "(", "tpl", ")", "\n", "...
6,761
all-6762
[ "Demangle", "a", "string", "just", "as", "the", "GNU", "c", "++", "filt", "program", "does", "." ]
[ "func", "doDemangle", "(", "out", "*", "bufio", ".", "Writer", ",", "name", "string", ")", "{", "skip", ":=", "0", "\n", "if", "name", "[", "0", "]", "==", "'.'", "||", "name", "[", "0", "]", "==", "'$'", "{", "skip", "++", "\n", "}", "\n", "...
6,762
all-6763
[ "ParseImageName", "parses", "a", "docker", "image", "into", "an", "ImageName", "struct", "." ]
[ "func", "ParseImageName", "(", "image", "string", ")", "(", "ImageName", ",", "error", ")", "{", "ret", ":=", "ImageName", "{", "}", "\n\n", "img", ",", "err", ":=", "registry", ".", "ParseImage", "(", "image", ")", "\n", "if", "err", "!=", "nil", "{...
6,763
all-6764
[ "record", "the", "GL", "time", "into", "a", "query", "object", "after", "all", "previous", "commands", "have", "reached", "the", "GL", "server", "but", "have", "not", "yet", "necessarily", "executed", "." ]
[ "func", "QueryCounter", "(", "<mask>", "uint32", ",", "target", "uint32", ")", "{", "C", ".", "glowQueryCounter", "(", "gpQueryCounter", ",", "(", "C", ".", "GLuint", ")", "(", "id", ")", ",", "(", "C", ".", "GLenum", ")", "(", "target", ")", ")", ...
6,764
all-6765
[ "UnmarshalJSON", "supports", "json", ".", "Unmarshaler", "interface" ]
[ "func", "(", "v", "*", "CallFrame", ")", "UnmarshalJSON", "(", "data", "[", "]", "<mask>", ")", "error", "{", "r", ":=", "jlexer", ".", "Lexer", "{", "Data", ":", "data", "}", "\n", "easyjsonC5a4559bDecodeGithubComChromedpCdprotoDebugger48", "(", "&", "r", ...
6,765
all-6766
[ "Leader", "returns", "the", "leader", "value", "for", "the", "current", "election", "." ]
[ "func", "(", "e", "*", "Election", ")", "Leader", "(", "ctx", "context", ".", "Context", ")", "(", "*", "v3", ".", "GetResponse", ",", "error", ")", "{", "client", ":=", "e", ".", "session", ".", "Client", "(", ")", "\n", "resp", ",", "err", ":="...
6,766
all-6767
[ "uploads", "a", "part", "checking", "the", "etag", "against", "the", "calculated", "value" ]
[ "func", "(", "p", "*", "putter", ")", "putPart", "(", "part", "*", "part", ")", "error", "{", "v", ":=", "url", ".", "Values", "{", "}", "\n", "v", ".", "Set", "(", "\"", "\"", ",", "strconv", ".", "Itoa", "(", "part", ".", "PartNumber", ")", ...
6,767
all-6768
[ "Call", "invokes", "the", "appropriate", "HTTP", "method", "on", "a", "given", "Firebase", "URL", "." ]
[ "func", "(", "f", "*", "f", ")", "Call", "(", "method", ",", "<mask>", ",", "auth", "string", ",", "body", "[", "]", "byte", ",", "params", "map", "[", "string", "]", "string", ")", "(", "[", "]", "byte", ",", "error", ")", "{", "if", "!", "s...
6,768
all-6769
[ "getSCSIController", "picks", "a", "SCSI", "controller", "at", "the", "specific", "bus", "number", "supplied", "." ]
[ "func", "pickSCSIController", "(", "l", "object", ".", "VirtualDeviceList", ",", "bus", "int", ")", "(", "types", ".", "BaseVirtualController", ",", "error", ")", "{", "<mask>", ".", "Printf", "(", "\"", "\"", ",", "bus", ")", "\n", "l", "=", "l", ".",...
6,769
all-6770
[ "Push", "pushes", "over", "https", "to", "the", "provided", "owner", "/", "repo#branch", "using", "a", "password", "for", "basic", "auth", "." ]
[ "func", "(", "r", "*", "Repo", ")", "Push", "(", "repo", ",", "branch", "string", ")", "error", "{", "if", "r", ".", "user", "==", "\"", "\"", "||", "r", ".", "pass", "==", "\"", "\"", "{", "return", "errors", ".", "New", "(", "\"", "\"", ")"...
6,770
all-6771
[ "Instruction", ".", "String", "()" ]
[ "func", "(", "v", "*", "Alloc", ")", "String", "(", ")", "string", "{", "op", ":=", "\"", "\"", "\n", "if", "v", ".", "Heap", "{", "op", "=", "\"", "\"", "\n", "}", "\n", "from", ":=", "v", ".", "Parent", "(", ")", ".", "pkg", "(", ")", "...
6,771
all-6772
[ "Delete", "implements", "storage", "interface", "." ]
[ "func", "(", "s", "*", "Storage", ")", "Delete", "(", "ctx", "context", ".", "Context", ",", "subjectID", ",", "accessToken", ",", "refreshToken", "string", ",", "expiredAtFrom", ",", "expiredAtTo", "*", "time", ".", "Time", ")", "(", "int64", ",", "erro...
6,772
all-6773
[ "DefaultConfig", "returns", "the", "default", "configuration", "struct", ".", "Certain", "environment", "variables", "may", "be", "set", "which", "control", "the", "values", "for", "the", "default", "configuration", "." ]
[ "func", "DefaultConfig", "(", ")", "*", "Config", "{", "<mask>", "&", "Config", "{", "Consul", ":", "DefaultConsulConfig", "(", ")", ",", "Dedup", ":", "DefaultDedupConfig", "(", ")", ",", "Exec", ":", "DefaultExecConfig", "(", ")", ",", "Syslog", ":", "...
6,773
all-6774
[ "Activate", "is", "a", "wrapper", "around", "g_action_group_activate_action" ]
[ "func", "(", "v", "*", "ActionGroup", ")", "Activate", "(", "actionName", "<mask>", ",", "parameter", "*", "Variant", ")", "{", "C", ".", "g_action_group_activate_action", "(", "v", ".", "native", "(", ")", ",", "(", "*", "C", ".", "gchar", ")", "(", ...
6,774
all-6775
[ "export", "FileSequence_Format" ]
[ "func", "FileSequence_Format", "(", "id", "FileSeqId", ",", "tpl", "*", "C", ".", "char", ")", "(", "*", "C", ".", "char", ",", "Error", ")", "{", "fs", ",", "ok", ":=", "sFileSeqs", ".", "Get", "(", "id", ")", "\n", "if", "!", "<mask>", "{", "...
6,775
all-6776
[ "Invariant", ":", "Each", "snapshot", "n", "is", "dependent", "on", "snapshot", "n", "-", "1", ".", "Unless", "snapshot", "n", "-", "1", "is", "collected", "snapshot", "n", "cannot", "be", "collected", "." ]
[ "func", "(", "m", "*", "Nitro", ")", "collectDead", "(", ")", "{", "buf1", ":=", "m", ".", "snapshots", ".", "MakeBuf", "(", ")", "\n", "buf2", ":=", "m", ".", "snapshots", ".", "MakeBuf", "(", ")", "\n", "defer", "m", ".", "snapshots", ".", "Fre...
6,776
all-6777
[ "Returns", "information", "about", "several", "active", "uniform", "variables", "for", "the", "specified", "program", "object" ]
[ "func", "GetActiveUniformsiv", "(", "<mask>", "uint32", ",", "uniformCount", "int32", ",", "uniformIndices", "*", "uint32", ",", "pname", "uint32", ",", "params", "*", "int32", ")", "{", "syscall", ".", "Syscall6", "(", "gpGetActiveUniformsiv", ",", "5", ",", ...
6,777
all-6778
[ "UnmarshalJSON", "supports", "json", ".", "Unmarshaler", "interface" ]
[ "func", "(", "v", "*", "GetUsageAndQuotaParams", ")", "UnmarshalJSON", "(", "data", "[", "]", "byte", ")", "error", "{", "r", ":=", "jlexer", ".", "Lexer", "{", "Data", ":", "data", "}", "\n", "easyjsonC5a4559bDecodeGithubComChromedpCdprotoStorage6", "(", "&",...
6,778
all-6779
[ "Do", "executes", "CSS", ".", "setStyleSheetText", "against", "the", "provided", "context", ".", "returns", ":", "sourceMapURL", "-", "URL", "of", "source", "map", "associated", "with", "script", "(", "if", "any", ")", "." ]
[ "func", "(", "p", "*", "SetStyleSheetTextParams", ")", "Do", "(", "ctx", "context", ".", "Context", ")", "(", "sourceMapURL", "string", ",", "err", "error", ")", "{", "// execute", "<mask>", "res", "SetStyleSheetTextReturns", "\n", "err", "=", "cdp", ".", ...
6,779
all-6780
[ "findLast", "returns", "the", "last", "element", ".", "If", "head", "(", "empty", "list", ")", "we", "return", "nil", ".", "All", "the", "find", "functions", "will", "NEVER", "return", "the", "head", "nodes", "." ]
[ "func", "(", "s", "*", "Skiplist", ")", "findLast", "(", ")", "*", "node", "{", "n", ":=", "s", ".", "head", "\n", "level", ":=", "int", "(", "s", ".", "getHeight", "(", ")", ")", "-", "1", "\n", "for", "{", "next", ":=", "s", ".", "getNext",...
6,780
all-6781
[ "CreateIndex", "creates", "the", "index", "into", "database", ".", "If", "table", "isn", "t", "direct", "/", "indirect", "struct", "it", "returns", "error", "." ]
[ "func", "(", "<mask>", "*", "DB", ")", "CreateIndex", "(", "table", "interface", "{", "}", ",", "name", "string", ",", "names", "...", "string", ")", "error", "{", "return", "db", ".", "createIndex", "(", "table", ",", "false", ",", "name", ",", "nam...
6,781
all-6782
[ "BCCAddrs", "returns", "a", "copy", "of", "MailBuilder", "with", "the", "specified", "as", "the", "blind", "CC", "list", ".", "This", "method", "only", "has", "an", "effect", "if", "the", "Send", "method", "is", "used", "to", "transmit", "the", "message", ...
[ "func", "(", "p", "MailBuilder", ")", "BCCAddrs", "(", "bcc", "[", "]", "mail", ".", "<mask>", ")", "MailBuilder", "{", "p", ".", "bcc", "=", "bcc", "\n", "return", "p", "\n", "}" ]
6,782
all-6783
[ "/", "*", "SetFetchSize", "sets", "the", "fetchSize", "of", "the", "connector", "." ]
[ "func", "(", "c", "*", "Connector", ")", "SetFetchSize", "(", "fetchSize", "int", ")", "error", "{", "c", ".", "mu", ".", "Lock", "(", ")", "\n", "defer", "c", ".", "mu", ".", "Unlock", "(", ")", "\n", "if", "fetchSize", "<", "minFetchSize", "{", ...
6,783
all-6784
[ "Create", "a", "new", "Account", "with", "the", "specified", "values", ".", "https", ":", "//", "www", ".", "twilio", ".", "com", "/", "docs", "/", "api", "/", "rest", "/", "subaccounts#creating", "-", "subaccounts" ]
[ "func", "(", "a", "*", "AccountService", ")", "Create", "(", "ctx", "context", ".", "Context", ",", "data", "url", ".", "Values", ")", "(", "*", "Account", ",", "error", ")", "{", "acct", ":=", "new", "(", "Account", ")", "\n", "err", ":=", "a", ...
6,784
all-6785
[ "GetYaxisOk", "returns", "a", "tuple", "with", "the", "Yaxis", "field", "if", "it", "s", "non", "-", "nil", "zero", "value", "otherwise", "and", "a", "boolean", "to", "check", "if", "the", "value", "has", "been", "set", "." ]
[ "func", "(", "h", "*", "HeatmapDefinition", ")", "GetYaxisOk", "(", ")", "(", "WidgetAxis", ",", "bool", ")", "{", "if", "h", "==", "nil", "||", "h", ".", "Yaxis", "==", "nil", "{", "return", "WidgetAxis", "{", "}", ",", "false", "\n", "}", "\n", ...
6,785
all-6786
[ "Error", "returns", "the", "underlying", "error", "s", "message", "." ]
[ "func", "(", "err", "*", "Error", ")", "<mask>", "(", ")", "string", "{", "msg", ":=", "err", ".", "Err", ".", "Error", "(", ")", "\n", "if", "err", ".", "prefix", "!=", "\"", "\"", "{", "msg", "=", "fmt", ".", "Sprintf", "(", "\"", "\"", ","...
6,786
all-6787
[ "WriteTo", "writes", "data", "to", "w", "." ]
[ "func", "(", "e", "*", "htmlComment", ")", "WriteTo", "(", "w", "io", ".", "<mask>", ")", "(", "int64", ",", "error", ")", "{", "var", "bf", "bytes", ".", "Buffer", "\n\n", "// Write an open tag.", "bf", ".", "WriteString", "(", "e", ".", "opts", "."...
6,787
all-6788
[ "CvSeq", "*", "cvApproxPoly", "(", "const", "void", "*", "src_seq", "int", "header_size", "CvMemStorage", "*", "storage", "int", "method", "double", "eps", "int", "recursive", "=", "0", ")" ]
[ "func", "ApproxPoly", "(", "src", "*", "Seq", ",", "header_size", "int", ",", "storage", "*", "MemStorage", ",", "method", "int", ",", "eps", "float64", ",", "recursive", "int", ")", "*", "Seq", "{", "seq", ":=", "C", ".", "cvApproxPoly", "(", "unsafe"...
6,788
all-6789
[ "UnmarshalJSON", "supports", "json", ".", "Unmarshaler", "interface" ]
[ "func", "(", "v", "*", "Media", ")", "UnmarshalJSON", "(", "data", "[", "]", "<mask>", ")", "error", "{", "r", ":=", "jlexer", ".", "Lexer", "{", "Data", ":", "data", "}", "\n", "easyjsonC5a4559bDecodeGithubComChromedpCdprotoCss31", "(", "&", "r", ",", "...
6,789
all-6790
[ "HaveAttribute", "passes", "when", "the", "expected", "attribute", "and", "value", "are", "present", "on", "the", "element", ".", "This", "matcher", "will", "fail", "if", "the", "provided", "selection", "refers", "to", "more", "than", "one", "element", "." ]
[ "func", "HaveAttribute", "(", "attribute", "string", ",", "value", "string", ")", "types", ".", "GomegaMatcher", "{", "return", "&", "<mask>", ".", "HaveAttributeMatcher", "{", "ExpectedAttribute", ":", "attribute", ",", "ExpectedValue", ":", "value", "}", "\n",...
6,790
all-6791
[ "Header", "returns", "response", "header", "representation", ".", "The", "returned", "value", "is", "valid", "until", "the", "next", "call", "to", "ResponseHeader", "methods", "." ]
[ "func", "(", "h", "*", "ResponseHeader", ")", "Header", "(", ")", "[", "]", "byte", "{", "h", ".", "bufKV", ".", "value", "=", "h", ".", "AppendBytes", "(", "h", ".", "bufKV", ".", "value", "[", ":", "0", "]", ")", "\n", "return", "h", ".", "...
6,791
all-6792
[ "Execute", "-", "updates", "org", "configuration" ]
[ "func", "(", "c", "*", "UpdateOrgsConfigurationCommand", ")", "Execute", "(", "args", "[", "]", "string", ")", "error", "{", "c", ".", "initConfig", "(", ")", "\n", "orgs", ",", "err", ":=", "c", ".", "ConfigManager", ".", "Orgs", "(", ")", "\n", "if...
6,792
all-6793
[ "MarshalJSON", "supports", "json", ".", "Marshaler", "interface" ]
[ "func", "(", "v", "Request", ")", "MarshalJSON", "(", ")", "(", "[", "]", "byte", ",", "error", ")", "{", "w", ":=", "jwriter", ".", "Writer", "{", "}", "\n", "easyjsonC5a4559bEncodeGithubComChromedpCdprotoNetwork25", "(", "&", "w", ",", "v", ")", "\n", ...
6,793
all-6794
[ "resourceVSphereDPMHostOverrideObjects", "handles", "the", "fetching", "of", "the", "cluster", "and", "host", "depending", "on", "what", "attributes", "are", "available", ":", "*", "If", "the", "resource", "ID", "is", "available", "the", "data", "is", "derived", ...
[ "func", "resourceVSphereDPMHostOverrideObjects", "(", "d", "*", "schema", ".", "ResourceData", ",", "meta", "interface", "{", "}", ",", ")", "(", "*", "object", ".", "ClusterComputeResource", ",", "*", "object", ".", "HostSystem", ",", "error", ")", "{", "if...
6,794
all-6795
[ "MarshalEasyJSON", "satisfies", "easyjson", ".", "Marshaler", "." ]
[ "func", "(", "t", "StreamFormat", ")", "MarshalEasyJSON", "(", "out", "*", "jwriter", ".", "Writer", ")", "{", "<mask>", ".", "String", "(", "string", "(", "t", ")", ")", "\n", "}" ]
6,795
all-6796
[ "watcherSetByKey", "gets", "the", "set", "of", "watchers", "that", "receive", "events", "on", "the", "given", "key", "." ]
[ "func", "(", "wg", "*", "watcherGroup", ")", "watcherSetByKey", "(", "key", "string", ")", "watcherSet", "{", "wkeys", ":=", "wg", ".", "keyWatchers", "[", "key", "]", "\n", "wranges", ":=", "wg", ".", "ranges", ".", "Stab", "(", "adt", ".", "NewString...
6,796
all-6797
[ "MarshalJSON", "supports", "json", ".", "Marshaler", "interface" ]
[ "func", "(", "v", "GetDOMCountersReturns", ")", "MarshalJSON", "(", ")", "(", "[", "]", "byte", ",", "error", ")", "{", "w", ":=", "jwriter", ".", "Writer", "{", "}", "\n", "easyjsonC5a4559bEncodeGithubComChromedpCdprotoMemory10", "(", "&", "w", ",", "v", ...
6,797
all-6798
[ "NewGossipSenders", "returns", "a", "usable", "GossipSenders", "leveraging", "the", "ProtocolSender", ".", "TODO", "(", "pb", ")", ":", "is", "stop", "chan", "the", "best", "way", "to", "do", "that?" ]
[ "func", "newGossipSenders", "(", "sender", "protocolSender", ",", "stop", "<-", "chan", "struct", "{", "}", ")", "*", "gossipSenders", "{", "return", "&", "gossipSenders", "{", "sender", ":", "sender", ",", "<mask>", ":", "stop", ",", "senders", ":", "make...
6,798
all-6799
[ "WithTimeout", "adds", "the", "timeout", "to", "the", "patch", "apps", "app", "params" ]
[ "func", "(", "o", "*", "PatchAppsAppParams", ")", "WithTimeout", "(", "timeout", "<mask>", ".", "Duration", ")", "*", "PatchAppsAppParams", "{", "o", ".", "SetTimeout", "(", "timeout", ")", "\n", "return", "o", "\n", "}" ]
6,799
all-6800
[ "the", "actual", "work", "is", "done", "on", "the", "handler", ".", "go", "here", "we", "just", "provide", "a", "helper", "for", "the", "main", "package", "to", "create", "an", "http", ".", "Server", "and", "serve", "a", "cache", "remote", "service", "...
[ "func", "New", "(", "addr", "string", ",", "<mask>", "Store", ")", "*", "http", ".", "Server", "{", "if", "store", "==", "nil", "{", "store", "=", "NewMemoryStore", "(", ")", "\n", "}", "\n", "h", ":=", "&", "Handler", "{", "store", ":", "store", ...