repo
stringclasses
195 values
path
stringlengths
4
99
func_name
stringlengths
0
41
original_string
stringlengths
72
56.1k
language
stringclasses
1 value
code
stringlengths
72
56.1k
code_tokens
listlengths
25
8.12k
docstring
stringlengths
2
12.5k
docstring_tokens
listlengths
1
449
sha
stringclasses
197 values
url
stringlengths
88
186
partition
stringclasses
1 value
summary
stringlengths
8
338
input_ids
listlengths
502
502
token_type_ids
listlengths
502
502
attention_mask
listlengths
502
502
labels
listlengths
502
502
GeekyAnts/vue-native-core
packages/vue-server-renderer/build.js
createRenderer$1
function createRenderer$1 (ref) { if ( ref === void 0 ) ref = {}; var modules = ref.modules; if ( modules === void 0 ) modules = []; var directives = ref.directives; if ( directives === void 0 ) directives = {}; var isUnaryTag = ref.isUnaryTag; if ( isUnaryTag === void 0 ) isUnaryTag = (function () { return fal...
javascript
function createRenderer$1 (ref) { if ( ref === void 0 ) ref = {}; var modules = ref.modules; if ( modules === void 0 ) modules = []; var directives = ref.directives; if ( directives === void 0 ) directives = {}; var isUnaryTag = ref.isUnaryTag; if ( isUnaryTag === void 0 ) isUnaryTag = (function () { return fal...
[ "function", "createRenderer$1", "(", "ref", ")", "{", "if", "(", "ref", "===", "void", "0", ")", "ref", "=", "{", "}", ";", "var", "modules", "=", "ref", ".", "modules", ";", "if", "(", "modules", "===", "void", "0", ")", "modules", "=", "[", "]"...
/*
[ "/", "*" ]
a7b4c9e35fe3f01d7576086f41e5e9ec6975b72e
https://github.com/GeekyAnts/vue-native-core/blob/a7b4c9e35fe3f01d7576086f41e5e9ec6975b72e/packages/vue-server-renderer/build.js#L5542-L5613
train
Creates a renderer function for a component.
[ 30522, 3853, 3443, 7389, 4063, 2121, 1002, 1015, 1006, 25416, 1007, 1063, 2065, 1006, 25416, 1027, 1027, 1027, 11675, 1014, 1007, 25416, 1027, 1063, 1065, 1025, 13075, 14184, 1027, 25416, 1012, 14184, 1025, 2065, 1006, 14184, 1027, 1027, 10...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
facebook/watchman
node/bser/index.js
dumpToBuffer
function dumpToBuffer(val) { var buf = new Accumulator(); // Build out the header buf.writeByte(0); buf.writeByte(1); // Reserve room for an int32 to hold our PDU length buf.writeByte(BSER_INT32); buf.writeInt(0, 4); // We'll come back and fill this in at the end dump_any(buf, val); // Compute PDU l...
javascript
function dumpToBuffer(val) { var buf = new Accumulator(); // Build out the header buf.writeByte(0); buf.writeByte(1); // Reserve room for an int32 to hold our PDU length buf.writeByte(BSER_INT32); buf.writeInt(0, 4); // We'll come back and fill this in at the end dump_any(buf, val); // Compute PDU l...
[ "function", "dumpToBuffer", "(", "val", ")", "{", "var", "buf", "=", "new", "Accumulator", "(", ")", ";", "// Build out the header", "buf", ".", "writeByte", "(", "0", ")", ";", "buf", ".", "writeByte", "(", "1", ")", ";", "// Reserve room for an int32 to ho...
BSER encode value and return a buffer of the contents
[ "BSER", "encode", "value", "and", "return", "a", "buffer", "of", "the", "contents" ]
8d576a2d3e1191c977f03f584993da63a3b8e5ec
https://github.com/facebook/watchman/blob/8d576a2d3e1191c977f03f584993da63a3b8e5ec/node/bser/index.js#L566-L585
train
Dump the given value into a buffer.
[ 30522, 3853, 15653, 3406, 8569, 12494, 1006, 11748, 1007, 1063, 13075, 20934, 2546, 1027, 2047, 16222, 2819, 20350, 1006, 1007, 1025, 1013, 1013, 3857, 2041, 1996, 20346, 20934, 2546, 1012, 4339, 3762, 2618, 1006, 1014, 1007, 1025, 20934, 2...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/extensibility/Package.js
formatError
function formatError(error) { function localize(key) { if (Strings[key]) { return Strings[key]; } console.log("Unknown installation error", key); return Strings.UNKNOWN_ERROR; } if (Array.isArray(error)) { error[0] = lo...
javascript
function formatError(error) { function localize(key) { if (Strings[key]) { return Strings[key]; } console.log("Unknown installation error", key); return Strings.UNKNOWN_ERROR; } if (Array.isArray(error)) { error[0] = lo...
[ "function", "formatError", "(", "error", ")", "{", "function", "localize", "(", "key", ")", "{", "if", "(", "Strings", "[", "key", "]", ")", "{", "return", "Strings", "[", "key", "]", ";", "}", "console", ".", "log", "(", "\"Unknown installation error\""...
Converts an error object as returned by install(), installFromPath() or installFromURL() into a flattened, localized string. @param {string|Array.<string>} error @return {string}
[ "Converts", "an", "error", "object", "as", "returned", "by", "install", "()", "installFromPath", "()", "or", "installFromURL", "()", "into", "a", "flattened", "localized", "string", "." ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/extensibility/Package.js#L414-L429
train
format error
[ 30522, 3853, 4289, 2121, 29165, 1006, 7561, 1007, 1063, 3853, 2334, 4697, 1006, 3145, 1007, 1063, 2065, 1006, 7817, 1031, 3145, 1033, 1007, 1063, 2709, 7817, 1031, 3145, 1033, 1025, 1065, 10122, 1012, 8833, 1006, 1000, 4242, 8272, 7561, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
nodejs/node-gyp
lib/configure.js
run
function run(exec, args, shell, callback) { var env = extend({}, this.env) env.TERM = 'dumb' const opts = { env: env, shell: shell } this.log.silly('execFile: exec = %j', exec) this.log.silly('execFile: args = %j', args) this.log.silly('execFile: opts = %j', opts) try { this.execFile(...
javascript
function run(exec, args, shell, callback) { var env = extend({}, this.env) env.TERM = 'dumb' const opts = { env: env, shell: shell } this.log.silly('execFile: exec = %j', exec) this.log.silly('execFile: args = %j', args) this.log.silly('execFile: opts = %j', opts) try { this.execFile(...
[ "function", "run", "(", "exec", ",", "args", ",", "shell", ",", "callback", ")", "{", "var", "env", "=", "extend", "(", "{", "}", ",", "this", ".", "env", ")", "env", ".", "TERM", "=", "'dumb'", "const", "opts", "=", "{", "env", ":", "env", ","...
Run an executable or shell command, trimming the output.
[ "Run", "an", "executable", "or", "shell", "command", "trimming", "the", "output", "." ]
721eb691cf15556cc2700eda0558d5bad5f84232
https://github.com/nodejs/node-gyp/blob/721eb691cf15556cc2700eda0558d5bad5f84232/lib/configure.js#L581-L606
train
Runs a command in the specified shell.
[ 30522, 3853, 2448, 1006, 4654, 8586, 1010, 12098, 5620, 1010, 5806, 1010, 2655, 5963, 1007, 1063, 13075, 4372, 2615, 1027, 7949, 1006, 1063, 1065, 1010, 2023, 1012, 4372, 2615, 1007, 4372, 2615, 1012, 2744, 1027, 1005, 12873, 1005, 9530, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
markdown-it/markdown-it
lib/parser_inline.js
ParserInline
function ParserInline() { var i; /** * ParserInline#ruler -> Ruler * * [[Ruler]] instance. Keep configuration of inline rules. **/ this.ruler = new Ruler(); for (i = 0; i < _rules.length; i++) { this.ruler.push(_rules[i][0], _rules[i][1]); } /** * ParserInline#ruler2 -> Ruler * *...
javascript
function ParserInline() { var i; /** * ParserInline#ruler -> Ruler * * [[Ruler]] instance. Keep configuration of inline rules. **/ this.ruler = new Ruler(); for (i = 0; i < _rules.length; i++) { this.ruler.push(_rules[i][0], _rules[i][1]); } /** * ParserInline#ruler2 -> Ruler * *...
[ "function", "ParserInline", "(", ")", "{", "var", "i", ";", "/**\n * ParserInline#ruler -> Ruler\n *\n * [[Ruler]] instance. Keep configuration of inline rules.\n **/", "this", ".", "ruler", "=", "new", "Ruler", "(", ")", ";", "for", "(", "i", "=", "0", ";", "...
new ParserInline()
[ "new", "ParserInline", "()" ]
ba6830ba13fb92953a91fb90318964ccd15b82c4
https://github.com/markdown-it/markdown-it/blob/ba6830ba13fb92953a91fb90318964ccd15b82c4/lib/parser_inline.js#L40-L65
train
Inline Parser class
[ 30522, 3853, 11968, 8043, 2378, 4179, 1006, 1007, 1063, 13075, 1045, 1025, 1013, 1008, 1008, 1008, 11968, 8043, 2378, 4179, 1001, 7786, 1011, 1028, 7786, 1008, 1008, 1031, 1031, 7786, 1033, 1033, 6013, 1012, 2562, 9563, 1997, 23881, 3513, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
apache/incubator-echarts
src/chart/sunburst/SunburstPiece.js
getNodeColor
function getNodeColor(node, seriesModel, ecModel) { // Color from visualMap var visualColor = node.getVisual('color'); var visualMetaList = node.getVisual('visualMeta'); if (!visualMetaList || visualMetaList.length === 0) { // Use first-generation color if has no visualMap visualColor = ...
javascript
function getNodeColor(node, seriesModel, ecModel) { // Color from visualMap var visualColor = node.getVisual('color'); var visualMetaList = node.getVisual('visualMeta'); if (!visualMetaList || visualMetaList.length === 0) { // Use first-generation color if has no visualMap visualColor = ...
[ "function", "getNodeColor", "(", "node", ",", "seriesModel", ",", "ecModel", ")", "{", "// Color from visualMap", "var", "visualColor", "=", "node", ".", "getVisual", "(", "'color'", ")", ";", "var", "visualMetaList", "=", "node", ".", "getVisual", "(", "'visu...
Get node color @param {TreeNode} node the node to get color @param {module:echarts/model/Series} seriesModel series @param {module:echarts/model/Global} ecModel echarts defaults
[ "Get", "node", "color" ]
4d0ea095dc3929cb6de40c45748826e7999c7aa8
https://github.com/apache/incubator-echarts/blob/4d0ea095dc3929cb6de40c45748826e7999c7aa8/src/chart/sunburst/SunburstPiece.js#L356-L384
train
Get node color
[ 30522, 3853, 2131, 3630, 3207, 18717, 1006, 13045, 1010, 2186, 5302, 9247, 1010, 14925, 5302, 9247, 1007, 1063, 1013, 1013, 3609, 2013, 5107, 2863, 2361, 13075, 5107, 18717, 1027, 13045, 1012, 2131, 11365, 8787, 1006, 1005, 3609, 1005, 1007...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
babel/babel
packages/babel-traverse/src/path/evaluation.js
deopt
function deopt(path, state) { if (!state.confident) return; state.deoptPath = path; state.confident = false; }
javascript
function deopt(path, state) { if (!state.confident) return; state.deoptPath = path; state.confident = false; }
[ "function", "deopt", "(", "path", ",", "state", ")", "{", "if", "(", "!", "state", ".", "confident", ")", "return", ";", "state", ".", "deoptPath", "=", "path", ";", "state", ".", "confident", "=", "false", ";", "}" ]
Deopts the evaluation
[ "Deopts", "the", "evaluation" ]
1969e6b6aa7d90be3fbb3aca98ea96849656a55a
https://github.com/babel/babel/blob/1969e6b6aa7d90be3fbb3aca98ea96849656a55a/packages/babel-traverse/src/path/evaluation.js#L34-L38
train
Deopt a path
[ 30522, 3853, 2139, 7361, 2102, 1006, 4130, 1010, 2110, 1007, 1063, 2065, 1006, 999, 2110, 1012, 9657, 1007, 2709, 1025, 2110, 1012, 2139, 7361, 25856, 8988, 1027, 4130, 1025, 2110, 1012, 9657, 1027, 6270, 1025, 1065, 102, 0, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.m/src/sap/m/GrowingEnablement.js
function(bLoading) { var oTrigger = this._oTrigger, oControl = this._oControl; // If there are no visible columns then also hide the trigger. if (!oTrigger || !oControl || !oControl.shouldRenderItems() || !oControl.getDomRef()) { return; } var oBinding = oControl.getBinding("items"); if (!oB...
javascript
function(bLoading) { var oTrigger = this._oTrigger, oControl = this._oControl; // If there are no visible columns then also hide the trigger. if (!oTrigger || !oControl || !oControl.shouldRenderItems() || !oControl.getDomRef()) { return; } var oBinding = oControl.getBinding("items"); if (!oB...
[ "function", "(", "bLoading", ")", "{", "var", "oTrigger", "=", "this", ".", "_oTrigger", ",", "oControl", "=", "this", ".", "_oControl", ";", "// If there are no visible columns then also hide the trigger.", "if", "(", "!", "oTrigger", "||", "!", "oControl", "||",...
updates the trigger state
[ "updates", "the", "trigger", "state" ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.m/src/sap/m/GrowingEnablement.js#L611-L679
train
Show or hide the trigger
[ 30522, 3853, 1006, 1038, 18570, 1007, 1063, 13075, 27178, 3089, 13327, 1027, 2023, 1012, 1035, 27178, 3089, 13327, 1010, 1051, 8663, 13181, 2140, 1027, 2023, 1012, 1035, 1051, 8663, 13181, 2140, 1025, 1013, 1013, 2065, 2045, 2024, 2053, 571...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/editor/EditorStatusBar.js
_init
function _init() { $cursorInfo = $("#status-cursor"); $fileInfo = $("#status-file"); $indentType = $("#indent-type"); $indentWidthLabel = $("#indent-width-label"); $indentWidthInput = $("#indent-width-input"); $statusOverwrite = $("#statu...
javascript
function _init() { $cursorInfo = $("#status-cursor"); $fileInfo = $("#status-file"); $indentType = $("#indent-type"); $indentWidthLabel = $("#indent-width-label"); $indentWidthInput = $("#indent-width-input"); $statusOverwrite = $("#statu...
[ "function", "_init", "(", ")", "{", "$cursorInfo", "=", "$", "(", "\"#status-cursor\"", ")", ";", "$fileInfo", "=", "$", "(", "\"#status-file\"", ")", ";", "$indentType", "=", "$", "(", "\"#indent-type\"", ")", ";", "$indentWidthLabel", "=", "$", "(", "\"#...
Initialize
[ "Initialize" ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/editor/EditorStatusBar.js#L380-L520
train
Initialize status bar
[ 30522, 3853, 1035, 1999, 4183, 1006, 1007, 1063, 1002, 12731, 25301, 6657, 14876, 1027, 1002, 1006, 1000, 1001, 3570, 1011, 12731, 25301, 2099, 1000, 1007, 1025, 1002, 5371, 2378, 14876, 1027, 1002, 1006, 1000, 1001, 3570, 1011, 5371, 1000,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/model/analytics/odata4analytics.js
function(array, from, to) { var rest = array.slice((to || from) + 1 || array.length); array.length = from < 0 ? array.length + from : from; return array.push.apply(array, rest); }
javascript
function(array, from, to) { var rest = array.slice((to || from) + 1 || array.length); array.length = from < 0 ? array.length + from : from; return array.push.apply(array, rest); }
[ "function", "(", "array", ",", "from", ",", "to", ")", "{", "var", "rest", "=", "array", ".", "slice", "(", "(", "to", "||", "from", ")", "+", "1", "||", "array", ".", "length", ")", ";", "array", ".", "length", "=", "from", "<", "0", "?", "a...
TODO helper method to remove elements from array @private
[ "TODO", "helper", "method", "to", "remove", "elements", "from", "array" ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/model/analytics/odata4analytics.js#L3654-L3658
train
Add a range of items to an array
[ 30522, 3853, 1006, 9140, 1010, 2013, 1010, 2000, 1007, 1063, 13075, 2717, 1027, 9140, 1012, 14704, 1006, 1006, 2000, 1064, 1064, 2013, 1007, 1009, 1015, 1064, 1064, 9140, 1012, 3091, 1007, 1025, 9140, 1012, 3091, 1027, 2013, 1026, 1014, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
wuchangming/spy-debugger
buildin_modules/weinre/web/client/DataGrid.js
function() { var headerTableColumns = this._headerTableColumnGroup.children; var tableWidth = this._dataTable.offsetWidth; var numColumns = headerTableColumns.length; // Do not attempt to use offsetes if we're not attached to the document tree yet. if (!this...
javascript
function() { var headerTableColumns = this._headerTableColumnGroup.children; var tableWidth = this._dataTable.offsetWidth; var numColumns = headerTableColumns.length; // Do not attempt to use offsetes if we're not attached to the document tree yet. if (!this...
[ "function", "(", ")", "{", "var", "headerTableColumns", "=", "this", ".", "_headerTableColumnGroup", ".", "children", ";", "var", "tableWidth", "=", "this", ".", "_dataTable", ".", "offsetWidth", ";", "var", "numColumns", "=", "headerTableColumns", ".", "length"...
Updates the widths of the table, including the positions of the column resizers. IMPORTANT: This function MUST be called once after the element of the DataGrid is attached to its parent element and every subsequent time the width of the parent element is changed in order to make it possible to resize the columns. If ...
[ "Updates", "the", "widths", "of", "the", "table", "including", "the", "positions", "of", "the", "column", "resizers", ".", "IMPORTANT", ":", "This", "function", "MUST", "be", "called", "once", "after", "the", "element", "of", "the", "DataGrid", "is", "attach...
55c1dda0dff0c44920673711656ddfd7ff03c307
https://github.com/wuchangming/spy-debugger/blob/55c1dda0dff0c44920673711656ddfd7ff03c307/buildin_modules/weinre/web/client/DataGrid.js#L404-L427
train
This method is called when the width of the table is changed.
[ 30522, 3853, 1006, 1007, 1063, 13075, 20346, 10880, 25778, 2819, 3619, 1027, 2023, 1012, 1035, 20346, 10880, 25778, 2819, 3070, 22107, 1012, 2336, 1025, 13075, 2795, 9148, 11927, 2232, 1027, 2023, 1012, 1035, 2951, 10880, 1012, 16396, 9148, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
graphql/graphql-js
resources/benchmark.js
prepareRevision
function prepareRevision(revision) { console.log(`🍳 Preparing ${revision}...`); if (revision === LOCAL) { return babelBuild(LOCAL_DIR()); } else { if (!fs.existsSync(TEMP_DIR())) { fs.mkdirSync(TEMP_DIR()); } const hash = hashForRevision(revision); const dir = TEMP_DIR(hash); if...
javascript
function prepareRevision(revision) { console.log(`🍳 Preparing ${revision}...`); if (revision === LOCAL) { return babelBuild(LOCAL_DIR()); } else { if (!fs.existsSync(TEMP_DIR())) { fs.mkdirSync(TEMP_DIR()); } const hash = hashForRevision(revision); const dir = TEMP_DIR(hash); if...
[ "function", "prepareRevision", "(", "revision", ")", "{", "console", ".", "log", "(", "`", "ev", "ision}..", ".", "", "", "", "if", "(", "revision", "===", "LOCAL", ")", "{", "return", "babelBuild", "(", "LOCAL_DIR", "(", ")", ")", ";", "}", "else", ...
Build a benchmarkable environment for the given revision and returns path to its 'dist' directory.
[ "Build", "a", "benchmarkable", "environment", "for", "the", "given", "revision", "and", "returns", "path", "to", "its", "dist", "directory", "." ]
b65ff6db8893c1c68f0f236c4b2d663e6c55f5ef
https://github.com/graphql/graphql-js/blob/b65ff6db8893c1c68f0f236c4b2d663e6c55f5ef/resources/benchmark.js#L48-L77
train
Prepare a revision for babel build
[ 30522, 3853, 7374, 2890, 17084, 1006, 13921, 1007, 1063, 10122, 1012, 8833, 1006, 1036, 100, 8225, 1002, 1063, 13921, 1065, 1012, 1012, 1012, 1036, 1007, 1025, 2065, 1006, 13921, 1027, 1027, 1027, 2334, 1007, 1063, 2709, 11561, 20850, 19231...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.support/src/sap/ui/support/supportRules/IssueManager.js
function (rules, selectedRulesIDs, issues) { var rulesViewModel = {}, issueCount = 0, group = {}, library = {}, rule = {}, rulesCopy = jQuery.extend(true, {}, rules), issuesCopy = jQuery.extend(true, {}, issues); for (group in rulesCopy) { rulesViewModel[group] = jQuery.exten...
javascript
function (rules, selectedRulesIDs, issues) { var rulesViewModel = {}, issueCount = 0, group = {}, library = {}, rule = {}, rulesCopy = jQuery.extend(true, {}, rules), issuesCopy = jQuery.extend(true, {}, issues); for (group in rulesCopy) { rulesViewModel[group] = jQuery.exten...
[ "function", "(", "rules", ",", "selectedRulesIDs", ",", "issues", ")", "{", "var", "rulesViewModel", "=", "{", "}", ",", "issueCount", "=", "0", ",", "group", "=", "{", "}", ",", "library", "=", "{", "}", ",", "rule", "=", "{", "}", ",", "rulesCopy...
Gets rules and issues, and converts each rule to a ruleViewModel - parameters should be converted as specified beforehand. @public @method @name sap.ui.support.IssueManager.getRulesViewModel @param {object} rules All the rules from _mRulesets @param {array} selectedRulesIDs The rule ID's of the selected rules. @param {...
[ "Gets", "rules", "and", "issues", "and", "converts", "each", "rule", "to", "a", "ruleViewModel", "-", "parameters", "should", "be", "converted", "as", "specified", "beforehand", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.support/src/sap/ui/support/supportRules/IssueManager.js#L133-L195
train
Creates a new rules view model and issues view model
[ 30522, 3853, 1006, 3513, 1010, 3479, 6820, 4244, 9821, 1010, 3314, 1007, 1063, 13075, 3513, 8584, 5302, 9247, 1027, 1063, 1065, 1010, 3277, 3597, 16671, 1027, 1014, 1010, 2177, 1027, 1063, 1065, 1010, 3075, 1027, 1063, 1065, 1010, 3627, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
chartjs/Chart.js
src/scales/scale.time.js
computeOffsets
function computeOffsets(table, ticks, min, max, options) { var start = 0; var end = 0; var first, last; if (options.offset && ticks.length) { if (!getMin(options)) { first = interpolate(table, 'time', ticks[0], 'pos'); if (ticks.length === 1) { start = 1 - first; } else { start = (interpolate(ta...
javascript
function computeOffsets(table, ticks, min, max, options) { var start = 0; var end = 0; var first, last; if (options.offset && ticks.length) { if (!getMin(options)) { first = interpolate(table, 'time', ticks[0], 'pos'); if (ticks.length === 1) { start = 1 - first; } else { start = (interpolate(ta...
[ "function", "computeOffsets", "(", "table", ",", "ticks", ",", "min", ",", "max", ",", "options", ")", "{", "var", "start", "=", "0", ";", "var", "end", "=", "0", ";", "var", "first", ",", "last", ";", "if", "(", "options", ".", "offset", "&&", "...
Returns the start and end offsets from edges in the form of {start, end} where each value is a relative width to the scale and ranges between 0 and 1. They add extra margins on the both sides by scaling down the original scale. Offsets are added when the `offset` option is true.
[ "Returns", "the", "start", "and", "end", "offsets", "from", "edges", "in", "the", "form", "of", "{", "start", "end", "}", "where", "each", "value", "is", "a", "relative", "width", "to", "the", "scale", "and", "ranges", "between", "0", "and", "1", ".", ...
f093c36574d290330ed623e60fbd070421c730d5
https://github.com/chartjs/Chart.js/blob/f093c36574d290330ed623e60fbd070421c730d5/src/scales/scale.time.js#L384-L409
train
Compute the offsets for a given set of ticks
[ 30522, 3853, 24134, 27475, 8454, 1006, 2795, 1010, 16356, 2015, 1010, 8117, 1010, 4098, 1010, 7047, 1007, 1063, 13075, 2707, 1027, 1014, 1025, 13075, 2203, 1027, 1014, 1025, 13075, 2034, 1010, 2197, 1025, 2065, 1006, 7047, 1012, 16396, 1004...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.codeeditor/src/sap/ui/codeeditor/js/ace/worker-xml.js
function(namespaceURI,localName){ var attr = this.getNamedItemNS(namespaceURI,localName); _removeNamedNode(this._ownerElement,this,attr); return attr; }
javascript
function(namespaceURI,localName){ var attr = this.getNamedItemNS(namespaceURI,localName); _removeNamedNode(this._ownerElement,this,attr); return attr; }
[ "function", "(", "namespaceURI", ",", "localName", ")", "{", "var", "attr", "=", "this", ".", "getNamedItemNS", "(", "namespaceURI", ",", "localName", ")", ";", "_removeNamedNode", "(", "this", ".", "_ownerElement", ",", "this", ",", "attr", ")", ";", "ret...
raises: NOT_FOUND_ERR,NO_MODIFICATION_ALLOWED_ERR
[ "raises", ":", "NOT_FOUND_ERR", "NO_MODIFICATION_ALLOWED_ERR" ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.codeeditor/src/sap/ui/codeeditor/js/ace/worker-xml.js#L2100-L2104
train
Removes an attribute from the element.
[ 30522, 3853, 1006, 3415, 15327, 9496, 1010, 2334, 18442, 1007, 1063, 13075, 2012, 16344, 1027, 2023, 1012, 2131, 18442, 23194, 6633, 3619, 1006, 3415, 15327, 9496, 1010, 2334, 18442, 1007, 1025, 1035, 6366, 18442, 2094, 3630, 3207, 1006, 20...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
sparksuite/simplemde-markdown-editor
src/js/simplemde.js
getState
function getState(cm, pos) { pos = pos || cm.getCursor("start"); var stat = cm.getTokenAt(pos); if(!stat.type) return {}; var types = stat.type.split(" "); var ret = {}, data, text; for(var i = 0; i < types.length; i++) { data = types[i]; if(data === "strong") { ret.bold = true; } else if(data === "v...
javascript
function getState(cm, pos) { pos = pos || cm.getCursor("start"); var stat = cm.getTokenAt(pos); if(!stat.type) return {}; var types = stat.type.split(" "); var ret = {}, data, text; for(var i = 0; i < types.length; i++) { data = types[i]; if(data === "strong") { ret.bold = true; } else if(data === "v...
[ "function", "getState", "(", "cm", ",", "pos", ")", "{", "pos", "=", "pos", "||", "cm", ".", "getCursor", "(", "\"start\"", ")", ";", "var", "stat", "=", "cm", ".", "getTokenAt", "(", "pos", ")", ";", "if", "(", "!", "stat", ".", "type", ")", "...
The state of CodeMirror at the given position.
[ "The", "state", "of", "CodeMirror", "at", "the", "given", "position", "." ]
6abda7ab68cc20f4aca870eb243747951b90ab04
https://github.com/sparksuite/simplemde-markdown-editor/blob/6abda7ab68cc20f4aca870eb243747951b90ab04/src/js/simplemde.js#L140-L179
train
Get state of a given position
[ 30522, 3853, 4152, 12259, 1006, 4642, 1010, 13433, 2015, 1007, 1063, 13433, 2015, 1027, 13433, 2015, 1064, 1064, 4642, 1012, 2131, 10841, 25301, 2099, 1006, 1000, 2707, 1000, 1007, 1025, 13075, 28093, 1027, 4642, 1012, 2131, 18715, 8189, 21...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
mui-org/material-ui
packages/material-ui-styles/src/getThemeProps/getThemeProps.js
getThemeProps
function getThemeProps(params) { const { theme, name, props } = params; if (!theme || !theme.props || !theme.props[name]) { return props; } // Resolve default props, code borrow from React source. // https://github.com/facebook/react/blob/15a8f031838a553e41c0b66eb1bcf1da8448104d/packages/react/src/React...
javascript
function getThemeProps(params) { const { theme, name, props } = params; if (!theme || !theme.props || !theme.props[name]) { return props; } // Resolve default props, code borrow from React source. // https://github.com/facebook/react/blob/15a8f031838a553e41c0b66eb1bcf1da8448104d/packages/react/src/React...
[ "function", "getThemeProps", "(", "params", ")", "{", "const", "{", "theme", ",", "name", ",", "props", "}", "=", "params", ";", "if", "(", "!", "theme", "||", "!", "theme", ".", "props", "||", "!", "theme", ".", "props", "[", "name", "]", ")", "...
/* eslint-disable no-restricted-syntax
[ "/", "*", "eslint", "-", "disable", "no", "-", "restricted", "-", "syntax" ]
1555e52367835946382fbf2a8f681de71318915d
https://github.com/mui-org/material-ui/blob/1555e52367835946382fbf2a8f681de71318915d/packages/material-ui-styles/src/getThemeProps/getThemeProps.js#L3-L22
train
Get theme props
[ 30522, 3853, 2131, 10760, 4168, 21572, 4523, 1006, 11498, 5244, 1007, 1063, 9530, 3367, 1063, 4323, 1010, 2171, 1010, 24387, 1065, 1027, 11498, 5244, 1025, 2065, 1006, 999, 4323, 1064, 1064, 999, 4323, 1012, 24387, 1064, 1064, 999, 4323, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/editor/EditorManager.js
openDocument
function openDocument(doc, pane, editorOptions) { var perfTimerName = PerfUtils.markStart("EditorManager.openDocument():\t" + (!doc || doc.file.fullPath)); if (doc && pane) { _showEditor(doc, pane, editorOptions); } PerfUtils.addMeasurement(perfTimerName); }
javascript
function openDocument(doc, pane, editorOptions) { var perfTimerName = PerfUtils.markStart("EditorManager.openDocument():\t" + (!doc || doc.file.fullPath)); if (doc && pane) { _showEditor(doc, pane, editorOptions); } PerfUtils.addMeasurement(perfTimerName); }
[ "function", "openDocument", "(", "doc", ",", "pane", ",", "editorOptions", ")", "{", "var", "perfTimerName", "=", "PerfUtils", ".", "markStart", "(", "\"EditorManager.openDocument():\\t\"", "+", "(", "!", "doc", "||", "doc", ".", "file", ".", "fullPath", ")", ...
Opens the specified document in the given pane @param {!Document} doc - the document to open @param {!Pane} pane - the pane to open the document in @param {!Object} editorOptions - If specified, contains editor options that can be passed to CodeMirror @return {boolean} true if the file can be opened, false if not
[ "Opens", "the", "specified", "document", "in", "the", "given", "pane" ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/editor/EditorManager.js#L613-L621
train
Open a document
[ 30522, 3853, 2330, 3527, 24894, 4765, 1006, 9986, 1010, 6090, 2063, 1010, 3559, 7361, 9285, 1007, 1063, 13075, 2566, 6199, 14428, 12789, 4168, 1027, 2566, 11263, 3775, 4877, 1012, 6017, 7559, 2102, 1006, 1000, 3559, 24805, 4590, 1012, 2330,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
angular/material
src/components/radioButton/radio-button.js
configureAria
function configureAria(element, scope){ element.attr({ id: attr.id || 'radio_' + $mdUtil.nextUid(), role: 'radio', 'aria-checked': 'false' }); $mdAria.expectWithText(element, 'aria-label'); }
javascript
function configureAria(element, scope){ element.attr({ id: attr.id || 'radio_' + $mdUtil.nextUid(), role: 'radio', 'aria-checked': 'false' }); $mdAria.expectWithText(element, 'aria-label'); }
[ "function", "configureAria", "(", "element", ",", "scope", ")", "{", "element", ".", "attr", "(", "{", "id", ":", "attr", ".", "id", "||", "'radio_'", "+", "$mdUtil", ".", "nextUid", "(", ")", ",", "role", ":", "'radio'", ",", "'aria-checked'", ":", ...
Inject ARIA-specific attributes appropriate for each radio button
[ "Inject", "ARIA", "-", "specific", "attributes", "appropriate", "for", "each", "radio", "button" ]
84ac558674e73958be84312444c48d9f823f6684
https://github.com/angular/material/blob/84ac558674e73958be84312444c48d9f823f6684/src/components/radioButton/radio-button.js#L335-L343
train
Aria - specific configuration for the radio button
[ 30522, 3853, 9530, 8873, 27390, 14644, 2401, 1006, 5783, 1010, 9531, 1007, 1063, 5783, 1012, 2012, 16344, 1006, 1063, 8909, 1024, 2012, 16344, 1012, 8909, 1064, 1064, 1005, 2557, 1035, 1005, 1009, 1002, 9108, 21823, 2140, 1012, 2279, 21272,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
TryGhost/Ghost
core/server/api/v0.1/subscribers.js
doQuery
function doQuery(options) { return models.Subscriber.getByEmail(options.data.subscribers[0].email) .then((subscriber) => { if (subscriber && options.context.external) { // we don't expose this information return Promise.reso...
javascript
function doQuery(options) { return models.Subscriber.getByEmail(options.data.subscribers[0].email) .then((subscriber) => { if (subscriber && options.context.external) { // we don't expose this information return Promise.reso...
[ "function", "doQuery", "(", "options", ")", "{", "return", "models", ".", "Subscriber", ".", "getByEmail", "(", "options", ".", "data", ".", "subscribers", "[", "0", "]", ".", "email", ")", ".", "then", "(", "(", "subscriber", ")", "=>", "{", "if", "...
### Model Query Make the call to the Model layer @param {Object} options @returns {Object} options
[ "###", "Model", "Query", "Make", "the", "call", "to", "the", "Model", "layer" ]
bb7bb55cf3e60af99ebbc56099928827b58461bc
https://github.com/TryGhost/Ghost/blob/bb7bb55cf3e60af99ebbc56099928827b58461bc/core/server/api/v0.1/subscribers.js#L113-L136
train
Query for a subscriber
[ 30522, 3853, 2079, 4226, 2854, 1006, 7047, 1007, 1063, 2709, 4275, 1012, 4942, 29234, 2099, 1012, 2131, 3762, 14545, 4014, 1006, 7047, 1012, 2951, 1012, 17073, 1031, 30524, 1007, 1025, 1065, 2842, 2065, 1006, 4942, 29234, 2099, 1007, 1063, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
keplergl/kepler.gl
src/reducers/vis-state-updaters.js
closeSpecificMapAtIndex
function closeSpecificMapAtIndex(state, action) { // retrieve layers meta data from the remaining map that we need to keep const indexToRetrieve = 1 - action.payload; const metaSettings = state.splitMaps[indexToRetrieve]; if (!metaSettings || !metaSettings.layers) { // if we can't find the meta settings we...
javascript
function closeSpecificMapAtIndex(state, action) { // retrieve layers meta data from the remaining map that we need to keep const indexToRetrieve = 1 - action.payload; const metaSettings = state.splitMaps[indexToRetrieve]; if (!metaSettings || !metaSettings.layers) { // if we can't find the meta settings we...
[ "function", "closeSpecificMapAtIndex", "(", "state", ",", "action", ")", "{", "// retrieve layers meta data from the remaining map that we need to keep", "const", "indexToRetrieve", "=", "1", "-", "action", ".", "payload", ";", "const", "metaSettings", "=", "state", ".", ...
When a user clicks on the specific map closing icon the application will close the selected map and will merge the remaining one with the global state TODO: i think in the future this action should be called merge map layers with global settings @param {Object} state `visState` @param {Object} action action @returns {O...
[ "When", "a", "user", "clicks", "on", "the", "specific", "map", "closing", "icon", "the", "application", "will", "close", "the", "selected", "map", "and", "will", "merge", "the", "remaining", "one", "with", "the", "global", "state", "TODO", ":", "i", "think...
779238435707cc54335c2d00001e4b9334b314aa
https://github.com/keplergl/kepler.gl/blob/779238435707cc54335c2d00001e4b9334b314aa/src/reducers/vis-state-updaters.js#L1196-L1228
train
close specific map at index 1
[ 30522, 3853, 14572, 5051, 6895, 8873, 27487, 22068, 7629, 3207, 2595, 1006, 2110, 1010, 2895, 1007, 1063, 1013, 1013, 12850, 9014, 18804, 2951, 2013, 1996, 3588, 4949, 2008, 2057, 2342, 2000, 2562, 9530, 3367, 5950, 19277, 18886, 18697, 102...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/thirdparty/signals.js
Signal
function Signal() { /** * @type Array.<SignalBinding> * @private */ this._bindings = []; this._prevParams = null; // enforce dispatch to aways work on same context (#47) var self = this; this.dispatch = function(){ Signal.prototype....
javascript
function Signal() { /** * @type Array.<SignalBinding> * @private */ this._bindings = []; this._prevParams = null; // enforce dispatch to aways work on same context (#47) var self = this; this.dispatch = function(){ Signal.prototype....
[ "function", "Signal", "(", ")", "{", "/**\n * @type Array.<SignalBinding>\n * @private\n */", "this", ".", "_bindings", "=", "[", "]", ";", "this", ".", "_prevParams", "=", "null", ";", "// enforce dispatch to aways work on same context (#47)", "var", ...
Custom event broadcaster <br />- inspired by Robert Penner's AS3 Signals. @name Signal @author Miller Medeiros @constructor
[ "Custom", "event", "broadcaster", "<br", "/", ">", "-", "inspired", "by", "Robert", "Penner", "s", "AS3", "Signals", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/thirdparty/signals.js#L176-L189
train
Signal constructor.
[ 30522, 3853, 4742, 1006, 1007, 1063, 1013, 1008, 1008, 1008, 1030, 2828, 9140, 1012, 1026, 4742, 8428, 4667, 1028, 1008, 1030, 2797, 1008, 1013, 2023, 1012, 1035, 8031, 2015, 1027, 1031, 1033, 1025, 2023, 1012, 1035, 3653, 2615, 28689, 52...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/LiveDevelopment/Inspector/Inspector.js
_verifySignature
function _verifySignature(signature, value) { if (value === undefined) { console.assert(signature.optional === true, "Missing argument: " + signature.name); } return true; }
javascript
function _verifySignature(signature, value) { if (value === undefined) { console.assert(signature.optional === true, "Missing argument: " + signature.name); } return true; }
[ "function", "_verifySignature", "(", "signature", ",", "value", ")", "{", "if", "(", "value", "===", "undefined", ")", "{", "console", ".", "assert", "(", "signature", ".", "optional", "===", "true", ",", "\"Missing argument: \"", "+", "signature", ".", "nam...
user agent string Check a parameter value against the given signature This only checks for optional parameters, not types Type checking is complex because of $ref and done on the remote end anyways @param {signature} @param {value}
[ "user", "agent", "string", "Check", "a", "parameter", "value", "against", "the", "given", "signature", "This", "only", "checks", "for", "optional", "parameters", "not", "types", "Type", "checking", "is", "complex", "because", "of", "$ref", "and", "done", "on",...
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/LiveDevelopment/Inspector/Inspector.js#L104-L109
train
Verify signature
[ 30522, 3853, 1035, 20410, 5332, 16989, 11244, 1006, 8085, 1010, 3643, 1007, 1063, 2065, 1006, 3643, 1027, 1027, 1027, 6151, 28344, 1007, 1063, 10122, 1012, 20865, 1006, 8085, 1012, 11887, 1027, 1027, 1027, 2995, 1010, 1000, 4394, 6685, 1024...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/extensions/default/InlineColorEditor/ColorEditor.js
_0xColorToHex
function _0xColorToHex(color, convertToStr) { var hexColor = tinycolor(color.replace("0x", "#")); hexColor._format = "0x"; if (convertToStr) { return hexColor.toString(); } return hexColor; }
javascript
function _0xColorToHex(color, convertToStr) { var hexColor = tinycolor(color.replace("0x", "#")); hexColor._format = "0x"; if (convertToStr) { return hexColor.toString(); } return hexColor; }
[ "function", "_0xColorToHex", "(", "color", ",", "convertToStr", ")", "{", "var", "hexColor", "=", "tinycolor", "(", "color", ".", "replace", "(", "\"0x\"", ",", "\"#\"", ")", ")", ";", "hexColor", ".", "_format", "=", "\"0x\"", ";", "if", "(", "convertTo...
Converts 0x-prefixed color to hex @param {string} color - Color to convert @param {boolean} convertToString - true if color should be returned as string @returns {tinycolor|string} - Hex color as a Tinycolor object or a hex string
[ "Converts", "0x", "-", "prefixed", "color", "to", "hex" ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/extensions/default/InlineColorEditor/ColorEditor.js#L71-L79
train
Convert a 0x color to a hex color
[ 30522, 3853, 1035, 1014, 2595, 18717, 3406, 5369, 2595, 1006, 3609, 1010, 10463, 13122, 16344, 1007, 1063, 13075, 2002, 2595, 18717, 1027, 4714, 18717, 1006, 3609, 1012, 5672, 1006, 1000, 1014, 2595, 1000, 1010, 1000, 1001, 1000, 1007, 1007...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
firebase/firebase-js-sdk
packages/auth/src/iframeclient/iframewrapper.js
function() { // The developer may have tried to previously run gapi.load and failed. // Run this to fix that. fireauth.util.resetUnloadedGapiModules(); var loader = /** @type {function(string, !Object)} */ ( fireauth.util.getObjectRef('gapi.load')); loader('gapi.iframes', { ...
javascript
function() { // The developer may have tried to previously run gapi.load and failed. // Run this to fix that. fireauth.util.resetUnloadedGapiModules(); var loader = /** @type {function(string, !Object)} */ ( fireauth.util.getObjectRef('gapi.load')); loader('gapi.iframes', { ...
[ "function", "(", ")", "{", "// The developer may have tried to previously run gapi.load and failed.", "// Run this to fix that.", "fireauth", ".", "util", ".", "resetUnloadedGapiModules", "(", ")", ";", "var", "loader", "=", "/** @type {function(string, !Object)} */", "(", "fir...
Function to run when gapi.load is ready.
[ "Function", "to", "run", "when", "gapi", ".", "load", "is", "ready", "." ]
491598a499813dacc23724de5e237ec220cc560e
https://github.com/firebase/firebase-js-sdk/blob/491598a499813dacc23724de5e237ec220cc560e/packages/auth/src/iframeclient/iframewrapper.js#L252-L272
train
The network error is thrown when the network error occurs.
[ 30522, 3853, 1006, 1007, 1063, 1013, 1013, 1996, 9722, 2089, 2031, 2699, 2000, 3130, 2448, 6578, 2072, 1012, 7170, 1998, 3478, 1012, 1013, 1013, 2448, 2023, 2000, 8081, 2008, 1012, 2543, 4887, 2705, 1012, 21183, 4014, 1012, 25141, 4609, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
ipfs/js-ipfs
examples/exchange-files-in-browser/public/app.js
start
function start () { if (!node) { const options = { EXPERIMENTAL: { pubsub: true }, repo: 'ipfs-' + Math.random(), config: { Addresses: { Swarm: ['/dns4/ws-star.discovery.libp2p.io/tcp/443/wss/p2p-websocket-star'] } } } node = new IPFS(option...
javascript
function start () { if (!node) { const options = { EXPERIMENTAL: { pubsub: true }, repo: 'ipfs-' + Math.random(), config: { Addresses: { Swarm: ['/dns4/ws-star.discovery.libp2p.io/tcp/443/wss/p2p-websocket-star'] } } } node = new IPFS(option...
[ "function", "start", "(", ")", "{", "if", "(", "!", "node", ")", "{", "const", "options", "=", "{", "EXPERIMENTAL", ":", "{", "pubsub", ":", "true", "}", ",", "repo", ":", "'ipfs-'", "+", "Math", ".", "random", "(", ")", ",", "config", ":", "{", ...
/* =========================================================================== Start the IPFS node ===========================================================================
[ "/", "*", "===========================================================================", "Start", "the", "IPFS", "node", "===========================================================================" ]
97e67601094acda3906549ecb0248fd09f1a8cc3
https://github.com/ipfs/js-ipfs/blob/97e67601094acda3906549ecb0248fd09f1a8cc3/examples/exchange-files-in-browser/public/app.js#L44-L76
train
Starts the node
[ 30522, 3853, 2707, 1006, 1007, 1063, 2065, 1006, 999, 13045, 1007, 1063, 9530, 3367, 7047, 1027, 1063, 6388, 1024, 1063, 23598, 12083, 1024, 2995, 1065, 1010, 16360, 2080, 1024, 1005, 12997, 10343, 1011, 1005, 1009, 8785, 1012, 6721, 1006, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
benweet/stackedit
src/services/networkSvc.js
parseHeaders
function parseHeaders(xhr) { const pairs = xhr.getAllResponseHeaders().trim().split('\n'); const headers = {}; pairs.forEach((header) => { const split = header.trim().split(':'); const key = split.shift().trim().toLowerCase(); const value = split.join(':').trim(); headers[key] = value; }); ret...
javascript
function parseHeaders(xhr) { const pairs = xhr.getAllResponseHeaders().trim().split('\n'); const headers = {}; pairs.forEach((header) => { const split = header.trim().split(':'); const key = split.shift().trim().toLowerCase(); const value = split.join(':').trim(); headers[key] = value; }); ret...
[ "function", "parseHeaders", "(", "xhr", ")", "{", "const", "pairs", "=", "xhr", ".", "getAllResponseHeaders", "(", ")", ".", "trim", "(", ")", ".", "split", "(", "'\\n'", ")", ";", "const", "headers", "=", "{", "}", ";", "pairs", ".", "forEach", "(",...
3 minutes (twice the default sync period)
[ "3", "minutes", "(", "twice", "the", "default", "sync", "period", ")" ]
91f8cf3c10b75df65b69f9181cee8151d65a788d
https://github.com/benweet/stackedit/blob/91f8cf3c10b75df65b69f9181cee8151d65a788d/src/services/networkSvc.js#L13-L23
train
Parse the response headers from the server
[ 30522, 3853, 11968, 3366, 4974, 2545, 1006, 1060, 8093, 1007, 1063, 9530, 3367, 7689, 1027, 1060, 8093, 1012, 2131, 8095, 6072, 26029, 3366, 4974, 2545, 1006, 1007, 1012, 12241, 1006, 1007, 1012, 3975, 1006, 1005, 1032, 1050, 1005, 1007, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
TryGhost/Ghost
core/server/helpers/get.js
resolvePaths
function resolvePaths(globals, data, value) { var regex = /\{\{(.*?)\}\}/g; value = value.replace(regex, function (match, path) { var result; // Handle aliases path = pathAliases[path] ? pathAliases[path] : path; // Handle Handlebars .[] style arrays path = path.replace...
javascript
function resolvePaths(globals, data, value) { var regex = /\{\{(.*?)\}\}/g; value = value.replace(regex, function (match, path) { var result; // Handle aliases path = pathAliases[path] ? pathAliases[path] : path; // Handle Handlebars .[] style arrays path = path.replace...
[ "function", "resolvePaths", "(", "globals", ",", "data", ",", "value", ")", "{", "var", "regex", "=", "/", "\\{\\{(.*?)\\}\\}", "/", "g", ";", "value", "=", "value", ".", "replace", "(", "regex", ",", "function", "(", "match", ",", "path", ")", "{", ...
## Resolve Paths Find and resolve path strings @param {Object} data @param {String} value @returns {String}
[ "##", "Resolve", "Paths", "Find", "and", "resolve", "path", "strings" ]
bb7bb55cf3e60af99ebbc56099928827b58461bc
https://github.com/TryGhost/Ghost/blob/bb7bb55cf3e60af99ebbc56099928827b58461bc/core/server/helpers/get.js#L77-L106
train
Resolve paths in the value
[ 30522, 3853, 10663, 15069, 2015, 1006, 3795, 2015, 1010, 2951, 1010, 3643, 1007, 1063, 13075, 19723, 10288, 1027, 1013, 1032, 1063, 1032, 1063, 1006, 1012, 1008, 1029, 1007, 1032, 1065, 1032, 1065, 1013, 1043, 1025, 3643, 1027, 3643, 1012, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
angular/material
src/components/gridList/grid-list.js
GridLayoutFactory
function GridLayoutFactory($mdUtil) { var defaultAnimator = GridTileAnimator; /** * Set the reflow animator callback */ GridLayout.animateWith = function(customAnimator) { defaultAnimator = !angular.isFunction(customAnimator) ? GridTileAnimator : customAnimator; }; return GridLayout; /** * P...
javascript
function GridLayoutFactory($mdUtil) { var defaultAnimator = GridTileAnimator; /** * Set the reflow animator callback */ GridLayout.animateWith = function(customAnimator) { defaultAnimator = !angular.isFunction(customAnimator) ? GridTileAnimator : customAnimator; }; return GridLayout; /** * P...
[ "function", "GridLayoutFactory", "(", "$mdUtil", ")", "{", "var", "defaultAnimator", "=", "GridTileAnimator", ";", "/**\n * Set the reflow animator callback\n */", "GridLayout", ".", "animateWith", "=", "function", "(", "customAnimator", ")", "{", "defaultAnimator", "...
/* @ngInject
[ "/", "*" ]
84ac558674e73958be84312444c48d9f823f6684
https://github.com/angular/material/blob/84ac558674e73958be84312444c48d9f823f6684/src/components/gridList/grid-list.js#L466-L660
train
Creates a new GridLayout instance.
[ 30522, 3853, 8370, 8485, 5833, 21450, 1006, 1002, 9108, 21823, 2140, 1007, 1063, 13075, 12398, 7088, 18900, 2953, 1027, 8370, 15286, 7088, 18900, 2953, 1025, 1013, 1008, 1008, 1008, 2275, 1996, 25416, 8261, 25132, 2655, 5963, 1008, 1013, 83...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/dom/jquery/Aria.js
removeFromAttributeList
function removeFromAttributeList(sAttribute, sValue) { var sAttributes = this.attr(sAttribute) || "", aAttributes = sAttributes.split(" "), iIndex = aAttributes.indexOf(sValue); if (iIndex == -1) { return this; } aAttributes.splice(iIndex, 1); if (aAttributes.length) { this.attr(sAttribute, aAtt...
javascript
function removeFromAttributeList(sAttribute, sValue) { var sAttributes = this.attr(sAttribute) || "", aAttributes = sAttributes.split(" "), iIndex = aAttributes.indexOf(sValue); if (iIndex == -1) { return this; } aAttributes.splice(iIndex, 1); if (aAttributes.length) { this.attr(sAttribute, aAtt...
[ "function", "removeFromAttributeList", "(", "sAttribute", ",", "sValue", ")", "{", "var", "sAttributes", "=", "this", ".", "attr", "(", "sAttribute", ")", "||", "\"\"", ",", "aAttributes", "=", "sAttributes", ".", "split", "(", "\" \"", ")", ",", "iIndex", ...
Remove space separated value from the given attribute. @this {jQuery} jQuery context @param {string} sAttribute The name of the attribute. @param {string} sValue The value of the attribute to be inserted. @return {jQuery} <code>this</code> to allow method chaining. @author SAP SE @function @private
[ "Remove", "space", "separated", "value", "from", "the", "given", "attribute", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/dom/jquery/Aria.js#L62-L79
train
Removes an attribute from the list of attributes
[ 30522, 3853, 6366, 19699, 9626, 4779, 3089, 8569, 9834, 2923, 1006, 2938, 18886, 8569, 2618, 1010, 17917, 2389, 5657, 1007, 1063, 13075, 2938, 18886, 8569, 4570, 1027, 2023, 1012, 2012, 16344, 1006, 2938, 18886, 8569, 2618, 1007, 1064, 1064...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/model/odata/v4/AnnotationHelper.js
function (oContext) { var iEndOfPath, // after $*Path iIndexOfAt, // first "@" before $*Path iIndexOfPath, // begin of $*Path iLastIndexOfSlash, // last "/" before iIndexOfAt aMatches, sPath = oContext.getPath(), sPrefix, vValue; for (;;) { aMatches = sPath.match(rPaths)...
javascript
function (oContext) { var iEndOfPath, // after $*Path iIndexOfAt, // first "@" before $*Path iIndexOfPath, // begin of $*Path iLastIndexOfSlash, // last "/" before iIndexOfAt aMatches, sPath = oContext.getPath(), sPrefix, vValue; for (;;) { aMatches = sPath.match(rPaths)...
[ "function", "(", "oContext", ")", "{", "var", "iEndOfPath", ",", "// after $*Path", "iIndexOfAt", ",", "// first \"@\" before $*Path", "iIndexOfPath", ",", "// begin of $*Path", "iLastIndexOfSlash", ",", "// last \"/\" before iIndexOfAt", "aMatches", ",", "sPath", "=", "o...
Helper function for a <code>template:with</code> instruction that returns an equivalent to the given context's path, without "$AnnotationPath", "$NavigationPropertyPath", "$Path", and "$PropertyPath" segments. @param {sap.ui.model.Context} oContext A context which belongs to an {@link sap.ui.model.odata.v4.ODataMetaMo...
[ "Helper", "function", "for", "a", "<code", ">", "template", ":", "with<", "/", "code", ">", "instruction", "that", "returns", "an", "equivalent", "to", "the", "given", "context", "s", "path", "without", "$AnnotationPath", "$NavigationPropertyPath", "$Path", "and...
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/model/odata/v4/AnnotationHelper.js#L486-L525
train
Returns the path of the given context.
[ 30522, 3853, 1006, 1051, 8663, 18209, 1007, 1063, 13075, 29464, 15482, 22540, 8988, 1010, 1013, 1013, 2044, 1002, 1008, 4130, 2462, 13629, 2595, 11253, 4017, 1010, 1013, 1013, 2034, 1000, 1030, 1000, 2077, 1002, 1008, 4130, 2462, 13629, 259...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SheetJS/js-xlsx
xlsx.js
namecmp
function namecmp(l, r) { var L = l.split("/"), R = r.split("/"); for(var i = 0, c = 0, Z = Math.min(L.length, R.length); i < Z; ++i) { if((c = L[i].length - R[i].length)) return c; if(L[i] != R[i]) return L[i] < R[i] ? -1 : 1; } return L.length - R.length; }
javascript
function namecmp(l, r) { var L = l.split("/"), R = r.split("/"); for(var i = 0, c = 0, Z = Math.min(L.length, R.length); i < Z; ++i) { if((c = L[i].length - R[i].length)) return c; if(L[i] != R[i]) return L[i] < R[i] ? -1 : 1; } return L.length - R.length; }
[ "function", "namecmp", "(", "l", ",", "r", ")", "{", "var", "L", "=", "l", ".", "split", "(", "\"/\"", ")", ",", "R", "=", "r", ".", "split", "(", "\"/\"", ")", ";", "for", "(", "var", "i", "=", "0", ",", "c", "=", "0", ",", "Z", "=", "...
/* [MS-CFB] 2.6.4
[ "/", "*", "[", "MS", "-", "CFB", "]", "2", ".", "6", ".", "4" ]
9a6d8a1d3d80c78dad5201fb389316f935279cdc
https://github.com/SheetJS/js-xlsx/blob/9a6d8a1d3d80c78dad5201fb389316f935279cdc/xlsx.js#L1251-L1258
train
Compare two names
[ 30522, 3853, 2171, 27487, 2361, 1006, 1048, 1010, 1054, 1007, 1063, 13075, 1048, 1027, 1048, 1012, 3975, 1006, 1000, 1013, 1000, 1007, 1010, 1054, 1027, 1054, 1012, 3975, 1006, 1000, 1013, 1000, 1007, 1025, 2005, 1006, 13075, 1045, 1027, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/LiveDevelopment/Agents/CSSAgent.js
styleForURL
function styleForURL(url) { var styleSheetId, styles = {}; url = _canonicalize(url); for (styleSheetId in _styleSheetDetails) { if (_styleSheetDetails[styleSheetId].canonicalizedURL === url) { styles[styleSheetId] = _styleSheetDetails[styleSheetId]; } ...
javascript
function styleForURL(url) { var styleSheetId, styles = {}; url = _canonicalize(url); for (styleSheetId in _styleSheetDetails) { if (_styleSheetDetails[styleSheetId].canonicalizedURL === url) { styles[styleSheetId] = _styleSheetDetails[styleSheetId]; } ...
[ "function", "styleForURL", "(", "url", ")", "{", "var", "styleSheetId", ",", "styles", "=", "{", "}", ";", "url", "=", "_canonicalize", "(", "url", ")", ";", "for", "(", "styleSheetId", "in", "_styleSheetDetails", ")", "{", "if", "(", "_styleSheetDetails",...
Get the style sheets for a url @param {string} url @return {Object.<string, CSSStyleSheetHeader>}
[ "Get", "the", "style", "sheets", "for", "a", "url" ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/LiveDevelopment/Agents/CSSAgent.js#L81-L90
train
Get styleSheet for a given URL
[ 30522, 3853, 2806, 29278, 3126, 2140, 1006, 24471, 2140, 1007, 1063, 13075, 6782, 21030, 3775, 2094, 1010, 6782, 1027, 1063, 1065, 1025, 24471, 2140, 1027, 1035, 18562, 4697, 1006, 24471, 2140, 1007, 1025, 2005, 1006, 6782, 21030, 3775, 209...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/core/rules/CoreHelper.support.js
function (styleSheet) { var styleSheetSourceName; if (styleSheet.href) { // This will get only the name of the styleSheet example: "/customstyle.css" styleSheetSourceName = styleSheet.href.substr(styleSheet.href.lastIndexOf("/"), styleSheet.href.length - 1); } else { styleSheetSourceName = "...
javascript
function (styleSheet) { var styleSheetSourceName; if (styleSheet.href) { // This will get only the name of the styleSheet example: "/customstyle.css" styleSheetSourceName = styleSheet.href.substr(styleSheet.href.lastIndexOf("/"), styleSheet.href.length - 1); } else { styleSheetSourceName = "...
[ "function", "(", "styleSheet", ")", "{", "var", "styleSheetSourceName", ";", "if", "(", "styleSheet", ".", "href", ")", "{", "// This will get only the name of the styleSheet example: \"/customstyle.css\"", "styleSheetSourceName", "=", "styleSheet", ".", "href", ".", "sub...
* Gets the only the style sheet name from source. @param styleSheet @returns {string} Name of the file source or "<style> tag" if style sheet is inline.
[ "*", "Gets", "the", "only", "the", "style", "sheet", "name", "from", "source", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/core/rules/CoreHelper.support.js#L66-L77
train
Get the name of the style sheet
[ 30522, 3853, 1006, 6782, 21030, 2102, 1007, 1063, 13075, 6782, 21030, 3215, 8162, 27524, 14074, 1025, 2065, 1006, 6782, 21030, 2102, 1012, 17850, 12879, 1007, 1063, 1013, 1013, 2023, 2097, 2131, 2069, 1996, 2171, 1997, 1996, 6782, 21030, 21...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/JSUtils/node/TernNodeDomain.js
getTernHints
function getTernHints(fileInfo, offset, isProperty) { var request = buildRequest(fileInfo, "completions", offset), i; //_log("request " + dir + " " + file + " " + offset /*+ " " + text */); try { ternServer.request(request, function (error, data) { var completions = []; ...
javascript
function getTernHints(fileInfo, offset, isProperty) { var request = buildRequest(fileInfo, "completions", offset), i; //_log("request " + dir + " " + file + " " + offset /*+ " " + text */); try { ternServer.request(request, function (error, data) { var completions = []; ...
[ "function", "getTernHints", "(", "fileInfo", ",", "offset", ",", "isProperty", ")", "{", "var", "request", "=", "buildRequest", "(", "fileInfo", ",", "\"completions\"", ",", "offset", ")", ",", "i", ";", "//_log(\"request \" + dir + \" \" + file + \" \" + offset /*+ \...
Get the completions for the given offset @param {{type: string, name: string, offsetLines: number, text: string}} fileInfo - type of update, name of file, and the text of the update. For "full" updates, the whole text of the file is present. For "part" updates, the changed portion of the text. For "empty" updates, the...
[ "Get", "the", "completions", "for", "the", "given", "offset" ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/JSUtils/node/TernNodeDomain.js#L457-L489
train
Get the completions for a given file and offset
[ 30522, 3853, 2131, 16451, 10606, 3215, 1006, 5371, 2378, 14876, 1010, 16396, 1010, 2003, 21572, 4842, 3723, 1007, 1063, 13075, 5227, 1027, 3857, 2890, 15500, 1006, 5371, 2378, 14876, 1010, 1000, 6503, 2015, 1000, 1010, 16396, 1007, 1010, 10...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/preferences/PreferencesManager.js
_updateCurrentProjectContext
function _updateCurrentProjectContext() { var defaultScopeOrder = PreferencesImpl.manager._getScopeOrder({}); scopeOrderWithProject = _adjustScopeOrderForProject(defaultScopeOrder, true); scopeOrderWithoutProject = _adjustScopeOrderForProject(defaultScopeOrder, false); CURRENT_PROJECT.sc...
javascript
function _updateCurrentProjectContext() { var defaultScopeOrder = PreferencesImpl.manager._getScopeOrder({}); scopeOrderWithProject = _adjustScopeOrderForProject(defaultScopeOrder, true); scopeOrderWithoutProject = _adjustScopeOrderForProject(defaultScopeOrder, false); CURRENT_PROJECT.sc...
[ "function", "_updateCurrentProjectContext", "(", ")", "{", "var", "defaultScopeOrder", "=", "PreferencesImpl", ".", "manager", ".", "_getScopeOrder", "(", "{", "}", ")", ";", "scopeOrderWithProject", "=", "_adjustScopeOrderForProject", "(", "defaultScopeOrder", ",", "...
@private Updates the CURRENT_PROJECT context to have the correct scopes.
[ "@private" ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/preferences/PreferencesManager.js#L256-L261
train
Updates the current project context
[ 30522, 3853, 1035, 10651, 10841, 14343, 3372, 21572, 20614, 8663, 18209, 1006, 1007, 1063, 13075, 12398, 26127, 8551, 2121, 1027, 18394, 5714, 24759, 1012, 3208, 1012, 1035, 4152, 16186, 8551, 2121, 1006, 1063, 1065, 1007, 1025, 9531, 8551, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/LiveDevelopment/MultiBrowserImpl/protocol/remote/LiveDevProtocolRemote.js
function (msg) { var msgHandlers; if (!msg.method) { // no message type, ignoring it // TODO: should we trigger a generic event? console.log("[Brackets LiveDev] Received message without method."); return; } /...
javascript
function (msg) { var msgHandlers; if (!msg.method) { // no message type, ignoring it // TODO: should we trigger a generic event? console.log("[Brackets LiveDev] Received message without method."); return; } /...
[ "function", "(", "msg", ")", "{", "var", "msgHandlers", ";", "if", "(", "!", "msg", ".", "method", ")", "{", "// no message type, ignoring it", "// TODO: should we trigger a generic event?", "console", ".", "log", "(", "\"[Brackets LiveDev] Received message without method...
Dispatch messages to handlers according to msg.method value. @param {Object} msg Message to be dispatched.
[ "Dispatch", "messages", "to", "handlers", "according", "to", "msg", ".", "method", "value", "." ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/LiveDevelopment/MultiBrowserImpl/protocol/remote/LiveDevProtocolRemote.js#L60-L90
train
handle a message
[ 30522, 3853, 1006, 5796, 2290, 1007, 1063, 13075, 5796, 22218, 21222, 2015, 1025, 2065, 1006, 999, 5796, 2290, 1012, 4118, 1007, 1063, 1013, 1013, 2053, 4471, 2828, 1010, 9217, 2009, 1013, 1013, 28681, 2080, 1024, 2323, 2057, 9495, 1037, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/extensions/default/InAppNotifications/main.js
_getVersionInfoUrl
function _getVersionInfoUrl(localeParam) { var locale = localeParam || brackets.getLocale(); if (locale.length > 2) { locale = locale.substring(0, 2); } return brackets.config.notification_info_url.replace("<locale>", locale); }
javascript
function _getVersionInfoUrl(localeParam) { var locale = localeParam || brackets.getLocale(); if (locale.length > 2) { locale = locale.substring(0, 2); } return brackets.config.notification_info_url.replace("<locale>", locale); }
[ "function", "_getVersionInfoUrl", "(", "localeParam", ")", "{", "var", "locale", "=", "localeParam", "||", "brackets", ".", "getLocale", "(", ")", ";", "if", "(", "locale", ".", "length", ">", "2", ")", "{", "locale", "=", "locale", ".", "substring", "("...
Constructs notification info URL for XHR @param {string=} localeParam - optional locale, defaults to 'brackets.getLocale()' when omitted. @returns {string} the new notification info url
[ "Constructs", "notification", "info", "URL", "for", "XHR" ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/extensions/default/InAppNotifications/main.js#L55-L64
train
Get the URL to the version information page
[ 30522, 3853, 1035, 2131, 27774, 2378, 14876, 3126, 2140, 1006, 2334, 13699, 5400, 2213, 1007, 1063, 13075, 2334, 2063, 1027, 2334, 13699, 5400, 2213, 1064, 1064, 19719, 1012, 2131, 4135, 9289, 2063, 1006, 1007, 1025, 2065, 1006, 2334, 2063,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
jhipster/generator-jhipster
generators/entity/prompts.js
logFieldsAndRelationships
function logFieldsAndRelationships() { const context = this.context; if (context.fields.length > 0 || context.relationships.length > 0) { this.log(chalk.red(chalk.white('\n================= ') + context.entityNameCapitalized + chalk.white(' ================='))); } if (context.fields.length > 0)...
javascript
function logFieldsAndRelationships() { const context = this.context; if (context.fields.length > 0 || context.relationships.length > 0) { this.log(chalk.red(chalk.white('\n================= ') + context.entityNameCapitalized + chalk.white(' ================='))); } if (context.fields.length > 0)...
[ "function", "logFieldsAndRelationships", "(", ")", "{", "const", "context", "=", "this", ".", "context", ";", "if", "(", "context", ".", "fields", ".", "length", ">", "0", "||", "context", ".", "relationships", ".", "length", ">", "0", ")", "{", "this", ...
Show the entity and it's fields and relationships in console
[ "Show", "the", "entity", "and", "it", "s", "fields", "and", "relationships", "in", "console" ]
f76fa8de0818ce6bda6c7b1455942e2a9b0ae3ff
https://github.com/jhipster/generator-jhipster/blob/f76fa8de0818ce6bda6c7b1455942e2a9b0ae3ff/generators/entity/prompts.js#L1075-L1137
train
Logs fields and relationships
[ 30522, 3853, 8833, 15155, 5685, 16570, 10708, 19801, 1006, 1007, 1063, 9530, 3367, 6123, 1027, 2023, 1012, 6123, 1025, 2065, 1006, 6123, 1012, 4249, 1012, 3091, 1028, 1014, 1064, 1064, 6123, 1012, 6550, 1012, 3091, 1028, 1014, 1007, 1063, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
aws/aws-sdk-js
lib/service.js
defineService
function defineService(serviceIdentifier, versions, features) { AWS.Service._serviceMap[serviceIdentifier] = true; if (!Array.isArray(versions)) { features = versions; versions = []; } var svc = inherit(AWS.Service, features || {}); if (typeof serviceIdentifier === 'string') { AW...
javascript
function defineService(serviceIdentifier, versions, features) { AWS.Service._serviceMap[serviceIdentifier] = true; if (!Array.isArray(versions)) { features = versions; versions = []; } var svc = inherit(AWS.Service, features || {}); if (typeof serviceIdentifier === 'string') { AW...
[ "function", "defineService", "(", "serviceIdentifier", ",", "versions", ",", "features", ")", "{", "AWS", ".", "Service", ".", "_serviceMap", "[", "serviceIdentifier", "]", "=", "true", ";", "if", "(", "!", "Array", ".", "isArray", "(", "versions", ")", ")...
Defines a new Service class using a service identifier and list of versions including an optional set of features (functions) to apply to the class prototype. @param serviceIdentifier [String] the identifier for the service @param versions [Array<String>] a list of versions that work with this service @param features ...
[ "Defines", "a", "new", "Service", "class", "using", "a", "service", "identifier", "and", "list", "of", "versions", "including", "an", "optional", "set", "of", "features", "(", "functions", ")", "to", "apply", "to", "the", "class", "prototype", "." ]
c23e5f0edd150f8885267e5f7c8a564f8e6e8562
https://github.com/aws/aws-sdk-js/blob/c23e5f0edd150f8885267e5f7c8a564f8e6e8562/lib/service.js#L690-L723
train
defineService - define a service
[ 30522, 3853, 11859, 2121, 7903, 2063, 1006, 2326, 5178, 16778, 8873, 2121, 1010, 4617, 1010, 2838, 1007, 1063, 22091, 2015, 1012, 2326, 1012, 1035, 2326, 2863, 2361, 1031, 2326, 5178, 16778, 8873, 2121, 1033, 1027, 2995, 1025, 2065, 1006, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/JSUtils/ScopeManager.js
_setConfig
function _setConfig(configUpdate) { config = brackets._configureJSCodeHints.config; postMessage({ type: MessageIds.SET_CONFIG, config: configUpdate }); }
javascript
function _setConfig(configUpdate) { config = brackets._configureJSCodeHints.config; postMessage({ type: MessageIds.SET_CONFIG, config: configUpdate }); }
[ "function", "_setConfig", "(", "configUpdate", ")", "{", "config", "=", "brackets", ".", "_configureJSCodeHints", ".", "config", ";", "postMessage", "(", "{", "type", ":", "MessageIds", ".", "SET_CONFIG", ",", "config", ":", "configUpdate", "}", ")", ";", "}...
@private Update the configuration in the tern node domain.
[ "@private" ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/JSUtils/ScopeManager.js#L1582-L1588
train
Sets the config of the node
[ 30522, 3853, 1035, 2275, 8663, 8873, 2290, 1006, 9530, 8873, 12193, 17299, 3686, 1007, 1063, 9530, 8873, 2290, 1027, 19719, 1012, 1035, 9530, 8873, 27390, 20518, 9363, 25383, 18447, 2015, 1012, 9530, 8873, 2290, 1025, 2695, 7834, 3736, 3351...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
dcloudio/mui
examples/hello-mui/js/mui.js
function() { var self = this; var val = self.input.value; if (val == null || val == '' || isNaN(val)) { self.input.value = self.options.min || 0; self.minus.disabled = self.options.min != null; } else { var val = parseInt(va...
javascript
function() { var self = this; var val = self.input.value; if (val == null || val == '' || isNaN(val)) { self.input.value = self.options.min || 0; self.minus.disabled = self.options.min != null; } else { var val = parseInt(va...
[ "function", "(", ")", "{", "var", "self", "=", "this", ";", "var", "val", "=", "self", ".", "input", ".", "value", ";", "if", "(", "val", "==", "null", "||", "val", "==", "''", "||", "isNaN", "(", "val", ")", ")", "{", "self", ".", "input", "...
验证当前值是法合法
[ "验证当前值是法合法" ]
ff74c90a1671a552f3604b1288bf38a4126312d0
https://github.com/dcloudio/mui/blob/ff74c90a1671a552f3604b1288bf38a4126312d0/examples/hello-mui/js/mui.js#L8227-L8249
train
Set the value of the option
[ 30522, 3853, 1006, 1007, 1063, 13075, 2969, 1027, 2023, 1025, 13075, 11748, 1027, 2969, 1012, 7953, 1012, 3643, 1025, 2065, 1006, 11748, 1027, 1027, 19701, 1064, 1064, 11748, 1027, 1027, 1005, 1005, 1064, 1064, 3475, 2319, 1006, 11748, 1007...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
angular/material
src/core/util/util.js
function(element, nodeName, scanDeep, warnNotFound) { var found = scanTree(element); if (!found && !!warnNotFound) { $log.warn($mdUtil.supplant("Unable to find node '{0}' in element '{1}'.",[nodeName, element[0].outerHTML])); } return angular.element(found || element); /** ...
javascript
function(element, nodeName, scanDeep, warnNotFound) { var found = scanTree(element); if (!found && !!warnNotFound) { $log.warn($mdUtil.supplant("Unable to find node '{0}' in element '{1}'.",[nodeName, element[0].outerHTML])); } return angular.element(found || element); /** ...
[ "function", "(", "element", ",", "nodeName", ",", "scanDeep", ",", "warnNotFound", ")", "{", "var", "found", "=", "scanTree", "(", "element", ")", ";", "if", "(", "!", "found", "&&", "!", "!", "warnNotFound", ")", "{", "$log", ".", "warn", "(", "$mdU...
Functional equivalent for $element.filter(‘md-bottom-sheet’) useful with interimElements where the element and its container are important... @param {angular.JQLite} element to scan @param {string} nodeName of node to find (e.g. 'md-dialog') @param {boolean=} scanDeep optional flag to allow deep scans; defaults to 'fa...
[ "Functional", "equivalent", "for", "$element", ".", "filter", "(", "‘md", "-", "bottom", "-", "sheet’", ")", "useful", "with", "interimElements", "where", "the", "element", "and", "its", "container", "are", "important", "..." ]
84ac558674e73958be84312444c48d9f823f6684
https://github.com/angular/material/blob/84ac558674e73958be84312444c48d9f823f6684/src/core/util/util.js#L597-L644
train
Returns the first node that matches nodeName
[ 30522, 3853, 1006, 5783, 1010, 13045, 18442, 1010, 13594, 26095, 2361, 1010, 11582, 17048, 14876, 8630, 1007, 1063, 13075, 2179, 1027, 13594, 13334, 1006, 5783, 1007, 1025, 2065, 1006, 999, 2179, 1004, 1004, 999, 999, 11582, 17048, 14876, 8...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
aws/aws-sdk-js
lib/services/s3.js
requestBucketRegion
function requestBucketRegion(resp, done) { var error = resp.error; var req = resp.request; var bucket = req.params.Bucket || null; if (!error || !bucket || error.region || req.operation === 'listObjects' || (AWS.util.isNode() && req.operation === 'headBucket') || (error.statusCode === 4...
javascript
function requestBucketRegion(resp, done) { var error = resp.error; var req = resp.request; var bucket = req.params.Bucket || null; if (!error || !bucket || error.region || req.operation === 'listObjects' || (AWS.util.isNode() && req.operation === 'headBucket') || (error.statusCode === 4...
[ "function", "requestBucketRegion", "(", "resp", ",", "done", ")", "{", "var", "error", "=", "resp", ".", "error", ";", "var", "req", "=", "resp", ".", "request", ";", "var", "bucket", "=", "req", ".", "params", ".", "Bucket", "||", "null", ";", "if",...
If region was not obtained synchronously, then send async request to get bucket region for errors resulting from wrong region. @api private
[ "If", "region", "was", "not", "obtained", "synchronously", "then", "send", "async", "request", "to", "get", "bucket", "region", "for", "errors", "resulting", "from", "wrong", "region", "." ]
c23e5f0edd150f8885267e5f7c8a564f8e6e8562
https://github.com/aws/aws-sdk-js/blob/c23e5f0edd150f8885267e5f7c8a564f8e6e8562/lib/services/s3.js#L600-L621
train
Request bucket region
[ 30522, 3853, 5227, 24204, 3388, 23784, 1006, 24501, 2361, 1010, 2589, 1007, 1063, 13075, 7561, 1027, 24501, 2361, 1012, 7561, 1025, 13075, 2128, 4160, 1027, 24501, 2361, 1012, 5227, 1025, 13075, 13610, 1027, 2128, 4160, 1012, 11498, 5244, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
summernote/summernote
src/js/base/core/dom.js
splitTree
function splitTree(root, point, options) { // ex) [#text, <span>, <p>] const ancestors = listAncestor(point.node, func.eq(root)); if (!ancestors.length) { return null; } else if (ancestors.length === 1) { return splitNode(point, options); } return ancestors.reduce(function(node, parent) { if (...
javascript
function splitTree(root, point, options) { // ex) [#text, <span>, <p>] const ancestors = listAncestor(point.node, func.eq(root)); if (!ancestors.length) { return null; } else if (ancestors.length === 1) { return splitNode(point, options); } return ancestors.reduce(function(node, parent) { if (...
[ "function", "splitTree", "(", "root", ",", "point", ",", "options", ")", "{", "// ex) [#text, <span>, <p>]", "const", "ancestors", "=", "listAncestor", "(", "point", ".", "node", ",", "func", ".", "eq", "(", "root", ")", ")", ";", "if", "(", "!", "ancest...
@method splitTree split tree by point @param {Node} root - split root @param {BoundaryPoint} point @param {Object} [options] @param {Boolean} [options.isSkipPaddingBlankHTML] - default: false @param {Boolean} [options.isNotSplitEdgePoint] - default: false @return {Node} right node of boundaryPoint
[ "@method", "splitTree" ]
8dcafb8107453006b905ef697a529c42e76beb3f
https://github.com/summernote/summernote/blob/8dcafb8107453006b905ef697a529c42e76beb3f/src/js/base/core/dom.js#L796-L816
train
Split a node into two nodes
[ 30522, 3853, 3975, 13334, 1006, 7117, 1010, 2391, 1010, 7047, 1007, 1063, 1013, 1013, 4654, 1007, 1031, 1001, 3793, 1010, 1026, 8487, 1028, 1010, 1026, 1052, 1028, 1033, 9530, 3367, 10748, 1027, 2862, 26755, 4263, 1006, 2391, 1012, 13045, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SeleniumHQ/selenium
common/src/web/jquery-1.3.2.js
function(from, to, unit){ this.startTime = now(); this.start = from; this.end = to; this.unit = unit || this.unit || "px"; this.now = this.start; this.pos = this.state = 0; var self = this; function t(gotoEnd){ return self.step(gotoEnd); } t.elem = this.elem; if ( t() && jQuery.timers.push(t...
javascript
function(from, to, unit){ this.startTime = now(); this.start = from; this.end = to; this.unit = unit || this.unit || "px"; this.now = this.start; this.pos = this.state = 0; var self = this; function t(gotoEnd){ return self.step(gotoEnd); } t.elem = this.elem; if ( t() && jQuery.timers.push(t...
[ "function", "(", "from", ",", "to", ",", "unit", ")", "{", "this", ".", "startTime", "=", "now", "(", ")", ";", "this", ".", "start", "=", "from", ";", "this", ".", "end", "=", "to", ";", "this", ".", "unit", "=", "unit", "||", "this", ".", "...
Start an animation from one number to another
[ "Start", "an", "animation", "from", "one", "number", "to", "another" ]
38d5e4440b2c866a78a1ccb2a18d9795a1bdeafd
https://github.com/SeleniumHQ/selenium/blob/38d5e4440b2c866a78a1ccb2a18d9795a1bdeafd/common/src/web/jquery-1.3.2.js#L4037-L4066
train
set the start and end values
[ 30522, 3853, 1006, 2013, 1010, 2000, 1010, 3131, 1007, 1063, 2023, 1012, 2707, 7292, 1027, 2085, 1006, 1007, 1025, 2023, 1012, 2707, 1027, 2013, 1025, 2023, 1012, 2203, 1027, 2000, 1025, 2023, 1012, 3131, 1027, 3131, 1064, 1064, 2023, 101...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
TryGhost/Ghost
core/server/update-check.js
updateCheckError
function updateCheckError(err) { api.settings.edit({ settings: [{ key: 'next_update_check', value: nextCheckTimestamp() }] }, internal); err.context = common.i18n.t('errors.updateCheck.checkingForUpdatesFailed.error'); err.help = common.i18n.t('errors.updateCheck...
javascript
function updateCheckError(err) { api.settings.edit({ settings: [{ key: 'next_update_check', value: nextCheckTimestamp() }] }, internal); err.context = common.i18n.t('errors.updateCheck.checkingForUpdatesFailed.error'); err.help = common.i18n.t('errors.updateCheck...
[ "function", "updateCheckError", "(", "err", ")", "{", "api", ".", "settings", ".", "edit", "(", "{", "settings", ":", "[", "{", "key", ":", "'next_update_check'", ",", "value", ":", "nextCheckTimestamp", "(", ")", "}", "]", "}", ",", "internal", ")", "...
@description Centralised error handler for the update check unit. CASES: - the update check service returns an error - error during collecting blog stats We still need to ensure that we set the "next_update_check" to a new value, otherwise no more update checks will happen. @param err
[ "@description", "Centralised", "error", "handler", "for", "the", "update", "check", "unit", "." ]
bb7bb55cf3e60af99ebbc56099928827b58461bc
https://github.com/TryGhost/Ghost/blob/bb7bb55cf3e60af99ebbc56099928827b58461bc/core/server/update-check.js#L43-L54
train
updateCheckError - error message
[ 30522, 3853, 10651, 5403, 9102, 29165, 1006, 9413, 2099, 1007, 1063, 17928, 1012, 10906, 1012, 10086, 1006, 1063, 10906, 1024, 1031, 1063, 3145, 1024, 1005, 2279, 1035, 10651, 1035, 4638, 1005, 1010, 3643, 1024, 2279, 5403, 3600, 7292, 9153...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
cytoscape/cytoscape.js
dist/cytoscape.esm.js
animation
function animation() { return function animationImpl(properties, params) { var self = this; var selfIsArrayLike = self.length !== undefined; var all = selfIsArrayLike ? self : [self]; // put in array if not array-like var cy = this._private.cy || this; var isCore = !selfIsArrayLike; ...
javascript
function animation() { return function animationImpl(properties, params) { var self = this; var selfIsArrayLike = self.length !== undefined; var all = selfIsArrayLike ? self : [self]; // put in array if not array-like var cy = this._private.cy || this; var isCore = !selfIsArrayLike; ...
[ "function", "animation", "(", ")", "{", "return", "function", "animationImpl", "(", "properties", ",", "params", ")", "{", "var", "self", "=", "this", ";", "var", "selfIsArrayLike", "=", "self", ".", "length", "!==", "undefined", ";", "var", "all", "=", ...
delay
[ "delay" ]
ad2051b65e2243cfd953d8b24a8bf95bfa8559e5
https://github.com/cytoscape/cytoscape.js/blob/ad2051b65e2243cfd953d8b24a8bf95bfa8559e5/dist/cytoscape.esm.js#L5800-L5897
train
Animation implementation for the core animation
[ 30522, 3853, 7284, 1006, 1007, 1063, 2709, 3853, 7284, 5714, 24759, 1006, 5144, 1010, 11498, 5244, 1007, 1063, 13075, 2969, 1027, 2023, 1025, 13075, 2969, 14268, 11335, 8516, 17339, 1027, 2969, 1012, 3091, 999, 1027, 1027, 6151, 28344, 1025...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
apache/incubator-echarts
src/coord/Axis.js
function (coord, clamp) { var extent = this._extent; var scale = this.scale; if (this.onBand && scale.type === 'ordinal') { extent = extent.slice(); fixExtentWithBands(extent, scale.count()); } var t = linearMap(coord, extent, NORMALIZED_EXTENT, clamp); ...
javascript
function (coord, clamp) { var extent = this._extent; var scale = this.scale; if (this.onBand && scale.type === 'ordinal') { extent = extent.slice(); fixExtentWithBands(extent, scale.count()); } var t = linearMap(coord, extent, NORMALIZED_EXTENT, clamp); ...
[ "function", "(", "coord", ",", "clamp", ")", "{", "var", "extent", "=", "this", ".", "_extent", ";", "var", "scale", "=", "this", ".", "scale", ";", "if", "(", "this", ".", "onBand", "&&", "scale", ".", "type", "===", "'ordinal'", ")", "{", "extent...
Convert coord to data. Data is the rank if it has an ordinal scale @param {number} coord @param {boolean} clamp @return {number}
[ "Convert", "coord", "to", "data", ".", "Data", "is", "the", "rank", "if", "it", "has", "an", "ordinal", "scale" ]
4d0ea095dc3929cb6de40c45748826e7999c7aa8
https://github.com/apache/incubator-echarts/blob/4d0ea095dc3929cb6de40c45748826e7999c7aa8/src/coord/Axis.js#L147-L159
train
Returns a new vector with the given coord
[ 30522, 3853, 1006, 2522, 8551, 1010, 18856, 16613, 1007, 1063, 13075, 6698, 1027, 2023, 1012, 1035, 6698, 1025, 13075, 4094, 1027, 2023, 1012, 4094, 1025, 2065, 1006, 2023, 1012, 2006, 12733, 1004, 1004, 4094, 1012, 2828, 1027, 1027, 1027, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/model/odata/v4/lib/_Batch.js
getChangeSetResponseIndex
function getChangeSetResponseIndex(sMimeTypeHeaders) { var sContentID = getHeaderValue(sMimeTypeHeaders, "content-id"), iResponseIndex; if (!sContentID) { throw new Error("Content-ID MIME header missing for the change set response."); } iResponseIndex = parseInt(sContentID); if (isNaN(iResponseIndex))...
javascript
function getChangeSetResponseIndex(sMimeTypeHeaders) { var sContentID = getHeaderValue(sMimeTypeHeaders, "content-id"), iResponseIndex; if (!sContentID) { throw new Error("Content-ID MIME header missing for the change set response."); } iResponseIndex = parseInt(sContentID); if (isNaN(iResponseIndex))...
[ "function", "getChangeSetResponseIndex", "(", "sMimeTypeHeaders", ")", "{", "var", "sContentID", "=", "getHeaderValue", "(", "sMimeTypeHeaders", ",", "\"content-id\"", ")", ",", "iResponseIndex", ";", "if", "(", "!", "sContentID", ")", "{", "throw", "new", "Error"...
Returns index of the response inside of a change set by parsing the Content-ID header value available as a part of the specified change set response <code>sMimeTypeHeaders</code>. The function expects Content-ID header value to be specified in <code>i.j</code> notation, where <code>i</code> represents the index of the ...
[ "Returns", "index", "of", "the", "response", "inside", "of", "a", "change", "set", "by", "parsing", "the", "Content", "-", "ID", "header", "value", "available", "as", "a", "part", "of", "the", "specified", "change", "set", "response", "<code", ">", "sMimeT...
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/model/odata/v4/lib/_Batch.js#L92-L105
train
Returns the index of the change set response.
[ 30522, 3853, 2131, 22305, 6810, 19168, 26029, 20240, 13629, 2595, 1006, 15488, 14428, 13874, 4974, 2545, 1007, 1063, 13075, 8040, 28040, 16778, 2094, 1027, 2131, 4974, 2121, 10175, 5657, 1006, 15488, 14428, 13874, 4974, 2545, 1010, 1000, 4180...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
caolan/async
lib/mapValuesLimit.js
mapValuesLimit
function mapValuesLimit(obj, limit, iteratee, callback) { callback = once(callback); var newObj = {}; var _iteratee = wrapAsync(iteratee) return eachOfLimit(limit)(obj, (val, key, next) => { _iteratee(val, key, (err, result) => { if (err) return next(err); newObj[key] = r...
javascript
function mapValuesLimit(obj, limit, iteratee, callback) { callback = once(callback); var newObj = {}; var _iteratee = wrapAsync(iteratee) return eachOfLimit(limit)(obj, (val, key, next) => { _iteratee(val, key, (err, result) => { if (err) return next(err); newObj[key] = r...
[ "function", "mapValuesLimit", "(", "obj", ",", "limit", ",", "iteratee", ",", "callback", ")", "{", "callback", "=", "once", "(", "callback", ")", ";", "var", "newObj", "=", "{", "}", ";", "var", "_iteratee", "=", "wrapAsync", "(", "iteratee", ")", "re...
The same as [`mapValues`]{@link module:Collections.mapValues} but runs a maximum of `limit` async operations at a time. @name mapValuesLimit @static @memberOf module:Collections @method @see [async.mapValues]{@link module:Collections.mapValues} @category Collection @param {Object} obj - A collection to iterate over. @...
[ "The", "same", "as", "[", "mapValues", "]", "{", "@link", "module", ":", "Collections", ".", "mapValues", "}", "but", "runs", "a", "maximum", "of", "limit", "async", "operations", "at", "a", "time", "." ]
4330d536c106592139fa82062494c9dba0da1fdb
https://github.com/caolan/async/blob/4330d536c106592139fa82062494c9dba0da1fdb/lib/mapValuesLimit.js#L28-L39
train
Map values from an object to a new object with the highest key value
[ 30522, 3853, 4949, 10175, 15808, 17960, 4183, 1006, 27885, 3501, 1010, 5787, 1010, 2009, 22139, 2063, 1010, 2655, 5963, 1007, 1063, 2655, 5963, 1027, 2320, 1006, 2655, 5963, 1007, 1025, 13075, 2047, 16429, 3501, 1027, 1063, 1065, 1025, 1307...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
google/closure-library
closure/goog/loader/activemodulemanager.js
get
function get() { if (!moduleManager && getDefault) { moduleManager = getDefault(); } asserts.assert( moduleManager != null, 'The module manager has not yet been set.'); return moduleManager; }
javascript
function get() { if (!moduleManager && getDefault) { moduleManager = getDefault(); } asserts.assert( moduleManager != null, 'The module manager has not yet been set.'); return moduleManager; }
[ "function", "get", "(", ")", "{", "if", "(", "!", "moduleManager", "&&", "getDefault", ")", "{", "moduleManager", "=", "getDefault", "(", ")", ";", "}", "asserts", ".", "assert", "(", "moduleManager", "!=", "null", ",", "'The module manager has not yet been se...
Gets the active module manager, instantiating one if necessary. @return {!AbstractModuleManager}
[ "Gets", "the", "active", "module", "manager", "instantiating", "one", "if", "necessary", "." ]
97390e9ca4483cebb9628e06026139fbb3023d65
https://github.com/google/closure-library/blob/97390e9ca4483cebb9628e06026139fbb3023d65/closure/goog/loader/activemodulemanager.js#L36-L43
train
Get the module manager
[ 30522, 3853, 2131, 1006, 1007, 1063, 2065, 1006, 999, 11336, 24805, 4590, 1004, 1004, 2131, 3207, 7011, 11314, 1007, 1063, 11336, 24805, 4590, 1027, 2131, 3207, 7011, 11314, 1006, 1007, 1025, 1065, 19514, 1012, 20865, 1006, 11336, 24805, 45...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/core/Configuration.js
function(sFormatId) { sFormatId = sFormatId ? sFormatId.toUpperCase() : ""; check(!sFormatId || M_ABAP_NUMBER_FORMAT_SYMBOLS.hasOwnProperty(sFormatId), "sFormatId must be one of [' ','X','Y'] or empty"); var mChanges = this.oConfiguration._collect(); this.sLegacyNumberFormat = mChanges.legacyNumberFormat = ...
javascript
function(sFormatId) { sFormatId = sFormatId ? sFormatId.toUpperCase() : ""; check(!sFormatId || M_ABAP_NUMBER_FORMAT_SYMBOLS.hasOwnProperty(sFormatId), "sFormatId must be one of [' ','X','Y'] or empty"); var mChanges = this.oConfiguration._collect(); this.sLegacyNumberFormat = mChanges.legacyNumberFormat = ...
[ "function", "(", "sFormatId", ")", "{", "sFormatId", "=", "sFormatId", "?", "sFormatId", ".", "toUpperCase", "(", ")", ":", "\"\"", ";", "check", "(", "!", "sFormatId", "||", "M_ABAP_NUMBER_FORMAT_SYMBOLS", ".", "hasOwnProperty", "(", "sFormatId", ")", ",", ...
Allows to specify one of the legacy ABAP number format. This method will modify the 'group' and 'decimal' symbols. When called with a null or undefined format id, any previously applied format will be removed. After changing the legacy number format, the framework tries to update localization specific parts of the UI...
[ "Allows", "to", "specify", "one", "of", "the", "legacy", "ABAP", "number", "format", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/core/Configuration.js#L2126-L2135
train
Sets the legacy number format
[ 30522, 3853, 1006, 16420, 2953, 18900, 3593, 1007, 1063, 16420, 2953, 18900, 3593, 1027, 16420, 2953, 18900, 3593, 1029, 16420, 2953, 18900, 3593, 1012, 2000, 29547, 18992, 3366, 1006, 1007, 1024, 1000, 1000, 1025, 4638, 1006, 999, 16420, 2...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
chartjs/Chart.js
src/core/core.tooltip.js
function(line) { ctx.fillText(line, pt.x + xLinePadding, pt.y); pt.y += bodyFontSize + bodySpacing; }
javascript
function(line) { ctx.fillText(line, pt.x + xLinePadding, pt.y); pt.y += bodyFontSize + bodySpacing; }
[ "function", "(", "line", ")", "{", "ctx", ".", "fillText", "(", "line", ",", "pt", ".", "x", "+", "xLinePadding", ",", "pt", ".", "y", ")", ";", "pt", ".", "y", "+=", "bodyFontSize", "+", "bodySpacing", ";", "}" ]
Before Body
[ "Before", "Body" ]
f093c36574d290330ed623e60fbd070421c730d5
https://github.com/chartjs/Chart.js/blob/f093c36574d290330ed623e60fbd070421c730d5/src/core/core.tooltip.js#L794-L797
train
fill the line
[ 30522, 3853, 1006, 2240, 1007, 1063, 14931, 2595, 1012, 6039, 18209, 1006, 2240, 1010, 13866, 1012, 1060, 1009, 28712, 3170, 15455, 4667, 1010, 13866, 1012, 1061, 1007, 1025, 13866, 1012, 1061, 1009, 1027, 2303, 14876, 7666, 4697, 1009, 230...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
fengyuanchen/cropper
dist/cropper.common.js
setData
function setData(element, name, data) { if (isObject(data)) { element[name] = data; } else if (element.dataset) { element.dataset[name] = data; } else { element.setAttribute('data-' + hyphenate(name), data); } }
javascript
function setData(element, name, data) { if (isObject(data)) { element[name] = data; } else if (element.dataset) { element.dataset[name] = data; } else { element.setAttribute('data-' + hyphenate(name), data); } }
[ "function", "setData", "(", "element", ",", "name", ",", "data", ")", "{", "if", "(", "isObject", "(", "data", ")", ")", "{", "element", "[", "name", "]", "=", "data", ";", "}", "else", "if", "(", "element", ".", "dataset", ")", "{", "element", "...
Set data to the given element. @param {Element} element - The target element. @param {string} name - The data key to set. @param {string} data - The data value.
[ "Set", "data", "to", "the", "given", "element", "." ]
6677332a6a375b647f58808dfc24ea09f5804041
https://github.com/fengyuanchen/cropper/blob/6677332a6a375b647f58808dfc24ea09f5804041/dist/cropper.common.js#L491-L499
train
Set data on an element
[ 30522, 3853, 2275, 2850, 2696, 1006, 5783, 1010, 2171, 1010, 2951, 1007, 1063, 2065, 1006, 11163, 2497, 20614, 1006, 2951, 1007, 1007, 1063, 5783, 1031, 2171, 1033, 1027, 2951, 1025, 1065, 2842, 2065, 1006, 5783, 1012, 2951, 13462, 1007, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
aframevr/aframe
src/utils/styleParser.js
transformKeysToCamelCase
function transformKeysToCamelCase (obj) { var camelKey; var key; for (key in obj) { camelKey = toCamelCase(key); if (key === camelKey) { continue; } obj[camelKey] = obj[key]; delete obj[key]; } return obj; }
javascript
function transformKeysToCamelCase (obj) { var camelKey; var key; for (key in obj) { camelKey = toCamelCase(key); if (key === camelKey) { continue; } obj[camelKey] = obj[key]; delete obj[key]; } return obj; }
[ "function", "transformKeysToCamelCase", "(", "obj", ")", "{", "var", "camelKey", ";", "var", "key", ";", "for", "(", "key", "in", "obj", ")", "{", "camelKey", "=", "toCamelCase", "(", "key", ")", ";", "if", "(", "key", "===", "camelKey", ")", "{", "c...
Converts object's keys from hyphens to camelCase (e.g., `max-value` to `maxValue`). @param {object} obj - The object to camelCase keys. @return {object} The object with keys camelCased.
[ "Converts", "object", "s", "keys", "from", "hyphens", "to", "camelCase", "(", "e", ".", "g", ".", "max", "-", "value", "to", "maxValue", ")", "." ]
24acc78a7299a4cdfe3ef617f4d40ddf6275c992
https://github.com/aframevr/aframe/blob/24acc78a7299a4cdfe3ef617f4d40ddf6275c992/src/utils/styleParser.js#L53-L63
train
Transform keys to camel case
[ 30522, 3853, 10938, 14839, 16033, 28727, 2884, 18382, 1006, 27885, 3501, 1007, 1063, 13075, 19130, 14839, 1025, 13075, 3145, 1025, 2005, 1006, 3145, 1999, 27885, 3501, 1007, 1063, 19130, 14839, 1027, 2000, 28727, 2884, 18382, 1006, 3145, 1007...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
aws/aws-sdk-js
features/extra/cleanup.js
function(list, iter, callback) { var item = list.shift(); iter(item, function(err) { if (err) return callback(err); else if (list.length) { eachSeries(list, iter, callback); } else { return callback(); } }); }
javascript
function(list, iter, callback) { var item = list.shift(); iter(item, function(err) { if (err) return callback(err); else if (list.length) { eachSeries(list, iter, callback); } else { return callback(); } }); }
[ "function", "(", "list", ",", "iter", ",", "callback", ")", "{", "var", "item", "=", "list", ".", "shift", "(", ")", ";", "iter", "(", "item", ",", "function", "(", "err", ")", "{", "if", "(", "err", ")", "return", "callback", "(", "err", ")", ...
Run bucket cleanup serially.
[ "Run", "bucket", "cleanup", "serially", "." ]
c23e5f0edd150f8885267e5f7c8a564f8e6e8562
https://github.com/aws/aws-sdk-js/blob/c23e5f0edd150f8885267e5f7c8a564f8e6e8562/features/extra/cleanup.js#L48-L58
train
iterate over the list and return the next result
[ 30522, 3853, 1006, 2862, 1010, 2009, 2121, 1010, 2655, 5963, 1007, 1063, 13075, 8875, 1027, 2862, 1012, 5670, 1006, 1007, 1025, 2009, 2121, 1006, 8875, 1010, 3853, 1006, 9413, 2099, 1007, 1063, 2065, 1006, 9413, 2099, 1007, 2709, 2655, 59...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
catapult-project/catapult
tracing/third_party/oboe/src/lists.js
foldR1
function foldR1(fn, list) { return tail(list) ? fn(foldR1(fn, tail(list)), head(list)) : head(list) ; }
javascript
function foldR1(fn, list) { return tail(list) ? fn(foldR1(fn, tail(list)), head(list)) : head(list) ; }
[ "function", "foldR1", "(", "fn", ",", "list", ")", "{", "return", "tail", "(", "list", ")", "?", "fn", "(", "foldR1", "(", "fn", ",", "tail", "(", "list", ")", ")", ",", "head", "(", "list", ")", ")", ":", "head", "(", "list", ")", ";", "}" ]
foldR implementation. Reduce a list down to a single value. @pram {Function} fn (rightEval, curVal) -> result
[ "foldR", "implementation", ".", "Reduce", "a", "list", "down", "to", "a", "single", "value", "." ]
992929ffccac68827869a497f01ee4d653ed4f25
https://github.com/catapult-project/catapult/blob/992929ffccac68827869a497f01ee4d653ed4f25/tracing/third_party/oboe/src/lists.js#L115-L121
train
R1 folds the list in reverse order
[ 30522, 3853, 10671, 2099, 2487, 1006, 1042, 2078, 1010, 2862, 1007, 1063, 2709, 5725, 1006, 2862, 1007, 1029, 1042, 2078, 1006, 10671, 2099, 2487, 1006, 1042, 2078, 1010, 5725, 1006, 2862, 1007, 1007, 1010, 2132, 1006, 2862, 1007, 1007, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.m/src/sap/m/Support.js
setupDialog
function setupDialog() { // setup e2e values as log level and content if (dialog.traceXml) { dialog.$(e2eTraceConst.taContent).text(dialog.traceXml); } if (dialog.e2eLogLevel) { dialog.$(e2eTraceConst.selLevel).val(dialog.e2eLogLevel); } fillPanelContent(controlIDs.dvLoadedModules, oD...
javascript
function setupDialog() { // setup e2e values as log level and content if (dialog.traceXml) { dialog.$(e2eTraceConst.taContent).text(dialog.traceXml); } if (dialog.e2eLogLevel) { dialog.$(e2eTraceConst.selLevel).val(dialog.e2eLogLevel); } fillPanelContent(controlIDs.dvLoadedModules, oD...
[ "function", "setupDialog", "(", ")", "{", "// setup e2e values as log level and content", "if", "(", "dialog", ".", "traceXml", ")", "{", "dialog", ".", "$", "(", "e2eTraceConst", ".", "taContent", ")", ".", "text", "(", "dialog", ".", "traceXml", ")", ";", ...
setup dialog elements and bind some events
[ "setup", "dialog", "elements", "and", "bind", "some", "events" ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.m/src/sap/m/Support.js#L208-L238
train
Setup the dialog
[ 30522, 30524, 2504, 1998, 4180, 2065, 1006, 13764, 8649, 1012, 7637, 2595, 19968, 1007, 1063, 13764, 8649, 1012, 1002, 1006, 1041, 2475, 3388, 22903, 8663, 3367, 1012, 11937, 8663, 6528, 2102, 1007, 1012, 3793, 1006, 13764, 8649, 1012, 7637...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
mochajs/mocha
lib/utils.js
hasMatchingExtname
function hasMatchingExtname(pathname, exts) { var suffix = path.extname(pathname).slice(1); return exts.some(function(element) { return suffix === element; }); }
javascript
function hasMatchingExtname(pathname, exts) { var suffix = path.extname(pathname).slice(1); return exts.some(function(element) { return suffix === element; }); }
[ "function", "hasMatchingExtname", "(", "pathname", ",", "exts", ")", "{", "var", "suffix", "=", "path", ".", "extname", "(", "pathname", ")", ".", "slice", "(", "1", ")", ";", "return", "exts", ".", "some", "(", "function", "(", "element", ")", "{", ...
Determines if pathname has a matching file extension. @private @param {string} pathname - Pathname to check for match. @param {string[]} exts - List of file extensions (sans period). @return {boolean} whether file extension matches. @example hasMatchingExtname('foo.html', ['js', 'css']); // => false
[ "Determines", "if", "pathname", "has", "a", "matching", "file", "extension", "." ]
9b00fedb610241e33f7592c40164e42a38a793cf
https://github.com/mochajs/mocha/blob/9b00fedb610241e33f7592c40164e42a38a793cf/lib/utils.js#L530-L535
train
Check if a pathname has a matching extension
[ 30522, 3853, 2038, 18900, 8450, 10288, 2102, 18442, 1006, 4130, 18442, 1010, 4654, 3215, 1007, 1063, 13075, 16809, 1027, 4130, 1012, 4654, 2102, 18442, 1006, 4130, 18442, 1007, 1012, 14704, 1006, 1015, 1007, 1025, 2709, 4654, 3215, 1012, 20...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/LiveDevelopment/MultiBrowserImpl/protocol/LiveDevProtocol.js
setStylesheetText
function setStylesheetText(url, text, clients) { return _send( { method: "CSS.setStylesheetText", params: { url: url, text: text } } ); }
javascript
function setStylesheetText(url, text, clients) { return _send( { method: "CSS.setStylesheetText", params: { url: url, text: text } } ); }
[ "function", "setStylesheetText", "(", "url", ",", "text", ",", "clients", ")", "{", "return", "_send", "(", "{", "method", ":", "\"CSS.setStylesheetText\"", ",", "params", ":", "{", "url", ":", "url", ",", "text", ":", "text", "}", "}", ")", ";", "}" ]
Protocol method. Reloads a CSS styleseet in the browser (by replacing its text) given its url. @param {string} url Absolute URL of the stylesheet @param {string} text The new text of the stylesheet @param {number|Array.<number>} clients A client ID or array of client IDs that should evaluate the script. @return {$.Prom...
[ "Protocol", "method", ".", "Reloads", "a", "CSS", "styleseet", "in", "the", "browser", "(", "by", "replacing", "its", "text", ")", "given", "its", "url", "." ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/LiveDevelopment/MultiBrowserImpl/protocol/LiveDevProtocol.js#L265-L275
train
Set stylesheet text
[ 30522, 3853, 4520, 27983, 4095, 15558, 18209, 1006, 24471, 2140, 1010, 3793, 1010, 30524, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
ColorlibHQ/AdminLTE
plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.all.js
function(options) { var nextSibling = wysihtml5.dom.domNode(node).next({ignoreBlankTexts: true}), previousSibling = wysihtml5.dom.domNode(node).prev({ignoreBlankTexts: true}); if (nextSibling && _isLineBreak(nextSibling)) { nextSibling.parentNode.removeChild(nextSibling); ...
javascript
function(options) { var nextSibling = wysihtml5.dom.domNode(node).next({ignoreBlankTexts: true}), previousSibling = wysihtml5.dom.domNode(node).prev({ignoreBlankTexts: true}); if (nextSibling && _isLineBreak(nextSibling)) { nextSibling.parentNode.removeChild(nextSibling); ...
[ "function", "(", "options", ")", "{", "var", "nextSibling", "=", "wysihtml5", ".", "dom", ".", "domNode", "(", "node", ")", ".", "next", "(", "{", "ignoreBlankTexts", ":", "true", "}", ")", ",", "previousSibling", "=", "wysihtml5", ".", "dom", ".", "do...
/* wysihtml5.dom.lineBreaks(element).remove(); Removes line breaks before and after the given node
[ "/", "*", "wysihtml5", ".", "dom", ".", "lineBreaks", "(", "element", ")", ".", "remove", "()", ";" ]
19113c3cbc19a7afe0cfd3158d647064d2d30661
https://github.com/ColorlibHQ/AdminLTE/blob/19113c3cbc19a7afe0cfd3158d647064d2d30661/plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.all.js#L5746-L5756
train
Remove the text nodes that are not blank
[ 30522, 3853, 1006, 7047, 1007, 1063, 13075, 2279, 5332, 9709, 1027, 1059, 7274, 19190, 21246, 2140, 2629, 1012, 14383, 1012, 14383, 3630, 3207, 1006, 13045, 1007, 1012, 2279, 1006, 1063, 8568, 28522, 8950, 18209, 2015, 1024, 2995, 1065, 100...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/utils/PerfUtils.js
createPerfMeasurement
function createPerfMeasurement(id, name) { var pm = new PerfMeasurement(id, name); exports[id] = pm; return pm; }
javascript
function createPerfMeasurement(id, name) { var pm = new PerfMeasurement(id, name); exports[id] = pm; return pm; }
[ "function", "createPerfMeasurement", "(", "id", ",", "name", ")", "{", "var", "pm", "=", "new", "PerfMeasurement", "(", "id", ",", "name", ")", ";", "exports", "[", "id", "]", "=", "pm", ";", "return", "pm", ";", "}" ]
Create a new PerfMeasurement key. Adds itself to the module export. Can be accessed on the module, e.g. PerfUtils.MY_PERF_KEY. @param {!string} id Unique ID for this measurement name @param {!name} name A short name for this measurement
[ "Create", "a", "new", "PerfMeasurement", "key", ".", "Adds", "itself", "to", "the", "module", "export", ".", "Can", "be", "accessed", "on", "the", "module", "e", ".", "g", ".", "PerfUtils", ".", "MY_PERF_KEY", "." ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/utils/PerfUtils.js#L103-L108
train
Create a new PerfMeasurement instance
[ 30522, 3853, 3443, 4842, 16715, 5243, 28632, 3672, 1006, 8909, 1010, 2171, 1007, 1063, 13075, 7610, 1027, 2047, 2566, 16715, 5243, 28632, 3672, 1006, 8909, 1010, 2171, 1007, 1025, 14338, 1031, 8909, 1033, 1027, 7610, 1025, 2709, 7610, 1025,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
wuchangming/spy-debugger
buildin_modules/weinre/web/interfaces/interfaces.js
setUpShowCheckBox
function setUpShowCheckBox(element, key) { var value = localStorage.getItem(key) if (null == value) value = true else value = (value == "true") element.checked = value element.storageKey = key element.addEventListener("click", el_showCheckBoxClicked, false) }
javascript
function setUpShowCheckBox(element, key) { var value = localStorage.getItem(key) if (null == value) value = true else value = (value == "true") element.checked = value element.storageKey = key element.addEventListener("click", el_showCheckBoxClicked, false) }
[ "function", "setUpShowCheckBox", "(", "element", ",", "key", ")", "{", "var", "value", "=", "localStorage", ".", "getItem", "(", "key", ")", "if", "(", "null", "==", "value", ")", "value", "=", "true", "else", "value", "=", "(", "value", "==", "\"true\...
-----------------------------------------------------------------------------
[ "-----------------------------------------------------------------------------" ]
55c1dda0dff0c44920673711656ddfd7ff03c307
https://github.com/wuchangming/spy-debugger/blob/55c1dda0dff0c44920673711656ddfd7ff03c307/buildin_modules/weinre/web/interfaces/interfaces.js#L67-L78
train
Set up the show checkbox
[ 30522, 3853, 16437, 22231, 16526, 5369, 3600, 8758, 1006, 5783, 1010, 3145, 1007, 1063, 13075, 3643, 1027, 10575, 4263, 4270, 1012, 2131, 4221, 2213, 1006, 3145, 1007, 2065, 1006, 19701, 1027, 1027, 3643, 1007, 3643, 1027, 2995, 2842, 3643,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
GitbookIO/gitbook
lib/json/encodeSummaryPart.js
encodeSummaryPart
function encodeSummaryPart(part) { return { title: part.getTitle(), articles: part.getArticles() .map(encodeSummaryArticle).toJS() }; }
javascript
function encodeSummaryPart(part) { return { title: part.getTitle(), articles: part.getArticles() .map(encodeSummaryArticle).toJS() }; }
[ "function", "encodeSummaryPart", "(", "part", ")", "{", "return", "{", "title", ":", "part", ".", "getTitle", "(", ")", ",", "articles", ":", "part", ".", "getArticles", "(", ")", ".", "map", "(", "encodeSummaryArticle", ")", ".", "toJS", "(", ")", "}"...
Encode a SummaryPart to JSON @param {SummaryPart} @return {Object}
[ "Encode", "a", "SummaryPart", "to", "JSON" ]
6c6ef7f4af32a2977e44dd23d3feb6ebf28970f4
https://github.com/GitbookIO/gitbook/blob/6c6ef7f4af32a2977e44dd23d3feb6ebf28970f4/lib/json/encodeSummaryPart.js#L9-L15
train
Encode a summary part
[ 30522, 3853, 4372, 23237, 2819, 7849, 22571, 8445, 1006, 2112, 1007, 1063, 2709, 1063, 2516, 1024, 2112, 1012, 2131, 3775, 9286, 1006, 1007, 1010, 4790, 1024, 2112, 1012, 2131, 8445, 20921, 1006, 1007, 1012, 4949, 1006, 4372, 23237, 2819, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
nhn/tui.editor
src/js/extensions/chart/chart.js
calcDSVDelta
function calcDSVDelta(code, delimiter) { let rows, delta; try { csv.COLUMN_SEPARATOR = delimiter; rows = csv.parse(code); if (rows[0].length < 2) { // parsing completely failed throw new Error('parser fail'); } // sum of all length difference of all rows delta = rows.map(row =...
javascript
function calcDSVDelta(code, delimiter) { let rows, delta; try { csv.COLUMN_SEPARATOR = delimiter; rows = csv.parse(code); if (rows[0].length < 2) { // parsing completely failed throw new Error('parser fail'); } // sum of all length difference of all rows delta = rows.map(row =...
[ "function", "calcDSVDelta", "(", "code", ",", "delimiter", ")", "{", "let", "rows", ",", "delta", ";", "try", "{", "csv", ".", "COLUMN_SEPARATOR", "=", "delimiter", ";", "rows", "=", "csv", ".", "parse", "(", "code", ")", ";", "if", "(", "rows", "[",...
calculate delta(sum of length difference of rows) values of given DSV @param {string} code - code to be test @param {string|RegExp} delimiter - delimiter to test @returns {number} delta value for code @ignore
[ "calculate", "delta", "(", "sum", "of", "length", "difference", "of", "rows", ")", "values", "of", "given", "DSV" ]
e75ab08c2a7ab07d1143e318f7cde135c5e3002e
https://github.com/nhn/tui.editor/blob/e75ab08c2a7ab07d1143e318f7cde135c5e3002e/src/js/extensions/chart/chart.js#L141-L167
train
Calculates the delta of the DSV from the given CSV code.
[ 30522, 3853, 10250, 19797, 2015, 16872, 20042, 2050, 1006, 3642, 1010, 3972, 27605, 3334, 1007, 1063, 2292, 10281, 1010, 7160, 1025, 3046, 1063, 20116, 2615, 1012, 5930, 1035, 19802, 25879, 2953, 1027, 3972, 27605, 3334, 1025, 10281, 1027, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
eslint/eslint
lib/rules/semi.js
checkForSemicolon
function checkForSemicolon(node) { const isSemi = astUtils.isSemicolonToken(sourceCode.getLastToken(node)); if (never) { if (isSemi && canRemoveSemicolon(node)) { report(node, true); } else if (!isSemi && beforeStatementContinuationChars === "...
javascript
function checkForSemicolon(node) { const isSemi = astUtils.isSemicolonToken(sourceCode.getLastToken(node)); if (never) { if (isSemi && canRemoveSemicolon(node)) { report(node, true); } else if (!isSemi && beforeStatementContinuationChars === "...
[ "function", "checkForSemicolon", "(", "node", ")", "{", "const", "isSemi", "=", "astUtils", ".", "isSemicolonToken", "(", "sourceCode", ".", "getLastToken", "(", "node", ")", ")", ";", "if", "(", "never", ")", "{", "if", "(", "isSemi", "&&", "canRemoveSemi...
Checks a node to see if it's followed by a semicolon. @param {ASTNode} node The node to check. @returns {void}
[ "Checks", "a", "node", "to", "see", "if", "it", "s", "followed", "by", "a", "semicolon", "." ]
bc0819c94aad14f7fad3cbc2338ea15658b0f272
https://github.com/eslint/eslint/blob/bc0819c94aad14f7fad3cbc2338ea15658b0f272/lib/rules/semi.js#L265-L283
train
Check if a semicolon is present in the source code
[ 30522, 3853, 4638, 29278, 3366, 7712, 12898, 2078, 1006, 13045, 1007, 1063, 9530, 3367, 26354, 23238, 1027, 2004, 8525, 3775, 4877, 1012, 26354, 23238, 25778, 12162, 11045, 2078, 1006, 3120, 16044, 1012, 2131, 8523, 9284, 7520, 1006, 13045, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
LLK/scratch-blocks
blocks_horizontal/wedo.js
function() { this.appendDummyInput() .appendField(new Blockly.FieldIconMenu( [ {src: Blockly.mainWorkspace.options.pathToMedia + 'icons/wedo_motor-speed_slow.svg', value: 'slow', width: 48, height: 48, alt: 'Slow'}, {src: Blockly.mainWorkspace.options....
javascript
function() { this.appendDummyInput() .appendField(new Blockly.FieldIconMenu( [ {src: Blockly.mainWorkspace.options.pathToMedia + 'icons/wedo_motor-speed_slow.svg', value: 'slow', width: 48, height: 48, alt: 'Slow'}, {src: Blockly.mainWorkspace.options....
[ "function", "(", ")", "{", "this", ".", "appendDummyInput", "(", ")", ".", "appendField", "(", "new", "Blockly", ".", "FieldIconMenu", "(", "[", "{", "src", ":", "Blockly", ".", "mainWorkspace", ".", "options", ".", "pathToMedia", "+", "'icons/wedo_motor-spe...
Block for motor speed drop-down (used for shadow). @this Blockly.Block
[ "Block", "for", "motor", "speed", "drop", "-", "down", "(", "used", "for", "shadow", ")", "." ]
455b2a854435c0a67da1da92320ddc3ec3e2b799
https://github.com/LLK/scratch-blocks/blob/455b2a854435c0a67da1da92320ddc3ec3e2b799/blocks_horizontal/wedo.js#L175-L191
train
Block for onomic motors.
[ 30522, 3853, 1006, 1007, 1063, 2023, 1012, 10439, 10497, 8566, 18879, 2378, 18780, 1006, 1007, 1012, 10439, 10497, 3790, 1006, 2047, 3796, 2135, 1012, 2492, 28524, 3549, 2226, 1006, 1031, 1063, 5034, 2278, 1024, 3796, 2135, 1012, 2364, 9316...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
angular/material
src/components/datepicker/js/calendar.spec.js
findYearElement
function findYearElement(parent, year) { var node = parent[0] || parent; var years = node.querySelectorAll('[md-calendar-year-body]'); var yearHeader = year.toString(); var target; for (var i = 0; i < years.length; i++) { target = years[i]; if (target.querySelector('.md-calendar-month-l...
javascript
function findYearElement(parent, year) { var node = parent[0] || parent; var years = node.querySelectorAll('[md-calendar-year-body]'); var yearHeader = year.toString(); var target; for (var i = 0; i < years.length; i++) { target = years[i]; if (target.querySelector('.md-calendar-month-l...
[ "function", "findYearElement", "(", "parent", ",", "year", ")", "{", "var", "node", "=", "parent", "[", "0", "]", "||", "parent", ";", "var", "years", "=", "node", ".", "querySelectorAll", "(", "'[md-calendar-year-body]'", ")", ";", "var", "yearHeader", "=...
Find the `tbody` for a year in the calendar.
[ "Find", "the", "tbody", "for", "a", "year", "in", "the", "calendar", "." ]
84ac558674e73958be84312444c48d9f823f6684
https://github.com/angular/material/blob/84ac558674e73958be84312444c48d9f823f6684/src/components/datepicker/js/calendar.spec.js#L74-L87
train
Find the year element in the specified calendar container
[ 30522, 3853, 2424, 29100, 12260, 3672, 1006, 6687, 1010, 2095, 1007, 1063, 13075, 13045, 1027, 6687, 1031, 1014, 1033, 1064, 1064, 6687, 1025, 13075, 2086, 1027, 13045, 30524, 2095, 4974, 2121, 1027, 2095, 1012, 2000, 3367, 4892, 1006, 1007...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/view/ViewCommandHandlers.js
init
function init() { currFontFamily = prefs.get("fontFamily"); _addDynamicFontFamily(currFontFamily); currFontSize = prefs.get("fontSize"); _addDynamicFontSize(currFontSize); _updateUI(); }
javascript
function init() { currFontFamily = prefs.get("fontFamily"); _addDynamicFontFamily(currFontFamily); currFontSize = prefs.get("fontSize"); _addDynamicFontSize(currFontSize); _updateUI(); }
[ "function", "init", "(", ")", "{", "currFontFamily", "=", "prefs", ".", "get", "(", "\"fontFamily\"", ")", ";", "_addDynamicFontFamily", "(", "currFontFamily", ")", ";", "currFontSize", "=", "prefs", ".", "get", "(", "\"fontSize\"", ")", ";", "_addDynamicFontS...
Initializes the different settings that need to loaded
[ "Initializes", "the", "different", "settings", "that", "need", "to", "loaded" ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/view/ViewCommandHandlers.js#L393-L399
train
Initialize the language
[ 30522, 3853, 1999, 4183, 1006, 1007, 1063, 12731, 12171, 14876, 3372, 7011, 4328, 2135, 1027, 3653, 10343, 1012, 2131, 1006, 1000, 15489, 7011, 4328, 2135, 1000, 1007, 1025, 1035, 5587, 5149, 28987, 2278, 14876, 3372, 7011, 4328, 2135, 1006...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/editor/Editor.js
_buildPreferencesContext
function _buildPreferencesContext(fullPath) { return PreferencesManager._buildContext(fullPath, fullPath ? LanguageManager.getLanguageForPath(fullPath).getId() : undefined); }
javascript
function _buildPreferencesContext(fullPath) { return PreferencesManager._buildContext(fullPath, fullPath ? LanguageManager.getLanguageForPath(fullPath).getId() : undefined); }
[ "function", "_buildPreferencesContext", "(", "fullPath", ")", "{", "return", "PreferencesManager", ".", "_buildContext", "(", "fullPath", ",", "fullPath", "?", "LanguageManager", ".", "getLanguageForPath", "(", "fullPath", ")", ".", "getId", "(", ")", ":", "undefi...
Helper function to build preferences context based on the full path of the file. @param {string} fullPath Full path of the file @return {*} A context for the specified file name
[ "Helper", "function", "to", "build", "preferences", "context", "based", "on", "the", "full", "path", "of", "the", "file", "." ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/editor/Editor.js#L292-L295
train
Build preferences context for the given file
[ 30522, 3853, 1035, 3857, 28139, 25523, 9363, 10111, 18413, 1006, 2440, 15069, 1007, 1063, 2709, 18394, 24805, 4590, 1012, 1035, 3857, 8663, 18209, 1006, 2440, 15069, 1010, 2440, 15069, 1029, 2653, 24805, 4590, 1012, 2131, 25023, 6692, 3351, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/LiveDevelopment/MultiBrowserImpl/protocol/remote/LiveDevProtocolRemote.js
function (orig, response) { if (!orig.id) { console.log("[Brackets LiveDev] Trying to send a response for a message with no ID"); return; } response.id = orig.id; this.send(response); }
javascript
function (orig, response) { if (!orig.id) { console.log("[Brackets LiveDev] Trying to send a response for a message with no ID"); return; } response.id = orig.id; this.send(response); }
[ "function", "(", "orig", ",", "response", ")", "{", "if", "(", "!", "orig", ".", "id", ")", "{", "console", ".", "log", "(", "\"[Brackets LiveDev] Trying to send a response for a message with no ID\"", ")", ";", "return", ";", "}", "response", ".", "id", "=", ...
Send a response of a particular message to the Editor. Original message must provide an 'id' property @param {Object} orig Original message. @param {Object} response Message to be sent as the response.
[ "Send", "a", "response", "of", "a", "particular", "message", "to", "the", "Editor", ".", "Original", "message", "must", "provide", "an", "id", "property" ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/LiveDevelopment/MultiBrowserImpl/protocol/remote/LiveDevProtocolRemote.js#L98-L105
train
send a response
[ 30522, 3853, 1006, 2030, 8004, 1010, 3433, 1007, 1063, 2065, 1006, 999, 2030, 8004, 1012, 8909, 1007, 1063, 10122, 1012, 8833, 1006, 1000, 1031, 19719, 2973, 6777, 1033, 2667, 2000, 4604, 1037, 3433, 2005, 1037, 4471, 2007, 2053, 8909, 10...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
eslint/eslint
lib/rules/no-useless-escape.js
report
function report(node, startOffset, character) { context.report({ node, loc: sourceCode.getLocFromIndex(sourceCode.getIndexFromLoc(node.loc.start) + startOffset), message: "Unnecessary escape character: \\{{character}}.", data: { character } ...
javascript
function report(node, startOffset, character) { context.report({ node, loc: sourceCode.getLocFromIndex(sourceCode.getIndexFromLoc(node.loc.start) + startOffset), message: "Unnecessary escape character: \\{{character}}.", data: { character } ...
[ "function", "report", "(", "node", ",", "startOffset", ",", "character", ")", "{", "context", ".", "report", "(", "{", "node", ",", "loc", ":", "sourceCode", ".", "getLocFromIndex", "(", "sourceCode", ".", "getIndexFromLoc", "(", "node", ".", "loc", ".", ...
Reports a node @param {ASTNode} node The node to report @param {number} startOffset The backslash's offset from the start of the node @param {string} character The uselessly escaped character (not including the backslash) @returns {void}
[ "Reports", "a", "node" ]
bc0819c94aad14f7fad3cbc2338ea15658b0f272
https://github.com/eslint/eslint/blob/bc0819c94aad14f7fad3cbc2338ea15658b0f272/lib/rules/no-useless-escape.js#L104-L111
train
Reports an unclosed escape character in a node.
[ 30522, 3853, 3189, 1006, 13045, 1010, 2707, 27475, 3388, 1010, 2839, 1007, 1063, 6123, 1012, 3189, 1006, 1063, 13045, 1010, 8840, 2278, 1024, 3120, 16044, 1012, 2131, 4135, 2278, 19699, 20936, 13629, 2595, 1006, 3120, 16044, 1012, 2131, 222...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
radare/radare2
shlr/www/graph/js-graph-it.js
Segment
function Segment(id, parentElement) { this.id = id; this.htmlElement = document.createElement('div'); this.htmlElement.id = id; this.htmlElement.style.position = 'absolute'; this.htmlElement.style.overflow = 'hidden'; parentElement.appendChild(this.htmlElement); this.startX; this.startY; this.length; this.th...
javascript
function Segment(id, parentElement) { this.id = id; this.htmlElement = document.createElement('div'); this.htmlElement.id = id; this.htmlElement.style.position = 'absolute'; this.htmlElement.style.overflow = 'hidden'; parentElement.appendChild(this.htmlElement); this.startX; this.startY; this.length; this.th...
[ "function", "Segment", "(", "id", ",", "parentElement", ")", "{", "this", ".", "id", "=", "id", ";", "this", ".", "htmlElement", "=", "document", ".", "createElement", "(", "'div'", ")", ";", "this", ".", "htmlElement", ".", "id", "=", "id", ";", "th...
This class represents a connector segment, it is drawn via a div element. A segment has a starting point defined by the properties startX and startY, a length, a thickness and an orientation. Allowed values for the orientation property are defined by the constants UP, LEFT, DOWN and RIGHT.
[ "This", "class", "represents", "a", "connector", "segment", "it", "is", "drawn", "via", "a", "div", "element", ".", "A", "segment", "has", "a", "starting", "point", "defined", "by", "the", "properties", "startX", "and", "startY", "a", "length", "a", "thick...
bf5e3028810a0ec7c267c6fe4bfad639b4819e35
https://github.com/radare/radare2/blob/bf5e3028810a0ec7c267c6fe4bfad639b4819e35/shlr/www/graph/js-graph-it.js#L513-L636
train
This class is the base class for the segment
[ 30522, 3853, 6903, 1006, 8909, 1010, 6687, 12260, 3672, 1007, 1063, 2023, 1012, 8909, 1027, 8909, 1025, 2023, 1012, 16129, 12260, 3672, 1027, 6254, 1012, 3443, 12260, 3672, 1006, 1005, 4487, 2615, 1005, 1007, 1025, 2023, 1012, 16129, 12260,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
grpc/grpc
examples/node/dynamic_codegen/route_guide/route_guide_server.js
routeChat
function routeChat(call) { call.on('data', function(note) { var key = pointKey(note.location); /* For each note sent, respond with all previous notes that correspond to * the same point */ if (route_notes.hasOwnProperty(key)) { _.each(route_notes[key], function(note) { call.write(note);...
javascript
function routeChat(call) { call.on('data', function(note) { var key = pointKey(note.location); /* For each note sent, respond with all previous notes that correspond to * the same point */ if (route_notes.hasOwnProperty(key)) { _.each(route_notes[key], function(note) { call.write(note);...
[ "function", "routeChat", "(", "call", ")", "{", "call", ".", "on", "(", "'data'", ",", "function", "(", "note", ")", "{", "var", "key", "=", "pointKey", "(", "note", ".", "location", ")", ";", "/* For each note sent, respond with all previous notes that correspo...
routeChat handler. Receives a stream of message/location pairs, and responds with a stream of all previous messages at each of those locations. @param {Duplex} call The stream for incoming and outgoing messages
[ "routeChat", "handler", ".", "Receives", "a", "stream", "of", "message", "/", "location", "pairs", "and", "responds", "with", "a", "stream", "of", "all", "previous", "messages", "at", "each", "of", "those", "locations", "." ]
cc75d93818410e2b0edd0fa3009a6def9ac403ca
https://github.com/grpc/grpc/blob/cc75d93818410e2b0edd0fa3009a6def9ac403ca/examples/node/dynamic_codegen/route_guide/route_guide_server.js#L194-L212
train
routeChat - Sends a note to the specified call
[ 30522, 3853, 2799, 7507, 2102, 1006, 2655, 1007, 1063, 2655, 1012, 2006, 1006, 1005, 2951, 1005, 1010, 3853, 1006, 3602, 1007, 1063, 13075, 3145, 1027, 2391, 14839, 1006, 3602, 1012, 3295, 1007, 1025, 1013, 1008, 2005, 2169, 3602, 2741, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
babel/babel
packages/babel-traverse/src/path/evaluation.js
evaluateCached
function evaluateCached(path, state) { const { node } = path; const { seen } = state; if (seen.has(node)) { const existing = seen.get(node); if (existing.resolved) { return existing.value; } else { deopt(path, state); return; } } else { const item = { resolved: false }; ...
javascript
function evaluateCached(path, state) { const { node } = path; const { seen } = state; if (seen.has(node)) { const existing = seen.get(node); if (existing.resolved) { return existing.value; } else { deopt(path, state); return; } } else { const item = { resolved: false }; ...
[ "function", "evaluateCached", "(", "path", ",", "state", ")", "{", "const", "{", "node", "}", "=", "path", ";", "const", "{", "seen", "}", "=", "state", ";", "if", "(", "seen", ".", "has", "(", "node", ")", ")", "{", "const", "existing", "=", "se...
We wrap the _evaluate method so we can track `seen` nodes, we push an item to the map before we actually evaluate it so we can deopt on self recursive nodes such as: var g = a ? 1 : 2, a = g * this.foo
[ "We", "wrap", "the", "_evaluate", "method", "so", "we", "can", "track", "seen", "nodes", "we", "push", "an", "item", "to", "the", "map", "before", "we", "actually", "evaluate", "it", "so", "we", "can", "deopt", "on", "self", "recursive", "nodes", "such",...
1969e6b6aa7d90be3fbb3aca98ea96849656a55a
https://github.com/babel/babel/blob/1969e6b6aa7d90be3fbb3aca98ea96849656a55a/packages/babel-traverse/src/path/evaluation.js#L48-L71
train
evaluate cached value
[ 30522, 3853, 16157, 3540, 7690, 1006, 4130, 1010, 2110, 1007, 1063, 9530, 3367, 1063, 13045, 1065, 1027, 4130, 1025, 9530, 3367, 1063, 2464, 1065, 1027, 2110, 1025, 2065, 1006, 2464, 1012, 2038, 1006, 13045, 1007, 1007, 1063, 9530, 3367, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.ux3/src/sap/ui/ux3/ExactList.js
function(oList, iWidth){ iWidth = ExactAttribute._checkWidth(iWidth); var sPos = oList._bRTL ? "right" : "left"; oList._iCurrentWidth = iWidth; oList._getAtt()._setWidth(oList._iCurrentWidth); oList.$("lst").css("width", iWidth + "px"); oList.$("rsz").css(sPos, (iWidth - 4) + "px"); if (oList._isTop()) { ...
javascript
function(oList, iWidth){ iWidth = ExactAttribute._checkWidth(iWidth); var sPos = oList._bRTL ? "right" : "left"; oList._iCurrentWidth = iWidth; oList._getAtt()._setWidth(oList._iCurrentWidth); oList.$("lst").css("width", iWidth + "px"); oList.$("rsz").css(sPos, (iWidth - 4) + "px"); if (oList._isTop()) { ...
[ "function", "(", "oList", ",", "iWidth", ")", "{", "iWidth", "=", "ExactAttribute", ".", "_checkWidth", "(", "iWidth", ")", ";", "var", "sPos", "=", "oList", ".", "_bRTL", "?", "\"right\"", ":", "\"left\"", ";", "oList", ".", "_iCurrentWidth", "=", "iWid...
Sets the width of the list to the given width (maybe the width is adapted to the allowed range (@see checkWidth))
[ "Sets", "the", "width", "of", "the", "list", "to", "the", "given", "width", "(", "maybe", "the", "width", "is", "adapted", "to", "the", "allowed", "range", "(" ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.ux3/src/sap/ui/ux3/ExactList.js#L1191-L1209
train
Sets the width of the ExactList
[ 30522, 3853, 1006, 19330, 2923, 1010, 1045, 9148, 11927, 2232, 1007, 1063, 1045, 9148, 11927, 2232, 1027, 6635, 19321, 3089, 8569, 2618, 1012, 1035, 4638, 9148, 11927, 2232, 1006, 1045, 9148, 11927, 2232, 1007, 1025, 13075, 11867, 2891, 102...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
eslint/eslint
lib/rules/rest-spread-spacing.js
checkWhiteSpace
function checkWhiteSpace(node) { const operator = sourceCode.getFirstToken(node), nextToken = sourceCode.getTokenAfter(operator), hasWhitespace = sourceCode.isSpaceBetweenTokens(operator, nextToken); let type; switch (node.type) { case...
javascript
function checkWhiteSpace(node) { const operator = sourceCode.getFirstToken(node), nextToken = sourceCode.getTokenAfter(operator), hasWhitespace = sourceCode.isSpaceBetweenTokens(operator, nextToken); let type; switch (node.type) { case...
[ "function", "checkWhiteSpace", "(", "node", ")", "{", "const", "operator", "=", "sourceCode", ".", "getFirstToken", "(", "node", ")", ",", "nextToken", "=", "sourceCode", ".", "getTokenAfter", "(", "operator", ")", ",", "hasWhitespace", "=", "sourceCode", ".",...
-------------------------------------------------------------------------- Helpers -------------------------------------------------------------------------- Checks whitespace between rest/spread operators and their expressions @param {ASTNode} node - The node to check @returns {void}
[ "--------------------------------------------------------------------------", "Helpers", "--------------------------------------------------------------------------", "Checks", "whitespace", "between", "rest", "/", "spread", "operators", "and", "their", "expressions" ]
bc0819c94aad14f7fad3cbc2338ea15658b0f272
https://github.com/eslint/eslint/blob/bc0819c94aad14f7fad3cbc2338ea15658b0f272/lib/rules/rest-spread-spacing.js#L45-L105
train
Check if whitespace is present in operator
[ 30522, 3853, 4638, 2860, 16584, 2229, 15327, 1006, 13045, 1007, 1063, 9530, 3367, 6872, 1027, 3120, 16044, 1012, 2131, 8873, 12096, 18715, 2368, 1006, 13045, 1007, 1010, 2279, 18715, 2368, 1027, 3120, 16044, 1012, 2131, 18715, 8189, 6199, 2...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
ColorlibHQ/AdminLTE
bower_components/jquery-sparkline/src/vcanvas-base.js
function (shapetype, shapeargs) { var id = shapeCount++; shapeargs.unshift(id); return new VShape(this, id, shapetype, shapeargs); }
javascript
function (shapetype, shapeargs) { var id = shapeCount++; shapeargs.unshift(id); return new VShape(this, id, shapetype, shapeargs); }
[ "function", "(", "shapetype", ",", "shapeargs", ")", "{", "var", "id", "=", "shapeCount", "++", ";", "shapeargs", ".", "unshift", "(", "id", ")", ";", "return", "new", "VShape", "(", "this", ",", "id", ",", "shapetype", ",", "shapeargs", ")", ";", "}...
Generate a shape object and id for later rendering
[ "Generate", "a", "shape", "object", "and", "id", "for", "later", "rendering" ]
19113c3cbc19a7afe0cfd3158d647064d2d30661
https://github.com/ColorlibHQ/AdminLTE/blob/19113c3cbc19a7afe0cfd3158d647064d2d30661/bower_components/jquery-sparkline/src/vcanvas-base.js#L99-L103
train
Create a new VShape
[ 30522, 3853, 1006, 4338, 13874, 1010, 4338, 2906, 5620, 1007, 1063, 13075, 8909, 1027, 4338, 3597, 16671, 1009, 1009, 1025, 4338, 2906, 5620, 1012, 4895, 6182, 6199, 1006, 8909, 1007, 1025, 2709, 2047, 5443, 3270, 5051, 1006, 2023, 1010, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
netlify/netlify-cms
packages/netlify-cms-core/src/lib/stringTemplate.js
getExplicitFieldReplacement
function getExplicitFieldReplacement(key, data) { if (!key.startsWith(FIELD_PREFIX)) { return; } const fieldName = key.substring(FIELD_PREFIX.length); return data.get(fieldName, ''); }
javascript
function getExplicitFieldReplacement(key, data) { if (!key.startsWith(FIELD_PREFIX)) { return; } const fieldName = key.substring(FIELD_PREFIX.length); return data.get(fieldName, ''); }
[ "function", "getExplicitFieldReplacement", "(", "key", ",", "data", ")", "{", "if", "(", "!", "key", ".", "startsWith", "(", "FIELD_PREFIX", ")", ")", "{", "return", ";", "}", "const", "fieldName", "=", "key", ".", "substring", "(", "FIELD_PREFIX", ".", ...
Allow `fields.` prefix in placeholder to override built in replacements like "slug" and "year" with values from fields of the same name.
[ "Allow", "fields", ".", "prefix", "in", "placeholder", "to", "override", "built", "in", "replacements", "like", "slug", "and", "year", "with", "values", "from", "fields", "of", "the", "same", "name", "." ]
2488556590cbfdcefa626f2f2de01e7a160cf6ee
https://github.com/netlify/netlify-cms/blob/2488556590cbfdcefa626f2f2de01e7a160cf6ee/packages/netlify-cms-core/src/lib/stringTemplate.js#L26-L32
train
Get the replacement for a field
[ 30522, 3853, 2131, 10288, 24759, 28775, 24475, 12891, 2890, 24759, 10732, 3672, 1006, 3145, 1010, 2951, 1007, 1063, 2065, 1006, 999, 3145, 1012, 4627, 24415, 1006, 2492, 1035, 17576, 1007, 1007, 1063, 2709, 1025, 1065, 9530, 3367, 2492, 184...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
eslint/eslint
lib/rules/no-eval.js
isConstant
function isConstant(node, name) { switch (node.type) { case "Literal": return node.value === name; case "TemplateLiteral": return ( node.expressions.length === 0 && node.quasis[0].value.cooked === name ); default: ...
javascript
function isConstant(node, name) { switch (node.type) { case "Literal": return node.value === name; case "TemplateLiteral": return ( node.expressions.length === 0 && node.quasis[0].value.cooked === name ); default: ...
[ "function", "isConstant", "(", "node", ",", "name", ")", "{", "switch", "(", "node", ".", "type", ")", "{", "case", "\"Literal\"", ":", "return", "node", ".", "value", "===", "name", ";", "case", "\"TemplateLiteral\"", ":", "return", "(", "node", ".", ...
Checks a given node is a Literal node of the specified string value. @param {ASTNode} node - A node to check. @param {string} name - A name to check. @returns {boolean} `true` if the node is a Literal node of the name.
[ "Checks", "a", "given", "node", "is", "a", "Literal", "node", "of", "the", "specified", "string", "value", "." ]
bc0819c94aad14f7fad3cbc2338ea15658b0f272
https://github.com/eslint/eslint/blob/bc0819c94aad14f7fad3cbc2338ea15658b0f272/lib/rules/no-eval.js#L41-L55
train
Check if a node is constant
[ 30522, 3853, 2003, 8663, 12693, 2102, 1006, 13045, 1010, 2171, 1007, 1063, 6942, 1006, 13045, 1012, 2828, 1007, 1063, 2553, 1000, 18204, 1000, 1024, 2709, 13045, 1012, 3643, 1027, 1027, 1027, 2171, 1025, 2553, 1000, 23561, 22779, 7941, 1000...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.commons/src/sap/ui/commons/MenuBar.js
function(oThis){ var iVisibleItems = 0; var jAreaRef = oThis.$("area"); var jItems = jAreaRef.children(); var bRtl = sap.ui.getCore().getConfiguration().getRTL(); var lastOffsetLeft = (bRtl ? 100000 : 0); jItems.each(function(iIdx) { if (iIdx == 0) { return true; } var currentOffsetLeft = t...
javascript
function(oThis){ var iVisibleItems = 0; var jAreaRef = oThis.$("area"); var jItems = jAreaRef.children(); var bRtl = sap.ui.getCore().getConfiguration().getRTL(); var lastOffsetLeft = (bRtl ? 100000 : 0); jItems.each(function(iIdx) { if (iIdx == 0) { return true; } var currentOffsetLeft = t...
[ "function", "(", "oThis", ")", "{", "var", "iVisibleItems", "=", "0", ";", "var", "jAreaRef", "=", "oThis", ".", "$", "(", "\"area\"", ")", ";", "var", "jItems", "=", "jAreaRef", ".", "children", "(", ")", ";", "var", "bRtl", "=", "sap", ".", "ui",...
Compute actual number of items currently hidden due to overflow
[ "Compute", "actual", "number", "of", "items", "currently", "hidden", "due", "to", "overflow" ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.commons/src/sap/ui/commons/MenuBar.js#L446-L478
train
Returns true if the item is visible
[ 30522, 3853, 1006, 27178, 24158, 1007, 1063, 13075, 4921, 17417, 3468, 4221, 5244, 1027, 1014, 1025, 13075, 15723, 14644, 12879, 1027, 27178, 24158, 1012, 1002, 1006, 1000, 2181, 1000, 1007, 1025, 13075, 10147, 18532, 2015, 1027, 15723, 14644...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
angular/angular
tools/gulp-tasks/cldr/extract.js
getDayPeriods
function getDayPeriods(localeData, dayPeriodsList) { const dayPeriods = localeData.main(`dates/calendars/gregorian/dayPeriods`); const result = {}; // cleaning up unused keys Object.keys(dayPeriods).forEach(key1 => { // format / stand-alone result[key1] = {}; Object.keys(dayPeriods[key1]).forEa...
javascript
function getDayPeriods(localeData, dayPeriodsList) { const dayPeriods = localeData.main(`dates/calendars/gregorian/dayPeriods`); const result = {}; // cleaning up unused keys Object.keys(dayPeriods).forEach(key1 => { // format / stand-alone result[key1] = {}; Object.keys(dayPeriods[key1]).forEa...
[ "function", "getDayPeriods", "(", "localeData", ",", "dayPeriodsList", ")", "{", "const", "dayPeriods", "=", "localeData", ".", "main", "(", "`", "`", ")", ";", "const", "result", "=", "{", "}", ";", "// cleaning up unused keys", "Object", ".", "keys", "(", ...
Returns data for the chosen day periods @returns {format: {narrow / abbreviated / wide: [...]}, stand-alone: {narrow / abbreviated / wide: [...]}}
[ "Returns", "data", "for", "the", "chosen", "day", "periods" ]
c016e2c4ecf7529f08fae4ca0f5c8b0170c6b51c
https://github.com/angular/angular/blob/c016e2c4ecf7529f08fae4ca0f5c8b0170c6b51c/tools/gulp-tasks/cldr/extract.js#L245-L262
train
Get day periods from a locale
[ 30522, 3853, 2131, 10259, 4842, 3695, 5104, 1006, 2334, 11960, 2696, 1010, 2154, 4842, 3695, 5104, 9863, 1007, 1063, 9530, 3367, 2154, 4842, 3695, 5104, 1027, 2334, 11960, 2696, 1012, 2364, 1006, 1036, 5246, 1013, 8094, 2015, 1013, 25847, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
getsentry/sentry-javascript
packages/raven-js/src/raven.js
function(breadcrumbs) { // known breadcrumb properties with urls // TODO: also consider arbitrary prop values that start with (https?)?:// var urlProps = ['to', 'from', 'url'], urlProp, crumb, data; for (var i = 0; i < breadcrumbs.values.length; ++i) { crumb = breadcrumbs.values...
javascript
function(breadcrumbs) { // known breadcrumb properties with urls // TODO: also consider arbitrary prop values that start with (https?)?:// var urlProps = ['to', 'from', 'url'], urlProp, crumb, data; for (var i = 0; i < breadcrumbs.values.length; ++i) { crumb = breadcrumbs.values...
[ "function", "(", "breadcrumbs", ")", "{", "// known breadcrumb properties with urls", "// TODO: also consider arbitrary prop values that start with (https?)?://", "var", "urlProps", "=", "[", "'to'", ",", "'from'", ",", "'url'", "]", ",", "urlProp", ",", "crumb", ",", "da...
Truncate breadcrumb values (right now just URLs)
[ "Truncate", "breadcrumb", "values", "(", "right", "now", "just", "URLs", ")" ]
a872223343fecf7364473b78bede937f1eb57bd0
https://github.com/getsentry/sentry-javascript/blob/a872223343fecf7364473b78bede937f1eb57bd0/packages/raven-js/src/raven.js#L1839-L1865
train
Merge breadcrumbs with urls
[ 30522, 3853, 1006, 7852, 26775, 25438, 2015, 1007, 1063, 1013, 1013, 2124, 7852, 26775, 25438, 5144, 2007, 24471, 4877, 1013, 1013, 28681, 2080, 1024, 2036, 5136, 15275, 17678, 5300, 2008, 2707, 2007, 1006, 16770, 1029, 1007, 1029, 1024, 10...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Dogfalo/materialize
dist/js/materialize.js
destroy
function destroy() { this._removeEventHandlers(); this.el.M_Materialbox = undefined; // Unwrap image $(this.placeholder).after(this.el).remove(); this.$el.removeAttr('style'); }
javascript
function destroy() { this._removeEventHandlers(); this.el.M_Materialbox = undefined; // Unwrap image $(this.placeholder).after(this.el).remove(); this.$el.removeAttr('style'); }
[ "function", "destroy", "(", ")", "{", "this", ".", "_removeEventHandlers", "(", ")", ";", "this", ".", "el", ".", "M_Materialbox", "=", "undefined", ";", "// Unwrap image", "$", "(", "this", ".", "placeholder", ")", ".", "after", "(", "this", ".", "el", ...
Teardown component
[ "Teardown", "component" ]
1122efadad8f1433d404696f7613e3cc13fb83a4
https://github.com/Dogfalo/materialize/blob/1122efadad8f1433d404696f7613e3cc13fb83a4/dist/js/materialize.js#L3369-L3377
train
Destroys the materialbox
[ 30522, 3853, 6033, 1006, 1007, 1063, 2023, 1012, 1035, 6366, 18697, 3372, 11774, 12910, 1006, 1007, 1025, 2023, 1012, 3449, 1012, 1049, 1035, 3430, 8758, 1027, 6151, 28344, 1025, 1013, 1013, 4895, 13088, 9331, 3746, 1002, 1006, 2023, 1012, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
nhn/tui.editor
src/js/wysiwygCommands/tableAlignCol.js
getSelectionInformation
function getSelectionInformation($table, rangeInformation) { const columnLength = $table.find('tr').eq(0).find('td,th').length; const { from, to } = rangeInformation; let startColumnIndex, endColumnIndex, isDivided; if (from.row === to.row) { startColumnIndex = from.cell; endColumnIndex = to....
javascript
function getSelectionInformation($table, rangeInformation) { const columnLength = $table.find('tr').eq(0).find('td,th').length; const { from, to } = rangeInformation; let startColumnIndex, endColumnIndex, isDivided; if (from.row === to.row) { startColumnIndex = from.cell; endColumnIndex = to....
[ "function", "getSelectionInformation", "(", "$table", ",", "rangeInformation", ")", "{", "const", "columnLength", "=", "$table", ".", "find", "(", "'tr'", ")", ".", "eq", "(", "0", ")", ".", "find", "(", "'td,th'", ")", ".", "length", ";", "const", "{", ...
Return start, end column index and boolean value for whether range divided or not @param {jQuery} $table jQuery wrapped TABLE @param {{startColumnIndex: number, endColumnIndex: number}} rangeInformation Range information @returns {{startColumnIndex: number, endColumnIndex: number, isDivided: boolean}}
[ "Return", "start", "end", "column", "index", "and", "boolean", "value", "for", "whether", "range", "divided", "or", "not" ]
e75ab08c2a7ab07d1143e318f7cde135c5e3002e
https://github.com/nhn/tui.editor/blob/e75ab08c2a7ab07d1143e318f7cde135c5e3002e/src/js/wysiwygCommands/tableAlignCol.js#L80-L107
train
Get selection information
[ 30522, 3853, 4152, 12260, 7542, 2378, 14192, 3370, 1006, 1002, 2795, 1010, 2846, 2378, 14192, 3370, 1007, 1063, 9530, 3367, 5930, 7770, 13512, 2232, 1027, 1002, 2795, 1012, 2424, 1006, 1005, 19817, 1005, 1007, 1012, 1041, 4160, 1006, 1014, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/model/Model.js
_traverseFilter
function _traverseFilter (vFilters, fnCheck) { vFilters = vFilters || []; if (vFilters instanceof Filter) { vFilters = [vFilters]; } // filter has more sub-filter instances (we ignore the subfilters below the any/all operators) for (var i = 0; i < vFilters.length; i++) { // check single Filter var ...
javascript
function _traverseFilter (vFilters, fnCheck) { vFilters = vFilters || []; if (vFilters instanceof Filter) { vFilters = [vFilters]; } // filter has more sub-filter instances (we ignore the subfilters below the any/all operators) for (var i = 0; i < vFilters.length; i++) { // check single Filter var ...
[ "function", "_traverseFilter", "(", "vFilters", ",", "fnCheck", ")", "{", "vFilters", "=", "vFilters", "||", "[", "]", ";", "if", "(", "vFilters", "instanceof", "Filter", ")", "{", "vFilters", "=", "[", "vFilters", "]", ";", "}", "// filter has more sub-filt...
Traverses the given filter tree. @param {sap.ui.model.Filter[]|sap.ui.model.Filter} vFilters Array of filters or a single filter instance, which will be checked for unsupported filter operators @param {function} fnCheck Check function which is called for each filter instance in the tree @private
[ "Traverses", "the", "given", "filter", "tree", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/model/Model.js#L1030-L1049
train
Traverse a filter
[ 30522, 3853, 1035, 20811, 8873, 21928, 1006, 1058, 8873, 21928, 2015, 1010, 1042, 26091, 3600, 1007, 1063, 1058, 8873, 21928, 2015, 1027, 1058, 8873, 21928, 2015, 1064, 1064, 1031, 1033, 1025, 2065, 1006, 1058, 8873, 21928, 2015, 6013, 1125...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SeleniumHQ/selenium
third_party/closure/goog/base.js
addNewerLanguageTranspilationCheck
function addNewerLanguageTranspilationCheck(modeName, isSupported) { if (transpilationRequiredForAllLaterModes) { requiresTranspilation[modeName] = true; } else if (isSupported()) { requiresTranspilation[modeName] = false; } else { requiresTranspilation[modeName] = true; transpilatio...
javascript
function addNewerLanguageTranspilationCheck(modeName, isSupported) { if (transpilationRequiredForAllLaterModes) { requiresTranspilation[modeName] = true; } else if (isSupported()) { requiresTranspilation[modeName] = false; } else { requiresTranspilation[modeName] = true; transpilatio...
[ "function", "addNewerLanguageTranspilationCheck", "(", "modeName", ",", "isSupported", ")", "{", "if", "(", "transpilationRequiredForAllLaterModes", ")", "{", "requiresTranspilation", "[", "modeName", "]", "=", "true", ";", "}", "else", "if", "(", "isSupported", "("...
Adds an entry to requiresTranspliation for the given language mode. IMPORTANT: Calls must be made in order from oldest to newest language mode. @param {string} modeName @param {function(): boolean} isSupported Returns true if the JS engine supports the given mode.
[ "Adds", "an", "entry", "to", "requiresTranspliation", "for", "the", "given", "language", "mode", "." ]
38d5e4440b2c866a78a1ccb2a18d9795a1bdeafd
https://github.com/SeleniumHQ/selenium/blob/38d5e4440b2c866a78a1ccb2a18d9795a1bdeafd/third_party/closure/goog/base.js#L2853-L2862
train
Add newer language transpilation check
[ 30522, 3853, 5587, 2638, 13777, 25023, 6692, 18150, 5521, 13102, 29545, 5403, 3600, 1006, 5549, 18442, 1010, 26354, 6279, 6442, 2098, 1007, 1063, 2065, 1006, 9099, 8197, 13490, 2890, 15549, 5596, 29278, 8095, 13806, 10867, 19847, 1007, 1063, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.commons/src/sap/ui/commons/FormattedTextView.js
function (tagName, attribs) { var intPattern = /^[0-9]*$/; for (var i = 0; i < attribs.length; i += 2) { // attribs[i] is the name of the tag's attribute. // attribs[i+1] is its corresponding value. // (i.e. <span class="foo"> -> attribs[i] = "class" | attribs[i+1] = // "foo") var sAttribKey...
javascript
function (tagName, attribs) { var intPattern = /^[0-9]*$/; for (var i = 0; i < attribs.length; i += 2) { // attribs[i] is the name of the tag's attribute. // attribs[i+1] is its corresponding value. // (i.e. <span class="foo"> -> attribs[i] = "class" | attribs[i+1] = // "foo") var sAttribKey...
[ "function", "(", "tagName", ",", "attribs", ")", "{", "var", "intPattern", "=", "/", "^[0-9]*$", "/", ";", "for", "(", "var", "i", "=", "0", ";", "i", "<", "attribs", ".", "length", ";", "i", "+=", "2", ")", "{", "// attribs[i] is the name of the tag's...
Sanitizes attributes on an HTML tag. @param {string} tagName An HTML tag name in lowercase @param {array} attribs An array of alternating names and values @return {array} The sanitized attributes as a list of alternating names and values. Null value means to omit the attribute @private
[ "Sanitizes", "attributes", "on", "an", "HTML", "tag", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.commons/src/sap/ui/commons/FormattedTextView.js#L159-L186
train
This function is called by the renderer to add an attribute to a tag.
[ 30522, 3853, 1006, 6415, 18442, 1010, 2012, 18886, 5910, 1007, 1063, 13075, 20014, 4502, 12079, 2078, 1027, 1013, 1034, 1031, 1014, 1011, 1023, 1033, 1008, 1002, 1013, 1025, 2005, 1006, 13075, 1045, 1027, 1014, 1025, 1045, 1026, 2012, 18886...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
chartjs/Chart.js
src/scales/scale.radialLinear.js
function(largestPossibleRadius, furthestLimits, furthestAngles) { var me = this; var radiusReductionLeft = furthestLimits.l / Math.sin(furthestAngles.l); var radiusReductionRight = Math.max(furthestLimits.r - me.width, 0) / Math.sin(furthestAngles.r); var radiusReductionTop = -furthestLimits.t / Math.cos(furthe...
javascript
function(largestPossibleRadius, furthestLimits, furthestAngles) { var me = this; var radiusReductionLeft = furthestLimits.l / Math.sin(furthestAngles.l); var radiusReductionRight = Math.max(furthestLimits.r - me.width, 0) / Math.sin(furthestAngles.r); var radiusReductionTop = -furthestLimits.t / Math.cos(furthe...
[ "function", "(", "largestPossibleRadius", ",", "furthestLimits", ",", "furthestAngles", ")", "{", "var", "me", "=", "this", ";", "var", "radiusReductionLeft", "=", "furthestLimits", ".", "l", "/", "Math", ".", "sin", "(", "furthestAngles", ".", "l", ")", ";"...
Set radius reductions and determine new radius and center point @private
[ "Set", "radius", "reductions", "and", "determine", "new", "radius", "and", "center", "point" ]
f093c36574d290330ed623e60fbd070421c730d5
https://github.com/chartjs/Chart.js/blob/f093c36574d290330ed623e60fbd070421c730d5/src/scales/scale.radialLinear.js#L396-L412
train
Calculates the largest possible radius of the rectangle
[ 30522, 3853, 1006, 2922, 6873, 18719, 16213, 17190, 2271, 1010, 6519, 20515, 17960, 12762, 1010, 6519, 20515, 5654, 4244, 1007, 1063, 13075, 2033, 1027, 2023, 1025, 13075, 12177, 5596, 14194, 3508, 2571, 6199, 1027, 6519, 20515, 17960, 12762,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/core/routing/Router.js
function (sHash) { return Object.keys(this._oRoutes).some(function(sRouteName) { return this._oRoutes[sRouteName].match(sHash); }.bind(this)); }
javascript
function (sHash) { return Object.keys(this._oRoutes).some(function(sRouteName) { return this._oRoutes[sRouteName].match(sHash); }.bind(this)); }
[ "function", "(", "sHash", ")", "{", "return", "Object", ".", "keys", "(", "this", ".", "_oRoutes", ")", ".", "some", "(", "function", "(", "sRouteName", ")", "{", "return", "this", ".", "_oRoutes", "[", "sRouteName", "]", ".", "match", "(", "sHash", ...
Returns whether the given hash can be matched by any one of the Route in the Router. @param {string} hash which will be tested by the Router @return {boolean} whether the hash can be matched @public @since 1.58.0
[ "Returns", "whether", "the", "given", "hash", "can", "be", "matched", "by", "any", "one", "of", "the", "Route", "in", "the", "Router", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/core/routing/Router.js#L535-L539
train
Returns true if the route hash matches the hash
[ 30522, 3853, 1006, 21146, 4095, 1007, 1063, 2709, 4874, 1012, 6309, 1006, 2023, 1012, 1035, 20298, 10421, 2015, 1007, 1012, 2070, 1006, 3853, 1006, 5034, 5833, 8189, 4168, 1007, 1063, 2709, 2023, 1012, 1035, 20298, 10421, 2015, 1031, 5034, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.fl/src/sap/ui/fl/support/apps/contentbrowser/controller/LayerContentMaster.controller.js
function (oPage, oData) { var oContentModel = this.getView().getModel("content"); oContentModel.setData(oData); oPage.setBusy(false); this.filterListByQuery(""); this.byId("search").setValue(""); }
javascript
function (oPage, oData) { var oContentModel = this.getView().getModel("content"); oContentModel.setData(oData); oPage.setBusy(false); this.filterListByQuery(""); this.byId("search").setValue(""); }
[ "function", "(", "oPage", ",", "oData", ")", "{", "var", "oContentModel", "=", "this", ".", "getView", "(", ")", ".", "getModel", "(", "\"content\"", ")", ";", "oContentModel", ".", "setData", "(", "oData", ")", ";", "oPage", ".", "setBusy", "(", "fals...
Handler if content data was received; Sets the received data to the current content model. @param {Object} oPage @param {Object} oData - data which is received from <code>LRepConnector</code> "getContent" promise @private
[ "Handler", "if", "content", "data", "was", "received", ";", "Sets", "the", "received", "data", "to", "the", "current", "content", "model", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.fl/src/sap/ui/fl/support/apps/contentbrowser/controller/LayerContentMaster.controller.js#L72-L78
train
Sets the data of the content model and sets busy flag
[ 30522, 3853, 1006, 6728, 4270, 1010, 1051, 2850, 2696, 1007, 1063, 13075, 1051, 8663, 6528, 21246, 10244, 2140, 1027, 2023, 1012, 2131, 8584, 1006, 1007, 1012, 2131, 5302, 9247, 1006, 1000, 4180, 1000, 1007, 1025, 1051, 8663, 6528, 21246, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
sass/node-sass
lib/extensions.js
getBinaryUrl
function getBinaryUrl() { var site = getArgument('--sass-binary-site') || process.env.SASS_BINARY_SITE || process.env.npm_config_sass_binary_site || (pkg.nodeSassConfig && pkg.nodeSassConfig.binarySite) || 'https://github.com/sass/node-sass/releases/download'; r...
javascript
function getBinaryUrl() { var site = getArgument('--sass-binary-site') || process.env.SASS_BINARY_SITE || process.env.npm_config_sass_binary_site || (pkg.nodeSassConfig && pkg.nodeSassConfig.binarySite) || 'https://github.com/sass/node-sass/releases/download'; r...
[ "function", "getBinaryUrl", "(", ")", "{", "var", "site", "=", "getArgument", "(", "'--sass-binary-site'", ")", "||", "process", ".", "env", ".", "SASS_BINARY_SITE", "||", "process", ".", "env", ".", "npm_config_sass_binary_site", "||", "(", "pkg", ".", "nodeS...
Determine the URL to fetch binary file from. By default fetch from the node-sass distribution site on GitHub. The default URL can be overriden using the environment variable SASS_BINARY_SITE, .npmrc variable sass_binary_site or or a command line option --sass-binary-site: node scripts/install.js --sass-binary-site ht...
[ "Determine", "the", "URL", "to", "fetch", "binary", "file", "from", ".", "By", "default", "fetch", "from", "the", "node", "-", "sass", "distribution", "site", "on", "GitHub", "." ]
0c1a49eefa37544d16041c5fe5b2e3d9168004b7
https://github.com/sass/node-sass/blob/0c1a49eefa37544d16041c5fe5b2e3d9168004b7/lib/extensions.js#L240-L248
train
Get binary URL
[ 30522, 3853, 2131, 21114, 2854, 3126, 2140, 1006, 1007, 1063, 13075, 2609, 1027, 2131, 2906, 22850, 4765, 1006, 1005, 1011, 1011, 21871, 2015, 1011, 12441, 1011, 2609, 1005, 1007, 1064, 1064, 2832, 1012, 4372, 2615, 1012, 21871, 2015, 1035,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/extensions/samples/BracketsConfigCentral/main.js
_createConfigViewOf
function _createConfigViewOf(file, pane) { var result = new $.Deferred(), view = pane.findViewOfFile(file.fullPath); if (view) { // existing view, then just show it pane.showView(view); result.resolve(view.getFile()); } else { Document...
javascript
function _createConfigViewOf(file, pane) { var result = new $.Deferred(), view = pane.findViewOfFile(file.fullPath); if (view) { // existing view, then just show it pane.showView(view); result.resolve(view.getFile()); } else { Document...
[ "function", "_createConfigViewOf", "(", "file", ",", "pane", ")", "{", "var", "result", "=", "new", "$", ".", "Deferred", "(", ")", ",", "view", "=", "pane", ".", "findViewOfFile", "(", "file", ".", "fullPath", ")", ";", "if", "(", "view", ")", "{", ...
/* Creates a view of a file (.brackets.json) @param {!File} file - the file to create a view for @param {!Pane} pane - the pane where to create the view @private
[ "/", "*", "Creates", "a", "view", "of", "a", "file", "(", ".", "brackets", ".", "json", ")" ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/extensions/samples/BracketsConfigCentral/main.js#L79-L99
train
Create a ConfigView of a file
[ 30522, 3853, 1035, 3443, 8663, 8873, 2290, 8584, 11253, 1006, 5371, 1010, 6090, 2063, 1007, 1063, 13075, 2765, 1027, 2047, 1002, 1012, 13366, 28849, 2094, 1006, 1007, 1010, 3193, 1027, 6090, 2063, 1012, 2424, 8584, 7245, 9463, 1006, 5371, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
muaz-khan/RTCMultiConnection
dev/MediaStreamRecorder.js
MediaStreamRecorder
function MediaStreamRecorder(mediaStream) { if (!mediaStream) { throw 'MediaStream is mandatory.'; } // void start(optional long timeSlice) // timestamp to fire "ondataavailable" this.start = function(timeSlice) { var Recorder; if (typeof MediaRecorder !== 'undefined') { ...
javascript
function MediaStreamRecorder(mediaStream) { if (!mediaStream) { throw 'MediaStream is mandatory.'; } // void start(optional long timeSlice) // timestamp to fire "ondataavailable" this.start = function(timeSlice) { var Recorder; if (typeof MediaRecorder !== 'undefined') { ...
[ "function", "MediaStreamRecorder", "(", "mediaStream", ")", "{", "if", "(", "!", "mediaStream", ")", "{", "throw", "'MediaStream is mandatory.'", ";", "}", "// void start(optional long timeSlice)", "// timestamp to fire \"ondataavailable\"", "this", ".", "start", "=", "fu...
______________________ MediaStreamRecorder.js
[ "______________________", "MediaStreamRecorder", ".", "js" ]
2032ce949bde30b43a3d2666e0f1e5afbf337f3d
https://github.com/muaz-khan/RTCMultiConnection/blob/2032ce949bde30b43a3d2666e0f1e5afbf337f3d/dev/MediaStreamRecorder.js#L18-L140
train
Recorder class for recording media
[ 30522, 3853, 2865, 21422, 2890, 27108, 4063, 1006, 2865, 21422, 1007, 1063, 2065, 1006, 999, 2865, 21422, 1007, 1063, 5466, 1005, 2865, 21422, 2003, 10915, 1012, 1005, 1025, 1065, 1013, 1013, 11675, 2707, 1006, 11887, 2146, 2335, 13231, 100...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
GitbookIO/gitbook
lib/modifiers/summary/unshiftArticle.js
unshiftArticle
function unshiftArticle(summary, article) { article = SummaryArticle(article); var parts = summary.getParts(); var part = parts.get(0) || SummaryPart(); var articles = part.getArticles(); articles = articles.unshift(article); part = part.set('articles', articles); parts = parts.set(0, par...
javascript
function unshiftArticle(summary, article) { article = SummaryArticle(article); var parts = summary.getParts(); var part = parts.get(0) || SummaryPart(); var articles = part.getArticles(); articles = articles.unshift(article); part = part.set('articles', articles); parts = parts.set(0, par...
[ "function", "unshiftArticle", "(", "summary", ",", "article", ")", "{", "article", "=", "SummaryArticle", "(", "article", ")", ";", "var", "parts", "=", "summary", ".", "getParts", "(", ")", ";", "var", "part", "=", "parts", ".", "get", "(", "0", ")", ...
Insert an article at the beginning of summary @param {Summary} summary @param {Article} article @return {Summary}
[ "Insert", "an", "article", "at", "the", "beginning", "of", "summary" ]
6c6ef7f4af32a2977e44dd23d3feb6ebf28970f4
https://github.com/GitbookIO/gitbook/blob/6c6ef7f4af32a2977e44dd23d3feb6ebf28970f4/lib/modifiers/summary/unshiftArticle.js#L13-L27
train
unshift an article to the beginning of summary
[ 30522, 3853, 4895, 6182, 6199, 8445, 25128, 1006, 12654, 1010, 3720, 1007, 1063, 3720, 1027, 12654, 8445, 25128, 1006, 3720, 1007, 1025, 13075, 3033, 1027, 12654, 1012, 2131, 26950, 1006, 1007, 1025, 13075, 2112, 1027, 3033, 1012, 2131, 100...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
juliangarnier/anime
lib/anime.js
anime
function anime(params) { if ( params === void 0 ) params = {}; var startTime = 0, lastTime = 0, now = 0; var children, childrenLength = 0; var resolve = null; function makePromise(instance) { var promise = window.Promise && new Promise(function (_resolve) { return resolve = _resolve; }); instance.f...
javascript
function anime(params) { if ( params === void 0 ) params = {}; var startTime = 0, lastTime = 0, now = 0; var children, childrenLength = 0; var resolve = null; function makePromise(instance) { var promise = window.Promise && new Promise(function (_resolve) { return resolve = _resolve; }); instance.f...
[ "function", "anime", "(", "params", ")", "{", "if", "(", "params", "===", "void", "0", ")", "params", "=", "{", "}", ";", "var", "startTime", "=", "0", ",", "lastTime", "=", "0", ",", "now", "=", "0", ";", "var", "children", ",", "childrenLength", ...
Public Instance
[ "Public", "Instance" ]
875a3d6745d4bff2e4c6ffe0e2d24aac3bf8a45a
https://github.com/juliangarnier/anime/blob/875a3d6745d4bff2e4c6ffe0e2d24aac3bf8a45a/lib/anime.js#L925-L1168
train
Anime function
[ 30522, 3853, 8750, 1006, 11498, 5244, 1007, 1063, 2065, 1006, 11498, 5244, 1027, 1027, 1027, 11675, 1014, 1007, 11498, 5244, 1027, 1063, 1065, 1025, 13075, 2707, 7292, 1027, 1014, 1010, 2197, 7292, 1027, 1014, 1010, 2085, 1027, 1014, 1025, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
angular/angular
tools/gulp-tasks/cldr/extract.js
getPluralFunction
function getPluralFunction(locale) { let fn = cldr.extractPluralRuleFunction(locale).toString(); if (fn === EMPTY_RULE) { fn = DEFAULT_RULE; } fn = fn .replace( toRegExp('function anonymous(n\n/*``*/) {\n'), 'function plural(n: number): number {\n ') .replace(toRegExp('var'), 'let') ...
javascript
function getPluralFunction(locale) { let fn = cldr.extractPluralRuleFunction(locale).toString(); if (fn === EMPTY_RULE) { fn = DEFAULT_RULE; } fn = fn .replace( toRegExp('function anonymous(n\n/*``*/) {\n'), 'function plural(n: number): number {\n ') .replace(toRegExp('var'), 'let') ...
[ "function", "getPluralFunction", "(", "locale", ")", "{", "let", "fn", "=", "cldr", ".", "extractPluralRuleFunction", "(", "locale", ")", ".", "toString", "(", ")", ";", "if", "(", "fn", "===", "EMPTY_RULE", ")", "{", "fn", "=", "DEFAULT_RULE", ";", "}",...
Returns the plural function for a locale todo(ocombe): replace "cldr" extractPluralRuleFunction with our own extraction using "CldrJS" because the 2 libs can become out of sync if they use different versions of the cldr database
[ "Returns", "the", "plural", "function", "for", "a", "locale", "todo", "(", "ocombe", ")", ":", "replace", "cldr", "extractPluralRuleFunction", "with", "our", "own", "extraction", "using", "CldrJS", "because", "the", "2", "libs", "can", "become", "out", "of", ...
c016e2c4ecf7529f08fae4ca0f5c8b0170c6b51c
https://github.com/angular/angular/blob/c016e2c4ecf7529f08fae4ca0f5c8b0170c6b51c/tools/gulp-tasks/cldr/extract.js#L510-L534
train
Returns the plural function for the given locale
[ 30522, 3853, 2131, 24759, 11137, 11263, 27989, 1006, 2334, 2063, 1007, 1063, 2292, 1042, 2078, 1027, 18856, 13626, 1012, 14817, 24759, 11137, 6820, 2571, 11263, 27989, 1006, 2334, 2063, 1007, 1012, 2000, 3367, 4892, 1006, 1007, 1025, 2065, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
aws/aws-sdk-js
lib/services/s3.js
getSignedUrl
function getSignedUrl(operation, params, callback) { params = AWS.util.copy(params || {}); var expires = params.Expires || 900; delete params.Expires; // we can't validate this var request = this.makeRequest(operation, params); if (callback) { AWS.util.defer(function() { request.presi...
javascript
function getSignedUrl(operation, params, callback) { params = AWS.util.copy(params || {}); var expires = params.Expires || 900; delete params.Expires; // we can't validate this var request = this.makeRequest(operation, params); if (callback) { AWS.util.defer(function() { request.presi...
[ "function", "getSignedUrl", "(", "operation", ",", "params", ",", "callback", ")", "{", "params", "=", "AWS", ".", "util", ".", "copy", "(", "params", "||", "{", "}", ")", ";", "var", "expires", "=", "params", ".", "Expires", "||", "900", ";", "delet...
Get a pre-signed URL for a given operation name. @note You must ensure that you have static or previously resolved credentials if you call this method synchronously (with no callback), otherwise it may not properly sign the request. If you cannot guarantee this (you are using an asynchronous credential provider, i.e.,...
[ "Get", "a", "pre", "-", "signed", "URL", "for", "a", "given", "operation", "name", "." ]
c23e5f0edd150f8885267e5f7c8a564f8e6e8562
https://github.com/aws/aws-sdk-js/blob/c23e5f0edd150f8885267e5f7c8a564f8e6e8562/lib/services/s3.js#L785-L798
train
Get the signed URL for the specified resource
[ 30522, 3853, 4152, 23773, 2098, 3126, 2140, 1006, 3169, 1010, 11498, 5244, 1010, 2655, 5963, 1007, 1063, 11498, 5244, 1027, 22091, 2015, 1012, 21183, 4014, 1012, 6100, 1006, 11498, 5244, 1064, 1064, 1063, 1065, 1007, 1025, 13075, 4654, 2078...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/model/odata/v4/_AnnotationHelperExpression.js
function (oPathValue) { var oModel = oPathValue.model, oPromise; Basics.expectType(oPathValue, "string"); oPromise = oModel.fetchObject(oPathValue.path + "/$"); if (oPromise.isPending() && !oPathValue.$$valueAsPromise) { oPromise.caught(); oPromise = SyncPromise.resolve(); } return oProm...
javascript
function (oPathValue) { var oModel = oPathValue.model, oPromise; Basics.expectType(oPathValue, "string"); oPromise = oModel.fetchObject(oPathValue.path + "/$"); if (oPromise.isPending() && !oPathValue.$$valueAsPromise) { oPromise.caught(); oPromise = SyncPromise.resolve(); } return oProm...
[ "function", "(", "oPathValue", ")", "{", "var", "oModel", "=", "oPathValue", ".", "model", ",", "oPromise", ";", "Basics", ".", "expectType", "(", "oPathValue", ",", "\"string\"", ")", ";", "oPromise", "=", "oModel", ".", "fetchObject", "(", "oPathValue", ...
Handling of "14.5.12 Expression edm:Path" and "14.5.13 Expression edm:PropertyPath". If <code>oPathValue.path</code> references a property which has an <code>Org.OData.Measures.V1.ISOCurrency</code> annotation, a composite result object for a <code>sap.ui.model.odata.type.Currency</code> type with the currency, the cur...
[ "Handling", "of", "14", ".", "5", ".", "12", "Expression", "edm", ":", "Path", "and", "14", ".", "5", ".", "13", "Expression", "edm", ":", "PropertyPath", ".", "If", "<code", ">", "oPathValue", ".", "path<", "/", "code", ">", "references", "a", "prop...
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/model/odata/v4/_AnnotationHelperExpression.js#L720-L748
train
Returns a promise that resolves to the property
[ 30522, 3853, 1006, 6728, 8988, 10175, 5657, 1007, 1063, 13075, 18168, 10244, 2140, 1027, 6728, 8988, 10175, 5657, 1012, 2944, 1010, 6728, 21716, 5562, 1025, 24078, 1012, 5987, 13874, 1006, 6728, 8988, 10175, 5657, 1010, 1000, 5164, 1000, 10...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...