query
stringlengths
9
14.6k
document
stringlengths
8
5.39M
metadata
dict
negatives
listlengths
0
30
negative_scores
listlengths
0
30
document_score
stringlengths
5
10
document_rank
stringclasses
2 values
set the default appearance of the scene
setDefaultAppearance() { this.setAmbient(0.2, 0.4, 0.8, 1.0); this.setDiffuse(0.2, 0.4, 0.8, 1.0); this.setSpecular(0.2, 0.4, 0.8, 1.0); this.setShininess(10.0); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setThemeDefaults() {\n // Initialize all the sliders, buttons and color fields in the selectBlock blocks\n if (!viewer.atomizer.theme) return;\n for (var controlId in viewer.atomizer.theme.settings) {\n var control = viewer.atomizer.theme.settings[controlId];\n var id = contro...
[ "0.64274883", "0.63662785", "0.6187514", "0.61667156", "0.61621004", "0.61621004", "0.60307026", "0.59806633", "0.5974549", "0.59059274", "0.58521754", "0.58322805", "0.58078575", "0.57999104", "0.5730954", "0.57287276", "0.57111347", "0.5681733", "0.5681733", "0.5664417", "0...
0.7750094
0
Comparison operator test. The value of the argument passed should be 5.
function testCmp(v5) { var v6 = v5 + 1; if (v5 !== v5) return 1; if (v5 !== 5) return 2; if (v6 === v5) return 3; if (v5 != v5) return 4; if (v5 != 5) return 5; if (v6 == v5) return 6; if (v6 < 5) return 7; if (v5 < 5) ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function testEqual(val) {\n if (val === 7) {//aici operator egal\n return \"Equal\";\n\n }\n return \"Not equal\";\n}", "function isFive(input) {\n if(input === 5){\n return true;\n }\n}", "function equalToNumberFive(num) {\n if (num === '5') {\n return true;\n } else ...
[ "0.66023636", "0.6221857", "0.59838074", "0.5961567", "0.5883018", "0.585547", "0.58081394", "0.580583", "0.57757723", "0.577291", "0.5766053", "0.573992", "0.5725745", "0.5721766", "0.57171565", "0.57130075", "0.56944835", "0.56900215", "0.5684334", "0.5681332", "0.5679752",...
0.6331966
1
Calculates and returns the weighted grade
function weighted() { var total = 0; var weightTotal = 0; // Get the total weight first for (var i=0; i < weights.length; i++) { if (weights[i].value == ''){ return "Error: Empty field."; } var weight = parseFloat(weights[i].value); if (weight < 0){ return "Error: Cannot have a negat...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function calcGrad(grade, weight) {\n let num = (grade / 100) * weight;\n return Math.round((num + Number.EPSILON) * 100) / 100;\n}", "function calcWeightedAvg(assignments){\n \tvar numAssignments = assignments.length;\n\t\tvar totalEarnedPoints = 0.0;\n\t\tvar totalPossiblePoints = 0.0;\n \tvar finalGrad...
[ "0.7604061", "0.73870796", "0.73344946", "0.69952273", "0.69339746", "0.685241", "0.6809321", "0.65278774", "0.6369219", "0.6285375", "0.62748307", "0.6272916", "0.6265204", "0.6253398", "0.62382597", "0.6233383", "0.62275785", "0.6223362", "0.6206763", "0.6198042", "0.619257...
0.74388885
1
Clears all text fields, percents, and result
function clearAll() { document.getElementById("result").innerHTML = '&nbsp' ; for (var i=0; i < numerators.length; i++) { numerators[i].value = ''; } for (var i=0; i < denominators.length; i++) { denominators[i].value = ''; } for (var i=0; i < weights.length; i++) { weights[i].value = ''; } ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function allClear() {\n $operand1Decimal.val('');\n $operand1Binary.val('');\n $operand1System.val('');\n $operand2Decimal.val('');\n $operand2Binary.val('');\n $operand2System.val('');\n $resultDecimal.val('');\n $resultBinary...
[ "0.7646538", "0.74609447", "0.7435603", "0.74322844", "0.7393528", "0.73934674", "0.73763853", "0.7371137", "0.73657143", "0.7331113", "0.73048955", "0.7264303", "0.7257492", "0.7231469", "0.7212527", "0.72119427", "0.72109896", "0.7197334", "0.71952856", "0.7188494", "0.7184...
0.8078534
0
Toggle numeric field validation to allow a wildcard for 'Like' and whitespace/commas for 'In'.
function updateNumericValidation() { var operator = getSelectedOperator(); var attribute = getSelectedAttribute(); if (operator.value === 'Like') { // Allow use of wildcards (*) with Like operator. fields.numericField.validation = a...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function onlyNumberValidate(input) {\n\tfunction setInputFilter(textbox, inputFilter) {\n\t [\"input\", \"keydown\", \"keyup\", \"mousedown\", \"mouseup\", \"select\", \"contextmenu\", \"drop\"].forEach(function(event) {\n\t textbox.addEventListener(event, function() {\n\t if (inputFilter(this.value)) {\n...
[ "0.6917604", "0.6353939", "0.6338073", "0.63350576", "0.62551934", "0.61103415", "0.6058067", "0.6055068", "0.60320604", "0.60238826", "0.60135657", "0.60050476", "0.60026425", "0.59887487", "0.59695446", "0.59662527", "0.5965181", "0.5961843", "0.59566075", "0.59536403", "0....
0.706017
0
If the cwlUrl prop was set, send a request for the CWL object, and set it to the internal state
mounted() { if (this.cwlUrl) { fetch(this.cwlUrl, { headers: new Headers({ 'Accept': 'application/json' }) }).then(response => { return response.json(); }).then(json => { this.cwlState = json;...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "cwl() {\n this.cwlState = this.cwl;\n }", "setUrl(url) {\n assert(/^https?:\\/\\//.test(url));\n\n if (url != this.url_) {\n // Clear the internal state and start with a new URL.\n this.clearInternalState();\n this.url_ = url;\n this.loadWithFallbackTimer();\n } els...
[ "0.5891961", "0.53478575", "0.5165471", "0.51507646", "0.5050157", "0.5017151", "0.5017151", "0.49764767", "0.4968344", "0.48951155", "0.48763496", "0.4869448", "0.48072806", "0.4800935", "0.4800935", "0.47978404", "0.47853547", "0.47758314", "0.47758314", "0.47758314", "0.47...
0.5721391
1
Initialise the buffer with the constant
function initBuffer(){ buffer = Buffer.from([255, 255, 255, 255]); skipBytes(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "SetBuffer() {}", "constructor(buffer) {\n if (typeof buffer === 'number') {\n this.buf = [];\n for (let i=0; i<buffer; i++) {\n this.buf.push(null);\n }\n } else {\n this.buf = buffer;\n }\n this.i = 0;\n }", "prepareBuff...
[ "0.6986903", "0.65515417", "0.62910724", "0.61663675", "0.6142083", "0.6125853", "0.59950835", "0.58858", "0.586595", "0.5850839", "0.5850839", "0.5850839", "0.5850839", "0.5850839", "0.5850839", "0.5850839", "0.5850839", "0.5850839", "0.5850839", "0.5850839", "0.58443636", ...
0.7606903
0
A buffer that accepts objects fed in via calls to its push() method. The buffer stores the object and calls a provided addFunction, storing up to maxBufferSize objects. When objects have to be removed from the buffer to make room for more, it will remove the oldest objects and call the 'remove' function with the remove...
function CircularBuffer(addFunction, removeFunction, maxBufferSize) { this._addFunction = addFunction; this._removeFunction = removeFunction; this.indexFn = function(buf, startIndex, size, count, index) { if (size == 0) return -1; var i = startIndex + index - buf[startIndex][id]; i...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "add(val){\n this.buffer.push(val);\n this.buffer = this.buffer.slice(-this.size);\n }", "function addToRollingBuffer1(buffer, maxBufferSize, newElement) {\n buffer.push(newElement);\n if (buffer.length > maxBufferSize) {\n buffer.shift();\n }\n return buffer;\n }", "function addToRolli...
[ "0.66525805", "0.6527709", "0.6440638", "0.6154817", "0.6150945", "0.5941051", "0.5878921", "0.5704923", "0.56544536", "0.55831736", "0.5538887", "0.5530033", "0.5521914", "0.5419156", "0.5407506", "0.5370065", "0.53259695", "0.5278693", "0.52232504", "0.52106524", "0.5209893...
0.677194
0
parseGently function dumps undesirable exceptions to RqlQuery().error
parseGently () { var terms; try { terms = this.parse.apply(this, arguments); } catch (err) { terms = new RqlQuery(); terms.error = err.message; } return terms; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "error(e_parse) {\n\t\t\t\tfk_syntax(e_parse);\n\t\t\t}", "function error(resp) {\n // try to 'parse' whatever user entered\n (0, _util.cl)(['error', resp]);\n ws.sendwait('parse \"' + qesc(resp[1]) + '\"', function (result) {\n console.log('error parse');\n oq({ error: resp[0], line: resp[1], ...
[ "0.61985093", "0.5846136", "0.5720021", "0.56577134", "0.5656763", "0.5545637", "0.55359435", "0.55296195", "0.5515307", "0.5515307", "0.5515307", "0.5515307", "0.5515307", "0.5515307", "0.5501651", "0.54794616", "0.54669815", "0.542283", "0.54127055", "0.5369217", "0.5369217...
0.58469135
1
stringToValue function converts string representations of things into values of the proper data type
stringToValue (str, parameters) { var converter = this.converters['default']; if (str.charAt(0) === "$") { var param_index = parseInt(str.substring(1)) - 1; return param_index >= 0 && parameters ? parameters[param_index] : undefined; } if (str.indexOf(":") > -1) {...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "ConvertDataToType(inputString, type) {}", "function castString(value) {\n if (typeof value === \"string\") {\n return value;\n } else if (typeof value === \"number\") {\n return \"\" + value;\n } else {\n throw new Error(\"Expected a string or number but got \" + getType(value...
[ "0.67723", "0.67595094", "0.66956604", "0.66791624", "0.65804005", "0.65804005", "0.65804005", "0.63526785", "0.63526785", "0.63526785", "0.6215643", "0.6215643", "0.6215643", "0.6178457", "0.61326665", "0.5943068", "0.592096", "0.5894518", "0.5894518", "0.5894518", "0.589451...
0.69574404
0
Renders the task infomation in a modal popup
function showTask(taskDetails) { renderTask(taskDetails.task); renderNote(taskDetails.note); $("#task-modal").modal("open"); function renderTask(task) { var title = $("#task-title")[0]; var date = $("#task-date")[0]; var text = $("#task-desc")[0]; title.innerHTML = ""; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function displayTask(subjectId, taskId) {\n fetchCertainTasks(subjectId, taskId, fillInTaskDetails);\n //Makes the modal window display\n $('#taskModal').css('display','block');\n //Fades in the greyed-out background\n $('#taskModalBG').fadeIn();\n}", "function open_calendar_done_task() {\n $(\...
[ "0.7243201", "0.6836689", "0.6762652", "0.67336214", "0.67170644", "0.67170644", "0.66642076", "0.65393025", "0.65121263", "0.63421625", "0.6293732", "0.628833", "0.62566286", "0.6242929", "0.62382925", "0.6233507", "0.6197999", "0.61829984", "0.61783665", "0.616414", "0.6157...
0.7015813
1
Generates random string from alpha array with length defined by `n`.
function randomString(n) { var randString = []; for(var i = 0; i < n; i++) { randString.push(alpha[Math.floor(Math.random() * alpha.length)]); } return randString.join(''); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function createRandStr(n) {\n var text = \"\";\n for (var i = 0; i < n; i++) {\n text += ALPHABET.charAt(Math.floor(Math.random() * ALPHABET.length));\n }\n return text;\n}", "function generateRandomString(n) { \n var chars = ['a', 'b','c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm',...
[ "0.8423629", "0.8193476", "0.81910497", "0.78021324", "0.7706029", "0.7669183", "0.7631197", "0.7555705", "0.7432719", "0.7393918", "0.7377368", "0.7305172", "0.7259176", "0.7248754", "0.71276927", "0.71103144", "0.7051681", "0.7026415", "0.6999356", "0.69970804", "0.6983834"...
0.8872852
0
inflections maintains arrays of find/replace regexp pairs Add a collection by calling inflections.addInflectionCollection('name'); this will add an inflections.name(find, replace); and an array, inflections.names; inflections has english plural and singluar pairs inflections.irregular(singular, plural); creates singula...
function Inflections (){ this.uncountables = []; collections = "plural singular".split(" "); for (var i = collections.length - 1; i >= 0; i--){ this.addInflectionCollection(collections[i]); }; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getInflections() {\n return this.inflections\n }", "function Collection () {}", "function Collection () {}", "function Collection () {}", "function Collection() {}", "function Collection() {}", "function Collection(){}", "function Collection(context) {\n\tvar that = context;\n\tthat.length ...
[ "0.6749714", "0.52073216", "0.52073216", "0.52073216", "0.5196697", "0.5196697", "0.50129", "0.49699417", "0.47922617", "0.47298226", "0.47298226", "0.47298226", "0.46858394", "0.46159488", "0.4610187", "0.4560709", "0.4525187", "0.44263595", "0.44085205", "0.44007298", "0.43...
0.7837828
0
Parse mayastor node ID in form "mayastor://nodename/host:port" and return node name and endpoint.
function parseMayastorNodeId(nodeId) { let parts = nodeId.split('/'); if ( parts.length != 4 || parts[0] !== 'mayastor:' || parts[1] !== '' || !parts[2] || !parts[3] ) { throw new GrpcError( grpc.status.INVALID_ARGUMENT, 'Invalid mayastor node ID: ' + nodeId ); } retur...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function parseMayastorNodeId (nodeId) {\n const parts = nodeId.split('/');\n\n if (\n parts.length !== 4 ||\n parts[0] !== 'mayastor:' ||\n parts[1] !== '' ||\n !parts[2] ||\n !parts[3]\n ) {\n throw new GrpcError(\n grpc.status.INVALID_ARGUMENT,\n 'Invalid mayastor node ID: ' + node...
[ "0.7198895", "0.54627407", "0.5397287", "0.5277194", "0.5209412", "0.51679814", "0.51312435", "0.5074034", "0.5074034", "0.4969971", "0.4871872", "0.4862059", "0.4856451", "0.4825633", "0.47670177", "0.47637117", "0.47499487", "0.47453353", "0.47166416", "0.47118005", "0.4695...
0.71716714
1
Return true if the storage pool is accessible via gRPC
function isPoolAccessible(pool) { return pool.state == 'ONLINE' || pool.state == 'DEGRADED'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async function isAvailable() {\n try {\n // If a user is instantiating several GCP libraries at the same time,\n // this may result in multiple calls to isAvailable(), to detect the\n // runtime environment. We use the same promise for each of these calls\n // to reduce the network l...
[ "0.63679343", "0.6292739", "0.62591225", "0.58354795", "0.5704374", "0.5689772", "0.5596754", "0.55931646", "0.55834496", "0.5564977", "0.55515915", "0.5550773", "0.5550773", "0.55481994", "0.5529588", "0.5504395", "0.55016387", "0.54760504", "0.5453272", "0.5453272", "0.5446...
0.6661846
0
Cannon, a specific kind of tower
function Cannon(game, x, y) { Entity.call(this, game, x, y); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function controlCannon()\n\t{\n\t\tif(Key.isDown(Key.A))\n\t\t{\n\t\t\tcannon.rotation.y -=0.01;\n\t\t\tif(cannonBase.rotation.y < -(Math.PI /3))\n\t\t\t{\n\t\t\t\tcannonBase.rotation.y = -(Math.PI / 3);\n\t\t\t}\n\t\t}\n\t\tif(Key.isDown(Key.D))\n\t\t{\n\t\t\tcannon.rotation.y +=0.01;\n\t\t\tif(cannonBase.rotatio...
[ "0.69858277", "0.62264556", "0.5974008", "0.5878834", "0.5850308", "0.57858914", "0.57705206", "0.5686837", "0.5686837", "0.56329113", "0.54950887", "0.5492023", "0.54592824", "0.5429882", "0.5413384", "0.5396622", "0.53856397", "0.53705776", "0.5357368", "0.5348055", "0.5341...
0.6679545
1
GET_PAGE_DATA: state => state.pageData
GET_PAGE_DATA (state, pageData) { state.pageData = pageData; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "_pageData(data) {\n if (!this.paginator) {\n return data;\n }\n const startIndex = this.paginator.pageIndex * this.paginator.pageSize;\n return data.slice(startIndex, startIndex + this.paginator.pageSize);\n }", "_pageData(data) {\n if (!this.paginator) {\n ...
[ "0.74961114", "0.74961114", "0.728301", "0.7024509", "0.6913998", "0.68915486", "0.68830156", "0.6582377", "0.65169764", "0.6480819", "0.64148694", "0.6396369", "0.63498753", "0.63372576", "0.63210547", "0.6312595", "0.63060296", "0.6284494", "0.62837917", "0.6281742", "0.627...
0.88344496
0
Allows external callback functions to be called on the words as pre processors
function process_custom(words, customizers) { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "forEachWord(fn) {\n let _tokens = this._tokens;\n for(let i = 0, len = _tokens.length; i < len; i++) {\n if(_tokens[i].tokentype === \"RUS\") {\n fn.call(this, _tokens[i].token, i, _tokens);\n }\n }\n }", "function getFuncti...
[ "0.66353106", "0.5993151", "0.5970776", "0.5899199", "0.5824675", "0.5824675", "0.57814854", "0.5776255", "0.5766723", "0.5754769", "0.5712357", "0.5688103", "0.55945843", "0.5585724", "0.55832237", "0.5542181", "0.5530559", "0.5459025", "0.5449019", "0.54437417", "0.5433568"...
0.76636535
0
Asynchronously loops through the provided files and puts them through the CSSCSS tool.
function analyze(files) { /** * Loops over all the files specified in the src array. */ grunt.util.async.forEachSeries(files, function(file, next) { /** * Stores the output that is to be written to the file.dest, if one is * specified. */ ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function stylesheets(cb) {\n\n async.forEach(config.stylesheets, function (ss, callback) {\n // bench('pre stylus')\n fs.readFile(dir + '/source/resource/css/' + ss + '.styl', 'utf8', function (err, data) {\n if (err) return callback(err)\n stylus(data)\n .set('filename', dir + '/source/res...
[ "0.6701981", "0.66855186", "0.66241246", "0.65945685", "0.64734226", "0.63236576", "0.63156897", "0.6230645", "0.6227522", "0.6156544", "0.6105176", "0.61000925", "0.6086644", "0.60735387", "0.6023692", "0.6011767", "0.6002717", "0.5965265", "0.59130156", "0.59123206", "0.589...
0.70505965
0
this is used, returns the index of the Array that holds the point, p, which is an id(cursor)
getIndex(p) { let index = -1; for (var i=0; i<this.points1.length; i++) { for (var b = 0; b < this.points1[i].pois.length; b++) { if (this.points1[i].pois[b].cursor == p) { index = i } if (index != -1) break; } ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getPoint(id) {\n let indexA = this.getIndex(id);\n let index = _.findIndex(this.points1[indexA].pois, point => point.cursor == id);\n let result = index !== -1 ? this.points1[indexA].pois[index] : null;\n return result;\n }", "function getIndex(p) {\n if (!(\"index\" in p)) ...
[ "0.7366351", "0.7081636", "0.68974346", "0.6732236", "0.6556154", "0.6504327", "0.64896506", "0.6486872", "0.6471336", "0.6449049", "0.6420501", "0.6410311", "0.64048386", "0.6388974", "0.63546526", "0.6347512", "0.6265602", "0.6229613", "0.62148905", "0.62135303", "0.6206566...
0.84494567
0
this is used to return the point object based on the point id(cursor) as the points are stored in different arrays based on areas (poiType) indexA is the index of the Array once we have the array, we can serach that arry to find the location within the arayy of the point, index. as long as the id if found within the ar...
getPoint(id) { let indexA = this.getIndex(id); let index = _.findIndex(this.points1[indexA].pois, point => point.cursor == id); let result = index !== -1 ? this.points1[indexA].pois[index] : null; return result; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getAllPoints3(poiType) {\n\n if (poiType == \"all\") {\n this.pointsP = [];\n for (var c = 0; c <this.points2.length; c++) {\n this.pointsP.push(this.points2[c])\n }\n } else {\n let ind...
[ "0.6610636", "0.6179353", "0.6171061", "0.5947002", "0.5912735", "0.5894607", "0.5891805", "0.58312213", "0.5801617", "0.5748396", "0.5723676", "0.5689854", "0.56773376", "0.56467175", "0.5624613", "0.5606364", "0.5595998", "0.55841357", "0.55702806", "0.55255723", "0.5520075...
0.7567769
0
points are stored in arrays based on the gerographical areas wehen we are given the id of a point to remove, its necessay to locate the array that it is stored in. rather than having the function too big, this implementation is done through getIndex(k)
deletePoint(k) { let elements2 = {}; let index = this.getIndex(k); console.log("in del point and index of k is " +index) //for (var i = 0; i < this.points1[index].pois.length; i++) { // for (var b = 0; b < this.points1[index].length; b++) { // this.pointsP.pus...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "_removePoint(){let newIndex=this.currentIndex;this.points.splice(this.currentIndex,1);this._updateValue();this.$points.find('.point').eq(this.currentIndex).remove();if(typeof this.points[this.currentIndex]==='undefined'){newIndex=this.currentIndex-1;}this._setCurrent(newIndex);// this will call updateMarkers for t...
[ "0.640492", "0.6372959", "0.6340981", "0.61821616", "0.60127354", "0.5979624", "0.59094626", "0.59079367", "0.58438945", "0.58404994", "0.58400977", "0.58324325", "0.58257705", "0.575742", "0.57221323", "0.5717283", "0.5697325", "0.5655651", "0.5645903", "0.56428826", "0.5635...
0.64662284
0
used in index.js file, here we take in array of points, and as we go through each point in the Array, we add 2 additional properties to each point, an array to hold comments and an upvote property, with a default value of 1. pointsIn this is the json data fron the API. points array, holds all the points with additional...
initializePoints3(pointsIn) { let items = pointsIn.map((point) =>({...point,['comments']:[],['upvotes']:1})); this.points = items; //console.log("inside initilaizeP categ points"); // pointsIn.map((categ) =>( // console.log(categ.title) // )); let cat = []; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getAllPoints3(poiType) {\n\n if (poiType == \"all\") {\n this.pointsP = [];\n for (var c = 0; c <this.points2.length; c++) {\n this.pointsP.push(this.points2[c])\n }\n } else {\n let ind...
[ "0.58282846", "0.5694288", "0.55840033", "0.5560209", "0.55486214", "0.54842985", "0.5427263", "0.5412465", "0.54001516", "0.5388527", "0.5371374", "0.53706324", "0.5370503", "0.5360866", "0.53605187", "0.5353129", "0.53335786", "0.53265357", "0.53199303", "0.5308967", "0.526...
0.74041396
0
used in App.js returning an array of points based on the area selected by user (poiType)
getAllPoints3(poiType) { if (poiType == "all") { this.pointsP = []; for (var c = 0; c <this.points2.length; c++) { this.pointsP.push(this.points2[c]) } } else { let index = -1; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getPoints(){\n return Point.getByRoute(this.routeID,this.stops);\n }", "function getPOIofType(type, poiList){\n\tvar ret = [];\n\tfor (var i = 0; i < poiList.length; i++) {\n\t\tif (poiList[i].type == type){\n\t\t\tret.push(poiList[i]);\n\t\t}\n\t}\n\treturn ret;\n}", "function getPoints() {\n\n\n ...
[ "0.6353097", "0.6327714", "0.6294902", "0.62291765", "0.6119486", "0.6044688", "0.60276634", "0.59860456", "0.5945321", "0.5943193", "0.59284055", "0.5889313", "0.58699024", "0.58589625", "0.58169574", "0.5803196", "0.58013856", "0.5792423", "0.5770087", "0.5766196", "0.57290...
0.7234579
0
function for falling effect
function fallingTP (TP) { var id = setInterval(function(){ TP.y+=8 if(TP.y > 1000){ clearInterval(id) } }, 100) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function fall(){\n\tmovement[\"verticalSpeed\"] += movement[\"fallAcceleration\"];\n\ty += movement[\"verticalSpeed\"];\n\tbat.style.top = y + \"px\";\n\t\n\tif( y < 0 || y + dimension[\"batHeight\"] > dimension[\"viewHeight\"]){\n\t\tloseGame();\n\t}\n\tcheckCollisions();\n}", "function fallingSnow (i, defaultP...
[ "0.67300147", "0.6538613", "0.6516746", "0.6407193", "0.6360859", "0.6345065", "0.63259035", "0.6284927", "0.62680143", "0.61778057", "0.615922", "0.6115988", "0.59939855", "0.5991874", "0.595165", "0.5946907", "0.5920413", "0.58985645", "0.58946484", "0.5892124", "0.58801717...
0.6915529
0
function to draw many TPs
function drawAllTheTPs(){ // console.log("falling"); tpArray.forEach(function(TP){ ctx.drawImage(tpImage, TP.x, TP.y,TP.width,TP.height) }) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function drawTress() {\n \n for(var t=0; t < trees.length; t++){\n \n y = floorPos_y;\n x_pos = trees[t].x_pos;\n heightY = trees[t].heightY;\n fill(150,96,30);\n rect(x_pos,y-heightY,20,heightY);\n fill(30,180,87);\n triangle(x_pos-30,y-heightY,x_pos+10,y-2*heightY,x_pos+50,y-hei...
[ "0.7024328", "0.67149675", "0.6600316", "0.6519541", "0.64973986", "0.643063", "0.64072216", "0.63633305", "0.62755316", "0.6252901", "0.6228438", "0.62227625", "0.6180293", "0.61434984", "0.6130699", "0.61241627", "0.61149824", "0.61086076", "0.6107298", "0.6104513", "0.6103...
0.7298648
0
Extend the original method, make the tooltip's header reflect the grouped range.
function onTooltipHeaderFormatter(e) { const chart = this.chart, time = chart.time, labelConfig = e.labelConfig, series = labelConfig.series, options = series.options, tooltipOptions = series.tooltipOptions, dataGroupingOptions = options.dataGrouping, xAxis = series.xAxis; let xDateFormat = tooltipOptions.xDate...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function substitute (original)\n {\n\n if (typeof opt.object.tooltipSubstitutions !== 'function') {\n return original;\n }\n\n // Get hold of the indexes from the sequentialIndex that we have.\n //\n if (typeof opt.object.tooltipSubstitut...
[ "0.55727184", "0.54193306", "0.53912324", "0.53572744", "0.5301908", "0.52271664", "0.5150366", "0.51276994", "0.5123711", "0.5111839", "0.50960743", "0.50850123", "0.5073483", "0.50627595", "0.5054958", "0.5050153", "0.5044798", "0.50381315", "0.5035166", "0.50192744", "0.50...
0.630971
0
This is port of 'FAST Corner Detection' to JavaScript. fast9.c nonmax.c
function detect(im, width, height, threshold, nonmax) { const corners = fast9_detect(im, width, height, threshold); const scores = fast9_score(im, width, height, corners, threshold); if (nonmax) { var nonmax = nonmax_suppression(corners, scores); return nonmax; } for (let i = 0; i < corners.length; i+...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setupFastkeypointdetector(thres)\n {\n img_u8 = new jsfeat.matrix_t(width, height, jsfeat.U8_t | jsfeat.C1_t);\n\n prev_corners = corners;\n corners = [];\n var i = width*height;\n while(--i >= 0) {\n corners[i] = new jsfeat.keypoint_t(0,0,0,0);\n }\n\n threshold = thres;\n ...
[ "0.5607602", "0.5523051", "0.54998577", "0.5411233", "0.5398924", "0.53711134", "0.53671503", "0.535761", "0.53447646", "0.52646154", "0.5210026", "0.5199865", "0.5173073", "0.51727307", "0.51578224", "0.51439553", "0.5126008", "0.5124304", "0.51198226", "0.5112346", "0.51110...
0.57182336
0
Getter and Setter for Categories Length
function getCategoriesLength() { return localStorage.getItem("categoriesLength"); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getCategoryWidth() {\n let iv = this.i.getCategoryWidth();\n return (iv);\n }", "len(value) {\r\n return this.attr('length', value);\r\n }", "get dimension() { return this.length }", "get length() {\n return this.size();\n }", "get length() {\n return this.meta.size;...
[ "0.68696207", "0.6614823", "0.66049016", "0.65588045", "0.6436901", "0.6433858", "0.6427026", "0.6404683", "0.640091", "0.6377826", "0.6377826", "0.63147324", "0.6296765", "0.62859285", "0.62620395", "0.62469643", "0.62469643", "0.6203944", "0.6203944", "0.6196946", "0.611749...
0.7016064
0
Default values setter for categories
function setDefaultCategories() { if (getCategoriesLength() <= 0) { setCategoryName(0,"Film"); setCategoryName(1,"Music"); setCategoryKeywords("",""); setCategoryKeywords("Film","film, movie, hollywood, box office, action, crime, drama, romance"); setCategoryKeywords("Music",...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function handleCategoryChange(value) {\n setCategory(value);\n }", "function cambiarDefault() {\n var categoriaId = $$(this).val();\n var categorias = almacenamientoCategorias.get();\n var tipo = $$(this).parents('ul.listado').data('tipo');\n\n for (var i in categorias) {\n if(tipo == catego...
[ "0.6137806", "0.6085111", "0.605926", "0.6000763", "0.5984059", "0.5858053", "0.5831564", "0.5831564", "0.5790274", "0.578106", "0.57761395", "0.5769526", "0.57543397", "0.5735011", "0.5698873", "0.56839406", "0.56407124", "0.559286", "0.55817467", "0.5573122", "0.5529986", ...
0.6876289
0
Default implementation of logging a duration. Overrideable via the constructor because the specific format of a performance log likely differs per organization.
function defaultLogDuration(log, start, label) { log.info({duration: new Date().getTime() - start}, label); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "log() {\n logger.logInfo(this.type + \": \" + (this.id || 'unknown'));\n logger.log(\"duration: \" + this.duration)\n if (this.success) logger.logSuccess();\n else logger.logError((this.error && this.error.message) || undefined);\n }", "static formatDuration(duration) {\n if (duration < 500) {\n ...
[ "0.614236", "0.6141455", "0.59767497", "0.59512085", "0.5930938", "0.5821114", "0.57341725", "0.5724198", "0.57212764", "0.5720463", "0.5702301", "0.5702301", "0.56666654", "0.5641203", "0.55905426", "0.5523241", "0.5500649", "0.54728985", "0.5472492", "0.54713863", "0.545547...
0.6647973
0
Inserts an impulse in the wave at a specific position.
function InsertImpulse( positionX, forceY ) { var particle = particles[Math.round( positionX / WIDTH * particles.length )]; if( particle ) { particle.force.y += forceY; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function InsertImpulse( positionX, forceY ) {\n const particle = particles[Math.round( positionX / WIDTH * particles.length )];\n if (particle) {\n particle.force.y += forceY\n }\n }", "function InsertImpulse(positionX, forceY) {\n\t\tvar particle = particles[Math.round(positionX / WIDTH * particl...
[ "0.72249633", "0.7096333", "0.64184994", "0.6150182", "0.577976", "0.56171477", "0.52994835", "0.5218748", "0.5146983", "0.50813955", "0.5064494", "0.5008532", "0.5004", "0.49829108", "0.49590325", "0.4958974", "0.49532405", "0.49445096", "0.49293062", "0.4908397", "0.4906636...
0.7103471
1
Gets input and returns its absolute value
function rtAbs(input){ if(input<0){ return input * -1; } return input; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function absoluteValue() {\n \"use strict\";\n var num;\n num = window.prompt(\"Please enter any REAL number:\");\n window.console.log(Math.abs(num));\n}", "abs(x){\n x = ToNumber(x);\n\n return x === 0 ? 0 : x < 0 ? -x : x;\n }", "function abs(parms){ return Math.abs(parms) }", "function ...
[ "0.7530318", "0.6931633", "0.6914105", "0.6866174", "0.6715824", "0.6681569", "0.6631943", "0.658841", "0.657601", "0.65504783", "0.6541004", "0.6529775", "0.6509475", "0.65016097", "0.6499474", "0.6407908", "0.63786215", "0.6308745", "0.6266079", "0.6237221", "0.6155781", ...
0.7373584
1
Check superficial characteristics of functions and properties (not functionality).
function checkFunction(obj, name, nargs) { var desc = Object.getOwnPropertyDescriptor(obj, name); assertEq(desc.configurable, true, name + " should be configurable"); assertEq(desc.writable, true, name + " should be writable"); assertEq(desc.enumerable, false, name + " should be non-enumerable"); as...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function checkFunctionOverrides() {\n var whitelist = ['ModelAdapter.init', 'ModelAdapter._init', 'Calendar.init'];\n var result1 = ['Legend:', '[!] Function includes super call, and parent function uses arguments', ' ~ Function includes super call, but parent function does not use arguments', ' Function doe...
[ "0.61597925", "0.61510307", "0.6127479", "0.6123178", "0.6049906", "0.6002775", "0.5969503", "0.5826311", "0.57885176", "0.5744793", "0.5708293", "0.56638366", "0.5649346", "0.5642038", "0.56220835", "0.5620166", "0.5595872", "0.5584338", "0.55822587", "0.5558846", "0.5554548...
0.6225809
0
Create a `Fingerprint` from `HashSources` array
async function createFingerprintFromSourcesAsync(sources, projectRoot, options) { const limiter = (0, p_limit_1.default)(options.concurrentIoLimit); const fingerprintSources = await Promise.all(sources.map((source) => createFingerprintSourceAsync(source, limiter, projectRoot, options))); const hasher = (0, ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async function createFingerprintSourceAsync(source, limiter, projectRoot, options) {\n let result = null;\n switch (source.type) {\n case 'contents':\n result = await createContentsHashResultsAsync(source, options);\n break;\n case 'file':\n result = await creat...
[ "0.5719562", "0.54640853", "0.52795273", "0.5187351", "0.5179069", "0.48646757", "0.48555157", "0.48186895", "0.47629482", "0.47109255", "0.45729274", "0.4567393", "0.45504484", "0.4537181", "0.45118976", "0.44975603", "0.44768178", "0.44759098", "0.4465745", "0.44462505", "0...
0.7019237
0
Create a `FingerprintSource` from a `HashSource` This function will get a hash value and merge back to original source
async function createFingerprintSourceAsync(source, limiter, projectRoot, options) { let result = null; switch (source.type) { case 'contents': result = await createContentsHashResultsAsync(source, options); break; case 'file': result = await createFileHashRes...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function calcSourceHash(source) {\n const hash = crypto.createHash('sha1');\n\n hash.update(source);\n\n return hash.digest('hex');\n}", "makeHash(source) {\n return crypto.createHash('md5').update(JSON.stringify(source)).digest('hex')\n }", "async function createFingerprintFromSourcesAsync(source...
[ "0.6564691", "0.62923443", "0.5345719", "0.52042705", "0.51759815", "0.49550855", "0.49333915", "0.48787397", "0.48637915", "0.4854538", "0.48344728", "0.48008123", "0.47788963", "0.47538447", "0.47538447", "0.47450614", "0.47420022", "0.47419783", "0.47307706", "0.4721146", ...
0.65109706
1
Indicate the given `dirPath` should be excluded by `dirExcludes`
function isExcludedDir(dirPath, dirExcludes) { for (const exclude of dirExcludes) { if ((0, minimatch_1.default)(dirPath, exclude)) { return true; } } return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "_filterExcludeFiles (targetDir, excludeFiles = []) {\n return fs.readdirSync(targetDir).filter(file => {\n return (!excludeFiles.includes(file))\n })\n }", "_isExcludedDirectory(directory) {\n for (var i=0; i<this._folderExcludes.length; i++) {\n if (this._folderExcludes[i].test(direc...
[ "0.68327713", "0.6550053", "0.65166366", "0.6219528", "0.61133367", "0.6060013", "0.5954974", "0.58435297", "0.575281", "0.5717382", "0.56419283", "0.5499529", "0.5488121", "0.5481189", "0.54776305", "0.54776305", "0.54776305", "0.54776305", "0.54776305", "0.54776305", "0.547...
0.79989564
0
Create `HashResult` for a dir. If the dir is excluded, returns null rather than a HashResult
async function createDirHashResultsAsync(dirPath, limiter, projectRoot, options, depth = 0) { if (isExcludedDir(dirPath, options.dirExcludes)) { return null; } const dirents = (await promises_1.default.readdir(path_1.default.join(projectRoot, dirPath), { withFileTypes: true })).sort((a, b) => a.name...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function GenerateDirectoryHash(rootDir, chaincodeDir, hash) {\n var self = this;\n // Generate the project directory\n var projectDir = rootDir + \"/\" + chaincodeDir;\n // Read in the contents of the current directory\n var dirContents = fs.readdirSync(projectDir);\n var dirContentsLen = dirCont...
[ "0.57954717", "0.5157458", "0.50190437", "0.49108806", "0.48817587", "0.4738966", "0.46815467", "0.46078175", "0.45758885", "0.44957495", "0.44750983", "0.44740197", "0.44740197", "0.44740197", "0.4429552", "0.44255954", "0.44184643", "0.44123638", "0.44113627", "0.44069785", ...
0.6667428
0
Create `HashResult` for a `HashSourceContents`
async function createContentsHashResultsAsync(source, options) { const hex = (0, crypto_1.createHash)(options.hashAlgorithm).update(source.contents).digest('hex'); return { id: source.id, hex }; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "makeHash(source) {\n return crypto.createHash('md5').update(JSON.stringify(source)).digest('hex')\n }", "async function createFingerprintSourceAsync(source, limiter, projectRoot, options) {\n let result = null;\n switch (source.type) {\n case 'contents':\n result = await createContent...
[ "0.6270962", "0.5926959", "0.59084886", "0.5339334", "0.53073406", "0.5210483", "0.52006984", "0.5177815", "0.5093231", "0.508981", "0.50430477", "0.50317127", "0.5001039", "0.4993768", "0.49933055", "0.49767938", "0.49755478", "0.49574953", "0.49354184", "0.49324778", "0.492...
0.7720421
0
Create id from given source
function createSourceId(source) { switch (source.type) { case 'contents': return source.id; case 'file': return source.filePath; case 'dir': return source.filePath; default: throw new Error('Unsupported source type'); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "generateId(src) {\n return aguid_1.default(src);\n }", "getSourceId(source) {\n let sourceId = this.sourceIds.get(source);\n if (sourceId === undefined) {\n sourceId = `${this.sourceIds.size}`;\n this.sourceIds.set(source, sourceId);\n }\n return source...
[ "0.71735287", "0.70483905", "0.70483905", "0.64809656", "0.61940473", "0.61543685", "0.6141818", "0.61253965", "0.60776216", "0.6066129", "0.60633576", "0.60440284", "0.6039879", "0.60353076", "0.6035262", "0.6034669", "0.60307354", "0.6018925", "0.59813076", "0.59727067", "0...
0.8000047
0
utility function for making sure the last window in the history queue is open and visible
function makeSureLatestWindowIsOpen() { var toOpen = parseInt(history[history.length-1]); // have we created our new window yet? if (windows[toOpen].neverBeenOpened) { windows[toOpen].open(); windows[toOpen].neverBeenOpened = false; } else { // it's already been c...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function makeSureLatestWindowIsOpen() {\nvar toOpen = parseInt(history[history.length-1]);\n// have we created our new window yet?\nif (windows[toOpen].neverBeenOpened) {\n\twindows[toOpen].open({animated:true});\n\twindows[toOpen].neverBeenOpened = false;\n} else { // it's already been created, and hidden. show i...
[ "0.7585048", "0.66169375", "0.622546", "0.6218081", "0.6158302", "0.6084021", "0.6071487", "0.60379744", "0.5982691", "0.5975674", "0.59697235", "0.5960641", "0.59238875", "0.5835319", "0.57953715", "0.57924813", "0.57900774", "0.57777077", "0.574147", "0.574147", "0.574147",...
0.75521195
1
Change the content of a page
function changeContent(page) { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "setPageContent(htmlContent){\r\n document.getElementById(\"content\").innerHTML = htmlContent;\r\n }", "function setPage (page) {\n browserWindow.webContents.send('change', { page })\n}", "function doChange(newPage) {\n $(\"body\").pagecontainer(\"change\", newPage, {transition: \"slide\"});\n ...
[ "0.7118645", "0.67718023", "0.67490864", "0.6716156", "0.6650642", "0.6639319", "0.6521501", "0.65038323", "0.64861625", "0.6477797", "0.6472775", "0.6440625", "0.6417389", "0.6396811", "0.6390152", "0.6383662", "0.63787436", "0.63744086", "0.63676393", "0.636737", "0.6354344...
0.85088056
0
returns an array with 12 randomly selected animal icon paths
function selectRandomIcons() { var iconPathsArray = []; for (var i = 1; i < 25; i++) { iconPathsArray.push("../assets/icons/" + i + ".png"); } Helpers.shuffleArray(iconPathsArray); return iconPathsArray.slice(0, 12); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getRandomIconPathCollection() {\n var randomIcons = selectRandomIcons();\n var randomIconCollection = randomIcons.concat(randomIcons);\n Helpers.shuffleArray(randomIconCollection);\n return randomIconCollection;\n}", "function getRandomIcons() {\n let icons = [];\n\n switch (Math.floor...
[ "0.7767848", "0.71335113", "0.7037373", "0.6772046", "0.6488093", "0.6450469", "0.6417396", "0.64061564", "0.63061625", "0.62980485", "0.6270612", "0.6213009", "0.61770755", "0.61630774", "0.61591786", "0.6137212", "0.61048657", "0.60987383", "0.60917324", "0.6091532", "0.607...
0.8105046
0
returns an array with 12 pairs of animal icon paths randomly placed in the array
function getRandomIconPathCollection() { var randomIcons = selectRandomIcons(); var randomIconCollection = randomIcons.concat(randomIcons); Helpers.shuffleArray(randomIconCollection); return randomIconCollection; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function selectRandomIcons() {\n var iconPathsArray = [];\n for (var i = 1; i < 25; i++) {\n iconPathsArray.push(\"../assets/icons/\" + i + \".png\");\n }\n\n Helpers.shuffleArray(iconPathsArray);\n return iconPathsArray.slice(0, 12);\n}", "function chooseIcons() {\r\n var icons = new Ar...
[ "0.743744", "0.7060333", "0.69477475", "0.6656906", "0.664881", "0.6415647", "0.6343549", "0.63306373", "0.63056695", "0.6180298", "0.6152957", "0.61502", "0.61252624", "0.61206424", "0.6105867", "0.61042315", "0.60931456", "0.60519135", "0.60360765", "0.59696674", "0.5954811...
0.7440103
0
query_pair :: [String, String] > String
function query_pair(pair) { return (0, _query_escape2.default)(pair[0]) + '=' + (0, _query_escape2.default)(pair[1]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function toQueryPair(key, value) {\n\n if (value !== undefined) {\n\n value = core.stringInterpret(value).replace(/(\\r)?\\n/g, \"\\r\\n\");\n value = window.encodeURIComponent(value).replace(/%20/g, \"+\");\n\n key += \"=\" + value;\n\n }\n\n return key;\n\n ...
[ "0.6270055", "0.59034175", "0.5846553", "0.57575285", "0.56739396", "0.5668378", "0.5608001", "0.5508114", "0.547085", "0.54454184", "0.5418541", "0.5416136", "0.53949106", "0.53503674", "0.5309312", "0.5276164", "0.52670866", "0.5234962", "0.52109444", "0.5208505", "0.520378...
0.7722548
0
scheduling scheduled action (action, nextUtcMilliseconds, endUtcMilliseconds, intervalMilliseconds)
function scheduleAction(action, startMilliseconds) { var scheduledAction = new Object(); scheduledAction.action = action; scheduledAction.nextUtcMilliseconds = new Date().getTime() + startMilliseconds; scheduledAction.intervalMilliseconds = null; scheduledAction.endUtcMilliseconds = null; addAct...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function schedular(params) {\r\n let morning_vote = schedule.scheduleJob({\r\n hour: 10,\r\n minute: 00\r\n }, () => {\r\n console.log(`Morning Vote`, true);\r\n start_iteration();\r\n setTimeout(() => {\r\n console.log(`Morning Claim`, true);\r\n clai...
[ "0.62039", "0.58008707", "0.5765255", "0.5723969", "0.56580114", "0.5539045", "0.55108047", "0.5457251", "0.5451583", "0.5438744", "0.5434205", "0.5433509", "0.5372589", "0.5370357", "0.5320767", "0.52572525", "0.5240537", "0.5179515", "0.51468575", "0.5142073", "0.51327705",...
0.7355705
0
Get all the CSS on the page
function getStyleSheets() { var metas = document.getElementsByTagName('link'); var stylesheets = ''; for (i=0; i<metas.length; i++) { if (metas[i].getAttribute("rel") == "stylesheet") { stylesheets += '<link rel="stylesheet" href="'+metas[i].getAttribute("href")+'">'; } ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getCSS(csfiles){\n $.each(csfiles, function(i, val){\n $('<link>').attr({\n href: val,\n rel: 'stylesheet'\n }).appendTo('head');\n });\n }", "function getCss(url) {\n return document.querySelector(\"link[href*=\\\"\" + ...
[ "0.7335855", "0.7212722", "0.7169961", "0.7061428", "0.7058925", "0.69810736", "0.671866", "0.6555473", "0.6457853", "0.63898855", "0.63764966", "0.63482416", "0.6346604", "0.6345896", "0.62813234", "0.62478507", "0.6224654", "0.6222449", "0.62212634", "0.62212634", "0.621731...
0.7246916
1
Complete a function that takes in two parameters, an object, and a string (which will represent a key). Your function should remove (delete) the property located at the inputted key. Your function should then return the inputted object.
function removeProperty(obj, key) { // your code here delete obj[key]; return obj; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function myProp(object, key) {\n delete object[key]\n return object\n}", "function destructivelyDeleteFromObjectByKey(object, key) {\n object.key='1';\n delete object[key];\n return object; \n}", "function destructivelyDeleteFromObjectByKey(object, key) {\n \n delete object[key];\n return object;\...
[ "0.7911788", "0.7501027", "0.7466372", "0.7450248", "0.74121624", "0.7396708", "0.7204476", "0.7122961", "0.70944506", "0.708455", "0.70555025", "0.69928837", "0.6986028", "0.6972416", "0.6924271", "0.6917129", "0.682877", "0.6803834", "0.6774888", "0.67535806", "0.67376447",...
0.82994705
0
Binary search a sorted array Input: sortedObject: object to serach (sorted descending) key: lookup key (property withing an object) lookup_value: value we are looking for Output 1 if key:lookup_value when there is no match index of key:lookup_value when a match is found
function binarySearch(sortedObject, key, lookup_value){ var start = 0; var end = sortedObject.length -1; // lookup_value = parseInt(lookup_value); // console.log('seraching for',key, lookup_value ); while (start <= end){ var mid = Math.floor((start + end)/2); ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function binarySearch(array, value, keySelector, keyComparer, offset) {\n if (!array || array.length === 0) {\n return -1;\n }\n var low = offset || 0;\n var high = array.length - 1;\n var key = keySelector(value);\n while (low <= hig...
[ "0.6987196", "0.6955362", "0.67008924", "0.6533705", "0.6531997", "0.65134627", "0.64675176", "0.6423175", "0.6378475", "0.6374004", "0.63421607", "0.63421607", "0.63421607", "0.63421607", "0.63421607", "0.6294894", "0.6292982", "0.6289502", "0.6289502", "0.6288572", "0.62820...
0.8133316
0
BEGIN FREEWHEEL CORE FUNCTIONS Setting the main video src when the ad is complete:
function adComplete(event){ console.log("adComplete()"); model.data.isFreewheelAdPlaying = false; // Resets the flag. playVideo(model.data.originalVideoUrl, true); var $video = $('#'+model.dom.videoId); adTracker.sendVideoViewCallback(); adTracker.destroy(); adTracker = null; $adOverlay.remove(); ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function videoPrincipal() {\r\n ocultarX();\r\n insertarAnuncio();\r\n insertarContador();\r\n controles();\r\n var videoPrincipal = this.src;\r\n this.src = video.src;\r\n video.src = videoPrincipal;\r\n\r\n}", "function videoPlay($wrapper) {\n let $iframe = $wrapper.find('.bda-video__...
[ "0.6804424", "0.65289545", "0.6517707", "0.64915365", "0.6478321", "0.6478321", "0.64762074", "0.6431903", "0.6427988", "0.64166427", "0.6403604", "0.6400936", "0.63883394", "0.63667023", "0.63667023", "0.6356415", "0.63542145", "0.63329923", "0.6324918", "0.6307351", "0.6285...
0.6832782
0
This is the configuration to import our master csv file via PapaParse It requires a call back function to make data useable
function parseCSV(url, callBack){ Papa.parse(url, { delimiter: "\t", // since titles have commas, we are using a tab delimited file newline: "", // auto-detect quoteChar: '"', escapeChar: '"', header: true, transformHeader: undefined, dynamicTyping: false, ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function init(){\n Papa.parse('marlboroTrails3.csv',\n\t { download: true, \n\t\theader: true, \n\t\tdynamicTyping: true,\n\t\tcomplete: convert_and_draw,\n\t }\n\t);\n}", "componentWillMount() {\n let csvFilePath = require(\"./data.csv\");\n Papa.parse(csvFilePath, {\n header: ...
[ "0.675013", "0.6559914", "0.6534126", "0.6497668", "0.6483578", "0.6433946", "0.62967634", "0.6119742", "0.60938036", "0.6061415", "0.5935876", "0.59346884", "0.588575", "0.58673084", "0.58250177", "0.5823599", "0.58095056", "0.58003116", "0.5796101", "0.5784448", "0.5725566"...
0.65826786
1
call back function to send podcast name and papaparse array to graph function
function setVar(podcast_array){ make_directed_graph(podcast, podcast_array) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function selected_podcast(){\n podcast = $('#podcast_search_box').val();\n\n if (all_podcasts_unique.indexOf(podcast) != -1){\n console.log(\"selected podcast -> \", podcast)\n\n // call back function to send podcast name and papaparse array to graph function\n function setVar(podcast_ar...
[ "0.6537921", "0.55214614", "0.53294635", "0.5058863", "0.5053866", "0.49923816", "0.49024293", "0.49022418", "0.48724052", "0.48616248", "0.48279694", "0.48250067", "0.4756073", "0.4743212", "0.47394213", "0.4729137", "0.47114882", "0.4705193", "0.46971208", "0.46870998", "0....
0.5532036
1
Constructor defining root as null and default comparator (possible overwrite by passing an argument)
constructor (comp) { this.root = null; //Constructor is using one node and sets it as root of list this.comparator = comp; if (this.comparator === undefined) { this.comparator = (node1, node2) => { if (node1 > node2) { return 1; } else if (node1 < node2) { ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "constructor(name, comparator) {\n this.nodes = {};\n this.apex = null;\n this.name = name;\n this.comparator = comparator;\n }", "function BinarySearchTree() {\n this.root = null;\n}", "function BinaryTree(){\n this.root= null;\n this.preOrder = preOrder;\n}", "function ...
[ "0.6406701", "0.63119555", "0.62199944", "0.6162743", "0.61331946", "0.61331946", "0.6122667", "0.61000943", "0.6096166", "0.60538316", "0.60467046", "0.60467046", "0.6006257", "0.5975919", "0.59552956", "0.5919895", "0.5919895", "0.59083015", "0.58912504", "0.58749014", "0.5...
0.7379121
0
Unary operator on first child
function op(elem, unary) { return unary(execChildren(elem,0,1)[0]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "visitUnaryOperator(ctx) {\n\t return this.visitChildren(ctx);\n\t}", "visitUnaryOperator(ctx) {\n\t return this.visitChildren(ctx);\n\t}", "visitUnaryExpression(ctx) {\n\t return this.visitChildren(ctx);\n\t}", "function reduce_to_first_child(thing) {\n if(thing.children.length > 1) {\n return t...
[ "0.6510134", "0.6510134", "0.6210395", "0.6163282", "0.6128059", "0.5895621", "0.5812987", "0.5768307", "0.5716323", "0.57118833", "0.57118833", "0.55850303", "0.5548301", "0.55397445", "0.5536069", "0.5523784", "0.5523784", "0.5523784", "0.5523784", "0.5523784", "0.5523784",...
0.73302186
0
Binary operator on first two children
function op2(elem, binary) { let values = execChildren(elem,0,2); return binary(values[0],values[1]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function op(elem, unary) {\n return unary(execChildren(elem,0,1)[0]);\n}", "visitLogicalOperator(ctx) {\n\t return this.visitChildren(ctx);\n\t}", "function handleLogicalOperator2(node) {\n switch (node.tag) {\n case \"joinOp\":\n node.name = node.tag.replace(/Op$...
[ "0.615886", "0.5726743", "0.555542", "0.5546257", "0.5545049", "0.5518185", "0.5518185", "0.5516867", "0.5514949", "0.5512647", "0.5512647", "0.5471386", "0.5426877", "0.53981173", "0.53981173", "0.5382201", "0.5363101", "0.5363101", "0.5298747", "0.5270686", "0.5255958", "...
0.64599705
0
Returns the sum of differences from y, squared.
function sumOfDiffsSquared(values,y) { return values.map(x=>(x-y)*(x-y)).reduce((a,b)=>a+b); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "meanSquaredError(x, y) {\n let sum = 0;\n for (let i = 0; i < x.length; i++) {\n sum += Math.pow(this.hypothesis(x[i]) - y[i], 2);\n }\n return sum / (x.length * 2);\n }", "lengthSquared() {\n var x = this.m[0];\n var y = this.m[1];\n var result = x*...
[ "0.6741557", "0.61229694", "0.595686", "0.577543", "0.57742137", "0.5740198", "0.5720946", "0.5717878", "0.57026833", "0.56940633", "0.5691579", "0.56820375", "0.5681106", "0.5675011", "0.5663765", "0.56363714", "0.5635549", "0.56222886", "0.56104696", "0.56048244", "0.558163...
0.7446411
0
Returns true if value matches or contains identifier.
function member(identifier, value) { return value && (Array.isArray(value) && value.includes(identifier)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function matchesOrMember(identifier, value) {\n return value\n && (identifier==value\n || (Array.isArray(value) && value.includes(identifier)));\n}", "__contains__(value) {\n if (value.type() === \"dict\") {\n return value.valueOf()[this.toString()] !== undefined; // fixme: toString...
[ "0.75678605", "0.63504785", "0.62620145", "0.6257448", "0.6193648", "0.610601", "0.60948247", "0.6084097", "0.60830486", "0.60830486", "0.6034671", "0.60307866", "0.6016109", "0.6002353", "0.6001384", "0.5991825", "0.5991825", "0.5986359", "0.5980617", "0.59730345", "0.597207...
0.65582556
1
Returns true if value matches or contains identifier.
function matchesOrMember(identifier, value) { return value && (identifier==value || (Array.isArray(value) && value.includes(identifier))); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function member(identifier, value) {\n return value && (Array.isArray(value) && value.includes(identifier));\n}", "__contains__(value) {\n if (value.type() === \"dict\") {\n return value.valueOf()[this.toString()] !== undefined; // fixme: toString() conversion falsifies data\n }\n ...
[ "0.65582556", "0.63504785", "0.62620145", "0.6257448", "0.6193648", "0.610601", "0.60948247", "0.6084097", "0.60830486", "0.60830486", "0.6034671", "0.60307866", "0.6016109", "0.6002353", "0.6001384", "0.5991825", "0.5991825", "0.5986359", "0.5980617", "0.59730345", "0.597207...
0.75678605
0
Returns the array, after deleting items equal to e
function del(e, array) { return (e && array && array.filter)? array.filter(x=>x!=e) : null }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function deletesAnElement(e, a) {\n var newArray = [];\n\n for (var i = 0; i < a.length; i++) {\n if (a[i] !== e) {\n newArray[newArray.length] = a[i];\n }\n }\n\n return newArray;\n}", "function delFromArr(e,a) {\n var aDel = [];\n for (var i = 0; i < a.length; i++) {\...
[ "0.7698843", "0.7690411", "0.74383295", "0.7421382", "0.70846003", "0.6633716", "0.66193384", "0.65699154", "0.6539259", "0.65267897", "0.65152115", "0.6505844", "0.64586145", "0.6453436", "0.64367396", "0.6414745", "0.6383577", "0.63796985", "0.6332716", "0.6316075", "0.6306...
0.7692076
1
Evaluates elem numberRepeats times, and returns an array concatenating all the values.
function repeat(elem) { let r = intOrIdentifier(elem, "numberRepeats"); return flatten(Array.from({length:r}, ()=>opN(elem, flatten))); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "repeat(what, n){\n var arr = [];\n for(var i=0; i<n; i++){\n arr.push(what);\n }\n return arr;\n }", "function elemsTimesLength(arr) {\n let multipleArray = [];\n for (let index = 0; index < arr.length; index++) {\n let element = arr[index];\n let elementMultiple = element * arr.length;...
[ "0.6536905", "0.6317163", "0.6273918", "0.62319773", "0.6226272", "0.60707563", "0.5959798", "0.59256005", "0.5829387", "0.5784919", "0.5772636", "0.5748229", "0.5746461", "0.5732933", "0.5719649", "0.571889", "0.5697996", "0.5696646", "0.5691815", "0.5646361", "0.56322587", ...
0.68459404
0
Returns the "pattern" attribute of an element,
function pattern(elem) { return stringOrIdentifier(elem, "pattern"); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "static get PATTERN()\n {\n return 'pattern';\n }", "get pattern() {\r\n return this._pattern;\r\n }", "get pattern() {\r\n return this._pattern;\r\n }", "get pattern() {\n return this._pattern;\n }", "get pattern() {\n return this._pattern;\n }", "get ...
[ "0.67282957", "0.6707293", "0.6707293", "0.669173", "0.669173", "0.669173", "0.669173", "0.6321725", "0.579373", "0.5736417", "0.5690544", "0.5685795", "0.56704193", "0.56704193", "0.56679267", "0.56283444", "0.5576599", "0.55519825", "0.53614163", "0.53573054", "0.5219906", ...
0.74182576
0
Returns an int where the attribute is either the integer value or the identifier of an integer variable
function intOrIdentifier(elem, attrib) { let value = elem.getAttribute(attrib); return variable(elem, value)||(value*1); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function IntegerValue() {}", "get intParameter() {}", "function db_integer(object, attribute, def) {\n\t\t\tdb_string.call(this, object, attribute, def);\n\t\t}", "function assegnaattrstella(x){\n var attributorif;\n // controllo se stella ha valori da 1 a 5\n switch (x){\n case 1:\n att...
[ "0.62482005", "0.62000686", "0.61320215", "0.6070886", "0.6062619", "0.5926509", "0.59029096", "0.5704675", "0.5688437", "0.56227654", "0.5585672", "0.55611247", "0.5548472", "0.5544814", "0.5504024", "0.5482823", "0.5465567", "0.5436872", "0.5412772", "0.5407657", "0.5375129...
0.76845247
0
Returns a string where the attribute is either the integer value or the identifier of a string variable
function stringOrIdentifier(elem, attrib) { let value = elem.getAttribute(attrib); return variable(elem, value)||(value+""); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function intOrIdentifier(elem, attrib) {\n let value = elem.getAttribute(attrib);\n return variable(elem, value)||(value*1);\n}", "function getAttr(attr, type){\n return (attr != undefined)?type+\"='\"+attr+\"'\":'';\n }", "function valueOrIdentityString(_) {\n return String(valueOrIdentity(_));...
[ "0.66612965", "0.6410647", "0.61697686", "0.60929793", "0.6060479", "0.6044644", "0.5961414", "0.58593315", "0.58469665", "0.5835571", "0.57508296", "0.574786", "0.57410026", "0.5660471", "0.56149757", "0.56149757", "0.56149757", "0.56091046", "0.56049126", "0.55784917", "0.5...
0.74468005
0
Loads XML and replaces element with the result. Assumes that the referent is a resource containing a single XML node. Note that xi:include currently uses this, though the W3C XML Include spec allows multiple nodes in an included resource.
function referent(elem) { let href = elem.getAttribute("href"); if (href) { let id = getId(elem); DEBUG("referent: launch id=", id); loadXml(href, elem, (ref)=> { DEBUG("referent: callback id=", id); ref = ref.children[0]; elem.parentElement.replaceChild(merge(ref,elem), elem); ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function update_xinclude_in_parent(path, create, callback) {\n\t\t\t\t\t\t// Where would this file be x:included from?\n\t\t\t\t\t\tvar parentfile = get_parent_path(path);\n\n\t\t\t\t\t\t// Get the raw content of the parent file.\n\t\t\t\t\t\tpatch.getPathContent(parentfile, false, function(dummy, content) {\n\t\t...
[ "0.6313318", "0.5421631", "0.5316769", "0.5117416", "0.5054581", "0.5048778", "0.4911086", "0.48552898", "0.4851309", "0.48185524", "0.47676528", "0.47469163", "0.47376543", "0.47121745", "0.470801", "0.46624285", "0.465247", "0.4567547", "0.45629245", "0.45109642", "0.447044...
0.5579047
1
Maps the value of a response variable through the mapping specified for the variable.
function mapResponse(elem) { let decl = getDeclarations(elem)[identifier(elem)]; let lookupMethod = function(K) { let entry = decl.mapping.entries[K]; if (!entry && decl.baseType=="pair") entry = decl.mapping.entries[swapPair(K)]; return entry? entry.mappedValue: decl.mapping.defaultValue; } r...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "set(variable, value) {\n const copy = new Response(this)\n copy[variable] = value\n return copy\n }", "static performVariableReverseLookup(responseVariable) {\r\n if (CensusApi.VARIABLES_REVERSE_LOOKUP.hasOwnProperty(responseVariable)) {\r\n return CensusApi.VARIABLES_RE...
[ "0.5741305", "0.5601891", "0.53700185", "0.5311358", "0.5311358", "0.5286345", "0.5217582", "0.51447904", "0.51024514", "0.5089156", "0.5086225", "0.5081676", "0.5064557", "0.5006662", "0.49879444", "0.49584684", "0.49584684", "0.49506763", "0.49437574", "0.49118373", "0.4874...
0.6043478
0
Builds a pair with members swapped.
function swapPair(pair) { let [a, b] = pair.split(" "); return [b, a].join(" "); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function get_new_pair() {\n return pair(undefined, undefined);\n}", "function swapPair(arr) {\n return [arr[1], arr[0]];\n }", "function arraySwapPairs(arr){\n\tvar temp;\n\tvar length = arr.length;\n\tfor(let i = 0; i < length - 1; i += 2){\n\t\ttemp = arr[i];\n\t\tarr[i] = arr[i + 1];\n\t\tarr[i + 1] ...
[ "0.5904732", "0.5774509", "0.5706117", "0.5660216", "0.5529151", "0.5474355", "0.5437258", "0.5371859", "0.5370343", "0.5321123", "0.53171945", "0.52623755", "0.52568424", "0.5158358", "0.5152652", "0.5149334", "0.5143015", "0.511407", "0.51042014", "0.5102843", "0.50931823",...
0.6057046
0
Maps the point value of a response variable through the areaMapping specified for the variable
function mapResponsePoint(elem) { let decl = getDeclarations(elem)[identifier(elem)]; let lookupMethod = function(point) { for (let a in decl.areaMapping.entries) { let area = decl.areaMapping.entries[a]; if (Array.isArray(point)) point = point[0]; if (inside(area, point)) retu...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "set Area(value) {}", "function focusMapOnArea() {\n var area = self.areaBounds[self.currentAreaIndex];\n var bounds = new google.maps.LatLngBounds();\n\n //iterate over the paths\n area.latLngs.getArray().forEach(function(path) {\n //iterate over the points in the path\n path.getArray().for...
[ "0.59975386", "0.56408876", "0.5627006", "0.5592072", "0.55778104", "0.54779637", "0.54418015", "0.5394247", "0.53852576", "0.53531283", "0.53398436", "0.53278494", "0.5273359", "0.5231092", "0.52127385", "0.52127385", "0.52127385", "0.52127385", "0.52127385", "0.52127385", "...
0.6722306
0
Calls "method" or maps it over a "multiple" or "ordered" value, followed by a reduce (sum).
function mapMethod(decl, method, value=decl.value) { if (decl.cardinality=="multiple" || decl.cardinality=="ordered") { if (!Array.isArray(value)) value = [value]; return value.map(method).reduce((acc,val)=>acc*1+val*1, 0); } else { return method(value)*1; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function testReduce(method) {\n\t\tequal(Array.prototype[method].length, 1);\n\n\t\tfunction sum(x,y) { return x+y; }\n\t\tfunction product(x,y) { return x*y; }\n\n\t\tequal(nums[method](sum), 15);\n\t\tequal(nums[method](product), 120);\n\n\t\tequal(nums[method](sum, 0), 15);\n\t\tequal(nums[method](product, 1), ...
[ "0.6695748", "0.6548076", "0.6289414", "0.62179816", "0.62122893", "0.61335486", "0.6129681", "0.6120488", "0.6120488", "0.6115471", "0.6115471", "0.6115471", "0.6091963", "0.60728294", "0.6070516", "0.6070516", "0.6070516", "0.6070516", "0.60571283", "0.6027312", "0.6026462"...
0.65627986
1
Converts the shape and coords attributes on an element to an object, for use with "inside".
function area(elem) { return {shape:elem.getAttribute("shape"), coords:elem.getAttribute("coords")}; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function genElementObject($element){\n \n /* Find assigned URIs\n * \n * URIs are assigned by an HTML attribute 'x-kolola-uri'\n * [We use x- rather than an XML namespace, because XML namespace support is dodgy in jQuery]\n */\n var uris = [$element.attr('x-kolo...
[ "0.578763", "0.5646772", "0.5609048", "0.5539222", "0.54913926", "0.5482474", "0.54528546", "0.5383528", "0.53116256", "0.5311504", "0.5304854", "0.5283777", "0.5264909", "0.52613425", "0.52351654", "0.5230457", "0.522174", "0.5221108", "0.5205631", "0.52034175", "0.51954895"...
0.6788653
0
Returns true if the point is inside the area.
function inside(area, point) { let [x,y] = point.split(" "); let coords = area.coords.split(","); coords = coords.map(coord=>+coord); switch(area.shape) { case "circle": return pointInCircle(x, y, coords); case "poly": return pointInPolygon(x, y, coords); case "rect": return pointInRectangle(...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "isPointInside(point) {\r\n console.log(\"Test point inside \" + point.x + \" \" + point.y);\r\n console.log(this.x + \" y: \" + this.y + \" r: \" + this.right + \" b: \" + this.bottom);\r\n console.log(\"////\");\r\n return (this.x <= point.x && point.x < this.right) && (this.y <= point...
[ "0.74660087", "0.72200525", "0.702569", "0.7020239", "0.69614553", "0.69608766", "0.69203955", "0.690166", "0.6872086", "0.6803118", "0.68030167", "0.6760514", "0.67457163", "0.6739013", "0.6731106", "0.67059815", "0.66862184", "0.66390723", "0.6617389", "0.66129863", "0.6585...
0.762922
0
TODO: REWORK getDeclarationContext into getDeclaration ////////////////////////// Climbs DOM tree looking for an element with declarations and returns the element.
function getDeclarationContext(elem) { while (elem && !((elem.tagName=="assessmentItem"||elem.tagName=="assessmentTest") && elem.declarations)) elem = elem.parentElement; return elem; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "get firstElementChild() {\n return this.childNodes.find(elementPredicate) || null;\n }", "function getDomElement() {\n return getElement();\n }", "function getDomElement() {\n\t return getElement();\n\t } // ========================== Motion End ==========================", "function _fir...
[ "0.58615315", "0.5786674", "0.57412523", "0.5703873", "0.5673402", "0.5665532", "0.5659139", "0.5642936", "0.5614385", "0.5614385", "0.5614385", "0.5614385", "0.5614385", "0.5610276", "0.5603935", "0.5603935", "0.5586864", "0.5573517", "0.5539683", "0.550153", "0.54957753", ...
0.6957484
0
Sets the completionStatus variable.
function setCompletionStatus(elem, status, when) { let ctx = getDeclarationContext(elem); if (ctx && ctx.declarations) { let completionStatus = ctx.declarations["completionStatus"]; if (completionStatus) { if (when == completionStatus.value){ let prevValue = completionStatus.value; com...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setCompletionStatus(sCompletion) {\n\t/* see if this SCORM 2004 */\n\tif (_sAPI == \"API_1484_11\") {\n\t\t/* it is SCORM 2004, set the completion status */\n\t\tscormSetValue(\"cmi.completion_status\", sCompletion+\"\");\n\t} else if (_sAPI == \"API\") {\n\t\t/* it is SCORM 1.2, see if this is a valid co...
[ "0.72452605", "0.6864981", "0.62866926", "0.6225877", "0.6161851", "0.61310387", "0.61310387", "0.61310387", "0.61310387", "0.61310387", "0.61310387", "0.61310387", "0.61310387", "0.61310387", "0.61310387", "0.60521156", "0.59529734", "0.5939932", "0.5860952", "0.58379644", "...
0.68786377
1
Returns values of a variable across all assessmentItems.
function testVariables(elem) { let variableIdentifier = elem.getAttribute("variableIdentifier"); let weightIdentifier = elem.getAttribute("weightIdentifier"); let includeNulls = elem.getAttribute("includeNulls")==="true"; let filters = getVariableFilters(elem); let result = [...QTI.ROOT.querySelectorAll("asse...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getAllAssessment() {\n var AllAssessments = {};\n AllValues.forEach(function (item) {\n var VisitNo = AllAssessments[item.VisitNo] = AllAssessments[item.VisitNo] || {};\n VisitNo[item.Assessment] = true;\n });\n var outputList = [];\n for (var Visit...
[ "0.589826", "0.5497952", "0.54491186", "0.5358149", "0.53065425", "0.5182115", "0.5167712", "0.5160319", "0.5154202", "0.5083799", "0.5063553", "0.5058946", "0.5058946", "0.503891", "0.50178695", "0.50082105", "0.4996421", "0.4987284", "0.49521706", "0.49495232", "0.49375874"...
0.626546
0
Gets attribute of a variable, such as "defaultValue", "correctResponse"
function getVarAttribute(elem, attribute) { let id = identifier(elem); return declAttribute(elem, attribute, id); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "get attribute() {}", "getAttribute(name) {\n return this.attributes[name];\n }", "function getPropValue(attribute) {\n return extractValue(attribute, _values2.default);\n}", "function attr (obj, attribute) {\n if (obj) {\n if (obj[attribute] || obj[attribute] == \"\") {\n return obj...
[ "0.74280316", "0.63703674", "0.6274825", "0.6176751", "0.6131099", "0.61279666", "0.6090641", "0.60622966", "0.602862", "0.60251045", "0.60107577", "0.5991603", "0.5943691", "0.594005", "0.594005", "0.594005", "0.594005", "0.594005", "0.594005", "0.594005", "0.594005", "0.5...
0.6632358
1
Get range min/max/step attributes from element.
function getRange(elem) { let range = { min:(elem.getAttribute("min")*1)||0, max:(elem.getAttribute("max")*1)||0, step:(elem.getAttribute("step")*1)||1, } return range; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function attr_range(t){\n if(map_attribute == 'Gini'){\n return range_gini;\n } else if(map_attribute =='GDP'){\n return range_pib;\n } else if (map_attribute =='PP'){\n return range_pp;\n }\n }", "static get inputAttributes() {\n return [\n ...
[ "0.69801193", "0.655777", "0.6299137", "0.61648536", "0.61586356", "0.6126441", "0.60433596", "0.6031181", "0.59360796", "0.59254724", "0.5912824", "0.5904999", "0.5903304", "0.58880967", "0.5887998", "0.58369243", "0.58010966", "0.57534355", "0.5731623", "0.5730054", "0.5723...
0.8217034
0
Returns true if the item is "presented". The session control logic sets the "presented" attribute on items which are to count as presented.
function isPresented(frame) { return frame.elem.tagName=="assessmentItem" && frame.presented; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "get isPresenting() {\n return this.presentedScene != null;\n }", "get isPresenting() {\n return this.presentedScene != null;\n }", "isDisplayed() {\n\t\treturn this.element.isDisplayed();\n\t}", "hasItem() {\n return !!this._item;\n }", "function isItemsVisible(){\r\n\t\t\r\n\t\tvar...
[ "0.6791538", "0.6791538", "0.5951587", "0.587761", "0.58405846", "0.58167404", "0.57974946", "0.57974946", "0.57974946", "0.57974946", "0.57974946", "0.57208574", "0.5716028", "0.5712735", "0.5712735", "0.5629472", "0.5629472", "0.5629472", "0.5623648", "0.56039727", "0.56039...
0.709221
0
Returns true if at least one interaction in an item has a "response"
function isResponded(frame) { return frame.elem.tagName=="assessmentItem" && getResponses(frame.elem).length>0; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "allQuestClaimed() {\n return !this.incompleteQuests().length && !this.currentQuests().length;\n }", "checkIfAnswered(questions){\n for(let i=0; i<questions.length; i++){\n if(questions[i].response == null)\n return false;\n }\n return true;\n }", "fun...
[ "0.5947256", "0.5851502", "0.58042836", "0.5759281", "0.57004166", "0.57004166", "0.5687441", "0.5666947", "0.5619006", "0.55764216", "0.55746377", "0.5572812", "0.55670476", "0.5550326", "0.55372465", "0.5522653", "0.55222267", "0.5505901", "0.54859775", "0.5476373", "0.5450...
0.70155334
0
Returns the response variables with nonnull and nondefault values.
function getResponses(item) { return getResponseVariables(item).filter(decl=>{ return !(decl.value === null || (decl.defaultValue && match(decl.defaultValue, decl.value)) || (decl.cardinality=="multiple" && decl.value.length==0)); }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "get variables() {\n\t\t\treturn present.variables;\n\t\t}", "function vars() {\n return ['local','visitante','competition','year'];\n}", "function vars() {\n return ['local','visitante','competition','year'];\n}", "function getEmptyResult() {\n return {\n domain: null,\n domainWithoutS...
[ "0.5917914", "0.5858942", "0.5858942", "0.5830788", "0.556086", "0.5555323", "0.5489609", "0.5464454", "0.5410337", "0.51854044", "0.51672286", "0.51669794", "0.5156173", "0.51308334", "0.50901794", "0.5058041", "0.5039386", "0.50350666", "0.5028551", "0.50230044", "0.5017274...
0.6404001
0
Returns true if all the response variables for the item which have the specified property ("correctResponse" or "defaultValue") defined have a value which matches the property.
function valueMatches(frame, prop) { if (frame.elem.tagName=="assessmentItem") { let vars = getResponseVariables(frame.elem).filter(decl=>decl[prop]); let matches = vars.filter(decl=>decl.value && match(decl[prop], decl.value)); return matches.length==vars.length; } else { return false; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isAnswerCorrect(reponseObject){\n\n return reponseObject.is_correct;\n\n }", "function isCorrect(frame) {\n return valueMatches(frame, \"correctResponse\");\n}", "checkIfAnswered(questions){\n for(let i=0; i<questions.length; i++){\n if(questions[i].response == null)\n ...
[ "0.6174846", "0.57357544", "0.5622875", "0.55852723", "0.55376416", "0.54622966", "0.53698355", "0.53597605", "0.53583616", "0.5304262", "0.52647847", "0.5262662", "0.5251513", "0.5244342", "0.52288204", "0.5196071", "0.51772", "0.5172268", "0.5169049", "0.5161841", "0.514657...
0.6230487
0
Returns true if the first two child expressions are equal after rounding.
function equalRounded(elem) { return op2(elem, (a,b)=>{ let f=figures(elem); return +a.toFixed(f)==+b.toFixed(f); }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function approxEqual(n1, n2) {\n /* Exactly equal */\n if (n1 === n2) return true;\n /* Differ by less than epsilon */\n if (Math.abs(n1 - n2) < Number.EPSILON) return true;\n /* Number of digits after the decimal */\n const decDigits = (n) => {\n let s = `${n}`;\n if (s.indexOf(\".\") === -1) {\n ...
[ "0.61735594", "0.60815793", "0.5772919", "0.5733497", "0.563073", "0.5619092", "0.5602604", "0.5596551", "0.55338204", "0.5522899", "0.5522899", "0.5522899", "0.5522899", "0.5522899", "0.5522899", "0.5522899", "0.5522899", "0.5522899", "0.5522899", "0.5522899", "0.5522899", ...
0.71152806
0
Logs textContent of element on console.
function consoleLog(elem) { console.log("console: ",trim(elem.textContent)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function log(text){\n $('#consoleOutput').append('<p>'+text+'</p>')\n }", "log(text) {\n appConsole.innerHTML += `<p class=\"console--log\">${text}</p>`;\n }", "function log(text) {console.log(text);}", "function logIt(text) {\n console.log(text)\n}", "get text() { return this....
[ "0.69011194", "0.65931267", "0.6511366", "0.6492275", "0.6484627", "0.641602", "0.6348339", "0.6324676", "0.63041466", "0.62963307", "0.6273034", "0.626171", "0.6230753", "0.6197406", "0.6185009", "0.61744255", "0.61650014", "0.6164573", "0.6153809", "0.6141942", "0.6117492",...
0.7222721
0
Support URLs relative to a directory, but be careful about a protocol prefix in case we are in the browser (i.e. directories may start with "
function supportRelativeURL(file,url){if(!file)return url;var dir=path.dirname(file);var match=/^\w+:\/\/[^\/]*/.exec(dir);var protocol=match?match[0]:'';return protocol+path.resolve(dir.slice(protocol.length),url);}
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function supportRelativeURL(file, url) {\n if (!file) return url;\n var dir = path.dirname(file);\n var match = /^\\w+:\\/\\/[^\\/]*/.exec(dir);\n var protocol = match ? match[0] : '';\n var startPath = dir.slice(protocol.length);\n if (protocol && /^\\/\\w\\:/.test(startPath)) {\n // handle...
[ "0.7151168", "0.7072716", "0.70653147", "0.70653147", "0.70653147", "0.70653147", "0.70159996", "0.70159996", "0.6961041", "0.6961041", "0.6961041", "0.6246227", "0.623678", "0.6068821", "0.5998057", "0.5962027", "0.59541446", "0.59403753", "0.59275633", "0.59081924", "0.5903...
0.72605187
1
The implementation of wrapCallSite() used to just forward to the actual source code of CallSite.prototype.toString but unfortunately a new release of V8 did something to the prototype chain and broke the shim. The only fix I could find was copy/paste.
function CallSiteToString(){var fileName;var fileLocation="";if(this.isNative()){fileLocation="native";}else{fileName=this.getScriptNameOrSourceURL();if(!fileName&&this.isEval()){fileLocation=this.getEvalOrigin();fileLocation+=", ";// Expecting source position to follow. }if(fileName){fileLocation+=fileName;}else{// S...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function CallSiteToString() {\n var fileName;\n var fileLocation = \"\";\n if (this.isNative()) {\n fileLocation = \"native\";\n } else {\n fileName = this.getScriptNameOrSourceURL();\n if (!fileName && this.isEval()) {\n fileLocation = this.getEvalOrigin();\n fileLocation += \", \"; // Exp...
[ "0.6478927", "0.6478927", "0.6478927", "0.6478927", "0.6478927", "0.6478927", "0.6478927", "0.64553124", "0.6287522", "0.62493587", "0.62493587", "0.60562366", "0.60446465", "0.5956615", "0.5956615", "0.5956615", "0.5956615", "0.5956615", "0.5956615", "0.5956615", "0.5956615"...
0.676007
1
Support URLs relative to a directory, but be careful about a protocol prefix in case we are in the browser (i.e. directories may start with "
function supportRelativeURL(file,url){if(!file)return url;var dir=path.dirname(file);var match=/^\w+:\/\/[^\/]*/.exec(dir);var protocol=match?match[0]:'';return protocol+path.resolve(dir.slice(protocol.length),url);}
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function supportRelativeURL(file, url) {\n if (!file) return url;\n var dir = path.dirname(file);\n var match = /^\\w+:\\/\\/[^\\/]*/.exec(dir);\n var protocol = match ? match[0] : '';\n var startPath = dir.slice(protocol.length);\n if (protocol && /^\\/\\w\\:/.test(startPath)) {\n // handle...
[ "0.7151636", "0.7072828", "0.70657265", "0.70657265", "0.70657265", "0.70657265", "0.7016029", "0.7016029", "0.6961108", "0.6961108", "0.6961108", "0.62457526", "0.6237434", "0.60694075", "0.59992075", "0.59626734", "0.59533274", "0.5940014", "0.5927178", "0.59087706", "0.590...
0.72602373
0
The implementation of wrapCallSite() used to just forward to the actual source code of CallSite.prototype.toString but unfortunately a new release of V8 did something to the prototype chain and broke the shim. The only fix I could find was copy/paste.
function CallSiteToString(){var fileName;var fileLocation="";if(this.isNative()){fileLocation="native";}else{fileName=this.getScriptNameOrSourceURL();if(!fileName&&this.isEval()){fileLocation=this.getEvalOrigin();fileLocation+=", ";// Expecting source position to follow. }if(fileName){fileLocation+=fileName;}else{// S...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function CallSiteToString() {\n var fileName;\n var fileLocation = \"\";\n if (this.isNative()) {\n fileLocation = \"native\";\n } else {\n fileName = this.getScriptNameOrSourceURL();\n if (!fileName && this.isEval()) {\n fileLocation = this.getEvalOrigin();\n fileLocation += \", \"; // Exp...
[ "0.6478872", "0.6478872", "0.6478872", "0.6478872", "0.6478872", "0.6478872", "0.6478872", "0.64552236", "0.62875515", "0.62493664", "0.62493664", "0.60563654", "0.6044775", "0.5956605", "0.5956605", "0.5956605", "0.5956605", "0.5956605", "0.5956605", "0.5956605", "0.5956605"...
0.6760198
0
Build the rebundle function using the bundler we just created
function rebundle() { // Log the start gutil.log('Starting', "'" + gutil.colors.cyan('rebundle') + "'..."); var start = new Date().getTime(); // Build the javascript bundle file var b = bundler.bundle() .on('error', notify.onError({ title: "Compile Error", message: "<%= er...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function rebundle() {\n var stream = bundler.bundle()\n .on('error', gutil.log)\n .pipe(source(bundleName))\n .pipe(buffer());\n\n if (production.isSet()) {\n stream = stream\n\n // Load Browserify's inline sourcemaps\n .pipe(sourcemaps.init({loadMaps: true}))\n\n // ...
[ "0.649154", "0.62343806", "0.62195945", "0.61288214", "0.6109262", "0.6100223", "0.6089282", "0.5987184", "0.59237695", "0.59033114", "0.5889114", "0.5881392", "0.5834417", "0.5822088", "0.5772808", "0.5747964", "0.5700793", "0.56931835", "0.5687203", "0.5652093", "0.5646567"...
0.7317395
0
that will be called any time an event requires the viewport to be redrawn. initSlices is a callback that will be called when the viewport's current slices need to be updated.
function init2dViewportEvents(canvas, viewport, model, kAxis, redraw, initSlices) { canvas = $(canvas); var container = canvas.closest('div'); // Zooming canvas.bind('mousewheel DOMMouseScroll', $.throttle(16, function(event) { event.preventDefault(); if (event.originalEvent.wheelDelta > 0 || event.o...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function viewerLoaded(){\n iv.addEvent(\"centerchanged\",centerChanged);\n iv.addEvent(\"zoomchanged\",zoomChanged);\n iv.addEvent(\"layerchanged\",layerChanged);\n iv.addEvent(\"layeradded\",layerAdded);\n iv.addEvent(\"layerremoved\",layerRemoved);\n iv.addEvent(\"componentchanged\",componentCh...
[ "0.5578186", "0.5369806", "0.53418505", "0.5340816", "0.5210058", "0.51876897", "0.51857203", "0.5184112", "0.5160184", "0.51473063", "0.51224107", "0.5084171", "0.5084108", "0.5070311", "0.50533414", "0.50524145", "0.50408775", "0.50335205", "0.50266373", "0.50139284", "0.50...
0.5743002
0
clusterUuid : clusterUuid nxRequest: Instance of nxRequest
function ClusterContainers(clusterUuid, nxRequest) { this.clusterUuid = clusterUuid; this.nxRequest = nxRequest; this.idAttribute = 'id'; this.syncData(); setInterval(this.syncData.bind(this), 30000); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "get clusterIdInput() {\n return this._clusterId;\n }", "function CommonCluster(IpAddress) {\n\tthis.apiBaseUrl = \"https://\"+IpAddress + \":8443/wsg/api/public\";\n\tthis.internalApiBaseUrl = \"https://\"+IpAddress + \":8443/wsg/api/scg\";\n\tthis.username = \"admin\";\n\tthis.password = \"Ruckus123$\...
[ "0.5455565", "0.5114828", "0.50501776", "0.5019633", "0.49797454", "0.49776804", "0.49548802", "0.49280927", "0.4912115", "0.48478162", "0.48279044", "0.48012692", "0.4783321", "0.47677976", "0.47677976", "0.47612807", "0.47441968", "0.4739017", "0.47271314", "0.47233063", "0...
0.7116285
0
Initializes a new SocketIoClient, not connected by default.
function SocketIoClient() { _classCallCheck(this, SocketIoClient); this.connected = false; this.connecting = false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "init(socket) {\n this.socket = socket;\n }", "function initSocketIO(){\n // Add Socket.IO include now that we know where from and the server is running\n var path = robopaint.cncserver.api.server.protocol +\n '://' + robopaint.cncserver.api.server.domain + ':' +\n robopaint.cncserver.api.server...
[ "0.69096726", "0.6646056", "0.662071", "0.6539944", "0.6458445", "0.6380467", "0.63611007", "0.634848", "0.634848", "0.63317275", "0.63146317", "0.63146317", "0.6283508", "0.6243505", "0.6227208", "0.620691", "0.61938447", "0.61631924", "0.61631924", "0.6157316", "0.61212844"...
0.8020609
0
A rating for anything in the system by a user
function Rating() { this.id = 0; // a rating, generally 0-5 this.rating = 0; // the user creating the rating (may be anonymous) this.user = null; this.created = null; this.modified = null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function rate(rating) {\n let current = JSON.parse(getLocal(profilecount));\n rating === 'like' ? current.liked = 1 : current.liked = -1;\n setLocal(profilecount, JSON.stringify(current));\n profilecount++;\n setLocal('profilecount',profilecount);\n checkClick();\n}", "function isRating() {}", ...
[ "0.71589005", "0.71265227", "0.70420134", "0.70365983", "0.7005084", "0.6938734", "0.6932716", "0.68063074", "0.68063074", "0.6760044", "0.6753159", "0.6715684", "0.67003983", "0.6699068", "0.66952056", "0.65902567", "0.65449923", "0.65312797", "0.64899623", "0.64724916", "0....
0.7321985
0
HttpClient API get() method => Fetch notice list
getNoticeList() { return this.http.get(this.apiURL + '/home/notices/?format=json', this.httpOptions) .pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["retry"])(2), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["catchError"])(this.handleError)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "list() {\n let rqst = this.client.newSignedRequest('GET', `${this.urlPrefix}`, null);\n return this.client._wrapWithPromise(rqst);\n }", "getAll_() {\r\n return fetch(this.endPoint)\r\n .then( (resp)=> {\r\n return resp.json();\r\n } );\r\n }", "async function getItemList(){\n\n let re...
[ "0.6805695", "0.652409", "0.6361967", "0.62184465", "0.6107571", "0.60899305", "0.60849816", "0.6079994", "0.6068325", "0.5984717", "0.59777945", "0.59571457", "0.5953999", "0.593451", "0.59317666", "0.5926105", "0.5914319", "0.59073293", "0.5907234", "0.58957994", "0.588452"...
0.74428487
0
HttpClient API get() method => Fetch Commitee Member List
getCommiteeMemberList() { return this.http.get(this.apiURL + '/home/commiteemembers/?format=json', this.httpOptions) .pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["retry"])(2), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["catchError"])(this.handleError)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async function getMemberList() {\n\n // nur die Daten, die wir auch brauchen erfassen mit xprofile string \n var params = {\n xprofile: \"Über mich\",\n per_page: 100\n }\n\n return await fetch(`${BB_API_BASE_URL}/buddyboss/v1/members${params ? `?${new URLSearchParams(params)}` : \"\"}`, ...
[ "0.73987186", "0.68666416", "0.6698062", "0.6682532", "0.6682532", "0.6575691", "0.6556613", "0.65551853", "0.6434558", "0.6380475", "0.63503814", "0.630779", "0.62452114", "0.62423164", "0.621304", "0.61914563", "0.6165563", "0.614587", "0.6141416", "0.61365956", "0.61293536...
0.7589234
0
HttpClient API get() method => Fetch Helpfull Info list
getHelpfullInfoList() { return this.http.get(this.apiURL + '/home/helpfull_info_list/?format=json', this.httpOptions) .pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["retry"])(2), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["catchError"])(this.handleError)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async tips() {\r\n return this.fetchJson(\"get\", \"tips\");\r\n }", "async info() {\r\n return this.fetchJson(\"get\", \"info\");\r\n }", "async getHelpTickets() {\n await this.helpTickets.getHelpTickets(this.userObj)\n }", "async getHelpTicketsContents() {\n await this....
[ "0.6551773", "0.6529162", "0.6315278", "0.6180994", "0.6157292", "0.61452585", "0.6118088", "0.6103076", "0.60587054", "0.60551304", "0.602994", "0.5983997", "0.5982956", "0.59764874", "0.5975585", "0.59755325", "0.59642744", "0.5941173", "0.5936862", "0.5908343", "0.5884255"...
0.7505134
0
HttpClient API get() method => Fetch Sliding Images list
getSlidingImageList() { return this.http.get(this.apiURL + '/home/sliding_images/?format=json', this.httpOptions) .pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["retry"])(2), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["catchError"])(this.handleError)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getGalleryImageList() {\n return this.http.get(this.apiURL + '/home/gallery_images_list/?format=json', this.httpOptions)\n .pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__[\"retry\"])(2), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__[\"catchError\"])(this.handleError));\n }", "f...
[ "0.7158317", "0.70409423", "0.68475914", "0.6791849", "0.6691209", "0.6632614", "0.6578644", "0.6557881", "0.6535648", "0.6490867", "0.6447339", "0.64378214", "0.64262396", "0.6404504", "0.6393977", "0.6342426", "0.6337504", "0.63193", "0.63042647", "0.6252849", "0.6252338", ...
0.7849668
0
HttpClient API get() method => Fetch Gallery Images list
getGalleryImageList() { return this.http.get(this.apiURL + '/home/gallery_images_list/?format=json', this.httpOptions) .pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["retry"])(2), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["catchError"])(this.handleError)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getImagesList(){\n\tImageScrollerService.getImages().then(\n\t\tfunction (response) {//sucess handler\n\t\t\tif(response.stat==\"ok\"){\n\t\t\t\t$scope.response =response.photos.photo;\n\t\t\t\t//after we get the response push the response in the array\n\t\t\t\tpushResponse();\n\t\t\t\t//once we get the r...
[ "0.7386918", "0.7218415", "0.7175353", "0.71705973", "0.71345514", "0.70986193", "0.70685035", "0.70657164", "0.706096", "0.69741493", "0.69631493", "0.6954484", "0.6940098", "0.6927794", "0.68927574", "0.68591887", "0.6818148", "0.6810048", "0.68059987", "0.67586225", "0.675...
0.7907126
0
HttpClient API get() method => Fetch Important link list
getImportantLinksList() { return this.http.get(this.apiURL + '/home/important_links/?format=json', this.httpOptions) .pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["retry"])(2), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["catchError"])(this.handleError)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async function get_itemsList(link){\n\n let response = await fetch(link);\n\n if (response.ok) {\n let return_value = await response.json();\n return return_value\n } else {\n alert(\"HTTP-Error: \" + response.status);\n }\n}", "function get() {\n url.list().\n success(...
[ "0.67405385", "0.6717234", "0.6646332", "0.64755857", "0.6438364", "0.6388074", "0.6370165", "0.6300655", "0.62758195", "0.62665945", "0.6248683", "0.62431186", "0.62196517", "0.6213733", "0.61516565", "0.6149523", "0.614941", "0.6124431", "0.61208475", "0.60914487", "0.60720...
0.7624673
0
Ticket management services HttpClient API get() method => Fetch Ticket list
getTicketsList(ticketId) { let username = localStorage.getItem('username'); let ticketApiUrl = "/ticket_management/tickets/?format=json&user=" + username; if (typeof (ticketId) != 'undefined' && ticketId != -1) { ticketApiUrl = "/ticket_management/tickets/" + ticketId + "/?format=jso...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async function fetchTicketData() {\n // TODO: Error handling\n const response = await fetch(\"/api/tickets\");\n const data = await response.json();\n return data.tickets;\n}", "getTicketTypeList() {\n let ticketTypeApiUrl = \"/ticket_management/ticket_types/?format=json\";\n return this.http.g...
[ "0.73968154", "0.73401684", "0.7300392", "0.72208333", "0.71494603", "0.7136679", "0.71181124", "0.69714034", "0.6955499", "0.6794053", "0.67237896", "0.6673383", "0.666236", "0.66031134", "0.6594433", "0.6585141", "0.6378544", "0.6326601", "0.6317511", "0.62920266", "0.62413...
0.7770341
0
HttpClient API get() method => Fetch Ticket Type list
getTicketTypeList() { let ticketTypeApiUrl = "/ticket_management/ticket_types/?format=json"; return this.http.get(this.apiURL + ticketTypeApiUrl, this.httpOptions) .pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["retry"])(2), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["catch...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "static async getAllBookedTickets() {\n try {\n let url = \"http://localhost:3000/api/v1/tickets/\";\n let result = await axios.get(url);\n return result.data;\n } catch (error) {\n console.log(error);\n }\n }", "async function fetchTicketData() ...
[ "0.66682404", "0.6653411", "0.66117716", "0.6589459", "0.65246725", "0.6444781", "0.6404243", "0.6384647", "0.637335", "0.6369121", "0.63542265", "0.63375574", "0.6336614", "0.61447823", "0.5963915", "0.59280634", "0.5921473", "0.588348", "0.5872052", "0.5862122", "0.5855174"...
0.7650894
0
HttpClient API get() method => Fetch Ticket Status list
getTicketStatusList() { let ticketStatusApiUrl = "/ticket_management/ticket_status/?format=json"; return this.http.get(this.apiURL + ticketStatusApiUrl, this.httpOptions) .pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["retry"])(2), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getTicketsByStatus() {\n clearAlerts();\n clearElement('query-result-tickets');\n\n if (!validateField(\"project\", \"Project is required.\")) {\n return;\n }\n\n var project = document.getElementById(\"project\").value;\n var status = document.getElementById(\"statusSelect\").val...
[ "0.73389304", "0.7097725", "0.7047632", "0.700598", "0.6934936", "0.6629678", "0.66094", "0.65840477", "0.6488548", "0.63421035", "0.6339913", "0.62985307", "0.629655", "0.61787045", "0.61754435", "0.59549826", "0.59546524", "0.59296197", "0.5898926", "0.5891064", "0.58903027...
0.7831032
0
HttpClient API get() method => Fetch Ticket Attachment list
getTicketAttachmentList() { let ticketAttachmentApiUrl = "/ticket_management/ticket_attachments/?format=json"; return this.http.get(this.apiURL + ticketAttachmentApiUrl, this.httpOptions) .pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["retry"])(2), Object(rxjs_operators__WEBPACK_IM...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getTicketsList(ticketId) {\n let username = localStorage.getItem('username');\n let ticketApiUrl = \"/ticket_management/tickets/?format=json&user=\" + username;\n if (typeof (ticketId) != 'undefined' && ticketId != -1) {\n ticketApiUrl = \"/ticket_management/tickets/\" + ticketId + ...
[ "0.6242894", "0.6223939", "0.621847", "0.60670567", "0.602093", "0.59794855", "0.59727764", "0.5954702", "0.5942575", "0.59417754", "0.59358543", "0.5874247", "0.584969", "0.58303326", "0.5825159", "0.58139074", "0.57663625", "0.5637684", "0.5629622", "0.55702114", "0.5536489...
0.81476814
0