Search is not available for this dataset
query
stringlengths
7
355k
document
stringlengths
9
341k
metadata
dict
negatives
listlengths
0
101
negative_scores
listlengths
0
101
document_score
stringlengths
3
10
document_rank
stringclasses
102 values
9.a Draw line graph
function drawLineGraph(ctx, data) { return new Chart(ctx).Line(data, { animation: false, scaleStartValue: 0, bezierCurve: false, datasetFill: true, scaleFontColor: "#FFFFFF", scaleGridLineColor: "rgba(128, 128, 128, 0.2)", pointDotRadius: 1 }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function lines()\n{\n //line colour\n stroke(255);\n strokeWeight(5);\n //vertical lines\n line(100,200,400,200)\n line(100,300,400,300)\n //horizontal lines\n line(200,100,200,400)\n line(300,100,300,400)\n \n \n}", "function drawLines() {\n}", "function drawLines() {\n}", "...
[ "0.76008505", "0.7387488", "0.7387488", "0.73219913", "0.7215956", "0.7200775", "0.7127951", "0.71114296", "0.7106248", "0.7013877", "0.700071", "0.69914764", "0.69713664", "0.6927594", "0.6924324", "0.6915258", "0.69101197", "0.6906959", "0.6896263", "0.6865007", "0.68606114...
0.68061393
27
9.b Display filtered burn up chart
function filterBurnUp() { var from = $("#txtBUFrom").val(); var to = $("#txtBUTo").val(); // Filter data var newData = filterLineGraph(from, to, burnupData); // Display new chart var ctx = document.getElementById("burnupChart").getContext("2d"); myBurnUp.destroy(); myBurnUp = drawLineG...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "filteredData() {\n this.plotCumulativeFrequency();\n }", "function FilterChart(){}", "function showMillionaires() {\n data = data.filter(item => item.worth > 1000000);\n updateDom();\n}", "function filterBurnDown() {\n var from = $(\"#txtBDFrom\").val();\n var to = $(\"#txtBDTo\").val();\...
[ "0.6678504", "0.662397", "0.63395005", "0.6294592", "0.6156652", "0.61338884", "0.61227757", "0.6113868", "0.59319925", "0.5912316", "0.5901345", "0.5869542", "0.5854268", "0.57675844", "0.57041323", "0.5678249", "0.56768316", "0.5655159", "0.5636547", "0.5621485", "0.5615385...
0.6549628
2
9.c Display filtered burn down chart
function filterBurnDown() { var from = $("#txtBDFrom").val(); var to = $("#txtBDTo").val(); // Filter data var newData = filterLineGraph(from, to, burndownData); // Display new chart var ctx = document.getElementById("burndownChart").getContext("2d"); myBurnDown.destroy(); myBurnDown =...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "filteredData() {\n this.plotCumulativeFrequency();\n }", "function FilterChart(){}", "function filterBurnUp() {\n var from = $(\"#txtBUFrom\").val();\n var to = $(\"#txtBUTo\").val();\n\n // Filter data\n var newData = filterLineGraph(from, to, burnupData);\n\n // Display new chart\n ...
[ "0.6657718", "0.6534122", "0.64190096", "0.62501055", "0.6140576", "0.6025067", "0.5999245", "0.5988224", "0.5961193", "0.5854282", "0.58371055", "0.5794533", "0.5778474", "0.57058364", "0.57036746", "0.56646806", "0.5652852", "0.5626619", "0.5616331", "0.56045437", "0.560186...
0.64799
2
9.d Filter dataset for line graph
function filterLineGraph(from, to, data) { var temp = JSON.parse(JSON.stringify(data)); var labels = temp.labels; var dataset = temp.datasets[0].data; // Search starting point if (from != "") { from = toDate(from); while (toDate(labels[0]) < from) { labels.splice(0, 1); ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function FilterChart(){}", "function linePreprocess(data) {\n\t\n\tvar day = d3.select(\"#ctrlHeatmapDay\").node();\n\tvar dayValue = day.options[day.selectedIndex].value;\n\n// TODO implement day filters\t\n// \tdata = data.filter(function(d) {\n// \t\treturn d.day == dayValue;\n// \t});\n\n\tvar dayToSamplesMa...
[ "0.6617396", "0.6470913", "0.6399172", "0.62878495", "0.6226077", "0.61851674", "0.5967072", "0.59658766", "0.5946065", "0.59443355", "0.5898868", "0.5876672", "0.5869127", "0.58659047", "0.5831381", "0.5827541", "0.57928914", "0.5776271", "0.57656187", "0.572915", "0.5728572...
0.6779614
0
9.e Setup team estimation factor
function setupGaugeEstimation() { var gaugeColor = []; var i = -100; while (i <= 100) { if ((i < -25) || (i > 25)) gaugeColor.push("#ff4b4b"); else if ((i < -10) || (i > 10)) gaugeColor.push("#ffa500"); else gaugeColor.push("#4bff4b"); i = i + 5; } wi...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "decideTeams() {\n\n let teams;\n\n // 1. create team arrays\n let numberOfTeams = this.options.numOfTeams;\n if(numberOfTeams === undefined) { // if private\n let teams = new Set();\n for(let [c, data] of this.playersMap) teams.add(data[2] === 0 ? c : data[2]);\n numberOfTeams = teams.si...
[ "0.6132859", "0.58512384", "0.5833332", "0.57635176", "0.5668028", "0.5661524", "0.56502426", "0.56443363", "0.5577926", "0.55534637", "0.55223435", "0.5509431", "0.54971725", "0.54904103", "0.5482642", "0.54558045", "0.54283524", "0.5420136", "0.5374648", "0.53724843", "0.53...
0.0
-1
Chart support function Parse date string to object
function toDate(input) { var part = input.split("."); return new Date(part[2], (part[1] - 1), part[0]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function dateStringToObject(string){\n var splitString = console.log(string.split(\"-\"));// adding - in between each value entry for separation\n return {month: splitString[1], day: splitString[2], year: splitString[0]}//return array as object after placing dashes here\n // var objectDate = new Object();...
[ "0.67970574", "0.6705781", "0.66532695", "0.6597305", "0.6560116", "0.65344185", "0.63273203", "0.6317144", "0.62568456", "0.62540257", "0.62522286", "0.61954695", "0.61812925", "0.615063", "0.6130901", "0.60984164", "0.6075361", "0.60436773", "0.60414135", "0.60318714", "0.5...
0.0
-1
Load spinner while waiting for fetching chart
function loadChartSpinner(chart) { $(chart).css("display", "none"); var parent = chart.parentElement; var spinner = $(parent).find($(".loading-spinner")); $(spinner).fadeIn("fast"); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function startLoading() {\n setStatus( RateCheckerChart.STATUS_OKAY );\n _dataLoadedDom.classList.add( 'loading' );\n _dataLoadedDom.classList.remove( 'loaded' );\n }", "displayLoading(){\n $.showLoading({\n name: \"line-scale\"\n });\n }", "ngOnInit() {\n /** spinn...
[ "0.7276864", "0.67573446", "0.6694039", "0.6626349", "0.66194", "0.6570602", "0.6567367", "0.6562086", "0.65024066", "0.6439965", "0.64222693", "0.64201945", "0.64078045", "0.6406233", "0.64033234", "0.6361399", "0.634403", "0.633268", "0.6329325", "0.63085663", "0.63083297",...
0.7477897
0
Unload spinner after fetching chart
function unloadChartSpinner(chart) { var parent = chart.parentElement; var spinner = $(parent).find($(".loading-spinner")); $(spinner).fadeOut("fast"); $(chart).fadeIn("fast"); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function onAllApiDataLoaded() {\n $(\".spinner\").remove();\n }", "function stopLoadingIndicator(){\r\n\t$('#svg').hideLoading();\r\n\t$('#list').hideLoading();\r\n}", "closeLoading() {\n if (this.progressBar) {\n clearInterval(this.progressTimer);\n this.prog...
[ "0.74249285", "0.68304074", "0.67277753", "0.65568", "0.6470922", "0.64393157", "0.64297444", "0.6374673", "0.63731176", "0.6358584", "0.6358584", "0.6339816", "0.632735", "0.63070524", "0.63017464", "0.628213", "0.62788695", "0.6260688", "0.6252154", "0.6250425", "0.6248777"...
0.7811235
0
Backlog statistic / Format tblTaskBacklog and load data
function loadTaskBacklogTable(backlog_id) { var task = $(".note[data-type='2'][data-backlog-id='" + backlog_id + "']"); var tbody = $("#tblTaskBacklog tbody"); $(tbody).html(""); for (var i = 0; i < task.length; i++) { var relativeID = task[i].getElementsByClassName("item-id")[0].innerHTML; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function loadBacklogStat(backlog_id) {\n // Create stats\n var task = $(\".note[data-type='2'][data-backlog-id='\" + backlog_id + \"']\");\n\n var data = [0, 0, 0];\n for (var i = 0; i < task.length; i++) {\n switch (task[i].getAttribute(\"data-status\")) {\n case \"Standby\":\n ...
[ "0.6213649", "0.6127478", "0.58380836", "0.575636", "0.54916435", "0.5452125", "0.5440652", "0.52733946", "0.51848614", "0.5169576", "0.50608957", "0.50588083", "0.50454247", "0.50367004", "0.50321263", "0.5020075", "0.49897295", "0.4950332", "0.49482858", "0.49092633", "0.49...
0.56738365
4
10.2 Load and draw chat
function loadBacklogStat(backlog_id) { // Create stats var task = $(".note[data-type='2'][data-backlog-id='" + backlog_id + "']"); var data = [0, 0, 0]; for (var i = 0; i < task.length; i++) { switch (task[i].getAttribute("data-status")) { case "Standby": data[0]++; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function load_chat(response)\n{\n\t// Prepare Values\n\tvar chatInner = document.getElementById(\"chat-inner\");\n\t\n\t// If there is no response this interval:\n\tif(!response)\n\t{\n\t\t// If the chat interval is less than 30 seconds long, add 1 tick to the interval\n\t\tif(timers.chat.interval < 120) { timers....
[ "0.68362427", "0.6771712", "0.6669105", "0.66038585", "0.6549843", "0.6494181", "0.6489949", "0.6455985", "0.6448732", "0.6385964", "0.6379747", "0.63476753", "0.6341807", "0.63156986", "0.63045824", "0.62992734", "0.62897074", "0.628446", "0.6248768", "0.6230773", "0.6229185...
0.0
-1
10.3 Show dialogBacklogStat window
function viewBacklogStat(obj, backlog_id) { loadBacklogStat(backlog_id); var windowHeight = window.innerHeight || document.documentElement.clientHeight; var windowWidth = window.innerWidth || document.documentElement.clientWidth; var offset = $(obj).offset(); var top = (offset.top > windowHeight - 2...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function fOpenShowBackupWindow(){\n\tvar\n\tmyDiv = document.createElement('div'),\n\ttext = '';\n\n\ttext += '<div id=\"ShowBackupTitle\"/>'+\n\t\t\t\t\t'备选基站 <span id=\"ShowBackupNum\"/>0</span>'+vCurCCells.length+'个</div>';\n\ttext += '<div class=\"ShowBackupContent\"/>'+\n\t\t\t\t\t'<input type=\"button\" id=\...
[ "0.6168356", "0.5933956", "0.592207", "0.58879423", "0.5841211", "0.5802789", "0.5797065", "0.57187736", "0.5704425", "0.5695348", "0.56687313", "0.56687313", "0.5667595", "0.5628692", "0.5595213", "0.55866534", "0.5579052", "0.55760014", "0.55363566", "0.5529544", "0.5523639...
0.63588834
0
10.4 Hide dialogBacklogStat window
function hideBacklogStat() { backlogStat.destroy(); $("#diaglogBacklogStat").removeClass("show"); setTimeout(function () { $("#diaglogBacklogStat").css("display", "none"); }, 150) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function hideWait() {\n waitingForReply=false;\n hideField(\"wait\");\n hideField(\"waitLogin\");\n if (window.top.document.getElementById(\"dialogInfo\")) {\n window.top.document.getElementById(\"dialogInfo\").style.visibility='hidden';\n }\n}", "function fnhideInformation()\r\n\t\t{\r\n\t...
[ "0.7011189", "0.6969613", "0.6878335", "0.68410003", "0.6817034", "0.677534", "0.67208344", "0.666187", "0.657267", "0.65591526", "0.6544408", "0.6537385", "0.65339416", "0.65123963", "0.65032065", "0.6500104", "0.6491397", "0.6444175", "0.6424012", "0.6398214", "0.63912916",...
0.7264932
0
11.1.1 Show swimlane window with all information of current swimlanes
function showSwimlaneWindow() { $("#currentSwimlane").html(""); var sw = $("#kanban th"); for (var i = 0; i < sw.length; i++) { // Attributes var name = $(".swName", sw[i]).html(); var id = $(sw[i]).attr("data-id"); var type = $(sw[i]).attr("data-type"); var objtext...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "showSettings() {\n // Implement in your WM\n }", "function getSwimlaneDisplay(name, id, type) {\n // Visual\n var objtext = \"<li class='swimlane' data-id='\" + id + \"'><span class='ui-icon ui-icon-arrowthick-2-n-s'></span>\" +\n \"<span class='swName'>\" + name + \"</span>\";\n\n //...
[ "0.6628136", "0.6545177", "0.615312", "0.6126486", "0.61084896", "0.607441", "0.60365146", "0.6026735", "0.60147566", "0.5975951", "0.5957452", "0.5870749", "0.5850358", "0.58415383", "0.582723", "0.58192325", "0.5814011", "0.5809511", "0.58003753", "0.57839614", "0.57498723"...
0.80976105
0
11.1.2 Get representative box of swimlane
function getSwimlaneDisplay(name, id, type) { // Visual var objtext = "<li class='swimlane' data-id='" + id + "'><span class='ui-icon ui-icon-arrowthick-2-n-s'></span>" + "<span class='swName'>" + name + "</span>"; // Don't allow edit done swimlane if (parseInt(type) != 3) { obj...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getLogicalBox() {\n let rv = {};\n if (!this.updatedMetrics) {\n this._calculateBlockIndex();\n }\n const adjBox = (box) => {\n const nbox = svgHelpers.smoBox(box);\n nbox.y = nbox.y - nbox.height;\n return nbox;\n };\n this.blocks.forEach((block) => {\n if (!rv.x) {\n ...
[ "0.7152083", "0.6493675", "0.64745104", "0.6195824", "0.6154021", "0.6103979", "0.6054218", "0.5970808", "0.5945631", "0.58319193", "0.5817558", "0.5815788", "0.57841474", "0.5777977", "0.5724486", "0.5707159", "0.5679191", "0.5673834", "0.56687474", "0.5651392", "0.56346184"...
0.5377277
54
11.2.1 Load info of a swimlane to textbox to edit and update
function editSwimlane(id) { var sw = $("#kanban th[data-id='" + id + "']"); $(".input-sw.txtName").val($(".swName", sw).html()); $(".input-sw.ddlType").val($(sw).attr("data-type")).attr("disabled", "disabled"); $(".input-sw.ddlDataStatus").val($(sw).attr("data-status")).attr("disabled", "disabled"); ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function showCurrentLangData(){\n document.getElementById('title').value=point.currentLangData.title;\n document.getElementById('prim').value=point.currentLangData.prim;\n document.getElementById('primsaf').value=point.currentLangData.primsaf;\n autosize.update(document.getElementById('primsaf'));\n ...
[ "0.6046388", "0.5996876", "0.59726745", "0.59637564", "0.59559715", "0.5951165", "0.5944851", "0.59205925", "0.59015113", "0.58203673", "0.5801046", "0.57704765", "0.5763784", "0.5756915", "0.5729348", "0.57190704", "0.5718771", "0.56976223", "0.56837577", "0.56566983", "0.56...
0.6092199
0
11.2.2 Reset swimlane form
function resetSwForm() { $(".input-sw.txtName").val(""); $(".input-sw.ddlType").val("1").removeAttr("disabled"); $(".input-sw.ddlDataStatus").val("Standby").removeAttr("disabled"); $("#btnAddSw").val("Add").attr("onclick", "addSwimlane()"); $("#btnCancelSw").val("Close").attr("onclick", "showView(0)...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function reset() {\n if (settings) {\n var lock = settings.createLock();\n for (var i = 0; i < fields.length; i++) {\n (function(input) {\n var key = input.dataset.setting;\n var request = lock.get(key);\n request.onsuccess = function() {\n ...
[ "0.737241", "0.7296105", "0.7244663", "0.7244663", "0.71595424", "0.71546495", "0.71280617", "0.7084821", "0.7057178", "0.7049844", "0.70336497", "0.70228255", "0.7022766", "0.70220125", "0.70010453", "0.69804245", "0.69762725", "0.69737357", "0.69687223", "0.6960744", "0.695...
0.7449806
0
11.3.1 Add new swimlane
function addSwimlane() { showProcessingDiaglog(); var sw = new Swimlane(); $.ajax({ url: "Handler/SwimlaneHandler.ashx", data: { action: "addSwimlane", projectID: projectID, swimlane: JSON.stringify(sw) }, type: "post", success: fun...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function addSWtoBoard(sw) {\n // Add swimlane in swimlane management window\n var objtext = getSwimlaneDisplay(sw.Name, sw.Swimlane_ID, sw.Type);\n $(\"#currentSwimlane\").append(objtext);\n\n // Add swimlane in kanban board\n var table = (sw.Type == 1) ? \"backlog\" : \"task\";\n var id = sw.Swi...
[ "0.68512094", "0.61688507", "0.57455057", "0.57350695", "0.57000166", "0.5501438", "0.5483024", "0.542815", "0.54105085", "0.53480476", "0.53170264", "0.53003895", "0.5240855", "0.5228336", "0.5208079", "0.520536", "0.5197776", "0.51911074", "0.51782364", "0.51729935", "0.515...
0.7402656
0
11.3.2 Add visual swimlane
function addSWtoBoard(sw) { // Add swimlane in swimlane management window var objtext = getSwimlaneDisplay(sw.Name, sw.Swimlane_ID, sw.Type); $("#currentSwimlane").append(objtext); // Add swimlane in kanban board var table = (sw.Type == 1) ? "backlog" : "task"; var id = sw.Swimlane_ID; var ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "addDataVisuals () {\n }", "function createVisualPanel() {\n const articleVisualElAll = document.querySelectorAll('.element-image:not(.header-image), .element-interactive, .element-atom--media');\n\n const visualPanelEl = document.createElement('div');\n const visualPanelInnerEl = document.createElement('div'...
[ "0.648991", "0.6345586", "0.62822086", "0.6239157", "0.60110205", "0.5942932", "0.5847008", "0.5847008", "0.5829896", "0.5770179", "0.57510597", "0.5740157", "0.57375944", "0.5711525", "0.5688133", "0.568221", "0.55929506", "0.55863494", "0.5568075", "0.5567448", "0.5548277",...
0.5575695
18
11.4.1 Update swimlane info
function updateSwimlane(id) { showProcessingDiaglog(); var sw = new Swimlane(); sw.Swimlane_ID = id; $.ajax({ url: "Handler/SwimlaneHandler.ashx", data: { action: "updateSwimlane", projectID: projectID, swimlane: JSON.stringify(sw) }, t...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function updateSWinBoard(id, name) {\n // In swimlane management window\n $(\".swimlane[data-id='\" + id + \"'] .swName\").html(name);\n\n // Update in the board\n $(\"#kanban th[data-id='\" + id + \"'] .swName\").html(name).attr(\"title\", name);\n}", "updateSettings() {\n this.updateTuneClasses(...
[ "0.59962034", "0.56679374", "0.56228215", "0.5575537", "0.55484545", "0.550083", "0.5497692", "0.54793847", "0.5477188", "0.54757166", "0.54455125", "0.5443513", "0.54216856", "0.5404194", "0.5372729", "0.5336356", "0.53282547", "0.5308181", "0.5297066", "0.5293275", "0.52814...
0.59078103
1
11.4.2 Update visual data swimlane
function updateSWinBoard(id, name) { // In swimlane management window $(".swimlane[data-id='" + id + "'] .swName").html(name); // Update in the board $("#kanban th[data-id='" + id + "'] .swName").html(name).attr("title", name); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function updateGUI() {\n\tvar dataLayer = $(\"#dataTypeSelect\").val();\t\n\tshowHideScenarioButtons(dataLayer);\n\tupdateTimePeriodLabels(dataLayer);\n\tupdateStoryWindow();\n\t\n\tif(dataLayer === \"maxSWE\") {\n\t\tmakeChartWindow();\n\t} else {\n\t\t$(\"#chartWindow\").remove();\n\t\t$(\"#showChartButton\").hi...
[ "0.66293174", "0.652999", "0.6500516", "0.6360312", "0.6217544", "0.6197221", "0.61670864", "0.6138687", "0.6125503", "0.61070585", "0.60840625", "0.60524905", "0.60360736", "0.5993342", "0.5943563", "0.58926284", "0.5870571", "0.5854325", "0.5848661", "0.58388513", "0.583257...
0.55412817
74
11.5.2 Delete visual swimlane
function deleteSWinBoard(id) { $(".swimlane[data-id='" + id + "']").remove(); $("#kanban th[data-id='" + id + "']").remove(); $("#kanban td[data-id='" + id + "']").remove(); recalibrate(); $(".window-content").perfectScrollbar("update"); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function clearVisuals() {\n tabBtns.forEach((tab) => {\n tab.classList.remove(\"selected\");\n });\n hrtab.classList.add(\"hidden\");\n wktab.classList.add(\"hidden\");\n settingstab.classList.add(\"hidden\");\n}", "function deleteFigure() {\n var figDel = STACK.figureGetById(selectedFigureId);\n i...
[ "0.64640236", "0.6420983", "0.6364725", "0.6266425", "0.6213539", "0.61906236", "0.61878884", "0.61819315", "0.61819315", "0.61743844", "0.6135085", "0.60767275", "0.60736805", "0.6069986", "0.6047124", "0.604205", "0.6038547", "0.60259825", "0.60246944", "0.6015187", "0.6004...
0.6621282
0
11.6.1 Save swimlane position
function saveSwimlanePosition(id, position) { $.ajax({ url: "Handler/SwimlaneHandler.ashx", data: { action: "updatePosition", projectID: projectID, swimlaneID: id, pos: position }, type: "get" }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function savePosition()\r\n{\r\n\tvar pos = getPosition();\r\n\tMZ_setValue(numTroll+\".position.X\",pos[0]);\r\n\tMZ_setValue(numTroll+\".position.Y\",pos[1]);\r\n\tMZ_setValue(numTroll+\".position.N\",pos[2]);\r\n}", "function saveRowLayout() {\n var indexes = [];\n $tableBody.children(tableRowXP...
[ "0.6368709", "0.6106207", "0.60594076", "0.59941125", "0.5889843", "0.5841861", "0.5826567", "0.57549524", "0.57477725", "0.57218665", "0.5709189", "0.56395555", "0.55416054", "0.5537076", "0.5500998", "0.5483554", "0.54776293", "0.54462713", "0.54361665", "0.54298824", "0.54...
0.5558088
12
11.6.2 Update visual position of swimlane in kanban
function changeSwPosition(org, target) { // Update position in kanban board if (target < org) { $("#kanban th:eq(" + org + ")").insertBefore( $("#kanban th:eq(" + target + ")")); $("#kanban td:eq(" + org + ")").insertBefore( $("#kanban td:eq(" + target + ")"...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function changeLayout() {\r\n // Remove the buddy icon\r\n if (!showBuddyIcon) {\r\n $('table.launchHead').remove();\r\n\t\tGM_addStyle('#Main {margin-top: 15px ! important; }');\r\n }\r\n\r\n // Dynamic width of homepage contents\r\n if (dynamicWidth) {\r\n GM_addStyle(\r\n ...
[ "0.58190566", "0.5674475", "0.5623723", "0.5576071", "0.5564721", "0.55286247", "0.5513095", "0.55016154", "0.5496079", "0.5467477", "0.5406545", "0.5390776", "0.5385928", "0.5384051", "0.53619397", "0.535584", "0.5347924", "0.5340258", "0.53282815", "0.5306028", "0.53033584"...
0.57597095
1
Notification center New swimlane message
function msgNewSw(sender, name) { content = "<div class='noti-msg'><img src='" + sender.Avatar + "' class='noti-msg-avatar' />" + "<div class='noti-msg-content'><span class='subject'>" + sender.Name + "</span> added new swimlane " + "<i>" + name + "</i></div>"; pushNoti(content); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function addNotification() {\n var unread = document.getElementById(\"unread\");\n var newUnread = unread.cloneNode(true);\n var bell = document.getElementById(\"bell\");\n var newBell = bell.cloneNode(true);\n var notification_container = document.getElementById(\"notification_c...
[ "0.6245678", "0.62379634", "0.62370723", "0.62198067", "0.6163937", "0.6163126", "0.615684", "0.6155944", "0.61448246", "0.6140102", "0.61268693", "0.6124265", "0.6118274", "0.60969776", "0.60611475", "0.60506004", "0.60506004", "0.60502815", "0.60370195", "0.6009828", "0.600...
0.6657544
0
Change name swimlane message
function msgEditSw(sender, from, to) { content = "<div class='noti-msg'><img src='" + sender.Avatar + "' class='noti-msg-avatar' />" + "<div class='noti-msg-content'><span class='subject'>" + sender.Name + "</span> change a swimlane name from " + "<i>" + from + "</i> to <i>" + to + "</i></div>"; p...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function changeNameInHeader() {\n $headerName.html('Todo list for ' + $TaskName.val());\n }", "function updateName() { changeTextField(name, nameLabel, isValidName()) }", "correctName() {\n\t\tthis.name = this.stringCorrector.getMon(this.name);\n\t}", "handlebutton(name) {\n addUserMessage(n...
[ "0.6556968", "0.64639705", "0.6409069", "0.63385236", "0.63157403", "0.62550557", "0.624265", "0.62140185", "0.6184301", "0.61658114", "0.6121838", "0.6057261", "0.60488725", "0.60391575", "0.6036792", "0.60233945", "0.60208863", "0.6001906", "0.5997992", "0.59620136", "0.594...
0.0
-1
Change position swimlane message
function msgChangePosSw(sender, name) { content = "<div class='noti-msg'><img src='" + sender.Avatar + "' class='noti-msg-avatar' />" + "<div class='noti-msg-content'><span class='subject'>" + sender.Name + "</span> changed position of swimlane " + " <i>" + name + "</i></div>"; pushNoti(content)...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function moveChatBelow() {\r\n overrideElems.forEach(function(elem){\r\n document.querySelector(elem).classList.remove(\"swSide\");\r\n document.querySelector(elem).classList.add(\"swBel\");});\r\n $(\".chatpositionswitcher\").hide();\r\n $(\".chatpositionswitcherON\").sh...
[ "0.64957285", "0.635677", "0.62855554", "0.62300324", "0.6147836", "0.5943856", "0.59045005", "0.5860932", "0.5839839", "0.5766554", "0.5755812", "0.571215", "0.5664991", "0.5656474", "0.56483364", "0.5645044", "0.5642954", "0.56307906", "0.5603549", "0.55885106", "0.55823225...
0.729536
0
When the owner of the project delete the project or kick the user then do this
function redirectAfterDeleting(pid, name, reason) { if (pid == projectID) { $(".diaglog.error").fadeIn(200).addClass("show"); $(".diaglog.error .btnOK").hide(); var content = "<strong>" + name + "</strong> has " + reason + " this project.</br></br>" + "Redirect to Project page in...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function deleteProject() {\n if (window.confirm(\"Are you sure you want to delete this project?\")) {\n const { id, email, password } = user\n service.deleteProject(id, email, password).then(() => {\n history.push(\"/\")\n })\n }\n }", "run(args) {\n //console.log(\"%s run: ar...
[ "0.64997315", "0.6197166", "0.6053348", "0.594726", "0.58887535", "0.5857727", "0.5852091", "0.5821774", "0.58160627", "0.58140796", "0.5793606", "0.57925445", "0.57661444", "0.5733606", "0.57286954", "0.5723945", "0.57039917", "0.5689214", "0.56678563", "0.56512064", "0.5650...
0.0
-1
Handles d3 initialization and checks whether the dependency is available or not.
initialize() { if (!d3) { throw new Error('D3 is not imported and Francy won\'t work without it... please import D3 v5+ library.'); } Logger.debug('D3 is available...'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function init() {\n\n svg = d3\n .select(\"#d3-container-1\")\n .append(\"svg\")\n\n draw(); // calls the draw function\n }", "function onScriptLoad () {\n $rootScope.$apply(function () { deferred.resolve(window.d3); });\n }", "function ZooT_3DInit() {\n __zoot_c3d__process_DOM();\n}", ...
[ "0.65506893", "0.63025147", "0.613414", "0.6030578", "0.5929036", "0.58996433", "0.58243495", "0.58177257", "0.5757345", "0.57561755", "0.57364655", "0.57284385", "0.5726091", "0.57109463", "0.5710342", "0.5698865", "0.5696751", "0.5690108", "0.566443", "0.56558836", "0.56431...
0.7816011
0
reload teacher attendance on click
function reloadteaatt() { $.ajax({ type:'POST', url: 'tea_attendance.php', data:{}, success: function(data){ $('#no').html(data); }, error:function (){} }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function saveTeacher(){\n teacher = true;\n }", "async function saveTeachers(e) {\n e.preventDefault();\n const newData = await API.updateStudentsTeachers(checkTeachers);\n console.log(\"Student's teachers updated...printing new data...\", newData.data);\n // setUserState({\n // type: newDat...
[ "0.58840704", "0.5874487", "0.580996", "0.5796991", "0.5732755", "0.56549054", "0.5645075", "0.564453", "0.55464345", "0.54849935", "0.5436141", "0.540027", "0.5395795", "0.5353049", "0.5332691", "0.53255713", "0.5317048", "0.5314545", "0.52964884", "0.5284106", "0.52707046",...
0.6650372
0
go back to home
function backtohome() { $.ajax({ type:'POST', url: 'backtohome.php', data:{}, success: function(data){ $('#menu-12').html(data); }, error:function (){} }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function returnToHome(){\n\t\n}", "function goBackOrGoHome() {\n if(WinJS.Navigation.canGoBack) {\n WinJS.Navigation.back();\n }\n else {\n navigate('home');\n }\n }", "function backToHomeView () {\n currentFolder = -1\n showOneContainer(homeContain)\n...
[ "0.81200504", "0.7887944", "0.7883397", "0.7797984", "0.7705506", "0.7672751", "0.7657057", "0.76536965", "0.7641366", "0.7631465", "0.76167125", "0.759704", "0.75547254", "0.75330526", "0.75316346", "0.7513984", "0.74935985", "0.7456699", "0.7456699", "0.7456699", "0.7445984...
0.0
-1
go to dat for routine
function gotoday(alt) { $('#hellofday').html('<img src=img/loader.gif style="margin-top: 25%;">'); $.ajax({ type:'POST', url: 'routineday.php', data:{today:alt}, success: function(data){ $('#hellofday').html(data); }, error:function (){} }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function loopData() {\n\n}", "function get_data_loop()\r\n{\r\n if(!ansvers){\r\n \tget_data();\r\n \tansvers = 1;\r\n }\r\n \tsetTimeout(\"get_data_loop()\",10000);\r\n}", "function loopingData2() {\n\n}", "function senGuiData()\n{\n\tvar datasend={\n\t\tevent:\"guidata\"\n\t}\n\tqueryDataGet(\"php/api_proc...
[ "0.6181406", "0.59037006", "0.57992864", "0.5788949", "0.57109374", "0.5666051", "0.5612348", "0.5612348", "0.55453473", "0.55453473", "0.5543909", "0.54896384", "0.54896384", "0.54896384", "0.5420713", "0.5410149", "0.53890055", "0.5369998", "0.5349026", "0.53376293", "0.532...
0.0
-1
progress on transfers from the server to the client (downloads)
function updateProgress (oEvent) { if (oEvent.lengthComputable) { $("button, input").prop("disabled",true); var percentComplete = oEvent.loaded / oEvent.total; console.log("Loading music file... " + Math.floor(percentComplete * 100) + "%"); $("#loading").html("Loading... " + Math.floor(percentComplete * 100) +...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function transferProgressCallback(transferObject, numBytesSent, numBytesTotal, estimatedTimeRemaining) {\n var percent = Math.round((numBytesSent / numBytesTotal) * 100);\n $(\"#contentUploadText\").html(percent + \"% uploaded<p>Completes in about \" + moment.duration(estimatedTimeRemaining * 1000).humanize(...
[ "0.7169936", "0.675747", "0.66730195", "0.6643107", "0.6405057", "0.6405057", "0.6405057", "0.6402697", "0.6356231", "0.63561004", "0.62947476", "0.6279575", "0.622525", "0.6218713", "0.6198738", "0.6198738", "0.6174756", "0.61563784", "0.6140004", "0.61275804", "0.6115606", ...
0.0
-1
PUT THIS STUFF IN A SIAF
function singleTemplate(imageName){ return "<img class='main' src='images/" + imageName + "'>"; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private internal function m248() {}", "private public function m246() {}", "function JFather() {\r\n\t}", "transient final protected internal function m174() {}", "protected internal function m252() {}", "function sf(){}", "function wa(){}", "transient protected internal function m189() {}", "funct...
[ "0.6086821", "0.59477764", "0.58514285", "0.56830704", "0.5581475", "0.5559655", "0.54826987", "0.5476168", "0.54752845", "0.5449451", "0.5442491", "0.538828", "0.5340937", "0.5335771", "0.533091", "0.531933", "0.5297901", "0.5282978", "0.5275525", "0.5272609", "0.52598476", ...
0.0
-1
add in state to track current selected channel
defaultWrapperFocus(channelId) { let currChannelPath = this.props.match.params.channelId; if (currChannelPath === JSON.stringify(channelId)) { return "channelContentSelected"; } else { return "channelContent"; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@track((undefined, state) => {\n return {action: `enter-attempt-to-channel: ${state.channel.name}`};\n })\n enterChannel(channel){\n\n let addNewMessage = this.props.addNewMessage;\n let updateMessage = this.props.updateMessage;\n\n sb.OpenChannel.getChannel(channel.url, (channel, error) => {\n ...
[ "0.6686637", "0.666606", "0.6657704", "0.6385423", "0.6361085", "0.62726396", "0.6271718", "0.6231164", "0.62108743", "0.6012108", "0.6005465", "0.5994493", "0.5994259", "0.5993198", "0.5965095", "0.59592843", "0.5954635", "0.5938415", "0.592306", "0.58923733", "0.58759356", ...
0.0
-1
Combine the baseUrl, genre, and year together to create a complete url with the right query parameters. Then return the url. Check out examples query params at
function buildQueryString(genre, language, year){ return `${baseAPIUrl}&with_genres=${genre}&primary_release_year=${year}&with_original_language=${language}&sort_by=revenue.desc`; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async function makeUrl(genre, releaseYear, runtime) {\n await computeGenre(genre);\n await computeYear(releaseYear);\n await computeTime(runtime);\n \n \n let api_url = `https://api.themoviedb.org/3/discover/movie?with_original_language=en${parseGenre}${parseYear}${parseTime}&sort_by=popularity.d...
[ "0.6756152", "0.6756152", "0.65191996", "0.64742595", "0.63907814", "0.62726414", "0.62207437", "0.6198448", "0.6123757", "0.6115374", "0.60516936", "0.5989583", "0.5985787", "0.59821975", "0.5981985", "0.5978049", "0.5945591", "0.59369516", "0.59205127", "0.5879472", "0.5858...
0.77001506
0
Call this function with the data object that comes back from getJSON
function afterDataLoaded(dataObject){ // All images have this base URL var posterBaseUrl = "https://image.tmdb.org/t/p/w500" // store API data in Global Scope (client side) localData = dataObject; /* Loop over the results in the dataObject. HINT: use your debugger to find the name of the property...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function jsonData() {\n getJSONP(jsonLink, function(data) {\n fillList(data);\n });\n}", "loadJsonData() {\n }", "function setData (jsonData) { //we create a function to call later when the data is retrieved from the server in a new variable\n data = jsonData; // this is also called deserial...
[ "0.69713277", "0.693672", "0.6823031", "0.6714532", "0.66568726", "0.6625304", "0.6562954", "0.6528886", "0.6379441", "0.6354121", "0.63437635", "0.6329572", "0.62453747", "0.62452585", "0.61985254", "0.6190922", "0.6172134", "0.61708605", "0.6169103", "0.61656547", "0.616353...
0.0
-1
Get Block By Height
async getBlock (height) { const json = await this.chainStore.get(height) if (this.logLevel >= 2) console.log('block data for ' + height + ': ' + json) return JSON.parse(json) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getBlockByHeight(blockHeight) {\n try {\n return this.db.getLevelDBData(blockHeight)\n } catch (error) {\n console.error(error)\n }\n }", "getBlock(blockheight) {\n return this.chain.get(this.lexi(blockheight))\n .then((block) => {\n return JSON.parse(block);\n });\n }", ...
[ "0.73870385", "0.73455936", "0.73064876", "0.7247599", "0.7223613", "0.7216959", "0.717925", "0.71272117", "0.7007219", "0.70052457", "0.6990343", "0.69874924", "0.69666386", "0.6938851", "0.6937033", "0.6928839", "0.6885524", "0.6870916", "0.6853841", "0.68460965", "0.678911...
0.7000245
10
Get Block by its hash
async getBlockByHash (hash) { return this.chainStore.getByHash(hash) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getBlockByHash(hash) {\n return this.db.getBlockByHash(hash);\n }", "async getBlockByHash(hash) {\r\n try {\r\n // Get block height\r\n let height = await this.getBlockHeight();\r\n\r\n for (var i = 1; i <= height; i++)\n {\n let targetHashBlo...
[ "0.8228084", "0.8081457", "0.80458516", "0.8024594", "0.80000556", "0.7969649", "0.78784883", "0.78464353", "0.7843984", "0.7817416", "0.7809391", "0.77981824", "0.76831573", "0.754503", "0.75379425", "0.75366193", "0.7404194", "0.73791105", "0.73379225", "0.73340917", "0.727...
0.8354271
0
Get block height, it is auxiliar method that return the height of the blockchain
async getBlockHeight () { return this.chainStore.countNumEntries() }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async getBlockHeight() {\n\t\treturn await chaindb.getBlockHeight().then((height) => { return height; }).catch(error => { throw error; });\n\t}", "async getBlockHeight () {\n return await this.getBlockHeightLevel()\n }", "async getBlockHeight() {\n\t\treturn await this.bd.getBlocksCount();\n\t}", "getBlo...
[ "0.8404184", "0.81468153", "0.80094063", "0.77392167", "0.773802", "0.77232736", "0.75898516", "0.7557202", "0.7546895", "0.7437176", "0.73472553", "0.72774005", "0.7272452", "0.72073466", "0.7145288", "0.7107371", "0.6999558", "0.69855505", "0.6944961", "0.685618", "0.685144...
0.74175
10
Validate if Block is being tampered by Block Height
async validateBlock (height) { var block = await this.getBlock(height) const originalHash = block.hash block.hash = '' return originalHash === this.getHash(block) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "validateBlock(height) {\n // Add your code here\n // get block object\n let block = this.getBlock(blockHeight);\n // get block hash\n let blockHash = block.hash;\n // remove block hash to test block integrity\n block.hash = '';\n // generate block hash\n let v...
[ "0.7536371", "0.7454925", "0.7340291", "0.7293968", "0.71957767", "0.716315", "0.7083623", "0.7023425", "0.6738329", "0.67095625", "0.6608089", "0.6581837", "0.6578328", "0.6549188", "0.6547058", "0.6535181", "0.6252507", "0.6240716", "0.6227588", "0.62208176", "0.62176883", ...
0.75058913
1
Utility Method to Tamper a Block for Test Validation This method is for testing purpose
async _modifyBlock (height, block) { let self = this return new Promise((resolve, reject) => { self.chainStore.addLevelDBData(height, JSON.stringify(block)) .then((blockModified) => { resolve(blockModified) }).catch((err) => { console.log(err); reject(err) }) }) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "tamperBlock() {\n const self = this\n return new Promise(function(resolve, reject) {\n self.myBlockChain.getBlock(5).then((block) => {\n let blockAux = block;\n self.myBlockChain._modifyBlock(blockAux.height, blockAux).then((blockModified) => {\n if(blockModified){\n se...
[ "0.67275935", "0.6238755", "0.6177759", "0.6158477", "0.6108975", "0.60628533", "0.6043047", "0.6021675", "0.5996323", "0.5915504", "0.5873659", "0.5844542", "0.5785661", "0.57770383", "0.5758525", "0.5758382", "0.57411164", "0.5724199", "0.57190925", "0.56925964", "0.5684112...
0.0
-1
pixel color values of the reference image
function preload() { // referenceImage = loadImage('mondrian.jpg'); referenceImage = loadImage('reference.jpg'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function colorDiff(reference, pixel) {\n var r = reference[0] - pixel[0]\n var g = reference[1] - pixel[1]\n var b = reference[2] - pixel[2]\n\n return Math.abs(r) + Math.abs(g) + Math.abs(b)\n}", "function getPixelColor(img, x, y) {\n var data = img.data;\n var offset = ((y * (img.width * 4)) ...
[ "0.70904595", "0.69493014", "0.6772581", "0.66782427", "0.6582531", "0.6557623", "0.64807045", "0.6440409", "0.63695943", "0.63540953", "0.63287854", "0.6319834", "0.63144845", "0.6296929", "0.6259288", "0.6247108", "0.62360877", "0.6222256", "0.6222151", "0.61990356", "0.618...
0.0
-1
A plugin for testing the `dirdependency` message handling.
function testDirDep() { return { postcssPlugin: 'dir-dep', AtRule(atRule, { result, Comment }) { if (atRule.name === 'test') { const pattern = normalizePath( path.resolve(path.dirname(result.opts.from), './glob-dep/*.css') ) const files = glob.sync(pattern) cons...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "dependencyLoaded (pkg) {\n this.loadedDepsProgress.tick({locationxxxxxxxxxxxxxxxxxx: pkg.location().substr(0, 'locationxxxxxxxxxxxxxxxxxx'.length)})\n }", "dependencyChanged(srcDir, dep) {\n let file = path.isAbsolute(dep[0]) ? dep[0] : path.join(srcDir, dep[0]);\n let hexDigest = dep[1];\n\n let ha...
[ "0.5411069", "0.53443265", "0.5011571", "0.49347246", "0.4878817", "0.47712868", "0.47308567", "0.46975735", "0.4695943", "0.4656798", "0.4634544", "0.45993885", "0.45988917", "0.45963702", "0.455346", "0.45359674", "0.4519176", "0.45145518", "0.45108223", "0.45036945", "0.45...
0.70054394
0
retrieve weather conditions for city entered by user
function getWeather() { var apiKey = ""; // query URL for city weather var queryURL = "https://api.openweathermap.org/data/2.5/weather?q=" + cityName + "&appid=" + apiKey; // API call for city weather $.ajax({ url: queryURL, method: "GET" }) .then(function (response) { ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getWeather() {\n var location = globals.location,\n usrInput = $('.input-div input').val() || '';\n\n getCityWeather(usrInput, location);\n getCityForecast(usrInput, location)\n\n }", "function getCondition() {\n // get current location\n $.getJSON(\n \"https://co...
[ "0.7815282", "0.76671475", "0.73007715", "0.72920465", "0.72296286", "0.7212685", "0.71868795", "0.7181452", "0.71488607", "0.7121885", "0.71030813", "0.7098734", "0.7089537", "0.70879996", "0.7086906", "0.707797", "0.7054263", "0.7021997", "0.6981536", "0.6981487", "0.698068...
0.65908694
67
search for similar key terms based on weather condition to use to get gif URLs
function getGifKeys() { var apiKey = ""; // use this API call to get collection of words similar to currentWeather var queryUrl = "https://api.giphy.com/v1/gifs/search/tags?q=" + currentWeather + "&limit=10&api_key=" + apiKey; $.ajax({ url: queryUrl, method: "GET" }) .then(...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function search(q){\n const apiKey = '60j6blu7K1BahTceUDM7FC8TRZ6QwbkF';\n const path = `https://api.giphy.com/v1/gifs/search?api_key=${apiKey}&q=${q}&limit=12`\n fetch(path).then(function(res) {\n return res.json()\n }).then(function(json){\n let resultsHTML = ''\n let tendencia;\...
[ "0.6221152", "0.6167599", "0.61081505", "0.60123336", "0.59946775", "0.59699726", "0.5956104", "0.59328836", "0.5910496", "0.58407253", "0.5839351", "0.5831687", "0.58279777", "0.5820497", "0.5793322", "0.57793903", "0.57731897", "0.5760029", "0.57222", "0.57190216", "0.56735...
0.6575937
0
using values from getGifKeys, search gifs, create tags and append to gallery
function createGif() { var apiKey = ""; for (var i = 0; i < weatherKeys.length; i++) { // query URLs for giphy search - testing out 2 different ones // var queryUrl = "https://api.giphy.com/v1/gifs/search?q=" + weatherKeys[0] + "&limit=10&api_key=" + apiKey; var queryUrl = "https://api...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getGifs(looneyName) {\n // let queryURL = `https://api.giphy.com/v1/gifs/search?api_key=dc6zaTOxFJmzC&limit=10&rating=g&q=${looneyName}`;\n let queryURL = `https://api.giphy.com/v1/gifs/search?q=${looneyName}&api_key=dc6zaTOxFJmzC&limit=10&rating=g`;\n $.ajax({\n url: queryURL,\n ...
[ "0.7368024", "0.72084296", "0.7021392", "0.70162845", "0.70100725", "0.69926333", "0.6984874", "0.6976227", "0.6938365", "0.69201934", "0.6876339", "0.6868316", "0.68674254", "0.6854373", "0.68458325", "0.68134695", "0.6811208", "0.6806044", "0.6803015", "0.6802386", "0.67911...
0.7120316
2
this is the "bar" for how close a correlation needs to be
function autoCorrelate( buf, sampleRate ) { var SIZE = buf.length; var MAX_SAMPLES = Math.floor(SIZE/2); var best_offset = -1; var best_correlation = 0; var rms = 0; var foundGoodCorrelation = false; var correlations = new Array(MAX_SAMPLES); for (var i=0;i<SIZE;i++) { var val = buf[i]; rms += val*val; } ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function toBarPerc(n) {\nreturn (-1 + n) * 100;\n}", "function calRadialBar(barSeries) {\n // Columns info on each category axis. Key is polar name\n var columnsMap = {};\n util[\"k\" /* each */](barSeries, function (seriesModel, idx) {\n var data = seriesModel.getData();\n var polar = seriesModel.coord...
[ "0.5914718", "0.5761647", "0.57567", "0.5734197", "0.5692795", "0.5644246", "0.5636063", "0.5625874", "0.5623799", "0.55974025", "0.55974025", "0.55974025", "0.55974025", "0.55479294", "0.5535995", "0.5535995", "0.5535995", "0.5535995", "0.5535995", "0.5535995", "0.5535995", ...
0.0
-1
Attaches a CSRF token to the request
function attachCsrfToken(url, cookie, value) { return (req, res, next) => { if (req.url == url) { res.cookie(cookie, value); } next(); }; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function attachCSRF(req, csrftoken) {\n if (shouldSendCSRF(req.method)) {\n req.headers['X-CSRFToken'] = csrftoken\n }\n return req\n}", "function setCsrfToken(request, response, next) {\n response.cookie('XSRF-TOKEN', request.csrfToken());\n next();\n}", "function handleCsrfToken(){\n var token...
[ "0.7761813", "0.74533945", "0.7143836", "0.7057959", "0.69849455", "0.68897116", "0.6889343", "0.6682586", "0.6641543", "0.6634894", "0.6621065", "0.657253", "0.654347", "0.65397054", "0.64774996", "0.6463975", "0.63771933", "0.6318861", "0.62406033", "0.61188257", "0.6105765...
0.6495986
14
Checks if a user is already signed in and if so, redirect to home page
function checkIfSignedIn(url) { return (req, res, next) => { if (req.url == url) { const sessionCookie = req.cookies.session || ''; verifySession(sessionCookie) .then(decodedClaims => { res.redirect(process.env.CLIENT_URL); }) .catch(error => { next(); ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function checkLoggedIn() {\n if (window.location.pathname == \"/\" || window.location.pathname == \"/Register\") {\n if (getUsernameCookie() != \"\") {\n window.location.pathname = \"/Homepage\";\n }\n } else {\n if (getUsernameCookie() == \"\") {\n window.location.pathname = \"/\";\n }\n ...
[ "0.7419069", "0.73446053", "0.73406214", "0.72419345", "0.72087324", "0.71145916", "0.709413", "0.7091637", "0.7045491", "0.7021566", "0.69878453", "0.6960646", "0.69550544", "0.69393885", "0.6931547", "0.6930198", "0.69221014", "0.692127", "0.691604", "0.69019705", "0.689752...
0.0
-1
Create the HTML to hold a private conversation between two users
function createPrivateConversationRoom(penPal) { // Get the ID of the HTML element for this private convo, if there is one var roomName = 'private-room-'+penPal.id; // If HTML for the room already exists, return. if ($('#'+roomName).length) { return; } var penPalName = penPal.name == "unknown" ? ("Us...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function printConversation(conver) {\n const right = document.getElementById(\"right\");\n const sameConversationOpen = right.num === conver.num && right.querySelector(\"section.messages\");\n if (!sameConversationOpen) {\n // if it's not the same conversation we do not need to be careful to not override the...
[ "0.6585164", "0.6424574", "0.63490105", "0.6302306", "0.6155063", "0.5989231", "0.5958475", "0.59479994", "0.5921495", "0.5921298", "0.58756506", "0.5865235", "0.5837759", "0.58185995", "0.58153194", "0.5808057", "0.5760151", "0.5749923", "0.5748984", "0.57460576", "0.5689310...
0.6396308
2
Callback for when the user clicks the "Send message" button in a private conversation
function onClickSendPrivateMessage(e) { // Get the button that was pressed var button = e.currentTarget; // Get the ID of the user we want to send to var recipientId = button.id.split('-')[2]; // Get the message to send var message = $('#private-message-'+recipientId).val(); $('#private-message-'+recip...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function onSendClicked() {\n var target=vw.getPeerName();// NOT from mc.userParams.targetUsername, so that you can chat and speak with different users \n if ( ! target) {\n //vw.showAlert(\"Peer user name required\");\n alert(\"Peer user name required\");\n return false;\n }\n var msg = {\n text: ...
[ "0.7605406", "0.73025596", "0.7128854", "0.701351", "0.7012243", "0.6974718", "0.6962912", "0.69262236", "0.69199896", "0.6887332", "0.6842395", "0.6841257", "0.68374914", "0.6804129", "0.6802686", "0.6738178", "0.6738178", "0.6738178", "0.6738178", "0.672473", "0.6711482", ...
0.7788356
0
Add HTML for a new message in a private conversation
function addMessageToConversation(senderId, recipientId, message) { var fromMe = senderId == window.me.id; var roomName = 'private-messages-' + (fromMe ? recipientId : senderId); var senderName = fromMe ? "Me" : $('#private-username-'+senderId).html(); var justify = fromMe ? 'right' : 'left'; var div = $('<...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function addPrivateMessageHTML(msg, isAuthor) {\n console.log(msg.nicknames);\n return $(isAuthor ? '<div class=\"msg-container private-message author\">' : '<div class=\"msg-container private-message\">')\n .append(`<div class=\"row\">\n ${!isAuthor ? `<p class=\"author-name privat...
[ "0.6917786", "0.67044115", "0.6673333", "0.66259515", "0.6622047", "0.6551283", "0.65318584", "0.6527578", "0.65274745", "0.6499943", "0.6498739", "0.64848423", "0.64785105", "0.6476066", "0.64624286", "0.6448321", "0.6442378", "0.6439375", "0.64304936", "0.64304537", "0.6425...
0.0
-1
Handle an incoming private message from the server.
function receivePrivateMessage(data) { var sender = data.from; // Create a room for this message if one doesn't exist createPrivateConversationRoom(sender); // Add a message to the room addMessageToConversation(sender.id, window.me.id, data.msg); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function receivedMessage(event) {\n messageHandler.handleMessage(event);\n }", "function receivePrivateMessage(event, data) {\n\n var sender = data.from;\n\n // Create a room for this message if one doesn't exist\n //createPrivateConversationRoom(sender);\n\n // Ad...
[ "0.6618694", "0.656879", "0.6405985", "0.6369745", "0.61029774", "0.5906615", "0.584421", "0.5842446", "0.5829584", "0.5815832", "0.58094615", "0.58092", "0.58045655", "0.57957137", "0.57892907", "0.57866997", "0.5775966", "0.5760952", "0.57554656", "0.5739252", "0.5733199", ...
0.63325644
4
an admin can send out an email to someone that when clicked, allows the user to create an account and automatically have cashier priviledges
function sendCashierInviteEmail(req, res) { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "sendEmail() {\n email([EMAIL], null, null, null, null);\n }", "async handle ({ name, email, token }) {\n const link = `${Env.get('URL_FRONT')}confirm?token=${token}`\n\n await Mail.send(\n ['mails.confirm_new_user', 'mails.confirm_new_user-text'],\n {\n name,\n email,\n t...
[ "0.6479439", "0.64688957", "0.6429719", "0.6397785", "0.63944054", "0.63725877", "0.63484967", "0.6304804", "0.6301761", "0.6285132", "0.6234316", "0.6222861", "0.6222784", "0.60871243", "0.6071756", "0.60234004", "0.6009375", "0.59995013", "0.5988557", "0.59733427", "0.59713...
0.64253193
3
Creates a set of bars for the given data node, at the specified index.
function bar(d) { var bar = svg.insert("g", ".y.axis") .attr("class", "enter") .attr("transform", "translate(0,5)") .selectAll("g") .data(d.children) .enter().append("g") .style("cursor", function (d) { return !d.children ? null : "pointer"; }) ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function addBars(parent, config, data) {\n var bars = parent.selectAll('g.bars')\n .data(data)\n .enter()\n .append('svg:g')\n .attr('transform', function (d, i) { return formatString('translate(0, {0})', config.y(i)); })\n .append('svg:rect')\n .attr('class', function ...
[ "0.68883747", "0.64110166", "0.6272019", "0.62121385", "0.6095658", "0.5949822", "0.59484303", "0.5942214", "0.58291817", "0.581634", "0.5802592", "0.5799465", "0.57862717", "0.5784548", "0.57642835", "0.5760384", "0.57230633", "0.5722844", "0.5722209", "0.5719925", "0.571368...
0.53594774
66
Send request to server and assign a callback
function processResponse(respObj) { totalPages = parseInt(respObj); showOnePageArticleList(type1, pageSize1, curPage, templateFileDir+"showArticleListByType.template", contentPos); var pagestr = ""; //var selectedIndex = document.getElementById("selectPage").selectedIndex+1; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "send(request, callback) {\n if (!request)\n callback('Undefined request');\n this.request(request)\n .then((result) => callback(null, { jsonrpc: '2.0', id: request.id, result }))\n .catch((error) => callback(error, null));\n }", "async send(request, response) {}"...
[ "0.7295607", "0.7010951", "0.6911083", "0.67787623", "0.6765163", "0.6735015", "0.66286904", "0.6601929", "0.65868884", "0.6485859", "0.64688534", "0.6423112", "0.6396494", "0.63565284", "0.63102865", "0.63098216", "0.62991214", "0.62934273", "0.62676406", "0.6231644", "0.621...
0.0
-1
Send request to server and assign a callback
function processResponse(respObj) { $(position1).html(respObj); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "send(request, callback) {\n if (!request)\n callback('Undefined request');\n this.request(request)\n .then((result) => callback(null, { jsonrpc: '2.0', id: request.id, result }))\n .catch((error) => callback(error, null));\n }", "async send(request, response) {}"...
[ "0.72960544", "0.70098054", "0.69123304", "0.6779859", "0.6766118", "0.6734541", "0.6629341", "0.66039973", "0.65875226", "0.64857227", "0.6469651", "0.6423202", "0.6398184", "0.63573855", "0.63111746", "0.63106555", "0.6301777", "0.6293919", "0.6268311", "0.6232416", "0.6219...
0.0
-1
//////////////////// Brush functions ////////////////////// /////////////////////////////////////////////////////////// First function that runs on a brush move
function brushmove() { var extent = brush.extent(); //Reset the part that is visible on the big chart var originalRange = main_yZoom.range(); main_yZoom.domain( extent ); ///////////////////////////////////////////////////////////// /////////////// Update the mini bar fills //////////////////...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function DrawBrush() {\r\n for (let i = 1; i < brushXPoints.length; i++) {\r\n ctx.beginPath()\r\n\r\n // Check if the mouse button was down at this point\r\n // and if so continue drawing\r\n if (brushDownPos[i]) {\r\n ctx.moveTo(brushXPoints[i-1], brushYPoints[i-1])\r\n ...
[ "0.7326504", "0.7263764", "0.7251124", "0.719147", "0.7185443", "0.70174855", "0.6989749", "0.6905786", "0.6879242", "0.684503", "0.68170226", "0.679825", "0.679825", "0.67670923", "0.6760393", "0.6743343", "0.6730744", "0.6699259", "0.66954345", "0.6672229", "0.6670272", "...
0.6528187
32
Based on What to do when the user clicks on another location along the brushable bar chart
function brushcenter() { var target = d3.event.target, extent = brush.extent(), size = extent[1] - extent[0], range = mini_yScale.range(), y0 = d3.min(range) + size / 2, y1 = d3.max(range) + mini_yScale.rangeBand() - size / 2, center = Math.max( y0, Math.min( y1, d3.m...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function ClickBarra() {\n\n var selectedItem = chart.getSelection()[0];\n if (selectedItem) {\n var planta = data.getValue(selectedItem.row, 0);\n click_grafica(planta);\n\n\n ...
[ "0.70979464", "0.6916284", "0.6720722", "0.65143263", "0.64719987", "0.6447514", "0.64435256", "0.64137554", "0.6407923", "0.63521945", "0.6341858", "0.6320099", "0.6296895", "0.6290442", "0.6284013", "0.6235459", "0.62257326", "0.621657", "0.6198094", "0.61769295", "0.615162...
0.0
-1
/////////////////// Scroll functions //////////////////////
function scroll() { //Mouse scroll on the mini chart var extent = brush.extent(), size = extent[1] - extent[0], range = mini_yScale.range(), y0 = d3.min(range), y1 = d3.max(range) + mini_yScale.rangeBand(), dy = d3.event.deltaY, topSection; if ( extent[0] - dy < y0 ) { ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function ScrollPosition() {}", "function updateScroll(){if(!elements.li[0])return;var height=elements.li[0].offsetHeight,top=height*ctrl.index,bot=top+height,hgt=elements.scroller.clientHeight,scrollTop=elements.scroller.scrollTop;if(top<scrollTop){scrollTo(top);}else if(bot>scrollTop+hgt){scrollTo(bot-hgt);}}",...
[ "0.7868472", "0.7776815", "0.7644434", "0.7597788", "0.7404497", "0.7361407", "0.7320042", "0.7320042", "0.7320042", "0.7315017", "0.730842", "0.730842", "0.71824384", "0.7167269", "0.7167269", "0.7167269", "0.7167269", "0.7167269", "0.71640426", "0.71462345", "0.7124807", ...
0.0
-1
The actual plugin constructor
function Plugin(element, options) { this.$element = $(element); this.$submit = this.$element.find('button[type="submit"]'); // jQuery has an extend method that merges the // contents of two or more objects, storing the // result in the first object. The first object // is...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "constructor() {\n super();\n this._init();\n }", "constructor() {\n\t\t// ...\n\t}", "consructor() {\n }", "constructor() {\r\n super()\r\n this.init()\r\n }", "init() {\n }", "constructor()\n {\n this.init();\n }", "function contruct() {\n\n ...
[ "0.7422684", "0.7349132", "0.7314277", "0.73003334", "0.7299704", "0.7292701", "0.72775894", "0.72354233", "0.7233936", "0.7181569", "0.71798736", "0.71798736", "0.71798736", "0.71798736", "0.71798736", "0.71761876", "0.7157667", "0.71499527", "0.71496284", "0.71496284", "0.7...
0.0
-1
utility fn for deep serialization
function deepSerialize(extraData) { var serialized = $.param(extraData, options.traditional).split('&'); var len = serialized.length; var result = []; var i, part; for (i = 0; i < len; i++) { // #252; undo param space replacement ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function NestedModelSerializer() {}", "get serializedObject() {}", "serialize() {}", "serialize() {}", "serialize() {}", "serialize() {}", "serialize() {}", "serialize() {}", "serialize() {}", "serialize() {}", "serialize() {}", "serialize() {}", "serialize() {}", "serialize() {}", "ser...
[ "0.6755528", "0.66965616", "0.66875905", "0.66875905", "0.66875905", "0.66875905", "0.66875905", "0.66875905", "0.66875905", "0.66875905", "0.66875905", "0.66875905", "0.66875905", "0.66875905", "0.66875905", "0.66875905", "0.66875905", "0.66875905", "0.66875905", "0.66875905",...
0.5767848
80
XMLHttpRequest Level 2 file uploads (big hat tip to francois2metz)
function fileUploadXhr(a) { var formdata = new FormData(); for (var i = 0; i < a.length; i++) { formdata.append(a[i].name, a[i].value); } if (options.extraData) { var serializedData = deepSerialize(options.extraData); for ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "uploadFile(e) {\n // get the file and send\n const selectedFile = this.postcardEle.getElementsByTagName(\"input\")[0].files[0];\n const formData = new FormData();\n formData.append('newImage', selectedFile, selectedFile.name);\n // build a browser-style HTTP request data structure\n const xhr = n...
[ "0.7322555", "0.7273731", "0.7271379", "0.7180992", "0.71526027", "0.71236026", "0.71159536", "0.698366", "0.69743043", "0.6968604", "0.6951908", "0.69236374", "0.6916526", "0.6914455", "0.6868251", "0.6827199", "0.6794339", "0.6775737", "0.67418045", "0.67178273", "0.6711435...
0.6642481
28
private function for handling file uploads (hat tip to YAHOO!)
function fileUploadIframe(a) { var form = $form[0], el, i, s, g, id, $io, io, xhr, sub, n, timedOut, timeoutHandle; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function handleUploads() {\n \n}", "function fileUpload() {\n\tvar files = this.files;\n\tvar sendData = new FormData();\n\tsendData.append('tree', properties.toLink());\n\tsendData.append('types', properties.typesAllowed);\n\tsendData.append('action', 'upload');\n\tif (files.length > 1) {\n\t\tfor (var f = 0...
[ "0.74707425", "0.70916146", "0.7023393", "0.69353056", "0.6881197", "0.68620133", "0.6855042", "0.68530947", "0.68530947", "0.68352777", "0.68093586", "0.6787075", "0.6776702", "0.6759755", "0.6732652", "0.6730007", "0.6730007", "0.6686071", "0.6625134", "0.6624002", "0.66192...
0.0
-1
take a breath so that pending repaints get some cpu time before the upload starts
function doSubmit() { // make sure form attrs are set var t = $form.attr2('target'), a = $form.attr2('action'), mp = 'multipart/form-data', et = $form.attr('enctype') || $form.attr('encoding') || mp; // update f...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function heartbeat(){\n\t//var start = performance.now();\n\tvar deltax = _mouse_move_x-_mouse_move_lastX;\n\tvar deltay = _mouse_move_y-_mouse_move_lastY;\n\n\tif (_mouse_isDown){\n\t _viewBox.x -= unzoomcalc(deltax);\n\t _viewBox.y -= unzoomcalc(deltay);\n\n\t /*\n\t // remove invisible tiles\n\t ...
[ "0.6028981", "0.60246295", "0.59328365", "0.58252156", "0.5794251", "0.57839215", "0.57567847", "0.5724271", "0.5700683", "0.5682808", "0.5666204", "0.5661084", "0.5643599", "0.5638432", "0.56274664", "0.56251335", "0.5614759", "0.56108755", "0.5590139", "0.55750877", "0.5570...
0.0
-1
look for server aborts
function checkState() { try { var state = getDoc(io).readyState; log('state = ' + state); if (state && state.toLowerCase() == 'uninitialized') { setTimeout(checkState, 50); } ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "_check_for_abort_sequence() {\n var abort_at = Zmodem.ZMLIB.find_subarray( this._input_buffer, ABORT_SEQUENCE );\n\n if (abort_at !== -1) {\n\n //TODO: expose this to caller\n this._input_buffer.splice( 0, abort_at + ABORT_SEQUENCE.length );\n\n this._aborted = true;\...
[ "0.6288338", "0.61375135", "0.6072864", "0.59043014", "0.57939357", "0.56451464", "0.56315064", "0.56079155", "0.5596992", "0.5548196", "0.5548196", "0.5548196", "0.5548196", "0.5548196", "0.5548196", "0.5548196", "0.5548196", "0.5548196", "0.5548196", "0.55446726", "0.553745...
0.54859346
33
helper fn for console logging
function log() { if (!$.fn.ajaxSubmit.debug) { return; } var msg = '[jquery.form] ' + Array.prototype.join.call(arguments, ''); if (window.console && window.console.log) { window.console.log(msg); } else if (window.opera && window.opera.postError) { ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "static log() {\n var str;\n str = Util.toStrArgs('', arguments);\n Util.consoleLog(str);\n }", "function log(txt){ console.log(txt); }", "function showLog(msg, arg) {\n console.log(msg, arg)\n}", "function logHelper(){\n\tconsole.log(\"----------------------------------------------------...
[ "0.7856629", "0.7569712", "0.748923", "0.7406033", "0.72819793", "0.7240815", "0.7194853", "0.71828324", "0.71828324", "0.7154196", "0.7097173", "0.70933986", "0.7087667", "0.70609504", "0.7052547", "0.7044371", "0.70436656", "0.7042956", "0.7041169", "0.7041169", "0.7034969"...
0.0
-1
Try/catch helper to minimize deoptimizations. Returns a completion record like context.tryEntries[i].completion. This interface could have been (and was previously) designed to take a closure to be invoked without arguments, but in all the cases we care about we already have an existing method we want to call, so there...
function tryCatch(fn, obj, arg) { try { return { type: "normal", arg: fn.call(obj, arg) }; } catch (err) { return { type: "throw", arg: err }; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function tryCatch(fn, obj, arg) { // 59\n try { // 60\n return { type: \"normal\", arg: fn.call(obj, arg) }; ...
[ "0.5071568", "0.5061275", "0.4849881", "0.47927505", "0.47927505", "0.47927505", "0.47927505", "0.47927505", "0.47831497", "0.47831497", "0.47063333", "0.46893752", "0.46678346", "0.4655878", "0.46554154", "0.46554154", "0.46554154", "0.46371436", "0.46213374", "0.46146342", ...
0.0
-1
Dummy constructor functions that we use as the .constructor and .constructor.prototype properties for functions that return Generator objects. For full spec compliance, you may wish to configure your minifier not to mangle the names of these two functions.
function Generator() {}
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function tempCtor() {}", "function temporaryConstructor() {}", "function TempCtor() {}", "function TempCtor() {}", "function TempCtor() {}", "function TempCtor() {}", "function TempCtor() {}", "function TempCtor() {}", "function HelperConstructor() {}", "function DummyClass() {\r\n // ...
[ "0.7218366", "0.70249206", "0.69523525", "0.69523525", "0.69523525", "0.69523525", "0.69523525", "0.69523525", "0.6760518", "0.65990555", "0.6572468", "0.6572468", "0.6572468", "0.64856845", "0.644338", "0.6399951", "0.63927424", "0.6376415", "0.6376415", "0.6337515", "0.6277...
0.0
-1
Helper for defining the .next, .throw, and .return methods of the Iterator interface in terms of a single ._invoke method.
function defineIteratorMethods(prototype) { ["next", "throw", "return"].forEach(function(method) { prototype[method] = function(arg) { return this._invoke(method, arg); }; }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function defineIteratorMethods(prototype){[\"next\",\"throw\",\"return\"].forEach(function(method){prototype[method]=function(arg){return this._invoke(method,arg);};});}", "function defineIteratorMethods(prototype){[\"next\",\"throw\",\"return\"].forEach(function(method){prototype[method]=function(arg){return th...
[ "0.7480683", "0.7480683", "0.7480683", "0.7480683", "0.7480683", "0.7480683", "0.7178389", "0.6994433", "0.6994433", "0.6972576", "0.6966516", "0.6966516", "0.6966516", "0.6966516", "0.6966516", "0.6966516", "0.6966516", "0.6966516", "0.6966516", "0.6966516", "0.6966516", "...
0.0
-1
This invoke function is written in a style that assumes some calling function (or Promise) will handle exceptions.
function invoke(method, arg) { var result = generator[method](arg); var value = result.value; return value instanceof AwaitArgument ? Promise.resolve(value.arg).then(invokeNext, invokeThrow) : Promise.resolve(value).then(function(unwrapped) { // When a yielded Promise is re...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "tryInvoke(value, ...args) {\n try {\n return isFunc(value) ? value.call(this, ...args) : value;\n }\n catch (e) {\n if (console && console.error) { console.error(e); } // eslint-disable-line no-console\n this.__notify(EV.SUPPRESSED_ERROR, e, e.stack || 'No stack available.');\n return ...
[ "0.6504093", "0.63485897", "0.63089263", "0.615802", "0.6102842", "0.60421896", "0.5986337", "0.5953871", "0.5938659", "0.5914783", "0.5797391", "0.57901716", "0.57901716", "0.57901716", "0.57901716", "0.57901716", "0.5762997", "0.5762997", "0.5762997", "0.5762997", "0.576299...
0.55933535
47
Copyright Joyent, Inc. and other Node contributors. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish...
function normalizeArray(parts, allowAboveRoot) { // if the path tries to go above the root, `up` ends up > 0 var up = 0; for (var i = parts.length - 1; i >= 0; i--) { var last = parts[i]; if (last === '.') { parts.splice(i, 1); } else if (last === '..') { parts.splice(i, 1); up++; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function rationalizePaths(array){\n for(var i = 0, len = array.length; i < len; i++){\n //I know, this is very unneeded, but I like having it because of it's over bearing round-a-bout-ness\n array[i] = require.resolve(array[i]).split('\\\\').filter(function(o,i,a){ return (a.length-1) !== i; }).jo...
[ "0.62566835", "0.609112", "0.5959465", "0.5927116", "0.5911643", "0.58731693", "0.5850678", "0.58194745", "0.5761436", "0.57423615", "0.57103646", "0.5641536", "0.5557576", "0.5512329", "0.54775536", "0.54392856", "0.54349303", "0.54344493", "0.54288816", "0.540262", "0.54002...
0.0
-1
v8 likes predictible objects
function Item(fun, array) { this.fun = fun; this.array = array; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function compareLike(a,b){\n var al = a.idLikesProp.length;\n var bl = b.idLikesProp.length;\n if(al > bl) return -1;\n if(bl > al) return 1;\n return 0;\n}", "function lookAround() {\n var objectDescription = \"\"\n tj.see().then(function(objects) {\n objects.forEach(function(each) {\n ...
[ "0.52765024", "0.5259989", "0.5191908", "0.5185475", "0.5126739", "0.5045062", "0.4894077", "0.4859557", "0.4840031", "0.48308602", "0.48213598", "0.48129985", "0.48068723", "0.47867215", "0.4783404", "0.47590926", "0.4750297", "0.47395125", "0.47262868", "0.47044972", "0.470...
0.0
-1
For compatibility and usage outside of module systems, make the Handlebars object a namespace
function create() { var hb = new base.HandlebarsEnvironment(); Utils.extend(hb, base); hb.SafeString = _handlebarsSafeString2['default']; hb.Exception = _handlebarsException2['default']; hb.Utils = Utils; hb.escapeExpression = Utils.escapeExpression; hb.VM = runtime; hb.template = function (sp...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function handlebars(hljs) {\n var BUILT_INS = {'builtin-name': 'each in with if else unless bindattr action collection debugger log outlet template unbound view yield lookup'};\n\n var IDENTIFIER_PLAIN_OR_QUOTED = {\n begin: /\".*?\"|'.*?'|\\[.*?\\]|\\w+/\n };\n\n var EXPRESSION_OR_HELPER_CALL = hljs.inheri...
[ "0.6172546", "0.604681", "0.604681", "0.604681", "0.604681", "0.60276735", "0.60271466", "0.5933552", "0.59230536", "0.591528", "0.5911213", "0.5911213", "0.5911213", "0.5908983", "0.5870879", "0.585121", "0.585121", "0.585121", "0.585121", "0.585121", "0.585121", "0.585121...
0.59807104
15
Older IE versions do not directly support indexOf so we must implement our own, sadly.
function indexOf(array, value) { for (var i = 0, len = array.length; i < len; i++) { if (array[i] === value) { return i; } } return -1; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "indexOf(val) {}", "function _indexOf(a,s){\n\t// Do we need the hack?\n\tif(a.indexOf){\n\t\treturn a.indexOf(s);\n\t}\n\n\tfor(var j=0;j<a.length;j++){\n\t\tif(a[j]===s){\n\t\t\treturn j;\n\t\t}\n\t}\n\treturn -1;\n}", "indexOf(data) {}", "indexOf(elemento){}", "function indexOf(val) {\n return this.in...
[ "0.7916735", "0.77107406", "0.7475343", "0.7374483", "0.71538013", "0.70467556", "0.6902652", "0.688232", "0.688232", "0.68596435", "0.6819322", "0.681385", "0.67678684", "0.6752915", "0.67430687", "0.6737495", "0.66632336", "0.66632336", "0.66632336", "0.66632336", "0.664798...
0.0
-1
Template is only compiled on first use and cached after that point.
function ret(context, execOptions) { if (!compiled) { compiled = compileInput(); } return compiled.call(this, context, execOptions); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "_$getTemplate(result2) {\n let template2 = templateCache.get(result2.strings);\n if (template2 === void 0) {\n templateCache.set(result2.strings, template2 = new Template(result2));\n }\n return template2;\n }", "function compile(template, options) {\n options = options || {};\n\n // Use ...
[ "0.67869866", "0.65429974", "0.6456374", "0.63971233", "0.6342088", "0.62534887", "0.62455904", "0.6228083", "0.61761236", "0.6084438", "0.6044861", "0.6022681", "0.6013232", "0.59883845", "0.5984776", "0.59824026", "0.59824026", "0.59824026", "0.5972568", "0.59706694", "0.59...
0.0
-1
A data structure which is a combination of an array and a set. Adding a new member is O(1), testing for membership is O(1), and finding the index of an element is O(1). Removing elements from the set is not supported. Only strings are supported for membership.
function ArraySet() { this._array = []; this._set = {}; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Set(a){\n\tif(a.isSet) return a;\n\tvar self;\n\tvar index = {};\n\tself = [];\n\tself.isSet = true;\n\tself.add = function(v){\n\t\tif(self._has(v)) return;\n\t\tself.push(v);\n\t\tindex[(typeof v) + \"_\" + v] = true;\n\t\treturn self;\n\t};\n\tself._has = function(v){\n\t\treturn index.hasOwnProperty((...
[ "0.66958183", "0.6421208", "0.6415087", "0.6390999", "0.63883936", "0.6353244", "0.6284871", "0.62828034", "0.6227823", "0.6227823", "0.6227823", "0.6227823", "0.6227823", "0.6227823", "0.6227823", "0.6227823", "0.6227823", "0.6227823", "0.6227823", "0.6227823", "0.6227823", ...
0.62902164
23
Converts from a twocomplement value to a value where the sign bit is placed in the least significant bit. For example, as decimals: 1 becomes 2 (10 binary), 1 becomes 3 (11 binary) 2 becomes 4 (100 binary), 2 becomes 5 (101 binary)
function toVLQSigned(aValue) { return aValue < 0 ? ((-aValue) << 1) + 1 : (aValue << 1) + 0; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function DecimalToSignedBin(number, nbBits)\n{\n absNumber = Math.abs(number)\n result = Array(nbBits)\n\n for(let i = nbBits -1; i >= 0; --i)\n {\n if(absNumber >= Math.pow(2,i))\n {\n //Sub the value and set the correct bit to one\n absNumber -= Math.pow(2,i)\n ...
[ "0.72056013", "0.69437486", "0.6770407", "0.6402026", "0.6402026", "0.6402026", "0.6402026", "0.6402026", "0.6402026", "0.6402026", "0.6402026", "0.6402026", "0.6402026", "0.6402026", "0.6402026", "0.6402026", "0.6402026", "0.6402026", "0.6402026", "0.6402026", "0.6402026", ...
0.0
-1
Converts to a twocomplement value from a value where the sign bit is placed in the least significant bit. For example, as decimals: 2 (10 binary) becomes 1, 3 (11 binary) becomes 1 4 (100 binary) becomes 2, 5 (101 binary) becomes 2
function fromVLQSigned(aValue) { var isNegative = (aValue & 1) === 1; var shifted = aValue >> 1; return isNegative ? -shifted : shifted; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function DecimalToSignedBin(number, nbBits)\n{\n absNumber = Math.abs(number)\n result = Array(nbBits)\n\n for(let i = nbBits -1; i >= 0; --i)\n {\n if(absNumber >= Math.pow(2,i))\n {\n //Sub the value and set the correct bit to one\n absNumber -= Math.pow(2,i)\n ...
[ "0.7107055", "0.69254225", "0.6529448", "0.6349443", "0.62549543", "0.62549543", "0.62549543", "0.62549543", "0.62549543", "0.62549543", "0.62549543", "0.62549543", "0.62549543", "0.62549543", "0.62549543", "0.62549543", "0.62549543", "0.62549543", "0.62549543", "0.62549543", ...
0.0
-1
Recursive implementation of binary search.
function recursiveSearch(aLow, aHigh, aNeedle, aHaystack, aCompare, aBias) { // This function terminates when one of the following is true: // // 1. We find the exact element we are looking for. // // 2. We did not find the exact element, but we can return the index of // the next-close...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function recursiveBinarySearch(arr, element){\n console.log(arr.length);\n let mid = Math.floor(arr.length / 2);\n let end = arr.length - 1;\n function helper(){\n if (arr.length === 1 && arr[0] !== element) {\n console.log(\"value not found\");\n return -1;\n }\n if (arr[mid] === element) {...
[ "0.77963585", "0.76379734", "0.7617944", "0.75735766", "0.75391334", "0.7520074", "0.7502346", "0.7450449", "0.7438148", "0.7435616", "0.74321216", "0.74138963", "0.7411604", "0.7400333", "0.7394127", "0.7391328", "0.73500323", "0.73500323", "0.73500323", "0.73500323", "0.734...
0.7294611
42
Determine whether mappingB is after mappingA with respect to generated position.
function generatedPositionAfter(mappingA, mappingB) { // Optimized for most common case var lineA = mappingA.generatedLine; var lineB = mappingB.generatedLine; var columnA = mappingA.generatedColumn; var columnB = mappingB.generatedColumn; return lineB > lineA || lineB == lineA && columnB >= col...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function generatedPositionAfter(mappingA, mappingB) {\n // Optimized for most common case\n var lineA = mappingA.generatedLine;\n var lineB = mappingB.generatedLine;\n var columnA = mappingA.generatedColumn;\n var columnB = mappin...
[ "0.80941486", "0.80775034", "0.8071079", "0.8071079", "0.8071079", "0.8071079", "0.8067486", "0.80641484", "0.80587137", "0.80587137", "0.80587137", "0.80587137", "0.80587137", "0.80587137", "0.80587137", "0.80587137", "0.80587137", "0.80587137", "0.80587137", "0.80587137", "...
0.8081928
6
A data structure to provide a sorted view of accumulated mappings in a performance conscious manner. It trades a neglibable overhead in general case for a large speedup in case of mappings being added in order.
function MappingList() { this._array = []; this._sorted = true; // Serves as infimum this._last = {generatedLine: -1, generatedColumn: 0}; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function documentSizeMap() {\n return new SortedMap(DocumentKey.comparator);\n}", "_pushMap(gen, obj, opts) {\n opts = {\n indefinite: false,\n ...opts\n };\n let entries = [...obj.entries()];\n if(gen.omitUndefinedProperties) {\n entries = entries.filter(([, v]) => v !== undefined)...
[ "0.60815156", "0.5939408", "0.58071345", "0.57162166", "0.5714398", "0.5702524", "0.56623805", "0.5645522", "0.5645522", "0.5645522", "0.5645522", "0.5645522", "0.5645522", "0.5643897", "0.5643897", "0.5643897", "0.5643897", "0.5633388", "0.5632058", "0.5632058", "0.5632058",...
0.5611489
75
Provide the JIT with a nice shape / hidden class.
function Mapping() { this.generatedLine = 0; this.generatedColumn = 0; this.source = null; this.originalLine = null; this.originalColumn = null; this.name = null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Class() {}", "function Class(){}", "function Class(){}", "function Class(){}", "function internalClass() { }", "function ClassHandle() {\n}", "function IClass() {}", "function Class_alloc(){}", "function Class() { }", "function Class() { }", "function Class() { }", "function Class() ...
[ "0.57826924", "0.5762645", "0.5762645", "0.5762645", "0.56935275", "0.562511", "0.55932504", "0.54922724", "0.5426919", "0.5426919", "0.5426919", "0.5426919", "0.5426919", "0.5426919", "0.5426919", "0.5426919", "0.5426919", "0.5426919", "0.5426919", "0.5421752", "0.5421001", ...
0.0
-1
An instance of the SourceMapGenerator represents a source map which is being built incrementally. You may pass an object with the following properties: file: The filename of the generated source. sourceRoot: A root for all relative URLs in this source map.
function SourceMapGenerator(aArgs) { if (!aArgs) { aArgs = {}; } this._file = util.getArg(aArgs, 'file', null); this._sourceRoot = util.getArg(aArgs, 'sourceRoot', null); this._skipValidation = util.getArg(aArgs, 'skipValidation', false); this._sources = new ArraySet(); this._names = n...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function SourceMapGenerator(aArgs){if(!aArgs){aArgs={};}this._file=util.getArg(aArgs,'file',null);this._sourceRoot=util.getArg(aArgs,'sourceRoot',null);this._skipValidation=util.getArg(aArgs,'skipValidation',false);this._sources=new ArraySet();this._names=new ArraySet();this._mappings=new MappingList();this._sourc...
[ "0.8245171", "0.81880283", "0.8152583", "0.8152583", "0.8152583", "0.8152583", "0.8152583", "0.8145216", "0.81188595", "0.81188595", "0.81188595", "0.81188595", "0.81172997", "0.8117158", "0.81141526", "0.81141526", "0.81141526", "0.81141526", "0.81011903", "0.81011903", "0.8...
0.81215006
15
SourceNodes provide a way to abstract over interpolating/concatenating snippets of generated JavaScript source code while maintaining the line and column information associated with the original source code.
function SourceNode(aLine, aColumn, aSource, aChunks, aName) { this.children = []; this.sourceContents = {}; this.line = aLine == null ? null : aLine; this.column = aColumn == null ? null : aColumn; this.source = aSource == null ? null : aSource; this.name = aName == null ? null : aName; thi...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function SourceNode(aLine, aColumn, aSource, aChunks, aName) {\n this.children = []\n this.sourceContents = {}\n this.line = aLine == null ? null : aLine\n this.column = aColumn == null ? null : aColumn\n this.source = aSource == null ? null : aSource\n this.name = aName == null ? null : aName\n this[isSour...
[ "0.6660969", "0.6607223", "0.65970564", "0.6551429", "0.6551429", "0.6551429", "0.6551429", "0.6551429", "0.6551429", "0.6551429", "0.6551429", "0.6551429", "0.6551429", "0.6551429", "0.6551429", "0.6551429", "0.6551429", "0.6551429", "0.6551429", "0.6551429", "0.6551429", ...
0.6433187
68
This is a helper function for getting values from parameter/options objects.
function getArg(aArgs, aName, aDefaultValue) { if (aName in aArgs) { return aArgs[aName]; } else if (arguments.length === 3) { return aDefaultValue; } else { throw new Error('"' + aName + '" is a required argument.'); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function get_parameter_values() {\n \"use strict\";\n let result = {};\n $(\".cea-parameter\").not(\"bootstrap-select\").each(function (index, element) {\n console.log(`Reading parameter: ${element.id}`);\n result[element.id] = read_value(element);\n });\n console.log(\"get_parameter_v...
[ "0.68455243", "0.6687373", "0.620966", "0.61871606", "0.6111289", "0.6095494", "0.6069015", "0.60682374", "0.60338724", "0.60314167", "0.60140955", "0.6000939", "0.6000939", "0.59996676", "0.5985312", "0.5939819", "0.5915073", "0.5905341", "0.58770657", "0.5860704", "0.581952...
0.0
-1
Normalizes a path, or the path portion of a URL: Replaces consequtive slashes with one slash. Removes unnecessary '.' parts. Removes unnecessary '/..' parts. Based on code in the Node.js 'path' core module.
function normalize(aPath) { var path = aPath; var url = urlParse(aPath); if (url) { if (!url.path) { return aPath; } path = url.path; } var isAbsolute = (path.charAt(0) === '/'); var parts = path.split(/\/+/); for (var part, up = 0, i = parts.length - 1; i >= 0; i-...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function normalize(aPath){var path=aPath;var url=urlParse(aPath);if(url){if(!url.path){return aPath;}path=url.path;}var isAbsolute=exports.isAbsolute(path);var parts=path.split(/\\/+/);for(var part,up=0,i=parts.length-1;i>=0;i--){part=parts[i];if(part==='.'){parts.splice(i,1);}else if(part==='..'){up++;}else if(up...
[ "0.81822854", "0.8142456", "0.8132537", "0.8132537", "0.8132537", "0.8114465", "0.8103893", "0.80993205", "0.80993205", "0.80953616", "0.8079681", "0.8079681", "0.80773944", "0.80751145", "0.80751145", "0.80751145", "0.80751145", "0.80751145", "0.80751145", "0.80751145", "0.8...
0.8116857
19
Make a path relative to a URL or another path.
function relative(aRoot, aPath) { if (aRoot === "") { aRoot = "."; } aRoot = aRoot.replace(/\/$/, ''); // It is possible for the path to be above the root. In this case, simply // checking whether the root is a prefix of the path won't work. Instead, we // need to remove components from ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function toRelativePath(path) {\n\ttoRelative\n}", "function relativePathWrapper(original) {\n return function() {\n var args = arguments\n\n // Assumes the first argument is a path string\n if (args[0][0] === '/')\n args[0] = \"..\" + args[0]\n return original.apply(thi...
[ "0.6727342", "0.6667964", "0.66587543", "0.665684", "0.6643501", "0.6633142", "0.6506549", "0.64645755", "0.6442088", "0.64077127", "0.638984", "0.63896716", "0.63896716", "0.6380381", "0.63783306", "0.6363264", "0.62991583", "0.6283188", "0.6283188", "0.6283188", "0.6256562"...
0.0
-1
Because behavior goes wacky when you set `__proto__` on objects, we have to prefix all the strings in our set with an arbitrary character. See and
function toSetString(aStr) { return '$' + aStr; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function stripPrototypes(obj, seen = new WeakSet) {\n if (typeof obj !== 'object' || obj === null || seen.has(obj)) {\n return obj;\n }\n seen.add(obj);\n Object.setPrototypeOf(obj, null);\n for (const name of Reflect.ownKeys(obj)) {\n stripPrototypes(obj[name], seen);\n }\n return obj;\n}", "functi...
[ "0.5578852", "0.5455889", "0.5455889", "0.5442018", "0.5440876", "0.5435003", "0.5419901", "0.53955466", "0.5377961", "0.5311436", "0.5311436", "0.530992", "0.5299065", "0.52628356", "0.5251617", "0.5193246", "0.51814044", "0.50986546", "0.50834054", "0.5081505", "0.5081505",...
0.0
-1
Comparator between two mappings where the original positions are compared. Optionally pass in `true` as `onlyCompareGenerated` to consider two mappings with the same original source/line/column, but different generated line and column the same. Useful when searching for a mapping with a stubbed out mapping.
function compareByOriginalPositions(mappingA, mappingB, onlyCompareOriginal) { var cmp = mappingA.source - mappingB.source; if (cmp !== 0) { return cmp; } cmp = mappingA.originalLine - mappingB.originalLine; if (cmp !== 0) { return cmp; } cmp = mappingA.originalColumn - mapping...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function compareByGeneratedPositions(mappingA, mappingB, onlyCompareGenerated) {\n var cmp;\n\n cmp = mappingA.generatedLine - mappingB.generatedLine;\n if (cmp) {\n return cmp;\n }\n\n cmp = mappingA.generatedColumn - mappingB.generatedColumn;\n if (cmp || onlyCompareGenerated) {\n ret...
[ "0.8266512", "0.8266512", "0.8266512", "0.8266512", "0.8266512", "0.8266512", "0.8266512", "0.8266512", "0.8266512", "0.8266512", "0.8266512", "0.8266512", "0.8266512", "0.8266512", "0.81804025", "0.8104091", "0.8104091", "0.8090736", "0.8090736", "0.8090736", "0.8090736", ...
0.0
-1
Comparator between two mappings with deflated source and name indices where the generated positions are compared. Optionally pass in `true` as `onlyCompareGenerated` to consider two mappings with the same generated line and column, but different source/name/original line and column the same. Useful when searching for a...
function compareByGeneratedPositionsDeflated(mappingA, mappingB, onlyCompareGenerated) { var cmp = mappingA.generatedLine - mappingB.generatedLine; if (cmp !== 0) { return cmp; } cmp = mappingA.generatedColumn - mappingB.generatedColumn; if (cmp !== 0 || onlyCompareGenerated) { return c...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function compareByGeneratedPositionsDeflated(\n mappingA,\n mappingB,\n onlyCompareGenerated\n ) {\n var cmp = mappingA.generatedLine - mappingB.generatedLine\n if (cmp !== 0) {\n return cmp\n }\n\n cmp = mappingA.generatedColumn - mappingB.generatedColumn\n if (cmp !== 0 || onlyCompa...
[ "0.830529", "0.823805", "0.8235972", "0.8235972", "0.82344055", "0.82344055", "0.82344055", "0.82344055", "0.82344055", "0.82344055", "0.82344055", "0.82344055", "0.82344055", "0.82344055", "0.82344055", "0.82344055", "0.82344055", "0.82344055", "0.82344055", "0.82344055", "0...
0.8014472
56
Comparator between two mappings with inflated source and name strings where the generated positions are compared.
function compareByGeneratedPositionsInflated(mappingA, mappingB) { var cmp = mappingA.generatedLine - mappingB.generatedLine; if (cmp !== 0) { return cmp; } cmp = mappingA.generatedColumn - mappingB.generatedColumn; if (cmp !== 0) { return cmp; } cmp = strcmp(mappingA.source, m...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function compareByGeneratedPositionsInflated(mappingA,mappingB){var cmp=mappingA.generatedLine-mappingB.generatedLine;if(cmp!==0){return cmp;}cmp=mappingA.generatedColumn-mappingB.generatedColumn;if(cmp!==0){return cmp;}cmp=strcmp(mappingA.source,mappingB.source);if(cmp!==0){return cmp;}cmp=mappingA.originalLine-m...
[ "0.78793555", "0.7730354", "0.7715609", "0.75661385", "0.7529118", "0.75169015", "0.75155807", "0.75155807", "0.75155807", "0.75155807", "0.7509198", "0.7505216", "0.7505216", "0.74911785", "0.74911785", "0.74911785", "0.74911785", "0.74911785", "0.74911785", "0.74911785", "0...
0.75153524
16
Create the normalize() function passed to a loader plugin's normalize method.
function makeNormalize(relName) { return function (name) { return normalize(name, relName); }; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function makeNormalize(relName) {\n\t return function (name) {\n\t return normalize(name, relName);\n\t };\n\t }", "function makeNormalize(relName) {\n return function (name) {\n return normalize(name, relName);\n };\n }", "async normalize () {\n\t}", "function getNorm...
[ "0.69965756", "0.69092196", "0.65772325", "0.6472097", "0.63452625", "0.59559876", "0.5683507", "0.56809765", "0.5614795", "0.5390814", "0.5319899", "0.5315959", "0.5315457", "0.5291301", "0.520445", "0.520429", "0.5167384", "0.5053521", "0.50454944", "0.5045297", "0.5040434"...
0.6875031
25
Create a define function specific to the module asking for amdefine.
function define(id, deps, factory) { if (Array.isArray(id)) { factory = deps; deps = id; id = undefined; } else if (typeof id !== 'string') { factory = id; id = deps = undefined; } if (deps && !Array.isArray(deps)) { ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "defineFn(name, words) {this.fnDefs[name] = words;}", "function createDefine() {\n // ensure no NodeJS environment detection\n var oldModule = __global.module;\n var oldExports = __global.exports;\n var oldDefine = __global.define;\n\n __global.module = undefined;\n __global.exports ...
[ "0.67292166", "0.65721786", "0.61196005", "0.6110185", "0.60765976", "0.60107386", "0.59239537", "0.59221685", "0.589497", "0.589497", "0.58683014", "0.5863456", "0.58621514", "0.58621514", "0.58621514", "0.57344866", "0.56188864", "0.55900455", "0.5539028", "0.54815006", "0....
0.5292803
54
The function whose prototype chain sequence wrappers inherit from.
function baseLodash() { // No operation performed. }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "get prototype() {}", "function FunctionWithPrototypeTest() {}", "function n(e,t){e.prototype.__proto__=t&&t.prototype,e.__proto__=t}", "function inheritFrom(subfn,superfn) {\n\tvar r = function () {}\n\tr.prototype = superfn.prototype;\n\tsubfn.prototype = new r();\n}", "function m(a){var b=function(){};re...
[ "0.6342288", "0.6208167", "0.58855337", "0.583702", "0.57527447", "0.57292926", "0.57292926", "0.57196784", "0.57196784", "0.57196784", "0.57196784", "0.57196784", "0.57149184", "0.57149184", "0.5680923", "0.5680923", "0.5680923", "0.5680923", "0.5680923", "0.5680923", "0.568...
0.0
-1
Removes all keyvalue entries from the hash.
function hashClear() { this.__data__ = nativeCreate ? nativeCreate(null) : {}; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "clear() {\n var map = this._map;\n var keys = Object.keys(map);\n\n for (var i = 0; i < keys.length; i++) {\n var key = keys[i];\n map[key].clear();\n }\n }", "function clear() {\n this.keys.forEach((key) => {\n this._store[key] = undefined;\n delete this._store[key];\n });\n}", ...
[ "0.67334944", "0.6623336", "0.6511826", "0.6455883", "0.62145466", "0.6201314", "0.61386395", "0.6110296", "0.6029897", "0.5967433", "0.5935932", "0.5907081", "0.5907081", "0.5907081", "0.59049076", "0.5900418", "0.5900418", "0.5900418", "0.58645844", "0.58645844", "0.5864584...
0.0
-1
Removes all keyvalue entries from the list cache.
function listCacheClear() { this.__data__ = []; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function listCacheClear(){this.__data__=[];}", "function listCacheClear(){this.__data__=[];}", "function listCacheClear(){this.__data__=[];}", "function listCacheClear(){this.__data__=[];}", "function listCacheClear() {\n\t\t this.__data__ = [];\n\t\t this.size = 0;\n\t\t}", "function listCacheClear() ...
[ "0.73577744", "0.73577744", "0.73577744", "0.73577744", "0.73179376", "0.72645366", "0.72645366", "0.7262961", "0.7256912", "0.7256912", "0.7236398", "0.7236398", "0.7236398", "0.7236398", "0.7236398", "0.7236398", "0.7236398", "0.7236398", "0.7236398", "0.7236398", "0.723455...
0.0
-1
Removes all keyvalue entries from the map.
function mapCacheClear() { this.__data__ = { 'hash': new Hash, 'map': new (Map || ListCache), 'string': new Hash }; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "clear() {\n var map = this._map;\n var keys = Object.keys(map);\n\n for (var i = 0; i < keys.length; i++) {\n var key = keys[i];\n map[key].clear();\n }\n }", "clear() {\n log.map(\"Clearing the map of all the entries\");\n this._map.clear();\n }", "function multiMapRemo...
[ "0.7590112", "0.70694387", "0.6735414", "0.6652174", "0.6530006", "0.6267597", "0.62582785", "0.62582785", "0.62582785", "0.617115", "0.617115", "0.617115", "0.6166302", "0.61519635", "0.614778", "0.614778", "0.614778", "0.614778", "0.614778", "0.614778", "0.614778", "0.614...
0.0
-1
Removes all keyvalue entries from the stack.
function stackClear() { this.__data__ = new ListCache; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "clear () {\n this._dict = {}\n this._stack = [this._dict]\n }", "function stackClear(){this.__data__={'array':[],'map':null};}", "function stackClear(){this.__data__={'array':[],'map':null};}", "function stackClear(){this.__data__={'array':[],'map':null};}", "function stackClear() {\n\t this.__...
[ "0.63577557", "0.63297385", "0.63297385", "0.63297385", "0.62740946", "0.6227898", "0.6227898", "0.6227898", "0.6227898", "0.6227898", "0.6227898", "0.6227898", "0.6217544", "0.6217544", "0.6217544", "0.6217544", "0.6217544", "0.6217544", "0.6217544", "0.6217544", "0.6217544"...
0.0
-1
ADDING EVENT LISTENERS varifying username
function verifyUsername(){ if(username.value != ''){ usernameError.textContent = ''; username.style.border = '1px solid green'; // username.focus(); return true; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setUsername (username) { socket.emit('add user', username); }", "async registerUserEvents () {\n const eventFiles = await this.loadEvents()\n\n _.forEach(eventFiles, async eventFile => {\n const Event = this.resolve(eventFile)\n const event = new Event()\n this.ensureEvent(event)\n\...
[ "0.6574213", "0.6340358", "0.61698854", "0.6061126", "0.6059097", "0.6038304", "0.5944296", "0.593371", "0.5898707", "0.58854604", "0.58844143", "0.5845891", "0.5816225", "0.5772364", "0.5758812", "0.5748536", "0.5748536", "0.5732396", "0.57285976", "0.5713424", "0.5712218", ...
0.0
-1