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
Numero de silencios antes de soltar PTT
function UpdateSilenceEnd() { try { let numSilence = Number(gb_ctrl_input_silenceEnd.elt.value); let i=0; gb_cadSilenceEnd = ''; for (i=0;i<numSilence;i++) { gb_cadSilenceEnd += ' '; } } catch(err) { DebugLog(err.message.toString()); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function tNumber() {\n const [h, k] = [opt.h, opt.k];\n eid(\"tnumber\").innerHTML = `=&nbsp;${h}<sup>2</sup>&nbsp;+&nbsp;(${h})(${k})&nbsp;+&nbsp;${k}<sup>2</sup>&nbsp=&nbsp${h * h + h * k + k * k}`;\n}", "function potencia(base, expoente) {\n return 0\n}", "function parse_PtgNum(blob) { blob.l++; retu...
[ "0.6435445", "0.6395012", "0.6370049", "0.6370049", "0.6370049", "0.6370049", "0.6329845", "0.62346804", "0.61756223", "0.6161063", "0.6129681", "0.61288387", "0.6126414", "0.61013275", "0.6018806", "0.5992113", "0.59423316", "0.5942148", "0.5910016", "0.59056205", "0.5901125...
0.0
-1
Prepara los 2 tonos de los osciladores
function PreLoadOscillator() { try { gb_oscTone1 = new p5.Oscillator(); gb_oscTone1.setType('sine'); gb_oscTone1.freq(697); gb_oscTone1.amp(1); gb_oscTone2 = new p5.Oscillator(); gb_oscTone2.setType('sine'); gb_oscTone2.freq(1209); gb_oscTone2.amp(1); //gb_oscTone2.start(); //gb_...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function sukeistiMasayvoElementus(nr1, nr2) {\nlet y = prekiautojai[nr1];\nprekiautojai[nr1] = prekiautojai[nr2];\nprekiautojai[nr2] = y;\n\n}", "function sukeistiMasyvo2elementus(nr1, nr2) {\n var x = prekybosCentrai[nr1];\n prekybosCentrai[nr1] = prekybosCentrai[nr2];\n prekybosCentrai[nr2] = x;...
[ "0.60261047", "0.5924631", "0.565717", "0.5645054", "0.5582667", "0.5571745", "0.55629593", "0.55518836", "0.55413795", "0.5541158", "0.55282575", "0.55263877", "0.5489029", "0.54848707", "0.54801786", "0.5473434", "0.5465906", "0.5457252", "0.54551196", "0.54546285", "0.5450...
0.0
-1
Activa microfono si no existe primer vez
function ActivarMic() { try { if (gb_use_mic_dtmf === true) { if ((typeof gb_mic === 'undefined') || (typeof gb_fft === 'undefined')) { gb_mic = new p5.AudioIn(); gb_mic.start(); gb_fft = new p5.FFT(); gb_fft.setInput(gb_mic); } } } catch(err) { DebugLog(err...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "editarFalse1() {\n this.activarPersonal = true;\n }", "function activateStatCLIENTE(ID) {\n if (ID) {\n const sql = `UPDATE espacios SET ? WHERE ID = '${ID}'`\n const data = {\n CLIENTE: 1\n }\n connection.query(sql, data, error => {\n /*Trabajo de e...
[ "0.61895555", "0.5914281", "0.59009457", "0.5806023", "0.57382375", "0.5721891", "0.57206285", "0.57205826", "0.5705693", "0.5700861", "0.569673", "0.56714875", "0.5631845", "0.56022555", "0.559015", "0.5588717", "0.5568641", "0.5556228", "0.55475503", "0.553351", "0.552776",...
0.0
-1
Seleccion Mic decodificar tonos DTMF
function MicEvent() { try { gb_use_mic_dtmf = this.checked() ? true : false; ActivarMic(); } catch(err) { DebugLog(err.message.toString()); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getTahun() {\n karyawanid = document.getElementById('karyawanId').value;\n param = \"proses=getTahun\";\n param += \"&karyawanid=\"+karyawanid;\n tujuan='sdm_slave_ijin_meninggalkan_kantor.php';\n post_response_text(tujuan, param, respog);\n function respog()\n {\n if(c...
[ "0.56656945", "0.56465167", "0.56357586", "0.56287336", "0.56120056", "0.56000876", "0.5576091", "0.5536179", "0.55321425", "0.55291903", "0.55160797", "0.55155134", "0.55081815", "0.55078393", "0.5458893", "0.54475945", "0.5423098", "0.53959066", "0.5382899", "0.537926", "0....
0.0
-1
Seleccion de GAMEPAD para leer MT8870 tonos DTMF
function GamePADEvent() { try { gb_use_gamepad_dtmf = this.checked() ? true : false; } catch(err) { DebugLog(err.message.toString()); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Poll_Pad_DTMF()\r\n{ \r\n try\r\n {\r\n if (gb_use_gamepad_dtmf === false)\r\n {\t\r\n return;\r\n }\r\n\t\r\n let pads = navigator.getGamepads();\r\n let pad0 = pads[0];\r\n let i=0;\r\n if (pad0)\r\n {\r\n gb_cad_botones='';\r\n for (i=0;i<pad0.buttons.length;i++)\r\n {\r\n if (pad0.b...
[ "0.66167855", "0.652405", "0.575782", "0.54509795", "0.5369567", "0.5340621", "0.5320802", "0.53105164", "0.53023535", "0.52705276", "0.52630883", "0.52314454", "0.52288496", "0.52280974", "0.52263254", "0.52218914", "0.5125258", "0.51089764", "0.50998664", "0.50856864", "0.5...
0.5028941
27
Fullduplex RX y TX al mismo tiempo ECO de lo enviado
function FullDuplexEvent() { try { gb_fullduplex = this.checked() ? true : false; } catch(err) { DebugLog(err.message.toString()); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "txTick() {\n var t = this;\n if (!t.lastTxSuccess) {\n if (t.lastCmdSendMs == null) { // If command has already been received\n if (t.nextTxAttMs != null) {\n if (Date.now() > t.nextTxAttMs && t.port.canWrite()) {\n t.nextTxAttMs = n...
[ "0.6039069", "0.6023294", "0.5977954", "0.58658236", "0.5847341", "0.58467346", "0.57238066", "0.5699251", "0.5625312", "0.55507207", "0.5547604", "0.5509749", "0.55085814", "0.54787856", "0.54787856", "0.54418725", "0.54224104", "0.5381825", "0.5372066", "0.5353507", "0.5332...
0.0
-1
Imprime consola log si tenemos activa gb_log_debug
function DebugLog(cad) { try { if (gb_log_debug === true) { console.log(cad); } } catch(err) { } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function log() {\n\ttry { \n\t\tconsole.log(\n\t\t\tshowOnly(logjs).forFilter(\n\t\t\t\t{\n\t\t\t\t\tapp: \"opsebf\",\n\t\t\t\t\tdate: \"20180623\",\n\t\t\t\t\tafter: \"1900\",\n\t\t\t\t}\n\t\t\t)\n\t\t);\n\t}\n\tcatch(err) {\n\t\tvar msg = \"opsebf logs only in development stage\";\n\t\tconsole.warn(msg);\n\t}\n}...
[ "0.6858884", "0.65588164", "0.65382206", "0.6520181", "0.65099853", "0.62979925", "0.62972194", "0.62966883", "0.62569255", "0.6244638", "0.62391585", "0.62187636", "0.61886066", "0.61867064", "0.61478215", "0.6144665", "0.6136041", "0.6135759", "0.61000836", "0.6099957", "0....
0.76270914
1
Numero de D para activar VOX PTT
function UpdateNumPTT() { try { let numPTT = Number(gb_ctrl_input_ptt.elt.value); let i=0; gb_cadPTT = ''; for (i=0;i<numPTT;i++) { gb_cadPTT += 'D'; } } catch(err) { DebugLog(err.message.toString()); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function tNumber() {\n const [h, k] = [opt.h, opt.k];\n eid(\"tnumber\").innerHTML = `=&nbsp;${h}<sup>2</sup>&nbsp;+&nbsp;(${h})(${k})&nbsp;+&nbsp;${k}<sup>2</sup>&nbsp=&nbsp${h * h + h * k + k * k}`;\n}", "function telefone(e){\r\n e.value=e.value.replace(/\\D/g,\"\") //REMOVE TUDO O QU...
[ "0.55350643", "0.553259", "0.5451237", "0.5447314", "0.54074", "0.5385545", "0.5361611", "0.5349261", "0.5300222", "0.52612275", "0.52318263", "0.5229801", "0.519442", "0.51936823", "0.51904696", "0.51897794", "0.51769674", "0.51434004", "0.5141143", "0.5141143", "0.5141143",...
0.57257485
0
Reproduce un tono DTMF dado
function PlayDTMF(data) { try { //gb_buf_send_dtmf[0] = data; gb_buf_send_dtmf = data; gb_total_dtmf_send= 0; gb_current_dtmf_send = 0; gb_play_dtmf= true; gb_begin_dtmf = false; gb_end_dtmf = false; gb_begin_silence = false; gb_end_silence = false; } catch(err) { DebugLog(er...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function dibujarFresado115(modelo,di,pos,document){\n\t\n\t//ESTABLECER CAPA\n\tvar op_fresado = new RAddObjectsOperation();\n\tdi.setCurrentLayer(\"Fresado\"); //Seleccionar la capa de fresado\n\t\n\t\n\tvar plieguesInf=[pliegueInf1, pliegueInf2, pliegueInf3, pliegueInf4]\n\t\n\t//sacar el mayor pliegue\n\tpliegu...
[ "0.5827639", "0.5812888", "0.5776628", "0.5770002", "0.57203674", "0.5719519", "0.5709198", "0.570645", "0.5697036", "0.5657723", "0.56489044", "0.5648624", "0.56407267", "0.5635243", "0.56237525", "0.56167865", "0.5611896", "0.55837715", "0.5570577", "0.55611384", "0.5557462...
0.0
-1
Para reproducir sonidos DTMF
function StopSound(){ try { gb_oscTone1.stop(); gb_oscTone2.stop(); gb_play_dtmf = false; } catch(err) { DebugLog(err.message.toString()); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function dibujarFresado116(modelo,di,pos,document){\n\t\n\t//ESTABLECER CAPA\n\tvar op_fresado = new RAddObjectsOperation();\n\tdi.setCurrentLayer(\"Fresado\"); //Seleccionar la capa de fresado\n\t\n\tanchura4=0\n\tanchura5=0\n\t\n\t//Puntos trayectoria \n\t\t\t//Son los mismos puntos que la figura 001 (el unico q...
[ "0.58315045", "0.581211", "0.5805234", "0.5785477", "0.5780203", "0.57680494", "0.576773", "0.57655036", "0.5732608", "0.5712099", "0.5694818", "0.5690469", "0.5679988", "0.56684035", "0.5656925", "0.56521857", "0.56488496", "0.5648591", "0.5642034", "0.56296957", "0.56286037...
0.0
-1
Convierte caracter Base64 A..Z a codigo decimal 0..63
function CharBase64To2DTMF(car) { let aReturn = ''; try { switch(car) { case 'A': aReturn='00'; break; case 'B': aReturn='01'; break; case 'C': aReturn='02'; break; case 'D': aReturn='03'; break; case 'E': aReturn='04'; break; case 'F': aReturn='05'; break; case 'G': aReturn='...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getBase64() {\n var s = this.getDump();\n\n var ch =\n \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\";\n var c1, c2, c3, e1, e2, e3, e4;\n var l = s.length;\n var i = 0;\n var r = \"\";\n\n do {\n c1 = s.charCodeAt(i);\n e1 = c1 >> 2;\n c2 = s.charCod...
[ "0.6894408", "0.67799854", "0.6776089", "0.6718383", "0.66937184", "0.66824454", "0.66479546", "0.6621761", "0.65995044", "0.65782475", "0.6568478", "0.6487984", "0.6483536", "0.6471556", "0.6471556", "0.6471556", "0.6414547", "0.6399728", "0.6370955", "0.6370501", "0.63531",...
0.66972715
4
Convierte de 2 DTMF a Base64
function DTMFtoCharBase64(dtmf) { let aReturn = ''; try { switch(dtmf) { case '00': aReturn='A'; break; case '01': aReturn='B'; break; case '02': aReturn='C'; break; case '03': aReturn='D'; break; case '04': aReturn='E'; break; case '05': aReturn='F'; break; case '06': aReturn...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function CharBase64To2DTMF(car)\r\n{\r\n let aReturn = '';\r\n try\r\n {\r\n switch(car)\r\n { \r\n case 'A': aReturn='00'; break;\r\n case 'B': aReturn='01'; break;\r\n case 'C': aReturn='02'; break;\r\n case 'D': aReturn='03'; break;\r\n case 'E': aReturn='04'; break;\r\n case 'F': aReturn='05'; b...
[ "0.6250404", "0.6170061", "0.61428016", "0.61284786", "0.6121006", "0.6117859", "0.6108484", "0.61060137", "0.6085503", "0.60733056", "0.60656935", "0.6018246", "0.6016483", "0.6014514", "0.5995327", "0.5983649", "0.59485555", "0.59349895", "0.59348315", "0.59345365", "0.5891...
0.6234314
1
Envia un mensaje del TextMemo
function SendTXSMSTipo(tipo) { try { let cadToSend = gb_ctrl_areaTX.elt.value; switch (tipo) { case 0: SendSMSTipo0(cadToSend); //Texto Base64 crudo break; case 1: SendSMSTipo1Serv(cadToSend,'0'); //Diccionario,empaquetado,mayusculas break; case 2: SendSMSTipo1Serv(cadToSend,'2'); /...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function writeMessage(message) {\n setText(text + (text ? \"\\n\" : \"\") + message); \n }", "function showMemotaro() {\n botui.message.add({\n delay: 1500,\n content: \"This website mainly includes my technical memorandoms.\"\n }).then(function(){\n return botui.message.add({\n ...
[ "0.6183076", "0.6060494", "0.59520316", "0.5896689", "0.5827239", "0.57994616", "0.5788936", "0.57343197", "0.56677", "0.5644189", "0.5602496", "0.55807406", "0.5563037", "0.5553235", "0.5518", "0.55015737", "0.5491215", "0.5489491", "0.54853994", "0.54441553", "0.5443677", ...
0.0
-1
Actualiza la area de recepcion que tambien pone TX
function UpdateAreaRX(cad) { try { gb_ctrl_areaRX.elt.value += cad+'\n'; } catch(err) { DebugLog(err.message.toString()); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function pEnviarPlantilla(idOrder, reenvio) {\n\n console.log(\"Enviamos el la plantilla \"+idOrder);\n\n // Recuperar la cabecer\n var s = \"SELECT * FROM ordersPending WHERE idInternalOrder=\" + idOrder;\n\n var res = {};\n var linea = {};\n\n console.log(\"ini ENVIO WS PLANTILLA!!!!!!!!!!!!!!!...
[ "0.5572519", "0.5512937", "0.5506627", "0.54174", "0.54114956", "0.52419394", "0.5232712", "0.521291", "0.52121705", "0.5205747", "0.5201709", "0.5199024", "0.5180341", "0.51637685", "0.51422185", "0.5127629", "0.51136523", "0.5113233", "0.51104236", "0.5108163", "0.50863016"...
0.49861732
30
Send SMS de Prueba basica tipo 0 sin longitud ni CRC
function SendSMSTipo0(cadToSend) { //#0323334* //gb_buf_send_dtmf[0]='#'; try { gb_buf_send_dtmf = (gb_use_relay === true) ? 'C' : ''; gb_buf_send_dtmf += gb_cadPTT + gb_cadSilenceStart + '#'; //gb_buf_send_dtmf = '#'; let cadLog = ''; let frameData = '0'; //Tipo 0 let cadTX = ''; //let c...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function SendSMSTipo1Serv(cadToSend, servicio)\r\n{\r\n //#10CRxxYYzz*\r\n //Tipo:1 \r\n //Servicio:0 Diccionario Espaniol\r\n //Longitud 00\r\n //CRC 00\r\n try\r\n {\r\n gb_buf_send_dtmf = (gb_use_relay === true) ? 'C' : '';\r\n gb_buf_send_dtmf += gb_cadPTT + gb_cadSilenceStart + '#';\r\n let cadLog = '';\r...
[ "0.6894302", "0.67547494", "0.6613629", "0.66038173", "0.65757006", "0.6224436", "0.62031484", "0.6181375", "0.6167109", "0.6124608", "0.5895078", "0.5876259", "0.58707446", "0.5720026", "0.56973785", "0.5684693", "0.5616311", "0.55992365", "0.55859435", "0.5531663", "0.55133...
0.6515885
5
Genera CRC de todo el frame a enviar
function FrameGenerateCRC(frameOrigen) { let aReturn = '00'; let aux = 0; try { let i = 0; for (i=0; i<frameOrigen.length; i++) { aux += Number(frameOrigen[i]); } if (aux > 63) { aux = aux % 64; } aReturn = aux.toString().padStart(2,'0'); } catch(err) { DebugLog(err....
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function crc(buf){return(updateCrc(-1,buf,buf.length)^-1)>>>0;// u32\n}", "function updateCrc(crc,buf,len){for(let n=0;n<len;n++){crc=crc>>>8^crcTable[(crc^buf[n])&255]}return crc}", "computeIdemCrc() {\n let crc = 0xFFFF;\n for (let i = -3; i < 5; i++) {\n crc = Crc16_1.CRC_16_CCITT.u...
[ "0.6853199", "0.6817945", "0.6426775", "0.63545346", "0.61762613", "0.61584264", "0.6044017", "0.5965166", "0.594299", "0.59208256", "0.591945", "0.5898417", "0.5898417", "0.58749074", "0.57686824", "0.5739841", "0.5715014", "0.56501323", "0.56498694", "0.5621926", "0.5604970...
0.8403116
0
Send SMS de Prueba basica tipo 1 con longitud y CRC
function SendSMSTipo1Serv(cadToSend, servicio) { //#10CRxxYYzz* //Tipo:1 //Servicio:0 Diccionario Espaniol //Longitud 00 //CRC 00 try { gb_buf_send_dtmf = (gb_use_relay === true) ? 'C' : ''; gb_buf_send_dtmf += gb_cadPTT + gb_cadSilenceStart + '#'; let cadLog = ''; let frameData = '1'; //Ti...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function ProcesSMSTipo1()\r\n{\r\n let auxLen= 0; //longiud trama\r\n let auxCadLen=0; //longitud cadena\r\n let auxCRC= 0;\r\n let cadServ= 0;\r\n let cadLog='';\r\n let i=0;\r\n let cont=0;\r\n let cadBase64='';\r\n let cadDTMF ='';\r\n let cadDecompress='';\r\n let cadAreaRX ='';\r\n try\r\n {\r\n auxLen = gb_...
[ "0.6995498", "0.6894542", "0.666541", "0.64961565", "0.6451183", "0.6260964", "0.6248307", "0.62290585", "0.6117647", "0.6045322", "0.59831", "0.59566313", "0.5903152", "0.5884233", "0.5860891", "0.5833471", "0.5805979", "0.576053", "0.5735613", "0.5735475", "0.57321835", "...
0.7173016
0
Convierte de 2key dtmf a caracter
function TwoKeyDTMFTochar(valor) { let aReturn=''; try { switch(valor) { case '2A': aReturn= 'A';break; case '2B': aReturn= 'B';break; case '2C': aReturn= 'C';break; case '3A': aReturn= 'D';break; case '3B': aReturn= 'E';break; case '3C': aReturn= 'F';break; case '4A': aReturn= ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function PlaySeqDTMF(cad)\r\n{ \r\n try\r\n {\r\n if (gb_use_fast === true)\r\n {\r\n switch (cad)\r\n {\r\n case '#00*': cad = 'D'; break;\r\n case '#01*': cad = '1'; break;\r\n case '#02*': cad = '2'; break;\r\n case '#03*': cad = '3'; break;\r\n case '#04*': cad = '4'; break;\r\n case '#...
[ "0.6420938", "0.63112944", "0.62593603", "0.6259082", "0.612114", "0.6112791", "0.6036943", "0.60317826", "0.60315007", "0.5989632", "0.59230214", "0.59010017", "0.587426", "0.58417106", "0.579337", "0.5720343", "0.568851", "0.568851", "0.5673339", "0.5673339", "0.56711215", ...
0.57552594
15
Convierte un caracter a codigo 2key dtmf
function CharTo2KeyDTMF(valor) { let aReturn=''; try { switch(valor) { case 'A': aReturn= '2A';break; case 'B': aReturn= '2B';break; case 'C': aReturn= '2C';break; case 'D': aReturn= '3A';break; case 'E': aReturn= '3B';break; case 'F': aReturn= '3C';break; case 'G': aReturn= '4A...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function StringTwoKeyDTMFToString(cad)\r\n{\r\n let aReturn=''; \r\n let i=0;\r\n try\r\n {\r\n for (i=0;i<(cad.length-2);i+=2)\r\n {\r\n aReturn += TwoKeyDTMFTochar(cad[i]+cad[i+1]);\r\n }\r\n }\r\n catch(err)\r\n {\r\n DebugLog(err.message.toString());\r\n } \r\n return (aReturn);\r\n}", "function String...
[ "0.66612995", "0.6583459", "0.6580413", "0.65202546", "0.61486924", "0.593506", "0.5693366", "0.5693366", "0.568712", "0.5684501", "0.5681833", "0.5679486", "0.5679486", "0.5679486", "0.5679486", "0.5679486", "0.5679486", "0.5679486", "0.5679486", "0.5679486", "0.5679486", ...
0.674081
0
Convierte string 2KeyDTMFTo String normal
function StringTwoKeyDTMFToString(cad) { let aReturn=''; let i=0; try { for (i=0;i<(cad.length-2);i+=2) { aReturn += TwoKeyDTMFTochar(cad[i]+cad[i+1]); } } catch(err) { DebugLog(err.message.toString()); } return (aReturn); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function StringTo2KeyDTMF(cad)\r\n{\r\n let aReturn='';\r\n let i=0;\r\n try\r\n {\r\n for (i=0;i<cad.length;i++)\r\n {\r\n aReturn = aReturn+CharTo2KeyDTMF(cad[i].toUpperCase());\r\n }\r\n }\r\n catch(err)\r\n {\r\n DebugLog(err.message.toString());\r\n } \r\n return aReturn;\r\n}", "function CharTo2KeyDT...
[ "0.74133885", "0.66777056", "0.6553963", "0.6067563", "0.58732074", "0.5837891", "0.583367", "0.56118786", "0.5601498", "0.5519546", "0.5493411", "0.5493411", "0.5463884", "0.54617226", "0.54569054", "0.5456802", "0.5432094", "0.5432094", "0.54316854", "0.5425919", "0.5378922...
0.79674417
0
Convierte un string a 2key dtmf
function StringTo2KeyDTMF(cad) { let aReturn=''; let i=0; try { for (i=0;i<cad.length;i++) { aReturn = aReturn+CharTo2KeyDTMF(cad[i].toUpperCase()); } } catch(err) { DebugLog(err.message.toString()); } return aReturn; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function DTMFtoCharBase64(dtmf)\r\n{\r\n let aReturn = '';\r\n try\r\n {\r\n switch(dtmf)\r\n { \r\n case '00': aReturn='A'; break;\r\n case '01': aReturn='B'; break;\r\n case '02': aReturn='C'; break;\r\n case '03': aReturn='D'; break;\r\n case '04': aReturn='E'; break;\r\n case '05': aReturn='F'; ...
[ "0.6370067", "0.6353441", "0.60405606", "0.5996002", "0.59314215", "0.5842472", "0.5836141", "0.57355326", "0.55778056", "0.5561348", "0.5537075", "0.5532573", "0.55318564", "0.55318564", "0.55218655", "0.55218655", "0.55218655", "0.55218655", "0.55218655", "0.55218655", "0.5...
0.64494807
0
Silencio de los 2 tonos DTMF
function StopSoundDTMF() { try { gb_oscTone1.amp(0); gb_oscTone2.amp(0); gb_oscTone1.stop(); gb_oscTone2.stop(); } catch(err) { DebugLog(err.message.toString()); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Poll_FFT_DTMF()\r\n{\r\n //44100 / 1024 = 43,06 Hz saltos 21,533203125 Hz\r\n try\r\n {\r\n if (gb_use_mic_dtmf === false)\r\n {\r\n return;\r\n }\r\n\t \r\n let spectrum = gb_fft.analyze();\r\n let row= -1;\r\n let col= -1; \r\n \r\n //if (spectrum[31] > 250){row = 0;}\r\n if (spectrum[32]...
[ "0.6058966", "0.5964638", "0.5915729", "0.57711905", "0.57450235", "0.5744699", "0.5703797", "0.56786746", "0.56719756", "0.5631674", "0.5613712", "0.560563", "0.5578871", "0.5575638", "0.5548615", "0.5542086", "0.551767", "0.5498882", "0.5436281", "0.54208", "0.539236", "0...
0.0
-1
Convierte fila columna a DTMF
function RowColToDtmf(row,col) { try { if ((row === 0) && (col === 0)){return ('1');} if ((row === 0) && (col === 1)){return ('2');} if ((row === 0) && (col === 2)){return ('3');} if ((row === 0) && (col === 3)){return ('A');} if ((row === 1) && (col === 0)){return ('4');} if ((row === 1) && (co...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "each(f) {\n for (var i = 0; i < rows.length; i++) {\n f(column.val(i), i);\n }\n }", "function recargaFila(){\n\tsubPrecio = 0;\n\t$('#tabla tbody').find('tr').each(function(index, element){\n\t\tsubPrecio = parseFloat(subPrecio) + parseFloat($(this).find('td').eq(5).f...
[ "0.56790465", "0.5496509", "0.5469539", "0.54569346", "0.53258365", "0.5267369", "0.51868826", "0.51748306", "0.5120406", "0.51048064", "0.5037323", "0.5031669", "0.5021916", "0.50167817", "0.49942082", "0.49932498", "0.49898624", "0.49586627", "0.49478808", "0.49400964", "0....
0.0
-1
Analiza las frecuencias desde Tarjeta Sonido
function Poll_FFT_DTMF() { //44100 / 1024 = 43,06 Hz saltos 21,533203125 Hz try { if (gb_use_mic_dtmf === true) { if ((typeof gb_mic === 'undefined') || (typeof gb_fft === 'undefined')) { return; } let spectrum = gb_fft.analyze(); let row= -1; let col= -1; if (sp...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function VerLibrosPrestados(_inicio, _fin, _filtro) {\n var autores;\n var temas;\n var prestamos;\n var prestamos_activos = [];\n var usuarios;\n if (localStorage.autores != null) autores = JSON.parse(localStorage.autores);\n else return;\n if (localStorage.temas != null) temas = JSON.pars...
[ "0.61426264", "0.61329234", "0.60433674", "0.6016633", "0.60151416", "0.601267", "0.5985496", "0.5969736", "0.5959699", "0.5956952", "0.59497243", "0.5934814", "0.59328926", "0.59093785", "0.59076434", "0.5898076", "0.58965784", "0.5883607", "0.5883371", "0.58827364", "0.5879...
0.0
-1
Lee tonos DTMF desde el gamepad conectado a MT8870
function Poll_Pad_DTMF() { try { if (gb_use_gamepad_dtmf === true) { let pads = navigator.getGamepads(); let pad0 = pads[0]; let i=0; if (pad0) { gb_cad_botones=''; for (i=0;i<pad0.buttons.length;i++) { if (pad0.buttons[i].value === 1) { gb_cad_botones+='...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Poll_Pad_DTMF()\r\n{ \r\n try\r\n {\r\n if (gb_use_gamepad_dtmf === false)\r\n {\t\r\n return;\r\n }\r\n\t\r\n let pads = navigator.getGamepads();\r\n let pad0 = pads[0];\r\n let i=0;\r\n if (pad0)\r\n {\r\n gb_cad_botones='';\r\n for (i=0;i<pad0.buttons.length;i++)\r\n {\r\n if (pad0.b...
[ "0.6907961", "0.6067778", "0.60327035", "0.58857167", "0.58231556", "0.5782203", "0.5747616", "0.57162505", "0.5669428", "0.56650484", "0.5605578", "0.55369365", "0.54975027", "0.5477136", "0.5442367", "0.5435744", "0.54341644", "0.5350091", "0.5347595", "0.5329132", "0.52777...
0.6828581
1
Dibuja los datos principales en Pantalla del gamepad
function PollDibujaDatos() { let cadTX=''; try { if (gb_forceDraw === true) { gb_forceDraw = false; background(255); //fill(0, 0, 0); if (gb_use_gamepad_dtmf === true) { text(gb_cad_botones, 200, 30); text(gb_cad_bit_dtmf, 200, 60); text('stq: '+value_stq, 200, 80); ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function inizializzaDati(oggetto){\r\n \"use strict\";\r\n\tsessionStorage.numTurnoP = Number(sessionStorage.numTurnoP) + 1;\r\n\tnomeGruppo = oggetto.group.name;\r\n //Prelevo i dati dal server, e salvo i dati\r\n\r\n //Variabile per il numero di camion\r\n var numeroCamion = oggetto.group.transportPa...
[ "0.606355", "0.5978924", "0.5921213", "0.5851112", "0.58247524", "0.5774936", "0.5727287", "0.57054", "0.5640711", "0.56159294", "0.5608813", "0.5608813", "0.5608777", "0.56060916", "0.5585993", "0.5585529", "0.5579702", "0.55794895", "0.5566532", "0.55653137", "0.55518824", ...
0.0
-1
Detecta Tipo de datagrama 1 si no tiene tipo
function DetectFrameData() { let aReturn = -1; try { if (gb_end_sms === true) { gb_end_sms = false; aReturn = Number(gb_buf_rcv_dtmf[0]); } } catch(err) { DebugLog(err.message.toString()); } return aReturn; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function crearDatagramaBinario (datagrama)\r\n {\r\n let datagramaResultante=[];\r\n \r\n /**\r\n * Se convierten los datos del datagrama obtenido por parametro a binario y se completan según la cantidad\r\n * de digitos que tiene cada campo\r\n */\r\n let version= convertirABinario(d...
[ "0.529334", "0.5166381", "0.5112037", "0.50828713", "0.5079654", "0.50419337", "0.4941976", "0.4911017", "0.488836", "0.48812842", "0.4842275", "0.47070467", "0.46567902", "0.46489617", "0.46118972", "0.4603027", "0.45814687", "0.45325777", "0.45305482", "0.45211795", "0.4502...
0.46660775
12
Procesa un SMS Tipo 0 con longitud y CRC
function ProcesSMSTipo0() { //#0xxYYzz..* let auxLen= 0; let auxCRC= 0; let cadLog=''; let i=0; let cont=0; let cadBase64=''; let cadRX=''; let cadAreaRX =''; let cadDTMF =''; try { auxLen = gb_buf_rcv_dtmf.length-2; //Quitamos * y Type 0 cadLog += new Date(Date.now()).toLocaleString...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function ProcesSMSTipo1()\r\n{\r\n let auxLen= 0; //longiud trama\r\n let auxCadLen=0; //longitud cadena\r\n let auxCRC= 0;\r\n let cadServ= 0;\r\n let cadLog='';\r\n let i=0;\r\n let cont=0;\r\n let cadBase64='';\r\n let cadDTMF ='';\r\n let cadDecompress='';\r\n let cadAreaRX ='';\r\n try\r\n {\r\n auxLen = gb_...
[ "0.69878644", "0.6129404", "0.6125521", "0.61132395", "0.6023254", "0.5928832", "0.56959", "0.5633107", "0.562692", "0.5540894", "0.55408686", "0.5540184", "0.55230504", "0.5514316", "0.54076415", "0.53659517", "0.53628266", "0.5311578", "0.5234766", "0.5210593", "0.517258", ...
0.65842795
1
Procesa un SMS Tipo 1 con longitud y CRC
function ProcesSMSTipo1() { let auxLen= 0; //longiud trama let auxCadLen=0; //longitud cadena let auxCRC= 0; let cadServ= 0; let cadLog=''; let i=0; let cont=0; let cadBase64=''; let cadDTMF =''; let cadDecompress=''; let cadAreaRX =''; try { auxLen = gb_buf_rcv_dtmf.length-7; //Quitamos *...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function SendSMSTipo1Serv(cadToSend, servicio)\r\n{\r\n //#10CRxxYYzz*\r\n //Tipo:1 \r\n //Servicio:0 Diccionario Espaniol\r\n //Longitud 00\r\n //CRC 00\r\n try\r\n {\r\n gb_buf_send_dtmf = (gb_use_relay === true) ? 'C' : '';\r\n gb_buf_send_dtmf += gb_cadPTT + gb_cadSilenceStart + '#';\r\n let cadLog = '';\r...
[ "0.6368657", "0.6356379", "0.63394445", "0.6154589", "0.5858009", "0.5661778", "0.5523624", "0.5504698", "0.5498333", "0.5498029", "0.5491549", "0.5463454", "0.5411878", "0.5390254", "0.538085", "0.53661954", "0.53593934", "0.53526956", "0.53269225", "0.5297519", "0.52930635"...
0.725428
0
Procesa los buffers de datos DTMF recibidos y eventos
function PollProcessDTMF() { try { if (gb_begin_sync_dtmf === true) { gb_begin_sync_dtmf= false; //Comienzo trama //gb_cadDTMF +=' Sync'; //let aux_cad = gb_buf_rcv_dtmf; //console.log(aux_cad); //gb_cadDTMF+=' '+StringTwoKeyDTMFToString(aux_cad); gb_buf_rcv_dtmf =''; //rese...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function ProcesSMSTipo0()\r\n{\r\n //#0xxYYzz..*\r\n let auxLen= 0;\r\n let auxCRC= 0;\r\n let cadLog='';\r\n let i=0;\r\n let cont=0;\r\n let cadBase64='';\r\n let cadRX='';\r\n let cadAreaRX ='';\r\n let cadDTMF ='';\r\n \r\n try\r\n {\r\n auxLen = gb_buf_rcv_dtmf.length-2; //Quitamos * y Type 0 \r\n cadLog +...
[ "0.6233689", "0.60080945", "0.59937626", "0.5856266", "0.5838191", "0.58273494", "0.58273494", "0.5747404", "0.5731132", "0.5697753", "0.5631476", "0.56230956", "0.5618751", "0.56152976", "0.5606243", "0.5586834", "0.55648774", "0.5557434", "0.55422467", "0.55340457", "0.5507...
0.6577281
0
Selecciona tab config gamepad
function SelectTabPAD() { try { gb_ctrl_btnTabPAD.elt.disabled = true; gb_ctrl_btnTabRX.elt.disabled = false; gb_ctrl_areaRX.hide(); gb_ctrl_areaTX.hide(); gb_ctrl_lbl_stq.show(); //labels pad Show gb_ctrl_lbl_q4.show(); gb_ctrl_lbl_q3.show(); gb_ctrl_lbl_q2.show(); gb_ctrl_lbl_q1....
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function IMcTabsConfig() { }", "function ac_showConfigPanel() {\n\tac_switchTool(\"cfg\");\n}", "function openSettingsTab(evt, tabName) {\n var i;\n var x = document.getElementsByClassName(\"settingstab\");\n for (i = 0; i < x.length; i++) {\n x[i].style.display = \"none\";\n }\n var tabl...
[ "0.618024", "0.6068545", "0.59358466", "0.5919164", "0.590008", "0.5851603", "0.58081776", "0.57505924", "0.5699452", "0.56742316", "0.56705606", "0.5651837", "0.5625869", "0.56011766", "0.55988413", "0.5595225", "0.55794436", "0.5575065", "0.55597633", "0.5555198", "0.555145...
0.55423635
21
Rutina principal Draw Poll
function draw() { try { Poll_DTMFPlaySound(); //Reproduce tonos DTMF //Poll Gamepad if (gb_use_gamepad_dtmf === true) { if (gb_play_dtmf === true) { if (gb_fullduplex === true) { Poll_Pad_DTMF(); //Lee del gamepad tonos DTMF } } else { Poll_Pad_DTMF(); //L...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "get Overdraw() {}", "function principal(){\r\n\tcleanCanvas();\r\n\tconsole.log(level.dead);\r\n\tif(level.ft==true){\r\n\t\tdrawinst();\t\r\n\t}else if(level.dead==false){\r\n\t\tdrawScore();\r\n\t\tif(level.score>=1000){\r\n\t\t\tconsole.log(level.score);\r\n\t\t\tdrawWin();\t\t\t\r\n\t\t}else{\r\n\t\t\tcoalit...
[ "0.60468614", "0.6035454", "0.58174175", "0.5711783", "0.570296", "0.56571394", "0.5649731", "0.5641426", "0.5627808", "0.562352", "0.562352", "0.562352", "0.562352", "0.56154543", "0.56114125", "0.559574", "0.558546", "0.55842197", "0.5580139", "0.5571729", "0.5562017", "0...
0.0
-1
Llamado a la api de giphy search
async function getGifs(inputValue) { try { if(inputValue == undefined){ inputValue = searchTerm.value; } gifLen = Gifs(); let url = `https://api.giphy.com/v1/gifs/search?&q=${inputValue}&limit=${gifLen}&api_key=3mIxmBZUIIPyb8R69gtxaW8Hsh74dFKV`; const resp = await fetch(url); const json ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function callGiphy(search) {\n $.ajax({\n url: getURLGiphy(search),\n method: \"GET\"\n }).then(function (response) {\n handleResponse(response);\n\n //console.log(response);\n\n })\n\n }", "function searchGiphy(keyword) {\n //Michelle's ...
[ "0.78480685", "0.76516825", "0.7610904", "0.7595845", "0.7577541", "0.7568805", "0.7533824", "0.74983215", "0.74626505", "0.7444366", "0.74282825", "0.7424192", "0.738878", "0.73646164", "0.736026", "0.73400414", "0.7327818", "0.72872883", "0.7250781", "0.7216295", "0.7205721...
0.6445797
74
Funcionalidad de boton ver mas
function Gifs() { test = test + 3; cont = 0 return test; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function eventListenerButtonsVerMas() {\n const buttonsVerMas = document.querySelectorAll('button.ver-mas');\n // Agrego listener a cada uno de los botones 'Ver mas...'\n buttonsVerMas.forEach(button => {\n button.addEventListener('click', () => {\n // Del contenedor en el que se encuent...
[ "0.64910185", "0.64407414", "0.6331949", "0.60658175", "0.60628045", "0.6048024", "0.59726", "0.5971308", "0.597014", "0.59641254", "0.5931507", "0.59247094", "0.59244555", "0.5908788", "0.5863112", "0.5855532", "0.5841489", "0.5826282", "0.58226913", "0.5818793", "0.581695",...
0.0
-1
Adapted from convertsourcemap (MIT)
function toComment(sourceMap) { // eslint-disable-next-line no-undef var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))); var data = 'sourceMappingURL=data:application/json;charset=utf-8;base64,' + base64; return '/*# ' + data + ' */'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function extractSourceMap(fs, logger, file) {\n var inline = convert_source_map_1.commentRegex.test(file.text);\n var external = convert_source_map_1.mapFileCommentRegex.exec(file.text);\n if (inline) {\n var inlineSourceMap = convert_source_map_1.fromSource(file.text);\n ...
[ "0.69679236", "0.69377637", "0.67660517", "0.644171", "0.63287604", "0.62983114", "0.6256009", "0.6210124", "0.61941147", "0.61812603", "0.6174446", "0.6158444", "0.6158444", "0.6158444", "0.6154958", "0.60953784", "0.6039884", "0.5989862", "0.5980611", "0.5979347", "0.597915...
0.0
-1
Translates the list format produced by cssloader into something easier to manipulate.
function listToStyles (parentId, list) { var styles = [] var newStyles = {} for (var i = 0; i < list.length; i++) { var item = list[i] var id = item[0] var css = item[1] var media = item[2] var sourceMap = item[3] var part = { id: parentId + ':' + i, css: css, media: medi...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function listToStyles(parentId, list) {\n var styles = [];\n var newStyles = {};\n\n for (var i = 0; i < list.length; i++) {\n var item = list[i];\n var id = item[0];\n var css = item[1];\n var media = item[2];\n var sourceMap = item[3];\n ...
[ "0.63066626", "0.6301221" ]
0.0
-1
globals __VUE_SSR_CONTEXT__ IMPORTANT: Do NOT use ES2015 features in this file (except for modules). This module is a runtime utility for cleaner component module output and will be included in the final webpack user bundle.
function normalizeComponent ( scriptExports, render, staticRenderFns, functionalTemplate, injectStyles, scopeId, moduleIdentifier, /* server only */ shadowMode, /* vue-cli only */ components, // fixed by xxxxxx auto components renderjs // fixed by xxxxxx renderjs ) { // Vue.extend constructor expo...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Es(t,e,n,i,r,o,a,s){var u=(\"function\"===typeof n?n.options:n)||{};return u.__file=\"source.vue\",u.render||(u.render=t.render,u.staticRenderFns=t.staticRenderFns,u._compiled=!0,r&&(u.functional=!0)),u._scopeId=i,u}", "extend(config, ctx) {\n // if (process.server && process.browser) {\n if (...
[ "0.58465886", "0.57273436", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.572473", "0.5...
0.0
-1
Carga el formulario para buscar a un cliente especifico
function js_descuentofactura_carga_busquedaCliente(div,url){ var spanish_in="//cdn.datatables.net/plug-ins/f2c75b7247b/i18n/Spanish.json"; document.getElementById(div).innerHTML='<br><div align="center" style="height:100%;"><i style="font-size:large;color:#E55A2F;" class="fa fa-cog fa-spin"></i></div>'; var...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function init_inpt_formulario_cargar_recorrido() {\n // Inputs del formulario para inicializar\n}", "function buscarClienteOnClick(){\n if ( get('formulario.accion') != 'clienteSeleccionado' ) {\n // var oid;\n // var obj = new Object();\n var whnd = mostrarModalSICC('LPBus...
[ "0.689254", "0.6844166", "0.65094787", "0.64512306", "0.624657", "0.62300247", "0.622515", "0.6215107", "0.6197003", "0.6194617", "0.6188483", "0.61882913", "0.6183829", "0.6148888", "0.6147197", "0.61382395", "0.611139", "0.61085063", "0.60609573", "0.6059345", "0.6051096", ...
0.0
-1
Valida que no se desborden los abonos asignados por el usuario deacuerdo a los pagos ingresados por el mismo
function validaDesbordamientoAbono (e, field, totalPagos, max_value) { var maximo=0; if(max_value>totalPagos) { maximo=parseFloat(totalPagos); } else { maximo=parseFloat(max_value); } //var valor = field.value; var valor_actual = field.value+String.fromCharCode(e.which); var va...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function AdministrarValidaciones() {\r\n var _a, _b, _c, _d;\r\n var Valido = true;\r\n var errorArray = [];\r\n if (!ValidarCamposVacios(\"numDni\") || !ValidarRangoNumerico(\"numDni\", 1000000, 55000000)) {\r\n console.log(\"Error en el DNI\");\r\n errorArray.push(\"DNI\");\r\n V...
[ "0.5856784", "0.5822479", "0.58029985", "0.57743263", "0.57218814", "0.5707674", "0.57062244", "0.5692129", "0.567697", "0.56752175", "0.5659836", "0.5649498", "0.5640227", "0.56207687", "0.5603791", "0.55922097", "0.5580455", "0.55730784", "0.5570467", "0.5558738", "0.555190...
0.5373769
35
Quita una deuda de la grilla lista a cobrar
function quitarDeuda(codigoDeuda) { $('#deudasSeleccionadas_table tbody tr').each(function(){ if( $(this).find('td').eq(0).data('codigo') == codigoDeuda ) { $(this).remove(); } }); justificaMensajeNoData($('#deudasSeleccionadas_table')); // Agrego el div que coloca el datatable donde...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function iniciarListaBusqueda(){\n var ciclos = selectDatoErasmu();\n for(var aux = 0, help = 0 ; aux < erasmu.length ; aux++){\n if(ciclos.indexOf(erasmu[aux].ciclo) != -1){\n crearListErasmu(erasmu[aux]);\n }\n }\n}", "listarPendientesCompletados (completado=true){\n\n //Arreglos para dife...
[ "0.6693157", "0.66415733", "0.65689874", "0.63596463", "0.6245344", "0.62328255", "0.62217903", "0.6192027", "0.6145261", "0.61371773", "0.61111224", "0.605773", "0.5983271", "0.59605867", "0.5955452", "0.59468895", "0.5935828", "0.59261113", "0.5910041", "0.5907397", "0.5904...
0.0
-1
Carga el combo de las manzanas
function js_descuentofactura_carga_porcentaje( valor, div, url ) { var data = new FormData(); var v_readonly = 0; if ( document.getElementById("porcentaje_descto").getAttribute("readonly") == "readonly" ) v_readonly = 0; else v_readonly = 1; document.getElementById(div).innerHTML=...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function posicionarCombos() { \n\t\t//combo tipoSolicitud\n\t\tvar iSeleccionadoTipoSol = new Array(); \n\t\tiSeleccionadoTipoSol[0] = get('frmFormulario.hOidTipoSolicitud'); \n\t\tset('frmFormulario.cbTipoSolicitud',iSeleccionadoTipoSol); \n\n\t\t//combo periodos\n\t\tvar iSeleccionadoPeriodo = new Array(); \n\t\...
[ "0.72694623", "0.6981651", "0.68885624", "0.68804777", "0.68360317", "0.6783176", "0.67803514", "0.67546034", "0.6688931", "0.66785944", "0.6678474", "0.66555494", "0.66452414", "0.66113174", "0.6569539", "0.6527432", "0.6517877", "0.65052074", "0.650049", "0.649853", "0.6483...
0.0
-1
criptografia do email para a api gravatar
emailCript() { const { emailUser } = this.props; const stringEmail = md5(emailUser).toString(); this.setState({ criptoEmail: stringEmail, }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getGravatarUrl(email) {\n return $gravatar.generate(email);\n }", "function Gravatar (props) {\n const email = props.email;\n const hash = md5(email);\n\n return(\n <img className={props.className}\n src={'https://s.gravatar.com/avatar/'||`${hash}`||'?s=80'} //arre...
[ "0.66961664", "0.63684964", "0.6151422", "0.61103845", "0.6063167", "0.5995908", "0.594422", "0.5868086", "0.58059365", "0.5804434", "0.57796246", "0.57788473", "0.5740457", "0.57347375", "0.5727868", "0.5713128", "0.5704428", "0.5669228", "0.56597906", "0.56411445", "0.56365...
0.52164656
70
!AngularListOperator object parameters items: the item array which will be operate. tempItem: a single default template item. return
function AngularListOperator(items,tempItem){ this.tempItem={}; this.items=[]; this.tempItem=tempItem; this.items=items; //operate tag values this.operate={ opr_id:{name:"opr_id"}, opr_display:{name:"opr_display",enum:{"display":true,"hidden":false}}, opr_status:{name:"opr_status",en...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function templateCntl($scope) {\n console.log('in template');\n var items = [];\n var anItem = {\n type: 'text' //or table, or calendar\n ,isSection: false\n ,title: 'my first item'\n ,content: 'and this is the content'\n };\n $scope.items = items;\n}", "function listI...
[ "0.56641924", "0.55928785", "0.55308694", "0.5529264", "0.5476436", "0.5461293", "0.5406746", "0.539825", "0.5385362", "0.5379865", "0.5379865", "0.5379865", "0.53781545", "0.5375956", "0.532436", "0.5322039", "0.5311958", "0.53069633", "0.5297092", "0.5257466", "0.5250631", ...
0.77381706
0
A definir o lugar dela.
function criarObjetoFis(_objeto) { var objeto = _objeto; switch (objeto) { case "Esfera": { try { if (document.getElementById("MassaEsfera").value === "" || document.getElementById("MassaEsfera").value <= 0) { alert("O valor da da massa não pode se...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "constructor(nombreLugar='Tierra de mordor', tipoDescripcion='Es un lugar rodeado de arboles muertos y arena negra, donde no se puede ver nada por su densa niebla.')\r\n {\r\n this.nombreLugar = nombreLugar;\r\n this.tipoDescripcion = tipoDescripcion;\r\n }", "function lalalala() {\n\n}", "constructor(n...
[ "0.6669704", "0.65097404", "0.6474004", "0.64200014", "0.63002086", "0.6228127", "0.61945844", "0.6184454", "0.6184115", "0.61688805", "0.6121656", "0.6107887", "0.60410815", "0.59972215", "0.59865516", "0.59741884", "0.5964914", "0.5961498", "0.5939296", "0.5921166", "0.5912...
0.0
-1
var fs = require('fs'); Searches player stats given player term
function searchPlayer(term) { return search(term, 'soccer player', true); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function randomSearch() {\n\nfs.readFile(\"random.txt\", \"utf8\", function(respError, data) {\n\n var randomArray = data.split(\", \");\n\n errorCheck();\n\n if (randomArray[0] == \"spotify-this\") {\n findSong(randomArray[1]);\n } else if (randomArray[0] == \"movie-this\") {\n findMovie...
[ "0.6536013", "0.65353537", "0.63952893", "0.6003416", "0.5923568", "0.59141505", "0.591365", "0.59050244", "0.58963275", "0.58764195", "0.58618766", "0.5837937", "0.58032906", "0.579475", "0.5791965", "0.5783436", "0.57745874", "0.5766538", "0.5758997", "0.5758406", "0.574884...
0.6440655
2
Searches a team stats given team term
function searchTeam(term) { return search(term, 'soccer club', true); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function search( searchTerm ) {\n //If teams[] array is empty, return (maybe it is still loading or is empty for some reason)\n if(teams.length === 0) {\n return;\n }\n \n var convertedSearchTerm = searchTerm.toUpperCase(); \n hits.length = 0; \n\n for ( var i = 0; i < teams.length; i++ ) { \n // Search...
[ "0.7499354", "0.6815976", "0.62446386", "0.62212443", "0.6100092", "0.6062966", "0.6039086", "0.5995693", "0.5986417", "0.592927", "0.59111893", "0.59098005", "0.5815349", "0.5781848", "0.5740773", "0.5733888", "0.5726606", "0.570673", "0.56988865", "0.5666331", "0.56544834",...
0.81517166
0
Searches stats for term term given term and ontology class
function search(term, ontologyClass, firstOnly) { helper.debug('term: ', term, ' class: ', ontologyClass); return new Promise(function(resolve, reject) { dbp.keywordSearch(term, ontologyClass, function(results) { if (results == null) { reject("error searching"); }...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function search(term) {\n RtThisRun = 0\n console.log('Search: ' + JSON.stringify(term));\n T.get('search/tweets', { q: term, count: 10 }, function(err, reply) {\n if (err) {\n return err;\n }\n \n var tweets = reply.statuses;\n tweets.forEach(function(o) { ch...
[ "0.6508114", "0.63046783", "0.61540496", "0.6100761", "0.6079867", "0.5855075", "0.5854378", "0.5818459", "0.57975036", "0.5770043", "0.5750915", "0.5747712", "0.57427126", "0.5740345", "0.56651664", "0.5661367", "0.5641545", "0.5596306", "0.55864763", "0.5583709", "0.5563357...
0.6143865
3
String providing the tag name to register the element under.
static get is() { return "firefly-login-provider-item"; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function updateTagNameDisplayer(element) {\n $(\"#tag-name\").text(\"<\" + element.tagName + \">\");\n}", "get annotatedName() {\n if (this.annotation) {\n return this.annotation;\n }\n else {\n return `<${this.tagName}>`;\n }\n }", "constructor(shownName...
[ "0.6640236", "0.6094292", "0.60864943", "0.60658187", "0.6060267", "0.5899772", "0.58273387", "0.58273387", "0.58273387", "0.58273387", "0.58042705", "0.5776867", "0.5770518", "0.5731797", "0.568792", "0.5679729", "0.5671037", "0.5661941", "0.5661941", "0.5661941", "0.5661941...
0.0
-1
Object describing propertyrelated metadata used by Polymer features
static get properties() { return { /** The ID of the item is the auth provider. i.e. 'google', 'facebook', etc */ id: { type: String, value: "" }, /** The text of the label to be displayed. */ label: { type: String, value: "" }, /** The ico...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "static get properties() {\n return {\n title: {\n type: String\n },\n initialTool: {\n attribute: 'initialtool',\n type: String\n },\n }\n }", "static get properties() {\n return {\n label: { type: S...
[ "0.71726227", "0.7169829", "0.70662737", "0.6885095", "0.68430597", "0.6766321", "0.67564565", "0.66670036", "0.6634938", "0.6548201", "0.6543979", "0.65407705", "0.6509862", "0.6509862", "0.65078914", "0.64804155", "0.64797443", "0.64649576", "0.64472115", "0.6432242", "0.64...
0.6154194
35
Instance of the element is created/upgraded. Use: initializing state, set up event listeners, create shadow dom.
constructor() { super(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "init() {\n // override init to make sure createEl is not triggered\n }", "ready() {\n super.ready();\n const that = this;\n\n that._createElement();\n }", "setupUselessElement() {\n this.uselessElement = this.document.createElement('div');\n }", "setupUselessElement() {\n t...
[ "0.6551576", "0.6409181", "0.63825965", "0.63825965", "0.63825965", "0.63527596", "0.6111384", "0.6063018", "0.6046229", "0.60349965", "0.6033839", "0.5984546", "0.597416", "0.5959151", "0.5937906", "0.59257185", "0.58933425", "0.58754593", "0.5828205", "0.5812903", "0.581238...
0.0
-1
Use for onetime configuration of your component after local DOM is initialized.
ready() { super.ready(); afterNextRender(this, function() {}); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function initConfig() {\n\tupdateDOM();\t\n}", "async initialize(config) { \n \n this.url = config.url;\n \n this.appendWidgetScript();\n }", "init() {\n // override init to make sure createEl is not triggered\n }", "configure () {\n // this can be extended in children classes to avoid ...
[ "0.73335564", "0.6550655", "0.6488836", "0.6481784", "0.6467598", "0.64625657", "0.63998014", "0.63696283", "0.63543314", "0.63226455", "0.63226455", "0.6313334", "0.6301065", "0.620518", "0.619442", "0.61637914", "0.61495346", "0.61450315", "0.6118691", "0.6093574", "0.60259...
0.0
-1
POINTS UPDATE THE COUNTER
function updateCounter() { document.querySelector('#counter').textContent = (points); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function incrementPoints() {\n currentPointValue++;\n }", "addPoint() {\n this.points += 1;\n this.updateScore();\n }", "function increasePoints() {\n\tvar points = parseInt(pointsLabel.innerHTML);\n\tnewPoints = 20 / (seconds + 1) + 3;\n\tnewPoints = Math.round(newPoints);\n\tnewPoints *= 100...
[ "0.8081689", "0.74488485", "0.7242448", "0.71695", "0.71073014", "0.70761055", "0.6985826", "0.6974689", "0.689769", "0.68555206", "0.6814216", "0.677296", "0.67685807", "0.6724368", "0.6695941", "0.66217613", "0.66174316", "0.6609617", "0.6605062", "0.6587106", "0.6563072", ...
0.76945406
1
Not at all contrived Generator
function translating(language) { return regeneratorRuntime.wrap(function translating$(context$1$0) { while (1) switch (context$1$0.prev = context$1$0.next) { case 0: console.log('Winding up the gears...'); context$1$0.next = 3; return null; case 3: console.log('Finding...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Generator(){}", "function Generator(){}", "function Generator(){}", "function Generator(){}", "function Generator(){}", "function Generator(){}", "function Generator() {}", "function Generator() {}", "function Generator() {}", "function Generator() {}", "function Generator() {}", "fu...
[ "0.85245", "0.85245", "0.85245", "0.85245", "0.85245", "0.85245", "0.85160464", "0.85160464", "0.85160464", "0.85160464", "0.85160464", "0.85160464", "0.85160464", "0.85160464", "0.85160464", "0.85160464", "0.85160464", "0.85160464", "0.85160464", "0.85160464", "0.85160464", ...
0.0
-1
codigo de chullo no BORRAR este es tu codigo chullito desde la linea 86 hasta 210
render(){ return( <View style={{flex: 1}}> <ImageBackground source = {imgBackground} style={{width: '100%', height: '100%'}} > <Text style={{ ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getBrillo(valor){\n if(valor<0)\n return 0;\n if(valor>255)\n return 255;\n else\n return valor;\n }", "function identificarTipoBoleto(codigo) {\n codigo = codigo.replace(/[^0-9]/g, '');\n\n if (typeof codigo !== ...
[ "0.61492896", "0.61374843", "0.60601884", "0.5908802", "0.56593674", "0.56547225", "0.562407", "0.5606917", "0.56041056", "0.5580653", "0.5558394", "0.5483325", "0.54694355", "0.546422", "0.5461838", "0.54514885", "0.5451384", "0.5424274", "0.54122406", "0.5375503", "0.534889...
0.0
-1
to clear all data from redis use flushdb
deleteRedis(redisKeyArray) { return new Promise((resolve, reject) => { client.del(redisKeyArray, function (err, succeeded) { if (err) { reject(err); } else { resolve(succeeded); } }); }); ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "clearDb() {\n db.createKeyStream().on('data', key=>db.del(key));\n }", "function clear() {\n\tdb = {};\n}", "function clearAll(){\r\n\tObject.keys(this.datastore).forEach((key)=>\r\n\t{\r\n\t\tdelete this.datastore[key];\r\n\t});\t\r\n}", "static flush() {\n PStore.clearAll();\n }", "async fu...
[ "0.75557894", "0.72886634", "0.70574087", "0.6961206", "0.69243354", "0.6852064", "0.68454665", "0.6788997", "0.6777934", "0.67698145", "0.67514414", "0.6679419", "0.6663751", "0.66366965", "0.6619183", "0.6616945", "0.6561292", "0.65457165", "0.6494347", "0.64901197", "0.646...
0.0
-1
Have the function DashInsert(str) insert dashes ('') between each two odd numbers in str. For example: if str is 454793 the output should be 454793. Don't count zero as an odd number.
function DashInsert(str) { // code goes here return str; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function DashInsert(str) { \r\n\r\n // code goes here \r\nvar numbers=str.split(\"\");\r\nvar result=[];\r\nfor(var i=0;i<numbers.length;i++){\r\n if((numbers[i]%2&&numbers[i+1]%2)==1){\r\n numbers[i]=numbers[i]+\"-\";\r\n\r\n }\r\n result.push(numbers[i]);\r\n}\r\nreturn result.join(\"\");\r\n}"...
[ "0.87130755", "0.86572516", "0.8430845", "0.8406211", "0.8174874", "0.8168105", "0.80795103", "0.8052132", "0.77774554", "0.76582783", "0.75036156", "0.7353825", "0.7312933", "0.7174091", "0.7082239", "0.7000399", "0.6928466", "0.65788954", "0.6561445", "0.65296614", "0.63116...
0.69107246
17
1. menampilkan menu mata_kuliah
function menuMataKuliah() { rl.setPrompt(console.log(` =========================================================== Silahkan pilih opsi di bawah ini [1] daftar mata kuliah [2] cari mata kuliah [3] tambah mata kuliah [4] hapus mata kuliah [5] kembali ===============================...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function simulat_menu_infos() {\n display_menu_infos();\n}", "function DetailMenuMakanan(IdMenuMakanan)\n{\n Messi.load(\"module/content.php?m=menumakanan&a=DetailMenuMakanan&IdMenuMakanan=\"+IdMenuMakanan, \n {title: 'Detail Menu Makanan', titleClass: 'info', modal: true, width: '500px', buttons: [{id:...
[ "0.6809553", "0.6673447", "0.6592012", "0.63755167", "0.63001686", "0.62811255", "0.627437", "0.61846346", "0.61615634", "0.61530125", "0.61218894", "0.6027496", "0.6016777", "0.59878504", "0.5958516", "0.5949031", "0.59466964", "0.5946361", "0.5944586", "0.59118223", "0.5907...
0.65855646
3
digest the queue of open buy/sell orders
async consume() { if (this.state.consuming) return; if (!this.queue.meta.length) return; this.state.consuming = true; console.log('Consuming queue...', 'Orders in queue: ' + this.queue.meta.length); const filledTransactions = await this.queue.digest(); //repopulate que...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async sendOrders()\n\t{\n\t\tvar currentBlock = await EtherMiumApi.getCurrentBlockNumber();\n\t\ttry {\n\t\t\tfor (let token of this.tokensList)\n\t\t\t{\n\t\t\t\tvar found_buy_order = false;\n\t\t\t\tvar found_sell_order = false;\n\n\t\t\t\t// check if there active orders\n\t\t\t\tvar orders = await EtherMiumApi....
[ "0.602205", "0.59220463", "0.5908035", "0.5846901", "0.57785326", "0.57484376", "0.5724596", "0.56473637", "0.56043786", "0.5581398", "0.5576218", "0.55615354", "0.5551782", "0.55470496", "0.5515174", "0.55141234", "0.5476634", "0.5473289", "0.54628617", "0.5459224", "0.54413...
0.67462915
0
calculate quantity of coin to purchase based on given budget from .env
calculateQuantity() { console.log('Calculating quantity... '); const symbol = this.symbol.meta; const minQuantity = symbol.minQty; const maxQuantity = symbol.maxQty; const quantitySigFig = symbol.quantitySigFig; const stepSize = symbol.stepSize; //minimum quantity differ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getMoneySpent(keyboards, drives, budget) {\n\tlet totalPrice = -1;\n\n\tfor (let i = 0; i < keyboards.length; i++) {\n\t\tfor (let j = 0; j < drives.length; j++) {\n\t\t\tlet sum = keyboards[i] + drives[j];\n\n\t\t\tif (sum <= budget && sum > totalPrice) {\n\t\t\t\ttotalPrice = sum;\n\t\t\t}\n\t\t}\n\t}\n...
[ "0.6711728", "0.65935516", "0.65357095", "0.65249914", "0.65060085", "0.6499298", "0.64533114", "0.6421219", "0.6417626", "0.64006317", "0.63867164", "0.6385053", "0.6344331", "0.63169014", "0.63153183", "0.6281409", "0.6265249", "0.6265069", "0.62632066", "0.62494195", "0.62...
0.6699428
1
push an unfilled limit purchase order to the queue
async purchase(quantity, price) { try { const symbol = this.symbol.meta; const tickSize = symbol.tickSize; //minimum price difference you can trade by const priceSigFig = symbol.priceSigFig; const quantitySigFig = symbol.quantitySigFig; const unconfir...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "enqueue(item) {\n this.queue.push(item);\n this.size += 1;\n }", "enqueue(element) {\n // adding element to the queue \n this.items.push(element);\n }", "enqueue(element) {\n // adding element to the queue \n this.items.push(element);\n }", "enqueue(element) {\n ...
[ "0.63033617", "0.62847465", "0.62847465", "0.62847465", "0.62689126", "0.62689126", "0.62673914", "0.6249882", "0.622663", "0.6177341", "0.6111176", "0.6096332", "0.60598296", "0.6051982", "0.60304147", "0.5998505", "0.5993917", "0.59781843", "0.59736156", "0.5970237", "0.595...
0.5776236
34
push an unfilled limit sell order to the queue
async sell(quantity, profit) { try { const symbol = this.symbol.meta; const tickSize = symbol.tickSize; //minimum price difference you can trade by const priceSigFig = symbol.priceSigFig; const quantitySigFig = symbol.quantitySigFig; const unconfirmed...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async placeSellLimitOrder(amount, price){\n return await this.exchange.placeSellLimitOrder(amount, price);\n }", "async placeBuyLimitOrder(amount, price){\n return await this.exchange.placeBuyLimitOrder(amount, price);\n }", "function sellOrder(price) {\n\tvar amount = BTC - keepBTC;\n\t\n\...
[ "0.65006316", "0.6471445", "0.64266276", "0.64255553", "0.6224162", "0.61757964", "0.6174636", "0.6144907", "0.6130078", "0.6079346", "0.605974", "0.605974", "0.60461986", "0.60357714", "0.60125524", "0.5984316", "0.5984316", "0.5984316", "0.59795547", "0.59762067", "0.597130...
0.5815175
28
By using the above way of making object, if we need to make 10 types of cars then we need to give value to every property 10 types for 10 different cars, So, to avoid that repetition of work we need to create the object using constructor method like follows.
function carConstructor(carName, model, color, brand){ this.theCarName = carName; this.theModel = model; this.theColor = color; this.theBrand = brand; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function car(model,year,color,speed,engine,shape){\n//we use this to create a property of an object\n//this property name should be the same as the parameter\nthis.model=model\nthis.year=year\nthis.color=color\nthis.speed=speed\nthis.engine=engine\nthis.body=body\n}", "function myCar(make, model, year, color){\n...
[ "0.717366", "0.6950849", "0.6915672", "0.6755867", "0.6639787", "0.6589559", "0.65784204", "0.65626913", "0.65553063", "0.65378255", "0.65280586", "0.65251315", "0.6516299", "0.6498377", "0.64968115", "0.64774126", "0.6463716", "0.64603645", "0.6424766", "0.6424766", "0.64171...
0.6704386
4
tiny helper function to add breakpoints
function getGridSize() { return (window.innerWidth < 320) ? 1 : (window.innerWidth < 600) ? 2 : (window.innerWidth < 800) ? 3 : (window.innerWidth < 900) ? 4 : 5; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "_registerBreakpoints() {\n const self = this;\n\n self.$win.mediaQueryEvents({\n breakpoints: self.opts.breakpoints\n });\n }", "_addBreakpoints() {\n for (var i in Foundation.MediaQuery.queries) {\n if (Foundation.MediaQuery.queries.hasOwnProperty(i)) {\n var query = Foundation.Med...
[ "0.6714101", "0.6669999", "0.6657945", "0.65653723", "0.63086164", "0.6290297", "0.62746996", "0.61558396", "0.6126688", "0.6112599", "0.60694015", "0.6063303", "0.60611445", "0.6060265", "0.6032141", "0.60083616", "0.60023844", "0.60023844", "0.60023844", "0.60023844", "0.59...
0.0
-1
Return a firebase namespace object. In production, this will be called exactly once and the result assigned to the 'firebase' global. It may be called multiple times in unit tests.
function createFirebaseNamespace() { var apps_ = {}; var factories = {}; var appHooks = {}; // A namespace is a plain JavaScript Object. var namespace = { // Hack to prevent Babel from modifying the object returned // as the firebase namespace. __esModule: true, ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function createFirebaseNamespace() {\n var apps_ = {};\n var factories = {};\n var appHooks = {};\n // A namespace is a plain JavaScript Object.\n var namespace = {\n // Hack to prevent Babel from modifying the object returned\n // as the firebase namespace.\n __esModule: true,\...
[ "0.7396058", "0.7396058", "0.7395023", "0.73853666", "0.73261255", "0.7325864", "0.7325686", "0.7305236", "0.73001844", "0.72946507", "0.7282356", "0.7241198", "0.7237989", "0.7228324", "0.7228324", "0.71012306", "0.70843583", "0.6664544", "0.59658456", "0.591994", "0.5859306...
0.72926885
10
Called by App.delete() but before any services associated with the App are deleted.
function removeApp(name) { var app = apps_[name]; callAppHooks(app, 'delete'); delete apps_[name]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async delete() {\r\n const services = Array.from(this.instances.values());\r\n await Promise.all([\r\n ...services\r\n .filter(service => 'INTERNAL' in service) // legacy services\r\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\r\n ...
[ "0.65310735", "0.6322627", "0.61983705", "0.5972042", "0.5902842", "0.58731693", "0.5814189", "0.5814189", "0.5814189", "0.5814189", "0.5814189", "0.5814189", "0.5778787", "0.57423764", "0.5738532", "0.5733327", "0.5728636", "0.5704295", "0.56835425", "0.56539804", "0.5644793...
0.5145323
75
Get the App object for a given name (or DEFAULT).
function app(name) { name = name || DEFAULT_ENTRY_NAME; if (!contains(apps_, name)) { error('no-app', { name: name }); } return apps_[name]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function app(name) {\r\n name = name || DEFAULT_ENTRY_NAME;\r\n if (!util.contains(apps, name)) {\r\n throw ERROR_FACTORY.create(\"no-app\" /* NO_APP */, { appName: name });\r\n }\r\n return apps[name];\r\n }", "function app(name) {\r\n name = name || DEFAULT_ENTR...
[ "0.85640585", "0.85640585", "0.85640585", "0.85640585", "0.85640585", "0.85560256", "0.85454327", "0.85454327", "0.83911544", "0.8369064", "0.8369064", "0.8369064", "0.8369064", "0.8369064", "0.8369064", "0.8369064", "0.8369064", "0.8369064", "0.8369064", "0.8369064", "0.8366...
0.84141004
9
Return an array of all the nondeleted FirebaseApps.
function getApps() { // Make a copy so caller cannot mutate the apps list. return Object.keys(apps_).map(function (name) { return apps_[name]; }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getApps() {\r\n return Array.from(_apps.values());\r\n}", "function destroyFirebaseApps() {\n var deletions = _firebase.default.apps.map(function (app) {\n return app.delete();\n });\n Ember.RSVP.all(deletions).then(function () {\n return run(function () {\n // NOOP to delay...
[ "0.6482602", "0.6231479", "0.62088907", "0.62088907", "0.6073565", "0.6062356", "0.60584325", "0.60584325", "0.60584325", "0.60584325", "0.60584325", "0.60584325", "0.6044587", "0.6036813", "0.6036813", "0.6036813", "0.6036813", "0.6036813", "0.6036813", "0.6036813", "0.60368...
0.6056177
13
Register a Firebase Service. firebase.INTERNAL.registerService() TODO: Implement serviceProperties.
function registerService(name, createService, serviceProperties, appHook, allowMultipleInstances) { // Cannot re-register a service that already exists if (factories[name]) { error('duplicate-service', { name: name }); } // Capture the service factory for later service i...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function RegisterService() { }", "function registerService(name, createService, serviceProperties, appHook, allowMultipleInstances) {\n // Cannot re-register a service that already exists\n if (factories[name]) {\n error('duplicate-service', { name: name });\n }\n // Captur...
[ "0.7038455", "0.7001225", "0.7001225", "0.6969678", "0.6955652", "0.6955286", "0.6955286", "0.69436747", "0.69334453", "0.69334453", "0.69001436", "0.6895383", "0.6895383", "0.68870986", "0.6863721", "0.68226594", "0.68226594", "0.657825", "0.63509023", "0.63509023", "0.63274...
0.6939398
9
Patch the toplevel firebase namespace with additional properties. firebase.INTERNAL.extendNamespace()
function extendNamespace(props) { util.deepExtend(namespace, props); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function extendNamespace(props) {\n Object(_firebase_util__WEBPACK_IMPORTED_MODULE_1__[\"deepExtend\"])(namespace, props);\n }", "function extendNamespace(props) {\n Object(_firebase_util__WEBPACK_IMPORTED_MODULE_1__[\"deepExtend\"])(namespace, props);\n }", "function extendNamespace(props)...
[ "0.7600929", "0.7600929", "0.7600929", "0.7600929", "0.75977015", "0.75977015", "0.7552601", "0.7524821", "0.7524821", "0.74773073", "0.7473711", "0.7473711", "0.724302", "0.6654882", "0.65823597", "0.65823597", "0.65503323", "0.65503323", "0.64324695", "0.64129937", "0.63206...
0.6291142
30
Map the requested service to a registered service name (used to map auth to serverAuth service when needed).
function useAsService(app, name) { if (name === 'serverAuth') { return null; } var useService = name; var options = app.options; return useService; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function serviceName (ctx) {\n const {mu, server} = ctx\n\n const handle = pattern(mu)\n\n // set up the component\n component({name}, ctx)\n\n // set up API routes for services\n\n server.route({\n method: 'GET',\n path: '/service-name/one',\n handler: handle({role: name, cmd: 'one'})\n })\n\n //...
[ "0.631961", "0.628306", "0.6266422", "0.6239733", "0.62207735", "0.6161897", "0.6161897", "0.6161897", "0.6161897", "0.6161897", "0.6161897", "0.6155846", "0.6155846", "0.6155846", "0.6155846", "0.6155846", "0.6155846", "0.6155846", "0.6155846", "0.6071547", "0.60624367", "...
0.5910525
36
Portions of this code are from MochiKit, received by The Closure Authors under the MIT license. All other code is Copyright 20052009 The Closure Authors. All Rights Reserved.
function hh(a,b){this.g=[];this.v=a;this.u=b||null;this.f=this.a=!1;this.c=void 0;this.l=this.w=this.i=!1;this.h=0;this.b=null;this.m=0}
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private internal function m248() {}", "private public function m246() {}", "transient protected internal function m189() {}", "static private internal function m121() {}", "static final private internal function m106() {}", "protected internal function m252() {}", "transient private protected internal ...
[ "0.7015196", "0.68221396", "0.64721495", "0.645177", "0.63634706", "0.63576025", "0.6283477", "0.62537736", "0.6181127", "0.6060236", "0.6005848", "0.5902877", "0.58771926", "0.58558613", "0.5826161", "0.5814073", "0.5808794", "0.5795108", "0.57838106", "0.5770663", "0.576977...
0.0
-1
Copyright 2017 Google Inc. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS I...
function NAME_ONLY_COMPARATOR(left, right) { return nameCompare(left.name, right.name); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function me(e,t,a,s){var n,i=arguments.length,r=i<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,a):s;if(\"object\"==typeof Reflect&&\"function\"==typeof Reflect.decorate)r=Reflect.decorate(e,t,a,s);else for(var d=e.length-1;d>=0;d--)(n=e[d])&&(r=(i<3?n(r):i>3?n(t,a,r):n(t,a))||r);return i>3&&r&&Object.definePro...
[ "0.57526267", "0.5344435", "0.52881753", "0.5241314", "0.50730455", "0.50553477", "0.5051857", "0.5051857", "0.5051702", "0.5027337", "0.49896058", "0.49863064", "0.49736023", "0.49573568", "0.49151677", "0.48896116", "0.48750693", "0.48582536", "0.48582536", "0.48466054", "0...
0.0
-1
Gives you an instance of a Logger to capture messages according to Firebase's logging scheme.
function Logger(name) { this.name = name; /** * The log level of the given Logger instance. */ this._logLevel = defaultLogLevel; /** * The log handler for the Logger instance. */ this._logHandler = defaultLogHandler; /** ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getLogger() {\n if (logger) return logger;\n var ccLogger = ccHandler(serializer);\n logger = new logger$1.Logger('@firebase/performance/cc');\n logger.logHandler = ccLogger;\n return logger;\n}", "function getLogger() {\r\n if (logger) {\r\n return logger;\r\n }\r\n var ccLogger = ...
[ "0.6986026", "0.6933602", "0.65863216", "0.6470402", "0.64227134", "0.63121414", "0.6255328", "0.62327695", "0.6198341", "0.61969954", "0.602709", "0.6016677", "0.5993694", "0.5946694", "0.59342194", "0.5931741", "0.59288454", "0.59000206", "0.5881631", "0.5872361", "0.584135...
0.5472387
70
Copyright 2017 Google Inc. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS I...
function setLogLevel(level) { instances.forEach(function (inst) { inst.logLevel = level; }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function me(e,t,a,s){var n,i=arguments.length,r=i<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,a):s;if(\"object\"==typeof Reflect&&\"function\"==typeof Reflect.decorate)r=Reflect.decorate(e,t,a,s);else for(var d=e.length-1;d>=0;d--)(n=e[d])&&(r=(i<3?n(r):i>3?n(t,a,r):n(t,a))||r);return i>3&&r&&Object.definePro...
[ "0.57508355", "0.5345458", "0.5285114", "0.5238391", "0.50738794", "0.50537604", "0.5053402", "0.5053402", "0.50511533", "0.50274", "0.49889907", "0.4984785", "0.49724665", "0.495729", "0.49126434", "0.48875505", "0.48740584", "0.48586908", "0.48586908", "0.48470676", "0.4847...
0.0
-1
Take a potentially misbehaving resolver function and make sure onFulfilled and onRejected are only called once. Makes no guarantees about asynchrony.
function doResolve(fn, self) { var done = false; try { fn( function(value) { if (done) return; done = true; resolve(self, value); }, function(reason) { if (done) return; done = true; reject(self, reason); } ); } catch (ex) { if (d...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function doResolve(fn, onFulfilled, onRejected) {\n var done = false;\n try {\n fn(function (value) {\n if (done) return;\n done = true;\n onFulfilled(value);\n }, function (reason) {\n if (done) return;\n done = true;\n onRejected(reaso...
[ "0.7080197", "0.70737344", "0.7044053", "0.7041934", "0.7041934", "0.7041934", "0.70339864", "0.7033429", "0.7033429", "0.7033429", "0.7033429", "0.7033429", "0.7016779", "0.69620943", "0.69620943", "0.69620943", "0.69620943", "0.6809515", "0.6281849", "0.6168724", "0.6025227...
0.56241477
85
Copyright 2017 Google Inc. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS I...
function deepCopy(value) { return deepExtend(undefined, value); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function deepCopy(source){\n return JSON.parse(JSON.stringify(source));\n}", "copy(obj){\n return JSON.parse(JSON.stringify(obj));\n }", "function copy(o) {\n return JSON.parse(JSON.stringify(o));\n}", "function deepCopy(obj){\n return JSON.parse(JSON.stringify(obj));\n}", "function deepCopy(src) ...
[ "0.7375367", "0.73087543", "0.7194347", "0.71768814", "0.7167464", "0.7134046", "0.71329516", "0.7130612", "0.70624685", "0.7034208", "0.7034208", "0.7026713", "0.70003474", "0.6936194", "0.6918663", "0.6882317", "0.6870952", "0.6839788", "0.6814996", "0.6814589", "0.6806204"...
0.0
-1
Copy properties from source to target (recursively allows extension of Objects and Arrays). Scalar values in the target are overwritten. If target is undefined, an object of the appropriate type will be created (and returned). We recursively copy all child properties of plain Objects in the source so that namespace lik...
function deepExtend(target, source) { if (!(source instanceof Object)) { return source; } switch (source.constructor) { case Date: // Treat Dates like scalars; if the target date object had any child // properties - they will be lost! var dateValue...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function deepExtend(target, source) {\n if (!(source instanceof Object)) {\n return source;\n }\n\n switch (source.constructor) {\n case Date:\n // Treat Dates like scalars; if the target date object had any child\n // properties - they will be lost!\n var da...
[ "0.7501224", "0.7439495", "0.74256873", "0.74256873", "0.74256873", "0.74256873", "0.74256873", "0.74256873", "0.7419015", "0.7419015", "0.74101686", "0.74101686", "0.74101686", "0.74101686", "0.74101686", "0.74101686", "0.74101686", "0.74101686", "0.74101686", "0.74101686", ...
0.73403525
33
TODO: Really needed (for JSCompiler type checking)?
function patchProperty(obj, prop, value) { obj[prop] = value; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Js(e){return(Js=\"function\"==typeof Symbol&&\"symbol\"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&\"function\"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?\"symbol\":typeof e})(e)}", "function Type() {}", "__eval__(__source__, __boundValues__) { return...
[ "0.62902296", "0.58050174", "0.5695141", "0.56580913", "0.56333554", "0.5606612", "0.5565383", "0.5545024", "0.5512546", "0.55076134", "0.55066526", "0.5505603", "0.54781395", "0.5472474", "0.5468769", "0.5468146", "0.54635763", "0.5463289", "0.5453843", "0.54421264", "0.5437...
0.0
-1
Export for faking in tests
function patchCapture(captureFake) { var result = captureStackTrace; captureStackTrace = captureFake; return result; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setup() {}", "setup() {}", "setup() {}", "setup() {}", "function fakeUsage() {\n var fakeObj = fake('example');\n fakeObj.mock('foo').map([], 'bar');\n fakeObj.foo();\n }", "function AeUtil() {}", "async setup() { }", "function MockedProvider() {\n /* ... */\n}", "expected(_...
[ "0.63395375", "0.62538314", "0.62538314", "0.62538314", "0.59652007", "0.592908", "0.59203243", "0.5870511", "0.58335674", "0.5803979", "0.5803955", "0.5799477", "0.5797888", "0.5797888", "0.5751915", "0.5734973", "0.5734036", "0.5698406", "0.567787", "0.5670397", "0.56570923...
0.0
-1
Helper to make a Subscribe function (just like Promise helps make a Thenable).
function createSubscribe(executor, onNoObservers) { var proxy = new ObserverProxy(executor, onNoObservers); return proxy.subscribe.bind(proxy); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "subscribe(fn) {\n return this._subscribe(fn);\n }", "subscribe() {}", "subscribe(s) { return dispatcher.subscribe(s); }", "function subscribe ( util, uri, handler ) {\n var ws = util.connection ? util.connection : util;\n var p = Packet\n .make()\n .uri( uri )\...
[ "0.71118283", "0.69480467", "0.6911258", "0.688115", "0.68079275", "0.6788889", "0.6763425", "0.66539085", "0.6646344", "0.6621718", "0.6593132", "0.65709716", "0.65709716", "0.65709716", "0.65709716", "0.65709716", "0.65709716", "0.65709716", "0.65709716", "0.65709716", "0.6...
0.6600295
16
Turn synchronous function into one called asynchronously.
function async(fn, onError) { return function () { var args = []; for (var _i = 0; _i < arguments.length; _i++) { args[_i] = arguments[_i]; } Promise.resolve(true) .then(function () { fn.apply(void 0, args); }) .catch(...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async function MyAsyncFn () {}", "async function asyncFunction(arg) {\r\n return arg;\r\n}", "async function fn(){ //This is the newer way of doing an async function\n return 'hello';\n}", "async function asyncFn(){\n\n return 1;\n}", "async function f(){\n return something\n}", "function async(f...
[ "0.7155934", "0.7116087", "0.70804554", "0.68879116", "0.68725556", "0.6768867", "0.67274386", "0.6606676", "0.6605907", "0.6605907", "0.6598512", "0.6598512", "0.65512455", "0.65512455", "0.65438145", "0.65246886", "0.65200365", "0.6504154", "0.6503758", "0.64964813", "0.649...
0.5935199
58
Return true if the object passed in implements any of the named methods.
function implementsAnyMethods(obj, methods) { if (typeof obj !== 'object' || obj === null) { return false; } for (var _i = 0, methods_1 = methods; _i < methods_1.length; _i++) { var method = methods_1[_i]; if (method in obj && typeof obj[method] === 'function') { r...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function implementsAnyMethods(obj, methods) {\r\n if (typeof obj !== 'object' || obj === null) {\r\n return false;\r\n }\r\n var object = obj;\r\n for (var _i = 0, methods_1 = methods; _i < methods_1.length; _i++) {\r\n var method = methods_1[_i];\r\n if (method in object && typeof...
[ "0.7897867", "0.7897867", "0.7897867", "0.7887639", "0.7887639", "0.7887639", "0.7887639", "0.78607833", "0.78380656", "0.78380656", "0.78380656", "0.78259933", "0.78231764", "0.78231764", "0.78231764", "0.78231764", "0.78231764", "0.78231764", "0.78231764", "0.78231764", "0....
0.7840518
17
This has a complexity linear to the value of the code. The assumption is that looking up astral identifier characters is rare.
function isInAstralSet(code, set) { var pos = 0x10000; for (var i = 0; i < set.length; i += 2) { pos += set[i]; if (pos > code) { return false } pos += set[i + 1]; if (pos >= code) { return true } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isIdentifierChar(code, astral) {\n if (code < 48) return code === 36;\n if (code < 58) return true;\n if (code < 65) return false;\n if (code < 91) return true;\n if (code < 97) return code === 95;\n if (code < 123) return true;\n if (code <= 0xffff) return code >= 0xaa && nonASCIIidentifier.test(S...
[ "0.6759391", "0.674876", "0.674876", "0.6719769", "0.6719769", "0.6719769", "0.6718266", "0.6718266", "0.6718266", "0.6686632", "0.6686632", "0.6686632", "0.6686632", "0.6686632", "0.6686632", "0.6686632", "0.6686632", "0.6686632", "0.6686632", "0.6686632", "0.66606367", "0...
0.0
-1
Test whether a given character code starts an identifier.
function isIdentifierStart(code, astral) { if (code < 65) { return code === 36 } if (code < 91) { return true } if (code < 97) { return code === 95 } if (code < 123) { return true } if (code <= 0xffff) { return code >= 0xaa && nonASCIIidentifierStart.test(String.fromCharCode(code)) } if (astral === false) {...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isIdentifierStart(code) {\n if (code < 65) return code === 36;\n if (code < 91) return true;\n if (code < 97) return code === 95;\n if (code < 123) return true;\n if (code <= 0xffff) return code >= 0xaa && nonASCIIidentifierStart.test(String.fromCharCode(code));\n return isInAstralSet(code, astralId...
[ "0.8720475", "0.8720475", "0.8720475", "0.8698139", "0.8698139", "0.8698139", "0.8698139", "0.8698139", "0.8698139", "0.8698139", "0.8698139", "0.8698139", "0.85178787", "0.85178787", "0.85178787", "0.85115576", "0.85115576", "0.8494048", "0.8223864", "0.8223864", "0.81962353...
0.8485452
28
Test whether a given character is part of an identifier.
function isIdentifierChar(code, astral) { if (code < 48) { return code === 36 } if (code < 58) { return true } if (code < 65) { return false } if (code < 91) { return true } if (code < 97) { return code === 95 } if (code < 123) { return true } if (code <= 0xffff) { return code >= 0xaa && nonASCIIidentifie...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isIdentifierChar(code) {\n\t if (code < 48) return code === 36;\n\t if (code < 58) return true;\n\t if (code < 65) return false;\n\t if (code < 91) return true;\n\t if (code < 97) return code === 95;\n\t if (code < 123) return true;\n\t if (code <= 0xffff) return code >= 0xaa && nonASCIIidentifier....
[ "0.8051218", "0.8051218", "0.8051218", "0.8051218", "0.8051218", "0.8051218", "0.8051218", "0.8051218", "0.8051218", "0.80078155", "0.80078155", "0.80078155", "0.78380007", "0.78380007", "0.78380007", "0.7782578", "0.7782578", "0.7769867", "0.77178866", "0.76648295", "0.76620...
0.77737
26
Succinct definitions of keyword token types
function kw(name, options) { if ( options === void 0 ) options = {}; options.keyword = name; return keywords$1[name] = new TokenType(name, options) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function kw(name, options) {\n if ( options === void 0 ) options = {};\n\n options.keyword = name\n return keywordTypes[name] = new TokenType(name, options)\n}", "function kw(name, options) {\n if ( options === void 0 ) options = {};\n\n options.keyword = name\n keywordTypes[name] = tt[\"_\" + name] = new ...
[ "0.7119781", "0.71091473", "0.705262", "0.705262", "0.70280963", "0.70280963", "0.70205903", "0.7000085", "0.6955209", "0.6955209", "0.6955209", "0.6955209", "0.6955209", "0.6944097", "0.6944097", "0.6875176", "0.6791205", "0.6578073", "0.64432263", "0.6387144", "0.6342707", ...
0.70212656
15
Checks if an object has a property.
function has(obj, propName) { return hasOwnProperty.call(obj, propName) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function hasProperty(obj, prop) {\n return obj.hasOwnProperty(prop);\n}", "function checkGivenProperty(obj,property){\n return hasOwnProperty.call(obj,property);\n}", "function hasProperty (obj, propName) {\n return obj != null && typeof obj === 'object' && (propName in obj);\n }", "function hasPro...
[ "0.81458074", "0.8019888", "0.80009675", "0.80009675", "0.80009675", "0.80009675", "0.80009675", "0.80009675", "0.80009675", "0.80009675", "0.80009675", "0.80009675", "0.80009675", "0.80009675", "0.80009675", "0.80009675", "0.80009675", "0.80009675", "0.80009675", "0.7978682", ...
0.74655426
54
The `getLineInfo` function is mostly useful when the `locations` option is off (for performance reasons) and you want to find the line/column position for a given character offset. `input` should be the code string that the offset refers into.
function getLineInfo(input, offset) { for (var line = 1, cur = 0;;) { lineBreakG.lastIndex = cur; var match = lineBreakG.exec(input); if (match && match.index < offset) { ++line; cur = match.index + match[0].length; } else { return new Position(line, offset - cur) } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getLineInfo(input, offset) {\n for (var line = 1, cur = 0;;) {\n var nextBreak = nextLineBreak(input, cur, offset);\n if (nextBreak < 0) { return new Position(line, offset - cur) }\n ++line;\n cur = nextBreak;\n }\n}", "function getLineInfo(input, offset) {\n for (var line = 1, cur = 0;...
[ "0.8573441", "0.8534986", "0.85279596", "0.85279596", "0.8519235", "0.8519235", "0.84579295", "0.84579295", "0.84500694", "0.84500694", "0.8415851", "0.8348055", "0.8348055", "0.644414", "0.61385876", "0.6047828", "0.59417284", "0.5929556", "0.5929556", "0.5929556", "0.592955...
0.85206974
12
Interpret and default an options object
function getOptions(opts) { var options = {}; for (var opt in defaultOptions) { options[opt] = opts && has(opts, opt) ? opts[opt] : defaultOptions[opt]; } if (options.ecmaVersion >= 2015) { options.ecmaVersion -= 2009; } if (options.allowReserved == null) { options.allowReserved = options.ecmaVer...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "get options() {}", "set options(value) {}", "function options(o, k, a, i) {\n o.files = o.files||[];\n if (a[i]==='-h' || a[i]==='--help') o.help = true;\n else if (a[i]==='-o' || a[i]==='--output') o.output = a[++i];\n else if (a[i]==='-i' || a[i]==='--input') o.input = a[++i];\n else if (a[i]==='-s' |...
[ "0.7570844", "0.71893245", "0.67991704", "0.6662725", "0.65952104", "0.64926785", "0.64670914", "0.6447548", "0.6391328", "0.6385957", "0.6353899", "0.6312276", "0.6303747", "0.62941635", "0.6266218", "0.6266218", "0.62437254", "0.62333316", "0.62333316", "0.6226142", "0.6225...
0.0
-1
Finish an AST node, adding `type` and `end` properties.
function finishNodeAt(node, type, pos, loc) { node.type = type; node.end = pos; if (this.options.locations) { node.loc.end = loc; } if (this.options.ranges) { node.range[1] = pos; } return node }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function finishNode(node, type) {\n node.type = type;\n node.end = lastEnd;\n if (options.locations)\n node.loc.end = lastEndLoc;\n if (options.ranges)\n node.range[1] = lastEnd;\n return node;\n ...
[ "0.7520146", "0.63963157", "0.6272652", "0.6182319", "0.6182319", "0.6182319", "0.61174476", "0.58955485", "0.5865197", "0.5640883", "0.550494", "0.541169", "0.54019", "0.53866416", "0.53593165", "0.528267", "0.5258403", "0.5217955", "0.5162242", "0.51038045", "0.5065633", ...
0.60903645
16
The main exported interface (under `self.acorn` when in the browser) is a `parse` function that takes a code string and returns an abstract syntax tree as specified by [Mozilla parser API][api]. [api]:
function parse(input, options) { return new Parser(options, input).parse() }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Parse (code) {\n this.code = code\n}", "function acorn_parse(input, options) {\n return Parser.parse(input, options)\n}", "function Parser() {\n\n}", "function Parser() {\n}", "function Parser() {\n}", "function parseAndRun(code, state, callback) {\n const program = acorn.parse(code);\n re...
[ "0.6707588", "0.6692118", "0.6599717", "0.65766746", "0.65766746", "0.6441525", "0.63855094", "0.63404024", "0.63332415", "0.62201166", "0.621807", "0.6207969", "0.6162909", "0.6162601", "0.6162601", "0.6156242", "0.6156242", "0.6156242", "0.6156242", "0.6142595", "0.61303407...
0.0
-1
This function tries to parse a single expression at a given offset in a string. Useful for parsing mixedlanguage formats that embed JavaScript expressions.
function parseExpressionAt(input, pos, options) { var p = new Parser(options, input, pos); p.nextToken(); return p.parseExpression() }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function parseExpressionAt(input, pos, options) {\n var p = new _state.Parser(options, input, pos);\n p.nextToken();\n return p.parseExpression();\n}", "function parseExpressionAt(input, pos, options) {\n return Parser.parseExpressionAt(input, pos, options)\n }", "function parseExpressionAt(input, pos, ...
[ "0.65483725", "0.64095134", "0.64095134", "0.64095134", "0.6357989", "0.6357989", "0.6357989", "0.6357989", "0.6357989", "0.6357989", "0.6357989", "0.6297378", "0.6297378", "0.6297378", "0.6270578", "0.6211725", "0.60523975", "0.60290456", "0.6027976", "0.57910913", "0.570137...
0.6568649
2
Acorn is organized as a tokenizer and a recursivedescent parser. The `tokenizer` export provides an interface to the tokenizer.
function tokenizer(input, options) { return new Parser(options, input) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "tokenizer(token , isEndOfInput , previousTokens , terminal , config){\n }", "function tokenizer(input, options) {\n return Parser.tokenizer(input, options)\n }", "function tokenizer(input, options) {\n return Parser.tokenizer(input, options)\n }", "function tokenizer(input, options) {\n return ...
[ "0.6867658", "0.61212033", "0.61212033", "0.61212033", "0.6061202", "0.5989804", "0.59251326", "0.59251326", "0.59251326", "0.59251326", "0.59251326", "0.59251326", "0.59251326", "0.5847465", "0.57643414", "0.57420915", "0.57230216", "0.5683116", "0.5656273", "0.5648087", "0....
0.57611364
17
This is a terrible kludge to support the existing, preES6 interface where the loose parser module retroactively adds exports to this module. eslintdisableline camelcase
function addLooseExports(parse, Parser$$1, plugins$$1) { exports.parse_dammit = parse; // eslint-disable-line camelcase exports.LooseParser = Parser$$1; exports.pluginsLoose = plugins$$1; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function u(t,e){return t(e={exports:{}},e.exports),e.exports}", "function exports() {}", "function exports() {}", "function exports() {}", "function s(e){return e&&e.__esModule?e:{default:e}}", "function s(e){return e&&e.__esModule?e:{default:e}}", "resolveImports() {\n return { safeMath: true, paus...
[ "0.59641546", "0.5957586", "0.5957586", "0.5957586", "0.5743198", "0.5743198", "0.56995517", "0.5624032", "0.5601947", "0.55620044", "0.5551094", "0.5517886", "0.54847705", "0.5440284", "0.5421127", "0.5350658", "0.533074", "0.533074", "0.53231806", "0.53041846", "0.5299287",...
0.5879617
5
base64 is 4/3 + up to two characters of the original data
function byteLength (b64) { var lens = getLens(b64) var validLen = lens[0] var placeHoldersLen = lens[1] return ((validLen + placeHoldersLen) * 3 / 4) - placeHoldersLen }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "getBase64() {\n var s = this.getDump();\n\n var ch =\n \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\";\n var c1, c2, c3, e1, e2, e3, e4;\n var l = s.length;\n var i = 0;\n var r = \"\";\n\n do {\n c1 = s.charCodeAt(i);\n e1 = c1 >> 2;\n c2 = s.charCod...
[ "0.77057606", "0.7324507", "0.72870255", "0.7230772", "0.7183817", "0.71231633", "0.7105772", "0.7089243", "0.7062078", "0.6977857", "0.6975599", "0.6933752", "0.6899215", "0.6899215", "0.6893997", "0.6879304", "0.68740326", "0.68740326", "0.68538475", "0.68362004", "0.681601...
0.0
-1
The Buffer constructor returns instances of `Uint8Array` that have their prototype changed to `Buffer.prototype`. Furthermore, `Buffer` is a subclass of `Uint8Array`, so the returned instances will have all the node `Buffer` methods and the `Uint8Array` methods. Square bracket notation works as expected it returns a si...
function Buffer (arg, encodingOrOffset, length) { // Common case. if (typeof arg === 'number') { if (typeof encodingOrOffset === 'string') { throw new Error( 'If encoding is specified then the first argument must be a string' ) } return allocUnsafe(arg) } return from(arg, encodin...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function BufferToArrayBuffer () {\n return (new Buffer(this)).buffer\n}", "function BufferToArrayBuffer () {\n return (new Buffer(this)).buffer\n}", "function BufferToArrayBuffer () {\n return (new Buffer(this)).buffer\n}", "function BufferToArrayBuffer () {\n return (new Buffer(this)).buffer\n}", "toB...
[ "0.7352709", "0.7352709", "0.7352709", "0.7352709", "0.69731885", "0.68939346", "0.68939346", "0.6847772", "0.6847772", "0.6847772", "0.6847772", "0.6847772", "0.6847772", "0.6847772", "0.6837532", "0.6837532", "0.6837532", "0.6837532", "0.6837532", "0.6837532", "0.6837532", ...
0.0
-1
Finds either the first index of `val` in `buffer` at offset >= `byteOffset`, OR the last index of `val` in `buffer` at offset <= `byteOffset`. Arguments: buffer a Buffer to search val a string, Buffer, or number byteOffset an index into `buffer`; will be clamped to an int32 encoding an optional encoding, relevant is va...
function bidirectionalIndexOf (buffer, val, byteOffset, encoding, dir) { // Empty buffer means no match if (buffer.length === 0) return -1 // Normalize byteOffset if (typeof byteOffset === 'string') { encoding = byteOffset byteOffset = 0 } else if (byteOffset > 0x7fffffff) { byteOffset = 0x7fffff...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function bidirectionalIndexOf(buffer,val,byteOffset,encoding,dir){// Empty buffer means no match\n if(buffer.length===0)return -1;// Normalize byteOffset\n if(typeof byteOffset==='string'){encoding=byteOffset;byteOffset=0;}else if(byteOffset>0x7fffffff){byteOffset=0x7fffffff;}else if(byteOffset<-0x80000000){byte...
[ "0.82820684", "0.8254326", "0.8254326", "0.82527834", "0.82527834", "0.82527834", "0.82527834", "0.82527834", "0.82527834", "0.82527834", "0.82527834", "0.8247838", "0.8245605", "0.8243842", "0.8243842", "0.8227566", "0.82194644", "0.8218097", "0.8218097", "0.8218097", "0.821...
0.0
-1
Need to make sure that buffer isn't trying to write out of bounds.
function checkOffset (offset, ext, length) { if ((offset % 1) !== 0 || offset < 0) throw new RangeError('offset is not uint') if (offset + ext > length) throw new RangeError('Trying to access beyond buffer length') }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function writeBuffer(buffer, pos, src) {\n src.copy(buffer, pos)\n return src.length\n}", "function writeBuffer(buffer, pos, src) {\n src.copy(buffer, pos)\n return src.length\n}", "ensure(n) {\n let minsize = this.pos + n;\n if (minsize > this.capacity) {\n let cap = this.capacity * 2;\n w...
[ "0.66712785", "0.66712785", "0.6632945", "0.65210676", "0.63827264", "0.62754023", "0.62562263", "0.62335545", "0.62335545", "0.61056054", "0.6035937", "0.6017502", "0.59810936", "0.5959609", "0.5951102", "0.5951102", "0.5951102", "0.5951102", "0.5951102", "0.5951102", "0.595...
0.0
-1
ArrayBuffers from another context (i.e. an iframe) do not pass the `instanceof` check but they should be treated as valid. See:
function isArrayBuffer (obj) { return obj instanceof ArrayBuffer || (obj != null && obj.constructor != null && obj.constructor.name === 'ArrayBuffer' && typeof obj.byteLength === 'number') }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isArrayBuffer (o) { return o instanceof ArrayBuffer }", "function isArrayBuffer (o) { return o instanceof ArrayBuffer }", "function isArrayBufferView(obj){return typeof ArrayBuffer.isView===\"function\"&&ArrayBuffer.isView(obj)}", "function isArrayBuffer(obj){return obj instanceof ArrayBuffer||obj!=...
[ "0.69085234", "0.69085234", "0.6720318", "0.6711146", "0.66147333", "0.65531737", "0.65471214", "0.6545262", "0.6545262", "0.6545262", "0.6545262", "0.6545262", "0.6545262", "0.6545262", "0.6545262", "0.6545262", "0.6545262", "0.6545262", "0.6545262", "0.6545262", "0.6545262"...
0.6538274
52
From FvD 13.37, CSS Color Module Level 3
function hsl2rgb(h, m1, m2) { return (h < 60 ? m1 + (m2 - m1) * h / 60 : h < 180 ? m2 : h < 240 ? m1 + (m2 - m1) * (240 - h) / 60 : m1) * 255; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function Colour(){\n\n /* Returns an object representing the RGBA components of this Colour. The red,\n * green, and blue components are converted to integers in the range [0,255].\n * The alpha is a value in the range [0,1].\n */\n this.getIntegerRGB = function(){\n\n // get the RGB components of this ...
[ "0.7089194", "0.7050894", "0.70180076", "0.6918326", "0.69088155", "0.6865348", "0.6787769", "0.6779162", "0.67433536", "0.6725297", "0.6723463", "0.6701248", "0.66937774", "0.66653216", "0.6639698", "0.66359454", "0.66359454", "0.66359454", "0.66295534", "0.66295534", "0.662...
0.0
-1